@coyalabs/bts-style 1.0.8 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (60) hide show
  1. package/dist/Base/BaseContainer.svelte +85 -0
  2. package/dist/{BaseContainer.svelte.d.ts → Base/BaseContainer.svelte.d.ts} +12 -2
  3. package/dist/Base/BaseIcon.svelte +42 -0
  4. package/dist/Base/BaseIcon.svelte.d.ts +30 -0
  5. package/dist/Base/BasePage.svelte +73 -0
  6. package/dist/Base/BasePage.svelte.d.ts +37 -0
  7. package/dist/{Text.svelte → Base/BaseText.svelte} +9 -11
  8. package/dist/{Text.svelte.d.ts → Base/BaseText.svelte.d.ts} +5 -3
  9. package/dist/Components/Button.svelte +151 -0
  10. package/dist/Components/Button.svelte.d.ts +65 -0
  11. package/dist/Components/Dropdown.svelte +191 -0
  12. package/dist/Components/Dropdown.svelte.d.ts +54 -0
  13. package/dist/Components/IconButton.svelte +44 -0
  14. package/dist/Components/IconButton.svelte.d.ts +34 -0
  15. package/dist/Components/InputBox.svelte +103 -0
  16. package/dist/Components/InputBox.svelte.d.ts +56 -0
  17. package/dist/Components/Popup/AlertPopup.svelte +27 -0
  18. package/dist/Components/Popup/AlertPopup.svelte.d.ts +28 -0
  19. package/dist/Components/Popup/ConfirmPopup.svelte +39 -0
  20. package/dist/Components/Popup/ConfirmPopup.svelte.d.ts +32 -0
  21. package/dist/Components/Popup/Popup.svelte +67 -0
  22. package/dist/{BasePage.svelte.d.ts → Components/Popup/Popup.svelte.d.ts} +15 -9
  23. package/dist/Components/Popup/PromptPopup.svelte +61 -0
  24. package/dist/Components/Popup/PromptPopup.svelte.d.ts +36 -0
  25. package/dist/Components/Separator.svelte +63 -0
  26. package/dist/Components/Separator.svelte.d.ts +30 -0
  27. package/dist/Components/Special/SpecialAction.svelte +46 -0
  28. package/dist/Components/Special/SpecialAction.svelte.d.ts +32 -0
  29. package/dist/Components/Special/SpecialParagraph.svelte +159 -0
  30. package/dist/Components/Special/SpecialParagraph.svelte.d.ts +52 -0
  31. package/dist/Components/TabBar.svelte +128 -0
  32. package/dist/Components/TabBar.svelte.d.ts +40 -0
  33. package/dist/Components/Toggle.svelte +59 -0
  34. package/dist/{Testing.svelte.d.ts → Components/Toggle.svelte.d.ts} +5 -9
  35. package/dist/Components/Tooltip.svelte +132 -0
  36. package/dist/Components/Tooltip.svelte.d.ts +28 -0
  37. package/dist/Components/TreeDirectory.svelte +148 -0
  38. package/dist/Components/TreeDirectory.svelte.d.ts +58 -0
  39. package/dist/Components/popupStore.d.ts +31 -0
  40. package/dist/Components/popupStore.js +99 -0
  41. package/dist/Structure/BG/AssetGear.d.ts +2 -0
  42. package/dist/Structure/BG/AssetGear.js +2 -0
  43. package/dist/Structure/BG/BGChain.svelte +188 -0
  44. package/dist/Structure/BG/BGChain.svelte.d.ts +36 -0
  45. package/dist/Structure/BG/BGDetails.svelte +130 -0
  46. package/dist/Structure/BG/BGDetails.svelte.d.ts +36 -0
  47. package/dist/Structure/BG/BGGears.svelte +188 -0
  48. package/dist/Structure/BG/BGGears.svelte.d.ts +38 -0
  49. package/dist/Structure/TextHeader.svelte +32 -0
  50. package/dist/Structure/TextHeader.svelte.d.ts +28 -0
  51. package/dist/icons.d.ts +11 -0
  52. package/dist/icons.js +11 -0
  53. package/dist/index.d.ts +25 -3
  54. package/dist/index.js +30 -3
  55. package/package.json +2 -1
  56. package/public/favicon.png +0 -0
  57. package/README.md +0 -35
  58. package/dist/BaseContainer.svelte +0 -43
  59. package/dist/BasePage.svelte +0 -30
  60. package/dist/Testing.svelte +0 -26
