@@ -121,8 +121,12 @@ export class AddRedirectModelElement extends UmbModalBaseElement {
121
121
}
122
122
123
123
render ( ) {
124
+ const self = this ;
125
+ function term ( key ) { return self . localize . term ( "redirects_" + key ) ; }
126
+ function label ( key ) { return self . localize . term ( "redirectsLabels_" + key ) ; }
127
+ function property ( key ) { return self . localize . term ( "redirectsProperties_" + key ) ; }
124
128
return html `
125
- <umb- body- layout headline= "Add new redirect " >
129
+ <umb- body- layout headline= "${ term ( "addRedirectTitle" ) } " >
126
130
<uui- box>
127
131
<div class= "property" >
128
132
<div>
@@ -139,55 +143,55 @@ export class AddRedirectModelElement extends UmbModalBaseElement {
139
143
</ div>
140
144
<div class= "property" >
141
145
<div>
142
- <strong> Original URL <span style= "color: red;" > * </ span> </ strong> <br / >
143
- <small > Specify the original URL to match from which the user should be redirected to the destination . </ small>
146
+ <strong> ${ property ( "originalUrl" ) } <span style= "color: red;" > * </ span> </ strong> <br / >
147
+ <small > ${ property ( "originalUrlDescription" ) } </ small>
144
148
</ div>
145
149
<div>
146
- <uui- input id= "originalUrl" label = "Original URL "> </ uui- input>
150
+ <uui- input id= "originalUrl" label = "${ property ( "originalUrl" ) } "> </ uui- input>
147
151
</ div>
148
152
</ div>
149
153
<div class= "property" >
150
154
<div>
151
- <strong> Destination <span style= "color: red;" > * </ span> </ strong> <br / >
152
- <small > Select the page or URL the user should be redirected to . </ small>
155
+ <strong> ${ property ( "destination" ) } <span style= "color: red;" > * </ span> </ strong> <br / >
156
+ <small > ${ property ( "destinationDescription" ) } </ small>
153
157
</ div>
154
158
<div>
155
159
<redirects- destination id= "destination" > </ redirects- destination>
156
160
</ div>
157
161
</ div>
158
- <h4> Advanced Options </ h4>
162
+ <h4> ${ label ( "advancedOptions" ) } </ h4>
159
163
<div class= "property" >
160
164
<div>
161
- <strong> Redirect type </ strong> <br / >
162
- <small> Select the type of the redirect . Notice that browsers will remember permanent redirects . </ small>
165
+ <strong> ${ property ( "redirectType" ) } </ strong> <br / >
166
+ <small> ${ property ( "redirectTypeDescription" ) } </ small>
163
167
</ div>
164
168
<div>
165
169
<uui- radio- group name= "redirectType" >
166
- <uui- radio id= "redirectTypePermanent" value = "permanent" label= "Permanent " checked= "checked"> </ uui- radio>
167
- <uui- radio id= "redirectTypeTemporary" value = "tempor ary" label= "Temp or ary "> </ uui- radio>
170
+ <uui- radio id= "redirectTypePermanent" value = "permanent" label= "${ term ( "permanent" ) } " checked= "checked"> </ uui- radio>
171
+ <uui- radio id= "redirectTypeTemporary" value = "tempor ary" label= "${ term ( "temporary" ) } "> </ uui- radio>
168
172
</ uui- radio- group>
169
173
</ div>
170
174
</ div>
171
175
<div class= "property" >
172
176
<div>
173
- <strong> Forward query string </ strong> <br / >
174
- <small> When enabled , the query string of the original request is forwarded to the redirect location (pass through). </ small>
177
+ <strong> ${ property ( "forwardQueryString" ) } </ strong> <br / >
178
+ <small> ${ property ( "forwardQueryStringDescription" ) } </ small>
175
179
</ div>
176
180
<div>
177
181
<uui- radio- group name= "forward" >
178
- <uui- radio id= "forwardEnabled" value = "enabled" label=" Enabled "></uui-radio>
179
- <uui-radio id=" forwardDisabled" value=" disabled" label=" Disabled " checked=" true"></uui-radio>
182
+ <uui- radio id= "forwardEnabled" value = "enabled" label= "${ term ( "enabled" ) } "> </ uui- radio>
183
+ <uui- radio id= "forwardDisabled" value = "dis abled" label= "${ term ( "disabled" ) } " checked= "true"> </ uui- radio>
180
184
</ uui- radio- group>
181
185
</ div>
182
186
</ div>
183
187
</ uui- box>
184
188
<div slot= "actions" >
185
- <uui-button id=" cancel" label=" Cancel " @click="${ this . handleCancel } ">Cancel </uui-button>
189
+ <uui- butto n id= "cancel" label = "${ this . localize . term ( "general_cancel" ) } " @click = "${ this . handleCancel } "> ${ this . localize . term ( "general_cancel" ) } </ uui- butto n>
186
190
<uui- butto n
187
191
id= "submit"
188
192
color = 'positive'
189
193
look= "primary"
190
- label=" Submit "
194
+ label= "${ term ( "save" ) } "
191
195
state= "${ this . submitButtonState } "
192
196
@click = "${ this . handleConfirm } "> </ uui- butto n>
193
197
</ div>
0 commit comments