You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -142,75 +142,162 @@ The **LocalizedString** element contains the following attributes:
142
142
143
143
| Attribute | Required | Description |
144
144
| --------- | -------- | ----------- |
145
-
| ElementType | Yes | Possible values: `ClaimType`, `UxElement`, `ErrorMessage`, `Predicate`, or `GetLocalizedStringsTransformationClaimType`. |
145
+
| ElementType | Yes | Possible values: `ClaimsProvider`, `ClaimType`, `ErrorMessage`, `GetLocalizedStringsTransformationClaimType`, `Predicate`, `InputValidation`, or `UxElement`. |
146
146
| ElementId | Yes | If **ElementType** is set to `ClaimType`, `Predicate`, or `InputValidation`, this element contains a reference to a claim type already defined in the ClaimsSchema section. |
147
147
| StringId | Yes | If **ElementType** is set to `ClaimType`, this element contains a reference to an attribute of a claim type. Possible values: `DisplayName`, `AdminHelpText`, or `PatternHelpText`. The `DisplayName` value is used to set the claim display name. The `AdminHelpText` value is used to set the help text name of the claim user. The `PatternHelpText` value is used to set the claim pattern help text. If **ElementType** is set to `UxElement`, this element contains a reference to an attribute of a user interface element. If **ElementType** is set to `ErrorMessage`, this element specifies the identifier of an error message. See [Localization string IDs](localization-string-ids.md) for a complete list of the `UxElement` identifiers.|
148
148
149
149
## ElementType
150
150
151
-
The ElementType reference to a claim type or a user interface element in the policy to be localized.
151
+
The ElementType reference to a claim type, a claim transformation, or a user interface element in the policy to be localized.
152
+
153
+
### ClaimsProvider
154
+
155
+
The ClaimsProvider value is used to localize claim provider name as specified in the StringId.
The ClaimType value is used to localize one of the claim attributes, as specified in the StringId. The following example shows how to localized the DisplayName, UserHelpText and PatternHelpText attributes of the email claim type.
181
+
The ClaimType value is used to localize one of the claim attributes, as specified in the StringId.
182
+
183
+
```xml
184
+
<ClaimTypeId="email">
185
+
<DisplayName>Email Address</DisplayName>
186
+
<DataType>string</DataType>
187
+
<UserHelpText>Email address that can be used to contact you.</UserHelpText>
188
+
<UserInputType>TextBox</UserInputType>
189
+
</ClaimType>
190
+
```
191
+
192
+
The following example shows how to localize the DisplayName, UserHelpText, and PatternHelpText attributes of the email claim type.
<LocalizedStringElementType="ClaimType"ElementId="email"StringId="UserHelpText">Please enter your email</LocalizedString>
160
197
<LocalizedStringElementType="ClaimType"ElementId="email"StringId="PatternHelpText">Please enter a valid email address</LocalizedString>
161
198
```
162
199
163
-
### UxElement
200
+
### ErrorMessage
164
201
165
-
The UxElement value is used to localize one of the user interface elements as specified in the StringId. The following example shows how to localized the continue and cancel buttonn.
202
+
The ErrorMessage value is used to localize one of the system error messages as specified in the StringId.
166
203
167
-
```XML
168
-
<LocalizedStringElementType="UxElement"StringId="button_continue">Create new account</LocalizedString>
<ItemKey="UserMessageIfClaimsPrincipalAlreadyExists">You are already registered, please press the back button and sign in instead.</Item>
209
+
</Metadata>
210
+
...
211
+
</TechnicalProfile>
170
212
```
171
213
172
-
### ErrorMessage
173
-
The ErrorMessage value is used to localize one of the system error messages as specified in the StringId. The following example shows how to localized the UserMessageIfClaimsPrincipalAlreadyExists UserMessageIfClaimsPrincipalDoesNotExist and error messages.
214
+
The following example shows how to localize the UserMessageIfClaimsPrincipalAlreadyExists error message.
215
+
174
216
175
217
```XML
176
218
<LocalizedStringElementType="ErrorMessage"StringId="UserMessageIfClaimsPrincipalAlreadyExists">The account you are trying to create already exists, please sign-in.</LocalizedString>
177
-
<LocalizedStringElementType="ErrorMessage"StringId="UserMessageIfClaimsPrincipalDoesNotExist">We can't seem to find your account.</LocalizedString>
178
219
```
179
220
180
-
### Predicate
221
+
### GetLocalizedStringsTransformationClaimType
181
222
182
-
The `Predicate` value is used to localize one of the [Predicate](predicates.md) error messages, as specified in the StringId. The `InputValidation` value is used to localize one of the [PredicateValidation](predicates.md) group error messages as specified in the StringId.
223
+
The `GetLocalizedStringsTransformationClaimType` value is used to copy localized strings into claims. For more information, see [GetLocalizedStringsTransformation claims transformation](string-transformations.md#getlocalizedstringstransformation)
183
224
184
-
The following example shows a localized the **UserHelpText** of **Predicate** with Id `IsLengthBetween8And64`. And a localized **UserHelpText** of **PredicateGroup** with Id `CharacterClasses` of **PredicateValidation** with Id `StrongPassword`.
<LocalizedStringElementType="InputValidation"ElementId="StrongPassword"StringId="CharacterClasses">The password must have at least 3 of the following:</LocalizedString>
252
+
The following example shows a localized a predicate help text.
205
253
206
-
<LocalizedStringElementType="Predicate"ElementId="IsLengthBetween8And64"StringId="HelpText">The password must be between 8 and 64 characters.</LocalizedString>
254
+
```xml
255
+
<LocalizedStringElementType="Predicate"ElementId="LengthRange"StringId="HelpText">The password must be between 6 and 64 characters.</LocalizedString>
The `InputValidation` value is used to localize one of the [PredicateValidation](predicates.md) group error messages as specified in the StringId.
263
+
264
+
```xml
265
+
<PredicateValidations>
266
+
<PredicateValidationId="CustomPassword">
267
+
<PredicateGroups>
268
+
<PredicateGroupId="LengthGroup">
269
+
<PredicateReferencesMatchAtLeast="1">
270
+
<PredicateReferenceId="LengthRange" />
271
+
</PredicateReferences>
272
+
</PredicateGroup>
273
+
<PredicateGroupId="CharacterClasses">
274
+
<UserHelpText>The password must have at least 3 of the following:</UserHelpText>
275
+
<PredicateReferencesMatchAtLeast="3">
276
+
<PredicateReferenceId="Lowercase" />
277
+
<PredicateReferenceId="Uppercase" />
278
+
<PredicateReferenceId="Number" />
279
+
<PredicateReferenceId="Symbol" />
280
+
</PredicateReferences>
281
+
</PredicateGroup>
282
+
</PredicateGroups>
283
+
</PredicateValidation>
284
+
</PredicateValidations>
285
+
```
210
286
211
-
The `GetLocalizedStringsTransformationClaimType` value is used to copy localized strings into claims. For more information, see [GetLocalizedStringsTransformation claims transformation](string-transformations.md#getlocalizedstringstransformation)
287
+
The following example shows a localized a predicate validation group help text.
212
288
289
+
```XML
290
+
<LocalizedStringElementType="InputValidation"ElementId="StrongPassword"StringId="CharacterClasses">The password must have at least 3 of the following:</LocalizedString>
291
+
```
292
+
293
+
### UxElement
294
+
295
+
The UxElement value is used to localize one of the user interface elements as specified in the StringId. The following example shows how to localize the continue and cancel buttons.
213
296
297
+
```XML
298
+
<LocalizedStringElementType="UxElement"StringId="button_continue">Create new account</LocalizedString>
0 commit comments