@plaidev/karte-action-sdk 1.1.270-29228770.05dce6ca → 1.1.270-29270501.62e803ca6
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/dist/action.d.ts +0 -1
- package/dist/actionEvent.d.ts +0 -1
- package/dist/components/index.d.ts +0 -1
- package/dist/components-flex/avatar/types.d.ts +0 -1
- package/dist/components-flex/button/types.d.ts +0 -3
- package/dist/components-flex/button-outlined/types.d.ts +0 -3
- package/dist/components-flex/button-text/types.d.ts +0 -3
- package/dist/components-flex/form/types.d.ts +35 -20
- package/dist/components-flex/form.d.ts +40 -3
- package/dist/components-flex/icon/types.d.ts +0 -1
- package/dist/components-flex/text/types.d.ts +0 -3
- package/dist/components-flex/text-link/types.d.ts +0 -3
- package/dist/components-flex/variants.d.ts +0 -15
- package/dist/components-flex/youtube/types.d.ts +0 -1
- package/dist/constants.d.ts +0 -1
- package/dist/functions.d.ts +1 -1
- package/dist/hooks/useInjectCustomizeCss.d.ts +1 -1
- package/dist/hooks/useText.d.ts +1 -1
- package/dist/hydrate/action.d.ts +0 -1
- package/dist/hydrate/actionEvent.d.ts +0 -1
- package/dist/hydrate/components/index.d.ts +0 -1
- package/dist/hydrate/components-flex/avatar/types.d.ts +0 -1
- package/dist/hydrate/components-flex/button/types.d.ts +0 -3
- package/dist/hydrate/components-flex/button-outlined/types.d.ts +0 -3
- package/dist/hydrate/components-flex/button-text/types.d.ts +0 -3
- package/dist/hydrate/components-flex/form/types.d.ts +35 -20
- package/dist/hydrate/components-flex/form.d.ts +40 -3
- package/dist/hydrate/components-flex/icon/types.d.ts +0 -1
- package/dist/hydrate/components-flex/text/types.d.ts +0 -3
- package/dist/hydrate/components-flex/text-link/types.d.ts +0 -3
- package/dist/hydrate/components-flex/variants.d.ts +0 -15
- package/dist/hydrate/components-flex/youtube/types.d.ts +0 -1
- package/dist/hydrate/constants.d.ts +0 -1
- package/dist/hydrate/functions.d.ts +1 -1
- package/dist/hydrate/hooks/useInjectCustomizeCss.d.ts +1 -1
- package/dist/hydrate/hooks/useText.d.ts +1 -1
- package/dist/hydrate/index.d.ts +0 -2
- package/dist/hydrate/index.es.js +914 -573
- package/dist/hydrate/index.svelte5.d.ts +2 -1
- package/dist/hydrate/modal.d.ts +0 -2
- package/dist/hydrate/modal.svelte5.d.ts +0 -2
- package/dist/hydrate/prop.d.ts +4 -0
- package/dist/hydrate/types.d.ts +0 -1
- package/dist/icons.d.ts +0 -3
- package/dist/index.es.d.ts +0 -2
- package/dist/index.es.js +902 -511
- package/dist/modal.d.ts +0 -2
- package/dist/modal.svelte5.d.ts +0 -2
- package/dist/prop.d.ts +4 -0
- package/dist/svelte5/action.d.ts +0 -1
- package/dist/svelte5/actionEvent.d.ts +0 -1
- package/dist/svelte5/components/index.d.ts +0 -1
- package/dist/svelte5/components-flex/avatar/types.d.ts +0 -1
- package/dist/svelte5/components-flex/button/types.d.ts +0 -3
- package/dist/svelte5/components-flex/button-outlined/types.d.ts +0 -3
- package/dist/svelte5/components-flex/button-text/types.d.ts +0 -3
- package/dist/svelte5/components-flex/form/types.d.ts +35 -20
- package/dist/svelte5/components-flex/form.d.ts +40 -3
- package/dist/svelte5/components-flex/icon/types.d.ts +0 -1
- package/dist/svelte5/components-flex/text/types.d.ts +0 -3
- package/dist/svelte5/components-flex/text-link/types.d.ts +0 -3
- package/dist/svelte5/components-flex/variants.d.ts +0 -15
- package/dist/svelte5/components-flex/youtube/types.d.ts +0 -1
- package/dist/svelte5/constants.d.ts +0 -1
- package/dist/svelte5/functions.d.ts +1 -1
- package/dist/svelte5/hooks/useInjectCustomizeCss.d.ts +1 -1
- package/dist/svelte5/hooks/useText.d.ts +1 -1
- package/dist/svelte5/hydrate/action.d.ts +0 -1
- package/dist/svelte5/hydrate/actionEvent.d.ts +0 -1
- package/dist/svelte5/hydrate/components/index.d.ts +0 -1
- package/dist/svelte5/hydrate/components-flex/avatar/types.d.ts +0 -1
- package/dist/svelte5/hydrate/components-flex/button/types.d.ts +0 -3
- package/dist/svelte5/hydrate/components-flex/button-outlined/types.d.ts +0 -3
- package/dist/svelte5/hydrate/components-flex/button-text/types.d.ts +0 -3
- package/dist/svelte5/hydrate/components-flex/form/types.d.ts +35 -20
- package/dist/svelte5/hydrate/components-flex/form.d.ts +40 -3
- package/dist/svelte5/hydrate/components-flex/icon/types.d.ts +0 -1
- package/dist/svelte5/hydrate/components-flex/text/types.d.ts +0 -3
- package/dist/svelte5/hydrate/components-flex/text-link/types.d.ts +0 -3
- package/dist/svelte5/hydrate/components-flex/variants.d.ts +0 -15
- package/dist/svelte5/hydrate/components-flex/youtube/types.d.ts +0 -1
- package/dist/svelte5/hydrate/constants.d.ts +0 -1
- package/dist/svelte5/hydrate/functions.d.ts +1 -1
- package/dist/svelte5/hydrate/hooks/useInjectCustomizeCss.d.ts +1 -1
- package/dist/svelte5/hydrate/hooks/useText.d.ts +1 -1
- package/dist/svelte5/hydrate/index.es.d.ts +2 -1
- package/dist/svelte5/hydrate/index.es.js +606 -379
- package/dist/svelte5/hydrate/modal.d.ts +0 -2
- package/dist/svelte5/hydrate/modal.svelte5.d.ts +0 -2
- package/dist/svelte5/hydrate/prop.d.ts +4 -0
- package/dist/svelte5/hydrate/types.d.ts +0 -1
- package/dist/svelte5/index.es.d.ts +2 -1
- package/dist/svelte5/index.es.js +606 -379
- package/dist/svelte5/index.front2.es.js +648 -418
- package/dist/svelte5/index.svelte5.d.ts +2 -1
- package/dist/svelte5/modal.d.ts +0 -2
- package/dist/svelte5/modal.svelte5.d.ts +0 -2
- package/dist/svelte5/prop.d.ts +4 -0
- package/dist/svelte5/types.d.ts +0 -1
- package/dist/templates.cjs.js +4 -2
- package/dist/templates.d.ts +0 -2
- package/dist/templates.js +4 -2
- package/dist/types.d.ts +0 -1
- package/package.json +3 -3
@@ -371,6 +371,11 @@ const OnClickOperationOptions = [
|
|
371
371
|
name: "decode",
|
372
372
|
type: "BooleanKeyword",
|
373
373
|
default: false
|
374
|
+
},
|
375
|
+
{
|
376
|
+
name: "keep_native_action_viewed",
|
377
|
+
type: "BooleanKeyword",
|
378
|
+
default: false
|
374
379
|
}
|
375
380
|
]
|
376
381
|
},
|
@@ -2445,7 +2450,7 @@ function formDataToEventValues$1(campaignId, formData$1) {
|
|
2445
2450
|
...answersMap
|
2446
2451
|
} };
|
2447
2452
|
}
|
2448
|
-
function formDataToIdentifyEventValues(formData$1) {
|
2453
|
+
function formDataToIdentifyEventValues$1(formData$1) {
|
2449
2454
|
return Object.fromEntries(Object.entries(formData$1).map(([name, dataItem]) => {
|
2450
2455
|
const value = dataItem.value;
|
2451
2456
|
return [name, value];
|
@@ -2459,7 +2464,7 @@ function submit() {
|
|
2459
2464
|
const formData$1 = get(formData);
|
2460
2465
|
const identifyFormData$1 = get(identifyFormData);
|
2461
2466
|
const values = formDataToEventValues$1(campaignId, formData$1);
|
2462
|
-
const identifyValues = formDataToIdentifyEventValues(identifyFormData$1);
|
2467
|
+
const identifyValues = formDataToIdentifyEventValues$1(identifyFormData$1);
|
2463
2468
|
if (Object.keys(identifyValues).length > 0) identifyValues["user_id"] = getVariables()?.[USER_ID_VARIABLE_NAME];
|
2464
2469
|
return {
|
2465
2470
|
values,
|
@@ -2849,6 +2854,33 @@ const LAYOUT_COMPONENT_NAMES = [
|
|
2849
2854
|
|
2850
2855
|
//#endregion
|
2851
2856
|
//#region src/components-flex/form.ts
|
2857
|
+
const FORM_VALIDATION_TYPE = {
|
2858
|
+
required: "必須",
|
2859
|
+
email: "メールアドレス",
|
2860
|
+
tel: "電話番号",
|
2861
|
+
url: "URL",
|
2862
|
+
minLength: "最小文字数",
|
2863
|
+
maxLength: "最大文字数",
|
2864
|
+
minCount: "最小個数",
|
2865
|
+
maxCount: "最大個数",
|
2866
|
+
pattern: "正規表現"
|
2867
|
+
};
|
2868
|
+
const FORM_VALIDATION_DEFAULT_ERROR_MESSAGES = {
|
2869
|
+
required: `入力してください`,
|
2870
|
+
minLength: `{minLength}文字以上で入力してください`,
|
2871
|
+
maxLength: `{maxLength}文字以下で入力してください`,
|
2872
|
+
minCount: `{minCount}個以上選択してください`,
|
2873
|
+
maxCount: `{maxCount}個以下で選択してください`,
|
2874
|
+
pattern: `正しい形式で入力してください`,
|
2875
|
+
email: `正しいメールアドレスを入力してください`,
|
2876
|
+
tel: `正しい電話番号を入力してください`,
|
2877
|
+
url: `正しいURLを入力してください`
|
2878
|
+
};
|
2879
|
+
const FORM_VALIDATION_REGEX = {
|
2880
|
+
email: "^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9-]*\\.?[a-zA-Z0-9-]+\\.[a-zA-Z]{2,}$",
|
2881
|
+
tel: "^0\\d{1,4}[-]?\\d{1,4}[-]?\\d{4}$",
|
2882
|
+
url: "^http(s)?://.+$"
|
2883
|
+
};
|
2852
2884
|
/**
|
2853
2885
|
* @internal
|
2854
2886
|
*/
|
@@ -2857,6 +2889,7 @@ const formStore = writable({
|
|
2857
2889
|
states: {}
|
2858
2890
|
});
|
2859
2891
|
const formSubmittedValues = writable({});
|
2892
|
+
const formSubmittedIdentifyValues = writable({});
|
2860
2893
|
/**
|
2861
2894
|
* @public
|
2862
2895
|
*/
|
@@ -2875,7 +2908,6 @@ const getFormFieldState = (name) => {
|
|
2875
2908
|
* @public
|
2876
2909
|
*/
|
2877
2910
|
const getFormFieldValue = (name) => {
|
2878
|
-
console.log("getFormFieldValue", getFormFieldState(name)?.value ?? void 0);
|
2879
2911
|
return getFormFieldState(name)?.value ?? void 0;
|
2880
2912
|
};
|
2881
2913
|
/**
|
@@ -2963,14 +2995,18 @@ const registerFormField = (schemas) => {
|
|
2963
2995
|
defaultValue: schema.defaultValue,
|
2964
2996
|
type: schema.type,
|
2965
2997
|
required: schema.required,
|
2966
|
-
statePath: getState()
|
2998
|
+
statePath: getState(),
|
2999
|
+
isIdentify: schema.isIdentify,
|
3000
|
+
validations: schema.validations
|
2967
3001
|
};
|
2968
3002
|
else resultSchemes.push({
|
2969
3003
|
name: schema.name,
|
2970
3004
|
defaultValue: schema.defaultValue,
|
2971
3005
|
type: schema.type,
|
2972
3006
|
required: schema.required,
|
2973
|
-
statePath: getState()
|
3007
|
+
statePath: getState(),
|
3008
|
+
isIdentify: schema.isIdentify,
|
3009
|
+
validations: schema.validations
|
2974
3010
|
});
|
2975
3011
|
});
|
2976
3012
|
return resultSchemes;
|
@@ -2978,21 +3014,23 @@ const registerFormField = (schemas) => {
|
|
2978
3014
|
states: (() => {
|
2979
3015
|
const states$1 = { ...updater.states };
|
2980
3016
|
const submittedValues = get(formSubmittedValues);
|
2981
|
-
|
2982
|
-
|
2983
|
-
|
2984
|
-
|
2985
|
-
|
2986
|
-
|
2987
|
-
|
2988
|
-
|
2989
|
-
|
2990
|
-
|
2991
|
-
}
|
2992
|
-
|
2993
|
-
|
2994
|
-
|
2995
|
-
|
3017
|
+
const submittedIdentifyValues = get(formSubmittedIdentifyValues);
|
3018
|
+
schemas.forEach((schema) => {
|
3019
|
+
if (!(schema.name in states$1) && schema.name) states$1[schema.name] = {
|
3020
|
+
isDirty: false,
|
3021
|
+
isValid: false,
|
3022
|
+
isTouched: false,
|
3023
|
+
type: schema.type,
|
3024
|
+
value: (() => {
|
3025
|
+
if (schema.isIdentify) {
|
3026
|
+
if (submittedIdentifyValues[schema.name]) return submittedIdentifyValues[schema.name].value;
|
3027
|
+
} else if (submittedValues[schema.name]) return submittedValues[schema.name].value;
|
3028
|
+
if (schema.type === "checkboxes") return Array.isArray(schema.defaultValue) ? schema.defaultValue : [];
|
3029
|
+
else if (schema.type === "boolean") return schema.defaultValue ?? void 0;
|
3030
|
+
else return typeof schema.defaultValue === "string" ? schema.defaultValue : "";
|
3031
|
+
})(),
|
3032
|
+
errorMessage: null
|
3033
|
+
};
|
2996
3034
|
});
|
2997
3035
|
return states$1;
|
2998
3036
|
})()
|
@@ -3017,31 +3055,81 @@ const unregisterFormField = (fieldNames) => {
|
|
3017
3055
|
}));
|
3018
3056
|
};
|
3019
3057
|
const validateFormField = (schema, value) => {
|
3020
|
-
const store = get(formStore);
|
3021
3058
|
if (schema.required) {
|
3022
3059
|
if (schema.type === "checkboxes") {
|
3023
|
-
if (value.length === 0) return {
|
3060
|
+
if (Array.isArray(value) && value.length === 0) return {
|
3024
3061
|
isValid: false,
|
3025
|
-
error: "
|
3062
|
+
error: FORM_VALIDATION_DEFAULT_ERROR_MESSAGES["required"]
|
3026
3063
|
};
|
3027
3064
|
} else if (typeof value !== "string" || value.trim() === "") return {
|
3028
3065
|
isValid: false,
|
3029
|
-
error: "
|
3066
|
+
error: FORM_VALIDATION_DEFAULT_ERROR_MESSAGES["required"]
|
3030
3067
|
};
|
3031
3068
|
}
|
3069
|
+
if (schema.validations && schema.validations.length > 0) for (const validation of schema.validations) {
|
3070
|
+
const { type, number, errorMessage, regexp } = validation;
|
3071
|
+
if (type === "minLength" && !!number) {
|
3072
|
+
if (typeof value === "string" && value.length < number) return {
|
3073
|
+
isValid: false,
|
3074
|
+
error: (errorMessage || FORM_VALIDATION_DEFAULT_ERROR_MESSAGES[type]).replace("{minLength}", number.toString())
|
3075
|
+
};
|
3076
|
+
}
|
3077
|
+
if (type === "maxLength" && !!number) {
|
3078
|
+
if (typeof value === "string" && value.length > number) return {
|
3079
|
+
isValid: false,
|
3080
|
+
error: (errorMessage || FORM_VALIDATION_DEFAULT_ERROR_MESSAGES[type]).replace("{maxLength}", number.toString())
|
3081
|
+
};
|
3082
|
+
}
|
3083
|
+
if (type === "minCount" && !!number) {
|
3084
|
+
if (Array.isArray(value) && value.length < number) return {
|
3085
|
+
isValid: false,
|
3086
|
+
error: (errorMessage || FORM_VALIDATION_DEFAULT_ERROR_MESSAGES[type]).replace("{minCount}", number.toString())
|
3087
|
+
};
|
3088
|
+
}
|
3089
|
+
if (type === "maxCount" && !!number) {
|
3090
|
+
if (Array.isArray(value) && value.length > number) return {
|
3091
|
+
isValid: false,
|
3092
|
+
error: (errorMessage || FORM_VALIDATION_DEFAULT_ERROR_MESSAGES[type]).replace("{maxCount}", number.toString())
|
3093
|
+
};
|
3094
|
+
}
|
3095
|
+
if (type === "pattern" && !!regexp) {
|
3096
|
+
if (typeof value === "string" && new RegExp(regexp).test(value) === false) return {
|
3097
|
+
isValid: false,
|
3098
|
+
error: errorMessage || FORM_VALIDATION_DEFAULT_ERROR_MESSAGES[type]
|
3099
|
+
};
|
3100
|
+
}
|
3101
|
+
if (type === "email") {
|
3102
|
+
if (typeof value === "string" && new RegExp(regexp || FORM_VALIDATION_REGEX.email).test(value) === false) return {
|
3103
|
+
isValid: false,
|
3104
|
+
error: errorMessage || FORM_VALIDATION_DEFAULT_ERROR_MESSAGES[type]
|
3105
|
+
};
|
3106
|
+
}
|
3107
|
+
if (type === "tel") {
|
3108
|
+
if (typeof value === "string" && new RegExp(regexp || FORM_VALIDATION_REGEX.tel).test(value) === false) return {
|
3109
|
+
isValid: false,
|
3110
|
+
error: errorMessage || FORM_VALIDATION_DEFAULT_ERROR_MESSAGES[type]
|
3111
|
+
};
|
3112
|
+
}
|
3113
|
+
if (type === "url") {
|
3114
|
+
if (typeof value === "string" && new RegExp(regexp || FORM_VALIDATION_REGEX.url).test(value) === false) return {
|
3115
|
+
isValid: false,
|
3116
|
+
error: errorMessage || FORM_VALIDATION_DEFAULT_ERROR_MESSAGES[type]
|
3117
|
+
};
|
3118
|
+
}
|
3119
|
+
}
|
3032
3120
|
return {
|
3033
3121
|
isValid: true,
|
3034
3122
|
error: void 0
|
3035
3123
|
};
|
3036
3124
|
};
|
3037
3125
|
function createAnswerValue(value) {
|
3038
|
-
if (
|
3039
|
-
else
|
3126
|
+
if (value.type === "input" || value.type === "textarea") return { free_answer: String(value.value) };
|
3127
|
+
else return { choices: Array.isArray(value) ? value : [value] };
|
3040
3128
|
}
|
3041
|
-
function formDataToEventValues(campaignId,
|
3129
|
+
function formDataToEventValues(campaignId, values) {
|
3042
3130
|
const questions = [];
|
3043
3131
|
const answersMap = {};
|
3044
|
-
Object.entries(
|
3132
|
+
Object.entries(values).forEach(([name, value]) => {
|
3045
3133
|
questions.push(name);
|
3046
3134
|
const answerKey = `question_${name}`;
|
3047
3135
|
answersMap[answerKey] = createAnswerValue(value);
|
@@ -3051,6 +3139,9 @@ function formDataToEventValues(campaignId, formData$1) {
|
|
3051
3139
|
...answersMap
|
3052
3140
|
} };
|
3053
3141
|
}
|
3142
|
+
function formDataToIdentifyEventValues(values) {
|
3143
|
+
return Object.fromEntries(Object.entries(values).map(([name, { value }]) => [name, value]));
|
3144
|
+
}
|
3054
3145
|
/**
|
3055
3146
|
* @public
|
3056
3147
|
*/
|
@@ -3078,13 +3169,30 @@ function onSubmitForm(fn) {
|
|
3078
3169
|
})()
|
3079
3170
|
}));
|
3080
3171
|
if (hasInvalid) return;
|
3081
|
-
const
|
3172
|
+
const newValues = {};
|
3173
|
+
const newIdentifyValues = {};
|
3174
|
+
currentStateSchemas.forEach((schema) => {
|
3175
|
+
if (schema.isIdentify) newIdentifyValues[schema.name] = {
|
3176
|
+
value: formData$1.states[schema.name]?.value,
|
3177
|
+
type: schema.type
|
3178
|
+
};
|
3179
|
+
else newValues[schema.name] = {
|
3180
|
+
value: formData$1.states[schema.name]?.value,
|
3181
|
+
type: schema.type
|
3182
|
+
};
|
3183
|
+
});
|
3082
3184
|
formSubmittedValues.update((updater) => ({
|
3083
3185
|
...updater,
|
3084
|
-
...
|
3186
|
+
...newValues
|
3187
|
+
}));
|
3188
|
+
if (Object.keys(newIdentifyValues).length > 0) formSubmittedIdentifyValues.update((updater) => ({
|
3189
|
+
...updater,
|
3190
|
+
...newIdentifyValues
|
3085
3191
|
}));
|
3086
3192
|
fn({
|
3087
|
-
|
3193
|
+
currentStateIdentifyValues: formDataToIdentifyEventValues(newIdentifyValues),
|
3194
|
+
allIdentifyValues: formDataToIdentifyEventValues(get(formSubmittedIdentifyValues)),
|
3195
|
+
currentStateValues: formDataToEventValues(campaignId, newValues),
|
3088
3196
|
allValues: formDataToEventValues(campaignId, get(formSubmittedValues))
|
3089
3197
|
});
|
3090
3198
|
}
|
@@ -3110,16 +3218,14 @@ function Header($$anchor, $$props) {
|
|
3110
3218
|
$.head(($$anchor$1) => {
|
3111
3219
|
var fragment = $.comment();
|
3112
3220
|
var node = $.first_child(fragment);
|
3113
|
-
{
|
3114
|
-
var
|
3115
|
-
|
3116
|
-
|
3117
|
-
|
3118
|
-
|
3119
|
-
|
3120
|
-
|
3121
|
-
});
|
3122
|
-
}
|
3221
|
+
var consequent = ($$anchor$2) => {
|
3222
|
+
var link = root_2$9();
|
3223
|
+
$.template_effect(() => $.set_attribute(link, "href", $.get(googleFontUrl)));
|
3224
|
+
$.append($$anchor$2, link);
|
3225
|
+
};
|
3226
|
+
$.if(node, ($$render) => {
|
3227
|
+
if ($.get(googleFontUrl)) $$render(consequent);
|
3228
|
+
});
|
3123
3229
|
$.append($$anchor$1, fragment);
|
3124
3230
|
});
|
3125
3231
|
$.pop();
|
@@ -3191,13 +3297,13 @@ function State($$anchor, $$props) {
|
|
3191
3297
|
//#region src/components-flex/state/StateItem.svelte
|
3192
3298
|
const STATE_ITEM_CONTEXT_KEY = Symbol();
|
3193
3299
|
var root_1$15 = $.template(`<div class="state-item svelte-2qb6dm"></div> <!>`, 1);
|
3194
|
-
const $$css$
|
3300
|
+
const $$css$33 = {
|
3195
3301
|
hash: "svelte-2qb6dm",
|
3196
3302
|
code: ".state-item.svelte-2qb6dm {position:absolute;display:none;}"
|
3197
3303
|
};
|
3198
3304
|
function StateItem($$anchor, $$props) {
|
3199
3305
|
$.push($$props, false);
|
3200
|
-
$.append_styles($$anchor, $$css$
|
3306
|
+
$.append_styles($$anchor, $$css$33);
|
3201
3307
|
const [$$stores, $$cleanup] = $.setup_stores();
|
3202
3308
|
const $state = () => $.store_get(state, "$state", $$stores);
|
3203
3309
|
let path = $.prop($$props, "path", 8);
|
@@ -3209,19 +3315,17 @@ function StateItem($$anchor, $$props) {
|
|
3209
3315
|
$.init();
|
3210
3316
|
var fragment = $.comment();
|
3211
3317
|
var node = $.first_child(fragment);
|
3212
|
-
{
|
3213
|
-
var
|
3214
|
-
|
3215
|
-
|
3216
|
-
|
3217
|
-
|
3218
|
-
|
3219
|
-
|
3220
|
-
|
3221
|
-
|
3222
|
-
|
3223
|
-
});
|
3224
|
-
}
|
3318
|
+
var consequent = ($$anchor$1) => {
|
3319
|
+
var fragment_1 = root_1$15();
|
3320
|
+
var div = $.first_child(fragment_1);
|
3321
|
+
var node_1 = $.sibling(div, 2);
|
3322
|
+
$.slot(node_1, $$props, "default", {}, null);
|
3323
|
+
$.template_effect(() => $.set_attribute(div, "data-state-path", path()));
|
3324
|
+
$.append($$anchor$1, fragment_1);
|
3325
|
+
};
|
3326
|
+
$.if(node, ($$render) => {
|
3327
|
+
if ($state() === path()) $$render(consequent);
|
3328
|
+
});
|
3225
3329
|
$.append($$anchor, fragment);
|
3226
3330
|
$.pop();
|
3227
3331
|
$$cleanup();
|
@@ -3533,7 +3637,7 @@ const moveTo = (to) => () => {
|
|
3533
3637
|
_moveTo(to);
|
3534
3638
|
};
|
3535
3639
|
/** @internal */
|
3536
|
-
const linkTo = (to, targetBlank = true, decode = false) => () => {
|
3640
|
+
const linkTo = (to, targetBlank = true, decode = false, keepNativeActionViewed = false) => () => {
|
3537
3641
|
const decodedTo = decode ? decodeURI(to) : to;
|
3538
3642
|
const { target } = getActionRunnerContext() ?? {};
|
3539
3643
|
async function sleep(ms) {
|
@@ -3546,10 +3650,23 @@ const linkTo = (to, targetBlank = true, decode = false) => () => {
|
|
3546
3650
|
});
|
3547
3651
|
await sleep(450);
|
3548
3652
|
}
|
3549
|
-
|
3550
|
-
if (
|
3653
|
+
let doTransitionByLocation = true;
|
3654
|
+
if (target === "native" && targetBlank && keepNativeActionViewed) {
|
3655
|
+
const win = window;
|
3656
|
+
const nativeMessageName = "open_url";
|
3657
|
+
const nativeMessageData = {
|
3658
|
+
url: decodedTo,
|
3659
|
+
target: "_blank"
|
3660
|
+
};
|
3661
|
+
win.NativeBridge?.onReceivedMessage(nativeMessageName, JSON.stringify(nativeMessageData));
|
3662
|
+
win.webkit?.messageHandlers[nativeMessageName]?.postMessage(nativeMessageData);
|
3663
|
+
doTransitionByLocation = false;
|
3664
|
+
} else if (target === "web" && targetBlank) {
|
3665
|
+
window.open(decodedTo, "_blank");
|
3666
|
+
doTransitionByLocation = false;
|
3667
|
+
}
|
3551
3668
|
Promise.race([_send(), sleep(650)]).then(() => {
|
3552
|
-
if (
|
3669
|
+
if (doTransitionByLocation) location.href = decodedTo;
|
3553
3670
|
});
|
3554
3671
|
};
|
3555
3672
|
/** @internal */
|
@@ -3576,18 +3693,24 @@ const submitForm = (to) => () => {
|
|
3576
3693
|
};
|
3577
3694
|
/** @internal */
|
3578
3695
|
const submitFormProgress = (to) => () => {
|
3579
|
-
onSubmitForm(({ currentStateValues }) => {
|
3696
|
+
onSubmitForm(({ currentStateValues, currentStateIdentifyValues }) => {
|
3580
3697
|
send_event("_answer_question_progress", {
|
3581
3698
|
...currentStateValues,
|
3582
3699
|
state: getState()
|
3583
3700
|
});
|
3701
|
+
if (Object.keys(currentStateIdentifyValues).length > 0) send_event("identify", currentStateIdentifyValues);
|
3702
|
+
console.log("currentStateValues", currentStateValues);
|
3703
|
+
console.log("currentStateIdentifyValues", currentStateIdentifyValues);
|
3584
3704
|
_moveTo(to);
|
3585
3705
|
});
|
3586
3706
|
};
|
3587
3707
|
/** @internal */
|
3588
3708
|
const submitFormFinal = (to) => () => {
|
3589
|
-
onSubmitForm(({ allValues }) => {
|
3709
|
+
onSubmitForm(({ allValues, allIdentifyValues }) => {
|
3590
3710
|
send_event("_answer_question", allValues);
|
3711
|
+
if (Object.keys(allIdentifyValues).length > 0) send_event("identify", allIdentifyValues);
|
3712
|
+
console.log("allValues", allValues);
|
3713
|
+
console.log("allIdentifyValues", allIdentifyValues);
|
3591
3714
|
_moveTo(to);
|
3592
3715
|
});
|
3593
3716
|
};
|
@@ -3750,32 +3873,30 @@ var useClickable_default = useClickable;
|
|
3750
3873
|
|
3751
3874
|
//#endregion
|
3752
3875
|
//#region src/hooks/useInjectCustomizeCss.ts
|
3753
|
-
const
|
3876
|
+
const DATA_ATTR_LAYER_ID_KEY = "data-customize-css-layer-id";
|
3877
|
+
const useInjectCustomizeCss = (props, layerId) => {
|
3754
3878
|
function injectCss() {
|
3755
|
-
const modalElements = Array.from(document.querySelectorAll(`.${KARTE_MODAL_ROOT}`));
|
3756
|
-
const style = document.createElement("style");
|
3757
3879
|
let headAppended = false;
|
3880
|
+
const roots = Array.from(document.querySelectorAll(`.${KARTE_ACTION_ROOT}[data-${KARTE_ACTION_RID}='${actionId}']`));
|
3881
|
+
const style = document.createElement("style");
|
3882
|
+
style.setAttribute(DATA_ATTR_LAYER_ID_KEY, layerId);
|
3758
3883
|
style.textContent = props.customizeCss;
|
3759
|
-
|
3760
|
-
if (
|
3761
|
-
|
3884
|
+
roots.forEach((root$49) => {
|
3885
|
+
if (root$49 && root$49.shadowRoot) {
|
3886
|
+
const existingStyles = Array.from(root$49.shadowRoot.querySelectorAll(`style[${DATA_ATTR_LAYER_ID_KEY}='${layerId}']`));
|
3887
|
+
existingStyles.forEach((style$1) => {
|
3888
|
+
style$1.parentNode?.removeChild(style$1);
|
3889
|
+
});
|
3890
|
+
root$49.shadowRoot.appendChild(style);
|
3891
|
+
} else if (!headAppended) {
|
3762
3892
|
document.head.appendChild(style);
|
3763
3893
|
headAppended = true;
|
3764
3894
|
}
|
3765
3895
|
});
|
3766
|
-
return () => {
|
3767
|
-
modalElements.forEach((modalElement) => {
|
3768
|
-
if (modalElement?.shadowRoot) modalElement.shadowRoot.removeChild(style);
|
3769
|
-
else document.head.removeChild(style);
|
3770
|
-
});
|
3771
|
-
};
|
3772
3896
|
}
|
3773
3897
|
onMount(() => {
|
3774
3898
|
if (!props.isCustomizeCss) return;
|
3775
|
-
|
3776
|
-
return () => {
|
3777
|
-
removeCss();
|
3778
|
-
};
|
3899
|
+
injectCss();
|
3779
3900
|
});
|
3780
3901
|
};
|
3781
3902
|
|
@@ -3807,19 +3928,19 @@ const AVATAR_SIZE_STYLES = {
|
|
3807
3928
|
//#endregion
|
3808
3929
|
//#region src/components-flex/avatar/Avatar.svelte
|
3809
3930
|
var root_1$14 = $.template(`<img class="avatar-image svelte-1xhdr99">`);
|
3810
|
-
const $$css$
|
3931
|
+
const $$css$32 = {
|
3811
3932
|
hash: "svelte-1xhdr99",
|
3812
3933
|
code: ".avatar.svelte-1xhdr99 {display:flex;align-items:center;justify-content:center;overflow:hidden;flex-shrink:0;border:0;background:none;padding:0;margin:0;text-align:left;-webkit-appearance:none;}"
|
3813
3934
|
};
|
3814
3935
|
function Avatar($$anchor, $$props) {
|
3815
3936
|
$.push($$props, false);
|
3816
|
-
$.append_styles($$anchor, $$css$
|
3937
|
+
$.append_styles($$anchor, $$css$32);
|
3817
3938
|
const styleObj = $.mutable_state();
|
3818
3939
|
const style = $.mutable_state();
|
3819
3940
|
const imgStyle = $.mutable_state();
|
3820
3941
|
let props = $.prop($$props, "props", 24, () => ({}));
|
3821
3942
|
let layerId = $.prop($$props, "layerId", 8, "");
|
3822
|
-
useInjectCustomizeCss(props());
|
3943
|
+
useInjectCustomizeCss(props(), layerId());
|
3823
3944
|
const { attributes, element, handleClick } = useClickable_default(props());
|
3824
3945
|
const avatarSizeStyle = !isNaN(Number(props().size)) ? {
|
3825
3946
|
width: `${props().size}px`,
|
@@ -4376,18 +4497,18 @@ const ICON_VARIANTS = {
|
|
4376
4497
|
|
4377
4498
|
//#endregion
|
4378
4499
|
//#region src/components-flex/icon/Icon.svelte
|
4379
|
-
const $$css$
|
4500
|
+
const $$css$31 = {
|
4380
4501
|
hash: "svelte-1kl9m59",
|
4381
4502
|
code: ".icon.svelte-1kl9m59 {display:flex;align-items:center;overflow:hidden;width:auto;cursor:pointer;text-decoration:none;border:0;background:none;padding:0;margin:0;text-align:left;-webkit-appearance:none;}"
|
4382
4503
|
};
|
4383
4504
|
function Icon($$anchor, $$props) {
|
4384
4505
|
$.push($$props, false);
|
4385
|
-
$.append_styles($$anchor, $$css$
|
4506
|
+
$.append_styles($$anchor, $$css$31);
|
4386
4507
|
const style = $.mutable_state();
|
4387
4508
|
const IconComponent = $.mutable_state();
|
4388
4509
|
let props = $.prop($$props, "props", 24, () => ({}));
|
4389
4510
|
let layerId = $.prop($$props, "layerId", 8, "");
|
4390
|
-
useInjectCustomizeCss(props());
|
4511
|
+
useInjectCustomizeCss(props(), layerId());
|
4391
4512
|
const { attributes, element, handleClick } = useClickable_default(props());
|
4392
4513
|
const getSizeCss = () => {
|
4393
4514
|
return {
|
@@ -4604,18 +4725,18 @@ function darkenColor(color, percent) {
|
|
4604
4725
|
//#region src/components-flex/button/Button.svelte
|
4605
4726
|
var root_2$8 = $.template(`<div class="button-icon svelte-l0rauj"><!></div>`);
|
4606
4727
|
var root_1$13 = $.template(`<!> <span class="button-label"> </span>`, 1);
|
4607
|
-
const $$css$
|
4728
|
+
const $$css$30 = {
|
4608
4729
|
hash: "svelte-l0rauj",
|
4609
4730
|
code: ".button.svelte-l0rauj {display:inline-flex;gap:0.8em;align-items:center;justify-content:center;text-decoration:none;outline:0;border-width:1px;border-style:solid;line-height:1.5;transition:background-color 0.12s,\n border-color 0.12s,\n color 0.12s;cursor:pointer;color:var(--color);border-color:var(--border-color);background-color:var(--bg-color);}.button.svelte-l0rauj:hover {background-color:var(--hover-bg-color);border-color:var(--hover-border-color);}.button-icon.svelte-l0rauj {display:flex;align-items:center;justify-content:center;margin-left:-0.2em;margin-right:-0.2em;}"
|
4610
4731
|
};
|
4611
4732
|
function Button($$anchor, $$props) {
|
4612
4733
|
$.push($$props, false);
|
4613
|
-
$.append_styles($$anchor, $$css$
|
4734
|
+
$.append_styles($$anchor, $$css$30);
|
4614
4735
|
const variables$1 = $.mutable_state();
|
4615
4736
|
const style = $.mutable_state();
|
4616
4737
|
let props = $.prop($$props, "props", 24, () => ({}));
|
4617
4738
|
let layerId = $.prop($$props, "layerId", 8, "");
|
4618
|
-
useInjectCustomizeCss(props());
|
4739
|
+
useInjectCustomizeCss(props(), layerId());
|
4619
4740
|
const { attributes, element, handleClick } = useClickable_default(props());
|
4620
4741
|
const { brandKit } = useBrandKit();
|
4621
4742
|
const buttonThemeStyles = getButtonThemeStyles(brandKit);
|
@@ -4695,26 +4816,24 @@ function Button($$anchor, $$props) {
|
|
4695
4816
|
$.event("click", $$element, handleClick);
|
4696
4817
|
var fragment_1 = root_1$13();
|
4697
4818
|
var node_1 = $.first_child(fragment_1);
|
4698
|
-
{
|
4699
|
-
var
|
4700
|
-
|
4701
|
-
|
4702
|
-
|
4703
|
-
|
4704
|
-
|
4705
|
-
|
4706
|
-
|
4707
|
-
|
4708
|
-
|
4709
|
-
|
4710
|
-
|
4711
|
-
|
4712
|
-
|
4713
|
-
|
4714
|
-
|
4715
|
-
|
4716
|
-
});
|
4717
|
-
}
|
4819
|
+
var consequent = ($$anchor$2) => {
|
4820
|
+
var div = root_2$8();
|
4821
|
+
var node_2 = $.child(div);
|
4822
|
+
const expression = $.derived_safe_equal(() => ({
|
4823
|
+
variant: props().iconVariant,
|
4824
|
+
color: props().iconColor ?? props().color ?? buttonThemeStyle.color,
|
4825
|
+
width: "1em",
|
4826
|
+
height: "1em"
|
4827
|
+
}));
|
4828
|
+
Icon(node_2, { get props() {
|
4829
|
+
return $.get(expression);
|
4830
|
+
} });
|
4831
|
+
$.reset(div);
|
4832
|
+
$.append($$anchor$2, div);
|
4833
|
+
};
|
4834
|
+
$.if(node_1, ($$render) => {
|
4835
|
+
if (props().isIcon && props().iconVariant) $$render(consequent);
|
4836
|
+
});
|
4718
4837
|
var span = $.sibling(node_1, 2);
|
4719
4838
|
var text = $.child(span, true);
|
4720
4839
|
$.reset(span);
|
@@ -4822,18 +4941,18 @@ const BUTTON_OUTLINED_WRAP_STYLES = {
|
|
4822
4941
|
//#region src/components-flex/button-outlined/ButtonOutlined.svelte
|
4823
4942
|
var root_2$7 = $.template(`<div class="button-outlined-icon svelte-z8gomx"><!></div>`);
|
4824
4943
|
var root_1$12 = $.template(`<!> <span class="button-outlined-label svelte-z8gomx"> </span>`, 1);
|
4825
|
-
const $$css$
|
4944
|
+
const $$css$29 = {
|
4826
4945
|
hash: "svelte-z8gomx",
|
4827
4946
|
code: ".button-outlined.svelte-z8gomx {display:inline-flex;gap:0.65em;align-items:center;justify-content:center;text-decoration:none;outline:0;border-width:1px;border-style:solid;line-height:1.5;transition:background-color 0.12s,\n border-color 0.12s,\n color 0.12s;cursor:pointer;background-color:var(--bg-color);}.button-outlined.svelte-z8gomx:hover {background-color:var(--hover-bg-color);}.button-outlined-icon.svelte-z8gomx {display:flex;align-items:center;justify-content:center;margin-left:-0.2em;margin-right:-0.2em;margin-bottom:0.1em;}"
|
4828
4947
|
};
|
4829
4948
|
function ButtonOutlined($$anchor, $$props) {
|
4830
4949
|
$.push($$props, false);
|
4831
|
-
$.append_styles($$anchor, $$css$
|
4950
|
+
$.append_styles($$anchor, $$css$29);
|
4832
4951
|
const variables$1 = $.mutable_state();
|
4833
4952
|
const style = $.mutable_state();
|
4834
4953
|
let props = $.prop($$props, "props", 24, () => ({}));
|
4835
4954
|
let layerId = $.prop($$props, "layerId", 8, "");
|
4836
|
-
useInjectCustomizeCss(props());
|
4955
|
+
useInjectCustomizeCss(props(), layerId());
|
4837
4956
|
const { brandKit } = useBrandKit();
|
4838
4957
|
const { attributes, element, handleClick } = useClickable_default(props());
|
4839
4958
|
const buttonThemeStyles = getButtonOutlinedThemeStyles(brandKit);
|
@@ -4879,26 +4998,24 @@ function ButtonOutlined($$anchor, $$props) {
|
|
4879
4998
|
$.event("click", $$element, handleClick);
|
4880
4999
|
var fragment_1 = root_1$12();
|
4881
5000
|
var node_1 = $.first_child(fragment_1);
|
4882
|
-
{
|
4883
|
-
var
|
4884
|
-
|
4885
|
-
|
4886
|
-
|
4887
|
-
|
4888
|
-
|
4889
|
-
|
4890
|
-
|
4891
|
-
|
4892
|
-
|
4893
|
-
|
4894
|
-
|
4895
|
-
|
4896
|
-
|
4897
|
-
|
4898
|
-
|
4899
|
-
|
4900
|
-
});
|
4901
|
-
}
|
5001
|
+
var consequent = ($$anchor$2) => {
|
5002
|
+
var div = root_2$7();
|
5003
|
+
var node_2 = $.child(div);
|
5004
|
+
const expression = $.derived_safe_equal(() => ({
|
5005
|
+
variant: props().iconVariant,
|
5006
|
+
color: props().iconColor ?? props().color ?? buttonThemeStyle.color,
|
5007
|
+
width: "1em",
|
5008
|
+
height: "1em"
|
5009
|
+
}));
|
5010
|
+
Icon(node_2, { get props() {
|
5011
|
+
return $.get(expression);
|
5012
|
+
} });
|
5013
|
+
$.reset(div);
|
5014
|
+
$.append($$anchor$2, div);
|
5015
|
+
};
|
5016
|
+
$.if(node_1, ($$render) => {
|
5017
|
+
if (props().isIcon && props().iconVariant) $$render(consequent);
|
5018
|
+
});
|
4902
5019
|
var span = $.sibling(node_1, 2);
|
4903
5020
|
var text = $.child(span, true);
|
4904
5021
|
$.reset(span);
|
@@ -4971,18 +5088,18 @@ const getButtonTextThemeStyles = getPropStyles(callback$2);
|
|
4971
5088
|
//#region src/components-flex/button-text/ButtonText.svelte
|
4972
5089
|
var root_2$6 = $.template(`<div class="button-text-icon svelte-l90o4j"><!></div>`);
|
4973
5090
|
var root_1$11 = $.template(`<!> <span class="button-text-label svelte-l90o4j"> </span>`, 1);
|
4974
|
-
const $$css$
|
5091
|
+
const $$css$28 = {
|
4975
5092
|
hash: "svelte-l90o4j",
|
4976
5093
|
code: ".button-text.svelte-l90o4j {display:inline-flex;gap:0.65em;align-items:center;justify-content:center;text-decoration:none;outline:0;border:0;line-height:1.5;transition:background-color 0.12s,\n border-color 0.12s,\n color 0.12s;cursor:pointer;background-color:rgba(255, 255, 255, 0);}.button-text.svelte-l90o4j:hover {background-color:var(--hover-bg-color);}.button-text-icon.svelte-l90o4j {display:flex;align-items:center;justify-content:center;margin-left:-0.2em;margin-right:-0.2em;}"
|
4977
5094
|
};
|
4978
5095
|
function ButtonText($$anchor, $$props) {
|
4979
5096
|
$.push($$props, false);
|
4980
|
-
$.append_styles($$anchor, $$css$
|
5097
|
+
$.append_styles($$anchor, $$css$28);
|
4981
5098
|
const variables$1 = $.mutable_state();
|
4982
5099
|
const style = $.mutable_state();
|
4983
5100
|
let props = $.prop($$props, "props", 24, () => ({}));
|
4984
5101
|
let layerId = $.prop($$props, "layerId", 8, "");
|
4985
|
-
useInjectCustomizeCss(props());
|
5102
|
+
useInjectCustomizeCss(props(), layerId());
|
4986
5103
|
const { brandKit } = useBrandKit();
|
4987
5104
|
const { attributes, element, handleClick } = useClickable_default(props());
|
4988
5105
|
const themeStyles = getButtonTextThemeStyles(brandKit);
|
@@ -5022,26 +5139,24 @@ function ButtonText($$anchor, $$props) {
|
|
5022
5139
|
$.event("click", $$element, handleClick);
|
5023
5140
|
var fragment_1 = root_1$11();
|
5024
5141
|
var node_1 = $.first_child(fragment_1);
|
5025
|
-
{
|
5026
|
-
var
|
5027
|
-
|
5028
|
-
|
5029
|
-
|
5030
|
-
|
5031
|
-
|
5032
|
-
|
5033
|
-
|
5034
|
-
|
5035
|
-
|
5036
|
-
|
5037
|
-
|
5038
|
-
|
5039
|
-
|
5040
|
-
|
5041
|
-
|
5042
|
-
|
5043
|
-
});
|
5044
|
-
}
|
5142
|
+
var consequent = ($$anchor$2) => {
|
5143
|
+
var div = root_2$6();
|
5144
|
+
var node_2 = $.child(div);
|
5145
|
+
const expression = $.derived_safe_equal(() => ({
|
5146
|
+
variant: props().iconVariant,
|
5147
|
+
color: props().color ?? buttonThemeStyle.color,
|
5148
|
+
width: "1em",
|
5149
|
+
height: "1em"
|
5150
|
+
}));
|
5151
|
+
Icon(node_2, { get props() {
|
5152
|
+
return $.get(expression);
|
5153
|
+
} });
|
5154
|
+
$.reset(div);
|
5155
|
+
$.append($$anchor$2, div);
|
5156
|
+
};
|
5157
|
+
$.if(node_1, ($$render) => {
|
5158
|
+
if (props().isIcon && props().iconVariant) $$render(consequent);
|
5159
|
+
});
|
5045
5160
|
var span = $.sibling(node_1, 2);
|
5046
5161
|
var text = $.child(span, true);
|
5047
5162
|
$.reset(span);
|
@@ -5088,13 +5203,13 @@ const getTextThemeStyles = getPropStyles(callback$1);
|
|
5088
5203
|
//#region src/components-flex/close-button/CloseButton.svelte
|
5089
5204
|
var root_2$5 = $.template(`<span></span>`);
|
5090
5205
|
var root_1$10 = $.template(`<span><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 384 512" style="width: 100%; height: 100%;" class="svelte-18wmfyq"><path d="M342.6 150.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192 210.7 86.6 105.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L146.7 256 41.4 361.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L192 301.3 297.4 406.6c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L237.3 256 342.6 150.6z"></path></svg></span> <!>`, 1);
|
5091
|
-
const $$css$
|
5206
|
+
const $$css$27 = {
|
5092
5207
|
hash: "svelte-18wmfyq",
|
5093
5208
|
code: ".close-button.svelte-18wmfyq {display:inline-flex;align-items:center;justify-content:center;align-self:center;gap:8px;border-radius:100%;background:none;cursor:pointer;border:0;outline:0;flex-shrink:0;transition:background-color 0.12s,\n border-color 0.12s,\n color 0.12s;}.close-button.svelte-18wmfyq svg:where(.svelte-18wmfyq) {transition:transform 0.12s;}.close-button.svelte-18wmfyq:hover svg:where(.svelte-18wmfyq) {transform:rotate(90deg);}.close-button-order-one.svelte-18wmfyq {order:1;}.close-button-order-two.svelte-18wmfyq {order:2;}"
|
5094
5209
|
};
|
5095
5210
|
function CloseButton($$anchor, $$props) {
|
5096
5211
|
$.push($$props, false);
|
5097
|
-
$.append_styles($$anchor, $$css$
|
5212
|
+
$.append_styles($$anchor, $$css$27);
|
5098
5213
|
const hasLabel = $.mutable_state();
|
5099
5214
|
const styleObj = $.mutable_state();
|
5100
5215
|
const style = $.mutable_state();
|
@@ -5107,7 +5222,7 @@ function CloseButton($$anchor, $$props) {
|
|
5107
5222
|
let eventName = $.prop($$props, "eventName", 8, "");
|
5108
5223
|
let eventValue = $.prop($$props, "eventValue", 8, void 0);
|
5109
5224
|
const { brandKit } = useBrandKit();
|
5110
|
-
useInjectCustomizeCss(props());
|
5225
|
+
useInjectCustomizeCss(props(), layerId());
|
5111
5226
|
const { attributes, element, handleClick } = useClickable_default(props().onClick ? props() : {
|
5112
5227
|
onClick: {
|
5113
5228
|
operation: "closeApp",
|
@@ -5212,18 +5327,16 @@ function CloseButton($$anchor, $$props) {
|
|
5212
5327
|
$.set_attribute(svg, "fill", color);
|
5213
5328
|
$.reset(span);
|
5214
5329
|
var node_1 = $.sibling(span, 2);
|
5215
|
-
{
|
5216
|
-
var
|
5217
|
-
|
5218
|
-
|
5219
|
-
|
5220
|
-
|
5221
|
-
|
5222
|
-
|
5223
|
-
|
5224
|
-
|
5225
|
-
});
|
5226
|
-
}
|
5330
|
+
var consequent = ($$anchor$2) => {
|
5331
|
+
var span_1 = root_2$5();
|
5332
|
+
$.set_class(span_1, 1, `close-button-label ${isLeftLabelPlacement ? "close-button-order-one" : ""}`, "svelte-18wmfyq");
|
5333
|
+
span_1.textContent = label;
|
5334
|
+
$.template_effect(() => $.set_style(span_1, $.get(labelStyle)));
|
5335
|
+
$.append($$anchor$2, span_1);
|
5336
|
+
};
|
5337
|
+
$.if(node_1, ($$render) => {
|
5338
|
+
if ($.get(hasLabel)) $$render(consequent);
|
5339
|
+
});
|
5227
5340
|
$.template_effect(() => $.set_style(span, $.get(iconStyle)));
|
5228
5341
|
$.append($$anchor$1, fragment_1);
|
5229
5342
|
});
|
@@ -5308,19 +5421,19 @@ const IMAGE_ROUND_STYLES = {
|
|
5308
5421
|
//#endregion
|
5309
5422
|
//#region src/components-flex/image/Image.svelte
|
5310
5423
|
var root_1$9 = $.template(`<img class="image-img svelte-1olvu11">`);
|
5311
|
-
const $$css$
|
5424
|
+
const $$css$26 = {
|
5312
5425
|
hash: "svelte-1olvu11",
|
5313
5426
|
code: ".image.svelte-1olvu11 {max-width:100%;overflow:hidden;display:flex;align-items:center;justify-content:center;border:0;background:none;padding:0;margin:0;text-align:left;-webkit-appearance:none;}.image-img.svelte-1olvu11 {vertical-align:top;width:100%;height:100%;object-fit:cover;user-select:none;-webkit-user-drag:none;}"
|
5314
5427
|
};
|
5315
5428
|
function Image($$anchor, $$props) {
|
5316
5429
|
$.push($$props, false);
|
5317
|
-
$.append_styles($$anchor, $$css$
|
5430
|
+
$.append_styles($$anchor, $$css$26);
|
5318
5431
|
const styleObj = $.mutable_state();
|
5319
5432
|
const style = $.mutable_state();
|
5320
5433
|
const imgStyle = $.mutable_state();
|
5321
5434
|
let props = $.prop($$props, "props", 24, () => ({}));
|
5322
5435
|
let layerId = $.prop($$props, "layerId", 8, "");
|
5323
|
-
useInjectCustomizeCss(props());
|
5436
|
+
useInjectCustomizeCss(props(), layerId());
|
5324
5437
|
const { attributes, element, handleClick } = useClickable_default(props());
|
5325
5438
|
const aspectVariantStyles = ASPECT_VARIANT[props().aspectVariant]?.getProps();
|
5326
5439
|
const width = props().width ?? "100%";
|
@@ -5401,18 +5514,18 @@ const IMAGE_ASPECT_VARIANTS = {
|
|
5401
5514
|
|
5402
5515
|
//#endregion
|
5403
5516
|
//#region src/components-flex/layout/Layout.svelte
|
5404
|
-
const $$css$
|
5517
|
+
const $$css$25 = {
|
5405
5518
|
hash: "svelte-1o103hp",
|
5406
5519
|
code: ".layout.svelte-1o103hp {text-decoration:none;color:inherit;}.layout[data-clickable='true'].svelte-1o103hp {cursor:pointer;}.layout[data-clickable='true'].svelte-1o103hp:hover {opacity:0.8;}"
|
5407
5520
|
};
|
5408
5521
|
function Layout($$anchor, $$props) {
|
5409
5522
|
$.push($$props, false);
|
5410
|
-
$.append_styles($$anchor, $$css$
|
5523
|
+
$.append_styles($$anchor, $$css$25);
|
5411
5524
|
const style = $.mutable_state();
|
5412
5525
|
let props = $.prop($$props, "props", 24, () => ({}));
|
5413
5526
|
let layerId = $.prop($$props, "layerId", 8, "");
|
5414
5527
|
const { brandKit } = useBrandKit();
|
5415
|
-
useInjectCustomizeCss(props());
|
5528
|
+
useInjectCustomizeCss(props(), layerId());
|
5416
5529
|
const { attributes, element, handleClick } = useClickable_default(props());
|
5417
5530
|
$.legacy_pre_effect(() => ($.deep_read_state(props()), toCssBorder), () => {
|
5418
5531
|
$.set(style, objToStyle({
|
@@ -5487,13 +5600,13 @@ const LAYOUT_JUSTIFY = [
|
|
5487
5600
|
//#region src/components-flex/slider/Slider.svelte
|
5488
5601
|
var root_1$8 = $.template(`<button><i></i></button>`);
|
5489
5602
|
var root$16 = $.template(`<div><div class="slider-container svelte-wwv1o"><ul class="slider-list svelte-wwv1o"><!></ul></div> <div></div></div>`);
|
5490
|
-
const $$css$
|
5603
|
+
const $$css$24 = {
|
5491
5604
|
hash: "svelte-wwv1o",
|
5492
5605
|
code: ".slider.svelte-wwv1o {width:100%;overflow:hidden;overscroll-behavior:contain;touch-action:pan-y;}.slider-container.svelte-wwv1o {width:100%;overflow:hidden;overscroll-behavior:contain;touch-action:pan-y;}.slider-list.svelte-wwv1o {-webkit-user-drag:none;margin:0;padding:0;list-style:none;will-change:transform;}"
|
5493
5606
|
};
|
5494
5607
|
function Slider($$anchor, $$props) {
|
5495
5608
|
$.push($$props, false);
|
5496
|
-
$.append_styles($$anchor, $$css$
|
5609
|
+
$.append_styles($$anchor, $$css$24);
|
5497
5610
|
const indicators = $.mutable_state();
|
5498
5611
|
const itemWidthPercentage = $.mutable_state();
|
5499
5612
|
const baseContainerStyle = $.mutable_state();
|
@@ -5503,7 +5616,7 @@ function Slider($$anchor, $$props) {
|
|
5503
5616
|
let layerId = $.prop($$props, "layerId", 8);
|
5504
5617
|
let props = $.prop($$props, "props", 8);
|
5505
5618
|
let overrideStyle = $.prop($$props, "overrideStyle", 8);
|
5506
|
-
useInjectCustomizeCss(props());
|
5619
|
+
useInjectCustomizeCss(props(), layerId());
|
5507
5620
|
let containerElement = $.mutable_state();
|
5508
5621
|
let slotElement = $.mutable_state();
|
5509
5622
|
let currentIndex = $.mutable_state(0);
|
@@ -5702,16 +5815,16 @@ function Slider($$anchor, $$props) {
|
|
5702
5815
|
//#endregion
|
5703
5816
|
//#region src/components-flex/slider/SliderItem.svelte
|
5704
5817
|
var root$15 = $.template(`<li><!></li>`);
|
5705
|
-
const $$css$
|
5818
|
+
const $$css$23 = {
|
5706
5819
|
hash: "svelte-1m93md9",
|
5707
5820
|
code: ".slider-item.svelte-1m93md9 {overflow:hidden;}.slider-item-inner.svelte-1m93md9 {text-decoration:none;border:0;background:none;padding:0;margin:0;text-align:left;-webkit-appearance:none;text-align:left;color:inherit;-webkit-user-drag:none;user-select:none;}"
|
5708
5821
|
};
|
5709
5822
|
function SliderItem($$anchor, $$props) {
|
5710
5823
|
$.push($$props, false);
|
5711
|
-
$.append_styles($$anchor, $$css$
|
5824
|
+
$.append_styles($$anchor, $$css$23);
|
5712
5825
|
let layerId = $.prop($$props, "layerId", 8);
|
5713
5826
|
let props = $.prop($$props, "props", 8);
|
5714
|
-
useInjectCustomizeCss(props());
|
5827
|
+
useInjectCustomizeCss(props(), layerId());
|
5715
5828
|
const { attributes, element, handleClick } = useClickable_default(props());
|
5716
5829
|
$.init();
|
5717
5830
|
var li = root$15();
|
@@ -5781,18 +5894,18 @@ const TEXT_VARIANTS = { size: {
|
|
5781
5894
|
//#endregion
|
5782
5895
|
//#region src/components-flex/text/Text.svelte
|
5783
5896
|
var root$14 = $.template(`<p><!></p>`);
|
5784
|
-
const $$css$
|
5897
|
+
const $$css$22 = {
|
5785
5898
|
hash: "svelte-vifn7y",
|
5786
5899
|
code: ".text.svelte-vifn7y {margin:0;word-break:break-all;text-decoration:none;}"
|
5787
5900
|
};
|
5788
5901
|
function Text($$anchor, $$props) {
|
5789
5902
|
$.push($$props, false);
|
5790
|
-
$.append_styles($$anchor, $$css$
|
5903
|
+
$.append_styles($$anchor, $$css$22);
|
5791
5904
|
const escapedHTML = $.mutable_state();
|
5792
5905
|
const style = $.mutable_state();
|
5793
5906
|
let props = $.prop($$props, "props", 24, () => ({ content: "" }));
|
5794
5907
|
let layerId = $.prop($$props, "layerId", 8, "");
|
5795
|
-
useInjectCustomizeCss(props());
|
5908
|
+
useInjectCustomizeCss(props(), layerId());
|
5796
5909
|
const { brandKit } = useBrandKit();
|
5797
5910
|
const themeStyles = getTextThemeStyles(brandKit);
|
5798
5911
|
const fontFamilyStyles = props().fontFamilyVariant in FONT_FAMILY_VARIANT ? FONT_FAMILY_VARIANT[props().fontFamilyVariant].getProps(brandKit) : FONT_FAMILY_VARIANT.default.getProps(brandKit);
|
@@ -5879,17 +5992,17 @@ function Text($$anchor, $$props) {
|
|
5879
5992
|
//#endregion
|
5880
5993
|
//#region src/components-flex/rich-text/RichText.svelte
|
5881
5994
|
var root$13 = $.template(`<div><!></div>`);
|
5882
|
-
const $$css$
|
5995
|
+
const $$css$21 = {
|
5883
5996
|
hash: "svelte-dxr423",
|
5884
5997
|
code: ".rich-text.svelte-dxr423 p {margin:0;word-break:break-all;text-decoration:none;}.rich-text.svelte-dxr423 p + p {margin-top:0.75em;}"
|
5885
5998
|
};
|
5886
5999
|
function RichText($$anchor, $$props) {
|
5887
6000
|
$.push($$props, false);
|
5888
|
-
$.append_styles($$anchor, $$css$
|
6001
|
+
$.append_styles($$anchor, $$css$21);
|
5889
6002
|
const style = $.mutable_state();
|
5890
6003
|
let props = $.prop($$props, "props", 24, () => ({ content: "" }));
|
5891
6004
|
let layerId = $.prop($$props, "layerId", 8, "");
|
5892
|
-
useInjectCustomizeCss(props());
|
6005
|
+
useInjectCustomizeCss(props(), layerId());
|
5893
6006
|
const { brandKit } = useBrandKit();
|
5894
6007
|
const themeStyles = getTextThemeStyles(brandKit);
|
5895
6008
|
const fontFamilyStyles = props().fontFamilyVariant in FONT_FAMILY_VARIANT ? FONT_FAMILY_VARIANT[props().fontFamilyVariant].getProps(brandKit) : FONT_FAMILY_VARIANT.default.getProps(brandKit);
|
@@ -6005,19 +6118,19 @@ const getTextLinkThemeStyles = getPropStyles(callback);
|
|
6005
6118
|
//#endregion
|
6006
6119
|
//#region src/components-flex/text-link/TextLink.svelte
|
6007
6120
|
var root_1$7 = $.template(`<!> <span><!></span>`, 1);
|
6008
|
-
const $$css$
|
6121
|
+
const $$css$20 = {
|
6009
6122
|
hash: "svelte-dc9m5n",
|
6010
6123
|
code: ".link.svelte-dc9m5n {-webkit-appearance:none;border:0;background:none;padding:0;display:inline-flex;}.link.svelte-dc9m5n,\n .link.svelte-dc9m5n:visited,\n .link.svelte-dc9m5n:link {color:var(--color);}.link.svelte-dc9m5n:hover {color:var(--hover-color);}.link.svelte-dc9m5n:active {color:var(--active-color);}.link.underline-hover-on.svelte-dc9m5n {text-decoration:none;}.link.underline-hover-on.svelte-dc9m5n:hover {text-decoration:underline;}.link.underline-hover-off.svelte-dc9m5n {text-decoration:underline;}.link.underline-hover-off.svelte-dc9m5n:hover {text-decoration:none;}.link.underline-on.svelte-dc9m5n {text-decoration:underline;}.link.underline-off.svelte-dc9m5n {text-decoration:none;}"
|
6011
6124
|
};
|
6012
6125
|
function TextLink($$anchor, $$props) {
|
6013
6126
|
$.push($$props, false);
|
6014
|
-
$.append_styles($$anchor, $$css$
|
6127
|
+
$.append_styles($$anchor, $$css$20);
|
6015
6128
|
const escapedHTML = $.mutable_state();
|
6016
6129
|
const variables$1 = $.mutable_state();
|
6017
6130
|
const style = $.mutable_state();
|
6018
6131
|
let props = $.prop($$props, "props", 24, () => ({ label: "" }));
|
6019
6132
|
let layerId = $.prop($$props, "layerId", 8, "");
|
6020
|
-
useInjectCustomizeCss(props());
|
6133
|
+
useInjectCustomizeCss(props(), layerId());
|
6021
6134
|
const { brandKit } = useBrandKit();
|
6022
6135
|
const { attributes, element, handleClick } = useClickable_default({
|
6023
6136
|
...props(),
|
@@ -6080,22 +6193,20 @@ function TextLink($$anchor, $$props) {
|
|
6080
6193
|
$.event("click", $$element, handleClick);
|
6081
6194
|
var fragment_1 = root_1$7();
|
6082
6195
|
var node_1 = $.first_child(fragment_1);
|
6083
|
-
{
|
6084
|
-
|
6085
|
-
|
6086
|
-
|
6087
|
-
|
6088
|
-
|
6089
|
-
|
6090
|
-
|
6091
|
-
|
6092
|
-
|
6093
|
-
|
6094
|
-
|
6095
|
-
|
6096
|
-
|
6097
|
-
});
|
6098
|
-
}
|
6196
|
+
var consequent = ($$anchor$2) => {
|
6197
|
+
const expression = $.derived_safe_equal(() => ({
|
6198
|
+
variant: props().iconVariant,
|
6199
|
+
color: props().iconColor ?? props().color,
|
6200
|
+
width: "1em",
|
6201
|
+
height: "1em"
|
6202
|
+
}));
|
6203
|
+
Icon($$anchor$2, { get props() {
|
6204
|
+
return $.get(expression);
|
6205
|
+
} });
|
6206
|
+
};
|
6207
|
+
$.if(node_1, ($$render) => {
|
6208
|
+
if (props().isIcon && props().iconVariant) $$render(consequent);
|
6209
|
+
});
|
6099
6210
|
var span = $.sibling(node_1, 2);
|
6100
6211
|
var node_2 = $.child(span);
|
6101
6212
|
$.html(node_2, () => $.get(escapedHTML), false, false);
|
@@ -6131,30 +6242,28 @@ const TEXT_LINK_UNDERLINE = {
|
|
6131
6242
|
//#endregion
|
6132
6243
|
//#region src/components-flex/background-overlay/BackgroundOverlay.svelte
|
6133
6244
|
var root_1$6 = $.template(`<div></div>`);
|
6134
|
-
const $$css$
|
6245
|
+
const $$css$19 = {
|
6135
6246
|
hash: "svelte-18nkdjz",
|
6136
6247
|
code: ".v2-background.svelte-18nkdjz {position:fixed;top:0;left:0;width:100%;height:100%;background:rgba(0, 0, 0, 0.3);z-index:2147483646;}"
|
6137
6248
|
};
|
6138
6249
|
function BackgroundOverlay($$anchor, $$props) {
|
6139
6250
|
$.push($$props, false);
|
6140
|
-
$.append_styles($$anchor, $$css$
|
6251
|
+
$.append_styles($$anchor, $$css$19);
|
6141
6252
|
let backgroundOverlay = $.prop($$props, "backgroundOverlay", 8, false);
|
6142
6253
|
let className = $.prop($$props, "class", 8, void 0);
|
6143
6254
|
const dispatch = createEventDispatcher();
|
6144
6255
|
$.init();
|
6145
6256
|
var fragment = $.comment();
|
6146
6257
|
var node = $.first_child(fragment);
|
6147
|
-
{
|
6148
|
-
var
|
6149
|
-
|
6150
|
-
|
6151
|
-
|
6152
|
-
|
6153
|
-
|
6154
|
-
|
6155
|
-
|
6156
|
-
});
|
6157
|
-
}
|
6258
|
+
var consequent = ($$anchor$1) => {
|
6259
|
+
var div = root_1$6();
|
6260
|
+
$.template_effect(($0) => $.set_class(div, 1, $0, "svelte-18nkdjz"), [() => $.clsx(["v2-background", className() || ""].join(" "))], $.derived_safe_equal);
|
6261
|
+
$.event("click", div, () => dispatch("click"));
|
6262
|
+
$.append($$anchor$1, div);
|
6263
|
+
};
|
6264
|
+
$.if(node, ($$render) => {
|
6265
|
+
if (backgroundOverlay()) $$render(consequent);
|
6266
|
+
});
|
6158
6267
|
$.append($$anchor, fragment);
|
6159
6268
|
$.pop();
|
6160
6269
|
}
|
@@ -6164,13 +6273,13 @@ function BackgroundOverlay($$anchor, $$props) {
|
|
6164
6273
|
var root_2$4 = $.template(`<!> <!>`, 1);
|
6165
6274
|
var root_4 = $.template(`<div role="dialog" aria-modal="true"><!></div>`);
|
6166
6275
|
var root$12 = $.template(`<!> <!>`, 1);
|
6167
|
-
const $$css$
|
6276
|
+
const $$css$18 = {
|
6168
6277
|
hash: "svelte-45ue06",
|
6169
6278
|
code: "* {box-sizing:border-box;}.modal.svelte-45ue06 {position:fixed;z-index:2147483647;display:flex;}.modal.svelte-45ue06 > .button {flex:auto;display:flex;}\n /* PC */\n @media screen and (min-width: 641px) {.modal-bp.svelte-45ue06 {height:var(--modal-bp-height-pc) !important;width:var(--modal-bp-width-pc) !important;top:var(--modal-bp-top-pc) !important;left:var(--modal-bp-left-pc) !important;bottom:var(--modal-bp-bottom-pc) !important;right:var(--modal-bp-right-pc) !important;transform:var(--modal-bp-transform-pc);margin:var(--modal-bp-margin-pc) !important;}.background-bp-pc {display:block;}.background-bp-sp {display:none;}\n }\n\n /* SP */\n @media screen and (max-width: 640px) {.modal-bp.svelte-45ue06 {height:var(--modal-bp-height-sp) !important;width:var(--modal-bp-width-sp) !important;top:var(--modal-bp-top-sp) !important;left:var(--modal-bp-left-sp) !important;bottom:var(--modal-bp-bottom-sp) !important;right:var(--modal-bp-right-sp) !important;transform:var(--modal-bp-transform-sp);margin:var(--modal-bp-margin-sp) !important;}.background-bp-pc {display:none;}.background-bp-sp {display:block;}\n }"
|
6170
6279
|
};
|
6171
6280
|
function Modal($$anchor, $$props) {
|
6172
6281
|
$.push($$props, false);
|
6173
|
-
$.append_styles($$anchor, $$css$
|
6282
|
+
$.append_styles($$anchor, $$css$18);
|
6174
6283
|
const close$1 = $.mutable_state();
|
6175
6284
|
const backgroundClick = $.mutable_state();
|
6176
6285
|
const backgroundClickPC = $.mutable_state();
|
@@ -6180,7 +6289,7 @@ function Modal($$anchor, $$props) {
|
|
6180
6289
|
let useBreakPoint = $.prop($$props, "useBreakPoint", 8, false);
|
6181
6290
|
let placement = $.prop($$props, "placement", 8);
|
6182
6291
|
let breakPoint = $.prop($$props, "breakPoint", 8);
|
6183
|
-
|
6292
|
+
$.prop($$props, "elasticity", 8);
|
6184
6293
|
let animation = $.prop($$props, "animation", 8, "none");
|
6185
6294
|
let props = $.prop($$props, "props", 24, () => ({}));
|
6186
6295
|
let closeEventName = $.prop($$props, "closeEventName", 8, "");
|
@@ -6323,78 +6432,72 @@ function Modal($$anchor, $$props) {
|
|
6323
6432
|
$.get(handle_keydown)?.apply(this, $$args);
|
6324
6433
|
});
|
6325
6434
|
var node = $.first_child(fragment);
|
6326
|
-
{
|
6327
|
-
|
6328
|
-
var
|
6329
|
-
|
6330
|
-
|
6331
|
-
|
6332
|
-
|
6333
|
-
|
6334
|
-
|
6335
|
-
|
6336
|
-
|
6337
|
-
|
6338
|
-
|
6339
|
-
|
6340
|
-
|
6341
|
-
|
6342
|
-
|
6343
|
-
|
6344
|
-
|
6345
|
-
|
6346
|
-
|
6347
|
-
|
6348
|
-
|
6349
|
-
|
6350
|
-
|
6351
|
-
});
|
6352
|
-
$.append($$anchor$2, fragment_1);
|
6353
|
-
};
|
6354
|
-
var alternate_1 = ($$anchor$2) => {
|
6355
|
-
BackgroundOverlay($$anchor$2, {
|
6356
|
-
get backgroundOverlay() {
|
6357
|
-
return $.get(backgroundOverlay);
|
6358
|
-
},
|
6359
|
-
$$events: { click(...$$args) {
|
6360
|
-
$.get(backgroundClick)?.apply(this, $$args);
|
6361
|
-
} }
|
6362
|
-
});
|
6363
|
-
};
|
6364
|
-
$.if($$anchor$1, ($$render) => {
|
6365
|
-
if (useBreakPoint()) $$render(consequent_1);
|
6366
|
-
else $$render(alternate_1, false);
|
6367
|
-
}, $$elseif);
|
6368
|
-
}
|
6435
|
+
var consequent = ($$anchor$1) => {};
|
6436
|
+
var alternate = ($$anchor$1, $$elseif) => {
|
6437
|
+
var consequent_1 = ($$anchor$2) => {
|
6438
|
+
var fragment_1 = root_2$4();
|
6439
|
+
var node_1 = $.first_child(fragment_1);
|
6440
|
+
BackgroundOverlay(node_1, {
|
6441
|
+
class: "background-bp-pc",
|
6442
|
+
get backgroundOverlay() {
|
6443
|
+
return $.get(backgroundOverlayPC);
|
6444
|
+
},
|
6445
|
+
$$events: { click(...$$args) {
|
6446
|
+
$.get(backgroundClickPC)?.apply(this, $$args);
|
6447
|
+
} }
|
6448
|
+
});
|
6449
|
+
var node_2 = $.sibling(node_1, 2);
|
6450
|
+
BackgroundOverlay(node_2, {
|
6451
|
+
class: "background-bp-sp ",
|
6452
|
+
get backgroundOverlay() {
|
6453
|
+
return $.get(backgroundOverlaySP);
|
6454
|
+
},
|
6455
|
+
$$events: { click(...$$args) {
|
6456
|
+
$.get(backgroundClickSP)?.apply(this, $$args);
|
6457
|
+
} }
|
6458
|
+
});
|
6459
|
+
$.append($$anchor$2, fragment_1);
|
6369
6460
|
};
|
6370
|
-
|
6371
|
-
|
6372
|
-
|
6373
|
-
|
6374
|
-
|
6375
|
-
|
6376
|
-
|
6377
|
-
|
6378
|
-
|
6379
|
-
var node_4 = $.child(div);
|
6380
|
-
$.slot(node_4, $$props, "default", {}, null);
|
6381
|
-
$.reset(div);
|
6382
|
-
$.bind_this(div, ($$value) => $.set(modal, $$value), () => $.get(modal));
|
6383
|
-
$.template_effect(($0, $1) => {
|
6384
|
-
$.set_class(div, 1, $0, "svelte-45ue06");
|
6385
|
-
$.set_attribute(div, "data-layer-id", layerId());
|
6386
|
-
$.set_style(div, $1);
|
6387
|
-
}, [() => $.clsx(["modal", useBreakPoint() ? "modal-bp" : ""].join(" ")), () => Array.from(modalStyles).join(";")], $.derived_safe_equal);
|
6388
|
-
$.transition(1, div, () => customAnimation, () => ({
|
6389
|
-
transforms: $.get(transforms),
|
6390
|
-
animationStyle: animation()
|
6391
|
-
}));
|
6392
|
-
$.append($$anchor$1, div);
|
6461
|
+
var alternate_1 = ($$anchor$2) => {
|
6462
|
+
BackgroundOverlay($$anchor$2, {
|
6463
|
+
get backgroundOverlay() {
|
6464
|
+
return $.get(backgroundOverlay);
|
6465
|
+
},
|
6466
|
+
$$events: { click(...$$args) {
|
6467
|
+
$.get(backgroundClick)?.apply(this, $$args);
|
6468
|
+
} }
|
6469
|
+
});
|
6393
6470
|
};
|
6394
|
-
$.if(
|
6395
|
-
if (
|
6396
|
-
|
6397
|
-
|
6471
|
+
$.if($$anchor$1, ($$render) => {
|
6472
|
+
if (useBreakPoint()) $$render(consequent_1);
|
6473
|
+
else $$render(alternate_1, false);
|
6474
|
+
}, $$elseif);
|
6475
|
+
};
|
6476
|
+
$.if(node, ($$render) => {
|
6477
|
+
if (isCanvasPreview()) $$render(consequent);
|
6478
|
+
else $$render(alternate, false);
|
6479
|
+
});
|
6480
|
+
var node_3 = $.sibling(node, 2);
|
6481
|
+
var consequent_2 = ($$anchor$1) => {
|
6482
|
+
var div = root_4();
|
6483
|
+
var node_4 = $.child(div);
|
6484
|
+
$.slot(node_4, $$props, "default", {}, null);
|
6485
|
+
$.reset(div);
|
6486
|
+
$.bind_this(div, ($$value) => $.set(modal, $$value), () => $.get(modal));
|
6487
|
+
$.template_effect(($0, $1) => {
|
6488
|
+
$.set_class(div, 1, $0, "svelte-45ue06");
|
6489
|
+
$.set_attribute(div, "data-layer-id", layerId());
|
6490
|
+
$.set_style(div, $1);
|
6491
|
+
}, [() => $.clsx(["modal", useBreakPoint() ? "modal-bp" : ""].join(" ")), () => Array.from(modalStyles).join(";")], $.derived_safe_equal);
|
6492
|
+
$.transition(1, div, () => customAnimation, () => ({
|
6493
|
+
transforms: $.get(transforms),
|
6494
|
+
animationStyle: animation()
|
6495
|
+
}));
|
6496
|
+
$.append($$anchor$1, div);
|
6497
|
+
};
|
6498
|
+
$.if(node_3, ($$render) => {
|
6499
|
+
if ($.get(visible)) $$render(consequent_2);
|
6500
|
+
});
|
6398
6501
|
$.append($$anchor, fragment);
|
6399
6502
|
$.pop();
|
6400
6503
|
}
|
@@ -6402,13 +6505,13 @@ function Modal($$anchor, $$props) {
|
|
6402
6505
|
//#endregion
|
6403
6506
|
//#region src/components-flex/code/Code.svelte
|
6404
6507
|
var root$11 = $.template(`<div><!></div>`);
|
6405
|
-
const $$css$
|
6508
|
+
const $$css$17 = {
|
6406
6509
|
hash: "svelte-igivoz",
|
6407
6510
|
code: ".code.svelte-igivoz {flex-grow:1;flex-shrink:0;align-self:stretch;}\n /*{@html props.rawCss}*/"
|
6408
6511
|
};
|
6409
6512
|
function Code($$anchor, $$props) {
|
6410
6513
|
$.push($$props, false);
|
6411
|
-
$.append_styles($$anchor, $$css$
|
6514
|
+
$.append_styles($$anchor, $$css$17);
|
6412
6515
|
let props = $.prop($$props, "props", 24, () => ({}));
|
6413
6516
|
let layerId = $.prop($$props, "layerId", 8, "");
|
6414
6517
|
function unescapeBraces(str) {
|
@@ -6461,20 +6564,20 @@ const LIST_ITEM_CONTEXT_KEY = "ListItemContext";
|
|
6461
6564
|
//#endregion
|
6462
6565
|
//#region src/components-flex/list/ListItem.svelte
|
6463
6566
|
var root$10 = $.template(`<li><!></li>`);
|
6464
|
-
const $$css$
|
6567
|
+
const $$css$16 = {
|
6465
6568
|
hash: "svelte-b4b4gh",
|
6466
6569
|
code: ".list-item.svelte-b4b4gh {margin:0;padding:0;}.list-item-inner.svelte-b4b4gh {display:flex;align-items:center;width:100%;text-decoration:none;color:inherit;border:0;background:none;padding:0;margin:0;text-align:left;-webkit-appearance:none;}.list-item-inner.svelte-b4b4gh:hover {opacity:0.8;}.list-item.svelte-b4b4gh:not(:first-child) {border-top-width:var(--list-item-border-width);border-top-style:var(--list-item-border-style);border-top-color:var(--list-item-border-color);}"
|
6467
6570
|
};
|
6468
6571
|
function ListItem($$anchor, $$props) {
|
6469
6572
|
$.push($$props, false);
|
6470
|
-
$.append_styles($$anchor, $$css$
|
6573
|
+
$.append_styles($$anchor, $$css$16);
|
6471
6574
|
const variables$1 = $.mutable_state();
|
6472
6575
|
const style = $.mutable_state();
|
6473
6576
|
const innerStyle = $.mutable_state();
|
6474
6577
|
let layerId = $.prop($$props, "layerId", 8);
|
6475
6578
|
let props = $.prop($$props, "props", 8);
|
6476
|
-
|
6477
|
-
useInjectCustomizeCss(props());
|
6579
|
+
$.prop($$props, "item", 8);
|
6580
|
+
useInjectCustomizeCss(props(), layerId());
|
6478
6581
|
const { attributes, element, handleClick } = useClickable_default(props());
|
6479
6582
|
const context = getContext(LIST_ITEM_CONTEXT_KEY) || {};
|
6480
6583
|
$.legacy_pre_effect(() => {}, () => {
|
@@ -6527,13 +6630,13 @@ function ListItem($$anchor, $$props) {
|
|
6527
6630
|
//#endregion
|
6528
6631
|
//#region src/components-flex/list/List.svelte
|
6529
6632
|
var root$9 = $.template(`<ul><!></ul>`);
|
6530
|
-
const $$css$
|
6633
|
+
const $$css$15 = {
|
6531
6634
|
hash: "svelte-v2vy6p",
|
6532
6635
|
code: ".list.svelte-v2vy6p {padding:0;margin:0;list-style:none;display:flex;flex-direction:column;--border-width: 0;--border-style: solit;--border-color: rgba(255, 255, 255, 0);border-top-width:var(--border-width);border-top-style:var(--border-style);border-top-color:var(--border-color);border-bottom-width:var(--border-width);border-bottom-style:var(--border-style);border-bottom-color:var(--border-color);}"
|
6533
6636
|
};
|
6534
6637
|
function List($$anchor, $$props) {
|
6535
6638
|
$.push($$props, false);
|
6536
|
-
$.append_styles($$anchor, $$css$
|
6639
|
+
$.append_styles($$anchor, $$css$15);
|
6537
6640
|
const variables$1 = $.mutable_state();
|
6538
6641
|
const actionTableData = $.mutable_state();
|
6539
6642
|
const items = $.mutable_state();
|
@@ -6541,7 +6644,7 @@ function List($$anchor, $$props) {
|
|
6541
6644
|
let layerId = $.prop($$props, "layerId", 8);
|
6542
6645
|
let props = $.prop($$props, "props", 8);
|
6543
6646
|
const { brandKit } = useBrandKit();
|
6544
|
-
useInjectCustomizeCss(props());
|
6647
|
+
useInjectCustomizeCss(props(), layerId());
|
6545
6648
|
const vars = getVariables();
|
6546
6649
|
setContext(LIST_ITEM_CONTEXT_KEY, {
|
6547
6650
|
paddingTop: props().itemPaddingTop,
|
@@ -6615,18 +6718,18 @@ function splitNumberAndUnit(value) {
|
|
6615
6718
|
//#endregion
|
6616
6719
|
//#region src/components-flex/multi-column/MultiColumn.svelte
|
6617
6720
|
var root$8 = $.template(`<ul><!></ul>`);
|
6618
|
-
const $$css$
|
6721
|
+
const $$css$14 = {
|
6619
6722
|
hash: "svelte-9pwfkr",
|
6620
6723
|
code: ".multi-column.svelte-9pwfkr {padding:0;margin:0;list-style:none;display:flex;flex-direction:row;}"
|
6621
6724
|
};
|
6622
6725
|
function MultiColumn($$anchor, $$props) {
|
6623
6726
|
$.push($$props, false);
|
6624
|
-
$.append_styles($$anchor, $$css$
|
6727
|
+
$.append_styles($$anchor, $$css$14);
|
6625
6728
|
const style = $.mutable_state();
|
6626
6729
|
let layerId = $.prop($$props, "layerId", 8);
|
6627
6730
|
let props = $.prop($$props, "props", 8);
|
6628
6731
|
const { brandKit } = useBrandKit();
|
6629
|
-
useInjectCustomizeCss(props());
|
6732
|
+
useInjectCustomizeCss(props(), layerId());
|
6630
6733
|
let listGap = (() => {
|
6631
6734
|
if (!props().gap) return "0";
|
6632
6735
|
const { number, unit } = splitNumberAndUnit(props().gap);
|
@@ -6674,18 +6777,18 @@ function MultiColumn($$anchor, $$props) {
|
|
6674
6777
|
//#endregion
|
6675
6778
|
//#region src/components-flex/multi-column/MultiColumnItem.svelte
|
6676
6779
|
var root$7 = $.template(`<li><!></li>`);
|
6677
|
-
const $$css$
|
6780
|
+
const $$css$13 = {
|
6678
6781
|
hash: "svelte-18bwzrs",
|
6679
6782
|
code: ".multi-column-item.svelte-18bwzrs {margin:0;width:100%;padding-top:0;padding-bottom:0;padding-left:var(--multi-column-item-padding);padding-right:var(--multi-column-item-padding);}.multi-column-item-inner.svelte-18bwzrs {display:flex;flex-direction:column;align-items:center;gap:var(--multi-column-item-gap);width:100%;text-decoration:none;border:0;background:none;margin:0;text-align:left;-webkit-appearance:none;padding-top:var(--multi-column-item-padding-top);padding-left:var(--multi-column-item-padding-left);padding-right:var(--multi-column-item-padding-right);padding-bottom:var(--multi-column-item-padding-bottom);}.multi-column-item-inner.svelte-18bwzrs:hover {opacity:0.8;}.multi-column-item.svelte-18bwzrs:not(:first-child) {border-left-width:var(--multi-column-item-border-width);border-left-style:var(--multi-column-item-border-style);border-left-color:var(--multi-column-item-border-color);}"
|
6680
6783
|
};
|
6681
6784
|
function MultiColumnItem($$anchor, $$props) {
|
6682
6785
|
$.push($$props, false);
|
6683
|
-
$.append_styles($$anchor, $$css$
|
6786
|
+
$.append_styles($$anchor, $$css$13);
|
6684
6787
|
const variables$1 = $.mutable_state();
|
6685
6788
|
const style = $.mutable_state();
|
6686
6789
|
let layerId = $.prop($$props, "layerId", 8);
|
6687
6790
|
let props = $.prop($$props, "props", 8);
|
6688
|
-
useInjectCustomizeCss(props());
|
6791
|
+
useInjectCustomizeCss(props(), layerId());
|
6689
6792
|
const { attributes, element, handleClick } = useClickable_default(props());
|
6690
6793
|
const context = getContext(MULTI_COLUMN_ITEM_CONTEXT_KEY) || {};
|
6691
6794
|
$.legacy_pre_effect(() => {}, () => {
|
@@ -6736,17 +6839,17 @@ function MultiColumnItem($$anchor, $$props) {
|
|
6736
6839
|
//#endregion
|
6737
6840
|
//#region src/components-flex/youtube/Youtube.svelte
|
6738
6841
|
var root$6 = $.template(`<div><div class="youtube-player"></div></div>`);
|
6739
|
-
const $$css$
|
6842
|
+
const $$css$12 = {
|
6740
6843
|
hash: "svelte-odfkc2",
|
6741
6844
|
code: ".youtube.svelte-odfkc2 {position:relative;aspect-ratio:16 / 9;width:100%;border-radius:3px;}.youtube.svelte-odfkc2 iframe {position:absolute;width:100%;height:100%;object-fit:cover;}"
|
6742
6845
|
};
|
6743
6846
|
function Youtube($$anchor, $$props) {
|
6744
6847
|
$.push($$props, false);
|
6745
|
-
$.append_styles($$anchor, $$css$
|
6848
|
+
$.append_styles($$anchor, $$css$12);
|
6746
6849
|
const style = $.mutable_state();
|
6747
6850
|
let props = $.prop($$props, "props", 24, () => ({}));
|
6748
6851
|
let layerId = $.prop($$props, "layerId", 8, "");
|
6749
|
-
useInjectCustomizeCss(props());
|
6852
|
+
useInjectCustomizeCss(props(), layerId());
|
6750
6853
|
if (!window.YT) {
|
6751
6854
|
const tag = document.createElement("script");
|
6752
6855
|
tag.src = "https://www.youtube.com/iframe_api";
|
@@ -6839,20 +6942,20 @@ function Youtube($$anchor, $$props) {
|
|
6839
6942
|
//#endregion
|
6840
6943
|
//#region src/components-flex/count-down/CountDown.svelte
|
6841
6944
|
var root$5 = $.template(`<div><!></div>`);
|
6842
|
-
const $$css$
|
6945
|
+
const $$css$11 = {
|
6843
6946
|
hash: "svelte-1n395il",
|
6844
6947
|
code: ".countdown.svelte-1n395il {display:flex;align-items:center;gap:4px;}"
|
6845
6948
|
};
|
6846
6949
|
function CountDown($$anchor, $$props) {
|
6847
6950
|
$.push($$props, false);
|
6848
|
-
$.append_styles($$anchor, $$css$
|
6951
|
+
$.append_styles($$anchor, $$css$11);
|
6849
6952
|
const day = $.mutable_state();
|
6850
6953
|
const hour = $.mutable_state();
|
6851
6954
|
const min = $.mutable_state();
|
6852
6955
|
const sec = $.mutable_state();
|
6853
6956
|
let props = $.prop($$props, "props", 24, () => ({}));
|
6854
6957
|
let layerId = $.prop($$props, "layerId", 8, "");
|
6855
|
-
useInjectCustomizeCss(props());
|
6958
|
+
useInjectCustomizeCss(props(), layerId());
|
6856
6959
|
let remainingTime = $.mutable_state();
|
6857
6960
|
let timeLimit = props().timeLimit ? new Date(props().timeLimit) : /* @__PURE__ */ new Date();
|
6858
6961
|
function calcRemainingTime(limit) {
|
@@ -6929,8 +7032,8 @@ function CountDown($$anchor, $$props) {
|
|
6929
7032
|
|
6930
7033
|
//#endregion
|
6931
7034
|
//#region src/hooks/useText.ts
|
6932
|
-
const useText = (props) => {
|
6933
|
-
useInjectCustomizeCss(props);
|
7035
|
+
const useText = (props, layerId) => {
|
7036
|
+
useInjectCustomizeCss(props, layerId);
|
6934
7037
|
const { brandKit } = useBrandKit();
|
6935
7038
|
const themeStyles = getTextThemeStyles(brandKit);
|
6936
7039
|
const fontFamilyStyles = props.fontFamilyVariant in FONT_FAMILY_VARIANT ? FONT_FAMILY_VARIANT[props.fontFamilyVariant].getProps(brandKit) : FONT_FAMILY_VARIANT.default.getProps(brandKit);
|
@@ -6995,7 +7098,7 @@ function CountDownValue($$anchor, $$props) {
|
|
6995
7098
|
let props = $.prop($$props, "props", 24, () => ({}));
|
6996
7099
|
let layerId = $.prop($$props, "layerId", 8, "");
|
6997
7100
|
let countdownStore = getContext("countdownStore");
|
6998
|
-
let { style } = useText(props());
|
7101
|
+
let { style } = useText(props(), layerId());
|
6999
7102
|
$.legacy_pre_effect(() => ($countdownStore(), $.deep_read_state(props())), () => {
|
7000
7103
|
$.set(value, (() => {
|
7001
7104
|
const { day, hour, min, sec } = $countdownStore();
|
@@ -7028,16 +7131,16 @@ function CountDownValue($$anchor, $$props) {
|
|
7028
7131
|
//#endregion
|
7029
7132
|
//#region src/components-flex/clip-copy/ClipCopy.svelte
|
7030
7133
|
var root$3 = $.template(`<div><button class="clipboard-button svelte-orhp4c"><!></button> <span class="clipboard-tooltip svelte-orhp4c">コピーしました</span></div>`);
|
7031
|
-
const $$css$
|
7134
|
+
const $$css$10 = {
|
7032
7135
|
hash: "svelte-orhp4c",
|
7033
7136
|
code: ".clipboard.svelte-orhp4c {position:relative;display:inline-flex;}.clipboard-button.svelte-orhp4c {position:relative;display:inline-flex;align-items:center;white-space:nowrap;gap:12px;background:none;border:0;transition:0.12s;cursor:pointer;}.clipboard-button.svelte-orhp4c:hover {opacity:0.8;}.clipboard-button.svelte-orhp4c:active {opacity:0.6;}.clipboard-tooltip.svelte-orhp4c {position:absolute;top:-8px;left:50%;display:block;transform:translate(-50%, -100%);padding:4px 10px;background-color:#333333;color:#ffffff;font-size:11px;font-weight:bold;border-radius:4px;transition:transform 0.2s ease-out;white-space:nowrap;pointer-events:none;}.clipboard-tooltip.svelte-orhp4c:after {content:'';display:block;position:absolute;bottom:0;left:50%;width:8px;height:8px;background-color:#333333;border-radius:1px;transform:translate(-50%, 40%) rotate(45deg);}.clipboard-tooltip[aria-hidden='true'].svelte-orhp4c {opacity:0;transform:translate(-50%, -80%);}"
|
7034
7137
|
};
|
7035
7138
|
function ClipCopy($$anchor, $$props) {
|
7036
7139
|
$.push($$props, false);
|
7037
|
-
$.append_styles($$anchor, $$css$
|
7140
|
+
$.append_styles($$anchor, $$css$10);
|
7038
7141
|
let props = $.prop($$props, "props", 24, () => ({}));
|
7039
7142
|
let layerId = $.prop($$props, "layerId", 8, "");
|
7040
|
-
useInjectCustomizeCss(props());
|
7143
|
+
useInjectCustomizeCss(props(), layerId());
|
7041
7144
|
let buttonElement = $.mutable_state();
|
7042
7145
|
let showTooltip = $.mutable_state(false);
|
7043
7146
|
const handleClick = (e) => {
|
@@ -7074,19 +7177,19 @@ function ClipCopy($$anchor, $$props) {
|
|
7074
7177
|
//#endregion
|
7075
7178
|
//#region src/components-flex/embed/Embed.svelte
|
7076
7179
|
var root$2 = $.template(`<div><!></div>`);
|
7077
|
-
const $$css$
|
7180
|
+
const $$css$9 = {
|
7078
7181
|
hash: "svelte-13tkwh0",
|
7079
7182
|
code: ".embed.svelte-13tkwh0 {width:var(--width);height:var(--height);aspect-ratio:var(--aspect);}.embed.svelte-13tkwh0 iframe {vertical-align:bottom;max-width:100%;width:var(--width) !important;height:var(--height) !important;aspect-ratio:var(--aspect) !important;}"
|
7080
7183
|
};
|
7081
7184
|
function Embed($$anchor, $$props) {
|
7082
7185
|
$.push($$props, false);
|
7083
|
-
$.append_styles($$anchor, $$css$
|
7186
|
+
$.append_styles($$anchor, $$css$9);
|
7084
7187
|
const variables$1 = $.mutable_state();
|
7085
7188
|
const styleObj = $.mutable_state();
|
7086
7189
|
const style = $.mutable_state();
|
7087
7190
|
let props = $.prop($$props, "props", 24, () => ({}));
|
7088
7191
|
let layerId = $.prop($$props, "layerId", 8, "");
|
7089
|
-
useInjectCustomizeCss(props());
|
7192
|
+
useInjectCustomizeCss(props(), layerId());
|
7090
7193
|
const aspectVariantStyles = ASPECT_VARIANT[props().aspectVariant]?.getProps();
|
7091
7194
|
const width = props().width ?? "100%";
|
7092
7195
|
$.legacy_pre_effect(() => $.deep_read_state(props()), () => {
|
@@ -7124,16 +7227,16 @@ function Embed($$anchor, $$props) {
|
|
7124
7227
|
//#endregion
|
7125
7228
|
//#region src/components-flex/form/Form.svelte
|
7126
7229
|
var root$1 = $.template(`<div><!></div>`);
|
7127
|
-
const $$css$
|
7230
|
+
const $$css$8 = {
|
7128
7231
|
hash: "svelte-nekp9e",
|
7129
7232
|
code: ".form.svelte-nekp9e {width:100%;}"
|
7130
7233
|
};
|
7131
7234
|
function Form($$anchor, $$props) {
|
7132
7235
|
$.push($$props, false);
|
7133
|
-
$.append_styles($$anchor, $$css$
|
7236
|
+
$.append_styles($$anchor, $$css$8);
|
7134
7237
|
let props = $.prop($$props, "props", 24, () => ({}));
|
7135
7238
|
let layerId = $.prop($$props, "layerId", 8, "");
|
7136
|
-
useInjectCustomizeCss(props());
|
7239
|
+
useInjectCustomizeCss(props(), layerId());
|
7137
7240
|
$.init();
|
7138
7241
|
var div = root$1();
|
7139
7242
|
var node = $.child(div);
|
@@ -7169,18 +7272,18 @@ var root_2$3 = $.template(`<span class="field-required svelte-1maygd6">*</span
|
|
7169
7272
|
var root_1$5 = $.template(`<dt class="svelte-1maygd6"><span> </span> <!></dt>`);
|
7170
7273
|
var root_3 = $.template(`<p class="field-error svelte-1maygd6"> </p>`);
|
7171
7274
|
var root = $.template(`<dl><!> <dd class="svelte-1maygd6"><!> <!></dd></dl>`);
|
7172
|
-
const $$css$
|
7275
|
+
const $$css$7 = {
|
7173
7276
|
hash: "svelte-1maygd6",
|
7174
7277
|
code: ".field.svelte-1maygd6 {margin:0;padding:0;border:0;display:flex;width:100%;flex-direction:var(--form-field-direction);gap:var(--form-field-gap);}.field.svelte-1maygd6 > dt:where(.svelte-1maygd6) {position:relative;font-weight:bold;font-size:var(--form-field-label-font-size);width:var(--form-field-label-width);flex-shrink:0;color:var(--form-field-label-color);display:inline-flex;gap:0.4em;}.field-required.svelte-1maygd6 {flex-shrink:0;font-size:0.6em;color:var(--danger-color);}.field.svelte-1maygd6 > dd:where(.svelte-1maygd6) {position:relative;margin:0;flex-grow:1;}.field-error.svelte-1maygd6 {position:absolute;top:calc(100% + 8px);left:0;display:inline-flex;color:var(--danger-color);border:1px solid var(--danger-color);border-radius:4px;background-color:#fff;padding:6px 12px;font-size:12px;margin:0;z-index:10;}.field-error.svelte-1maygd6::after {content:'';display:block;position:absolute;top:0;left:8px;width:8px;height:8px;transform:rotate(45deg) translateY(-80%);border-top:1px solid var(--danger-color);border-left:1px solid var(--danger-color);border-radius:1px;background-color:#fff;}"
|
7175
7278
|
};
|
7176
7279
|
function FormField($$anchor, $$props) {
|
7177
7280
|
$.push($$props, false);
|
7178
|
-
$.append_styles($$anchor, $$css$
|
7281
|
+
$.append_styles($$anchor, $$css$7);
|
7179
7282
|
const variables$1 = $.mutable_state();
|
7180
7283
|
const style = $.mutable_state();
|
7181
7284
|
let props = $.prop($$props, "props", 24, () => ({}));
|
7182
7285
|
let layerId = $.prop($$props, "layerId", 8, "");
|
7183
|
-
useInjectCustomizeCss(props());
|
7286
|
+
useInjectCustomizeCss(props(), layerId());
|
7184
7287
|
const { brandKit } = useBrandKit();
|
7185
7288
|
let registeredFieldName = $.mutable_state("");
|
7186
7289
|
let errorMessage = $.mutable_state(null);
|
@@ -7211,7 +7314,9 @@ function FormField($$anchor, $$props) {
|
|
7211
7314
|
type: props().fieldType,
|
7212
7315
|
name: props().fieldName,
|
7213
7316
|
defaultValue: props().defaultValue,
|
7214
|
-
required: props().required
|
7317
|
+
required: props().required,
|
7318
|
+
validations: props().validations,
|
7319
|
+
isIdentify: props().isIdentify
|
7215
7320
|
});
|
7216
7321
|
formStore.subscribe(($store) => {
|
7217
7322
|
$.set(errorMessage, $store.states[props().fieldName]?.errorMessage ?? null);
|
@@ -7224,48 +7329,42 @@ function FormField($$anchor, $$props) {
|
|
7224
7329
|
$.init();
|
7225
7330
|
var dl = root();
|
7226
7331
|
var node = $.child(dl);
|
7227
|
-
{
|
7228
|
-
var
|
7229
|
-
|
7230
|
-
|
7231
|
-
|
7232
|
-
|
7233
|
-
|
7234
|
-
|
7235
|
-
|
7236
|
-
var span_1 = root_2$3();
|
7237
|
-
$.append($$anchor$2, span_1);
|
7238
|
-
};
|
7239
|
-
$.if(node_1, ($$render) => {
|
7240
|
-
if (props().required) $$render(consequent);
|
7241
|
-
});
|
7242
|
-
}
|
7243
|
-
$.reset(dt);
|
7244
|
-
$.template_effect(() => $.set_text(text, props().label));
|
7245
|
-
$.append($$anchor$1, dt);
|
7332
|
+
var consequent_1 = ($$anchor$1) => {
|
7333
|
+
var dt = root_1$5();
|
7334
|
+
var span = $.child(dt);
|
7335
|
+
var text = $.child(span, true);
|
7336
|
+
$.reset(span);
|
7337
|
+
var node_1 = $.sibling(span, 2);
|
7338
|
+
var consequent = ($$anchor$2) => {
|
7339
|
+
var span_1 = root_2$3();
|
7340
|
+
$.append($$anchor$2, span_1);
|
7246
7341
|
};
|
7247
|
-
$.if(
|
7248
|
-
if (props().
|
7342
|
+
$.if(node_1, ($$render) => {
|
7343
|
+
if (props().required) $$render(consequent);
|
7249
7344
|
});
|
7250
|
-
|
7345
|
+
$.reset(dt);
|
7346
|
+
$.template_effect(() => $.set_text(text, props().label));
|
7347
|
+
$.append($$anchor$1, dt);
|
7348
|
+
};
|
7349
|
+
$.if(node, ($$render) => {
|
7350
|
+
if (props().label) $$render(consequent_1);
|
7351
|
+
});
|
7251
7352
|
var dd = $.sibling(node, 2);
|
7252
7353
|
var node_2 = $.child(dd);
|
7253
7354
|
$.slot(node_2, $$props, "default", { get "data-layer-id"() {
|
7254
7355
|
return layerId();
|
7255
7356
|
} }, null);
|
7256
7357
|
var node_3 = $.sibling(node_2, 2);
|
7257
|
-
{
|
7258
|
-
var
|
7259
|
-
|
7260
|
-
|
7261
|
-
|
7262
|
-
|
7263
|
-
|
7264
|
-
|
7265
|
-
|
7266
|
-
|
7267
|
-
});
|
7268
|
-
}
|
7358
|
+
var consequent_2 = ($$anchor$1) => {
|
7359
|
+
var p = root_3();
|
7360
|
+
var text_1 = $.child(p, true);
|
7361
|
+
$.reset(p);
|
7362
|
+
$.template_effect(() => $.set_text(text_1, $.get(errorMessage)));
|
7363
|
+
$.append($$anchor$1, p);
|
7364
|
+
};
|
7365
|
+
$.if(node_3, ($$render) => {
|
7366
|
+
if ($.get(isShowErrorMessage) && $.get(errorMessage)) $$render(consequent_2);
|
7367
|
+
});
|
7269
7368
|
$.reset(dd);
|
7270
7369
|
$.reset(dl);
|
7271
7370
|
$.template_effect(($0) => {
|
@@ -7285,13 +7384,13 @@ function FormField($$anchor, $$props) {
|
|
7285
7384
|
//#endregion
|
7286
7385
|
//#region src/components-flex/form/FormInput.svelte
|
7287
7386
|
var root_1$4 = $.template(`<input type="text">`);
|
7288
|
-
const $$css$
|
7387
|
+
const $$css$6 = {
|
7289
7388
|
hash: "svelte-176cxs0",
|
7290
7389
|
code: ".form-input.svelte-176cxs0 {margin:0;width:var(--form-input-width);-webkit-appearance:none;color:var(--font-color);transition:all 0.2s;}.form-input.small.svelte-176cxs0 {font-size:12px;line-height:19px;padding:6px 10px 5px;border-radius:4px;}.form-input.medium.svelte-176cxs0 {font-size:14px;line-height:21px;padding:8px 12px 7px;border-radius:6px;}.form-input.large.svelte-176cxs0 {font-size:16px;line-height:25px;padding:11px 16px 10px;border-radius:8px;}.form-input.outlined.svelte-176cxs0 {border:1px solid var(--border-color);}.form-input.filled.svelte-176cxs0 {background-color:var(--background-color);border:1px solid var(--background-color);}.form-input.underlined.svelte-176cxs0 {border-radius:0;border-width:0 0 1px;border-style:solid;border-color:rgba(255, 255, 255, 0) rgba(255, 255, 255, 0) var(--border-color);}.form-input.underlined.svelte-176cxs0:focus-visible {outline:0;border-bottom-color:1px solid var(--focused-outline-color);}.form-input.svelte-176cxs0:focus-visible {outline-color:var(--focused-outline-color);}.form-input.svelte-176cxs0::placeholder {color:var(--placeholder-color);}"
|
7291
7390
|
};
|
7292
7391
|
function FormInput($$anchor, $$props) {
|
7293
7392
|
$.push($$props, false);
|
7294
|
-
$.append_styles($$anchor, $$css$
|
7393
|
+
$.append_styles($$anchor, $$css$6);
|
7295
7394
|
const variant = $.mutable_state();
|
7296
7395
|
const size = $.mutable_state();
|
7297
7396
|
const variables$1 = $.mutable_state();
|
@@ -7300,7 +7399,7 @@ function FormInput($$anchor, $$props) {
|
|
7300
7399
|
let props = $.prop($$props, "props", 24, () => ({}));
|
7301
7400
|
let layerId = $.prop($$props, "layerId", 8, "");
|
7302
7401
|
const { brandKit } = useBrandKit();
|
7303
|
-
useInjectCustomizeCss(props());
|
7402
|
+
useInjectCustomizeCss(props(), layerId());
|
7304
7403
|
let value = $.mutable_state("");
|
7305
7404
|
const handleBlur = () => {
|
7306
7405
|
if (props().fieldName) {
|
@@ -7378,13 +7477,13 @@ function FormInput($$anchor, $$props) {
|
|
7378
7477
|
//#endregion
|
7379
7478
|
//#region src/components-flex/form/FormTextarea.svelte
|
7380
7479
|
var root_1$3 = $.template(`<textarea></textarea>`);
|
7381
|
-
const $$css$
|
7480
|
+
const $$css$5 = {
|
7382
7481
|
hash: "svelte-1oqg2c0",
|
7383
7482
|
code: ".form-textarea.svelte-1oqg2c0 {margin:0;width:var(--form-textarea-width);max-width:var(--form-textarea-width);min-width:var(--form-textarea-width);-webkit-appearance:none;vertical-align:bottom;color:var(--font-color);transition:all 0.2s;}.form-textarea.small.svelte-1oqg2c0 {font-size:12px;line-height:19px;padding:6px 10px 5px;border-radius:4px;}.form-textarea.medium.svelte-1oqg2c0 {font-size:14px;line-height:21px;padding:8px 12px 7px;border-radius:6px;}.form-textarea.large.svelte-1oqg2c0 {font-size:16px;line-height:25px;padding:11px 16px 10px;border-radius:8px;}.form-textarea.outlined.svelte-1oqg2c0 {border:1px solid var(--border-color);}.form-textarea.filled.svelte-1oqg2c0 {background-color:var(--background-color);border:1px solid var(--background-color);}.form-textarea.underlined.svelte-1oqg2c0 {border-radius:0;border-width:0 0 1px;border-style:solid;border-color:rgba(255, 255, 255, 0) rgba(255, 255, 255, 0) var(--border-color);}.form-textarea.underlined.svelte-1oqg2c0:focus-visible {outline:0;border-bottom-color:1px solid var(--focused-outline-color);}.form-textarea.svelte-1oqg2c0:focus-visible {outline-color:var(--focused-outline-color);}.form-textarea.svelte-1oqg2c0::placeholder {color:var(--placeholder-color);}"
|
7384
7483
|
};
|
7385
7484
|
function FormTextarea($$anchor, $$props) {
|
7386
7485
|
$.push($$props, false);
|
7387
|
-
$.append_styles($$anchor, $$css$
|
7486
|
+
$.append_styles($$anchor, $$css$5);
|
7388
7487
|
const variant = $.mutable_state();
|
7389
7488
|
const size = $.mutable_state();
|
7390
7489
|
const variables$1 = $.mutable_state();
|
@@ -7392,7 +7491,7 @@ function FormTextarea($$anchor, $$props) {
|
|
7392
7491
|
let props = $.prop($$props, "props", 24, () => ({}));
|
7393
7492
|
let layerId = $.prop($$props, "layerId", 8, "");
|
7394
7493
|
const { brandKit } = useBrandKit();
|
7395
|
-
useInjectCustomizeCss(props());
|
7494
|
+
useInjectCustomizeCss(props(), layerId());
|
7396
7495
|
let value = $.mutable_state("");
|
7397
7496
|
const handleBlur = () => {
|
7398
7497
|
if (props().fieldName) {
|
@@ -7464,13 +7563,13 @@ function FormTextarea($$anchor, $$props) {
|
|
7464
7563
|
//#region src/components-flex/form/FormSelect.svelte
|
7465
7564
|
var root_2$2 = $.template(`<option class="svelte-p118m"> </option>`);
|
7466
7565
|
var root_1$2 = $.template(`<div><select class="form-select-select svelte-p118m"><option disabled class="svelte-p118m"> </option><!></select></div>`);
|
7467
|
-
const $$css$
|
7566
|
+
const $$css$4 = {
|
7468
7567
|
hash: "svelte-p118m",
|
7469
7568
|
code: ".form-select.svelte-p118m {position:relative;display:inline-flex;width:var(--width);color:var(--font-color);}.form-select.empty.svelte-p118m select:where(.svelte-p118m) {color:var(--placeholder-color);}.form-select.svelte-p118m:after {content:'';display:block;position:absolute;top:50%;right:12px;width:6px;height:6px;border-bottom:1px solid var(--font-color);border-left:1px solid var(--font-color);transform:translateY(-75%) rotate(-45deg);}.form-select.svelte-p118m select:where(.svelte-p118m) {margin:0;width:100%;-webkit-appearance:none;transition:all 0.2s;}.form-select.small.svelte-p118m select:where(.svelte-p118m) {font-size:12px;line-height:19px;padding:6px 32px 5px 10px;border-radius:4px;}.form-select.medium.svelte-p118m select:where(.svelte-p118m) {font-size:14px;line-height:21px;padding:8px 36px 7px 12px;border-radius:6px;}.form-select.large.svelte-p118m select:where(.svelte-p118m) {font-size:16px;line-height:25px;padding:11px 40px 10px 16px;border-radius:8px;}.form-select.large.svelte-p118m:after {right:20px;}.form-select.outlined.svelte-p118m select:where(.svelte-p118m) {border:1px solid var(--border-color);}.form-select.filled.svelte-p118m select:where(.svelte-p118m) {background-color:var(--background-color);border:1px solid var(--background-color);}.form-select.underlined.svelte-p118m select:where(.svelte-p118m) {border-radius:0;border-width:0 0 1px;border-style:solid;border-color:rgba(255, 255, 255, 0) rgba(255, 255, 255, 0) var(--border-color);}.form-select.underlined.svelte-p118m select:where(.svelte-p118m):focus-visible {outline:0;border-bottom-color:1px solid var(--focused-outline-color);}.form-select.svelte-p118m select:where(.svelte-p118m):focus-visible {outline-color:var(--focused-outline-color);}.form-select.svelte-p118m select:where(.svelte-p118m) option:where(.svelte-p118m) {color:var(--font-color);}"
|
7470
7569
|
};
|
7471
7570
|
function FormSelect($$anchor, $$props) {
|
7472
7571
|
$.push($$props, false);
|
7473
|
-
$.append_styles($$anchor, $$css$
|
7572
|
+
$.append_styles($$anchor, $$css$4);
|
7474
7573
|
const variant = $.mutable_state();
|
7475
7574
|
const size = $.mutable_state();
|
7476
7575
|
const isEmpty$1 = $.mutable_state();
|
@@ -7479,7 +7578,7 @@ function FormSelect($$anchor, $$props) {
|
|
7479
7578
|
let props = $.prop($$props, "props", 24, () => ({}));
|
7480
7579
|
let layerId = $.prop($$props, "layerId", 8, "");
|
7481
7580
|
const { brandKit } = useBrandKit();
|
7482
|
-
useInjectCustomizeCss(props());
|
7581
|
+
useInjectCustomizeCss(props(), layerId());
|
7483
7582
|
let value = $.mutable_state("");
|
7484
7583
|
const handleChange = () => {
|
7485
7584
|
if (props().fieldName) {
|
@@ -7582,12 +7681,22 @@ const FORM_FIELD_LABEL_THEME = {
|
|
7582
7681
|
gray: "グレー",
|
7583
7682
|
brand: "ブランド"
|
7584
7683
|
};
|
7684
|
+
const FORM_IDENTIFY_FIELD_TYPE = {
|
7685
|
+
email: "メールアドレス",
|
7686
|
+
subscription: "メールマガジン登録",
|
7687
|
+
phone: "電話番号",
|
7688
|
+
phone_subscribe: "SMS配信許可",
|
7689
|
+
first_name: "名前(名)",
|
7690
|
+
last_name: "名前(姓)",
|
7691
|
+
address: "住所"
|
7692
|
+
};
|
7585
7693
|
const FORM_FIELD_TYPE = {
|
7586
7694
|
INPUT: "input",
|
7587
7695
|
SELECT: "select",
|
7588
7696
|
CHECKBOX: "checkbox",
|
7589
7697
|
CHECKBOXES: "checkboxes",
|
7590
7698
|
RADIOS: "radio",
|
7699
|
+
BOOLEAN: "boolean",
|
7591
7700
|
TEXTAREA: "textarea"
|
7592
7701
|
};
|
7593
7702
|
const FORM_FIELD_VARIANT = {
|
@@ -7615,13 +7724,13 @@ const FORM_INPUT_TYPE = {
|
|
7615
7724
|
//#region src/components-flex/form/FormCheckboxes.svelte
|
7616
7725
|
var root_2$1 = $.template(`<li><label class="form-checkbox svelte-rx48m9"><input type="checkbox" class="form-checkbox-input svelte-rx48m9"> <span class="form-checkbox-check svelte-rx48m9"><i class="form-checkbox-check-icon svelte-rx48m9"></i></span> <span class="form-checkbox-label svelte-rx48m9"> </span></label></li>`);
|
7617
7726
|
var root_1$1 = $.template(`<ul></ul>`);
|
7618
|
-
const $$css$
|
7727
|
+
const $$css$3 = {
|
7619
7728
|
hash: "svelte-rx48m9",
|
7620
7729
|
code: ".form-checkboxes.svelte-rx48m9 {position:relative;display:var(--checkboxes-display);flex-direction:var(--checkboxes-direction);flex-wrap:wrap;column-gap:var(--checkboxes-gap-x);row-gap:var(--checkboxes-gap-y);grid-template-columns:var(--checkboxes-grid-cols);width:100%;list-style:none;padding:2px 0;}.form-checkboxes.outlined.svelte-rx48m9 .form-checkbox-check:where(.svelte-rx48m9) {background-color:#fff;border:1px solid var(--border-color);}.form-checkboxes.filled.svelte-rx48m9 .form-checkbox-check:where(.svelte-rx48m9) {background-color:var(--background-color);border:1px solid var(--background-color);}.form-checkbox.svelte-rx48m9 {display:flex;align-items:center;gap:var(--checkbox-gap);cursor:pointer;}.form-checkbox-input.svelte-rx48m9 {appearance:none;margin:0;width:var(--checkbox-check-size);height:var(--checkbox-check-size);cursor:pointer;position:absolute;}.form-checkbox-check.svelte-rx48m9 {display:flex;align-items:center;justify-content:center;flex-shrink:0;width:var(--checkbox-check-size);height:var(--checkbox-check-size);border-radius:var(--checkbox-check-radius);transition:0.2s;}.form-checkbox-check-icon.svelte-rx48m9 {display:block;width:0.625em;height:0.375em;border-bottom:2px solid white;border-left:2px solid white;transform:translateY(-25%) rotate(-45deg);opacity:0;transition:0.2s;}.form-checkbox-label.svelte-rx48m9 {font-size:var(--checkbox-font-size);color:var(--font-color);white-space:nowrap;user-select:none;}.form-checkbox-input.svelte-rx48m9:checked ~ .form-checkbox-check:where(.svelte-rx48m9) {background-color:var(--accent-color);border-color:var(--accent-color);}.form-checkbox-input.svelte-rx48m9:checked ~ .form-checkbox-check:where(.svelte-rx48m9) .form-checkbox-check-icon:where(.svelte-rx48m9) {opacity:1;}"
|
7621
7730
|
};
|
7622
7731
|
function FormCheckboxes($$anchor, $$props) {
|
7623
7732
|
$.push($$props, false);
|
7624
|
-
$.append_styles($$anchor, $$css$
|
7733
|
+
$.append_styles($$anchor, $$css$3);
|
7625
7734
|
const variant = $.mutable_state();
|
7626
7735
|
const size = $.mutable_state();
|
7627
7736
|
const options = $.mutable_state();
|
@@ -7630,7 +7739,7 @@ function FormCheckboxes($$anchor, $$props) {
|
|
7630
7739
|
const binding_group = [];
|
7631
7740
|
let props = $.prop($$props, "props", 24, () => ({}));
|
7632
7741
|
let layerId = $.prop($$props, "layerId", 8, "");
|
7633
|
-
useInjectCustomizeCss(props());
|
7742
|
+
useInjectCustomizeCss(props(), layerId());
|
7634
7743
|
const { brandKit } = useBrandKit();
|
7635
7744
|
let values = $.mutable_state([]);
|
7636
7745
|
const handleChange = () => {
|
@@ -7671,7 +7780,7 @@ function FormCheckboxes($$anchor, $$props) {
|
|
7671
7780
|
})(),
|
7672
7781
|
"--checkbox-check-size": (() => {
|
7673
7782
|
if ($.get(size) === "small") return "14x";
|
7674
|
-
if ($.get(size) === "large") return "
|
7783
|
+
if ($.get(size) === "large") return "18px";
|
7675
7784
|
return "16px";
|
7676
7785
|
})(),
|
7677
7786
|
"--checkbox-check-radius": (() => {
|
@@ -7747,13 +7856,13 @@ function FormCheckboxes($$anchor, $$props) {
|
|
7747
7856
|
//#region src/components-flex/form/FormRadios.svelte
|
7748
7857
|
var root_2 = $.template(`<li><label class="form-radio svelte-ps4qqa"><input type="radio" class="form-radio-input svelte-ps4qqa"> <span class="form-radio-check svelte-ps4qqa"><i class="form-radio-check-icon svelte-ps4qqa"></i></span> <span class="form-radio-label svelte-ps4qqa"> </span></label></li>`);
|
7749
7858
|
var root_1 = $.template(`<ul></ul>`);
|
7750
|
-
const $$css = {
|
7859
|
+
const $$css$2 = {
|
7751
7860
|
hash: "svelte-ps4qqa",
|
7752
7861
|
code: ".form-radios.svelte-ps4qqa {position:relative;display:var(--radios-display);flex-direction:var(--radios-direction);flex-wrap:wrap;column-gap:var(--radios-gap-x);row-gap:var(--radios-gap-y);grid-template-columns:var(--radios-grid-cols);width:100%;list-style:none;padding:2px 0;}.form-radios.outlined.svelte-ps4qqa .form-radio-check:where(.svelte-ps4qqa) {background-color:#fff;border:1px solid var(--border-color);}.form-radios.filled.svelte-ps4qqa .form-radio-check:where(.svelte-ps4qqa) {background-color:var(--background-color);border:1px solid var(--background-color);}.form-radio.svelte-ps4qqa {display:flex;align-items:center;gap:var(--radio-gap);cursor:pointer;}.form-radio-input.svelte-ps4qqa {appearance:none;width:var(--radio-check-size);height:var(--radio-check-size);margin:0;cursor:pointer;position:absolute;}.form-radio-check.svelte-ps4qqa {display:flex;align-items:center;justify-content:center;flex-shrink:0;width:var(--radio-check-size);height:var(--radio-check-size);border-radius:100%;transition:0.2s;}.form-radio-check-icon.svelte-ps4qqa {display:block;width:var(--radio-check-icon-size);height:var(--radio-check-icon-size);border-radius:100%;background-color:var(--accent-color);opacity:0;transition:0.2s;}.form-radio-label.svelte-ps4qqa {font-size:var(--radio-font-size);color:var(--font-color);white-space:nowrap;user-select:none;}.form-radio-input.svelte-ps4qqa:checked ~ .form-radio-check:where(.svelte-ps4qqa) {border-color:var(--accent-color);}.form-radio-input.svelte-ps4qqa:checked ~ .form-radio-check:where(.svelte-ps4qqa) .form-radio-check-icon:where(.svelte-ps4qqa) {opacity:1;}"
|
7753
7862
|
};
|
7754
7863
|
function FormRadios($$anchor, $$props) {
|
7755
7864
|
$.push($$props, false);
|
7756
|
-
$.append_styles($$anchor, $$css);
|
7865
|
+
$.append_styles($$anchor, $$css$2);
|
7757
7866
|
const variant = $.mutable_state();
|
7758
7867
|
const size = $.mutable_state();
|
7759
7868
|
const options = $.mutable_state();
|
@@ -7762,7 +7871,7 @@ function FormRadios($$anchor, $$props) {
|
|
7762
7871
|
const binding_group = [];
|
7763
7872
|
let props = $.prop($$props, "props", 24, () => ({}));
|
7764
7873
|
let layerId = $.prop($$props, "layerId", 8, "");
|
7765
|
-
useInjectCustomizeCss(props());
|
7874
|
+
useInjectCustomizeCss(props(), layerId());
|
7766
7875
|
const { brandKit } = useBrandKit();
|
7767
7876
|
let value = $.mutable_state("");
|
7768
7877
|
const handleChange = () => {
|
@@ -7880,6 +7989,124 @@ function FormRadios($$anchor, $$props) {
|
|
7880
7989
|
$.pop();
|
7881
7990
|
}
|
7882
7991
|
|
7992
|
+
//#endregion
|
7993
|
+
//#region src/components-flex/form/FormBoolean.svelte
|
7994
|
+
const $$css$1 = {
|
7995
|
+
hash: "svelte-3kpd",
|
7996
|
+
code: ""
|
7997
|
+
};
|
7998
|
+
function FormBoolean($$anchor, $$props) {
|
7999
|
+
$.append_styles($$anchor, $$css$1);
|
8000
|
+
let props = $.prop($$props, "props", 24, () => ({}));
|
8001
|
+
let layerId = $.prop($$props, "layerId", 8, "");
|
8002
|
+
FormRadios($$anchor, {
|
8003
|
+
get layerId() {
|
8004
|
+
return layerId();
|
8005
|
+
},
|
8006
|
+
get props() {
|
8007
|
+
return props();
|
8008
|
+
}
|
8009
|
+
});
|
8010
|
+
}
|
8011
|
+
|
8012
|
+
//#endregion
|
8013
|
+
//#region src/components-flex/form/FormIdentifyField.svelte
|
8014
|
+
const $$css = {
|
8015
|
+
hash: "svelte-3kpd",
|
8016
|
+
code: ""
|
8017
|
+
};
|
8018
|
+
function FormIdentifyField($$anchor, $$props) {
|
8019
|
+
$.push($$props, false);
|
8020
|
+
$.append_styles($$anchor, $$css);
|
8021
|
+
const fieldType = $.mutable_state();
|
8022
|
+
const fieldProps = $.mutable_state();
|
8023
|
+
const inputProps = $.mutable_state();
|
8024
|
+
const booleanProps = $.mutable_state();
|
8025
|
+
let props = $.prop($$props, "props", 24, () => ({}));
|
8026
|
+
let layerId = $.prop($$props, "layerId", 8, "");
|
8027
|
+
useInjectCustomizeCss(props(), layerId());
|
8028
|
+
const identifyType = props().identifyType ?? "email";
|
8029
|
+
$.legacy_pre_effect(() => {}, () => {
|
8030
|
+
$.set(fieldType, (() => {
|
8031
|
+
switch (identifyType) {
|
8032
|
+
case "phone_subscribe":
|
8033
|
+
case "subscription": return "boolean";
|
8034
|
+
case "address":
|
8035
|
+
case "first_name":
|
8036
|
+
case "last_name":
|
8037
|
+
case "email":
|
8038
|
+
case "phone":
|
8039
|
+
default: return "input";
|
8040
|
+
}
|
8041
|
+
})());
|
8042
|
+
});
|
8043
|
+
$.legacy_pre_effect(() => ($.deep_read_state(props()), $.get(fieldType)), () => {
|
8044
|
+
$.set(fieldProps, (() => {
|
8045
|
+
return {
|
8046
|
+
...props(),
|
8047
|
+
fieldType: $.get(fieldType),
|
8048
|
+
fieldName: identifyType,
|
8049
|
+
isIdentify: true
|
8050
|
+
};
|
8051
|
+
})());
|
8052
|
+
});
|
8053
|
+
$.legacy_pre_effect(() => ($.get(fieldType), $.get(fieldProps), $.deep_read_state(props())), () => {
|
8054
|
+
$.set(inputProps, (() => {
|
8055
|
+
if ($.get(fieldType) !== "input") return null;
|
8056
|
+
return {
|
8057
|
+
...$.get(fieldProps),
|
8058
|
+
...props().inputProps ?? {}
|
8059
|
+
};
|
8060
|
+
})());
|
8061
|
+
});
|
8062
|
+
$.legacy_pre_effect(() => ($.get(fieldType), $.get(fieldProps), $.deep_read_state(props())), () => {
|
8063
|
+
$.set(booleanProps, (() => {
|
8064
|
+
if ($.get(fieldType) !== "boolean") return null;
|
8065
|
+
return {
|
8066
|
+
...$.get(fieldProps),
|
8067
|
+
...props().checkerProps ?? {}
|
8068
|
+
};
|
8069
|
+
})());
|
8070
|
+
});
|
8071
|
+
$.legacy_pre_effect_reset();
|
8072
|
+
$.init();
|
8073
|
+
var fragment = $.comment();
|
8074
|
+
var node = $.first_child(fragment);
|
8075
|
+
var consequent = ($$anchor$1) => {
|
8076
|
+
FormInput($$anchor$1, {
|
8077
|
+
get layerId() {
|
8078
|
+
return layerId();
|
8079
|
+
},
|
8080
|
+
get props() {
|
8081
|
+
return $.get(inputProps);
|
8082
|
+
}
|
8083
|
+
});
|
8084
|
+
};
|
8085
|
+
var alternate = ($$anchor$1, $$elseif) => {
|
8086
|
+
var consequent_1 = ($$anchor$2) => {
|
8087
|
+
FormBoolean($$anchor$2, {
|
8088
|
+
get layerId() {
|
8089
|
+
return layerId();
|
8090
|
+
},
|
8091
|
+
get props() {
|
8092
|
+
return $.get(booleanProps);
|
8093
|
+
}
|
8094
|
+
});
|
8095
|
+
};
|
8096
|
+
var alternate_1 = ($$anchor$2) => {};
|
8097
|
+
$.if($$anchor$1, ($$render) => {
|
8098
|
+
if ($.get(booleanProps)) $$render(consequent_1);
|
8099
|
+
else $$render(alternate_1, false);
|
8100
|
+
}, $$elseif);
|
8101
|
+
};
|
8102
|
+
$.if(node, ($$render) => {
|
8103
|
+
if ($.get(inputProps)) $$render(consequent);
|
8104
|
+
else $$render(alternate, false);
|
8105
|
+
});
|
8106
|
+
$.append($$anchor, fragment);
|
8107
|
+
$.pop();
|
8108
|
+
}
|
8109
|
+
|
7883
8110
|
//#endregion
|
7884
8111
|
//#region src/components-flex/shared/styles.ts
|
7885
8112
|
const ROUND_STYLES = {
|
@@ -8152,7 +8379,11 @@ __export(index_svelte5_exports, {
|
|
8152
8379
|
FORM_FIELD_TYPE: () => FORM_FIELD_TYPE,
|
8153
8380
|
FORM_FIELD_VARIANT: () => FORM_FIELD_VARIANT,
|
8154
8381
|
FORM_FIELD_VARIANT_FOR_CHECKER: () => FORM_FIELD_VARIANT_FOR_CHECKER,
|
8382
|
+
FORM_IDENTIFY_FIELD_TYPE: () => FORM_IDENTIFY_FIELD_TYPE,
|
8155
8383
|
FORM_INPUT_TYPE: () => FORM_INPUT_TYPE,
|
8384
|
+
FORM_VALIDATION_DEFAULT_ERROR_MESSAGES: () => FORM_VALIDATION_DEFAULT_ERROR_MESSAGES,
|
8385
|
+
FORM_VALIDATION_REGEX: () => FORM_VALIDATION_REGEX,
|
8386
|
+
FORM_VALIDATION_TYPE: () => FORM_VALIDATION_TYPE,
|
8156
8387
|
FlexAvatar: () => Avatar,
|
8157
8388
|
FlexButton: () => Button,
|
8158
8389
|
FlexButtonOutlined: () => ButtonOutlined,
|
@@ -8165,8 +8396,10 @@ __export(index_svelte5_exports, {
|
|
8165
8396
|
FlexDirections: () => FlexDirections,
|
8166
8397
|
FlexEmbed: () => Embed,
|
8167
8398
|
FlexForm: () => Form,
|
8399
|
+
FlexFormBoolean: () => FormBoolean,
|
8168
8400
|
FlexFormCheckboxes: () => FormCheckboxes,
|
8169
8401
|
FlexFormField: () => FormField,
|
8402
|
+
FlexFormIdentifyField: () => FormIdentifyField,
|
8170
8403
|
FlexFormInput: () => FormInput,
|
8171
8404
|
FlexFormRadios: () => FormRadios,
|
8172
8405
|
FlexFormSelect: () => FormSelect,
|
@@ -8257,6 +8490,7 @@ __export(index_svelte5_exports, {
|
|
8257
8490
|
flexComponentSchemes: () => flexComponentSchemes,
|
8258
8491
|
formData: () => formData,
|
8259
8492
|
formStore: () => formStore,
|
8493
|
+
formSubmittedIdentifyValues: () => formSubmittedIdentifyValues,
|
8260
8494
|
formSubmittedValues: () => formSubmittedValues,
|
8261
8495
|
getActionRoot: () => getActionRoot,
|
8262
8496
|
getAnsweredQuestion: () => getAnsweredQuestion,
|
@@ -8348,48 +8582,44 @@ function ThumbnailPreview($$anchor, $$props) {
|
|
8348
8582
|
$.init();
|
8349
8583
|
var fragment = $.comment();
|
8350
8584
|
var node = $.first_child(fragment);
|
8351
|
-
{
|
8352
|
-
var
|
8353
|
-
|
8354
|
-
|
8355
|
-
|
8356
|
-
|
8357
|
-
|
8358
|
-
get
|
8359
|
-
|
8360
|
-
|
8361
|
-
|
8362
|
-
|
8363
|
-
|
8364
|
-
|
8365
|
-
|
8366
|
-
|
8367
|
-
|
8368
|
-
|
8369
|
-
|
8370
|
-
|
8371
|
-
|
8372
|
-
|
8373
|
-
|
8374
|
-
|
8375
|
-
|
8376
|
-
|
8377
|
-
|
8378
|
-
|
8379
|
-
|
8380
|
-
|
8381
|
-
|
8382
|
-
$.append($$anchor$3, fragment_2);
|
8383
|
-
},
|
8384
|
-
$$slots: { default: true }
|
8385
|
-
});
|
8585
|
+
var consequent_1 = ($$anchor$1) => {
|
8586
|
+
var fragment_1 = $.comment();
|
8587
|
+
var node_1 = $.first_child(fragment_1);
|
8588
|
+
const expression = $.derived_safe_equal(() => "previewProps" in option() && typeof option().previewProps !== "undefined" ? option().previewProps : option().props);
|
8589
|
+
$.component(node_1, () => $.get(component), ($$anchor$2, $$component) => {
|
8590
|
+
$$component($$anchor$2, {
|
8591
|
+
get props() {
|
8592
|
+
return $.get(expression);
|
8593
|
+
},
|
8594
|
+
children: ($$anchor$3, $$slotProps) => {
|
8595
|
+
var fragment_2 = $.comment();
|
8596
|
+
var node_2 = $.first_child(fragment_2);
|
8597
|
+
var consequent = ($$anchor$4) => {
|
8598
|
+
var fragment_3 = $.comment();
|
8599
|
+
var node_3 = $.first_child(fragment_3);
|
8600
|
+
$.each(node_3, 1, () => option().children, $.index, ($$anchor$5, child) => {
|
8601
|
+
var fragment_4 = $.comment();
|
8602
|
+
var node_4 = $.first_child(fragment_4);
|
8603
|
+
ThumbnailPreview(node_4, { get option() {
|
8604
|
+
return $.get(child);
|
8605
|
+
} });
|
8606
|
+
$.append($$anchor$5, fragment_4);
|
8607
|
+
});
|
8608
|
+
$.append($$anchor$4, fragment_3);
|
8609
|
+
};
|
8610
|
+
$.if(node_2, ($$render) => {
|
8611
|
+
if (option().children) $$render(consequent);
|
8612
|
+
});
|
8613
|
+
$.append($$anchor$3, fragment_2);
|
8614
|
+
},
|
8615
|
+
$$slots: { default: true }
|
8386
8616
|
});
|
8387
|
-
$.append($$anchor$1, fragment_1);
|
8388
|
-
};
|
8389
|
-
$.if(node, ($$render) => {
|
8390
|
-
if ($.get(component)) $$render(consequent_1);
|
8391
8617
|
});
|
8392
|
-
|
8618
|
+
$.append($$anchor$1, fragment_1);
|
8619
|
+
};
|
8620
|
+
$.if(node, ($$render) => {
|
8621
|
+
if ($.get(component)) $$render(consequent_1);
|
8622
|
+
});
|
8393
8623
|
$.append($$anchor, fragment);
|
8394
8624
|
$.pop();
|
8395
8625
|
}
|