@forgerock/login-widget 1.0.0-beta.8 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +168 -3
- package/index.cjs +1367 -785
- package/index.cjs.map +1 -1
- package/index.js +1367 -785
- package/index.js.map +1 -1
- package/package.json +2 -9
- package/{index.d.ts → types.d.ts} +164 -234
- package/widget.css +28 -11
package/index.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,12 +14948,18 @@ 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);
|
|
14931
14959
|
}
|
|
14932
14960
|
|
|
14933
|
-
const journeyConfigItemSchema = z
|
|
14961
|
+
const journeyConfigItemSchema = z
|
|
14962
|
+
.object({
|
|
14934
14963
|
journey: z.string().optional(),
|
|
14935
14964
|
match: z
|
|
14936
14965
|
.string()
|
|
@@ -14938,7 +14967,8 @@ const journeyConfigItemSchema = z.object({
|
|
|
14938
14967
|
message: 'HREF string must start with `?journey` or `#/service`',
|
|
14939
14968
|
})
|
|
14940
14969
|
.array(),
|
|
14941
|
-
})
|
|
14970
|
+
})
|
|
14971
|
+
.optional();
|
|
14942
14972
|
const journeyConfigSchema = z.object({
|
|
14943
14973
|
forgotPassword: journeyConfigItemSchema,
|
|
14944
14974
|
forgotUsername: journeyConfigItemSchema,
|
|
@@ -14955,8 +14985,8 @@ const defaultJourneys = {
|
|
|
14955
14985
|
match: ['#/service/ForgottenUsername', '?journey=ForgottenUsername'],
|
|
14956
14986
|
},
|
|
14957
14987
|
login: {
|
|
14958
|
-
journey:
|
|
14959
|
-
match: ['#/service/Login', '?journey'],
|
|
14988
|
+
journey: 'Login',
|
|
14989
|
+
match: ['#/service/Login', '?journey', '?journey=Login'],
|
|
14960
14990
|
},
|
|
14961
14991
|
register: {
|
|
14962
14992
|
journey: 'Registration',
|
|
@@ -14970,12 +15000,24 @@ const fallbackJourneyConfig = Object.keys(defaultJourneys).map((key) => ({
|
|
|
14970
15000
|
key,
|
|
14971
15001
|
}));
|
|
14972
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
|
+
*/
|
|
14973
15009
|
function initialize$6(customJourneys) {
|
|
14974
15010
|
if (customJourneys) {
|
|
14975
15011
|
// Provide developer feedback if customized
|
|
14976
15012
|
journeyConfigSchema.parse(customJourneys);
|
|
14977
|
-
|
|
14978
|
-
|
|
15013
|
+
// Merge the two journey configs, dev's overwriting the default
|
|
15014
|
+
const mergedJourneyObjects = {
|
|
15015
|
+
...defaultJourneys,
|
|
15016
|
+
...customJourneys,
|
|
15017
|
+
};
|
|
15018
|
+
const customJourneyKeys = Object.keys(mergedJourneyObjects);
|
|
15019
|
+
configuredJourneysStore.set(customJourneyKeys.map((key) => ({
|
|
15020
|
+
...mergedJourneyObjects[key],
|
|
14979
15021
|
key,
|
|
14980
15022
|
})));
|
|
14981
15023
|
}
|
|
@@ -16722,6 +16764,8 @@ var backToDefault = "Back to Sign In";
|
|
|
16722
16764
|
var backToLogin = "Back to Sign In";
|
|
16723
16765
|
var dontHaveAnAccount = "No account? <a href='?journey=Registration'>Register here!</a>";
|
|
16724
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)";
|
|
16725
16769
|
var chooseDifferentUsername = "Please choose a different username.";
|
|
16726
16770
|
var confirmPassword = "Confirm password";
|
|
16727
16771
|
var constraintViolationForPassword = "Password does not meet the requirements.";
|
|
@@ -16754,6 +16798,9 @@ var nextButton = "Next";
|
|
|
16754
16798
|
var notToExceedMaximumCharacterLength = "No more than {max} characters";
|
|
16755
16799
|
var noLessThanMinimumCharacterLength = "At least {min} character(s)";
|
|
16756
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";
|
|
16757
16804
|
var passwordRequirements = "Password requirements:";
|
|
16758
16805
|
var pleaseCheckValue = "Please check this value";
|
|
16759
16806
|
var pleaseConfirm = "Please confirm";
|
|
@@ -16767,7 +16814,11 @@ var registerSuccess = "Registration successful!";
|
|
|
16767
16814
|
var requiredField = "Value is required";
|
|
16768
16815
|
var securityAnswer = "Security answer";
|
|
16769
16816
|
var securityQuestions = "Security question(s)";
|
|
16770
|
-
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";
|
|
16771
16822
|
var showPassword = "Show password";
|
|
16772
16823
|
var sn = "Last name";
|
|
16773
16824
|
var submitButton = "Submit";
|
|
@@ -16778,6 +16829,7 @@ var tryAgain = "Please try again";
|
|
|
16778
16829
|
var twoFactorAuthentication = "Two factor authentication";
|
|
16779
16830
|
var useValidEmail = "Please use a valid email address.";
|
|
16780
16831
|
var unrecoverableError = "There was an error in the form submission.";
|
|
16832
|
+
var unknownLoginError = "Unknown login failure has occurred.";
|
|
16781
16833
|
var unknownNetworkError = "Unknown network request failure has occurred.";
|
|
16782
16834
|
var userName = "Username";
|
|
16783
16835
|
var usernameRequirements = "Username requirements:";
|
|
@@ -16791,6 +16843,8 @@ var fallback = {
|
|
|
16791
16843
|
backToLogin: backToLogin,
|
|
16792
16844
|
dontHaveAnAccount: dontHaveAnAccount,
|
|
16793
16845
|
closeModal: closeModal,
|
|
16846
|
+
charactersCannotRepeatMoreThan: charactersCannotRepeatMoreThan,
|
|
16847
|
+
charactersCannotRepeatMoreThanCaseInsensitive: charactersCannotRepeatMoreThanCaseInsensitive,
|
|
16794
16848
|
chooseDifferentUsername: chooseDifferentUsername,
|
|
16795
16849
|
confirmPassword: confirmPassword,
|
|
16796
16850
|
constraintViolationForPassword: constraintViolationForPassword,
|
|
@@ -16823,6 +16877,9 @@ var fallback = {
|
|
|
16823
16877
|
notToExceedMaximumCharacterLength: notToExceedMaximumCharacterLength,
|
|
16824
16878
|
noLessThanMinimumCharacterLength: noLessThanMinimumCharacterLength,
|
|
16825
16879
|
passwordCallback: passwordCallback,
|
|
16880
|
+
passwordCannotContainCommonPasswords: passwordCannotContainCommonPasswords,
|
|
16881
|
+
passwordCannotContainCommonPasswordsOrBeReversible: passwordCannotContainCommonPasswordsOrBeReversible,
|
|
16882
|
+
passwordCannotContainCommonPasswordsOrBeReversibleStringsLessThan: passwordCannotContainCommonPasswordsOrBeReversibleStringsLessThan,
|
|
16826
16883
|
passwordRequirements: passwordRequirements,
|
|
16827
16884
|
pleaseCheckValue: pleaseCheckValue,
|
|
16828
16885
|
pleaseConfirm: pleaseConfirm,
|
|
@@ -16837,6 +16894,10 @@ var fallback = {
|
|
|
16837
16894
|
securityAnswer: securityAnswer,
|
|
16838
16895
|
securityQuestions: securityQuestions,
|
|
16839
16896
|
securityQuestionsPrompt: securityQuestionsPrompt,
|
|
16897
|
+
shouldContainANumber: shouldContainANumber,
|
|
16898
|
+
shouldContainAnUppercase: shouldContainAnUppercase,
|
|
16899
|
+
shouldContainALowercase: shouldContainALowercase,
|
|
16900
|
+
shouldContainASymbol: shouldContainASymbol,
|
|
16840
16901
|
showPassword: showPassword,
|
|
16841
16902
|
sn: sn,
|
|
16842
16903
|
submitButton: submitButton,
|
|
@@ -16847,6 +16908,7 @@ var fallback = {
|
|
|
16847
16908
|
twoFactorAuthentication: twoFactorAuthentication,
|
|
16848
16909
|
useValidEmail: useValidEmail,
|
|
16849
16910
|
unrecoverableError: unrecoverableError,
|
|
16911
|
+
unknownLoginError: unknownLoginError,
|
|
16850
16912
|
unknownNetworkError: unknownNetworkError,
|
|
16851
16913
|
userName: userName,
|
|
16852
16914
|
usernameRequirements: usernameRequirements,
|
|
@@ -16863,6 +16925,8 @@ const stringsSchema = z
|
|
|
16863
16925
|
backToLogin: z.string(),
|
|
16864
16926
|
dontHaveAnAccount: z.string(),
|
|
16865
16927
|
closeModal: z.string(),
|
|
16928
|
+
charactersCannotRepeatMoreThan: z.string(),
|
|
16929
|
+
charactersCannotRepeatMoreThanCaseInsensitive: z.string(),
|
|
16866
16930
|
chooseDifferentUsername: z.string(),
|
|
16867
16931
|
confirmPassword: z.string(),
|
|
16868
16932
|
constraintViolationForPassword: z.string(),
|
|
@@ -16895,6 +16959,9 @@ const stringsSchema = z
|
|
|
16895
16959
|
notToExceedMaximumCharacterLength: z.string(),
|
|
16896
16960
|
noLessThanMinimumCharacterLength: z.string(),
|
|
16897
16961
|
passwordCallback: z.string(),
|
|
16962
|
+
passwordCannotContainCommonPasswords: z.string(),
|
|
16963
|
+
passwordCannotContainCommonPasswordsOrBeReversible: z.string(),
|
|
16964
|
+
passwordCannotContainCommonPasswordsOrBeReversibleStringsLessThan: z.string(),
|
|
16898
16965
|
passwordRequirements: z.string(),
|
|
16899
16966
|
pleaseCheckValue: z.string(),
|
|
16900
16967
|
pleaseConfirm: z.string(),
|
|
@@ -16909,6 +16976,10 @@ const stringsSchema = z
|
|
|
16909
16976
|
securityAnswer: z.string(),
|
|
16910
16977
|
securityQuestions: z.string(),
|
|
16911
16978
|
securityQuestionsPrompt: z.string(),
|
|
16979
|
+
shouldContainANumber: z.string(),
|
|
16980
|
+
shouldContainAnUppercase: z.string(),
|
|
16981
|
+
shouldContainALowercase: z.string(),
|
|
16982
|
+
shouldContainASymbol: z.string(),
|
|
16912
16983
|
showPassword: z.string(),
|
|
16913
16984
|
sn: z.string(),
|
|
16914
16985
|
submitButton: z.string(),
|
|
@@ -16919,6 +16990,7 @@ const stringsSchema = z
|
|
|
16919
16990
|
twoFactorAuthentication: z.string(),
|
|
16920
16991
|
useValidEmail: z.string(),
|
|
16921
16992
|
unrecoverableError: z.string(),
|
|
16993
|
+
unknownLoginError: z.string(),
|
|
16922
16994
|
unknownNetworkError: z.string(),
|
|
16923
16995
|
userName: z.string(),
|
|
16924
16996
|
usernameRequirements: z.string(),
|
|
@@ -16932,6 +17004,12 @@ stringsSchema.partial();
|
|
|
16932
17004
|
// Ensure fallback follows schema
|
|
16933
17005
|
stringsSchema.parse(fallback);
|
|
16934
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
|
+
*/
|
|
16935
17013
|
function initialize$5(userLocale) {
|
|
16936
17014
|
if (userLocale) {
|
|
16937
17015
|
/**
|
|
@@ -16951,6 +17029,14 @@ function initialize$5(userLocale) {
|
|
|
16951
17029
|
* Demo: https://regex101.com/r/Mw9vTB/1
|
|
16952
17030
|
*/
|
|
16953
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
|
+
*/
|
|
16954
17040
|
function interpolate(key, values, externalText) {
|
|
16955
17041
|
// Let's throw some errors if we're trying to use keys/locales that don't exist.
|
|
16956
17042
|
// We could improve this by using Typescript and/or fallback values.
|
|
@@ -17022,6 +17108,31 @@ function interpolate(key, values, externalText) {
|
|
|
17022
17108
|
});
|
|
17023
17109
|
return messageClean;
|
|
17024
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
|
+
*/
|
|
17025
17136
|
function textToKey(text) {
|
|
17026
17137
|
if (typeof text !== 'string' && typeof text !== 'number') {
|
|
17027
17138
|
throw new Error('Parameter for textToKey function needs to be of type string or number');
|
|
@@ -17163,7 +17274,9 @@ const userInputCallbacks = [
|
|
|
17163
17274
|
CallbackType$1.ValidatedCreatePasswordCallback,
|
|
17164
17275
|
CallbackType$1.ValidatedCreateUsernameCallback,
|
|
17165
17276
|
];
|
|
17166
|
-
|
|
17277
|
+
/**
|
|
17278
|
+
* @function forceUserInputOptionalityCallbacks - Determines if a callback should be forced to be optional
|
|
17279
|
+
*/
|
|
17167
17280
|
const forceUserInputOptionalityCallbacks = {
|
|
17168
17281
|
SelectIdPCallback: (callback) => {
|
|
17169
17282
|
const selectIdpCb = callback;
|
|
@@ -17172,6 +17285,11 @@ const forceUserInputOptionalityCallbacks = {
|
|
|
17172
17285
|
.find((provider) => provider.provider === 'localAuthentication');
|
|
17173
17286
|
},
|
|
17174
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
|
+
*/
|
|
17175
17293
|
function isCbReadyByDefault(callback) {
|
|
17176
17294
|
if (callback.getType() === CallbackType$1.ConfirmationCallback) {
|
|
17177
17295
|
const cb = callback;
|
|
@@ -17181,6 +17299,11 @@ function isCbReadyByDefault(callback) {
|
|
|
17181
17299
|
}
|
|
17182
17300
|
return false;
|
|
17183
17301
|
}
|
|
17302
|
+
/**
|
|
17303
|
+
* @function canForceUserInputOptionality
|
|
17304
|
+
* @param {object} callback - generic FRCallback from JavaScript SDK
|
|
17305
|
+
* @returns
|
|
17306
|
+
*/
|
|
17184
17307
|
function canForceUserInputOptionality(callback) {
|
|
17185
17308
|
// See if a callback function exists within this collection
|
|
17186
17309
|
const fn = forceUserInputOptionalityCallbacks[callback.getType()];
|
|
@@ -17208,9 +17331,9 @@ function isStepSelfSubmittable(callbacks, userInputOptional) {
|
|
|
17208
17331
|
return !unsubmittableCallbacks.length;
|
|
17209
17332
|
}
|
|
17210
17333
|
/**
|
|
17211
|
-
*
|
|
17334
|
+
* @function requiresUserInput - Determines if a callback requires user input
|
|
17212
17335
|
* @param {object} callback - Generic callback provided by JavaScript SDK
|
|
17213
|
-
* @returns
|
|
17336
|
+
* @returns {boolean}
|
|
17214
17337
|
*/
|
|
17215
17338
|
function requiresUserInput(callback) {
|
|
17216
17339
|
if (callback.getType() === CallbackType$1.SelectIdPCallback) {
|
|
@@ -17226,6 +17349,22 @@ function requiresUserInput(callback) {
|
|
|
17226
17349
|
}
|
|
17227
17350
|
// Notice this function can take a user provided argument function to
|
|
17228
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
|
+
*/
|
|
17229
17368
|
function isUserInputOptional(callbackMetadataArray, numOfUserInputCbs, fn) {
|
|
17230
17369
|
// default reducer function to check if both overriding callback exists
|
|
17231
17370
|
// along with user input required callbacks
|
|
@@ -17242,7 +17381,7 @@ function isUserInputOptional(callbackMetadataArray, numOfUserInputCbs, fn) {
|
|
|
17242
17381
|
/**
|
|
17243
17382
|
* @function buildCallbackMetadata - Constructs an array of callback metadata that matches to original callback array
|
|
17244
17383
|
* @param {object} step - The modified Widget step object
|
|
17245
|
-
* @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
|
|
17246
17385
|
* @returns {array}
|
|
17247
17386
|
*/
|
|
17248
17387
|
function buildCallbackMetadata(step, checkValidation, stageJson) {
|
|
@@ -17321,11 +17460,25 @@ function buildStepMetadata(callbackMetadataArray, stageJson, stageName) {
|
|
|
17321
17460
|
};
|
|
17322
17461
|
}
|
|
17323
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
|
+
*/
|
|
17324
17468
|
function initializeStack(initOptions) {
|
|
17325
17469
|
const initialValue = initOptions ? [initOptions] : [];
|
|
17326
17470
|
const { update, set, subscribe } = writable(initialValue);
|
|
17327
17471
|
// Assign to exported variable (see bottom of file)
|
|
17328
17472
|
stack = {
|
|
17473
|
+
latest: async () => {
|
|
17474
|
+
return new Promise((resolve) => {
|
|
17475
|
+
// subscribe, grab the current value and unsubscribe
|
|
17476
|
+
subscribe((current) => {
|
|
17477
|
+
const lastItem = current[current.length - 1];
|
|
17478
|
+
resolve(lastItem);
|
|
17479
|
+
})();
|
|
17480
|
+
});
|
|
17481
|
+
},
|
|
17329
17482
|
pop: async () => {
|
|
17330
17483
|
return new Promise((resolve) => {
|
|
17331
17484
|
update((current) => {
|
|
@@ -17375,9 +17528,13 @@ const journeyStore = writable({
|
|
|
17375
17528
|
successful: false,
|
|
17376
17529
|
response: null,
|
|
17377
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
|
+
*/
|
|
17378
17536
|
function initialize$4(initOptions) {
|
|
17379
17537
|
const stack = initializeStack();
|
|
17380
|
-
let restartOptions;
|
|
17381
17538
|
let stepNumber = 0;
|
|
17382
17539
|
async function next(prevStep = null, nextOptions, resumeUrl) {
|
|
17383
17540
|
if (!Config.get().serverConfig?.baseUrl) {
|
|
@@ -17391,14 +17548,6 @@ function initialize$4(initOptions) {
|
|
|
17391
17548
|
...initOptions,
|
|
17392
17549
|
...nextOptions,
|
|
17393
17550
|
};
|
|
17394
|
-
// These options are reserved only for restarting a journey after failure
|
|
17395
|
-
if (initOptions || nextOptions) {
|
|
17396
|
-
restartOptions = {
|
|
17397
|
-
// Prioritize next options over initialize options
|
|
17398
|
-
...initOptions,
|
|
17399
|
-
...nextOptions,
|
|
17400
|
-
};
|
|
17401
|
-
}
|
|
17402
17551
|
/**
|
|
17403
17552
|
* Save previous step information just in case we have a total
|
|
17404
17553
|
* form failure due to 400 response from ForgeRock.
|
|
@@ -17485,6 +17634,7 @@ function initialize$4(initOptions) {
|
|
|
17485
17634
|
/**
|
|
17486
17635
|
* SUCCESSFUL COMPLETION BLOCK
|
|
17487
17636
|
*/
|
|
17637
|
+
stack.reset();
|
|
17488
17638
|
// Set final state
|
|
17489
17639
|
journeyStore.set({
|
|
17490
17640
|
completed: true,
|
|
@@ -17502,12 +17652,13 @@ function initialize$4(initOptions) {
|
|
|
17502
17652
|
*
|
|
17503
17653
|
* Grab failure message, which may contain encoded HTML
|
|
17504
17654
|
*/
|
|
17505
|
-
const failureMessageStr = htmlDecode(nextStep.payload.message || '');
|
|
17655
|
+
const failureMessageStr = htmlDecode(nextStep.payload.message || 'Unknown login error');
|
|
17506
17656
|
let restartedStep = null;
|
|
17507
17657
|
try {
|
|
17508
17658
|
/**
|
|
17509
17659
|
* Restart tree to get fresh step
|
|
17510
17660
|
*/
|
|
17661
|
+
const restartOptions = await stack.latest();
|
|
17511
17662
|
restartedStep = await FRAuth$1.next(undefined, restartOptions);
|
|
17512
17663
|
}
|
|
17513
17664
|
catch (err) {
|
|
@@ -17584,8 +17735,7 @@ function initialize$4(initOptions) {
|
|
|
17584
17735
|
error: {
|
|
17585
17736
|
code: nextStep.getCode(),
|
|
17586
17737
|
message: failureMessageStr,
|
|
17587
|
-
|
|
17588
|
-
step: prevStep?.payload,
|
|
17738
|
+
stage: prevStep?.payload?.stage,
|
|
17589
17739
|
troubleshoot: null,
|
|
17590
17740
|
},
|
|
17591
17741
|
loading: false,
|
|
@@ -17615,8 +17765,7 @@ function initialize$4(initOptions) {
|
|
|
17615
17765
|
error: {
|
|
17616
17766
|
code: nextStep.getCode(),
|
|
17617
17767
|
message: failureMessageStr,
|
|
17618
|
-
|
|
17619
|
-
step: prevStep?.payload,
|
|
17768
|
+
stage: prevStep?.payload?.stage,
|
|
17620
17769
|
troubleshoot: null,
|
|
17621
17770
|
},
|
|
17622
17771
|
loading: false,
|
|
@@ -17643,6 +17792,18 @@ function initialize$4(initOptions) {
|
|
|
17643
17792
|
await next(undefined, resumeOptions, url);
|
|
17644
17793
|
}
|
|
17645
17794
|
async function start(startOptions) {
|
|
17795
|
+
const configTree = Config.get().tree;
|
|
17796
|
+
// If no tree is passed in, but there's a configured default tree, use that
|
|
17797
|
+
if (!startOptions?.tree && configTree) {
|
|
17798
|
+
if (startOptions) {
|
|
17799
|
+
startOptions.tree = configTree;
|
|
17800
|
+
}
|
|
17801
|
+
else {
|
|
17802
|
+
startOptions = {
|
|
17803
|
+
tree: configTree,
|
|
17804
|
+
};
|
|
17805
|
+
}
|
|
17806
|
+
}
|
|
17646
17807
|
await stack.push(startOptions);
|
|
17647
17808
|
await next(undefined, startOptions);
|
|
17648
17809
|
}
|
|
@@ -17676,6 +17837,12 @@ const linksSchema = z
|
|
|
17676
17837
|
.strict();
|
|
17677
17838
|
linksSchema.partial();
|
|
17678
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
|
+
*/
|
|
17679
17846
|
function initialize$3(customLinks) {
|
|
17680
17847
|
// If customLinks is provided, provide feedback for object
|
|
17681
17848
|
if (customLinks) {
|
|
@@ -17698,7 +17865,19 @@ const oauthStore = writable({
|
|
|
17698
17865
|
successful: false,
|
|
17699
17866
|
response: null,
|
|
17700
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
|
+
*/
|
|
17701
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
|
+
*/
|
|
17702
17881
|
async function get(getOptions) {
|
|
17703
17882
|
/**
|
|
17704
17883
|
* Create an options object with getOptions overriding anything from initOptions
|
|
@@ -17766,7 +17945,18 @@ const userStore = writable({
|
|
|
17766
17945
|
successful: false,
|
|
17767
17946
|
response: null,
|
|
17768
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
|
+
*/
|
|
17769
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
|
+
*/
|
|
17770
17960
|
async function get(getOptions) {
|
|
17771
17961
|
/**
|
|
17772
17962
|
* Create an options object with getOptions overriding anything from initOptions
|
|
@@ -17853,11 +18043,17 @@ styleSchema.partial();
|
|
|
17853
18043
|
const fallbackStyles = {
|
|
17854
18044
|
checksAndRadios: 'animated',
|
|
17855
18045
|
labels: 'floating',
|
|
17856
|
-
logo:
|
|
17857
|
-
sections:
|
|
17858
|
-
stage:
|
|
18046
|
+
logo: undefined,
|
|
18047
|
+
sections: undefined,
|
|
18048
|
+
stage: undefined,
|
|
17859
18049
|
};
|
|
17860
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
|
+
*/
|
|
17861
18057
|
function initialize(customStyle) {
|
|
17862
18058
|
if (customStyle) {
|
|
17863
18059
|
styleSchema.parse(customStyle);
|
|
@@ -17869,6 +18065,17 @@ function initialize(customStyle) {
|
|
|
17869
18065
|
return styleStore;
|
|
17870
18066
|
}
|
|
17871
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
|
+
*/
|
|
17872
18079
|
function widgetApiFactory(componentApi) {
|
|
17873
18080
|
let journeyStore;
|
|
17874
18081
|
let oauthStore;
|
|
@@ -17885,8 +18092,6 @@ function widgetApiFactory(componentApi) {
|
|
|
17885
18092
|
journeyStore.reset();
|
|
17886
18093
|
oauthStore.reset();
|
|
17887
18094
|
userStore.reset();
|
|
17888
|
-
// Fetch fresh journey step
|
|
17889
|
-
journey().start();
|
|
17890
18095
|
}
|
|
17891
18096
|
const configuration = (options) => {
|
|
17892
18097
|
if (options?.forgerock) {
|
|
@@ -17919,6 +18124,10 @@ function widgetApiFactory(componentApi) {
|
|
|
17919
18124
|
initialize$3(options?.links);
|
|
17920
18125
|
initialize(options?.style);
|
|
17921
18126
|
return {
|
|
18127
|
+
/** Set the Login Widget's Configuration
|
|
18128
|
+
* @param {WidgetConfigOptions} options - The configuration options for the Login Widget
|
|
18129
|
+
* @returns {void}
|
|
18130
|
+
**/
|
|
17922
18131
|
set(setOptions) {
|
|
17923
18132
|
if (setOptions?.forgerock) {
|
|
17924
18133
|
configure({
|
|
@@ -18040,6 +18249,11 @@ function widgetApiFactory(componentApi) {
|
|
|
18040
18249
|
return { change, start, subscribe };
|
|
18041
18250
|
};
|
|
18042
18251
|
const user = {
|
|
18252
|
+
/**
|
|
18253
|
+
* User Info
|
|
18254
|
+
* @param: void
|
|
18255
|
+
* @returns: UserStore
|
|
18256
|
+
*/
|
|
18043
18257
|
info() {
|
|
18044
18258
|
if (!journeyStore || !oauthStore || !userStore) {
|
|
18045
18259
|
logErrorAndThrow('missingStores');
|
|
@@ -18062,6 +18276,12 @@ function widgetApiFactory(componentApi) {
|
|
|
18062
18276
|
}
|
|
18063
18277
|
return { get: wrappedGet, subscribe };
|
|
18064
18278
|
},
|
|
18279
|
+
/**
|
|
18280
|
+
* Logout a user from an AM Session
|
|
18281
|
+
* @async
|
|
18282
|
+
* @param: void
|
|
18283
|
+
* @returns: Promise<void>
|
|
18284
|
+
**/
|
|
18065
18285
|
async logout() {
|
|
18066
18286
|
if (!journeyStore || !oauthStore || !userStore) {
|
|
18067
18287
|
logErrorAndThrow('missingStores');
|
|
@@ -18090,6 +18310,11 @@ function widgetApiFactory(componentApi) {
|
|
|
18090
18310
|
// Return undefined as there's no response information to share
|
|
18091
18311
|
return;
|
|
18092
18312
|
},
|
|
18313
|
+
/**
|
|
18314
|
+
* Returns the widget's Tokens object
|
|
18315
|
+
* @param void;
|
|
18316
|
+
* @returns OAuthStore
|
|
18317
|
+
*/
|
|
18093
18318
|
tokens() {
|
|
18094
18319
|
if (!journeyStore || !oauthStore || !userStore) {
|
|
18095
18320
|
logErrorAndThrow('missingStores');
|
|
@@ -18118,7 +18343,7 @@ function widgetApiFactory(componentApi) {
|
|
|
18118
18343
|
configuration,
|
|
18119
18344
|
getStores,
|
|
18120
18345
|
journey,
|
|
18121
|
-
request: _default$2.request,
|
|
18346
|
+
request: _default$2.request.bind(_default$2),
|
|
18122
18347
|
user,
|
|
18123
18348
|
};
|
|
18124
18349
|
}
|
|
@@ -18508,7 +18733,7 @@ function create_else_block$9(ctx) {
|
|
|
18508
18733
|
attr(button, "aria-controls", /*dialogId*/ ctx[1]);
|
|
18509
18734
|
|
|
18510
18735
|
attr(div, "class", div_class_value = `tw_pt-10 md:tw_pt-10 tw_text-right ${(/*$styleStore*/ ctx[5]?.logo)
|
|
18511
|
-
? 'tw_h-32 md:tw_h-36
|
|
18736
|
+
? 'tw_h-32 md:tw_h-36 tw_pb-6'
|
|
18512
18737
|
: ''}`);
|
|
18513
18738
|
},
|
|
18514
18739
|
m(target, anchor) {
|
|
@@ -18551,7 +18776,7 @@ function create_else_block$9(ctx) {
|
|
|
18551
18776
|
}
|
|
18552
18777
|
|
|
18553
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)
|
|
18554
|
-
? 'tw_h-32 md:tw_h-36
|
|
18779
|
+
? 'tw_h-32 md:tw_h-36 tw_pb-6'
|
|
18555
18780
|
: ''}`)) {
|
|
18556
18781
|
attr(div, "class", div_class_value);
|
|
18557
18782
|
}
|
|
@@ -20572,6 +20797,11 @@ function matchJourneyAndDecideAction(href, journeys, stack) {
|
|
|
20572
20797
|
/** *********************************************
|
|
20573
20798
|
* NEW "NORMALIZED" METHODS
|
|
20574
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
|
+
*/
|
|
20575
20805
|
function getInputTypeFromPolicies(policies) {
|
|
20576
20806
|
const value = policies?.value;
|
|
20577
20807
|
if (typeof value !== 'object') {
|
|
@@ -20589,13 +20819,47 @@ function getInputTypeFromPolicies(policies) {
|
|
|
20589
20819
|
}
|
|
20590
20820
|
return 'text';
|
|
20591
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
|
+
*/
|
|
20592
20827
|
function getValidationFailureParams(failedPolicy) {
|
|
20593
|
-
if (failedPolicy?.policyRequirement === '
|
|
20594
|
-
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;
|
|
20595
20859
|
return params?.['character-sets'].map(convertCharacterSetToRuleObj);
|
|
20596
20860
|
}
|
|
20597
20861
|
else if (failedPolicy?.policyRequirement === 'LENGTH_BASED') {
|
|
20598
|
-
const params = failedPolicy
|
|
20862
|
+
const params = failedPolicy.params;
|
|
20599
20863
|
const min = params?.['min-password-length'] || 0;
|
|
20600
20864
|
const max = params?.['max-password-length'] || null;
|
|
20601
20865
|
const arr = [];
|
|
@@ -20615,6 +20879,26 @@ function getValidationFailureParams(failedPolicy) {
|
|
|
20615
20879
|
}
|
|
20616
20880
|
return arr;
|
|
20617
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
|
+
}
|
|
20618
20902
|
else if (failedPolicy?.policyRequirement === 'VALID_USERNAME') {
|
|
20619
20903
|
return [
|
|
20620
20904
|
{
|
|
@@ -20643,6 +20927,11 @@ function getValidationFailureParams(failedPolicy) {
|
|
|
20643
20927
|
];
|
|
20644
20928
|
}
|
|
20645
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
|
+
*/
|
|
20646
20935
|
function getValidationMessageString(policy) {
|
|
20647
20936
|
switch (policy?.policyId) {
|
|
20648
20937
|
case 'at-least-X-capitals': {
|
|
@@ -20657,18 +20946,36 @@ function getValidationMessageString(policy) {
|
|
|
20657
20946
|
}
|
|
20658
20947
|
case 'cannot-contain-characters': {
|
|
20659
20948
|
const params = policy?.params;
|
|
20660
|
-
|
|
20661
|
-
|
|
20662
|
-
return
|
|
20663
|
-
}
|
|
20949
|
+
let chars = '';
|
|
20950
|
+
if (typeof params !== 'object') {
|
|
20951
|
+
return '';
|
|
20952
|
+
}
|
|
20953
|
+
if (Array.isArray(params.forbiddenChars)) {
|
|
20954
|
+
chars = params.forbiddenChars.reduce((prev, curr) => {
|
|
20955
|
+
prev = `${prev ? `${prev}, ` : `${prev}`} ${curr}`;
|
|
20956
|
+
return prev;
|
|
20957
|
+
}, '');
|
|
20958
|
+
}
|
|
20959
|
+
else if (typeof params.forbiddenChars === 'string') {
|
|
20960
|
+
chars = params.forbiddenChars;
|
|
20961
|
+
}
|
|
20664
20962
|
return interpolate('fieldCanNotContainFollowingCharacters', { chars });
|
|
20665
20963
|
}
|
|
20666
20964
|
case 'cannot-contain-others': {
|
|
20667
20965
|
const params = policy?.params;
|
|
20668
|
-
|
|
20669
|
-
|
|
20670
|
-
return
|
|
20671
|
-
}
|
|
20966
|
+
let fields = '';
|
|
20967
|
+
if (typeof params !== 'object') {
|
|
20968
|
+
return '';
|
|
20969
|
+
}
|
|
20970
|
+
if (Array.isArray(params.disallowedFields)) {
|
|
20971
|
+
fields = params.disallowedFields?.reduce((prev, curr) => {
|
|
20972
|
+
prev = `${prev ? `${prev}, ` : `${prev}`} ${interpolate(curr)}`;
|
|
20973
|
+
return prev;
|
|
20974
|
+
}, '');
|
|
20975
|
+
}
|
|
20976
|
+
else if (typeof params.disallowedFields === 'string') {
|
|
20977
|
+
fields = params.disallowedFields;
|
|
20978
|
+
}
|
|
20672
20979
|
return interpolate('fieldCanNotContainFollowingValues', { fields });
|
|
20673
20980
|
}
|
|
20674
20981
|
case 'maximum-length': {
|
|
@@ -20708,6 +21015,12 @@ function getValidationMessageString(policy) {
|
|
|
20708
21015
|
return '';
|
|
20709
21016
|
}
|
|
20710
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
|
+
*/
|
|
20711
21024
|
function getValidationFailures(callback, label) {
|
|
20712
21025
|
const failedPolicies = callback.getFailedPolicies && callback.getFailedPolicies();
|
|
20713
21026
|
const parsedPolicies = parseFailedPolicies(failedPolicies, label);
|
|
@@ -20719,6 +21032,11 @@ function getValidationFailures(callback, label) {
|
|
|
20719
21032
|
};
|
|
20720
21033
|
});
|
|
20721
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
|
+
*/
|
|
20722
21040
|
function getValidationPolicies(policies) {
|
|
20723
21041
|
if (typeof policies !== 'object' && !policies) {
|
|
20724
21042
|
return [];
|
|
@@ -20737,6 +21055,11 @@ function getValidationPolicies(policies) {
|
|
|
20737
21055
|
})
|
|
20738
21056
|
.filter((policy) => !!policy.message);
|
|
20739
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
|
+
*/
|
|
20740
21063
|
function isInputRequired(callback) {
|
|
20741
21064
|
const policies = callback.getPolicies && callback.getPolicies();
|
|
20742
21065
|
let isRequired = false;
|
|
@@ -20748,46 +21071,93 @@ function isInputRequired(callback) {
|
|
|
20748
21071
|
}
|
|
20749
21072
|
return isRequired;
|
|
20750
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
|
+
*/
|
|
20751
21079
|
function convertCharacterSetToRuleObj(set) {
|
|
20752
21080
|
const arr = set.split(':');
|
|
20753
21081
|
const num = arr[0];
|
|
20754
21082
|
const type = arr[1];
|
|
20755
21083
|
if (type === '0123456789') {
|
|
20756
|
-
|
|
20757
|
-
|
|
20758
|
-
|
|
20759
|
-
|
|
20760
|
-
|
|
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
|
+
}
|
|
20761
21098
|
}
|
|
20762
21099
|
else if (type === 'ABCDEFGHIJKLMNOPQRSTUVWXYZ') {
|
|
20763
|
-
|
|
20764
|
-
|
|
20765
|
-
|
|
20766
|
-
|
|
20767
|
-
|
|
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
|
+
}
|
|
20768
21114
|
}
|
|
20769
21115
|
else if (type === 'abcdefghijklmnopqrstuvwxyz') {
|
|
20770
|
-
|
|
20771
|
-
|
|
20772
|
-
|
|
20773
|
-
|
|
20774
|
-
|
|
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
|
+
}
|
|
20775
21130
|
}
|
|
20776
21131
|
else if (type.includes('@') || type.includes('!') || type.includes('*') || type.includes('#')) {
|
|
20777
|
-
|
|
20778
|
-
|
|
20779
|
-
|
|
20780
|
-
|
|
20781
|
-
|
|
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
|
+
}
|
|
20782
21146
|
}
|
|
20783
21147
|
else {
|
|
20784
21148
|
return {
|
|
20785
|
-
length:
|
|
21149
|
+
length: null,
|
|
20786
21150
|
message: interpolate('pleaseCheckValue'),
|
|
20787
21151
|
rule: 'unknown',
|
|
20788
21152
|
};
|
|
20789
21153
|
}
|
|
20790
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
|
+
*/
|
|
20791
21161
|
function parseFailedPolicies(policies, label) {
|
|
20792
21162
|
return policies.map((policy) => {
|
|
20793
21163
|
if (typeof policy === 'string') {
|
|
@@ -20803,8 +21173,10 @@ function parseFailedPolicies(policies, label) {
|
|
|
20803
21173
|
}
|
|
20804
21174
|
});
|
|
20805
21175
|
}
|
|
20806
|
-
/**
|
|
20807
|
-
*
|
|
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
|
|
20808
21180
|
*/
|
|
20809
21181
|
function getAttributeValidationFailureText(callback) {
|
|
20810
21182
|
// TODO: Mature this utility for better parsing and display
|
|
@@ -21803,13 +22175,6 @@ function instance$I($$self, $$props, $$invalidate) {
|
|
|
21803
22175
|
let validationFailure;
|
|
21804
22176
|
|
|
21805
22177
|
function setValue(event) {
|
|
21806
|
-
/** ***********************************************************************
|
|
21807
|
-
* SDK INTEGRATION POINT
|
|
21808
|
-
* Summary: SDK callback methods for setting values
|
|
21809
|
-
* ------------------------------------------------------------------------
|
|
21810
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
21811
|
-
* for writing values to the callbacks received from AM
|
|
21812
|
-
*********************************************************************** */
|
|
21813
22178
|
callback.setInputValue(event.target.checked);
|
|
21814
22179
|
}
|
|
21815
22180
|
|
|
@@ -22749,7 +23114,7 @@ function get_each_context$7(ctx, list, i) {
|
|
|
22749
23114
|
return child_ctx;
|
|
22750
23115
|
}
|
|
22751
23116
|
|
|
22752
|
-
// (
|
|
23117
|
+
// (39:0) {#if labelOrder === 'first'}
|
|
22753
23118
|
function create_if_block_1$a(ctx) {
|
|
22754
23119
|
let label_1;
|
|
22755
23120
|
let current;
|
|
@@ -22797,7 +23162,7 @@ function create_if_block_1$a(ctx) {
|
|
|
22797
23162
|
};
|
|
22798
23163
|
}
|
|
22799
23164
|
|
|
22800
|
-
// (
|
|
23165
|
+
// (40:2) <Label {key} classes={`${labelClasses}`}>
|
|
22801
23166
|
function create_default_slot_1$b(ctx) {
|
|
22802
23167
|
let t;
|
|
22803
23168
|
|
|
@@ -22817,7 +23182,7 @@ function create_default_slot_1$b(ctx) {
|
|
|
22817
23182
|
};
|
|
22818
23183
|
}
|
|
22819
23184
|
|
|
22820
|
-
// (
|
|
23185
|
+
// (54:2) {#each options as option}
|
|
22821
23186
|
function create_each_block$7(ctx) {
|
|
22822
23187
|
let option;
|
|
22823
23188
|
let t0_value = /*option*/ ctx[15].text + "";
|
|
@@ -22858,7 +23223,7 @@ function create_each_block$7(ctx) {
|
|
|
22858
23223
|
};
|
|
22859
23224
|
}
|
|
22860
23225
|
|
|
22861
|
-
// (
|
|
23226
|
+
// (61:0) {#if labelOrder === 'last'}
|
|
22862
23227
|
function create_if_block$g(ctx) {
|
|
22863
23228
|
let label_1;
|
|
22864
23229
|
let current;
|
|
@@ -22911,7 +23276,7 @@ function create_if_block$g(ctx) {
|
|
|
22911
23276
|
};
|
|
22912
23277
|
}
|
|
22913
23278
|
|
|
22914
|
-
// (
|
|
23279
|
+
// (62:2) <Label {key} classes={`${shouldDisplayOption ? labelClasses : 'tw_sr-only'}`}>
|
|
22915
23280
|
function create_default_slot$i(ctx) {
|
|
22916
23281
|
let t;
|
|
22917
23282
|
|
|
@@ -23150,8 +23515,6 @@ function instance$E($$self, $$props, $$invalidate) {
|
|
|
23150
23515
|
// Check if text is same as label
|
|
23151
23516
|
$$invalidate(10, shouldDisplayOption = !(label === selectedOption?.text));
|
|
23152
23517
|
|
|
23153
|
-
console.log(shouldDisplayOption);
|
|
23154
|
-
|
|
23155
23518
|
// Continue with calling onChange parameter
|
|
23156
23519
|
onChange(event);
|
|
23157
23520
|
}
|
|
@@ -23578,7 +23941,7 @@ function create_else_block$6(ctx) {
|
|
|
23578
23941
|
};
|
|
23579
23942
|
}
|
|
23580
23943
|
|
|
23581
|
-
// (
|
|
23944
|
+
// (52:0) {#if callbackMetadata?.platform?.displayType === 'radio'}
|
|
23582
23945
|
function create_if_block$f(ctx) {
|
|
23583
23946
|
let radio;
|
|
23584
23947
|
let current;
|
|
@@ -23733,13 +24096,6 @@ function instance$B($$self, $$props, $$invalidate) {
|
|
|
23733
24096
|
* @param {Object} event
|
|
23734
24097
|
*/
|
|
23735
24098
|
function setValue(event) {
|
|
23736
|
-
/** ***********************************************************************
|
|
23737
|
-
* SDK INTEGRATION POINT
|
|
23738
|
-
* Summary: SDK callback methods for setting values
|
|
23739
|
-
* ------------------------------------------------------------------------
|
|
23740
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
23741
|
-
* for writing values to the callbacks received from AM
|
|
23742
|
-
*********************************************************************** */
|
|
23743
24099
|
callback.setChoiceIndex(Number(event.target.value));
|
|
23744
24100
|
}
|
|
23745
24101
|
|
|
@@ -23752,13 +24108,6 @@ function instance$B($$self, $$props, $$invalidate) {
|
|
|
23752
24108
|
$$self.$$.update = () => {
|
|
23753
24109
|
if ($$self.$$.dirty & /*callback, callbackMetadata, prompt*/ 2051) {
|
|
23754
24110
|
{
|
|
23755
|
-
/** *************************************************************************
|
|
23756
|
-
* SDK INTEGRATION POINT
|
|
23757
|
-
* Summary: SDK callback methods for getting values
|
|
23758
|
-
* --------------------------------------------------------------------------
|
|
23759
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
23760
|
-
* for accessing values from the callbacks received from AM
|
|
23761
|
-
************************************************************************* */
|
|
23762
24111
|
$$invalidate(2, choiceOptions = callback.getChoices()?.map((text, idx) => ({
|
|
23763
24112
|
/**
|
|
23764
24113
|
* Since locale content keys for the choice component are built off of the
|
|
@@ -23923,7 +24272,7 @@ function get_each_context$6(ctx, list, i) {
|
|
|
23923
24272
|
return child_ctx;
|
|
23924
24273
|
}
|
|
23925
24274
|
|
|
23926
|
-
// (
|
|
24275
|
+
// (81:0) {#if stepMetadata?.platform?.stageName !== 'OneTimePassword'}
|
|
23927
24276
|
function create_if_block$e(ctx) {
|
|
23928
24277
|
let current_block_type_index;
|
|
23929
24278
|
let if_block;
|
|
@@ -23993,7 +24342,7 @@ function create_if_block$e(ctx) {
|
|
|
23993
24342
|
};
|
|
23994
24343
|
}
|
|
23995
24344
|
|
|
23996
|
-
// (
|
|
24345
|
+
// (103:2) {:else}
|
|
23997
24346
|
function create_else_block_1(ctx) {
|
|
23998
24347
|
let grid;
|
|
23999
24348
|
let current;
|
|
@@ -24039,7 +24388,7 @@ function create_else_block_1(ctx) {
|
|
|
24039
24388
|
};
|
|
24040
24389
|
}
|
|
24041
24390
|
|
|
24042
|
-
// (
|
|
24391
|
+
// (82:2) {#if !stepMetadata?.derived.isStepSelfSubmittable}
|
|
24043
24392
|
function create_if_block_1$9(ctx) {
|
|
24044
24393
|
let current_block_type_index;
|
|
24045
24394
|
let if_block;
|
|
@@ -24109,7 +24458,7 @@ function create_if_block_1$9(ctx) {
|
|
|
24109
24458
|
};
|
|
24110
24459
|
}
|
|
24111
24460
|
|
|
24112
|
-
// (
|
|
24461
|
+
// (106:8) <Button style={options.length > 1 && defaultChoice === Number(opt.value) ? 'primary' : buttonStyle} type="button" width="auto" onClick={() => setBtnValue(Number(opt.value))} >
|
|
24113
24462
|
function create_default_slot_2$5(ctx) {
|
|
24114
24463
|
let t0_value = /*opt*/ ctx[15].text + "";
|
|
24115
24464
|
let t0;
|
|
@@ -24134,7 +24483,7 @@ function create_default_slot_2$5(ctx) {
|
|
|
24134
24483
|
};
|
|
24135
24484
|
}
|
|
24136
24485
|
|
|
24137
|
-
// (
|
|
24486
|
+
// (105:6) {#each options as opt}
|
|
24138
24487
|
function create_each_block$6(ctx) {
|
|
24139
24488
|
let button;
|
|
24140
24489
|
let current;
|
|
@@ -24195,7 +24544,7 @@ function create_each_block$6(ctx) {
|
|
|
24195
24544
|
};
|
|
24196
24545
|
}
|
|
24197
24546
|
|
|
24198
|
-
// (
|
|
24547
|
+
// (104:4) <Grid num={options.length}>
|
|
24199
24548
|
function create_default_slot_1$a(ctx) {
|
|
24200
24549
|
let each_1_anchor;
|
|
24201
24550
|
let current;
|
|
@@ -24279,7 +24628,7 @@ function create_default_slot_1$a(ctx) {
|
|
|
24279
24628
|
};
|
|
24280
24629
|
}
|
|
24281
24630
|
|
|
24282
|
-
// (
|
|
24631
|
+
// (92:4) {:else}
|
|
24283
24632
|
function create_else_block$5(ctx) {
|
|
24284
24633
|
let checkbox;
|
|
24285
24634
|
let current;
|
|
@@ -24330,7 +24679,7 @@ function create_else_block$5(ctx) {
|
|
|
24330
24679
|
};
|
|
24331
24680
|
}
|
|
24332
24681
|
|
|
24333
|
-
// (
|
|
24682
|
+
// (83:4) {#if options.length > 1}
|
|
24334
24683
|
function create_if_block_2$8(ctx) {
|
|
24335
24684
|
let select;
|
|
24336
24685
|
let current;
|
|
@@ -24377,7 +24726,7 @@ function create_if_block_2$8(ctx) {
|
|
|
24377
24726
|
};
|
|
24378
24727
|
}
|
|
24379
24728
|
|
|
24380
|
-
// (
|
|
24729
|
+
// (93:6) <Checkbox isFirstInvalidInput={callbackMetadata?.derived.isFirstInvalidInput || false} isInvalid={false} key={inputName} onChange={setCheckboxValue} value={false} >
|
|
24381
24730
|
function create_default_slot$h(ctx) {
|
|
24382
24731
|
let t_value = /*options*/ ctx[3][0].text + "";
|
|
24383
24732
|
let t;
|
|
@@ -24489,13 +24838,6 @@ function instance$z($$self, $$props, $$invalidate) {
|
|
|
24489
24838
|
* @param {Object} event
|
|
24490
24839
|
*/
|
|
24491
24840
|
function setOptionValue(event) {
|
|
24492
|
-
/** ***********************************************************************
|
|
24493
|
-
* SDK INTEGRATION POINT
|
|
24494
|
-
* Summary: SDK callback methods for setting values
|
|
24495
|
-
* ------------------------------------------------------------------------
|
|
24496
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
24497
|
-
* for writing values to the callbacks received from AM
|
|
24498
|
-
*********************************************************************** */
|
|
24499
24841
|
callback.setOptionIndex(Number(event.target.value));
|
|
24500
24842
|
}
|
|
24501
24843
|
|
|
@@ -24504,13 +24846,6 @@ function instance$z($$self, $$props, $$invalidate) {
|
|
|
24504
24846
|
* @param {Object} event
|
|
24505
24847
|
*/
|
|
24506
24848
|
function setCheckboxValue(event) {
|
|
24507
|
-
/** ***********************************************************************
|
|
24508
|
-
* SDK INTEGRATION POINT
|
|
24509
|
-
* Summary: SDK callback methods for setting values
|
|
24510
|
-
* ------------------------------------------------------------------------
|
|
24511
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
24512
|
-
* for writing values to the callbacks received from AM
|
|
24513
|
-
*********************************************************************** */
|
|
24514
24849
|
const value = event.target.checked;
|
|
24515
24850
|
|
|
24516
24851
|
if (value) {
|
|
@@ -24875,7 +25210,7 @@ function create_if_block_5$1(ctx) {
|
|
|
24875
25210
|
}
|
|
24876
25211
|
|
|
24877
25212
|
// (65:0) {#if type === 'number'}
|
|
24878
|
-
function create_if_block_4$
|
|
25213
|
+
function create_if_block_4$2(ctx) {
|
|
24879
25214
|
let input;
|
|
24880
25215
|
let input_aria_describedby_value;
|
|
24881
25216
|
let input_class_value;
|
|
@@ -24955,7 +25290,7 @@ function create_if_block_4$1(ctx) {
|
|
|
24955
25290
|
}
|
|
24956
25291
|
|
|
24957
25292
|
// (81:0) {#if type === 'password'}
|
|
24958
|
-
function create_if_block_3$
|
|
25293
|
+
function create_if_block_3$6(ctx) {
|
|
24959
25294
|
let input;
|
|
24960
25295
|
let input_aria_describedby_value;
|
|
24961
25296
|
let input_class_value;
|
|
@@ -25275,8 +25610,8 @@ function create_fragment$x(ctx) {
|
|
|
25275
25610
|
let if_block0 = /*labelOrder*/ ctx[6] === 'first' && create_if_block_7$1(ctx);
|
|
25276
25611
|
let if_block1 = /*type*/ ctx[11] === 'date' && create_if_block_6$1(ctx);
|
|
25277
25612
|
let if_block2 = /*type*/ ctx[11] === 'email' && create_if_block_5$1(ctx);
|
|
25278
|
-
let if_block3 = /*type*/ ctx[11] === 'number' && create_if_block_4$
|
|
25279
|
-
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);
|
|
25280
25615
|
let if_block5 = /*type*/ ctx[11] === 'phone' && create_if_block_2$7(ctx);
|
|
25281
25616
|
let if_block6 = /*type*/ ctx[11] === 'text' && create_if_block_1$8(ctx);
|
|
25282
25617
|
let if_block7 = /*labelOrder*/ ctx[6] === 'last' && create_if_block$d(ctx);
|
|
@@ -25373,7 +25708,7 @@ function create_fragment$x(ctx) {
|
|
|
25373
25708
|
if (if_block3) {
|
|
25374
25709
|
if_block3.p(ctx, dirty);
|
|
25375
25710
|
} else {
|
|
25376
|
-
if_block3 = create_if_block_4$
|
|
25711
|
+
if_block3 = create_if_block_4$2(ctx);
|
|
25377
25712
|
if_block3.c();
|
|
25378
25713
|
if_block3.m(t3.parentNode, t3);
|
|
25379
25714
|
}
|
|
@@ -25386,7 +25721,7 @@ function create_fragment$x(ctx) {
|
|
|
25386
25721
|
if (if_block4) {
|
|
25387
25722
|
if_block4.p(ctx, dirty);
|
|
25388
25723
|
} else {
|
|
25389
|
-
if_block4 = create_if_block_3$
|
|
25724
|
+
if_block4 = create_if_block_3$6(ctx);
|
|
25390
25725
|
if_block4.c();
|
|
25391
25726
|
if_block4.m(t4.parentNode, t4);
|
|
25392
25727
|
}
|
|
@@ -26522,15 +26857,7 @@ function instance$t($$self, $$props, $$invalidate) {
|
|
|
26522
26857
|
? Stacked_label$1
|
|
26523
26858
|
: Floating_label$1;
|
|
26524
26859
|
|
|
26525
|
-
/** *************************************************************************
|
|
26526
|
-
* SDK INTEGRATION POINT
|
|
26527
|
-
* Summary: SDK callback methods for getting values
|
|
26528
|
-
* --------------------------------------------------------------------------
|
|
26529
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
26530
|
-
* for accessing values from the callbacks received from AM
|
|
26531
|
-
************************************************************************* */
|
|
26532
26860
|
let customQuestionIndex = null;
|
|
26533
|
-
|
|
26534
26861
|
let displayCustomQuestionInput = false;
|
|
26535
26862
|
let inputArr;
|
|
26536
26863
|
let inputName;
|
|
@@ -26558,13 +26885,6 @@ function instance$t($$self, $$props, $$invalidate) {
|
|
|
26558
26885
|
* @param {Object} event
|
|
26559
26886
|
*/
|
|
26560
26887
|
function setAnswer(event) {
|
|
26561
|
-
/** ***********************************************************************
|
|
26562
|
-
* SDK INTEGRATION POINT
|
|
26563
|
-
* Summary: SDK callback methods for setting values
|
|
26564
|
-
* ------------------------------------------------------------------------
|
|
26565
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
26566
|
-
* for writing values to the callbacks received from AM
|
|
26567
|
-
*********************************************************************** */
|
|
26568
26888
|
callback.setAnswer(event.target.value);
|
|
26569
26889
|
}
|
|
26570
26890
|
|
|
@@ -26581,14 +26901,6 @@ function instance$t($$self, $$props, $$invalidate) {
|
|
|
26581
26901
|
callback.setAnswer('');
|
|
26582
26902
|
} else {
|
|
26583
26903
|
$$invalidate(3, displayCustomQuestionInput = false);
|
|
26584
|
-
|
|
26585
|
-
/** ***********************************************************************
|
|
26586
|
-
* SDK INTEGRATION POINT
|
|
26587
|
-
* Summary: SDK callback methods for setting values
|
|
26588
|
-
* ------------------------------------------------------------------------
|
|
26589
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
26590
|
-
* for writing values to the callbacks received from AM
|
|
26591
|
-
*********************************************************************** */
|
|
26592
26904
|
callback.setQuestion(selectValue);
|
|
26593
26905
|
}
|
|
26594
26906
|
}
|
|
@@ -26599,14 +26911,6 @@ function instance$t($$self, $$props, $$invalidate) {
|
|
|
26599
26911
|
*/
|
|
26600
26912
|
function setQuestion(event) {
|
|
26601
26913
|
const inputValue = event.target.value;
|
|
26602
|
-
|
|
26603
|
-
/** ***********************************************************************
|
|
26604
|
-
* SDK INTEGRATION POINT
|
|
26605
|
-
* Summary: SDK callback methods for setting values
|
|
26606
|
-
* ------------------------------------------------------------------------
|
|
26607
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
26608
|
-
* for writing values to the callbacks received from AM
|
|
26609
|
-
*********************************************************************** */
|
|
26610
26914
|
callback.setQuestion(inputValue);
|
|
26611
26915
|
}
|
|
26612
26916
|
|
|
@@ -27097,8 +27401,8 @@ class Eye_icon extends SvelteComponent {
|
|
|
27097
27401
|
|
|
27098
27402
|
function create_default_slot_1$8(ctx) {
|
|
27099
27403
|
let current;
|
|
27100
|
-
const default_slot_template = /*#slots*/ ctx[
|
|
27101
|
-
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);
|
|
27102
27406
|
|
|
27103
27407
|
return {
|
|
27104
27408
|
c() {
|
|
@@ -27113,15 +27417,15 @@ function create_default_slot_1$8(ctx) {
|
|
|
27113
27417
|
},
|
|
27114
27418
|
p(ctx, dirty) {
|
|
27115
27419
|
if (default_slot) {
|
|
27116
|
-
if (default_slot.p && (!current || dirty & /*$$scope*/
|
|
27420
|
+
if (default_slot.p && (!current || dirty & /*$$scope*/ 65536)) {
|
|
27117
27421
|
update_slot_base(
|
|
27118
27422
|
default_slot,
|
|
27119
27423
|
default_slot_template,
|
|
27120
27424
|
ctx,
|
|
27121
|
-
/*$$scope*/ ctx[
|
|
27425
|
+
/*$$scope*/ ctx[16],
|
|
27122
27426
|
!current
|
|
27123
|
-
? get_all_dirty_from_scope(/*$$scope*/ ctx[
|
|
27124
|
-
: 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),
|
|
27125
27429
|
null
|
|
27126
27430
|
);
|
|
27127
27431
|
}
|
|
@@ -27142,7 +27446,7 @@ function create_default_slot_1$8(ctx) {
|
|
|
27142
27446
|
};
|
|
27143
27447
|
}
|
|
27144
27448
|
|
|
27145
|
-
// (
|
|
27449
|
+
// (69:4) <EyeIcon classes="tw_password-icon dark:tw_password-icon_dark" visible={isVisible}>
|
|
27146
27450
|
function create_default_slot$f(ctx) {
|
|
27147
27451
|
let t;
|
|
27148
27452
|
let current;
|
|
@@ -27172,7 +27476,7 @@ function create_default_slot$f(ctx) {
|
|
|
27172
27476
|
};
|
|
27173
27477
|
}
|
|
27174
27478
|
|
|
27175
|
-
// (
|
|
27479
|
+
// (63:2)
|
|
27176
27480
|
function create_input_button_slot$1(ctx) {
|
|
27177
27481
|
let button;
|
|
27178
27482
|
let eyeicon;
|
|
@@ -27203,7 +27507,7 @@ function create_input_button_slot$1(ctx) {
|
|
|
27203
27507
|
current = true;
|
|
27204
27508
|
|
|
27205
27509
|
if (!mounted) {
|
|
27206
|
-
dispose = listen(button, "click", /*toggleVisibility*/ ctx[
|
|
27510
|
+
dispose = listen(button, "click", /*toggleVisibility*/ ctx[11]);
|
|
27207
27511
|
mounted = true;
|
|
27208
27512
|
}
|
|
27209
27513
|
},
|
|
@@ -27211,7 +27515,7 @@ function create_input_button_slot$1(ctx) {
|
|
|
27211
27515
|
const eyeicon_changes = {};
|
|
27212
27516
|
if (dirty & /*isVisible*/ 64) eyeicon_changes.visible = /*isVisible*/ ctx[6];
|
|
27213
27517
|
|
|
27214
|
-
if (dirty & /*$$scope*/
|
|
27518
|
+
if (dirty & /*$$scope*/ 65536) {
|
|
27215
27519
|
eyeicon_changes.$$scope = { dirty, ctx };
|
|
27216
27520
|
}
|
|
27217
27521
|
|
|
@@ -27239,23 +27543,21 @@ function create_fragment$q(ctx) {
|
|
|
27239
27543
|
let input;
|
|
27240
27544
|
let current;
|
|
27241
27545
|
|
|
27242
|
-
input = new /*Input*/ ctx[
|
|
27546
|
+
input = new /*Input*/ ctx[9]({
|
|
27243
27547
|
props: {
|
|
27244
27548
|
forceValidityFailure: /*forceValidityFailure*/ ctx[0],
|
|
27245
27549
|
isFirstInvalidInput: false,
|
|
27246
27550
|
hasRightIcon: true,
|
|
27247
|
-
key: `${/*key*/ ctx[
|
|
27551
|
+
key: `${/*key*/ ctx[3]}-confirm`,
|
|
27248
27552
|
label: interpolate('confirmPassword', null, 'Confirm Password'),
|
|
27249
|
-
message: /*
|
|
27250
|
-
|
|
27251
|
-
:
|
|
27252
|
-
|
|
27253
|
-
|
|
27254
|
-
isRequired: /*isRequired*/ ctx[4],
|
|
27255
|
-
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],
|
|
27256
27558
|
type: /*type*/ ctx[7],
|
|
27257
|
-
value: typeof /*value*/ ctx[
|
|
27258
|
-
? /*value*/ ctx[
|
|
27559
|
+
value: typeof /*value*/ ctx[5] === 'string'
|
|
27560
|
+
? /*value*/ ctx[5]
|
|
27259
27561
|
: '',
|
|
27260
27562
|
$$slots: {
|
|
27261
27563
|
"input-button": [create_input_button_slot$1],
|
|
@@ -27276,19 +27578,18 @@ function create_fragment$q(ctx) {
|
|
|
27276
27578
|
p(ctx, [dirty]) {
|
|
27277
27579
|
const input_changes = {};
|
|
27278
27580
|
if (dirty & /*forceValidityFailure*/ 1) input_changes.forceValidityFailure = /*forceValidityFailure*/ ctx[0];
|
|
27279
|
-
if (dirty & /*key*/
|
|
27280
|
-
|
|
27281
|
-
if (dirty & /*
|
|
27282
|
-
|
|
27283
|
-
|
|
27284
|
-
|
|
27285
|
-
if (dirty & /*onChange*/ 4) input_changes.onChange = /*onChange*/ ctx[2];
|
|
27286
|
-
if (dirty & /*isInvalid*/ 8) input_changes.isInvalid = /*isInvalid*/ ctx[3];
|
|
27287
|
-
if (dirty & /*isRequired*/ 16) input_changes.isRequired = /*isRequired*/ ctx[4];
|
|
27288
|
-
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];
|
|
27289
27586
|
if (dirty & /*type*/ 128) input_changes.type = /*type*/ ctx[7];
|
|
27290
27587
|
|
|
27291
|
-
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) {
|
|
27292
27593
|
input_changes.$$scope = { dirty, ctx };
|
|
27293
27594
|
}
|
|
27294
27595
|
|
|
@@ -27312,16 +27613,25 @@ function create_fragment$q(ctx) {
|
|
|
27312
27613
|
function instance$q($$self, $$props, $$invalidate) {
|
|
27313
27614
|
let { $$slots: slots = {}, $$scope } = $$props;
|
|
27314
27615
|
let { forceValidityFailure = false } = $$props;
|
|
27616
|
+
let { passwordsDoNotMatch = false } = $$props;
|
|
27617
|
+
let { isRequired = false } = $$props;
|
|
27315
27618
|
let { key } = $$props;
|
|
27316
27619
|
let { onChange } = $$props;
|
|
27317
|
-
let {
|
|
27318
|
-
let { isRequired = true } = $$props;
|
|
27620
|
+
let { resetValue } = $$props;
|
|
27319
27621
|
let { style = {} } = $$props;
|
|
27320
27622
|
const Input = style.labels === 'stacked' ? Stacked_label : Floating_label;
|
|
27321
27623
|
let { showMessage = undefined } = $$props;
|
|
27322
27624
|
let isVisible = false;
|
|
27323
27625
|
let type = 'password';
|
|
27324
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
|
+
}
|
|
27325
27635
|
|
|
27326
27636
|
/**
|
|
27327
27637
|
* @function toggleVisibility - toggles the password from masked to plaintext
|
|
@@ -27333,27 +27643,50 @@ function instance$q($$self, $$props, $$invalidate) {
|
|
|
27333
27643
|
|
|
27334
27644
|
$$self.$$set = $$props => {
|
|
27335
27645
|
if ('forceValidityFailure' in $$props) $$invalidate(0, forceValidityFailure = $$props.forceValidityFailure);
|
|
27336
|
-
if ('
|
|
27337
|
-
if ('
|
|
27338
|
-
if ('
|
|
27339
|
-
if ('
|
|
27340
|
-
if ('
|
|
27341
|
-
if ('
|
|
27342
|
-
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
|
+
}
|
|
27343
27673
|
};
|
|
27344
27674
|
|
|
27345
27675
|
return [
|
|
27346
27676
|
forceValidityFailure,
|
|
27347
|
-
|
|
27348
|
-
onChange,
|
|
27349
|
-
isInvalid,
|
|
27677
|
+
passwordsDoNotMatch,
|
|
27350
27678
|
isRequired,
|
|
27679
|
+
key,
|
|
27351
27680
|
showMessage,
|
|
27681
|
+
value,
|
|
27352
27682
|
isVisible,
|
|
27353
27683
|
type,
|
|
27684
|
+
message,
|
|
27354
27685
|
Input,
|
|
27355
|
-
|
|
27686
|
+
onChangeWrapper,
|
|
27356
27687
|
toggleVisibility,
|
|
27688
|
+
onChange,
|
|
27689
|
+
resetValue,
|
|
27357
27690
|
style,
|
|
27358
27691
|
slots,
|
|
27359
27692
|
$$scope
|
|
@@ -27366,12 +27699,13 @@ class Confirm_input extends SvelteComponent {
|
|
|
27366
27699
|
|
|
27367
27700
|
init(this, options, instance$q, create_fragment$q, safe_not_equal, {
|
|
27368
27701
|
forceValidityFailure: 0,
|
|
27369
|
-
|
|
27370
|
-
|
|
27371
|
-
|
|
27372
|
-
|
|
27373
|
-
|
|
27374
|
-
|
|
27702
|
+
passwordsDoNotMatch: 1,
|
|
27703
|
+
isRequired: 2,
|
|
27704
|
+
key: 3,
|
|
27705
|
+
onChange: 12,
|
|
27706
|
+
resetValue: 13,
|
|
27707
|
+
style: 14,
|
|
27708
|
+
showMessage: 4
|
|
27375
27709
|
});
|
|
27376
27710
|
}
|
|
27377
27711
|
}
|
|
@@ -27380,8 +27714,8 @@ class Confirm_input extends SvelteComponent {
|
|
|
27380
27714
|
|
|
27381
27715
|
function create_default_slot_1$7(ctx) {
|
|
27382
27716
|
let current;
|
|
27383
|
-
const default_slot_template = /*#slots*/ ctx[
|
|
27384
|
-
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);
|
|
27385
27719
|
|
|
27386
27720
|
return {
|
|
27387
27721
|
c() {
|
|
@@ -27396,15 +27730,15 @@ function create_default_slot_1$7(ctx) {
|
|
|
27396
27730
|
},
|
|
27397
27731
|
p(ctx, dirty) {
|
|
27398
27732
|
if (default_slot) {
|
|
27399
|
-
if (default_slot.p && (!current || dirty & /*$$scope*/
|
|
27733
|
+
if (default_slot.p && (!current || dirty & /*$$scope*/ 4194304)) {
|
|
27400
27734
|
update_slot_base(
|
|
27401
27735
|
default_slot,
|
|
27402
27736
|
default_slot_template,
|
|
27403
27737
|
ctx,
|
|
27404
|
-
/*$$scope*/ ctx[
|
|
27738
|
+
/*$$scope*/ ctx[22],
|
|
27405
27739
|
!current
|
|
27406
|
-
? get_all_dirty_from_scope(/*$$scope*/ ctx[
|
|
27407
|
-
: 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),
|
|
27408
27742
|
null
|
|
27409
27743
|
);
|
|
27410
27744
|
}
|
|
@@ -27425,7 +27759,7 @@ function create_default_slot_1$7(ctx) {
|
|
|
27425
27759
|
};
|
|
27426
27760
|
}
|
|
27427
27761
|
|
|
27428
|
-
// (
|
|
27762
|
+
// (94:4) <EyeIcon classes="tw_password-icon dark:tw_password-icon_dark" visible={isVisible}>
|
|
27429
27763
|
function create_default_slot$e(ctx) {
|
|
27430
27764
|
let t;
|
|
27431
27765
|
let current;
|
|
@@ -27455,7 +27789,7 @@ function create_default_slot$e(ctx) {
|
|
|
27455
27789
|
};
|
|
27456
27790
|
}
|
|
27457
27791
|
|
|
27458
|
-
// (
|
|
27792
|
+
// (88:2)
|
|
27459
27793
|
function create_input_button_slot(ctx) {
|
|
27460
27794
|
let button;
|
|
27461
27795
|
let eyeicon;
|
|
@@ -27486,7 +27820,7 @@ function create_input_button_slot(ctx) {
|
|
|
27486
27820
|
current = true;
|
|
27487
27821
|
|
|
27488
27822
|
if (!mounted) {
|
|
27489
|
-
dispose = listen(button, "click", /*toggleVisibility*/ ctx[
|
|
27823
|
+
dispose = listen(button, "click", /*toggleVisibility*/ ctx[17]);
|
|
27490
27824
|
mounted = true;
|
|
27491
27825
|
}
|
|
27492
27826
|
},
|
|
@@ -27494,7 +27828,7 @@ function create_input_button_slot(ctx) {
|
|
|
27494
27828
|
const eyeicon_changes = {};
|
|
27495
27829
|
if (dirty & /*isVisible*/ 1024) eyeicon_changes.visible = /*isVisible*/ ctx[10];
|
|
27496
27830
|
|
|
27497
|
-
if (dirty & /*$$scope*/
|
|
27831
|
+
if (dirty & /*$$scope*/ 4194304) {
|
|
27498
27832
|
eyeicon_changes.$$scope = { dirty, ctx };
|
|
27499
27833
|
}
|
|
27500
27834
|
|
|
@@ -27518,7 +27852,7 @@ function create_input_button_slot(ctx) {
|
|
|
27518
27852
|
};
|
|
27519
27853
|
}
|
|
27520
27854
|
|
|
27521
|
-
// (
|
|
27855
|
+
// (101:0) {#if callbackMetadata?.platform?.confirmPassword}
|
|
27522
27856
|
function create_if_block$a(ctx) {
|
|
27523
27857
|
let confirminput;
|
|
27524
27858
|
let current;
|
|
@@ -27526,9 +27860,11 @@ function create_if_block$a(ctx) {
|
|
|
27526
27860
|
confirminput = new Confirm_input({
|
|
27527
27861
|
props: {
|
|
27528
27862
|
forceValidityFailure: /*doPasswordsMatch*/ ctx[9] === false,
|
|
27529
|
-
|
|
27863
|
+
passwordsDoNotMatch: /*doPasswordsMatch*/ ctx[9] === false,
|
|
27530
27864
|
key: /*key*/ ctx[0],
|
|
27531
|
-
|
|
27865
|
+
isRequired: /*value*/ ctx[7].length > 0,
|
|
27866
|
+
onChange: /*confirmInput*/ ctx[15],
|
|
27867
|
+
resetValue: /*resetValue*/ ctx[11],
|
|
27532
27868
|
showMessage: /*doPasswordsMatch*/ ctx[9] === false,
|
|
27533
27869
|
style: /*style*/ ctx[4]
|
|
27534
27870
|
}
|
|
@@ -27545,8 +27881,10 @@ function create_if_block$a(ctx) {
|
|
|
27545
27881
|
p(ctx, dirty) {
|
|
27546
27882
|
const confirminput_changes = {};
|
|
27547
27883
|
if (dirty & /*doPasswordsMatch*/ 512) confirminput_changes.forceValidityFailure = /*doPasswordsMatch*/ ctx[9] === false;
|
|
27548
|
-
if (dirty & /*doPasswordsMatch*/ 512) confirminput_changes.
|
|
27884
|
+
if (dirty & /*doPasswordsMatch*/ 512) confirminput_changes.passwordsDoNotMatch = /*doPasswordsMatch*/ ctx[9] === false;
|
|
27549
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];
|
|
27550
27888
|
if (dirty & /*doPasswordsMatch*/ 512) confirminput_changes.showMessage = /*doPasswordsMatch*/ ctx[9] === false;
|
|
27551
27889
|
if (dirty & /*style*/ 16) confirminput_changes.style = /*style*/ ctx[4];
|
|
27552
27890
|
confirminput.$set(confirminput_changes);
|
|
@@ -27572,20 +27910,20 @@ function create_fragment$p(ctx) {
|
|
|
27572
27910
|
let if_block_anchor;
|
|
27573
27911
|
let current;
|
|
27574
27912
|
|
|
27575
|
-
input = new /*Input*/ ctx[
|
|
27913
|
+
input = new /*Input*/ ctx[14]({
|
|
27576
27914
|
props: {
|
|
27577
27915
|
isFirstInvalidInput: /*callbackMetadata*/ ctx[1]?.derived.isFirstInvalidInput || false,
|
|
27578
27916
|
hasRightIcon: true,
|
|
27579
27917
|
key: /*key*/ ctx[0],
|
|
27580
|
-
label: interpolate(textToKey(/*callbackType*/ ctx[8]), null, /*textInputLabel*/ ctx[
|
|
27918
|
+
label: interpolate(textToKey(/*callbackType*/ ctx[8]), null, /*textInputLabel*/ ctx[12]),
|
|
27581
27919
|
message: /*validationFailure*/ ctx[6] || (/*isRequired*/ ctx[3]
|
|
27582
27920
|
? interpolate('inputRequiredError')
|
|
27583
27921
|
: undefined),
|
|
27584
|
-
onChange: /*setValue*/ ctx[
|
|
27922
|
+
onChange: /*setValue*/ ctx[16],
|
|
27585
27923
|
isInvalid: /*isInvalid*/ ctx[2],
|
|
27586
27924
|
isRequired: /*isRequired*/ ctx[3],
|
|
27587
27925
|
showMessage: /*showMessage*/ ctx[5],
|
|
27588
|
-
type: /*type*/ ctx[
|
|
27926
|
+
type: /*type*/ ctx[13],
|
|
27589
27927
|
value: typeof /*value*/ ctx[7] === 'string'
|
|
27590
27928
|
? /*value*/ ctx[7]
|
|
27591
27929
|
: '',
|
|
@@ -27617,7 +27955,7 @@ function create_fragment$p(ctx) {
|
|
|
27617
27955
|
const input_changes = {};
|
|
27618
27956
|
if (dirty & /*callbackMetadata*/ 2) input_changes.isFirstInvalidInput = /*callbackMetadata*/ ctx[1]?.derived.isFirstInvalidInput || false;
|
|
27619
27957
|
if (dirty & /*key*/ 1) input_changes.key = /*key*/ ctx[0];
|
|
27620
|
-
if (dirty & /*callbackType, textInputLabel*/
|
|
27958
|
+
if (dirty & /*callbackType, textInputLabel*/ 4352) input_changes.label = interpolate(textToKey(/*callbackType*/ ctx[8]), null, /*textInputLabel*/ ctx[12]);
|
|
27621
27959
|
|
|
27622
27960
|
if (dirty & /*validationFailure, isRequired*/ 72) input_changes.message = /*validationFailure*/ ctx[6] || (/*isRequired*/ ctx[3]
|
|
27623
27961
|
? interpolate('inputRequiredError')
|
|
@@ -27626,13 +27964,13 @@ function create_fragment$p(ctx) {
|
|
|
27626
27964
|
if (dirty & /*isInvalid*/ 4) input_changes.isInvalid = /*isInvalid*/ ctx[2];
|
|
27627
27965
|
if (dirty & /*isRequired*/ 8) input_changes.isRequired = /*isRequired*/ ctx[3];
|
|
27628
27966
|
if (dirty & /*showMessage*/ 32) input_changes.showMessage = /*showMessage*/ ctx[5];
|
|
27629
|
-
if (dirty & /*type*/
|
|
27967
|
+
if (dirty & /*type*/ 8192) input_changes.type = /*type*/ ctx[13];
|
|
27630
27968
|
|
|
27631
27969
|
if (dirty & /*value*/ 128) input_changes.value = typeof /*value*/ ctx[7] === 'string'
|
|
27632
27970
|
? /*value*/ ctx[7]
|
|
27633
27971
|
: '';
|
|
27634
27972
|
|
|
27635
|
-
if (dirty & /*$$scope, isVisible*/
|
|
27973
|
+
if (dirty & /*$$scope, isVisible*/ 4195328) {
|
|
27636
27974
|
input_changes.$$scope = { dirty, ctx };
|
|
27637
27975
|
}
|
|
27638
27976
|
|
|
@@ -27696,6 +28034,8 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27696
28034
|
let callbackType;
|
|
27697
28035
|
let doPasswordsMatch;
|
|
27698
28036
|
let isVisible = false;
|
|
28037
|
+
let resetValue = false;
|
|
28038
|
+
let savedValue = '';
|
|
27699
28039
|
let textInputLabel;
|
|
27700
28040
|
let type = 'password';
|
|
27701
28041
|
let value;
|
|
@@ -27704,8 +28044,8 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27704
28044
|
* @function confirmInput - ensures the second password input matches the first
|
|
27705
28045
|
* @param event
|
|
27706
28046
|
*/
|
|
27707
|
-
function confirmInput(
|
|
27708
|
-
$$invalidate(
|
|
28047
|
+
function confirmInput(val) {
|
|
28048
|
+
$$invalidate(19, confirmValue = val);
|
|
27709
28049
|
}
|
|
27710
28050
|
|
|
27711
28051
|
/**
|
|
@@ -27723,6 +28063,8 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27723
28063
|
* for writing values to the callbacks received from AM
|
|
27724
28064
|
*********************************************************************** */
|
|
27725
28065
|
callback.setInputValue(value);
|
|
28066
|
+
|
|
28067
|
+
$$invalidate(20, savedValue = String(value));
|
|
27726
28068
|
}
|
|
27727
28069
|
|
|
27728
28070
|
/**
|
|
@@ -27730,11 +28072,11 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27730
28072
|
*/
|
|
27731
28073
|
function toggleVisibility() {
|
|
27732
28074
|
$$invalidate(10, isVisible = !isVisible);
|
|
27733
|
-
$$invalidate(
|
|
28075
|
+
$$invalidate(13, type = isVisible ? 'text' : 'password');
|
|
27734
28076
|
}
|
|
27735
28077
|
|
|
27736
28078
|
$$self.$$set = $$props => {
|
|
27737
|
-
if ('callback' in $$props) $$invalidate(
|
|
28079
|
+
if ('callback' in $$props) $$invalidate(18, callback = $$props.callback);
|
|
27738
28080
|
if ('callbackMetadata' in $$props) $$invalidate(1, callbackMetadata = $$props.callbackMetadata);
|
|
27739
28081
|
if ('key' in $$props) $$invalidate(0, key = $$props.key);
|
|
27740
28082
|
if ('isInvalid' in $$props) $$invalidate(2, isInvalid = $$props.isInvalid);
|
|
@@ -27742,18 +28084,28 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27742
28084
|
if ('style' in $$props) $$invalidate(4, style = $$props.style);
|
|
27743
28085
|
if ('showMessage' in $$props) $$invalidate(5, showMessage = $$props.showMessage);
|
|
27744
28086
|
if ('validationFailure' in $$props) $$invalidate(6, validationFailure = $$props.validationFailure);
|
|
27745
|
-
if ('$$scope' in $$props) $$invalidate(
|
|
28087
|
+
if ('$$scope' in $$props) $$invalidate(22, $$scope = $$props.$$scope);
|
|
27746
28088
|
};
|
|
27747
28089
|
|
|
27748
28090
|
$$self.$$.update = () => {
|
|
27749
|
-
if ($$self.$$.dirty & /*callback, callbackMetadata,
|
|
28091
|
+
if ($$self.$$.dirty & /*callback, callbackMetadata, savedValue, value, confirmValue*/ 1835138) {
|
|
27750
28092
|
{
|
|
27751
28093
|
$$invalidate(8, callbackType = callback.getType());
|
|
27752
28094
|
$$invalidate(0, key = callback?.payload?.input?.[0].name || `password-${callbackMetadata?.idx}`);
|
|
27753
|
-
$$invalidate(
|
|
28095
|
+
$$invalidate(12, textInputLabel = callback.getPrompt());
|
|
27754
28096
|
$$invalidate(7, value = callback?.getInputValue());
|
|
27755
28097
|
|
|
27756
|
-
|
|
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
|
+
*/
|
|
27757
28109
|
$$invalidate(9, doPasswordsMatch = confirmValue !== undefined
|
|
27758
28110
|
? confirmValue === value
|
|
27759
28111
|
: undefined);
|
|
@@ -27773,6 +28125,7 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27773
28125
|
callbackType,
|
|
27774
28126
|
doPasswordsMatch,
|
|
27775
28127
|
isVisible,
|
|
28128
|
+
resetValue,
|
|
27776
28129
|
textInputLabel,
|
|
27777
28130
|
type,
|
|
27778
28131
|
Input,
|
|
@@ -27781,6 +28134,7 @@ function instance$p($$self, $$props, $$invalidate) {
|
|
|
27781
28134
|
toggleVisibility,
|
|
27782
28135
|
callback,
|
|
27783
28136
|
confirmValue,
|
|
28137
|
+
savedValue,
|
|
27784
28138
|
slots,
|
|
27785
28139
|
$$scope
|
|
27786
28140
|
];
|
|
@@ -27791,7 +28145,7 @@ class Base extends SvelteComponent {
|
|
|
27791
28145
|
super();
|
|
27792
28146
|
|
|
27793
28147
|
init(this, options, instance$p, create_fragment$p, safe_not_equal, {
|
|
27794
|
-
callback:
|
|
28148
|
+
callback: 18,
|
|
27795
28149
|
callbackMetadata: 1,
|
|
27796
28150
|
key: 0,
|
|
27797
28151
|
isInvalid: 2,
|
|
@@ -28483,7 +28837,7 @@ function get_each_context$5(ctx, list, i) {
|
|
|
28483
28837
|
}
|
|
28484
28838
|
|
|
28485
28839
|
// (66:56)
|
|
28486
|
-
function create_if_block_3$
|
|
28840
|
+
function create_if_block_3$5(ctx) {
|
|
28487
28841
|
let button;
|
|
28488
28842
|
let current;
|
|
28489
28843
|
|
|
@@ -28827,7 +29181,7 @@ function create_default_slot_1$6(ctx) {
|
|
|
28827
29181
|
let if_block;
|
|
28828
29182
|
let if_block_anchor;
|
|
28829
29183
|
let current;
|
|
28830
|
-
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];
|
|
28831
29185
|
const if_blocks = [];
|
|
28832
29186
|
|
|
28833
29187
|
function select_block_type(ctx, dirty) {
|
|
@@ -29218,17 +29572,17 @@ class Select_idp extends SvelteComponent {
|
|
|
29218
29572
|
|
|
29219
29573
|
function get_each_context_1(ctx, list, i) {
|
|
29220
29574
|
const child_ctx = ctx.slice();
|
|
29221
|
-
child_ctx[
|
|
29575
|
+
child_ctx[11] = list[i];
|
|
29222
29576
|
return child_ctx;
|
|
29223
29577
|
}
|
|
29224
29578
|
|
|
29225
29579
|
function get_each_context$4(ctx, list, i) {
|
|
29226
29580
|
const child_ctx = ctx.slice();
|
|
29227
|
-
child_ctx[
|
|
29581
|
+
child_ctx[8] = list[i];
|
|
29228
29582
|
return child_ctx;
|
|
29229
29583
|
}
|
|
29230
29584
|
|
|
29231
|
-
// (
|
|
29585
|
+
// (35:51)
|
|
29232
29586
|
function create_if_block_1$6(ctx) {
|
|
29233
29587
|
let div;
|
|
29234
29588
|
let p;
|
|
@@ -29238,7 +29592,7 @@ function create_if_block_1$6(ctx) {
|
|
|
29238
29592
|
let div_id_value;
|
|
29239
29593
|
let current;
|
|
29240
29594
|
t0 = new Locale_strings({ props: { key: /*messageKey*/ ctx[1] } });
|
|
29241
|
-
let each_value_1 = /*validationRules*/ ctx[
|
|
29595
|
+
let each_value_1 = /*validationRules*/ ctx[3];
|
|
29242
29596
|
let each_blocks = [];
|
|
29243
29597
|
|
|
29244
29598
|
for (let i = 0; i < each_value_1.length; i += 1) {
|
|
@@ -29280,8 +29634,8 @@ function create_if_block_1$6(ctx) {
|
|
|
29280
29634
|
if (dirty & /*messageKey*/ 2) t0_changes.key = /*messageKey*/ ctx[1];
|
|
29281
29635
|
t0.$set(t0_changes);
|
|
29282
29636
|
|
|
29283
|
-
if (dirty & /*validationRules*/
|
|
29284
|
-
each_value_1 = /*validationRules*/ ctx[
|
|
29637
|
+
if (dirty & /*validationRules*/ 8) {
|
|
29638
|
+
each_value_1 = /*validationRules*/ ctx[3];
|
|
29285
29639
|
let i;
|
|
29286
29640
|
|
|
29287
29641
|
for (i = 0; i < each_value_1.length; i += 1) {
|
|
@@ -29324,7 +29678,7 @@ function create_if_block_1$6(ctx) {
|
|
|
29324
29678
|
};
|
|
29325
29679
|
}
|
|
29326
29680
|
|
|
29327
|
-
// (
|
|
29681
|
+
// (24:0) {#if simplifiedFailures.length}
|
|
29328
29682
|
function create_if_block$8(ctx) {
|
|
29329
29683
|
let div;
|
|
29330
29684
|
let p;
|
|
@@ -29334,7 +29688,7 @@ function create_if_block$8(ctx) {
|
|
|
29334
29688
|
let div_id_value;
|
|
29335
29689
|
let current;
|
|
29336
29690
|
t0 = new Locale_strings({ props: { key: /*messageKey*/ ctx[1] } });
|
|
29337
|
-
let each_value = /*simplifiedFailures*/ ctx[
|
|
29691
|
+
let each_value = /*simplifiedFailures*/ ctx[4];
|
|
29338
29692
|
let each_blocks = [];
|
|
29339
29693
|
|
|
29340
29694
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -29376,8 +29730,8 @@ function create_if_block$8(ctx) {
|
|
|
29376
29730
|
if (dirty & /*messageKey*/ 2) t0_changes.key = /*messageKey*/ ctx[1];
|
|
29377
29731
|
t0.$set(t0_changes);
|
|
29378
29732
|
|
|
29379
|
-
if (dirty & /*simplifiedFailures*/
|
|
29380
|
-
each_value = /*simplifiedFailures*/ ctx[
|
|
29733
|
+
if (dirty & /*simplifiedFailures*/ 16) {
|
|
29734
|
+
each_value = /*simplifiedFailures*/ ctx[4];
|
|
29381
29735
|
let i;
|
|
29382
29736
|
|
|
29383
29737
|
for (i = 0; i < each_value.length; i += 1) {
|
|
@@ -29420,10 +29774,10 @@ function create_if_block$8(ctx) {
|
|
|
29420
29774
|
};
|
|
29421
29775
|
}
|
|
29422
29776
|
|
|
29423
|
-
// (
|
|
29777
|
+
// (41:6) {#each validationRules as rule}
|
|
29424
29778
|
function create_each_block_1(ctx) {
|
|
29425
29779
|
let li;
|
|
29426
|
-
let t_value = /*rule*/ ctx[
|
|
29780
|
+
let t_value = /*rule*/ ctx[11].message + "";
|
|
29427
29781
|
let t;
|
|
29428
29782
|
|
|
29429
29783
|
return {
|
|
@@ -29437,7 +29791,7 @@ function create_each_block_1(ctx) {
|
|
|
29437
29791
|
append(li, t);
|
|
29438
29792
|
},
|
|
29439
29793
|
p(ctx, dirty) {
|
|
29440
|
-
if (dirty & /*validationRules*/
|
|
29794
|
+
if (dirty & /*validationRules*/ 8 && t_value !== (t_value = /*rule*/ ctx[11].message + "")) set_data(t, t_value);
|
|
29441
29795
|
},
|
|
29442
29796
|
d(detaching) {
|
|
29443
29797
|
if (detaching) detach(li);
|
|
@@ -29445,10 +29799,10 @@ function create_each_block_1(ctx) {
|
|
|
29445
29799
|
};
|
|
29446
29800
|
}
|
|
29447
29801
|
|
|
29448
|
-
// (
|
|
29802
|
+
// (30:6) {#each simplifiedFailures as failure}
|
|
29449
29803
|
function create_each_block$4(ctx) {
|
|
29450
29804
|
let li;
|
|
29451
|
-
let t_value = /*failure*/ ctx[
|
|
29805
|
+
let t_value = /*failure*/ ctx[8].message + "";
|
|
29452
29806
|
let t;
|
|
29453
29807
|
|
|
29454
29808
|
return {
|
|
@@ -29462,7 +29816,7 @@ function create_each_block$4(ctx) {
|
|
|
29462
29816
|
append(li, t);
|
|
29463
29817
|
},
|
|
29464
29818
|
p(ctx, dirty) {
|
|
29465
|
-
if (dirty & /*simplifiedFailures*/
|
|
29819
|
+
if (dirty & /*simplifiedFailures*/ 16 && t_value !== (t_value = /*failure*/ ctx[8].message + "")) set_data(t, t_value);
|
|
29466
29820
|
},
|
|
29467
29821
|
d(detaching) {
|
|
29468
29822
|
if (detaching) detach(li);
|
|
@@ -29479,8 +29833,8 @@ function create_fragment$g(ctx) {
|
|
|
29479
29833
|
const if_blocks = [];
|
|
29480
29834
|
|
|
29481
29835
|
function select_block_type(ctx, dirty) {
|
|
29482
|
-
if (/*simplifiedFailures*/ ctx[
|
|
29483
|
-
if (/*
|
|
29836
|
+
if (/*simplifiedFailures*/ ctx[4].length) return 0;
|
|
29837
|
+
if (/*showPolicies*/ ctx[2] && /*validationRules*/ ctx[3].length) return 1;
|
|
29484
29838
|
return -1;
|
|
29485
29839
|
}
|
|
29486
29840
|
|
|
@@ -29561,6 +29915,7 @@ function instance$g($$self, $$props, $$invalidate) {
|
|
|
29561
29915
|
let { key = undefined } = $$props;
|
|
29562
29916
|
let { label } = $$props;
|
|
29563
29917
|
let { messageKey } = $$props;
|
|
29918
|
+
let { showPolicies = false } = $$props;
|
|
29564
29919
|
let validationFailures = getValidationFailures(callback, label);
|
|
29565
29920
|
let validationRules = getValidationPolicies(callback.getPolicies());
|
|
29566
29921
|
|
|
@@ -29573,19 +29928,20 @@ function instance$g($$self, $$props, $$invalidate) {
|
|
|
29573
29928
|
);
|
|
29574
29929
|
|
|
29575
29930
|
$$self.$$set = $$props => {
|
|
29576
|
-
if ('callback' in $$props) $$invalidate(
|
|
29931
|
+
if ('callback' in $$props) $$invalidate(5, callback = $$props.callback);
|
|
29577
29932
|
if ('key' in $$props) $$invalidate(0, key = $$props.key);
|
|
29578
|
-
if ('label' in $$props) $$invalidate(
|
|
29933
|
+
if ('label' in $$props) $$invalidate(6, label = $$props.label);
|
|
29579
29934
|
if ('messageKey' in $$props) $$invalidate(1, messageKey = $$props.messageKey);
|
|
29935
|
+
if ('showPolicies' in $$props) $$invalidate(2, showPolicies = $$props.showPolicies);
|
|
29580
29936
|
};
|
|
29581
29937
|
|
|
29582
29938
|
$$self.$$.update = () => {
|
|
29583
|
-
if ($$self.$$.dirty & /*callback, label, validationFailures*/
|
|
29939
|
+
if ($$self.$$.dirty & /*callback, label, validationFailures*/ 224) {
|
|
29584
29940
|
{
|
|
29585
|
-
$$invalidate(
|
|
29586
|
-
$$invalidate(
|
|
29941
|
+
$$invalidate(7, validationFailures = getValidationFailures(callback, label));
|
|
29942
|
+
$$invalidate(3, validationRules = getValidationPolicies(callback.getPolicies()));
|
|
29587
29943
|
|
|
29588
|
-
$$invalidate(
|
|
29944
|
+
$$invalidate(4, simplifiedFailures = validationFailures.reduce(
|
|
29589
29945
|
(prev, curr) => {
|
|
29590
29946
|
prev = prev.concat(curr.restructured);
|
|
29591
29947
|
return prev;
|
|
@@ -29599,6 +29955,7 @@ function instance$g($$self, $$props, $$invalidate) {
|
|
|
29599
29955
|
return [
|
|
29600
29956
|
key,
|
|
29601
29957
|
messageKey,
|
|
29958
|
+
showPolicies,
|
|
29602
29959
|
validationRules,
|
|
29603
29960
|
simplifiedFailures,
|
|
29604
29961
|
callback,
|
|
@@ -29612,10 +29969,11 @@ class Policies extends SvelteComponent {
|
|
|
29612
29969
|
super();
|
|
29613
29970
|
|
|
29614
29971
|
init(this, options, instance$g, create_fragment$g, safe_not_equal, {
|
|
29615
|
-
callback:
|
|
29972
|
+
callback: 5,
|
|
29616
29973
|
key: 0,
|
|
29617
|
-
label:
|
|
29618
|
-
messageKey: 1
|
|
29974
|
+
label: 6,
|
|
29975
|
+
messageKey: 1,
|
|
29976
|
+
showPolicies: 2
|
|
29619
29977
|
});
|
|
29620
29978
|
}
|
|
29621
29979
|
}
|
|
@@ -29755,13 +30113,6 @@ function instance$f($$self, $$props, $$invalidate) {
|
|
|
29755
30113
|
* @param {Object} event
|
|
29756
30114
|
*/
|
|
29757
30115
|
function setValue(event) {
|
|
29758
|
-
/** ***********************************************************************
|
|
29759
|
-
* SDK INTEGRATION POINT
|
|
29760
|
-
* Summary: SDK callback methods for setting values
|
|
29761
|
-
* ------------------------------------------------------------------------
|
|
29762
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
29763
|
-
* for writing values to the callbacks received from AM
|
|
29764
|
-
*********************************************************************** */
|
|
29765
30116
|
callback.setInputValue(event.target.value);
|
|
29766
30117
|
}
|
|
29767
30118
|
|
|
@@ -29950,7 +30301,7 @@ function create_else_block$3(ctx) {
|
|
|
29950
30301
|
};
|
|
29951
30302
|
}
|
|
29952
30303
|
|
|
29953
|
-
// (
|
|
30304
|
+
// (27:0) {#if $linksStore?.termsAndConditions}
|
|
29954
30305
|
function create_if_block$7(ctx) {
|
|
29955
30306
|
let link;
|
|
29956
30307
|
let t;
|
|
@@ -30028,7 +30379,7 @@ function create_if_block$7(ctx) {
|
|
|
30028
30379
|
};
|
|
30029
30380
|
}
|
|
30030
30381
|
|
|
30031
|
-
// (
|
|
30382
|
+
// (28:2) <Link classes="tw_block tw_mb-4" href={$linksStore?.termsAndConditions} target="_blank">
|
|
30032
30383
|
function create_default_slot_1$5(ctx) {
|
|
30033
30384
|
let t_value = interpolate('termsAndConditionsLinkText') + "";
|
|
30034
30385
|
let t;
|
|
@@ -30047,7 +30398,7 @@ function create_default_slot_1$5(ctx) {
|
|
|
30047
30398
|
};
|
|
30048
30399
|
}
|
|
30049
30400
|
|
|
30050
|
-
// (
|
|
30401
|
+
// (31:2) <Checkbox isFirstInvalidInput={callbackMetadata?.derived.isFirstInvalidInput || false} key={inputName} onChange={setValue} value={false} >
|
|
30051
30402
|
function create_default_slot$9(ctx) {
|
|
30052
30403
|
let t;
|
|
30053
30404
|
let current;
|
|
@@ -30155,13 +30506,6 @@ function instance$d($$self, $$props, $$invalidate) {
|
|
|
30155
30506
|
let { callback } = $$props;
|
|
30156
30507
|
let { callbackMetadata } = $$props;
|
|
30157
30508
|
|
|
30158
|
-
/** *************************************************************************
|
|
30159
|
-
* SDK INTEGRATION POINT
|
|
30160
|
-
* Summary: SDK callback methods for getting values
|
|
30161
|
-
* --------------------------------------------------------------------------
|
|
30162
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
30163
|
-
* for accessing values from the callbacks received from AM
|
|
30164
|
-
************************************************************************* */
|
|
30165
30509
|
const Checkbox = style.checksAndRadios === 'standard'
|
|
30166
30510
|
? Standard$1
|
|
30167
30511
|
: Animated$1;
|
|
@@ -30173,13 +30517,6 @@ function instance$d($$self, $$props, $$invalidate) {
|
|
|
30173
30517
|
* @param {Object} event
|
|
30174
30518
|
*/
|
|
30175
30519
|
function setValue(event) {
|
|
30176
|
-
/** ***********************************************************************
|
|
30177
|
-
* SDK INTEGRATION POINT
|
|
30178
|
-
* Summary: SDK callback methods for setting values
|
|
30179
|
-
* ------------------------------------------------------------------------
|
|
30180
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
30181
|
-
* for writing values to the callbacks received from AM
|
|
30182
|
-
*********************************************************************** */
|
|
30183
30520
|
callback.setAccepted(event.target.checked);
|
|
30184
30521
|
}
|
|
30185
30522
|
|
|
@@ -30443,7 +30780,8 @@ function create_default_slot$7(ctx) {
|
|
|
30443
30780
|
props: {
|
|
30444
30781
|
callback: /*callback*/ ctx[0],
|
|
30445
30782
|
label: /*prompt*/ ctx[3],
|
|
30446
|
-
messageKey: "passwordRequirements"
|
|
30783
|
+
messageKey: "passwordRequirements",
|
|
30784
|
+
showPolicies: true
|
|
30447
30785
|
}
|
|
30448
30786
|
});
|
|
30449
30787
|
|
|
@@ -30737,13 +31075,6 @@ function instance$9($$self, $$props, $$invalidate) {
|
|
|
30737
31075
|
* @param {Object} event
|
|
30738
31076
|
*/
|
|
30739
31077
|
function setValue(event) {
|
|
30740
|
-
/** ***********************************************************************
|
|
30741
|
-
* SDK INTEGRATION POINT
|
|
30742
|
-
* Summary: SDK callback methods for setting values
|
|
30743
|
-
* ------------------------------------------------------------------------
|
|
30744
|
-
* Details: Each callback is wrapped by the SDK to provide helper methods
|
|
30745
|
-
* for writing values to the callbacks received from AM
|
|
30746
|
-
*********************************************************************** */
|
|
30747
31078
|
callback.setInputValue(event.target.value);
|
|
30748
31079
|
}
|
|
30749
31080
|
|
|
@@ -31530,7 +31861,7 @@ function create_if_block_5(ctx) {
|
|
|
31530
31861
|
}
|
|
31531
31862
|
|
|
31532
31863
|
// (126:52)
|
|
31533
|
-
function create_if_block_4(ctx) {
|
|
31864
|
+
function create_if_block_4$1(ctx) {
|
|
31534
31865
|
let kbacreate;
|
|
31535
31866
|
let current;
|
|
31536
31867
|
const kbacreate_spread_levels = [/*newProps*/ ctx[19]];
|
|
@@ -31573,7 +31904,7 @@ function create_if_block_4(ctx) {
|
|
|
31573
31904
|
}
|
|
31574
31905
|
|
|
31575
31906
|
// (120:54)
|
|
31576
|
-
function create_if_block_3$
|
|
31907
|
+
function create_if_block_3$4(ctx) {
|
|
31577
31908
|
let hiddenvalue;
|
|
31578
31909
|
let current;
|
|
31579
31910
|
const hiddenvalue_spread_levels = [/*newProps*/ ctx[19]];
|
|
@@ -31754,8 +32085,8 @@ function create_fragment$8(ctx) {
|
|
|
31754
32085
|
create_if_block$6,
|
|
31755
32086
|
create_if_block_1$5,
|
|
31756
32087
|
create_if_block_2$5,
|
|
31757
|
-
create_if_block_3$
|
|
31758
|
-
create_if_block_4,
|
|
32088
|
+
create_if_block_3$4,
|
|
32089
|
+
create_if_block_4$1,
|
|
31759
32090
|
create_if_block_5,
|
|
31760
32091
|
create_if_block_6,
|
|
31761
32092
|
create_if_block_7,
|
|
@@ -31988,12 +32319,12 @@ class Callback_mapper extends SvelteComponent {
|
|
|
31988
32319
|
|
|
31989
32320
|
function get_each_context$3(ctx, list, i) {
|
|
31990
32321
|
const child_ctx = ctx.slice();
|
|
31991
|
-
child_ctx[
|
|
31992
|
-
child_ctx[
|
|
32322
|
+
child_ctx[16] = list[i];
|
|
32323
|
+
child_ctx[18] = i;
|
|
31993
32324
|
return child_ctx;
|
|
31994
32325
|
}
|
|
31995
32326
|
|
|
31996
|
-
// (70:2) {#if form?.icon}
|
|
32327
|
+
// (70:2) {#if form?.icon && componentStyle !== 'inline'}
|
|
31997
32328
|
function create_if_block_2$4(ctx) {
|
|
31998
32329
|
let div;
|
|
31999
32330
|
let shieldicon;
|
|
@@ -32041,7 +32372,7 @@ function create_if_block_1$4(ctx) {
|
|
|
32041
32372
|
alert = new Alert({
|
|
32042
32373
|
props: {
|
|
32043
32374
|
id: formFailureMessageId,
|
|
32044
|
-
needsFocus: /*alertNeedsFocus*/ ctx[
|
|
32375
|
+
needsFocus: /*alertNeedsFocus*/ ctx[6],
|
|
32045
32376
|
type: "error",
|
|
32046
32377
|
$$slots: { default: [create_default_slot_2$3] },
|
|
32047
32378
|
$$scope: { ctx }
|
|
@@ -32058,9 +32389,9 @@ function create_if_block_1$4(ctx) {
|
|
|
32058
32389
|
},
|
|
32059
32390
|
p(ctx, dirty) {
|
|
32060
32391
|
const alert_changes = {};
|
|
32061
|
-
if (dirty & /*alertNeedsFocus*/
|
|
32392
|
+
if (dirty & /*alertNeedsFocus*/ 64) alert_changes.needsFocus = /*alertNeedsFocus*/ ctx[6];
|
|
32062
32393
|
|
|
32063
|
-
if (dirty & /*$$scope, formMessageKey, form*/
|
|
32394
|
+
if (dirty & /*$$scope, formMessageKey, form*/ 524420) {
|
|
32064
32395
|
alert_changes.$$scope = { dirty, ctx };
|
|
32065
32396
|
}
|
|
32066
32397
|
|
|
@@ -32083,7 +32414,7 @@ function create_if_block_1$4(ctx) {
|
|
|
32083
32414
|
|
|
32084
32415
|
// (87:4) <Alert id={formFailureMessageId} needsFocus={alertNeedsFocus} type="error">
|
|
32085
32416
|
function create_default_slot_2$3(ctx) {
|
|
32086
|
-
let t_value = interpolate(/*formMessageKey*/ ctx[
|
|
32417
|
+
let t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "";
|
|
32087
32418
|
let t;
|
|
32088
32419
|
|
|
32089
32420
|
return {
|
|
@@ -32094,7 +32425,7 @@ function create_default_slot_2$3(ctx) {
|
|
|
32094
32425
|
insert(target, t, anchor);
|
|
32095
32426
|
},
|
|
32096
32427
|
p(ctx, dirty) {
|
|
32097
|
-
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);
|
|
32098
32429
|
},
|
|
32099
32430
|
d(detaching) {
|
|
32100
32431
|
if (detaching) detach(t);
|
|
@@ -32110,11 +32441,11 @@ function create_each_block$3(ctx) {
|
|
|
32110
32441
|
callbackmapper = new Callback_mapper({
|
|
32111
32442
|
props: {
|
|
32112
32443
|
props: {
|
|
32113
|
-
callback: /*callback*/ ctx[
|
|
32114
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
32115
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
32116
|
-
stepMetadata: /*metadata*/ ctx[
|
|
32117
|
-
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]
|
|
32118
32449
|
}
|
|
32119
32450
|
}
|
|
32120
32451
|
});
|
|
@@ -32130,12 +32461,12 @@ function create_each_block$3(ctx) {
|
|
|
32130
32461
|
p(ctx, dirty) {
|
|
32131
32462
|
const callbackmapper_changes = {};
|
|
32132
32463
|
|
|
32133
|
-
if (dirty & /*step, metadata, $styleStore*/
|
|
32134
|
-
callback: /*callback*/ ctx[
|
|
32135
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
32136
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
32137
|
-
stepMetadata: /*metadata*/ ctx[
|
|
32138
|
-
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]
|
|
32139
32470
|
};
|
|
32140
32471
|
|
|
32141
32472
|
callbackmapper.$set(callbackmapper_changes);
|
|
@@ -32162,7 +32493,7 @@ function create_if_block$5(ctx) {
|
|
|
32162
32493
|
|
|
32163
32494
|
button = new Button({
|
|
32164
32495
|
props: {
|
|
32165
|
-
busy: /*journey*/ ctx[
|
|
32496
|
+
busy: /*journey*/ ctx[3]?.loading,
|
|
32166
32497
|
style: "primary",
|
|
32167
32498
|
type: "submit",
|
|
32168
32499
|
width: "full",
|
|
@@ -32181,9 +32512,9 @@ function create_if_block$5(ctx) {
|
|
|
32181
32512
|
},
|
|
32182
32513
|
p(ctx, dirty) {
|
|
32183
32514
|
const button_changes = {};
|
|
32184
|
-
if (dirty & /*journey*/
|
|
32515
|
+
if (dirty & /*journey*/ 8) button_changes.busy = /*journey*/ ctx[3]?.loading;
|
|
32185
32516
|
|
|
32186
|
-
if (dirty & /*$$scope*/
|
|
32517
|
+
if (dirty & /*$$scope*/ 524288) {
|
|
32187
32518
|
button_changes.$$scope = { dirty, ctx };
|
|
32188
32519
|
}
|
|
32189
32520
|
|
|
@@ -32249,24 +32580,24 @@ function create_default_slot$5(ctx) {
|
|
|
32249
32580
|
let t5;
|
|
32250
32581
|
let backto;
|
|
32251
32582
|
let current;
|
|
32252
|
-
let if_block0 = /*form*/ ctx[
|
|
32583
|
+
let if_block0 = /*form*/ ctx[2]?.icon && /*componentStyle*/ ctx[1] !== 'inline' && create_if_block_2$4();
|
|
32253
32584
|
|
|
32254
32585
|
sanitize0 = new Server_strings({
|
|
32255
32586
|
props: {
|
|
32256
32587
|
html: true,
|
|
32257
|
-
string: /*step*/ ctx[
|
|
32588
|
+
string: /*step*/ ctx[5]?.getHeader() || ''
|
|
32258
32589
|
}
|
|
32259
32590
|
});
|
|
32260
32591
|
|
|
32261
32592
|
sanitize1 = new Server_strings({
|
|
32262
32593
|
props: {
|
|
32263
32594
|
html: true,
|
|
32264
|
-
string: /*step*/ ctx[
|
|
32595
|
+
string: /*step*/ ctx[5]?.getDescription() || ''
|
|
32265
32596
|
}
|
|
32266
32597
|
});
|
|
32267
32598
|
|
|
32268
|
-
let if_block1 = /*form*/ ctx[
|
|
32269
|
-
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;
|
|
32270
32601
|
let each_blocks = [];
|
|
32271
32602
|
|
|
32272
32603
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -32277,8 +32608,8 @@ function create_default_slot$5(ctx) {
|
|
|
32277
32608
|
each_blocks[i] = null;
|
|
32278
32609
|
});
|
|
32279
32610
|
|
|
32280
|
-
let if_block2 = (/*metadata*/ ctx[
|
|
32281
|
-
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] } });
|
|
32282
32613
|
|
|
32283
32614
|
return {
|
|
32284
32615
|
c() {
|
|
@@ -32315,7 +32646,7 @@ function create_default_slot$5(ctx) {
|
|
|
32315
32646
|
append(header, t1);
|
|
32316
32647
|
append(header, p);
|
|
32317
32648
|
mount_component(sanitize1, p, null);
|
|
32318
|
-
/*header_binding*/ ctx[
|
|
32649
|
+
/*header_binding*/ ctx[14](header);
|
|
32319
32650
|
insert(target, t2, anchor);
|
|
32320
32651
|
if (if_block1) if_block1.m(target, anchor);
|
|
32321
32652
|
insert(target, t3, anchor);
|
|
@@ -32331,9 +32662,9 @@ function create_default_slot$5(ctx) {
|
|
|
32331
32662
|
current = true;
|
|
32332
32663
|
},
|
|
32333
32664
|
p(ctx, dirty) {
|
|
32334
|
-
if (/*form*/ ctx[
|
|
32665
|
+
if (/*form*/ ctx[2]?.icon && /*componentStyle*/ ctx[1] !== 'inline') {
|
|
32335
32666
|
if (if_block0) {
|
|
32336
|
-
if (dirty & /*form*/
|
|
32667
|
+
if (dirty & /*form, componentStyle*/ 6) {
|
|
32337
32668
|
transition_in(if_block0, 1);
|
|
32338
32669
|
}
|
|
32339
32670
|
} else {
|
|
@@ -32353,17 +32684,17 @@ function create_default_slot$5(ctx) {
|
|
|
32353
32684
|
}
|
|
32354
32685
|
|
|
32355
32686
|
const sanitize0_changes = {};
|
|
32356
|
-
if (dirty & /*step*/
|
|
32687
|
+
if (dirty & /*step*/ 32) sanitize0_changes.string = /*step*/ ctx[5]?.getHeader() || '';
|
|
32357
32688
|
sanitize0.$set(sanitize0_changes);
|
|
32358
32689
|
const sanitize1_changes = {};
|
|
32359
|
-
if (dirty & /*step*/
|
|
32690
|
+
if (dirty & /*step*/ 32) sanitize1_changes.string = /*step*/ ctx[5]?.getDescription() || '';
|
|
32360
32691
|
sanitize1.$set(sanitize1_changes);
|
|
32361
32692
|
|
|
32362
|
-
if (/*form*/ ctx[
|
|
32693
|
+
if (/*form*/ ctx[2]?.message) {
|
|
32363
32694
|
if (if_block1) {
|
|
32364
32695
|
if_block1.p(ctx, dirty);
|
|
32365
32696
|
|
|
32366
|
-
if (dirty & /*form*/
|
|
32697
|
+
if (dirty & /*form*/ 4) {
|
|
32367
32698
|
transition_in(if_block1, 1);
|
|
32368
32699
|
}
|
|
32369
32700
|
} else {
|
|
@@ -32382,8 +32713,8 @@ function create_default_slot$5(ctx) {
|
|
|
32382
32713
|
check_outros();
|
|
32383
32714
|
}
|
|
32384
32715
|
|
|
32385
|
-
if (dirty & /*step, metadata, determineSubmission, $styleStore*/
|
|
32386
|
-
each_value = /*step*/ ctx[
|
|
32716
|
+
if (dirty & /*step, metadata, determineSubmission, $styleStore*/ 6192) {
|
|
32717
|
+
each_value = /*step*/ ctx[5]?.callbacks;
|
|
32387
32718
|
let i;
|
|
32388
32719
|
|
|
32389
32720
|
for (i = 0; i < each_value.length; i += 1) {
|
|
@@ -32409,11 +32740,11 @@ function create_default_slot$5(ctx) {
|
|
|
32409
32740
|
check_outros();
|
|
32410
32741
|
}
|
|
32411
32742
|
|
|
32412
|
-
if (/*metadata*/ ctx[
|
|
32743
|
+
if (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) {
|
|
32413
32744
|
if (if_block2) {
|
|
32414
32745
|
if_block2.p(ctx, dirty);
|
|
32415
32746
|
|
|
32416
|
-
if (dirty & /*metadata*/
|
|
32747
|
+
if (dirty & /*metadata*/ 16) {
|
|
32417
32748
|
transition_in(if_block2, 1);
|
|
32418
32749
|
}
|
|
32419
32750
|
} else {
|
|
@@ -32433,7 +32764,7 @@ function create_default_slot$5(ctx) {
|
|
|
32433
32764
|
}
|
|
32434
32765
|
|
|
32435
32766
|
const backto_changes = {};
|
|
32436
|
-
if (dirty & /*journey*/
|
|
32767
|
+
if (dirty & /*journey*/ 8) backto_changes.journey = /*journey*/ ctx[3];
|
|
32437
32768
|
backto.$set(backto_changes);
|
|
32438
32769
|
},
|
|
32439
32770
|
i(local) {
|
|
@@ -32472,7 +32803,7 @@ function create_default_slot$5(ctx) {
|
|
|
32472
32803
|
if (detaching) detach(header);
|
|
32473
32804
|
destroy_component(sanitize0);
|
|
32474
32805
|
destroy_component(sanitize1);
|
|
32475
|
-
/*header_binding*/ ctx[
|
|
32806
|
+
/*header_binding*/ ctx[14](null);
|
|
32476
32807
|
if (detaching) detach(t2);
|
|
32477
32808
|
if (if_block1) if_block1.d(detaching);
|
|
32478
32809
|
if (detaching) detach(t3);
|
|
@@ -32491,14 +32822,14 @@ function create_fragment$7(ctx) {
|
|
|
32491
32822
|
let current;
|
|
32492
32823
|
|
|
32493
32824
|
function form_1_formEl_binding(value) {
|
|
32494
|
-
/*form_1_formEl_binding*/ ctx[
|
|
32825
|
+
/*form_1_formEl_binding*/ ctx[15](value);
|
|
32495
32826
|
}
|
|
32496
32827
|
|
|
32497
32828
|
let form_1_props = {
|
|
32498
|
-
ariaDescribedBy: /*formAriaDescriptor*/ ctx[
|
|
32829
|
+
ariaDescribedBy: /*formAriaDescriptor*/ ctx[8],
|
|
32499
32830
|
id: formElementId,
|
|
32500
|
-
needsFocus: /*formNeedsFocus*/ ctx[
|
|
32501
|
-
onSubmitWhenValid: /*submitFormWrapper*/ ctx[
|
|
32831
|
+
needsFocus: /*formNeedsFocus*/ ctx[9],
|
|
32832
|
+
onSubmitWhenValid: /*submitFormWrapper*/ ctx[13],
|
|
32502
32833
|
$$slots: { default: [create_default_slot$5] },
|
|
32503
32834
|
$$scope: { ctx }
|
|
32504
32835
|
};
|
|
@@ -32520,10 +32851,10 @@ function create_fragment$7(ctx) {
|
|
|
32520
32851
|
},
|
|
32521
32852
|
p(ctx, [dirty]) {
|
|
32522
32853
|
const form_1_changes = {};
|
|
32523
|
-
if (dirty & /*formAriaDescriptor*/
|
|
32524
|
-
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];
|
|
32525
32856
|
|
|
32526
|
-
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) {
|
|
32527
32858
|
form_1_changes.$$scope = { dirty, ctx };
|
|
32528
32859
|
}
|
|
32529
32860
|
|
|
@@ -32556,7 +32887,8 @@ const formElementId = 'genericStepForm';
|
|
|
32556
32887
|
|
|
32557
32888
|
function instance$7($$self, $$props, $$invalidate) {
|
|
32558
32889
|
let $styleStore;
|
|
32559
|
-
component_subscribe($$self, styleStore, $$value => $$invalidate(
|
|
32890
|
+
component_subscribe($$self, styleStore, $$value => $$invalidate(11, $styleStore = $$value));
|
|
32891
|
+
let { componentStyle } = $$props;
|
|
32560
32892
|
let { form } = $$props;
|
|
32561
32893
|
let { formEl = null } = $$props;
|
|
32562
32894
|
let { journey } = $$props;
|
|
@@ -32578,20 +32910,20 @@ function instance$7($$self, $$props, $$invalidate) {
|
|
|
32578
32910
|
}
|
|
32579
32911
|
|
|
32580
32912
|
function submitFormWrapper() {
|
|
32581
|
-
$$invalidate(
|
|
32582
|
-
$$invalidate(
|
|
32913
|
+
$$invalidate(6, alertNeedsFocus = false);
|
|
32914
|
+
$$invalidate(9, formNeedsFocus = false);
|
|
32583
32915
|
form?.submit();
|
|
32584
32916
|
}
|
|
32585
32917
|
|
|
32586
32918
|
afterUpdate(() => {
|
|
32587
32919
|
if (form?.message) {
|
|
32588
|
-
$$invalidate(
|
|
32589
|
-
$$invalidate(
|
|
32590
|
-
$$invalidate(
|
|
32920
|
+
$$invalidate(8, formAriaDescriptor = formFailureMessageId);
|
|
32921
|
+
$$invalidate(6, alertNeedsFocus = true);
|
|
32922
|
+
$$invalidate(9, formNeedsFocus = false);
|
|
32591
32923
|
} else {
|
|
32592
|
-
$$invalidate(
|
|
32593
|
-
$$invalidate(
|
|
32594
|
-
$$invalidate(
|
|
32924
|
+
$$invalidate(8, formAriaDescriptor = formHeaderId);
|
|
32925
|
+
$$invalidate(6, alertNeedsFocus = false);
|
|
32926
|
+
$$invalidate(9, formNeedsFocus = true);
|
|
32595
32927
|
}
|
|
32596
32928
|
});
|
|
32597
32929
|
|
|
@@ -32600,7 +32932,7 @@ function instance$7($$self, $$props, $$invalidate) {
|
|
|
32600
32932
|
function header_binding($$value) {
|
|
32601
32933
|
binding_callbacks[$$value ? 'unshift' : 'push'](() => {
|
|
32602
32934
|
linkWrapper = $$value;
|
|
32603
|
-
$$invalidate(
|
|
32935
|
+
$$invalidate(10, linkWrapper);
|
|
32604
32936
|
});
|
|
32605
32937
|
}
|
|
32606
32938
|
|
|
@@ -32610,24 +32942,26 @@ function instance$7($$self, $$props, $$invalidate) {
|
|
|
32610
32942
|
}
|
|
32611
32943
|
|
|
32612
32944
|
$$self.$$set = $$props => {
|
|
32613
|
-
if ('
|
|
32945
|
+
if ('componentStyle' in $$props) $$invalidate(1, componentStyle = $$props.componentStyle);
|
|
32946
|
+
if ('form' in $$props) $$invalidate(2, form = $$props.form);
|
|
32614
32947
|
if ('formEl' in $$props) $$invalidate(0, formEl = $$props.formEl);
|
|
32615
|
-
if ('journey' in $$props) $$invalidate(
|
|
32616
|
-
if ('metadata' in $$props) $$invalidate(
|
|
32617
|
-
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);
|
|
32618
32951
|
};
|
|
32619
32952
|
|
|
32620
32953
|
$$self.$$.update = () => {
|
|
32621
|
-
if ($$self.$$.dirty & /*step, form*/
|
|
32954
|
+
if ($$self.$$.dirty & /*step, form*/ 36) {
|
|
32622
32955
|
{
|
|
32623
32956
|
shouldRedirectFromStep(step) && FRAuth$1.redirect(step);
|
|
32624
|
-
$$invalidate(
|
|
32957
|
+
$$invalidate(7, formMessageKey = convertStringToKey(form?.message));
|
|
32625
32958
|
}
|
|
32626
32959
|
}
|
|
32627
32960
|
};
|
|
32628
32961
|
|
|
32629
32962
|
return [
|
|
32630
32963
|
formEl,
|
|
32964
|
+
componentStyle,
|
|
32631
32965
|
form,
|
|
32632
32966
|
journey,
|
|
32633
32967
|
metadata,
|
|
@@ -32650,11 +32984,12 @@ class Generic extends SvelteComponent {
|
|
|
32650
32984
|
super();
|
|
32651
32985
|
|
|
32652
32986
|
init(this, options, instance$7, create_fragment$7, safe_not_equal, {
|
|
32653
|
-
|
|
32987
|
+
componentStyle: 1,
|
|
32988
|
+
form: 2,
|
|
32654
32989
|
formEl: 0,
|
|
32655
|
-
journey:
|
|
32656
|
-
metadata:
|
|
32657
|
-
step:
|
|
32990
|
+
journey: 3,
|
|
32991
|
+
metadata: 4,
|
|
32992
|
+
step: 5
|
|
32658
32993
|
});
|
|
32659
32994
|
}
|
|
32660
32995
|
}
|
|
@@ -32767,13 +33102,101 @@ class Key_icon extends SvelteComponent {
|
|
|
32767
33102
|
|
|
32768
33103
|
function get_each_context$2(ctx, list, i) {
|
|
32769
33104
|
const child_ctx = ctx.slice();
|
|
32770
|
-
child_ctx[
|
|
32771
|
-
child_ctx[
|
|
33105
|
+
child_ctx[11] = list[i];
|
|
33106
|
+
child_ctx[13] = i;
|
|
32772
33107
|
return child_ctx;
|
|
32773
33108
|
}
|
|
32774
33109
|
|
|
32775
|
-
// (
|
|
33110
|
+
// (38:2) {#if componentStyle !== 'inline'}
|
|
32776
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) {
|
|
32777
33200
|
let div;
|
|
32778
33201
|
let keyicon;
|
|
32779
33202
|
let current;
|
|
@@ -32812,7 +33235,7 @@ function create_if_block_2$3(ctx) {
|
|
|
32812
33235
|
};
|
|
32813
33236
|
}
|
|
32814
33237
|
|
|
32815
|
-
// (
|
|
33238
|
+
// (54:2) {#if form?.message}
|
|
32816
33239
|
function create_if_block_1$3(ctx) {
|
|
32817
33240
|
let alert;
|
|
32818
33241
|
let current;
|
|
@@ -32820,7 +33243,7 @@ function create_if_block_1$3(ctx) {
|
|
|
32820
33243
|
alert = new Alert({
|
|
32821
33244
|
props: {
|
|
32822
33245
|
id: "formFailureMessageAlert",
|
|
32823
|
-
needsFocus: /*alertNeedsFocus*/ ctx[
|
|
33246
|
+
needsFocus: /*alertNeedsFocus*/ ctx[6],
|
|
32824
33247
|
type: "error",
|
|
32825
33248
|
$$slots: { default: [create_default_slot_2$2] },
|
|
32826
33249
|
$$scope: { ctx }
|
|
@@ -32837,9 +33260,9 @@ function create_if_block_1$3(ctx) {
|
|
|
32837
33260
|
},
|
|
32838
33261
|
p(ctx, dirty) {
|
|
32839
33262
|
const alert_changes = {};
|
|
32840
|
-
if (dirty & /*alertNeedsFocus*/
|
|
33263
|
+
if (dirty & /*alertNeedsFocus*/ 64) alert_changes.needsFocus = /*alertNeedsFocus*/ ctx[6];
|
|
32841
33264
|
|
|
32842
|
-
if (dirty & /*$$scope, formMessageKey, form*/
|
|
33265
|
+
if (dirty & /*$$scope, formMessageKey, form*/ 16516) {
|
|
32843
33266
|
alert_changes.$$scope = { dirty, ctx };
|
|
32844
33267
|
}
|
|
32845
33268
|
|
|
@@ -32860,9 +33283,9 @@ function create_if_block_1$3(ctx) {
|
|
|
32860
33283
|
};
|
|
32861
33284
|
}
|
|
32862
33285
|
|
|
32863
|
-
// (
|
|
33286
|
+
// (55:4) <Alert id="formFailureMessageAlert" needsFocus={alertNeedsFocus} type="error">
|
|
32864
33287
|
function create_default_slot_2$2(ctx) {
|
|
32865
|
-
let t_value = interpolate(/*formMessageKey*/ ctx[
|
|
33288
|
+
let t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "";
|
|
32866
33289
|
let t;
|
|
32867
33290
|
|
|
32868
33291
|
return {
|
|
@@ -32873,7 +33296,7 @@ function create_default_slot_2$2(ctx) {
|
|
|
32873
33296
|
insert(target, t, anchor);
|
|
32874
33297
|
},
|
|
32875
33298
|
p(ctx, dirty) {
|
|
32876
|
-
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);
|
|
32877
33300
|
},
|
|
32878
33301
|
d(detaching) {
|
|
32879
33302
|
if (detaching) detach(t);
|
|
@@ -32881,7 +33304,7 @@ function create_default_slot_2$2(ctx) {
|
|
|
32881
33304
|
};
|
|
32882
33305
|
}
|
|
32883
33306
|
|
|
32884
|
-
// (
|
|
33307
|
+
// (60:2) {#each step?.callbacks as callback, idx}
|
|
32885
33308
|
function create_each_block$2(ctx) {
|
|
32886
33309
|
let callbackmapper;
|
|
32887
33310
|
let current;
|
|
@@ -32889,11 +33312,11 @@ function create_each_block$2(ctx) {
|
|
|
32889
33312
|
callbackmapper = new Callback_mapper({
|
|
32890
33313
|
props: {
|
|
32891
33314
|
props: {
|
|
32892
|
-
callback: /*callback*/ ctx[
|
|
32893
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
32894
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
32895
|
-
stepMetadata: /*metadata*/ ctx[
|
|
32896
|
-
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]
|
|
32897
33320
|
}
|
|
32898
33321
|
}
|
|
32899
33322
|
});
|
|
@@ -32909,12 +33332,12 @@ function create_each_block$2(ctx) {
|
|
|
32909
33332
|
p(ctx, dirty) {
|
|
32910
33333
|
const callbackmapper_changes = {};
|
|
32911
33334
|
|
|
32912
|
-
if (dirty & /*step, metadata, $style*/
|
|
32913
|
-
callback: /*callback*/ ctx[
|
|
32914
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
32915
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
32916
|
-
stepMetadata: /*metadata*/ ctx[
|
|
32917
|
-
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]
|
|
32918
33341
|
};
|
|
32919
33342
|
|
|
32920
33343
|
callbackmapper.$set(callbackmapper_changes);
|
|
@@ -32934,14 +33357,14 @@ function create_each_block$2(ctx) {
|
|
|
32934
33357
|
};
|
|
32935
33358
|
}
|
|
32936
33359
|
|
|
32937
|
-
// (
|
|
33360
|
+
// (72:2) {#if metadata?.step?.derived.isUserInputOptional || !metadata?.step?.derived.isStepSelfSubmittable}
|
|
32938
33361
|
function create_if_block$4(ctx) {
|
|
32939
33362
|
let button;
|
|
32940
33363
|
let current;
|
|
32941
33364
|
|
|
32942
33365
|
button = new Button({
|
|
32943
33366
|
props: {
|
|
32944
|
-
busy: /*journey*/ ctx[
|
|
33367
|
+
busy: /*journey*/ ctx[3]?.loading,
|
|
32945
33368
|
style: "primary",
|
|
32946
33369
|
type: "submit",
|
|
32947
33370
|
width: "full",
|
|
@@ -32960,9 +33383,9 @@ function create_if_block$4(ctx) {
|
|
|
32960
33383
|
},
|
|
32961
33384
|
p(ctx, dirty) {
|
|
32962
33385
|
const button_changes = {};
|
|
32963
|
-
if (dirty & /*journey*/
|
|
33386
|
+
if (dirty & /*journey*/ 8) button_changes.busy = /*journey*/ ctx[3]?.loading;
|
|
32964
33387
|
|
|
32965
|
-
if (dirty & /*$$scope*/
|
|
33388
|
+
if (dirty & /*$$scope*/ 16384) {
|
|
32966
33389
|
button_changes.$$scope = { dirty, ctx };
|
|
32967
33390
|
}
|
|
32968
33391
|
|
|
@@ -32983,7 +33406,7 @@ function create_if_block$4(ctx) {
|
|
|
32983
33406
|
};
|
|
32984
33407
|
}
|
|
32985
33408
|
|
|
32986
|
-
// (
|
|
33409
|
+
// (73:4) <Button busy={journey?.loading} style="primary" type="submit" width="full">
|
|
32987
33410
|
function create_default_slot_1$3(ctx) {
|
|
32988
33411
|
let t;
|
|
32989
33412
|
let current;
|
|
@@ -33013,31 +33436,16 @@ function create_default_slot_1$3(ctx) {
|
|
|
33013
33436
|
};
|
|
33014
33437
|
}
|
|
33015
33438
|
|
|
33016
|
-
// (
|
|
33439
|
+
// (37:0) <Form bind:formEl ariaDescribedBy="formFailureMessageAlert" onSubmitWhenValid={form?.submit}>
|
|
33017
33440
|
function create_default_slot$4(ctx) {
|
|
33018
33441
|
let t0;
|
|
33019
|
-
let h1;
|
|
33020
33442
|
let t1;
|
|
33021
33443
|
let t2;
|
|
33022
|
-
let p;
|
|
33023
|
-
let t3;
|
|
33024
|
-
let t4;
|
|
33025
|
-
let t5;
|
|
33026
|
-
let t6;
|
|
33027
33444
|
let if_block2_anchor;
|
|
33028
33445
|
let current;
|
|
33029
|
-
let if_block0 = /*
|
|
33030
|
-
|
|
33031
|
-
|
|
33032
|
-
props: { key: "twoFactorAuthentication" }
|
|
33033
|
-
});
|
|
33034
|
-
|
|
33035
|
-
t3 = new Locale_strings({
|
|
33036
|
-
props: { key: "useTheAuthenticatorAppOnYourPhone" }
|
|
33037
|
-
});
|
|
33038
|
-
|
|
33039
|
-
let if_block1 = /*form*/ ctx[1]?.message && create_if_block_1$3(ctx);
|
|
33040
|
-
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;
|
|
33041
33449
|
let each_blocks = [];
|
|
33042
33450
|
|
|
33043
33451
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -33048,60 +33456,48 @@ function create_default_slot$4(ctx) {
|
|
|
33048
33456
|
each_blocks[i] = null;
|
|
33049
33457
|
});
|
|
33050
33458
|
|
|
33051
|
-
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);
|
|
33052
33460
|
|
|
33053
33461
|
return {
|
|
33054
33462
|
c() {
|
|
33055
33463
|
if (if_block0) if_block0.c();
|
|
33056
33464
|
t0 = space();
|
|
33057
|
-
h1 = element("h1");
|
|
33058
|
-
create_component(t1.$$.fragment);
|
|
33059
|
-
t2 = space();
|
|
33060
|
-
p = element("p");
|
|
33061
|
-
create_component(t3.$$.fragment);
|
|
33062
|
-
t4 = space();
|
|
33063
33465
|
if (if_block1) if_block1.c();
|
|
33064
|
-
|
|
33466
|
+
t1 = space();
|
|
33065
33467
|
|
|
33066
33468
|
for (let i = 0; i < each_blocks.length; i += 1) {
|
|
33067
33469
|
each_blocks[i].c();
|
|
33068
33470
|
}
|
|
33069
33471
|
|
|
33070
|
-
|
|
33472
|
+
t2 = space();
|
|
33071
33473
|
if (if_block2) if_block2.c();
|
|
33072
33474
|
if_block2_anchor = empty();
|
|
33073
|
-
attr(h1, "class", "tw_primary-header dark:tw_primary-header_dark");
|
|
33074
|
-
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");
|
|
33075
33475
|
},
|
|
33076
33476
|
m(target, anchor) {
|
|
33077
33477
|
if (if_block0) if_block0.m(target, anchor);
|
|
33078
33478
|
insert(target, t0, anchor);
|
|
33079
|
-
insert(target, h1, anchor);
|
|
33080
|
-
mount_component(t1, h1, null);
|
|
33081
|
-
insert(target, t2, anchor);
|
|
33082
|
-
insert(target, p, anchor);
|
|
33083
|
-
mount_component(t3, p, null);
|
|
33084
|
-
insert(target, t4, anchor);
|
|
33085
33479
|
if (if_block1) if_block1.m(target, anchor);
|
|
33086
|
-
insert(target,
|
|
33480
|
+
insert(target, t1, anchor);
|
|
33087
33481
|
|
|
33088
33482
|
for (let i = 0; i < each_blocks.length; i += 1) {
|
|
33089
33483
|
each_blocks[i].m(target, anchor);
|
|
33090
33484
|
}
|
|
33091
33485
|
|
|
33092
|
-
insert(target,
|
|
33486
|
+
insert(target, t2, anchor);
|
|
33093
33487
|
if (if_block2) if_block2.m(target, anchor);
|
|
33094
33488
|
insert(target, if_block2_anchor, anchor);
|
|
33095
33489
|
current = true;
|
|
33096
33490
|
},
|
|
33097
33491
|
p(ctx, dirty) {
|
|
33098
|
-
if (/*
|
|
33492
|
+
if (/*componentStyle*/ ctx[1] !== 'inline') {
|
|
33099
33493
|
if (if_block0) {
|
|
33100
|
-
|
|
33494
|
+
if_block0.p(ctx, dirty);
|
|
33495
|
+
|
|
33496
|
+
if (dirty & /*componentStyle*/ 2) {
|
|
33101
33497
|
transition_in(if_block0, 1);
|
|
33102
33498
|
}
|
|
33103
33499
|
} else {
|
|
33104
|
-
if_block0 = create_if_block_2$3();
|
|
33500
|
+
if_block0 = create_if_block_2$3(ctx);
|
|
33105
33501
|
if_block0.c();
|
|
33106
33502
|
transition_in(if_block0, 1);
|
|
33107
33503
|
if_block0.m(t0.parentNode, t0);
|
|
@@ -33116,18 +33512,18 @@ function create_default_slot$4(ctx) {
|
|
|
33116
33512
|
check_outros();
|
|
33117
33513
|
}
|
|
33118
33514
|
|
|
33119
|
-
if (/*form*/ ctx[
|
|
33515
|
+
if (/*form*/ ctx[2]?.message) {
|
|
33120
33516
|
if (if_block1) {
|
|
33121
33517
|
if_block1.p(ctx, dirty);
|
|
33122
33518
|
|
|
33123
|
-
if (dirty & /*form*/
|
|
33519
|
+
if (dirty & /*form*/ 4) {
|
|
33124
33520
|
transition_in(if_block1, 1);
|
|
33125
33521
|
}
|
|
33126
33522
|
} else {
|
|
33127
33523
|
if_block1 = create_if_block_1$3(ctx);
|
|
33128
33524
|
if_block1.c();
|
|
33129
33525
|
transition_in(if_block1, 1);
|
|
33130
|
-
if_block1.m(
|
|
33526
|
+
if_block1.m(t1.parentNode, t1);
|
|
33131
33527
|
}
|
|
33132
33528
|
} else if (if_block1) {
|
|
33133
33529
|
group_outros();
|
|
@@ -33139,8 +33535,8 @@ function create_default_slot$4(ctx) {
|
|
|
33139
33535
|
check_outros();
|
|
33140
33536
|
}
|
|
33141
33537
|
|
|
33142
|
-
if (dirty & /*step, metadata, determineSubmission, $style*/
|
|
33143
|
-
each_value = /*step*/ ctx[
|
|
33538
|
+
if (dirty & /*step, metadata, determineSubmission, $style*/ 816) {
|
|
33539
|
+
each_value = /*step*/ ctx[5]?.callbacks;
|
|
33144
33540
|
let i;
|
|
33145
33541
|
|
|
33146
33542
|
for (i = 0; i < each_value.length; i += 1) {
|
|
@@ -33153,7 +33549,7 @@ function create_default_slot$4(ctx) {
|
|
|
33153
33549
|
each_blocks[i] = create_each_block$2(child_ctx);
|
|
33154
33550
|
each_blocks[i].c();
|
|
33155
33551
|
transition_in(each_blocks[i], 1);
|
|
33156
|
-
each_blocks[i].m(
|
|
33552
|
+
each_blocks[i].m(t2.parentNode, t2);
|
|
33157
33553
|
}
|
|
33158
33554
|
}
|
|
33159
33555
|
|
|
@@ -33166,11 +33562,11 @@ function create_default_slot$4(ctx) {
|
|
|
33166
33562
|
check_outros();
|
|
33167
33563
|
}
|
|
33168
33564
|
|
|
33169
|
-
if (/*metadata*/ ctx[
|
|
33565
|
+
if (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) {
|
|
33170
33566
|
if (if_block2) {
|
|
33171
33567
|
if_block2.p(ctx, dirty);
|
|
33172
33568
|
|
|
33173
|
-
if (dirty & /*metadata*/
|
|
33569
|
+
if (dirty & /*metadata*/ 16) {
|
|
33174
33570
|
transition_in(if_block2, 1);
|
|
33175
33571
|
}
|
|
33176
33572
|
} else {
|
|
@@ -33192,8 +33588,6 @@ function create_default_slot$4(ctx) {
|
|
|
33192
33588
|
i(local) {
|
|
33193
33589
|
if (current) return;
|
|
33194
33590
|
transition_in(if_block0);
|
|
33195
|
-
transition_in(t1.$$.fragment, local);
|
|
33196
|
-
transition_in(t3.$$.fragment, local);
|
|
33197
33591
|
transition_in(if_block1);
|
|
33198
33592
|
|
|
33199
33593
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -33205,8 +33599,6 @@ function create_default_slot$4(ctx) {
|
|
|
33205
33599
|
},
|
|
33206
33600
|
o(local) {
|
|
33207
33601
|
transition_out(if_block0);
|
|
33208
|
-
transition_out(t1.$$.fragment, local);
|
|
33209
|
-
transition_out(t3.$$.fragment, local);
|
|
33210
33602
|
transition_out(if_block1);
|
|
33211
33603
|
each_blocks = each_blocks.filter(Boolean);
|
|
33212
33604
|
|
|
@@ -33220,16 +33612,10 @@ function create_default_slot$4(ctx) {
|
|
|
33220
33612
|
d(detaching) {
|
|
33221
33613
|
if (if_block0) if_block0.d(detaching);
|
|
33222
33614
|
if (detaching) detach(t0);
|
|
33223
|
-
if (detaching) detach(h1);
|
|
33224
|
-
destroy_component(t1);
|
|
33225
|
-
if (detaching) detach(t2);
|
|
33226
|
-
if (detaching) detach(p);
|
|
33227
|
-
destroy_component(t3);
|
|
33228
|
-
if (detaching) detach(t4);
|
|
33229
33615
|
if (if_block1) if_block1.d(detaching);
|
|
33230
|
-
if (detaching) detach(
|
|
33616
|
+
if (detaching) detach(t1);
|
|
33231
33617
|
destroy_each(each_blocks, detaching);
|
|
33232
|
-
if (detaching) detach(
|
|
33618
|
+
if (detaching) detach(t2);
|
|
33233
33619
|
if (if_block2) if_block2.d(detaching);
|
|
33234
33620
|
if (detaching) detach(if_block2_anchor);
|
|
33235
33621
|
}
|
|
@@ -33242,12 +33628,12 @@ function create_fragment$5(ctx) {
|
|
|
33242
33628
|
let current;
|
|
33243
33629
|
|
|
33244
33630
|
function form_1_formEl_binding(value) {
|
|
33245
|
-
/*form_1_formEl_binding*/ ctx[
|
|
33631
|
+
/*form_1_formEl_binding*/ ctx[10](value);
|
|
33246
33632
|
}
|
|
33247
33633
|
|
|
33248
33634
|
let form_1_props = {
|
|
33249
33635
|
ariaDescribedBy: "formFailureMessageAlert",
|
|
33250
|
-
onSubmitWhenValid: /*form*/ ctx[
|
|
33636
|
+
onSubmitWhenValid: /*form*/ ctx[2]?.submit,
|
|
33251
33637
|
$$slots: { default: [create_default_slot$4] },
|
|
33252
33638
|
$$scope: { ctx }
|
|
33253
33639
|
};
|
|
@@ -33269,9 +33655,9 @@ function create_fragment$5(ctx) {
|
|
|
33269
33655
|
},
|
|
33270
33656
|
p(ctx, [dirty]) {
|
|
33271
33657
|
const form_1_changes = {};
|
|
33272
|
-
if (dirty & /*form*/
|
|
33658
|
+
if (dirty & /*form*/ 4) form_1_changes.onSubmitWhenValid = /*form*/ ctx[2]?.submit;
|
|
33273
33659
|
|
|
33274
|
-
if (dirty & /*$$scope, journey, metadata, step, $style, alertNeedsFocus, formMessageKey, form*/
|
|
33660
|
+
if (dirty & /*$$scope, journey, metadata, step, $style, alertNeedsFocus, formMessageKey, form, componentStyle*/ 16894) {
|
|
33275
33661
|
form_1_changes.$$scope = { dirty, ctx };
|
|
33276
33662
|
}
|
|
33277
33663
|
|
|
@@ -33300,7 +33686,8 @@ function create_fragment$5(ctx) {
|
|
|
33300
33686
|
|
|
33301
33687
|
function instance$5($$self, $$props, $$invalidate) {
|
|
33302
33688
|
let $style;
|
|
33303
|
-
component_subscribe($$self, styleStore, $$value => $$invalidate(
|
|
33689
|
+
component_subscribe($$self, styleStore, $$value => $$invalidate(8, $style = $$value));
|
|
33690
|
+
let { componentStyle } = $$props;
|
|
33304
33691
|
let { form } = $$props;
|
|
33305
33692
|
let { formEl = null } = $$props;
|
|
33306
33693
|
let { journey } = $$props;
|
|
@@ -33319,7 +33706,7 @@ function instance$5($$self, $$props, $$invalidate) {
|
|
|
33319
33706
|
}
|
|
33320
33707
|
|
|
33321
33708
|
afterUpdate(() => {
|
|
33322
|
-
$$invalidate(
|
|
33709
|
+
$$invalidate(6, alertNeedsFocus = !!form?.message);
|
|
33323
33710
|
});
|
|
33324
33711
|
|
|
33325
33712
|
function form_1_formEl_binding(value) {
|
|
@@ -33328,23 +33715,25 @@ function instance$5($$self, $$props, $$invalidate) {
|
|
|
33328
33715
|
}
|
|
33329
33716
|
|
|
33330
33717
|
$$self.$$set = $$props => {
|
|
33331
|
-
if ('
|
|
33718
|
+
if ('componentStyle' in $$props) $$invalidate(1, componentStyle = $$props.componentStyle);
|
|
33719
|
+
if ('form' in $$props) $$invalidate(2, form = $$props.form);
|
|
33332
33720
|
if ('formEl' in $$props) $$invalidate(0, formEl = $$props.formEl);
|
|
33333
|
-
if ('journey' in $$props) $$invalidate(
|
|
33334
|
-
if ('metadata' in $$props) $$invalidate(
|
|
33335
|
-
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);
|
|
33336
33724
|
};
|
|
33337
33725
|
|
|
33338
33726
|
$$self.$$.update = () => {
|
|
33339
|
-
if ($$self.$$.dirty & /*form*/
|
|
33727
|
+
if ($$self.$$.dirty & /*form*/ 4) {
|
|
33340
33728
|
{
|
|
33341
|
-
$$invalidate(
|
|
33729
|
+
$$invalidate(7, formMessageKey = convertStringToKey(form?.message));
|
|
33342
33730
|
}
|
|
33343
33731
|
}
|
|
33344
33732
|
};
|
|
33345
33733
|
|
|
33346
33734
|
return [
|
|
33347
33735
|
formEl,
|
|
33736
|
+
componentStyle,
|
|
33348
33737
|
form,
|
|
33349
33738
|
journey,
|
|
33350
33739
|
metadata,
|
|
@@ -33362,11 +33751,12 @@ class One_time_password extends SvelteComponent {
|
|
|
33362
33751
|
super();
|
|
33363
33752
|
|
|
33364
33753
|
init(this, options, instance$5, create_fragment$5, safe_not_equal, {
|
|
33365
|
-
|
|
33754
|
+
componentStyle: 1,
|
|
33755
|
+
form: 2,
|
|
33366
33756
|
formEl: 0,
|
|
33367
|
-
journey:
|
|
33368
|
-
metadata:
|
|
33369
|
-
step:
|
|
33757
|
+
journey: 3,
|
|
33758
|
+
metadata: 4,
|
|
33759
|
+
step: 5
|
|
33370
33760
|
});
|
|
33371
33761
|
}
|
|
33372
33762
|
}
|
|
@@ -33479,13 +33869,100 @@ class New_user_icon extends SvelteComponent {
|
|
|
33479
33869
|
|
|
33480
33870
|
function get_each_context$1(ctx, list, i) {
|
|
33481
33871
|
const child_ctx = ctx.slice();
|
|
33482
|
-
child_ctx[
|
|
33483
|
-
child_ctx[
|
|
33872
|
+
child_ctx[13] = list[i];
|
|
33873
|
+
child_ctx[15] = i;
|
|
33484
33874
|
return child_ctx;
|
|
33485
33875
|
}
|
|
33486
33876
|
|
|
33487
|
-
// (
|
|
33877
|
+
// (50:2) {#if componentStyle !== 'inline'}
|
|
33488
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) {
|
|
33489
33966
|
let div;
|
|
33490
33967
|
let newusericon;
|
|
33491
33968
|
let current;
|
|
@@ -33524,7 +34001,7 @@ function create_if_block_2$2(ctx) {
|
|
|
33524
34001
|
};
|
|
33525
34002
|
}
|
|
33526
34003
|
|
|
33527
|
-
// (
|
|
34004
|
+
// (67:2) {#if form.message}
|
|
33528
34005
|
function create_if_block_1$2(ctx) {
|
|
33529
34006
|
let alert;
|
|
33530
34007
|
let current;
|
|
@@ -33532,7 +34009,7 @@ function create_if_block_1$2(ctx) {
|
|
|
33532
34009
|
alert = new Alert({
|
|
33533
34010
|
props: {
|
|
33534
34011
|
id: "formFailureMessageAlert",
|
|
33535
|
-
needsFocus: /*alertNeedsFocus*/ ctx[
|
|
34012
|
+
needsFocus: /*alertNeedsFocus*/ ctx[6],
|
|
33536
34013
|
type: "error",
|
|
33537
34014
|
$$slots: { default: [create_default_slot_2$1] },
|
|
33538
34015
|
$$scope: { ctx }
|
|
@@ -33549,9 +34026,9 @@ function create_if_block_1$2(ctx) {
|
|
|
33549
34026
|
},
|
|
33550
34027
|
p(ctx, dirty) {
|
|
33551
34028
|
const alert_changes = {};
|
|
33552
|
-
if (dirty & /*alertNeedsFocus*/
|
|
34029
|
+
if (dirty & /*alertNeedsFocus*/ 64) alert_changes.needsFocus = /*alertNeedsFocus*/ ctx[6];
|
|
33553
34030
|
|
|
33554
|
-
if (dirty & /*$$scope, formMessageKey, form*/
|
|
34031
|
+
if (dirty & /*$$scope, formMessageKey, form*/ 65668) {
|
|
33555
34032
|
alert_changes.$$scope = { dirty, ctx };
|
|
33556
34033
|
}
|
|
33557
34034
|
|
|
@@ -33572,9 +34049,9 @@ function create_if_block_1$2(ctx) {
|
|
|
33572
34049
|
};
|
|
33573
34050
|
}
|
|
33574
34051
|
|
|
33575
|
-
// (
|
|
34052
|
+
// (68:4) <Alert id="formFailureMessageAlert" needsFocus={alertNeedsFocus} type="error">
|
|
33576
34053
|
function create_default_slot_2$1(ctx) {
|
|
33577
|
-
let t_value = interpolate(/*formMessageKey*/ ctx[
|
|
34054
|
+
let t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "";
|
|
33578
34055
|
let t;
|
|
33579
34056
|
|
|
33580
34057
|
return {
|
|
@@ -33585,7 +34062,7 @@ function create_default_slot_2$1(ctx) {
|
|
|
33585
34062
|
insert(target, t, anchor);
|
|
33586
34063
|
},
|
|
33587
34064
|
p(ctx, dirty) {
|
|
33588
|
-
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);
|
|
33589
34066
|
},
|
|
33590
34067
|
d(detaching) {
|
|
33591
34068
|
if (detaching) detach(t);
|
|
@@ -33593,7 +34070,7 @@ function create_default_slot_2$1(ctx) {
|
|
|
33593
34070
|
};
|
|
33594
34071
|
}
|
|
33595
34072
|
|
|
33596
|
-
// (
|
|
34073
|
+
// (73:2) {#each step?.callbacks as callback, idx}
|
|
33597
34074
|
function create_each_block$1(ctx) {
|
|
33598
34075
|
let callbackmapper;
|
|
33599
34076
|
let current;
|
|
@@ -33601,11 +34078,11 @@ function create_each_block$1(ctx) {
|
|
|
33601
34078
|
callbackmapper = new Callback_mapper({
|
|
33602
34079
|
props: {
|
|
33603
34080
|
props: {
|
|
33604
|
-
callback: /*callback*/ ctx[
|
|
33605
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
33606
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
33607
|
-
stepMetadata: /*metadata*/ ctx[
|
|
33608
|
-
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]
|
|
33609
34086
|
}
|
|
33610
34087
|
}
|
|
33611
34088
|
});
|
|
@@ -33621,12 +34098,12 @@ function create_each_block$1(ctx) {
|
|
|
33621
34098
|
p(ctx, dirty) {
|
|
33622
34099
|
const callbackmapper_changes = {};
|
|
33623
34100
|
|
|
33624
|
-
if (dirty & /*step, metadata, $styleStore*/
|
|
33625
|
-
callback: /*callback*/ ctx[
|
|
33626
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
33627
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
33628
|
-
stepMetadata: /*metadata*/ ctx[
|
|
33629
|
-
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]
|
|
33630
34107
|
};
|
|
33631
34108
|
|
|
33632
34109
|
callbackmapper.$set(callbackmapper_changes);
|
|
@@ -33646,14 +34123,14 @@ function create_each_block$1(ctx) {
|
|
|
33646
34123
|
};
|
|
33647
34124
|
}
|
|
33648
34125
|
|
|
33649
|
-
// (
|
|
34126
|
+
// (85:2) {#if metadata?.step?.derived.isUserInputOptional || !metadata?.step?.derived.isStepSelfSubmittable}
|
|
33650
34127
|
function create_if_block$3(ctx) {
|
|
33651
34128
|
let button;
|
|
33652
34129
|
let current;
|
|
33653
34130
|
|
|
33654
34131
|
button = new Button({
|
|
33655
34132
|
props: {
|
|
33656
|
-
busy: /*journey*/ ctx[
|
|
34133
|
+
busy: /*journey*/ ctx[3]?.loading,
|
|
33657
34134
|
style: "primary",
|
|
33658
34135
|
type: "submit",
|
|
33659
34136
|
width: "full",
|
|
@@ -33672,9 +34149,9 @@ function create_if_block$3(ctx) {
|
|
|
33672
34149
|
},
|
|
33673
34150
|
p(ctx, dirty) {
|
|
33674
34151
|
const button_changes = {};
|
|
33675
|
-
if (dirty & /*journey*/
|
|
34152
|
+
if (dirty & /*journey*/ 8) button_changes.busy = /*journey*/ ctx[3]?.loading;
|
|
33676
34153
|
|
|
33677
|
-
if (dirty & /*$$scope*/
|
|
34154
|
+
if (dirty & /*$$scope*/ 65536) {
|
|
33678
34155
|
button_changes.$$scope = { dirty, ctx };
|
|
33679
34156
|
}
|
|
33680
34157
|
|
|
@@ -33695,7 +34172,7 @@ function create_if_block$3(ctx) {
|
|
|
33695
34172
|
};
|
|
33696
34173
|
}
|
|
33697
34174
|
|
|
33698
|
-
// (
|
|
34175
|
+
// (86:4) <Button busy={journey?.loading} style="primary" type="submit" width="full">
|
|
33699
34176
|
function create_default_slot_1$2(ctx) {
|
|
33700
34177
|
let t;
|
|
33701
34178
|
let current;
|
|
@@ -33725,28 +34202,16 @@ function create_default_slot_1$2(ctx) {
|
|
|
33725
34202
|
};
|
|
33726
34203
|
}
|
|
33727
34204
|
|
|
33728
|
-
// (
|
|
34205
|
+
// (49:0) <Form bind:formEl ariaDescribedBy="formFailureMessageAlert" onSubmitWhenValid={form?.submit}>
|
|
33729
34206
|
function create_default_slot$3(ctx) {
|
|
33730
34207
|
let t0;
|
|
33731
|
-
let h1;
|
|
33732
34208
|
let t1;
|
|
33733
34209
|
let t2;
|
|
33734
|
-
let p;
|
|
33735
|
-
let t3;
|
|
33736
|
-
let t4;
|
|
33737
|
-
let t5;
|
|
33738
|
-
let t6;
|
|
33739
34210
|
let if_block2_anchor;
|
|
33740
34211
|
let current;
|
|
33741
|
-
let if_block0 = /*
|
|
33742
|
-
|
|
33743
|
-
|
|
33744
|
-
t3 = new Locale_strings({
|
|
33745
|
-
props: { key: "alreadyHaveAnAccount", html: true }
|
|
33746
|
-
});
|
|
33747
|
-
|
|
33748
|
-
let if_block1 = /*form*/ ctx[1].message && create_if_block_1$2(ctx);
|
|
33749
|
-
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;
|
|
33750
34215
|
let each_blocks = [];
|
|
33751
34216
|
|
|
33752
34217
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -33757,61 +34222,48 @@ function create_default_slot$3(ctx) {
|
|
|
33757
34222
|
each_blocks[i] = null;
|
|
33758
34223
|
});
|
|
33759
34224
|
|
|
33760
|
-
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);
|
|
33761
34226
|
|
|
33762
34227
|
return {
|
|
33763
34228
|
c() {
|
|
33764
34229
|
if (if_block0) if_block0.c();
|
|
33765
34230
|
t0 = space();
|
|
33766
|
-
h1 = element("h1");
|
|
33767
|
-
create_component(t1.$$.fragment);
|
|
33768
|
-
t2 = space();
|
|
33769
|
-
p = element("p");
|
|
33770
|
-
create_component(t3.$$.fragment);
|
|
33771
|
-
t4 = space();
|
|
33772
34231
|
if (if_block1) if_block1.c();
|
|
33773
|
-
|
|
34232
|
+
t1 = space();
|
|
33774
34233
|
|
|
33775
34234
|
for (let i = 0; i < each_blocks.length; i += 1) {
|
|
33776
34235
|
each_blocks[i].c();
|
|
33777
34236
|
}
|
|
33778
34237
|
|
|
33779
|
-
|
|
34238
|
+
t2 = space();
|
|
33780
34239
|
if (if_block2) if_block2.c();
|
|
33781
34240
|
if_block2_anchor = empty();
|
|
33782
|
-
attr(h1, "class", "tw_primary-header dark:tw_primary-header_dark");
|
|
33783
|
-
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");
|
|
33784
34241
|
},
|
|
33785
34242
|
m(target, anchor) {
|
|
33786
34243
|
if (if_block0) if_block0.m(target, anchor);
|
|
33787
34244
|
insert(target, t0, anchor);
|
|
33788
|
-
insert(target, h1, anchor);
|
|
33789
|
-
mount_component(t1, h1, null);
|
|
33790
|
-
insert(target, t2, anchor);
|
|
33791
|
-
insert(target, p, anchor);
|
|
33792
|
-
mount_component(t3, p, null);
|
|
33793
|
-
/*p_binding*/ ctx[10](p);
|
|
33794
|
-
insert(target, t4, anchor);
|
|
33795
34245
|
if (if_block1) if_block1.m(target, anchor);
|
|
33796
|
-
insert(target,
|
|
34246
|
+
insert(target, t1, anchor);
|
|
33797
34247
|
|
|
33798
34248
|
for (let i = 0; i < each_blocks.length; i += 1) {
|
|
33799
34249
|
each_blocks[i].m(target, anchor);
|
|
33800
34250
|
}
|
|
33801
34251
|
|
|
33802
|
-
insert(target,
|
|
34252
|
+
insert(target, t2, anchor);
|
|
33803
34253
|
if (if_block2) if_block2.m(target, anchor);
|
|
33804
34254
|
insert(target, if_block2_anchor, anchor);
|
|
33805
34255
|
current = true;
|
|
33806
34256
|
},
|
|
33807
34257
|
p(ctx, dirty) {
|
|
33808
|
-
if (/*
|
|
34258
|
+
if (/*componentStyle*/ ctx[1] !== 'inline') {
|
|
33809
34259
|
if (if_block0) {
|
|
33810
|
-
|
|
34260
|
+
if_block0.p(ctx, dirty);
|
|
34261
|
+
|
|
34262
|
+
if (dirty & /*componentStyle*/ 2) {
|
|
33811
34263
|
transition_in(if_block0, 1);
|
|
33812
34264
|
}
|
|
33813
34265
|
} else {
|
|
33814
|
-
if_block0 = create_if_block_2$2();
|
|
34266
|
+
if_block0 = create_if_block_2$2(ctx);
|
|
33815
34267
|
if_block0.c();
|
|
33816
34268
|
transition_in(if_block0, 1);
|
|
33817
34269
|
if_block0.m(t0.parentNode, t0);
|
|
@@ -33826,18 +34278,18 @@ function create_default_slot$3(ctx) {
|
|
|
33826
34278
|
check_outros();
|
|
33827
34279
|
}
|
|
33828
34280
|
|
|
33829
|
-
if (/*form*/ ctx[
|
|
34281
|
+
if (/*form*/ ctx[2].message) {
|
|
33830
34282
|
if (if_block1) {
|
|
33831
34283
|
if_block1.p(ctx, dirty);
|
|
33832
34284
|
|
|
33833
|
-
if (dirty & /*form*/
|
|
34285
|
+
if (dirty & /*form*/ 4) {
|
|
33834
34286
|
transition_in(if_block1, 1);
|
|
33835
34287
|
}
|
|
33836
34288
|
} else {
|
|
33837
34289
|
if_block1 = create_if_block_1$2(ctx);
|
|
33838
34290
|
if_block1.c();
|
|
33839
34291
|
transition_in(if_block1, 1);
|
|
33840
|
-
if_block1.m(
|
|
34292
|
+
if_block1.m(t1.parentNode, t1);
|
|
33841
34293
|
}
|
|
33842
34294
|
} else if (if_block1) {
|
|
33843
34295
|
group_outros();
|
|
@@ -33849,8 +34301,8 @@ function create_default_slot$3(ctx) {
|
|
|
33849
34301
|
check_outros();
|
|
33850
34302
|
}
|
|
33851
34303
|
|
|
33852
|
-
if (dirty & /*step, metadata, determineSubmission, $styleStore*/
|
|
33853
|
-
each_value = /*step*/ ctx[
|
|
34304
|
+
if (dirty & /*step, metadata, determineSubmission, $styleStore*/ 1584) {
|
|
34305
|
+
each_value = /*step*/ ctx[5]?.callbacks;
|
|
33854
34306
|
let i;
|
|
33855
34307
|
|
|
33856
34308
|
for (i = 0; i < each_value.length; i += 1) {
|
|
@@ -33863,7 +34315,7 @@ function create_default_slot$3(ctx) {
|
|
|
33863
34315
|
each_blocks[i] = create_each_block$1(child_ctx);
|
|
33864
34316
|
each_blocks[i].c();
|
|
33865
34317
|
transition_in(each_blocks[i], 1);
|
|
33866
|
-
each_blocks[i].m(
|
|
34318
|
+
each_blocks[i].m(t2.parentNode, t2);
|
|
33867
34319
|
}
|
|
33868
34320
|
}
|
|
33869
34321
|
|
|
@@ -33876,11 +34328,11 @@ function create_default_slot$3(ctx) {
|
|
|
33876
34328
|
check_outros();
|
|
33877
34329
|
}
|
|
33878
34330
|
|
|
33879
|
-
if (/*metadata*/ ctx[
|
|
34331
|
+
if (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) {
|
|
33880
34332
|
if (if_block2) {
|
|
33881
34333
|
if_block2.p(ctx, dirty);
|
|
33882
34334
|
|
|
33883
|
-
if (dirty & /*metadata*/
|
|
34335
|
+
if (dirty & /*metadata*/ 16) {
|
|
33884
34336
|
transition_in(if_block2, 1);
|
|
33885
34337
|
}
|
|
33886
34338
|
} else {
|
|
@@ -33902,8 +34354,6 @@ function create_default_slot$3(ctx) {
|
|
|
33902
34354
|
i(local) {
|
|
33903
34355
|
if (current) return;
|
|
33904
34356
|
transition_in(if_block0);
|
|
33905
|
-
transition_in(t1.$$.fragment, local);
|
|
33906
|
-
transition_in(t3.$$.fragment, local);
|
|
33907
34357
|
transition_in(if_block1);
|
|
33908
34358
|
|
|
33909
34359
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -33915,8 +34365,6 @@ function create_default_slot$3(ctx) {
|
|
|
33915
34365
|
},
|
|
33916
34366
|
o(local) {
|
|
33917
34367
|
transition_out(if_block0);
|
|
33918
|
-
transition_out(t1.$$.fragment, local);
|
|
33919
|
-
transition_out(t3.$$.fragment, local);
|
|
33920
34368
|
transition_out(if_block1);
|
|
33921
34369
|
each_blocks = each_blocks.filter(Boolean);
|
|
33922
34370
|
|
|
@@ -33930,17 +34378,10 @@ function create_default_slot$3(ctx) {
|
|
|
33930
34378
|
d(detaching) {
|
|
33931
34379
|
if (if_block0) if_block0.d(detaching);
|
|
33932
34380
|
if (detaching) detach(t0);
|
|
33933
|
-
if (detaching) detach(h1);
|
|
33934
|
-
destroy_component(t1);
|
|
33935
|
-
if (detaching) detach(t2);
|
|
33936
|
-
if (detaching) detach(p);
|
|
33937
|
-
destroy_component(t3);
|
|
33938
|
-
/*p_binding*/ ctx[10](null);
|
|
33939
|
-
if (detaching) detach(t4);
|
|
33940
34381
|
if (if_block1) if_block1.d(detaching);
|
|
33941
|
-
if (detaching) detach(
|
|
34382
|
+
if (detaching) detach(t1);
|
|
33942
34383
|
destroy_each(each_blocks, detaching);
|
|
33943
|
-
if (detaching) detach(
|
|
34384
|
+
if (detaching) detach(t2);
|
|
33944
34385
|
if (if_block2) if_block2.d(detaching);
|
|
33945
34386
|
if (detaching) detach(if_block2_anchor);
|
|
33946
34387
|
}
|
|
@@ -33953,12 +34394,12 @@ function create_fragment$3(ctx) {
|
|
|
33953
34394
|
let current;
|
|
33954
34395
|
|
|
33955
34396
|
function form_1_formEl_binding(value) {
|
|
33956
|
-
/*form_1_formEl_binding*/ ctx[
|
|
34397
|
+
/*form_1_formEl_binding*/ ctx[12](value);
|
|
33957
34398
|
}
|
|
33958
34399
|
|
|
33959
34400
|
let form_1_props = {
|
|
33960
34401
|
ariaDescribedBy: "formFailureMessageAlert",
|
|
33961
|
-
onSubmitWhenValid: /*form*/ ctx[
|
|
34402
|
+
onSubmitWhenValid: /*form*/ ctx[2]?.submit,
|
|
33962
34403
|
$$slots: { default: [create_default_slot$3] },
|
|
33963
34404
|
$$scope: { ctx }
|
|
33964
34405
|
};
|
|
@@ -33980,9 +34421,9 @@ function create_fragment$3(ctx) {
|
|
|
33980
34421
|
},
|
|
33981
34422
|
p(ctx, [dirty]) {
|
|
33982
34423
|
const form_1_changes = {};
|
|
33983
|
-
if (dirty & /*form*/
|
|
34424
|
+
if (dirty & /*form*/ 4) form_1_changes.onSubmitWhenValid = /*form*/ ctx[2]?.submit;
|
|
33984
34425
|
|
|
33985
|
-
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) {
|
|
33986
34427
|
form_1_changes.$$scope = { dirty, ctx };
|
|
33987
34428
|
}
|
|
33988
34429
|
|
|
@@ -34011,7 +34452,8 @@ function create_fragment$3(ctx) {
|
|
|
34011
34452
|
|
|
34012
34453
|
function instance$3($$self, $$props, $$invalidate) {
|
|
34013
34454
|
let $styleStore;
|
|
34014
|
-
component_subscribe($$self, styleStore, $$value => $$invalidate(
|
|
34455
|
+
component_subscribe($$self, styleStore, $$value => $$invalidate(9, $styleStore = $$value));
|
|
34456
|
+
let { componentStyle } = $$props;
|
|
34015
34457
|
let { form } = $$props;
|
|
34016
34458
|
let { formEl = null } = $$props;
|
|
34017
34459
|
let { journey } = $$props;
|
|
@@ -34031,15 +34473,25 @@ function instance$3($$self, $$props, $$invalidate) {
|
|
|
34031
34473
|
}
|
|
34032
34474
|
|
|
34033
34475
|
afterUpdate(() => {
|
|
34034
|
-
$$invalidate(
|
|
34476
|
+
$$invalidate(6, alertNeedsFocus = !!form?.message);
|
|
34035
34477
|
});
|
|
34036
34478
|
|
|
34037
|
-
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
|
+
});
|
|
34038
34490
|
|
|
34039
34491
|
function p_binding($$value) {
|
|
34040
34492
|
binding_callbacks[$$value ? 'unshift' : 'push'](() => {
|
|
34041
34493
|
linkWrapper = $$value;
|
|
34042
|
-
$$invalidate(
|
|
34494
|
+
$$invalidate(8, linkWrapper);
|
|
34043
34495
|
});
|
|
34044
34496
|
}
|
|
34045
34497
|
|
|
@@ -34049,23 +34501,25 @@ function instance$3($$self, $$props, $$invalidate) {
|
|
|
34049
34501
|
}
|
|
34050
34502
|
|
|
34051
34503
|
$$self.$$set = $$props => {
|
|
34052
|
-
if ('
|
|
34504
|
+
if ('componentStyle' in $$props) $$invalidate(1, componentStyle = $$props.componentStyle);
|
|
34505
|
+
if ('form' in $$props) $$invalidate(2, form = $$props.form);
|
|
34053
34506
|
if ('formEl' in $$props) $$invalidate(0, formEl = $$props.formEl);
|
|
34054
|
-
if ('journey' in $$props) $$invalidate(
|
|
34055
|
-
if ('metadata' in $$props) $$invalidate(
|
|
34056
|
-
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);
|
|
34057
34510
|
};
|
|
34058
34511
|
|
|
34059
34512
|
$$self.$$.update = () => {
|
|
34060
|
-
if ($$self.$$.dirty & /*form*/
|
|
34513
|
+
if ($$self.$$.dirty & /*form*/ 4) {
|
|
34061
34514
|
{
|
|
34062
|
-
$$invalidate(
|
|
34515
|
+
$$invalidate(7, formMessageKey = convertStringToKey(form?.message));
|
|
34063
34516
|
}
|
|
34064
34517
|
}
|
|
34065
34518
|
};
|
|
34066
34519
|
|
|
34067
34520
|
return [
|
|
34068
34521
|
formEl,
|
|
34522
|
+
componentStyle,
|
|
34069
34523
|
form,
|
|
34070
34524
|
journey,
|
|
34071
34525
|
metadata,
|
|
@@ -34085,26 +34539,93 @@ class Registration extends SvelteComponent {
|
|
|
34085
34539
|
super();
|
|
34086
34540
|
|
|
34087
34541
|
init(this, options, instance$3, create_fragment$3, safe_not_equal, {
|
|
34088
|
-
|
|
34542
|
+
componentStyle: 1,
|
|
34543
|
+
form: 2,
|
|
34089
34544
|
formEl: 0,
|
|
34090
|
-
journey:
|
|
34091
|
-
metadata:
|
|
34092
|
-
step:
|
|
34545
|
+
journey: 3,
|
|
34546
|
+
metadata: 4,
|
|
34547
|
+
step: 5
|
|
34093
34548
|
});
|
|
34094
34549
|
}
|
|
34095
34550
|
}
|
|
34096
34551
|
|
|
34097
|
-
/* src/lib/journey/stages/
|
|
34552
|
+
/* src/lib/journey/stages/login.svelte generated by Svelte v3.55.1 */
|
|
34098
34553
|
|
|
34099
34554
|
function get_each_context(ctx, list, i) {
|
|
34100
34555
|
const child_ctx = ctx.slice();
|
|
34101
|
-
child_ctx[
|
|
34102
|
-
child_ctx[
|
|
34556
|
+
child_ctx[15] = list[i];
|
|
34557
|
+
child_ctx[17] = i;
|
|
34103
34558
|
return child_ctx;
|
|
34104
34559
|
}
|
|
34105
34560
|
|
|
34106
|
-
// (
|
|
34107
|
-
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) {
|
|
34108
34629
|
let div;
|
|
34109
34630
|
let keyicon;
|
|
34110
34631
|
let current;
|
|
@@ -34143,15 +34664,15 @@ function create_if_block_2$1(ctx) {
|
|
|
34143
34664
|
};
|
|
34144
34665
|
}
|
|
34145
34666
|
|
|
34146
|
-
// (
|
|
34147
|
-
function
|
|
34667
|
+
// (56:2) {#if form?.message}
|
|
34668
|
+
function create_if_block_2$1(ctx) {
|
|
34148
34669
|
let alert;
|
|
34149
34670
|
let current;
|
|
34150
34671
|
|
|
34151
34672
|
alert = new Alert({
|
|
34152
34673
|
props: {
|
|
34153
34674
|
id: "formFailureMessageAlert",
|
|
34154
|
-
needsFocus: /*alertNeedsFocus*/ ctx[
|
|
34675
|
+
needsFocus: /*alertNeedsFocus*/ ctx[6],
|
|
34155
34676
|
type: "error",
|
|
34156
34677
|
$$slots: { default: [create_default_slot_2] },
|
|
34157
34678
|
$$scope: { ctx }
|
|
@@ -34168,9 +34689,9 @@ function create_if_block_1$1(ctx) {
|
|
|
34168
34689
|
},
|
|
34169
34690
|
p(ctx, dirty) {
|
|
34170
34691
|
const alert_changes = {};
|
|
34171
|
-
if (dirty & /*alertNeedsFocus*/
|
|
34692
|
+
if (dirty & /*alertNeedsFocus*/ 64) alert_changes.needsFocus = /*alertNeedsFocus*/ ctx[6];
|
|
34172
34693
|
|
|
34173
|
-
if (dirty & /*$$scope, formMessageKey, form*/
|
|
34694
|
+
if (dirty & /*$$scope, formMessageKey, form*/ 262276) {
|
|
34174
34695
|
alert_changes.$$scope = { dirty, ctx };
|
|
34175
34696
|
}
|
|
34176
34697
|
|
|
@@ -34191,9 +34712,9 @@ function create_if_block_1$1(ctx) {
|
|
|
34191
34712
|
};
|
|
34192
34713
|
}
|
|
34193
34714
|
|
|
34194
|
-
// (
|
|
34715
|
+
// (57:4) <Alert id="formFailureMessageAlert" needsFocus={alertNeedsFocus} type="error">
|
|
34195
34716
|
function create_default_slot_2(ctx) {
|
|
34196
|
-
let t_value = interpolate(/*formMessageKey*/ ctx[
|
|
34717
|
+
let t_value = interpolate(/*formMessageKey*/ ctx[7], null, /*form*/ ctx[2]?.message) + "";
|
|
34197
34718
|
let t;
|
|
34198
34719
|
|
|
34199
34720
|
return {
|
|
@@ -34204,7 +34725,7 @@ function create_default_slot_2(ctx) {
|
|
|
34204
34725
|
insert(target, t, anchor);
|
|
34205
34726
|
},
|
|
34206
34727
|
p(ctx, dirty) {
|
|
34207
|
-
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);
|
|
34208
34729
|
},
|
|
34209
34730
|
d(detaching) {
|
|
34210
34731
|
if (detaching) detach(t);
|
|
@@ -34212,7 +34733,7 @@ function create_default_slot_2(ctx) {
|
|
|
34212
34733
|
};
|
|
34213
34734
|
}
|
|
34214
34735
|
|
|
34215
|
-
// (
|
|
34736
|
+
// (62:2) {#each step?.callbacks as callback, idx}
|
|
34216
34737
|
function create_each_block(ctx) {
|
|
34217
34738
|
let callbackmapper;
|
|
34218
34739
|
let current;
|
|
@@ -34220,11 +34741,11 @@ function create_each_block(ctx) {
|
|
|
34220
34741
|
callbackmapper = new Callback_mapper({
|
|
34221
34742
|
props: {
|
|
34222
34743
|
props: {
|
|
34223
|
-
callback: /*callback*/ ctx[
|
|
34224
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
34225
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
34226
|
-
stepMetadata: /*metadata*/ ctx[
|
|
34227
|
-
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]
|
|
34228
34749
|
}
|
|
34229
34750
|
}
|
|
34230
34751
|
});
|
|
@@ -34240,12 +34761,12 @@ function create_each_block(ctx) {
|
|
|
34240
34761
|
p(ctx, dirty) {
|
|
34241
34762
|
const callbackmapper_changes = {};
|
|
34242
34763
|
|
|
34243
|
-
if (dirty & /*step, metadata, $styleStore*/
|
|
34244
|
-
callback: /*callback*/ ctx[
|
|
34245
|
-
callbackMetadata: /*metadata*/ ctx[
|
|
34246
|
-
selfSubmitFunction: /*determineSubmission*/ ctx[
|
|
34247
|
-
stepMetadata: /*metadata*/ ctx[
|
|
34248
|
-
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]
|
|
34249
34770
|
};
|
|
34250
34771
|
|
|
34251
34772
|
callbackmapper.$set(callbackmapper_changes);
|
|
@@ -34265,14 +34786,14 @@ function create_each_block(ctx) {
|
|
|
34265
34786
|
};
|
|
34266
34787
|
}
|
|
34267
34788
|
|
|
34268
|
-
// (
|
|
34269
|
-
function
|
|
34789
|
+
// (74:2) {#if metadata?.step?.derived.isUserInputOptional || !metadata?.step?.derived.isStepSelfSubmittable}
|
|
34790
|
+
function create_if_block_1$1(ctx) {
|
|
34270
34791
|
let button;
|
|
34271
34792
|
let current;
|
|
34272
34793
|
|
|
34273
34794
|
button = new Button({
|
|
34274
34795
|
props: {
|
|
34275
|
-
busy: /*journey*/ ctx[
|
|
34796
|
+
busy: /*journey*/ ctx[3]?.loading,
|
|
34276
34797
|
style: "primary",
|
|
34277
34798
|
type: "submit",
|
|
34278
34799
|
width: "full",
|
|
@@ -34291,9 +34812,9 @@ function create_if_block$2(ctx) {
|
|
|
34291
34812
|
},
|
|
34292
34813
|
p(ctx, dirty) {
|
|
34293
34814
|
const button_changes = {};
|
|
34294
|
-
if (dirty & /*journey*/
|
|
34815
|
+
if (dirty & /*journey*/ 8) button_changes.busy = /*journey*/ ctx[3]?.loading;
|
|
34295
34816
|
|
|
34296
|
-
if (dirty & /*$$scope*/
|
|
34817
|
+
if (dirty & /*$$scope*/ 262144) {
|
|
34297
34818
|
button_changes.$$scope = { dirty, ctx };
|
|
34298
34819
|
}
|
|
34299
34820
|
|
|
@@ -34314,7 +34835,7 @@ function create_if_block$2(ctx) {
|
|
|
34314
34835
|
};
|
|
34315
34836
|
}
|
|
34316
34837
|
|
|
34317
|
-
// (
|
|
34838
|
+
// (75:4) <Button busy={journey?.loading} style="primary" type="submit" width="full">
|
|
34318
34839
|
function create_default_slot_1$1(ctx) {
|
|
34319
34840
|
let t;
|
|
34320
34841
|
let current;
|
|
@@ -34344,31 +34865,99 @@ function create_default_slot_1$1(ctx) {
|
|
|
34344
34865
|
};
|
|
34345
34866
|
}
|
|
34346
34867
|
|
|
34347
|
-
// (
|
|
34348
|
-
function
|
|
34349
|
-
let t0;
|
|
34350
|
-
let h1;
|
|
34351
|
-
let t1;
|
|
34352
|
-
let t2;
|
|
34353
|
-
let t3;
|
|
34354
|
-
let t4;
|
|
34355
|
-
let t5;
|
|
34868
|
+
// (80:2) {#if componentStyle !== 'inline'}
|
|
34869
|
+
function create_if_block$2(ctx) {
|
|
34356
34870
|
let p0;
|
|
34357
34871
|
let button0;
|
|
34358
|
-
let
|
|
34872
|
+
let t1;
|
|
34359
34873
|
let button1;
|
|
34360
|
-
let
|
|
34874
|
+
let t3;
|
|
34361
34875
|
let hr;
|
|
34362
|
-
let
|
|
34876
|
+
let t4;
|
|
34363
34877
|
let p1;
|
|
34364
|
-
let
|
|
34878
|
+
let t5;
|
|
34365
34879
|
let current;
|
|
34366
34880
|
let mounted;
|
|
34367
34881
|
let dispose;
|
|
34368
|
-
|
|
34369
|
-
|
|
34370
|
-
|
|
34371
|
-
|
|
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;
|
|
34372
34961
|
let each_blocks = [];
|
|
34373
34962
|
|
|
34374
34963
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -34379,90 +34968,53 @@ function create_default_slot$2(ctx) {
|
|
|
34379
34968
|
each_blocks[i] = null;
|
|
34380
34969
|
});
|
|
34381
34970
|
|
|
34382
|
-
let if_block2 = (/*metadata*/ ctx[
|
|
34383
|
-
|
|
34384
|
-
t11 = new Locale_strings({
|
|
34385
|
-
props: { key: "dontHaveAnAccount", html: true }
|
|
34386
|
-
});
|
|
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);
|
|
34387
34973
|
|
|
34388
34974
|
return {
|
|
34389
34975
|
c() {
|
|
34390
34976
|
if (if_block0) if_block0.c();
|
|
34391
34977
|
t0 = space();
|
|
34392
|
-
h1 = element("h1");
|
|
34393
|
-
create_component(t1.$$.fragment);
|
|
34394
|
-
t2 = space();
|
|
34395
34978
|
if (if_block1) if_block1.c();
|
|
34396
|
-
|
|
34979
|
+
t1 = space();
|
|
34397
34980
|
|
|
34398
34981
|
for (let i = 0; i < each_blocks.length; i += 1) {
|
|
34399
34982
|
each_blocks[i].c();
|
|
34400
34983
|
}
|
|
34401
34984
|
|
|
34402
|
-
|
|
34985
|
+
t2 = space();
|
|
34403
34986
|
if (if_block2) if_block2.c();
|
|
34404
|
-
|
|
34405
|
-
|
|
34406
|
-
|
|
34407
|
-
button0.textContent = `${interpolate('forgotPassword', null, 'Forgot Password?')}`;
|
|
34408
|
-
t7 = text("\n \n ");
|
|
34409
|
-
button1 = element("button");
|
|
34410
|
-
button1.textContent = `${interpolate('forgotUsername', null, 'Forgot Username?')}`;
|
|
34411
|
-
t9 = space();
|
|
34412
|
-
hr = element("hr");
|
|
34413
|
-
t10 = space();
|
|
34414
|
-
p1 = element("p");
|
|
34415
|
-
create_component(t11.$$.fragment);
|
|
34416
|
-
attr(h1, "class", "tw_primary-header dark:tw_primary-header_dark");
|
|
34417
|
-
attr(p0, "class", "tw_my-4 tw_text-base tw_text-center tw_text-link-dark dark:tw_text-link-light");
|
|
34418
|
-
attr(hr, "class", "tw_border-0 tw_border-b tw_border-secondary-light dark:tw_border-secondary-dark");
|
|
34419
|
-
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();
|
|
34420
34990
|
},
|
|
34421
34991
|
m(target, anchor) {
|
|
34422
34992
|
if (if_block0) if_block0.m(target, anchor);
|
|
34423
34993
|
insert(target, t0, anchor);
|
|
34424
|
-
insert(target, h1, anchor);
|
|
34425
|
-
mount_component(t1, h1, null);
|
|
34426
|
-
insert(target, t2, anchor);
|
|
34427
34994
|
if (if_block1) if_block1.m(target, anchor);
|
|
34428
|
-
insert(target,
|
|
34995
|
+
insert(target, t1, anchor);
|
|
34429
34996
|
|
|
34430
34997
|
for (let i = 0; i < each_blocks.length; i += 1) {
|
|
34431
34998
|
each_blocks[i].m(target, anchor);
|
|
34432
34999
|
}
|
|
34433
35000
|
|
|
34434
|
-
insert(target,
|
|
35001
|
+
insert(target, t2, anchor);
|
|
34435
35002
|
if (if_block2) if_block2.m(target, anchor);
|
|
34436
|
-
insert(target,
|
|
34437
|
-
|
|
34438
|
-
|
|
34439
|
-
append(p0, t7);
|
|
34440
|
-
append(p0, button1);
|
|
34441
|
-
insert(target, t9, anchor);
|
|
34442
|
-
insert(target, hr, anchor);
|
|
34443
|
-
insert(target, t10, anchor);
|
|
34444
|
-
insert(target, p1, anchor);
|
|
34445
|
-
mount_component(t11, p1, null);
|
|
34446
|
-
/*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);
|
|
34447
35006
|
current = true;
|
|
34448
|
-
|
|
34449
|
-
if (!mounted) {
|
|
34450
|
-
dispose = [
|
|
34451
|
-
listen(button0, "click", prevent_default(/*click_handler*/ ctx[10])),
|
|
34452
|
-
listen(button1, "click", prevent_default(/*click_handler_1*/ ctx[11]))
|
|
34453
|
-
];
|
|
34454
|
-
|
|
34455
|
-
mounted = true;
|
|
34456
|
-
}
|
|
34457
35007
|
},
|
|
34458
35008
|
p(ctx, dirty) {
|
|
34459
|
-
if (/*
|
|
35009
|
+
if (/*componentStyle*/ ctx[1] !== 'inline') {
|
|
34460
35010
|
if (if_block0) {
|
|
34461
|
-
|
|
35011
|
+
if_block0.p(ctx, dirty);
|
|
35012
|
+
|
|
35013
|
+
if (dirty & /*componentStyle*/ 2) {
|
|
34462
35014
|
transition_in(if_block0, 1);
|
|
34463
35015
|
}
|
|
34464
35016
|
} else {
|
|
34465
|
-
if_block0 =
|
|
35017
|
+
if_block0 = create_if_block_3$1(ctx);
|
|
34466
35018
|
if_block0.c();
|
|
34467
35019
|
transition_in(if_block0, 1);
|
|
34468
35020
|
if_block0.m(t0.parentNode, t0);
|
|
@@ -34477,18 +35029,18 @@ function create_default_slot$2(ctx) {
|
|
|
34477
35029
|
check_outros();
|
|
34478
35030
|
}
|
|
34479
35031
|
|
|
34480
|
-
if (/*form*/ ctx[
|
|
35032
|
+
if (/*form*/ ctx[2]?.message) {
|
|
34481
35033
|
if (if_block1) {
|
|
34482
35034
|
if_block1.p(ctx, dirty);
|
|
34483
35035
|
|
|
34484
|
-
if (dirty & /*form*/
|
|
35036
|
+
if (dirty & /*form*/ 4) {
|
|
34485
35037
|
transition_in(if_block1, 1);
|
|
34486
35038
|
}
|
|
34487
35039
|
} else {
|
|
34488
|
-
if_block1 =
|
|
35040
|
+
if_block1 = create_if_block_2$1(ctx);
|
|
34489
35041
|
if_block1.c();
|
|
34490
35042
|
transition_in(if_block1, 1);
|
|
34491
|
-
if_block1.m(
|
|
35043
|
+
if_block1.m(t1.parentNode, t1);
|
|
34492
35044
|
}
|
|
34493
35045
|
} else if (if_block1) {
|
|
34494
35046
|
group_outros();
|
|
@@ -34500,8 +35052,8 @@ function create_default_slot$2(ctx) {
|
|
|
34500
35052
|
check_outros();
|
|
34501
35053
|
}
|
|
34502
35054
|
|
|
34503
|
-
if (dirty & /*step, metadata, determineSubmission, $styleStore*/
|
|
34504
|
-
each_value = /*step*/ ctx[
|
|
35055
|
+
if (dirty & /*step, metadata, determineSubmission, $styleStore*/ 1584) {
|
|
35056
|
+
each_value = /*step*/ ctx[5]?.callbacks;
|
|
34505
35057
|
let i;
|
|
34506
35058
|
|
|
34507
35059
|
for (i = 0; i < each_value.length; i += 1) {
|
|
@@ -34514,7 +35066,7 @@ function create_default_slot$2(ctx) {
|
|
|
34514
35066
|
each_blocks[i] = create_each_block(child_ctx);
|
|
34515
35067
|
each_blocks[i].c();
|
|
34516
35068
|
transition_in(each_blocks[i], 1);
|
|
34517
|
-
each_blocks[i].m(
|
|
35069
|
+
each_blocks[i].m(t2.parentNode, t2);
|
|
34518
35070
|
}
|
|
34519
35071
|
}
|
|
34520
35072
|
|
|
@@ -34527,18 +35079,18 @@ function create_default_slot$2(ctx) {
|
|
|
34527
35079
|
check_outros();
|
|
34528
35080
|
}
|
|
34529
35081
|
|
|
34530
|
-
if (/*metadata*/ ctx[
|
|
35082
|
+
if (/*metadata*/ ctx[4]?.step?.derived.isUserInputOptional || !/*metadata*/ ctx[4]?.step?.derived.isStepSelfSubmittable) {
|
|
34531
35083
|
if (if_block2) {
|
|
34532
35084
|
if_block2.p(ctx, dirty);
|
|
34533
35085
|
|
|
34534
|
-
if (dirty & /*metadata*/
|
|
35086
|
+
if (dirty & /*metadata*/ 16) {
|
|
34535
35087
|
transition_in(if_block2, 1);
|
|
34536
35088
|
}
|
|
34537
35089
|
} else {
|
|
34538
|
-
if_block2 =
|
|
35090
|
+
if_block2 = create_if_block_1$1(ctx);
|
|
34539
35091
|
if_block2.c();
|
|
34540
35092
|
transition_in(if_block2, 1);
|
|
34541
|
-
if_block2.m(
|
|
35093
|
+
if_block2.m(t3.parentNode, t3);
|
|
34542
35094
|
}
|
|
34543
35095
|
} else if (if_block2) {
|
|
34544
35096
|
group_outros();
|
|
@@ -34549,11 +35101,33 @@ function create_default_slot$2(ctx) {
|
|
|
34549
35101
|
|
|
34550
35102
|
check_outros();
|
|
34551
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
|
+
}
|
|
34552
35127
|
},
|
|
34553
35128
|
i(local) {
|
|
34554
35129
|
if (current) return;
|
|
34555
35130
|
transition_in(if_block0);
|
|
34556
|
-
transition_in(t1.$$.fragment, local);
|
|
34557
35131
|
transition_in(if_block1);
|
|
34558
35132
|
|
|
34559
35133
|
for (let i = 0; i < each_value.length; i += 1) {
|
|
@@ -34561,12 +35135,11 @@ function create_default_slot$2(ctx) {
|
|
|
34561
35135
|
}
|
|
34562
35136
|
|
|
34563
35137
|
transition_in(if_block2);
|
|
34564
|
-
transition_in(
|
|
35138
|
+
transition_in(if_block3);
|
|
34565
35139
|
current = true;
|
|
34566
35140
|
},
|
|
34567
35141
|
o(local) {
|
|
34568
35142
|
transition_out(if_block0);
|
|
34569
|
-
transition_out(t1.$$.fragment, local);
|
|
34570
35143
|
transition_out(if_block1);
|
|
34571
35144
|
each_blocks = each_blocks.filter(Boolean);
|
|
34572
35145
|
|
|
@@ -34575,30 +35148,20 @@ function create_default_slot$2(ctx) {
|
|
|
34575
35148
|
}
|
|
34576
35149
|
|
|
34577
35150
|
transition_out(if_block2);
|
|
34578
|
-
transition_out(
|
|
35151
|
+
transition_out(if_block3);
|
|
34579
35152
|
current = false;
|
|
34580
35153
|
},
|
|
34581
35154
|
d(detaching) {
|
|
34582
35155
|
if (if_block0) if_block0.d(detaching);
|
|
34583
35156
|
if (detaching) detach(t0);
|
|
34584
|
-
if (detaching) detach(h1);
|
|
34585
|
-
destroy_component(t1);
|
|
34586
|
-
if (detaching) detach(t2);
|
|
34587
35157
|
if (if_block1) if_block1.d(detaching);
|
|
34588
|
-
if (detaching) detach(
|
|
35158
|
+
if (detaching) detach(t1);
|
|
34589
35159
|
destroy_each(each_blocks, detaching);
|
|
34590
|
-
if (detaching) detach(
|
|
35160
|
+
if (detaching) detach(t2);
|
|
34591
35161
|
if (if_block2) if_block2.d(detaching);
|
|
34592
|
-
if (detaching) detach(
|
|
34593
|
-
if (
|
|
34594
|
-
if (detaching) detach(
|
|
34595
|
-
if (detaching) detach(hr);
|
|
34596
|
-
if (detaching) detach(t10);
|
|
34597
|
-
if (detaching) detach(p1);
|
|
34598
|
-
destroy_component(t11);
|
|
34599
|
-
/*p1_binding*/ ctx[12](null);
|
|
34600
|
-
mounted = false;
|
|
34601
|
-
run_all(dispose);
|
|
35162
|
+
if (detaching) detach(t3);
|
|
35163
|
+
if (if_block3) if_block3.d(detaching);
|
|
35164
|
+
if (detaching) detach(if_block3_anchor);
|
|
34602
35165
|
}
|
|
34603
35166
|
};
|
|
34604
35167
|
}
|
|
@@ -34609,12 +35172,12 @@ function create_fragment$2(ctx) {
|
|
|
34609
35172
|
let current;
|
|
34610
35173
|
|
|
34611
35174
|
function form_1_formEl_binding(value) {
|
|
34612
|
-
/*form_1_formEl_binding*/ ctx[
|
|
35175
|
+
/*form_1_formEl_binding*/ ctx[14](value);
|
|
34613
35176
|
}
|
|
34614
35177
|
|
|
34615
35178
|
let form_1_props = {
|
|
34616
35179
|
ariaDescribedBy: "formFailureMessageAlert",
|
|
34617
|
-
onSubmitWhenValid: /*form*/ ctx[
|
|
35180
|
+
onSubmitWhenValid: /*form*/ ctx[2]?.submit,
|
|
34618
35181
|
$$slots: { default: [create_default_slot$2] },
|
|
34619
35182
|
$$scope: { ctx }
|
|
34620
35183
|
};
|
|
@@ -34636,9 +35199,9 @@ function create_fragment$2(ctx) {
|
|
|
34636
35199
|
},
|
|
34637
35200
|
p(ctx, [dirty]) {
|
|
34638
35201
|
const form_1_changes = {};
|
|
34639
|
-
if (dirty & /*form*/
|
|
35202
|
+
if (dirty & /*form*/ 4) form_1_changes.onSubmitWhenValid = /*form*/ ctx[2]?.submit;
|
|
34640
35203
|
|
|
34641
|
-
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) {
|
|
34642
35205
|
form_1_changes.$$scope = { dirty, ctx };
|
|
34643
35206
|
}
|
|
34644
35207
|
|
|
@@ -34667,7 +35230,8 @@ function create_fragment$2(ctx) {
|
|
|
34667
35230
|
|
|
34668
35231
|
function instance$2($$self, $$props, $$invalidate) {
|
|
34669
35232
|
let $styleStore;
|
|
34670
|
-
component_subscribe($$self, styleStore, $$value => $$invalidate(
|
|
35233
|
+
component_subscribe($$self, styleStore, $$value => $$invalidate(9, $styleStore = $$value));
|
|
35234
|
+
let { componentStyle } = $$props;
|
|
34671
35235
|
let { form } = $$props;
|
|
34672
35236
|
let { formEl = null } = $$props;
|
|
34673
35237
|
let { journey } = $$props;
|
|
@@ -34687,10 +35251,14 @@ function instance$2($$self, $$props, $$invalidate) {
|
|
|
34687
35251
|
}
|
|
34688
35252
|
|
|
34689
35253
|
afterUpdate(() => {
|
|
34690
|
-
$$invalidate(
|
|
35254
|
+
$$invalidate(6, alertNeedsFocus = !!form?.message);
|
|
34691
35255
|
});
|
|
34692
35256
|
|
|
34693
|
-
onMount(() =>
|
|
35257
|
+
onMount(() => {
|
|
35258
|
+
if (componentStyle === 'modal') {
|
|
35259
|
+
captureLinks(linkWrapper, journey);
|
|
35260
|
+
}
|
|
35261
|
+
});
|
|
34694
35262
|
|
|
34695
35263
|
const click_handler = () => {
|
|
34696
35264
|
journey.push({ tree: 'ResetPassword' });
|
|
@@ -34703,7 +35271,7 @@ function instance$2($$self, $$props, $$invalidate) {
|
|
|
34703
35271
|
function p1_binding($$value) {
|
|
34704
35272
|
binding_callbacks[$$value ? 'unshift' : 'push'](() => {
|
|
34705
35273
|
linkWrapper = $$value;
|
|
34706
|
-
$$invalidate(
|
|
35274
|
+
$$invalidate(8, linkWrapper);
|
|
34707
35275
|
});
|
|
34708
35276
|
}
|
|
34709
35277
|
|
|
@@ -34713,23 +35281,25 @@ function instance$2($$self, $$props, $$invalidate) {
|
|
|
34713
35281
|
}
|
|
34714
35282
|
|
|
34715
35283
|
$$self.$$set = $$props => {
|
|
34716
|
-
if ('
|
|
35284
|
+
if ('componentStyle' in $$props) $$invalidate(1, componentStyle = $$props.componentStyle);
|
|
35285
|
+
if ('form' in $$props) $$invalidate(2, form = $$props.form);
|
|
34717
35286
|
if ('formEl' in $$props) $$invalidate(0, formEl = $$props.formEl);
|
|
34718
|
-
if ('journey' in $$props) $$invalidate(
|
|
34719
|
-
if ('metadata' in $$props) $$invalidate(
|
|
34720
|
-
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);
|
|
34721
35290
|
};
|
|
34722
35291
|
|
|
34723
35292
|
$$self.$$.update = () => {
|
|
34724
|
-
if ($$self.$$.dirty & /*form*/
|
|
35293
|
+
if ($$self.$$.dirty & /*form*/ 4) {
|
|
34725
35294
|
{
|
|
34726
|
-
$$invalidate(
|
|
35295
|
+
$$invalidate(7, formMessageKey = convertStringToKey(form?.message));
|
|
34727
35296
|
}
|
|
34728
35297
|
}
|
|
34729
35298
|
};
|
|
34730
35299
|
|
|
34731
35300
|
return [
|
|
34732
35301
|
formEl,
|
|
35302
|
+
componentStyle,
|
|
34733
35303
|
form,
|
|
34734
35304
|
journey,
|
|
34735
35305
|
metadata,
|
|
@@ -34746,38 +35316,37 @@ function instance$2($$self, $$props, $$invalidate) {
|
|
|
34746
35316
|
];
|
|
34747
35317
|
}
|
|
34748
35318
|
|
|
34749
|
-
class
|
|
35319
|
+
class Login extends SvelteComponent {
|
|
34750
35320
|
constructor(options) {
|
|
34751
35321
|
super();
|
|
34752
35322
|
|
|
34753
35323
|
init(this, options, instance$2, create_fragment$2, safe_not_equal, {
|
|
34754
|
-
|
|
35324
|
+
componentStyle: 1,
|
|
35325
|
+
form: 2,
|
|
34755
35326
|
formEl: 0,
|
|
34756
|
-
journey:
|
|
34757
|
-
metadata:
|
|
34758
|
-
step:
|
|
35327
|
+
journey: 3,
|
|
35328
|
+
metadata: 4,
|
|
35329
|
+
step: 5
|
|
34759
35330
|
});
|
|
34760
35331
|
}
|
|
34761
35332
|
}
|
|
34762
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
|
+
*/
|
|
34763
35339
|
function mapStepToStage(currentStep) {
|
|
34764
|
-
/** *********************************************************************
|
|
34765
|
-
* SDK INTEGRATION POINT
|
|
34766
|
-
* Summary:SDK step method for getting the stage value
|
|
34767
|
-
* ----------------------------------------------------------------------
|
|
34768
|
-
* Details: This method is helpful in quickly identifying the stage
|
|
34769
|
-
* when you want to provide special layout or handling of the form
|
|
34770
|
-
********************************************************************* */
|
|
34771
35340
|
if (!currentStep || currentStep.type !== 'Step') {
|
|
34772
35341
|
return Generic;
|
|
34773
35342
|
}
|
|
34774
35343
|
switch (currentStep?.getStage && currentStep.getStage()) {
|
|
34775
35344
|
case 'OneTimePassword':
|
|
34776
35345
|
return One_time_password;
|
|
34777
|
-
case '
|
|
35346
|
+
case 'DefaultRegistration':
|
|
34778
35347
|
return Registration;
|
|
34779
|
-
case '
|
|
34780
|
-
return
|
|
35348
|
+
case 'DefaultLogin':
|
|
35349
|
+
return Login;
|
|
34781
35350
|
default:
|
|
34782
35351
|
return Generic;
|
|
34783
35352
|
}
|
|
@@ -34794,7 +35363,7 @@ function create_else_block$1(ctx) {
|
|
|
34794
35363
|
alert = new Alert({
|
|
34795
35364
|
props: {
|
|
34796
35365
|
id: "unrecoverableStepError",
|
|
34797
|
-
needsFocus: /*alertNeedsFocus*/ ctx[
|
|
35366
|
+
needsFocus: /*alertNeedsFocus*/ ctx[4],
|
|
34798
35367
|
type: "error",
|
|
34799
35368
|
$$slots: { default: [create_default_slot_1] },
|
|
34800
35369
|
$$scope: { ctx }
|
|
@@ -34804,7 +35373,7 @@ function create_else_block$1(ctx) {
|
|
|
34804
35373
|
button = new Button({
|
|
34805
35374
|
props: {
|
|
34806
35375
|
style: "secondary",
|
|
34807
|
-
onClick: /*tryAgain*/ ctx[
|
|
35376
|
+
onClick: /*tryAgain*/ ctx[7],
|
|
34808
35377
|
$$slots: { default: [create_default_slot$1] },
|
|
34809
35378
|
$$scope: { ctx }
|
|
34810
35379
|
}
|
|
@@ -34824,16 +35393,16 @@ function create_else_block$1(ctx) {
|
|
|
34824
35393
|
},
|
|
34825
35394
|
p(ctx, dirty) {
|
|
34826
35395
|
const alert_changes = {};
|
|
34827
|
-
if (dirty & /*alertNeedsFocus*/
|
|
35396
|
+
if (dirty & /*alertNeedsFocus*/ 16) alert_changes.needsFocus = /*alertNeedsFocus*/ ctx[4];
|
|
34828
35397
|
|
|
34829
|
-
if (dirty & /*$$scope*/
|
|
35398
|
+
if (dirty & /*$$scope*/ 512) {
|
|
34830
35399
|
alert_changes.$$scope = { dirty, ctx };
|
|
34831
35400
|
}
|
|
34832
35401
|
|
|
34833
35402
|
alert.$set(alert_changes);
|
|
34834
35403
|
const button_changes = {};
|
|
34835
35404
|
|
|
34836
|
-
if (dirty & /*$$scope*/
|
|
35405
|
+
if (dirty & /*$$scope*/ 512) {
|
|
34837
35406
|
button_changes.$$scope = { dirty, ctx };
|
|
34838
35407
|
}
|
|
34839
35408
|
|
|
@@ -34858,7 +35427,7 @@ function create_else_block$1(ctx) {
|
|
|
34858
35427
|
};
|
|
34859
35428
|
}
|
|
34860
35429
|
|
|
34861
|
-
// (
|
|
35430
|
+
// (56:52)
|
|
34862
35431
|
function create_if_block_3(ctx) {
|
|
34863
35432
|
let div;
|
|
34864
35433
|
let spinner;
|
|
@@ -34899,7 +35468,7 @@ function create_if_block_3(ctx) {
|
|
|
34899
35468
|
};
|
|
34900
35469
|
}
|
|
34901
35470
|
|
|
34902
|
-
// (
|
|
35471
|
+
// (30:0) {#if $journeyStore && !$journeyStore.completed}
|
|
34903
35472
|
function create_if_block$1(ctx) {
|
|
34904
35473
|
let current_block_type_index;
|
|
34905
35474
|
let if_block;
|
|
@@ -34909,8 +35478,8 @@ function create_if_block$1(ctx) {
|
|
|
34909
35478
|
const if_blocks = [];
|
|
34910
35479
|
|
|
34911
35480
|
function select_block_type_1(ctx, dirty) {
|
|
34912
|
-
if (!/*$journeyStore*/ ctx[
|
|
34913
|
-
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;
|
|
34914
35483
|
return -1;
|
|
34915
35484
|
}
|
|
34916
35485
|
|
|
@@ -34986,7 +35555,7 @@ function create_if_block$1(ctx) {
|
|
|
34986
35555
|
};
|
|
34987
35556
|
}
|
|
34988
35557
|
|
|
34989
|
-
// (
|
|
35558
|
+
// (61:2) <Alert id="unrecoverableStepError" needsFocus={alertNeedsFocus} type="error">
|
|
34990
35559
|
function create_default_slot_1(ctx) {
|
|
34991
35560
|
let t;
|
|
34992
35561
|
let current;
|
|
@@ -35019,7 +35588,7 @@ function create_default_slot_1(ctx) {
|
|
|
35019
35588
|
};
|
|
35020
35589
|
}
|
|
35021
35590
|
|
|
35022
|
-
// (
|
|
35591
|
+
// (64:2) <Button style="secondary" onClick={tryAgain}>
|
|
35023
35592
|
function create_default_slot$1(ctx) {
|
|
35024
35593
|
let t;
|
|
35025
35594
|
let current;
|
|
@@ -35049,7 +35618,7 @@ function create_default_slot$1(ctx) {
|
|
|
35049
35618
|
};
|
|
35050
35619
|
}
|
|
35051
35620
|
|
|
35052
|
-
// (
|
|
35621
|
+
// (35:55)
|
|
35053
35622
|
function create_if_block_2(ctx) {
|
|
35054
35623
|
let switch_instance;
|
|
35055
35624
|
let updating_formEl;
|
|
@@ -35057,27 +35626,28 @@ function create_if_block_2(ctx) {
|
|
|
35057
35626
|
let current;
|
|
35058
35627
|
|
|
35059
35628
|
function switch_instance_formEl_binding(value) {
|
|
35060
|
-
/*switch_instance_formEl_binding*/ ctx[
|
|
35629
|
+
/*switch_instance_formEl_binding*/ ctx[8](value);
|
|
35061
35630
|
}
|
|
35062
35631
|
|
|
35063
|
-
var switch_value = mapStepToStage(/*$journeyStore*/ ctx[
|
|
35632
|
+
var switch_value = mapStepToStage(/*$journeyStore*/ ctx[5].step);
|
|
35064
35633
|
|
|
35065
35634
|
function switch_props(ctx) {
|
|
35066
35635
|
let switch_instance_props = {
|
|
35636
|
+
componentStyle: /*componentStyle*/ ctx[1],
|
|
35067
35637
|
form: {
|
|
35068
|
-
icon: /*displayIcon*/ ctx[
|
|
35069
|
-
message: /*$journeyStore*/ ctx[
|
|
35070
|
-
status: (/*$journeyStore*/ ctx[
|
|
35071
|
-
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]
|
|
35072
35642
|
},
|
|
35073
35643
|
journey: {
|
|
35074
|
-
loading: /*$journeyStore*/ ctx[
|
|
35075
|
-
pop: /*journeyStore*/ ctx[
|
|
35076
|
-
push: /*journeyStore*/ ctx[
|
|
35644
|
+
loading: /*$journeyStore*/ ctx[5].loading,
|
|
35645
|
+
pop: /*journeyStore*/ ctx[3].pop,
|
|
35646
|
+
push: /*journeyStore*/ ctx[3].push,
|
|
35077
35647
|
stack
|
|
35078
35648
|
},
|
|
35079
|
-
metadata: /*$journeyStore*/ ctx[
|
|
35080
|
-
step: /*$journeyStore*/ ctx[
|
|
35649
|
+
metadata: /*$journeyStore*/ ctx[5].metadata,
|
|
35650
|
+
step: /*$journeyStore*/ ctx[5].step
|
|
35081
35651
|
};
|
|
35082
35652
|
|
|
35083
35653
|
if (/*formEl*/ ctx[0] !== void 0) {
|
|
@@ -35104,23 +35674,24 @@ function create_if_block_2(ctx) {
|
|
|
35104
35674
|
},
|
|
35105
35675
|
p(ctx, dirty) {
|
|
35106
35676
|
const switch_instance_changes = {};
|
|
35677
|
+
if (dirty & /*componentStyle*/ 2) switch_instance_changes.componentStyle = /*componentStyle*/ ctx[1];
|
|
35107
35678
|
|
|
35108
|
-
if (dirty & /*displayIcon, $journeyStore*/
|
|
35109
|
-
icon: /*displayIcon*/ ctx[
|
|
35110
|
-
message: /*$journeyStore*/ ctx[
|
|
35111
|
-
status: (/*$journeyStore*/ ctx[
|
|
35112
|
-
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]
|
|
35113
35684
|
};
|
|
35114
35685
|
|
|
35115
|
-
if (dirty & /*$journeyStore, journeyStore*/
|
|
35116
|
-
loading: /*$journeyStore*/ ctx[
|
|
35117
|
-
pop: /*journeyStore*/ ctx[
|
|
35118
|
-
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,
|
|
35119
35690
|
stack
|
|
35120
35691
|
};
|
|
35121
35692
|
|
|
35122
|
-
if (dirty & /*$journeyStore*/
|
|
35123
|
-
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;
|
|
35124
35695
|
|
|
35125
35696
|
if (!updating_formEl && dirty & /*formEl*/ 1) {
|
|
35126
35697
|
updating_formEl = true;
|
|
@@ -35128,7 +35699,7 @@ function create_if_block_2(ctx) {
|
|
|
35128
35699
|
add_flush_callback(() => updating_formEl = false);
|
|
35129
35700
|
}
|
|
35130
35701
|
|
|
35131
|
-
if (switch_value !== (switch_value = mapStepToStage(/*$journeyStore*/ ctx[
|
|
35702
|
+
if (switch_value !== (switch_value = mapStepToStage(/*$journeyStore*/ ctx[5].step))) {
|
|
35132
35703
|
if (switch_instance) {
|
|
35133
35704
|
group_outros();
|
|
35134
35705
|
const old_component = switch_instance;
|
|
@@ -35169,7 +35740,7 @@ function create_if_block_2(ctx) {
|
|
|
35169
35740
|
};
|
|
35170
35741
|
}
|
|
35171
35742
|
|
|
35172
|
-
// (
|
|
35743
|
+
// (31:2) {#if $journeyStore && !$journeyStore.step}
|
|
35173
35744
|
function create_if_block_1(ctx) {
|
|
35174
35745
|
let div;
|
|
35175
35746
|
let spinner;
|
|
@@ -35219,8 +35790,8 @@ function create_fragment$1(ctx) {
|
|
|
35219
35790
|
const if_blocks = [];
|
|
35220
35791
|
|
|
35221
35792
|
function select_block_type(ctx, dirty) {
|
|
35222
|
-
if (!/*$journeyStore*/ ctx[
|
|
35223
|
-
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;
|
|
35224
35795
|
return 2;
|
|
35225
35796
|
}
|
|
35226
35797
|
|
|
@@ -35283,13 +35854,19 @@ function create_fragment$1(ctx) {
|
|
|
35283
35854
|
function instance$1($$self, $$props, $$invalidate) {
|
|
35284
35855
|
let $journeyStore,
|
|
35285
35856
|
$$unsubscribe_journeyStore = noop,
|
|
35286
|
-
$$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);
|
|
35287
35858
|
|
|
35288
35859
|
$$self.$$.on_destroy.push(() => $$unsubscribe_journeyStore());
|
|
35860
|
+
let { componentStyle } = $$props;
|
|
35289
35861
|
let { displayIcon } = $$props;
|
|
35290
35862
|
let { formEl = null } = $$props;
|
|
35291
35863
|
let { journeyStore } = $$props;
|
|
35292
35864
|
$$subscribe_journeyStore();
|
|
35865
|
+
|
|
35866
|
+
if (!$journeyStore) {
|
|
35867
|
+
console.error('Widget missing configuration. Import and call `configuration()`, then use `set()` to configure.');
|
|
35868
|
+
}
|
|
35869
|
+
|
|
35293
35870
|
let alertNeedsFocus = false;
|
|
35294
35871
|
|
|
35295
35872
|
function submitForm() {
|
|
@@ -35303,7 +35880,7 @@ function instance$1($$self, $$props, $$invalidate) {
|
|
|
35303
35880
|
}
|
|
35304
35881
|
|
|
35305
35882
|
afterUpdate(() => {
|
|
35306
|
-
$$invalidate(
|
|
35883
|
+
$$invalidate(4, alertNeedsFocus = $journeyStore && !$journeyStore.successful);
|
|
35307
35884
|
});
|
|
35308
35885
|
|
|
35309
35886
|
function switch_instance_formEl_binding(value) {
|
|
@@ -35312,13 +35889,15 @@ function instance$1($$self, $$props, $$invalidate) {
|
|
|
35312
35889
|
}
|
|
35313
35890
|
|
|
35314
35891
|
$$self.$$set = $$props => {
|
|
35315
|
-
if ('
|
|
35892
|
+
if ('componentStyle' in $$props) $$invalidate(1, componentStyle = $$props.componentStyle);
|
|
35893
|
+
if ('displayIcon' in $$props) $$invalidate(2, displayIcon = $$props.displayIcon);
|
|
35316
35894
|
if ('formEl' in $$props) $$invalidate(0, formEl = $$props.formEl);
|
|
35317
|
-
if ('journeyStore' in $$props) $$subscribe_journeyStore($$invalidate(
|
|
35895
|
+
if ('journeyStore' in $$props) $$subscribe_journeyStore($$invalidate(3, journeyStore = $$props.journeyStore));
|
|
35318
35896
|
};
|
|
35319
35897
|
|
|
35320
35898
|
return [
|
|
35321
35899
|
formEl,
|
|
35900
|
+
componentStyle,
|
|
35322
35901
|
displayIcon,
|
|
35323
35902
|
journeyStore,
|
|
35324
35903
|
alertNeedsFocus,
|
|
@@ -35334,9 +35913,10 @@ class Journey extends SvelteComponent {
|
|
|
35334
35913
|
super();
|
|
35335
35914
|
|
|
35336
35915
|
init(this, options, instance$1, create_fragment$1, safe_not_equal, {
|
|
35337
|
-
|
|
35916
|
+
componentStyle: 1,
|
|
35917
|
+
displayIcon: 2,
|
|
35338
35918
|
formEl: 0,
|
|
35339
|
-
journeyStore:
|
|
35919
|
+
journeyStore: 3
|
|
35340
35920
|
});
|
|
35341
35921
|
}
|
|
35342
35922
|
}
|
|
@@ -35354,6 +35934,7 @@ function create_else_block(ctx) {
|
|
|
35354
35934
|
}
|
|
35355
35935
|
|
|
35356
35936
|
let journey_1_props = {
|
|
35937
|
+
componentStyle: "inline",
|
|
35357
35938
|
displayIcon: /*$styleStore*/ ctx[4]?.stage?.icon ?? true,
|
|
35358
35939
|
journeyStore: /*journeyStore*/ ctx[5]
|
|
35359
35940
|
};
|
|
@@ -35485,6 +36066,7 @@ function create_default_slot(ctx) {
|
|
|
35485
36066
|
}
|
|
35486
36067
|
|
|
35487
36068
|
let journey_1_props = {
|
|
36069
|
+
componentStyle: "modal",
|
|
35488
36070
|
displayIcon: /*$styleStore*/ ctx[4]?.stage?.icon ?? !/*$styleStore*/ ctx[4]?.logo,
|
|
35489
36071
|
journeyStore: /*journeyStore*/ ctx[5]
|
|
35490
36072
|
};
|