@@ -0,0 +1,191 @@
1
+ <script>
2
+ import Button from './Button.svelte';
3
+ import BaseContainer from '../Base/BaseContainer.svelte';
4
+ import { icons } from '../icons';
5
+ import { slide } from 'svelte/transition';
6
+
7
+ /**
8
+ * @type {string}
9
+ */
10
+ export let label = '';
11
+
12
+ /**
13
+ * @type {string | null}
14
+ */
15
+ export let icon = null;
16
+
17
+ /**
18
+ * @type {'full' | 'primary' | 'secondary'}
19
+ */
20
+ export let theme = 'full';
21
+
22
+ /**
23
+ * @type {string}
24
+ */
25
+ export let width = '200px';
26
+
27
+ /**
28
+ * @type {Array<{label: string, value: any, disabled?: boolean}>}
29
+ */
30
+ export let options = [];
31
+
32
+ /**
33
+ * @type {any}
34
+ */
35
+ export let value = null;
36
+
37
+ /**
38
+ * @type {(value: any) => void}
39
+ */
40
+ export let onChange = () => {};
41
+
42
+ /**
43
+ * @type {string}
44
+ */
45
+ export let borderRadiusTopLeft = '25px';
46
+
47
+ /**
48
+ * @type {string}
49
+ */
50
+ export let borderRadiusTopRight = '25px';
51
+
52
+ /**
53
+ * @type {string}
54
+ */
55
+ export let borderRadiusBottomLeft = '25px';
56
+
57
+ /**
58
+ * @type {string}
59
+ */
60
+ export let borderRadiusBottomRight = '25px';
61
+
62
+ let isOpen = false;
63
+ /**
64
+ * @type {HTMLDivElement}
65
+ */
66
+ let dropdownRef;
67
+
68
+ function toggleDropdown() {
69
+ isOpen = !isOpen;
70
+ }
71
+
72
+ /**
73
+ * @param {any} optionValue
74
+ */
75
+ function selectOption(optionValue) {
76
+ value = optionValue;
77
+ isOpen = false;
78
+ onChange(optionValue);
79
+ }
80
+
81
+ /**
82
+ * @param {MouseEvent} event
83
+ */
84
+ function handleClickOutside(event) {
85
+ if (dropdownRef && event.target instanceof Node && !dropdownRef.contains(event.target)) {
86
+ isOpen = false;
87
+ }
88
+ }
89
+
90
+ $: selectedOption = options.find(opt => opt.value === value);
91
+ $: displayLabel = selectedOption ? selectedOption.label : label;
92
+ </script>
93
+
94
+ <svelte:window on:click={handleClickOutside} />
95
+
96
+ <div class="dropdown-container" bind:this={dropdownRef} style="width: {width};">
97
+ <Button
98
+ {theme}
99
+ {icon}
100
+ actionIcon={icons.icon_expand}
101
+ actionIconSize="12px"
102
+ actionIconRotation={isOpen ? 180 : 0}
103
+ {borderRadiusTopLeft}
104
+ {borderRadiusTopRight}
105
+ {borderRadiusBottomLeft}
106
+ {borderRadiusBottomRight}
107
+ on:click={toggleDropdown}
108
+ >
109
+ <span class="button-label">{displayLabel}</span>
110
+ </Button>
111
+
112
+ {#if isOpen}
113
+ <div class="dropdown-menu" transition:slide={{ duration: 150 }}>
114
+ <BaseContainer theme="filled" padding="0.5rem" borderRadiusTopLeft="15px" borderRadiusTopRight="15px" borderRadiusBottomLeft="15px" borderRadiusBottomRight="15px">
115
+ {#each options as option}
116
+ <button
117
+ class="dropdown-item"
118
+ class:selected={option.value === value}
119
+ class:disabled={option.disabled}
120
+ disabled={option.disabled}
121
+ on:click={() => selectOption(option.value)}
122
+ >
123
+ {option.label}
124
+ </button>
125
+ {/each}
126
+ </BaseContainer>
127
+ </div>
128
+ {/if}
129
+ </div>
130
+
131
+ <style>
132
+ .dropdown-container {
133
+ position: relative;
134
+ display: inline-block;
135
+ }
136
+
137
+ .dropdown-container :global(button) {
138
+ width: 100%;
139
+ }
140
+
141
+ .button-label {
142
+ max-width: 100%;
143
+ overflow: hidden;
144
+ text-overflow: ellipsis;
145
+ white-space: nowrap;
146
+ }
147
+
148
+ .dropdown-menu {
149
+ position: absolute;
150
+ top: calc(100% + 4px);
151
+ left: 0;
152
+ right: 0;
153
+ z-index: 1000;
154
+ }
155
+
156
+ .dropdown-item {
157
+ width: 100%;
158
+ padding: 0.75rem 1rem;
159
+ background: none;
160
+ border: none;
161
+ color: #E3D8D8;
162
+ font-family: 'Satoshi', sans-serif;
163
+ font-size: 0.95rem;
164
+ font-weight: 500;
165
+ text-align: left;
166
+ cursor: pointer;
167
+ transition: background-color 0.15s ease;
168
+ border-radius: 10px;
169
+ white-space: nowrap;
170
+ overflow: hidden;
171
+ text-overflow: ellipsis;
172
+ }
173
+
174
+ .dropdown-item:hover:not(.disabled) {
175
+ background-color: rgba(227, 216, 216, 0.1);
176
+ }
177
+
178
+ .dropdown-item.selected {
179
+ background-color: rgba(255, 239, 246, 0.15);
180
+ font-weight: 700;
181
+ }
182
+
183
+ .dropdown-item.disabled {
184
+ opacity: 0.4;
185
+ cursor: not-allowed;
186
+ }
187
+
188
+ .dropdown-item:not(:last-child) {
189
+ margin-bottom: 4px;
190
+ }
191
+ </style>
@@ -0,0 +1,54 @@
1
+ export default Dropdown;
2
+ type Dropdown = SvelteComponent<{
3
+ theme?: "full" | "primary" | "secondary" | undefined;
4
+ borderRadiusTopLeft?: string | undefined;
5
+ borderRadiusTopRight?: string | undefined;
6
+ borderRadiusBottomLeft?: string | undefined;
7
+ borderRadiusBottomRight?: string | undefined;
8
+ label?: string | undefined;
9
+ icon?: string | null | undefined;
10
+ width?: string | undefined;
11
+ value?: any;
12
+ options?: {
13
+ label: string;
14
+ value: any;
15
+ disabled?: boolean | undefined;
16
+ }[] | undefined;
17
+ onChange?: ((value: any) => void) | undefined;
18
+ }, {
19
+ [evt: string]: CustomEvent<any>;
20
+ }, {}> & {
21
+ $$bindings?: string | undefined;
22
+ };
23
+ declare const Dropdown: $$__sveltets_2_IsomorphicComponent<{
24
+ theme?: "full" | "primary" | "secondary" | undefined;
25
+ borderRadiusTopLeft?: string | undefined;
26
+ borderRadiusTopRight?: string | undefined;
27
+ borderRadiusBottomLeft?: string | undefined;
28
+ borderRadiusBottomRight?: string | undefined;
29
+ label?: string | undefined;
30
+ icon?: string | null | undefined;
31
+ width?: string | undefined;
32
+ value?: any;
33
+ options?: {
34
+ label: string;
35
+ value: any;
36
+ disabled?: boolean;
37
+ }[] | undefined;
38
+ onChange?: ((value: any) => void) | undefined;
39
+ }, {
40
+ [evt: string]: CustomEvent<any>;
41
+ }, {}, {}, string>;
42
+ 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> {
43
+ new (options: import("svelte").ComponentConstructorOptions<Props>): import("svelte").SvelteComponent<Props, Events, Slots> & {
44
+ $$bindings?: Bindings;
45
+ } & Exports;
46
+ (internal: unknown, props: Props & {
47
+ $$events?: Events;
48
+ $$slots?: Slots;
49
+ }): Exports & {
50
+ $set?: any;
51
+ $on?: any;
52
+ };
53
+ z_$$bindings?: Bindings;
54
+ }
@@ -0,0 +1,44 @@
1
+ <script>
2
+ import BaseIcon from '../Base/BaseIcon.svelte';
3
+
4
+ /**
5
+ * @type {string}
6
+ */
7
+ export let svg;
8
+
9
+ /**
10
+ * @type {string}
11
+ */
12
+ export let size = '20px';
13
+
14
+ /**
15
+ * @type {'default' | 'toned'}
16
+ */
17
+ export let variant = 'toned';
18
+ </script>
19
+
20
+ <button class="icon-button" on:click>
21
+ <BaseIcon variant={variant} {svg} {size} />
22
+ </button>
23
+
24
+ <style>
25
+ .icon-button {
26
+ all: unset;
27
+ cursor: pointer;
28
+ padding: 0.5rem;
29
+ border-radius: 50%;
30
+ display: flex;
31
+ align-items: center;
32
+ justify-content: center;
33
+ transition: background 0.2s, transform 0.2s;
34
+ }
35
+
36
+ .icon-button:hover {
37
+ background: rgba(255, 255, 255, 0.1);
38
+ transform: scale(1.1);
39
+ }
40
+
41
+ .icon-button:active {
42
+ transform: scale(0.95);
43
+ }
44
+ </style>
@@ -0,0 +1,34 @@
1
+ export default IconButton;
2
+ type IconButton = SvelteComponent<{
3
+ svg: string;
4
+ variant?: "default" | "toned" | undefined;
5
+ size?: string | undefined;
6
+ }, {
7
+ click: PointerEvent;
8
+ } & {
9
+ [evt: string]: CustomEvent<any>;
10
+ }, {}> & {
11
+ $$bindings?: string | undefined;
12
+ };
13
+ declare const IconButton: $$__sveltets_2_IsomorphicComponent<{
14
+ svg: string;
15
+ variant?: "default" | "toned" | undefined;
16
+ size?: string | undefined;
17
+ }, {
18
+ click: PointerEvent;
19
+ } & {
20
+ [evt: string]: CustomEvent<any>;
21
+ }, {}, {}, string>;
22
+ 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> {
23
+ new (options: import("svelte").ComponentConstructorOptions<Props>): import("svelte").SvelteComponent<Props, Events, Slots> & {
24
+ $$bindings?: Bindings;
25
+ } & Exports;
26
+ (internal: unknown, props: Props & {
27
+ $$events?: Events;
28
+ $$slots?: Slots;
29
+ }): Exports & {
30
+ $set?: any;
31
+ $on?: any;
32
+ };
33
+ z_$$bindings?: Bindings;
34
+ }
@@ -0,0 +1,103 @@
1
+ <script>
2
+ import BaseContainer from '../Base/BaseContainer.svelte';
3
+ import BaseIcon from '../Base/BaseIcon.svelte';
4
+ import { icons } from '../icons.js';
5
+
6
+ /**
7
+ * @type {'full' | 'primary' | 'secondary'}
8
+ */
9
+ export let theme = 'secondary';
10
+
11
+ /**
12
+ * @type {string}
13
+ */
14
+ export let value = '';
15
+
16
+ /**
17
+ * @type {string}
18
+ */
19
+ export let placeholder = '';
20
+
21
+ /**
22
+ * @type {string}
23
+ */
24
+ export let type = 'text';
25
+
26
+ /**
27
+ * @type {string | null}
28
+ */
29
+ export let icon = null;
30
+
31
+ /**
32
+ * @type {string}
33
+ */
34
+ export let iconSize = '18px';
35
+
36
+ /**
37
+ * @type {string}
38
+ */
39
+ export let borderRadiusTopLeft = '25px';
40
+
41
+ /**
42
+ * @type {string}
43
+ */
44
+ export let borderRadiusTopRight = '25px';
45
+
46
+ /**
47
+ * @type {string}
48
+ */
49
+ export let borderRadiusBottomLeft = '25px';
50
+
51
+ /**
52
+ * @type {string}
53
+ */
54
+ export let borderRadiusBottomRight = '25px';
55
+ </script>
56
+
57
+ <div class="input-wrapper">
58
+ <BaseContainer {theme} {borderRadiusTopLeft} {borderRadiusTopRight} {borderRadiusBottomLeft} {borderRadiusBottomRight}>
59
+ <div class="input-content">
60
+ {#if icon}
61
+ <BaseIcon variant="toned" svg={icon} size={iconSize} />
62
+ {/if}
63
+ <input
64
+ {type}
65
+ {placeholder}
66
+ bind:value
67
+ on:input
68
+ on:change
69
+ on:focus
70
+ on:blur
71
+ on:keydown
72
+ />
73
+ <BaseIcon variant="toned" svg={icons.pen} size="15px" />
74
+ </div>
75
+ </BaseContainer>
76
+ </div>
77
+
78
+ <style>
79
+ .input-wrapper {
80
+ width: 100%;
81
+ }
82
+
83
+ .input-content {
84
+ display: flex;
85
+ align-items: center;
86
+ gap: 8px;
87
+ height: 25px; /* Match button text height */
88
+ }
89
+
90
+ input {
91
+ all: unset;
92
+ flex: 1;
93
+ font-family: 'Satoshi', sans-serif;
94
+ font-weight: 700;
95
+ font-size: 18px;
96
+ color: #E3D8D8;
97
+ width: 100%;
98
+ }
99
+
100
+ input::placeholder {
101
+ color: rgba(227, 216, 216, 0.4);
102
+ }
103
+ </style>
@@ -0,0 +1,56 @@
1
+ export default InputBox;
2
+ type InputBox = SvelteComponent<{
3
+ theme?: "full" | "primary" | "secondary" | undefined;
4
+ borderRadiusTopLeft?: string | undefined;
5
+ borderRadiusTopRight?: string | undefined;
6
+ borderRadiusBottomLeft?: string | undefined;
7
+ borderRadiusBottomRight?: string | undefined;
8
+ icon?: string | null | undefined;
9
+ iconSize?: string | undefined;
10
+ value?: string | undefined;
11
+ placeholder?: string | undefined;
12
+ type?: string | undefined;
13
+ }, {
14
+ input: Event;
15
+ change: Event;
16
+ focus: FocusEvent;
17
+ blur: FocusEvent;
18
+ keydown: KeyboardEvent;
19
+ } & {
20
+ [evt: string]: CustomEvent<any>;
21
+ }, {}> & {
22
+ $$bindings?: string | undefined;
23
+ };
24
+ declare const InputBox: $$__sveltets_2_IsomorphicComponent<{
25
+ theme?: "full" | "primary" | "secondary" | undefined;
26
+ borderRadiusTopLeft?: string | undefined;
27
+ borderRadiusTopRight?: string | undefined;
28
+ borderRadiusBottomLeft?: string | undefined;
29
+ borderRadiusBottomRight?: string | undefined;
30
+ icon?: string | null | undefined;
31
+ iconSize?: string | undefined;
32
+ value?: string | undefined;
33
+ placeholder?: string | undefined;
34
+ type?: string | undefined;
35
+ }, {
36
+ input: Event;
37
+ change: Event;
38
+ focus: FocusEvent;
39
+ blur: FocusEvent;
40
+ keydown: KeyboardEvent;
41
+ } & {
42
+ [evt: string]: CustomEvent<any>;
43
+ }, {}, {}, string>;
44
+ 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> {
45
+ new (options: import("svelte").ComponentConstructorOptions<Props>): import("svelte").SvelteComponent<Props, Events, Slots> & {
46
+ $$bindings?: Bindings;
47
+ } & Exports;
48
+ (internal: unknown, props: Props & {
49
+ $$events?: Events;
50
+ $$slots?: Slots;
51
+ }): Exports & {
52
+ $set?: any;
53
+ $on?: any;
54
+ };
55
+ z_$$bindings?: Bindings;
56
+ }
@@ -0,0 +1,27 @@
1
+ <script>
2
+ import Button from '../Button.svelte';
3
+ import { icons } from '../../icons.js';
4
+ import { popupStore } from '../popupStore.js';
5
+
6
+ /** @type {() => void} */
7
+ export let onOk = () => {};
8
+
9
+ /** @type {string} */
10
+ export let okText = 'OK';
11
+
12
+ function handleOk() {
13
+ onOk();
14
+ popupStore.close();
15
+ }
16
+ </script>
17
+
18
+ <div class="buttons">
19
+ <Button actionIcon={icons.check} theme="primary" on:click={handleOk}>{okText}</Button>
20
+ </div>
21
+
22
+ <style>
23
+ .buttons {
24
+ display: flex;
25
+ justify-content: flex-end;
26
+ }
27
+ </style>
@@ -0,0 +1,28 @@
1
+ export default AlertPopup;
2
+ type AlertPopup = SvelteComponent<{
3
+ onOk?: (() => void) | undefined;
4
+ okText?: string | undefined;
5
+ }, {
6
+ [evt: string]: CustomEvent<any>;
7
+ }, {}> & {
8
+ $$bindings?: string | undefined;
9
+ };
10
+ declare const AlertPopup: $$__sveltets_2_IsomorphicComponent<{
11
+ onOk?: (() => void) | undefined;
12
+ okText?: string | undefined;
13
+ }, {
14
+ [evt: string]: CustomEvent<any>;
15
+ }, {}, {}, string>;
16
+ 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> {
17
+ new (options: import("svelte").ComponentConstructorOptions<Props>): import("svelte").SvelteComponent<Props, Events, Slots> & {
18
+ $$bindings?: Bindings;
19
+ } & Exports;
20
+ (internal: unknown, props: Props & {
21
+ $$events?: Events;
22
+ $$slots?: Slots;
23
+ }): Exports & {
24
+ $set?: any;
25
+ $on?: any;
26
+ };
27
+ z_$$bindings?: Bindings;
28
+ }
@@ -0,0 +1,39 @@
1
+ <script>
2
+ import { icons } from '../../icons.js';
3
+ import Button from '../Button.svelte';
4
+ import { popupStore } from '../popupStore.js';
5
+
6
+ /** @type {() => void} */
7
+ export let onConfirm = () => {};
8
+
9
+ /** @type {() => void} */
10
+ export let onCancel = () => {};
11
+
12
+ /** @type {string} */
13
+ export let confirmText = 'Confirm';
14
+
15
+ /** @type {string} */
16
+ export let cancelText = 'Cancel';
17
+
18
+ function handleConfirm() {
19
+ onConfirm();
20
+ popupStore.close();
21
+ }
22
+
23
+ function handleCancel() {
24
+ onCancel();
25
+ popupStore.close();
26
+ }
27
+ </script>
28
+
29
+ <div class="buttons">
30
+ <Button theme="primary" actionIcon={icons.check} on:click={handleConfirm}>{confirmText}</Button>
31
+ <Button theme="secondary" actionIcon={icons.crossb} on:click={handleCancel}>{cancelText}</Button>
32
+ </div>
33
+
34
+ <style>
35
+ .buttons {
36
+ display: flex;
37
+ gap: 1rem;
38
+ }
39
+ </style>
@@ -0,0 +1,32 @@
1
+ export default ConfirmPopup;
2
+ type ConfirmPopup = SvelteComponent<{
3
+ onConfirm?: (() => void) | undefined;
4
+ onCancel?: (() => void) | undefined;
5
+ confirmText?: string | undefined;
6
+ cancelText?: string | undefined;
7
+ }, {
8
+ [evt: string]: CustomEvent<any>;
9
+ }, {}> & {
10
+ $$bindings?: string | undefined;
11
+ };
12
+ declare const ConfirmPopup: $$__sveltets_2_IsomorphicComponent<{
13
+ onConfirm?: (() => void) | undefined;
14
+ onCancel?: (() => void) | undefined;
15
+ confirmText?: string | undefined;
16
+ cancelText?: string | undefined;
17
+ }, {
18
+ [evt: string]: CustomEvent<any>;
19
+ }, {}, {}, string>;
20
+ 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> {
21
+ new (options: import("svelte").ComponentConstructorOptions<Props>): import("svelte").SvelteComponent<Props, Events, Slots> & {
22
+ $$bindings?: Bindings;
23
+ } & Exports;
24
+ (internal: unknown, props: Props & {
25
+ $$events?: Events;
26
+ $$slots?: Slots;
27
+ }): Exports & {
28
+ $set?: any;
29
+ $on?: any;
30
+ };
31
+ z_$$bindings?: Bindings;
32
+ }
@@ -0,0 +1,67 @@
1
+ <script>
2
+ import { fade, fly } from 'svelte/transition';
3
+ import { backOut } from 'svelte/easing';
4
+ import { popupStore } from '../popupStore.js';
5
+ import BaseContainer from '../../Base/BaseContainer.svelte';
6
+ import IconButton from '../IconButton.svelte';
7
+ import TextHeader from '../../Structure/TextHeader.svelte';
8
+ import { icons } from '../../icons.js';
9
+ </script>
10
+
11
+ {#if $popupStore.isOpen}
12
+ <div class="overlay" transition:fade={{ duration: 250 }} on:click={popupStore.close} role="presentation">
13
+ <div
14
+ class="dialog"
15
+ transition:fly={{ y: 30, duration: 300, easing: backOut }}
16
+ on:click|stopPropagation
17
+ on:keydown|stopPropagation
18
+ role="dialog"
19
+ tabindex="-1"
20
+ >
21
+ <BaseContainer padding="1.5rem" borderRadiusTopLeft="35px" borderRadiusTopRight="35px" borderRadiusBottomLeft="35px" borderRadiusBottomRight="35px" theme="filled">
22
+ <header>
23
+ <TextHeader title={$popupStore.title} subtitle={$popupStore.subtitle || ''} />
24
+ <div class="close-btn">
25
+ <IconButton svg={icons.cross} size="20px" variant="toned" on:click={popupStore.close} />
26
+ </div>
27
+ </header>
28
+ <main>
29
+ <svelte:component this={$popupStore.component} {...$popupStore.props} />
30
+ </main>
31
+ </BaseContainer>
32
+ </div>
33
+ </div>
34
+ {/if}
35
+
36
+ <style>
37
+ .overlay {
38
+ position: fixed;
39
+ inset: 0;
40
+ background: #0b070eda;
41
+ backdrop-filter: blur(3px);
42
+ display: grid;
43
+ place-items: center;
44
+ z-index: 9999;
45
+ }
46
+
47
+ .dialog {
48
+ width: min(90%, 600px);
49
+ max-height: 80vh;
50
+ zoom: 0.92;
51
+ }
52
+
53
+ header {
54
+ display: flex;
55
+ justify-content: space-between;
56
+ align-items: flex-start;
57
+ gap: 1rem;
58
+ }
59
+
60
+ .close-btn {
61
+ opacity: 0.5;
62
+ }
63
+
64
+ main {
65
+ margin-top: 1.5rem;
66
+ }
67
+ </style>