@getmicdrop/svelte-components 2.4.0 → 2.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/__LIB_STORES__.js +2 -30
- package/dist/components/Badges/Badge.svelte +3 -129
- package/dist/components/Badges/Badge.svelte.d.ts +2 -8
- package/dist/components/Badges/Badge.svelte.d.ts.map +1 -1
- package/dist/components/Breadcrumb/Breadcrumb.svelte +36 -65
- package/dist/components/Breadcrumb/Breadcrumb.svelte.d.ts +2 -16
- package/dist/components/Breadcrumb/Breadcrumb.svelte.d.ts.map +1 -1
- package/dist/components/Button/Button.svelte +0 -1
- package/dist/components/Calendar/Calendar.spec.d.ts +2 -0
- package/dist/components/Calendar/Calendar.spec.d.ts.map +1 -0
- package/dist/components/Calendar/Calendar.spec.js +131 -0
- package/dist/components/Calendar/Calendar.svelte +1115 -0
- package/dist/components/Calendar/{MiniMonthCalendar.svelte.d.ts → Calendar.svelte.d.ts} +21 -20
- package/dist/components/{Checkbox/Checkbox.svelte.d.ts.map → Calendar/Calendar.svelte.d.ts.map} +1 -1
- package/dist/components/Calendar/QuarterView.spec.d.ts +2 -0
- package/dist/components/Calendar/QuarterView.spec.d.ts.map +1 -0
- package/dist/components/Calendar/QuarterView.spec.js +394 -0
- package/dist/components/Calendar/QuarterView.stories.svelte +134 -0
- package/dist/components/{PublicCard/PublicCard.svelte.d.ts → Calendar/QuarterView.stories.svelte.d.ts} +21 -15
- package/dist/components/Calendar/QuarterView.stories.svelte.d.ts.map +1 -0
- package/dist/components/Calendar/QuarterView.svelte +736 -0
- package/dist/components/{FAQs/FAQs.svelte.d.ts → Calendar/QuarterView.svelte.d.ts} +10 -10
- package/dist/components/{Skeleton/Skeleton.svelte.d.ts.map → Calendar/QuarterView.svelte.d.ts.map} +1 -1
- package/dist/components/DarkModeToggle.svelte +0 -2
- package/dist/components/DarkModeToggle.svelte.d.ts.map +1 -1
- package/dist/components/Input/Input.svelte +12 -100
- package/dist/components/Input/Input.svelte.d.ts +6 -18
- package/dist/components/Input/Input.svelte.d.ts.map +1 -1
- package/dist/components/Input/MultiSelect.svelte +5 -4
- package/dist/components/Input/MultiSelect.svelte.d.ts +6 -6
- package/dist/components/Input/MultiSelect.svelte.d.ts.map +1 -1
- package/dist/components/Input/OTPInput.svelte +1 -1
- package/dist/components/Input/Select.svelte +5 -4
- package/dist/components/Input/Select.svelte.d.ts +6 -6
- package/dist/components/Input/Select.svelte.d.ts.map +1 -1
- package/dist/components/Layout/Header.svelte +4 -14
- package/dist/components/Modal/ConfirmationModal.svelte +17 -69
- package/dist/components/Modal/ConfirmationModal.svelte.d.ts +0 -22
- package/dist/components/Modal/ConfirmationModal.svelte.d.ts.map +1 -1
- package/dist/components/Modal/Modal.svelte +8 -34
- package/dist/components/Modal/Modal.svelte.d.ts +0 -2
- package/dist/components/Modal/Modal.svelte.d.ts.map +1 -1
- package/dist/components/PasswordStrengthIndicator/PasswordStrengthIndicator.svelte.d.ts +2 -2
- package/dist/components/Spinner/Spinner.svelte +17 -73
- package/dist/components/Spinner/Spinner.svelte.d.ts +3 -5
- package/dist/components/Spinner/Spinner.svelte.d.ts.map +1 -1
- package/dist/components/pages/performers/AvailabilityCalendarModal.svelte +632 -0
- package/dist/components/{ShowTimeCard/ShowTimeCard.svelte.d.ts → pages/performers/AvailabilityCalendarModal.svelte.d.ts} +14 -14
- package/dist/components/pages/performers/AvailabilityCalendarModal.svelte.d.ts.map +1 -0
- package/dist/components/pages/performers/ShowDetails.svelte.d.ts +2 -2
- package/dist/components/pages/performers/ShowItemCard.svelte.d.ts +8 -8
- package/dist/components/pages/performers/SwitchOption.svelte.d.ts +2 -2
- package/dist/components/pages/performers/VenueInfo.svelte.d.ts +2 -2
- package/dist/components/pages/performers/VenueItemCard.svelte +2 -2
- package/dist/components/pages/performers/VenueItemCard.svelte.d.ts +4 -4
- package/dist/components/pages/profile/profile-form.svelte +1 -1
- package/dist/components/pages/shows/TabNavigation.svelte +8 -7
- package/dist/constants/formOptions.d.ts +2 -5
- package/dist/constants/formOptions.d.ts.map +1 -1
- package/dist/constants/formOptions.js +1 -2
- package/dist/index.d.ts +4 -24
- package/dist/index.js +4 -30
- package/dist/services/EventService.js +75 -75
- package/dist/services/EventService.spec.js +217 -217
- package/dist/services/ShowService.spec.js +342 -342
- package/package.json +160 -160
- package/dist/components/AboutShow/AboutShow.svelte +0 -278
- package/dist/components/AboutShow/AboutShow.svelte.d.ts +0 -43
- package/dist/components/AboutShow/AboutShow.svelte.d.ts.map +0 -1
- package/dist/components/Accordion/Accordion.svelte +0 -44
- package/dist/components/Accordion/Accordion.svelte.d.ts +0 -42
- package/dist/components/Accordion/Accordion.svelte.d.ts.map +0 -1
- package/dist/components/Accordion/AccordionItem.svelte +0 -141
- package/dist/components/Accordion/AccordionItem.svelte.d.ts +0 -50
- package/dist/components/Accordion/AccordionItem.svelte.d.ts.map +0 -1
- package/dist/components/Calendar/MiniMonthCalendar.svelte +0 -1446
- package/dist/components/Calendar/MiniMonthCalendar.svelte.d.ts.map +0 -1
- package/dist/components/Checkbox/Checkbox.svelte +0 -116
- package/dist/components/Checkbox/Checkbox.svelte.d.ts +0 -52
- package/dist/components/Drawer/Drawer.svelte +0 -207
- package/dist/components/Drawer/Drawer.svelte.d.ts +0 -74
- package/dist/components/Drawer/Drawer.svelte.d.ts.map +0 -1
- package/dist/components/Dropdown/Dropdown.svelte +0 -129
- package/dist/components/Dropdown/Dropdown.svelte.d.ts +0 -48
- package/dist/components/Dropdown/Dropdown.svelte.d.ts.map +0 -1
- package/dist/components/Dropdown/DropdownItem.svelte +0 -111
- package/dist/components/Dropdown/DropdownItem.svelte.d.ts +0 -48
- package/dist/components/Dropdown/DropdownItem.svelte.d.ts.map +0 -1
- package/dist/components/FAQs/FAQs.svelte +0 -49
- package/dist/components/FAQs/FAQs.svelte.d.ts.map +0 -1
- package/dist/components/Input/Search.svelte +0 -173
- package/dist/components/Input/Search.svelte.d.ts +0 -68
- package/dist/components/Input/Search.svelte.d.ts.map +0 -1
- package/dist/components/Input/Textarea.svelte +0 -160
- package/dist/components/Input/Textarea.svelte.d.ts +0 -69
- package/dist/components/Input/Textarea.svelte.d.ts.map +0 -1
- package/dist/components/Label/Label.svelte +0 -60
- package/dist/components/Label/Label.svelte.d.ts +0 -48
- package/dist/components/Label/Label.svelte.d.ts.map +0 -1
- package/dist/components/Modal/InputModal.svelte +0 -180
- package/dist/components/Modal/InputModal.svelte.d.ts +0 -77
- package/dist/components/Modal/InputModal.svelte.d.ts.map +0 -1
- package/dist/components/Modal/StatusModal.svelte +0 -221
- package/dist/components/Modal/StatusModal.svelte.d.ts +0 -59
- package/dist/components/Modal/StatusModal.svelte.d.ts.map +0 -1
- package/dist/components/MonthSwitcher/MonthSwitcher.svelte +0 -206
- package/dist/components/MonthSwitcher/MonthSwitcher.svelte.d.ts +0 -37
- package/dist/components/MonthSwitcher/MonthSwitcher.svelte.d.ts.map +0 -1
- package/dist/components/OrderSummary/OrderSummary.svelte +0 -553
- package/dist/components/OrderSummary/OrderSummary.svelte.d.ts +0 -65
- package/dist/components/OrderSummary/OrderSummary.svelte.d.ts.map +0 -1
- package/dist/components/Pagination/Pagination.svelte +0 -197
- package/dist/components/Pagination/Pagination.svelte.d.ts +0 -53
- package/dist/components/Pagination/Pagination.svelte.d.ts.map +0 -1
- package/dist/components/PublicCard/PublicCard.svelte +0 -267
- package/dist/components/PublicCard/PublicCard.svelte.d.ts.map +0 -1
- package/dist/components/Radio/Radio.svelte +0 -119
- package/dist/components/Radio/Radio.svelte.d.ts +0 -54
- package/dist/components/Radio/Radio.svelte.d.ts.map +0 -1
- package/dist/components/ShowCard/ShowCard.svelte +0 -240
- package/dist/components/ShowCard/ShowCard.svelte.d.ts +0 -39
- package/dist/components/ShowCard/ShowCard.svelte.d.ts.map +0 -1
- package/dist/components/ShowTimeCard/ShowTimeCard.svelte +0 -92
- package/dist/components/ShowTimeCard/ShowTimeCard.svelte.d.ts.map +0 -1
- package/dist/components/Skeleton/Skeleton.svelte +0 -68
- package/dist/components/Skeleton/Skeleton.svelte.d.ts +0 -37
- package/dist/components/Tabs/TabItem.svelte +0 -39
- package/dist/components/Tabs/TabItem.svelte.d.ts +0 -52
- package/dist/components/Tabs/TabItem.svelte.d.ts.map +0 -1
- package/dist/components/Tabs/Tabs.svelte +0 -181
- package/dist/components/Tabs/Tabs.svelte.d.ts +0 -46
- package/dist/components/Tabs/Tabs.svelte.d.ts.map +0 -1
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
export default
|
|
2
|
-
type
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
export default QuarterView;
|
|
2
|
+
type QuarterView = SvelteComponent<{
|
|
3
|
+
selectedDates: any;
|
|
4
|
+
saveStatus?: string | undefined;
|
|
5
|
+
currentevents?: any[] | undefined;
|
|
6
6
|
}, {
|
|
7
7
|
[evt: string]: CustomEvent<any>;
|
|
8
8
|
}, {}> & {
|
|
9
9
|
$$bindings?: string | undefined;
|
|
10
10
|
};
|
|
11
|
-
declare const
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
11
|
+
declare const QuarterView: $$__sveltets_2_IsomorphicComponent<{
|
|
12
|
+
selectedDates: any;
|
|
13
|
+
saveStatus?: string | undefined;
|
|
14
|
+
currentevents?: any[] | undefined;
|
|
15
15
|
}, {
|
|
16
16
|
[evt: string]: CustomEvent<any>;
|
|
17
17
|
}, {}, {}, string>;
|
|
@@ -28,4 +28,4 @@ interface $$__sveltets_2_IsomorphicComponent<Props extends Record<string, any> =
|
|
|
28
28
|
};
|
|
29
29
|
z_$$bindings?: Bindings;
|
|
30
30
|
}
|
|
31
|
-
//# sourceMappingURL=
|
|
31
|
+
//# sourceMappingURL=QuarterView.svelte.d.ts.map
|
package/dist/components/{Skeleton/Skeleton.svelte.d.ts.map → Calendar/QuarterView.svelte.d.ts.map}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"
|
|
1
|
+
{"version":3,"file":"QuarterView.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/components/Calendar/QuarterView.svelte.js"],"names":[],"mappings":";;;;;;;;;;AAsYA;;;;;;mBAAuJ;6CAT1G,KAAK,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,QAAQ,MAAM,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,QAAQ,KAAK,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,QAAQ,OAAO,OAAO,QAAQ;IAC3L,cAAc,OAAO,QAAQ,EAAE,2BAA2B,CAAC,KAAK,CAAC,GAAG,OAAO,QAAQ,EAAE,eAAe,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,CAAC,GAAG;QAAE,UAAU,CAAC,EAAE,QAAQ,CAAA;KAAE,GAAG,OAAO,CAAC;IACjK,WAAW,OAAO,SAAS,KAAK,GAAG;QAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;QAAC,OAAO,CAAC,EAAE,KAAK,CAAA;KAAC,GAAG,OAAO,GAAG;QAAE,IAAI,CAAC,EAAE,GAAG,CAAC;QAAC,GAAG,CAAC,EAAE,GAAG,CAAA;KAAE,CAAC;IAC9G,eAAe,QAAQ,CAAC"}
|
|
@@ -11,7 +11,6 @@
|
|
|
11
11
|
let themeMode = 'auto';
|
|
12
12
|
let isDark = false; // Current display state (for applying classes)
|
|
13
13
|
|
|
14
|
-
/** @param {boolean} enable */
|
|
15
14
|
function setMicdropDarkClass(enable) {
|
|
16
15
|
// Support both performers portal and micdrop frontend
|
|
17
16
|
const container = document.querySelector(containerSelector);
|
|
@@ -64,7 +63,6 @@
|
|
|
64
63
|
};
|
|
65
64
|
});
|
|
66
65
|
|
|
67
|
-
/** @param {MouseEvent} event */
|
|
68
66
|
function toggleTheme(event) {
|
|
69
67
|
// Cycle: auto -> light -> dark -> auto
|
|
70
68
|
if (themeMode === 'auto') {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DarkModeToggle.svelte.d.ts","sourceRoot":"","sources":["../../src/lib/components/DarkModeToggle.svelte.js"],"names":[],"mappings":";;;;;;;;;
|
|
1
|
+
{"version":3,"file":"DarkModeToggle.svelte.d.ts","sourceRoot":"","sources":["../../src/lib/components/DarkModeToggle.svelte.js"],"names":[],"mappings":";;;;;;;;;AAqJA;;;;;mBAA8J;6CATjH,KAAK,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,QAAQ,MAAM,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,QAAQ,KAAK,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,QAAQ,OAAO,OAAO,QAAQ;IAC3L,cAAc,OAAO,QAAQ,EAAE,2BAA2B,CAAC,KAAK,CAAC,GAAG,OAAO,QAAQ,EAAE,eAAe,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,CAAC,GAAG;QAAE,UAAU,CAAC,EAAE,QAAQ,CAAA;KAAE,GAAG,OAAO,CAAC;IACjK,WAAW,OAAO,SAAS,KAAK,GAAG;QAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;QAAC,OAAO,CAAC,EAAE,KAAK,CAAA;KAAC,GAAG,OAAO,GAAG;QAAE,IAAI,CAAC,EAAE,GAAG,CAAC;QAAC,GAAG,CAAC,EAAE,GAAG,CAAA;KAAE,CAAC;IAC9G,eAAe,QAAQ,CAAC"}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
<script>
|
|
2
2
|
import { slide } from "svelte/transition";
|
|
3
3
|
import { cubicOut } from "svelte/easing";
|
|
4
|
-
import { createEventDispatcher, onDestroy } from "svelte";
|
|
5
4
|
import WarningIcon from "../Icons/WarningIcon.svelte";
|
|
6
5
|
|
|
7
6
|
export let required = false;
|
|
@@ -42,16 +41,8 @@
|
|
|
42
41
|
export let showErrors = false; // Show errors immediately (bypass touched requirement)
|
|
43
42
|
export let disableBuiltInValidation = false; // When true, disables the built-in blur validation (use for custom validation)
|
|
44
43
|
|
|
45
|
-
// Instant search props
|
|
46
|
-
export let instantSearch = false; // Enable search-as-you-type with debouncing
|
|
47
|
-
export let debounceMs = 250; // Debounce delay for instant search
|
|
48
|
-
export let minSearchChars = 2; // Minimum characters before search triggers
|
|
49
|
-
export let showClearButton = false; // Show clear (X) button when input has value
|
|
50
|
-
|
|
51
44
|
let inputValue = value;
|
|
52
45
|
let inputElement;
|
|
53
|
-
let debounceTimer;
|
|
54
|
-
const dispatch = createEventDispatcher();
|
|
55
46
|
|
|
56
47
|
// Derive inputmode from type if not explicitly set
|
|
57
48
|
$: computedInputmode = inputmode || getInputmodeFromType(type);
|
|
@@ -172,56 +163,8 @@
|
|
|
172
163
|
|
|
173
164
|
// Update exported value for parent bind:value
|
|
174
165
|
value = inputValue;
|
|
175
|
-
|
|
176
|
-
// Instant search functionality
|
|
177
|
-
if (instantSearch) {
|
|
178
|
-
clearTimeout(debounceTimer);
|
|
179
|
-
|
|
180
|
-
// Dispatch immediately if cleared
|
|
181
|
-
if (inputValue.length === 0) {
|
|
182
|
-
dispatch('search', { query: '' });
|
|
183
|
-
return;
|
|
184
|
-
}
|
|
185
|
-
|
|
186
|
-
// Only search if we have enough characters
|
|
187
|
-
if (inputValue.length >= minSearchChars) {
|
|
188
|
-
debounceTimer = setTimeout(() => {
|
|
189
|
-
dispatch('search', { query: inputValue });
|
|
190
|
-
}, debounceMs);
|
|
191
|
-
}
|
|
192
|
-
}
|
|
193
166
|
};
|
|
194
167
|
|
|
195
|
-
// Clear input (for instant search clear button)
|
|
196
|
-
function clearInput() {
|
|
197
|
-
inputValue = '';
|
|
198
|
-
value = '';
|
|
199
|
-
clearTimeout(debounceTimer);
|
|
200
|
-
if (instantSearch) {
|
|
201
|
-
dispatch('search', { query: '' });
|
|
202
|
-
}
|
|
203
|
-
if (inputElement) {
|
|
204
|
-
inputElement.focus();
|
|
205
|
-
}
|
|
206
|
-
}
|
|
207
|
-
|
|
208
|
-
// Handle keyboard shortcuts for instant search
|
|
209
|
-
function handleSearchKeyDown(event) {
|
|
210
|
-
if (instantSearch) {
|
|
211
|
-
if (event.key === 'Enter') {
|
|
212
|
-
clearTimeout(debounceTimer);
|
|
213
|
-
dispatch('search', { query: inputValue });
|
|
214
|
-
}
|
|
215
|
-
if (event.key === 'Escape') {
|
|
216
|
-
clearInput();
|
|
217
|
-
}
|
|
218
|
-
}
|
|
219
|
-
}
|
|
220
|
-
|
|
221
|
-
onDestroy(() => {
|
|
222
|
-
clearTimeout(debounceTimer);
|
|
223
|
-
});
|
|
224
|
-
|
|
225
168
|
const isStrongPassword = (password) => {
|
|
226
169
|
const minLength = 8;
|
|
227
170
|
const hasUpperCase = /[A-Z]/.test(password);
|
|
@@ -456,7 +399,7 @@
|
|
|
456
399
|
</div>
|
|
457
400
|
{:else}
|
|
458
401
|
<!-- Standard Input Layout -->
|
|
459
|
-
<div class="
|
|
402
|
+
<div class="flex items-center">
|
|
460
403
|
<input
|
|
461
404
|
bind:this={inputElement}
|
|
462
405
|
{id}
|
|
@@ -468,10 +411,9 @@
|
|
|
468
411
|
on:change={checkForAutofill}
|
|
469
412
|
on:animationstart={handleAnimationStart}
|
|
470
413
|
on:blur={handleBlur}
|
|
471
|
-
on:keydown={handleSearchKeyDown}
|
|
472
414
|
{maxlength}
|
|
473
415
|
{minlength}
|
|
474
|
-
class="input-field
|
|
416
|
+
class="input-field {icon
|
|
475
417
|
? 'pr-10'
|
|
476
418
|
: ''} {getContentFloatClass()} {displayErrorText
|
|
477
419
|
? 'input-error'
|
|
@@ -484,26 +426,7 @@
|
|
|
484
426
|
{autofocus}
|
|
485
427
|
inputmode={computedInputmode}
|
|
486
428
|
/>
|
|
487
|
-
{#if
|
|
488
|
-
<button
|
|
489
|
-
type="button"
|
|
490
|
-
on:click={clearInput}
|
|
491
|
-
class="absolute right-2 top-1/2 -translate-y-1/2 flex items-center justify-center p-1 input-clear-button"
|
|
492
|
-
aria-label="Clear input"
|
|
493
|
-
tabindex="-1"
|
|
494
|
-
>
|
|
495
|
-
<svg
|
|
496
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
497
|
-
viewBox="0 0 20 20"
|
|
498
|
-
fill="currentColor"
|
|
499
|
-
class="w-4 h-4"
|
|
500
|
-
>
|
|
501
|
-
<path
|
|
502
|
-
d="M6.28 5.22a.75.75 0 00-1.06 1.06L8.94 10l-3.72 3.72a.75.75 0 101.06 1.06L10 11.06l3.72 3.72a.75.75 0 101.06-1.06L11.06 10l3.72-3.72a.75.75 0 00-1.06-1.06L10 8.94 6.28 5.22z"
|
|
503
|
-
/>
|
|
504
|
-
</svg>
|
|
505
|
-
</button>
|
|
506
|
-
{:else if controlled && (buttonIcon || buttonText)}
|
|
429
|
+
{#if controlled && (buttonIcon || buttonText)}
|
|
507
430
|
<button
|
|
508
431
|
type="button"
|
|
509
432
|
on:click={handleButtonClick}
|
|
@@ -524,13 +447,6 @@
|
|
|
524
447
|
{/if}
|
|
525
448
|
</button>
|
|
526
449
|
{/if}
|
|
527
|
-
{#if icon && type !== "textarea" && !(showClearButton && inputValue)}
|
|
528
|
-
<img
|
|
529
|
-
src={icon}
|
|
530
|
-
alt="Input icon"
|
|
531
|
-
class="absolute inset-y-0 right-0 w-5 h-5 mr-3 top-1/2 transform -translate-y-1/2 text-Text-Primary"
|
|
532
|
-
/>
|
|
533
|
-
{/if}
|
|
534
450
|
</div>
|
|
535
451
|
{/if}
|
|
536
452
|
|
|
@@ -551,9 +467,17 @@
|
|
|
551
467
|
{#if helperIcon || hintIcon}
|
|
552
468
|
<img src={helperIcon || hintIcon} alt="Helper icon" class="w-4 h-4 mr-2" />
|
|
553
469
|
{/if}
|
|
554
|
-
<span>{
|
|
470
|
+
<span>{helperText || hintText}</span>
|
|
555
471
|
</div>
|
|
556
472
|
{/if}
|
|
473
|
+
|
|
474
|
+
{#if icon && type !== "textarea"}
|
|
475
|
+
<img
|
|
476
|
+
src={icon}
|
|
477
|
+
alt="Input icon"
|
|
478
|
+
class="absolute inset-y-0 right-0 w-5 h-5 mr-3 top-1/2 transform -translate-y-1/2 text-Text-Primary"
|
|
479
|
+
/>
|
|
480
|
+
{/if}
|
|
557
481
|
</div>
|
|
558
482
|
</div>
|
|
559
483
|
|
|
@@ -625,18 +549,6 @@
|
|
|
625
549
|
cursor: not-allowed;
|
|
626
550
|
}
|
|
627
551
|
|
|
628
|
-
.input-clear-button {
|
|
629
|
-
color: var(--input-text-placeholder);
|
|
630
|
-
background: transparent;
|
|
631
|
-
border: none;
|
|
632
|
-
cursor: pointer;
|
|
633
|
-
transition: color 0.15s ease;
|
|
634
|
-
}
|
|
635
|
-
|
|
636
|
-
.input-clear-button:hover {
|
|
637
|
-
color: var(--input-text);
|
|
638
|
-
}
|
|
639
|
-
|
|
640
552
|
.input-field {
|
|
641
553
|
padding: 0.25rem 0.625rem;
|
|
642
554
|
height: 40px;
|
|
@@ -4,10 +4,8 @@ type Input = SvelteComponent<{
|
|
|
4
4
|
size?: string | undefined;
|
|
5
5
|
className?: string | undefined;
|
|
6
6
|
disabled?: boolean | undefined;
|
|
7
|
-
value?: string | undefined;
|
|
8
|
-
name?: string | undefined;
|
|
9
7
|
label?: string | undefined;
|
|
10
|
-
|
|
8
|
+
name?: string | undefined;
|
|
11
9
|
icon?: null | undefined;
|
|
12
10
|
required?: boolean | undefined;
|
|
13
11
|
optional?: boolean | undefined;
|
|
@@ -16,6 +14,7 @@ type Input = SvelteComponent<{
|
|
|
16
14
|
maxlength?: null | undefined;
|
|
17
15
|
minlength?: null | undefined;
|
|
18
16
|
placeholder?: string | undefined;
|
|
17
|
+
id?: string | undefined;
|
|
19
18
|
textareaSize?: string | undefined;
|
|
20
19
|
errorText?: string | undefined;
|
|
21
20
|
helperText?: string | undefined;
|
|
@@ -26,6 +25,7 @@ type Input = SvelteComponent<{
|
|
|
26
25
|
readonly?: boolean | undefined;
|
|
27
26
|
controlled?: boolean | undefined;
|
|
28
27
|
onButtonClick?: null | undefined;
|
|
28
|
+
value?: string | undefined;
|
|
29
29
|
autocomplete?: null | undefined;
|
|
30
30
|
autofocus?: boolean | undefined;
|
|
31
31
|
showPasswordToggle?: boolean | undefined;
|
|
@@ -36,13 +36,7 @@ type Input = SvelteComponent<{
|
|
|
36
36
|
inputmode?: null | undefined;
|
|
37
37
|
showErrors?: boolean | undefined;
|
|
38
38
|
disableBuiltInValidation?: boolean | undefined;
|
|
39
|
-
instantSearch?: boolean | undefined;
|
|
40
|
-
debounceMs?: number | undefined;
|
|
41
|
-
minSearchChars?: number | undefined;
|
|
42
|
-
showClearButton?: boolean | undefined;
|
|
43
39
|
}, {
|
|
44
|
-
search: CustomEvent<any>;
|
|
45
|
-
} & {
|
|
46
40
|
[evt: string]: CustomEvent<any>;
|
|
47
41
|
}, {}> & {
|
|
48
42
|
$$bindings?: string | undefined;
|
|
@@ -52,10 +46,8 @@ declare const Input: $$__sveltets_2_IsomorphicComponent<{
|
|
|
52
46
|
size?: string | undefined;
|
|
53
47
|
className?: string | undefined;
|
|
54
48
|
disabled?: boolean | undefined;
|
|
55
|
-
value?: string | undefined;
|
|
56
|
-
name?: string | undefined;
|
|
57
49
|
label?: string | undefined;
|
|
58
|
-
|
|
50
|
+
name?: string | undefined;
|
|
59
51
|
icon?: null | undefined;
|
|
60
52
|
required?: boolean | undefined;
|
|
61
53
|
optional?: boolean | undefined;
|
|
@@ -64,6 +56,7 @@ declare const Input: $$__sveltets_2_IsomorphicComponent<{
|
|
|
64
56
|
maxlength?: null | undefined;
|
|
65
57
|
minlength?: null | undefined;
|
|
66
58
|
placeholder?: string | undefined;
|
|
59
|
+
id?: string | undefined;
|
|
67
60
|
textareaSize?: string | undefined;
|
|
68
61
|
errorText?: string | undefined;
|
|
69
62
|
helperText?: string | undefined;
|
|
@@ -74,6 +67,7 @@ declare const Input: $$__sveltets_2_IsomorphicComponent<{
|
|
|
74
67
|
readonly?: boolean | undefined;
|
|
75
68
|
controlled?: boolean | undefined;
|
|
76
69
|
onButtonClick?: null | undefined;
|
|
70
|
+
value?: string | undefined;
|
|
77
71
|
autocomplete?: null | undefined;
|
|
78
72
|
autofocus?: boolean | undefined;
|
|
79
73
|
showPasswordToggle?: boolean | undefined;
|
|
@@ -84,13 +78,7 @@ declare const Input: $$__sveltets_2_IsomorphicComponent<{
|
|
|
84
78
|
inputmode?: null | undefined;
|
|
85
79
|
showErrors?: boolean | undefined;
|
|
86
80
|
disableBuiltInValidation?: boolean | undefined;
|
|
87
|
-
instantSearch?: boolean | undefined;
|
|
88
|
-
debounceMs?: number | undefined;
|
|
89
|
-
minSearchChars?: number | undefined;
|
|
90
|
-
showClearButton?: boolean | undefined;
|
|
91
81
|
}, {
|
|
92
|
-
search: CustomEvent<any>;
|
|
93
|
-
} & {
|
|
94
82
|
[evt: string]: CustomEvent<any>;
|
|
95
83
|
}, {}, {}, string>;
|
|
96
84
|
interface $$__sveltets_2_IsomorphicComponent<Props extends Record<string, any> = any, Events extends Record<string, any> = any, Slots extends Record<string, any> = any, Exports = {}, Bindings = string> {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Input.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/components/Input/Input.svelte.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Input.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/components/Input/Input.svelte.js"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAyYA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;mBAAkjB;6CATrgB,KAAK,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,QAAQ,MAAM,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,QAAQ,KAAK,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,QAAQ,OAAO,OAAO,QAAQ;IAC3L,cAAc,OAAO,QAAQ,EAAE,2BAA2B,CAAC,KAAK,CAAC,GAAG,OAAO,QAAQ,EAAE,eAAe,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,CAAC,GAAG;QAAE,UAAU,CAAC,EAAE,QAAQ,CAAA;KAAE,GAAG,OAAO,CAAC;IACjK,WAAW,OAAO,SAAS,KAAK,GAAG;QAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;QAAC,OAAO,CAAC,EAAE,KAAK,CAAA;KAAC,GAAG,OAAO,GAAG;QAAE,IAAI,CAAC,EAAE,GAAG,CAAC;QAAC,GAAG,CAAC,EAAE,GAAG,CAAA;KAAE,CAAC;IAC9G,eAAe,QAAQ,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<script>
|
|
2
|
-
import { createEventDispatcher, onMount } from "svelte";
|
|
2
|
+
import { createEventDispatcher, onMount, onDestroy } from "svelte";
|
|
3
3
|
|
|
4
4
|
const dispatch = createEventDispatcher();
|
|
5
5
|
|
|
@@ -117,9 +117,10 @@
|
|
|
117
117
|
|
|
118
118
|
onMount(() => {
|
|
119
119
|
document.addEventListener("click", handleClickOutside);
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
120
|
+
});
|
|
121
|
+
|
|
122
|
+
onDestroy(() => {
|
|
123
|
+
document.removeEventListener("click", handleClickOutside);
|
|
123
124
|
});
|
|
124
125
|
</script>
|
|
125
126
|
|
|
@@ -2,12 +2,12 @@ export default MultiSelect;
|
|
|
2
2
|
type MultiSelect = SvelteComponent<{
|
|
3
3
|
error?: string | undefined;
|
|
4
4
|
disabled?: boolean | undefined;
|
|
5
|
-
value?: any[] | undefined;
|
|
6
|
-
name?: string | undefined;
|
|
7
5
|
label?: string | undefined;
|
|
8
|
-
|
|
6
|
+
name?: string | undefined;
|
|
9
7
|
required?: boolean | undefined;
|
|
10
8
|
placeholder?: string | undefined;
|
|
9
|
+
id?: string | undefined;
|
|
10
|
+
value?: any[] | undefined;
|
|
11
11
|
animateFocus?: boolean | undefined;
|
|
12
12
|
items?: any[] | undefined;
|
|
13
13
|
hideClear?: boolean | undefined;
|
|
@@ -21,12 +21,12 @@ type MultiSelect = SvelteComponent<{
|
|
|
21
21
|
declare const MultiSelect: $$__sveltets_2_IsomorphicComponent<{
|
|
22
22
|
error?: string | undefined;
|
|
23
23
|
disabled?: boolean | undefined;
|
|
24
|
-
value?: any[] | undefined;
|
|
25
|
-
name?: string | undefined;
|
|
26
24
|
label?: string | undefined;
|
|
27
|
-
|
|
25
|
+
name?: string | undefined;
|
|
28
26
|
required?: boolean | undefined;
|
|
29
27
|
placeholder?: string | undefined;
|
|
28
|
+
id?: string | undefined;
|
|
29
|
+
value?: any[] | undefined;
|
|
30
30
|
animateFocus?: boolean | undefined;
|
|
31
31
|
items?: any[] | undefined;
|
|
32
32
|
hideClear?: boolean | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MultiSelect.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/components/Input/MultiSelect.svelte.js"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"MultiSelect.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/components/Input/MultiSelect.svelte.js"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAuNA;;;;;;;;;;;;;;;;mBAAqO;6CATxL,KAAK,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,QAAQ,MAAM,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,QAAQ,KAAK,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,QAAQ,OAAO,OAAO,QAAQ;IAC3L,cAAc,OAAO,QAAQ,EAAE,2BAA2B,CAAC,KAAK,CAAC,GAAG,OAAO,QAAQ,EAAE,eAAe,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,CAAC,GAAG;QAAE,UAAU,CAAC,EAAE,QAAQ,CAAA;KAAE,GAAG,OAAO,CAAC;IACjK,WAAW,OAAO,SAAS,KAAK,GAAG;QAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;QAAC,OAAO,CAAC,EAAE,KAAK,CAAA;KAAC,GAAG,OAAO,GAAG;QAAE,IAAI,CAAC,EAAE,GAAG,CAAC;QAAC,GAAG,CAAC,EAAE,GAAG,CAAA;KAAE,CAAC;IAC9G,eAAe,QAAQ,CAAC"}
|
|
@@ -89,7 +89,7 @@
|
|
|
89
89
|
{disabled}
|
|
90
90
|
aria-label="Digit {index + 1} of {length}"
|
|
91
91
|
aria-describedby="otp-instructions"
|
|
92
|
-
class="otp-input w-12 h-12 md:w-14 md:h-14 text-center text-xl md:text-2xl text-
|
|
92
|
+
class="otp-input w-12 h-12 md:w-14 md:h-14 text-center text-xl md:text-2xl text-Text-Primary font-semibold border-2 border-stroke-Primary rounded-xl focus:border-primary-700 focus:outline-none transition-colors bg-BG-Primary disabled:bg-BG-Secondary disabled:cursor-not-allowed"
|
|
93
93
|
on:input={(e) => handleInput(index, e)}
|
|
94
94
|
on:keydown={(e) => handleKeyDown(index, e)}
|
|
95
95
|
on:paste={handlePaste}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<script>
|
|
2
|
-
import { createEventDispatcher, onMount } from "svelte";
|
|
2
|
+
import { createEventDispatcher, onMount, onDestroy } from "svelte";
|
|
3
3
|
|
|
4
4
|
const dispatch = createEventDispatcher();
|
|
5
5
|
|
|
@@ -96,9 +96,10 @@
|
|
|
96
96
|
|
|
97
97
|
onMount(() => {
|
|
98
98
|
document.addEventListener("click", handleClickOutside);
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
99
|
+
});
|
|
100
|
+
|
|
101
|
+
onDestroy(() => {
|
|
102
|
+
document.removeEventListener("click", handleClickOutside);
|
|
102
103
|
});
|
|
103
104
|
</script>
|
|
104
105
|
|
|
@@ -2,12 +2,12 @@ export default Select;
|
|
|
2
2
|
type Select = SvelteComponent<{
|
|
3
3
|
error?: string | undefined;
|
|
4
4
|
disabled?: boolean | undefined;
|
|
5
|
-
value?: string | undefined;
|
|
6
|
-
name?: string | undefined;
|
|
7
5
|
label?: string | undefined;
|
|
8
|
-
|
|
6
|
+
name?: string | undefined;
|
|
9
7
|
required?: boolean | undefined;
|
|
10
8
|
placeholder?: string | undefined;
|
|
9
|
+
id?: string | undefined;
|
|
10
|
+
value?: string | undefined;
|
|
11
11
|
animateFocus?: boolean | undefined;
|
|
12
12
|
items?: any[] | undefined;
|
|
13
13
|
}, {
|
|
@@ -20,12 +20,12 @@ type Select = SvelteComponent<{
|
|
|
20
20
|
declare const Select: $$__sveltets_2_IsomorphicComponent<{
|
|
21
21
|
error?: string | undefined;
|
|
22
22
|
disabled?: boolean | undefined;
|
|
23
|
-
value?: string | undefined;
|
|
24
|
-
name?: string | undefined;
|
|
25
23
|
label?: string | undefined;
|
|
26
|
-
|
|
24
|
+
name?: string | undefined;
|
|
27
25
|
required?: boolean | undefined;
|
|
28
26
|
placeholder?: string | undefined;
|
|
27
|
+
id?: string | undefined;
|
|
28
|
+
value?: string | undefined;
|
|
29
29
|
animateFocus?: boolean | undefined;
|
|
30
30
|
items?: any[] | undefined;
|
|
31
31
|
}, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Select.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/components/Input/Select.svelte.js"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"Select.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/components/Input/Select.svelte.js"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;AAqKA;;;;;;;;;;;;;;;mBAAoN;6CATvK,KAAK,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,QAAQ,MAAM,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,QAAQ,KAAK,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,QAAQ,OAAO,OAAO,QAAQ;IAC3L,cAAc,OAAO,QAAQ,EAAE,2BAA2B,CAAC,KAAK,CAAC,GAAG,OAAO,QAAQ,EAAE,eAAe,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,CAAC,GAAG;QAAE,UAAU,CAAC,EAAE,QAAQ,CAAA;KAAE,GAAG,OAAO,CAAC;IACjK,WAAW,OAAO,SAAS,KAAK,GAAG;QAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;QAAC,OAAO,CAAC,EAAE,KAAK,CAAA;KAAC,GAAG,OAAO,GAAG;QAAE,IAAI,CAAC,EAAE,GAAG,CAAC;QAAC,GAAG,CAAC,EAAE,GAAG,CAAA;KAAE,CAAC;IAC9G,eAAe,QAAQ,CAAC"}
|
|
@@ -79,7 +79,7 @@
|
|
|
79
79
|
class="avatar-button"
|
|
80
80
|
on:click={() => showDesktopDropdown = !showDesktopDropdown}
|
|
81
81
|
>
|
|
82
|
-
<Avatar src={avatar} rounded size="
|
|
82
|
+
<Avatar src={avatar} dot={{ color: "green" }} rounded size="sm" />
|
|
83
83
|
</button>
|
|
84
84
|
|
|
85
85
|
{#if showDesktopDropdown}
|
|
@@ -137,7 +137,7 @@
|
|
|
137
137
|
<div class="header-avatar-wrapper">
|
|
138
138
|
<!-- Mobile: triggers bottom sheet -->
|
|
139
139
|
<button class="avatar-button avatar-button--mobile" on:click={() => showMobileSheet = true}>
|
|
140
|
-
<Avatar src={avatar} rounded size="
|
|
140
|
+
<Avatar src={avatar} dot={{ color: "green" }} rounded size="sm" />
|
|
141
141
|
</button>
|
|
142
142
|
|
|
143
143
|
<!-- Desktop: triggers dropdown -->
|
|
@@ -145,7 +145,7 @@
|
|
|
145
145
|
class="avatar-button avatar-button--desktop"
|
|
146
146
|
on:click={() => showDesktopDropdown = !showDesktopDropdown}
|
|
147
147
|
>
|
|
148
|
-
<Avatar src={avatar} rounded size="
|
|
148
|
+
<Avatar src={avatar} dot={{ color: "green" }} rounded size="sm" />
|
|
149
149
|
</button>
|
|
150
150
|
|
|
151
151
|
<!-- Desktop dropdown -->
|
|
@@ -294,23 +294,13 @@
|
|
|
294
294
|
margin-left: 0.25rem;
|
|
295
295
|
}
|
|
296
296
|
|
|
297
|
-
/* Fix avatar image aspect ratio and border radius */
|
|
298
|
-
:global(.avatar-button img) {
|
|
299
|
-
-o-object-fit: cover !important;
|
|
300
|
-
object-fit: cover !important;
|
|
301
|
-
aspect-ratio: 1 / 1 !important;
|
|
302
|
-
border-radius: 0.5rem !important;
|
|
303
|
-
}
|
|
304
|
-
|
|
305
297
|
.avatar-button {
|
|
306
298
|
background: none;
|
|
307
299
|
border: none;
|
|
308
300
|
padding: 0;
|
|
309
301
|
cursor: pointer;
|
|
310
|
-
border-radius:
|
|
302
|
+
border-radius: 9999px;
|
|
311
303
|
transition: opacity 0.15s;
|
|
312
|
-
min-width: 40px;
|
|
313
|
-
min-height: 40px;
|
|
314
304
|
}
|
|
315
305
|
|
|
316
306
|
.avatar-button:hover {
|
|
@@ -5,68 +5,21 @@
|
|
|
5
5
|
import Modal from "./Modal.svelte";
|
|
6
6
|
|
|
7
7
|
export let show = false;
|
|
8
|
-
export let size = "default"; // "small" | "default" | "large"
|
|
9
8
|
export let title = "";
|
|
10
9
|
export let description = "";
|
|
11
10
|
export let warningText = "";
|
|
12
11
|
export let actions = [];
|
|
13
12
|
export let icon = null;
|
|
14
|
-
export let customIcon = null; // Alias for icon (used by some wrappers)
|
|
15
13
|
export let closeBtn = false; // To show close button
|
|
16
14
|
|
|
17
|
-
// Simple props-based API (alternative to actions array)
|
|
18
|
-
export let primaryButtonText = "";
|
|
19
|
-
export let secondaryButtonText = "";
|
|
20
|
-
export let variant = "default"; // "default" | "danger"
|
|
21
|
-
|
|
22
|
-
// Loading/disabled state
|
|
23
|
-
export let loading = false;
|
|
24
|
-
export let disabled = false;
|
|
25
|
-
|
|
26
15
|
const dispatch = createEventDispatcher();
|
|
27
16
|
|
|
28
|
-
// Resolve icon (support both prop names)
|
|
29
|
-
$: resolvedIcon = customIcon || icon;
|
|
30
|
-
|
|
31
|
-
// Build actions from simple props if actions array is empty
|
|
32
|
-
$: resolvedActions = actions.length > 0 ? actions : buildActionsFromProps();
|
|
33
|
-
|
|
34
|
-
function buildActionsFromProps() {
|
|
35
|
-
const result = [];
|
|
36
|
-
|
|
37
|
-
if (secondaryButtonText) {
|
|
38
|
-
result.push({
|
|
39
|
-
label: secondaryButtonText,
|
|
40
|
-
variant: "gray-outline",
|
|
41
|
-
onClick: () => dispatch("cancel")
|
|
42
|
-
});
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
if (primaryButtonText) {
|
|
46
|
-
result.push({
|
|
47
|
-
label: primaryButtonText,
|
|
48
|
-
variant: variant === "danger" ? "red-solid" : "blue-solid",
|
|
49
|
-
onClick: () => dispatch("confirm"),
|
|
50
|
-
primary: true
|
|
51
|
-
});
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
return result;
|
|
55
|
-
}
|
|
56
|
-
|
|
57
17
|
const handleAction = (action) => {
|
|
58
|
-
|
|
59
|
-
action.onClick?.();
|
|
18
|
+
action.onClick();
|
|
60
19
|
dispatch(action.label.toLowerCase());
|
|
61
20
|
show = false;
|
|
62
21
|
};
|
|
63
22
|
|
|
64
|
-
const handleClose = () => {
|
|
65
|
-
if (disabled || loading) return;
|
|
66
|
-
dispatch("close");
|
|
67
|
-
show = false;
|
|
68
|
-
};
|
|
69
|
-
|
|
70
23
|
const getVariant = (action) => {
|
|
71
24
|
// If variant is already specified, use it
|
|
72
25
|
if (action.variant) return action.variant;
|
|
@@ -95,59 +48,54 @@
|
|
|
95
48
|
onClick,
|
|
96
49
|
beforeIcon,
|
|
97
50
|
afterIcon,
|
|
98
|
-
primary,
|
|
99
51
|
...rest
|
|
100
52
|
} = action;
|
|
101
53
|
return rest;
|
|
102
54
|
};
|
|
103
55
|
</script>
|
|
104
56
|
|
|
105
|
-
<Modal bind:show
|
|
106
|
-
<div slot="header" class="text-center">
|
|
57
|
+
<Modal bind:show>
|
|
58
|
+
<div slot="header" class="flex flex-col gap-6 text-center">
|
|
107
59
|
{#if closeBtn}
|
|
108
|
-
<div class="flex justify-end
|
|
109
|
-
<button
|
|
110
|
-
|
|
111
|
-
on:click={handleClose}
|
|
112
|
-
{disabled}
|
|
113
|
-
>
|
|
114
|
-
<img src={Cancel} alt="Close" class="w-5 h-5" />
|
|
60
|
+
<div class="flex justify-end">
|
|
61
|
+
<button class="focus:outline-none" on:click={() => (show = false)}>
|
|
62
|
+
<img src={Cancel} alt="Close Icon" />
|
|
115
63
|
</button>
|
|
116
64
|
</div>
|
|
117
65
|
{/if}
|
|
118
|
-
{#if
|
|
119
|
-
<div class="flex justify-center
|
|
120
|
-
<img src={
|
|
66
|
+
{#if icon}
|
|
67
|
+
<div class="flex justify-center items-center">
|
|
68
|
+
<img src={icon} alt="Icon here" />
|
|
121
69
|
</div>
|
|
122
70
|
{/if}
|
|
123
71
|
{#if title}
|
|
124
|
-
<h2 class="text-xl
|
|
72
|
+
<h2 class="text-xl text-Text-Primary leading-5 font-normal">{title}</h2>
|
|
125
73
|
{/if}
|
|
126
74
|
</div>
|
|
127
75
|
|
|
128
|
-
<div slot="body" class="text-center mt-
|
|
76
|
+
<div slot="body" class="flex flex-col gap-6 text-center mt-6">
|
|
129
77
|
{#if description}
|
|
130
|
-
<p class="text-
|
|
78
|
+
<p class="text-Text-Tartiary text-sm leading-[22px] font-normal">
|
|
131
79
|
{description}
|
|
132
80
|
</p>
|
|
133
81
|
{/if}
|
|
134
82
|
{#if warningText}
|
|
135
|
-
<p
|
|
83
|
+
<p
|
|
84
|
+
class="text-accent-Danger text-center text-sm leading-[22px] font-bold"
|
|
85
|
+
>
|
|
136
86
|
{warningText}
|
|
137
87
|
</p>
|
|
138
88
|
{/if}
|
|
139
89
|
</div>
|
|
140
90
|
|
|
141
|
-
<div slot="footer" class="flex gap-3">
|
|
142
|
-
{#each
|
|
91
|
+
<div slot="footer" class="flex justify-around gap-3 mt-6">
|
|
92
|
+
{#each actions as action}
|
|
143
93
|
<Button
|
|
144
94
|
size="full"
|
|
145
95
|
variant={getVariant(action)}
|
|
146
96
|
{...cleanActionProps(action)}
|
|
147
97
|
beforeIcon={action.beforeIcon}
|
|
148
98
|
afterIcon={action.afterIcon}
|
|
149
|
-
disabled={disabled || action.disabled}
|
|
150
|
-
loading={action.primary && loading}
|
|
151
99
|
on:click={() => handleAction(action)}
|
|
152
100
|
>
|
|
153
101
|
{action.label}
|