Skip to content

Commit 16382f8

Browse files
authored
Merge pull request #5553 from TrainLCD/dev
canary
2 parents 245ac8a + 3a4a801 commit 16382f8

27 files changed

+1518
-659
lines changed

android/app/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -141,12 +141,12 @@ android {
141141
dimension "environment"
142142
applicationId "me.tinykitten.trainlcd.dev"
143143
versionNameSuffix "-dev"
144-
versionCode 100000309
144+
versionCode 100000310
145145
versionName "10.2.1"
146146
}
147147
prod {
148148
dimension "environment"
149-
versionCode 100000309
149+
versionCode 100000310
150150
versionName "10.2.1"
151151
}
152152
}

app.config.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ export default ({ config }: ConfigContext) => ({
5252
},
5353
},
5454
ios: {
55-
buildNumber: '2522',
55+
buildNumber: '2523',
5656
bundleIdentifier:
5757
process.env.EAS_BUILD_PROFILE === 'production'
5858
? 'me.tinykitten.trainlcd'
@@ -69,7 +69,7 @@ export default ({ config }: ConfigContext) => ({
6969
? 'me.tinykitten.trainlcd'
7070
: 'me.tinykitten.trainlcd.dev',
7171
permissions: [],
72-
versionCode: 100000309,
72+
versionCode: 100000310,
7373
},
7474
owner: 'trainlcd',
7575
});
@@ -86,3 +86,4 @@ export default ({ config }: ConfigContext) => ({
8686

8787

8888

89+

assets/translations/en.json

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -277,5 +277,11 @@
277277
"settingsWalkthroughDescription3": "Configure auto announcement settings. You can receive voice guidance when arriving at stations.",
278278
"settingsWalkthroughTitle4": "Display Languages",
279279
"settingsWalkthroughDescription4": "Set the languages to display on screen. You can choose from Japanese, English, Chinese, and Korean.",
280-
"requireJapaneseOrEnglish": "Either Japanese or English must be set."
280+
"requireJapaneseOrEnglish": "Either Japanese or English must be set.",
281+
"savePresetTitle": "Save preset",
282+
"presetNameLabel": "Preset name",
283+
"presetNamePlaceholder": "Preset name",
284+
"save": "Save",
285+
"selectStartStationTitle": "Select starting station",
286+
"departure": "Dep."
281287
}

assets/translations/ja.json

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -278,5 +278,11 @@
278278
"settingsWalkthroughDescription3": "自動アナウンス機能の設定ができます。駅到着時に音声で案内を受け取ることができます。",
279279
"settingsWalkthroughTitle4": "表示言語",
280280
"settingsWalkthroughDescription4": "画面に表示する言語を設定できます。日本語、英語、中国語、韓国語から選択可能です。",
281-
"requireJapaneseOrEnglish": "日本語または英語のいずれかを設定する必要があります"
281+
"requireJapaneseOrEnglish": "日本語または英語のいずれかを設定する必要があります",
282+
"savePresetTitle": "プリセットを保存",
283+
"presetNameLabel": "プリセット名",
284+
"presetNamePlaceholder": "プリセット名",
285+
"save": "保存",
286+
"selectStartStationTitle": "始発駅を選択",
287+
"departure": "始発"
282288
}

functions/src/funcs/tts.ts

Lines changed: 31 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ const googleTtsApiKey = defineSecret('GOOGLE_TTS_API_KEY');
2323
const GEMINI_TTS_MODEL = 'gemini-2.5-flash-tts';
2424
const VERTEX_AI_LOCATION = 'us-central1';
2525
const GOOGLE_TTS_API_VERSION = 'v1';
26-
const EN_GEMINI_VOLUME_BOOST_DB = 6;
26+
const EN_GEMINI_VOLUME_BOOST_DB = 4;
2727

