Skip to content

Commit 6b61fb6

Browse files
derekmcqccbrown
andauthored
add jp locale ("sort of" fixes ccbrown#108) (ccbrown#120)
* add jp locale * change translations to sound more natural Co-authored-by: Chris <[email protected]> --------- Co-authored-by: Chris <[email protected]>
1 parent b1e2421 commit 6b61fb6

File tree

3 files changed

+26
-0
lines changed

3 files changed

+26
-0
lines changed

aws-sam/gggtracker.cfn.yaml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,13 @@ Resources:
8989
DomainName: !Sub www.${DomainName}
9090
RestApiId: !Ref API
9191
Stage: !Ref APIStage
92+
APIBasePathMappingSubdomain8:
93+
Type: AWS::ApiGateway::BasePathMapping
94+
DependsOn: APISubdomainName8
95+
Properties:
96+
DomainName: !Sub jp.${DomainName}
97+
RestApiId: !Ref API
98+
Stage: !Ref APIStage
9299
APICloudWatchRole:
93100
Type: AWS::IAM::Role
94101
Properties:
@@ -165,6 +172,14 @@ Resources:
165172
EndpointConfiguration:
166173
Types:
167174
- EDGE
175+
APISubdomainName8:
176+
Type: AWS::ApiGateway::DomainName
177+
Properties:
178+
CertificateArn: !Ref CertificateARN
179+
DomainName: !Sub jp.${DomainName}
180+
EndpointConfiguration:
181+
Types:
182+
- EDGE
168183
APIProxyResource:
169184
Type: AWS::ApiGateway::Resource
170185
Properties:

server/localization.go

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -155,6 +155,17 @@ var Locales = []*Locale{
155155
"Forum": "Foro",
156156
},
157157
},
158+
{
159+
Subdomain: "jp",
160+
Image: "static/images/locales/jp.png",
161+
Translations: map[string]string{
162+
"Activity": "アクティビティ",
163+
"Thread": "スレッド",
164+
"Poster": "投稿者",
165+
"Time": "日時",
166+
"Forum": "フォーラム",
167+
},
168+
},
158169
}
159170

160171
func LocaleForRequest(r *http.Request) *Locale {
209 Bytes
Loading

0 commit comments

Comments
 (0)