@forgerock/login-widget 1.0.0-beta.9 → 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 +161 -1
- package/index.cjs +1266 -727
- package/index.cjs.map +1 -1
- package/index.js +1266 -727
- package/index.js.map +1 -1
- package/package.json +2 -9
- package/{index.d.ts → types.d.ts} +140 -210
- package/widget.css +24 -7
package/index.cjs
CHANGED
|
@@ -706,6 +706,10 @@ function closeComponent(args, shouldCloseDialog) {
|
|
|
706
706
|
};
|
|
707
707
|
});
|
|
708
708
|
}
|
|
709
|
+
/**
|
|
710
|
+
* @function componentApi - this is a widget external API
|
|
711
|
+
* @returns {object} - the public component API
|
|
712
|
+
*/
|
|
709
713
|
const componentApi = () => {
|
|
710
714
|
const { update } = componentStore;
|
|
711
715
|
// Create derived store to minimize what's exposed to the dev
|
|
@@ -719,9 +723,19 @@ const componentApi = () => {
|
|
|
719
723
|
});
|
|
720
724
|
});
|
|
721
725
|
return {
|
|
726
|
+
/**
|
|
727
|
+
* Close a modal
|
|
728
|
+
* @param {object} args - object containing the reason for closing component
|
|
729
|
+
* @returns {void}
|
|
730
|
+
*/
|
|
722
731
|
close: (args) => {
|
|
723
732
|
closeComponent(args, true);
|
|
724
733
|
},
|
|
734
|
+
/**
|
|
735
|
+
* Open a modal
|
|
736
|
+
* @param: void
|
|
737
|
+
* @returns: void
|
|
738
|
+
*/
|
|
725
739
|
open: () => {
|
|
726
740
|
update((state) => {
|
|
727
741
|
if (state.type === 'inline') {
|
|
@@ -743,6 +757,10 @@ const componentApi = () => {
|
|
|
743
757
|
};
|
|
744
758
|
});
|
|
745
759
|
},
|
|
760
|
+
/**
|
|
761
|
+
* Subscribe to modal events
|
|
762
|
+
* returns the latest value from the event
|
|
763
|
+
*/
|
|
746
764
|
subscribe,
|
|
747
765
|
};
|
|
748
766
|
};
|
|
@@ -10877,6 +10895,11 @@ var HttpClient = /** @class */ (function (_super) {
|
|
|
10877
10895
|
}(event_1.default));
|
|
10878
10896
|
var _default$2 = httpClient.default = HttpClient;
|
|
10879
10897
|
|
|
10898
|
+
/**
|
|
10899
|
+
* @function logErrorAndThrow - Logs an error message and throws an error.
|
|
10900
|
+
* @param {string} type - The type of error. This will be used to determine what error message to log.
|
|
10901
|
+
* @throws {Error} - An error with a message that depends on the value of `type`.
|
|
10902
|
+
*/
|
|
10880
10903
|
function logErrorAndThrow(type) {
|
|
10881
10904
|
if (type === 'missingStores') {
|
|
10882
10905
|
const errorMessage = 'Error: missing configuration.';
|
|
@@ -14925,6 +14948,11 @@ const configSchema = z
|
|
|
14925
14948
|
})
|
|
14926
14949
|
.strict();
|
|
14927
14950
|
configSchema.partial();
|
|
14951
|
+
/**
|
|
14952
|
+
* @function - Sets the configuration for the SDK
|
|
14953
|
+
* @param {object} config - The configuration object
|
|
14954
|
+
* @returns {void}
|
|
14955
|
+
*/
|
|
14928
14956
|
function configure (config) {
|
|
14929
14957
|
configSchema.parse(config);
|
|
14930
14958
|
Config.set(config);
|
|
@@ -14972,6 +15000,12 @@ const fallbackJourneyConfig = Object.keys(defaultJourneys).map((key) => ({
|
|
|
14972
15000
|
key,
|
|
14973
15001
|
}));
|
|
14974
15002
|
const configuredJourneysStore = writable(fallbackJourneyConfig);
|
|
15003
|
+
/**
|
|
15004
|
+
* @function initialize - Initialize the configured journeys store
|
|
15005
|
+
* @param {object} customJourneys - An object of custom journeys to merge with the default
|
|
15006
|
+
* @returns {object} - The configured journeys store
|
|
15007
|
+
* @example initialize({ login: { journey: 'Login', match: ['?journey=Login'] } })
|
|
15008
|
+
*/
|
|
14975
15009
|
function initialize$6(customJourneys) {
|
|
14976
15010
|
if (customJourneys) {
|
|
14977
15011
|
// Provide developer feedback if customized
|
|
@@ -16730,6 +16764,8 @@ var backToDefault = "Back to Sign In";
|
|
|
16730
16764
|
var backToLogin = "Back to Sign In";
|
|
16731
16765
|
var dontHaveAnAccount = "No account? <a href='?journey=Registration'>Register here!</a>";
|
|
16732
16766
|
var closeModal = "Close";
|
|
16767
|
+
var charactersCannotRepeatMoreThan = "Character cannot repeat more than {max} times";
|
|
16768
|
+
var charactersCannotRepeatMoreThanCaseInsensitive = "Character cannot repeat more than {max} times (case insensitive)";
|
|
16733
16769
|
var chooseDifferentUsername = "Please choose a different username.";
|
|
16734
16770
|
var confirmPassword = "Confirm password";
|
|
16735
16771
|
var constraintViolationForPassword = "Password does not meet the requirements.";
|
|
@@ -16762,6 +16798,9 @@ var nextButton = "Next";
|
|
|
16762
16798
|
var notToExceedMaximumCharacterLength = "No more than {max} characters";
|
|
16763
16799
|
var noLessThanMinimumCharacterLength = "At least {min} character(s)";
|
|
16764
16800
|
var passwordCallback = "Password";
|
|
16801
|
+
var passwordCannotContainCommonPasswords = "Password cannot contain common passwords";
|
|
16802
|
+
var passwordCannotContainCommonPasswordsOrBeReversible = "Password cannot contain common passwords or reversible text";
|
|
16803
|
+
var passwordCannotContainCommonPasswordsOrBeReversibleStringsLessThan = "Password cannot contain common passwords or reversible text less than {min} characters";
|
|
16765
16804
|
var passwordRequirements = "Password requirements:";
|
|
16766
16805
|
var pleaseCheckValue = "Please check this value";
|
|
16767
16806
|
var pleaseConfirm = "Please confirm";
|
|
@@ -16775,7 +16814,11 @@ var registerSuccess = "Registration successful!";
|
|
|
16775
16814
|
var requiredField = "Value is required";
|
|
16776
16815
|
var securityAnswer = "Security answer";
|
|
16777
16816
|
var securityQuestions = "Security question(s)";
|
|
16778
|
-
var securityQuestionsPrompt = "Provide
|
|
16817
|
+
var securityQuestionsPrompt = "Provide security question(s) and answer(s):";
|
|
16818
|
+
var shouldContainANumber = "Should contain a number";
|
|
16819
|
+
var shouldContainAnUppercase = "Should contain an uppercase letter";
|
|
16820
|
+
var shouldContainALowercase = "Should contain a lowercase letter";
|
|
16821
|
+
var shouldContainASymbol = "Should contain a symbol";
|
|
16779
16822
|
var showPassword = "Show password";
|
|
16780
16823
|
var sn = "Last name";
|
|
16781
16824
|
var submitButton = "Submit";
|
|
@@ -16786,6 +16829,7 @@ var tryAgain = "Please try again";
|
|
|
16786
16829
|
var twoFactorAuthentication = "Two factor authentication";
|
|
16787
16830
|
var useValidEmail = "Please use a valid email address.";
|
|
16788
16831
|
var unrecoverableError = "There was an error in the form submission.";
|
|
16832
|
+
var unknownLoginError = "Unknown login failure has occurred.";
|
|
16789
16833
|
var unknownNetworkError = "Unknown network request failure has occurred.";
|
|
16790
16834
|
var userName = "Username";
|
|
16791
16835
|
var usernameRequirements = "Username requirements:";
|
|
@@ -16799,6 +16843,8 @@ var fallback = {
|
|
|
16799
16843
|
backToLogin: backToLogin,
|
|
16800
16844
|
dontHaveAnAccount: dontHaveAnAccount,
|
|
16801
16845
|
closeModal: closeModal,
|
|
16846
|
+
charactersCannotRepeatMoreThan: charactersCannotRepeatMoreThan,
|
|
16847
|
+
charactersCannotRepeatMoreThanCaseInsensitive: charactersCannotRepeatMoreThanCaseInsensitive,
|
|
16802
16848
|
chooseDifferentUsername: chooseDifferentUsername,
|
|
16803
16849
|
confirmPassword: confirmPassword,
|
|
16804
16850
|
constraintViolationForPassword: constraintViolationForPassword,
|
|
@@ -16831,6 +16877,9 @@ var fallback = {
|
|
|
16831
16877
|
notToExceedMaximumCharacterLength: notToExceedMaximumCharacterLength,
|
|
16832
16878
|
noLessThanMinimumCharacterLength: noLessThanMinimumCharacterLength,
|
|
16833
16879
|
passwordCallback: passwordCallback,
|
|
16880
|
+
passwordCannotContainCommonPasswords: passwordCannotContainCommonPasswords,
|
|
16881
|
+
passwordCannotContainCommonPasswordsOrBeReversible: passwordCannotContainCommonPasswordsOrBeReversible,
|
|
16882
|
+
passwordCannotContainCommonPasswordsOrBeReversibleStringsLessThan: passwordCannotContainCommonPasswordsOrBeReversibleStringsLessThan,
|
|
16834
16883
|
passwordRequirements: passwordRequirements,
|
|
16835
16884
|
pleaseCheckValue: pleaseCheckValue,
|
|
16836
16885
|
pleaseConfirm: pleaseConfirm,
|
|
@@ -16845,6 +16894,10 @@ var fallback = {
|
|
|
16845
16894
|
securityAnswer: securityAnswer,
|
|
16846
16895
|
securityQuestions: securityQuestions,
|
|
16847
16896
|
securityQuestionsPrompt: securityQuestionsPrompt,
|
|
16897
|
+
shouldContainANumber: shouldContainANumber,
|
|
16898
|
+
shouldContainAnUppercase: shouldContainAnUppercase,
|
|
16899
|
+
shouldContainALowercase: shouldContainALowercase,
|
|
16900
|
+
shouldContainASymbol: shouldContainASymbol,
|
|
16848
16901
|
showPassword: showPassword,
|
|
16849
16902
|
sn: sn,
|
|
16850
16903
|
submitButton: submitButton,
|
|
@@ -16855,6 +16908,7 @@ var fallback = {
|
|
|
16855
16908
|
twoFactorAuthentication: twoFactorAuthentication,
|
|
16856
16909
|
useValidEmail: useValidEmail,
|
|
16857
16910
|
unrecoverableError: unrecoverableError,
|
|
16911
|
+
unknownLoginError: unknownLoginError,
|
|
16858
16912
|
unknownNetworkError: unknownNetworkError,
|
|
16859
16913
|
userName: userName,
|
|
16860
16914
|
usernameRequirements: usernameRequirements,
|
|
@@ -16871,6 +16925,8 @@ const stringsSchema = z
|
|
|
16871
16925
|
backToLogin: z.string(),
|
|
16872
16926
|
dontHaveAnAccount: z.string(),
|
|
16873
16927
|
closeModal: z.string(),
|
|
16928
|
+
charactersCannotRepeatMoreThan: z.string(),
|
|
16929
|
+
charactersCannotRepeatMoreThanCaseInsensitive: z.string(),
|
|
16874
16930
|
chooseDifferentUsername: z.string(),
|
|
16875
16931
|
confirmPassword: z.string(),
|
|
16876
16932
|
constraintViolationForPassword: z.string(),
|
|
@@ -16903,6 +16959,9 @@ const stringsSchema = z
|
|
|
16903
16959
|
notToExceedMaximumCharacterLength: z.string(),
|
|
16904
16960
|
noLessThanMinimumCharacterLength: z.string(),
|
|
16905
16961
|
passwordCallback: z.string(),
|
|
16962
|
+
passwordCannotContainCommonPasswords: z.string(),
|
|
16963
|
+
passwordCannotContainCommonPasswordsOrBeReversible: z.string(),
|
|
16964
|
+
passwordCannotContainCommonPasswordsOrBeReversibleStringsLessThan: z.string(),
|
|
16906
16965
|
passwordRequirements: z.string(),
|
|
16907
16966
|
pleaseCheckValue: z.string(),
|
|
16908
16967
|
pleaseConfirm: z.string(),
|
|
@@ -16917,6 +16976,10 @@ const stringsSchema = z
|
|
|
16917
16976
|
securityAnswer: z.string(),
|
|
16918
16977
|
securityQuestions: z.string(),
|
|
16919
16978
|
securityQuestionsPrompt: z.string(),
|
|
16979
|
+
shouldContainANumber: z.string(),
|
|
16980
|
+
shouldContainAnUppercase: z.string(),
|
|
16981
|
+
shouldContainALowercase: z.string(),
|
|
16982
|
+
shouldContainASymbol: z.string(),
|
|
16920
16983
|
showPassword: z.string(),
|
|
16921
16984
|
sn: z.string(),
|
|
16922
16985
|
submitButton: z.string(),
|
|
@@ -16927,6 +16990,7 @@ const stringsSchema = z
|
|
|
16927
16990
|
twoFactorAuthentication: z.string(),
|
|
16928
16991
|
useValidEmail: z.string(),
|
|
16929
16992
|
unrecoverableError: z.string(),
|
|
16993
|
+
unknownLoginError: z.string(),
|
|
16930
16994
|
unknownNetworkError: z.string(),
|
|
16931
16995
|
userName: z.string(),
|
|
16932
16996
|
usernameRequirements: z.string(),
|
|
@@ -16940,6 +17004,12 @@ stringsSchema.partial();
|
|
|
16940
17004
|
// Ensure fallback follows schema
|
|
16941
17005
|
stringsSchema.parse(fallback);
|
|
16942
17006
|
const stringsStore = writable(null);
|
|
17007
|
+
/**
|
|
17008
|
+
* @function initialize - Initialize the locale store
|
|
17009
|
+
* @param {object} userLocale - An object of custom locale strings to merge with the default
|
|
17010
|
+
* @returns {object} - The locale store
|
|
17011
|
+
* @example initialize({ loginHeader: 'Welcome to the login page' });
|
|
17012
|
+
*/
|
|
16943
17013
|
function initialize$5(userLocale) {
|
|
16944
17014
|
if (userLocale) {
|
|
16945
17015
|
/**
|
|
@@ -16959,6 +17029,14 @@ function initialize$5(userLocale) {
|
|
|
16959
17029
|
* Demo: https://regex101.com/r/Mw9vTB/1
|
|
16960
17030
|
*/
|
|
16961
17031
|
const valueSchema = z.record(z.string().regex(/^[^<>]*$/)).optional();
|
|
17032
|
+
/**
|
|
17033
|
+
* @function interpolate - Get a translation string
|
|
17034
|
+
* Interpolate a string that contains variables
|
|
17035
|
+
*
|
|
17036
|
+
* @param {string} key - The key to lookup in the translation strings
|
|
17037
|
+
* @param {object} values - An object of values to interpolate into the string
|
|
17038
|
+
* @param {string} externalText - A string to use if no translation is found
|
|
17039
|
+
*/
|
|
16962
17040
|
function interpolate(key, values, externalText) {
|
|
16963
17041
|
// Let's throw some errors if we're trying to use keys/locales that don't exist.
|
|
16964
17042
|
// We could improve this by using Typescript and/or fallback values.
|
|
@@ -17030,6 +17108,31 @@ function interpolate(key, values, externalText) {
|
|
|
17030
17108
|
});
|
|
17031
17109
|
return messageClean;
|
|
17032
17110
|
}
|
|
17111
|
+
/**
|
|
17112
|
+
* @function textToKey - Takes a human readable string and returns a key from it.
|
|
17113
|
+
* This key is used to look up the string in the translation files.
|
|
17114
|
+
*
|
|
17115
|
+
* If the item is a number, it will be converted to a string and then
|
|
17116
|
+
* processed as if it were a string.
|
|
17117
|
+
*
|
|
17118
|
+
* If the item is a string that contains word characters (`\w`) mixed with
|
|
17119
|
+
* non-word characters (`\W`), the non-word characters will be removed and
|
|
17120
|
+
* the resulting string will be converted to camelCase.
|
|
17121
|
+
*
|
|
17122
|
+
* @param {string} text - The text that will be converted to a key.
|
|
17123
|
+
* @returns {string} A key that is unique to the given text.
|
|
17124
|
+
*
|
|
17125
|
+
* Examples:
|
|
17126
|
+
* textToKey('hello world') => 'helloWorld'
|
|
17127
|
+
* textToKey('HELLO WORLD') => 'helloWorld'
|
|
17128
|
+
* textToKey('HELLO WORLD!!!') => 'helloWorld'
|
|
17129
|
+
* textToKey('HELLO WORLD!!!') => 'helloWorld'
|
|
17130
|
+
* textToKey('helloWorld') => 'helloWorld'
|
|
17131
|
+
* textToKey('helloWorld123') => 'helloWorld123'
|
|
17132
|
+
* textToKey('hello_world') => 'helloWorld'
|
|
17133
|
+
* textToKey('hello-world') => 'helloWorld'
|
|
17134
|
+
* textToKey('hello.world') => 'helloWorld'
|
|
17135
|
+
*/
|
|
17033
17136
|
function textToKey(text) {
|
|
17034
17137
|
if (typeof text !== 'string' && typeof text !== 'number') {
|
|
17035
17138
|
throw new Error('Parameter for textToKey function needs to be of type string or number');
|
|
@@ -17171,7 +17274,9 @@ const userInputCallbacks = [
|
|
|
17171
17274
|
CallbackType$1.ValidatedCreatePasswordCallback,
|
|
17172
17275
|
CallbackType$1.ValidatedCreateUsernameCallback,
|
|
17173
17276
|
];
|
|
17174
|
-
|
|
17277
|
+
/**
|
|
17278
|
+
* @function forceUserInputOptionalityCallbacks - Determines if a callback should be forced to be optional
|
|
17279
|
+
*/
|
|
17175
17280
|
const forceUserInputOptionalityCallbacks = {
|
|
17176
17281
|
SelectIdPCallback: (callback) => {
|
|
17177
17282
|
const selectIdpCb = callback;
|
|
@@ -17180,6 +17285,11 @@ const forceUserInputOptionalityCallbacks = {
|
|
|
17180
17285
|
.find((provider) => provider.provider === 'localAuthentication');
|
|
17181
17286
|
},
|
|
17182
17287
|
};
|
|
17288
|
+
/**
|
|
17289
|
+
* @function isCbReadyByDefault - Determines if a callback is ready to be submitted by default
|
|
17290
|
+
* @param {object} callback - Generic FRCallback from JavaScript SDK
|
|
17291
|
+
* @returns {boolean}
|
|
17292
|
+
*/
|
|
17183
17293
|
function isCbReadyByDefault(callback) {
|
|
17184
17294
|
if (callback.getType() === CallbackType$1.ConfirmationCallback) {
|
|
17185
17295
|
const cb = callback;
|
|
@@ -17189,6 +17299,11 @@ function isCbReadyByDefault(callback) {
|
|
|
17189
17299
|
}
|
|
17190
17300
|
return false;
|
|
17191
17301
|
}
|
|
17302
|
+
/**
|
|
17303
|
+
* @function canForceUserInputOptionality
|
|
17304
|
+
* @param {object} callback - generic FRCallback from JavaScript SDK
|
|
17305
|
+
* @returns
|
|
17306
|
+
*/
|
|
17192
17307
|
function canForceUserInputOptionality(callback) {
|
|
17193
17308
|
// See if a callback function exists within this collection
|
|
17194
17309
|
const fn = forceUserInputOptionalityCallbacks[callback.getType()];
|
|
@@ -17216,9 +17331,9 @@ function isStepSelfSubmittable(callbacks, userInputOptional) {
|
|
|
17216
17331
|
return !unsubmittableCallbacks.length;
|
|
17217
17332
|
}
|
|
17218
17333
|
/**
|
|
17219
|
-
*
|
|
17334
|
+
* @function requiresUserInput - Determines if a callback requires user input
|
|
17220
17335
|
* @param {object} callback - Generic callback provided by JavaScript SDK
|
|
17221
|
-
* @returns
|
|
17336
|
+
* @returns {boolean}
|
|
17222
17337
|
*/
|
|
17223
17338
|
function requiresUserInput(callback) {
|
|
17224
17339
|
if (callback.getType() === CallbackType$1.SelectIdPCallback) {
|
|
@@ -17234,6 +17349,22 @@ function requiresUserInput(callback) {
|
|
|
17234
17349
|
}
|
|
17235
17350
|
// Notice this function can take a user provided argument function to
|
|
17236
17351
|
// override behavior (this doesn't have to be well defined)
|
|
17352
|
+
/**
|
|
17353
|
+
* @function isUserInputOptional - Determines if user input is optional
|
|
17354
|
+
* Notice this function can take a user provided argument function to
|
|
17355
|
+
* override behavior (this doesn't have to be well defined)
|
|
17356
|
+
* @param {array} callbackMetadataArray - array of callback metadata
|
|
17357
|
+
* @param {number} numOfUserInputCbs - number of user input requiring callbacks
|
|
17358
|
+
* @param {function} fn - optional function to override default behavior
|
|
17359
|
+
* @returns {boolean} - true if user input is optional
|
|
17360
|
+
* @example isUserInputOptional(callbackMetadataArray, numOfUserInputCbs, (prev, curr) => {
|
|
17361
|
+
* if (curr.derived.canForceUserInputOptionality && numOfUserInputCbs > 0) {
|
|
17362
|
+
* prev = true;
|
|
17363
|
+
* }
|
|
17364
|
+
* return prev;
|
|
17365
|
+
* })
|
|
17366
|
+
* @example isUserInputOptional(callbackMetadataArray, numOfUserInputCbs);
|
|
17367
|
+
*/
|
|
17237
17368
|
function isUserInputOptional(callbackMetadataArray, numOfUserInputCbs, fn) {
|
|
17238
17369
|
// default reducer function to check if both overriding callback exists
|
|
17239
17370
|
// along with user input required callbacks
|
|
@@ -17250,7 +17381,7 @@ function isUserInputOptional(callbackMetadataArray, numOfUserInputCbs, fn) {
|
|
|
17250
17381
|
/**
|
|
17251
17382
|
* @function buildCallbackMetadata - Constructs an array of callback metadata that matches to original callback array
|
|
17252
17383
|
* @param {object} step - The modified Widget step object
|
|
17253
|
-
* @param checkValidation - function that checks if current callback is the first invalid callback
|
|
17384
|
+
* @param {function} checkValidation - function that checks if current callback is the first invalid callback
|
|
17254
17385
|
* @returns {array}
|
|
17255
17386
|
*/
|
|
17256
17387
|
function buildCallbackMetadata(step, checkValidation, stageJson) {
|
|
@@ -17329,6 +17460,11 @@ function buildStepMetadata(callbackMetadataArray, stageJson, stageName) {
|
|
|
17329
17460
|
};
|
|
17330
17461
|
}
|
|
17331
17462
|
|
|
17463
|
+
/**
|
|
17464
|
+
* @function initializeJourney - Initializes the journey stack for tracking journey switches
|
|
17465
|
+
* @param {object} initOptions - The initial options to set
|
|
17466
|
+
* @returns {object} - The journey stack store with stack methods
|
|
17467
|
+
*/
|
|
17332
17468
|
function initializeStack(initOptions) {
|
|
17333
17469
|
const initialValue = initOptions ? [initOptions] : [];
|
|
17334
17470
|
const { update, set, subscribe } = writable(initialValue);
|
|
@@ -17392,6 +17528,11 @@ const journeyStore = writable({
|
|
|
17392
17528
|
successful: false,
|
|
17393
17529
|
response: null,
|
|
17394
17530
|
});
|
|
17531
|
+
/**
|
|
17532
|
+
* @function initialize - Initializes the journey store
|
|
17533
|
+
* @param {object} initOptions - The initial options to set
|
|
17534
|
+
* @returns {object} - The journey store
|
|
17535
|
+
*/
|
|
17395
17536
|
function initialize$4(initOptions) {
|
|
17396
17537
|
const stack = initializeStack();
|
|
17397
17538
|
let stepNumber = 0;
|
|
@@ -17511,7 +17652,7 @@ function initialize$4(initOptions) {
|
|
|
17511
17652
|
*
|
|
17512
17653
|
* Grab failure message, which may contain encoded HTML
|
|
17513
17654
|
*/
|
|
17514
|
-
const failureMessageStr = htmlDecode(nextStep.payload.message || '');
|
|
17655
|
+
const failureMessageStr = htmlDecode(nextStep.payload.message || 'Unknown login error');
|
|
17515
17656
|
let restartedStep = null;
|
|
17516
17657
|
try {
|
|
17517
17658
|
/**
|
|
@@ -17594,8 +17735,7 @@ function initialize$4(initOptions) {
|
|
|
17594
17735
|
error: {
|
|
17595
17736
|
code: nextStep.getCode(),
|
|
17596
17737
|
message: failureMessageStr,
|
|
17597
|
-
|
|
17598
|
-
step: prevStep?.payload,
|
|
17738
|
+
stage: prevStep?.payload?.stage,
|
|
17599
17739
|
troubleshoot: null,
|
|
17600
17740
|
},
|
|
17601
17741
|
loading: false,
|
|
@@ -17625,8 +17765,7 @@ function initialize$4(initOptions) {
|
|
|
17625
17765
|
error: {
|
|
17626
17766
|
code: nextStep.getCode(),
|
|
17627
17767
|
message: failureMessageStr,
|
|
17628
|
-
|
|
17629
|
-
step: prevStep?.payload,
|
|
17768
|
+
stage: prevStep?.payload?.stage,
|
|
17630
17769
|
troubleshoot: null,
|
|
17631
17770
|
},
|
|
17632
17771
|
loading: false,
|
|
@@ -17698,6 +17837,12 @@ const linksSchema = z
|
|
|
17698
17837
|
.strict();
|
|
17699
17838
|
linksSchema.partial();
|
|
17700
17839
|
const linksStore = writable();
|
|
17840
|
+
/**
|
|
17841
|
+
* @function initialize - Initialize the links store
|
|
17842
|
+
* @param {object} customLinks - An object of custom links to merge with the default
|
|
17843
|
+
* @returns {object} - The links store
|
|
17844
|
+
* @example initialize({ termsAndConditions: 'https://example.com/terms' });
|
|
17845
|
+
*/
|
|
17701
17846
|
function initialize$3(customLinks) {
|
|
17702
17847
|
// If customLinks is provided, provide feedback for object
|
|
17703
17848
|
if (customLinks) {
|
|
@@ -17720,7 +17865,19 @@ const oauthStore = writable({
|
|
|
17720
17865
|
successful: false,
|
|
17721
17866
|
response: null,
|
|
17722
17867
|
});
|
|
17868
|
+
/**
|
|
17869
|
+
* @function initialize - Initializes the OAuth store with a get function and a reset function
|
|
17870
|
+
* @param {object} initOptions - The options to pass to the TokenManager.getTokens function
|
|
17871
|
+
* @returns {object} - The OAuth store
|
|
17872
|
+
* @example initialize({ query: { prompt: 'none' } });
|
|
17873
|
+
*/
|
|
17723
17874
|
function initialize$2(initOptions) {
|
|
17875
|
+
/**
|
|
17876
|
+
* Get tokens from the server
|
|
17877
|
+
* new tokens are available in the subscribe method
|
|
17878
|
+
* @params: getOptions?: GetTokensOptions
|
|
17879
|
+
* @returns: Promise<void>
|
|
17880
|
+
*/
|
|
17724
17881
|
async function get(getOptions) {
|
|
17725
17882
|
/**
|
|
17726
17883
|
* Create an options object with getOptions overriding anything from initOptions
|
|
@@ -17788,7 +17945,18 @@ const userStore = writable({
|
|
|
17788
17945
|
successful: false,
|
|
17789
17946
|
response: null,
|
|
17790
17947
|
});
|
|
17948
|
+
/**
|
|
17949
|
+
* @function initialize - Initializes the user store with a get function and a reset function
|
|
17950
|
+
* @param {object} initOptions - The options to pass to the UserManager.getCurrentUser function
|
|
17951
|
+
* @returns {object} - The user store
|
|
17952
|
+
*/
|
|
17791
17953
|
function initialize$1(initOptions) {
|
|
17954
|
+
/**
|
|
17955
|
+
* Get user info from the server
|
|
17956
|
+
* New state is returned in your `userEvents.subscribe` callback function
|
|
17957
|
+
* @params: getOptions?: ConfigOptions
|
|
17958
|
+
* @returns: Promise<void>
|
|
17959
|
+
*/
|
|
17792
17960
|
async function get(getOptions) {
|
|
17793
17961
|
/**
|
|
17794
17962
|
* Create an options object with getOptions overriding anything from initOptions
|
|
@@ -17875,11 +18043,17 @@ styleSchema.partial();
|
|
|
17875
18043
|
const fallbackStyles = {
|
|
17876
18044
|
checksAndRadios: 'animated',
|
|
17877
18045
|
labels: 'floating',
|
|
17878
|
-
logo:
|
|
17879
|
-
sections:
|
|
17880
|
-
stage:
|
|
18046
|
+
logo: undefined,
|
|
18047
|
+
sections: undefined,
|
|
18048
|
+
stage: undefined,
|
|
17881
18049
|
};
|
|
17882
18050
|
const styleStore = writable(fallbackStyles);
|
|
18051
|
+
/**
|
|
18052
|
+
* @function initialize - Initialize the style store
|
|
18053
|
+
* @param {object} customStyle - An object of custom styles to merge with the default
|
|
18054
|
+
* @returns {object} - The style store
|
|
18055
|
+
* @example initialize({ checksAndRadios: 'standard' });
|
|
18056
|
+
*/
|
|
17883
18057
|
function initialize(customStyle) {
|
|
17884
18058
|
if (customStyle) {
|
|
17885
18059
|
styleSchema.parse(customStyle);
|
|
@@ -17891,6 +18065,17 @@ function initialize(customStyle) {
|
|
|
17891
18065
|
return styleStore;
|
|
17892
18066
|
}
|
|
17893
18067
|
|
|
18068
|
+
/**
|
|
18069
|
+
* @function widgetApiFactory - Creates the widget API
|
|
18070
|
+
* @param {object} componentApi - The component API
|
|
18071
|
+
* @returns {object} - The widget API
|
|
18072
|
+
* @property {object} componentApi - The component API for either inline or modal
|
|
18073
|
+
* @property {object} configuration - Sets the configuration for the widget
|
|
18074
|
+
* @property {function} getStores - Returns the stores: journeyStore, oauthStore, userStore
|
|
18075
|
+
* @property {object} journey - the journey API
|
|
18076
|
+
* @property {function} request - The HttpClient.request function from the SDK
|
|
18077
|
+
* @property {object} user - the user API
|
|
18078
|
+
*/
|
|
17894
18079
|
function widgetApiFactory(componentApi) {
|
|
17895
18080
|
let journeyStore;
|
|
17896
18081
|
let oauthStore;
|
|
@@ -17939,6 +18124,10 @@ function widgetApiFactory(componentApi) {
|
|
|
17939
18124
|
initialize$3(options?.links);
|
|
17940
18125
|
initialize(options?.style);
|
|
17941
18126
|
return {
|
|
18127
|
+
/** Set the Login Widget's Configuration
|
|
18128
|
+
* @param {WidgetConfigOptions} options - The configuration options for the Login Widget
|
|
18129
|
+
* @returns {void}
|
|
18130
|
+
**/
|
|
17942
18131
|
set(setOptions) {
|
|
17943
18132
|
if (setOptions?.forgerock) {
|
|
17944
18133
|
configure({
|
|
@@ -18060,6 +18249,11 @@ function widgetApiFactory(componentApi) {
|
|
|
18060
18249
|
return { change, start, subscribe };
|
|
18061
18250
|
};
|
|
18062
18251
|
const user = {
|
|
18252
|
+
/**
|
|
18253
|
+
* User Info
|
|
18254
|
+
* @param: void
|
|
18255
|
+
* @returns: UserStore
|
|
18256
|
+
*/
|
|
18063
18257
|
info() {
|
|
18064
18258
|
if (!journeyStore || !oauthStore || !userStore) {
|
|
18065
18259
|
logErrorAndThrow('missingStores');
|
|
@@ -18082,6 +18276,12 @@ function widgetApiFactory(componentApi) {
|
|
|
18082
18276
|
}
|
|
18083
18277
|
return { get: wrappedGet, subscribe };
|
|
18084
18278
|
},
|
|
18279
|
+
/**
|
|
18280
|
+
* Logout a user from an AM Session
|
|
18281
|
+
* @async
|
|
18282
|
+
* @param: void
|
|
18283
|
+
* @returns: Promise<void>
|
|
18284
|
+
**/
|
|
18085
18285
|
async logout() {
|
|
18086
18286
|
if (!journeyStore || !oauthStore || !userStore) {
|
|
18087
18287
|
logErrorAndThrow('missingStores');
|
|
@@ -18110,6 +18310,11 @@ function widgetApiFactory(componentApi) {
|
|
|
18110
18310
|
// Return undefined as there's no response information to share
|
|
18111
18311
|
return;
|
|
18112
18312
|
},
|
|
18313
|
+
/**
|
|
18314
|
+
* Returns the widget's Tokens object
|
|
18315
|
+
* @param void;
|
|
18316
|
+
* @returns OAuthStore
|
|
18317
|
+
*/
|
|
18113
18318
|
tokens() {
|
|
18114
18319
|
if (!journeyStore || !oauthStore || !userStore) {
|
|
18115
18320
|
logErrorAndThrow('missingStores');
|
|
@@ -18138,7 +18343,7 @@ function widgetApiFactory(componentApi) {
|
|
|
18138
18343
|
configuration,
|
|
18139
18344
|
getStores,
|
|
18140
18345
|
journey,
|
|
18141
|
-
request: _default$2.request,
|
|
18346
|
+
request: _default$2.request.bind(_default$2),
|
|
18142
18347
|
user,
|
|
18143
18348
|
};
|
|
18144
18349
|
}
|
|
@@ -18528,7 +18733,7 @@ function create_else_block$9(ctx) {
|
|
|
18528
18733
|
attr(button, "aria-controls", /*dialogId*/ ctx[1]);
|
|
18529
18734
|
|
|
18530
18735
|
attr(div, "class", div_class_value = `tw_pt-10 md:tw_pt-10 tw_text-right ${(/*$styleStore*/ ctx[5]?.logo)
|
|
18531
|
-
? 'tw_h-32 md:tw_h-36
|
|
18736
|
+
? 'tw_h-32 md:tw_h-36 tw_pb-6'
|
|
18532
18737
|
: ''}`);
|
|
18533
18738
|
},
|
|
18534
18739
|
m(target, anchor) {
|
|
@@ -18571,7 +18776,7 @@ function create_else_block$9(ctx) {
|
|
|
18571
18776
|
}
|
|
18572
18777
|
|
|
18573
18778
|
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)
|
|
18574
|
-
? 'tw_h-32 md:tw_h-36
|
|
18779
|
+
? 'tw_h-32 md:tw_h-36 tw_pb-6'
|
|
18575
18780
|
: ''}`)) {
|
|
18576
18781
|
attr(div, "class", div_class_value);
|
|
18577
18782
|
}
|
|
@@ -20592,6 +20797,11 @@ function matchJourneyAndDecideAction(href, journeys, stack) {
|
|
|
20592
20797
|
/** *********************************************
|
|
20593
20798
|
* NEW "NORMALIZED" METHODS
|
|
20594
20799
|
*/
|
|
20800
|
+
/**
|
|
20801
|
+
* @function getInputTypeFromPolicies - Determines the type of input to use based on the policies object
|
|
20802
|
+
* @param {object} policies - The policies object from the callback
|
|
20803
|
+
* @returns {string} - The type of input to use
|
|
20804
|
+
*/
|
|
20595
20805
|
function getInputTypeFromPolicies(policies) {
|
|
20596
20806
|
const value = policies?.value;
|
|
20597
20807
|
if (typeof value !== 'object') {
|
|
@@ -20609,13 +20819,47 @@ function getInputTypeFromPolicies(policies) {
|
|
|
20609
20819
|
}
|
|
20610
20820
|
return 'text';
|
|
20611
20821
|
}
|
|
20822
|
+
/**
|
|
20823
|
+
* @function getValidationFailureParams - Gets the validation failure params from the failed policy object
|
|
20824
|
+
* @param {object} failedPolicy - The failed policy object from the callback
|
|
20825
|
+
* @returns {array} - An array of objects containing the length, message, and rule
|
|
20826
|
+
*/
|
|
20612
20827
|
function getValidationFailureParams(failedPolicy) {
|
|
20613
|
-
if (failedPolicy?.policyRequirement === '
|
|
20614
|
-
const params = failedPolicy
|
|
20828
|
+
if (failedPolicy?.policyRequirement === 'DICTIONARY') {
|
|
20829
|
+
const params = failedPolicy.params;
|
|
20830
|
+
const min = params?.['min-substring-length'] || 0;
|
|
20831
|
+
const arr = [];
|
|
20832
|
+
if (params?.['check-substrings'] && params?.['test-reversed-password']) {
|
|
20833
|
+
arr.push({
|
|
20834
|
+
length: min,
|
|
20835
|
+
message: interpolate('passwordCannotContainCommonPasswordsOrBeReversibleStringsLessThan', {
|
|
20836
|
+
min: String(min),
|
|
20837
|
+
}),
|
|
20838
|
+
rule: 'reversibleSubstrings',
|
|
20839
|
+
});
|
|
20840
|
+
}
|
|
20841
|
+
else if (params?.['test-reversed-password']) {
|
|
20842
|
+
arr.push({
|
|
20843
|
+
length: null,
|
|
20844
|
+
message: interpolate('passwordCannotContainCommonPasswordsOrBeReversible'),
|
|
20845
|
+
rule: 'reversibleSubstrings',
|
|
20846
|
+
});
|
|
20847
|
+
}
|
|
20848
|
+
else {
|
|
20849
|
+
arr.push({
|
|
20850
|
+
length: null,
|
|
20851
|
+
message: interpolate('passwordCannotContainCommonPasswords'),
|
|
20852
|
+
rule: 'reversibleSubstrings',
|
|
20853
|
+
});
|
|
20854
|
+
}
|
|
20855
|
+
return arr;
|
|
20856
|
+
}
|
|
20857
|
+
else if (failedPolicy?.policyRequirement === 'CHARACTER_SET') {
|
|
20858
|
+
const params = failedPolicy.params;
|
|
20615
20859
|
return params?.['character-sets'].map(convertCharacterSetToRuleObj);
|
|
20616
20860
|
}
|
|
20617
20861
|
else if (failedPolicy?.policyRequirement === 'LENGTH_BASED') {
|
|
20618
|
-
const params = failedPolicy
|
|
20862
|
+
const params = failedPolicy.params;
|
|
20619
20863
|
const min = params?.['min-password-length'] || 0;
|
|
20620
20864
|
const max = params?.['max-password-length'] || null;
|
|
20621
20865
|
const arr = [];
|
|
@@ -20635,6 +20879,26 @@ function getValidationFailureParams(failedPolicy) {
|
|
|
20635
20879
|
}
|
|
20636
20880
|
return arr;
|
|
20637
20881
|
}
|
|
20882
|
+
else if (failedPolicy?.policyRequirement === 'REPEATED_CHARACTERS') {
|
|
20883
|
+
const params = failedPolicy.params;
|
|
20884
|
+
const max = params['max-consecutive-length'] || 0;
|
|
20885
|
+
const arr = [];
|
|
20886
|
+
if (!params['case-sensitive-validation']) {
|
|
20887
|
+
arr.push({
|
|
20888
|
+
length: max,
|
|
20889
|
+
message: interpolate('charactersCannotRepeatMoreThanCaseInsensitive', { max: String(max) }),
|
|
20890
|
+
rule: 'repeatedCharactersCaseInsensitive',
|
|
20891
|
+
});
|
|
20892
|
+
}
|
|
20893
|
+
else {
|
|
20894
|
+
arr.push({
|
|
20895
|
+
length: max,
|
|
20896
|
+
message: interpolate('charactersCannotRepeatMoreThan', { max: String(max) }),
|
|
20897
|
+
rule: 'repeatedCharacters',
|
|
20898
|
+
});
|
|
20899
|
+
}
|
|
20900
|
+
return arr;
|
|
20901
|
+
}
|
|
20638
20902
|
else if (failedPolicy?.policyRequirement === 'VALID_USERNAME') {
|
|
20639
20903
|
return [
|
|
20640
20904
|
{
|
|
@@ -20663,6 +20927,11 @@ function getValidationFailureParams(failedPolicy) {
|
|
|
20663
20927
|
];
|
|
20664
20928
|
}
|
|
20665
20929
|
}
|
|
20930
|
+
/**
|
|
20931
|
+
* @function getValidationMessageString - Gets the validation message string from the policy object
|
|
20932
|
+
* @param {object} policy - The policy object from the callback
|
|
20933
|
+
* @returns {string} - The validation message string
|
|
20934
|
+
*/
|
|
20666
20935
|
function getValidationMessageString(policy) {
|
|
20667
20936
|
switch (policy?.policyId) {
|
|
20668
20937
|
case 'at-least-X-capitals': {
|
|
@@ -20746,6 +21015,12 @@ function getValidationMessageString(policy) {
|
|
|
20746
21015
|
return '';
|
|
20747
21016
|
}
|
|
20748
21017
|
}
|
|
21018
|
+
/**
|
|
21019
|
+
* @function getValidationFailures - Gets the validation failures from the callback object
|
|
21020
|
+
* @param {object} callback - The callback object from the server
|
|
21021
|
+
* @param {string} label - The label of the field
|
|
21022
|
+
* @returns {array} - An array of failed policies
|
|
21023
|
+
*/
|
|
20749
21024
|
function getValidationFailures(callback, label) {
|
|
20750
21025
|
const failedPolicies = callback.getFailedPolicies && callback.getFailedPolicies();
|
|
20751
21026
|
const parsedPolicies = parseFailedPolicies(failedPolicies, label);
|
|
@@ -20757,6 +21032,11 @@ function getValidationFailures(callback, label) {
|
|
|
20757
21032
|
};
|
|
20758
21033
|
});
|
|
20759
21034
|
}
|
|
21035
|
+
/**
|
|
21036
|
+
* @function getValidationPolicies - Gets the validation policies from the callback object
|
|
21037
|
+
* @param {object} policies - The policies object from the callback
|
|
21038
|
+
* @returns {array} - An array of policies
|
|
21039
|
+
*/
|
|
20760
21040
|
function getValidationPolicies(policies) {
|
|
20761
21041
|
if (typeof policies !== 'object' && !policies) {
|
|
20762
21042
|
return [];
|
|
@@ -20775,6 +21055,11 @@ function getValidationPolicies(policies) {
|
|
|
20775
21055
|
})
|
|
20776
21056
|
.filter((policy) => !!policy.message);
|
|
20777
21057
|
}
|
|
21058
|
+
/**
|
|
21059
|
+
* @function isInputRequired - Checks if the input is required
|
|
21060
|
+
* @param {object} callback - The callback object from the server
|
|
21061
|
+
* @returns {boolean} - Whether the input is required
|
|
21062
|
+
*/
|
|
20778
21063
|
function isInputRequired(callback) {
|
|
20779
21064
|
const policies = callback.getPolicies && callback.getPolicies();
|
|
20780
21065
|
let isRequired = false;
|
|
@@ -20786,46 +21071,93 @@ function isInputRequired(callback) {
|
|
|
20786
21071
|
}
|
|
20787
21072
|
return isRequired;
|
|
20788
21073
|
}
|
|
21074
|
+
/**
|
|
21075
|
+
* @function convertCharacterSetToRuleObj - Converts a character set to a rule object
|
|
21076
|
+
* @param {string} set - The character set to convert
|
|
21077
|
+
* @returns {object} - The rule object
|
|
21078
|
+
*/
|
|
20789
21079
|
function convertCharacterSetToRuleObj(set) {
|
|
20790
21080
|
const arr = set.split(':');
|
|
20791
21081
|
const num = arr[0];
|
|
20792
21082
|
const type = arr[1];
|
|
20793
21083
|
if (type === '0123456789') {
|
|
20794
|
-
|
|
20795
|
-
|
|
20796
|
-
|
|
20797
|
-
|
|
20798
|
-
|
|
21084
|
+
if (num === '0') {
|
|
21085
|
+
return {
|
|
21086
|
+
length: null,
|
|
21087
|
+
message: interpolate('shouldContainANumber'),
|
|
21088
|
+
rule: 'numbers',
|
|
21089
|
+
};
|
|
21090
|
+
}
|
|
21091
|
+
else {
|
|
21092
|
+
return {
|
|
21093
|
+
length: Number(num),
|
|
21094
|
+
message: interpolate('minimumNumberOfNumbers', { num: String(num) }),
|
|
21095
|
+
rule: 'numbers',
|
|
21096
|
+
};
|
|
21097
|
+
}
|
|
20799
21098
|
}
|
|
20800
21099
|
else if (type === 'ABCDEFGHIJKLMNOPQRSTUVWXYZ') {
|
|
20801
|
-
|
|
20802
|
-
|
|
20803
|
-
|
|
20804
|
-
|
|
20805
|
-
|
|
21100
|
+
if (num === '0') {
|
|
21101
|
+
return {
|
|
21102
|
+
length: null,
|
|
21103
|
+
message: interpolate('shouldContainAnUppercase'),
|
|
21104
|
+
rule: 'uppercase',
|
|
21105
|
+
};
|
|
21106
|
+
}
|
|
21107
|
+
else {
|
|
21108
|
+
return {
|
|
21109
|
+
length: Number(num),
|
|
21110
|
+
message: interpolate('minimumNumberOfUppercase', { num: String(num) }),
|
|
21111
|
+
rule: 'uppercase',
|
|
21112
|
+
};
|
|
21113
|
+
}
|
|
20806
21114
|
}
|
|
20807
21115
|
else if (type === 'abcdefghijklmnopqrstuvwxyz') {
|
|
20808
|
-
|
|
20809
|
-
|
|
20810
|
-
|
|
20811
|
-
|
|
20812
|
-
|
|
21116
|
+
if (num === '0') {
|
|
21117
|
+
return {
|
|
21118
|
+
length: null,
|
|
21119
|
+
message: interpolate('shouldContainALowercase'),
|
|
21120
|
+
rule: 'lowercase',
|
|
21121
|
+
};
|
|
21122
|
+
}
|
|
21123
|
+
else {
|
|
21124
|
+
return {
|
|
21125
|
+
length: Number(num),
|
|
21126
|
+
message: interpolate('minimumNumberOfLowercase', { num: String(num) }),
|
|
21127
|
+
rule: 'lowercase',
|
|
21128
|
+
};
|
|
21129
|
+
}
|
|
20813
21130
|
}
|
|
20814
21131
|
else if (type.includes('@') || type.includes('!') || type.includes('*') || type.includes('#')) {
|
|
20815
|
-
|
|
20816
|
-
|
|
20817
|
-
|
|
20818
|
-
|
|
20819
|
-
|
|
21132
|
+
if (num === '0') {
|
|
21133
|
+
return {
|
|
21134
|
+
length: null,
|
|
21135
|
+
message: interpolate('shouldContainASymbol'),
|
|
21136
|
+
rule: 'symbols',
|
|
21137
|
+
};
|
|
21138
|
+
}
|
|
21139
|
+
else {
|
|
21140
|
+
return {
|
|
21141
|
+
length: Number(num),
|
|
21142
|
+
message: interpolate('minimumNumberOfSymbols', { num: String(num) }),
|
|
21143
|
+
rule: 'symbols',
|
|
21144
|
+
};
|
|
21145
|
+
}
|
|
20820
21146
|
}
|
|
20821
21147
|
else {
|
|
20822
21148
|
return {
|
|
20823
|
-
length:
|
|
21149
|
+
length: null,
|
|
20824
21150
|
message: interpolate('pleaseCheckValue'),
|
|
20825
21151
|
rule: 'unknown',
|
|
20826
21152
|
};
|
|
20827
21153
|
}
|
|
20828
21154
|
}
|
|
21155
|
+
/**
|
|
21156
|
+
* @function parseFailedPolicies - Parses the failed policies from the callback object
|
|
21157
|
+
* @param {array} policies - The policies array from the callback
|
|
21158
|
+
* @param {string} label - The label of the field
|
|
21159
|
+
* @returns {array} - An array of failed policies
|
|
21160
|
+
*/
|
|
20829
21161
|
function parseFailedPolicies(policies, label) {
|
|
20830
21162
|
return policies.map((policy) => {
|
|
20831
21163
|
if (typeof policy === 'string') {
|
|
@@ -20841,8 +21173,10 @@ function parseFailedPolicies(policies, label) {
|
|
|
20841
21173
|
}
|
|
20842
21174
|
});
|
|
20843
21175
|
}
|
|
20844
|
-
/**
|
|
20845
|
-
*
|
|
21176
|
+
/**
|
|
21177
|
+
* @function getAttributeValidationFailureText - Gets the validation failure text from the callback object
|
|
21178
|
+
* @param {object} callback - The callback object from the server
|
|
21179
|
+
* @returns {string} - The validation failure text
|
|
20846
21180
|
*/
|
|
20847
21181
|
function getAttributeValidationFailureText(callback) {
|
|
20848
21182
|
// TODO: Mature this utility for better parsing and display
|
|
@@ -21841,13 +22175,6 @@ function instance$I($$self, $$props, $$invalidate) {
|
|
|
21841
22175
|
let validationFailure;
|
|
21842
22176
|
|
|
21843
22177
|
function setValue(event) {
|
|
21844
|
-
/** ***********************************************************************
|
|
21845
|
-
* SDK INTEGRATION POINT
|
|
21846
|
-
* Summary: SDK callback methods for setting values
|
|
21847
|
-
* ------------------------------------------------------------------------
|
|
21848
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
21849
|
-
* for writing values to the callbacks received from AM
|
|
21850
|
-
*********************************************************************** */
|
|
21851
22178
|
callback.setInputValue(event.target.checked);
|
|
21852
22179
|
}
|
|
21853
22180
|
|
|
@@ -22787,7 +23114,7 @@ function get_each_context$7(ctx, list, i) {
|
|
|
22787
23114
|
return child_ctx;
|
|
22788
23115
|
}
|
|
22789
23116
|
|
|
22790
|
-
// (
|
|
23117
|
+
// (39:0) {#if labelOrder === 'first'}
|
|
22791
23118
|
function create_if_block_1$a(ctx) {
|
|
22792
23119
|
let label_1;
|
|
22793
23120
|
let current;
|
|
@@ -22835,7 +23162,7 @@ function create_if_block_1$a(ctx) {
|
|
|
22835
23162
|
};
|
|
22836
23163
|
}
|
|
22837
23164
|
|
|
22838
|
-
// (
|
|
23165
|
+
// (40:2) <Label {key} classes={`${labelClasses}`}>
|
|
22839
23166
|
function create_default_slot_1$b(ctx) {
|
|
22840
23167
|
let t;
|
|
22841
23168
|
|
|
@@ -22855,7 +23182,7 @@ function create_default_slot_1$b(ctx) {
|
|
|
22855
23182
|
};
|
|
22856
23183
|
}
|
|
22857
23184
|
|
|
22858
|
-
// (
|
|
23185
|
+
// (54:2) {#each options as option}
|
|
22859
23186
|
function create_each_block$7(ctx) {
|
|
22860
23187
|
let option;
|
|
22861
23188
|
let t0_value = /*option*/ ctx[15].text + "";
|
|
@@ -22896,7 +23223,7 @@ function create_each_block$7(ctx) {
|
|
|
22896
23223
|
};
|
|
22897
23224
|
}
|
|
22898
23225
|
|
|
22899
|
-
// (
|
|
23226
|
+
// (61:0) {#if labelOrder === 'last'}
|
|
22900
23227
|
function create_if_block$g(ctx) {
|
|
22901
23228
|
let label_1;
|
|
22902
23229
|
let current;
|
|
@@ -22949,7 +23276,7 @@ function create_if_block$g(ctx) {
|
|
|
22949
23276
|
};
|
|
22950
23277
|
}
|
|
22951
23278
|
|
|
22952
|
-
// (
|
|
23279
|
+
// (62:2) <Label {key} classes={`${shouldDisplayOption ? labelClasses : 'tw_sr-only'}`}>
|
|
22953
23280
|
function create_default_slot$i(ctx) {
|
|
22954
23281
|
let t;
|
|
22955
23282
|
|
|
@@ -23188,8 +23515,6 @@ function instance$E($$self, $$props, $$invalidate) {
|
|
|
23188
23515
|
// Check if text is same as label
|
|
23189
23516
|
$$invalidate(10, shouldDisplayOption = !(label === selectedOption?.text));
|
|
23190
23517
|
|
|
23191
|
-
console.log(shouldDisplayOption);
|
|
23192
|
-
|
|
23193
23518
|
// Continue with calling onChange parameter
|
|
23194
23519
|
onChange(event);
|
|
23195
23520
|
}
|
|
@@ -23616,7 +23941,7 @@ function create_else_block$6(ctx) {
|
|
|
23616
23941
|
};
|
|
23617
23942
|
}
|
|
23618
23943
|
|
|
23619
|
-
// (
|
|
23944
|
+
// (52:0) {#if callbackMetadata?.platform?.displayType === 'radio'}
|
|
23620
23945
|
function create_if_block$f(ctx) {
|
|
23621
23946
|
let radio;
|
|
23622
23947
|
let current;
|
|
@@ -23771,13 +24096,6 @@ function instance$B($$self, $$props, $$invalidate) {
|
|
|
23771
24096
|
* @param {Object} event
|
|
23772
24097
|
*/
|
|
23773
24098
|
function setValue(event) {
|
|
23774
|
-
/** ***********************************************************************
|
|
23775
|
-
* SDK INTEGRATION POINT
|
|
23776
|
-
* Summary: SDK callback methods for setting values
|
|
23777
|
-
* ------------------------------------------------------------------------
|
|
23778
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
23779
|
-
* for writing values to the callbacks received from AM
|
|
23780
|
-
*********************************************************************** */
|
|
23781
24099
|
callback.setChoiceIndex(Number(event.target.value));
|
|
23782
24100
|
}
|
|
23783
24101
|
|
|
@@ -23790,13 +24108,6 @@ function instance$B($$self, $$props, $$invalidate) {
|
|
|
23790
24108
|
$$self.$$.update = () => {
|
|
23791
24109
|
if ($$self.$$.dirty & /*callback, callbackMetadata, prompt*/ 2051) {
|
|
23792
24110
|
{
|
|
23793
|
-
/** *************************************************************************
|
|
23794
|
-
* SDK INTEGRATION POINT
|
|
23795
|
-
* Summary: SDK callback methods for getting values
|
|
23796
|
-
* --------------------------------------------------------------------------
|
|
23797
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
23798
|
-
* for accessing values from the callbacks received from AM
|
|
23799
|
-
************************************************************************* */
|
|
23800
24111
|
$$invalidate(2, choiceOptions = callback.getChoices()?.map((text, idx) => ({
|
|
23801
24112
|
/**
|
|
23802
24113
|
* Since locale content keys for the choice component are built off of the
|
|
@@ -23961,7 +24272,7 @@ function get_each_context$6(ctx, list, i) {
|
|
|
23961
24272
|
return child_ctx;
|
|
23962
24273
|
}
|
|
23963
24274
|
|
|
23964
|
-
// (
|
|
24275
|
+
// (81:0) {#if stepMetadata?.platform?.stageName !== 'OneTimePassword'}
|
|
23965
24276
|
function create_if_block$e(ctx) {
|
|
23966
24277
|
let current_block_type_index;
|
|
23967
24278
|
let if_block;
|
|
@@ -24031,7 +24342,7 @@ function create_if_block$e(ctx) {
|
|
|
24031
24342
|
};
|
|
24032
24343
|
}
|
|
24033
24344
|
|
|
24034
|
-
// (
|
|
24345
|
+
// (103:2) {:else}
|
|
24035
24346
|
function create_else_block_1(ctx) {
|
|
24036
24347
|
let grid;
|
|
24037
24348
|
let current;
|
|
@@ -24077,7 +24388,7 @@ function create_else_block_1(ctx) {
|
|
|
24077
24388
|
};
|
|
24078
24389
|
}
|
|
24079
24390
|
|
|
24080
|
-
// (
|
|
24391
|
+
// (82:2) {#if !stepMetadata?.derived.isStepSelfSubmittable}
|
|
24081
24392
|
function create_if_block_1$9(ctx) {
|
|
24082
24393
|
let current_block_type_index;
|
|
24083
24394
|
let if_block;
|
|
@@ -24147,7 +24458,7 @@ function create_if_block_1$9(ctx) {
|
|
|
24147
24458
|
};
|
|
24148
24459
|
}
|
|
24149
24460
|
|
|
24150
|
-
// (
|
|
24461
|
+
// (106:8) <Button style={options.length > 1 && defaultChoice === Number(opt.value) ? 'primary' : buttonStyle} type="button" width="auto" onClick={() => setBtnValue(Number(opt.value))} >
|
|
24151
24462
|
function create_default_slot_2$5(ctx) {
|
|
24152
24463
|
let t0_value = /*opt*/ ctx[15].text + "";
|
|
24153
24464
|
let t0;
|
|
@@ -24172,7 +24483,7 @@ function create_default_slot_2$5(ctx) {
|
|
|
24172
24483
|
};
|
|
24173
24484
|
}
|
|
24174
24485
|
|
|
24175
|
-
// (
|
|
24486
|
+
// (105:6) {#each options as opt}
|
|
24176
24487
|
function create_each_block$6(ctx) {
|
|
24177
24488
|
let button;
|
|
24178
24489
|
let current;
|
|
@@ -24233,7 +24544,7 @@ function create_each_block$6(ctx) {
|
|
|
24233
24544
|
};
|
|
24234
24545
|
}
|
|
24235
24546
|
|
|
24236
|
-
// (
|
|
24547
|
+
// (104:4) <Grid num={options.length}>
|
|
24237
24548
|
function create_default_slot_1$a(ctx) {
|
|
24238
24549
|
let each_1_anchor;
|
|
24239
24550
|
let current;
|
|
@@ -24317,7 +24628,7 @@ function create_default_slot_1$a(ctx) {
|
|
|
24317
24628
|
};
|
|
24318
24629
|
}
|
|
24319
24630
|
|
|
24320
|
-
// (
|
|
24631
|
+
// (92:4) {:else}
|
|
24321
24632
|
function create_else_block$5(ctx) {
|
|
24322
24633
|
let checkbox;
|
|
24323
24634
|
let current;
|
|
@@ -24368,7 +24679,7 @@ function create_else_block$5(ctx) {
|
|
|
24368
24679
|
};
|
|
24369
24680
|
}
|
|
24370
24681
|
|
|
24371
|
-
// (
|
|
24682
|
+
// (83:4) {#if options.length > 1}
|
|
24372
24683
|
function create_if_block_2$8(ctx) {
|
|
24373
24684
|
let select;
|
|
24374
24685
|
let current;
|
|
@@ -24415,7 +24726,7 @@ function create_if_block_2$8(ctx) {
|
|
|
24415
24726
|
};
|
|
24416
24727
|
}
|
|
24417
24728
|
|
|
24418
|
-
// (
|
|
24729
|
+
// (93:6) <Checkbox isFirstInvalidInput={callbackMetadata?.derived.isFirstInvalidInput || false} isInvalid={false} key={inputName} onChange={setCheckboxValue} value={false} >
|
|
24419
24730
|
function create_default_slot$h(ctx) {
|
|
24420
24731
|
let t_value = /*options*/ ctx[3][0].text + "";
|
|
24421
24732
|
let t;
|
|
@@ -24527,13 +24838,6 @@ function instance$z($$self, $$props, $$invalidate) {
|
|
|
24527
24838
|
* @param {Object} event
|
|
24528
24839
|
*/
|
|
24529
24840
|
function setOptionValue(event) {
|
|
24530
|
-
/** ***********************************************************************
|
|
24531
|
-
* SDK INTEGRATION POINT
|
|
24532
|
-
* Summary: SDK callback methods for setting values
|
|
24533
|
-
* ------------------------------------------------------------------------
|
|
24534
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
24535
|
-
* for writing values to the callbacks received from AM
|
|
24536
|
-
*********************************************************************** */
|
|
24537
24841
|
callback.setOptionIndex(Number(event.target.value));
|
|
24538
24842
|
}
|
|
24539
24843
|
|
|
@@ -24542,13 +24846,6 @@ function instance$z($$self, $$props, $$invalidate) {
|
|
|
24542
24846
|
* @param {Object} event
|
|
24543
24847
|
*/
|
|
24544
24848
|
function setCheckboxValue(event) {
|
|
24545
|
-
/** ***********************************************************************
|
|
24546
|
-
* SDK INTEGRATION POINT
|
|
24547
|
-
* Summary: SDK callback methods for setting values
|
|
24548
|
-
* ------------------------------------------------------------------------
|
|
24549
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
24550
|
-
* for writing values to the callbacks received from AM
|
|
24551
|
-
*********************************************************************** */
|
|
24552
24849
|
const value = event.target.checked;
|
|
24553
24850
|
|
|
24554
24851
|
if (value) {
|
|
@@ -24913,7 +25210,7 @@ function create_if_block_5$1(ctx) {
|
|
|
24913
25210
|
}
|
|
24914
25211
|
|
|
24915
25212
|
// (65:0) {#if type === 'number'}
|
|
24916
|
-
function create_if_block_4$
|
|
25213
|
+
function create_if_block_4$2(ctx) {
|
|
24917
25214
|
let input;
|
|
24918
25215
|
let input_aria_describedby_value;
|
|
24919
25216
|
let input_class_value;
|
|
@@ -24993,7 +25290,7 @@ function create_if_block_4$1(ctx) {
|
|
|
24993
25290
|
}
|
|
24994
25291
|
|
|
24995
25292
|
// (81:0) {#if type === 'password'}
|
|
24996
|
-
function create_if_block_3$
|
|
25293
|
+
function create_if_block_3$6(ctx) {
|
|
24997
25294
|
let input;
|
|
24998
25295
|
let input_aria_describedby_value;
|
|
24999
25296
|
let input_class_value;
|
|
@@ -25313,8 +25610,8 @@ function create_fragment$x(ctx) {
|
|
|
25313
25610
|
let if_block0 = /*labelOrder*/ ctx[6] === 'first' && create_if_block_7$1(ctx);
|
|
25314
25611
|
let if_block1 = /*type*/ ctx[11] === 'date' && create_if_block_6$1(ctx);
|
|
25315
25612
|
let if_block2 = /*type*/ ctx[11] === 'email' && create_if_block_5$1(ctx);
|
|
25316
|
-
let if_block3 = /*type*/ ctx[11] === 'number' && create_if_block_4$
|
|
25317
|
-
let if_block4 = /*type*/ ctx[11] === 'password' && create_if_block_3$
|
|
25613
|
+
let if_block3 = /*type*/ ctx[11] === 'number' && create_if_block_4$2(ctx);
|
|
25614
|
+
let if_block4 = /*type*/ ctx[11] === 'password' && create_if_block_3$6(ctx);
|
|
25318
25615
|
let if_block5 = /*type*/ ctx[11] === 'phone' && create_if_block_2$7(ctx);
|
|
25319
25616
|
let if_block6 = /*type*/ ctx[11] === 'text' && create_if_block_1$8(ctx);
|
|
25320
25617
|
let if_block7 = /*labelOrder*/ ctx[6] === 'last' && create_if_block$d(ctx);
|
|
@@ -25411,7 +25708,7 @@ function create_fragment$x(ctx) {
|
|
|
25411
25708
|
if (if_block3) {
|
|
25412
25709
|
if_block3.p(ctx, dirty);
|
|
25413
25710
|
} else {
|
|
25414
|
-
if_block3 = create_if_block_4$
|
|
25711
|
+
if_block3 = create_if_block_4$2(ctx);
|
|
25415
25712
|
if_block3.c();
|
|
25416
25713
|
if_block3.m(t3.parentNode, t3);
|
|
25417
25714
|
}
|
|
@@ -25424,7 +25721,7 @@ function create_fragment$x(ctx) {
|
|
|
25424
25721
|
if (if_block4) {
|
|
25425
25722
|
if_block4.p(ctx, dirty);
|
|
25426
25723
|
} else {
|
|
25427
|
-
if_block4 = create_if_block_3$
|
|
25724
|
+
if_block4 = create_if_block_3$6(ctx);
|
|
25428
25725
|
if_block4.c();
|
|
25429
25726
|
if_block4.m(t4.parentNode, t4);
|
|
25430
25727
|
}
|
|
@@ -26560,15 +26857,7 @@ function instance$t($$self, $$props, $$invalidate) {
|
|
|
26560
26857
|
? Stacked_label$1
|
|
26561
26858
|
: Floating_label$1;
|
|
26562
26859
|
|
|
26563
|
-
/** *************************************************************************
|
|
26564
|
-
* SDK INTEGRATION POINT
|
|
26565
|
-
* Summary: SDK callback methods for getting values
|
|
26566
|
-
* --------------------------------------------------------------------------
|
|
26567
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
26568
|
-
* for accessing values from the callbacks received from AM
|
|
26569
|
-
************************************************************************* */
|
|
26570
26860
|
let customQuestionIndex = null;
|
|
26571
|
-
|
|
26572
26861
|
let displayCustomQuestionInput = false;
|
|
26573
26862
|
let inputArr;
|
|
26574
26863
|
let inputName;
|
|
@@ -26596,13 +26885,6 @@ function instance$t($$self, $$props, $$invalidate) {
|
|
|
26596
26885
|
* @param {Object} event
|
|
26597
26886
|
*/
|
|
26598
26887
|
function setAnswer(event) {
|
|
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
26888
|
callback.setAnswer(event.target.value);
|
|
26607
26889
|
}
|
|
26608
26890
|
|
|
@@ -26619,14 +26901,6 @@ function instance$t($$self, $$props, $$invalidate) {
|
|
|
26619
26901
|
callback.setAnswer('');
|
|
26620
26902
|
} else {
|
|
26621
26903
|
$$invalidate(3, displayCustomQuestionInput = false);
|
|
26622
|
-
|
|
26623
|
-
/** ***********************************************************************
|
|
26624
|
-
* SDK INTEGRATION POINT
|
|
26625
|
-
* Summary: SDK callback methods for setting values
|
|
26626
|
-
* ------------------------------------------------------------------------
|
|
26627
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
26628
|
-
* for writing values to the callbacks received from AM
|
|
26629
|
-
*********************************************************************** */
|
|
26630
26904
|
callback.setQuestion(selectValue);
|
|
26631
26905
|
}
|
|
26632
26906
|
}
|
|
@@ -26637,14 +26911,6 @@ function instance$t($$self, $$props, $$invalidate) {
|
|
|
26637
26911
|
*/
|
|
26638
26912
|
function setQuestion(event) {
|
|
26639
26913
|
const inputValue = event.target.value;
|
|
26640
|
-
|
|
26641
|
-
/** ***********************************************************************
|
|
26642
|
-
* SDK INTEGRATION POINT
|
|
26643
|
-
* Summary: SDK callback methods for setting values
|
|
26644
|
-
* ------------------------------------------------------------------------
|
|
26645
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
26646
|
-
* for writing values to the callbacks received from AM
|
|
26647
|
-
*********************************************************************** */
|
|
26648
26914
|
callback.setQuestion(inputValue);
|
|
26649
26915
|
}
|
|
26650
26916
|
|
|
@@ -27135,8 +27401,8 @@ class Eye_icon extends SvelteComponent {
|
|
|
27135
27401
|
|
|
27136
27402
|
function create_default_slot_1$8(ctx) {
|
|
27137
27403
|
let current;
|
|
27138
|
-
const default_slot_template = /*#slots*/ ctx[
|
|
27139
|
-
const default_slot = create_slot(default_slot_template, ctx, /*$$scope*/ ctx[
|
|
27404
|
+
const default_slot_template = /*#slots*/ ctx[15].default;
|
|
27405
|
+
const default_slot = create_slot(default_slot_template, ctx, /*$$scope*/ ctx[16], null);
|
|
27140
27406
|
|
|
27141
27407
|
return {
|
|
27142
27408
|
c() {
|
|
@@ -27151,15 +27417,15 @@ function create_default_slot_1$8(ctx) {
|
|
|
27151
27417
|
},
|
|
27152
27418
|
p(ctx, dirty) {
|
|
27153
27419
|
if (default_slot) {
|
|
27154
|
-
if (default_slot.p && (!current || dirty & /*$$scope*/
|
|
27420
|
+
if (default_slot.p && (!current || dirty & /*$$scope*/ 65536)) {
|
|
27155
27421
|
update_slot_base(
|
|
27156
27422
|
default_slot,
|
|
27157
27423
|
default_slot_template,
|
|
27158
27424
|
ctx,
|
|
27159
|
-
/*$$scope*/ ctx[
|
|
27425
|
+
/*$$scope*/ ctx[16],
|
|
27160
27426
|
!current
|
|
27161
|
-
? get_all_dirty_from_scope(/*$$scope*/ ctx[
|
|
27162
|
-
: get_slot_changes(default_slot_template, /*$$scope*/ ctx[
|
|
27427
|
+
? get_all_dirty_from_scope(/*$$scope*/ ctx[16])
|
|
27428
|
+
: get_slot_changes(default_slot_template, /*$$scope*/ ctx[16], dirty, null),
|
|
27163
27429
|
null
|
|
27164
27430
|
);
|
|
27165
27431
|
}
|
|
@@ -27180,7 +27446,7 @@ function create_default_slot_1$8(ctx) {
|
|
|
27180
27446
|
};
|
|
27181
27447
|
}
|
|
27182
27448
|
|
|
27183
|
-
// (
|
|
27449
|
+
// (69:4) <EyeIcon classes="tw_password-icon dark:tw_password-icon_dark" visible={isVisible}>
|
|
27184
27450
|
function create_default_slot$f(ctx) {
|
|
27185
27451
|
let t;
|
|
27186
27452
|
let current;
|
|
@@ -27210,7 +27476,7 @@ function create_default_slot$f(ctx) {
|
|
|
27210
27476
|
};
|
|
27211
27477
|
}
|
|
27212
27478
|
|
|
27213
|
-
// (
|
|
27479
|
+
// (63:2)
|
|
27214
27480
|
function create_input_button_slot$1(ctx) {
|
|
27215
27481
|
let button;
|
|
27216
27482
|
let eyeicon;
|
|
@@ -27241,7 +27507,7 @@ function create_input_button_slot$1(ctx) {
|
|
|
27241
27507
|
current = true;
|
|
27242
27508
|
|
|
27243
27509
|
if (!mounted) {
|
|
27244
|
-
dispose = listen(button, "click", /*toggleVisibility*/ ctx[
|
|
27510
|
+
dispose = listen(button, "click", /*toggleVisibility*/ ctx[11]);
|
|
27245
27511
|
mounted = true;
|
|
27246
27512
|
}
|
|
27247
27513
|
},
|
|
@@ -27249,7 +27515,7 @@ function create_input_button_slot$1(ctx) {
|
|
|
27249
27515
|
const eyeicon_changes = {};
|
|
27250
27516
|
if (dirty & /*isVisible*/ 64) eyeicon_changes.visible = /*isVisible*/ ctx[6];
|
|
27251
27517
|
|
|
27252
|
-
if (dirty & /*$$scope*/
|
|
27518
|
+
if (dirty & /*$$scope*/ 65536) {
|
|
27253
27519
|
eyeicon_changes.$$scope = { dirty, ctx };
|
|
27254
27520
|
}
|
|
27255
27521
|
|
|
@@ -27277,23 +27543,21 @@ function create_fragment$q(ctx) {
|
|
|
27277
27543
|
let input;
|
|
27278
27544
|
let current;
|
|
27279
27545
|
|
|
27280
|
-
input = new /*Input*/ ctx[
|
|
27546
|
+
input = new /*Input*/ ctx[9]({
|
|
27281
27547
|
props: {
|
|
27282
27548
|
forceValidityFailure: /*forceValidityFailure*/ ctx[0],
|
|
27283
27549
|
isFirstInvalidInput: false,
|
|
27284
27550
|
hasRightIcon: true,
|
|
27285
|
-
key: `${/*key*/ ctx[
|
|
27551
|
+
key: `${/*key*/ ctx[3]}-confirm`,
|
|
27286
27552
|
label: interpolate('confirmPassword', null, 'Confirm Password'),
|
|
27287
|
-
message: /*
|
|
27288
|
-
|
|
27289
|
-
:
|
|
27290
|
-
|
|
27291
|
-
|
|
27292
|
-
isRequired: /*isRequired*/ ctx[4],
|
|
27293
|
-
showMessage: /*showMessage*/ ctx[5],
|
|
27553
|
+
message: /*message*/ ctx[8],
|
|
27554
|
+
onChange: /*onChangeWrapper*/ ctx[10],
|
|
27555
|
+
isInvalid: /*passwordsDoNotMatch*/ ctx[1],
|
|
27556
|
+
isRequired: /*isRequired*/ ctx[2],
|
|
27557
|
+
showMessage: /*showMessage*/ ctx[4],
|
|
27294
27558
|
type: /*type*/ ctx[7],
|
|
27295
|
-
value: typeof /*value*/ ctx[
|
|
27296
|
-
? /*value*/ ctx[
|
|
27559
|
+
value: typeof /*value*/ ctx[5] === 'string'
|
|
27560
|
+
? /*value*/ ctx[5]
|
|
27297
27561
|
: '',
|
|
27298
27562
|
$$slots: {
|
|
27299
27563
|
"input-button": [create_input_button_slot$1],
|
|
@@ -27314,19 +27578,18 @@ function create_fragment$q(ctx) {
|
|
|
27314
27578
|
p(ctx, [dirty]) {
|
|
27315
27579
|
const input_changes = {};
|
|
27316
27580
|
if (dirty & /*forceValidityFailure*/ 1) input_changes.forceValidityFailure = /*forceValidityFailure*/ ctx[0];
|
|
27317
|
-
if (dirty & /*key*/
|
|
27318
|
-
|
|
27319
|
-
if (dirty & /*
|
|
27320
|
-
|
|
27321
|
-
|
|
27322
|
-
|
|
27323
|
-
if (dirty & /*onChange*/ 4) input_changes.onChange = /*onChange*/ ctx[2];
|
|
27324
|
-
if (dirty & /*isInvalid*/ 8) input_changes.isInvalid = /*isInvalid*/ ctx[3];
|
|
27325
|
-
if (dirty & /*isRequired*/ 16) input_changes.isRequired = /*isRequired*/ ctx[4];
|
|
27326
|
-
if (dirty & /*showMessage*/ 32) input_changes.showMessage = /*showMessage*/ ctx[5];
|
|
27581
|
+
if (dirty & /*key*/ 8) input_changes.key = `${/*key*/ ctx[3]}-confirm`;
|
|
27582
|
+
if (dirty & /*message*/ 256) input_changes.message = /*message*/ ctx[8];
|
|
27583
|
+
if (dirty & /*passwordsDoNotMatch*/ 2) input_changes.isInvalid = /*passwordsDoNotMatch*/ ctx[1];
|
|
27584
|
+
if (dirty & /*isRequired*/ 4) input_changes.isRequired = /*isRequired*/ ctx[2];
|
|
27585
|
+
if (dirty & /*showMessage*/ 16) input_changes.showMessage = /*showMessage*/ ctx[4];
|
|
27327
27586
|
if (dirty & /*type*/ 128) input_changes.type = /*type*/ ctx[7];
|
|
27328
27587
|
|
|
27329
|
-
if (dirty &
|
|
27588
|
+
if (dirty & /*value*/ 32) input_changes.value = typeof /*value*/ ctx[5] === 'string'
|
|
27589
|
+
? /*value*/ ctx[5]
|
|
27590
|
+
: '';
|
|
27591
|
+
|
|
27592
|
+
if (dirty & /*$$scope, isVisible*/ 65600) {
|
|
27330
27593
|
input_changes.$$scope = { dirty, ctx };
|
|
27331
27594
|
}
|
|
27332
27595
|
|
|
@@ -27350,16 +27613,25 @@ function create_fragment$q(ctx) {
|
|
|
27350
27613
|
function instance$q($$self, $$props, $$invalidate) {
|
|
27351
27614
|
let { $$slots: slots = {}, $$scope } = $$props;
|
|
27352
27615
|
let { forceValidityFailure = false } = $$props;
|
|
27616
|
+
let { passwordsDoNotMatch = false } = $$props;
|
|
27617
|
+
let { isRequired = false } = $$props;
|
|
27353
27618
|
let { key } = $$props;
|
|
27354
27619
|
let { onChange } = $$props;
|
|
27355
|
-
let {
|
|
27356
|
-
let { isRequired = true } = $$props;
|
|
27620
|
+
let { resetValue } = $$props;
|
|
27357
27621
|
let { style = {} } = $$props;
|
|
27358
27622
|
const Input = style.labels === 'stacked' ? Stacked_label : Floating_label;
|
|
27359
27623
|
let { showMessage = undefined } = $$props;
|
|
27360
27624
|
let isVisible = false;
|
|
27361
27625
|
let type = 'password';
|
|
27362
27626
|
let value;
|
|
27627
|
+
let message = '';
|
|
27628
|
+
|
|
27629
|
+
function onChangeWrapper(event) {
|
|
27630
|
+
$$invalidate(5, value = event.target?.value);
|
|
27631
|
+
|
|
27632
|
+
// TODO: revisit this logic to avoid unnecessary ternary
|
|
27633
|
+
onChange(typeof value === 'string' ? value : undefined);
|
|
27634
|
+
}
|
|
27363
27635
|
|
|
27364
27636
|
/**
|
|
27365
27637
|
* @function toggleVisibility - toggles the password from masked to plaintext
|
|
@@ -27371,27 +27643,50 @@ function instance$q($$self, $$props, $$invalidate) {
|
|
|
27371
27643
|
|
|
27372
27644
|
$$self.$$set = $$props => {
|
|
27373
27645
|
if ('forceValidityFailure' in $$props) $$invalidate(0, forceValidityFailure = $$props.forceValidityFailure);
|
|
27374
|
-
if ('
|
|
27375
|
-
if ('
|
|
27376
|
-
if ('
|
|
27377
|
-
if ('
|
|
27378
|
-
if ('
|
|
27379
|
-
if ('
|
|
27380
|
-
if ('
|
|
27646
|
+
if ('passwordsDoNotMatch' in $$props) $$invalidate(1, passwordsDoNotMatch = $$props.passwordsDoNotMatch);
|
|
27647
|
+
if ('isRequired' in $$props) $$invalidate(2, isRequired = $$props.isRequired);
|
|
27648
|
+
if ('key' in $$props) $$invalidate(3, key = $$props.key);
|
|
27649
|
+
if ('onChange' in $$props) $$invalidate(12, onChange = $$props.onChange);
|
|
27650
|
+
if ('resetValue' in $$props) $$invalidate(13, resetValue = $$props.resetValue);
|
|
27651
|
+
if ('style' in $$props) $$invalidate(14, style = $$props.style);
|
|
27652
|
+
if ('showMessage' in $$props) $$invalidate(4, showMessage = $$props.showMessage);
|
|
27653
|
+
if ('$$scope' in $$props) $$invalidate(16, $$scope = $$props.$$scope);
|
|
27654
|
+
};
|
|
27655
|
+
|
|
27656
|
+
$$self.$$.update = () => {
|
|
27657
|
+
if ($$self.$$.dirty & /*resetValue, onChange, value, passwordsDoNotMatch, isRequired*/ 12326) {
|
|
27658
|
+
{
|
|
27659
|
+
if (resetValue) {
|
|
27660
|
+
$$invalidate(5, value = undefined);
|
|
27661
|
+
onChange(value);
|
|
27662
|
+
}
|
|
27663
|
+
|
|
27664
|
+
if (passwordsDoNotMatch) {
|
|
27665
|
+
$$invalidate(8, message = interpolate('passwordConfirmationError', null, 'Passwords do not match'));
|
|
27666
|
+
} else if (isRequired) {
|
|
27667
|
+
$$invalidate(8, message = interpolate('requiredField', null, 'This field is required'));
|
|
27668
|
+
} else {
|
|
27669
|
+
$$invalidate(8, message = '');
|
|
27670
|
+
}
|
|
27671
|
+
}
|
|
27672
|
+
}
|
|
27381
27673
|
};
|
|
27382
27674
|
|
|
27383
27675
|
return [
|
|
27384
27676
|
forceValidityFailure,
|
|
27385
|
-
|
|
27386
|
-
onChange,
|
|
27387
|
-
isInvalid,
|
|
27677
|
+
passwordsDoNotMatch,
|
|
27388
27678
|
isRequired,
|
|
27679
|
+
key,
|
|
27389
27680
|
showMessage,
|
|
27681
|
+
value,
|
|
27390
27682
|
isVisible,
|
|
27391
27683
|
type,
|
|
27684
|
+
message,
|
|
27392
27685
|
Input,
|
|
27393
|
-
|
|
27686
|
+
onChangeWrapper,
|
|
27394
27687
|
toggleVisibility,
|
|
27688
|
+
onChange,
|
|
27689
|
+
resetValue,
|
|
27395
27690
|
style,
|
|
27396
27691
|
slots,
|
|
27397
27692
|
$$scope
|
|
@@ -27404,12 +27699,13 @@ class Confirm_input extends SvelteComponent {
|
|
|
27404
27699
|
|
|
27405
27700
|
init(this, options, instance$q, create_fragment$q, safe_not_equal, {
|
|
27406
27701
|
forceValidityFailure: 0,
|
|
27407
|
-
|
|
27408
|
-
|
|
27409
|
-
|
|
27410
|
-
|
|
27411
|
-
|
|
27412
|
-
|
|
27702
|
+
passwordsDoNotMatch: 1,
|
|
27703
|
+
isRequired: 2,
|
|
27704
|
+
key: 3,
|
|
27705
|
+
onChange: 12,
|
|
27706
|
+
resetValue: 13,
|
|
27707
|
+
style: 14,
|
|
27708
|
+
showMessage: 4
|
|
27413
27709
|
});
|
|
27414
27710
|
}
|
|
27415
27711
|
}
|
|
@@ -27418,8 +27714,8 @@ class Confirm_input extends SvelteComponent {
|
|
|
27418
27714
|
|
|
27419
27715
|
function create_default_slot_1$7(ctx) {
|
|
27420
27716
|
let current;
|
|
27421
|
-
const default_slot_template = /*#slots*/ ctx[
|
|
27422
|
-
const default_slot = create_slot(default_slot_template, ctx, /*$$scope*/ ctx[
|
|
27717
|
+
const default_slot_template = /*#slots*/ ctx[21].default;
|
|
27718
|
+
const default_slot = create_slot(default_slot_template, ctx, /*$$scope*/ ctx[22], null);
|
|
27423
27719
|
|
|
27424
27720
|
return {
|
|
27425
27721
|
c() {
|
|
@@ -27434,15 +27730,15 @@ function create_default_slot_1$7(ctx) {
|
|
|
27434
27730
|
},
|
|
27435
27731
|
p(ctx, dirty) {
|
|
27436
27732
|
if (default_slot) {
|
|
27437
|
-
if (default_slot.p && (!current || dirty & /*$$scope*/
|
|
27733
|
+
if (default_slot.p && (!current || dirty & /*$$scope*/ 4194304)) {
|
|
27438
27734
|
update_slot_base(
|
|
27439
27735
|
default_slot,
|
|
27440
27736
|
default_slot_template,
|
|
27441
27737
|
ctx,
|
|
27442
|
-
/*$$scope*/ ctx[
|
|
27738
|
+
/*$$scope*/ ctx[22],
|
|
27443
27739
|
!current
|
|
27444
|
-
? get_all_dirty_from_scope(/*$$scope*/ ctx[
|
|
27445
|
-
: get_slot_changes(default_slot_template, /*$$scope*/ ctx[
|
|
27740
|
+
? get_all_dirty_from_scope(/*$$scope*/ ctx[22])
|
|
27741
|
+
: get_slot_changes(default_slot_template, /*$$scope*/ ctx[22], dirty, null),
|
|
27446
27742
|
null
|
|
27447
27743
|
);
|
|
27448
27744
|
}
|
|
@@ -27463,7 +27759,7 @@ function create_default_slot_1$7(ctx) {
|
|
|
27463
27759
|
};
|
|
27464
27760
|
}
|
|
27465
27761
|
|
|
27466
|
-
// (
|
|
27762
|
+
// (94:4) <EyeIcon classes="tw_password-icon dark:tw_password-icon_dark" visible={isVisible}>
|
|
27467
27763
|
function create_default_slot$e(ctx) {
|
|
27468
27764
|
let t;
|
|
27469
27765
|
let current;
|
|
@@ -27493,7 +27789,7 @@ function create_default_slot$e(ctx) {
|
|
|
27493
27789
|
};
|
|
27494
27790
|
}
|
|
27495
27791
|
|
|
27496
|
-
// (
|
|
27792
|
+
// (88:2)
|
|
27497
27793
|
function create_input_button_slot(ctx) {
|
|
27498
27794
|
let button;
|
|
27499
27795
|
let eyeicon;
|
|
@@ -27524,7 +27820,7 @@ function create_input_button_slot(ctx) {
|
|
|
27524
27820
|
current = true;
|
|
27525
27821
|
|
|
27526
27822
|
if (!mounted) {
|
|
27527
|
-
dispose = listen(button, "click", /*toggleVisibility*/ ctx[
|
|
27823
|
+
dispose = listen(button, "click", /*toggleVisibility*/ ctx[17]);
|
|
27528
27824
|
mounted = true;
|
|
27529
27825
|
}
|
|
27530
27826
|
},
|
|
@@ -27532,7 +27828,7 @@ function create_input_button_slot(ctx) {
|
|
|
27532
27828
|
const eyeicon_changes = {};
|
|
27533
27829
|
if (dirty & /*isVisible*/ 1024) eyeicon_changes.visible = /*isVisible*/ ctx[10];
|
|
27534
27830
|
|
|
27535
|
-
if (dirty & /*$$scope*/
|
|
27831
|
+
if (dirty & /*$$scope*/ 4194304) {
|
|
27536
27832
|
eyeicon_changes.$$scope = { dirty, ctx };
|
|
27537
27833
|
}
|
|
27538
27834
|
|
|
@@ -27556,7 +27852,7 @@ function create_input_button_slot(ctx) {
|
|
|
27556
27852
|
};
|
|
27557
27853
|
}
|
|
27558
27854
|
|
|
27559
|
-
// (
|
|
27855
|
+
// (101:0) {#if callbackMetadata?.platform?.confirmPassword}
|
|
27560
27856
|
function create_if_block$a(ctx) {
|
|
27561
27857
|
let confirminput;
|
|
27562
27858
|
let current;
|
|
@@ -27564,9 +27860,11 @@ function create_if_block$a(ctx) {
|
|
|
27564
27860
|
confirminput = new Confirm_input({
|
|
27565
27861
|
props: {
|
|
27566
27862
|
forceValidityFailure: /*doPasswordsMatch*/ ctx[9] === false,
|
|
27567
|
-
|
|
27863
|
+
passwordsDoNotMatch: /*doPasswordsMatch*/ ctx[9] === false,
|
|
27568
27864
|
key: /*key*/ ctx[0],
|
|
27569
|
-
|
|
27865
|
+
isRequired: /*value*/ ctx[7].length > 0,
|
|
27866
|
+
onChange: /*confirmInput*/ ctx[15],
|
|
27867
|
+
resetValue: /*resetValue*/ ctx[11],
|
|
27570
27868
|
showMessage: /*doPasswordsMatch*/ ctx[9] === false,
|
|
27571
27869
|
style: /*style*/ ctx[4]
|
|
27572
27870
|
}
|
|
@@ -27583,8 +27881,10 @@ function create_if_block$a(ctx) {
|
|
|
27583
27881
|
p(ctx, dirty) {
|
|
27584
27882
|
const confirminput_changes = {};
|
|
27585
27883
|
if (dirty & /*doPasswordsMatch*/ 512) confirminput_changes.forceValidityFailure = /*doPasswordsMatch*/ ctx[9] === false;
|
|
27586
|
-
if (dirty & /*doPasswordsMatch*/ 512) confirminput_changes.
|
|
27884
|
+
if (dirty & /*doPasswordsMatch*/ 512) confirminput_changes.passwordsDoNotMatch = /*doPasswordsMatch*/ ctx[9] === false;
|
|
27587
27885
|
if (dirty & /*key*/ 1) confirminput_changes.key = /*key*/ ctx[0];
|
|
27886
|
+
if (dirty & /*value*/ 128) confirminput_changes.isRequired = /*value*/ ctx[7].length > 0;
|
|
27887
|
+
if (dirty & /*resetValue*/ 2048) confirminput_changes.resetValue = /*resetValue*/ ctx[11];
|
|
27588
27888
|
if (dirty & /*doPasswordsMatch*/ 512) confirminput_changes.showMessage = /*doPasswordsMatch*/ ctx[9] === false;
|
|
27589
27889
|
if (dirty & /*style*/ 16) confirminput_changes.style = /*style*/ ctx[4];
|
|
27590
27890
|
confirminput.$set(confirminput_changes);
|
|
@@ -27610,20 +27910,20 @@ function create_fragment$p(ctx) {
|
|
|
27610
27910
|
let if_block_anchor;
|
|
27611
27911
|
let current;
|
|
27612
27912
|
|
|
27613
|
-
input = new /*Input*/ ctx[
|
|
27913
|
+
input = new /*Input*/ ctx[14]({
|
|
27614
27914
|
props: {
|
|
27615
27915
|
isFirstInvalidInput: /*callbackMetadata*/ ctx[1]?.derived.isFirstInvalidInput || false,
|
|
27616
27916
|
hasRightIcon: true,
|
|
27617
27917
|
key: /*key*/ ctx[0],
|
|
27618
|
-
label: interpolate(textToKey(/*callbackType*/ ctx[8]), null, /*textInputLabel*/ ctx[
|
|
27918
|
+
label: interpolate(textToKey(/*callbackType*/ ctx[8]), null, /*textInputLabel*/ ctx[12]),
|
|
27619
27919
|
message: /*validationFailure*/ ctx[6] || (/*isRequired*/ ctx[3]
|
|
27620
27920
|
? interpolate('inputRequiredError')
|
|
27621
27921
|
: undefined),
|
|
27622
|
-
onChange: /*setValue*/ ctx[
|
|
27922
|
+
onChange: /*setValue*/ ctx[16],
|
|
27623
27923
|
isInvalid: /*isInvalid*/ ctx[2],
|
|
27624
27924
|
isRequired: /*isRequired*/ ctx[3],
|
|
27625
27925
|
showMessage: /*showMessage*/ ctx[5],
|
|
27626
|
-
type: /*type*/ ctx[
|
|
27926
|
+
type: /*type*/ ctx[13],
|
|
27627
27927
|
value: typeof /*value*/ ctx[7] === 'string'
|
|
27628
27928
|
? /*value*/ ctx[7]
|
|
27629
27929
|
: '',
|
|
@@ -27655,7 +27955,7 @@ function create_fragment$p(ctx) {
|
|
|
27655
27955
|
const input_changes = {};
|
|
27656
27956
|
if (dirty & /*callbackMetadata*/ 2) input_changes.isFirstInvalidInput = /*callbackMetadata*/ ctx[1]?.derived.isFirstInvalidInput || false;
|
|
27657
27957
|
if (dirty & /*key*/ 1) input_changes.key = /*key*/ ctx[0];
|
|
27658
|
-
if (dirty & /*callbackType, textInputLabel*/
|
|
27958
|
+
if (dirty & /*callbackType, textInputLabel*/ 4352) input_changes.label = interpolate(textToKey(/*callbackType*/ ctx[8]), null, /*textInputLabel*/ ctx[12]);
|
|
27659
27959
|
|
|
27660
27960
|
if (dirty & /*validationFailure, isRequired*/ 72) input_changes.message = /*validationFailure*/ ctx[6] || (/*isRequired*/ ctx[3]
|
|
27661
27961
|
? interpolate('inputRequiredError')
|
|
@@ -27664,13 +27964,13 @@ function create_fragment$p(ctx) {
|
|
|
27664
27964
|
if (dirty & /*isInvalid*/ 4) input_changes.isInvalid = /*isInvalid*/ ctx[2];
|
|
27665
27965
|
if (dirty & /*isRequired*/ 8) input_changes.isRequired = /*isRequired*/ ctx[3];
|
|
27666
27966
|
if (dirty & /*showMessage*/ 32) input_changes.showMessage = /*showMessage*/ ctx[5];
|
|
27667
|
-
if (dirty & /*type*/
|
|
27967
|
+
if (dirty & /*type*/ 8192) input_changes.type = /*type*/ ctx[13];
|
|
27668
27968
|
|
|
27669
27969
|
if (dirty & /*value*/ 128) input_changes.value = typeof /*value*/ ctx[7] === 'string'
|
|
27670
27970
|
? /*value*/ ctx[7]
|
|
27671
27971
|
: '';
|
|
27672
27972
|
|
|
27673
|
-
if (dirty & /*$$scope, isVisible*/
|
|
27973
|
+
if (dirty & /*$$scope, isVisible*/ 4195328) {
|
|
27674
27974
|
input_changes.$$scope = { dirty, ctx };
|
|
27675
27975
|
}
|
|
27676
27976
|
|
|
@@ -27734,6 +28034,8 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27734
28034
|
let callbackType;
|
|
27735
28035
|
let doPasswordsMatch;
|
|
27736
28036
|
let isVisible = false;
|
|
28037
|
+
let resetValue = false;
|
|
28038
|
+
let savedValue = '';
|
|
27737
28039
|
let textInputLabel;
|
|
27738
28040
|
let type = 'password';
|
|
27739
28041
|
let value;
|
|
@@ -27742,8 +28044,8 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27742
28044
|
* @function confirmInput - ensures the second password input matches the first
|
|
27743
28045
|
* @param event
|
|
27744
28046
|
*/
|
|
27745
|
-
function confirmInput(
|
|
27746
|
-
$$invalidate(
|
|
28047
|
+
function confirmInput(val) {
|
|
28048
|
+
$$invalidate(19, confirmValue = val);
|
|
27747
28049
|
}
|
|
27748
28050
|
|
|
27749
28051
|
/**
|
|
@@ -27761,6 +28063,8 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27761
28063
|
* for writing values to the callbacks received from AM
|
|
27762
28064
|
*********************************************************************** */
|
|
27763
28065
|
callback.setInputValue(value);
|
|
28066
|
+
|
|
28067
|
+
$$invalidate(20, savedValue = String(value));
|
|
27764
28068
|
}
|
|
27765
28069
|
|
|
27766
28070
|
/**
|
|
@@ -27768,11 +28072,11 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27768
28072
|
*/
|
|
27769
28073
|
function toggleVisibility() {
|
|
27770
28074
|
$$invalidate(10, isVisible = !isVisible);
|
|
27771
|
-
$$invalidate(
|
|
28075
|
+
$$invalidate(13, type = isVisible ? 'text' : 'password');
|
|
27772
28076
|
}
|
|
27773
28077
|
|
|
27774
28078
|
$$self.$$set = $$props => {
|
|
27775
|
-
if ('callback' in $$props) $$invalidate(
|
|
28079
|
+
if ('callback' in $$props) $$invalidate(18, callback = $$props.callback);
|
|
27776
28080
|
if ('callbackMetadata' in $$props) $$invalidate(1, callbackMetadata = $$props.callbackMetadata);
|
|
27777
28081
|
if ('key' in $$props) $$invalidate(0, key = $$props.key);
|
|
27778
28082
|
if ('isInvalid' in $$props) $$invalidate(2, isInvalid = $$props.isInvalid);
|
|
@@ -27780,18 +28084,28 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27780
28084
|
if ('style' in $$props) $$invalidate(4, style = $$props.style);
|
|
27781
28085
|
if ('showMessage' in $$props) $$invalidate(5, showMessage = $$props.showMessage);
|
|
27782
28086
|
if ('validationFailure' in $$props) $$invalidate(6, validationFailure = $$props.validationFailure);
|
|
27783
|
-
if ('$$scope' in $$props) $$invalidate(
|
|
28087
|
+
if ('$$scope' in $$props) $$invalidate(22, $$scope = $$props.$$scope);
|
|
27784
28088
|
};
|
|
27785
28089
|
|
|
27786
28090
|
$$self.$$.update = () => {
|
|
27787
|
-
if ($$self.$$.dirty & /*callback, callbackMetadata,
|
|
28091
|
+
if ($$self.$$.dirty & /*callback, callbackMetadata, savedValue, value, confirmValue*/ 1835138) {
|
|
27788
28092
|
{
|
|
27789
28093
|
$$invalidate(8, callbackType = callback.getType());
|
|
27790
28094
|
$$invalidate(0, key = callback?.payload?.input?.[0].name || `password-${callbackMetadata?.idx}`);
|
|
27791
|
-
$$invalidate(
|
|
28095
|
+
$$invalidate(12, textInputLabel = callback.getPrompt());
|
|
27792
28096
|
$$invalidate(7, value = callback?.getInputValue());
|
|
27793
28097
|
|
|
27794
|
-
|
|
28098
|
+
/**
|
|
28099
|
+
* `savedValue` represents what the user set after blur (local component state)
|
|
28100
|
+
* `value` represents what's in the callback (empties from AM response)
|
|
28101
|
+
*
|
|
28102
|
+
* This unique combination is what produces the most reliable reset flag
|
|
28103
|
+
*/
|
|
28104
|
+
$$invalidate(11, resetValue = !!savedValue && value === '');
|
|
28105
|
+
|
|
28106
|
+
/**
|
|
28107
|
+
* Only assign a boolean if the confirm input has an actual value.
|
|
28108
|
+
*/
|
|
27795
28109
|
$$invalidate(9, doPasswordsMatch = confirmValue !== undefined
|
|
27796
28110
|
? confirmValue === value
|
|
27797
28111
|
: undefined);
|
|
@@ -27811,6 +28125,7 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27811
28125
|
callbackType,
|
|
27812
28126
|
doPasswordsMatch,
|
|
27813
28127
|
isVisible,
|
|
28128
|
+
resetValue,
|
|
27814
28129
|
textInputLabel,
|
|
27815
28130
|
type,
|
|
27816
28131
|
Input,
|
|
@@ -27819,6 +28134,7 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27819
28134
|
toggleVisibility,
|
|
27820
28135
|
callback,
|
|
27821
28136
|
confirmValue,
|
|
28137
|
+
savedValue,
|
|
27822
28138
|
slots,
|
|
27823
28139
|
$$scope
|
|
27824
28140
|
];
|
|
@@ -27829,7 +28145,7 @@ class Base extends SvelteComponent {
|
|
|
27829
28145
|
super();
|
|
27830
28146
|
|
|
27831
28147
|
init(this, options, instance$p, create_fragment$p, safe_not_equal, {
|
|
27832
|
-
callback:
|
|
28148
|
+
callback: 18,
|
|
27833
28149
|
callbackMetadata: 1,
|
|
27834
28150
|
key: 0,
|
|
27835
28151
|
isInvalid: 2,
|
|
@@ -28521,7 +28837,7 @@ function get_each_context$5(ctx, list, i) {
|
|
|
28521
28837
|
}
|
|
28522
28838
|
|
|
28523
28839
|
// (66:56)
|
|
28524
|
-
function create_if_block_3$
|
|
28840
|
+
function create_if_block_3$5(ctx) {
|
|
28525
28841
|
let button;
|
|
28526
28842
|
let current;
|
|
28527
28843
|
|
|
@@ -28865,7 +29181,7 @@ function create_default_slot_1$6(ctx) {
|
|
|
28865
29181
|
let if_block;
|
|
28866
29182
|
let if_block_anchor;
|
|
28867
29183
|
let current;
|
|
28868
|
-
const if_block_creators = [create_if_block_1$7, create_if_block_2$6, create_if_block_3$
|
|
29184
|
+
const if_block_creators = [create_if_block_1$7, create_if_block_2$6, create_if_block_3$5];
|
|
28869
29185
|
const if_blocks = [];
|
|
28870
29186
|
|
|
28871
29187
|
function select_block_type(ctx, dirty) {
|
|
@@ -29797,13 +30113,6 @@ function instance$f($$self, $$props, $$invalidate) {
|
|
|
29797
30113
|
* @param {Object} event
|
|
29798
30114
|
*/
|
|
29799
30115
|
function setValue(event) {
|
|
29800
|
-
/** ***********************************************************************
|
|
29801
|
-
* SDK INTEGRATION POINT
|
|
29802
|
-
* Summary: SDK callback methods for setting values
|
|
29803
|
-
* ------------------------------------------------------------------------
|
|
29804
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
29805
|
-
* for writing values to the callbacks received from AM
|
|
29806
|
-
*********************************************************************** */
|
|
29807
30116
|
callback.setInputValue(event.target.value);
|
|
29808
30117
|
}
|
|
29809
30118
|
|
|
@@ -29992,7 +30301,7 @@ function create_else_block$3(ctx) {
|
|
|
29992
30301
|
};
|
|
29993
30302
|
}
|
|
29994
30303
|
|
|
29995
|
-
// (
|
|
30304
|
+
// (27:0) {#if $linksStore?.termsAndConditions}
|
|
29996
30305
|
function create_if_block$7(ctx) {
|
|
29997
30306
|
let link;
|
|
29998
30307
|
let t;
|
|
@@ -30070,7 +30379,7 @@ function create_if_block$7(ctx) {
|
|
|
30070
30379
|
};
|
|
30071
30380
|
}
|
|
30072
30381
|
|
|
30073
|
-
// (
|
|
30382
|
+
// (28:2) <Link classes="tw_block tw_mb-4" href={$linksStore?.termsAndConditions} target="_blank">
|
|
30074
30383
|
function create_default_slot_1$5(ctx) {
|
|
30075
30384
|
let t_value = interpolate('termsAndConditionsLinkText') + "";
|
|
30076
30385
|
let t;
|
|
@@ -30089,7 +30398,7 @@ function create_default_slot_1$5(ctx) {
|
|
|
30089
30398
|
};
|
|
30090
30399
|
}
|
|
30091
30400
|
|
|
30092
|
-
// (
|
|
30401
|
+
// (31:2) <Checkbox isFirstInvalidInput={callbackMetadata?.derived.isFirstInvalidInput || false} key={inputName} onChange={setValue} value={false} >
|
|
30093
30402
|
function create_default_slot$9(ctx) {
|
|
30094
30403
|
let t;
|
|
30095
30404
|
let current;
|
|
@@ -30197,13 +30506,6 @@ function instance$d($$self, $$props, $$invalidate) {
|
|
|
30197
30506
|
let { callback } = $$props;
|
|
30198
30507
|
let { callbackMetadata } = $$props;
|
|
30199
30508
|
|
|
30200
|
-
/** *************************************************************************
|
|
30201
|
-
* SDK INTEGRATION POINT
|
|
30202
|
-
* Summary: SDK callback methods for getting values
|
|
30203
|
-
* --------------------------------------------------------------------------
|
|
30204
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
30205
|
-
* for accessing values from the callbacks received from AM
|
|
30206
|
-
************************************************************************* */
|
|
30207
30509
|
const Checkbox = style.checksAndRadios === 'standard'
|
|
30208
30510
|
? Standard$1
|
|
30209
30511
|
: Animated$1;
|
|
@@ -30215,13 +30517,6 @@ function instance$d($$self, $$props, $$invalidate) {
|
|
|
30215
30517
|
* @param {Object} event
|
|
30216
30518
|
*/
|
|
30217
30519
|
function setValue(event) {
|
|
30218
|
-
/** ***********************************************************************
|
|
30219
|
-
* SDK INTEGRATION POINT
|
|
30220
|
-
* Summary: SDK callback methods for setting values
|
|
30221
|
-
* ------------------------------------------------------------------------
|
|
30222
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
30223
|
-
* for writing values to the callbacks received from AM
|
|
30224
|
-
*********************************************************************** */
|
|
30225
30520
|
callback.setAccepted(event.target.checked);
|
|
30226
30521
|
}
|
|
30227
30522
|
|
|
@@ -30780,13 +31075,6 @@ function instance$9($$self, $$props, $$invalidate) {
|
|
|
30780
31075
|
* @param {Object} event
|
|
30781
31076
|
*/
|
|
30782
31077
|
function setValue(event) {
|
|
30783
|
-
/** ***********************************************************************
|
|
30784
|
-
* SDK INTEGRATION POINT
|
|
30785
|
-
* Summary: SDK callback methods for setting values
|
|
30786
|
-
* ------------------------------------------------------------------------
|
|
30787
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
30788
|
-
* for writing values to the callbacks received from AM
|
|
30789
|
-
*********************************************************************** */
|
|
30790
31078
|
callback.setInputValue(event.target.value);
|
|
30791
31079
|
}
|
|
30792
31080
|
|
|
@@ -31573,7 +31861,7 @@ function create_if_block_5(ctx) {
|
|
|
31573
31861
|
}
|
|
31574
31862
|
|
|
31575
31863
|
// (126:52)
|
|
31576
|
-
function create_if_block_4(ctx) {
|
|
31864
|
+
function create_if_block_4$1(ctx) {
|
|
31577
31865
|
let kbacreate;
|
|
31578
31866
|
let current;
|
|
31579
31867
|
const kbacreate_spread_levels = [/*newProps*/ ctx[19]];
|
|
@@ -31616,7 +31904,7 @@ function create_if_block_4(ctx) {
|
|
|
31616
31904
|
}
|
|
31617
31905
|
|
|
31618
31906
|
// (120:54)
|
|
31619
|
-
function create_if_block_3$
|
|
31907
|
+
function create_if_block_3$4(ctx) {
|
|
31620
31908
|
let hiddenvalue;
|
|
31621
31909
|
let current;
|
|
31622
31910
|
const hiddenvalue_spread_levels = [/*newProps*/ ctx[19]];
|
|
@@ -31797,8 +32085,8 @@ function create_fragment$8(ctx) {
|
|
|
31797
32085
|
create_if_block$6,
|
|
31798
32086
|
create_if_block_1$5,
|
|
31799
32087
|
create_if_block_2$5,
|
|
31800
|
-
create_if_block_3$
|
|
31801
|
-
create_if_block_4,
|
|
32088
|
+
create_if_block_3$4,
|
|
32089
|
+
create_if_block_4$1,
|
|
31802
32090
|
create_if_block_5,
|
|
31803
32091
|
create_if_block_6,
|
|
31804
32092
|
create_if_block_7,
|
|
@@ -32031,12 +32319,12 @@ class Callback_mapper extends SvelteComponent {
|
|
|
32031
32319
|
|
|
32032
32320
|
function get_each_context$3(ctx, list, i) {
|
|
32033
32321
|
const child_ctx = ctx.slice();
|
|
32034
|
-
child_ctx[
|
|
32035
|
-
child_ctx[
|
|
32322
|
+
child_ctx[16] = list[i];
|
|
32323
|
+
child_ctx[18] = i;
|
|
32036
32324
|
return child_ctx;
|
|
32037
32325
|
}
|
|
32038
32326
|
|
|
32039
|
-
// (70:2) {#if form?.icon}
|
|
32327
|
+
// (70:2) {#if form?.icon && componentStyle !== 'inline'}
|
|
32040
32328
|
function create_if_block_2$4(ctx) {
|
|
32041
32329
|
let div;
|
|
32042
32330
|
let shieldicon;
|
|
@@ -32084,7 +32372,7 @@ function create_if_block_1$4(ctx) {
|
|
|
32084
32372
|
alert = new Alert({
|
|
32085
32373
|
props: {
|
|
32086
32374
|
id: formFailureMessageId,
|
|
32087
|
-
needsFocus: /*alertNeedsFocus*/ ctx[
|
|
32375
|
+
needsFocus: /*alertNeedsFocus*/ ctx[6],
|
|
32088
32376
|
type: "error",
|
|
32089
32377
|
$$slots: { default: [create_default_slot_2$3] },
|
|
32090
32378
|
$$scope: { ctx }
|
|
@@ -32101,9 +32389,9 @@ function create_if_block_1$4(ctx) {
|
|
|
32101
32389
|
},
|
|
32102
32390
|
p(ctx, dirty) {
|
|
32103
32391
|
const alert_changes = {};
|
|
32104
|
-
if (dirty & /*alertNeedsFocus*/
|
|
32392
|
+
if (dirty & /*alertNeedsFocus*/ 64) alert_changes.needsFocus = /*alertNeedsFocus*/ ctx[6];
|
|
32105
32393
|
|
|
32106
|
-
if (dirty & /*$$scope, formMessageKey, form*/
|
|
32394
|
+
if (dirty & /*$$scope, formMessageKey, form*/ 524420) {
|
|
32107
32395
|
alert_changes.$$scope = { dirty, ctx };
|
|
32108
32396
|
}
|
|
32109
32397
|
|
|
@@ -32126,7 +32414,7 @@ function create_if_block_1$4(ctx) {
|
|
|
32126
32414
|
|
|
32127
32415
|
// (87:4) <Alert id={formFailureMessageId} needsFocus={alertNeedsFocus} type="error">
|
|
32128
32416
|
function create_default_slot_2$3(ctx) {
|
|
32129
|
-
let t_value = interpolate(/*formMessageKey*/ ctx[
|
|
32417
|
+
let t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "";
|
|
32130
32418
|
let t;
|
|
32131
32419
|
|
|
32132
32420
|
return {
|
|
@@ -32137,7 +32425,7 @@ function create_default_slot_2$3(ctx) {
|
|
|
32137
32425
|
insert(target, t, anchor);
|
|
32138
32426
|
},
|
|
32139
32427
|
p(ctx, dirty) {
|
|
32140
|
-
if (dirty & /*formMessageKey, form*/
|
|
32428
|
+
if (dirty & /*formMessageKey, form*/ 132 && t_value !== (t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "")) set_data(t, t_value);
|
|
32141
32429
|
},
|
|
32142
32430
|
d(detaching) {
|
|
32143
32431
|
if (detaching) detach(t);
|
|
@@ -32153,11 +32441,11 @@ function create_each_block$3(ctx) {
|
|
|
32153
32441
|
callbackmapper = new Callback_mapper({
|
|
32154
32442
|
props: {
|
|
32155
32443
|
props: {
|
|
32156
|
-
callback: /*callback*/ ctx[
|
|
32157
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
32158
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
32159
|
-
stepMetadata: /*metadata*/ ctx[
|
|
32160
|
-
style: /*$styleStore*/ ctx[
|
|
32444
|
+
callback: /*callback*/ ctx[16],
|
|
32445
|
+
callbackMetadata: /*metadata*/ ctx[4]?.callbacks[/*idx*/ ctx[18]],
|
|
32446
|
+
selfSubmitFunction: /*determineSubmission*/ ctx[12],
|
|
32447
|
+
stepMetadata: /*metadata*/ ctx[4]?.step && { .../*metadata*/ ctx[4].step },
|
|
32448
|
+
style: /*$styleStore*/ ctx[11]
|
|
32161
32449
|
}
|
|
32162
32450
|
}
|
|
32163
32451
|
});
|
|
@@ -32173,12 +32461,12 @@ function create_each_block$3(ctx) {
|
|
|
32173
32461
|
p(ctx, dirty) {
|
|
32174
32462
|
const callbackmapper_changes = {};
|
|
32175
32463
|
|
|
32176
|
-
if (dirty & /*step, metadata, $styleStore*/
|
|
32177
|
-
callback: /*callback*/ ctx[
|
|
32178
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
32179
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
32180
|
-
stepMetadata: /*metadata*/ ctx[
|
|
32181
|
-
style: /*$styleStore*/ ctx[
|
|
32464
|
+
if (dirty & /*step, metadata, $styleStore*/ 2096) callbackmapper_changes.props = {
|
|
32465
|
+
callback: /*callback*/ ctx[16],
|
|
32466
|
+
callbackMetadata: /*metadata*/ ctx[4]?.callbacks[/*idx*/ ctx[18]],
|
|
32467
|
+
selfSubmitFunction: /*determineSubmission*/ ctx[12],
|
|
32468
|
+
stepMetadata: /*metadata*/ ctx[4]?.step && { .../*metadata*/ ctx[4].step },
|
|
32469
|
+
style: /*$styleStore*/ ctx[11]
|
|
32182
32470
|
};
|
|
32183
32471
|
|
|
32184
32472
|
callbackmapper.$set(callbackmapper_changes);
|
|
@@ -32205,7 +32493,7 @@ function create_if_block$5(ctx) {
|
|
|
32205
32493
|
|
|
32206
32494
|
button = new Button({
|
|
32207
32495
|
props: {
|
|
32208
|
-
busy: /*journey*/ ctx[
|
|
32496
|
+
busy: /*journey*/ ctx[3]?.loading,
|
|
32209
32497
|
style: "primary",
|
|
32210
32498
|
type: "submit",
|
|
32211
32499
|
width: "full",
|
|
@@ -32224,9 +32512,9 @@ function create_if_block$5(ctx) {
|
|
|
32224
32512
|
},
|
|
32225
32513
|
p(ctx, dirty) {
|
|
32226
32514
|
const button_changes = {};
|
|
32227
|
-
if (dirty & /*journey*/
|
|
32515
|
+
if (dirty & /*journey*/ 8) button_changes.busy = /*journey*/ ctx[3]?.loading;
|
|
32228
32516
|
|
|
32229
|
-
if (dirty & /*$$scope*/
|
|
32517
|
+
if (dirty & /*$$scope*/ 524288) {
|
|
32230
32518
|
button_changes.$$scope = { dirty, ctx };
|
|
32231
32519
|
}
|
|
32232
32520
|
|
|
@@ -32292,24 +32580,24 @@ function create_default_slot$5(ctx) {
|
|
|
32292
32580
|
let t5;
|
|
32293
32581
|
let backto;
|
|
32294
32582
|
let current;
|
|
32295
|
-
let if_block0 = /*form*/ ctx[
|
|
32583
|
+
let if_block0 = /*form*/ ctx[2]?.icon && /*componentStyle*/ ctx[1] !== 'inline' && create_if_block_2$4();
|
|
32296
32584
|
|
|
32297
32585
|
sanitize0 = new Server_strings({
|
|
32298
32586
|
props: {
|
|
32299
32587
|
html: true,
|
|
32300
|
-
string: /*step*/ ctx[
|
|
32588
|
+
string: /*step*/ ctx[5]?.getHeader() || ''
|
|
32301
32589
|
}
|
|
32302
32590
|
});
|
|
32303
32591
|
|
|
32304
32592
|
sanitize1 = new Server_strings({
|
|
32305
32593
|
props: {
|
|
32306
32594
|
html: true,
|
|
32307
|
-
string: /*step*/ ctx[
|
|
32595
|
+
string: /*step*/ ctx[5]?.getDescription() || ''
|
|
32308
32596
|
}
|
|
32309
32597
|
});
|
|
32310
32598
|
|
|
32311
|
-
let if_block1 = /*form*/ ctx[
|
|
32312
|
-
let each_value = /*step*/ ctx[
|
|
32599
|
+
let if_block1 = /*form*/ ctx[2]?.message && create_if_block_1$4(ctx);
|
|
32600
|
+
let each_value = /*step*/ ctx[5]?.callbacks;
|
|
32313
32601
|
let each_blocks = [];
|
|
32314
32602
|
|
|
32315
32603
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -32320,8 +32608,8 @@ function create_default_slot$5(ctx) {
|
|
|
32320
32608
|
each_blocks[i] = null;
|
|
32321
32609
|
});
|
|
32322
32610
|
|
|
32323
|
-
let if_block2 = (/*metadata*/ ctx[
|
|
32324
|
-
backto = new Back_to({ props: { journey: /*journey*/ ctx[
|
|
32611
|
+
let if_block2 = (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) && create_if_block$5(ctx);
|
|
32612
|
+
backto = new Back_to({ props: { journey: /*journey*/ ctx[3] } });
|
|
32325
32613
|
|
|
32326
32614
|
return {
|
|
32327
32615
|
c() {
|
|
@@ -32358,7 +32646,7 @@ function create_default_slot$5(ctx) {
|
|
|
32358
32646
|
append(header, t1);
|
|
32359
32647
|
append(header, p);
|
|
32360
32648
|
mount_component(sanitize1, p, null);
|
|
32361
|
-
/*header_binding*/ ctx[
|
|
32649
|
+
/*header_binding*/ ctx[14](header);
|
|
32362
32650
|
insert(target, t2, anchor);
|
|
32363
32651
|
if (if_block1) if_block1.m(target, anchor);
|
|
32364
32652
|
insert(target, t3, anchor);
|
|
@@ -32374,9 +32662,9 @@ function create_default_slot$5(ctx) {
|
|
|
32374
32662
|
current = true;
|
|
32375
32663
|
},
|
|
32376
32664
|
p(ctx, dirty) {
|
|
32377
|
-
if (/*form*/ ctx[
|
|
32665
|
+
if (/*form*/ ctx[2]?.icon && /*componentStyle*/ ctx[1] !== 'inline') {
|
|
32378
32666
|
if (if_block0) {
|
|
32379
|
-
if (dirty & /*form*/
|
|
32667
|
+
if (dirty & /*form, componentStyle*/ 6) {
|
|
32380
32668
|
transition_in(if_block0, 1);
|
|
32381
32669
|
}
|
|
32382
32670
|
} else {
|
|
@@ -32396,17 +32684,17 @@ function create_default_slot$5(ctx) {
|
|
|
32396
32684
|
}
|
|
32397
32685
|
|
|
32398
32686
|
const sanitize0_changes = {};
|
|
32399
|
-
if (dirty & /*step*/
|
|
32687
|
+
if (dirty & /*step*/ 32) sanitize0_changes.string = /*step*/ ctx[5]?.getHeader() || '';
|
|
32400
32688
|
sanitize0.$set(sanitize0_changes);
|
|
32401
32689
|
const sanitize1_changes = {};
|
|
32402
|
-
if (dirty & /*step*/
|
|
32690
|
+
if (dirty & /*step*/ 32) sanitize1_changes.string = /*step*/ ctx[5]?.getDescription() || '';
|
|
32403
32691
|
sanitize1.$set(sanitize1_changes);
|
|
32404
32692
|
|
|
32405
|
-
if (/*form*/ ctx[
|
|
32693
|
+
if (/*form*/ ctx[2]?.message) {
|
|
32406
32694
|
if (if_block1) {
|
|
32407
32695
|
if_block1.p(ctx, dirty);
|
|
32408
32696
|
|
|
32409
|
-
if (dirty & /*form*/
|
|
32697
|
+
if (dirty & /*form*/ 4) {
|
|
32410
32698
|
transition_in(if_block1, 1);
|
|
32411
32699
|
}
|
|
32412
32700
|
} else {
|
|
@@ -32425,8 +32713,8 @@ function create_default_slot$5(ctx) {
|
|
|
32425
32713
|
check_outros();
|
|
32426
32714
|
}
|
|
32427
32715
|
|
|
32428
|
-
if (dirty & /*step, metadata, determineSubmission, $styleStore*/
|
|
32429
|
-
each_value = /*step*/ ctx[
|
|
32716
|
+
if (dirty & /*step, metadata, determineSubmission, $styleStore*/ 6192) {
|
|
32717
|
+
each_value = /*step*/ ctx[5]?.callbacks;
|
|
32430
32718
|
let i;
|
|
32431
32719
|
|
|
32432
32720
|
for (i = 0; i < each_value.length; i += 1) {
|
|
@@ -32452,11 +32740,11 @@ function create_default_slot$5(ctx) {
|
|
|
32452
32740
|
check_outros();
|
|
32453
32741
|
}
|
|
32454
32742
|
|
|
32455
|
-
if (/*metadata*/ ctx[
|
|
32743
|
+
if (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) {
|
|
32456
32744
|
if (if_block2) {
|
|
32457
32745
|
if_block2.p(ctx, dirty);
|
|
32458
32746
|
|
|
32459
|
-
if (dirty & /*metadata*/
|
|
32747
|
+
if (dirty & /*metadata*/ 16) {
|
|
32460
32748
|
transition_in(if_block2, 1);
|
|
32461
32749
|
}
|
|
32462
32750
|
} else {
|
|
@@ -32476,7 +32764,7 @@ function create_default_slot$5(ctx) {
|
|
|
32476
32764
|
}
|
|
32477
32765
|
|
|
32478
32766
|
const backto_changes = {};
|
|
32479
|
-
if (dirty & /*journey*/
|
|
32767
|
+
if (dirty & /*journey*/ 8) backto_changes.journey = /*journey*/ ctx[3];
|
|
32480
32768
|
backto.$set(backto_changes);
|
|
32481
32769
|
},
|
|
32482
32770
|
i(local) {
|
|
@@ -32515,7 +32803,7 @@ function create_default_slot$5(ctx) {
|
|
|
32515
32803
|
if (detaching) detach(header);
|
|
32516
32804
|
destroy_component(sanitize0);
|
|
32517
32805
|
destroy_component(sanitize1);
|
|
32518
|
-
/*header_binding*/ ctx[
|
|
32806
|
+
/*header_binding*/ ctx[14](null);
|
|
32519
32807
|
if (detaching) detach(t2);
|
|
32520
32808
|
if (if_block1) if_block1.d(detaching);
|
|
32521
32809
|
if (detaching) detach(t3);
|
|
@@ -32534,14 +32822,14 @@ function create_fragment$7(ctx) {
|
|
|
32534
32822
|
let current;
|
|
32535
32823
|
|
|
32536
32824
|
function form_1_formEl_binding(value) {
|
|
32537
|
-
/*form_1_formEl_binding*/ ctx[
|
|
32825
|
+
/*form_1_formEl_binding*/ ctx[15](value);
|
|
32538
32826
|
}
|
|
32539
32827
|
|
|
32540
32828
|
let form_1_props = {
|
|
32541
|
-
ariaDescribedBy: /*formAriaDescriptor*/ ctx[
|
|
32829
|
+
ariaDescribedBy: /*formAriaDescriptor*/ ctx[8],
|
|
32542
32830
|
id: formElementId,
|
|
32543
|
-
needsFocus: /*formNeedsFocus*/ ctx[
|
|
32544
|
-
onSubmitWhenValid: /*submitFormWrapper*/ ctx[
|
|
32831
|
+
needsFocus: /*formNeedsFocus*/ ctx[9],
|
|
32832
|
+
onSubmitWhenValid: /*submitFormWrapper*/ ctx[13],
|
|
32545
32833
|
$$slots: { default: [create_default_slot$5] },
|
|
32546
32834
|
$$scope: { ctx }
|
|
32547
32835
|
};
|
|
@@ -32563,10 +32851,10 @@ function create_fragment$7(ctx) {
|
|
|
32563
32851
|
},
|
|
32564
32852
|
p(ctx, [dirty]) {
|
|
32565
32853
|
const form_1_changes = {};
|
|
32566
|
-
if (dirty & /*formAriaDescriptor*/
|
|
32567
|
-
if (dirty & /*formNeedsFocus*/
|
|
32854
|
+
if (dirty & /*formAriaDescriptor*/ 256) form_1_changes.ariaDescribedBy = /*formAriaDescriptor*/ ctx[8];
|
|
32855
|
+
if (dirty & /*formNeedsFocus*/ 512) form_1_changes.needsFocus = /*formNeedsFocus*/ ctx[9];
|
|
32568
32856
|
|
|
32569
|
-
if (dirty & /*$$scope, journey, metadata, step, $styleStore, alertNeedsFocus, formMessageKey, form, linkWrapper*/
|
|
32857
|
+
if (dirty & /*$$scope, journey, metadata, step, $styleStore, alertNeedsFocus, formMessageKey, form, linkWrapper, componentStyle*/ 527614) {
|
|
32570
32858
|
form_1_changes.$$scope = { dirty, ctx };
|
|
32571
32859
|
}
|
|
32572
32860
|
|
|
@@ -32599,7 +32887,8 @@ const formElementId = 'genericStepForm';
|
|
|
32599
32887
|
|
|
32600
32888
|
function instance$7($$self, $$props, $$invalidate) {
|
|
32601
32889
|
let $styleStore;
|
|
32602
|
-
component_subscribe($$self, styleStore, $$value => $$invalidate(
|
|
32890
|
+
component_subscribe($$self, styleStore, $$value => $$invalidate(11, $styleStore = $$value));
|
|
32891
|
+
let { componentStyle } = $$props;
|
|
32603
32892
|
let { form } = $$props;
|
|
32604
32893
|
let { formEl = null } = $$props;
|
|
32605
32894
|
let { journey } = $$props;
|
|
@@ -32621,20 +32910,20 @@ function instance$7($$self, $$props, $$invalidate) {
|
|
|
32621
32910
|
}
|
|
32622
32911
|
|
|
32623
32912
|
function submitFormWrapper() {
|
|
32624
|
-
$$invalidate(
|
|
32625
|
-
$$invalidate(
|
|
32913
|
+
$$invalidate(6, alertNeedsFocus = false);
|
|
32914
|
+
$$invalidate(9, formNeedsFocus = false);
|
|
32626
32915
|
form?.submit();
|
|
32627
32916
|
}
|
|
32628
32917
|
|
|
32629
32918
|
afterUpdate(() => {
|
|
32630
32919
|
if (form?.message) {
|
|
32631
|
-
$$invalidate(
|
|
32632
|
-
$$invalidate(
|
|
32633
|
-
$$invalidate(
|
|
32920
|
+
$$invalidate(8, formAriaDescriptor = formFailureMessageId);
|
|
32921
|
+
$$invalidate(6, alertNeedsFocus = true);
|
|
32922
|
+
$$invalidate(9, formNeedsFocus = false);
|
|
32634
32923
|
} else {
|
|
32635
|
-
$$invalidate(
|
|
32636
|
-
$$invalidate(
|
|
32637
|
-
$$invalidate(
|
|
32924
|
+
$$invalidate(8, formAriaDescriptor = formHeaderId);
|
|
32925
|
+
$$invalidate(6, alertNeedsFocus = false);
|
|
32926
|
+
$$invalidate(9, formNeedsFocus = true);
|
|
32638
32927
|
}
|
|
32639
32928
|
});
|
|
32640
32929
|
|
|
@@ -32643,7 +32932,7 @@ function instance$7($$self, $$props, $$invalidate) {
|
|
|
32643
32932
|
function header_binding($$value) {
|
|
32644
32933
|
binding_callbacks[$$value ? 'unshift' : 'push'](() => {
|
|
32645
32934
|
linkWrapper = $$value;
|
|
32646
|
-
$$invalidate(
|
|
32935
|
+
$$invalidate(10, linkWrapper);
|
|
32647
32936
|
});
|
|
32648
32937
|
}
|
|
32649
32938
|
|
|
@@ -32653,24 +32942,26 @@ function instance$7($$self, $$props, $$invalidate) {
|
|
|
32653
32942
|
}
|
|
32654
32943
|
|
|
32655
32944
|
$$self.$$set = $$props => {
|
|
32656
|
-
if ('
|
|
32945
|
+
if ('componentStyle' in $$props) $$invalidate(1, componentStyle = $$props.componentStyle);
|
|
32946
|
+
if ('form' in $$props) $$invalidate(2, form = $$props.form);
|
|
32657
32947
|
if ('formEl' in $$props) $$invalidate(0, formEl = $$props.formEl);
|
|
32658
|
-
if ('journey' in $$props) $$invalidate(
|
|
32659
|
-
if ('metadata' in $$props) $$invalidate(
|
|
32660
|
-
if ('step' in $$props) $$invalidate(
|
|
32948
|
+
if ('journey' in $$props) $$invalidate(3, journey = $$props.journey);
|
|
32949
|
+
if ('metadata' in $$props) $$invalidate(4, metadata = $$props.metadata);
|
|
32950
|
+
if ('step' in $$props) $$invalidate(5, step = $$props.step);
|
|
32661
32951
|
};
|
|
32662
32952
|
|
|
32663
32953
|
$$self.$$.update = () => {
|
|
32664
|
-
if ($$self.$$.dirty & /*step, form*/
|
|
32954
|
+
if ($$self.$$.dirty & /*step, form*/ 36) {
|
|
32665
32955
|
{
|
|
32666
32956
|
shouldRedirectFromStep(step) && FRAuth$1.redirect(step);
|
|
32667
|
-
$$invalidate(
|
|
32957
|
+
$$invalidate(7, formMessageKey = convertStringToKey(form?.message));
|
|
32668
32958
|
}
|
|
32669
32959
|
}
|
|
32670
32960
|
};
|
|
32671
32961
|
|
|
32672
32962
|
return [
|
|
32673
32963
|
formEl,
|
|
32964
|
+
componentStyle,
|
|
32674
32965
|
form,
|
|
32675
32966
|
journey,
|
|
32676
32967
|
metadata,
|
|
@@ -32693,11 +32984,12 @@ class Generic extends SvelteComponent {
|
|
|
32693
32984
|
super();
|
|
32694
32985
|
|
|
32695
32986
|
init(this, options, instance$7, create_fragment$7, safe_not_equal, {
|
|
32696
|
-
|
|
32987
|
+
componentStyle: 1,
|
|
32988
|
+
form: 2,
|
|
32697
32989
|
formEl: 0,
|
|
32698
|
-
journey:
|
|
32699
|
-
metadata:
|
|
32700
|
-
step:
|
|
32990
|
+
journey: 3,
|
|
32991
|
+
metadata: 4,
|
|
32992
|
+
step: 5
|
|
32701
32993
|
});
|
|
32702
32994
|
}
|
|
32703
32995
|
}
|
|
@@ -32810,13 +33102,101 @@ class Key_icon extends SvelteComponent {
|
|
|
32810
33102
|
|
|
32811
33103
|
function get_each_context$2(ctx, list, i) {
|
|
32812
33104
|
const child_ctx = ctx.slice();
|
|
32813
|
-
child_ctx[
|
|
32814
|
-
child_ctx[
|
|
33105
|
+
child_ctx[11] = list[i];
|
|
33106
|
+
child_ctx[13] = i;
|
|
32815
33107
|
return child_ctx;
|
|
32816
33108
|
}
|
|
32817
33109
|
|
|
32818
|
-
// (
|
|
33110
|
+
// (38:2) {#if componentStyle !== 'inline'}
|
|
32819
33111
|
function create_if_block_2$3(ctx) {
|
|
33112
|
+
let t0;
|
|
33113
|
+
let h1;
|
|
33114
|
+
let t1;
|
|
33115
|
+
let t2;
|
|
33116
|
+
let p;
|
|
33117
|
+
let t3;
|
|
33118
|
+
let current;
|
|
33119
|
+
let if_block = /*form*/ ctx[2]?.icon && create_if_block_3$3();
|
|
33120
|
+
|
|
33121
|
+
t1 = new Locale_strings({
|
|
33122
|
+
props: { key: "twoFactorAuthentication" }
|
|
33123
|
+
});
|
|
33124
|
+
|
|
33125
|
+
t3 = new Locale_strings({
|
|
33126
|
+
props: { key: "useTheAuthenticatorAppOnYourPhone" }
|
|
33127
|
+
});
|
|
33128
|
+
|
|
33129
|
+
return {
|
|
33130
|
+
c() {
|
|
33131
|
+
if (if_block) if_block.c();
|
|
33132
|
+
t0 = space();
|
|
33133
|
+
h1 = element("h1");
|
|
33134
|
+
create_component(t1.$$.fragment);
|
|
33135
|
+
t2 = space();
|
|
33136
|
+
p = element("p");
|
|
33137
|
+
create_component(t3.$$.fragment);
|
|
33138
|
+
attr(h1, "class", "tw_primary-header dark:tw_primary-header_dark");
|
|
33139
|
+
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");
|
|
33140
|
+
},
|
|
33141
|
+
m(target, anchor) {
|
|
33142
|
+
if (if_block) if_block.m(target, anchor);
|
|
33143
|
+
insert(target, t0, anchor);
|
|
33144
|
+
insert(target, h1, anchor);
|
|
33145
|
+
mount_component(t1, h1, null);
|
|
33146
|
+
insert(target, t2, anchor);
|
|
33147
|
+
insert(target, p, anchor);
|
|
33148
|
+
mount_component(t3, p, null);
|
|
33149
|
+
current = true;
|
|
33150
|
+
},
|
|
33151
|
+
p(ctx, dirty) {
|
|
33152
|
+
if (/*form*/ ctx[2]?.icon) {
|
|
33153
|
+
if (if_block) {
|
|
33154
|
+
if (dirty & /*form*/ 4) {
|
|
33155
|
+
transition_in(if_block, 1);
|
|
33156
|
+
}
|
|
33157
|
+
} else {
|
|
33158
|
+
if_block = create_if_block_3$3();
|
|
33159
|
+
if_block.c();
|
|
33160
|
+
transition_in(if_block, 1);
|
|
33161
|
+
if_block.m(t0.parentNode, t0);
|
|
33162
|
+
}
|
|
33163
|
+
} else if (if_block) {
|
|
33164
|
+
group_outros();
|
|
33165
|
+
|
|
33166
|
+
transition_out(if_block, 1, 1, () => {
|
|
33167
|
+
if_block = null;
|
|
33168
|
+
});
|
|
33169
|
+
|
|
33170
|
+
check_outros();
|
|
33171
|
+
}
|
|
33172
|
+
},
|
|
33173
|
+
i(local) {
|
|
33174
|
+
if (current) return;
|
|
33175
|
+
transition_in(if_block);
|
|
33176
|
+
transition_in(t1.$$.fragment, local);
|
|
33177
|
+
transition_in(t3.$$.fragment, local);
|
|
33178
|
+
current = true;
|
|
33179
|
+
},
|
|
33180
|
+
o(local) {
|
|
33181
|
+
transition_out(if_block);
|
|
33182
|
+
transition_out(t1.$$.fragment, local);
|
|
33183
|
+
transition_out(t3.$$.fragment, local);
|
|
33184
|
+
current = false;
|
|
33185
|
+
},
|
|
33186
|
+
d(detaching) {
|
|
33187
|
+
if (if_block) if_block.d(detaching);
|
|
33188
|
+
if (detaching) detach(t0);
|
|
33189
|
+
if (detaching) detach(h1);
|
|
33190
|
+
destroy_component(t1);
|
|
33191
|
+
if (detaching) detach(t2);
|
|
33192
|
+
if (detaching) detach(p);
|
|
33193
|
+
destroy_component(t3);
|
|
33194
|
+
}
|
|
33195
|
+
};
|
|
33196
|
+
}
|
|
33197
|
+
|
|
33198
|
+
// (39:4) {#if form?.icon}
|
|
33199
|
+
function create_if_block_3$3(ctx) {
|
|
32820
33200
|
let div;
|
|
32821
33201
|
let keyicon;
|
|
32822
33202
|
let current;
|
|
@@ -32855,7 +33235,7 @@ function create_if_block_2$3(ctx) {
|
|
|
32855
33235
|
};
|
|
32856
33236
|
}
|
|
32857
33237
|
|
|
32858
|
-
// (
|
|
33238
|
+
// (54:2) {#if form?.message}
|
|
32859
33239
|
function create_if_block_1$3(ctx) {
|
|
32860
33240
|
let alert;
|
|
32861
33241
|
let current;
|
|
@@ -32863,7 +33243,7 @@ function create_if_block_1$3(ctx) {
|
|
|
32863
33243
|
alert = new Alert({
|
|
32864
33244
|
props: {
|
|
32865
33245
|
id: "formFailureMessageAlert",
|
|
32866
|
-
needsFocus: /*alertNeedsFocus*/ ctx[
|
|
33246
|
+
needsFocus: /*alertNeedsFocus*/ ctx[6],
|
|
32867
33247
|
type: "error",
|
|
32868
33248
|
$$slots: { default: [create_default_slot_2$2] },
|
|
32869
33249
|
$$scope: { ctx }
|
|
@@ -32880,9 +33260,9 @@ function create_if_block_1$3(ctx) {
|
|
|
32880
33260
|
},
|
|
32881
33261
|
p(ctx, dirty) {
|
|
32882
33262
|
const alert_changes = {};
|
|
32883
|
-
if (dirty & /*alertNeedsFocus*/
|
|
33263
|
+
if (dirty & /*alertNeedsFocus*/ 64) alert_changes.needsFocus = /*alertNeedsFocus*/ ctx[6];
|
|
32884
33264
|
|
|
32885
|
-
if (dirty & /*$$scope, formMessageKey, form*/
|
|
33265
|
+
if (dirty & /*$$scope, formMessageKey, form*/ 16516) {
|
|
32886
33266
|
alert_changes.$$scope = { dirty, ctx };
|
|
32887
33267
|
}
|
|
32888
33268
|
|
|
@@ -32903,9 +33283,9 @@ function create_if_block_1$3(ctx) {
|
|
|
32903
33283
|
};
|
|
32904
33284
|
}
|
|
32905
33285
|
|
|
32906
|
-
// (
|
|
33286
|
+
// (55:4) <Alert id="formFailureMessageAlert" needsFocus={alertNeedsFocus} type="error">
|
|
32907
33287
|
function create_default_slot_2$2(ctx) {
|
|
32908
|
-
let t_value = interpolate(/*formMessageKey*/ ctx[
|
|
33288
|
+
let t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "";
|
|
32909
33289
|
let t;
|
|
32910
33290
|
|
|
32911
33291
|
return {
|
|
@@ -32916,7 +33296,7 @@ function create_default_slot_2$2(ctx) {
|
|
|
32916
33296
|
insert(target, t, anchor);
|
|
32917
33297
|
},
|
|
32918
33298
|
p(ctx, dirty) {
|
|
32919
|
-
if (dirty & /*formMessageKey, form*/
|
|
33299
|
+
if (dirty & /*formMessageKey, form*/ 132 && t_value !== (t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "")) set_data(t, t_value);
|
|
32920
33300
|
},
|
|
32921
33301
|
d(detaching) {
|
|
32922
33302
|
if (detaching) detach(t);
|
|
@@ -32924,7 +33304,7 @@ function create_default_slot_2$2(ctx) {
|
|
|
32924
33304
|
};
|
|
32925
33305
|
}
|
|
32926
33306
|
|
|
32927
|
-
// (
|
|
33307
|
+
// (60:2) {#each step?.callbacks as callback, idx}
|
|
32928
33308
|
function create_each_block$2(ctx) {
|
|
32929
33309
|
let callbackmapper;
|
|
32930
33310
|
let current;
|
|
@@ -32932,11 +33312,11 @@ function create_each_block$2(ctx) {
|
|
|
32932
33312
|
callbackmapper = new Callback_mapper({
|
|
32933
33313
|
props: {
|
|
32934
33314
|
props: {
|
|
32935
|
-
callback: /*callback*/ ctx[
|
|
32936
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
32937
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
32938
|
-
stepMetadata: /*metadata*/ ctx[
|
|
32939
|
-
style: /*$style*/ ctx[
|
|
33315
|
+
callback: /*callback*/ ctx[11],
|
|
33316
|
+
callbackMetadata: /*metadata*/ ctx[4]?.callbacks[/*idx*/ ctx[13]],
|
|
33317
|
+
selfSubmitFunction: /*determineSubmission*/ ctx[9],
|
|
33318
|
+
stepMetadata: /*metadata*/ ctx[4]?.step && { .../*metadata*/ ctx[4].step },
|
|
33319
|
+
style: /*$style*/ ctx[8]
|
|
32940
33320
|
}
|
|
32941
33321
|
}
|
|
32942
33322
|
});
|
|
@@ -32952,12 +33332,12 @@ function create_each_block$2(ctx) {
|
|
|
32952
33332
|
p(ctx, dirty) {
|
|
32953
33333
|
const callbackmapper_changes = {};
|
|
32954
33334
|
|
|
32955
|
-
if (dirty & /*step, metadata, $style*/
|
|
32956
|
-
callback: /*callback*/ ctx[
|
|
32957
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
32958
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
32959
|
-
stepMetadata: /*metadata*/ ctx[
|
|
32960
|
-
style: /*$style*/ ctx[
|
|
33335
|
+
if (dirty & /*step, metadata, $style*/ 304) callbackmapper_changes.props = {
|
|
33336
|
+
callback: /*callback*/ ctx[11],
|
|
33337
|
+
callbackMetadata: /*metadata*/ ctx[4]?.callbacks[/*idx*/ ctx[13]],
|
|
33338
|
+
selfSubmitFunction: /*determineSubmission*/ ctx[9],
|
|
33339
|
+
stepMetadata: /*metadata*/ ctx[4]?.step && { .../*metadata*/ ctx[4].step },
|
|
33340
|
+
style: /*$style*/ ctx[8]
|
|
32961
33341
|
};
|
|
32962
33342
|
|
|
32963
33343
|
callbackmapper.$set(callbackmapper_changes);
|
|
@@ -32977,14 +33357,14 @@ function create_each_block$2(ctx) {
|
|
|
32977
33357
|
};
|
|
32978
33358
|
}
|
|
32979
33359
|
|
|
32980
|
-
// (
|
|
33360
|
+
// (72:2) {#if metadata?.step?.derived.isUserInputOptional || !metadata?.step?.derived.isStepSelfSubmittable}
|
|
32981
33361
|
function create_if_block$4(ctx) {
|
|
32982
33362
|
let button;
|
|
32983
33363
|
let current;
|
|
32984
33364
|
|
|
32985
33365
|
button = new Button({
|
|
32986
33366
|
props: {
|
|
32987
|
-
busy: /*journey*/ ctx[
|
|
33367
|
+
busy: /*journey*/ ctx[3]?.loading,
|
|
32988
33368
|
style: "primary",
|
|
32989
33369
|
type: "submit",
|
|
32990
33370
|
width: "full",
|
|
@@ -33003,9 +33383,9 @@ function create_if_block$4(ctx) {
|
|
|
33003
33383
|
},
|
|
33004
33384
|
p(ctx, dirty) {
|
|
33005
33385
|
const button_changes = {};
|
|
33006
|
-
if (dirty & /*journey*/
|
|
33386
|
+
if (dirty & /*journey*/ 8) button_changes.busy = /*journey*/ ctx[3]?.loading;
|
|
33007
33387
|
|
|
33008
|
-
if (dirty & /*$$scope*/
|
|
33388
|
+
if (dirty & /*$$scope*/ 16384) {
|
|
33009
33389
|
button_changes.$$scope = { dirty, ctx };
|
|
33010
33390
|
}
|
|
33011
33391
|
|
|
@@ -33026,7 +33406,7 @@ function create_if_block$4(ctx) {
|
|
|
33026
33406
|
};
|
|
33027
33407
|
}
|
|
33028
33408
|
|
|
33029
|
-
// (
|
|
33409
|
+
// (73:4) <Button busy={journey?.loading} style="primary" type="submit" width="full">
|
|
33030
33410
|
function create_default_slot_1$3(ctx) {
|
|
33031
33411
|
let t;
|
|
33032
33412
|
let current;
|
|
@@ -33056,31 +33436,16 @@ function create_default_slot_1$3(ctx) {
|
|
|
33056
33436
|
};
|
|
33057
33437
|
}
|
|
33058
33438
|
|
|
33059
|
-
// (
|
|
33439
|
+
// (37:0) <Form bind:formEl ariaDescribedBy="formFailureMessageAlert" onSubmitWhenValid={form?.submit}>
|
|
33060
33440
|
function create_default_slot$4(ctx) {
|
|
33061
33441
|
let t0;
|
|
33062
|
-
let h1;
|
|
33063
33442
|
let t1;
|
|
33064
33443
|
let t2;
|
|
33065
|
-
let p;
|
|
33066
|
-
let t3;
|
|
33067
|
-
let t4;
|
|
33068
|
-
let t5;
|
|
33069
|
-
let t6;
|
|
33070
33444
|
let if_block2_anchor;
|
|
33071
33445
|
let current;
|
|
33072
|
-
let if_block0 = /*
|
|
33073
|
-
|
|
33074
|
-
|
|
33075
|
-
props: { key: "twoFactorAuthentication" }
|
|
33076
|
-
});
|
|
33077
|
-
|
|
33078
|
-
t3 = new Locale_strings({
|
|
33079
|
-
props: { key: "useTheAuthenticatorAppOnYourPhone" }
|
|
33080
|
-
});
|
|
33081
|
-
|
|
33082
|
-
let if_block1 = /*form*/ ctx[1]?.message && create_if_block_1$3(ctx);
|
|
33083
|
-
let each_value = /*step*/ ctx[4]?.callbacks;
|
|
33446
|
+
let if_block0 = /*componentStyle*/ ctx[1] !== 'inline' && create_if_block_2$3(ctx);
|
|
33447
|
+
let if_block1 = /*form*/ ctx[2]?.message && create_if_block_1$3(ctx);
|
|
33448
|
+
let each_value = /*step*/ ctx[5]?.callbacks;
|
|
33084
33449
|
let each_blocks = [];
|
|
33085
33450
|
|
|
33086
33451
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -33091,60 +33456,48 @@ function create_default_slot$4(ctx) {
|
|
|
33091
33456
|
each_blocks[i] = null;
|
|
33092
33457
|
});
|
|
33093
33458
|
|
|
33094
|
-
let if_block2 = (/*metadata*/ ctx[
|
|
33459
|
+
let if_block2 = (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) && create_if_block$4(ctx);
|
|
33095
33460
|
|
|
33096
33461
|
return {
|
|
33097
33462
|
c() {
|
|
33098
33463
|
if (if_block0) if_block0.c();
|
|
33099
33464
|
t0 = space();
|
|
33100
|
-
h1 = element("h1");
|
|
33101
|
-
create_component(t1.$$.fragment);
|
|
33102
|
-
t2 = space();
|
|
33103
|
-
p = element("p");
|
|
33104
|
-
create_component(t3.$$.fragment);
|
|
33105
|
-
t4 = space();
|
|
33106
33465
|
if (if_block1) if_block1.c();
|
|
33107
|
-
|
|
33466
|
+
t1 = space();
|
|
33108
33467
|
|
|
33109
33468
|
for (let i = 0; i < each_blocks.length; i += 1) {
|
|
33110
33469
|
each_blocks[i].c();
|
|
33111
33470
|
}
|
|
33112
33471
|
|
|
33113
|
-
|
|
33472
|
+
t2 = space();
|
|
33114
33473
|
if (if_block2) if_block2.c();
|
|
33115
33474
|
if_block2_anchor = empty();
|
|
33116
|
-
attr(h1, "class", "tw_primary-header dark:tw_primary-header_dark");
|
|
33117
|
-
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");
|
|
33118
33475
|
},
|
|
33119
33476
|
m(target, anchor) {
|
|
33120
33477
|
if (if_block0) if_block0.m(target, anchor);
|
|
33121
33478
|
insert(target, t0, anchor);
|
|
33122
|
-
insert(target, h1, anchor);
|
|
33123
|
-
mount_component(t1, h1, null);
|
|
33124
|
-
insert(target, t2, anchor);
|
|
33125
|
-
insert(target, p, anchor);
|
|
33126
|
-
mount_component(t3, p, null);
|
|
33127
|
-
insert(target, t4, anchor);
|
|
33128
33479
|
if (if_block1) if_block1.m(target, anchor);
|
|
33129
|
-
insert(target,
|
|
33480
|
+
insert(target, t1, anchor);
|
|
33130
33481
|
|
|
33131
33482
|
for (let i = 0; i < each_blocks.length; i += 1) {
|
|
33132
33483
|
each_blocks[i].m(target, anchor);
|
|
33133
33484
|
}
|
|
33134
33485
|
|
|
33135
|
-
insert(target,
|
|
33486
|
+
insert(target, t2, anchor);
|
|
33136
33487
|
if (if_block2) if_block2.m(target, anchor);
|
|
33137
33488
|
insert(target, if_block2_anchor, anchor);
|
|
33138
33489
|
current = true;
|
|
33139
33490
|
},
|
|
33140
33491
|
p(ctx, dirty) {
|
|
33141
|
-
if (/*
|
|
33492
|
+
if (/*componentStyle*/ ctx[1] !== 'inline') {
|
|
33142
33493
|
if (if_block0) {
|
|
33143
|
-
|
|
33494
|
+
if_block0.p(ctx, dirty);
|
|
33495
|
+
|
|
33496
|
+
if (dirty & /*componentStyle*/ 2) {
|
|
33144
33497
|
transition_in(if_block0, 1);
|
|
33145
33498
|
}
|
|
33146
33499
|
} else {
|
|
33147
|
-
if_block0 = create_if_block_2$3();
|
|
33500
|
+
if_block0 = create_if_block_2$3(ctx);
|
|
33148
33501
|
if_block0.c();
|
|
33149
33502
|
transition_in(if_block0, 1);
|
|
33150
33503
|
if_block0.m(t0.parentNode, t0);
|
|
@@ -33159,18 +33512,18 @@ function create_default_slot$4(ctx) {
|
|
|
33159
33512
|
check_outros();
|
|
33160
33513
|
}
|
|
33161
33514
|
|
|
33162
|
-
if (/*form*/ ctx[
|
|
33515
|
+
if (/*form*/ ctx[2]?.message) {
|
|
33163
33516
|
if (if_block1) {
|
|
33164
33517
|
if_block1.p(ctx, dirty);
|
|
33165
33518
|
|
|
33166
|
-
if (dirty & /*form*/
|
|
33519
|
+
if (dirty & /*form*/ 4) {
|
|
33167
33520
|
transition_in(if_block1, 1);
|
|
33168
33521
|
}
|
|
33169
33522
|
} else {
|
|
33170
33523
|
if_block1 = create_if_block_1$3(ctx);
|
|
33171
33524
|
if_block1.c();
|
|
33172
33525
|
transition_in(if_block1, 1);
|
|
33173
|
-
if_block1.m(
|
|
33526
|
+
if_block1.m(t1.parentNode, t1);
|
|
33174
33527
|
}
|
|
33175
33528
|
} else if (if_block1) {
|
|
33176
33529
|
group_outros();
|
|
@@ -33182,8 +33535,8 @@ function create_default_slot$4(ctx) {
|
|
|
33182
33535
|
check_outros();
|
|
33183
33536
|
}
|
|
33184
33537
|
|
|
33185
|
-
if (dirty & /*step, metadata, determineSubmission, $style*/
|
|
33186
|
-
each_value = /*step*/ ctx[
|
|
33538
|
+
if (dirty & /*step, metadata, determineSubmission, $style*/ 816) {
|
|
33539
|
+
each_value = /*step*/ ctx[5]?.callbacks;
|
|
33187
33540
|
let i;
|
|
33188
33541
|
|
|
33189
33542
|
for (i = 0; i < each_value.length; i += 1) {
|
|
@@ -33196,7 +33549,7 @@ function create_default_slot$4(ctx) {
|
|
|
33196
33549
|
each_blocks[i] = create_each_block$2(child_ctx);
|
|
33197
33550
|
each_blocks[i].c();
|
|
33198
33551
|
transition_in(each_blocks[i], 1);
|
|
33199
|
-
each_blocks[i].m(
|
|
33552
|
+
each_blocks[i].m(t2.parentNode, t2);
|
|
33200
33553
|
}
|
|
33201
33554
|
}
|
|
33202
33555
|
|
|
@@ -33209,11 +33562,11 @@ function create_default_slot$4(ctx) {
|
|
|
33209
33562
|
check_outros();
|
|
33210
33563
|
}
|
|
33211
33564
|
|
|
33212
|
-
if (/*metadata*/ ctx[
|
|
33565
|
+
if (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) {
|
|
33213
33566
|
if (if_block2) {
|
|
33214
33567
|
if_block2.p(ctx, dirty);
|
|
33215
33568
|
|
|
33216
|
-
if (dirty & /*metadata*/
|
|
33569
|
+
if (dirty & /*metadata*/ 16) {
|
|
33217
33570
|
transition_in(if_block2, 1);
|
|
33218
33571
|
}
|
|
33219
33572
|
} else {
|
|
@@ -33235,8 +33588,6 @@ function create_default_slot$4(ctx) {
|
|
|
33235
33588
|
i(local) {
|
|
33236
33589
|
if (current) return;
|
|
33237
33590
|
transition_in(if_block0);
|
|
33238
|
-
transition_in(t1.$$.fragment, local);
|
|
33239
|
-
transition_in(t3.$$.fragment, local);
|
|
33240
33591
|
transition_in(if_block1);
|
|
33241
33592
|
|
|
33242
33593
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -33248,8 +33599,6 @@ function create_default_slot$4(ctx) {
|
|
|
33248
33599
|
},
|
|
33249
33600
|
o(local) {
|
|
33250
33601
|
transition_out(if_block0);
|
|
33251
|
-
transition_out(t1.$$.fragment, local);
|
|
33252
|
-
transition_out(t3.$$.fragment, local);
|
|
33253
33602
|
transition_out(if_block1);
|
|
33254
33603
|
each_blocks = each_blocks.filter(Boolean);
|
|
33255
33604
|
|
|
@@ -33263,16 +33612,10 @@ function create_default_slot$4(ctx) {
|
|
|
33263
33612
|
d(detaching) {
|
|
33264
33613
|
if (if_block0) if_block0.d(detaching);
|
|
33265
33614
|
if (detaching) detach(t0);
|
|
33266
|
-
if (detaching) detach(h1);
|
|
33267
|
-
destroy_component(t1);
|
|
33268
|
-
if (detaching) detach(t2);
|
|
33269
|
-
if (detaching) detach(p);
|
|
33270
|
-
destroy_component(t3);
|
|
33271
|
-
if (detaching) detach(t4);
|
|
33272
33615
|
if (if_block1) if_block1.d(detaching);
|
|
33273
|
-
if (detaching) detach(
|
|
33616
|
+
if (detaching) detach(t1);
|
|
33274
33617
|
destroy_each(each_blocks, detaching);
|
|
33275
|
-
if (detaching) detach(
|
|
33618
|
+
if (detaching) detach(t2);
|
|
33276
33619
|
if (if_block2) if_block2.d(detaching);
|
|
33277
33620
|
if (detaching) detach(if_block2_anchor);
|
|
33278
33621
|
}
|
|
@@ -33285,12 +33628,12 @@ function create_fragment$5(ctx) {
|
|
|
33285
33628
|
let current;
|
|
33286
33629
|
|
|
33287
33630
|
function form_1_formEl_binding(value) {
|
|
33288
|
-
/*form_1_formEl_binding*/ ctx[
|
|
33631
|
+
/*form_1_formEl_binding*/ ctx[10](value);
|
|
33289
33632
|
}
|
|
33290
33633
|
|
|
33291
33634
|
let form_1_props = {
|
|
33292
33635
|
ariaDescribedBy: "formFailureMessageAlert",
|
|
33293
|
-
onSubmitWhenValid: /*form*/ ctx[
|
|
33636
|
+
onSubmitWhenValid: /*form*/ ctx[2]?.submit,
|
|
33294
33637
|
$$slots: { default: [create_default_slot$4] },
|
|
33295
33638
|
$$scope: { ctx }
|
|
33296
33639
|
};
|
|
@@ -33312,9 +33655,9 @@ function create_fragment$5(ctx) {
|
|
|
33312
33655
|
},
|
|
33313
33656
|
p(ctx, [dirty]) {
|
|
33314
33657
|
const form_1_changes = {};
|
|
33315
|
-
if (dirty & /*form*/
|
|
33658
|
+
if (dirty & /*form*/ 4) form_1_changes.onSubmitWhenValid = /*form*/ ctx[2]?.submit;
|
|
33316
33659
|
|
|
33317
|
-
if (dirty & /*$$scope, journey, metadata, step, $style, alertNeedsFocus, formMessageKey, form*/
|
|
33660
|
+
if (dirty & /*$$scope, journey, metadata, step, $style, alertNeedsFocus, formMessageKey, form, componentStyle*/ 16894) {
|
|
33318
33661
|
form_1_changes.$$scope = { dirty, ctx };
|
|
33319
33662
|
}
|
|
33320
33663
|
|
|
@@ -33343,7 +33686,8 @@ function create_fragment$5(ctx) {
|
|
|
33343
33686
|
|
|
33344
33687
|
function instance$5($$self, $$props, $$invalidate) {
|
|
33345
33688
|
let $style;
|
|
33346
|
-
component_subscribe($$self, styleStore, $$value => $$invalidate(
|
|
33689
|
+
component_subscribe($$self, styleStore, $$value => $$invalidate(8, $style = $$value));
|
|
33690
|
+
let { componentStyle } = $$props;
|
|
33347
33691
|
let { form } = $$props;
|
|
33348
33692
|
let { formEl = null } = $$props;
|
|
33349
33693
|
let { journey } = $$props;
|
|
@@ -33362,7 +33706,7 @@ function instance$5($$self, $$props, $$invalidate) {
|
|
|
33362
33706
|
}
|
|
33363
33707
|
|
|
33364
33708
|
afterUpdate(() => {
|
|
33365
|
-
$$invalidate(
|
|
33709
|
+
$$invalidate(6, alertNeedsFocus = !!form?.message);
|
|
33366
33710
|
});
|
|
33367
33711
|
|
|
33368
33712
|
function form_1_formEl_binding(value) {
|
|
@@ -33371,23 +33715,25 @@ function instance$5($$self, $$props, $$invalidate) {
|
|
|
33371
33715
|
}
|
|
33372
33716
|
|
|
33373
33717
|
$$self.$$set = $$props => {
|
|
33374
|
-
if ('
|
|
33718
|
+
if ('componentStyle' in $$props) $$invalidate(1, componentStyle = $$props.componentStyle);
|
|
33719
|
+
if ('form' in $$props) $$invalidate(2, form = $$props.form);
|
|
33375
33720
|
if ('formEl' in $$props) $$invalidate(0, formEl = $$props.formEl);
|
|
33376
|
-
if ('journey' in $$props) $$invalidate(
|
|
33377
|
-
if ('metadata' in $$props) $$invalidate(
|
|
33378
|
-
if ('step' in $$props) $$invalidate(
|
|
33721
|
+
if ('journey' in $$props) $$invalidate(3, journey = $$props.journey);
|
|
33722
|
+
if ('metadata' in $$props) $$invalidate(4, metadata = $$props.metadata);
|
|
33723
|
+
if ('step' in $$props) $$invalidate(5, step = $$props.step);
|
|
33379
33724
|
};
|
|
33380
33725
|
|
|
33381
33726
|
$$self.$$.update = () => {
|
|
33382
|
-
if ($$self.$$.dirty & /*form*/
|
|
33727
|
+
if ($$self.$$.dirty & /*form*/ 4) {
|
|
33383
33728
|
{
|
|
33384
|
-
$$invalidate(
|
|
33729
|
+
$$invalidate(7, formMessageKey = convertStringToKey(form?.message));
|
|
33385
33730
|
}
|
|
33386
33731
|
}
|
|
33387
33732
|
};
|
|
33388
33733
|
|
|
33389
33734
|
return [
|
|
33390
33735
|
formEl,
|
|
33736
|
+
componentStyle,
|
|
33391
33737
|
form,
|
|
33392
33738
|
journey,
|
|
33393
33739
|
metadata,
|
|
@@ -33405,11 +33751,12 @@ class One_time_password extends SvelteComponent {
|
|
|
33405
33751
|
super();
|
|
33406
33752
|
|
|
33407
33753
|
init(this, options, instance$5, create_fragment$5, safe_not_equal, {
|
|
33408
|
-
|
|
33754
|
+
componentStyle: 1,
|
|
33755
|
+
form: 2,
|
|
33409
33756
|
formEl: 0,
|
|
33410
|
-
journey:
|
|
33411
|
-
metadata:
|
|
33412
|
-
step:
|
|
33757
|
+
journey: 3,
|
|
33758
|
+
metadata: 4,
|
|
33759
|
+
step: 5
|
|
33413
33760
|
});
|
|
33414
33761
|
}
|
|
33415
33762
|
}
|
|
@@ -33522,13 +33869,100 @@ class New_user_icon extends SvelteComponent {
|
|
|
33522
33869
|
|
|
33523
33870
|
function get_each_context$1(ctx, list, i) {
|
|
33524
33871
|
const child_ctx = ctx.slice();
|
|
33525
|
-
child_ctx[
|
|
33526
|
-
child_ctx[
|
|
33872
|
+
child_ctx[13] = list[i];
|
|
33873
|
+
child_ctx[15] = i;
|
|
33527
33874
|
return child_ctx;
|
|
33528
33875
|
}
|
|
33529
33876
|
|
|
33530
|
-
// (
|
|
33877
|
+
// (50:2) {#if componentStyle !== 'inline'}
|
|
33531
33878
|
function create_if_block_2$2(ctx) {
|
|
33879
|
+
let t0;
|
|
33880
|
+
let h1;
|
|
33881
|
+
let t1;
|
|
33882
|
+
let t2;
|
|
33883
|
+
let p;
|
|
33884
|
+
let t3;
|
|
33885
|
+
let current;
|
|
33886
|
+
let if_block = /*form*/ ctx[2]?.icon && create_if_block_3$2();
|
|
33887
|
+
t1 = new Locale_strings({ props: { key: "registerHeader" } });
|
|
33888
|
+
|
|
33889
|
+
t3 = new Locale_strings({
|
|
33890
|
+
props: { key: "alreadyHaveAnAccount", html: true }
|
|
33891
|
+
});
|
|
33892
|
+
|
|
33893
|
+
return {
|
|
33894
|
+
c() {
|
|
33895
|
+
if (if_block) if_block.c();
|
|
33896
|
+
t0 = space();
|
|
33897
|
+
h1 = element("h1");
|
|
33898
|
+
create_component(t1.$$.fragment);
|
|
33899
|
+
t2 = space();
|
|
33900
|
+
p = element("p");
|
|
33901
|
+
create_component(t3.$$.fragment);
|
|
33902
|
+
attr(h1, "class", "tw_primary-header dark:tw_primary-header_dark");
|
|
33903
|
+
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");
|
|
33904
|
+
},
|
|
33905
|
+
m(target, anchor) {
|
|
33906
|
+
if (if_block) if_block.m(target, anchor);
|
|
33907
|
+
insert(target, t0, anchor);
|
|
33908
|
+
insert(target, h1, anchor);
|
|
33909
|
+
mount_component(t1, h1, null);
|
|
33910
|
+
insert(target, t2, anchor);
|
|
33911
|
+
insert(target, p, anchor);
|
|
33912
|
+
mount_component(t3, p, null);
|
|
33913
|
+
/*p_binding*/ ctx[11](p);
|
|
33914
|
+
current = true;
|
|
33915
|
+
},
|
|
33916
|
+
p(ctx, dirty) {
|
|
33917
|
+
if (/*form*/ ctx[2]?.icon) {
|
|
33918
|
+
if (if_block) {
|
|
33919
|
+
if (dirty & /*form*/ 4) {
|
|
33920
|
+
transition_in(if_block, 1);
|
|
33921
|
+
}
|
|
33922
|
+
} else {
|
|
33923
|
+
if_block = create_if_block_3$2();
|
|
33924
|
+
if_block.c();
|
|
33925
|
+
transition_in(if_block, 1);
|
|
33926
|
+
if_block.m(t0.parentNode, t0);
|
|
33927
|
+
}
|
|
33928
|
+
} else if (if_block) {
|
|
33929
|
+
group_outros();
|
|
33930
|
+
|
|
33931
|
+
transition_out(if_block, 1, 1, () => {
|
|
33932
|
+
if_block = null;
|
|
33933
|
+
});
|
|
33934
|
+
|
|
33935
|
+
check_outros();
|
|
33936
|
+
}
|
|
33937
|
+
},
|
|
33938
|
+
i(local) {
|
|
33939
|
+
if (current) return;
|
|
33940
|
+
transition_in(if_block);
|
|
33941
|
+
transition_in(t1.$$.fragment, local);
|
|
33942
|
+
transition_in(t3.$$.fragment, local);
|
|
33943
|
+
current = true;
|
|
33944
|
+
},
|
|
33945
|
+
o(local) {
|
|
33946
|
+
transition_out(if_block);
|
|
33947
|
+
transition_out(t1.$$.fragment, local);
|
|
33948
|
+
transition_out(t3.$$.fragment, local);
|
|
33949
|
+
current = false;
|
|
33950
|
+
},
|
|
33951
|
+
d(detaching) {
|
|
33952
|
+
if (if_block) if_block.d(detaching);
|
|
33953
|
+
if (detaching) detach(t0);
|
|
33954
|
+
if (detaching) detach(h1);
|
|
33955
|
+
destroy_component(t1);
|
|
33956
|
+
if (detaching) detach(t2);
|
|
33957
|
+
if (detaching) detach(p);
|
|
33958
|
+
destroy_component(t3);
|
|
33959
|
+
/*p_binding*/ ctx[11](null);
|
|
33960
|
+
}
|
|
33961
|
+
};
|
|
33962
|
+
}
|
|
33963
|
+
|
|
33964
|
+
// (51:4) {#if form?.icon}
|
|
33965
|
+
function create_if_block_3$2(ctx) {
|
|
33532
33966
|
let div;
|
|
33533
33967
|
let newusericon;
|
|
33534
33968
|
let current;
|
|
@@ -33567,7 +34001,7 @@ function create_if_block_2$2(ctx) {
|
|
|
33567
34001
|
};
|
|
33568
34002
|
}
|
|
33569
34003
|
|
|
33570
|
-
// (
|
|
34004
|
+
// (67:2) {#if form.message}
|
|
33571
34005
|
function create_if_block_1$2(ctx) {
|
|
33572
34006
|
let alert;
|
|
33573
34007
|
let current;
|
|
@@ -33575,7 +34009,7 @@ function create_if_block_1$2(ctx) {
|
|
|
33575
34009
|
alert = new Alert({
|
|
33576
34010
|
props: {
|
|
33577
34011
|
id: "formFailureMessageAlert",
|
|
33578
|
-
needsFocus: /*alertNeedsFocus*/ ctx[
|
|
34012
|
+
needsFocus: /*alertNeedsFocus*/ ctx[6],
|
|
33579
34013
|
type: "error",
|
|
33580
34014
|
$$slots: { default: [create_default_slot_2$1] },
|
|
33581
34015
|
$$scope: { ctx }
|
|
@@ -33592,9 +34026,9 @@ function create_if_block_1$2(ctx) {
|
|
|
33592
34026
|
},
|
|
33593
34027
|
p(ctx, dirty) {
|
|
33594
34028
|
const alert_changes = {};
|
|
33595
|
-
if (dirty & /*alertNeedsFocus*/
|
|
34029
|
+
if (dirty & /*alertNeedsFocus*/ 64) alert_changes.needsFocus = /*alertNeedsFocus*/ ctx[6];
|
|
33596
34030
|
|
|
33597
|
-
if (dirty & /*$$scope, formMessageKey, form*/
|
|
34031
|
+
if (dirty & /*$$scope, formMessageKey, form*/ 65668) {
|
|
33598
34032
|
alert_changes.$$scope = { dirty, ctx };
|
|
33599
34033
|
}
|
|
33600
34034
|
|
|
@@ -33615,9 +34049,9 @@ function create_if_block_1$2(ctx) {
|
|
|
33615
34049
|
};
|
|
33616
34050
|
}
|
|
33617
34051
|
|
|
33618
|
-
// (
|
|
34052
|
+
// (68:4) <Alert id="formFailureMessageAlert" needsFocus={alertNeedsFocus} type="error">
|
|
33619
34053
|
function create_default_slot_2$1(ctx) {
|
|
33620
|
-
let t_value = interpolate(/*formMessageKey*/ ctx[
|
|
34054
|
+
let t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "";
|
|
33621
34055
|
let t;
|
|
33622
34056
|
|
|
33623
34057
|
return {
|
|
@@ -33628,7 +34062,7 @@ function create_default_slot_2$1(ctx) {
|
|
|
33628
34062
|
insert(target, t, anchor);
|
|
33629
34063
|
},
|
|
33630
34064
|
p(ctx, dirty) {
|
|
33631
|
-
if (dirty & /*formMessageKey, form*/
|
|
34065
|
+
if (dirty & /*formMessageKey, form*/ 132 && t_value !== (t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "")) set_data(t, t_value);
|
|
33632
34066
|
},
|
|
33633
34067
|
d(detaching) {
|
|
33634
34068
|
if (detaching) detach(t);
|
|
@@ -33636,7 +34070,7 @@ function create_default_slot_2$1(ctx) {
|
|
|
33636
34070
|
};
|
|
33637
34071
|
}
|
|
33638
34072
|
|
|
33639
|
-
// (
|
|
34073
|
+
// (73:2) {#each step?.callbacks as callback, idx}
|
|
33640
34074
|
function create_each_block$1(ctx) {
|
|
33641
34075
|
let callbackmapper;
|
|
33642
34076
|
let current;
|
|
@@ -33644,11 +34078,11 @@ function create_each_block$1(ctx) {
|
|
|
33644
34078
|
callbackmapper = new Callback_mapper({
|
|
33645
34079
|
props: {
|
|
33646
34080
|
props: {
|
|
33647
|
-
callback: /*callback*/ ctx[
|
|
33648
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
33649
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
33650
|
-
stepMetadata: /*metadata*/ ctx[
|
|
33651
|
-
style: /*$styleStore*/ ctx[
|
|
34081
|
+
callback: /*callback*/ ctx[13],
|
|
34082
|
+
callbackMetadata: /*metadata*/ ctx[4]?.callbacks[/*idx*/ ctx[15]],
|
|
34083
|
+
selfSubmitFunction: /*determineSubmission*/ ctx[10],
|
|
34084
|
+
stepMetadata: /*metadata*/ ctx[4]?.step && { .../*metadata*/ ctx[4].step },
|
|
34085
|
+
style: /*$styleStore*/ ctx[9]
|
|
33652
34086
|
}
|
|
33653
34087
|
}
|
|
33654
34088
|
});
|
|
@@ -33664,12 +34098,12 @@ function create_each_block$1(ctx) {
|
|
|
33664
34098
|
p(ctx, dirty) {
|
|
33665
34099
|
const callbackmapper_changes = {};
|
|
33666
34100
|
|
|
33667
|
-
if (dirty & /*step, metadata, $styleStore*/
|
|
33668
|
-
callback: /*callback*/ ctx[
|
|
33669
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
33670
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
33671
|
-
stepMetadata: /*metadata*/ ctx[
|
|
33672
|
-
style: /*$styleStore*/ ctx[
|
|
34101
|
+
if (dirty & /*step, metadata, $styleStore*/ 560) callbackmapper_changes.props = {
|
|
34102
|
+
callback: /*callback*/ ctx[13],
|
|
34103
|
+
callbackMetadata: /*metadata*/ ctx[4]?.callbacks[/*idx*/ ctx[15]],
|
|
34104
|
+
selfSubmitFunction: /*determineSubmission*/ ctx[10],
|
|
34105
|
+
stepMetadata: /*metadata*/ ctx[4]?.step && { .../*metadata*/ ctx[4].step },
|
|
34106
|
+
style: /*$styleStore*/ ctx[9]
|
|
33673
34107
|
};
|
|
33674
34108
|
|
|
33675
34109
|
callbackmapper.$set(callbackmapper_changes);
|
|
@@ -33689,14 +34123,14 @@ function create_each_block$1(ctx) {
|
|
|
33689
34123
|
};
|
|
33690
34124
|
}
|
|
33691
34125
|
|
|
33692
|
-
// (
|
|
34126
|
+
// (85:2) {#if metadata?.step?.derived.isUserInputOptional || !metadata?.step?.derived.isStepSelfSubmittable}
|
|
33693
34127
|
function create_if_block$3(ctx) {
|
|
33694
34128
|
let button;
|
|
33695
34129
|
let current;
|
|
33696
34130
|
|
|
33697
34131
|
button = new Button({
|
|
33698
34132
|
props: {
|
|
33699
|
-
busy: /*journey*/ ctx[
|
|
34133
|
+
busy: /*journey*/ ctx[3]?.loading,
|
|
33700
34134
|
style: "primary",
|
|
33701
34135
|
type: "submit",
|
|
33702
34136
|
width: "full",
|
|
@@ -33715,9 +34149,9 @@ function create_if_block$3(ctx) {
|
|
|
33715
34149
|
},
|
|
33716
34150
|
p(ctx, dirty) {
|
|
33717
34151
|
const button_changes = {};
|
|
33718
|
-
if (dirty & /*journey*/
|
|
34152
|
+
if (dirty & /*journey*/ 8) button_changes.busy = /*journey*/ ctx[3]?.loading;
|
|
33719
34153
|
|
|
33720
|
-
if (dirty & /*$$scope*/
|
|
34154
|
+
if (dirty & /*$$scope*/ 65536) {
|
|
33721
34155
|
button_changes.$$scope = { dirty, ctx };
|
|
33722
34156
|
}
|
|
33723
34157
|
|
|
@@ -33738,7 +34172,7 @@ function create_if_block$3(ctx) {
|
|
|
33738
34172
|
};
|
|
33739
34173
|
}
|
|
33740
34174
|
|
|
33741
|
-
// (
|
|
34175
|
+
// (86:4) <Button busy={journey?.loading} style="primary" type="submit" width="full">
|
|
33742
34176
|
function create_default_slot_1$2(ctx) {
|
|
33743
34177
|
let t;
|
|
33744
34178
|
let current;
|
|
@@ -33768,28 +34202,16 @@ function create_default_slot_1$2(ctx) {
|
|
|
33768
34202
|
};
|
|
33769
34203
|
}
|
|
33770
34204
|
|
|
33771
|
-
// (
|
|
34205
|
+
// (49:0) <Form bind:formEl ariaDescribedBy="formFailureMessageAlert" onSubmitWhenValid={form?.submit}>
|
|
33772
34206
|
function create_default_slot$3(ctx) {
|
|
33773
34207
|
let t0;
|
|
33774
|
-
let h1;
|
|
33775
34208
|
let t1;
|
|
33776
34209
|
let t2;
|
|
33777
|
-
let p;
|
|
33778
|
-
let t3;
|
|
33779
|
-
let t4;
|
|
33780
|
-
let t5;
|
|
33781
|
-
let t6;
|
|
33782
34210
|
let if_block2_anchor;
|
|
33783
34211
|
let current;
|
|
33784
|
-
let if_block0 = /*
|
|
33785
|
-
|
|
33786
|
-
|
|
33787
|
-
t3 = new Locale_strings({
|
|
33788
|
-
props: { key: "alreadyHaveAnAccount", html: true }
|
|
33789
|
-
});
|
|
33790
|
-
|
|
33791
|
-
let if_block1 = /*form*/ ctx[1].message && create_if_block_1$2(ctx);
|
|
33792
|
-
let each_value = /*step*/ ctx[4]?.callbacks;
|
|
34212
|
+
let if_block0 = /*componentStyle*/ ctx[1] !== 'inline' && create_if_block_2$2(ctx);
|
|
34213
|
+
let if_block1 = /*form*/ ctx[2].message && create_if_block_1$2(ctx);
|
|
34214
|
+
let each_value = /*step*/ ctx[5]?.callbacks;
|
|
33793
34215
|
let each_blocks = [];
|
|
33794
34216
|
|
|
33795
34217
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -33800,61 +34222,48 @@ function create_default_slot$3(ctx) {
|
|
|
33800
34222
|
each_blocks[i] = null;
|
|
33801
34223
|
});
|
|
33802
34224
|
|
|
33803
|
-
let if_block2 = (/*metadata*/ ctx[
|
|
34225
|
+
let if_block2 = (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) && create_if_block$3(ctx);
|
|
33804
34226
|
|
|
33805
34227
|
return {
|
|
33806
34228
|
c() {
|
|
33807
34229
|
if (if_block0) if_block0.c();
|
|
33808
34230
|
t0 = space();
|
|
33809
|
-
h1 = element("h1");
|
|
33810
|
-
create_component(t1.$$.fragment);
|
|
33811
|
-
t2 = space();
|
|
33812
|
-
p = element("p");
|
|
33813
|
-
create_component(t3.$$.fragment);
|
|
33814
|
-
t4 = space();
|
|
33815
34231
|
if (if_block1) if_block1.c();
|
|
33816
|
-
|
|
34232
|
+
t1 = space();
|
|
33817
34233
|
|
|
33818
34234
|
for (let i = 0; i < each_blocks.length; i += 1) {
|
|
33819
34235
|
each_blocks[i].c();
|
|
33820
34236
|
}
|
|
33821
34237
|
|
|
33822
|
-
|
|
34238
|
+
t2 = space();
|
|
33823
34239
|
if (if_block2) if_block2.c();
|
|
33824
34240
|
if_block2_anchor = empty();
|
|
33825
|
-
attr(h1, "class", "tw_primary-header dark:tw_primary-header_dark");
|
|
33826
|
-
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");
|
|
33827
34241
|
},
|
|
33828
34242
|
m(target, anchor) {
|
|
33829
34243
|
if (if_block0) if_block0.m(target, anchor);
|
|
33830
34244
|
insert(target, t0, anchor);
|
|
33831
|
-
insert(target, h1, anchor);
|
|
33832
|
-
mount_component(t1, h1, null);
|
|
33833
|
-
insert(target, t2, anchor);
|
|
33834
|
-
insert(target, p, anchor);
|
|
33835
|
-
mount_component(t3, p, null);
|
|
33836
|
-
/*p_binding*/ ctx[10](p);
|
|
33837
|
-
insert(target, t4, anchor);
|
|
33838
34245
|
if (if_block1) if_block1.m(target, anchor);
|
|
33839
|
-
insert(target,
|
|
34246
|
+
insert(target, t1, anchor);
|
|
33840
34247
|
|
|
33841
34248
|
for (let i = 0; i < each_blocks.length; i += 1) {
|
|
33842
34249
|
each_blocks[i].m(target, anchor);
|
|
33843
34250
|
}
|
|
33844
34251
|
|
|
33845
|
-
insert(target,
|
|
34252
|
+
insert(target, t2, anchor);
|
|
33846
34253
|
if (if_block2) if_block2.m(target, anchor);
|
|
33847
34254
|
insert(target, if_block2_anchor, anchor);
|
|
33848
34255
|
current = true;
|
|
33849
34256
|
},
|
|
33850
34257
|
p(ctx, dirty) {
|
|
33851
|
-
if (/*
|
|
34258
|
+
if (/*componentStyle*/ ctx[1] !== 'inline') {
|
|
33852
34259
|
if (if_block0) {
|
|
33853
|
-
|
|
34260
|
+
if_block0.p(ctx, dirty);
|
|
34261
|
+
|
|
34262
|
+
if (dirty & /*componentStyle*/ 2) {
|
|
33854
34263
|
transition_in(if_block0, 1);
|
|
33855
34264
|
}
|
|
33856
34265
|
} else {
|
|
33857
|
-
if_block0 = create_if_block_2$2();
|
|
34266
|
+
if_block0 = create_if_block_2$2(ctx);
|
|
33858
34267
|
if_block0.c();
|
|
33859
34268
|
transition_in(if_block0, 1);
|
|
33860
34269
|
if_block0.m(t0.parentNode, t0);
|
|
@@ -33869,18 +34278,18 @@ function create_default_slot$3(ctx) {
|
|
|
33869
34278
|
check_outros();
|
|
33870
34279
|
}
|
|
33871
34280
|
|
|
33872
|
-
if (/*form*/ ctx[
|
|
34281
|
+
if (/*form*/ ctx[2].message) {
|
|
33873
34282
|
if (if_block1) {
|
|
33874
34283
|
if_block1.p(ctx, dirty);
|
|
33875
34284
|
|
|
33876
|
-
if (dirty & /*form*/
|
|
34285
|
+
if (dirty & /*form*/ 4) {
|
|
33877
34286
|
transition_in(if_block1, 1);
|
|
33878
34287
|
}
|
|
33879
34288
|
} else {
|
|
33880
34289
|
if_block1 = create_if_block_1$2(ctx);
|
|
33881
34290
|
if_block1.c();
|
|
33882
34291
|
transition_in(if_block1, 1);
|
|
33883
|
-
if_block1.m(
|
|
34292
|
+
if_block1.m(t1.parentNode, t1);
|
|
33884
34293
|
}
|
|
33885
34294
|
} else if (if_block1) {
|
|
33886
34295
|
group_outros();
|
|
@@ -33892,8 +34301,8 @@ function create_default_slot$3(ctx) {
|
|
|
33892
34301
|
check_outros();
|
|
33893
34302
|
}
|
|
33894
34303
|
|
|
33895
|
-
if (dirty & /*step, metadata, determineSubmission, $styleStore*/
|
|
33896
|
-
each_value = /*step*/ ctx[
|
|
34304
|
+
if (dirty & /*step, metadata, determineSubmission, $styleStore*/ 1584) {
|
|
34305
|
+
each_value = /*step*/ ctx[5]?.callbacks;
|
|
33897
34306
|
let i;
|
|
33898
34307
|
|
|
33899
34308
|
for (i = 0; i < each_value.length; i += 1) {
|
|
@@ -33906,7 +34315,7 @@ function create_default_slot$3(ctx) {
|
|
|
33906
34315
|
each_blocks[i] = create_each_block$1(child_ctx);
|
|
33907
34316
|
each_blocks[i].c();
|
|
33908
34317
|
transition_in(each_blocks[i], 1);
|
|
33909
|
-
each_blocks[i].m(
|
|
34318
|
+
each_blocks[i].m(t2.parentNode, t2);
|
|
33910
34319
|
}
|
|
33911
34320
|
}
|
|
33912
34321
|
|
|
@@ -33919,11 +34328,11 @@ function create_default_slot$3(ctx) {
|
|
|
33919
34328
|
check_outros();
|
|
33920
34329
|
}
|
|
33921
34330
|
|
|
33922
|
-
if (/*metadata*/ ctx[
|
|
34331
|
+
if (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) {
|
|
33923
34332
|
if (if_block2) {
|
|
33924
34333
|
if_block2.p(ctx, dirty);
|
|
33925
34334
|
|
|
33926
|
-
if (dirty & /*metadata*/
|
|
34335
|
+
if (dirty & /*metadata*/ 16) {
|
|
33927
34336
|
transition_in(if_block2, 1);
|
|
33928
34337
|
}
|
|
33929
34338
|
} else {
|
|
@@ -33945,8 +34354,6 @@ function create_default_slot$3(ctx) {
|
|
|
33945
34354
|
i(local) {
|
|
33946
34355
|
if (current) return;
|
|
33947
34356
|
transition_in(if_block0);
|
|
33948
|
-
transition_in(t1.$$.fragment, local);
|
|
33949
|
-
transition_in(t3.$$.fragment, local);
|
|
33950
34357
|
transition_in(if_block1);
|
|
33951
34358
|
|
|
33952
34359
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -33958,8 +34365,6 @@ function create_default_slot$3(ctx) {
|
|
|
33958
34365
|
},
|
|
33959
34366
|
o(local) {
|
|
33960
34367
|
transition_out(if_block0);
|
|
33961
|
-
transition_out(t1.$$.fragment, local);
|
|
33962
|
-
transition_out(t3.$$.fragment, local);
|
|
33963
34368
|
transition_out(if_block1);
|
|
33964
34369
|
each_blocks = each_blocks.filter(Boolean);
|
|
33965
34370
|
|
|
@@ -33973,17 +34378,10 @@ function create_default_slot$3(ctx) {
|
|
|
33973
34378
|
d(detaching) {
|
|
33974
34379
|
if (if_block0) if_block0.d(detaching);
|
|
33975
34380
|
if (detaching) detach(t0);
|
|
33976
|
-
if (detaching) detach(h1);
|
|
33977
|
-
destroy_component(t1);
|
|
33978
|
-
if (detaching) detach(t2);
|
|
33979
|
-
if (detaching) detach(p);
|
|
33980
|
-
destroy_component(t3);
|
|
33981
|
-
/*p_binding*/ ctx[10](null);
|
|
33982
|
-
if (detaching) detach(t4);
|
|
33983
34381
|
if (if_block1) if_block1.d(detaching);
|
|
33984
|
-
if (detaching) detach(
|
|
34382
|
+
if (detaching) detach(t1);
|
|
33985
34383
|
destroy_each(each_blocks, detaching);
|
|
33986
|
-
if (detaching) detach(
|
|
34384
|
+
if (detaching) detach(t2);
|
|
33987
34385
|
if (if_block2) if_block2.d(detaching);
|
|
33988
34386
|
if (detaching) detach(if_block2_anchor);
|
|
33989
34387
|
}
|
|
@@ -33996,12 +34394,12 @@ function create_fragment$3(ctx) {
|
|
|
33996
34394
|
let current;
|
|
33997
34395
|
|
|
33998
34396
|
function form_1_formEl_binding(value) {
|
|
33999
|
-
/*form_1_formEl_binding*/ ctx[
|
|
34397
|
+
/*form_1_formEl_binding*/ ctx[12](value);
|
|
34000
34398
|
}
|
|
34001
34399
|
|
|
34002
34400
|
let form_1_props = {
|
|
34003
34401
|
ariaDescribedBy: "formFailureMessageAlert",
|
|
34004
|
-
onSubmitWhenValid: /*form*/ ctx[
|
|
34402
|
+
onSubmitWhenValid: /*form*/ ctx[2]?.submit,
|
|
34005
34403
|
$$slots: { default: [create_default_slot$3] },
|
|
34006
34404
|
$$scope: { ctx }
|
|
34007
34405
|
};
|
|
@@ -34023,9 +34421,9 @@ function create_fragment$3(ctx) {
|
|
|
34023
34421
|
},
|
|
34024
34422
|
p(ctx, [dirty]) {
|
|
34025
34423
|
const form_1_changes = {};
|
|
34026
|
-
if (dirty & /*form*/
|
|
34424
|
+
if (dirty & /*form*/ 4) form_1_changes.onSubmitWhenValid = /*form*/ ctx[2]?.submit;
|
|
34027
34425
|
|
|
34028
|
-
if (dirty & /*$$scope, journey, metadata, step, $styleStore, alertNeedsFocus, formMessageKey, form, linkWrapper*/
|
|
34426
|
+
if (dirty & /*$$scope, journey, metadata, step, $styleStore, alertNeedsFocus, formMessageKey, form, linkWrapper, componentStyle*/ 66558) {
|
|
34029
34427
|
form_1_changes.$$scope = { dirty, ctx };
|
|
34030
34428
|
}
|
|
34031
34429
|
|
|
@@ -34054,7 +34452,8 @@ function create_fragment$3(ctx) {
|
|
|
34054
34452
|
|
|
34055
34453
|
function instance$3($$self, $$props, $$invalidate) {
|
|
34056
34454
|
let $styleStore;
|
|
34057
|
-
component_subscribe($$self, styleStore, $$value => $$invalidate(
|
|
34455
|
+
component_subscribe($$self, styleStore, $$value => $$invalidate(9, $styleStore = $$value));
|
|
34456
|
+
let { componentStyle } = $$props;
|
|
34058
34457
|
let { form } = $$props;
|
|
34059
34458
|
let { formEl = null } = $$props;
|
|
34060
34459
|
let { journey } = $$props;
|
|
@@ -34074,15 +34473,25 @@ function instance$3($$self, $$props, $$invalidate) {
|
|
|
34074
34473
|
}
|
|
34075
34474
|
|
|
34076
34475
|
afterUpdate(() => {
|
|
34077
|
-
$$invalidate(
|
|
34476
|
+
$$invalidate(6, alertNeedsFocus = !!form?.message);
|
|
34078
34477
|
});
|
|
34079
34478
|
|
|
34080
|
-
onMount(() =>
|
|
34479
|
+
onMount(() => {
|
|
34480
|
+
if (componentStyle === 'modal') {
|
|
34481
|
+
captureLinks(linkWrapper, journey);
|
|
34482
|
+
}
|
|
34483
|
+
});
|
|
34484
|
+
|
|
34485
|
+
onMount(() => {
|
|
34486
|
+
if (componentStyle === 'modal') {
|
|
34487
|
+
captureLinks(linkWrapper, journey);
|
|
34488
|
+
}
|
|
34489
|
+
});
|
|
34081
34490
|
|
|
34082
34491
|
function p_binding($$value) {
|
|
34083
34492
|
binding_callbacks[$$value ? 'unshift' : 'push'](() => {
|
|
34084
34493
|
linkWrapper = $$value;
|
|
34085
|
-
$$invalidate(
|
|
34494
|
+
$$invalidate(8, linkWrapper);
|
|
34086
34495
|
});
|
|
34087
34496
|
}
|
|
34088
34497
|
|
|
@@ -34092,23 +34501,25 @@ function instance$3($$self, $$props, $$invalidate) {
|
|
|
34092
34501
|
}
|
|
34093
34502
|
|
|
34094
34503
|
$$self.$$set = $$props => {
|
|
34095
|
-
if ('
|
|
34504
|
+
if ('componentStyle' in $$props) $$invalidate(1, componentStyle = $$props.componentStyle);
|
|
34505
|
+
if ('form' in $$props) $$invalidate(2, form = $$props.form);
|
|
34096
34506
|
if ('formEl' in $$props) $$invalidate(0, formEl = $$props.formEl);
|
|
34097
|
-
if ('journey' in $$props) $$invalidate(
|
|
34098
|
-
if ('metadata' in $$props) $$invalidate(
|
|
34099
|
-
if ('step' in $$props) $$invalidate(
|
|
34507
|
+
if ('journey' in $$props) $$invalidate(3, journey = $$props.journey);
|
|
34508
|
+
if ('metadata' in $$props) $$invalidate(4, metadata = $$props.metadata);
|
|
34509
|
+
if ('step' in $$props) $$invalidate(5, step = $$props.step);
|
|
34100
34510
|
};
|
|
34101
34511
|
|
|
34102
34512
|
$$self.$$.update = () => {
|
|
34103
|
-
if ($$self.$$.dirty & /*form*/
|
|
34513
|
+
if ($$self.$$.dirty & /*form*/ 4) {
|
|
34104
34514
|
{
|
|
34105
|
-
$$invalidate(
|
|
34515
|
+
$$invalidate(7, formMessageKey = convertStringToKey(form?.message));
|
|
34106
34516
|
}
|
|
34107
34517
|
}
|
|
34108
34518
|
};
|
|
34109
34519
|
|
|
34110
34520
|
return [
|
|
34111
34521
|
formEl,
|
|
34522
|
+
componentStyle,
|
|
34112
34523
|
form,
|
|
34113
34524
|
journey,
|
|
34114
34525
|
metadata,
|
|
@@ -34128,11 +34539,12 @@ class Registration extends SvelteComponent {
|
|
|
34128
34539
|
super();
|
|
34129
34540
|
|
|
34130
34541
|
init(this, options, instance$3, create_fragment$3, safe_not_equal, {
|
|
34131
|
-
|
|
34542
|
+
componentStyle: 1,
|
|
34543
|
+
form: 2,
|
|
34132
34544
|
formEl: 0,
|
|
34133
|
-
journey:
|
|
34134
|
-
metadata:
|
|
34135
|
-
step:
|
|
34545
|
+
journey: 3,
|
|
34546
|
+
metadata: 4,
|
|
34547
|
+
step: 5
|
|
34136
34548
|
});
|
|
34137
34549
|
}
|
|
34138
34550
|
}
|
|
@@ -34141,13 +34553,79 @@ class Registration extends SvelteComponent {
|
|
|
34141
34553
|
|
|
34142
34554
|
function get_each_context(ctx, list, i) {
|
|
34143
34555
|
const child_ctx = ctx.slice();
|
|
34144
|
-
child_ctx[
|
|
34145
|
-
child_ctx[
|
|
34556
|
+
child_ctx[15] = list[i];
|
|
34557
|
+
child_ctx[17] = i;
|
|
34146
34558
|
return child_ctx;
|
|
34147
34559
|
}
|
|
34148
34560
|
|
|
34149
|
-
// (
|
|
34150
|
-
function
|
|
34561
|
+
// (45:2) {#if componentStyle !== 'inline'}
|
|
34562
|
+
function create_if_block_3$1(ctx) {
|
|
34563
|
+
let t0;
|
|
34564
|
+
let h1;
|
|
34565
|
+
let t1;
|
|
34566
|
+
let current;
|
|
34567
|
+
let if_block = /*form*/ ctx[2]?.icon && create_if_block_4();
|
|
34568
|
+
t1 = new Locale_strings({ props: { key: "loginHeader" } });
|
|
34569
|
+
|
|
34570
|
+
return {
|
|
34571
|
+
c() {
|
|
34572
|
+
if (if_block) if_block.c();
|
|
34573
|
+
t0 = space();
|
|
34574
|
+
h1 = element("h1");
|
|
34575
|
+
create_component(t1.$$.fragment);
|
|
34576
|
+
attr(h1, "class", "tw_primary-header dark:tw_primary-header_dark");
|
|
34577
|
+
},
|
|
34578
|
+
m(target, anchor) {
|
|
34579
|
+
if (if_block) if_block.m(target, anchor);
|
|
34580
|
+
insert(target, t0, anchor);
|
|
34581
|
+
insert(target, h1, anchor);
|
|
34582
|
+
mount_component(t1, h1, null);
|
|
34583
|
+
current = true;
|
|
34584
|
+
},
|
|
34585
|
+
p(ctx, dirty) {
|
|
34586
|
+
if (/*form*/ ctx[2]?.icon) {
|
|
34587
|
+
if (if_block) {
|
|
34588
|
+
if (dirty & /*form*/ 4) {
|
|
34589
|
+
transition_in(if_block, 1);
|
|
34590
|
+
}
|
|
34591
|
+
} else {
|
|
34592
|
+
if_block = create_if_block_4();
|
|
34593
|
+
if_block.c();
|
|
34594
|
+
transition_in(if_block, 1);
|
|
34595
|
+
if_block.m(t0.parentNode, t0);
|
|
34596
|
+
}
|
|
34597
|
+
} else if (if_block) {
|
|
34598
|
+
group_outros();
|
|
34599
|
+
|
|
34600
|
+
transition_out(if_block, 1, 1, () => {
|
|
34601
|
+
if_block = null;
|
|
34602
|
+
});
|
|
34603
|
+
|
|
34604
|
+
check_outros();
|
|
34605
|
+
}
|
|
34606
|
+
},
|
|
34607
|
+
i(local) {
|
|
34608
|
+
if (current) return;
|
|
34609
|
+
transition_in(if_block);
|
|
34610
|
+
transition_in(t1.$$.fragment, local);
|
|
34611
|
+
current = true;
|
|
34612
|
+
},
|
|
34613
|
+
o(local) {
|
|
34614
|
+
transition_out(if_block);
|
|
34615
|
+
transition_out(t1.$$.fragment, local);
|
|
34616
|
+
current = false;
|
|
34617
|
+
},
|
|
34618
|
+
d(detaching) {
|
|
34619
|
+
if (if_block) if_block.d(detaching);
|
|
34620
|
+
if (detaching) detach(t0);
|
|
34621
|
+
if (detaching) detach(h1);
|
|
34622
|
+
destroy_component(t1);
|
|
34623
|
+
}
|
|
34624
|
+
};
|
|
34625
|
+
}
|
|
34626
|
+
|
|
34627
|
+
// (46:4) {#if form?.icon}
|
|
34628
|
+
function create_if_block_4(ctx) {
|
|
34151
34629
|
let div;
|
|
34152
34630
|
let keyicon;
|
|
34153
34631
|
let current;
|
|
@@ -34186,15 +34664,15 @@ function create_if_block_2$1(ctx) {
|
|
|
34186
34664
|
};
|
|
34187
34665
|
}
|
|
34188
34666
|
|
|
34189
|
-
// (
|
|
34190
|
-
function
|
|
34667
|
+
// (56:2) {#if form?.message}
|
|
34668
|
+
function create_if_block_2$1(ctx) {
|
|
34191
34669
|
let alert;
|
|
34192
34670
|
let current;
|
|
34193
34671
|
|
|
34194
34672
|
alert = new Alert({
|
|
34195
34673
|
props: {
|
|
34196
34674
|
id: "formFailureMessageAlert",
|
|
34197
|
-
needsFocus: /*alertNeedsFocus*/ ctx[
|
|
34675
|
+
needsFocus: /*alertNeedsFocus*/ ctx[6],
|
|
34198
34676
|
type: "error",
|
|
34199
34677
|
$$slots: { default: [create_default_slot_2] },
|
|
34200
34678
|
$$scope: { ctx }
|
|
@@ -34211,9 +34689,9 @@ function create_if_block_1$1(ctx) {
|
|
|
34211
34689
|
},
|
|
34212
34690
|
p(ctx, dirty) {
|
|
34213
34691
|
const alert_changes = {};
|
|
34214
|
-
if (dirty & /*alertNeedsFocus*/
|
|
34692
|
+
if (dirty & /*alertNeedsFocus*/ 64) alert_changes.needsFocus = /*alertNeedsFocus*/ ctx[6];
|
|
34215
34693
|
|
|
34216
|
-
if (dirty & /*$$scope, formMessageKey, form*/
|
|
34694
|
+
if (dirty & /*$$scope, formMessageKey, form*/ 262276) {
|
|
34217
34695
|
alert_changes.$$scope = { dirty, ctx };
|
|
34218
34696
|
}
|
|
34219
34697
|
|
|
@@ -34234,9 +34712,9 @@ function create_if_block_1$1(ctx) {
|
|
|
34234
34712
|
};
|
|
34235
34713
|
}
|
|
34236
34714
|
|
|
34237
|
-
// (
|
|
34715
|
+
// (57:4) <Alert id="formFailureMessageAlert" needsFocus={alertNeedsFocus} type="error">
|
|
34238
34716
|
function create_default_slot_2(ctx) {
|
|
34239
|
-
let t_value = interpolate(/*formMessageKey*/ ctx[
|
|
34717
|
+
let t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "";
|
|
34240
34718
|
let t;
|
|
34241
34719
|
|
|
34242
34720
|
return {
|
|
@@ -34247,7 +34725,7 @@ function create_default_slot_2(ctx) {
|
|
|
34247
34725
|
insert(target, t, anchor);
|
|
34248
34726
|
},
|
|
34249
34727
|
p(ctx, dirty) {
|
|
34250
|
-
if (dirty & /*formMessageKey, form*/
|
|
34728
|
+
if (dirty & /*formMessageKey, form*/ 132 && t_value !== (t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "")) set_data(t, t_value);
|
|
34251
34729
|
},
|
|
34252
34730
|
d(detaching) {
|
|
34253
34731
|
if (detaching) detach(t);
|
|
@@ -34255,7 +34733,7 @@ function create_default_slot_2(ctx) {
|
|
|
34255
34733
|
};
|
|
34256
34734
|
}
|
|
34257
34735
|
|
|
34258
|
-
// (
|
|
34736
|
+
// (62:2) {#each step?.callbacks as callback, idx}
|
|
34259
34737
|
function create_each_block(ctx) {
|
|
34260
34738
|
let callbackmapper;
|
|
34261
34739
|
let current;
|
|
@@ -34263,11 +34741,11 @@ function create_each_block(ctx) {
|
|
|
34263
34741
|
callbackmapper = new Callback_mapper({
|
|
34264
34742
|
props: {
|
|
34265
34743
|
props: {
|
|
34266
|
-
callback: /*callback*/ ctx[
|
|
34267
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
34268
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
34269
|
-
stepMetadata: /*metadata*/ ctx[
|
|
34270
|
-
style: /*$styleStore*/ ctx[
|
|
34744
|
+
callback: /*callback*/ ctx[15],
|
|
34745
|
+
callbackMetadata: /*metadata*/ ctx[4]?.callbacks[/*idx*/ ctx[17]],
|
|
34746
|
+
selfSubmitFunction: /*determineSubmission*/ ctx[10],
|
|
34747
|
+
stepMetadata: /*metadata*/ ctx[4]?.step && { .../*metadata*/ ctx[4].step },
|
|
34748
|
+
style: /*$styleStore*/ ctx[9]
|
|
34271
34749
|
}
|
|
34272
34750
|
}
|
|
34273
34751
|
});
|
|
@@ -34283,12 +34761,12 @@ function create_each_block(ctx) {
|
|
|
34283
34761
|
p(ctx, dirty) {
|
|
34284
34762
|
const callbackmapper_changes = {};
|
|
34285
34763
|
|
|
34286
|
-
if (dirty & /*step, metadata, $styleStore*/
|
|
34287
|
-
callback: /*callback*/ ctx[
|
|
34288
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
34289
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
34290
|
-
stepMetadata: /*metadata*/ ctx[
|
|
34291
|
-
style: /*$styleStore*/ ctx[
|
|
34764
|
+
if (dirty & /*step, metadata, $styleStore*/ 560) callbackmapper_changes.props = {
|
|
34765
|
+
callback: /*callback*/ ctx[15],
|
|
34766
|
+
callbackMetadata: /*metadata*/ ctx[4]?.callbacks[/*idx*/ ctx[17]],
|
|
34767
|
+
selfSubmitFunction: /*determineSubmission*/ ctx[10],
|
|
34768
|
+
stepMetadata: /*metadata*/ ctx[4]?.step && { .../*metadata*/ ctx[4].step },
|
|
34769
|
+
style: /*$styleStore*/ ctx[9]
|
|
34292
34770
|
};
|
|
34293
34771
|
|
|
34294
34772
|
callbackmapper.$set(callbackmapper_changes);
|
|
@@ -34308,14 +34786,14 @@ function create_each_block(ctx) {
|
|
|
34308
34786
|
};
|
|
34309
34787
|
}
|
|
34310
34788
|
|
|
34311
|
-
// (
|
|
34312
|
-
function
|
|
34789
|
+
// (74:2) {#if metadata?.step?.derived.isUserInputOptional || !metadata?.step?.derived.isStepSelfSubmittable}
|
|
34790
|
+
function create_if_block_1$1(ctx) {
|
|
34313
34791
|
let button;
|
|
34314
34792
|
let current;
|
|
34315
34793
|
|
|
34316
34794
|
button = new Button({
|
|
34317
34795
|
props: {
|
|
34318
|
-
busy: /*journey*/ ctx[
|
|
34796
|
+
busy: /*journey*/ ctx[3]?.loading,
|
|
34319
34797
|
style: "primary",
|
|
34320
34798
|
type: "submit",
|
|
34321
34799
|
width: "full",
|
|
@@ -34334,9 +34812,9 @@ function create_if_block$2(ctx) {
|
|
|
34334
34812
|
},
|
|
34335
34813
|
p(ctx, dirty) {
|
|
34336
34814
|
const button_changes = {};
|
|
34337
|
-
if (dirty & /*journey*/
|
|
34815
|
+
if (dirty & /*journey*/ 8) button_changes.busy = /*journey*/ ctx[3]?.loading;
|
|
34338
34816
|
|
|
34339
|
-
if (dirty & /*$$scope*/
|
|
34817
|
+
if (dirty & /*$$scope*/ 262144) {
|
|
34340
34818
|
button_changes.$$scope = { dirty, ctx };
|
|
34341
34819
|
}
|
|
34342
34820
|
|
|
@@ -34357,7 +34835,7 @@ function create_if_block$2(ctx) {
|
|
|
34357
34835
|
};
|
|
34358
34836
|
}
|
|
34359
34837
|
|
|
34360
|
-
// (
|
|
34838
|
+
// (75:4) <Button busy={journey?.loading} style="primary" type="submit" width="full">
|
|
34361
34839
|
function create_default_slot_1$1(ctx) {
|
|
34362
34840
|
let t;
|
|
34363
34841
|
let current;
|
|
@@ -34387,31 +34865,99 @@ function create_default_slot_1$1(ctx) {
|
|
|
34387
34865
|
};
|
|
34388
34866
|
}
|
|
34389
34867
|
|
|
34390
|
-
// (
|
|
34391
|
-
function
|
|
34392
|
-
let t0;
|
|
34393
|
-
let h1;
|
|
34394
|
-
let t1;
|
|
34395
|
-
let t2;
|
|
34396
|
-
let t3;
|
|
34397
|
-
let t4;
|
|
34398
|
-
let t5;
|
|
34868
|
+
// (80:2) {#if componentStyle !== 'inline'}
|
|
34869
|
+
function create_if_block$2(ctx) {
|
|
34399
34870
|
let p0;
|
|
34400
34871
|
let button0;
|
|
34401
|
-
let
|
|
34872
|
+
let t1;
|
|
34402
34873
|
let button1;
|
|
34403
|
-
let
|
|
34874
|
+
let t3;
|
|
34404
34875
|
let hr;
|
|
34405
|
-
let
|
|
34876
|
+
let t4;
|
|
34406
34877
|
let p1;
|
|
34407
|
-
let
|
|
34878
|
+
let t5;
|
|
34408
34879
|
let current;
|
|
34409
34880
|
let mounted;
|
|
34410
34881
|
let dispose;
|
|
34411
|
-
|
|
34412
|
-
|
|
34413
|
-
|
|
34414
|
-
|
|
34882
|
+
|
|
34883
|
+
t5 = new Locale_strings({
|
|
34884
|
+
props: { key: "dontHaveAnAccount", html: true }
|
|
34885
|
+
});
|
|
34886
|
+
|
|
34887
|
+
return {
|
|
34888
|
+
c() {
|
|
34889
|
+
p0 = element("p");
|
|
34890
|
+
button0 = element("button");
|
|
34891
|
+
button0.textContent = `${interpolate('forgotPassword', null, 'Forgot Password?')}`;
|
|
34892
|
+
t1 = text("\n \n ");
|
|
34893
|
+
button1 = element("button");
|
|
34894
|
+
button1.textContent = `${interpolate('forgotUsername', null, 'Forgot Username?')}`;
|
|
34895
|
+
t3 = space();
|
|
34896
|
+
hr = element("hr");
|
|
34897
|
+
t4 = space();
|
|
34898
|
+
p1 = element("p");
|
|
34899
|
+
create_component(t5.$$.fragment);
|
|
34900
|
+
attr(p0, "class", "tw_my-4 tw_text-base tw_text-center tw_text-link-dark dark:tw_text-link-light");
|
|
34901
|
+
attr(hr, "class", "tw_border-0 tw_border-b tw_border-secondary-light dark:tw_border-secondary-dark");
|
|
34902
|
+
attr(p1, "class", "tw_text-base tw_text-center tw_py-4 tw_text-secondary-dark dark:tw_text-secondary-light");
|
|
34903
|
+
},
|
|
34904
|
+
m(target, anchor) {
|
|
34905
|
+
insert(target, p0, anchor);
|
|
34906
|
+
append(p0, button0);
|
|
34907
|
+
append(p0, t1);
|
|
34908
|
+
append(p0, button1);
|
|
34909
|
+
insert(target, t3, anchor);
|
|
34910
|
+
insert(target, hr, anchor);
|
|
34911
|
+
insert(target, t4, anchor);
|
|
34912
|
+
insert(target, p1, anchor);
|
|
34913
|
+
mount_component(t5, p1, null);
|
|
34914
|
+
/*p1_binding*/ ctx[13](p1);
|
|
34915
|
+
current = true;
|
|
34916
|
+
|
|
34917
|
+
if (!mounted) {
|
|
34918
|
+
dispose = [
|
|
34919
|
+
listen(button0, "click", prevent_default(/*click_handler*/ ctx[11])),
|
|
34920
|
+
listen(button1, "click", prevent_default(/*click_handler_1*/ ctx[12]))
|
|
34921
|
+
];
|
|
34922
|
+
|
|
34923
|
+
mounted = true;
|
|
34924
|
+
}
|
|
34925
|
+
},
|
|
34926
|
+
p: noop,
|
|
34927
|
+
i(local) {
|
|
34928
|
+
if (current) return;
|
|
34929
|
+
transition_in(t5.$$.fragment, local);
|
|
34930
|
+
current = true;
|
|
34931
|
+
},
|
|
34932
|
+
o(local) {
|
|
34933
|
+
transition_out(t5.$$.fragment, local);
|
|
34934
|
+
current = false;
|
|
34935
|
+
},
|
|
34936
|
+
d(detaching) {
|
|
34937
|
+
if (detaching) detach(p0);
|
|
34938
|
+
if (detaching) detach(t3);
|
|
34939
|
+
if (detaching) detach(hr);
|
|
34940
|
+
if (detaching) detach(t4);
|
|
34941
|
+
if (detaching) detach(p1);
|
|
34942
|
+
destroy_component(t5);
|
|
34943
|
+
/*p1_binding*/ ctx[13](null);
|
|
34944
|
+
mounted = false;
|
|
34945
|
+
run_all(dispose);
|
|
34946
|
+
}
|
|
34947
|
+
};
|
|
34948
|
+
}
|
|
34949
|
+
|
|
34950
|
+
// (44:0) <Form bind:formEl ariaDescribedBy="formFailureMessageAlert" onSubmitWhenValid={form?.submit}>
|
|
34951
|
+
function create_default_slot$2(ctx) {
|
|
34952
|
+
let t0;
|
|
34953
|
+
let t1;
|
|
34954
|
+
let t2;
|
|
34955
|
+
let t3;
|
|
34956
|
+
let if_block3_anchor;
|
|
34957
|
+
let current;
|
|
34958
|
+
let if_block0 = /*componentStyle*/ ctx[1] !== 'inline' && create_if_block_3$1(ctx);
|
|
34959
|
+
let if_block1 = /*form*/ ctx[2]?.message && create_if_block_2$1(ctx);
|
|
34960
|
+
let each_value = /*step*/ ctx[5]?.callbacks;
|
|
34415
34961
|
let each_blocks = [];
|
|
34416
34962
|
|
|
34417
34963
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -34422,90 +34968,53 @@ function create_default_slot$2(ctx) {
|
|
|
34422
34968
|
each_blocks[i] = null;
|
|
34423
34969
|
});
|
|
34424
34970
|
|
|
34425
|
-
let if_block2 = (/*metadata*/ ctx[
|
|
34426
|
-
|
|
34427
|
-
t11 = new Locale_strings({
|
|
34428
|
-
props: { key: "dontHaveAnAccount", html: true }
|
|
34429
|
-
});
|
|
34971
|
+
let if_block2 = (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) && create_if_block_1$1(ctx);
|
|
34972
|
+
let if_block3 = /*componentStyle*/ ctx[1] !== 'inline' && create_if_block$2(ctx);
|
|
34430
34973
|
|
|
34431
34974
|
return {
|
|
34432
34975
|
c() {
|
|
34433
34976
|
if (if_block0) if_block0.c();
|
|
34434
34977
|
t0 = space();
|
|
34435
|
-
h1 = element("h1");
|
|
34436
|
-
create_component(t1.$$.fragment);
|
|
34437
|
-
t2 = space();
|
|
34438
34978
|
if (if_block1) if_block1.c();
|
|
34439
|
-
|
|
34979
|
+
t1 = space();
|
|
34440
34980
|
|
|
34441
34981
|
for (let i = 0; i < each_blocks.length; i += 1) {
|
|
34442
34982
|
each_blocks[i].c();
|
|
34443
34983
|
}
|
|
34444
34984
|
|
|
34445
|
-
|
|
34985
|
+
t2 = space();
|
|
34446
34986
|
if (if_block2) if_block2.c();
|
|
34447
|
-
|
|
34448
|
-
|
|
34449
|
-
|
|
34450
|
-
button0.textContent = `${interpolate('forgotPassword', null, 'Forgot Password?')}`;
|
|
34451
|
-
t7 = text("\n \n ");
|
|
34452
|
-
button1 = element("button");
|
|
34453
|
-
button1.textContent = `${interpolate('forgotUsername', null, 'Forgot Username?')}`;
|
|
34454
|
-
t9 = space();
|
|
34455
|
-
hr = element("hr");
|
|
34456
|
-
t10 = space();
|
|
34457
|
-
p1 = element("p");
|
|
34458
|
-
create_component(t11.$$.fragment);
|
|
34459
|
-
attr(h1, "class", "tw_primary-header dark:tw_primary-header_dark");
|
|
34460
|
-
attr(p0, "class", "tw_my-4 tw_text-base tw_text-center tw_text-link-dark dark:tw_text-link-light");
|
|
34461
|
-
attr(hr, "class", "tw_border-0 tw_border-b tw_border-secondary-light dark:tw_border-secondary-dark");
|
|
34462
|
-
attr(p1, "class", "tw_text-base tw_text-center tw_py-4 tw_text-secondary-dark dark:tw_text-secondary-light");
|
|
34987
|
+
t3 = space();
|
|
34988
|
+
if (if_block3) if_block3.c();
|
|
34989
|
+
if_block3_anchor = empty();
|
|
34463
34990
|
},
|
|
34464
34991
|
m(target, anchor) {
|
|
34465
34992
|
if (if_block0) if_block0.m(target, anchor);
|
|
34466
34993
|
insert(target, t0, anchor);
|
|
34467
|
-
insert(target, h1, anchor);
|
|
34468
|
-
mount_component(t1, h1, null);
|
|
34469
|
-
insert(target, t2, anchor);
|
|
34470
34994
|
if (if_block1) if_block1.m(target, anchor);
|
|
34471
|
-
insert(target,
|
|
34995
|
+
insert(target, t1, anchor);
|
|
34472
34996
|
|
|
34473
34997
|
for (let i = 0; i < each_blocks.length; i += 1) {
|
|
34474
34998
|
each_blocks[i].m(target, anchor);
|
|
34475
34999
|
}
|
|
34476
35000
|
|
|
34477
|
-
insert(target,
|
|
35001
|
+
insert(target, t2, anchor);
|
|
34478
35002
|
if (if_block2) if_block2.m(target, anchor);
|
|
34479
|
-
insert(target,
|
|
34480
|
-
|
|
34481
|
-
|
|
34482
|
-
append(p0, t7);
|
|
34483
|
-
append(p0, button1);
|
|
34484
|
-
insert(target, t9, anchor);
|
|
34485
|
-
insert(target, hr, anchor);
|
|
34486
|
-
insert(target, t10, anchor);
|
|
34487
|
-
insert(target, p1, anchor);
|
|
34488
|
-
mount_component(t11, p1, null);
|
|
34489
|
-
/*p1_binding*/ ctx[12](p1);
|
|
35003
|
+
insert(target, t3, anchor);
|
|
35004
|
+
if (if_block3) if_block3.m(target, anchor);
|
|
35005
|
+
insert(target, if_block3_anchor, anchor);
|
|
34490
35006
|
current = true;
|
|
34491
|
-
|
|
34492
|
-
if (!mounted) {
|
|
34493
|
-
dispose = [
|
|
34494
|
-
listen(button0, "click", prevent_default(/*click_handler*/ ctx[10])),
|
|
34495
|
-
listen(button1, "click", prevent_default(/*click_handler_1*/ ctx[11]))
|
|
34496
|
-
];
|
|
34497
|
-
|
|
34498
|
-
mounted = true;
|
|
34499
|
-
}
|
|
34500
35007
|
},
|
|
34501
35008
|
p(ctx, dirty) {
|
|
34502
|
-
if (/*
|
|
35009
|
+
if (/*componentStyle*/ ctx[1] !== 'inline') {
|
|
34503
35010
|
if (if_block0) {
|
|
34504
|
-
|
|
35011
|
+
if_block0.p(ctx, dirty);
|
|
35012
|
+
|
|
35013
|
+
if (dirty & /*componentStyle*/ 2) {
|
|
34505
35014
|
transition_in(if_block0, 1);
|
|
34506
35015
|
}
|
|
34507
35016
|
} else {
|
|
34508
|
-
if_block0 =
|
|
35017
|
+
if_block0 = create_if_block_3$1(ctx);
|
|
34509
35018
|
if_block0.c();
|
|
34510
35019
|
transition_in(if_block0, 1);
|
|
34511
35020
|
if_block0.m(t0.parentNode, t0);
|
|
@@ -34520,18 +35029,18 @@ function create_default_slot$2(ctx) {
|
|
|
34520
35029
|
check_outros();
|
|
34521
35030
|
}
|
|
34522
35031
|
|
|
34523
|
-
if (/*form*/ ctx[
|
|
35032
|
+
if (/*form*/ ctx[2]?.message) {
|
|
34524
35033
|
if (if_block1) {
|
|
34525
35034
|
if_block1.p(ctx, dirty);
|
|
34526
35035
|
|
|
34527
|
-
if (dirty & /*form*/
|
|
35036
|
+
if (dirty & /*form*/ 4) {
|
|
34528
35037
|
transition_in(if_block1, 1);
|
|
34529
35038
|
}
|
|
34530
35039
|
} else {
|
|
34531
|
-
if_block1 =
|
|
35040
|
+
if_block1 = create_if_block_2$1(ctx);
|
|
34532
35041
|
if_block1.c();
|
|
34533
35042
|
transition_in(if_block1, 1);
|
|
34534
|
-
if_block1.m(
|
|
35043
|
+
if_block1.m(t1.parentNode, t1);
|
|
34535
35044
|
}
|
|
34536
35045
|
} else if (if_block1) {
|
|
34537
35046
|
group_outros();
|
|
@@ -34543,8 +35052,8 @@ function create_default_slot$2(ctx) {
|
|
|
34543
35052
|
check_outros();
|
|
34544
35053
|
}
|
|
34545
35054
|
|
|
34546
|
-
if (dirty & /*step, metadata, determineSubmission, $styleStore*/
|
|
34547
|
-
each_value = /*step*/ ctx[
|
|
35055
|
+
if (dirty & /*step, metadata, determineSubmission, $styleStore*/ 1584) {
|
|
35056
|
+
each_value = /*step*/ ctx[5]?.callbacks;
|
|
34548
35057
|
let i;
|
|
34549
35058
|
|
|
34550
35059
|
for (i = 0; i < each_value.length; i += 1) {
|
|
@@ -34557,7 +35066,7 @@ function create_default_slot$2(ctx) {
|
|
|
34557
35066
|
each_blocks[i] = create_each_block(child_ctx);
|
|
34558
35067
|
each_blocks[i].c();
|
|
34559
35068
|
transition_in(each_blocks[i], 1);
|
|
34560
|
-
each_blocks[i].m(
|
|
35069
|
+
each_blocks[i].m(t2.parentNode, t2);
|
|
34561
35070
|
}
|
|
34562
35071
|
}
|
|
34563
35072
|
|
|
@@ -34570,18 +35079,18 @@ function create_default_slot$2(ctx) {
|
|
|
34570
35079
|
check_outros();
|
|
34571
35080
|
}
|
|
34572
35081
|
|
|
34573
|
-
if (/*metadata*/ ctx[
|
|
35082
|
+
if (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) {
|
|
34574
35083
|
if (if_block2) {
|
|
34575
35084
|
if_block2.p(ctx, dirty);
|
|
34576
35085
|
|
|
34577
|
-
if (dirty & /*metadata*/
|
|
35086
|
+
if (dirty & /*metadata*/ 16) {
|
|
34578
35087
|
transition_in(if_block2, 1);
|
|
34579
35088
|
}
|
|
34580
35089
|
} else {
|
|
34581
|
-
if_block2 =
|
|
35090
|
+
if_block2 = create_if_block_1$1(ctx);
|
|
34582
35091
|
if_block2.c();
|
|
34583
35092
|
transition_in(if_block2, 1);
|
|
34584
|
-
if_block2.m(
|
|
35093
|
+
if_block2.m(t3.parentNode, t3);
|
|
34585
35094
|
}
|
|
34586
35095
|
} else if (if_block2) {
|
|
34587
35096
|
group_outros();
|
|
@@ -34592,11 +35101,33 @@ function create_default_slot$2(ctx) {
|
|
|
34592
35101
|
|
|
34593
35102
|
check_outros();
|
|
34594
35103
|
}
|
|
35104
|
+
|
|
35105
|
+
if (/*componentStyle*/ ctx[1] !== 'inline') {
|
|
35106
|
+
if (if_block3) {
|
|
35107
|
+
if_block3.p(ctx, dirty);
|
|
35108
|
+
|
|
35109
|
+
if (dirty & /*componentStyle*/ 2) {
|
|
35110
|
+
transition_in(if_block3, 1);
|
|
35111
|
+
}
|
|
35112
|
+
} else {
|
|
35113
|
+
if_block3 = create_if_block$2(ctx);
|
|
35114
|
+
if_block3.c();
|
|
35115
|
+
transition_in(if_block3, 1);
|
|
35116
|
+
if_block3.m(if_block3_anchor.parentNode, if_block3_anchor);
|
|
35117
|
+
}
|
|
35118
|
+
} else if (if_block3) {
|
|
35119
|
+
group_outros();
|
|
35120
|
+
|
|
35121
|
+
transition_out(if_block3, 1, 1, () => {
|
|
35122
|
+
if_block3 = null;
|
|
35123
|
+
});
|
|
35124
|
+
|
|
35125
|
+
check_outros();
|
|
35126
|
+
}
|
|
34595
35127
|
},
|
|
34596
35128
|
i(local) {
|
|
34597
35129
|
if (current) return;
|
|
34598
35130
|
transition_in(if_block0);
|
|
34599
|
-
transition_in(t1.$$.fragment, local);
|
|
34600
35131
|
transition_in(if_block1);
|
|
34601
35132
|
|
|
34602
35133
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -34604,12 +35135,11 @@ function create_default_slot$2(ctx) {
|
|
|
34604
35135
|
}
|
|
34605
35136
|
|
|
34606
35137
|
transition_in(if_block2);
|
|
34607
|
-
transition_in(
|
|
35138
|
+
transition_in(if_block3);
|
|
34608
35139
|
current = true;
|
|
34609
35140
|
},
|
|
34610
35141
|
o(local) {
|
|
34611
35142
|
transition_out(if_block0);
|
|
34612
|
-
transition_out(t1.$$.fragment, local);
|
|
34613
35143
|
transition_out(if_block1);
|
|
34614
35144
|
each_blocks = each_blocks.filter(Boolean);
|
|
34615
35145
|
|
|
@@ -34618,30 +35148,20 @@ function create_default_slot$2(ctx) {
|
|
|
34618
35148
|
}
|
|
34619
35149
|
|
|
34620
35150
|
transition_out(if_block2);
|
|
34621
|
-
transition_out(
|
|
35151
|
+
transition_out(if_block3);
|
|
34622
35152
|
current = false;
|
|
34623
35153
|
},
|
|
34624
35154
|
d(detaching) {
|
|
34625
35155
|
if (if_block0) if_block0.d(detaching);
|
|
34626
35156
|
if (detaching) detach(t0);
|
|
34627
|
-
if (detaching) detach(h1);
|
|
34628
|
-
destroy_component(t1);
|
|
34629
|
-
if (detaching) detach(t2);
|
|
34630
35157
|
if (if_block1) if_block1.d(detaching);
|
|
34631
|
-
if (detaching) detach(
|
|
35158
|
+
if (detaching) detach(t1);
|
|
34632
35159
|
destroy_each(each_blocks, detaching);
|
|
34633
|
-
if (detaching) detach(
|
|
35160
|
+
if (detaching) detach(t2);
|
|
34634
35161
|
if (if_block2) if_block2.d(detaching);
|
|
34635
|
-
if (detaching) detach(
|
|
34636
|
-
if (
|
|
34637
|
-
if (detaching) detach(
|
|
34638
|
-
if (detaching) detach(hr);
|
|
34639
|
-
if (detaching) detach(t10);
|
|
34640
|
-
if (detaching) detach(p1);
|
|
34641
|
-
destroy_component(t11);
|
|
34642
|
-
/*p1_binding*/ ctx[12](null);
|
|
34643
|
-
mounted = false;
|
|
34644
|
-
run_all(dispose);
|
|
35162
|
+
if (detaching) detach(t3);
|
|
35163
|
+
if (if_block3) if_block3.d(detaching);
|
|
35164
|
+
if (detaching) detach(if_block3_anchor);
|
|
34645
35165
|
}
|
|
34646
35166
|
};
|
|
34647
35167
|
}
|
|
@@ -34652,12 +35172,12 @@ function create_fragment$2(ctx) {
|
|
|
34652
35172
|
let current;
|
|
34653
35173
|
|
|
34654
35174
|
function form_1_formEl_binding(value) {
|
|
34655
|
-
/*form_1_formEl_binding*/ ctx[
|
|
35175
|
+
/*form_1_formEl_binding*/ ctx[14](value);
|
|
34656
35176
|
}
|
|
34657
35177
|
|
|
34658
35178
|
let form_1_props = {
|
|
34659
35179
|
ariaDescribedBy: "formFailureMessageAlert",
|
|
34660
|
-
onSubmitWhenValid: /*form*/ ctx[
|
|
35180
|
+
onSubmitWhenValid: /*form*/ ctx[2]?.submit,
|
|
34661
35181
|
$$slots: { default: [create_default_slot$2] },
|
|
34662
35182
|
$$scope: { ctx }
|
|
34663
35183
|
};
|
|
@@ -34679,9 +35199,9 @@ function create_fragment$2(ctx) {
|
|
|
34679
35199
|
},
|
|
34680
35200
|
p(ctx, [dirty]) {
|
|
34681
35201
|
const form_1_changes = {};
|
|
34682
|
-
if (dirty & /*form*/
|
|
35202
|
+
if (dirty & /*form*/ 4) form_1_changes.onSubmitWhenValid = /*form*/ ctx[2]?.submit;
|
|
34683
35203
|
|
|
34684
|
-
if (dirty & /*$$scope, linkWrapper, journey, metadata, step, $styleStore, alertNeedsFocus, formMessageKey, form*/
|
|
35204
|
+
if (dirty & /*$$scope, linkWrapper, journey, componentStyle, metadata, step, $styleStore, alertNeedsFocus, formMessageKey, form*/ 263166) {
|
|
34685
35205
|
form_1_changes.$$scope = { dirty, ctx };
|
|
34686
35206
|
}
|
|
34687
35207
|
|
|
@@ -34710,7 +35230,8 @@ function create_fragment$2(ctx) {
|
|
|
34710
35230
|
|
|
34711
35231
|
function instance$2($$self, $$props, $$invalidate) {
|
|
34712
35232
|
let $styleStore;
|
|
34713
|
-
component_subscribe($$self, styleStore, $$value => $$invalidate(
|
|
35233
|
+
component_subscribe($$self, styleStore, $$value => $$invalidate(9, $styleStore = $$value));
|
|
35234
|
+
let { componentStyle } = $$props;
|
|
34714
35235
|
let { form } = $$props;
|
|
34715
35236
|
let { formEl = null } = $$props;
|
|
34716
35237
|
let { journey } = $$props;
|
|
@@ -34730,10 +35251,14 @@ function instance$2($$self, $$props, $$invalidate) {
|
|
|
34730
35251
|
}
|
|
34731
35252
|
|
|
34732
35253
|
afterUpdate(() => {
|
|
34733
|
-
$$invalidate(
|
|
35254
|
+
$$invalidate(6, alertNeedsFocus = !!form?.message);
|
|
34734
35255
|
});
|
|
34735
35256
|
|
|
34736
|
-
onMount(() =>
|
|
35257
|
+
onMount(() => {
|
|
35258
|
+
if (componentStyle === 'modal') {
|
|
35259
|
+
captureLinks(linkWrapper, journey);
|
|
35260
|
+
}
|
|
35261
|
+
});
|
|
34737
35262
|
|
|
34738
35263
|
const click_handler = () => {
|
|
34739
35264
|
journey.push({ tree: 'ResetPassword' });
|
|
@@ -34746,7 +35271,7 @@ function instance$2($$self, $$props, $$invalidate) {
|
|
|
34746
35271
|
function p1_binding($$value) {
|
|
34747
35272
|
binding_callbacks[$$value ? 'unshift' : 'push'](() => {
|
|
34748
35273
|
linkWrapper = $$value;
|
|
34749
|
-
$$invalidate(
|
|
35274
|
+
$$invalidate(8, linkWrapper);
|
|
34750
35275
|
});
|
|
34751
35276
|
}
|
|
34752
35277
|
|
|
@@ -34756,23 +35281,25 @@ function instance$2($$self, $$props, $$invalidate) {
|
|
|
34756
35281
|
}
|
|
34757
35282
|
|
|
34758
35283
|
$$self.$$set = $$props => {
|
|
34759
|
-
if ('
|
|
35284
|
+
if ('componentStyle' in $$props) $$invalidate(1, componentStyle = $$props.componentStyle);
|
|
35285
|
+
if ('form' in $$props) $$invalidate(2, form = $$props.form);
|
|
34760
35286
|
if ('formEl' in $$props) $$invalidate(0, formEl = $$props.formEl);
|
|
34761
|
-
if ('journey' in $$props) $$invalidate(
|
|
34762
|
-
if ('metadata' in $$props) $$invalidate(
|
|
34763
|
-
if ('step' in $$props) $$invalidate(
|
|
35287
|
+
if ('journey' in $$props) $$invalidate(3, journey = $$props.journey);
|
|
35288
|
+
if ('metadata' in $$props) $$invalidate(4, metadata = $$props.metadata);
|
|
35289
|
+
if ('step' in $$props) $$invalidate(5, step = $$props.step);
|
|
34764
35290
|
};
|
|
34765
35291
|
|
|
34766
35292
|
$$self.$$.update = () => {
|
|
34767
|
-
if ($$self.$$.dirty & /*form*/
|
|
35293
|
+
if ($$self.$$.dirty & /*form*/ 4) {
|
|
34768
35294
|
{
|
|
34769
|
-
$$invalidate(
|
|
35295
|
+
$$invalidate(7, formMessageKey = convertStringToKey(form?.message));
|
|
34770
35296
|
}
|
|
34771
35297
|
}
|
|
34772
35298
|
};
|
|
34773
35299
|
|
|
34774
35300
|
return [
|
|
34775
35301
|
formEl,
|
|
35302
|
+
componentStyle,
|
|
34776
35303
|
form,
|
|
34777
35304
|
journey,
|
|
34778
35305
|
metadata,
|
|
@@ -34794,23 +35321,22 @@ class Login extends SvelteComponent {
|
|
|
34794
35321
|
super();
|
|
34795
35322
|
|
|
34796
35323
|
init(this, options, instance$2, create_fragment$2, safe_not_equal, {
|
|
34797
|
-
|
|
35324
|
+
componentStyle: 1,
|
|
35325
|
+
form: 2,
|
|
34798
35326
|
formEl: 0,
|
|
34799
|
-
journey:
|
|
34800
|
-
metadata:
|
|
34801
|
-
step:
|
|
35327
|
+
journey: 3,
|
|
35328
|
+
metadata: 4,
|
|
35329
|
+
step: 5
|
|
34802
35330
|
});
|
|
34803
35331
|
}
|
|
34804
35332
|
}
|
|
34805
35333
|
|
|
35334
|
+
/**
|
|
35335
|
+
* @function mapStepToStage - Maps the current step to the proper stage component.
|
|
35336
|
+
* @param {object} currentStep - The current step to check
|
|
35337
|
+
* @returns {object} - The stage Svelte component
|
|
35338
|
+
*/
|
|
34806
35339
|
function mapStepToStage(currentStep) {
|
|
34807
|
-
/** *********************************************************************
|
|
34808
|
-
* SDK INTEGRATION POINT
|
|
34809
|
-
* Summary:SDK step method for getting the stage value
|
|
34810
|
-
* ----------------------------------------------------------------------
|
|
34811
|
-
* Details: This method is helpful in quickly identifying the stage
|
|
34812
|
-
* when you want to provide special layout or handling of the form
|
|
34813
|
-
********************************************************************* */
|
|
34814
35340
|
if (!currentStep || currentStep.type !== 'Step') {
|
|
34815
35341
|
return Generic;
|
|
34816
35342
|
}
|
|
@@ -34837,7 +35363,7 @@ function create_else_block$1(ctx) {
|
|
|
34837
35363
|
alert = new Alert({
|
|
34838
35364
|
props: {
|
|
34839
35365
|
id: "unrecoverableStepError",
|
|
34840
|
-
needsFocus: /*alertNeedsFocus*/ ctx[
|
|
35366
|
+
needsFocus: /*alertNeedsFocus*/ ctx[4],
|
|
34841
35367
|
type: "error",
|
|
34842
35368
|
$$slots: { default: [create_default_slot_1] },
|
|
34843
35369
|
$$scope: { ctx }
|
|
@@ -34847,7 +35373,7 @@ function create_else_block$1(ctx) {
|
|
|
34847
35373
|
button = new Button({
|
|
34848
35374
|
props: {
|
|
34849
35375
|
style: "secondary",
|
|
34850
|
-
onClick: /*tryAgain*/ ctx[
|
|
35376
|
+
onClick: /*tryAgain*/ ctx[7],
|
|
34851
35377
|
$$slots: { default: [create_default_slot$1] },
|
|
34852
35378
|
$$scope: { ctx }
|
|
34853
35379
|
}
|
|
@@ -34867,16 +35393,16 @@ function create_else_block$1(ctx) {
|
|
|
34867
35393
|
},
|
|
34868
35394
|
p(ctx, dirty) {
|
|
34869
35395
|
const alert_changes = {};
|
|
34870
|
-
if (dirty & /*alertNeedsFocus*/
|
|
35396
|
+
if (dirty & /*alertNeedsFocus*/ 16) alert_changes.needsFocus = /*alertNeedsFocus*/ ctx[4];
|
|
34871
35397
|
|
|
34872
|
-
if (dirty & /*$$scope*/
|
|
35398
|
+
if (dirty & /*$$scope*/ 512) {
|
|
34873
35399
|
alert_changes.$$scope = { dirty, ctx };
|
|
34874
35400
|
}
|
|
34875
35401
|
|
|
34876
35402
|
alert.$set(alert_changes);
|
|
34877
35403
|
const button_changes = {};
|
|
34878
35404
|
|
|
34879
|
-
if (dirty & /*$$scope*/
|
|
35405
|
+
if (dirty & /*$$scope*/ 512) {
|
|
34880
35406
|
button_changes.$$scope = { dirty, ctx };
|
|
34881
35407
|
}
|
|
34882
35408
|
|
|
@@ -34901,7 +35427,7 @@ function create_else_block$1(ctx) {
|
|
|
34901
35427
|
};
|
|
34902
35428
|
}
|
|
34903
35429
|
|
|
34904
|
-
// (
|
|
35430
|
+
// (56:52)
|
|
34905
35431
|
function create_if_block_3(ctx) {
|
|
34906
35432
|
let div;
|
|
34907
35433
|
let spinner;
|
|
@@ -34942,7 +35468,7 @@ function create_if_block_3(ctx) {
|
|
|
34942
35468
|
};
|
|
34943
35469
|
}
|
|
34944
35470
|
|
|
34945
|
-
// (
|
|
35471
|
+
// (30:0) {#if $journeyStore && !$journeyStore.completed}
|
|
34946
35472
|
function create_if_block$1(ctx) {
|
|
34947
35473
|
let current_block_type_index;
|
|
34948
35474
|
let if_block;
|
|
@@ -34952,8 +35478,8 @@ function create_if_block$1(ctx) {
|
|
|
34952
35478
|
const if_blocks = [];
|
|
34953
35479
|
|
|
34954
35480
|
function select_block_type_1(ctx, dirty) {
|
|
34955
|
-
if (!/*$journeyStore*/ ctx[
|
|
34956
|
-
if (/*$journeyStore*/ ctx[
|
|
35481
|
+
if (/*$journeyStore*/ ctx[5] && !/*$journeyStore*/ ctx[5].step) return 0;
|
|
35482
|
+
if (/*$journeyStore*/ ctx[5].step?.type === StepType$1.Step) return 1;
|
|
34957
35483
|
return -1;
|
|
34958
35484
|
}
|
|
34959
35485
|
|
|
@@ -35029,7 +35555,7 @@ function create_if_block$1(ctx) {
|
|
|
35029
35555
|
};
|
|
35030
35556
|
}
|
|
35031
35557
|
|
|
35032
|
-
// (
|
|
35558
|
+
// (61:2) <Alert id="unrecoverableStepError" needsFocus={alertNeedsFocus} type="error">
|
|
35033
35559
|
function create_default_slot_1(ctx) {
|
|
35034
35560
|
let t;
|
|
35035
35561
|
let current;
|
|
@@ -35062,7 +35588,7 @@ function create_default_slot_1(ctx) {
|
|
|
35062
35588
|
};
|
|
35063
35589
|
}
|
|
35064
35590
|
|
|
35065
|
-
// (
|
|
35591
|
+
// (64:2) <Button style="secondary" onClick={tryAgain}>
|
|
35066
35592
|
function create_default_slot$1(ctx) {
|
|
35067
35593
|
let t;
|
|
35068
35594
|
let current;
|
|
@@ -35092,7 +35618,7 @@ function create_default_slot$1(ctx) {
|
|
|
35092
35618
|
};
|
|
35093
35619
|
}
|
|
35094
35620
|
|
|
35095
|
-
// (
|
|
35621
|
+
// (35:55)
|
|
35096
35622
|
function create_if_block_2(ctx) {
|
|
35097
35623
|
let switch_instance;
|
|
35098
35624
|
let updating_formEl;
|
|
@@ -35100,27 +35626,28 @@ function create_if_block_2(ctx) {
|
|
|
35100
35626
|
let current;
|
|
35101
35627
|
|
|
35102
35628
|
function switch_instance_formEl_binding(value) {
|
|
35103
|
-
/*switch_instance_formEl_binding*/ ctx[
|
|
35629
|
+
/*switch_instance_formEl_binding*/ ctx[8](value);
|
|
35104
35630
|
}
|
|
35105
35631
|
|
|
35106
|
-
var switch_value = mapStepToStage(/*$journeyStore*/ ctx[
|
|
35632
|
+
var switch_value = mapStepToStage(/*$journeyStore*/ ctx[5].step);
|
|
35107
35633
|
|
|
35108
35634
|
function switch_props(ctx) {
|
|
35109
35635
|
let switch_instance_props = {
|
|
35636
|
+
componentStyle: /*componentStyle*/ ctx[1],
|
|
35110
35637
|
form: {
|
|
35111
|
-
icon: /*displayIcon*/ ctx[
|
|
35112
|
-
message: /*$journeyStore*/ ctx[
|
|
35113
|
-
status: (/*$journeyStore*/ ctx[
|
|
35114
|
-
submit: /*submitForm*/ ctx[
|
|
35638
|
+
icon: /*displayIcon*/ ctx[2],
|
|
35639
|
+
message: /*$journeyStore*/ ctx[5].error?.message || '',
|
|
35640
|
+
status: (/*$journeyStore*/ ctx[5].error?.code) ? 'error' : 'ok',
|
|
35641
|
+
submit: /*submitForm*/ ctx[6]
|
|
35115
35642
|
},
|
|
35116
35643
|
journey: {
|
|
35117
|
-
loading: /*$journeyStore*/ ctx[
|
|
35118
|
-
pop: /*journeyStore*/ ctx[
|
|
35119
|
-
push: /*journeyStore*/ ctx[
|
|
35644
|
+
loading: /*$journeyStore*/ ctx[5].loading,
|
|
35645
|
+
pop: /*journeyStore*/ ctx[3].pop,
|
|
35646
|
+
push: /*journeyStore*/ ctx[3].push,
|
|
35120
35647
|
stack
|
|
35121
35648
|
},
|
|
35122
|
-
metadata: /*$journeyStore*/ ctx[
|
|
35123
|
-
step: /*$journeyStore*/ ctx[
|
|
35649
|
+
metadata: /*$journeyStore*/ ctx[5].metadata,
|
|
35650
|
+
step: /*$journeyStore*/ ctx[5].step
|
|
35124
35651
|
};
|
|
35125
35652
|
|
|
35126
35653
|
if (/*formEl*/ ctx[0] !== void 0) {
|
|
@@ -35147,23 +35674,24 @@ function create_if_block_2(ctx) {
|
|
|
35147
35674
|
},
|
|
35148
35675
|
p(ctx, dirty) {
|
|
35149
35676
|
const switch_instance_changes = {};
|
|
35677
|
+
if (dirty & /*componentStyle*/ 2) switch_instance_changes.componentStyle = /*componentStyle*/ ctx[1];
|
|
35150
35678
|
|
|
35151
|
-
if (dirty & /*displayIcon, $journeyStore*/
|
|
35152
|
-
icon: /*displayIcon*/ ctx[
|
|
35153
|
-
message: /*$journeyStore*/ ctx[
|
|
35154
|
-
status: (/*$journeyStore*/ ctx[
|
|
35155
|
-
submit: /*submitForm*/ ctx[
|
|
35679
|
+
if (dirty & /*displayIcon, $journeyStore*/ 36) switch_instance_changes.form = {
|
|
35680
|
+
icon: /*displayIcon*/ ctx[2],
|
|
35681
|
+
message: /*$journeyStore*/ ctx[5].error?.message || '',
|
|
35682
|
+
status: (/*$journeyStore*/ ctx[5].error?.code) ? 'error' : 'ok',
|
|
35683
|
+
submit: /*submitForm*/ ctx[6]
|
|
35156
35684
|
};
|
|
35157
35685
|
|
|
35158
|
-
if (dirty & /*$journeyStore, journeyStore*/
|
|
35159
|
-
loading: /*$journeyStore*/ ctx[
|
|
35160
|
-
pop: /*journeyStore*/ ctx[
|
|
35161
|
-
push: /*journeyStore*/ ctx[
|
|
35686
|
+
if (dirty & /*$journeyStore, journeyStore*/ 40) switch_instance_changes.journey = {
|
|
35687
|
+
loading: /*$journeyStore*/ ctx[5].loading,
|
|
35688
|
+
pop: /*journeyStore*/ ctx[3].pop,
|
|
35689
|
+
push: /*journeyStore*/ ctx[3].push,
|
|
35162
35690
|
stack
|
|
35163
35691
|
};
|
|
35164
35692
|
|
|
35165
|
-
if (dirty & /*$journeyStore*/
|
|
35166
|
-
if (dirty & /*$journeyStore*/
|
|
35693
|
+
if (dirty & /*$journeyStore*/ 32) switch_instance_changes.metadata = /*$journeyStore*/ ctx[5].metadata;
|
|
35694
|
+
if (dirty & /*$journeyStore*/ 32) switch_instance_changes.step = /*$journeyStore*/ ctx[5].step;
|
|
35167
35695
|
|
|
35168
35696
|
if (!updating_formEl && dirty & /*formEl*/ 1) {
|
|
35169
35697
|
updating_formEl = true;
|
|
@@ -35171,7 +35699,7 @@ function create_if_block_2(ctx) {
|
|
|
35171
35699
|
add_flush_callback(() => updating_formEl = false);
|
|
35172
35700
|
}
|
|
35173
35701
|
|
|
35174
|
-
if (switch_value !== (switch_value = mapStepToStage(/*$journeyStore*/ ctx[
|
|
35702
|
+
if (switch_value !== (switch_value = mapStepToStage(/*$journeyStore*/ ctx[5].step))) {
|
|
35175
35703
|
if (switch_instance) {
|
|
35176
35704
|
group_outros();
|
|
35177
35705
|
const old_component = switch_instance;
|
|
@@ -35212,7 +35740,7 @@ function create_if_block_2(ctx) {
|
|
|
35212
35740
|
};
|
|
35213
35741
|
}
|
|
35214
35742
|
|
|
35215
|
-
// (
|
|
35743
|
+
// (31:2) {#if $journeyStore && !$journeyStore.step}
|
|
35216
35744
|
function create_if_block_1(ctx) {
|
|
35217
35745
|
let div;
|
|
35218
35746
|
let spinner;
|
|
@@ -35262,8 +35790,8 @@ function create_fragment$1(ctx) {
|
|
|
35262
35790
|
const if_blocks = [];
|
|
35263
35791
|
|
|
35264
35792
|
function select_block_type(ctx, dirty) {
|
|
35265
|
-
if (!/*$journeyStore*/ ctx[
|
|
35266
|
-
if (/*$journeyStore*/ ctx[
|
|
35793
|
+
if (/*$journeyStore*/ ctx[5] && !/*$journeyStore*/ ctx[5].completed) return 0;
|
|
35794
|
+
if (/*$journeyStore*/ ctx[5] && /*$journeyStore*/ ctx[5].successful) return 1;
|
|
35267
35795
|
return 2;
|
|
35268
35796
|
}
|
|
35269
35797
|
|
|
@@ -35326,13 +35854,19 @@ function create_fragment$1(ctx) {
|
|
|
35326
35854
|
function instance$1($$self, $$props, $$invalidate) {
|
|
35327
35855
|
let $journeyStore,
|
|
35328
35856
|
$$unsubscribe_journeyStore = noop,
|
|
35329
|
-
$$subscribe_journeyStore = () => ($$unsubscribe_journeyStore(), $$unsubscribe_journeyStore = subscribe(journeyStore, $$value => $$invalidate(
|
|
35857
|
+
$$subscribe_journeyStore = () => ($$unsubscribe_journeyStore(), $$unsubscribe_journeyStore = subscribe(journeyStore, $$value => $$invalidate(5, $journeyStore = $$value)), journeyStore);
|
|
35330
35858
|
|
|
35331
35859
|
$$self.$$.on_destroy.push(() => $$unsubscribe_journeyStore());
|
|
35860
|
+
let { componentStyle } = $$props;
|
|
35332
35861
|
let { displayIcon } = $$props;
|
|
35333
35862
|
let { formEl = null } = $$props;
|
|
35334
35863
|
let { journeyStore } = $$props;
|
|
35335
35864
|
$$subscribe_journeyStore();
|
|
35865
|
+
|
|
35866
|
+
if (!$journeyStore) {
|
|
35867
|
+
console.error('Widget missing configuration. Import and call `configuration()`, then use `set()` to configure.');
|
|
35868
|
+
}
|
|
35869
|
+
|
|
35336
35870
|
let alertNeedsFocus = false;
|
|
35337
35871
|
|
|
35338
35872
|
function submitForm() {
|
|
@@ -35346,7 +35880,7 @@ function instance$1($$self, $$props, $$invalidate) {
|
|
|
35346
35880
|
}
|
|
35347
35881
|
|
|
35348
35882
|
afterUpdate(() => {
|
|
35349
|
-
$$invalidate(
|
|
35883
|
+
$$invalidate(4, alertNeedsFocus = $journeyStore && !$journeyStore.successful);
|
|
35350
35884
|
});
|
|
35351
35885
|
|
|
35352
35886
|
function switch_instance_formEl_binding(value) {
|
|
@@ -35355,13 +35889,15 @@ function instance$1($$self, $$props, $$invalidate) {
|
|
|
35355
35889
|
}
|
|
35356
35890
|
|
|
35357
35891
|
$$self.$$set = $$props => {
|
|
35358
|
-
if ('
|
|
35892
|
+
if ('componentStyle' in $$props) $$invalidate(1, componentStyle = $$props.componentStyle);
|
|
35893
|
+
if ('displayIcon' in $$props) $$invalidate(2, displayIcon = $$props.displayIcon);
|
|
35359
35894
|
if ('formEl' in $$props) $$invalidate(0, formEl = $$props.formEl);
|
|
35360
|
-
if ('journeyStore' in $$props) $$subscribe_journeyStore($$invalidate(
|
|
35895
|
+
if ('journeyStore' in $$props) $$subscribe_journeyStore($$invalidate(3, journeyStore = $$props.journeyStore));
|
|
35361
35896
|
};
|
|
35362
35897
|
|
|
35363
35898
|
return [
|
|
35364
35899
|
formEl,
|
|
35900
|
+
componentStyle,
|
|
35365
35901
|
displayIcon,
|
|
35366
35902
|
journeyStore,
|
|
35367
35903
|
alertNeedsFocus,
|
|
@@ -35377,9 +35913,10 @@ class Journey extends SvelteComponent {
|
|
|
35377
35913
|
super();
|
|
35378
35914
|
|
|
35379
35915
|
init(this, options, instance$1, create_fragment$1, safe_not_equal, {
|
|
35380
|
-
|
|
35916
|
+
componentStyle: 1,
|
|
35917
|
+
displayIcon: 2,
|
|
35381
35918
|
formEl: 0,
|
|
35382
|
-
journeyStore:
|
|
35919
|
+
journeyStore: 3
|
|
35383
35920
|
});
|
|
35384
35921
|
}
|
|
35385
35922
|
}
|
|
@@ -35397,6 +35934,7 @@ function create_else_block(ctx) {
|
|
|
35397
35934
|
}
|
|
35398
35935
|
|
|
35399
35936
|
let journey_1_props = {
|
|
35937
|
+
componentStyle: "inline",
|
|
35400
35938
|
displayIcon: /*$styleStore*/ ctx[4]?.stage?.icon ?? true,
|
|
35401
35939
|
journeyStore: /*journeyStore*/ ctx[5]
|
|
35402
35940
|
};
|
|
@@ -35528,6 +36066,7 @@ function create_default_slot(ctx) {
|
|
|
35528
36066
|
}
|
|
35529
36067
|
|
|
35530
36068
|
let journey_1_props = {
|
|
36069
|
+
componentStyle: "modal",
|
|
35531
36070
|
displayIcon: /*$styleStore*/ ctx[4]?.stage?.icon ?? !/*$styleStore*/ ctx[4]?.logo,
|
|
35532
36071
|
journeyStore: /*journeyStore*/ ctx[5]
|
|
35533
36072
|
};
|