2828
interface SynthesizedAudio {
2929
audioContent: string;
@@ -82,13 +82,38 @@ const ensureMp3 = async (
8282
/** 0〜99 の整数を英単語に変換する */
8383
const numberToEnglishWord = (n: number): string => {
8484
const ones = [
85-
'zero', 'one', 'two', 'three', 'four', 'five', 'six', 'seven', 'eight',
86-
'nine', 'ten', 'eleven', 'twelve', 'thirteen', 'fourteen', 'fifteen',
87-
'sixteen', 'seventeen', 'eighteen', 'nineteen',
85+
'zero',
86+
'one',
87+
'two',
88+
'three',
89+
'four',
90+
'five',
91+
'six',
92+
'seven',
93+
'eight',
94+
'nine',
95+
'ten',
96+
'eleven',
97+
'twelve',
98+
'thirteen',
99+
'fourteen',
100+
'fifteen',
101+
'sixteen',
102+
'seventeen',
103+
'eighteen',
104+
'nineteen',
88105
];
89106
const tens = [
90-
'', '', 'twenty', 'thirty', 'forty', 'fifty', 'sixty', 'seventy',
91-
'eighty', 'ninety',
107+
'',
108+
'',
109+
'twenty',
110+
'thirty',
111+
'forty',
112+
'fifty',
113+
'sixty',
114+
'seventy',
115+
'eighty',
116+
'ninety',
92117
];
93118
if (n < 20) return ones[n] ?? String(n);
94119
if (n < 100) {

ios/TrainLCD.xcodeproj/project.pbxproj

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -2419,7 +2419,7 @@
24192419
CODE_SIGN_ENTITLEMENTS = ProdTrainLCD.entitlements;
24202420
CODE_SIGN_IDENTITY = "Apple Development";
24212421
CODE_SIGN_STYLE = Automatic;
2422-
CURRENT_PROJECT_VERSION = 2522;
2422+
CURRENT_PROJECT_VERSION = 2523;
24232423
DEAD_CODE_STRIPPING = YES;
24242424
DEVELOPMENT_TEAM = E6R2G33Z36;
24252425
INFOPLIST_FILE = TrainLCD/Schemes/Prod/Info.plist;
@@ -2458,7 +2458,7 @@
24582458
CODE_SIGN_ENTITLEMENTS = ProdTrainLCD.entitlements;
24592459
CODE_SIGN_IDENTITY = "Apple Development";
24602460
CODE_SIGN_STYLE = Automatic;
2461-
CURRENT_PROJECT_VERSION = 2522;
2461+
CURRENT_PROJECT_VERSION = 2523;
24622462
DEVELOPMENT_TEAM = E6R2G33Z36;
24632463
INFOPLIST_FILE = TrainLCD/Schemes/Prod/Info.plist;
24642464
INFOPLIST_KEY_CFBundleDisplayName = TrainLCD;
@@ -2517,7 +2517,7 @@
25172517
CODE_SIGN_ENTITLEMENTS = TrainLCD/trainlcd.entitlements;
25182518
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
25192519
COPY_PHASE_STRIP = NO;
2520-
CURRENT_PROJECT_VERSION = 2522;
2520+
CURRENT_PROJECT_VERSION = 2523;
25212521
CXX = "$(REACT_NATIVE_PATH)/scripts/xcode/ccache-clang++.sh";
25222522
ENABLE_STRICT_OBJC_MSGSEND = YES;
25232523
ENABLE_TESTABILITY = YES;
@@ -2623,7 +2623,7 @@
26232623
CODE_SIGN_ENTITLEMENTS = TrainLCD/trainlcd.entitlements;
26242624
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
26252625
COPY_PHASE_STRIP = YES;
2626-
CURRENT_PROJECT_VERSION = 2522;
2626+
CURRENT_PROJECT_VERSION = 2523;
26272627
CXX = "$(REACT_NATIVE_PATH)/scripts/xcode/ccache-clang++.sh";
26282628
ENABLE_NS_ASSERTIONS = NO;
26292629
ENABLE_STRICT_OBJC_MSGSEND = YES;
@@ -2702,7 +2702,7 @@
27022702
CODE_SIGN_ENTITLEMENTS = CanaryTrainLCD.entitlements;
27032703
CODE_SIGN_IDENTITY = "Apple Development";
27042704
CODE_SIGN_STYLE = Automatic;
2705-
CURRENT_PROJECT_VERSION = 2522;
2705+
CURRENT_PROJECT_VERSION = 2523;
27062706
DEAD_CODE_STRIPPING = YES;
27072707
DEVELOPMENT_TEAM = E6R2G33Z36;
27082708
INFOPLIST_FILE = TrainLCD/Schemes/Dev/Info.plist;
@@ -2741,7 +2741,7 @@
27412741
CODE_SIGN_ENTITLEMENTS = CanaryTrainLCD.entitlements;
27422742
CODE_SIGN_IDENTITY = "Apple Development";
27432743
CODE_SIGN_STYLE = Automatic;
2744-
CURRENT_PROJECT_VERSION = 2522;
2744+
CURRENT_PROJECT_VERSION = 2523;
27452745
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
27462746
DEVELOPMENT_TEAM = E6R2G33Z36;
27472747
INFOPLIST_FILE = TrainLCD/Schemes/Dev/Info.plist;
@@ -2952,7 +2952,7 @@
29522952
CODE_SIGN_ENTITLEMENTS = RideSessionActivity/CanaryRideSessionActivity.entitlements;
29532953
CODE_SIGN_IDENTITY = "Apple Development";
29542954
CODE_SIGN_STYLE = Automatic;
2955-
CURRENT_PROJECT_VERSION = 2522;
2955+
CURRENT_PROJECT_VERSION = 2523;
29562956
DEBUG_INFORMATION_FORMAT = dwarf;
29572957
DEVELOPMENT_TEAM = E6R2G33Z36;
29582958
GCC_C_LANGUAGE_STANDARD = gnu11;
@@ -3003,7 +3003,7 @@
30033003
CODE_SIGN_IDENTITY = "Apple Development";
30043004
CODE_SIGN_STYLE = Automatic;
30053005
COPY_PHASE_STRIP = NO;
3006-
CURRENT_PROJECT_VERSION = 2522;
3006+
CURRENT_PROJECT_VERSION = 2523;
30073007
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
30083008
DEVELOPMENT_TEAM = E6R2G33Z36;
30093009
GCC_C_LANGUAGE_STANDARD = gnu11;
@@ -3054,7 +3054,7 @@
30543054
CODE_SIGN_ENTITLEMENTS = WatchWidget/ProdWatchWidget.entitlements;
30553055
CODE_SIGN_IDENTITY = "Apple Development";
30563056
CODE_SIGN_STYLE = Automatic;
3057-
CURRENT_PROJECT_VERSION = 2522;
3057+
CURRENT_PROJECT_VERSION = 2523;
30583058
DEBUG_INFORMATION_FORMAT = dwarf;
30593059
DEVELOPMENT_TEAM = E6R2G33Z36;
30603060
ENABLE_USER_SCRIPT_SANDBOXING = YES;
@@ -3112,7 +3112,7 @@
31123112
CODE_SIGN_IDENTITY = "Apple Development";
31133113
CODE_SIGN_STYLE = Automatic;
31143114
COPY_PHASE_STRIP = NO;
3115-
CURRENT_PROJECT_VERSION = 2522;
3115+
CURRENT_PROJECT_VERSION = 2523;
31163116
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
31173117
DEVELOPMENT_TEAM = E6R2G33Z36;
31183118
ENABLE_USER_SCRIPT_SANDBOXING = YES;
@@ -3163,7 +3163,7 @@
31633163
CODE_SIGN_ENTITLEMENTS = WatchWidget/CanaryWatchWidget.entitlements;
31643164
CODE_SIGN_IDENTITY = "Apple Development";
31653165
CODE_SIGN_STYLE = Automatic;
3166-
CURRENT_PROJECT_VERSION = 2522;
3166+
CURRENT_PROJECT_VERSION = 2523;
31673167
DEBUG_INFORMATION_FORMAT = dwarf;
31683168
DEVELOPMENT_TEAM = E6R2G33Z36;
31693169
ENABLE_USER_SCRIPT_SANDBOXING = YES;
@@ -3220,7 +3220,7 @@
32203220
CODE_SIGN_IDENTITY = "Apple Development";
32213221
CODE_SIGN_STYLE = Automatic;
32223222
COPY_PHASE_STRIP = NO;
3223-
CURRENT_PROJECT_VERSION = 2522;
3223+
CURRENT_PROJECT_VERSION = 2523;
32243224
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
32253225
DEVELOPMENT_TEAM = E6R2G33Z36;
32263226
ENABLE_USER_SCRIPT_SANDBOXING = YES;
@@ -3268,7 +3268,7 @@
32683268
CODE_SIGN_ENTITLEMENTS = RideSessionActivity/ProdRideSessionActivity.entitlements;
32693269
CODE_SIGN_IDENTITY = "Apple Development";
32703270
CODE_SIGN_STYLE = Automatic;
3271-
CURRENT_PROJECT_VERSION = 2522;
3271+
CURRENT_PROJECT_VERSION = 2523;
32723272
DEBUG_INFORMATION_FORMAT = dwarf;
32733273
DEVELOPMENT_TEAM = E6R2G33Z36;
32743274
GCC_C_LANGUAGE_STANDARD = gnu11;
@@ -3319,7 +3319,7 @@
33193319
CODE_SIGN_IDENTITY = "Apple Development";
33203320
CODE_SIGN_STYLE = Automatic;
33213321
COPY_PHASE_STRIP = NO;
3322-
CURRENT_PROJECT_VERSION = 2522;
3322+
CURRENT_PROJECT_VERSION = 2523;
33233323
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
33243324
DEVELOPMENT_TEAM = E6R2G33Z36;
33253325
GCC_C_LANGUAGE_STANDARD = gnu11;
@@ -3538,7 +3538,7 @@
35383538
CODE_SIGN_ENTITLEMENTS = ProdAppClip/ProdAppClip.entitlements;
35393539
CODE_SIGN_IDENTITY = "Apple Development";
35403540
CODE_SIGN_STYLE = Automatic;
3541-
CURRENT_PROJECT_VERSION = 2522;
3541+
CURRENT_PROJECT_VERSION = 2523;
35423542
DEBUG_INFORMATION_FORMAT = dwarf;
35433543
DEVELOPMENT_TEAM = E6R2G33Z36;
35443544
ENABLE_USER_SCRIPT_SANDBOXING = NO;
@@ -3594,7 +3594,7 @@
35943594
CODE_SIGN_IDENTITY = "Apple Development";
35953595
CODE_SIGN_STYLE = Automatic;
35963596
COPY_PHASE_STRIP = NO;
3597-
CURRENT_PROJECT_VERSION = 2522;
3597+
CURRENT_PROJECT_VERSION = 2523;
35983598
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
35993599
DEVELOPMENT_TEAM = E6R2G33Z36;
36003600
ENABLE_USER_SCRIPT_SANDBOXING = NO;
@@ -3644,7 +3644,7 @@
36443644
CODE_SIGN_ENTITLEMENTS = CanaryAppClip/CanaryAppClip.entitlements;
36453645
CODE_SIGN_IDENTITY = "Apple Development";
36463646
CODE_SIGN_STYLE = Automatic;
3647-
CURRENT_PROJECT_VERSION = 2522;
3647+
CURRENT_PROJECT_VERSION = 2523;
36483648
DEBUG_INFORMATION_FORMAT = dwarf;
36493649
DEVELOPMENT_TEAM = E6R2G33Z36;
36503650
ENABLE_USER_SCRIPT_SANDBOXING = NO;
@@ -3702,7 +3702,7 @@
37023702
CODE_SIGN_IDENTITY = "Apple Development";
37033703
CODE_SIGN_STYLE = Automatic;
37043704
COPY_PHASE_STRIP = NO;
3705-
CURRENT_PROJECT_VERSION = 2522;
3705+
CURRENT_PROJECT_VERSION = 2523;
37063706
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
37073707
DEVELOPMENT_TEAM = E6R2G33Z36;
37083708
ENABLE_USER_SCRIPT_SANDBOXING = NO;

src/components/ChevronYamanote.tsx

Lines changed: 11 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,9 @@
11
import { useId } from 'react';
2-
import { StyleSheet, View } from 'react-native';
3-
import Animated, {
4-
type SharedValue,
5-
useAnimatedStyle,
6-
} from 'react-native-reanimated';
2+
import { Animated, StyleSheet, View } from 'react-native';
73
import { LinearGradient, Path, Polygon, Stop, Svg } from 'react-native-svg';
84

95
type Props = {
10-
backgroundScaleSV?: SharedValue<number>;
6+
backgroundScaleAV?: Animated.Value;
117
arrived: boolean;
128
};
139

@@ -21,14 +17,9 @@ const localStyles = StyleSheet.create({
2117
},
2218
});
2319

24-
export const ChevronYamanote = ({ backgroundScaleSV, arrived }: Props) => {
20+
export const ChevronYamanote = ({ backgroundScaleAV, arrived }: Props) => {
2521
const id = useId();
2622

27-
// 赤い塗り部分だけを拡縮するアニメーションスタイル
28-
const fillScaleStyle = useAnimatedStyle(() => ({
29-
transform: [{ scale: backgroundScaleSV?.value ?? 1 }],
30-
}));
31-
3223
if (!arrived) {
3324
return (
3425
<Svg viewBox="0 0 393 296" width="100%" height="100%">
@@ -56,7 +47,14 @@ export const ChevronYamanote = ({ backgroundScaleSV, arrived }: Props) => {
5647
<Path fill="#fff" d="M268 4H4v288h264l120-144z" />
5748
</Svg>
5849
{/* 赤い塗りだけ Animated.View で拡縮 */}
59-
<Animated.View style={[localStyles.fill, fillScaleStyle]}>
50+
<Animated.View
51+
style={[
52+
localStyles.fill,
53+
backgroundScaleAV
54+
? { transform: [{ scale: backgroundScaleAV }] }
55+
: undefined,
56+
]}
57+
>
6058
<Svg viewBox="0 0 393.2 296" width="100%" height="100%">
6159
<LinearGradient
6260
id={id}

0 commit comments

Comments
 (0)