@okta/okta-signin-widget 7.16.0 → 7.16.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -5
- package/dist/css/fonts.css +172 -0
- package/dist/css/okta-sign-in.next.css +1 -240
- package/dist/css/okta-sign-in.next.css.map +1 -1
- package/dist/esm/src/config/config.json.js +1 -1
- package/dist/js/okta-sign-in.classic.js +1 -1
- package/dist/js/okta-sign-in.classic.min.js +1 -1
- package/dist/js/okta-sign-in.js +1 -1
- package/dist/js/okta-sign-in.min.js +1 -1
- package/dist/js/okta-sign-in.next.js +61 -19
- package/dist/js/okta-sign-in.next.js.map +1 -1
- package/dist/js/okta-sign-in.next.no-polyfill.js +60 -18
- package/dist/js/okta-sign-in.next.no-polyfill.js.map +1 -1
- package/dist/js/okta-sign-in.no-polyfill.min.js +1 -1
- package/dist/js/okta-sign-in.oie.js +1 -1
- package/dist/js/okta-sign-in.oie.min.js +1 -1
- package/package.json +10 -5
- package/src/config/config.json +1 -1
- package/src/v3/components/AuthCoin/AuthCoin.tsx +15 -17
- package/src/v3/components/AuthContainer/AuthContainer.tsx +11 -17
- package/src/v3/components/AuthContent/AuthContent.tsx +21 -16
- package/src/v3/components/AuthHeader/AuthHeader.tsx +18 -19
- package/src/v3/components/AuthenticatorButton/AuthenticatorButton.tsx +116 -77
- package/src/v3/components/AuthenticatorButton/AuthenticatorButtonList.tsx +9 -3
- package/src/v3/components/Button/Button.tsx +16 -20
- package/src/v3/components/CaptchaContainer/CaptchaContainer.tsx +1 -1
- package/src/v3/components/Checkbox/Checkbox.tsx +33 -82
- package/src/v3/components/ConsentHeader/ConsentHeader.tsx +23 -23
- package/src/v3/components/Divider/Divider.tsx +2 -2
- package/src/v3/components/Form/Accordion.tsx +15 -36
- package/src/v3/components/Form/ElementContainer.tsx +6 -3
- package/src/v3/components/Form/Form.tsx +2 -4
- package/src/v3/components/Form/Layout.tsx +1 -1
- package/src/v3/components/Form/LayoutContainer.tsx +4 -2
- package/src/v3/components/Heading/Heading.tsx +7 -5
- package/src/v3/components/Icon/CustomAppIcon.tsx +13 -15
- package/src/v3/components/Icon/CustomOTPIcon.tsx +5 -10
- package/src/v3/components/Icon/DuoIcon.tsx +5 -10
- package/src/v3/components/Icon/EmailIcon.tsx +5 -10
- package/src/v3/components/Icon/GoogleOTPIcon.tsx +5 -10
- package/src/v3/components/Icon/IDPIcon.tsx +5 -10
- package/src/v3/components/Icon/OktaVerifyIcon.tsx +0 -7
- package/src/v3/components/Icon/OnPremMFAIcon.tsx +5 -10
- package/src/v3/components/Icon/PasswordIcon.tsx +5 -10
- package/src/v3/components/Icon/PhoneIcon.tsx +5 -10
- package/src/v3/components/Icon/RSAIcon.tsx +6 -11
- package/src/v3/components/Icon/SecurityKeyOrBiometricsIcon.tsx +5 -10
- package/src/v3/components/Icon/SecurityQuestionIcon.tsx +5 -10
- package/src/v3/components/Icon/SmartCardIcon.tsx +5 -10
- package/src/v3/components/Icon/SymantecIcon.tsx +5 -10
- package/src/v3/components/Icon/YubiKeyIcon.tsx +5 -10
- package/src/v3/components/Icon/index.tsx +0 -2
- package/src/v3/components/IdentifierContainer/IdentifierContainer.tsx +31 -47
- package/src/v3/components/Image/Image.tsx +42 -0
- package/src/v3/{src/components/CustomPluginsOdysseyCacheProvider → components/Image}/index.tsx +2 -2
- package/src/v3/components/ImageWithText/ImageWithText.tsx +7 -4
- package/src/v3/components/Images/AppIcon.tsx +16 -46
- package/src/v3/components/Images/DeviceIcon.tsx +16 -32
- package/src/v3/components/Images/LocationIcon.tsx +16 -26
- package/src/v3/components/Images/PhoneIcon.tsx +34 -29
- package/src/v3/components/Images/YubikeyDemoImage.tsx +32 -27
- package/src/v3/components/Images/index.tsx +0 -1
- package/src/v3/components/InfoBox/InfoBox.tsx +12 -12
- package/src/v3/components/InfoSection/InfoSection.tsx +20 -14
- package/src/v3/components/InformationalText/InformationalText.tsx +16 -6
- package/src/v3/components/InputPassword/InputPassword.tsx +31 -164
- package/src/v3/components/InputText/InputText.tsx +27 -103
- package/src/v3/components/LaunchAuthenticatorButton/LaunchAuthenticatorButton.tsx +14 -26
- package/src/v3/components/Link/Link.tsx +8 -20
- package/src/v3/components/List/List.tsx +16 -12
- package/src/v3/components/PIVButton/PIVButton.tsx +10 -8
- package/src/v3/components/PasswordRequirements/Icon.tsx +17 -23
- package/src/v3/components/PasswordRequirements/PasswordMatches.tsx +9 -2
- package/src/v3/components/PasswordRequirements/PasswordRequirementListItem.tsx +6 -5
- package/src/v3/components/PasswordRequirements/PasswordRequirements.tsx +5 -3
- package/src/v3/components/PhoneAuthenticator/PhoneAuthenticator.tsx +53 -137
- package/src/v3/components/QRCode/QRCode.tsx +27 -20
- package/src/v3/components/Radio/Radio.tsx +31 -93
- package/src/v3/components/ReminderPrompt/ReminderPrompt.tsx +9 -12
- package/src/v3/components/Select/Select.tsx +45 -92
- package/src/v3/components/Spinner/Spinner.tsx +6 -8
- package/src/v3/components/StepperButton/StepperButton.tsx +6 -10
- package/src/v3/components/StepperLink/StepperLink.tsx +1 -1
- package/src/v3/components/StepperRadio/StepperRadio.tsx +22 -43
- package/src/v3/components/TextWithActionLink/TextWithActionLink.tsx +1 -1
- package/src/v3/components/Title/Title.tsx +5 -9
- package/src/v3/components/WebAuthNSubmitButton/WebAuthNSubmitButton.tsx +10 -9
- package/src/v3/components/Widget/GlobalStyles.tsx +16 -21
- package/src/v3/components/Widget/index.tsx +51 -36
- package/src/v3/components/Widget/style.scss +295 -0
- package/src/v3/components/WidgetMessageContainer/WidgetMessageContainer.tsx +11 -8
- package/src/v3/components/hocs/withFormValidationState.tsx +2 -5
- package/src/v3/jest.config.js +1 -0
- package/src/v3/jest.setup.js +1 -0
- package/src/v3/package.json +11 -7
- package/src/v3/screenshots/base/UI_demo/UI_demo_RTL_VRT.png +0 -0
- package/src/v3/screenshots/base/UI_demo/UI_demo_VRT.png +0 -0
- package/src/v3/src/components/AuthCoin/AuthCoin.tsx +15 -17
- package/src/v3/src/components/AuthCoin/__snapshots__/AuthCoin.test.tsx.snap +20 -47
- package/src/v3/src/components/AuthContainer/AuthContainer.tsx +11 -17
- package/src/v3/src/components/AuthContent/AuthContent.tsx +21 -16
- package/src/v3/src/components/AuthHeader/AuthHeader.tsx +18 -19
- package/src/v3/src/components/AuthenticatorButton/AuthenticatorButton.tsx +116 -77
- package/src/v3/src/components/AuthenticatorButton/AuthenticatorButtonList.tsx +9 -3
- package/src/v3/src/components/Button/Button.tsx +16 -20
- package/src/v3/src/components/CaptchaContainer/CaptchaContainer.tsx +1 -1
- package/src/v3/src/components/Checkbox/Checkbox.tsx +33 -82
- package/src/v3/src/components/ConsentHeader/ConsentHeader.tsx +23 -23
- package/src/v3/src/components/Divider/Divider.tsx +2 -2
- package/src/v3/src/components/Form/Accordion.tsx +15 -36
- package/src/v3/src/components/Form/ElementContainer.tsx +6 -3
- package/src/v3/src/components/Form/Form.tsx +2 -4
- package/src/v3/src/components/Form/Layout.tsx +1 -1
- package/src/v3/src/components/Form/LayoutContainer.tsx +4 -2
- package/src/v3/src/components/Heading/Heading.tsx +7 -5
- package/src/v3/src/components/Icon/CustomAppIcon.tsx +13 -15
- package/src/v3/src/components/Icon/CustomOTPIcon.tsx +5 -10
- package/src/v3/src/components/Icon/DuoIcon.tsx +5 -10
- package/src/v3/src/components/Icon/EmailIcon.tsx +5 -10
- package/src/v3/src/components/Icon/GoogleOTPIcon.tsx +5 -10
- package/src/v3/src/components/Icon/IDPIcon.tsx +5 -10
- package/src/v3/src/components/Icon/OktaVerifyIcon.tsx +0 -7
- package/src/v3/src/components/Icon/OnPremMFAIcon.tsx +5 -10
- package/src/v3/src/components/Icon/PasswordIcon.tsx +5 -10
- package/src/v3/src/components/Icon/PhoneIcon.tsx +5 -10
- package/src/v3/src/components/Icon/RSAIcon.tsx +6 -11
- package/src/v3/src/components/Icon/SecurityKeyOrBiometricsIcon.tsx +5 -10
- package/src/v3/src/components/Icon/SecurityQuestionIcon.tsx +5 -10
- package/src/v3/src/components/Icon/SmartCardIcon.tsx +5 -10
- package/src/v3/src/components/Icon/SymantecIcon.tsx +5 -10
- package/src/v3/src/components/Icon/YubiKeyIcon.tsx +5 -10
- package/src/v3/src/components/Icon/index.tsx +0 -2
- package/src/v3/src/components/IdentifierContainer/IdentifierContainer.tsx +31 -47
- package/src/v3/src/components/Image/Image.tsx +42 -0
- package/src/v3/{components/CustomPluginsOdysseyCacheProvider → src/components/Image}/index.tsx +2 -2
- package/src/v3/src/components/ImageWithText/ImageWithText.tsx +7 -4
- package/src/v3/src/components/Images/AppIcon.tsx +16 -46
- package/src/v3/src/components/Images/DeviceIcon.tsx +16 -32
- package/src/v3/src/components/Images/LocationIcon.tsx +16 -26
- package/src/v3/src/components/Images/PhoneIcon.tsx +34 -29
- package/src/v3/src/components/Images/YubikeyDemoImage.tsx +32 -27
- package/src/v3/src/components/Images/index.tsx +0 -1
- package/src/v3/src/components/InfoBox/InfoBox.tsx +12 -12
- package/src/v3/src/components/InfoSection/InfoSection.tsx +20 -14
- package/src/v3/src/components/InformationalText/InformationalText.tsx +16 -6
- package/src/v3/src/components/InputPassword/InputPassword.tsx +31 -164
- package/src/v3/src/components/InputText/InputText.tsx +27 -103
- package/src/v3/src/components/LaunchAuthenticatorButton/LaunchAuthenticatorButton.tsx +14 -26
- package/src/v3/src/components/Link/Link.tsx +8 -20
- package/src/v3/src/components/List/List.tsx +16 -12
- package/src/v3/src/components/PIVButton/PIVButton.tsx +10 -8
- package/src/v3/src/components/PasswordRequirements/Icon.tsx +17 -23
- package/src/v3/src/components/PasswordRequirements/PasswordMatches.tsx +9 -2
- package/src/v3/src/components/PasswordRequirements/PasswordRequirementListItem.tsx +6 -5
- package/src/v3/src/components/PasswordRequirements/PasswordRequirements.tsx +5 -3
- package/src/v3/src/components/PhoneAuthenticator/PhoneAuthenticator.tsx +53 -137
- package/src/v3/src/components/QRCode/QRCode.tsx +27 -20
- package/src/v3/src/components/Radio/Radio.tsx +31 -93
- package/src/v3/src/components/ReminderPrompt/ReminderPrompt.tsx +9 -12
- package/src/v3/src/components/ReminderPrompt/__snapshots__/ReminderPrompt.test.tsx.snap +37 -17
- package/src/v3/src/components/Select/Select.tsx +45 -92
- package/src/v3/src/components/Spinner/Spinner.tsx +6 -8
- package/src/v3/src/components/StepperButton/StepperButton.tsx +6 -10
- package/src/v3/src/components/StepperLink/StepperLink.tsx +1 -1
- package/src/v3/src/components/StepperRadio/StepperRadio.tsx +22 -43
- package/src/v3/src/components/TextWithActionLink/TextWithActionLink.tsx +1 -1
- package/src/v3/src/components/Title/Title.tsx +5 -9
- package/src/v3/src/components/WebAuthNSubmitButton/WebAuthNSubmitButton.tsx +10 -9
- package/src/v3/src/components/Widget/GlobalStyles.tsx +16 -21
- package/src/v3/src/components/Widget/index.tsx +51 -36
- package/src/v3/src/components/Widget/style.scss +295 -0
- package/src/v3/src/components/WidgetMessageContainer/WidgetMessageContainer.tsx +11 -8
- package/src/v3/src/components/hocs/withFormValidationState.tsx +2 -5
- package/src/v3/src/transformer/button/__snapshots__/transformIDPButtons.test.ts.snap +0 -2
- package/src/v3/src/transformer/i18n/__snapshots__/transformAuthenticatorButton.test.ts.snap +4 -4
- package/src/v3/src/transformer/i18n/transformAuthenticatorButton.test.ts +3 -3
- package/src/v3/src/transformer/i18n/transformAuthenticatorButton.ts +18 -2
- package/src/v3/src/transformer/layout/development/transformEnumerateComponents.ts +72 -5
- package/src/v3/src/transformer/layout/idp/__snapshots__/transformIdpRedirect.test.ts.snap +4 -4
- package/src/v3/src/transformer/selectAuthenticator/__snapshots__/transformSelectAuthenticatorVerify.test.ts.snap +0 -3
- package/src/v3/src/transformer/selectAuthenticator/__snapshots__/transformSelectOVCustomAppMethodVerify.test.ts.snap +0 -1
- package/src/v3/src/transformer/selectAuthenticator/__snapshots__/utils.test.ts.snap +163 -42
- package/src/v3/src/transformer/selectAuthenticator/transformSelectAuthenticatorEnroll.ts +7 -1
- package/src/v3/src/transformer/selectAuthenticator/transformSelectAuthenticatorVerify.ts +0 -1
- package/src/v3/src/transformer/selectAuthenticator/transformSelectOVCustomAppMethodVerify.ts +0 -1
- package/src/v3/src/transformer/selectAuthenticator/utils.test.ts +117 -39
- package/src/v3/src/transformer/selectAuthenticator/utils.ts +102 -58
- package/src/v3/src/transformer/terminal/transformEmailMagicLinkOTPOnlyElements.ts +1 -3
- package/src/v3/src/transformer/uischema/transform.test.ts +0 -6
- package/src/v3/src/transformer/uischema/transform.ts +0 -2
- package/src/v3/src/{components/FieldLevelMessageContainer/index.tsx → types/image.ts} +10 -3
- package/src/v3/src/types/index.ts +1 -0
- package/src/v3/src/types/schema.ts +2 -1
- package/src/v3/src/types/widget.ts +3 -3
- package/src/v3/src/util/buildFieldLevelErrorMessages.ts +48 -0
- package/src/v3/src/util/formUtils.ts +5 -17
- package/src/v3/src/util/htmlContentParserUtils.tsx +3 -1
- package/src/v3/src/util/index.ts +2 -0
- package/src/v3/src/util/isLtrField.ts +22 -0
- package/src/v3/src/util/languageUtils.ts +14 -0
- package/src/v3/src/util/leonardo.d.ts +571 -0
- package/src/v3/src/util/mergeThemes.test.tsx +20 -7
- package/src/v3/src/util/mergeThemes.ts +32 -1
- package/src/v3/src/util/stylisPlugins.ts +21 -0
- package/src/v3/src/util/theme.test.ts +63 -187
- package/src/v3/src/util/theme.ts +274 -247
- package/src/v3/svgo.config.js +0 -6
- package/src/v3/transformer/i18n/transformAuthenticatorButton.ts +18 -2
- package/src/v3/transformer/layout/development/transformEnumerateComponents.ts +72 -5
- package/src/v3/transformer/selectAuthenticator/transformSelectAuthenticatorEnroll.ts +7 -1
- package/src/v3/transformer/selectAuthenticator/transformSelectAuthenticatorVerify.ts +0 -1
- package/src/v3/transformer/selectAuthenticator/transformSelectOVCustomAppMethodVerify.ts +0 -1
- package/src/v3/transformer/selectAuthenticator/utils.ts +102 -58
- package/src/v3/transformer/terminal/transformEmailMagicLinkOTPOnlyElements.ts +1 -3
- package/src/v3/transformer/uischema/transform.ts +0 -2
- package/src/v3/tsconfig.base.json +3 -0
- package/src/v3/{components/FieldLevelMessageContainer/index.tsx → types/image.ts} +10 -3
- package/src/v3/types/index.ts +1 -0
- package/src/v3/types/schema.ts +2 -1
- package/src/v3/types/widget.ts +3 -3
- package/src/v3/util/buildFieldLevelErrorMessages.ts +48 -0
- package/src/v3/util/formUtils.ts +5 -17
- package/src/v3/util/htmlContentParserUtils.tsx +3 -1
- package/src/v3/util/index.ts +2 -0
- package/src/v3/util/isLtrField.ts +22 -0
- package/src/v3/util/languageUtils.ts +14 -0
- package/src/v3/util/leonardo.d.ts +571 -0
- package/src/v3/util/mergeThemes.ts +32 -1
- package/src/v3/util/stylisPlugins.ts +21 -0
- package/src/v3/util/theme.ts +274 -247
- package/src/v3/components/CustomPluginsOdysseyCacheProvider/CustomPluginsOdysseyCacheProvider.tsx +0 -66
- package/src/v3/components/FieldLevelMessageContainer/FieldLevelMessageContainer.tsx +0 -55
- package/src/v3/components/Icon/CheckCircle.tsx +0 -30
- package/src/v3/components/Icon/RightArrowIcon.tsx +0 -30
- package/src/v3/components/Images/MobileDeviceIcon.tsx +0 -38
- package/src/v3/components/Widget/style.css +0 -181
- package/src/v3/src/components/CustomPluginsOdysseyCacheProvider/CustomPluginsOdysseyCacheProvider.tsx +0 -66
- package/src/v3/src/components/FieldLevelMessageContainer/FieldLevelMessageContainer.tsx +0 -55
- package/src/v3/src/components/Icon/CheckCircle.tsx +0 -30
- package/src/v3/src/components/Icon/RightArrowIcon.tsx +0 -30
- package/src/v3/src/components/Images/MobileDeviceIcon.tsx +0 -38
- package/src/v3/src/components/Widget/style.css +0 -181
- package/src/v3/src/transformer/uischema/setLtrFields.ts +0 -41
- package/src/v3/src/util/designTokens.ts +0 -249
- package/src/v3/transformer/uischema/setLtrFields.ts +0 -41
- package/src/v3/util/designTokens.ts +0 -249
|
@@ -1,181 +0,0 @@
|
|
|
1
|
-
/* TODO: move loginpage styles out of SIW repo OKTA-602545 */
|
|
2
|
-
|
|
3
|
-
/* loginpage utility styles */
|
|
4
|
-
.clearfix {
|
|
5
|
-
display: block;
|
|
6
|
-
}
|
|
7
|
-
.clearfix:after,
|
|
8
|
-
.clearfix:before {
|
|
9
|
-
display: block;
|
|
10
|
-
block-size: 0;
|
|
11
|
-
clear: both;
|
|
12
|
-
content: ".";
|
|
13
|
-
visibility: hidden;
|
|
14
|
-
}
|
|
15
|
-
.hide {
|
|
16
|
-
display: none;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
/* loginpage footer styles */
|
|
20
|
-
.auth .footer {
|
|
21
|
-
background-color: #fff;
|
|
22
|
-
min-inline-size: 300px;
|
|
23
|
-
position: absolute;
|
|
24
|
-
font-size: 12px;
|
|
25
|
-
inset-inline: 0;
|
|
26
|
-
inset-block-end: 0;
|
|
27
|
-
block-size: 34px;
|
|
28
|
-
overflow: hidden;
|
|
29
|
-
}
|
|
30
|
-
.auth .footer .footer-container {
|
|
31
|
-
padding-block: 9px;
|
|
32
|
-
padding-inline: 80px;
|
|
33
|
-
margin-block: 0;
|
|
34
|
-
margin-inline: auto;
|
|
35
|
-
box-sizing: border-box;
|
|
36
|
-
}
|
|
37
|
-
@media only screen and (max-width: 560px) {
|
|
38
|
-
.auth .footer .footer-container {
|
|
39
|
-
inline-size: 400px;
|
|
40
|
-
padding-inline: 20px;
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
@media only screen and (max-width: 400px) {
|
|
44
|
-
.auth .footer .footer-container {
|
|
45
|
-
inline-size: 100%;
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
.auth .footer a {
|
|
49
|
-
color: #6e6e78;
|
|
50
|
-
}
|
|
51
|
-
.auth .footer a:active,
|
|
52
|
-
.auth .footer a:link,
|
|
53
|
-
.auth .footer a:visited {
|
|
54
|
-
text-decoration: none;
|
|
55
|
-
color: #6e6e78;
|
|
56
|
-
}
|
|
57
|
-
.auth .footer a:focus,
|
|
58
|
-
.auth .footer a:hover {
|
|
59
|
-
text-decoration: underline;
|
|
60
|
-
color: #6e6e78;
|
|
61
|
-
}
|
|
62
|
-
.auth .footer .copyright {
|
|
63
|
-
/* stylelint-disable-next-line liberty/use-logical-spec */
|
|
64
|
-
float: left;
|
|
65
|
-
/* TODO: OKTA-586564 replace hardcoded value */
|
|
66
|
-
color: #6e6e78;
|
|
67
|
-
}
|
|
68
|
-
.auth .footer .copyright a {
|
|
69
|
-
/* TODO: OKTA-586564 replace hardcoded value */
|
|
70
|
-
color: #6e6e78;
|
|
71
|
-
}
|
|
72
|
-
.auth .footer .privacy-policy {
|
|
73
|
-
/* stylelint-disable-next-line liberty/use-logical-spec */
|
|
74
|
-
float: right;
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
/* loginpage app banner styles */
|
|
78
|
-
.okta-container .applogin-banner {
|
|
79
|
-
position: relative;
|
|
80
|
-
margin-block-end: 10px;
|
|
81
|
-
min-inline-size: 300px;
|
|
82
|
-
}
|
|
83
|
-
.okta-container .applogin-banner .applogin-background {
|
|
84
|
-
background-color: #fff;
|
|
85
|
-
opacity: 0.9;
|
|
86
|
-
position: absolute;
|
|
87
|
-
inset: 0;
|
|
88
|
-
box-shadow: 0 0 2px 1px hsla(0, 0%, 68.6%, 0.3);
|
|
89
|
-
}
|
|
90
|
-
.okta-container .applogin-banner .applogin-container {
|
|
91
|
-
position: relative;
|
|
92
|
-
inline-size: 400px;
|
|
93
|
-
min-inline-size: 300px;
|
|
94
|
-
margin-block: 0;
|
|
95
|
-
margin-inline: auto;
|
|
96
|
-
padding-block: 20px;
|
|
97
|
-
padding-inline: 0;
|
|
98
|
-
box-sizing: border-box;
|
|
99
|
-
text-align: center;
|
|
100
|
-
}
|
|
101
|
-
.okta-container .applogin-banner .applogin-container p {
|
|
102
|
-
/* TODO: OKTA-586564 replace hardcoded value */
|
|
103
|
-
color: #6e6e78;
|
|
104
|
-
}
|
|
105
|
-
@media only screen and (max-width: 400px) {
|
|
106
|
-
.okta-container .applogin-banner .applogin-container {
|
|
107
|
-
inline-size: 100%;
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
@media only screen and (max-height: 750px) {
|
|
111
|
-
.okta-container .applogin-banner .applogin-container {
|
|
112
|
-
padding-block: 10px;
|
|
113
|
-
padding-inline: 0;
|
|
114
|
-
}
|
|
115
|
-
}
|
|
116
|
-
@media only screen and (max-height: 660px) {
|
|
117
|
-
.okta-container .applogin-banner .applogin-container {
|
|
118
|
-
padding-block: 5px;
|
|
119
|
-
padding-inline: 0;
|
|
120
|
-
}
|
|
121
|
-
.okta-container .applogin-banner .applogin-container p {
|
|
122
|
-
display: none;
|
|
123
|
-
}
|
|
124
|
-
}
|
|
125
|
-
.okta-container .applogin-banner .applogin-container h1 {
|
|
126
|
-
font-size: 24px;
|
|
127
|
-
font-weight: lighter;
|
|
128
|
-
line-height: 26px;
|
|
129
|
-
color: #6e6e78;
|
|
130
|
-
}
|
|
131
|
-
.okta-container .applogin-banner .applogin-app-logo {
|
|
132
|
-
display: inline-block;
|
|
133
|
-
vertical-align: middle;
|
|
134
|
-
margin-inline-start: 5px;
|
|
135
|
-
}
|
|
136
|
-
.okta-container .applogin-banner .applogin-app-logo img {
|
|
137
|
-
max-block-size: 26px;
|
|
138
|
-
}
|
|
139
|
-
|
|
140
|
-
/* loginpage container styles */
|
|
141
|
-
.auth .content {
|
|
142
|
-
min-block-size: 100%;
|
|
143
|
-
min-inline-size: 300px;
|
|
144
|
-
display: inline-block;
|
|
145
|
-
inline-size: 100%;
|
|
146
|
-
}
|
|
147
|
-
.auth .content:after {
|
|
148
|
-
content: "";
|
|
149
|
-
display: block;
|
|
150
|
-
block-size: 30px;
|
|
151
|
-
}
|
|
152
|
-
.login-bg-image {
|
|
153
|
-
background-repeat: no-repeat;
|
|
154
|
-
background-position: 50%;
|
|
155
|
-
background-size: cover;
|
|
156
|
-
position: fixed;
|
|
157
|
-
inset: 0;
|
|
158
|
-
z-index: -5;
|
|
159
|
-
}
|
|
160
|
-
@media only screen and (max-width: 600px) {
|
|
161
|
-
.login-bg-image {
|
|
162
|
-
background-image: none !important;
|
|
163
|
-
background-color: #fff !important;
|
|
164
|
-
-webkit-filter: unset !important;
|
|
165
|
-
filter: unset !important;
|
|
166
|
-
}
|
|
167
|
-
}
|
|
168
|
-
|
|
169
|
-
/*
|
|
170
|
-
* NOTE: widget styles below, login page styles above. Take care when moving CSS
|
|
171
|
-
* from SIW to loginpage (okta-ui) in OKTA-602545
|
|
172
|
-
*
|
|
173
|
-
* TODO: OKTA-654405
|
|
174
|
-
*/
|
|
175
|
-
span.strong {
|
|
176
|
-
font-weight: 600;
|
|
177
|
-
word-break: break-all;
|
|
178
|
-
}
|
|
179
|
-
span.no-translate {
|
|
180
|
-
white-space: nowrap;
|
|
181
|
-
}
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (c) 2022-present, Okta, Inc. and/or its affiliates. All rights reserved.
|
|
3
|
-
* The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the "License.")
|
|
4
|
-
*
|
|
5
|
-
* You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
7
|
-
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
|
8
|
-
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9
|
-
*
|
|
10
|
-
* See the License for the specific language governing permissions and limitations under the License.
|
|
11
|
-
*/
|
|
12
|
-
|
|
13
|
-
import {
|
|
14
|
-
FieldElement,
|
|
15
|
-
TransformStepFn,
|
|
16
|
-
} from '../../types';
|
|
17
|
-
import { traverseLayout } from '../util';
|
|
18
|
-
|
|
19
|
-
export const setLtrFields: TransformStepFn = (formbag) => {
|
|
20
|
-
traverseLayout({
|
|
21
|
-
layout: formbag.uischema,
|
|
22
|
-
predicate: (el) => {
|
|
23
|
-
if (el.type !== 'Field') {
|
|
24
|
-
return false;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
// fields with these names should stay LTR by default
|
|
28
|
-
const ltrOnlyFieldNames = ['credentials.passcode', 'identifier', 'credentials.newPassword', 'confirmPassword'];
|
|
29
|
-
const fieldElement = (el as FieldElement);
|
|
30
|
-
return ltrOnlyFieldNames.includes(fieldElement.options.inputMeta.name);
|
|
31
|
-
},
|
|
32
|
-
callback: (el) => {
|
|
33
|
-
// only set dir here when it has not already been set and overridden
|
|
34
|
-
if (el.type === 'Field' && typeof el.dir === 'undefined') {
|
|
35
|
-
// eslint-disable-next-line no-param-reassign
|
|
36
|
-
el.dir = 'ltr';
|
|
37
|
-
}
|
|
38
|
-
},
|
|
39
|
-
});
|
|
40
|
-
return formbag;
|
|
41
|
-
};
|
|
@@ -1,249 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (c) 2023-present, Okta, Inc. and/or its affiliates. All rights reserved.
|
|
3
|
-
* The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the "License.")
|
|
4
|
-
*
|
|
5
|
-
* You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
7
|
-
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
|
8
|
-
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9
|
-
*
|
|
10
|
-
* See the License for the specific language governing permissions and limitations under the License.
|
|
11
|
-
*/
|
|
12
|
-
|
|
13
|
-
export const DESIGN_TOKENS = {
|
|
14
|
-
// BorderColor
|
|
15
|
-
// BorderColorControl: '#8d8d8d',
|
|
16
|
-
// BorderColorDisplay: '#e1e1e1',
|
|
17
|
-
// BorderColorDisabled: '#e1e1e1',
|
|
18
|
-
// BorderColorDangerLight: '#fe8f7a',
|
|
19
|
-
// BorderColorDangerControl: '#e72500',
|
|
20
|
-
// BorderColorDangerDark: '#951800',
|
|
21
|
-
// BorderColorPrimaryControl: '#546be7',
|
|
22
|
-
// BorderColorPrimaryDark: '#2e40a5',
|
|
23
|
-
|
|
24
|
-
// BorderRadius
|
|
25
|
-
// BorderRadiusTight: '4px',
|
|
26
|
-
BorderRadiusMain: '6px', // theme.mixins.borderRadius
|
|
27
|
-
// BorderRadiusOuter: '12px',
|
|
28
|
-
// BorderRadiusRound: '1.5em',
|
|
29
|
-
|
|
30
|
-
// BorderStyle
|
|
31
|
-
BorderStyleMain: 'solid', // theme.mixins.borderStyle
|
|
32
|
-
|
|
33
|
-
// BorderWidth
|
|
34
|
-
BorderWidthMain: '1px', // theme.mixins.borderWidth
|
|
35
|
-
// BorderWidthHeavy: '1.5px',
|
|
36
|
-
|
|
37
|
-
// FocusOutlineColor
|
|
38
|
-
// FocusOutlineColorPrimary: '#546be7',
|
|
39
|
-
// FocusOutlineColorDanger: '#e72500',
|
|
40
|
-
|
|
41
|
-
// FocusOutlineOffset
|
|
42
|
-
// FocusOutlineOffsetMain: '2px',
|
|
43
|
-
// FocusOutlineOffsetTight: '0',
|
|
44
|
-
|
|
45
|
-
// FocusOutlineStyle
|
|
46
|
-
// FocusOutlineStyle: 'solid',
|
|
47
|
-
|
|
48
|
-
// FocuOutlineWidth
|
|
49
|
-
// FocusOutlineWidthMain: '2px',
|
|
50
|
-
// FocusOutlineWidthTight: '1px',
|
|
51
|
-
|
|
52
|
-
// HueNeutral
|
|
53
|
-
// HueNeutral50: '#f4f4f4',
|
|
54
|
-
// HueNeutral100: '#ededed',
|
|
55
|
-
// HueNeutral200: '#e1e1e1',
|
|
56
|
-
// HueNeutral300: '#cbcbcb',
|
|
57
|
-
// HueNeutral400: '#aeaeae',
|
|
58
|
-
// HueNeutral500: '#8d8d8d',
|
|
59
|
-
// HueNeutral600: '#6e6e6e',
|
|
60
|
-
// HueNeutral700: '#4b4b4b',
|
|
61
|
-
// HueNeutral800: '#383838',
|
|
62
|
-
// HueNeutral900: '#272727',
|
|
63
|
-
// HueNeutralWhite: '#ffffff',
|
|
64
|
-
|
|
65
|
-
// HueBlue
|
|
66
|
-
// HueBlue50: '#f2f3fd',
|
|
67
|
-
// HueBlue100: '#dbe0fa',
|
|
68
|
-
// HueBlue200: '#c1c9f6',
|
|
69
|
-
// HueBlue300: '#9daaf1',
|
|
70
|
-
// HueBlue400: '#7286eb',
|
|
71
|
-
// HueBlue500: '#546be7',
|
|
72
|
-
// HueBlue600: '#4c64e1',
|
|
73
|
-
// HueBlue700: '#2e40a5',
|
|
74
|
-
// HueBlue800: '#22307c',
|
|
75
|
-
// HueBlue900: '#182257',
|
|
76
|
-
|
|
77
|
-
// HueGreen
|
|
78
|
-
// HueGreen50: '#defae7',
|
|
79
|
-
// HueGreen100: '#94f5b3',
|
|
80
|
-
// HueGreen200: '#7be09e',
|
|
81
|
-
// HueGreen300: '#59c282',
|
|
82
|
-
// HueGreen400: '#31a061',
|
|
83
|
-
// HueGreen500: '#16884a',
|
|
84
|
-
// HueGreen600: '#197f48',
|
|
85
|
-
// HueGreen700: '#0e562f',
|
|
86
|
-
// HueGreen800: '#0a4023',
|
|
87
|
-
// HueGreen900: '#072e19',
|
|
88
|
-
|
|
89
|
-
// HueRed
|
|
90
|
-
// HueRed50: '#fff0ee',
|
|
91
|
-
// HueRed100: '#ffd8d1',
|
|
92
|
-
// HueRed200: '#febbae',
|
|
93
|
-
// HueRed300: '#fe8f7a',
|
|
94
|
-
// HueRed400: '#fd4e2d',
|
|
95
|
-
// HueRed500: '#e72500',
|
|
96
|
-
// HueRed600: '#d92300',
|
|
97
|
-
// HueRed700: '#951800',
|
|
98
|
-
// HueRed800: '#711200',
|
|
99
|
-
// HueRed900: '#500d00',
|
|
100
|
-
|
|
101
|
-
// HueYellow
|
|
102
|
-
// HueYellow50: '#fcf6ac',
|
|
103
|
-
// HueYellow100: '#fce101',
|
|
104
|
-
// HueYellow200: '#f9c503',
|
|
105
|
-
// HueYellow300: '#eb9e05',
|
|
106
|
-
// HueYellow400: '#bf8004',
|
|
107
|
-
// HueYellow500: '#a16c03',
|
|
108
|
-
// HueYellow600: '#966603',
|
|
109
|
-
// HueYellow700: '#664402',
|
|
110
|
-
// HueYellow800: '#4c3302',
|
|
111
|
-
// HueYellow900: '#352401',
|
|
112
|
-
|
|
113
|
-
// PalettePrimary
|
|
114
|
-
PalettePrimaryLighter: '#f2f3fd', // theme.palette.primary.lighter
|
|
115
|
-
PalettePrimaryLight: '#9daaf1', // theme.palette.primary.light
|
|
116
|
-
PalettePrimaryMain: '#546be7', // theme.palette.primary.main
|
|
117
|
-
PalettePrimaryDark: '#2e40a5', // theme.palette.primary.dark
|
|
118
|
-
// PalettePrimaryDarker: '#22307c',
|
|
119
|
-
// PalettePrimaryText: '#4c64e1',
|
|
120
|
-
// PalettePrimaryHeading: '#182257',
|
|
121
|
-
// PalettePrimaryHighlight: '#dbe0fa',
|
|
122
|
-
|
|
123
|
-
// PaletteDanger
|
|
124
|
-
PaletteDangerLighter: '#fff0ee', // theme.palette.error.lighter
|
|
125
|
-
PaletteDangerLight: '#fe8f7a', // theme.palette.error.light
|
|
126
|
-
PaletteDangerMain: '#e72500', // theme.palette.error.main
|
|
127
|
-
PaletteDangerDark: '#951800', // theme.palette.error.dark
|
|
128
|
-
// PaletteDangerDarker: '#711200',
|
|
129
|
-
// PaletteDangerText: '#d92300',
|
|
130
|
-
// PaletteDangerHeading: '#500d00',
|
|
131
|
-
// PaletteDangerHighlight: '#ffd8d1',
|
|
132
|
-
|
|
133
|
-
// PaletteWarning
|
|
134
|
-
PaletteWarningLighter: '#fcf6ac', // theme.palette.warning.lighter
|
|
135
|
-
PaletteWarningLight: '#eb9e05', // theme.palette.warning.light
|
|
136
|
-
PaletteWarningMain: '#a16c03', // theme.palette.warning.main
|
|
137
|
-
PaletteWarningDark: '#664402', // theme.palette.warning.dark
|
|
138
|
-
// PaletteWarningDarker: '#4c3302',
|
|
139
|
-
// PaletteWarningText: '#966603',
|
|
140
|
-
// PaletteWarningHeading: '#352401',
|
|
141
|
-
// PaletteWarningHighlight: '#fce101',
|
|
142
|
-
|
|
143
|
-
// PaletteSuccess
|
|
144
|
-
PaletteSuccessLighter: '#defae7', // theme.palette.success.lighter
|
|
145
|
-
PaletteSuccessLight: '#59c282', // theme.palette.success.light
|
|
146
|
-
PaletteSuccessMain: '#16884a', // theme.palette.success.main
|
|
147
|
-
PaletteSuccessDark: '#0e562f', // theme.palette.success.dark
|
|
148
|
-
// PaletteSuccessDarker: '#0a4023',
|
|
149
|
-
// PaletteSuccessText: '#197f48',
|
|
150
|
-
// PaletteSuccessHeading: '#072e19',
|
|
151
|
-
// PaletteSuccessHighlight: '#94f5b3',
|
|
152
|
-
|
|
153
|
-
// PaletteNeutral
|
|
154
|
-
PaletteNeutralMain: '#6e6e6e',
|
|
155
|
-
PaletteNeutralDark: '#272727',
|
|
156
|
-
|
|
157
|
-
// PaletteAlpha
|
|
158
|
-
// PaletteAlphaOpaque: 'FF',
|
|
159
|
-
// PaletteAlphaSemi: 'BF',
|
|
160
|
-
|
|
161
|
-
// ShadowScale
|
|
162
|
-
ShadowScale0: '0px 1px 4px rgba(29, 29, 33, 0.08), 0px 4px 6px rgba(29, 29, 33, 0.01), 0px 5px 15px rgba(29, 29, 33, 0.05)', // theme.shadows[1]
|
|
163
|
-
ShadowScale1: '0px 1px 4px rgba(29, 29, 33, 0.08), 0px 4px 10px rgba(29, 29, 33, 0.08), 0px 8px 30px rgba(29, 29, 33, 0.1)', // theme.shadows[2]
|
|
164
|
-
|
|
165
|
-
// Spacing
|
|
166
|
-
Spacing0: '0', // theme.spacing(0)
|
|
167
|
-
Spacing1: '0.28571429rem', // theme.spacing(1)
|
|
168
|
-
Spacing2: '0.57142857rem', // theme.spacing(2)
|
|
169
|
-
Spacing3: '0.85714286rem', // theme.spacing(3)
|
|
170
|
-
Spacing4: '1.14285714rem', // theme.spacing(4)
|
|
171
|
-
Spacing5: '1.71428571rem', // theme.spacing(5)
|
|
172
|
-
Spacing6: '2.28571429rem', // theme.spacing(6)
|
|
173
|
-
Spacing7: '2.85714286rem', // theme.spacing(7)
|
|
174
|
-
Spacing8: '3.42857143rem', // theme.spacing(8)
|
|
175
|
-
Spacing9: '4rem', // theme.spacing(9)
|
|
176
|
-
|
|
177
|
-
// Transition
|
|
178
|
-
// TransitionDurationMain: '100ms',
|
|
179
|
-
// TransitionTimingMain: 'linear',
|
|
180
|
-
|
|
181
|
-
// TypographyColor
|
|
182
|
-
TypographyColorBody: '#272727', // theme.palette.text.primary
|
|
183
|
-
TypographyColorHeading: '#272727', // theme.typography.h1.color
|
|
184
|
-
// TypographyColorInverse: '#ffffff',
|
|
185
|
-
// TypographyColorSupport: '#4b4b4b',
|
|
186
|
-
TypographyColorSubordinate: '#6e6e6e', // theme.typography.caption.color
|
|
187
|
-
TypographyColorDisabled: '#aeaeae', // theme.palette.text.disabled
|
|
188
|
-
// TypographyColorAction: '#4c64e1',
|
|
189
|
-
// TypographyColorDanger: '#d92300',
|
|
190
|
-
// TypographyColorSuccess: '#197f48',
|
|
191
|
-
// TypographyColorWarning: '#966603',
|
|
192
|
-
|
|
193
|
-
// TypographyFamily
|
|
194
|
-
TypographyFamilyBody: "'Inter', '-apple-system', 'BlinkMacSystemFont', 'Segoe UI', 'Roboto', 'Oxygen-Sans', 'Ubuntu', 'Cantarell', 'Helvetica Neue', sans-serif", // theme.typography.fontFamily
|
|
195
|
-
TypographyFamilyHeading: "'Aeonik', 'Inter', '-apple-system', 'BlinkMacSystemFont', 'Segoe UI', 'Roboto', 'Oxygen-Sans', 'Ubuntu', 'Cantarell', 'Helvetica Neue', sans-serif", // theme.typography.h1.fontFamily
|
|
196
|
-
TypographyFamilyButton: "'Aeonik', 'Inter', '-apple-system', 'BlinkMacSystemFont', 'Segoe UI', 'Roboto', 'Oxygen-Sans', 'Ubuntu', 'Cantarell', 'Helvetica Neue', sans-serif", // theme.typography.button.fontFamily
|
|
197
|
-
TypographyFamilyMono: "'Roboto Mono', 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, Courier, monospace", // theme.typography.kbd.fontFamily
|
|
198
|
-
|
|
199
|
-
// TypographyScale
|
|
200
|
-
// TypographyScale0: '0.857rem',
|
|
201
|
-
// TypographyScale1: '1rem',
|
|
202
|
-
// TypographyScale2: '1.143rem',
|
|
203
|
-
// TypographyScale3: '1.286rem',
|
|
204
|
-
// TypographyScale4: '1.429rem',
|
|
205
|
-
// TypographyScale5: '1.571rem',
|
|
206
|
-
// TypographyScale6: '1.786rem',
|
|
207
|
-
// TypographyScale7: '2.000rem',
|
|
208
|
-
// TypographyScale8: '2.286rem',
|
|
209
|
-
// TypographyScale9: '2.571rem',
|
|
210
|
-
// TypographyScale10: '2.857rem',
|
|
211
|
-
// TypographyScale11: '3.214rem',
|
|
212
|
-
// TypographyScale12: '3.643rem',
|
|
213
|
-
|
|
214
|
-
// TypographySize
|
|
215
|
-
TypographySizeBase: '87.5%', // theme.typography.body1.fontSize
|
|
216
|
-
TypographySizeSubordinate: '0.857rem', // theme.typography.caption.fontSize = TypographyScale0
|
|
217
|
-
TypographySizeBody: '1rem', // theme.typography.body1.fontSize = TypographyScale1
|
|
218
|
-
TypographySizeHeading6: '1.143rem', // theme.typography.h6.fontSize = TypographyScale2
|
|
219
|
-
TypographySizeHeading5: '1.286rem', // theme.typography.h5.fontSize = TypographyScale3
|
|
220
|
-
TypographySizeHeading4: '1.571rem', // theme.typography.h4.fontSize = TypographyScale5
|
|
221
|
-
TypographySizeHeading3: '2.000rem', // theme.typography.h3.fontSize = TypographyScale7
|
|
222
|
-
TypographySizeHeading2: '2.286rem', // theme.typography.h2.fontSize = TypographyScale8
|
|
223
|
-
TypographySizeHeading1: '2.571rem', // theme.typography.h1.fontSize = TypographyScale9
|
|
224
|
-
|
|
225
|
-
// TypographyStyle
|
|
226
|
-
TypographyStyleNormal: 'normal', // theme.typography.body1.fontStyle
|
|
227
|
-
|
|
228
|
-
// TypographyWeight
|
|
229
|
-
TypographyWeightBody: '400', // theme.typography.fontWeightMedium
|
|
230
|
-
TypographyWeightBodyBold: '600', // theme.typography.fontWeightBold
|
|
231
|
-
TypographyWeightHeading: '500', // theme.typography.h1.fontWeight
|
|
232
|
-
// TypographyWeightHeadingBold: '700',
|
|
233
|
-
|
|
234
|
-
// TypographyLineHeight
|
|
235
|
-
TypographyLineHeightBody: 1.5, // theme.typography.body1.lineHeight
|
|
236
|
-
// TypographyLineHeightUi: 1.2,
|
|
237
|
-
TypographyLineHeightOverline: 1.3, // theme.typography.overline.lineHeight
|
|
238
|
-
TypographyLineHeightHeading6: 1.3, // theme.typography.h6.lineHeight
|
|
239
|
-
TypographyLineHeightHeading5: 1.3, // theme.typography.h5.lineHeight
|
|
240
|
-
TypographyLineHeightHeading4: 1.25, // theme.typography.h4.lineHeight
|
|
241
|
-
TypographyLineHeightHeading3: 1.25, // theme.typography.h3.lineHeight
|
|
242
|
-
TypographyLineHeightHeading2: 1.2, // theme.typography.h2.lineHeight
|
|
243
|
-
TypographyLineHeightHeading1: 1.2, // theme.typography.h1.lineHeight
|
|
244
|
-
|
|
245
|
-
// TypographyLineLength
|
|
246
|
-
// TypographyLineLengthMax: '55ch',
|
|
247
|
-
};
|
|
248
|
-
|
|
249
|
-
export type DesignTokensType = typeof DESIGN_TOKENS;
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (c) 2022-present, Okta, Inc. and/or its affiliates. All rights reserved.
|
|
3
|
-
* The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the "License.")
|
|
4
|
-
*
|
|
5
|
-
* You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
7
|
-
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
|
8
|
-
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9
|
-
*
|
|
10
|
-
* See the License for the specific language governing permissions and limitations under the License.
|
|
11
|
-
*/
|
|
12
|
-
|
|
13
|
-
import {
|
|
14
|
-
FieldElement,
|
|
15
|
-
TransformStepFn,
|
|
16
|
-
} from '../../types';
|
|
17
|
-
import { traverseLayout } from '../util';
|
|
18
|
-
|
|
19
|
-
export const setLtrFields: TransformStepFn = (formbag) => {
|
|
20
|
-
traverseLayout({
|
|
21
|
-
layout: formbag.uischema,
|
|
22
|
-
predicate: (el) => {
|
|
23
|
-
if (el.type !== 'Field') {
|
|
24
|
-
return false;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
// fields with these names should stay LTR by default
|
|
28
|
-
const ltrOnlyFieldNames = ['credentials.passcode', 'identifier', 'credentials.newPassword', 'confirmPassword'];
|
|
29
|
-
const fieldElement = (el as FieldElement);
|
|
30
|
-
return ltrOnlyFieldNames.includes(fieldElement.options.inputMeta.name);
|
|
31
|
-
},
|
|
32
|
-
callback: (el) => {
|
|
33
|
-
// only set dir here when it has not already been set and overridden
|
|
34
|
-
if (el.type === 'Field' && typeof el.dir === 'undefined') {
|
|
35
|
-
// eslint-disable-next-line no-param-reassign
|
|
36
|
-
el.dir = 'ltr';
|
|
37
|
-
}
|
|
38
|
-
},
|
|
39
|
-
});
|
|
40
|
-
return formbag;
|
|
41
|
-
};
|