@forgerock/login-widget 1.0.0-beta.8 → 1.0.0
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/CHANGELOG.md +168 -3
- package/index.cjs +1367 -785
- package/index.cjs.map +1 -1
- package/index.js +1367 -785
- package/index.js.map +1 -1
- package/package.json +2 -9
- package/{index.d.ts → types.d.ts} +164 -234
- package/widget.css +28 -11
package/index.js
CHANGED
|
@@ -702,6 +702,10 @@ function closeComponent(args, shouldCloseDialog) {
|
|
|
702
702
|
};
|
|
703
703
|
});
|
|
704
704
|
}
|
|
705
|
+
/**
|
|
706
|
+
* @function componentApi - this is a widget external API
|
|
707
|
+
* @returns {object} - the public component API
|
|
708
|
+
*/
|
|
705
709
|
const componentApi = () => {
|
|
706
710
|
const { update } = componentStore;
|
|
707
711
|
// Create derived store to minimize what's exposed to the dev
|
|
@@ -715,9 +719,19 @@ const componentApi = () => {
|
|
|
715
719
|
});
|
|
716
720
|
});
|
|
717
721
|
return {
|
|
722
|
+
/**
|
|
723
|
+
* Close a modal
|
|
724
|
+
* @param {object} args - object containing the reason for closing component
|
|
725
|
+
* @returns {void}
|
|
726
|
+
*/
|
|
718
727
|
close: (args) => {
|
|
719
728
|
closeComponent(args, true);
|
|
720
729
|
},
|
|
730
|
+
/**
|
|
731
|
+
* Open a modal
|
|
732
|
+
* @param: void
|
|
733
|
+
* @returns: void
|
|
734
|
+
*/
|
|
721
735
|
open: () => {
|
|
722
736
|
update((state) => {
|
|
723
737
|
if (state.type === 'inline') {
|
|
@@ -739,6 +753,10 @@ const componentApi = () => {
|
|
|
739
753
|
};
|
|
740
754
|
});
|
|
741
755
|
},
|
|
756
|
+
/**
|
|
757
|
+
* Subscribe to modal events
|
|
758
|
+
* returns the latest value from the event
|
|
759
|
+
*/
|
|
742
760
|
subscribe,
|
|
743
761
|
};
|
|
744
762
|
};
|
|
@@ -10873,6 +10891,11 @@ var HttpClient = /** @class */ (function (_super) {
|
|
|
10873
10891
|
}(event_1.default));
|
|
10874
10892
|
var _default$2 = httpClient.default = HttpClient;
|
|
10875
10893
|
|
|
10894
|
+
/**
|
|
10895
|
+
* @function logErrorAndThrow - Logs an error message and throws an error.
|
|
10896
|
+
* @param {string} type - The type of error. This will be used to determine what error message to log.
|
|
10897
|
+
* @throws {Error} - An error with a message that depends on the value of `type`.
|
|
10898
|
+
*/
|
|
10876
10899
|
function logErrorAndThrow(type) {
|
|
10877
10900
|
if (type === 'missingStores') {
|
|
10878
10901
|
const errorMessage = 'Error: missing configuration.';
|
|
@@ -14921,12 +14944,18 @@ const configSchema = z
|
|
|
14921
14944
|
})
|
|
14922
14945
|
.strict();
|
|
14923
14946
|
configSchema.partial();
|
|
14947
|
+
/**
|
|
14948
|
+
* @function - Sets the configuration for the SDK
|
|
14949
|
+
* @param {object} config - The configuration object
|
|
14950
|
+
* @returns {void}
|
|
14951
|
+
*/
|
|
14924
14952
|
function configure (config) {
|
|
14925
14953
|
configSchema.parse(config);
|
|
14926
14954
|
Config.set(config);
|
|
14927
14955
|
}
|
|
14928
14956
|
|
|
14929
|
-
const journeyConfigItemSchema = z
|
|
14957
|
+
const journeyConfigItemSchema = z
|
|
14958
|
+
.object({
|
|
14930
14959
|
journey: z.string().optional(),
|
|
14931
14960
|
match: z
|
|
14932
14961
|
.string()
|
|
@@ -14934,7 +14963,8 @@ const journeyConfigItemSchema = z.object({
|
|
|
14934
14963
|
message: 'HREF string must start with `?journey` or `#/service`',
|
|
14935
14964
|
})
|
|
14936
14965
|
.array(),
|
|
14937
|
-
})
|
|
14966
|
+
})
|
|
14967
|
+
.optional();
|
|
14938
14968
|
const journeyConfigSchema = z.object({
|
|
14939
14969
|
forgotPassword: journeyConfigItemSchema,
|
|
14940
14970
|
forgotUsername: journeyConfigItemSchema,
|
|
@@ -14951,8 +14981,8 @@ const defaultJourneys = {
|
|
|
14951
14981
|
match: ['#/service/ForgottenUsername', '?journey=ForgottenUsername'],
|
|
14952
14982
|
},
|
|
14953
14983
|
login: {
|
|
14954
|
-
journey:
|
|
14955
|
-
match: ['#/service/Login', '?journey'],
|
|
14984
|
+
journey: 'Login',
|
|
14985
|
+
match: ['#/service/Login', '?journey', '?journey=Login'],
|
|
14956
14986
|
},
|
|
14957
14987
|
register: {
|
|
14958
14988
|
journey: 'Registration',
|
|
@@ -14966,12 +14996,24 @@ const fallbackJourneyConfig = Object.keys(defaultJourneys).map((key) => ({
|
|
|
14966
14996
|
key,
|
|
14967
14997
|
}));
|
|
14968
14998
|
const configuredJourneysStore = writable(fallbackJourneyConfig);
|
|
14999
|
+
/**
|
|
15000
|
+
* @function initialize - Initialize the configured journeys store
|
|
15001
|
+
* @param {object} customJourneys - An object of custom journeys to merge with the default
|
|
15002
|
+
* @returns {object} - The configured journeys store
|
|
15003
|
+
* @example initialize({ login: { journey: 'Login', match: ['?journey=Login'] } })
|
|
15004
|
+
*/
|
|
14969
15005
|
function initialize$6(customJourneys) {
|
|
14970
15006
|
if (customJourneys) {
|
|
14971
15007
|
// Provide developer feedback if customized
|
|
14972
15008
|
journeyConfigSchema.parse(customJourneys);
|
|
14973
|
-
|
|
14974
|
-
|
|
15009
|
+
// Merge the two journey configs, dev's overwriting the default
|
|
15010
|
+
const mergedJourneyObjects = {
|
|
15011
|
+
...defaultJourneys,
|
|
15012
|
+
...customJourneys,
|
|
15013
|
+
};
|
|
15014
|
+
const customJourneyKeys = Object.keys(mergedJourneyObjects);
|
|
15015
|
+
configuredJourneysStore.set(customJourneyKeys.map((key) => ({
|
|
15016
|
+
...mergedJourneyObjects[key],
|
|
14975
15017
|
key,
|
|
14976
15018
|
})));
|
|
14977
15019
|
}
|
|
@@ -16718,6 +16760,8 @@ var backToDefault = "Back to Sign In";
|
|
|
16718
16760
|
var backToLogin = "Back to Sign In";
|
|
16719
16761
|
var dontHaveAnAccount = "No account? <a href='?journey=Registration'>Register here!</a>";
|
|
16720
16762
|
var closeModal = "Close";
|
|
16763
|
+
var charactersCannotRepeatMoreThan = "Character cannot repeat more than {max} times";
|
|
16764
|
+
var charactersCannotRepeatMoreThanCaseInsensitive = "Character cannot repeat more than {max} times (case insensitive)";
|
|
16721
16765
|
var chooseDifferentUsername = "Please choose a different username.";
|
|
16722
16766
|
var confirmPassword = "Confirm password";
|
|
16723
16767
|
var constraintViolationForPassword = "Password does not meet the requirements.";
|
|
@@ -16750,6 +16794,9 @@ var nextButton = "Next";
|
|
|
16750
16794
|
var notToExceedMaximumCharacterLength = "No more than {max} characters";
|
|
16751
16795
|
var noLessThanMinimumCharacterLength = "At least {min} character(s)";
|
|
16752
16796
|
var passwordCallback = "Password";
|
|
16797
|
+
var passwordCannotContainCommonPasswords = "Password cannot contain common passwords";
|
|
16798
|
+
var passwordCannotContainCommonPasswordsOrBeReversible = "Password cannot contain common passwords or reversible text";
|
|
16799
|
+
var passwordCannotContainCommonPasswordsOrBeReversibleStringsLessThan = "Password cannot contain common passwords or reversible text less than {min} characters";
|
|
16753
16800
|
var passwordRequirements = "Password requirements:";
|
|
16754
16801
|
var pleaseCheckValue = "Please check this value";
|
|
16755
16802
|
var pleaseConfirm = "Please confirm";
|
|
@@ -16763,7 +16810,11 @@ var registerSuccess = "Registration successful!";
|
|
|
16763
16810
|
var requiredField = "Value is required";
|
|
16764
16811
|
var securityAnswer = "Security answer";
|
|
16765
16812
|
var securityQuestions = "Security question(s)";
|
|
16766
|
-
var securityQuestionsPrompt = "Provide
|
|
16813
|
+
var securityQuestionsPrompt = "Provide security question(s) and answer(s):";
|
|
16814
|
+
var shouldContainANumber = "Should contain a number";
|
|
16815
|
+
var shouldContainAnUppercase = "Should contain an uppercase letter";
|
|
16816
|
+
var shouldContainALowercase = "Should contain a lowercase letter";
|
|
16817
|
+
var shouldContainASymbol = "Should contain a symbol";
|
|
16767
16818
|
var showPassword = "Show password";
|
|
16768
16819
|
var sn = "Last name";
|
|
16769
16820
|
var submitButton = "Submit";
|
|
@@ -16774,6 +16825,7 @@ var tryAgain = "Please try again";
|
|
|
16774
16825
|
var twoFactorAuthentication = "Two factor authentication";
|
|
16775
16826
|
var useValidEmail = "Please use a valid email address.";
|
|
16776
16827
|
var unrecoverableError = "There was an error in the form submission.";
|
|
16828
|
+
var unknownLoginError = "Unknown login failure has occurred.";
|
|
16777
16829
|
var unknownNetworkError = "Unknown network request failure has occurred.";
|
|
16778
16830
|
var userName = "Username";
|
|
16779
16831
|
var usernameRequirements = "Username requirements:";
|
|
@@ -16787,6 +16839,8 @@ var fallback = {
|
|
|
16787
16839
|
backToLogin: backToLogin,
|
|
16788
16840
|
dontHaveAnAccount: dontHaveAnAccount,
|
|
16789
16841
|
closeModal: closeModal,
|
|
16842
|
+
charactersCannotRepeatMoreThan: charactersCannotRepeatMoreThan,
|
|
16843
|
+
charactersCannotRepeatMoreThanCaseInsensitive: charactersCannotRepeatMoreThanCaseInsensitive,
|
|
16790
16844
|
chooseDifferentUsername: chooseDifferentUsername,
|
|
16791
16845
|
confirmPassword: confirmPassword,
|
|
16792
16846
|
constraintViolationForPassword: constraintViolationForPassword,
|
|
@@ -16819,6 +16873,9 @@ var fallback = {
|
|
|
16819
16873
|
notToExceedMaximumCharacterLength: notToExceedMaximumCharacterLength,
|
|
16820
16874
|
noLessThanMinimumCharacterLength: noLessThanMinimumCharacterLength,
|
|
16821
16875
|
passwordCallback: passwordCallback,
|
|
16876
|
+
passwordCannotContainCommonPasswords: passwordCannotContainCommonPasswords,
|
|
16877
|
+
passwordCannotContainCommonPasswordsOrBeReversible: passwordCannotContainCommonPasswordsOrBeReversible,
|
|
16878
|
+
passwordCannotContainCommonPasswordsOrBeReversibleStringsLessThan: passwordCannotContainCommonPasswordsOrBeReversibleStringsLessThan,
|
|
16822
16879
|
passwordRequirements: passwordRequirements,
|
|
16823
16880
|
pleaseCheckValue: pleaseCheckValue,
|
|
16824
16881
|
pleaseConfirm: pleaseConfirm,
|
|
@@ -16833,6 +16890,10 @@ var fallback = {
|
|
|
16833
16890
|
securityAnswer: securityAnswer,
|
|
16834
16891
|
securityQuestions: securityQuestions,
|
|
16835
16892
|
securityQuestionsPrompt: securityQuestionsPrompt,
|
|
16893
|
+
shouldContainANumber: shouldContainANumber,
|
|
16894
|
+
shouldContainAnUppercase: shouldContainAnUppercase,
|
|
16895
|
+
shouldContainALowercase: shouldContainALowercase,
|
|
16896
|
+
shouldContainASymbol: shouldContainASymbol,
|
|
16836
16897
|
showPassword: showPassword,
|
|
16837
16898
|
sn: sn,
|
|
16838
16899
|
submitButton: submitButton,
|
|
@@ -16843,6 +16904,7 @@ var fallback = {
|
|
|
16843
16904
|
twoFactorAuthentication: twoFactorAuthentication,
|
|
16844
16905
|
useValidEmail: useValidEmail,
|
|
16845
16906
|
unrecoverableError: unrecoverableError,
|
|
16907
|
+
unknownLoginError: unknownLoginError,
|
|
16846
16908
|
unknownNetworkError: unknownNetworkError,
|
|
16847
16909
|
userName: userName,
|
|
16848
16910
|
usernameRequirements: usernameRequirements,
|
|
@@ -16859,6 +16921,8 @@ const stringsSchema = z
|
|
|
16859
16921
|
backToLogin: z.string(),
|
|
16860
16922
|
dontHaveAnAccount: z.string(),
|
|
16861
16923
|
closeModal: z.string(),
|
|
16924
|
+
charactersCannotRepeatMoreThan: z.string(),
|
|
16925
|
+
charactersCannotRepeatMoreThanCaseInsensitive: z.string(),
|
|
16862
16926
|
chooseDifferentUsername: z.string(),
|
|
16863
16927
|
confirmPassword: z.string(),
|
|
16864
16928
|
constraintViolationForPassword: z.string(),
|
|
@@ -16891,6 +16955,9 @@ const stringsSchema = z
|
|
|
16891
16955
|
notToExceedMaximumCharacterLength: z.string(),
|
|
16892
16956
|
noLessThanMinimumCharacterLength: z.string(),
|
|
16893
16957
|
passwordCallback: z.string(),
|
|
16958
|
+
passwordCannotContainCommonPasswords: z.string(),
|
|
16959
|
+
passwordCannotContainCommonPasswordsOrBeReversible: z.string(),
|
|
16960
|
+
passwordCannotContainCommonPasswordsOrBeReversibleStringsLessThan: z.string(),
|
|
16894
16961
|
passwordRequirements: z.string(),
|
|
16895
16962
|
pleaseCheckValue: z.string(),
|
|
16896
16963
|
pleaseConfirm: z.string(),
|
|
@@ -16905,6 +16972,10 @@ const stringsSchema = z
|
|
|
16905
16972
|
securityAnswer: z.string(),
|
|
16906
16973
|
securityQuestions: z.string(),
|
|
16907
16974
|
securityQuestionsPrompt: z.string(),
|
|
16975
|
+
shouldContainANumber: z.string(),
|
|
16976
|
+
shouldContainAnUppercase: z.string(),
|
|
16977
|
+
shouldContainALowercase: z.string(),
|
|
16978
|
+
shouldContainASymbol: z.string(),
|
|
16908
16979
|
showPassword: z.string(),
|
|
16909
16980
|
sn: z.string(),
|
|
16910
16981
|
submitButton: z.string(),
|
|
@@ -16915,6 +16986,7 @@ const stringsSchema = z
|
|
|
16915
16986
|
twoFactorAuthentication: z.string(),
|
|
16916
16987
|
useValidEmail: z.string(),
|
|
16917
16988
|
unrecoverableError: z.string(),
|
|
16989
|
+
unknownLoginError: z.string(),
|
|
16918
16990
|
unknownNetworkError: z.string(),
|
|
16919
16991
|
userName: z.string(),
|
|
16920
16992
|
usernameRequirements: z.string(),
|
|
@@ -16928,6 +17000,12 @@ stringsSchema.partial();
|
|
|
16928
17000
|
// Ensure fallback follows schema
|
|
16929
17001
|
stringsSchema.parse(fallback);
|
|
16930
17002
|
const stringsStore = writable(null);
|
|
17003
|
+
/**
|
|
17004
|
+
* @function initialize - Initialize the locale store
|
|
17005
|
+
* @param {object} userLocale - An object of custom locale strings to merge with the default
|
|
17006
|
+
* @returns {object} - The locale store
|
|
17007
|
+
* @example initialize({ loginHeader: 'Welcome to the login page' });
|
|
17008
|
+
*/
|
|
16931
17009
|
function initialize$5(userLocale) {
|
|
16932
17010
|
if (userLocale) {
|
|
16933
17011
|
/**
|
|
@@ -16947,6 +17025,14 @@ function initialize$5(userLocale) {
|
|
|
16947
17025
|
* Demo: https://regex101.com/r/Mw9vTB/1
|
|
16948
17026
|
*/
|
|
16949
17027
|
const valueSchema = z.record(z.string().regex(/^[^<>]*$/)).optional();
|
|
17028
|
+
/**
|
|
17029
|
+
* @function interpolate - Get a translation string
|
|
17030
|
+
* Interpolate a string that contains variables
|
|
17031
|
+
*
|
|
17032
|
+
* @param {string} key - The key to lookup in the translation strings
|
|
17033
|
+
* @param {object} values - An object of values to interpolate into the string
|
|
17034
|
+
* @param {string} externalText - A string to use if no translation is found
|
|
17035
|
+
*/
|
|
16950
17036
|
function interpolate(key, values, externalText) {
|
|
16951
17037
|
// Let's throw some errors if we're trying to use keys/locales that don't exist.
|
|
16952
17038
|
// We could improve this by using Typescript and/or fallback values.
|
|
@@ -17018,6 +17104,31 @@ function interpolate(key, values, externalText) {
|
|
|
17018
17104
|
});
|
|
17019
17105
|
return messageClean;
|
|
17020
17106
|
}
|
|
17107
|
+
/**
|
|
17108
|
+
* @function textToKey - Takes a human readable string and returns a key from it.
|
|
17109
|
+
* This key is used to look up the string in the translation files.
|
|
17110
|
+
*
|
|
17111
|
+
* If the item is a number, it will be converted to a string and then
|
|
17112
|
+
* processed as if it were a string.
|
|
17113
|
+
*
|
|
17114
|
+
* If the item is a string that contains word characters (`\w`) mixed with
|
|
17115
|
+
* non-word characters (`\W`), the non-word characters will be removed and
|
|
17116
|
+
* the resulting string will be converted to camelCase.
|
|
17117
|
+
*
|
|
17118
|
+
* @param {string} text - The text that will be converted to a key.
|
|
17119
|
+
* @returns {string} A key that is unique to the given text.
|
|
17120
|
+
*
|
|
17121
|
+
* Examples:
|
|
17122
|
+
* textToKey('hello world') => 'helloWorld'
|
|
17123
|
+
* textToKey('HELLO WORLD') => 'helloWorld'
|
|
17124
|
+
* textToKey('HELLO WORLD!!!') => 'helloWorld'
|
|
17125
|
+
* textToKey('HELLO WORLD!!!') => 'helloWorld'
|
|
17126
|
+
* textToKey('helloWorld') => 'helloWorld'
|
|
17127
|
+
* textToKey('helloWorld123') => 'helloWorld123'
|
|
17128
|
+
* textToKey('hello_world') => 'helloWorld'
|
|
17129
|
+
* textToKey('hello-world') => 'helloWorld'
|
|
17130
|
+
* textToKey('hello.world') => 'helloWorld'
|
|
17131
|
+
*/
|
|
17021
17132
|
function textToKey(text) {
|
|
17022
17133
|
if (typeof text !== 'string' && typeof text !== 'number') {
|
|
17023
17134
|
throw new Error('Parameter for textToKey function needs to be of type string or number');
|
|
@@ -17159,7 +17270,9 @@ const userInputCallbacks = [
|
|
|
17159
17270
|
CallbackType$1.ValidatedCreatePasswordCallback,
|
|
17160
17271
|
CallbackType$1.ValidatedCreateUsernameCallback,
|
|
17161
17272
|
];
|
|
17162
|
-
|
|
17273
|
+
/**
|
|
17274
|
+
* @function forceUserInputOptionalityCallbacks - Determines if a callback should be forced to be optional
|
|
17275
|
+
*/
|
|
17163
17276
|
const forceUserInputOptionalityCallbacks = {
|
|
17164
17277
|
SelectIdPCallback: (callback) => {
|
|
17165
17278
|
const selectIdpCb = callback;
|
|
@@ -17168,6 +17281,11 @@ const forceUserInputOptionalityCallbacks = {
|
|
|
17168
17281
|
.find((provider) => provider.provider === 'localAuthentication');
|
|
17169
17282
|
},
|
|
17170
17283
|
};
|
|
17284
|
+
/**
|
|
17285
|
+
* @function isCbReadyByDefault - Determines if a callback is ready to be submitted by default
|
|
17286
|
+
* @param {object} callback - Generic FRCallback from JavaScript SDK
|
|
17287
|
+
* @returns {boolean}
|
|
17288
|
+
*/
|
|
17171
17289
|
function isCbReadyByDefault(callback) {
|
|
17172
17290
|
if (callback.getType() === CallbackType$1.ConfirmationCallback) {
|
|
17173
17291
|
const cb = callback;
|
|
@@ -17177,6 +17295,11 @@ function isCbReadyByDefault(callback) {
|
|
|
17177
17295
|
}
|
|
17178
17296
|
return false;
|
|
17179
17297
|
}
|
|
17298
|
+
/**
|
|
17299
|
+
* @function canForceUserInputOptionality
|
|
17300
|
+
* @param {object} callback - generic FRCallback from JavaScript SDK
|
|
17301
|
+
* @returns
|
|
17302
|
+
*/
|
|
17180
17303
|
function canForceUserInputOptionality(callback) {
|
|
17181
17304
|
// See if a callback function exists within this collection
|
|
17182
17305
|
const fn = forceUserInputOptionalityCallbacks[callback.getType()];
|
|
@@ -17204,9 +17327,9 @@ function isStepSelfSubmittable(callbacks, userInputOptional) {
|
|
|
17204
17327
|
return !unsubmittableCallbacks.length;
|
|
17205
17328
|
}
|
|
17206
17329
|
/**
|
|
17207
|
-
*
|
|
17330
|
+
* @function requiresUserInput - Determines if a callback requires user input
|
|
17208
17331
|
* @param {object} callback - Generic callback provided by JavaScript SDK
|
|
17209
|
-
* @returns
|
|
17332
|
+
* @returns {boolean}
|
|
17210
17333
|
*/
|
|
17211
17334
|
function requiresUserInput(callback) {
|
|
17212
17335
|
if (callback.getType() === CallbackType$1.SelectIdPCallback) {
|
|
@@ -17222,6 +17345,22 @@ function requiresUserInput(callback) {
|
|
|
17222
17345
|
}
|
|
17223
17346
|
// Notice this function can take a user provided argument function to
|
|
17224
17347
|
// override behavior (this doesn't have to be well defined)
|
|
17348
|
+
/**
|
|
17349
|
+
* @function isUserInputOptional - Determines if user input is optional
|
|
17350
|
+
* Notice this function can take a user provided argument function to
|
|
17351
|
+
* override behavior (this doesn't have to be well defined)
|
|
17352
|
+
* @param {array} callbackMetadataArray - array of callback metadata
|
|
17353
|
+
* @param {number} numOfUserInputCbs - number of user input requiring callbacks
|
|
17354
|
+
* @param {function} fn - optional function to override default behavior
|
|
17355
|
+
* @returns {boolean} - true if user input is optional
|
|
17356
|
+
* @example isUserInputOptional(callbackMetadataArray, numOfUserInputCbs, (prev, curr) => {
|
|
17357
|
+
* if (curr.derived.canForceUserInputOptionality && numOfUserInputCbs > 0) {
|
|
17358
|
+
* prev = true;
|
|
17359
|
+
* }
|
|
17360
|
+
* return prev;
|
|
17361
|
+
* })
|
|
17362
|
+
* @example isUserInputOptional(callbackMetadataArray, numOfUserInputCbs);
|
|
17363
|
+
*/
|
|
17225
17364
|
function isUserInputOptional(callbackMetadataArray, numOfUserInputCbs, fn) {
|
|
17226
17365
|
// default reducer function to check if both overriding callback exists
|
|
17227
17366
|
// along with user input required callbacks
|
|
@@ -17238,7 +17377,7 @@ function isUserInputOptional(callbackMetadataArray, numOfUserInputCbs, fn) {
|
|
|
17238
17377
|
/**
|
|
17239
17378
|
* @function buildCallbackMetadata - Constructs an array of callback metadata that matches to original callback array
|
|
17240
17379
|
* @param {object} step - The modified Widget step object
|
|
17241
|
-
* @param checkValidation - function that checks if current callback is the first invalid callback
|
|
17380
|
+
* @param {function} checkValidation - function that checks if current callback is the first invalid callback
|
|
17242
17381
|
* @returns {array}
|
|
17243
17382
|
*/
|
|
17244
17383
|
function buildCallbackMetadata(step, checkValidation, stageJson) {
|
|
@@ -17317,11 +17456,25 @@ function buildStepMetadata(callbackMetadataArray, stageJson, stageName) {
|
|
|
17317
17456
|
};
|
|
17318
17457
|
}
|
|
17319
17458
|
|
|
17459
|
+
/**
|
|
17460
|
+
* @function initializeJourney - Initializes the journey stack for tracking journey switches
|
|
17461
|
+
* @param {object} initOptions - The initial options to set
|
|
17462
|
+
* @returns {object} - The journey stack store with stack methods
|
|
17463
|
+
*/
|
|
17320
17464
|
function initializeStack(initOptions) {
|
|
17321
17465
|
const initialValue = initOptions ? [initOptions] : [];
|
|
17322
17466
|
const { update, set, subscribe } = writable(initialValue);
|
|
17323
17467
|
// Assign to exported variable (see bottom of file)
|
|
17324
17468
|
stack = {
|
|
17469
|
+
latest: async () => {
|
|
17470
|
+
return new Promise((resolve) => {
|
|
17471
|
+
// subscribe, grab the current value and unsubscribe
|
|
17472
|
+
subscribe((current) => {
|
|
17473
|
+
const lastItem = current[current.length - 1];
|
|
17474
|
+
resolve(lastItem);
|
|
17475
|
+
})();
|
|
17476
|
+
});
|
|
17477
|
+
},
|
|
17325
17478
|
pop: async () => {
|
|
17326
17479
|
return new Promise((resolve) => {
|
|
17327
17480
|
update((current) => {
|
|
@@ -17371,9 +17524,13 @@ const journeyStore = writable({
|
|
|
17371
17524
|
successful: false,
|
|
17372
17525
|
response: null,
|
|
17373
17526
|
});
|
|
17527
|
+
/**
|
|
17528
|
+
* @function initialize - Initializes the journey store
|
|
17529
|
+
* @param {object} initOptions - The initial options to set
|
|
17530
|
+
* @returns {object} - The journey store
|
|
17531
|
+
*/
|
|
17374
17532
|
function initialize$4(initOptions) {
|
|
17375
17533
|
const stack = initializeStack();
|
|
17376
|
-
let restartOptions;
|
|
17377
17534
|
let stepNumber = 0;
|
|
17378
17535
|
async function next(prevStep = null, nextOptions, resumeUrl) {
|
|
17379
17536
|
if (!Config.get().serverConfig?.baseUrl) {
|
|
@@ -17387,14 +17544,6 @@ function initialize$4(initOptions) {
|
|
|
17387
17544
|
...initOptions,
|
|
17388
17545
|
...nextOptions,
|
|
17389
17546
|
};
|
|
17390
|
-
// These options are reserved only for restarting a journey after failure
|
|
17391
|
-
if (initOptions || nextOptions) {
|
|
17392
|
-
restartOptions = {
|
|
17393
|
-
// Prioritize next options over initialize options
|
|
17394
|
-
...initOptions,
|
|
17395
|
-
...nextOptions,
|
|
17396
|
-
};
|
|
17397
|
-
}
|
|
17398
17547
|
/**
|
|
17399
17548
|
* Save previous step information just in case we have a total
|
|
17400
17549
|
* form failure due to 400 response from ForgeRock.
|
|
@@ -17481,6 +17630,7 @@ function initialize$4(initOptions) {
|
|
|
17481
17630
|
/**
|
|
17482
17631
|
* SUCCESSFUL COMPLETION BLOCK
|
|
17483
17632
|
*/
|
|
17633
|
+
stack.reset();
|
|
17484
17634
|
// Set final state
|
|
17485
17635
|
journeyStore.set({
|
|
17486
17636
|
completed: true,
|
|
@@ -17498,12 +17648,13 @@ function initialize$4(initOptions) {
|
|
|
17498
17648
|
*
|
|
17499
17649
|
* Grab failure message, which may contain encoded HTML
|
|
17500
17650
|
*/
|
|
17501
|
-
const failureMessageStr = htmlDecode(nextStep.payload.message || '');
|
|
17651
|
+
const failureMessageStr = htmlDecode(nextStep.payload.message || 'Unknown login error');
|
|
17502
17652
|
let restartedStep = null;
|
|
17503
17653
|
try {
|
|
17504
17654
|
/**
|
|
17505
17655
|
* Restart tree to get fresh step
|
|
17506
17656
|
*/
|
|
17657
|
+
const restartOptions = await stack.latest();
|
|
17507
17658
|
restartedStep = await FRAuth$1.next(undefined, restartOptions);
|
|
17508
17659
|
}
|
|
17509
17660
|
catch (err) {
|
|
@@ -17580,8 +17731,7 @@ function initialize$4(initOptions) {
|
|
|
17580
17731
|
error: {
|
|
17581
17732
|
code: nextStep.getCode(),
|
|
17582
17733
|
message: failureMessageStr,
|
|
17583
|
-
|
|
17584
|
-
step: prevStep?.payload,
|
|
17734
|
+
stage: prevStep?.payload?.stage,
|
|
17585
17735
|
troubleshoot: null,
|
|
17586
17736
|
},
|
|
17587
17737
|
loading: false,
|
|
@@ -17611,8 +17761,7 @@ function initialize$4(initOptions) {
|
|
|
17611
17761
|
error: {
|
|
17612
17762
|
code: nextStep.getCode(),
|
|
17613
17763
|
message: failureMessageStr,
|
|
17614
|
-
|
|
17615
|
-
step: prevStep?.payload,
|
|
17764
|
+
stage: prevStep?.payload?.stage,
|
|
17616
17765
|
troubleshoot: null,
|
|
17617
17766
|
},
|
|
17618
17767
|
loading: false,
|
|
@@ -17639,6 +17788,18 @@ function initialize$4(initOptions) {
|
|
|
17639
17788
|
await next(undefined, resumeOptions, url);
|
|
17640
17789
|
}
|
|
17641
17790
|
async function start(startOptions) {
|
|
17791
|
+
const configTree = Config.get().tree;
|
|
17792
|
+
// If no tree is passed in, but there's a configured default tree, use that
|
|
17793
|
+
if (!startOptions?.tree && configTree) {
|
|
17794
|
+
if (startOptions) {
|
|
17795
|
+
startOptions.tree = configTree;
|
|
17796
|
+
}
|
|
17797
|
+
else {
|
|
17798
|
+
startOptions = {
|
|
17799
|
+
tree: configTree,
|
|
17800
|
+
};
|
|
17801
|
+
}
|
|
17802
|
+
}
|
|
17642
17803
|
await stack.push(startOptions);
|
|
17643
17804
|
await next(undefined, startOptions);
|
|
17644
17805
|
}
|
|
@@ -17672,6 +17833,12 @@ const linksSchema = z
|
|
|
17672
17833
|
.strict();
|
|
17673
17834
|
linksSchema.partial();
|
|
17674
17835
|
const linksStore = writable();
|
|
17836
|
+
/**
|
|
17837
|
+
* @function initialize - Initialize the links store
|
|
17838
|
+
* @param {object} customLinks - An object of custom links to merge with the default
|
|
17839
|
+
* @returns {object} - The links store
|
|
17840
|
+
* @example initialize({ termsAndConditions: 'https://example.com/terms' });
|
|
17841
|
+
*/
|
|
17675
17842
|
function initialize$3(customLinks) {
|
|
17676
17843
|
// If customLinks is provided, provide feedback for object
|
|
17677
17844
|
if (customLinks) {
|
|
@@ -17694,7 +17861,19 @@ const oauthStore = writable({
|
|
|
17694
17861
|
successful: false,
|
|
17695
17862
|
response: null,
|
|
17696
17863
|
});
|
|
17864
|
+
/**
|
|
17865
|
+
* @function initialize - Initializes the OAuth store with a get function and a reset function
|
|
17866
|
+
* @param {object} initOptions - The options to pass to the TokenManager.getTokens function
|
|
17867
|
+
* @returns {object} - The OAuth store
|
|
17868
|
+
* @example initialize({ query: { prompt: 'none' } });
|
|
17869
|
+
*/
|
|
17697
17870
|
function initialize$2(initOptions) {
|
|
17871
|
+
/**
|
|
17872
|
+
* Get tokens from the server
|
|
17873
|
+
* new tokens are available in the subscribe method
|
|
17874
|
+
* @params: getOptions?: GetTokensOptions
|
|
17875
|
+
* @returns: Promise<void>
|
|
17876
|
+
*/
|
|
17698
17877
|
async function get(getOptions) {
|
|
17699
17878
|
/**
|
|
17700
17879
|
* Create an options object with getOptions overriding anything from initOptions
|
|
@@ -17762,7 +17941,18 @@ const userStore = writable({
|
|
|
17762
17941
|
successful: false,
|
|
17763
17942
|
response: null,
|
|
17764
17943
|
});
|
|
17944
|
+
/**
|
|
17945
|
+
* @function initialize - Initializes the user store with a get function and a reset function
|
|
17946
|
+
* @param {object} initOptions - The options to pass to the UserManager.getCurrentUser function
|
|
17947
|
+
* @returns {object} - The user store
|
|
17948
|
+
*/
|
|
17765
17949
|
function initialize$1(initOptions) {
|
|
17950
|
+
/**
|
|
17951
|
+
* Get user info from the server
|
|
17952
|
+
* New state is returned in your `userEvents.subscribe` callback function
|
|
17953
|
+
* @params: getOptions?: ConfigOptions
|
|
17954
|
+
* @returns: Promise<void>
|
|
17955
|
+
*/
|
|
17766
17956
|
async function get(getOptions) {
|
|
17767
17957
|
/**
|
|
17768
17958
|
* Create an options object with getOptions overriding anything from initOptions
|
|
@@ -17849,11 +18039,17 @@ styleSchema.partial();
|
|
|
17849
18039
|
const fallbackStyles = {
|
|
17850
18040
|
checksAndRadios: 'animated',
|
|
17851
18041
|
labels: 'floating',
|
|
17852
|
-
logo:
|
|
17853
|
-
sections:
|
|
17854
|
-
stage:
|
|
18042
|
+
logo: undefined,
|
|
18043
|
+
sections: undefined,
|
|
18044
|
+
stage: undefined,
|
|
17855
18045
|
};
|
|
17856
18046
|
const styleStore = writable(fallbackStyles);
|
|
18047
|
+
/**
|
|
18048
|
+
* @function initialize - Initialize the style store
|
|
18049
|
+
* @param {object} customStyle - An object of custom styles to merge with the default
|
|
18050
|
+
* @returns {object} - The style store
|
|
18051
|
+
* @example initialize({ checksAndRadios: 'standard' });
|
|
18052
|
+
*/
|
|
17857
18053
|
function initialize(customStyle) {
|
|
17858
18054
|
if (customStyle) {
|
|
17859
18055
|
styleSchema.parse(customStyle);
|
|
@@ -17865,6 +18061,17 @@ function initialize(customStyle) {
|
|
|
17865
18061
|
return styleStore;
|
|
17866
18062
|
}
|
|
17867
18063
|
|
|
18064
|
+
/**
|
|
18065
|
+
* @function widgetApiFactory - Creates the widget API
|
|
18066
|
+
* @param {object} componentApi - The component API
|
|
18067
|
+
* @returns {object} - The widget API
|
|
18068
|
+
* @property {object} componentApi - The component API for either inline or modal
|
|
18069
|
+
* @property {object} configuration - Sets the configuration for the widget
|
|
18070
|
+
* @property {function} getStores - Returns the stores: journeyStore, oauthStore, userStore
|
|
18071
|
+
* @property {object} journey - the journey API
|
|
18072
|
+
* @property {function} request - The HttpClient.request function from the SDK
|
|
18073
|
+
* @property {object} user - the user API
|
|
18074
|
+
*/
|
|
17868
18075
|
function widgetApiFactory(componentApi) {
|
|
17869
18076
|
let journeyStore;
|
|
17870
18077
|
let oauthStore;
|
|
@@ -17881,8 +18088,6 @@ function widgetApiFactory(componentApi) {
|
|
|
17881
18088
|
journeyStore.reset();
|
|
17882
18089
|
oauthStore.reset();
|
|
17883
18090
|
userStore.reset();
|
|
17884
|
-
// Fetch fresh journey step
|
|
17885
|
-
journey().start();
|
|
17886
18091
|
}
|
|
17887
18092
|
const configuration = (options) => {
|
|
17888
18093
|
if (options?.forgerock) {
|
|
@@ -17915,6 +18120,10 @@ function widgetApiFactory(componentApi) {
|
|
|
17915
18120
|
initialize$3(options?.links);
|
|
17916
18121
|
initialize(options?.style);
|
|
17917
18122
|
return {
|
|
18123
|
+
/** Set the Login Widget's Configuration
|
|
18124
|
+
* @param {WidgetConfigOptions} options - The configuration options for the Login Widget
|
|
18125
|
+
* @returns {void}
|
|
18126
|
+
**/
|
|
17918
18127
|
set(setOptions) {
|
|
17919
18128
|
if (setOptions?.forgerock) {
|
|
17920
18129
|
configure({
|
|
@@ -18036,6 +18245,11 @@ function widgetApiFactory(componentApi) {
|
|
|
18036
18245
|
return { change, start, subscribe };
|
|
18037
18246
|
};
|
|
18038
18247
|
const user = {
|
|
18248
|
+
/**
|
|
18249
|
+
* User Info
|
|
18250
|
+
* @param: void
|
|
18251
|
+
* @returns: UserStore
|
|
18252
|
+
*/
|
|
18039
18253
|
info() {
|
|
18040
18254
|
if (!journeyStore || !oauthStore || !userStore) {
|
|
18041
18255
|
logErrorAndThrow('missingStores');
|
|
@@ -18058,6 +18272,12 @@ function widgetApiFactory(componentApi) {
|
|
|
18058
18272
|
}
|
|
18059
18273
|
return { get: wrappedGet, subscribe };
|
|
18060
18274
|
},
|
|
18275
|
+
/**
|
|
18276
|
+
* Logout a user from an AM Session
|
|
18277
|
+
* @async
|
|
18278
|
+
* @param: void
|
|
18279
|
+
* @returns: Promise<void>
|
|
18280
|
+
**/
|
|
18061
18281
|
async logout() {
|
|
18062
18282
|
if (!journeyStore || !oauthStore || !userStore) {
|
|
18063
18283
|
logErrorAndThrow('missingStores');
|
|
@@ -18086,6 +18306,11 @@ function widgetApiFactory(componentApi) {
|
|
|
18086
18306
|
// Return undefined as there's no response information to share
|
|
18087
18307
|
return;
|
|
18088
18308
|
},
|
|
18309
|
+
/**
|
|
18310
|
+
* Returns the widget's Tokens object
|
|
18311
|
+
* @param void;
|
|
18312
|
+
* @returns OAuthStore
|
|
18313
|
+
*/
|
|
18089
18314
|
tokens() {
|
|
18090
18315
|
if (!journeyStore || !oauthStore || !userStore) {
|
|
18091
18316
|
logErrorAndThrow('missingStores');
|
|
@@ -18114,7 +18339,7 @@ function widgetApiFactory(componentApi) {
|
|
|
18114
18339
|
configuration,
|
|
18115
18340
|
getStores,
|
|
18116
18341
|
journey,
|
|
18117
|
-
request: _default$2.request,
|
|
18342
|
+
request: _default$2.request.bind(_default$2),
|
|
18118
18343
|
user,
|
|
18119
18344
|
};
|
|
18120
18345
|
}
|
|
@@ -18504,7 +18729,7 @@ function create_else_block$9(ctx) {
|
|
|
18504
18729
|
attr(button, "aria-controls", /*dialogId*/ ctx[1]);
|
|
18505
18730
|
|
|
18506
18731
|
attr(div, "class", div_class_value = `tw_pt-10 md:tw_pt-10 tw_text-right ${(/*$styleStore*/ ctx[5]?.logo)
|
|
18507
|
-
? 'tw_h-32 md:tw_h-36
|
|
18732
|
+
? 'tw_h-32 md:tw_h-36 tw_pb-6'
|
|
18508
18733
|
: ''}`);
|
|
18509
18734
|
},
|
|
18510
18735
|
m(target, anchor) {
|
|
@@ -18547,7 +18772,7 @@ function create_else_block$9(ctx) {
|
|
|
18547
18772
|
}
|
|
18548
18773
|
|
|
18549
18774
|
if (!current || dirty & /*$styleStore*/ 32 && div_class_value !== (div_class_value = `tw_pt-10 md:tw_pt-10 tw_text-right ${(/*$styleStore*/ ctx[5]?.logo)
|
|
18550
|
-
? 'tw_h-32 md:tw_h-36
|
|
18775
|
+
? 'tw_h-32 md:tw_h-36 tw_pb-6'
|
|
18551
18776
|
: ''}`)) {
|
|
18552
18777
|
attr(div, "class", div_class_value);
|
|
18553
18778
|
}
|
|
@@ -20568,6 +20793,11 @@ function matchJourneyAndDecideAction(href, journeys, stack) {
|
|
|
20568
20793
|
/** *********************************************
|
|
20569
20794
|
* NEW "NORMALIZED" METHODS
|
|
20570
20795
|
*/
|
|
20796
|
+
/**
|
|
20797
|
+
* @function getInputTypeFromPolicies - Determines the type of input to use based on the policies object
|
|
20798
|
+
* @param {object} policies - The policies object from the callback
|
|
20799
|
+
* @returns {string} - The type of input to use
|
|
20800
|
+
*/
|
|
20571
20801
|
function getInputTypeFromPolicies(policies) {
|
|
20572
20802
|
const value = policies?.value;
|
|
20573
20803
|
if (typeof value !== 'object') {
|
|
@@ -20585,13 +20815,47 @@ function getInputTypeFromPolicies(policies) {
|
|
|
20585
20815
|
}
|
|
20586
20816
|
return 'text';
|
|
20587
20817
|
}
|
|
20818
|
+
/**
|
|
20819
|
+
* @function getValidationFailureParams - Gets the validation failure params from the failed policy object
|
|
20820
|
+
* @param {object} failedPolicy - The failed policy object from the callback
|
|
20821
|
+
* @returns {array} - An array of objects containing the length, message, and rule
|
|
20822
|
+
*/
|
|
20588
20823
|
function getValidationFailureParams(failedPolicy) {
|
|
20589
|
-
if (failedPolicy?.policyRequirement === '
|
|
20590
|
-
const params = failedPolicy
|
|
20824
|
+
if (failedPolicy?.policyRequirement === 'DICTIONARY') {
|
|
20825
|
+
const params = failedPolicy.params;
|
|
20826
|
+
const min = params?.['min-substring-length'] || 0;
|
|
20827
|
+
const arr = [];
|
|
20828
|
+
if (params?.['check-substrings'] && params?.['test-reversed-password']) {
|
|
20829
|
+
arr.push({
|
|
20830
|
+
length: min,
|
|
20831
|
+
message: interpolate('passwordCannotContainCommonPasswordsOrBeReversibleStringsLessThan', {
|
|
20832
|
+
min: String(min),
|
|
20833
|
+
}),
|
|
20834
|
+
rule: 'reversibleSubstrings',
|
|
20835
|
+
});
|
|
20836
|
+
}
|
|
20837
|
+
else if (params?.['test-reversed-password']) {
|
|
20838
|
+
arr.push({
|
|
20839
|
+
length: null,
|
|
20840
|
+
message: interpolate('passwordCannotContainCommonPasswordsOrBeReversible'),
|
|
20841
|
+
rule: 'reversibleSubstrings',
|
|
20842
|
+
});
|
|
20843
|
+
}
|
|
20844
|
+
else {
|
|
20845
|
+
arr.push({
|
|
20846
|
+
length: null,
|
|
20847
|
+
message: interpolate('passwordCannotContainCommonPasswords'),
|
|
20848
|
+
rule: 'reversibleSubstrings',
|
|
20849
|
+
});
|
|
20850
|
+
}
|
|
20851
|
+
return arr;
|
|
20852
|
+
}
|
|
20853
|
+
else if (failedPolicy?.policyRequirement === 'CHARACTER_SET') {
|
|
20854
|
+
const params = failedPolicy.params;
|
|
20591
20855
|
return params?.['character-sets'].map(convertCharacterSetToRuleObj);
|
|
20592
20856
|
}
|
|
20593
20857
|
else if (failedPolicy?.policyRequirement === 'LENGTH_BASED') {
|
|
20594
|
-
const params = failedPolicy
|
|
20858
|
+
const params = failedPolicy.params;
|
|
20595
20859
|
const min = params?.['min-password-length'] || 0;
|
|
20596
20860
|
const max = params?.['max-password-length'] || null;
|
|
20597
20861
|
const arr = [];
|
|
@@ -20611,6 +20875,26 @@ function getValidationFailureParams(failedPolicy) {
|
|
|
20611
20875
|
}
|
|
20612
20876
|
return arr;
|
|
20613
20877
|
}
|
|
20878
|
+
else if (failedPolicy?.policyRequirement === 'REPEATED_CHARACTERS') {
|
|
20879
|
+
const params = failedPolicy.params;
|
|
20880
|
+
const max = params['max-consecutive-length'] || 0;
|
|
20881
|
+
const arr = [];
|
|
20882
|
+
if (!params['case-sensitive-validation']) {
|
|
20883
|
+
arr.push({
|
|
20884
|
+
length: max,
|
|
20885
|
+
message: interpolate('charactersCannotRepeatMoreThanCaseInsensitive', { max: String(max) }),
|
|
20886
|
+
rule: 'repeatedCharactersCaseInsensitive',
|
|
20887
|
+
});
|
|
20888
|
+
}
|
|
20889
|
+
else {
|
|
20890
|
+
arr.push({
|
|
20891
|
+
length: max,
|
|
20892
|
+
message: interpolate('charactersCannotRepeatMoreThan', { max: String(max) }),
|
|
20893
|
+
rule: 'repeatedCharacters',
|
|
20894
|
+
});
|
|
20895
|
+
}
|
|
20896
|
+
return arr;
|
|
20897
|
+
}
|
|
20614
20898
|
else if (failedPolicy?.policyRequirement === 'VALID_USERNAME') {
|
|
20615
20899
|
return [
|
|
20616
20900
|
{
|
|
@@ -20639,6 +20923,11 @@ function getValidationFailureParams(failedPolicy) {
|
|
|
20639
20923
|
];
|
|
20640
20924
|
}
|
|
20641
20925
|
}
|
|
20926
|
+
/**
|
|
20927
|
+
* @function getValidationMessageString - Gets the validation message string from the policy object
|
|
20928
|
+
* @param {object} policy - The policy object from the callback
|
|
20929
|
+
* @returns {string} - The validation message string
|
|
20930
|
+
*/
|
|
20642
20931
|
function getValidationMessageString(policy) {
|
|
20643
20932
|
switch (policy?.policyId) {
|
|
20644
20933
|
case 'at-least-X-capitals': {
|
|
@@ -20653,18 +20942,36 @@ function getValidationMessageString(policy) {
|
|
|
20653
20942
|
}
|
|
20654
20943
|
case 'cannot-contain-characters': {
|
|
20655
20944
|
const params = policy?.params;
|
|
20656
|
-
|
|
20657
|
-
|
|
20658
|
-
return
|
|
20659
|
-
}
|
|
20945
|
+
let chars = '';
|
|
20946
|
+
if (typeof params !== 'object') {
|
|
20947
|
+
return '';
|
|
20948
|
+
}
|
|
20949
|
+
if (Array.isArray(params.forbiddenChars)) {
|
|
20950
|
+
chars = params.forbiddenChars.reduce((prev, curr) => {
|
|
20951
|
+
prev = `${prev ? `${prev}, ` : `${prev}`} ${curr}`;
|
|
20952
|
+
return prev;
|
|
20953
|
+
}, '');
|
|
20954
|
+
}
|
|
20955
|
+
else if (typeof params.forbiddenChars === 'string') {
|
|
20956
|
+
chars = params.forbiddenChars;
|
|
20957
|
+
}
|
|
20660
20958
|
return interpolate('fieldCanNotContainFollowingCharacters', { chars });
|
|
20661
20959
|
}
|
|
20662
20960
|
case 'cannot-contain-others': {
|
|
20663
20961
|
const params = policy?.params;
|
|
20664
|
-
|
|
20665
|
-
|
|
20666
|
-
return
|
|
20667
|
-
}
|
|
20962
|
+
let fields = '';
|
|
20963
|
+
if (typeof params !== 'object') {
|
|
20964
|
+
return '';
|
|
20965
|
+
}
|
|
20966
|
+
if (Array.isArray(params.disallowedFields)) {
|
|
20967
|
+
fields = params.disallowedFields?.reduce((prev, curr) => {
|
|
20968
|
+
prev = `${prev ? `${prev}, ` : `${prev}`} ${interpolate(curr)}`;
|
|
20969
|
+
return prev;
|
|
20970
|
+
}, '');
|
|
20971
|
+
}
|
|
20972
|
+
else if (typeof params.disallowedFields === 'string') {
|
|
20973
|
+
fields = params.disallowedFields;
|
|
20974
|
+
}
|
|
20668
20975
|
return interpolate('fieldCanNotContainFollowingValues', { fields });
|
|
20669
20976
|
}
|
|
20670
20977
|
case 'maximum-length': {
|
|
@@ -20704,6 +21011,12 @@ function getValidationMessageString(policy) {
|
|
|
20704
21011
|
return '';
|
|
20705
21012
|
}
|
|
20706
21013
|
}
|
|
21014
|
+
/**
|
|
21015
|
+
* @function getValidationFailures - Gets the validation failures from the callback object
|
|
21016
|
+
* @param {object} callback - The callback object from the server
|
|
21017
|
+
* @param {string} label - The label of the field
|
|
21018
|
+
* @returns {array} - An array of failed policies
|
|
21019
|
+
*/
|
|
20707
21020
|
function getValidationFailures(callback, label) {
|
|
20708
21021
|
const failedPolicies = callback.getFailedPolicies && callback.getFailedPolicies();
|
|
20709
21022
|
const parsedPolicies = parseFailedPolicies(failedPolicies, label);
|
|
@@ -20715,6 +21028,11 @@ function getValidationFailures(callback, label) {
|
|
|
20715
21028
|
};
|
|
20716
21029
|
});
|
|
20717
21030
|
}
|
|
21031
|
+
/**
|
|
21032
|
+
* @function getValidationPolicies - Gets the validation policies from the callback object
|
|
21033
|
+
* @param {object} policies - The policies object from the callback
|
|
21034
|
+
* @returns {array} - An array of policies
|
|
21035
|
+
*/
|
|
20718
21036
|
function getValidationPolicies(policies) {
|
|
20719
21037
|
if (typeof policies !== 'object' && !policies) {
|
|
20720
21038
|
return [];
|
|
@@ -20733,6 +21051,11 @@ function getValidationPolicies(policies) {
|
|
|
20733
21051
|
})
|
|
20734
21052
|
.filter((policy) => !!policy.message);
|
|
20735
21053
|
}
|
|
21054
|
+
/**
|
|
21055
|
+
* @function isInputRequired - Checks if the input is required
|
|
21056
|
+
* @param {object} callback - The callback object from the server
|
|
21057
|
+
* @returns {boolean} - Whether the input is required
|
|
21058
|
+
*/
|
|
20736
21059
|
function isInputRequired(callback) {
|
|
20737
21060
|
const policies = callback.getPolicies && callback.getPolicies();
|
|
20738
21061
|
let isRequired = false;
|
|
@@ -20744,46 +21067,93 @@ function isInputRequired(callback) {
|
|
|
20744
21067
|
}
|
|
20745
21068
|
return isRequired;
|
|
20746
21069
|
}
|
|
21070
|
+
/**
|
|
21071
|
+
* @function convertCharacterSetToRuleObj - Converts a character set to a rule object
|
|
21072
|
+
* @param {string} set - The character set to convert
|
|
21073
|
+
* @returns {object} - The rule object
|
|
21074
|
+
*/
|
|
20747
21075
|
function convertCharacterSetToRuleObj(set) {
|
|
20748
21076
|
const arr = set.split(':');
|
|
20749
21077
|
const num = arr[0];
|
|
20750
21078
|
const type = arr[1];
|
|
20751
21079
|
if (type === '0123456789') {
|
|
20752
|
-
|
|
20753
|
-
|
|
20754
|
-
|
|
20755
|
-
|
|
20756
|
-
|
|
21080
|
+
if (num === '0') {
|
|
21081
|
+
return {
|
|
21082
|
+
length: null,
|
|
21083
|
+
message: interpolate('shouldContainANumber'),
|
|
21084
|
+
rule: 'numbers',
|
|
21085
|
+
};
|
|
21086
|
+
}
|
|
21087
|
+
else {
|
|
21088
|
+
return {
|
|
21089
|
+
length: Number(num),
|
|
21090
|
+
message: interpolate('minimumNumberOfNumbers', { num: String(num) }),
|
|
21091
|
+
rule: 'numbers',
|
|
21092
|
+
};
|
|
21093
|
+
}
|
|
20757
21094
|
}
|
|
20758
21095
|
else if (type === 'ABCDEFGHIJKLMNOPQRSTUVWXYZ') {
|
|
20759
|
-
|
|
20760
|
-
|
|
20761
|
-
|
|
20762
|
-
|
|
20763
|
-
|
|
21096
|
+
if (num === '0') {
|
|
21097
|
+
return {
|
|
21098
|
+
length: null,
|
|
21099
|
+
message: interpolate('shouldContainAnUppercase'),
|
|
21100
|
+
rule: 'uppercase',
|
|
21101
|
+
};
|
|
21102
|
+
}
|
|
21103
|
+
else {
|
|
21104
|
+
return {
|
|
21105
|
+
length: Number(num),
|
|
21106
|
+
message: interpolate('minimumNumberOfUppercase', { num: String(num) }),
|
|
21107
|
+
rule: 'uppercase',
|
|
21108
|
+
};
|
|
21109
|
+
}
|
|
20764
21110
|
}
|
|
20765
21111
|
else if (type === 'abcdefghijklmnopqrstuvwxyz') {
|
|
20766
|
-
|
|
20767
|
-
|
|
20768
|
-
|
|
20769
|
-
|
|
20770
|
-
|
|
21112
|
+
if (num === '0') {
|
|
21113
|
+
return {
|
|
21114
|
+
length: null,
|
|
21115
|
+
message: interpolate('shouldContainALowercase'),
|
|
21116
|
+
rule: 'lowercase',
|
|
21117
|
+
};
|
|
21118
|
+
}
|
|
21119
|
+
else {
|
|
21120
|
+
return {
|
|
21121
|
+
length: Number(num),
|
|
21122
|
+
message: interpolate('minimumNumberOfLowercase', { num: String(num) }),
|
|
21123
|
+
rule: 'lowercase',
|
|
21124
|
+
};
|
|
21125
|
+
}
|
|
20771
21126
|
}
|
|
20772
21127
|
else if (type.includes('@') || type.includes('!') || type.includes('*') || type.includes('#')) {
|
|
20773
|
-
|
|
20774
|
-
|
|
20775
|
-
|
|
20776
|
-
|
|
20777
|
-
|
|
21128
|
+
if (num === '0') {
|
|
21129
|
+
return {
|
|
21130
|
+
length: null,
|
|
21131
|
+
message: interpolate('shouldContainASymbol'),
|
|
21132
|
+
rule: 'symbols',
|
|
21133
|
+
};
|
|
21134
|
+
}
|
|
21135
|
+
else {
|
|
21136
|
+
return {
|
|
21137
|
+
length: Number(num),
|
|
21138
|
+
message: interpolate('minimumNumberOfSymbols', { num: String(num) }),
|
|
21139
|
+
rule: 'symbols',
|
|
21140
|
+
};
|
|
21141
|
+
}
|
|
20778
21142
|
}
|
|
20779
21143
|
else {
|
|
20780
21144
|
return {
|
|
20781
|
-
length:
|
|
21145
|
+
length: null,
|
|
20782
21146
|
message: interpolate('pleaseCheckValue'),
|
|
20783
21147
|
rule: 'unknown',
|
|
20784
21148
|
};
|
|
20785
21149
|
}
|
|
20786
21150
|
}
|
|
21151
|
+
/**
|
|
21152
|
+
* @function parseFailedPolicies - Parses the failed policies from the callback object
|
|
21153
|
+
* @param {array} policies - The policies array from the callback
|
|
21154
|
+
* @param {string} label - The label of the field
|
|
21155
|
+
* @returns {array} - An array of failed policies
|
|
21156
|
+
*/
|
|
20787
21157
|
function parseFailedPolicies(policies, label) {
|
|
20788
21158
|
return policies.map((policy) => {
|
|
20789
21159
|
if (typeof policy === 'string') {
|
|
@@ -20799,8 +21169,10 @@ function parseFailedPolicies(policies, label) {
|
|
|
20799
21169
|
}
|
|
20800
21170
|
});
|
|
20801
21171
|
}
|
|
20802
|
-
/**
|
|
20803
|
-
*
|
|
21172
|
+
/**
|
|
21173
|
+
* @function getAttributeValidationFailureText - Gets the validation failure text from the callback object
|
|
21174
|
+
* @param {object} callback - The callback object from the server
|
|
21175
|
+
* @returns {string} - The validation failure text
|
|
20804
21176
|
*/
|
|
20805
21177
|
function getAttributeValidationFailureText(callback) {
|
|
20806
21178
|
// TODO: Mature this utility for better parsing and display
|
|
@@ -21799,13 +22171,6 @@ function instance$I($$self, $$props, $$invalidate) {
|
|
|
21799
22171
|
let validationFailure;
|
|
21800
22172
|
|
|
21801
22173
|
function setValue(event) {
|
|
21802
|
-
/** ***********************************************************************
|
|
21803
|
-
* SDK INTEGRATION POINT
|
|
21804
|
-
* Summary: SDK callback methods for setting values
|
|
21805
|
-
* ------------------------------------------------------------------------
|
|
21806
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
21807
|
-
* for writing values to the callbacks received from AM
|
|
21808
|
-
*********************************************************************** */
|
|
21809
22174
|
callback.setInputValue(event.target.checked);
|
|
21810
22175
|
}
|
|
21811
22176
|
|
|
@@ -22745,7 +23110,7 @@ function get_each_context$7(ctx, list, i) {
|
|
|
22745
23110
|
return child_ctx;
|
|
22746
23111
|
}
|
|
22747
23112
|
|
|
22748
|
-
// (
|
|
23113
|
+
// (39:0) {#if labelOrder === 'first'}
|
|
22749
23114
|
function create_if_block_1$a(ctx) {
|
|
22750
23115
|
let label_1;
|
|
22751
23116
|
let current;
|
|
@@ -22793,7 +23158,7 @@ function create_if_block_1$a(ctx) {
|
|
|
22793
23158
|
};
|
|
22794
23159
|
}
|
|
22795
23160
|
|
|
22796
|
-
// (
|
|
23161
|
+
// (40:2) <Label {key} classes={`${labelClasses}`}>
|
|
22797
23162
|
function create_default_slot_1$b(ctx) {
|
|
22798
23163
|
let t;
|
|
22799
23164
|
|
|
@@ -22813,7 +23178,7 @@ function create_default_slot_1$b(ctx) {
|
|
|
22813
23178
|
};
|
|
22814
23179
|
}
|
|
22815
23180
|
|
|
22816
|
-
// (
|
|
23181
|
+
// (54:2) {#each options as option}
|
|
22817
23182
|
function create_each_block$7(ctx) {
|
|
22818
23183
|
let option;
|
|
22819
23184
|
let t0_value = /*option*/ ctx[15].text + "";
|
|
@@ -22854,7 +23219,7 @@ function create_each_block$7(ctx) {
|
|
|
22854
23219
|
};
|
|
22855
23220
|
}
|
|
22856
23221
|
|
|
22857
|
-
// (
|
|
23222
|
+
// (61:0) {#if labelOrder === 'last'}
|
|
22858
23223
|
function create_if_block$g(ctx) {
|
|
22859
23224
|
let label_1;
|
|
22860
23225
|
let current;
|
|
@@ -22907,7 +23272,7 @@ function create_if_block$g(ctx) {
|
|
|
22907
23272
|
};
|
|
22908
23273
|
}
|
|
22909
23274
|
|
|
22910
|
-
// (
|
|
23275
|
+
// (62:2) <Label {key} classes={`${shouldDisplayOption ? labelClasses : 'tw_sr-only'}`}>
|
|
22911
23276
|
function create_default_slot$i(ctx) {
|
|
22912
23277
|
let t;
|
|
22913
23278
|
|
|
@@ -23146,8 +23511,6 @@ function instance$E($$self, $$props, $$invalidate) {
|
|
|
23146
23511
|
// Check if text is same as label
|
|
23147
23512
|
$$invalidate(10, shouldDisplayOption = !(label === selectedOption?.text));
|
|
23148
23513
|
|
|
23149
|
-
console.log(shouldDisplayOption);
|
|
23150
|
-
|
|
23151
23514
|
// Continue with calling onChange parameter
|
|
23152
23515
|
onChange(event);
|
|
23153
23516
|
}
|
|
@@ -23574,7 +23937,7 @@ function create_else_block$6(ctx) {
|
|
|
23574
23937
|
};
|
|
23575
23938
|
}
|
|
23576
23939
|
|
|
23577
|
-
// (
|
|
23940
|
+
// (52:0) {#if callbackMetadata?.platform?.displayType === 'radio'}
|
|
23578
23941
|
function create_if_block$f(ctx) {
|
|
23579
23942
|
let radio;
|
|
23580
23943
|
let current;
|
|
@@ -23729,13 +24092,6 @@ function instance$B($$self, $$props, $$invalidate) {
|
|
|
23729
24092
|
* @param {Object} event
|
|
23730
24093
|
*/
|
|
23731
24094
|
function setValue(event) {
|
|
23732
|
-
/** ***********************************************************************
|
|
23733
|
-
* SDK INTEGRATION POINT
|
|
23734
|
-
* Summary: SDK callback methods for setting values
|
|
23735
|
-
* ------------------------------------------------------------------------
|
|
23736
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
23737
|
-
* for writing values to the callbacks received from AM
|
|
23738
|
-
*********************************************************************** */
|
|
23739
24095
|
callback.setChoiceIndex(Number(event.target.value));
|
|
23740
24096
|
}
|
|
23741
24097
|
|
|
@@ -23748,13 +24104,6 @@ function instance$B($$self, $$props, $$invalidate) {
|
|
|
23748
24104
|
$$self.$$.update = () => {
|
|
23749
24105
|
if ($$self.$$.dirty & /*callback, callbackMetadata, prompt*/ 2051) {
|
|
23750
24106
|
{
|
|
23751
|
-
/** *************************************************************************
|
|
23752
|
-
* SDK INTEGRATION POINT
|
|
23753
|
-
* Summary: SDK callback methods for getting values
|
|
23754
|
-
* --------------------------------------------------------------------------
|
|
23755
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
23756
|
-
* for accessing values from the callbacks received from AM
|
|
23757
|
-
************************************************************************* */
|
|
23758
24107
|
$$invalidate(2, choiceOptions = callback.getChoices()?.map((text, idx) => ({
|
|
23759
24108
|
/**
|
|
23760
24109
|
* Since locale content keys for the choice component are built off of the
|
|
@@ -23919,7 +24268,7 @@ function get_each_context$6(ctx, list, i) {
|
|
|
23919
24268
|
return child_ctx;
|
|
23920
24269
|
}
|
|
23921
24270
|
|
|
23922
|
-
// (
|
|
24271
|
+
// (81:0) {#if stepMetadata?.platform?.stageName !== 'OneTimePassword'}
|
|
23923
24272
|
function create_if_block$e(ctx) {
|
|
23924
24273
|
let current_block_type_index;
|
|
23925
24274
|
let if_block;
|
|
@@ -23989,7 +24338,7 @@ function create_if_block$e(ctx) {
|
|
|
23989
24338
|
};
|
|
23990
24339
|
}
|
|
23991
24340
|
|
|
23992
|
-
// (
|
|
24341
|
+
// (103:2) {:else}
|
|
23993
24342
|
function create_else_block_1(ctx) {
|
|
23994
24343
|
let grid;
|
|
23995
24344
|
let current;
|
|
@@ -24035,7 +24384,7 @@ function create_else_block_1(ctx) {
|
|
|
24035
24384
|
};
|
|
24036
24385
|
}
|
|
24037
24386
|
|
|
24038
|
-
// (
|
|
24387
|
+
// (82:2) {#if !stepMetadata?.derived.isStepSelfSubmittable}
|
|
24039
24388
|
function create_if_block_1$9(ctx) {
|
|
24040
24389
|
let current_block_type_index;
|
|
24041
24390
|
let if_block;
|
|
@@ -24105,7 +24454,7 @@ function create_if_block_1$9(ctx) {
|
|
|
24105
24454
|
};
|
|
24106
24455
|
}
|
|
24107
24456
|
|
|
24108
|
-
// (
|
|
24457
|
+
// (106:8) <Button style={options.length > 1 && defaultChoice === Number(opt.value) ? 'primary' : buttonStyle} type="button" width="auto" onClick={() => setBtnValue(Number(opt.value))} >
|
|
24109
24458
|
function create_default_slot_2$5(ctx) {
|
|
24110
24459
|
let t0_value = /*opt*/ ctx[15].text + "";
|
|
24111
24460
|
let t0;
|
|
@@ -24130,7 +24479,7 @@ function create_default_slot_2$5(ctx) {
|
|
|
24130
24479
|
};
|
|
24131
24480
|
}
|
|
24132
24481
|
|
|
24133
|
-
// (
|
|
24482
|
+
// (105:6) {#each options as opt}
|
|
24134
24483
|
function create_each_block$6(ctx) {
|
|
24135
24484
|
let button;
|
|
24136
24485
|
let current;
|
|
@@ -24191,7 +24540,7 @@ function create_each_block$6(ctx) {
|
|
|
24191
24540
|
};
|
|
24192
24541
|
}
|
|
24193
24542
|
|
|
24194
|
-
// (
|
|
24543
|
+
// (104:4) <Grid num={options.length}>
|
|
24195
24544
|
function create_default_slot_1$a(ctx) {
|
|
24196
24545
|
let each_1_anchor;
|
|
24197
24546
|
let current;
|
|
@@ -24275,7 +24624,7 @@ function create_default_slot_1$a(ctx) {
|
|
|
24275
24624
|
};
|
|
24276
24625
|
}
|
|
24277
24626
|
|
|
24278
|
-
// (
|
|
24627
|
+
// (92:4) {:else}
|
|
24279
24628
|
function create_else_block$5(ctx) {
|
|
24280
24629
|
let checkbox;
|
|
24281
24630
|
let current;
|
|
@@ -24326,7 +24675,7 @@ function create_else_block$5(ctx) {
|
|
|
24326
24675
|
};
|
|
24327
24676
|
}
|
|
24328
24677
|
|
|
24329
|
-
// (
|
|
24678
|
+
// (83:4) {#if options.length > 1}
|
|
24330
24679
|
function create_if_block_2$8(ctx) {
|
|
24331
24680
|
let select;
|
|
24332
24681
|
let current;
|
|
@@ -24373,7 +24722,7 @@ function create_if_block_2$8(ctx) {
|
|
|
24373
24722
|
};
|
|
24374
24723
|
}
|
|
24375
24724
|
|
|
24376
|
-
// (
|
|
24725
|
+
// (93:6) <Checkbox isFirstInvalidInput={callbackMetadata?.derived.isFirstInvalidInput || false} isInvalid={false} key={inputName} onChange={setCheckboxValue} value={false} >
|
|
24377
24726
|
function create_default_slot$h(ctx) {
|
|
24378
24727
|
let t_value = /*options*/ ctx[3][0].text + "";
|
|
24379
24728
|
let t;
|
|
@@ -24485,13 +24834,6 @@ function instance$z($$self, $$props, $$invalidate) {
|
|
|
24485
24834
|
* @param {Object} event
|
|
24486
24835
|
*/
|
|
24487
24836
|
function setOptionValue(event) {
|
|
24488
|
-
/** ***********************************************************************
|
|
24489
|
-
* SDK INTEGRATION POINT
|
|
24490
|
-
* Summary: SDK callback methods for setting values
|
|
24491
|
-
* ------------------------------------------------------------------------
|
|
24492
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
24493
|
-
* for writing values to the callbacks received from AM
|
|
24494
|
-
*********************************************************************** */
|
|
24495
24837
|
callback.setOptionIndex(Number(event.target.value));
|
|
24496
24838
|
}
|
|
24497
24839
|
|
|
@@ -24500,13 +24842,6 @@ function instance$z($$self, $$props, $$invalidate) {
|
|
|
24500
24842
|
* @param {Object} event
|
|
24501
24843
|
*/
|
|
24502
24844
|
function setCheckboxValue(event) {
|
|
24503
|
-
/** ***********************************************************************
|
|
24504
|
-
* SDK INTEGRATION POINT
|
|
24505
|
-
* Summary: SDK callback methods for setting values
|
|
24506
|
-
* ------------------------------------------------------------------------
|
|
24507
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
24508
|
-
* for writing values to the callbacks received from AM
|
|
24509
|
-
*********************************************************************** */
|
|
24510
24845
|
const value = event.target.checked;
|
|
24511
24846
|
|
|
24512
24847
|
if (value) {
|
|
@@ -24871,7 +25206,7 @@ function create_if_block_5$1(ctx) {
|
|
|
24871
25206
|
}
|
|
24872
25207
|
|
|
24873
25208
|
// (65:0) {#if type === 'number'}
|
|
24874
|
-
function create_if_block_4$
|
|
25209
|
+
function create_if_block_4$2(ctx) {
|
|
24875
25210
|
let input;
|
|
24876
25211
|
let input_aria_describedby_value;
|
|
24877
25212
|
let input_class_value;
|
|
@@ -24951,7 +25286,7 @@ function create_if_block_4$1(ctx) {
|
|
|
24951
25286
|
}
|
|
24952
25287
|
|
|
24953
25288
|
// (81:0) {#if type === 'password'}
|
|
24954
|
-
function create_if_block_3$
|
|
25289
|
+
function create_if_block_3$6(ctx) {
|
|
24955
25290
|
let input;
|
|
24956
25291
|
let input_aria_describedby_value;
|
|
24957
25292
|
let input_class_value;
|
|
@@ -25271,8 +25606,8 @@ function create_fragment$x(ctx) {
|
|
|
25271
25606
|
let if_block0 = /*labelOrder*/ ctx[6] === 'first' && create_if_block_7$1(ctx);
|
|
25272
25607
|
let if_block1 = /*type*/ ctx[11] === 'date' && create_if_block_6$1(ctx);
|
|
25273
25608
|
let if_block2 = /*type*/ ctx[11] === 'email' && create_if_block_5$1(ctx);
|
|
25274
|
-
let if_block3 = /*type*/ ctx[11] === 'number' && create_if_block_4$
|
|
25275
|
-
let if_block4 = /*type*/ ctx[11] === 'password' && create_if_block_3$
|
|
25609
|
+
let if_block3 = /*type*/ ctx[11] === 'number' && create_if_block_4$2(ctx);
|
|
25610
|
+
let if_block4 = /*type*/ ctx[11] === 'password' && create_if_block_3$6(ctx);
|
|
25276
25611
|
let if_block5 = /*type*/ ctx[11] === 'phone' && create_if_block_2$7(ctx);
|
|
25277
25612
|
let if_block6 = /*type*/ ctx[11] === 'text' && create_if_block_1$8(ctx);
|
|
25278
25613
|
let if_block7 = /*labelOrder*/ ctx[6] === 'last' && create_if_block$d(ctx);
|
|
@@ -25369,7 +25704,7 @@ function create_fragment$x(ctx) {
|
|
|
25369
25704
|
if (if_block3) {
|
|
25370
25705
|
if_block3.p(ctx, dirty);
|
|
25371
25706
|
} else {
|
|
25372
|
-
if_block3 = create_if_block_4$
|
|
25707
|
+
if_block3 = create_if_block_4$2(ctx);
|
|
25373
25708
|
if_block3.c();
|
|
25374
25709
|
if_block3.m(t3.parentNode, t3);
|
|
25375
25710
|
}
|
|
@@ -25382,7 +25717,7 @@ function create_fragment$x(ctx) {
|
|
|
25382
25717
|
if (if_block4) {
|
|
25383
25718
|
if_block4.p(ctx, dirty);
|
|
25384
25719
|
} else {
|
|
25385
|
-
if_block4 = create_if_block_3$
|
|
25720
|
+
if_block4 = create_if_block_3$6(ctx);
|
|
25386
25721
|
if_block4.c();
|
|
25387
25722
|
if_block4.m(t4.parentNode, t4);
|
|
25388
25723
|
}
|
|
@@ -26518,15 +26853,7 @@ function instance$t($$self, $$props, $$invalidate) {
|
|
|
26518
26853
|
? Stacked_label$1
|
|
26519
26854
|
: Floating_label$1;
|
|
26520
26855
|
|
|
26521
|
-
/** *************************************************************************
|
|
26522
|
-
* SDK INTEGRATION POINT
|
|
26523
|
-
* Summary: SDK callback methods for getting values
|
|
26524
|
-
* --------------------------------------------------------------------------
|
|
26525
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
26526
|
-
* for accessing values from the callbacks received from AM
|
|
26527
|
-
************************************************************************* */
|
|
26528
26856
|
let customQuestionIndex = null;
|
|
26529
|
-
|
|
26530
26857
|
let displayCustomQuestionInput = false;
|
|
26531
26858
|
let inputArr;
|
|
26532
26859
|
let inputName;
|
|
@@ -26554,13 +26881,6 @@ function instance$t($$self, $$props, $$invalidate) {
|
|
|
26554
26881
|
* @param {Object} event
|
|
26555
26882
|
*/
|
|
26556
26883
|
function setAnswer(event) {
|
|
26557
|
-
/** ***********************************************************************
|
|
26558
|
-
* SDK INTEGRATION POINT
|
|
26559
|
-
* Summary: SDK callback methods for setting values
|
|
26560
|
-
* ------------------------------------------------------------------------
|
|
26561
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
26562
|
-
* for writing values to the callbacks received from AM
|
|
26563
|
-
*********************************************************************** */
|
|
26564
26884
|
callback.setAnswer(event.target.value);
|
|
26565
26885
|
}
|
|
26566
26886
|
|
|
@@ -26577,14 +26897,6 @@ function instance$t($$self, $$props, $$invalidate) {
|
|
|
26577
26897
|
callback.setAnswer('');
|
|
26578
26898
|
} else {
|
|
26579
26899
|
$$invalidate(3, displayCustomQuestionInput = false);
|
|
26580
|
-
|
|
26581
|
-
/** ***********************************************************************
|
|
26582
|
-
* SDK INTEGRATION POINT
|
|
26583
|
-
* Summary: SDK callback methods for setting values
|
|
26584
|
-
* ------------------------------------------------------------------------
|
|
26585
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
26586
|
-
* for writing values to the callbacks received from AM
|
|
26587
|
-
*********************************************************************** */
|
|
26588
26900
|
callback.setQuestion(selectValue);
|
|
26589
26901
|
}
|
|
26590
26902
|
}
|
|
@@ -26595,14 +26907,6 @@ function instance$t($$self, $$props, $$invalidate) {
|
|
|
26595
26907
|
*/
|
|
26596
26908
|
function setQuestion(event) {
|
|
26597
26909
|
const inputValue = event.target.value;
|
|
26598
|
-
|
|
26599
|
-
/** ***********************************************************************
|
|
26600
|
-
* SDK INTEGRATION POINT
|
|
26601
|
-
* Summary: SDK callback methods for setting values
|
|
26602
|
-
* ------------------------------------------------------------------------
|
|
26603
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
26604
|
-
* for writing values to the callbacks received from AM
|
|
26605
|
-
*********************************************************************** */
|
|
26606
26910
|
callback.setQuestion(inputValue);
|
|
26607
26911
|
}
|
|
26608
26912
|
|
|
@@ -27093,8 +27397,8 @@ class Eye_icon extends SvelteComponent {
|
|
|
27093
27397
|
|
|
27094
27398
|
function create_default_slot_1$8(ctx) {
|
|
27095
27399
|
let current;
|
|
27096
|
-
const default_slot_template = /*#slots*/ ctx[
|
|
27097
|
-
const default_slot = create_slot(default_slot_template, ctx, /*$$scope*/ ctx[
|
|
27400
|
+
const default_slot_template = /*#slots*/ ctx[15].default;
|
|
27401
|
+
const default_slot = create_slot(default_slot_template, ctx, /*$$scope*/ ctx[16], null);
|
|
27098
27402
|
|
|
27099
27403
|
return {
|
|
27100
27404
|
c() {
|
|
@@ -27109,15 +27413,15 @@ function create_default_slot_1$8(ctx) {
|
|
|
27109
27413
|
},
|
|
27110
27414
|
p(ctx, dirty) {
|
|
27111
27415
|
if (default_slot) {
|
|
27112
|
-
if (default_slot.p && (!current || dirty & /*$$scope*/
|
|
27416
|
+
if (default_slot.p && (!current || dirty & /*$$scope*/ 65536)) {
|
|
27113
27417
|
update_slot_base(
|
|
27114
27418
|
default_slot,
|
|
27115
27419
|
default_slot_template,
|
|
27116
27420
|
ctx,
|
|
27117
|
-
/*$$scope*/ ctx[
|
|
27421
|
+
/*$$scope*/ ctx[16],
|
|
27118
27422
|
!current
|
|
27119
|
-
? get_all_dirty_from_scope(/*$$scope*/ ctx[
|
|
27120
|
-
: get_slot_changes(default_slot_template, /*$$scope*/ ctx[
|
|
27423
|
+
? get_all_dirty_from_scope(/*$$scope*/ ctx[16])
|
|
27424
|
+
: get_slot_changes(default_slot_template, /*$$scope*/ ctx[16], dirty, null),
|
|
27121
27425
|
null
|
|
27122
27426
|
);
|
|
27123
27427
|
}
|
|
@@ -27138,7 +27442,7 @@ function create_default_slot_1$8(ctx) {
|
|
|
27138
27442
|
};
|
|
27139
27443
|
}
|
|
27140
27444
|
|
|
27141
|
-
// (
|
|
27445
|
+
// (69:4) <EyeIcon classes="tw_password-icon dark:tw_password-icon_dark" visible={isVisible}>
|
|
27142
27446
|
function create_default_slot$f(ctx) {
|
|
27143
27447
|
let t;
|
|
27144
27448
|
let current;
|
|
@@ -27168,7 +27472,7 @@ function create_default_slot$f(ctx) {
|
|
|
27168
27472
|
};
|
|
27169
27473
|
}
|
|
27170
27474
|
|
|
27171
|
-
// (
|
|
27475
|
+
// (63:2)
|
|
27172
27476
|
function create_input_button_slot$1(ctx) {
|
|
27173
27477
|
let button;
|
|
27174
27478
|
let eyeicon;
|
|
@@ -27199,7 +27503,7 @@ function create_input_button_slot$1(ctx) {
|
|
|
27199
27503
|
current = true;
|
|
27200
27504
|
|
|
27201
27505
|
if (!mounted) {
|
|
27202
|
-
dispose = listen(button, "click", /*toggleVisibility*/ ctx[
|
|
27506
|
+
dispose = listen(button, "click", /*toggleVisibility*/ ctx[11]);
|
|
27203
27507
|
mounted = true;
|
|
27204
27508
|
}
|
|
27205
27509
|
},
|
|
@@ -27207,7 +27511,7 @@ function create_input_button_slot$1(ctx) {
|
|
|
27207
27511
|
const eyeicon_changes = {};
|
|
27208
27512
|
if (dirty & /*isVisible*/ 64) eyeicon_changes.visible = /*isVisible*/ ctx[6];
|
|
27209
27513
|
|
|
27210
|
-
if (dirty & /*$$scope*/
|
|
27514
|
+
if (dirty & /*$$scope*/ 65536) {
|
|
27211
27515
|
eyeicon_changes.$$scope = { dirty, ctx };
|
|
27212
27516
|
}
|
|
27213
27517
|
|
|
@@ -27235,23 +27539,21 @@ function create_fragment$q(ctx) {
|
|
|
27235
27539
|
let input;
|
|
27236
27540
|
let current;
|
|
27237
27541
|
|
|
27238
|
-
input = new /*Input*/ ctx[
|
|
27542
|
+
input = new /*Input*/ ctx[9]({
|
|
27239
27543
|
props: {
|
|
27240
27544
|
forceValidityFailure: /*forceValidityFailure*/ ctx[0],
|
|
27241
27545
|
isFirstInvalidInput: false,
|
|
27242
27546
|
hasRightIcon: true,
|
|
27243
|
-
key: `${/*key*/ ctx[
|
|
27547
|
+
key: `${/*key*/ ctx[3]}-confirm`,
|
|
27244
27548
|
label: interpolate('confirmPassword', null, 'Confirm Password'),
|
|
27245
|
-
message: /*
|
|
27246
|
-
|
|
27247
|
-
:
|
|
27248
|
-
|
|
27249
|
-
|
|
27250
|
-
isRequired: /*isRequired*/ ctx[4],
|
|
27251
|
-
showMessage: /*showMessage*/ ctx[5],
|
|
27549
|
+
message: /*message*/ ctx[8],
|
|
27550
|
+
onChange: /*onChangeWrapper*/ ctx[10],
|
|
27551
|
+
isInvalid: /*passwordsDoNotMatch*/ ctx[1],
|
|
27552
|
+
isRequired: /*isRequired*/ ctx[2],
|
|
27553
|
+
showMessage: /*showMessage*/ ctx[4],
|
|
27252
27554
|
type: /*type*/ ctx[7],
|
|
27253
|
-
value: typeof /*value*/ ctx[
|
|
27254
|
-
? /*value*/ ctx[
|
|
27555
|
+
value: typeof /*value*/ ctx[5] === 'string'
|
|
27556
|
+
? /*value*/ ctx[5]
|
|
27255
27557
|
: '',
|
|
27256
27558
|
$$slots: {
|
|
27257
27559
|
"input-button": [create_input_button_slot$1],
|
|
@@ -27272,19 +27574,18 @@ function create_fragment$q(ctx) {
|
|
|
27272
27574
|
p(ctx, [dirty]) {
|
|
27273
27575
|
const input_changes = {};
|
|
27274
27576
|
if (dirty & /*forceValidityFailure*/ 1) input_changes.forceValidityFailure = /*forceValidityFailure*/ ctx[0];
|
|
27275
|
-
if (dirty & /*key*/
|
|
27276
|
-
|
|
27277
|
-
if (dirty & /*
|
|
27278
|
-
|
|
27279
|
-
|
|
27280
|
-
|
|
27281
|
-
if (dirty & /*onChange*/ 4) input_changes.onChange = /*onChange*/ ctx[2];
|
|
27282
|
-
if (dirty & /*isInvalid*/ 8) input_changes.isInvalid = /*isInvalid*/ ctx[3];
|
|
27283
|
-
if (dirty & /*isRequired*/ 16) input_changes.isRequired = /*isRequired*/ ctx[4];
|
|
27284
|
-
if (dirty & /*showMessage*/ 32) input_changes.showMessage = /*showMessage*/ ctx[5];
|
|
27577
|
+
if (dirty & /*key*/ 8) input_changes.key = `${/*key*/ ctx[3]}-confirm`;
|
|
27578
|
+
if (dirty & /*message*/ 256) input_changes.message = /*message*/ ctx[8];
|
|
27579
|
+
if (dirty & /*passwordsDoNotMatch*/ 2) input_changes.isInvalid = /*passwordsDoNotMatch*/ ctx[1];
|
|
27580
|
+
if (dirty & /*isRequired*/ 4) input_changes.isRequired = /*isRequired*/ ctx[2];
|
|
27581
|
+
if (dirty & /*showMessage*/ 16) input_changes.showMessage = /*showMessage*/ ctx[4];
|
|
27285
27582
|
if (dirty & /*type*/ 128) input_changes.type = /*type*/ ctx[7];
|
|
27286
27583
|
|
|
27287
|
-
if (dirty &
|
|
27584
|
+
if (dirty & /*value*/ 32) input_changes.value = typeof /*value*/ ctx[5] === 'string'
|
|
27585
|
+
? /*value*/ ctx[5]
|
|
27586
|
+
: '';
|
|
27587
|
+
|
|
27588
|
+
if (dirty & /*$$scope, isVisible*/ 65600) {
|
|
27288
27589
|
input_changes.$$scope = { dirty, ctx };
|
|
27289
27590
|
}
|
|
27290
27591
|
|
|
@@ -27308,16 +27609,25 @@ function create_fragment$q(ctx) {
|
|
|
27308
27609
|
function instance$q($$self, $$props, $$invalidate) {
|
|
27309
27610
|
let { $$slots: slots = {}, $$scope } = $$props;
|
|
27310
27611
|
let { forceValidityFailure = false } = $$props;
|
|
27612
|
+
let { passwordsDoNotMatch = false } = $$props;
|
|
27613
|
+
let { isRequired = false } = $$props;
|
|
27311
27614
|
let { key } = $$props;
|
|
27312
27615
|
let { onChange } = $$props;
|
|
27313
|
-
let {
|
|
27314
|
-
let { isRequired = true } = $$props;
|
|
27616
|
+
let { resetValue } = $$props;
|
|
27315
27617
|
let { style = {} } = $$props;
|
|
27316
27618
|
const Input = style.labels === 'stacked' ? Stacked_label : Floating_label;
|
|
27317
27619
|
let { showMessage = undefined } = $$props;
|
|
27318
27620
|
let isVisible = false;
|
|
27319
27621
|
let type = 'password';
|
|
27320
27622
|
let value;
|
|
27623
|
+
let message = '';
|
|
27624
|
+
|
|
27625
|
+
function onChangeWrapper(event) {
|
|
27626
|
+
$$invalidate(5, value = event.target?.value);
|
|
27627
|
+
|
|
27628
|
+
// TODO: revisit this logic to avoid unnecessary ternary
|
|
27629
|
+
onChange(typeof value === 'string' ? value : undefined);
|
|
27630
|
+
}
|
|
27321
27631
|
|
|
27322
27632
|
/**
|
|
27323
27633
|
* @function toggleVisibility - toggles the password from masked to plaintext
|
|
@@ -27329,27 +27639,50 @@ function instance$q($$self, $$props, $$invalidate) {
|
|
|
27329
27639
|
|
|
27330
27640
|
$$self.$$set = $$props => {
|
|
27331
27641
|
if ('forceValidityFailure' in $$props) $$invalidate(0, forceValidityFailure = $$props.forceValidityFailure);
|
|
27332
|
-
if ('
|
|
27333
|
-
if ('
|
|
27334
|
-
if ('
|
|
27335
|
-
if ('
|
|
27336
|
-
if ('
|
|
27337
|
-
if ('
|
|
27338
|
-
if ('
|
|
27642
|
+
if ('passwordsDoNotMatch' in $$props) $$invalidate(1, passwordsDoNotMatch = $$props.passwordsDoNotMatch);
|
|
27643
|
+
if ('isRequired' in $$props) $$invalidate(2, isRequired = $$props.isRequired);
|
|
27644
|
+
if ('key' in $$props) $$invalidate(3, key = $$props.key);
|
|
27645
|
+
if ('onChange' in $$props) $$invalidate(12, onChange = $$props.onChange);
|
|
27646
|
+
if ('resetValue' in $$props) $$invalidate(13, resetValue = $$props.resetValue);
|
|
27647
|
+
if ('style' in $$props) $$invalidate(14, style = $$props.style);
|
|
27648
|
+
if ('showMessage' in $$props) $$invalidate(4, showMessage = $$props.showMessage);
|
|
27649
|
+
if ('$$scope' in $$props) $$invalidate(16, $$scope = $$props.$$scope);
|
|
27650
|
+
};
|
|
27651
|
+
|
|
27652
|
+
$$self.$$.update = () => {
|
|
27653
|
+
if ($$self.$$.dirty & /*resetValue, onChange, value, passwordsDoNotMatch, isRequired*/ 12326) {
|
|
27654
|
+
{
|
|
27655
|
+
if (resetValue) {
|
|
27656
|
+
$$invalidate(5, value = undefined);
|
|
27657
|
+
onChange(value);
|
|
27658
|
+
}
|
|
27659
|
+
|
|
27660
|
+
if (passwordsDoNotMatch) {
|
|
27661
|
+
$$invalidate(8, message = interpolate('passwordConfirmationError', null, 'Passwords do not match'));
|
|
27662
|
+
} else if (isRequired) {
|
|
27663
|
+
$$invalidate(8, message = interpolate('requiredField', null, 'This field is required'));
|
|
27664
|
+
} else {
|
|
27665
|
+
$$invalidate(8, message = '');
|
|
27666
|
+
}
|
|
27667
|
+
}
|
|
27668
|
+
}
|
|
27339
27669
|
};
|
|
27340
27670
|
|
|
27341
27671
|
return [
|
|
27342
27672
|
forceValidityFailure,
|
|
27343
|
-
|
|
27344
|
-
onChange,
|
|
27345
|
-
isInvalid,
|
|
27673
|
+
passwordsDoNotMatch,
|
|
27346
27674
|
isRequired,
|
|
27675
|
+
key,
|
|
27347
27676
|
showMessage,
|
|
27677
|
+
value,
|
|
27348
27678
|
isVisible,
|
|
27349
27679
|
type,
|
|
27680
|
+
message,
|
|
27350
27681
|
Input,
|
|
27351
|
-
|
|
27682
|
+
onChangeWrapper,
|
|
27352
27683
|
toggleVisibility,
|
|
27684
|
+
onChange,
|
|
27685
|
+
resetValue,
|
|
27353
27686
|
style,
|
|
27354
27687
|
slots,
|
|
27355
27688
|
$$scope
|
|
@@ -27362,12 +27695,13 @@ class Confirm_input extends SvelteComponent {
|
|
|
27362
27695
|
|
|
27363
27696
|
init(this, options, instance$q, create_fragment$q, safe_not_equal, {
|
|
27364
27697
|
forceValidityFailure: 0,
|
|
27365
|
-
|
|
27366
|
-
|
|
27367
|
-
|
|
27368
|
-
|
|
27369
|
-
|
|
27370
|
-
|
|
27698
|
+
passwordsDoNotMatch: 1,
|
|
27699
|
+
isRequired: 2,
|
|
27700
|
+
key: 3,
|
|
27701
|
+
onChange: 12,
|
|
27702
|
+
resetValue: 13,
|
|
27703
|
+
style: 14,
|
|
27704
|
+
showMessage: 4
|
|
27371
27705
|
});
|
|
27372
27706
|
}
|
|
27373
27707
|
}
|
|
@@ -27376,8 +27710,8 @@ class Confirm_input extends SvelteComponent {
|
|
|
27376
27710
|
|
|
27377
27711
|
function create_default_slot_1$7(ctx) {
|
|
27378
27712
|
let current;
|
|
27379
|
-
const default_slot_template = /*#slots*/ ctx[
|
|
27380
|
-
const default_slot = create_slot(default_slot_template, ctx, /*$$scope*/ ctx[
|
|
27713
|
+
const default_slot_template = /*#slots*/ ctx[21].default;
|
|
27714
|
+
const default_slot = create_slot(default_slot_template, ctx, /*$$scope*/ ctx[22], null);
|
|
27381
27715
|
|
|
27382
27716
|
return {
|
|
27383
27717
|
c() {
|
|
@@ -27392,15 +27726,15 @@ function create_default_slot_1$7(ctx) {
|
|
|
27392
27726
|
},
|
|
27393
27727
|
p(ctx, dirty) {
|
|
27394
27728
|
if (default_slot) {
|
|
27395
|
-
if (default_slot.p && (!current || dirty & /*$$scope*/
|
|
27729
|
+
if (default_slot.p && (!current || dirty & /*$$scope*/ 4194304)) {
|
|
27396
27730
|
update_slot_base(
|
|
27397
27731
|
default_slot,
|
|
27398
27732
|
default_slot_template,
|
|
27399
27733
|
ctx,
|
|
27400
|
-
/*$$scope*/ ctx[
|
|
27734
|
+
/*$$scope*/ ctx[22],
|
|
27401
27735
|
!current
|
|
27402
|
-
? get_all_dirty_from_scope(/*$$scope*/ ctx[
|
|
27403
|
-
: get_slot_changes(default_slot_template, /*$$scope*/ ctx[
|
|
27736
|
+
? get_all_dirty_from_scope(/*$$scope*/ ctx[22])
|
|
27737
|
+
: get_slot_changes(default_slot_template, /*$$scope*/ ctx[22], dirty, null),
|
|
27404
27738
|
null
|
|
27405
27739
|
);
|
|
27406
27740
|
}
|
|
@@ -27421,7 +27755,7 @@ function create_default_slot_1$7(ctx) {
|
|
|
27421
27755
|
};
|
|
27422
27756
|
}
|
|
27423
27757
|
|
|
27424
|
-
// (
|
|
27758
|
+
// (94:4) <EyeIcon classes="tw_password-icon dark:tw_password-icon_dark" visible={isVisible}>
|
|
27425
27759
|
function create_default_slot$e(ctx) {
|
|
27426
27760
|
let t;
|
|
27427
27761
|
let current;
|
|
@@ -27451,7 +27785,7 @@ function create_default_slot$e(ctx) {
|
|
|
27451
27785
|
};
|
|
27452
27786
|
}
|
|
27453
27787
|
|
|
27454
|
-
// (
|
|
27788
|
+
// (88:2)
|
|
27455
27789
|
function create_input_button_slot(ctx) {
|
|
27456
27790
|
let button;
|
|
27457
27791
|
let eyeicon;
|
|
@@ -27482,7 +27816,7 @@ function create_input_button_slot(ctx) {
|
|
|
27482
27816
|
current = true;
|
|
27483
27817
|
|
|
27484
27818
|
if (!mounted) {
|
|
27485
|
-
dispose = listen(button, "click", /*toggleVisibility*/ ctx[
|
|
27819
|
+
dispose = listen(button, "click", /*toggleVisibility*/ ctx[17]);
|
|
27486
27820
|
mounted = true;
|
|
27487
27821
|
}
|
|
27488
27822
|
},
|
|
@@ -27490,7 +27824,7 @@ function create_input_button_slot(ctx) {
|
|
|
27490
27824
|
const eyeicon_changes = {};
|
|
27491
27825
|
if (dirty & /*isVisible*/ 1024) eyeicon_changes.visible = /*isVisible*/ ctx[10];
|
|
27492
27826
|
|
|
27493
|
-
if (dirty & /*$$scope*/
|
|
27827
|
+
if (dirty & /*$$scope*/ 4194304) {
|
|
27494
27828
|
eyeicon_changes.$$scope = { dirty, ctx };
|
|
27495
27829
|
}
|
|
27496
27830
|
|
|
@@ -27514,7 +27848,7 @@ function create_input_button_slot(ctx) {
|
|
|
27514
27848
|
};
|
|
27515
27849
|
}
|
|
27516
27850
|
|
|
27517
|
-
// (
|
|
27851
|
+
// (101:0) {#if callbackMetadata?.platform?.confirmPassword}
|
|
27518
27852
|
function create_if_block$a(ctx) {
|
|
27519
27853
|
let confirminput;
|
|
27520
27854
|
let current;
|
|
@@ -27522,9 +27856,11 @@ function create_if_block$a(ctx) {
|
|
|
27522
27856
|
confirminput = new Confirm_input({
|
|
27523
27857
|
props: {
|
|
27524
27858
|
forceValidityFailure: /*doPasswordsMatch*/ ctx[9] === false,
|
|
27525
|
-
|
|
27859
|
+
passwordsDoNotMatch: /*doPasswordsMatch*/ ctx[9] === false,
|
|
27526
27860
|
key: /*key*/ ctx[0],
|
|
27527
|
-
|
|
27861
|
+
isRequired: /*value*/ ctx[7].length > 0,
|
|
27862
|
+
onChange: /*confirmInput*/ ctx[15],
|
|
27863
|
+
resetValue: /*resetValue*/ ctx[11],
|
|
27528
27864
|
showMessage: /*doPasswordsMatch*/ ctx[9] === false,
|
|
27529
27865
|
style: /*style*/ ctx[4]
|
|
27530
27866
|
}
|
|
@@ -27541,8 +27877,10 @@ function create_if_block$a(ctx) {
|
|
|
27541
27877
|
p(ctx, dirty) {
|
|
27542
27878
|
const confirminput_changes = {};
|
|
27543
27879
|
if (dirty & /*doPasswordsMatch*/ 512) confirminput_changes.forceValidityFailure = /*doPasswordsMatch*/ ctx[9] === false;
|
|
27544
|
-
if (dirty & /*doPasswordsMatch*/ 512) confirminput_changes.
|
|
27880
|
+
if (dirty & /*doPasswordsMatch*/ 512) confirminput_changes.passwordsDoNotMatch = /*doPasswordsMatch*/ ctx[9] === false;
|
|
27545
27881
|
if (dirty & /*key*/ 1) confirminput_changes.key = /*key*/ ctx[0];
|
|
27882
|
+
if (dirty & /*value*/ 128) confirminput_changes.isRequired = /*value*/ ctx[7].length > 0;
|
|
27883
|
+
if (dirty & /*resetValue*/ 2048) confirminput_changes.resetValue = /*resetValue*/ ctx[11];
|
|
27546
27884
|
if (dirty & /*doPasswordsMatch*/ 512) confirminput_changes.showMessage = /*doPasswordsMatch*/ ctx[9] === false;
|
|
27547
27885
|
if (dirty & /*style*/ 16) confirminput_changes.style = /*style*/ ctx[4];
|
|
27548
27886
|
confirminput.$set(confirminput_changes);
|
|
@@ -27568,20 +27906,20 @@ function create_fragment$p(ctx) {
|
|
|
27568
27906
|
let if_block_anchor;
|
|
27569
27907
|
let current;
|
|
27570
27908
|
|
|
27571
|
-
input = new /*Input*/ ctx[
|
|
27909
|
+
input = new /*Input*/ ctx[14]({
|
|
27572
27910
|
props: {
|
|
27573
27911
|
isFirstInvalidInput: /*callbackMetadata*/ ctx[1]?.derived.isFirstInvalidInput || false,
|
|
27574
27912
|
hasRightIcon: true,
|
|
27575
27913
|
key: /*key*/ ctx[0],
|
|
27576
|
-
label: interpolate(textToKey(/*callbackType*/ ctx[8]), null, /*textInputLabel*/ ctx[
|
|
27914
|
+
label: interpolate(textToKey(/*callbackType*/ ctx[8]), null, /*textInputLabel*/ ctx[12]),
|
|
27577
27915
|
message: /*validationFailure*/ ctx[6] || (/*isRequired*/ ctx[3]
|
|
27578
27916
|
? interpolate('inputRequiredError')
|
|
27579
27917
|
: undefined),
|
|
27580
|
-
onChange: /*setValue*/ ctx[
|
|
27918
|
+
onChange: /*setValue*/ ctx[16],
|
|
27581
27919
|
isInvalid: /*isInvalid*/ ctx[2],
|
|
27582
27920
|
isRequired: /*isRequired*/ ctx[3],
|
|
27583
27921
|
showMessage: /*showMessage*/ ctx[5],
|
|
27584
|
-
type: /*type*/ ctx[
|
|
27922
|
+
type: /*type*/ ctx[13],
|
|
27585
27923
|
value: typeof /*value*/ ctx[7] === 'string'
|
|
27586
27924
|
? /*value*/ ctx[7]
|
|
27587
27925
|
: '',
|
|
@@ -27613,7 +27951,7 @@ function create_fragment$p(ctx) {
|
|
|
27613
27951
|
const input_changes = {};
|
|
27614
27952
|
if (dirty & /*callbackMetadata*/ 2) input_changes.isFirstInvalidInput = /*callbackMetadata*/ ctx[1]?.derived.isFirstInvalidInput || false;
|
|
27615
27953
|
if (dirty & /*key*/ 1) input_changes.key = /*key*/ ctx[0];
|
|
27616
|
-
if (dirty & /*callbackType, textInputLabel*/
|
|
27954
|
+
if (dirty & /*callbackType, textInputLabel*/ 4352) input_changes.label = interpolate(textToKey(/*callbackType*/ ctx[8]), null, /*textInputLabel*/ ctx[12]);
|
|
27617
27955
|
|
|
27618
27956
|
if (dirty & /*validationFailure, isRequired*/ 72) input_changes.message = /*validationFailure*/ ctx[6] || (/*isRequired*/ ctx[3]
|
|
27619
27957
|
? interpolate('inputRequiredError')
|
|
@@ -27622,13 +27960,13 @@ function create_fragment$p(ctx) {
|
|
|
27622
27960
|
if (dirty & /*isInvalid*/ 4) input_changes.isInvalid = /*isInvalid*/ ctx[2];
|
|
27623
27961
|
if (dirty & /*isRequired*/ 8) input_changes.isRequired = /*isRequired*/ ctx[3];
|
|
27624
27962
|
if (dirty & /*showMessage*/ 32) input_changes.showMessage = /*showMessage*/ ctx[5];
|
|
27625
|
-
if (dirty & /*type*/
|
|
27963
|
+
if (dirty & /*type*/ 8192) input_changes.type = /*type*/ ctx[13];
|
|
27626
27964
|
|
|
27627
27965
|
if (dirty & /*value*/ 128) input_changes.value = typeof /*value*/ ctx[7] === 'string'
|
|
27628
27966
|
? /*value*/ ctx[7]
|
|
27629
27967
|
: '';
|
|
27630
27968
|
|
|
27631
|
-
if (dirty & /*$$scope, isVisible*/
|
|
27969
|
+
if (dirty & /*$$scope, isVisible*/ 4195328) {
|
|
27632
27970
|
input_changes.$$scope = { dirty, ctx };
|
|
27633
27971
|
}
|
|
27634
27972
|
|
|
@@ -27692,6 +28030,8 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27692
28030
|
let callbackType;
|
|
27693
28031
|
let doPasswordsMatch;
|
|
27694
28032
|
let isVisible = false;
|
|
28033
|
+
let resetValue = false;
|
|
28034
|
+
let savedValue = '';
|
|
27695
28035
|
let textInputLabel;
|
|
27696
28036
|
let type = 'password';
|
|
27697
28037
|
let value;
|
|
@@ -27700,8 +28040,8 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27700
28040
|
* @function confirmInput - ensures the second password input matches the first
|
|
27701
28041
|
* @param event
|
|
27702
28042
|
*/
|
|
27703
|
-
function confirmInput(
|
|
27704
|
-
$$invalidate(
|
|
28043
|
+
function confirmInput(val) {
|
|
28044
|
+
$$invalidate(19, confirmValue = val);
|
|
27705
28045
|
}
|
|
27706
28046
|
|
|
27707
28047
|
/**
|
|
@@ -27719,6 +28059,8 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27719
28059
|
* for writing values to the callbacks received from AM
|
|
27720
28060
|
*********************************************************************** */
|
|
27721
28061
|
callback.setInputValue(value);
|
|
28062
|
+
|
|
28063
|
+
$$invalidate(20, savedValue = String(value));
|
|
27722
28064
|
}
|
|
27723
28065
|
|
|
27724
28066
|
/**
|
|
@@ -27726,11 +28068,11 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27726
28068
|
*/
|
|
27727
28069
|
function toggleVisibility() {
|
|
27728
28070
|
$$invalidate(10, isVisible = !isVisible);
|
|
27729
|
-
$$invalidate(
|
|
28071
|
+
$$invalidate(13, type = isVisible ? 'text' : 'password');
|
|
27730
28072
|
}
|
|
27731
28073
|
|
|
27732
28074
|
$$self.$$set = $$props => {
|
|
27733
|
-
if ('callback' in $$props) $$invalidate(
|
|
28075
|
+
if ('callback' in $$props) $$invalidate(18, callback = $$props.callback);
|
|
27734
28076
|
if ('callbackMetadata' in $$props) $$invalidate(1, callbackMetadata = $$props.callbackMetadata);
|
|
27735
28077
|
if ('key' in $$props) $$invalidate(0, key = $$props.key);
|
|
27736
28078
|
if ('isInvalid' in $$props) $$invalidate(2, isInvalid = $$props.isInvalid);
|
|
@@ -27738,18 +28080,28 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27738
28080
|
if ('style' in $$props) $$invalidate(4, style = $$props.style);
|
|
27739
28081
|
if ('showMessage' in $$props) $$invalidate(5, showMessage = $$props.showMessage);
|
|
27740
28082
|
if ('validationFailure' in $$props) $$invalidate(6, validationFailure = $$props.validationFailure);
|
|
27741
|
-
if ('$$scope' in $$props) $$invalidate(
|
|
28083
|
+
if ('$$scope' in $$props) $$invalidate(22, $$scope = $$props.$$scope);
|
|
27742
28084
|
};
|
|
27743
28085
|
|
|
27744
28086
|
$$self.$$.update = () => {
|
|
27745
|
-
if ($$self.$$.dirty & /*callback, callbackMetadata,
|
|
28087
|
+
if ($$self.$$.dirty & /*callback, callbackMetadata, savedValue, value, confirmValue*/ 1835138) {
|
|
27746
28088
|
{
|
|
27747
28089
|
$$invalidate(8, callbackType = callback.getType());
|
|
27748
28090
|
$$invalidate(0, key = callback?.payload?.input?.[0].name || `password-${callbackMetadata?.idx}`);
|
|
27749
|
-
$$invalidate(
|
|
28091
|
+
$$invalidate(12, textInputLabel = callback.getPrompt());
|
|
27750
28092
|
$$invalidate(7, value = callback?.getInputValue());
|
|
27751
28093
|
|
|
27752
|
-
|
|
28094
|
+
/**
|
|
28095
|
+
* `savedValue` represents what the user set after blur (local component state)
|
|
28096
|
+
* `value` represents what's in the callback (empties from AM response)
|
|
28097
|
+
*
|
|
28098
|
+
* This unique combination is what produces the most reliable reset flag
|
|
28099
|
+
*/
|
|
28100
|
+
$$invalidate(11, resetValue = !!savedValue && value === '');
|
|
28101
|
+
|
|
28102
|
+
/**
|
|
28103
|
+
* Only assign a boolean if the confirm input has an actual value.
|
|
28104
|
+
*/
|
|
27753
28105
|
$$invalidate(9, doPasswordsMatch = confirmValue !== undefined
|
|
27754
28106
|
? confirmValue === value
|
|
27755
28107
|
: undefined);
|
|
@@ -27769,6 +28121,7 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27769
28121
|
callbackType,
|
|
27770
28122
|
doPasswordsMatch,
|
|
27771
28123
|
isVisible,
|
|
28124
|
+
resetValue,
|
|
27772
28125
|
textInputLabel,
|
|
27773
28126
|
type,
|
|
27774
28127
|
Input,
|
|
@@ -27777,6 +28130,7 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27777
28130
|
toggleVisibility,
|
|
27778
28131
|
callback,
|
|
27779
28132
|
confirmValue,
|
|
28133
|
+
savedValue,
|
|
27780
28134
|
slots,
|
|
27781
28135
|
$$scope
|
|
27782
28136
|
];
|
|
@@ -27787,7 +28141,7 @@ class Base extends SvelteComponent {
|
|
|
27787
28141
|
super();
|
|
27788
28142
|
|
|
27789
28143
|
init(this, options, instance$p, create_fragment$p, safe_not_equal, {
|
|
27790
|
-
callback:
|
|
28144
|
+
callback: 18,
|
|
27791
28145
|
callbackMetadata: 1,
|
|
27792
28146
|
key: 0,
|
|
27793
28147
|
isInvalid: 2,
|
|
@@ -28479,7 +28833,7 @@ function get_each_context$5(ctx, list, i) {
|
|
|
28479
28833
|
}
|
|
28480
28834
|
|
|
28481
28835
|
// (66:56)
|
|
28482
|
-
function create_if_block_3$
|
|
28836
|
+
function create_if_block_3$5(ctx) {
|
|
28483
28837
|
let button;
|
|
28484
28838
|
let current;
|
|
28485
28839
|
|
|
@@ -28823,7 +29177,7 @@ function create_default_slot_1$6(ctx) {
|
|
|
28823
29177
|
let if_block;
|
|
28824
29178
|
let if_block_anchor;
|
|
28825
29179
|
let current;
|
|
28826
|
-
const if_block_creators = [create_if_block_1$7, create_if_block_2$6, create_if_block_3$
|
|
29180
|
+
const if_block_creators = [create_if_block_1$7, create_if_block_2$6, create_if_block_3$5];
|
|
28827
29181
|
const if_blocks = [];
|
|
28828
29182
|
|
|
28829
29183
|
function select_block_type(ctx, dirty) {
|
|
@@ -29214,17 +29568,17 @@ class Select_idp extends SvelteComponent {
|
|
|
29214
29568
|
|
|
29215
29569
|
function get_each_context_1(ctx, list, i) {
|
|
29216
29570
|
const child_ctx = ctx.slice();
|
|
29217
|
-
child_ctx[
|
|
29571
|
+
child_ctx[11] = list[i];
|
|
29218
29572
|
return child_ctx;
|
|
29219
29573
|
}
|
|
29220
29574
|
|
|
29221
29575
|
function get_each_context$4(ctx, list, i) {
|
|
29222
29576
|
const child_ctx = ctx.slice();
|
|
29223
|
-
child_ctx[
|
|
29577
|
+
child_ctx[8] = list[i];
|
|
29224
29578
|
return child_ctx;
|
|
29225
29579
|
}
|
|
29226
29580
|
|
|
29227
|
-
// (
|
|
29581
|
+
// (35:51)
|
|
29228
29582
|
function create_if_block_1$6(ctx) {
|
|
29229
29583
|
let div;
|
|
29230
29584
|
let p;
|
|
@@ -29234,7 +29588,7 @@ function create_if_block_1$6(ctx) {
|
|
|
29234
29588
|
let div_id_value;
|
|
29235
29589
|
let current;
|
|
29236
29590
|
t0 = new Locale_strings({ props: { key: /*messageKey*/ ctx[1] } });
|
|
29237
|
-
let each_value_1 = /*validationRules*/ ctx[
|
|
29591
|
+
let each_value_1 = /*validationRules*/ ctx[3];
|
|
29238
29592
|
let each_blocks = [];
|
|
29239
29593
|
|
|
29240
29594
|
for (let i = 0; i < each_value_1.length; i += 1) {
|
|
@@ -29276,8 +29630,8 @@ function create_if_block_1$6(ctx) {
|
|
|
29276
29630
|
if (dirty & /*messageKey*/ 2) t0_changes.key = /*messageKey*/ ctx[1];
|
|
29277
29631
|
t0.$set(t0_changes);
|
|
29278
29632
|
|
|
29279
|
-
if (dirty & /*validationRules*/
|
|
29280
|
-
each_value_1 = /*validationRules*/ ctx[
|
|
29633
|
+
if (dirty & /*validationRules*/ 8) {
|
|
29634
|
+
each_value_1 = /*validationRules*/ ctx[3];
|
|
29281
29635
|
let i;
|
|
29282
29636
|
|
|
29283
29637
|
for (i = 0; i < each_value_1.length; i += 1) {
|
|
@@ -29320,7 +29674,7 @@ function create_if_block_1$6(ctx) {
|
|
|
29320
29674
|
};
|
|
29321
29675
|
}
|
|
29322
29676
|
|
|
29323
|
-
// (
|
|
29677
|
+
// (24:0) {#if simplifiedFailures.length}
|
|
29324
29678
|
function create_if_block$8(ctx) {
|
|
29325
29679
|
let div;
|
|
29326
29680
|
let p;
|
|
@@ -29330,7 +29684,7 @@ function create_if_block$8(ctx) {
|
|
|
29330
29684
|
let div_id_value;
|
|
29331
29685
|
let current;
|
|
29332
29686
|
t0 = new Locale_strings({ props: { key: /*messageKey*/ ctx[1] } });
|
|
29333
|
-
let each_value = /*simplifiedFailures*/ ctx[
|
|
29687
|
+
let each_value = /*simplifiedFailures*/ ctx[4];
|
|
29334
29688
|
let each_blocks = [];
|
|
29335
29689
|
|
|
29336
29690
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -29372,8 +29726,8 @@ function create_if_block$8(ctx) {
|
|
|
29372
29726
|
if (dirty & /*messageKey*/ 2) t0_changes.key = /*messageKey*/ ctx[1];
|
|
29373
29727
|
t0.$set(t0_changes);
|
|
29374
29728
|
|
|
29375
|
-
if (dirty & /*simplifiedFailures*/
|
|
29376
|
-
each_value = /*simplifiedFailures*/ ctx[
|
|
29729
|
+
if (dirty & /*simplifiedFailures*/ 16) {
|
|
29730
|
+
each_value = /*simplifiedFailures*/ ctx[4];
|
|
29377
29731
|
let i;
|
|
29378
29732
|
|
|
29379
29733
|
for (i = 0; i < each_value.length; i += 1) {
|
|
@@ -29416,10 +29770,10 @@ function create_if_block$8(ctx) {
|
|
|
29416
29770
|
};
|
|
29417
29771
|
}
|
|
29418
29772
|
|
|
29419
|
-
// (
|
|
29773
|
+
// (41:6) {#each validationRules as rule}
|
|
29420
29774
|
function create_each_block_1(ctx) {
|
|
29421
29775
|
let li;
|
|
29422
|
-
let t_value = /*rule*/ ctx[
|
|
29776
|
+
let t_value = /*rule*/ ctx[11].message + "";
|
|
29423
29777
|
let t;
|
|
29424
29778
|
|
|
29425
29779
|
return {
|
|
@@ -29433,7 +29787,7 @@ function create_each_block_1(ctx) {
|
|
|
29433
29787
|
append(li, t);
|
|
29434
29788
|
},
|
|
29435
29789
|
p(ctx, dirty) {
|
|
29436
|
-
if (dirty & /*validationRules*/
|
|
29790
|
+
if (dirty & /*validationRules*/ 8 && t_value !== (t_value = /*rule*/ ctx[11].message + "")) set_data(t, t_value);
|
|
29437
29791
|
},
|
|
29438
29792
|
d(detaching) {
|
|
29439
29793
|
if (detaching) detach(li);
|
|
@@ -29441,10 +29795,10 @@ function create_each_block_1(ctx) {
|
|
|
29441
29795
|
};
|
|
29442
29796
|
}
|
|
29443
29797
|
|
|
29444
|
-
// (
|
|
29798
|
+
// (30:6) {#each simplifiedFailures as failure}
|
|
29445
29799
|
function create_each_block$4(ctx) {
|
|
29446
29800
|
let li;
|
|
29447
|
-
let t_value = /*failure*/ ctx[
|
|
29801
|
+
let t_value = /*failure*/ ctx[8].message + "";
|
|
29448
29802
|
let t;
|
|
29449
29803
|
|
|
29450
29804
|
return {
|
|
@@ -29458,7 +29812,7 @@ function create_each_block$4(ctx) {
|
|
|
29458
29812
|
append(li, t);
|
|
29459
29813
|
},
|
|
29460
29814
|
p(ctx, dirty) {
|
|
29461
|
-
if (dirty & /*simplifiedFailures*/
|
|
29815
|
+
if (dirty & /*simplifiedFailures*/ 16 && t_value !== (t_value = /*failure*/ ctx[8].message + "")) set_data(t, t_value);
|
|
29462
29816
|
},
|
|
29463
29817
|
d(detaching) {
|
|
29464
29818
|
if (detaching) detach(li);
|
|
@@ -29475,8 +29829,8 @@ function create_fragment$g(ctx) {
|
|
|
29475
29829
|
const if_blocks = [];
|
|
29476
29830
|
|
|
29477
29831
|
function select_block_type(ctx, dirty) {
|
|
29478
|
-
if (/*simplifiedFailures*/ ctx[
|
|
29479
|
-
if (/*
|
|
29832
|
+
if (/*simplifiedFailures*/ ctx[4].length) return 0;
|
|
29833
|
+
if (/*showPolicies*/ ctx[2] && /*validationRules*/ ctx[3].length) return 1;
|
|
29480
29834
|
return -1;
|
|
29481
29835
|
}
|
|
29482
29836
|
|
|
@@ -29557,6 +29911,7 @@ function instance$g($$self, $$props, $$invalidate) {
|
|
|
29557
29911
|
let { key = undefined } = $$props;
|
|
29558
29912
|
let { label } = $$props;
|
|
29559
29913
|
let { messageKey } = $$props;
|
|
29914
|
+
let { showPolicies = false } = $$props;
|
|
29560
29915
|
let validationFailures = getValidationFailures(callback, label);
|
|
29561
29916
|
let validationRules = getValidationPolicies(callback.getPolicies());
|
|
29562
29917
|
|
|
@@ -29569,19 +29924,20 @@ function instance$g($$self, $$props, $$invalidate) {
|
|
|
29569
29924
|
);
|
|
29570
29925
|
|
|
29571
29926
|
$$self.$$set = $$props => {
|
|
29572
|
-
if ('callback' in $$props) $$invalidate(
|
|
29927
|
+
if ('callback' in $$props) $$invalidate(5, callback = $$props.callback);
|
|
29573
29928
|
if ('key' in $$props) $$invalidate(0, key = $$props.key);
|
|
29574
|
-
if ('label' in $$props) $$invalidate(
|
|
29929
|
+
if ('label' in $$props) $$invalidate(6, label = $$props.label);
|
|
29575
29930
|
if ('messageKey' in $$props) $$invalidate(1, messageKey = $$props.messageKey);
|
|
29931
|
+
if ('showPolicies' in $$props) $$invalidate(2, showPolicies = $$props.showPolicies);
|
|
29576
29932
|
};
|
|
29577
29933
|
|
|
29578
29934
|
$$self.$$.update = () => {
|
|
29579
|
-
if ($$self.$$.dirty & /*callback, label, validationFailures*/
|
|
29935
|
+
if ($$self.$$.dirty & /*callback, label, validationFailures*/ 224) {
|
|
29580
29936
|
{
|
|
29581
|
-
$$invalidate(
|
|
29582
|
-
$$invalidate(
|
|
29937
|
+
$$invalidate(7, validationFailures = getValidationFailures(callback, label));
|
|
29938
|
+
$$invalidate(3, validationRules = getValidationPolicies(callback.getPolicies()));
|
|
29583
29939
|
|
|
29584
|
-
$$invalidate(
|
|
29940
|
+
$$invalidate(4, simplifiedFailures = validationFailures.reduce(
|
|
29585
29941
|
(prev, curr) => {
|
|
29586
29942
|
prev = prev.concat(curr.restructured);
|
|
29587
29943
|
return prev;
|
|
@@ -29595,6 +29951,7 @@ function instance$g($$self, $$props, $$invalidate) {
|
|
|
29595
29951
|
return [
|
|
29596
29952
|
key,
|
|
29597
29953
|
messageKey,
|
|
29954
|
+
showPolicies,
|
|
29598
29955
|
validationRules,
|
|
29599
29956
|
simplifiedFailures,
|
|
29600
29957
|
callback,
|
|
@@ -29608,10 +29965,11 @@ class Policies extends SvelteComponent {
|
|
|
29608
29965
|
super();
|
|
29609
29966
|
|
|
29610
29967
|
init(this, options, instance$g, create_fragment$g, safe_not_equal, {
|
|
29611
|
-
callback:
|
|
29968
|
+
callback: 5,
|
|
29612
29969
|
key: 0,
|
|
29613
|
-
label:
|
|
29614
|
-
messageKey: 1
|
|
29970
|
+
label: 6,
|
|
29971
|
+
messageKey: 1,
|
|
29972
|
+
showPolicies: 2
|
|
29615
29973
|
});
|
|
29616
29974
|
}
|
|
29617
29975
|
}
|
|
@@ -29751,13 +30109,6 @@ function instance$f($$self, $$props, $$invalidate) {
|
|
|
29751
30109
|
* @param {Object} event
|
|
29752
30110
|
*/
|
|
29753
30111
|
function setValue(event) {
|
|
29754
|
-
/** ***********************************************************************
|
|
29755
|
-
* SDK INTEGRATION POINT
|
|
29756
|
-
* Summary: SDK callback methods for setting values
|
|
29757
|
-
* ------------------------------------------------------------------------
|
|
29758
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
29759
|
-
* for writing values to the callbacks received from AM
|
|
29760
|
-
*********************************************************************** */
|
|
29761
30112
|
callback.setInputValue(event.target.value);
|
|
29762
30113
|
}
|
|
29763
30114
|
|
|
@@ -29946,7 +30297,7 @@ function create_else_block$3(ctx) {
|
|
|
29946
30297
|
};
|
|
29947
30298
|
}
|
|
29948
30299
|
|
|
29949
|
-
// (
|
|
30300
|
+
// (27:0) {#if $linksStore?.termsAndConditions}
|
|
29950
30301
|
function create_if_block$7(ctx) {
|
|
29951
30302
|
let link;
|
|
29952
30303
|
let t;
|
|
@@ -30024,7 +30375,7 @@ function create_if_block$7(ctx) {
|
|
|
30024
30375
|
};
|
|
30025
30376
|
}
|
|
30026
30377
|
|
|
30027
|
-
// (
|
|
30378
|
+
// (28:2) <Link classes="tw_block tw_mb-4" href={$linksStore?.termsAndConditions} target="_blank">
|
|
30028
30379
|
function create_default_slot_1$5(ctx) {
|
|
30029
30380
|
let t_value = interpolate('termsAndConditionsLinkText') + "";
|
|
30030
30381
|
let t;
|
|
@@ -30043,7 +30394,7 @@ function create_default_slot_1$5(ctx) {
|
|
|
30043
30394
|
};
|
|
30044
30395
|
}
|
|
30045
30396
|
|
|
30046
|
-
// (
|
|
30397
|
+
// (31:2) <Checkbox isFirstInvalidInput={callbackMetadata?.derived.isFirstInvalidInput || false} key={inputName} onChange={setValue} value={false} >
|
|
30047
30398
|
function create_default_slot$9(ctx) {
|
|
30048
30399
|
let t;
|
|
30049
30400
|
let current;
|
|
@@ -30151,13 +30502,6 @@ function instance$d($$self, $$props, $$invalidate) {
|
|
|
30151
30502
|
let { callback } = $$props;
|
|
30152
30503
|
let { callbackMetadata } = $$props;
|
|
30153
30504
|
|
|
30154
|
-
/** *************************************************************************
|
|
30155
|
-
* SDK INTEGRATION POINT
|
|
30156
|
-
* Summary: SDK callback methods for getting values
|
|
30157
|
-
* --------------------------------------------------------------------------
|
|
30158
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
30159
|
-
* for accessing values from the callbacks received from AM
|
|
30160
|
-
************************************************************************* */
|
|
30161
30505
|
const Checkbox = style.checksAndRadios === 'standard'
|
|
30162
30506
|
? Standard$1
|
|
30163
30507
|
: Animated$1;
|
|
@@ -30169,13 +30513,6 @@ function instance$d($$self, $$props, $$invalidate) {
|
|
|
30169
30513
|
* @param {Object} event
|
|
30170
30514
|
*/
|
|
30171
30515
|
function setValue(event) {
|
|
30172
|
-
/** ***********************************************************************
|
|
30173
|
-
* SDK INTEGRATION POINT
|
|
30174
|
-
* Summary: SDK callback methods for setting values
|
|
30175
|
-
* ------------------------------------------------------------------------
|
|
30176
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
30177
|
-
* for writing values to the callbacks received from AM
|
|
30178
|
-
*********************************************************************** */
|
|
30179
30516
|
callback.setAccepted(event.target.checked);
|
|
30180
30517
|
}
|
|
30181
30518
|
|
|
@@ -30439,7 +30776,8 @@ function create_default_slot$7(ctx) {
|
|
|
30439
30776
|
props: {
|
|
30440
30777
|
callback: /*callback*/ ctx[0],
|
|
30441
30778
|
label: /*prompt*/ ctx[3],
|
|
30442
|
-
messageKey: "passwordRequirements"
|
|
30779
|
+
messageKey: "passwordRequirements",
|
|
30780
|
+
showPolicies: true
|
|
30443
30781
|
}
|
|
30444
30782
|
});
|
|
30445
30783
|
|
|
@@ -30733,13 +31071,6 @@ function instance$9($$self, $$props, $$invalidate) {
|
|
|
30733
31071
|
* @param {Object} event
|
|
30734
31072
|
*/
|
|
30735
31073
|
function setValue(event) {
|
|
30736
|
-
/** ***********************************************************************
|
|
30737
|
-
* SDK INTEGRATION POINT
|
|
30738
|
-
* Summary: SDK callback methods for setting values
|
|
30739
|
-
* ------------------------------------------------------------------------
|
|
30740
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
30741
|
-
* for writing values to the callbacks received from AM
|
|
30742
|
-
*********************************************************************** */
|
|
30743
31074
|
callback.setInputValue(event.target.value);
|
|
30744
31075
|
}
|
|
30745
31076
|
|
|
@@ -31526,7 +31857,7 @@ function create_if_block_5(ctx) {
|
|
|
31526
31857
|
}
|
|
31527
31858
|
|
|
31528
31859
|
// (126:52)
|
|
31529
|
-
function create_if_block_4(ctx) {
|
|
31860
|
+
function create_if_block_4$1(ctx) {
|
|
31530
31861
|
let kbacreate;
|
|
31531
31862
|
let current;
|
|
31532
31863
|
const kbacreate_spread_levels = [/*newProps*/ ctx[19]];
|
|
@@ -31569,7 +31900,7 @@ function create_if_block_4(ctx) {
|
|
|
31569
31900
|
}
|
|
31570
31901
|
|
|
31571
31902
|
// (120:54)
|
|
31572
|
-
function create_if_block_3$
|
|
31903
|
+
function create_if_block_3$4(ctx) {
|
|
31573
31904
|
let hiddenvalue;
|
|
31574
31905
|
let current;
|
|
31575
31906
|
const hiddenvalue_spread_levels = [/*newProps*/ ctx[19]];
|
|
@@ -31750,8 +32081,8 @@ function create_fragment$8(ctx) {
|
|
|
31750
32081
|
create_if_block$6,
|
|
31751
32082
|
create_if_block_1$5,
|
|
31752
32083
|
create_if_block_2$5,
|
|
31753
|
-
create_if_block_3$
|
|
31754
|
-
create_if_block_4,
|
|
32084
|
+
create_if_block_3$4,
|
|
32085
|
+
create_if_block_4$1,
|
|
31755
32086
|
create_if_block_5,
|
|
31756
32087
|
create_if_block_6,
|
|
31757
32088
|
create_if_block_7,
|
|
@@ -31984,12 +32315,12 @@ class Callback_mapper extends SvelteComponent {
|
|
|
31984
32315
|
|
|
31985
32316
|
function get_each_context$3(ctx, list, i) {
|
|
31986
32317
|
const child_ctx = ctx.slice();
|
|
31987
|
-
child_ctx[
|
|
31988
|
-
child_ctx[
|
|
32318
|
+
child_ctx[16] = list[i];
|
|
32319
|
+
child_ctx[18] = i;
|
|
31989
32320
|
return child_ctx;
|
|
31990
32321
|
}
|
|
31991
32322
|
|
|
31992
|
-
// (70:2) {#if form?.icon}
|
|
32323
|
+
// (70:2) {#if form?.icon && componentStyle !== 'inline'}
|
|
31993
32324
|
function create_if_block_2$4(ctx) {
|
|
31994
32325
|
let div;
|
|
31995
32326
|
let shieldicon;
|
|
@@ -32037,7 +32368,7 @@ function create_if_block_1$4(ctx) {
|
|
|
32037
32368
|
alert = new Alert({
|
|
32038
32369
|
props: {
|
|
32039
32370
|
id: formFailureMessageId,
|
|
32040
|
-
needsFocus: /*alertNeedsFocus*/ ctx[
|
|
32371
|
+
needsFocus: /*alertNeedsFocus*/ ctx[6],
|
|
32041
32372
|
type: "error",
|
|
32042
32373
|
$$slots: { default: [create_default_slot_2$3] },
|
|
32043
32374
|
$$scope: { ctx }
|
|
@@ -32054,9 +32385,9 @@ function create_if_block_1$4(ctx) {
|
|
|
32054
32385
|
},
|
|
32055
32386
|
p(ctx, dirty) {
|
|
32056
32387
|
const alert_changes = {};
|
|
32057
|
-
if (dirty & /*alertNeedsFocus*/
|
|
32388
|
+
if (dirty & /*alertNeedsFocus*/ 64) alert_changes.needsFocus = /*alertNeedsFocus*/ ctx[6];
|
|
32058
32389
|
|
|
32059
|
-
if (dirty & /*$$scope, formMessageKey, form*/
|
|
32390
|
+
if (dirty & /*$$scope, formMessageKey, form*/ 524420) {
|
|
32060
32391
|
alert_changes.$$scope = { dirty, ctx };
|
|
32061
32392
|
}
|
|
32062
32393
|
|
|
@@ -32079,7 +32410,7 @@ function create_if_block_1$4(ctx) {
|
|
|
32079
32410
|
|
|
32080
32411
|
// (87:4) <Alert id={formFailureMessageId} needsFocus={alertNeedsFocus} type="error">
|
|
32081
32412
|
function create_default_slot_2$3(ctx) {
|
|
32082
|
-
let t_value = interpolate(/*formMessageKey*/ ctx[
|
|
32413
|
+
let t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "";
|
|
32083
32414
|
let t;
|
|
32084
32415
|
|
|
32085
32416
|
return {
|
|
@@ -32090,7 +32421,7 @@ function create_default_slot_2$3(ctx) {
|
|
|
32090
32421
|
insert(target, t, anchor);
|
|
32091
32422
|
},
|
|
32092
32423
|
p(ctx, dirty) {
|
|
32093
|
-
if (dirty & /*formMessageKey, form*/
|
|
32424
|
+
if (dirty & /*formMessageKey, form*/ 132 && t_value !== (t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "")) set_data(t, t_value);
|
|
32094
32425
|
},
|
|
32095
32426
|
d(detaching) {
|
|
32096
32427
|
if (detaching) detach(t);
|
|
@@ -32106,11 +32437,11 @@ function create_each_block$3(ctx) {
|
|
|
32106
32437
|
callbackmapper = new Callback_mapper({
|
|
32107
32438
|
props: {
|
|
32108
32439
|
props: {
|
|
32109
|
-
callback: /*callback*/ ctx[
|
|
32110
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
32111
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
32112
|
-
stepMetadata: /*metadata*/ ctx[
|
|
32113
|
-
style: /*$styleStore*/ ctx[
|
|
32440
|
+
callback: /*callback*/ ctx[16],
|
|
32441
|
+
callbackMetadata: /*metadata*/ ctx[4]?.callbacks[/*idx*/ ctx[18]],
|
|
32442
|
+
selfSubmitFunction: /*determineSubmission*/ ctx[12],
|
|
32443
|
+
stepMetadata: /*metadata*/ ctx[4]?.step && { .../*metadata*/ ctx[4].step },
|
|
32444
|
+
style: /*$styleStore*/ ctx[11]
|
|
32114
32445
|
}
|
|
32115
32446
|
}
|
|
32116
32447
|
});
|
|
@@ -32126,12 +32457,12 @@ function create_each_block$3(ctx) {
|
|
|
32126
32457
|
p(ctx, dirty) {
|
|
32127
32458
|
const callbackmapper_changes = {};
|
|
32128
32459
|
|
|
32129
|
-
if (dirty & /*step, metadata, $styleStore*/
|
|
32130
|
-
callback: /*callback*/ ctx[
|
|
32131
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
32132
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
32133
|
-
stepMetadata: /*metadata*/ ctx[
|
|
32134
|
-
style: /*$styleStore*/ ctx[
|
|
32460
|
+
if (dirty & /*step, metadata, $styleStore*/ 2096) callbackmapper_changes.props = {
|
|
32461
|
+
callback: /*callback*/ ctx[16],
|
|
32462
|
+
callbackMetadata: /*metadata*/ ctx[4]?.callbacks[/*idx*/ ctx[18]],
|
|
32463
|
+
selfSubmitFunction: /*determineSubmission*/ ctx[12],
|
|
32464
|
+
stepMetadata: /*metadata*/ ctx[4]?.step && { .../*metadata*/ ctx[4].step },
|
|
32465
|
+
style: /*$styleStore*/ ctx[11]
|
|
32135
32466
|
};
|
|
32136
32467
|
|
|
32137
32468
|
callbackmapper.$set(callbackmapper_changes);
|
|
@@ -32158,7 +32489,7 @@ function create_if_block$5(ctx) {
|
|
|
32158
32489
|
|
|
32159
32490
|
button = new Button({
|
|
32160
32491
|
props: {
|
|
32161
|
-
busy: /*journey*/ ctx[
|
|
32492
|
+
busy: /*journey*/ ctx[3]?.loading,
|
|
32162
32493
|
style: "primary",
|
|
32163
32494
|
type: "submit",
|
|
32164
32495
|
width: "full",
|
|
@@ -32177,9 +32508,9 @@ function create_if_block$5(ctx) {
|
|
|
32177
32508
|
},
|
|
32178
32509
|
p(ctx, dirty) {
|
|
32179
32510
|
const button_changes = {};
|
|
32180
|
-
if (dirty & /*journey*/
|
|
32511
|
+
if (dirty & /*journey*/ 8) button_changes.busy = /*journey*/ ctx[3]?.loading;
|
|
32181
32512
|
|
|
32182
|
-
if (dirty & /*$$scope*/
|
|
32513
|
+
if (dirty & /*$$scope*/ 524288) {
|
|
32183
32514
|
button_changes.$$scope = { dirty, ctx };
|
|
32184
32515
|
}
|
|
32185
32516
|
|
|
@@ -32245,24 +32576,24 @@ function create_default_slot$5(ctx) {
|
|
|
32245
32576
|
let t5;
|
|
32246
32577
|
let backto;
|
|
32247
32578
|
let current;
|
|
32248
|
-
let if_block0 = /*form*/ ctx[
|
|
32579
|
+
let if_block0 = /*form*/ ctx[2]?.icon && /*componentStyle*/ ctx[1] !== 'inline' && create_if_block_2$4();
|
|
32249
32580
|
|
|
32250
32581
|
sanitize0 = new Server_strings({
|
|
32251
32582
|
props: {
|
|
32252
32583
|
html: true,
|
|
32253
|
-
string: /*step*/ ctx[
|
|
32584
|
+
string: /*step*/ ctx[5]?.getHeader() || ''
|
|
32254
32585
|
}
|
|
32255
32586
|
});
|
|
32256
32587
|
|
|
32257
32588
|
sanitize1 = new Server_strings({
|
|
32258
32589
|
props: {
|
|
32259
32590
|
html: true,
|
|
32260
|
-
string: /*step*/ ctx[
|
|
32591
|
+
string: /*step*/ ctx[5]?.getDescription() || ''
|
|
32261
32592
|
}
|
|
32262
32593
|
});
|
|
32263
32594
|
|
|
32264
|
-
let if_block1 = /*form*/ ctx[
|
|
32265
|
-
let each_value = /*step*/ ctx[
|
|
32595
|
+
let if_block1 = /*form*/ ctx[2]?.message && create_if_block_1$4(ctx);
|
|
32596
|
+
let each_value = /*step*/ ctx[5]?.callbacks;
|
|
32266
32597
|
let each_blocks = [];
|
|
32267
32598
|
|
|
32268
32599
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -32273,8 +32604,8 @@ function create_default_slot$5(ctx) {
|
|
|
32273
32604
|
each_blocks[i] = null;
|
|
32274
32605
|
});
|
|
32275
32606
|
|
|
32276
|
-
let if_block2 = (/*metadata*/ ctx[
|
|
32277
|
-
backto = new Back_to({ props: { journey: /*journey*/ ctx[
|
|
32607
|
+
let if_block2 = (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) && create_if_block$5(ctx);
|
|
32608
|
+
backto = new Back_to({ props: { journey: /*journey*/ ctx[3] } });
|
|
32278
32609
|
|
|
32279
32610
|
return {
|
|
32280
32611
|
c() {
|
|
@@ -32311,7 +32642,7 @@ function create_default_slot$5(ctx) {
|
|
|
32311
32642
|
append(header, t1);
|
|
32312
32643
|
append(header, p);
|
|
32313
32644
|
mount_component(sanitize1, p, null);
|
|
32314
|
-
/*header_binding*/ ctx[
|
|
32645
|
+
/*header_binding*/ ctx[14](header);
|
|
32315
32646
|
insert(target, t2, anchor);
|
|
32316
32647
|
if (if_block1) if_block1.m(target, anchor);
|
|
32317
32648
|
insert(target, t3, anchor);
|
|
@@ -32327,9 +32658,9 @@ function create_default_slot$5(ctx) {
|
|
|
32327
32658
|
current = true;
|
|
32328
32659
|
},
|
|
32329
32660
|
p(ctx, dirty) {
|
|
32330
|
-
if (/*form*/ ctx[
|
|
32661
|
+
if (/*form*/ ctx[2]?.icon && /*componentStyle*/ ctx[1] !== 'inline') {
|
|
32331
32662
|
if (if_block0) {
|
|
32332
|
-
if (dirty & /*form*/
|
|
32663
|
+
if (dirty & /*form, componentStyle*/ 6) {
|
|
32333
32664
|
transition_in(if_block0, 1);
|
|
32334
32665
|
}
|
|
32335
32666
|
} else {
|
|
@@ -32349,17 +32680,17 @@ function create_default_slot$5(ctx) {
|
|
|
32349
32680
|
}
|
|
32350
32681
|
|
|
32351
32682
|
const sanitize0_changes = {};
|
|
32352
|
-
if (dirty & /*step*/
|
|
32683
|
+
if (dirty & /*step*/ 32) sanitize0_changes.string = /*step*/ ctx[5]?.getHeader() || '';
|
|
32353
32684
|
sanitize0.$set(sanitize0_changes);
|
|
32354
32685
|
const sanitize1_changes = {};
|
|
32355
|
-
if (dirty & /*step*/
|
|
32686
|
+
if (dirty & /*step*/ 32) sanitize1_changes.string = /*step*/ ctx[5]?.getDescription() || '';
|
|
32356
32687
|
sanitize1.$set(sanitize1_changes);
|
|
32357
32688
|
|
|
32358
|
-
if (/*form*/ ctx[
|
|
32689
|
+
if (/*form*/ ctx[2]?.message) {
|
|
32359
32690
|
if (if_block1) {
|
|
32360
32691
|
if_block1.p(ctx, dirty);
|
|
32361
32692
|
|
|
32362
|
-
if (dirty & /*form*/
|
|
32693
|
+
if (dirty & /*form*/ 4) {
|
|
32363
32694
|
transition_in(if_block1, 1);
|
|
32364
32695
|
}
|
|
32365
32696
|
} else {
|
|
@@ -32378,8 +32709,8 @@ function create_default_slot$5(ctx) {
|
|
|
32378
32709
|
check_outros();
|
|
32379
32710
|
}
|
|
32380
32711
|
|
|
32381
|
-
if (dirty & /*step, metadata, determineSubmission, $styleStore*/
|
|
32382
|
-
each_value = /*step*/ ctx[
|
|
32712
|
+
if (dirty & /*step, metadata, determineSubmission, $styleStore*/ 6192) {
|
|
32713
|
+
each_value = /*step*/ ctx[5]?.callbacks;
|
|
32383
32714
|
let i;
|
|
32384
32715
|
|
|
32385
32716
|
for (i = 0; i < each_value.length; i += 1) {
|
|
@@ -32405,11 +32736,11 @@ function create_default_slot$5(ctx) {
|
|
|
32405
32736
|
check_outros();
|
|
32406
32737
|
}
|
|
32407
32738
|
|
|
32408
|
-
if (/*metadata*/ ctx[
|
|
32739
|
+
if (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) {
|
|
32409
32740
|
if (if_block2) {
|
|
32410
32741
|
if_block2.p(ctx, dirty);
|
|
32411
32742
|
|
|
32412
|
-
if (dirty & /*metadata*/
|
|
32743
|
+
if (dirty & /*metadata*/ 16) {
|
|
32413
32744
|
transition_in(if_block2, 1);
|
|
32414
32745
|
}
|
|
32415
32746
|
} else {
|
|
@@ -32429,7 +32760,7 @@ function create_default_slot$5(ctx) {
|
|
|
32429
32760
|
}
|
|
32430
32761
|
|
|
32431
32762
|
const backto_changes = {};
|
|
32432
|
-
if (dirty & /*journey*/
|
|
32763
|
+
if (dirty & /*journey*/ 8) backto_changes.journey = /*journey*/ ctx[3];
|
|
32433
32764
|
backto.$set(backto_changes);
|
|
32434
32765
|
},
|
|
32435
32766
|
i(local) {
|
|
@@ -32468,7 +32799,7 @@ function create_default_slot$5(ctx) {
|
|
|
32468
32799
|
if (detaching) detach(header);
|
|
32469
32800
|
destroy_component(sanitize0);
|
|
32470
32801
|
destroy_component(sanitize1);
|
|
32471
|
-
/*header_binding*/ ctx[
|
|
32802
|
+
/*header_binding*/ ctx[14](null);
|
|
32472
32803
|
if (detaching) detach(t2);
|
|
32473
32804
|
if (if_block1) if_block1.d(detaching);
|
|
32474
32805
|
if (detaching) detach(t3);
|
|
@@ -32487,14 +32818,14 @@ function create_fragment$7(ctx) {
|
|
|
32487
32818
|
let current;
|
|
32488
32819
|
|
|
32489
32820
|
function form_1_formEl_binding(value) {
|
|
32490
|
-
/*form_1_formEl_binding*/ ctx[
|
|
32821
|
+
/*form_1_formEl_binding*/ ctx[15](value);
|
|
32491
32822
|
}
|
|
32492
32823
|
|
|
32493
32824
|
let form_1_props = {
|
|
32494
|
-
ariaDescribedBy: /*formAriaDescriptor*/ ctx[
|
|
32825
|
+
ariaDescribedBy: /*formAriaDescriptor*/ ctx[8],
|
|
32495
32826
|
id: formElementId,
|
|
32496
|
-
needsFocus: /*formNeedsFocus*/ ctx[
|
|
32497
|
-
onSubmitWhenValid: /*submitFormWrapper*/ ctx[
|
|
32827
|
+
needsFocus: /*formNeedsFocus*/ ctx[9],
|
|
32828
|
+
onSubmitWhenValid: /*submitFormWrapper*/ ctx[13],
|
|
32498
32829
|
$$slots: { default: [create_default_slot$5] },
|
|
32499
32830
|
$$scope: { ctx }
|
|
32500
32831
|
};
|
|
@@ -32516,10 +32847,10 @@ function create_fragment$7(ctx) {
|
|
|
32516
32847
|
},
|
|
32517
32848
|
p(ctx, [dirty]) {
|
|
32518
32849
|
const form_1_changes = {};
|
|
32519
|
-
if (dirty & /*formAriaDescriptor*/
|
|
32520
|
-
if (dirty & /*formNeedsFocus*/
|
|
32850
|
+
if (dirty & /*formAriaDescriptor*/ 256) form_1_changes.ariaDescribedBy = /*formAriaDescriptor*/ ctx[8];
|
|
32851
|
+
if (dirty & /*formNeedsFocus*/ 512) form_1_changes.needsFocus = /*formNeedsFocus*/ ctx[9];
|
|
32521
32852
|
|
|
32522
|
-
if (dirty & /*$$scope, journey, metadata, step, $styleStore, alertNeedsFocus, formMessageKey, form, linkWrapper*/
|
|
32853
|
+
if (dirty & /*$$scope, journey, metadata, step, $styleStore, alertNeedsFocus, formMessageKey, form, linkWrapper, componentStyle*/ 527614) {
|
|
32523
32854
|
form_1_changes.$$scope = { dirty, ctx };
|
|
32524
32855
|
}
|
|
32525
32856
|
|
|
@@ -32552,7 +32883,8 @@ const formElementId = 'genericStepForm';
|
|
|
32552
32883
|
|
|
32553
32884
|
function instance$7($$self, $$props, $$invalidate) {
|
|
32554
32885
|
let $styleStore;
|
|
32555
|
-
component_subscribe($$self, styleStore, $$value => $$invalidate(
|
|
32886
|
+
component_subscribe($$self, styleStore, $$value => $$invalidate(11, $styleStore = $$value));
|
|
32887
|
+
let { componentStyle } = $$props;
|
|
32556
32888
|
let { form } = $$props;
|
|
32557
32889
|
let { formEl = null } = $$props;
|
|
32558
32890
|
let { journey } = $$props;
|
|
@@ -32574,20 +32906,20 @@ function instance$7($$self, $$props, $$invalidate) {
|
|
|
32574
32906
|
}
|
|
32575
32907
|
|
|
32576
32908
|
function submitFormWrapper() {
|
|
32577
|
-
$$invalidate(
|
|
32578
|
-
$$invalidate(
|
|
32909
|
+
$$invalidate(6, alertNeedsFocus = false);
|
|
32910
|
+
$$invalidate(9, formNeedsFocus = false);
|
|
32579
32911
|
form?.submit();
|
|
32580
32912
|
}
|
|
32581
32913
|
|
|
32582
32914
|
afterUpdate(() => {
|
|
32583
32915
|
if (form?.message) {
|
|
32584
|
-
$$invalidate(
|
|
32585
|
-
$$invalidate(
|
|
32586
|
-
$$invalidate(
|
|
32916
|
+
$$invalidate(8, formAriaDescriptor = formFailureMessageId);
|
|
32917
|
+
$$invalidate(6, alertNeedsFocus = true);
|
|
32918
|
+
$$invalidate(9, formNeedsFocus = false);
|
|
32587
32919
|
} else {
|
|
32588
|
-
$$invalidate(
|
|
32589
|
-
$$invalidate(
|
|
32590
|
-
$$invalidate(
|
|
32920
|
+
$$invalidate(8, formAriaDescriptor = formHeaderId);
|
|
32921
|
+
$$invalidate(6, alertNeedsFocus = false);
|
|
32922
|
+
$$invalidate(9, formNeedsFocus = true);
|
|
32591
32923
|
}
|
|
32592
32924
|
});
|
|
32593
32925
|
|
|
@@ -32596,7 +32928,7 @@ function instance$7($$self, $$props, $$invalidate) {
|
|
|
32596
32928
|
function header_binding($$value) {
|
|
32597
32929
|
binding_callbacks[$$value ? 'unshift' : 'push'](() => {
|
|
32598
32930
|
linkWrapper = $$value;
|
|
32599
|
-
$$invalidate(
|
|
32931
|
+
$$invalidate(10, linkWrapper);
|
|
32600
32932
|
});
|
|
32601
32933
|
}
|
|
32602
32934
|
|
|
@@ -32606,24 +32938,26 @@ function instance$7($$self, $$props, $$invalidate) {
|
|
|
32606
32938
|
}
|
|
32607
32939
|
|
|
32608
32940
|
$$self.$$set = $$props => {
|
|
32609
|
-
if ('
|
|
32941
|
+
if ('componentStyle' in $$props) $$invalidate(1, componentStyle = $$props.componentStyle);
|
|
32942
|
+
if ('form' in $$props) $$invalidate(2, form = $$props.form);
|
|
32610
32943
|
if ('formEl' in $$props) $$invalidate(0, formEl = $$props.formEl);
|
|
32611
|
-
if ('journey' in $$props) $$invalidate(
|
|
32612
|
-
if ('metadata' in $$props) $$invalidate(
|
|
32613
|
-
if ('step' in $$props) $$invalidate(
|
|
32944
|
+
if ('journey' in $$props) $$invalidate(3, journey = $$props.journey);
|
|
32945
|
+
if ('metadata' in $$props) $$invalidate(4, metadata = $$props.metadata);
|
|
32946
|
+
if ('step' in $$props) $$invalidate(5, step = $$props.step);
|
|
32614
32947
|
};
|
|
32615
32948
|
|
|
32616
32949
|
$$self.$$.update = () => {
|
|
32617
|
-
if ($$self.$$.dirty & /*step, form*/
|
|
32950
|
+
if ($$self.$$.dirty & /*step, form*/ 36) {
|
|
32618
32951
|
{
|
|
32619
32952
|
shouldRedirectFromStep(step) && FRAuth$1.redirect(step);
|
|
32620
|
-
$$invalidate(
|
|
32953
|
+
$$invalidate(7, formMessageKey = convertStringToKey(form?.message));
|
|
32621
32954
|
}
|
|
32622
32955
|
}
|
|
32623
32956
|
};
|
|
32624
32957
|
|
|
32625
32958
|
return [
|
|
32626
32959
|
formEl,
|
|
32960
|
+
componentStyle,
|
|
32627
32961
|
form,
|
|
32628
32962
|
journey,
|
|
32629
32963
|
metadata,
|
|
@@ -32646,11 +32980,12 @@ class Generic extends SvelteComponent {
|
|
|
32646
32980
|
super();
|
|
32647
32981
|
|
|
32648
32982
|
init(this, options, instance$7, create_fragment$7, safe_not_equal, {
|
|
32649
|
-
|
|
32983
|
+
componentStyle: 1,
|
|
32984
|
+
form: 2,
|
|
32650
32985
|
formEl: 0,
|
|
32651
|
-
journey:
|
|
32652
|
-
metadata:
|
|
32653
|
-
step:
|
|
32986
|
+
journey: 3,
|
|
32987
|
+
metadata: 4,
|
|
32988
|
+
step: 5
|
|
32654
32989
|
});
|
|
32655
32990
|
}
|
|
32656
32991
|
}
|
|
@@ -32763,13 +33098,101 @@ class Key_icon extends SvelteComponent {
|
|
|
32763
33098
|
|
|
32764
33099
|
function get_each_context$2(ctx, list, i) {
|
|
32765
33100
|
const child_ctx = ctx.slice();
|
|
32766
|
-
child_ctx[
|
|
32767
|
-
child_ctx[
|
|
33101
|
+
child_ctx[11] = list[i];
|
|
33102
|
+
child_ctx[13] = i;
|
|
32768
33103
|
return child_ctx;
|
|
32769
33104
|
}
|
|
32770
33105
|
|
|
32771
|
-
// (
|
|
33106
|
+
// (38:2) {#if componentStyle !== 'inline'}
|
|
32772
33107
|
function create_if_block_2$3(ctx) {
|
|
33108
|
+
let t0;
|
|
33109
|
+
let h1;
|
|
33110
|
+
let t1;
|
|
33111
|
+
let t2;
|
|
33112
|
+
let p;
|
|
33113
|
+
let t3;
|
|
33114
|
+
let current;
|
|
33115
|
+
let if_block = /*form*/ ctx[2]?.icon && create_if_block_3$3();
|
|
33116
|
+
|
|
33117
|
+
t1 = new Locale_strings({
|
|
33118
|
+
props: { key: "twoFactorAuthentication" }
|
|
33119
|
+
});
|
|
33120
|
+
|
|
33121
|
+
t3 = new Locale_strings({
|
|
33122
|
+
props: { key: "useTheAuthenticatorAppOnYourPhone" }
|
|
33123
|
+
});
|
|
33124
|
+
|
|
33125
|
+
return {
|
|
33126
|
+
c() {
|
|
33127
|
+
if (if_block) if_block.c();
|
|
33128
|
+
t0 = space();
|
|
33129
|
+
h1 = element("h1");
|
|
33130
|
+
create_component(t1.$$.fragment);
|
|
33131
|
+
t2 = space();
|
|
33132
|
+
p = element("p");
|
|
33133
|
+
create_component(t3.$$.fragment);
|
|
33134
|
+
attr(h1, "class", "tw_primary-header dark:tw_primary-header_dark");
|
|
33135
|
+
attr(p, "class", "tw_text-center tw_text-sm tw_-mt-5 tw_mb-2 tw_py-4 tw_text-secondary-dark dark:tw_text-secondary-light");
|
|
33136
|
+
},
|
|
33137
|
+
m(target, anchor) {
|
|
33138
|
+
if (if_block) if_block.m(target, anchor);
|
|
33139
|
+
insert(target, t0, anchor);
|
|
33140
|
+
insert(target, h1, anchor);
|
|
33141
|
+
mount_component(t1, h1, null);
|
|
33142
|
+
insert(target, t2, anchor);
|
|
33143
|
+
insert(target, p, anchor);
|
|
33144
|
+
mount_component(t3, p, null);
|
|
33145
|
+
current = true;
|
|
33146
|
+
},
|
|
33147
|
+
p(ctx, dirty) {
|
|
33148
|
+
if (/*form*/ ctx[2]?.icon) {
|
|
33149
|
+
if (if_block) {
|
|
33150
|
+
if (dirty & /*form*/ 4) {
|
|
33151
|
+
transition_in(if_block, 1);
|
|
33152
|
+
}
|
|
33153
|
+
} else {
|
|
33154
|
+
if_block = create_if_block_3$3();
|
|
33155
|
+
if_block.c();
|
|
33156
|
+
transition_in(if_block, 1);
|
|
33157
|
+
if_block.m(t0.parentNode, t0);
|
|
33158
|
+
}
|
|
33159
|
+
} else if (if_block) {
|
|
33160
|
+
group_outros();
|
|
33161
|
+
|
|
33162
|
+
transition_out(if_block, 1, 1, () => {
|
|
33163
|
+
if_block = null;
|
|
33164
|
+
});
|
|
33165
|
+
|
|
33166
|
+
check_outros();
|
|
33167
|
+
}
|
|
33168
|
+
},
|
|
33169
|
+
i(local) {
|
|
33170
|
+
if (current) return;
|
|
33171
|
+
transition_in(if_block);
|
|
33172
|
+
transition_in(t1.$$.fragment, local);
|
|
33173
|
+
transition_in(t3.$$.fragment, local);
|
|
33174
|
+
current = true;
|
|
33175
|
+
},
|
|
33176
|
+
o(local) {
|
|
33177
|
+
transition_out(if_block);
|
|
33178
|
+
transition_out(t1.$$.fragment, local);
|
|
33179
|
+
transition_out(t3.$$.fragment, local);
|
|
33180
|
+
current = false;
|
|
33181
|
+
},
|
|
33182
|
+
d(detaching) {
|
|
33183
|
+
if (if_block) if_block.d(detaching);
|
|
33184
|
+
if (detaching) detach(t0);
|
|
33185
|
+
if (detaching) detach(h1);
|
|
33186
|
+
destroy_component(t1);
|
|
33187
|
+
if (detaching) detach(t2);
|
|
33188
|
+
if (detaching) detach(p);
|
|
33189
|
+
destroy_component(t3);
|
|
33190
|
+
}
|
|
33191
|
+
};
|
|
33192
|
+
}
|
|
33193
|
+
|
|
33194
|
+
// (39:4) {#if form?.icon}
|
|
33195
|
+
function create_if_block_3$3(ctx) {
|
|
32773
33196
|
let div;
|
|
32774
33197
|
let keyicon;
|
|
32775
33198
|
let current;
|
|
@@ -32808,7 +33231,7 @@ function create_if_block_2$3(ctx) {
|
|
|
32808
33231
|
};
|
|
32809
33232
|
}
|
|
32810
33233
|
|
|
32811
|
-
// (
|
|
33234
|
+
// (54:2) {#if form?.message}
|
|
32812
33235
|
function create_if_block_1$3(ctx) {
|
|
32813
33236
|
let alert;
|
|
32814
33237
|
let current;
|
|
@@ -32816,7 +33239,7 @@ function create_if_block_1$3(ctx) {
|
|
|
32816
33239
|
alert = new Alert({
|
|
32817
33240
|
props: {
|
|
32818
33241
|
id: "formFailureMessageAlert",
|
|
32819
|
-
needsFocus: /*alertNeedsFocus*/ ctx[
|
|
33242
|
+
needsFocus: /*alertNeedsFocus*/ ctx[6],
|
|
32820
33243
|
type: "error",
|
|
32821
33244
|
$$slots: { default: [create_default_slot_2$2] },
|
|
32822
33245
|
$$scope: { ctx }
|
|
@@ -32833,9 +33256,9 @@ function create_if_block_1$3(ctx) {
|
|
|
32833
33256
|
},
|
|
32834
33257
|
p(ctx, dirty) {
|
|
32835
33258
|
const alert_changes = {};
|
|
32836
|
-
if (dirty & /*alertNeedsFocus*/
|
|
33259
|
+
if (dirty & /*alertNeedsFocus*/ 64) alert_changes.needsFocus = /*alertNeedsFocus*/ ctx[6];
|
|
32837
33260
|
|
|
32838
|
-
if (dirty & /*$$scope, formMessageKey, form*/
|
|
33261
|
+
if (dirty & /*$$scope, formMessageKey, form*/ 16516) {
|
|
32839
33262
|
alert_changes.$$scope = { dirty, ctx };
|
|
32840
33263
|
}
|
|
32841
33264
|
|
|
@@ -32856,9 +33279,9 @@ function create_if_block_1$3(ctx) {
|
|
|
32856
33279
|
};
|
|
32857
33280
|
}
|
|
32858
33281
|
|
|
32859
|
-
// (
|
|
33282
|
+
// (55:4) <Alert id="formFailureMessageAlert" needsFocus={alertNeedsFocus} type="error">
|
|
32860
33283
|
function create_default_slot_2$2(ctx) {
|
|
32861
|
-
let t_value = interpolate(/*formMessageKey*/ ctx[
|
|
33284
|
+
let t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "";
|
|
32862
33285
|
let t;
|
|
32863
33286
|
|
|
32864
33287
|
return {
|
|
@@ -32869,7 +33292,7 @@ function create_default_slot_2$2(ctx) {
|
|
|
32869
33292
|
insert(target, t, anchor);
|
|
32870
33293
|
},
|
|
32871
33294
|
p(ctx, dirty) {
|
|
32872
|
-
if (dirty & /*formMessageKey, form*/
|
|
33295
|
+
if (dirty & /*formMessageKey, form*/ 132 && t_value !== (t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "")) set_data(t, t_value);
|
|
32873
33296
|
},
|
|
32874
33297
|
d(detaching) {
|
|
32875
33298
|
if (detaching) detach(t);
|
|
@@ -32877,7 +33300,7 @@ function create_default_slot_2$2(ctx) {
|
|
|
32877
33300
|
};
|
|
32878
33301
|
}
|
|
32879
33302
|
|
|
32880
|
-
// (
|
|
33303
|
+
// (60:2) {#each step?.callbacks as callback, idx}
|
|
32881
33304
|
function create_each_block$2(ctx) {
|
|
32882
33305
|
let callbackmapper;
|
|
32883
33306
|
let current;
|
|
@@ -32885,11 +33308,11 @@ function create_each_block$2(ctx) {
|
|
|
32885
33308
|
callbackmapper = new Callback_mapper({
|
|
32886
33309
|
props: {
|
|
32887
33310
|
props: {
|
|
32888
|
-
callback: /*callback*/ ctx[
|
|
32889
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
32890
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
32891
|
-
stepMetadata: /*metadata*/ ctx[
|
|
32892
|
-
style: /*$style*/ ctx[
|
|
33311
|
+
callback: /*callback*/ ctx[11],
|
|
33312
|
+
callbackMetadata: /*metadata*/ ctx[4]?.callbacks[/*idx*/ ctx[13]],
|
|
33313
|
+
selfSubmitFunction: /*determineSubmission*/ ctx[9],
|
|
33314
|
+
stepMetadata: /*metadata*/ ctx[4]?.step && { .../*metadata*/ ctx[4].step },
|
|
33315
|
+
style: /*$style*/ ctx[8]
|
|
32893
33316
|
}
|
|
32894
33317
|
}
|
|
32895
33318
|
});
|
|
@@ -32905,12 +33328,12 @@ function create_each_block$2(ctx) {
|
|
|
32905
33328
|
p(ctx, dirty) {
|
|
32906
33329
|
const callbackmapper_changes = {};
|
|
32907
33330
|
|
|
32908
|
-
if (dirty & /*step, metadata, $style*/
|
|
32909
|
-
callback: /*callback*/ ctx[
|
|
32910
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
32911
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
32912
|
-
stepMetadata: /*metadata*/ ctx[
|
|
32913
|
-
style: /*$style*/ ctx[
|
|
33331
|
+
if (dirty & /*step, metadata, $style*/ 304) callbackmapper_changes.props = {
|
|
33332
|
+
callback: /*callback*/ ctx[11],
|
|
33333
|
+
callbackMetadata: /*metadata*/ ctx[4]?.callbacks[/*idx*/ ctx[13]],
|
|
33334
|
+
selfSubmitFunction: /*determineSubmission*/ ctx[9],
|
|
33335
|
+
stepMetadata: /*metadata*/ ctx[4]?.step && { .../*metadata*/ ctx[4].step },
|
|
33336
|
+
style: /*$style*/ ctx[8]
|
|
32914
33337
|
};
|
|
32915
33338
|
|
|
32916
33339
|
callbackmapper.$set(callbackmapper_changes);
|
|
@@ -32930,14 +33353,14 @@ function create_each_block$2(ctx) {
|
|
|
32930
33353
|
};
|
|
32931
33354
|
}
|
|
32932
33355
|
|
|
32933
|
-
// (
|
|
33356
|
+
// (72:2) {#if metadata?.step?.derived.isUserInputOptional || !metadata?.step?.derived.isStepSelfSubmittable}
|
|
32934
33357
|
function create_if_block$4(ctx) {
|
|
32935
33358
|
let button;
|
|
32936
33359
|
let current;
|
|
32937
33360
|
|
|
32938
33361
|
button = new Button({
|
|
32939
33362
|
props: {
|
|
32940
|
-
busy: /*journey*/ ctx[
|
|
33363
|
+
busy: /*journey*/ ctx[3]?.loading,
|
|
32941
33364
|
style: "primary",
|
|
32942
33365
|
type: "submit",
|
|
32943
33366
|
width: "full",
|
|
@@ -32956,9 +33379,9 @@ function create_if_block$4(ctx) {
|
|
|
32956
33379
|
},
|
|
32957
33380
|
p(ctx, dirty) {
|
|
32958
33381
|
const button_changes = {};
|
|
32959
|
-
if (dirty & /*journey*/
|
|
33382
|
+
if (dirty & /*journey*/ 8) button_changes.busy = /*journey*/ ctx[3]?.loading;
|
|
32960
33383
|
|
|
32961
|
-
if (dirty & /*$$scope*/
|
|
33384
|
+
if (dirty & /*$$scope*/ 16384) {
|
|
32962
33385
|
button_changes.$$scope = { dirty, ctx };
|
|
32963
33386
|
}
|
|
32964
33387
|
|
|
@@ -32979,7 +33402,7 @@ function create_if_block$4(ctx) {
|
|
|
32979
33402
|
};
|
|
32980
33403
|
}
|
|
32981
33404
|
|
|
32982
|
-
// (
|
|
33405
|
+
// (73:4) <Button busy={journey?.loading} style="primary" type="submit" width="full">
|
|
32983
33406
|
function create_default_slot_1$3(ctx) {
|
|
32984
33407
|
let t;
|
|
32985
33408
|
let current;
|
|
@@ -33009,31 +33432,16 @@ function create_default_slot_1$3(ctx) {
|
|
|
33009
33432
|
};
|
|
33010
33433
|
}
|
|
33011
33434
|
|
|
33012
|
-
// (
|
|
33435
|
+
// (37:0) <Form bind:formEl ariaDescribedBy="formFailureMessageAlert" onSubmitWhenValid={form?.submit}>
|
|
33013
33436
|
function create_default_slot$4(ctx) {
|
|
33014
33437
|
let t0;
|
|
33015
|
-
let h1;
|
|
33016
33438
|
let t1;
|
|
33017
33439
|
let t2;
|
|
33018
|
-
let p;
|
|
33019
|
-
let t3;
|
|
33020
|
-
let t4;
|
|
33021
|
-
let t5;
|
|
33022
|
-
let t6;
|
|
33023
33440
|
let if_block2_anchor;
|
|
33024
33441
|
let current;
|
|
33025
|
-
let if_block0 = /*
|
|
33026
|
-
|
|
33027
|
-
|
|
33028
|
-
props: { key: "twoFactorAuthentication" }
|
|
33029
|
-
});
|
|
33030
|
-
|
|
33031
|
-
t3 = new Locale_strings({
|
|
33032
|
-
props: { key: "useTheAuthenticatorAppOnYourPhone" }
|
|
33033
|
-
});
|
|
33034
|
-
|
|
33035
|
-
let if_block1 = /*form*/ ctx[1]?.message && create_if_block_1$3(ctx);
|
|
33036
|
-
let each_value = /*step*/ ctx[4]?.callbacks;
|
|
33442
|
+
let if_block0 = /*componentStyle*/ ctx[1] !== 'inline' && create_if_block_2$3(ctx);
|
|
33443
|
+
let if_block1 = /*form*/ ctx[2]?.message && create_if_block_1$3(ctx);
|
|
33444
|
+
let each_value = /*step*/ ctx[5]?.callbacks;
|
|
33037
33445
|
let each_blocks = [];
|
|
33038
33446
|
|
|
33039
33447
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -33044,60 +33452,48 @@ function create_default_slot$4(ctx) {
|
|
|
33044
33452
|
each_blocks[i] = null;
|
|
33045
33453
|
});
|
|
33046
33454
|
|
|
33047
|
-
let if_block2 = (/*metadata*/ ctx[
|
|
33455
|
+
let if_block2 = (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) && create_if_block$4(ctx);
|
|
33048
33456
|
|
|
33049
33457
|
return {
|
|
33050
33458
|
c() {
|
|
33051
33459
|
if (if_block0) if_block0.c();
|
|
33052
33460
|
t0 = space();
|
|
33053
|
-
h1 = element("h1");
|
|
33054
|
-
create_component(t1.$$.fragment);
|
|
33055
|
-
t2 = space();
|
|
33056
|
-
p = element("p");
|
|
33057
|
-
create_component(t3.$$.fragment);
|
|
33058
|
-
t4 = space();
|
|
33059
33461
|
if (if_block1) if_block1.c();
|
|
33060
|
-
|
|
33462
|
+
t1 = space();
|
|
33061
33463
|
|
|
33062
33464
|
for (let i = 0; i < each_blocks.length; i += 1) {
|
|
33063
33465
|
each_blocks[i].c();
|
|
33064
33466
|
}
|
|
33065
33467
|
|
|
33066
|
-
|
|
33468
|
+
t2 = space();
|
|
33067
33469
|
if (if_block2) if_block2.c();
|
|
33068
33470
|
if_block2_anchor = empty();
|
|
33069
|
-
attr(h1, "class", "tw_primary-header dark:tw_primary-header_dark");
|
|
33070
|
-
attr(p, "class", "tw_text-center tw_text-sm tw_-mt-5 tw_mb-2 tw_py-4 tw_text-secondary-dark dark:tw_text-secondary-light");
|
|
33071
33471
|
},
|
|
33072
33472
|
m(target, anchor) {
|
|
33073
33473
|
if (if_block0) if_block0.m(target, anchor);
|
|
33074
33474
|
insert(target, t0, anchor);
|
|
33075
|
-
insert(target, h1, anchor);
|
|
33076
|
-
mount_component(t1, h1, null);
|
|
33077
|
-
insert(target, t2, anchor);
|
|
33078
|
-
insert(target, p, anchor);
|
|
33079
|
-
mount_component(t3, p, null);
|
|
33080
|
-
insert(target, t4, anchor);
|
|
33081
33475
|
if (if_block1) if_block1.m(target, anchor);
|
|
33082
|
-
insert(target,
|
|
33476
|
+
insert(target, t1, anchor);
|
|
33083
33477
|
|
|
33084
33478
|
for (let i = 0; i < each_blocks.length; i += 1) {
|
|
33085
33479
|
each_blocks[i].m(target, anchor);
|
|
33086
33480
|
}
|
|
33087
33481
|
|
|
33088
|
-
insert(target,
|
|
33482
|
+
insert(target, t2, anchor);
|
|
33089
33483
|
if (if_block2) if_block2.m(target, anchor);
|
|
33090
33484
|
insert(target, if_block2_anchor, anchor);
|
|
33091
33485
|
current = true;
|
|
33092
33486
|
},
|
|
33093
33487
|
p(ctx, dirty) {
|
|
33094
|
-
if (/*
|
|
33488
|
+
if (/*componentStyle*/ ctx[1] !== 'inline') {
|
|
33095
33489
|
if (if_block0) {
|
|
33096
|
-
|
|
33490
|
+
if_block0.p(ctx, dirty);
|
|
33491
|
+
|
|
33492
|
+
if (dirty & /*componentStyle*/ 2) {
|
|
33097
33493
|
transition_in(if_block0, 1);
|
|
33098
33494
|
}
|
|
33099
33495
|
} else {
|
|
33100
|
-
if_block0 = create_if_block_2$3();
|
|
33496
|
+
if_block0 = create_if_block_2$3(ctx);
|
|
33101
33497
|
if_block0.c();
|
|
33102
33498
|
transition_in(if_block0, 1);
|
|
33103
33499
|
if_block0.m(t0.parentNode, t0);
|
|
@@ -33112,18 +33508,18 @@ function create_default_slot$4(ctx) {
|
|
|
33112
33508
|
check_outros();
|
|
33113
33509
|
}
|
|
33114
33510
|
|
|
33115
|
-
if (/*form*/ ctx[
|
|
33511
|
+
if (/*form*/ ctx[2]?.message) {
|
|
33116
33512
|
if (if_block1) {
|
|
33117
33513
|
if_block1.p(ctx, dirty);
|
|
33118
33514
|
|
|
33119
|
-
if (dirty & /*form*/
|
|
33515
|
+
if (dirty & /*form*/ 4) {
|
|
33120
33516
|
transition_in(if_block1, 1);
|
|
33121
33517
|
}
|
|
33122
33518
|
} else {
|
|
33123
33519
|
if_block1 = create_if_block_1$3(ctx);
|
|
33124
33520
|
if_block1.c();
|
|
33125
33521
|
transition_in(if_block1, 1);
|
|
33126
|
-
if_block1.m(
|
|
33522
|
+
if_block1.m(t1.parentNode, t1);
|
|
33127
33523
|
}
|
|
33128
33524
|
} else if (if_block1) {
|
|
33129
33525
|
group_outros();
|
|
@@ -33135,8 +33531,8 @@ function create_default_slot$4(ctx) {
|
|
|
33135
33531
|
check_outros();
|
|
33136
33532
|
}
|
|
33137
33533
|
|
|
33138
|
-
if (dirty & /*step, metadata, determineSubmission, $style*/
|
|
33139
|
-
each_value = /*step*/ ctx[
|
|
33534
|
+
if (dirty & /*step, metadata, determineSubmission, $style*/ 816) {
|
|
33535
|
+
each_value = /*step*/ ctx[5]?.callbacks;
|
|
33140
33536
|
let i;
|
|
33141
33537
|
|
|
33142
33538
|
for (i = 0; i < each_value.length; i += 1) {
|
|
@@ -33149,7 +33545,7 @@ function create_default_slot$4(ctx) {
|
|
|
33149
33545
|
each_blocks[i] = create_each_block$2(child_ctx);
|
|
33150
33546
|
each_blocks[i].c();
|
|
33151
33547
|
transition_in(each_blocks[i], 1);
|
|
33152
|
-
each_blocks[i].m(
|
|
33548
|
+
each_blocks[i].m(t2.parentNode, t2);
|
|
33153
33549
|
}
|
|
33154
33550
|
}
|
|
33155
33551
|
|
|
@@ -33162,11 +33558,11 @@ function create_default_slot$4(ctx) {
|
|
|
33162
33558
|
check_outros();
|
|
33163
33559
|
}
|
|
33164
33560
|
|
|
33165
|
-
if (/*metadata*/ ctx[
|
|
33561
|
+
if (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) {
|
|
33166
33562
|
if (if_block2) {
|
|
33167
33563
|
if_block2.p(ctx, dirty);
|
|
33168
33564
|
|
|
33169
|
-
if (dirty & /*metadata*/
|
|
33565
|
+
if (dirty & /*metadata*/ 16) {
|
|
33170
33566
|
transition_in(if_block2, 1);
|
|
33171
33567
|
}
|
|
33172
33568
|
} else {
|
|
@@ -33188,8 +33584,6 @@ function create_default_slot$4(ctx) {
|
|
|
33188
33584
|
i(local) {
|
|
33189
33585
|
if (current) return;
|
|
33190
33586
|
transition_in(if_block0);
|
|
33191
|
-
transition_in(t1.$$.fragment, local);
|
|
33192
|
-
transition_in(t3.$$.fragment, local);
|
|
33193
33587
|
transition_in(if_block1);
|
|
33194
33588
|
|
|
33195
33589
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -33201,8 +33595,6 @@ function create_default_slot$4(ctx) {
|
|
|
33201
33595
|
},
|
|
33202
33596
|
o(local) {
|
|
33203
33597
|
transition_out(if_block0);
|
|
33204
|
-
transition_out(t1.$$.fragment, local);
|
|
33205
|
-
transition_out(t3.$$.fragment, local);
|
|
33206
33598
|
transition_out(if_block1);
|
|
33207
33599
|
each_blocks = each_blocks.filter(Boolean);
|
|
33208
33600
|
|
|
@@ -33216,16 +33608,10 @@ function create_default_slot$4(ctx) {
|
|
|
33216
33608
|
d(detaching) {
|
|
33217
33609
|
if (if_block0) if_block0.d(detaching);
|
|
33218
33610
|
if (detaching) detach(t0);
|
|
33219
|
-
if (detaching) detach(h1);
|
|
33220
|
-
destroy_component(t1);
|
|
33221
|
-
if (detaching) detach(t2);
|
|
33222
|
-
if (detaching) detach(p);
|
|
33223
|
-
destroy_component(t3);
|
|
33224
|
-
if (detaching) detach(t4);
|
|
33225
33611
|
if (if_block1) if_block1.d(detaching);
|
|
33226
|
-
if (detaching) detach(
|
|
33612
|
+
if (detaching) detach(t1);
|
|
33227
33613
|
destroy_each(each_blocks, detaching);
|
|
33228
|
-
if (detaching) detach(
|
|
33614
|
+
if (detaching) detach(t2);
|
|
33229
33615
|
if (if_block2) if_block2.d(detaching);
|
|
33230
33616
|
if (detaching) detach(if_block2_anchor);
|
|
33231
33617
|
}
|
|
@@ -33238,12 +33624,12 @@ function create_fragment$5(ctx) {
|
|
|
33238
33624
|
let current;
|
|
33239
33625
|
|
|
33240
33626
|
function form_1_formEl_binding(value) {
|
|
33241
|
-
/*form_1_formEl_binding*/ ctx[
|
|
33627
|
+
/*form_1_formEl_binding*/ ctx[10](value);
|
|
33242
33628
|
}
|
|
33243
33629
|
|
|
33244
33630
|
let form_1_props = {
|
|
33245
33631
|
ariaDescribedBy: "formFailureMessageAlert",
|
|
33246
|
-
onSubmitWhenValid: /*form*/ ctx[
|
|
33632
|
+
onSubmitWhenValid: /*form*/ ctx[2]?.submit,
|
|
33247
33633
|
$$slots: { default: [create_default_slot$4] },
|
|
33248
33634
|
$$scope: { ctx }
|
|
33249
33635
|
};
|
|
@@ -33265,9 +33651,9 @@ function create_fragment$5(ctx) {
|
|
|
33265
33651
|
},
|
|
33266
33652
|
p(ctx, [dirty]) {
|
|
33267
33653
|
const form_1_changes = {};
|
|
33268
|
-
if (dirty & /*form*/
|
|
33654
|
+
if (dirty & /*form*/ 4) form_1_changes.onSubmitWhenValid = /*form*/ ctx[2]?.submit;
|
|
33269
33655
|
|
|
33270
|
-
if (dirty & /*$$scope, journey, metadata, step, $style, alertNeedsFocus, formMessageKey, form*/
|
|
33656
|
+
if (dirty & /*$$scope, journey, metadata, step, $style, alertNeedsFocus, formMessageKey, form, componentStyle*/ 16894) {
|
|
33271
33657
|
form_1_changes.$$scope = { dirty, ctx };
|
|
33272
33658
|
}
|
|
33273
33659
|
|
|
@@ -33296,7 +33682,8 @@ function create_fragment$5(ctx) {
|
|
|
33296
33682
|
|
|
33297
33683
|
function instance$5($$self, $$props, $$invalidate) {
|
|
33298
33684
|
let $style;
|
|
33299
|
-
component_subscribe($$self, styleStore, $$value => $$invalidate(
|
|
33685
|
+
component_subscribe($$self, styleStore, $$value => $$invalidate(8, $style = $$value));
|
|
33686
|
+
let { componentStyle } = $$props;
|
|
33300
33687
|
let { form } = $$props;
|
|
33301
33688
|
let { formEl = null } = $$props;
|
|
33302
33689
|
let { journey } = $$props;
|
|
@@ -33315,7 +33702,7 @@ function instance$5($$self, $$props, $$invalidate) {
|
|
|
33315
33702
|
}
|
|
33316
33703
|
|
|
33317
33704
|
afterUpdate(() => {
|
|
33318
|
-
$$invalidate(
|
|
33705
|
+
$$invalidate(6, alertNeedsFocus = !!form?.message);
|
|
33319
33706
|
});
|
|
33320
33707
|
|
|
33321
33708
|
function form_1_formEl_binding(value) {
|
|
@@ -33324,23 +33711,25 @@ function instance$5($$self, $$props, $$invalidate) {
|
|
|
33324
33711
|
}
|
|
33325
33712
|
|
|
33326
33713
|
$$self.$$set = $$props => {
|
|
33327
|
-
if ('
|
|
33714
|
+
if ('componentStyle' in $$props) $$invalidate(1, componentStyle = $$props.componentStyle);
|
|
33715
|
+
if ('form' in $$props) $$invalidate(2, form = $$props.form);
|
|
33328
33716
|
if ('formEl' in $$props) $$invalidate(0, formEl = $$props.formEl);
|
|
33329
|
-
if ('journey' in $$props) $$invalidate(
|
|
33330
|
-
if ('metadata' in $$props) $$invalidate(
|
|
33331
|
-
if ('step' in $$props) $$invalidate(
|
|
33717
|
+
if ('journey' in $$props) $$invalidate(3, journey = $$props.journey);
|
|
33718
|
+
if ('metadata' in $$props) $$invalidate(4, metadata = $$props.metadata);
|
|
33719
|
+
if ('step' in $$props) $$invalidate(5, step = $$props.step);
|
|
33332
33720
|
};
|
|
33333
33721
|
|
|
33334
33722
|
$$self.$$.update = () => {
|
|
33335
|
-
if ($$self.$$.dirty & /*form*/
|
|
33723
|
+
if ($$self.$$.dirty & /*form*/ 4) {
|
|
33336
33724
|
{
|
|
33337
|
-
$$invalidate(
|
|
33725
|
+
$$invalidate(7, formMessageKey = convertStringToKey(form?.message));
|
|
33338
33726
|
}
|
|
33339
33727
|
}
|
|
33340
33728
|
};
|
|
33341
33729
|
|
|
33342
33730
|
return [
|
|
33343
33731
|
formEl,
|
|
33732
|
+
componentStyle,
|
|
33344
33733
|
form,
|
|
33345
33734
|
journey,
|
|
33346
33735
|
metadata,
|
|
@@ -33358,11 +33747,12 @@ class One_time_password extends SvelteComponent {
|
|
|
33358
33747
|
super();
|
|
33359
33748
|
|
|
33360
33749
|
init(this, options, instance$5, create_fragment$5, safe_not_equal, {
|
|
33361
|
-
|
|
33750
|
+
componentStyle: 1,
|
|
33751
|
+
form: 2,
|
|
33362
33752
|
formEl: 0,
|
|
33363
|
-
journey:
|
|
33364
|
-
metadata:
|
|
33365
|
-
step:
|
|
33753
|
+
journey: 3,
|
|
33754
|
+
metadata: 4,
|
|
33755
|
+
step: 5
|
|
33366
33756
|
});
|
|
33367
33757
|
}
|
|
33368
33758
|
}
|
|
@@ -33475,13 +33865,100 @@ class New_user_icon extends SvelteComponent {
|
|
|
33475
33865
|
|
|
33476
33866
|
function get_each_context$1(ctx, list, i) {
|
|
33477
33867
|
const child_ctx = ctx.slice();
|
|
33478
|
-
child_ctx[
|
|
33479
|
-
child_ctx[
|
|
33868
|
+
child_ctx[13] = list[i];
|
|
33869
|
+
child_ctx[15] = i;
|
|
33480
33870
|
return child_ctx;
|
|
33481
33871
|
}
|
|
33482
33872
|
|
|
33483
|
-
// (
|
|
33873
|
+
// (50:2) {#if componentStyle !== 'inline'}
|
|
33484
33874
|
function create_if_block_2$2(ctx) {
|
|
33875
|
+
let t0;
|
|
33876
|
+
let h1;
|
|
33877
|
+
let t1;
|
|
33878
|
+
let t2;
|
|
33879
|
+
let p;
|
|
33880
|
+
let t3;
|
|
33881
|
+
let current;
|
|
33882
|
+
let if_block = /*form*/ ctx[2]?.icon && create_if_block_3$2();
|
|
33883
|
+
t1 = new Locale_strings({ props: { key: "registerHeader" } });
|
|
33884
|
+
|
|
33885
|
+
t3 = new Locale_strings({
|
|
33886
|
+
props: { key: "alreadyHaveAnAccount", html: true }
|
|
33887
|
+
});
|
|
33888
|
+
|
|
33889
|
+
return {
|
|
33890
|
+
c() {
|
|
33891
|
+
if (if_block) if_block.c();
|
|
33892
|
+
t0 = space();
|
|
33893
|
+
h1 = element("h1");
|
|
33894
|
+
create_component(t1.$$.fragment);
|
|
33895
|
+
t2 = space();
|
|
33896
|
+
p = element("p");
|
|
33897
|
+
create_component(t3.$$.fragment);
|
|
33898
|
+
attr(h1, "class", "tw_primary-header dark:tw_primary-header_dark");
|
|
33899
|
+
attr(p, "class", "tw_text-base tw_text-center tw_-mt-5 tw_mb-2 tw_py-4 tw_text-secondary-dark dark:tw_text-secondary-light");
|
|
33900
|
+
},
|
|
33901
|
+
m(target, anchor) {
|
|
33902
|
+
if (if_block) if_block.m(target, anchor);
|
|
33903
|
+
insert(target, t0, anchor);
|
|
33904
|
+
insert(target, h1, anchor);
|
|
33905
|
+
mount_component(t1, h1, null);
|
|
33906
|
+
insert(target, t2, anchor);
|
|
33907
|
+
insert(target, p, anchor);
|
|
33908
|
+
mount_component(t3, p, null);
|
|
33909
|
+
/*p_binding*/ ctx[11](p);
|
|
33910
|
+
current = true;
|
|
33911
|
+
},
|
|
33912
|
+
p(ctx, dirty) {
|
|
33913
|
+
if (/*form*/ ctx[2]?.icon) {
|
|
33914
|
+
if (if_block) {
|
|
33915
|
+
if (dirty & /*form*/ 4) {
|
|
33916
|
+
transition_in(if_block, 1);
|
|
33917
|
+
}
|
|
33918
|
+
} else {
|
|
33919
|
+
if_block = create_if_block_3$2();
|
|
33920
|
+
if_block.c();
|
|
33921
|
+
transition_in(if_block, 1);
|
|
33922
|
+
if_block.m(t0.parentNode, t0);
|
|
33923
|
+
}
|
|
33924
|
+
} else if (if_block) {
|
|
33925
|
+
group_outros();
|
|
33926
|
+
|
|
33927
|
+
transition_out(if_block, 1, 1, () => {
|
|
33928
|
+
if_block = null;
|
|
33929
|
+
});
|
|
33930
|
+
|
|
33931
|
+
check_outros();
|
|
33932
|
+
}
|
|
33933
|
+
},
|
|
33934
|
+
i(local) {
|
|
33935
|
+
if (current) return;
|
|
33936
|
+
transition_in(if_block);
|
|
33937
|
+
transition_in(t1.$$.fragment, local);
|
|
33938
|
+
transition_in(t3.$$.fragment, local);
|
|
33939
|
+
current = true;
|
|
33940
|
+
},
|
|
33941
|
+
o(local) {
|
|
33942
|
+
transition_out(if_block);
|
|
33943
|
+
transition_out(t1.$$.fragment, local);
|
|
33944
|
+
transition_out(t3.$$.fragment, local);
|
|
33945
|
+
current = false;
|
|
33946
|
+
},
|
|
33947
|
+
d(detaching) {
|
|
33948
|
+
if (if_block) if_block.d(detaching);
|
|
33949
|
+
if (detaching) detach(t0);
|
|
33950
|
+
if (detaching) detach(h1);
|
|
33951
|
+
destroy_component(t1);
|
|
33952
|
+
if (detaching) detach(t2);
|
|
33953
|
+
if (detaching) detach(p);
|
|
33954
|
+
destroy_component(t3);
|
|
33955
|
+
/*p_binding*/ ctx[11](null);
|
|
33956
|
+
}
|
|
33957
|
+
};
|
|
33958
|
+
}
|
|
33959
|
+
|
|
33960
|
+
// (51:4) {#if form?.icon}
|
|
33961
|
+
function create_if_block_3$2(ctx) {
|
|
33485
33962
|
let div;
|
|
33486
33963
|
let newusericon;
|
|
33487
33964
|
let current;
|
|
@@ -33520,7 +33997,7 @@ function create_if_block_2$2(ctx) {
|
|
|
33520
33997
|
};
|
|
33521
33998
|
}
|
|
33522
33999
|
|
|
33523
|
-
// (
|
|
34000
|
+
// (67:2) {#if form.message}
|
|
33524
34001
|
function create_if_block_1$2(ctx) {
|
|
33525
34002
|
let alert;
|
|
33526
34003
|
let current;
|
|
@@ -33528,7 +34005,7 @@ function create_if_block_1$2(ctx) {
|
|
|
33528
34005
|
alert = new Alert({
|
|
33529
34006
|
props: {
|
|
33530
34007
|
id: "formFailureMessageAlert",
|
|
33531
|
-
needsFocus: /*alertNeedsFocus*/ ctx[
|
|
34008
|
+
needsFocus: /*alertNeedsFocus*/ ctx[6],
|
|
33532
34009
|
type: "error",
|
|
33533
34010
|
$$slots: { default: [create_default_slot_2$1] },
|
|
33534
34011
|
$$scope: { ctx }
|
|
@@ -33545,9 +34022,9 @@ function create_if_block_1$2(ctx) {
|
|
|
33545
34022
|
},
|
|
33546
34023
|
p(ctx, dirty) {
|
|
33547
34024
|
const alert_changes = {};
|
|
33548
|
-
if (dirty & /*alertNeedsFocus*/
|
|
34025
|
+
if (dirty & /*alertNeedsFocus*/ 64) alert_changes.needsFocus = /*alertNeedsFocus*/ ctx[6];
|
|
33549
34026
|
|
|
33550
|
-
if (dirty & /*$$scope, formMessageKey, form*/
|
|
34027
|
+
if (dirty & /*$$scope, formMessageKey, form*/ 65668) {
|
|
33551
34028
|
alert_changes.$$scope = { dirty, ctx };
|
|
33552
34029
|
}
|
|
33553
34030
|
|
|
@@ -33568,9 +34045,9 @@ function create_if_block_1$2(ctx) {
|
|
|
33568
34045
|
};
|
|
33569
34046
|
}
|
|
33570
34047
|
|
|
33571
|
-
// (
|
|
34048
|
+
// (68:4) <Alert id="formFailureMessageAlert" needsFocus={alertNeedsFocus} type="error">
|
|
33572
34049
|
function create_default_slot_2$1(ctx) {
|
|
33573
|
-
let t_value = interpolate(/*formMessageKey*/ ctx[
|
|
34050
|
+
let t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "";
|
|
33574
34051
|
let t;
|
|
33575
34052
|
|
|
33576
34053
|
return {
|
|
@@ -33581,7 +34058,7 @@ function create_default_slot_2$1(ctx) {
|
|
|
33581
34058
|
insert(target, t, anchor);
|
|
33582
34059
|
},
|
|
33583
34060
|
p(ctx, dirty) {
|
|
33584
|
-
if (dirty & /*formMessageKey, form*/
|
|
34061
|
+
if (dirty & /*formMessageKey, form*/ 132 && t_value !== (t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "")) set_data(t, t_value);
|
|
33585
34062
|
},
|
|
33586
34063
|
d(detaching) {
|
|
33587
34064
|
if (detaching) detach(t);
|
|
@@ -33589,7 +34066,7 @@ function create_default_slot_2$1(ctx) {
|
|
|
33589
34066
|
};
|
|
33590
34067
|
}
|
|
33591
34068
|
|
|
33592
|
-
// (
|
|
34069
|
+
// (73:2) {#each step?.callbacks as callback, idx}
|
|
33593
34070
|
function create_each_block$1(ctx) {
|
|
33594
34071
|
let callbackmapper;
|
|
33595
34072
|
let current;
|
|
@@ -33597,11 +34074,11 @@ function create_each_block$1(ctx) {
|
|
|
33597
34074
|
callbackmapper = new Callback_mapper({
|
|
33598
34075
|
props: {
|
|
33599
34076
|
props: {
|
|
33600
|
-
callback: /*callback*/ ctx[
|
|
33601
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
33602
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
33603
|
-
stepMetadata: /*metadata*/ ctx[
|
|
33604
|
-
style: /*$styleStore*/ ctx[
|
|
34077
|
+
callback: /*callback*/ ctx[13],
|
|
34078
|
+
callbackMetadata: /*metadata*/ ctx[4]?.callbacks[/*idx*/ ctx[15]],
|
|
34079
|
+
selfSubmitFunction: /*determineSubmission*/ ctx[10],
|
|
34080
|
+
stepMetadata: /*metadata*/ ctx[4]?.step && { .../*metadata*/ ctx[4].step },
|
|
34081
|
+
style: /*$styleStore*/ ctx[9]
|
|
33605
34082
|
}
|
|
33606
34083
|
}
|
|
33607
34084
|
});
|
|
@@ -33617,12 +34094,12 @@ function create_each_block$1(ctx) {
|
|
|
33617
34094
|
p(ctx, dirty) {
|
|
33618
34095
|
const callbackmapper_changes = {};
|
|
33619
34096
|
|
|
33620
|
-
if (dirty & /*step, metadata, $styleStore*/
|
|
33621
|
-
callback: /*callback*/ ctx[
|
|
33622
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
33623
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
33624
|
-
stepMetadata: /*metadata*/ ctx[
|
|
33625
|
-
style: /*$styleStore*/ ctx[
|
|
34097
|
+
if (dirty & /*step, metadata, $styleStore*/ 560) callbackmapper_changes.props = {
|
|
34098
|
+
callback: /*callback*/ ctx[13],
|
|
34099
|
+
callbackMetadata: /*metadata*/ ctx[4]?.callbacks[/*idx*/ ctx[15]],
|
|
34100
|
+
selfSubmitFunction: /*determineSubmission*/ ctx[10],
|
|
34101
|
+
stepMetadata: /*metadata*/ ctx[4]?.step && { .../*metadata*/ ctx[4].step },
|
|
34102
|
+
style: /*$styleStore*/ ctx[9]
|
|
33626
34103
|
};
|
|
33627
34104
|
|
|
33628
34105
|
callbackmapper.$set(callbackmapper_changes);
|
|
@@ -33642,14 +34119,14 @@ function create_each_block$1(ctx) {
|
|
|
33642
34119
|
};
|
|
33643
34120
|
}
|
|
33644
34121
|
|
|
33645
|
-
// (
|
|
34122
|
+
// (85:2) {#if metadata?.step?.derived.isUserInputOptional || !metadata?.step?.derived.isStepSelfSubmittable}
|
|
33646
34123
|
function create_if_block$3(ctx) {
|
|
33647
34124
|
let button;
|
|
33648
34125
|
let current;
|
|
33649
34126
|
|
|
33650
34127
|
button = new Button({
|
|
33651
34128
|
props: {
|
|
33652
|
-
busy: /*journey*/ ctx[
|
|
34129
|
+
busy: /*journey*/ ctx[3]?.loading,
|
|
33653
34130
|
style: "primary",
|
|
33654
34131
|
type: "submit",
|
|
33655
34132
|
width: "full",
|
|
@@ -33668,9 +34145,9 @@ function create_if_block$3(ctx) {
|
|
|
33668
34145
|
},
|
|
33669
34146
|
p(ctx, dirty) {
|
|
33670
34147
|
const button_changes = {};
|
|
33671
|
-
if (dirty & /*journey*/
|
|
34148
|
+
if (dirty & /*journey*/ 8) button_changes.busy = /*journey*/ ctx[3]?.loading;
|
|
33672
34149
|
|
|
33673
|
-
if (dirty & /*$$scope*/
|
|
34150
|
+
if (dirty & /*$$scope*/ 65536) {
|
|
33674
34151
|
button_changes.$$scope = { dirty, ctx };
|
|
33675
34152
|
}
|
|
33676
34153
|
|
|
@@ -33691,7 +34168,7 @@ function create_if_block$3(ctx) {
|
|
|
33691
34168
|
};
|
|
33692
34169
|
}
|
|
33693
34170
|
|
|
33694
|
-
// (
|
|
34171
|
+
// (86:4) <Button busy={journey?.loading} style="primary" type="submit" width="full">
|
|
33695
34172
|
function create_default_slot_1$2(ctx) {
|
|
33696
34173
|
let t;
|
|
33697
34174
|
let current;
|
|
@@ -33721,28 +34198,16 @@ function create_default_slot_1$2(ctx) {
|
|
|
33721
34198
|
};
|
|
33722
34199
|
}
|
|
33723
34200
|
|
|
33724
|
-
// (
|
|
34201
|
+
// (49:0) <Form bind:formEl ariaDescribedBy="formFailureMessageAlert" onSubmitWhenValid={form?.submit}>
|
|
33725
34202
|
function create_default_slot$3(ctx) {
|
|
33726
34203
|
let t0;
|
|
33727
|
-
let h1;
|
|
33728
34204
|
let t1;
|
|
33729
34205
|
let t2;
|
|
33730
|
-
let p;
|
|
33731
|
-
let t3;
|
|
33732
|
-
let t4;
|
|
33733
|
-
let t5;
|
|
33734
|
-
let t6;
|
|
33735
34206
|
let if_block2_anchor;
|
|
33736
34207
|
let current;
|
|
33737
|
-
let if_block0 = /*
|
|
33738
|
-
|
|
33739
|
-
|
|
33740
|
-
t3 = new Locale_strings({
|
|
33741
|
-
props: { key: "alreadyHaveAnAccount", html: true }
|
|
33742
|
-
});
|
|
33743
|
-
|
|
33744
|
-
let if_block1 = /*form*/ ctx[1].message && create_if_block_1$2(ctx);
|
|
33745
|
-
let each_value = /*step*/ ctx[4]?.callbacks;
|
|
34208
|
+
let if_block0 = /*componentStyle*/ ctx[1] !== 'inline' && create_if_block_2$2(ctx);
|
|
34209
|
+
let if_block1 = /*form*/ ctx[2].message && create_if_block_1$2(ctx);
|
|
34210
|
+
let each_value = /*step*/ ctx[5]?.callbacks;
|
|
33746
34211
|
let each_blocks = [];
|
|
33747
34212
|
|
|
33748
34213
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -33753,61 +34218,48 @@ function create_default_slot$3(ctx) {
|
|
|
33753
34218
|
each_blocks[i] = null;
|
|
33754
34219
|
});
|
|
33755
34220
|
|
|
33756
|
-
let if_block2 = (/*metadata*/ ctx[
|
|
34221
|
+
let if_block2 = (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) && create_if_block$3(ctx);
|
|
33757
34222
|
|
|
33758
34223
|
return {
|
|
33759
34224
|
c() {
|
|
33760
34225
|
if (if_block0) if_block0.c();
|
|
33761
34226
|
t0 = space();
|
|
33762
|
-
h1 = element("h1");
|
|
33763
|
-
create_component(t1.$$.fragment);
|
|
33764
|
-
t2 = space();
|
|
33765
|
-
p = element("p");
|
|
33766
|
-
create_component(t3.$$.fragment);
|
|
33767
|
-
t4 = space();
|
|
33768
34227
|
if (if_block1) if_block1.c();
|
|
33769
|
-
|
|
34228
|
+
t1 = space();
|
|
33770
34229
|
|
|
33771
34230
|
for (let i = 0; i < each_blocks.length; i += 1) {
|
|
33772
34231
|
each_blocks[i].c();
|
|
33773
34232
|
}
|
|
33774
34233
|
|
|
33775
|
-
|
|
34234
|
+
t2 = space();
|
|
33776
34235
|
if (if_block2) if_block2.c();
|
|
33777
34236
|
if_block2_anchor = empty();
|
|
33778
|
-
attr(h1, "class", "tw_primary-header dark:tw_primary-header_dark");
|
|
33779
|
-
attr(p, "class", "tw_text-base tw_text-center tw_-mt-5 tw_mb-2 tw_py-4 tw_text-secondary-dark dark:tw_text-secondary-light");
|
|
33780
34237
|
},
|
|
33781
34238
|
m(target, anchor) {
|
|
33782
34239
|
if (if_block0) if_block0.m(target, anchor);
|
|
33783
34240
|
insert(target, t0, anchor);
|
|
33784
|
-
insert(target, h1, anchor);
|
|
33785
|
-
mount_component(t1, h1, null);
|
|
33786
|
-
insert(target, t2, anchor);
|
|
33787
|
-
insert(target, p, anchor);
|
|
33788
|
-
mount_component(t3, p, null);
|
|
33789
|
-
/*p_binding*/ ctx[10](p);
|
|
33790
|
-
insert(target, t4, anchor);
|
|
33791
34241
|
if (if_block1) if_block1.m(target, anchor);
|
|
33792
|
-
insert(target,
|
|
34242
|
+
insert(target, t1, anchor);
|
|
33793
34243
|
|
|
33794
34244
|
for (let i = 0; i < each_blocks.length; i += 1) {
|
|
33795
34245
|
each_blocks[i].m(target, anchor);
|
|
33796
34246
|
}
|
|
33797
34247
|
|
|
33798
|
-
insert(target,
|
|
34248
|
+
insert(target, t2, anchor);
|
|
33799
34249
|
if (if_block2) if_block2.m(target, anchor);
|
|
33800
34250
|
insert(target, if_block2_anchor, anchor);
|
|
33801
34251
|
current = true;
|
|
33802
34252
|
},
|
|
33803
34253
|
p(ctx, dirty) {
|
|
33804
|
-
if (/*
|
|
34254
|
+
if (/*componentStyle*/ ctx[1] !== 'inline') {
|
|
33805
34255
|
if (if_block0) {
|
|
33806
|
-
|
|
34256
|
+
if_block0.p(ctx, dirty);
|
|
34257
|
+
|
|
34258
|
+
if (dirty & /*componentStyle*/ 2) {
|
|
33807
34259
|
transition_in(if_block0, 1);
|
|
33808
34260
|
}
|
|
33809
34261
|
} else {
|
|
33810
|
-
if_block0 = create_if_block_2$2();
|
|
34262
|
+
if_block0 = create_if_block_2$2(ctx);
|
|
33811
34263
|
if_block0.c();
|
|
33812
34264
|
transition_in(if_block0, 1);
|
|
33813
34265
|
if_block0.m(t0.parentNode, t0);
|
|
@@ -33822,18 +34274,18 @@ function create_default_slot$3(ctx) {
|
|
|
33822
34274
|
check_outros();
|
|
33823
34275
|
}
|
|
33824
34276
|
|
|
33825
|
-
if (/*form*/ ctx[
|
|
34277
|
+
if (/*form*/ ctx[2].message) {
|
|
33826
34278
|
if (if_block1) {
|
|
33827
34279
|
if_block1.p(ctx, dirty);
|
|
33828
34280
|
|
|
33829
|
-
if (dirty & /*form*/
|
|
34281
|
+
if (dirty & /*form*/ 4) {
|
|
33830
34282
|
transition_in(if_block1, 1);
|
|
33831
34283
|
}
|
|
33832
34284
|
} else {
|
|
33833
34285
|
if_block1 = create_if_block_1$2(ctx);
|
|
33834
34286
|
if_block1.c();
|
|
33835
34287
|
transition_in(if_block1, 1);
|
|
33836
|
-
if_block1.m(
|
|
34288
|
+
if_block1.m(t1.parentNode, t1);
|
|
33837
34289
|
}
|
|
33838
34290
|
} else if (if_block1) {
|
|
33839
34291
|
group_outros();
|
|
@@ -33845,8 +34297,8 @@ function create_default_slot$3(ctx) {
|
|
|
33845
34297
|
check_outros();
|
|
33846
34298
|
}
|
|
33847
34299
|
|
|
33848
|
-
if (dirty & /*step, metadata, determineSubmission, $styleStore*/
|
|
33849
|
-
each_value = /*step*/ ctx[
|
|
34300
|
+
if (dirty & /*step, metadata, determineSubmission, $styleStore*/ 1584) {
|
|
34301
|
+
each_value = /*step*/ ctx[5]?.callbacks;
|
|
33850
34302
|
let i;
|
|
33851
34303
|
|
|
33852
34304
|
for (i = 0; i < each_value.length; i += 1) {
|
|
@@ -33859,7 +34311,7 @@ function create_default_slot$3(ctx) {
|
|
|
33859
34311
|
each_blocks[i] = create_each_block$1(child_ctx);
|
|
33860
34312
|
each_blocks[i].c();
|
|
33861
34313
|
transition_in(each_blocks[i], 1);
|
|
33862
|
-
each_blocks[i].m(
|
|
34314
|
+
each_blocks[i].m(t2.parentNode, t2);
|
|
33863
34315
|
}
|
|
33864
34316
|
}
|
|
33865
34317
|
|
|
@@ -33872,11 +34324,11 @@ function create_default_slot$3(ctx) {
|
|
|
33872
34324
|
check_outros();
|
|
33873
34325
|
}
|
|
33874
34326
|
|
|
33875
|
-
if (/*metadata*/ ctx[
|
|
34327
|
+
if (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) {
|
|
33876
34328
|
if (if_block2) {
|
|
33877
34329
|
if_block2.p(ctx, dirty);
|
|
33878
34330
|
|
|
33879
|
-
if (dirty & /*metadata*/
|
|
34331
|
+
if (dirty & /*metadata*/ 16) {
|
|
33880
34332
|
transition_in(if_block2, 1);
|
|
33881
34333
|
}
|
|
33882
34334
|
} else {
|
|
@@ -33898,8 +34350,6 @@ function create_default_slot$3(ctx) {
|
|
|
33898
34350
|
i(local) {
|
|
33899
34351
|
if (current) return;
|
|
33900
34352
|
transition_in(if_block0);
|
|
33901
|
-
transition_in(t1.$$.fragment, local);
|
|
33902
|
-
transition_in(t3.$$.fragment, local);
|
|
33903
34353
|
transition_in(if_block1);
|
|
33904
34354
|
|
|
33905
34355
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -33911,8 +34361,6 @@ function create_default_slot$3(ctx) {
|
|
|
33911
34361
|
},
|
|
33912
34362
|
o(local) {
|
|
33913
34363
|
transition_out(if_block0);
|
|
33914
|
-
transition_out(t1.$$.fragment, local);
|
|
33915
|
-
transition_out(t3.$$.fragment, local);
|
|
33916
34364
|
transition_out(if_block1);
|
|
33917
34365
|
each_blocks = each_blocks.filter(Boolean);
|
|
33918
34366
|
|
|
@@ -33926,17 +34374,10 @@ function create_default_slot$3(ctx) {
|
|
|
33926
34374
|
d(detaching) {
|
|
33927
34375
|
if (if_block0) if_block0.d(detaching);
|
|
33928
34376
|
if (detaching) detach(t0);
|
|
33929
|
-
if (detaching) detach(h1);
|
|
33930
|
-
destroy_component(t1);
|
|
33931
|
-
if (detaching) detach(t2);
|
|
33932
|
-
if (detaching) detach(p);
|
|
33933
|
-
destroy_component(t3);
|
|
33934
|
-
/*p_binding*/ ctx[10](null);
|
|
33935
|
-
if (detaching) detach(t4);
|
|
33936
34377
|
if (if_block1) if_block1.d(detaching);
|
|
33937
|
-
if (detaching) detach(
|
|
34378
|
+
if (detaching) detach(t1);
|
|
33938
34379
|
destroy_each(each_blocks, detaching);
|
|
33939
|
-
if (detaching) detach(
|
|
34380
|
+
if (detaching) detach(t2);
|
|
33940
34381
|
if (if_block2) if_block2.d(detaching);
|
|
33941
34382
|
if (detaching) detach(if_block2_anchor);
|
|
33942
34383
|
}
|
|
@@ -33949,12 +34390,12 @@ function create_fragment$3(ctx) {
|
|
|
33949
34390
|
let current;
|
|
33950
34391
|
|
|
33951
34392
|
function form_1_formEl_binding(value) {
|
|
33952
|
-
/*form_1_formEl_binding*/ ctx[
|
|
34393
|
+
/*form_1_formEl_binding*/ ctx[12](value);
|
|
33953
34394
|
}
|
|
33954
34395
|
|
|
33955
34396
|
let form_1_props = {
|
|
33956
34397
|
ariaDescribedBy: "formFailureMessageAlert",
|
|
33957
|
-
onSubmitWhenValid: /*form*/ ctx[
|
|
34398
|
+
onSubmitWhenValid: /*form*/ ctx[2]?.submit,
|
|
33958
34399
|
$$slots: { default: [create_default_slot$3] },
|
|
33959
34400
|
$$scope: { ctx }
|
|
33960
34401
|
};
|
|
@@ -33976,9 +34417,9 @@ function create_fragment$3(ctx) {
|
|
|
33976
34417
|
},
|
|
33977
34418
|
p(ctx, [dirty]) {
|
|
33978
34419
|
const form_1_changes = {};
|
|
33979
|
-
if (dirty & /*form*/
|
|
34420
|
+
if (dirty & /*form*/ 4) form_1_changes.onSubmitWhenValid = /*form*/ ctx[2]?.submit;
|
|
33980
34421
|
|
|
33981
|
-
if (dirty & /*$$scope, journey, metadata, step, $styleStore, alertNeedsFocus, formMessageKey, form, linkWrapper*/
|
|
34422
|
+
if (dirty & /*$$scope, journey, metadata, step, $styleStore, alertNeedsFocus, formMessageKey, form, linkWrapper, componentStyle*/ 66558) {
|
|
33982
34423
|
form_1_changes.$$scope = { dirty, ctx };
|
|
33983
34424
|
}
|
|
33984
34425
|
|
|
@@ -34007,7 +34448,8 @@ function create_fragment$3(ctx) {
|
|
|
34007
34448
|
|
|
34008
34449
|
function instance$3($$self, $$props, $$invalidate) {
|
|
34009
34450
|
let $styleStore;
|
|
34010
|
-
component_subscribe($$self, styleStore, $$value => $$invalidate(
|
|
34451
|
+
component_subscribe($$self, styleStore, $$value => $$invalidate(9, $styleStore = $$value));
|
|
34452
|
+
let { componentStyle } = $$props;
|
|
34011
34453
|
let { form } = $$props;
|
|
34012
34454
|
let { formEl = null } = $$props;
|
|
34013
34455
|
let { journey } = $$props;
|
|
@@ -34027,15 +34469,25 @@ function instance$3($$self, $$props, $$invalidate) {
|
|
|
34027
34469
|
}
|
|
34028
34470
|
|
|
34029
34471
|
afterUpdate(() => {
|
|
34030
|
-
$$invalidate(
|
|
34472
|
+
$$invalidate(6, alertNeedsFocus = !!form?.message);
|
|
34031
34473
|
});
|
|
34032
34474
|
|
|
34033
|
-
onMount(() =>
|
|
34475
|
+
onMount(() => {
|
|
34476
|
+
if (componentStyle === 'modal') {
|
|
34477
|
+
captureLinks(linkWrapper, journey);
|
|
34478
|
+
}
|
|
34479
|
+
});
|
|
34480
|
+
|
|
34481
|
+
onMount(() => {
|
|
34482
|
+
if (componentStyle === 'modal') {
|
|
34483
|
+
captureLinks(linkWrapper, journey);
|
|
34484
|
+
}
|
|
34485
|
+
});
|
|
34034
34486
|
|
|
34035
34487
|
function p_binding($$value) {
|
|
34036
34488
|
binding_callbacks[$$value ? 'unshift' : 'push'](() => {
|
|
34037
34489
|
linkWrapper = $$value;
|
|
34038
|
-
$$invalidate(
|
|
34490
|
+
$$invalidate(8, linkWrapper);
|
|
34039
34491
|
});
|
|
34040
34492
|
}
|
|
34041
34493
|
|
|
@@ -34045,23 +34497,25 @@ function instance$3($$self, $$props, $$invalidate) {
|
|
|
34045
34497
|
}
|
|
34046
34498
|
|
|
34047
34499
|
$$self.$$set = $$props => {
|
|
34048
|
-
if ('
|
|
34500
|
+
if ('componentStyle' in $$props) $$invalidate(1, componentStyle = $$props.componentStyle);
|
|
34501
|
+
if ('form' in $$props) $$invalidate(2, form = $$props.form);
|
|
34049
34502
|
if ('formEl' in $$props) $$invalidate(0, formEl = $$props.formEl);
|
|
34050
|
-
if ('journey' in $$props) $$invalidate(
|
|
34051
|
-
if ('metadata' in $$props) $$invalidate(
|
|
34052
|
-
if ('step' in $$props) $$invalidate(
|
|
34503
|
+
if ('journey' in $$props) $$invalidate(3, journey = $$props.journey);
|
|
34504
|
+
if ('metadata' in $$props) $$invalidate(4, metadata = $$props.metadata);
|
|
34505
|
+
if ('step' in $$props) $$invalidate(5, step = $$props.step);
|
|
34053
34506
|
};
|
|
34054
34507
|
|
|
34055
34508
|
$$self.$$.update = () => {
|
|
34056
|
-
if ($$self.$$.dirty & /*form*/
|
|
34509
|
+
if ($$self.$$.dirty & /*form*/ 4) {
|
|
34057
34510
|
{
|
|
34058
|
-
$$invalidate(
|
|
34511
|
+
$$invalidate(7, formMessageKey = convertStringToKey(form?.message));
|
|
34059
34512
|
}
|
|
34060
34513
|
}
|
|
34061
34514
|
};
|
|
34062
34515
|
|
|
34063
34516
|
return [
|
|
34064
34517
|
formEl,
|
|
34518
|
+
componentStyle,
|
|
34065
34519
|
form,
|
|
34066
34520
|
journey,
|
|
34067
34521
|
metadata,
|
|
@@ -34081,26 +34535,93 @@ class Registration extends SvelteComponent {
|
|
|
34081
34535
|
super();
|
|
34082
34536
|
|
|
34083
34537
|
init(this, options, instance$3, create_fragment$3, safe_not_equal, {
|
|
34084
|
-
|
|
34538
|
+
componentStyle: 1,
|
|
34539
|
+
form: 2,
|
|
34085
34540
|
formEl: 0,
|
|
34086
|
-
journey:
|
|
34087
|
-
metadata:
|
|
34088
|
-
step:
|
|
34541
|
+
journey: 3,
|
|
34542
|
+
metadata: 4,
|
|
34543
|
+
step: 5
|
|
34089
34544
|
});
|
|
34090
34545
|
}
|
|
34091
34546
|
}
|
|
34092
34547
|
|
|
34093
|
-
/* src/lib/journey/stages/
|
|
34548
|
+
/* src/lib/journey/stages/login.svelte generated by Svelte v3.55.1 */
|
|
34094
34549
|
|
|
34095
34550
|
function get_each_context(ctx, list, i) {
|
|
34096
34551
|
const child_ctx = ctx.slice();
|
|
34097
|
-
child_ctx[
|
|
34098
|
-
child_ctx[
|
|
34552
|
+
child_ctx[15] = list[i];
|
|
34553
|
+
child_ctx[17] = i;
|
|
34099
34554
|
return child_ctx;
|
|
34100
34555
|
}
|
|
34101
34556
|
|
|
34102
|
-
// (
|
|
34103
|
-
function
|
|
34557
|
+
// (45:2) {#if componentStyle !== 'inline'}
|
|
34558
|
+
function create_if_block_3$1(ctx) {
|
|
34559
|
+
let t0;
|
|
34560
|
+
let h1;
|
|
34561
|
+
let t1;
|
|
34562
|
+
let current;
|
|
34563
|
+
let if_block = /*form*/ ctx[2]?.icon && create_if_block_4();
|
|
34564
|
+
t1 = new Locale_strings({ props: { key: "loginHeader" } });
|
|
34565
|
+
|
|
34566
|
+
return {
|
|
34567
|
+
c() {
|
|
34568
|
+
if (if_block) if_block.c();
|
|
34569
|
+
t0 = space();
|
|
34570
|
+
h1 = element("h1");
|
|
34571
|
+
create_component(t1.$$.fragment);
|
|
34572
|
+
attr(h1, "class", "tw_primary-header dark:tw_primary-header_dark");
|
|
34573
|
+
},
|
|
34574
|
+
m(target, anchor) {
|
|
34575
|
+
if (if_block) if_block.m(target, anchor);
|
|
34576
|
+
insert(target, t0, anchor);
|
|
34577
|
+
insert(target, h1, anchor);
|
|
34578
|
+
mount_component(t1, h1, null);
|
|
34579
|
+
current = true;
|
|
34580
|
+
},
|
|
34581
|
+
p(ctx, dirty) {
|
|
34582
|
+
if (/*form*/ ctx[2]?.icon) {
|
|
34583
|
+
if (if_block) {
|
|
34584
|
+
if (dirty & /*form*/ 4) {
|
|
34585
|
+
transition_in(if_block, 1);
|
|
34586
|
+
}
|
|
34587
|
+
} else {
|
|
34588
|
+
if_block = create_if_block_4();
|
|
34589
|
+
if_block.c();
|
|
34590
|
+
transition_in(if_block, 1);
|
|
34591
|
+
if_block.m(t0.parentNode, t0);
|
|
34592
|
+
}
|
|
34593
|
+
} else if (if_block) {
|
|
34594
|
+
group_outros();
|
|
34595
|
+
|
|
34596
|
+
transition_out(if_block, 1, 1, () => {
|
|
34597
|
+
if_block = null;
|
|
34598
|
+
});
|
|
34599
|
+
|
|
34600
|
+
check_outros();
|
|
34601
|
+
}
|
|
34602
|
+
},
|
|
34603
|
+
i(local) {
|
|
34604
|
+
if (current) return;
|
|
34605
|
+
transition_in(if_block);
|
|
34606
|
+
transition_in(t1.$$.fragment, local);
|
|
34607
|
+
current = true;
|
|
34608
|
+
},
|
|
34609
|
+
o(local) {
|
|
34610
|
+
transition_out(if_block);
|
|
34611
|
+
transition_out(t1.$$.fragment, local);
|
|
34612
|
+
current = false;
|
|
34613
|
+
},
|
|
34614
|
+
d(detaching) {
|
|
34615
|
+
if (if_block) if_block.d(detaching);
|
|
34616
|
+
if (detaching) detach(t0);
|
|
34617
|
+
if (detaching) detach(h1);
|
|
34618
|
+
destroy_component(t1);
|
|
34619
|
+
}
|
|
34620
|
+
};
|
|
34621
|
+
}
|
|
34622
|
+
|
|
34623
|
+
// (46:4) {#if form?.icon}
|
|
34624
|
+
function create_if_block_4(ctx) {
|
|
34104
34625
|
let div;
|
|
34105
34626
|
let keyicon;
|
|
34106
34627
|
let current;
|
|
@@ -34139,15 +34660,15 @@ function create_if_block_2$1(ctx) {
|
|
|
34139
34660
|
};
|
|
34140
34661
|
}
|
|
34141
34662
|
|
|
34142
|
-
// (
|
|
34143
|
-
function
|
|
34663
|
+
// (56:2) {#if form?.message}
|
|
34664
|
+
function create_if_block_2$1(ctx) {
|
|
34144
34665
|
let alert;
|
|
34145
34666
|
let current;
|
|
34146
34667
|
|
|
34147
34668
|
alert = new Alert({
|
|
34148
34669
|
props: {
|
|
34149
34670
|
id: "formFailureMessageAlert",
|
|
34150
|
-
needsFocus: /*alertNeedsFocus*/ ctx[
|
|
34671
|
+
needsFocus: /*alertNeedsFocus*/ ctx[6],
|
|
34151
34672
|
type: "error",
|
|
34152
34673
|
$$slots: { default: [create_default_slot_2] },
|
|
34153
34674
|
$$scope: { ctx }
|
|
@@ -34164,9 +34685,9 @@ function create_if_block_1$1(ctx) {
|
|
|
34164
34685
|
},
|
|
34165
34686
|
p(ctx, dirty) {
|
|
34166
34687
|
const alert_changes = {};
|
|
34167
|
-
if (dirty & /*alertNeedsFocus*/
|
|
34688
|
+
if (dirty & /*alertNeedsFocus*/ 64) alert_changes.needsFocus = /*alertNeedsFocus*/ ctx[6];
|
|
34168
34689
|
|
|
34169
|
-
if (dirty & /*$$scope, formMessageKey, form*/
|
|
34690
|
+
if (dirty & /*$$scope, formMessageKey, form*/ 262276) {
|
|
34170
34691
|
alert_changes.$$scope = { dirty, ctx };
|
|
34171
34692
|
}
|
|
34172
34693
|
|
|
@@ -34187,9 +34708,9 @@ function create_if_block_1$1(ctx) {
|
|
|
34187
34708
|
};
|
|
34188
34709
|
}
|
|
34189
34710
|
|
|
34190
|
-
// (
|
|
34711
|
+
// (57:4) <Alert id="formFailureMessageAlert" needsFocus={alertNeedsFocus} type="error">
|
|
34191
34712
|
function create_default_slot_2(ctx) {
|
|
34192
|
-
let t_value = interpolate(/*formMessageKey*/ ctx[
|
|
34713
|
+
let t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "";
|
|
34193
34714
|
let t;
|
|
34194
34715
|
|
|
34195
34716
|
return {
|
|
@@ -34200,7 +34721,7 @@ function create_default_slot_2(ctx) {
|
|
|
34200
34721
|
insert(target, t, anchor);
|
|
34201
34722
|
},
|
|
34202
34723
|
p(ctx, dirty) {
|
|
34203
|
-
if (dirty & /*formMessageKey, form*/
|
|
34724
|
+
if (dirty & /*formMessageKey, form*/ 132 && t_value !== (t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "")) set_data(t, t_value);
|
|
34204
34725
|
},
|
|
34205
34726
|
d(detaching) {
|
|
34206
34727
|
if (detaching) detach(t);
|
|
@@ -34208,7 +34729,7 @@ function create_default_slot_2(ctx) {
|
|
|
34208
34729
|
};
|
|
34209
34730
|
}
|
|
34210
34731
|
|
|
34211
|
-
// (
|
|
34732
|
+
// (62:2) {#each step?.callbacks as callback, idx}
|
|
34212
34733
|
function create_each_block(ctx) {
|
|
34213
34734
|
let callbackmapper;
|
|
34214
34735
|
let current;
|
|
@@ -34216,11 +34737,11 @@ function create_each_block(ctx) {
|
|
|
34216
34737
|
callbackmapper = new Callback_mapper({
|
|
34217
34738
|
props: {
|
|
34218
34739
|
props: {
|
|
34219
|
-
callback: /*callback*/ ctx[
|
|
34220
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
34221
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
34222
|
-
stepMetadata: /*metadata*/ ctx[
|
|
34223
|
-
style: /*$styleStore*/ ctx[
|
|
34740
|
+
callback: /*callback*/ ctx[15],
|
|
34741
|
+
callbackMetadata: /*metadata*/ ctx[4]?.callbacks[/*idx*/ ctx[17]],
|
|
34742
|
+
selfSubmitFunction: /*determineSubmission*/ ctx[10],
|
|
34743
|
+
stepMetadata: /*metadata*/ ctx[4]?.step && { .../*metadata*/ ctx[4].step },
|
|
34744
|
+
style: /*$styleStore*/ ctx[9]
|
|
34224
34745
|
}
|
|
34225
34746
|
}
|
|
34226
34747
|
});
|
|
@@ -34236,12 +34757,12 @@ function create_each_block(ctx) {
|
|
|
34236
34757
|
p(ctx, dirty) {
|
|
34237
34758
|
const callbackmapper_changes = {};
|
|
34238
34759
|
|
|
34239
|
-
if (dirty & /*step, metadata, $styleStore*/
|
|
34240
|
-
callback: /*callback*/ ctx[
|
|
34241
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
34242
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
34243
|
-
stepMetadata: /*metadata*/ ctx[
|
|
34244
|
-
style: /*$styleStore*/ ctx[
|
|
34760
|
+
if (dirty & /*step, metadata, $styleStore*/ 560) callbackmapper_changes.props = {
|
|
34761
|
+
callback: /*callback*/ ctx[15],
|
|
34762
|
+
callbackMetadata: /*metadata*/ ctx[4]?.callbacks[/*idx*/ ctx[17]],
|
|
34763
|
+
selfSubmitFunction: /*determineSubmission*/ ctx[10],
|
|
34764
|
+
stepMetadata: /*metadata*/ ctx[4]?.step && { .../*metadata*/ ctx[4].step },
|
|
34765
|
+
style: /*$styleStore*/ ctx[9]
|
|
34245
34766
|
};
|
|
34246
34767
|
|
|
34247
34768
|
callbackmapper.$set(callbackmapper_changes);
|
|
@@ -34261,14 +34782,14 @@ function create_each_block(ctx) {
|
|
|
34261
34782
|
};
|
|
34262
34783
|
}
|
|
34263
34784
|
|
|
34264
|
-
// (
|
|
34265
|
-
function
|
|
34785
|
+
// (74:2) {#if metadata?.step?.derived.isUserInputOptional || !metadata?.step?.derived.isStepSelfSubmittable}
|
|
34786
|
+
function create_if_block_1$1(ctx) {
|
|
34266
34787
|
let button;
|
|
34267
34788
|
let current;
|
|
34268
34789
|
|
|
34269
34790
|
button = new Button({
|
|
34270
34791
|
props: {
|
|
34271
|
-
busy: /*journey*/ ctx[
|
|
34792
|
+
busy: /*journey*/ ctx[3]?.loading,
|
|
34272
34793
|
style: "primary",
|
|
34273
34794
|
type: "submit",
|
|
34274
34795
|
width: "full",
|
|
@@ -34287,9 +34808,9 @@ function create_if_block$2(ctx) {
|
|
|
34287
34808
|
},
|
|
34288
34809
|
p(ctx, dirty) {
|
|
34289
34810
|
const button_changes = {};
|
|
34290
|
-
if (dirty & /*journey*/
|
|
34811
|
+
if (dirty & /*journey*/ 8) button_changes.busy = /*journey*/ ctx[3]?.loading;
|
|
34291
34812
|
|
|
34292
|
-
if (dirty & /*$$scope*/
|
|
34813
|
+
if (dirty & /*$$scope*/ 262144) {
|
|
34293
34814
|
button_changes.$$scope = { dirty, ctx };
|
|
34294
34815
|
}
|
|
34295
34816
|
|
|
@@ -34310,7 +34831,7 @@ function create_if_block$2(ctx) {
|
|
|
34310
34831
|
};
|
|
34311
34832
|
}
|
|
34312
34833
|
|
|
34313
|
-
// (
|
|
34834
|
+
// (75:4) <Button busy={journey?.loading} style="primary" type="submit" width="full">
|
|
34314
34835
|
function create_default_slot_1$1(ctx) {
|
|
34315
34836
|
let t;
|
|
34316
34837
|
let current;
|
|
@@ -34340,31 +34861,99 @@ function create_default_slot_1$1(ctx) {
|
|
|
34340
34861
|
};
|
|
34341
34862
|
}
|
|
34342
34863
|
|
|
34343
|
-
// (
|
|
34344
|
-
function
|
|
34345
|
-
let t0;
|
|
34346
|
-
let h1;
|
|
34347
|
-
let t1;
|
|
34348
|
-
let t2;
|
|
34349
|
-
let t3;
|
|
34350
|
-
let t4;
|
|
34351
|
-
let t5;
|
|
34864
|
+
// (80:2) {#if componentStyle !== 'inline'}
|
|
34865
|
+
function create_if_block$2(ctx) {
|
|
34352
34866
|
let p0;
|
|
34353
34867
|
let button0;
|
|
34354
|
-
let
|
|
34868
|
+
let t1;
|
|
34355
34869
|
let button1;
|
|
34356
|
-
let
|
|
34870
|
+
let t3;
|
|
34357
34871
|
let hr;
|
|
34358
|
-
let
|
|
34872
|
+
let t4;
|
|
34359
34873
|
let p1;
|
|
34360
|
-
let
|
|
34874
|
+
let t5;
|
|
34361
34875
|
let current;
|
|
34362
34876
|
let mounted;
|
|
34363
34877
|
let dispose;
|
|
34364
|
-
|
|
34365
|
-
|
|
34366
|
-
|
|
34367
|
-
|
|
34878
|
+
|
|
34879
|
+
t5 = new Locale_strings({
|
|
34880
|
+
props: { key: "dontHaveAnAccount", html: true }
|
|
34881
|
+
});
|
|
34882
|
+
|
|
34883
|
+
return {
|
|
34884
|
+
c() {
|
|
34885
|
+
p0 = element("p");
|
|
34886
|
+
button0 = element("button");
|
|
34887
|
+
button0.textContent = `${interpolate('forgotPassword', null, 'Forgot Password?')}`;
|
|
34888
|
+
t1 = text("\n \n ");
|
|
34889
|
+
button1 = element("button");
|
|
34890
|
+
button1.textContent = `${interpolate('forgotUsername', null, 'Forgot Username?')}`;
|
|
34891
|
+
t3 = space();
|
|
34892
|
+
hr = element("hr");
|
|
34893
|
+
t4 = space();
|
|
34894
|
+
p1 = element("p");
|
|
34895
|
+
create_component(t5.$$.fragment);
|
|
34896
|
+
attr(p0, "class", "tw_my-4 tw_text-base tw_text-center tw_text-link-dark dark:tw_text-link-light");
|
|
34897
|
+
attr(hr, "class", "tw_border-0 tw_border-b tw_border-secondary-light dark:tw_border-secondary-dark");
|
|
34898
|
+
attr(p1, "class", "tw_text-base tw_text-center tw_py-4 tw_text-secondary-dark dark:tw_text-secondary-light");
|
|
34899
|
+
},
|
|
34900
|
+
m(target, anchor) {
|
|
34901
|
+
insert(target, p0, anchor);
|
|
34902
|
+
append(p0, button0);
|
|
34903
|
+
append(p0, t1);
|
|
34904
|
+
append(p0, button1);
|
|
34905
|
+
insert(target, t3, anchor);
|
|
34906
|
+
insert(target, hr, anchor);
|
|
34907
|
+
insert(target, t4, anchor);
|
|
34908
|
+
insert(target, p1, anchor);
|
|
34909
|
+
mount_component(t5, p1, null);
|
|
34910
|
+
/*p1_binding*/ ctx[13](p1);
|
|
34911
|
+
current = true;
|
|
34912
|
+
|
|
34913
|
+
if (!mounted) {
|
|
34914
|
+
dispose = [
|
|
34915
|
+
listen(button0, "click", prevent_default(/*click_handler*/ ctx[11])),
|
|
34916
|
+
listen(button1, "click", prevent_default(/*click_handler_1*/ ctx[12]))
|
|
34917
|
+
];
|
|
34918
|
+
|
|
34919
|
+
mounted = true;
|
|
34920
|
+
}
|
|
34921
|
+
},
|
|
34922
|
+
p: noop,
|
|
34923
|
+
i(local) {
|
|
34924
|
+
if (current) return;
|
|
34925
|
+
transition_in(t5.$$.fragment, local);
|
|
34926
|
+
current = true;
|
|
34927
|
+
},
|
|
34928
|
+
o(local) {
|
|
34929
|
+
transition_out(t5.$$.fragment, local);
|
|
34930
|
+
current = false;
|
|
34931
|
+
},
|
|
34932
|
+
d(detaching) {
|
|
34933
|
+
if (detaching) detach(p0);
|
|
34934
|
+
if (detaching) detach(t3);
|
|
34935
|
+
if (detaching) detach(hr);
|
|
34936
|
+
if (detaching) detach(t4);
|
|
34937
|
+
if (detaching) detach(p1);
|
|
34938
|
+
destroy_component(t5);
|
|
34939
|
+
/*p1_binding*/ ctx[13](null);
|
|
34940
|
+
mounted = false;
|
|
34941
|
+
run_all(dispose);
|
|
34942
|
+
}
|
|
34943
|
+
};
|
|
34944
|
+
}
|
|
34945
|
+
|
|
34946
|
+
// (44:0) <Form bind:formEl ariaDescribedBy="formFailureMessageAlert" onSubmitWhenValid={form?.submit}>
|
|
34947
|
+
function create_default_slot$2(ctx) {
|
|
34948
|
+
let t0;
|
|
34949
|
+
let t1;
|
|
34950
|
+
let t2;
|
|
34951
|
+
let t3;
|
|
34952
|
+
let if_block3_anchor;
|
|
34953
|
+
let current;
|
|
34954
|
+
let if_block0 = /*componentStyle*/ ctx[1] !== 'inline' && create_if_block_3$1(ctx);
|
|
34955
|
+
let if_block1 = /*form*/ ctx[2]?.message && create_if_block_2$1(ctx);
|
|
34956
|
+
let each_value = /*step*/ ctx[5]?.callbacks;
|
|
34368
34957
|
let each_blocks = [];
|
|
34369
34958
|
|
|
34370
34959
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -34375,90 +34964,53 @@ function create_default_slot$2(ctx) {
|
|
|
34375
34964
|
each_blocks[i] = null;
|
|
34376
34965
|
});
|
|
34377
34966
|
|
|
34378
|
-
let if_block2 = (/*metadata*/ ctx[
|
|
34379
|
-
|
|
34380
|
-
t11 = new Locale_strings({
|
|
34381
|
-
props: { key: "dontHaveAnAccount", html: true }
|
|
34382
|
-
});
|
|
34967
|
+
let if_block2 = (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) && create_if_block_1$1(ctx);
|
|
34968
|
+
let if_block3 = /*componentStyle*/ ctx[1] !== 'inline' && create_if_block$2(ctx);
|
|
34383
34969
|
|
|
34384
34970
|
return {
|
|
34385
34971
|
c() {
|
|
34386
34972
|
if (if_block0) if_block0.c();
|
|
34387
34973
|
t0 = space();
|
|
34388
|
-
h1 = element("h1");
|
|
34389
|
-
create_component(t1.$$.fragment);
|
|
34390
|
-
t2 = space();
|
|
34391
34974
|
if (if_block1) if_block1.c();
|
|
34392
|
-
|
|
34975
|
+
t1 = space();
|
|
34393
34976
|
|
|
34394
34977
|
for (let i = 0; i < each_blocks.length; i += 1) {
|
|
34395
34978
|
each_blocks[i].c();
|
|
34396
34979
|
}
|
|
34397
34980
|
|
|
34398
|
-
|
|
34981
|
+
t2 = space();
|
|
34399
34982
|
if (if_block2) if_block2.c();
|
|
34400
|
-
|
|
34401
|
-
|
|
34402
|
-
|
|
34403
|
-
button0.textContent = `${interpolate('forgotPassword', null, 'Forgot Password?')}`;
|
|
34404
|
-
t7 = text("\n \n ");
|
|
34405
|
-
button1 = element("button");
|
|
34406
|
-
button1.textContent = `${interpolate('forgotUsername', null, 'Forgot Username?')}`;
|
|
34407
|
-
t9 = space();
|
|
34408
|
-
hr = element("hr");
|
|
34409
|
-
t10 = space();
|
|
34410
|
-
p1 = element("p");
|
|
34411
|
-
create_component(t11.$$.fragment);
|
|
34412
|
-
attr(h1, "class", "tw_primary-header dark:tw_primary-header_dark");
|
|
34413
|
-
attr(p0, "class", "tw_my-4 tw_text-base tw_text-center tw_text-link-dark dark:tw_text-link-light");
|
|
34414
|
-
attr(hr, "class", "tw_border-0 tw_border-b tw_border-secondary-light dark:tw_border-secondary-dark");
|
|
34415
|
-
attr(p1, "class", "tw_text-base tw_text-center tw_py-4 tw_text-secondary-dark dark:tw_text-secondary-light");
|
|
34983
|
+
t3 = space();
|
|
34984
|
+
if (if_block3) if_block3.c();
|
|
34985
|
+
if_block3_anchor = empty();
|
|
34416
34986
|
},
|
|
34417
34987
|
m(target, anchor) {
|
|
34418
34988
|
if (if_block0) if_block0.m(target, anchor);
|
|
34419
34989
|
insert(target, t0, anchor);
|
|
34420
|
-
insert(target, h1, anchor);
|
|
34421
|
-
mount_component(t1, h1, null);
|
|
34422
|
-
insert(target, t2, anchor);
|
|
34423
34990
|
if (if_block1) if_block1.m(target, anchor);
|
|
34424
|
-
insert(target,
|
|
34991
|
+
insert(target, t1, anchor);
|
|
34425
34992
|
|
|
34426
34993
|
for (let i = 0; i < each_blocks.length; i += 1) {
|
|
34427
34994
|
each_blocks[i].m(target, anchor);
|
|
34428
34995
|
}
|
|
34429
34996
|
|
|
34430
|
-
insert(target,
|
|
34997
|
+
insert(target, t2, anchor);
|
|
34431
34998
|
if (if_block2) if_block2.m(target, anchor);
|
|
34432
|
-
insert(target,
|
|
34433
|
-
|
|
34434
|
-
|
|
34435
|
-
append(p0, t7);
|
|
34436
|
-
append(p0, button1);
|
|
34437
|
-
insert(target, t9, anchor);
|
|
34438
|
-
insert(target, hr, anchor);
|
|
34439
|
-
insert(target, t10, anchor);
|
|
34440
|
-
insert(target, p1, anchor);
|
|
34441
|
-
mount_component(t11, p1, null);
|
|
34442
|
-
/*p1_binding*/ ctx[12](p1);
|
|
34999
|
+
insert(target, t3, anchor);
|
|
35000
|
+
if (if_block3) if_block3.m(target, anchor);
|
|
35001
|
+
insert(target, if_block3_anchor, anchor);
|
|
34443
35002
|
current = true;
|
|
34444
|
-
|
|
34445
|
-
if (!mounted) {
|
|
34446
|
-
dispose = [
|
|
34447
|
-
listen(button0, "click", prevent_default(/*click_handler*/ ctx[10])),
|
|
34448
|
-
listen(button1, "click", prevent_default(/*click_handler_1*/ ctx[11]))
|
|
34449
|
-
];
|
|
34450
|
-
|
|
34451
|
-
mounted = true;
|
|
34452
|
-
}
|
|
34453
35003
|
},
|
|
34454
35004
|
p(ctx, dirty) {
|
|
34455
|
-
if (/*
|
|
35005
|
+
if (/*componentStyle*/ ctx[1] !== 'inline') {
|
|
34456
35006
|
if (if_block0) {
|
|
34457
|
-
|
|
35007
|
+
if_block0.p(ctx, dirty);
|
|
35008
|
+
|
|
35009
|
+
if (dirty & /*componentStyle*/ 2) {
|
|
34458
35010
|
transition_in(if_block0, 1);
|
|
34459
35011
|
}
|
|
34460
35012
|
} else {
|
|
34461
|
-
if_block0 =
|
|
35013
|
+
if_block0 = create_if_block_3$1(ctx);
|
|
34462
35014
|
if_block0.c();
|
|
34463
35015
|
transition_in(if_block0, 1);
|
|
34464
35016
|
if_block0.m(t0.parentNode, t0);
|
|
@@ -34473,18 +35025,18 @@ function create_default_slot$2(ctx) {
|
|
|
34473
35025
|
check_outros();
|
|
34474
35026
|
}
|
|
34475
35027
|
|
|
34476
|
-
if (/*form*/ ctx[
|
|
35028
|
+
if (/*form*/ ctx[2]?.message) {
|
|
34477
35029
|
if (if_block1) {
|
|
34478
35030
|
if_block1.p(ctx, dirty);
|
|
34479
35031
|
|
|
34480
|
-
if (dirty & /*form*/
|
|
35032
|
+
if (dirty & /*form*/ 4) {
|
|
34481
35033
|
transition_in(if_block1, 1);
|
|
34482
35034
|
}
|
|
34483
35035
|
} else {
|
|
34484
|
-
if_block1 =
|
|
35036
|
+
if_block1 = create_if_block_2$1(ctx);
|
|
34485
35037
|
if_block1.c();
|
|
34486
35038
|
transition_in(if_block1, 1);
|
|
34487
|
-
if_block1.m(
|
|
35039
|
+
if_block1.m(t1.parentNode, t1);
|
|
34488
35040
|
}
|
|
34489
35041
|
} else if (if_block1) {
|
|
34490
35042
|
group_outros();
|
|
@@ -34496,8 +35048,8 @@ function create_default_slot$2(ctx) {
|
|
|
34496
35048
|
check_outros();
|
|
34497
35049
|
}
|
|
34498
35050
|
|
|
34499
|
-
if (dirty & /*step, metadata, determineSubmission, $styleStore*/
|
|
34500
|
-
each_value = /*step*/ ctx[
|
|
35051
|
+
if (dirty & /*step, metadata, determineSubmission, $styleStore*/ 1584) {
|
|
35052
|
+
each_value = /*step*/ ctx[5]?.callbacks;
|
|
34501
35053
|
let i;
|
|
34502
35054
|
|
|
34503
35055
|
for (i = 0; i < each_value.length; i += 1) {
|
|
@@ -34510,7 +35062,7 @@ function create_default_slot$2(ctx) {
|
|
|
34510
35062
|
each_blocks[i] = create_each_block(child_ctx);
|
|
34511
35063
|
each_blocks[i].c();
|
|
34512
35064
|
transition_in(each_blocks[i], 1);
|
|
34513
|
-
each_blocks[i].m(
|
|
35065
|
+
each_blocks[i].m(t2.parentNode, t2);
|
|
34514
35066
|
}
|
|
34515
35067
|
}
|
|
34516
35068
|
|
|
@@ -34523,18 +35075,18 @@ function create_default_slot$2(ctx) {
|
|
|
34523
35075
|
check_outros();
|
|
34524
35076
|
}
|
|
34525
35077
|
|
|
34526
|
-
if (/*metadata*/ ctx[
|
|
35078
|
+
if (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) {
|
|
34527
35079
|
if (if_block2) {
|
|
34528
35080
|
if_block2.p(ctx, dirty);
|
|
34529
35081
|
|
|
34530
|
-
if (dirty & /*metadata*/
|
|
35082
|
+
if (dirty & /*metadata*/ 16) {
|
|
34531
35083
|
transition_in(if_block2, 1);
|
|
34532
35084
|
}
|
|
34533
35085
|
} else {
|
|
34534
|
-
if_block2 =
|
|
35086
|
+
if_block2 = create_if_block_1$1(ctx);
|
|
34535
35087
|
if_block2.c();
|
|
34536
35088
|
transition_in(if_block2, 1);
|
|
34537
|
-
if_block2.m(
|
|
35089
|
+
if_block2.m(t3.parentNode, t3);
|
|
34538
35090
|
}
|
|
34539
35091
|
} else if (if_block2) {
|
|
34540
35092
|
group_outros();
|
|
@@ -34545,11 +35097,33 @@ function create_default_slot$2(ctx) {
|
|
|
34545
35097
|
|
|
34546
35098
|
check_outros();
|
|
34547
35099
|
}
|
|
35100
|
+
|
|
35101
|
+
if (/*componentStyle*/ ctx[1] !== 'inline') {
|
|
35102
|
+
if (if_block3) {
|
|
35103
|
+
if_block3.p(ctx, dirty);
|
|
35104
|
+
|
|
35105
|
+
if (dirty & /*componentStyle*/ 2) {
|
|
35106
|
+
transition_in(if_block3, 1);
|
|
35107
|
+
}
|
|
35108
|
+
} else {
|
|
35109
|
+
if_block3 = create_if_block$2(ctx);
|
|
35110
|
+
if_block3.c();
|
|
35111
|
+
transition_in(if_block3, 1);
|
|
35112
|
+
if_block3.m(if_block3_anchor.parentNode, if_block3_anchor);
|
|
35113
|
+
}
|
|
35114
|
+
} else if (if_block3) {
|
|
35115
|
+
group_outros();
|
|
35116
|
+
|
|
35117
|
+
transition_out(if_block3, 1, 1, () => {
|
|
35118
|
+
if_block3 = null;
|
|
35119
|
+
});
|
|
35120
|
+
|
|
35121
|
+
check_outros();
|
|
35122
|
+
}
|
|
34548
35123
|
},
|
|
34549
35124
|
i(local) {
|
|
34550
35125
|
if (current) return;
|
|
34551
35126
|
transition_in(if_block0);
|
|
34552
|
-
transition_in(t1.$$.fragment, local);
|
|
34553
35127
|
transition_in(if_block1);
|
|
34554
35128
|
|
|
34555
35129
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -34557,12 +35131,11 @@ function create_default_slot$2(ctx) {
|
|
|
34557
35131
|
}
|
|
34558
35132
|
|
|
34559
35133
|
transition_in(if_block2);
|
|
34560
|
-
transition_in(
|
|
35134
|
+
transition_in(if_block3);
|
|
34561
35135
|
current = true;
|
|
34562
35136
|
},
|
|
34563
35137
|
o(local) {
|
|
34564
35138
|
transition_out(if_block0);
|
|
34565
|
-
transition_out(t1.$$.fragment, local);
|
|
34566
35139
|
transition_out(if_block1);
|
|
34567
35140
|
each_blocks = each_blocks.filter(Boolean);
|
|
34568
35141
|
|
|
@@ -34571,30 +35144,20 @@ function create_default_slot$2(ctx) {
|
|
|
34571
35144
|
}
|
|
34572
35145
|
|
|
34573
35146
|
transition_out(if_block2);
|
|
34574
|
-
transition_out(
|
|
35147
|
+
transition_out(if_block3);
|
|
34575
35148
|
current = false;
|
|
34576
35149
|
},
|
|
34577
35150
|
d(detaching) {
|
|
34578
35151
|
if (if_block0) if_block0.d(detaching);
|
|
34579
35152
|
if (detaching) detach(t0);
|
|
34580
|
-
if (detaching) detach(h1);
|
|
34581
|
-
destroy_component(t1);
|
|
34582
|
-
if (detaching) detach(t2);
|
|
34583
35153
|
if (if_block1) if_block1.d(detaching);
|
|
34584
|
-
if (detaching) detach(
|
|
35154
|
+
if (detaching) detach(t1);
|
|
34585
35155
|
destroy_each(each_blocks, detaching);
|
|
34586
|
-
if (detaching) detach(
|
|
35156
|
+
if (detaching) detach(t2);
|
|
34587
35157
|
if (if_block2) if_block2.d(detaching);
|
|
34588
|
-
if (detaching) detach(
|
|
34589
|
-
if (
|
|
34590
|
-
if (detaching) detach(
|
|
34591
|
-
if (detaching) detach(hr);
|
|
34592
|
-
if (detaching) detach(t10);
|
|
34593
|
-
if (detaching) detach(p1);
|
|
34594
|
-
destroy_component(t11);
|
|
34595
|
-
/*p1_binding*/ ctx[12](null);
|
|
34596
|
-
mounted = false;
|
|
34597
|
-
run_all(dispose);
|
|
35158
|
+
if (detaching) detach(t3);
|
|
35159
|
+
if (if_block3) if_block3.d(detaching);
|
|
35160
|
+
if (detaching) detach(if_block3_anchor);
|
|
34598
35161
|
}
|
|
34599
35162
|
};
|
|
34600
35163
|
}
|
|
@@ -34605,12 +35168,12 @@ function create_fragment$2(ctx) {
|
|
|
34605
35168
|
let current;
|
|
34606
35169
|
|
|
34607
35170
|
function form_1_formEl_binding(value) {
|
|
34608
|
-
/*form_1_formEl_binding*/ ctx[
|
|
35171
|
+
/*form_1_formEl_binding*/ ctx[14](value);
|
|
34609
35172
|
}
|
|
34610
35173
|
|
|
34611
35174
|
let form_1_props = {
|
|
34612
35175
|
ariaDescribedBy: "formFailureMessageAlert",
|
|
34613
|
-
onSubmitWhenValid: /*form*/ ctx[
|
|
35176
|
+
onSubmitWhenValid: /*form*/ ctx[2]?.submit,
|
|
34614
35177
|
$$slots: { default: [create_default_slot$2] },
|
|
34615
35178
|
$$scope: { ctx }
|
|
34616
35179
|
};
|
|
@@ -34632,9 +35195,9 @@ function create_fragment$2(ctx) {
|
|
|
34632
35195
|
},
|
|
34633
35196
|
p(ctx, [dirty]) {
|
|
34634
35197
|
const form_1_changes = {};
|
|
34635
|
-
if (dirty & /*form*/
|
|
35198
|
+
if (dirty & /*form*/ 4) form_1_changes.onSubmitWhenValid = /*form*/ ctx[2]?.submit;
|
|
34636
35199
|
|
|
34637
|
-
if (dirty & /*$$scope, linkWrapper, journey, metadata, step, $styleStore, alertNeedsFocus, formMessageKey, form*/
|
|
35200
|
+
if (dirty & /*$$scope, linkWrapper, journey, componentStyle, metadata, step, $styleStore, alertNeedsFocus, formMessageKey, form*/ 263166) {
|
|
34638
35201
|
form_1_changes.$$scope = { dirty, ctx };
|
|
34639
35202
|
}
|
|
34640
35203
|
|
|
@@ -34663,7 +35226,8 @@ function create_fragment$2(ctx) {
|
|
|
34663
35226
|
|
|
34664
35227
|
function instance$2($$self, $$props, $$invalidate) {
|
|
34665
35228
|
let $styleStore;
|
|
34666
|
-
component_subscribe($$self, styleStore, $$value => $$invalidate(
|
|
35229
|
+
component_subscribe($$self, styleStore, $$value => $$invalidate(9, $styleStore = $$value));
|
|
35230
|
+
let { componentStyle } = $$props;
|
|
34667
35231
|
let { form } = $$props;
|
|
34668
35232
|
let { formEl = null } = $$props;
|
|
34669
35233
|
let { journey } = $$props;
|
|
@@ -34683,10 +35247,14 @@ function instance$2($$self, $$props, $$invalidate) {
|
|
|
34683
35247
|
}
|
|
34684
35248
|
|
|
34685
35249
|
afterUpdate(() => {
|
|
34686
|
-
$$invalidate(
|
|
35250
|
+
$$invalidate(6, alertNeedsFocus = !!form?.message);
|
|
34687
35251
|
});
|
|
34688
35252
|
|
|
34689
|
-
onMount(() =>
|
|
35253
|
+
onMount(() => {
|
|
35254
|
+
if (componentStyle === 'modal') {
|
|
35255
|
+
captureLinks(linkWrapper, journey);
|
|
35256
|
+
}
|
|
35257
|
+
});
|
|
34690
35258
|
|
|
34691
35259
|
const click_handler = () => {
|
|
34692
35260
|
journey.push({ tree: 'ResetPassword' });
|
|
@@ -34699,7 +35267,7 @@ function instance$2($$self, $$props, $$invalidate) {
|
|
|
34699
35267
|
function p1_binding($$value) {
|
|
34700
35268
|
binding_callbacks[$$value ? 'unshift' : 'push'](() => {
|
|
34701
35269
|
linkWrapper = $$value;
|
|
34702
|
-
$$invalidate(
|
|
35270
|
+
$$invalidate(8, linkWrapper);
|
|
34703
35271
|
});
|
|
34704
35272
|
}
|
|
34705
35273
|
|
|
@@ -34709,23 +35277,25 @@ function instance$2($$self, $$props, $$invalidate) {
|
|
|
34709
35277
|
}
|
|
34710
35278
|
|
|
34711
35279
|
$$self.$$set = $$props => {
|
|
34712
|
-
if ('
|
|
35280
|
+
if ('componentStyle' in $$props) $$invalidate(1, componentStyle = $$props.componentStyle);
|
|
35281
|
+
if ('form' in $$props) $$invalidate(2, form = $$props.form);
|
|
34713
35282
|
if ('formEl' in $$props) $$invalidate(0, formEl = $$props.formEl);
|
|
34714
|
-
if ('journey' in $$props) $$invalidate(
|
|
34715
|
-
if ('metadata' in $$props) $$invalidate(
|
|
34716
|
-
if ('step' in $$props) $$invalidate(
|
|
35283
|
+
if ('journey' in $$props) $$invalidate(3, journey = $$props.journey);
|
|
35284
|
+
if ('metadata' in $$props) $$invalidate(4, metadata = $$props.metadata);
|
|
35285
|
+
if ('step' in $$props) $$invalidate(5, step = $$props.step);
|
|
34717
35286
|
};
|
|
34718
35287
|
|
|
34719
35288
|
$$self.$$.update = () => {
|
|
34720
|
-
if ($$self.$$.dirty & /*form*/
|
|
35289
|
+
if ($$self.$$.dirty & /*form*/ 4) {
|
|
34721
35290
|
{
|
|
34722
|
-
$$invalidate(
|
|
35291
|
+
$$invalidate(7, formMessageKey = convertStringToKey(form?.message));
|
|
34723
35292
|
}
|
|
34724
35293
|
}
|
|
34725
35294
|
};
|
|
34726
35295
|
|
|
34727
35296
|
return [
|
|
34728
35297
|
formEl,
|
|
35298
|
+
componentStyle,
|
|
34729
35299
|
form,
|
|
34730
35300
|
journey,
|
|
34731
35301
|
metadata,
|
|
@@ -34742,38 +35312,37 @@ function instance$2($$self, $$props, $$invalidate) {
|
|
|
34742
35312
|
];
|
|
34743
35313
|
}
|
|
34744
35314
|
|
|
34745
|
-
class
|
|
35315
|
+
class Login extends SvelteComponent {
|
|
34746
35316
|
constructor(options) {
|
|
34747
35317
|
super();
|
|
34748
35318
|
|
|
34749
35319
|
init(this, options, instance$2, create_fragment$2, safe_not_equal, {
|
|
34750
|
-
|
|
35320
|
+
componentStyle: 1,
|
|
35321
|
+
form: 2,
|
|
34751
35322
|
formEl: 0,
|
|
34752
|
-
journey:
|
|
34753
|
-
metadata:
|
|
34754
|
-
step:
|
|
35323
|
+
journey: 3,
|
|
35324
|
+
metadata: 4,
|
|
35325
|
+
step: 5
|
|
34755
35326
|
});
|
|
34756
35327
|
}
|
|
34757
35328
|
}
|
|
34758
35329
|
|
|
35330
|
+
/**
|
|
35331
|
+
* @function mapStepToStage - Maps the current step to the proper stage component.
|
|
35332
|
+
* @param {object} currentStep - The current step to check
|
|
35333
|
+
* @returns {object} - The stage Svelte component
|
|
35334
|
+
*/
|
|
34759
35335
|
function mapStepToStage(currentStep) {
|
|
34760
|
-
/** *********************************************************************
|
|
34761
|
-
* SDK INTEGRATION POINT
|
|
34762
|
-
* Summary:SDK step method for getting the stage value
|
|
34763
|
-
* ----------------------------------------------------------------------
|
|
34764
|
-
* Details: This method is helpful in quickly identifying the stage
|
|
34765
|
-
* when you want to provide special layout or handling of the form
|
|
34766
|
-
********************************************************************* */
|
|
34767
35336
|
if (!currentStep || currentStep.type !== 'Step') {
|
|
34768
35337
|
return Generic;
|
|
34769
35338
|
}
|
|
34770
35339
|
switch (currentStep?.getStage && currentStep.getStage()) {
|
|
34771
35340
|
case 'OneTimePassword':
|
|
34772
35341
|
return One_time_password;
|
|
34773
|
-
case '
|
|
35342
|
+
case 'DefaultRegistration':
|
|
34774
35343
|
return Registration;
|
|
34775
|
-
case '
|
|
34776
|
-
return
|
|
35344
|
+
case 'DefaultLogin':
|
|
35345
|
+
return Login;
|
|
34777
35346
|
default:
|
|
34778
35347
|
return Generic;
|
|
34779
35348
|
}
|
|
@@ -34790,7 +35359,7 @@ function create_else_block$1(ctx) {
|
|
|
34790
35359
|
alert = new Alert({
|
|
34791
35360
|
props: {
|
|
34792
35361
|
id: "unrecoverableStepError",
|
|
34793
|
-
needsFocus: /*alertNeedsFocus*/ ctx[
|
|
35362
|
+
needsFocus: /*alertNeedsFocus*/ ctx[4],
|
|
34794
35363
|
type: "error",
|
|
34795
35364
|
$$slots: { default: [create_default_slot_1] },
|
|
34796
35365
|
$$scope: { ctx }
|
|
@@ -34800,7 +35369,7 @@ function create_else_block$1(ctx) {
|
|
|
34800
35369
|
button = new Button({
|
|
34801
35370
|
props: {
|
|
34802
35371
|
style: "secondary",
|
|
34803
|
-
onClick: /*tryAgain*/ ctx[
|
|
35372
|
+
onClick: /*tryAgain*/ ctx[7],
|
|
34804
35373
|
$$slots: { default: [create_default_slot$1] },
|
|
34805
35374
|
$$scope: { ctx }
|
|
34806
35375
|
}
|
|
@@ -34820,16 +35389,16 @@ function create_else_block$1(ctx) {
|
|
|
34820
35389
|
},
|
|
34821
35390
|
p(ctx, dirty) {
|
|
34822
35391
|
const alert_changes = {};
|
|
34823
|
-
if (dirty & /*alertNeedsFocus*/
|
|
35392
|
+
if (dirty & /*alertNeedsFocus*/ 16) alert_changes.needsFocus = /*alertNeedsFocus*/ ctx[4];
|
|
34824
35393
|
|
|
34825
|
-
if (dirty & /*$$scope*/
|
|
35394
|
+
if (dirty & /*$$scope*/ 512) {
|
|
34826
35395
|
alert_changes.$$scope = { dirty, ctx };
|
|
34827
35396
|
}
|
|
34828
35397
|
|
|
34829
35398
|
alert.$set(alert_changes);
|
|
34830
35399
|
const button_changes = {};
|
|
34831
35400
|
|
|
34832
|
-
if (dirty & /*$$scope*/
|
|
35401
|
+
if (dirty & /*$$scope*/ 512) {
|
|
34833
35402
|
button_changes.$$scope = { dirty, ctx };
|
|
34834
35403
|
}
|
|
34835
35404
|
|
|
@@ -34854,7 +35423,7 @@ function create_else_block$1(ctx) {
|
|
|
34854
35423
|
};
|
|
34855
35424
|
}
|
|
34856
35425
|
|
|
34857
|
-
// (
|
|
35426
|
+
// (56:52)
|
|
34858
35427
|
function create_if_block_3(ctx) {
|
|
34859
35428
|
let div;
|
|
34860
35429
|
let spinner;
|
|
@@ -34895,7 +35464,7 @@ function create_if_block_3(ctx) {
|
|
|
34895
35464
|
};
|
|
34896
35465
|
}
|
|
34897
35466
|
|
|
34898
|
-
// (
|
|
35467
|
+
// (30:0) {#if $journeyStore && !$journeyStore.completed}
|
|
34899
35468
|
function create_if_block$1(ctx) {
|
|
34900
35469
|
let current_block_type_index;
|
|
34901
35470
|
let if_block;
|
|
@@ -34905,8 +35474,8 @@ function create_if_block$1(ctx) {
|
|
|
34905
35474
|
const if_blocks = [];
|
|
34906
35475
|
|
|
34907
35476
|
function select_block_type_1(ctx, dirty) {
|
|
34908
|
-
if (!/*$journeyStore*/ ctx[
|
|
34909
|
-
if (/*$journeyStore*/ ctx[
|
|
35477
|
+
if (/*$journeyStore*/ ctx[5] && !/*$journeyStore*/ ctx[5].step) return 0;
|
|
35478
|
+
if (/*$journeyStore*/ ctx[5].step?.type === StepType$1.Step) return 1;
|
|
34910
35479
|
return -1;
|
|
34911
35480
|
}
|
|
34912
35481
|
|
|
@@ -34982,7 +35551,7 @@ function create_if_block$1(ctx) {
|
|
|
34982
35551
|
};
|
|
34983
35552
|
}
|
|
34984
35553
|
|
|
34985
|
-
// (
|
|
35554
|
+
// (61:2) <Alert id="unrecoverableStepError" needsFocus={alertNeedsFocus} type="error">
|
|
34986
35555
|
function create_default_slot_1(ctx) {
|
|
34987
35556
|
let t;
|
|
34988
35557
|
let current;
|
|
@@ -35015,7 +35584,7 @@ function create_default_slot_1(ctx) {
|
|
|
35015
35584
|
};
|
|
35016
35585
|
}
|
|
35017
35586
|
|
|
35018
|
-
// (
|
|
35587
|
+
// (64:2) <Button style="secondary" onClick={tryAgain}>
|
|
35019
35588
|
function create_default_slot$1(ctx) {
|
|
35020
35589
|
let t;
|
|
35021
35590
|
let current;
|
|
@@ -35045,7 +35614,7 @@ function create_default_slot$1(ctx) {
|
|
|
35045
35614
|
};
|
|
35046
35615
|
}
|
|
35047
35616
|
|
|
35048
|
-
// (
|
|
35617
|
+
// (35:55)
|
|
35049
35618
|
function create_if_block_2(ctx) {
|
|
35050
35619
|
let switch_instance;
|
|
35051
35620
|
let updating_formEl;
|
|
@@ -35053,27 +35622,28 @@ function create_if_block_2(ctx) {
|
|
|
35053
35622
|
let current;
|
|
35054
35623
|
|
|
35055
35624
|
function switch_instance_formEl_binding(value) {
|
|
35056
|
-
/*switch_instance_formEl_binding*/ ctx[
|
|
35625
|
+
/*switch_instance_formEl_binding*/ ctx[8](value);
|
|
35057
35626
|
}
|
|
35058
35627
|
|
|
35059
|
-
var switch_value = mapStepToStage(/*$journeyStore*/ ctx[
|
|
35628
|
+
var switch_value = mapStepToStage(/*$journeyStore*/ ctx[5].step);
|
|
35060
35629
|
|
|
35061
35630
|
function switch_props(ctx) {
|
|
35062
35631
|
let switch_instance_props = {
|
|
35632
|
+
componentStyle: /*componentStyle*/ ctx[1],
|
|
35063
35633
|
form: {
|
|
35064
|
-
icon: /*displayIcon*/ ctx[
|
|
35065
|
-
message: /*$journeyStore*/ ctx[
|
|
35066
|
-
status: (/*$journeyStore*/ ctx[
|
|
35067
|
-
submit: /*submitForm*/ ctx[
|
|
35634
|
+
icon: /*displayIcon*/ ctx[2],
|
|
35635
|
+
message: /*$journeyStore*/ ctx[5].error?.message || '',
|
|
35636
|
+
status: (/*$journeyStore*/ ctx[5].error?.code) ? 'error' : 'ok',
|
|
35637
|
+
submit: /*submitForm*/ ctx[6]
|
|
35068
35638
|
},
|
|
35069
35639
|
journey: {
|
|
35070
|
-
loading: /*$journeyStore*/ ctx[
|
|
35071
|
-
pop: /*journeyStore*/ ctx[
|
|
35072
|
-
push: /*journeyStore*/ ctx[
|
|
35640
|
+
loading: /*$journeyStore*/ ctx[5].loading,
|
|
35641
|
+
pop: /*journeyStore*/ ctx[3].pop,
|
|
35642
|
+
push: /*journeyStore*/ ctx[3].push,
|
|
35073
35643
|
stack
|
|
35074
35644
|
},
|
|
35075
|
-
metadata: /*$journeyStore*/ ctx[
|
|
35076
|
-
step: /*$journeyStore*/ ctx[
|
|
35645
|
+
metadata: /*$journeyStore*/ ctx[5].metadata,
|
|
35646
|
+
step: /*$journeyStore*/ ctx[5].step
|
|
35077
35647
|
};
|
|
35078
35648
|
|
|
35079
35649
|
if (/*formEl*/ ctx[0] !== void 0) {
|
|
@@ -35100,23 +35670,24 @@ function create_if_block_2(ctx) {
|
|
|
35100
35670
|
},
|
|
35101
35671
|
p(ctx, dirty) {
|
|
35102
35672
|
const switch_instance_changes = {};
|
|
35673
|
+
if (dirty & /*componentStyle*/ 2) switch_instance_changes.componentStyle = /*componentStyle*/ ctx[1];
|
|
35103
35674
|
|
|
35104
|
-
if (dirty & /*displayIcon, $journeyStore*/
|
|
35105
|
-
icon: /*displayIcon*/ ctx[
|
|
35106
|
-
message: /*$journeyStore*/ ctx[
|
|
35107
|
-
status: (/*$journeyStore*/ ctx[
|
|
35108
|
-
submit: /*submitForm*/ ctx[
|
|
35675
|
+
if (dirty & /*displayIcon, $journeyStore*/ 36) switch_instance_changes.form = {
|
|
35676
|
+
icon: /*displayIcon*/ ctx[2],
|
|
35677
|
+
message: /*$journeyStore*/ ctx[5].error?.message || '',
|
|
35678
|
+
status: (/*$journeyStore*/ ctx[5].error?.code) ? 'error' : 'ok',
|
|
35679
|
+
submit: /*submitForm*/ ctx[6]
|
|
35109
35680
|
};
|
|
35110
35681
|
|
|
35111
|
-
if (dirty & /*$journeyStore, journeyStore*/
|
|
35112
|
-
loading: /*$journeyStore*/ ctx[
|
|
35113
|
-
pop: /*journeyStore*/ ctx[
|
|
35114
|
-
push: /*journeyStore*/ ctx[
|
|
35682
|
+
if (dirty & /*$journeyStore, journeyStore*/ 40) switch_instance_changes.journey = {
|
|
35683
|
+
loading: /*$journeyStore*/ ctx[5].loading,
|
|
35684
|
+
pop: /*journeyStore*/ ctx[3].pop,
|
|
35685
|
+
push: /*journeyStore*/ ctx[3].push,
|
|
35115
35686
|
stack
|
|
35116
35687
|
};
|
|
35117
35688
|
|
|
35118
|
-
if (dirty & /*$journeyStore*/
|
|
35119
|
-
if (dirty & /*$journeyStore*/
|
|
35689
|
+
if (dirty & /*$journeyStore*/ 32) switch_instance_changes.metadata = /*$journeyStore*/ ctx[5].metadata;
|
|
35690
|
+
if (dirty & /*$journeyStore*/ 32) switch_instance_changes.step = /*$journeyStore*/ ctx[5].step;
|
|
35120
35691
|
|
|
35121
35692
|
if (!updating_formEl && dirty & /*formEl*/ 1) {
|
|
35122
35693
|
updating_formEl = true;
|
|
@@ -35124,7 +35695,7 @@ function create_if_block_2(ctx) {
|
|
|
35124
35695
|
add_flush_callback(() => updating_formEl = false);
|
|
35125
35696
|
}
|
|
35126
35697
|
|
|
35127
|
-
if (switch_value !== (switch_value = mapStepToStage(/*$journeyStore*/ ctx[
|
|
35698
|
+
if (switch_value !== (switch_value = mapStepToStage(/*$journeyStore*/ ctx[5].step))) {
|
|
35128
35699
|
if (switch_instance) {
|
|
35129
35700
|
group_outros();
|
|
35130
35701
|
const old_component = switch_instance;
|
|
@@ -35165,7 +35736,7 @@ function create_if_block_2(ctx) {
|
|
|
35165
35736
|
};
|
|
35166
35737
|
}
|
|
35167
35738
|
|
|
35168
|
-
// (
|
|
35739
|
+
// (31:2) {#if $journeyStore && !$journeyStore.step}
|
|
35169
35740
|
function create_if_block_1(ctx) {
|
|
35170
35741
|
let div;
|
|
35171
35742
|
let spinner;
|
|
@@ -35215,8 +35786,8 @@ function create_fragment$1(ctx) {
|
|
|
35215
35786
|
const if_blocks = [];
|
|
35216
35787
|
|
|
35217
35788
|
function select_block_type(ctx, dirty) {
|
|
35218
|
-
if (!/*$journeyStore*/ ctx[
|
|
35219
|
-
if (/*$journeyStore*/ ctx[
|
|
35789
|
+
if (/*$journeyStore*/ ctx[5] && !/*$journeyStore*/ ctx[5].completed) return 0;
|
|
35790
|
+
if (/*$journeyStore*/ ctx[5] && /*$journeyStore*/ ctx[5].successful) return 1;
|
|
35220
35791
|
return 2;
|
|
35221
35792
|
}
|
|
35222
35793
|
|
|
@@ -35279,13 +35850,19 @@ function create_fragment$1(ctx) {
|
|
|
35279
35850
|
function instance$1($$self, $$props, $$invalidate) {
|
|
35280
35851
|
let $journeyStore,
|
|
35281
35852
|
$$unsubscribe_journeyStore = noop,
|
|
35282
|
-
$$subscribe_journeyStore = () => ($$unsubscribe_journeyStore(), $$unsubscribe_journeyStore = subscribe(journeyStore, $$value => $$invalidate(
|
|
35853
|
+
$$subscribe_journeyStore = () => ($$unsubscribe_journeyStore(), $$unsubscribe_journeyStore = subscribe(journeyStore, $$value => $$invalidate(5, $journeyStore = $$value)), journeyStore);
|
|
35283
35854
|
|
|
35284
35855
|
$$self.$$.on_destroy.push(() => $$unsubscribe_journeyStore());
|
|
35856
|
+
let { componentStyle } = $$props;
|
|
35285
35857
|
let { displayIcon } = $$props;
|
|
35286
35858
|
let { formEl = null } = $$props;
|
|
35287
35859
|
let { journeyStore } = $$props;
|
|
35288
35860
|
$$subscribe_journeyStore();
|
|
35861
|
+
|
|
35862
|
+
if (!$journeyStore) {
|
|
35863
|
+
console.error('Widget missing configuration. Import and call `configuration()`, then use `set()` to configure.');
|
|
35864
|
+
}
|
|
35865
|
+
|
|
35289
35866
|
let alertNeedsFocus = false;
|
|
35290
35867
|
|
|
35291
35868
|
function submitForm() {
|
|
@@ -35299,7 +35876,7 @@ function instance$1($$self, $$props, $$invalidate) {
|
|
|
35299
35876
|
}
|
|
35300
35877
|
|
|
35301
35878
|
afterUpdate(() => {
|
|
35302
|
-
$$invalidate(
|
|
35879
|
+
$$invalidate(4, alertNeedsFocus = $journeyStore && !$journeyStore.successful);
|
|
35303
35880
|
});
|
|
35304
35881
|
|
|
35305
35882
|
function switch_instance_formEl_binding(value) {
|
|
@@ -35308,13 +35885,15 @@ function instance$1($$self, $$props, $$invalidate) {
|
|
|
35308
35885
|
}
|
|
35309
35886
|
|
|
35310
35887
|
$$self.$$set = $$props => {
|
|
35311
|
-
if ('
|
|
35888
|
+
if ('componentStyle' in $$props) $$invalidate(1, componentStyle = $$props.componentStyle);
|
|
35889
|
+
if ('displayIcon' in $$props) $$invalidate(2, displayIcon = $$props.displayIcon);
|
|
35312
35890
|
if ('formEl' in $$props) $$invalidate(0, formEl = $$props.formEl);
|
|
35313
|
-
if ('journeyStore' in $$props) $$subscribe_journeyStore($$invalidate(
|
|
35891
|
+
if ('journeyStore' in $$props) $$subscribe_journeyStore($$invalidate(3, journeyStore = $$props.journeyStore));
|
|
35314
35892
|
};
|
|
35315
35893
|
|
|
35316
35894
|
return [
|
|
35317
35895
|
formEl,
|
|
35896
|
+
componentStyle,
|
|
35318
35897
|
displayIcon,
|
|
35319
35898
|
journeyStore,
|
|
35320
35899
|
alertNeedsFocus,
|
|
@@ -35330,9 +35909,10 @@ class Journey extends SvelteComponent {
|
|
|
35330
35909
|
super();
|
|
35331
35910
|
|
|
35332
35911
|
init(this, options, instance$1, create_fragment$1, safe_not_equal, {
|
|
35333
|
-
|
|
35912
|
+
componentStyle: 1,
|
|
35913
|
+
displayIcon: 2,
|
|
35334
35914
|
formEl: 0,
|
|
35335
|
-
journeyStore:
|
|
35915
|
+
journeyStore: 3
|
|
35336
35916
|
});
|
|
35337
35917
|
}
|
|
35338
35918
|
}
|
|
@@ -35350,6 +35930,7 @@ function create_else_block(ctx) {
|
|
|
35350
35930
|
}
|
|
35351
35931
|
|
|
35352
35932
|
let journey_1_props = {
|
|
35933
|
+
componentStyle: "inline",
|
|
35353
35934
|
displayIcon: /*$styleStore*/ ctx[4]?.stage?.icon ?? true,
|
|
35354
35935
|
journeyStore: /*journeyStore*/ ctx[5]
|
|
35355
35936
|
};
|
|
@@ -35481,6 +36062,7 @@ function create_default_slot(ctx) {
|
|
|
35481
36062
|
}
|
|
35482
36063
|
|
|
35483
36064
|
let journey_1_props = {
|
|
36065
|
+
componentStyle: "modal",
|
|
35484
36066
|
displayIcon: /*$styleStore*/ ctx[4]?.stage?.icon ?? !/*$styleStore*/ ctx[4]?.logo,
|
|
35485
36067
|
journeyStore: /*journeyStore*/ ctx[5]
|
|
35486
36068
|
};
|