nebula-cms 0.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.
- package/.claude/settings.local.json +42 -0
- package/.github/workflows/ci.yml +31 -0
- package/.mcp.json +12 -0
- package/.prettierignore +5 -0
- package/.prettierrc.cjs +22 -0
- package/AGENTS.md +183 -0
- package/LICENSE +201 -0
- package/README.md +128 -0
- package/package.json +74 -0
- package/playground/.claude/settings.local.json +5 -0
- package/playground/astro.config.mjs +7 -0
- package/playground/node_modules/.bin/astro +21 -0
- package/playground/node_modules/.bin/rollup +21 -0
- package/playground/node_modules/.bin/tsc +21 -0
- package/playground/node_modules/.bin/tsserver +21 -0
- package/playground/node_modules/.bin/vite +21 -0
- package/playground/node_modules/.vite/_svelte_metadata.json +1 -0
- package/playground/node_modules/.vite/deps/@astrojs_svelte_client__js.js +80 -0
- package/playground/node_modules/.vite/deps/@astrojs_svelte_client__js.js.map +7 -0
- package/playground/node_modules/.vite/deps/_metadata.json +184 -0
- package/playground/node_modules/.vite/deps/astro___aria-query.js +6776 -0
- package/playground/node_modules/.vite/deps/astro___aria-query.js.map +7 -0
- package/playground/node_modules/.vite/deps/astro___axobject-query.js +3754 -0
- package/playground/node_modules/.vite/deps/astro___axobject-query.js.map +7 -0
- package/playground/node_modules/.vite/deps/astro___html-escaper.js +34 -0
- package/playground/node_modules/.vite/deps/astro___html-escaper.js.map +7 -0
- package/playground/node_modules/.vite/deps/chunk-AJXJMYAF.js +0 -0
- package/playground/node_modules/.vite/deps/chunk-AJXJMYAF.js.map +7 -0
- package/playground/node_modules/.vite/deps/chunk-ALJIOON6.js +1005 -0
- package/playground/node_modules/.vite/deps/chunk-ALJIOON6.js.map +7 -0
- package/playground/node_modules/.vite/deps/chunk-BUSYA2B4.js +8 -0
- package/playground/node_modules/.vite/deps/chunk-BUSYA2B4.js.map +7 -0
- package/playground/node_modules/.vite/deps/chunk-CNYJBM5F.js +21 -0
- package/playground/node_modules/.vite/deps/chunk-CNYJBM5F.js.map +7 -0
- package/playground/node_modules/.vite/deps/chunk-DBPNBGEI.js +223 -0
- package/playground/node_modules/.vite/deps/chunk-DBPNBGEI.js.map +7 -0
- package/playground/node_modules/.vite/deps/chunk-G3C2FXJT.js +204 -0
- package/playground/node_modules/.vite/deps/chunk-G3C2FXJT.js.map +7 -0
- package/playground/node_modules/.vite/deps/chunk-GKDKFWC5.js +27 -0
- package/playground/node_modules/.vite/deps/chunk-GKDKFWC5.js.map +7 -0
- package/playground/node_modules/.vite/deps/chunk-HNCLEOC5.js +4376 -0
- package/playground/node_modules/.vite/deps/chunk-HNCLEOC5.js.map +7 -0
- package/playground/node_modules/.vite/deps/chunk-JICYXBFU.js +688 -0
- package/playground/node_modules/.vite/deps/chunk-JICYXBFU.js.map +7 -0
- package/playground/node_modules/.vite/deps/chunk-KCUTL6DD.js +5099 -0
- package/playground/node_modules/.vite/deps/chunk-KCUTL6DD.js.map +7 -0
- package/playground/node_modules/.vite/deps/chunk-ZP4UNCSN.js +23 -0
- package/playground/node_modules/.vite/deps/chunk-ZP4UNCSN.js.map +7 -0
- package/playground/node_modules/.vite/deps/chunk-ZREFNRZZ.js +148 -0
- package/playground/node_modules/.vite/deps/chunk-ZREFNRZZ.js.map +7 -0
- package/playground/node_modules/.vite/deps/package.json +3 -0
- package/playground/node_modules/.vite/deps/smol-toml.js +843 -0
- package/playground/node_modules/.vite/deps/smol-toml.js.map +7 -0
- package/playground/node_modules/.vite/deps/svelte.js +55 -0
- package/playground/node_modules/.vite/deps/svelte.js.map +7 -0
- package/playground/node_modules/.vite/deps/svelte___clsx.js +9 -0
- package/playground/node_modules/.vite/deps/svelte___clsx.js.map +7 -0
- package/playground/node_modules/.vite/deps/svelte_animate.js +57 -0
- package/playground/node_modules/.vite/deps/svelte_animate.js.map +7 -0
- package/playground/node_modules/.vite/deps/svelte_attachments.js +15 -0
- package/playground/node_modules/.vite/deps/svelte_attachments.js.map +7 -0
- package/playground/node_modules/.vite/deps/svelte_easing.js +67 -0
- package/playground/node_modules/.vite/deps/svelte_easing.js.map +7 -0
- package/playground/node_modules/.vite/deps/svelte_events.js +11 -0
- package/playground/node_modules/.vite/deps/svelte_events.js.map +7 -0
- package/playground/node_modules/.vite/deps/svelte_internal.js +5 -0
- package/playground/node_modules/.vite/deps/svelte_internal.js.map +7 -0
- package/playground/node_modules/.vite/deps/svelte_internal_client.js +402 -0
- package/playground/node_modules/.vite/deps/svelte_internal_client.js.map +7 -0
- package/playground/node_modules/.vite/deps/svelte_internal_disclose-version.js +10 -0
- package/playground/node_modules/.vite/deps/svelte_internal_disclose-version.js.map +7 -0
- package/playground/node_modules/.vite/deps/svelte_internal_flags_async.js +8 -0
- package/playground/node_modules/.vite/deps/svelte_internal_flags_async.js.map +7 -0
- package/playground/node_modules/.vite/deps/svelte_internal_flags_legacy.js +8 -0
- package/playground/node_modules/.vite/deps/svelte_internal_flags_legacy.js.map +7 -0
- package/playground/node_modules/.vite/deps/svelte_internal_flags_tracing.js +8 -0
- package/playground/node_modules/.vite/deps/svelte_internal_flags_tracing.js.map +7 -0
- package/playground/node_modules/.vite/deps/svelte_legacy.js +35 -0
- package/playground/node_modules/.vite/deps/svelte_legacy.js.map +7 -0
- package/playground/node_modules/.vite/deps/svelte_motion.js +545 -0
- package/playground/node_modules/.vite/deps/svelte_motion.js.map +7 -0
- package/playground/node_modules/.vite/deps/svelte_reactivity.js +29 -0
- package/playground/node_modules/.vite/deps/svelte_reactivity.js.map +7 -0
- package/playground/node_modules/.vite/deps/svelte_reactivity_window.js +127 -0
- package/playground/node_modules/.vite/deps/svelte_reactivity_window.js.map +7 -0
- package/playground/node_modules/.vite/deps/svelte_store.js +103 -0
- package/playground/node_modules/.vite/deps/svelte_store.js.map +7 -0
- package/playground/node_modules/.vite/deps/svelte_transition.js +208 -0
- package/playground/node_modules/.vite/deps/svelte_transition.js.map +7 -0
- package/playground/package.json +16 -0
- package/playground/pnpm-lock.yaml +3167 -0
- package/playground/src/content/authors/jane-doe.json +8 -0
- package/playground/src/content/config/build.toml +2 -0
- package/playground/src/content/courses/web-fundamentals.json +29 -0
- package/playground/src/content/docs/advanced.mdx +6 -0
- package/playground/src/content/docs/intro.md +6 -0
- package/playground/src/content/guides/getting-started.mdx +6 -0
- package/playground/src/content/posts/hello-world.md +7 -0
- package/playground/src/content/products/t-shirt.json +16 -0
- package/playground/src/content/recipes/pancakes.mdoc +8 -0
- package/playground/src/content/settings/site.yml +2 -0
- package/playground/src/content.config.ts +198 -0
- package/playground/src/env.d.ts +1 -0
- package/playground/src/pages/index.astro +11 -0
- package/playground/src/pages/nebula.astro +14 -0
- package/pnpm-workspace.yaml +2 -0
- package/scripts/subset-icons.mjs +178 -0
- package/src/astro/index.ts +295 -0
- package/src/client/Admin.svelte +283 -0
- package/src/client/components/BackendPicker.svelte +291 -0
- package/src/client/components/DraftChip.svelte +46 -0
- package/src/client/components/MetadataForm.svelte +56 -0
- package/src/client/components/ThemeToggle.svelte +18 -0
- package/src/client/components/dialogs/DeleteDraftDialog.svelte +51 -0
- package/src/client/components/dialogs/FilenameDialog.svelte +129 -0
- package/src/client/components/editor/EditorPane.svelte +227 -0
- package/src/client/components/editor/EditorTabs.svelte +81 -0
- package/src/client/components/editor/EditorToolbar.svelte +131 -0
- package/src/client/components/editor/FormatSelector.svelte +66 -0
- package/src/client/components/editor/Toolbar.svelte +17 -0
- package/src/client/components/fields/ArrayField.svelte +339 -0
- package/src/client/components/fields/ArrayItem.svelte +325 -0
- package/src/client/components/fields/BooleanField.svelte +114 -0
- package/src/client/components/fields/DateField.svelte +82 -0
- package/src/client/components/fields/EnumField.svelte +74 -0
- package/src/client/components/fields/FieldWrapper.svelte +96 -0
- package/src/client/components/fields/NumberField.svelte +99 -0
- package/src/client/components/fields/ObjectField.svelte +121 -0
- package/src/client/components/fields/SchemaField.svelte +107 -0
- package/src/client/components/fields/StringField.svelte +104 -0
- package/src/client/components/sidebar/AdminSidebar.svelte +339 -0
- package/src/client/components/sidebar/AdminSidebarSort.svelte +123 -0
- package/src/client/css/a11y.css +14 -0
- package/src/client/css/btn.css +113 -0
- package/src/client/css/dialog.css +29 -0
- package/src/client/css/field-input.css +39 -0
- package/src/client/css/reset.css +59 -0
- package/src/client/css/theme.css +77 -0
- package/src/client/index.ts +1 -0
- package/src/client/js/drafts/merge.svelte.ts +121 -0
- package/src/client/js/drafts/ops.svelte.ts +227 -0
- package/src/client/js/drafts/storage.ts +108 -0
- package/src/client/js/drafts/workers/diff.ts +40 -0
- package/src/client/js/editor/editor.svelte.ts +343 -0
- package/src/client/js/editor/languages.ts +98 -0
- package/src/client/js/editor/link-wrap.ts +45 -0
- package/src/client/js/editor/markdown-shortcuts.ts +261 -0
- package/src/client/js/handlers/admin.ts +246 -0
- package/src/client/js/state/dialogs.svelte.ts +35 -0
- package/src/client/js/state/router.svelte.ts +156 -0
- package/src/client/js/state/schema.svelte.ts +140 -0
- package/src/client/js/state/state.svelte.ts +334 -0
- package/src/client/js/state/theme.svelte.ts +173 -0
- package/src/client/js/storage/adapter.ts +102 -0
- package/src/client/js/storage/client.ts +150 -0
- package/src/client/js/storage/db.ts +36 -0
- package/src/client/js/storage/fsa.ts +110 -0
- package/src/client/js/storage/github.ts +297 -0
- package/src/client/js/storage/storage.ts +83 -0
- package/src/client/js/storage/workers/frontmatter.ts +320 -0
- package/src/client/js/storage/workers/storage.ts +177 -0
- package/src/client/js/storage/workers/toml-parser.ts +106 -0
- package/src/client/js/storage/workers/yaml-parser.ts +132 -0
- package/src/client/js/utils/file-types.ts +192 -0
- package/src/client/js/utils/format.ts +16 -0
- package/src/client/js/utils/frontmatter.ts +38 -0
- package/src/client/js/utils/schema-utils.ts +295 -0
- package/src/client/js/utils/slug.ts +18 -0
- package/src/client/js/utils/sort.ts +84 -0
- package/src/client/js/utils/stable-stringify.ts +27 -0
- package/src/client/js/utils/url-utils.ts +38 -0
- package/src/types.ts +25 -0
- package/src/virtual.d.ts +22 -0
- package/svelte.config.js +4 -0
- package/tests/astro/build.test.ts +63 -0
- package/tests/astro/index.test.ts +689 -0
- package/tests/client/components/Admin.test.ts +446 -0
- package/tests/client/components/BackendPicker.test.ts +239 -0
- package/tests/client/components/DraftChip.test.ts +53 -0
- package/tests/client/components/MetadataForm.test.ts +164 -0
- package/tests/client/components/dialogs/DeleteDraftDialog.test.ts +91 -0
- package/tests/client/components/dialogs/FilenameDialog.test.ts +209 -0
- package/tests/client/components/dialogs/dialog-stubs.ts +19 -0
- package/tests/client/components/editor/EditorPane.test.ts +100 -0
- package/tests/client/components/editor/EditorTabs.test.ts +253 -0
- package/tests/client/components/editor/EditorToolbar.test.ts +252 -0
- package/tests/client/components/editor/fixtures.ts +31 -0
- package/tests/client/components/fields/ArrayField.test.ts +197 -0
- package/tests/client/components/fields/BooleanField.test.ts +206 -0
- package/tests/client/components/fields/DateField.test.ts +210 -0
- package/tests/client/components/fields/EnumField.test.ts +246 -0
- package/tests/client/components/fields/NumberField.test.ts +240 -0
- package/tests/client/components/fields/ObjectField.test.ts +157 -0
- package/tests/client/components/fields/SchemaField.test.ts +190 -0
- package/tests/client/components/fields/StringField.test.ts +223 -0
- package/tests/client/components/sidebar/AdminSidebar.test.ts +285 -0
- package/tests/client/components/sidebar/AdminSidebarSort.test.ts +135 -0
- package/tests/client/components/sidebar/sort-mock.ts +23 -0
- package/tests/client/js/drafts/fixtures.ts +22 -0
- package/tests/client/js/drafts/merge.test.ts +282 -0
- package/tests/client/js/drafts/ops.test.ts +658 -0
- package/tests/client/js/drafts/storage.test.ts +200 -0
- package/tests/client/js/drafts/workers/diff.test.ts +165 -0
- package/tests/client/js/editor/editor.test.ts +616 -0
- package/tests/client/js/editor/link-wrap.test.ts +225 -0
- package/tests/client/js/editor/markdown-shortcuts.test.ts +370 -0
- package/tests/client/js/handlers/admin.test.ts +467 -0
- package/tests/client/js/state/router.test.ts +619 -0
- package/tests/client/js/state/schema.test.ts +266 -0
- package/tests/client/js/state/state.test.ts +328 -0
- package/tests/client/js/storage/adapter.test.ts +115 -0
- package/tests/client/js/storage/client.test.ts +250 -0
- package/tests/client/js/storage/db.test.ts +59 -0
- package/tests/client/js/storage/fsa.test.ts +284 -0
- package/tests/client/js/storage/github.test.ts +349 -0
- package/tests/client/js/storage/mock-port.ts +95 -0
- package/tests/client/js/storage/storage.test.ts +77 -0
- package/tests/client/js/storage/workers/frontmatter.test.ts +479 -0
- package/tests/client/js/storage/workers/storage.test.ts +299 -0
- package/tests/client/js/storage/workers/toml-parser.test.ts +169 -0
- package/tests/client/js/storage/workers/yaml-parser.test.ts +168 -0
- package/tests/client/js/utils/file-types.test.ts +268 -0
- package/tests/client/js/utils/frontmatter.test.ts +87 -0
- package/tests/client/js/utils/schema-utils.test.ts +318 -0
- package/tests/client/js/utils/slug.test.ts +58 -0
- package/tests/client/js/utils/sort.test.ts +276 -0
- package/tests/client/js/utils/stable-stringify.test.ts +68 -0
- package/tests/client/js/utils/url-utils.test.ts +70 -0
- package/tests/e2e/backend-connection.test.ts +301 -0
- package/tests/e2e/draft-lifecycle.test.ts +388 -0
- package/tests/e2e/editing.test.ts +355 -0
- package/tests/e2e/github-adapter.test.ts +330 -0
- package/tests/e2e/helpers/mock-adapter.ts +166 -0
- package/tests/e2e/helpers/test-app.ts +155 -0
- package/tests/e2e/navigation.test.ts +358 -0
- package/tests/e2e/publishing.test.ts +345 -0
- package/tests/e2e/unsaved-changes.test.ts +317 -0
- package/tests/setup.ts +2 -0
- package/tests/stubs/codemirror.ts +197 -0
- package/tsconfig.json +19 -0
- package/vitest.config.ts +178 -0
|
@@ -0,0 +1,4376 @@
|
|
|
1
|
+
import {
|
|
2
|
+
clsx
|
|
3
|
+
} from "./chunk-CNYJBM5F.js";
|
|
4
|
+
import {
|
|
5
|
+
append,
|
|
6
|
+
assign_nodes,
|
|
7
|
+
can_delegate_event,
|
|
8
|
+
createClassComponent,
|
|
9
|
+
create_fragment_from_html,
|
|
10
|
+
create_trusted_html,
|
|
11
|
+
hash,
|
|
12
|
+
is_capture_event,
|
|
13
|
+
is_raw_text_element,
|
|
14
|
+
is_void,
|
|
15
|
+
normalize_attribute,
|
|
16
|
+
sanitize_location,
|
|
17
|
+
set_should_intro,
|
|
18
|
+
should_intro
|
|
19
|
+
} from "./chunk-ALJIOON6.js";
|
|
20
|
+
import {
|
|
21
|
+
create_event,
|
|
22
|
+
delegate,
|
|
23
|
+
delegated
|
|
24
|
+
} from "./chunk-G3C2FXJT.js";
|
|
25
|
+
import {
|
|
26
|
+
ATTACHMENT_KEY,
|
|
27
|
+
BLOCK_EFFECT,
|
|
28
|
+
BRANCH_EFFECT,
|
|
29
|
+
Batch,
|
|
30
|
+
COMMENT_NODE,
|
|
31
|
+
DESTROYED,
|
|
32
|
+
DESTROYING,
|
|
33
|
+
DOCUMENT_FRAGMENT_NODE,
|
|
34
|
+
EACH_INDEX_REACTIVE,
|
|
35
|
+
EACH_IS_ANIMATED,
|
|
36
|
+
EACH_IS_CONTROLLED,
|
|
37
|
+
EACH_ITEM_IMMUTABLE,
|
|
38
|
+
EACH_ITEM_REACTIVE,
|
|
39
|
+
EFFECT_OFFSCREEN,
|
|
40
|
+
EFFECT_PRESERVED,
|
|
41
|
+
EFFECT_TRANSPARENT,
|
|
42
|
+
ELEMENT_NODE,
|
|
43
|
+
FILENAME,
|
|
44
|
+
HEAD_EFFECT,
|
|
45
|
+
HMR,
|
|
46
|
+
HYDRATION_END,
|
|
47
|
+
HYDRATION_ERROR,
|
|
48
|
+
HYDRATION_START,
|
|
49
|
+
HYDRATION_START_ELSE,
|
|
50
|
+
INERT,
|
|
51
|
+
IS_XHTML,
|
|
52
|
+
LEGACY_PROPS,
|
|
53
|
+
LOADING_ATTR_SYMBOL,
|
|
54
|
+
NAMESPACE_HTML,
|
|
55
|
+
NAMESPACE_MATHML,
|
|
56
|
+
NAMESPACE_SVG,
|
|
57
|
+
PROPS_IS_BINDABLE,
|
|
58
|
+
PROPS_IS_IMMUTABLE,
|
|
59
|
+
PROPS_IS_LAZY_INITIAL,
|
|
60
|
+
PROPS_IS_RUNES,
|
|
61
|
+
PROPS_IS_UPDATED,
|
|
62
|
+
REACTION_RAN,
|
|
63
|
+
STATE_SYMBOL,
|
|
64
|
+
TRANSITION_GLOBAL,
|
|
65
|
+
TRANSITION_IN,
|
|
66
|
+
TRANSITION_OUT,
|
|
67
|
+
UNINITIALIZED,
|
|
68
|
+
active_effect,
|
|
69
|
+
active_reaction,
|
|
70
|
+
add_form_reset_listener,
|
|
71
|
+
array_from,
|
|
72
|
+
autofocus,
|
|
73
|
+
bind_invalid_checkbox_value,
|
|
74
|
+
block,
|
|
75
|
+
branch,
|
|
76
|
+
capture,
|
|
77
|
+
capture_store_binding,
|
|
78
|
+
clear_text_content,
|
|
79
|
+
component_api_changed,
|
|
80
|
+
component_api_invalid_new,
|
|
81
|
+
component_context,
|
|
82
|
+
create_comment,
|
|
83
|
+
create_element,
|
|
84
|
+
create_text,
|
|
85
|
+
current_batch,
|
|
86
|
+
deep_read_state,
|
|
87
|
+
define_property,
|
|
88
|
+
derived2 as derived,
|
|
89
|
+
derived_safe_equal,
|
|
90
|
+
destroy_effect,
|
|
91
|
+
dev_current_component_function,
|
|
92
|
+
dev_stack,
|
|
93
|
+
dynamic_void_element_content,
|
|
94
|
+
each_key_duplicate,
|
|
95
|
+
each_key_volatile,
|
|
96
|
+
eager_effect,
|
|
97
|
+
effect,
|
|
98
|
+
effect_root,
|
|
99
|
+
experimental_async_required,
|
|
100
|
+
flatten,
|
|
101
|
+
flushSync,
|
|
102
|
+
get2 as get,
|
|
103
|
+
get_abort_signal_outside_reaction,
|
|
104
|
+
get_descriptor,
|
|
105
|
+
get_descriptors,
|
|
106
|
+
get_error,
|
|
107
|
+
get_first_child,
|
|
108
|
+
get_next_sibling,
|
|
109
|
+
get_prototype_of,
|
|
110
|
+
has_own_property,
|
|
111
|
+
hydratable_missing_but_required,
|
|
112
|
+
hydrate_next,
|
|
113
|
+
hydrate_node,
|
|
114
|
+
hydrating,
|
|
115
|
+
increment_pending,
|
|
116
|
+
internal_set,
|
|
117
|
+
invalid_snippet,
|
|
118
|
+
invalid_snippet_arguments,
|
|
119
|
+
is,
|
|
120
|
+
is_array,
|
|
121
|
+
is_destroying_effect,
|
|
122
|
+
is_flushing_sync,
|
|
123
|
+
is_function,
|
|
124
|
+
is_promise,
|
|
125
|
+
is_runes,
|
|
126
|
+
lifecycle_legacy_only,
|
|
127
|
+
lifecycle_outside_component,
|
|
128
|
+
listen,
|
|
129
|
+
listen_to_event_and_reset_event,
|
|
130
|
+
managed,
|
|
131
|
+
move_effect,
|
|
132
|
+
mutable_source,
|
|
133
|
+
noop,
|
|
134
|
+
object_keys,
|
|
135
|
+
pause_effect,
|
|
136
|
+
previous_batch,
|
|
137
|
+
props_invalid_value,
|
|
138
|
+
props_rest_readonly,
|
|
139
|
+
proxy,
|
|
140
|
+
queue_micro_task,
|
|
141
|
+
read_hydration_instruction,
|
|
142
|
+
remove_effect_dom,
|
|
143
|
+
render_effect,
|
|
144
|
+
reset,
|
|
145
|
+
resume_effect,
|
|
146
|
+
run,
|
|
147
|
+
run_after_blockers,
|
|
148
|
+
run_all,
|
|
149
|
+
rune_outside_svelte,
|
|
150
|
+
safe_not_equal,
|
|
151
|
+
set,
|
|
152
|
+
set_active_effect,
|
|
153
|
+
set_active_reaction,
|
|
154
|
+
set_dev_current_component_function,
|
|
155
|
+
set_hydrate_node,
|
|
156
|
+
set_hydrating,
|
|
157
|
+
should_defer_append,
|
|
158
|
+
skip_nodes,
|
|
159
|
+
snapshot,
|
|
160
|
+
snippet_without_render_tag,
|
|
161
|
+
source,
|
|
162
|
+
store_invalid_shape,
|
|
163
|
+
svelte_element_invalid_this_value,
|
|
164
|
+
teardown,
|
|
165
|
+
template_effect,
|
|
166
|
+
tick,
|
|
167
|
+
unset_context,
|
|
168
|
+
untrack,
|
|
169
|
+
update,
|
|
170
|
+
user_effect,
|
|
171
|
+
user_pre_effect,
|
|
172
|
+
validate_effect,
|
|
173
|
+
without_reactive_context
|
|
174
|
+
} from "./chunk-KCUTL6DD.js";
|
|
175
|
+
import {
|
|
176
|
+
assignment_value_stale,
|
|
177
|
+
binding_property_non_reactive,
|
|
178
|
+
console_log_state,
|
|
179
|
+
hydratable_missing_but_expected,
|
|
180
|
+
hydration_attribute_changed,
|
|
181
|
+
hydration_html_changed,
|
|
182
|
+
hydration_mismatch,
|
|
183
|
+
invalid_raw_snippet_render,
|
|
184
|
+
ownership_invalid_binding,
|
|
185
|
+
ownership_invalid_mutation,
|
|
186
|
+
select_multiple_invalid_value,
|
|
187
|
+
true_default
|
|
188
|
+
} from "./chunk-DBPNBGEI.js";
|
|
189
|
+
import {
|
|
190
|
+
async_mode_flag,
|
|
191
|
+
legacy_mode_flag
|
|
192
|
+
} from "./chunk-ZP4UNCSN.js";
|
|
193
|
+
|
|
194
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/attachments/index.js
|
|
195
|
+
function createAttachmentKey() {
|
|
196
|
+
return Symbol(ATTACHMENT_KEY);
|
|
197
|
+
}
|
|
198
|
+
function fromAction(action2, fn = (
|
|
199
|
+
/** @type {() => T} */
|
|
200
|
+
noop
|
|
201
|
+
)) {
|
|
202
|
+
return (element2) => {
|
|
203
|
+
const { update: update2, destroy } = untrack(() => action2(element2, fn()) ?? {});
|
|
204
|
+
if (update2) {
|
|
205
|
+
var ran = false;
|
|
206
|
+
render_effect(() => {
|
|
207
|
+
const arg = fn();
|
|
208
|
+
if (ran) update2(arg);
|
|
209
|
+
});
|
|
210
|
+
ran = true;
|
|
211
|
+
}
|
|
212
|
+
if (destroy) {
|
|
213
|
+
teardown(destroy);
|
|
214
|
+
}
|
|
215
|
+
};
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dev/assign.js
|
|
219
|
+
function compare(a, b, property, location) {
|
|
220
|
+
if (a !== b && typeof b === "object" && STATE_SYMBOL in b) {
|
|
221
|
+
assignment_value_stale(
|
|
222
|
+
property,
|
|
223
|
+
/** @type {string} */
|
|
224
|
+
sanitize_location(location)
|
|
225
|
+
);
|
|
226
|
+
}
|
|
227
|
+
return a;
|
|
228
|
+
}
|
|
229
|
+
function assign(object, property, operator, rhs, location) {
|
|
230
|
+
return compare(
|
|
231
|
+
operator === "=" ? object[property] = rhs : operator === "&&=" ? object[property] &&= rhs() : operator === "||=" ? object[property] ||= rhs() : operator === "??=" ? object[property] ??= rhs() : null,
|
|
232
|
+
untrack(() => object[property]),
|
|
233
|
+
property,
|
|
234
|
+
location
|
|
235
|
+
);
|
|
236
|
+
}
|
|
237
|
+
async function assign_async(object, property, operator, rhs, location) {
|
|
238
|
+
return compare(
|
|
239
|
+
operator === "=" ? object[property] = await rhs : operator === "&&=" ? object[property] &&= await rhs() : operator === "||=" ? object[property] ||= await rhs() : operator === "??=" ? object[property] ??= await rhs() : null,
|
|
240
|
+
untrack(() => object[property]),
|
|
241
|
+
property,
|
|
242
|
+
location
|
|
243
|
+
);
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dev/css.js
|
|
247
|
+
var all_styles = /* @__PURE__ */ new Map();
|
|
248
|
+
function register_style(hash2, style) {
|
|
249
|
+
var styles = all_styles.get(hash2);
|
|
250
|
+
if (!styles) {
|
|
251
|
+
styles = /* @__PURE__ */ new Set();
|
|
252
|
+
all_styles.set(hash2, styles);
|
|
253
|
+
}
|
|
254
|
+
styles.add(style);
|
|
255
|
+
}
|
|
256
|
+
function cleanup_styles(hash2) {
|
|
257
|
+
var styles = all_styles.get(hash2);
|
|
258
|
+
if (!styles) return;
|
|
259
|
+
for (const style of styles) {
|
|
260
|
+
style.remove();
|
|
261
|
+
}
|
|
262
|
+
all_styles.delete(hash2);
|
|
263
|
+
}
|
|
264
|
+
|
|
265
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dev/elements.js
|
|
266
|
+
function add_locations(fn, filename, locations) {
|
|
267
|
+
return (...args) => {
|
|
268
|
+
const dom = fn(...args);
|
|
269
|
+
var node = hydrating ? dom : dom.nodeType === DOCUMENT_FRAGMENT_NODE ? dom.firstChild : dom;
|
|
270
|
+
assign_locations(node, filename, locations);
|
|
271
|
+
return dom;
|
|
272
|
+
};
|
|
273
|
+
}
|
|
274
|
+
function assign_location(element2, filename, location) {
|
|
275
|
+
element2.__svelte_meta = {
|
|
276
|
+
parent: dev_stack,
|
|
277
|
+
loc: { file: filename, line: location[0], column: location[1] }
|
|
278
|
+
};
|
|
279
|
+
if (location[2]) {
|
|
280
|
+
assign_locations(element2.firstChild, filename, location[2]);
|
|
281
|
+
}
|
|
282
|
+
}
|
|
283
|
+
function assign_locations(node, filename, locations) {
|
|
284
|
+
var i = 0;
|
|
285
|
+
var depth = 0;
|
|
286
|
+
while (node && i < locations.length) {
|
|
287
|
+
if (hydrating && node.nodeType === COMMENT_NODE) {
|
|
288
|
+
var comment2 = (
|
|
289
|
+
/** @type {Comment} */
|
|
290
|
+
node
|
|
291
|
+
);
|
|
292
|
+
if (comment2.data[0] === HYDRATION_START) depth += 1;
|
|
293
|
+
else if (comment2.data[0] === HYDRATION_END) depth -= 1;
|
|
294
|
+
}
|
|
295
|
+
if (depth === 0 && node.nodeType === ELEMENT_NODE) {
|
|
296
|
+
assign_location(
|
|
297
|
+
/** @type {Element} */
|
|
298
|
+
node,
|
|
299
|
+
filename,
|
|
300
|
+
locations[i++]
|
|
301
|
+
);
|
|
302
|
+
}
|
|
303
|
+
node = node.nextSibling;
|
|
304
|
+
}
|
|
305
|
+
}
|
|
306
|
+
|
|
307
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dev/hmr.js
|
|
308
|
+
function hmr(fn) {
|
|
309
|
+
const current = source(fn);
|
|
310
|
+
function wrapper(anchor, props) {
|
|
311
|
+
let component2 = {};
|
|
312
|
+
let instance = {};
|
|
313
|
+
let effect2;
|
|
314
|
+
let ran = false;
|
|
315
|
+
let start = create_comment();
|
|
316
|
+
let end = create_comment();
|
|
317
|
+
if (!hydrating) {
|
|
318
|
+
anchor.before(start);
|
|
319
|
+
}
|
|
320
|
+
block(() => {
|
|
321
|
+
if (component2 === (component2 = get(current))) {
|
|
322
|
+
return;
|
|
323
|
+
}
|
|
324
|
+
if (effect2) {
|
|
325
|
+
for (var k in instance) delete instance[k];
|
|
326
|
+
destroy_effect(effect2);
|
|
327
|
+
}
|
|
328
|
+
effect2 = branch(() => {
|
|
329
|
+
if (ran) set_should_intro(false);
|
|
330
|
+
var result = (
|
|
331
|
+
// @ts-expect-error
|
|
332
|
+
new.target ? new component2(anchor, props) : component2(anchor, props)
|
|
333
|
+
);
|
|
334
|
+
if (result) {
|
|
335
|
+
Object.defineProperties(instance, Object.getOwnPropertyDescriptors(result));
|
|
336
|
+
}
|
|
337
|
+
if (ran) set_should_intro(true);
|
|
338
|
+
});
|
|
339
|
+
}, EFFECT_TRANSPARENT);
|
|
340
|
+
ran = true;
|
|
341
|
+
if (hydrating) {
|
|
342
|
+
anchor.before(start);
|
|
343
|
+
anchor = hydrate_node;
|
|
344
|
+
}
|
|
345
|
+
anchor.before(end);
|
|
346
|
+
assign_nodes(start, end);
|
|
347
|
+
return instance;
|
|
348
|
+
}
|
|
349
|
+
wrapper[FILENAME] = fn[FILENAME];
|
|
350
|
+
wrapper[HMR] = {
|
|
351
|
+
fn,
|
|
352
|
+
current,
|
|
353
|
+
update: (incoming) => {
|
|
354
|
+
set(wrapper[HMR].current, incoming[HMR].fn);
|
|
355
|
+
incoming[HMR].current = wrapper[HMR].current;
|
|
356
|
+
}
|
|
357
|
+
};
|
|
358
|
+
return wrapper;
|
|
359
|
+
}
|
|
360
|
+
|
|
361
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dev/ownership.js
|
|
362
|
+
function create_ownership_validator(props) {
|
|
363
|
+
const component2 = component_context?.function;
|
|
364
|
+
const parent = component_context?.p?.function;
|
|
365
|
+
return {
|
|
366
|
+
/**
|
|
367
|
+
* @param {string} prop
|
|
368
|
+
* @param {any[]} path
|
|
369
|
+
* @param {any} result
|
|
370
|
+
* @param {number} line
|
|
371
|
+
* @param {number} column
|
|
372
|
+
*/
|
|
373
|
+
mutation: (prop2, path, result, line, column) => {
|
|
374
|
+
const name = path[0];
|
|
375
|
+
if (is_bound_or_unset(props, name) || !parent) {
|
|
376
|
+
return result;
|
|
377
|
+
}
|
|
378
|
+
let value = props;
|
|
379
|
+
for (let i = 0; i < path.length - 1; i++) {
|
|
380
|
+
value = value[path[i]];
|
|
381
|
+
if (!value?.[STATE_SYMBOL]) {
|
|
382
|
+
return result;
|
|
383
|
+
}
|
|
384
|
+
}
|
|
385
|
+
const location = sanitize_location(`${component2[FILENAME]}:${line}:${column}`);
|
|
386
|
+
ownership_invalid_mutation(name, location, prop2, parent[FILENAME]);
|
|
387
|
+
return result;
|
|
388
|
+
},
|
|
389
|
+
/**
|
|
390
|
+
* @param {any} key
|
|
391
|
+
* @param {any} child_component
|
|
392
|
+
* @param {() => any} value
|
|
393
|
+
*/
|
|
394
|
+
binding: (key2, child_component, value) => {
|
|
395
|
+
if (!is_bound_or_unset(props, key2) && parent && value()?.[STATE_SYMBOL]) {
|
|
396
|
+
ownership_invalid_binding(
|
|
397
|
+
component2[FILENAME],
|
|
398
|
+
key2,
|
|
399
|
+
child_component[FILENAME],
|
|
400
|
+
parent[FILENAME]
|
|
401
|
+
);
|
|
402
|
+
}
|
|
403
|
+
}
|
|
404
|
+
};
|
|
405
|
+
}
|
|
406
|
+
function is_bound_or_unset(props, prop_name) {
|
|
407
|
+
const is_entry_props = STATE_SYMBOL in props || LEGACY_PROPS in props;
|
|
408
|
+
return !!get_descriptor(props, prop_name)?.set || is_entry_props && prop_name in props || !(prop_name in props);
|
|
409
|
+
}
|
|
410
|
+
|
|
411
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dev/legacy.js
|
|
412
|
+
function check_target(target) {
|
|
413
|
+
if (target) {
|
|
414
|
+
component_api_invalid_new(target[FILENAME] ?? "a component", target.name);
|
|
415
|
+
}
|
|
416
|
+
}
|
|
417
|
+
function legacy_api() {
|
|
418
|
+
const component2 = component_context?.function;
|
|
419
|
+
function error(method) {
|
|
420
|
+
component_api_changed(method, component2[FILENAME]);
|
|
421
|
+
}
|
|
422
|
+
return {
|
|
423
|
+
$destroy: () => error("$destroy()"),
|
|
424
|
+
$on: () => error("$on(...)"),
|
|
425
|
+
$set: () => error("$set(...)")
|
|
426
|
+
};
|
|
427
|
+
}
|
|
428
|
+
|
|
429
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dev/inspect.js
|
|
430
|
+
function inspect(get_value, inspector, show_stack = false) {
|
|
431
|
+
validate_effect("$inspect");
|
|
432
|
+
let initial = true;
|
|
433
|
+
let error = (
|
|
434
|
+
/** @type {any} */
|
|
435
|
+
UNINITIALIZED
|
|
436
|
+
);
|
|
437
|
+
eager_effect(() => {
|
|
438
|
+
try {
|
|
439
|
+
var value = get_value();
|
|
440
|
+
} catch (e) {
|
|
441
|
+
error = e;
|
|
442
|
+
return;
|
|
443
|
+
}
|
|
444
|
+
var snap = snapshot(value, true, true);
|
|
445
|
+
untrack(() => {
|
|
446
|
+
if (show_stack) {
|
|
447
|
+
inspector(...snap);
|
|
448
|
+
if (!initial) {
|
|
449
|
+
const stack = get_error("$inspect(...)");
|
|
450
|
+
if (stack) {
|
|
451
|
+
console.groupCollapsed("stack trace");
|
|
452
|
+
console.log(stack);
|
|
453
|
+
console.groupEnd();
|
|
454
|
+
}
|
|
455
|
+
}
|
|
456
|
+
} else {
|
|
457
|
+
inspector(initial ? "init" : "update", ...snap);
|
|
458
|
+
}
|
|
459
|
+
});
|
|
460
|
+
initial = false;
|
|
461
|
+
});
|
|
462
|
+
render_effect(() => {
|
|
463
|
+
try {
|
|
464
|
+
get_value();
|
|
465
|
+
} catch {
|
|
466
|
+
}
|
|
467
|
+
if (error !== UNINITIALIZED) {
|
|
468
|
+
console.error(error);
|
|
469
|
+
error = UNINITIALIZED;
|
|
470
|
+
}
|
|
471
|
+
});
|
|
472
|
+
}
|
|
473
|
+
|
|
474
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/blocks/async.js
|
|
475
|
+
function async(node, blockers = [], expressions = [], fn) {
|
|
476
|
+
var was_hydrating = hydrating;
|
|
477
|
+
var end = null;
|
|
478
|
+
if (was_hydrating) {
|
|
479
|
+
hydrate_next();
|
|
480
|
+
end = skip_nodes(false);
|
|
481
|
+
}
|
|
482
|
+
if (expressions.length === 0 && blockers.every((b) => b.settled)) {
|
|
483
|
+
fn(node);
|
|
484
|
+
if (was_hydrating) {
|
|
485
|
+
set_hydrate_node(end);
|
|
486
|
+
}
|
|
487
|
+
return;
|
|
488
|
+
}
|
|
489
|
+
const decrement_pending = increment_pending();
|
|
490
|
+
if (was_hydrating) {
|
|
491
|
+
var previous_hydrate_node = hydrate_node;
|
|
492
|
+
set_hydrate_node(end);
|
|
493
|
+
}
|
|
494
|
+
flatten(blockers, [], expressions, (values) => {
|
|
495
|
+
if (was_hydrating) {
|
|
496
|
+
set_hydrating(true);
|
|
497
|
+
set_hydrate_node(previous_hydrate_node);
|
|
498
|
+
}
|
|
499
|
+
try {
|
|
500
|
+
for (const d of values) get(d);
|
|
501
|
+
fn(node, ...values);
|
|
502
|
+
} finally {
|
|
503
|
+
if (was_hydrating) {
|
|
504
|
+
set_hydrating(false);
|
|
505
|
+
}
|
|
506
|
+
decrement_pending();
|
|
507
|
+
}
|
|
508
|
+
});
|
|
509
|
+
}
|
|
510
|
+
|
|
511
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dev/validation.js
|
|
512
|
+
function validate_snippet_args(anchor, ...args) {
|
|
513
|
+
if (typeof anchor !== "object" || !(anchor instanceof Node)) {
|
|
514
|
+
invalid_snippet_arguments();
|
|
515
|
+
}
|
|
516
|
+
for (let arg of args) {
|
|
517
|
+
if (typeof arg !== "function") {
|
|
518
|
+
invalid_snippet_arguments();
|
|
519
|
+
}
|
|
520
|
+
}
|
|
521
|
+
}
|
|
522
|
+
|
|
523
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/blocks/branches.js
|
|
524
|
+
var BranchManager = class {
|
|
525
|
+
/** @type {TemplateNode} */
|
|
526
|
+
anchor;
|
|
527
|
+
/** @type {Map<Batch, Key>} */
|
|
528
|
+
#batches = /* @__PURE__ */ new Map();
|
|
529
|
+
/**
|
|
530
|
+
* Map of keys to effects that are currently rendered in the DOM.
|
|
531
|
+
* These effects are visible and actively part of the document tree.
|
|
532
|
+
* Example:
|
|
533
|
+
* ```
|
|
534
|
+
* {#if condition}
|
|
535
|
+
* foo
|
|
536
|
+
* {:else}
|
|
537
|
+
* bar
|
|
538
|
+
* {/if}
|
|
539
|
+
* ```
|
|
540
|
+
* Can result in the entries `true->Effect` and `false->Effect`
|
|
541
|
+
* @type {Map<Key, Effect>}
|
|
542
|
+
*/
|
|
543
|
+
#onscreen = /* @__PURE__ */ new Map();
|
|
544
|
+
/**
|
|
545
|
+
* Similar to #onscreen with respect to the keys, but contains branches that are not yet
|
|
546
|
+
* in the DOM, because their insertion is deferred.
|
|
547
|
+
* @type {Map<Key, Branch>}
|
|
548
|
+
*/
|
|
549
|
+
#offscreen = /* @__PURE__ */ new Map();
|
|
550
|
+
/**
|
|
551
|
+
* Keys of effects that are currently outroing
|
|
552
|
+
* @type {Set<Key>}
|
|
553
|
+
*/
|
|
554
|
+
#outroing = /* @__PURE__ */ new Set();
|
|
555
|
+
/**
|
|
556
|
+
* Whether to pause (i.e. outro) on change, or destroy immediately.
|
|
557
|
+
* This is necessary for `<svelte:element>`
|
|
558
|
+
*/
|
|
559
|
+
#transition = true;
|
|
560
|
+
/**
|
|
561
|
+
* @param {TemplateNode} anchor
|
|
562
|
+
* @param {boolean} transition
|
|
563
|
+
*/
|
|
564
|
+
constructor(anchor, transition2 = true) {
|
|
565
|
+
this.anchor = anchor;
|
|
566
|
+
this.#transition = transition2;
|
|
567
|
+
}
|
|
568
|
+
/**
|
|
569
|
+
* @param {Batch} batch
|
|
570
|
+
*/
|
|
571
|
+
#commit = (batch) => {
|
|
572
|
+
if (!this.#batches.has(batch)) return;
|
|
573
|
+
var key2 = (
|
|
574
|
+
/** @type {Key} */
|
|
575
|
+
this.#batches.get(batch)
|
|
576
|
+
);
|
|
577
|
+
var onscreen = this.#onscreen.get(key2);
|
|
578
|
+
if (onscreen) {
|
|
579
|
+
resume_effect(onscreen);
|
|
580
|
+
this.#outroing.delete(key2);
|
|
581
|
+
} else {
|
|
582
|
+
var offscreen = this.#offscreen.get(key2);
|
|
583
|
+
if (offscreen) {
|
|
584
|
+
this.#onscreen.set(key2, offscreen.effect);
|
|
585
|
+
this.#offscreen.delete(key2);
|
|
586
|
+
offscreen.fragment.lastChild.remove();
|
|
587
|
+
this.anchor.before(offscreen.fragment);
|
|
588
|
+
onscreen = offscreen.effect;
|
|
589
|
+
}
|
|
590
|
+
}
|
|
591
|
+
for (const [b, k] of this.#batches) {
|
|
592
|
+
this.#batches.delete(b);
|
|
593
|
+
if (b === batch) {
|
|
594
|
+
break;
|
|
595
|
+
}
|
|
596
|
+
const offscreen2 = this.#offscreen.get(k);
|
|
597
|
+
if (offscreen2) {
|
|
598
|
+
destroy_effect(offscreen2.effect);
|
|
599
|
+
this.#offscreen.delete(k);
|
|
600
|
+
}
|
|
601
|
+
}
|
|
602
|
+
for (const [k, effect2] of this.#onscreen) {
|
|
603
|
+
if (k === key2 || this.#outroing.has(k)) continue;
|
|
604
|
+
const on_destroy = () => {
|
|
605
|
+
const keys = Array.from(this.#batches.values());
|
|
606
|
+
if (keys.includes(k)) {
|
|
607
|
+
var fragment = document.createDocumentFragment();
|
|
608
|
+
move_effect(effect2, fragment);
|
|
609
|
+
fragment.append(create_text());
|
|
610
|
+
this.#offscreen.set(k, { effect: effect2, fragment });
|
|
611
|
+
} else {
|
|
612
|
+
destroy_effect(effect2);
|
|
613
|
+
}
|
|
614
|
+
this.#outroing.delete(k);
|
|
615
|
+
this.#onscreen.delete(k);
|
|
616
|
+
};
|
|
617
|
+
if (this.#transition || !onscreen) {
|
|
618
|
+
this.#outroing.add(k);
|
|
619
|
+
pause_effect(effect2, on_destroy, false);
|
|
620
|
+
} else {
|
|
621
|
+
on_destroy();
|
|
622
|
+
}
|
|
623
|
+
}
|
|
624
|
+
};
|
|
625
|
+
/**
|
|
626
|
+
* @param {Batch} batch
|
|
627
|
+
*/
|
|
628
|
+
#discard = (batch) => {
|
|
629
|
+
this.#batches.delete(batch);
|
|
630
|
+
const keys = Array.from(this.#batches.values());
|
|
631
|
+
for (const [k, branch2] of this.#offscreen) {
|
|
632
|
+
if (!keys.includes(k)) {
|
|
633
|
+
destroy_effect(branch2.effect);
|
|
634
|
+
this.#offscreen.delete(k);
|
|
635
|
+
}
|
|
636
|
+
}
|
|
637
|
+
};
|
|
638
|
+
/**
|
|
639
|
+
*
|
|
640
|
+
* @param {any} key
|
|
641
|
+
* @param {null | ((target: TemplateNode) => void)} fn
|
|
642
|
+
*/
|
|
643
|
+
ensure(key2, fn) {
|
|
644
|
+
var batch = (
|
|
645
|
+
/** @type {Batch} */
|
|
646
|
+
current_batch
|
|
647
|
+
);
|
|
648
|
+
var defer = should_defer_append();
|
|
649
|
+
if (fn && !this.#onscreen.has(key2) && !this.#offscreen.has(key2)) {
|
|
650
|
+
if (defer) {
|
|
651
|
+
var fragment = document.createDocumentFragment();
|
|
652
|
+
var target = create_text();
|
|
653
|
+
fragment.append(target);
|
|
654
|
+
this.#offscreen.set(key2, {
|
|
655
|
+
effect: branch(() => fn(target)),
|
|
656
|
+
fragment
|
|
657
|
+
});
|
|
658
|
+
} else {
|
|
659
|
+
this.#onscreen.set(
|
|
660
|
+
key2,
|
|
661
|
+
branch(() => fn(this.anchor))
|
|
662
|
+
);
|
|
663
|
+
}
|
|
664
|
+
}
|
|
665
|
+
this.#batches.set(batch, key2);
|
|
666
|
+
if (defer) {
|
|
667
|
+
for (const [k, effect2] of this.#onscreen) {
|
|
668
|
+
if (k === key2) {
|
|
669
|
+
batch.unskip_effect(effect2);
|
|
670
|
+
} else {
|
|
671
|
+
batch.skip_effect(effect2);
|
|
672
|
+
}
|
|
673
|
+
}
|
|
674
|
+
for (const [k, branch2] of this.#offscreen) {
|
|
675
|
+
if (k === key2) {
|
|
676
|
+
batch.unskip_effect(branch2.effect);
|
|
677
|
+
} else {
|
|
678
|
+
batch.skip_effect(branch2.effect);
|
|
679
|
+
}
|
|
680
|
+
}
|
|
681
|
+
batch.oncommit(this.#commit);
|
|
682
|
+
batch.ondiscard(this.#discard);
|
|
683
|
+
} else {
|
|
684
|
+
if (hydrating) {
|
|
685
|
+
this.anchor = hydrate_node;
|
|
686
|
+
}
|
|
687
|
+
this.#commit(batch);
|
|
688
|
+
}
|
|
689
|
+
}
|
|
690
|
+
};
|
|
691
|
+
|
|
692
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/blocks/await.js
|
|
693
|
+
var PENDING = 0;
|
|
694
|
+
var THEN = 1;
|
|
695
|
+
var CATCH = 2;
|
|
696
|
+
function await_block(node, get_input, pending_fn, then_fn, catch_fn) {
|
|
697
|
+
if (hydrating) {
|
|
698
|
+
hydrate_next();
|
|
699
|
+
}
|
|
700
|
+
var runes = is_runes();
|
|
701
|
+
var v = (
|
|
702
|
+
/** @type {V} */
|
|
703
|
+
UNINITIALIZED
|
|
704
|
+
);
|
|
705
|
+
var value = runes ? source(v) : mutable_source(v, false, false);
|
|
706
|
+
var error = runes ? source(v) : mutable_source(v, false, false);
|
|
707
|
+
var branches = new BranchManager(node);
|
|
708
|
+
block(() => {
|
|
709
|
+
var batch = (
|
|
710
|
+
/** @type {Batch} */
|
|
711
|
+
current_batch
|
|
712
|
+
);
|
|
713
|
+
batch.deactivate();
|
|
714
|
+
var input = get_input();
|
|
715
|
+
batch.activate();
|
|
716
|
+
var destroyed = false;
|
|
717
|
+
let mismatch = hydrating && is_promise(input) === (node.data === HYDRATION_START_ELSE);
|
|
718
|
+
if (mismatch) {
|
|
719
|
+
set_hydrate_node(skip_nodes());
|
|
720
|
+
set_hydrating(false);
|
|
721
|
+
}
|
|
722
|
+
if (is_promise(input)) {
|
|
723
|
+
var restore = capture();
|
|
724
|
+
var resolved = false;
|
|
725
|
+
const resolve = (fn) => {
|
|
726
|
+
if (destroyed) return;
|
|
727
|
+
resolved = true;
|
|
728
|
+
restore(false);
|
|
729
|
+
Batch.ensure();
|
|
730
|
+
if (hydrating) {
|
|
731
|
+
set_hydrating(false);
|
|
732
|
+
}
|
|
733
|
+
try {
|
|
734
|
+
fn();
|
|
735
|
+
} finally {
|
|
736
|
+
unset_context(false);
|
|
737
|
+
if (!is_flushing_sync) flushSync();
|
|
738
|
+
}
|
|
739
|
+
};
|
|
740
|
+
input.then(
|
|
741
|
+
(v2) => {
|
|
742
|
+
resolve(() => {
|
|
743
|
+
internal_set(value, v2);
|
|
744
|
+
branches.ensure(THEN, then_fn && ((target) => then_fn(target, value)));
|
|
745
|
+
});
|
|
746
|
+
},
|
|
747
|
+
(e) => {
|
|
748
|
+
resolve(() => {
|
|
749
|
+
internal_set(error, e);
|
|
750
|
+
branches.ensure(CATCH, catch_fn && ((target) => catch_fn(target, error)));
|
|
751
|
+
if (!catch_fn) {
|
|
752
|
+
throw error.v;
|
|
753
|
+
}
|
|
754
|
+
});
|
|
755
|
+
}
|
|
756
|
+
);
|
|
757
|
+
if (hydrating) {
|
|
758
|
+
branches.ensure(PENDING, pending_fn);
|
|
759
|
+
} else {
|
|
760
|
+
queue_micro_task(() => {
|
|
761
|
+
if (!resolved) {
|
|
762
|
+
resolve(() => {
|
|
763
|
+
branches.ensure(PENDING, pending_fn);
|
|
764
|
+
});
|
|
765
|
+
}
|
|
766
|
+
});
|
|
767
|
+
}
|
|
768
|
+
} else {
|
|
769
|
+
internal_set(value, input);
|
|
770
|
+
branches.ensure(THEN, then_fn && ((target) => then_fn(target, value)));
|
|
771
|
+
}
|
|
772
|
+
if (mismatch) {
|
|
773
|
+
set_hydrating(true);
|
|
774
|
+
}
|
|
775
|
+
return () => {
|
|
776
|
+
destroyed = true;
|
|
777
|
+
};
|
|
778
|
+
});
|
|
779
|
+
}
|
|
780
|
+
|
|
781
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/blocks/if.js
|
|
782
|
+
function if_block(node, fn, elseif = false) {
|
|
783
|
+
var marker;
|
|
784
|
+
if (hydrating) {
|
|
785
|
+
marker = hydrate_node;
|
|
786
|
+
hydrate_next();
|
|
787
|
+
}
|
|
788
|
+
var branches = new BranchManager(node);
|
|
789
|
+
var flags = elseif ? EFFECT_TRANSPARENT : 0;
|
|
790
|
+
function update_branch(key2, fn2) {
|
|
791
|
+
if (hydrating) {
|
|
792
|
+
var data = read_hydration_instruction(
|
|
793
|
+
/** @type {TemplateNode} */
|
|
794
|
+
marker
|
|
795
|
+
);
|
|
796
|
+
if (key2 !== parseInt(data.substring(1))) {
|
|
797
|
+
var anchor = skip_nodes();
|
|
798
|
+
set_hydrate_node(anchor);
|
|
799
|
+
branches.anchor = anchor;
|
|
800
|
+
set_hydrating(false);
|
|
801
|
+
branches.ensure(key2, fn2);
|
|
802
|
+
set_hydrating(true);
|
|
803
|
+
return;
|
|
804
|
+
}
|
|
805
|
+
}
|
|
806
|
+
branches.ensure(key2, fn2);
|
|
807
|
+
}
|
|
808
|
+
block(() => {
|
|
809
|
+
var has_branch = false;
|
|
810
|
+
fn((fn2, key2 = 0) => {
|
|
811
|
+
has_branch = true;
|
|
812
|
+
update_branch(key2, fn2);
|
|
813
|
+
});
|
|
814
|
+
if (!has_branch) {
|
|
815
|
+
update_branch(-1, null);
|
|
816
|
+
}
|
|
817
|
+
}, flags);
|
|
818
|
+
}
|
|
819
|
+
|
|
820
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/blocks/key.js
|
|
821
|
+
var NAN = /* @__PURE__ */ Symbol("NaN");
|
|
822
|
+
function key(node, get_key, render_fn) {
|
|
823
|
+
if (hydrating) {
|
|
824
|
+
hydrate_next();
|
|
825
|
+
}
|
|
826
|
+
var branches = new BranchManager(node);
|
|
827
|
+
var legacy = !is_runes();
|
|
828
|
+
block(() => {
|
|
829
|
+
var key2 = get_key();
|
|
830
|
+
if (key2 !== key2) {
|
|
831
|
+
key2 = /** @type {any} */
|
|
832
|
+
NAN;
|
|
833
|
+
}
|
|
834
|
+
if (legacy && key2 !== null && typeof key2 === "object") {
|
|
835
|
+
key2 = /** @type {V} */
|
|
836
|
+
{};
|
|
837
|
+
}
|
|
838
|
+
branches.ensure(key2, render_fn);
|
|
839
|
+
});
|
|
840
|
+
}
|
|
841
|
+
|
|
842
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/blocks/css-props.js
|
|
843
|
+
function css_props(element2, get_styles) {
|
|
844
|
+
if (hydrating) {
|
|
845
|
+
set_hydrate_node(get_first_child(element2));
|
|
846
|
+
}
|
|
847
|
+
render_effect(() => {
|
|
848
|
+
var styles = get_styles();
|
|
849
|
+
for (var key2 in styles) {
|
|
850
|
+
var value = styles[key2];
|
|
851
|
+
if (value) {
|
|
852
|
+
element2.style.setProperty(key2, value);
|
|
853
|
+
} else {
|
|
854
|
+
element2.style.removeProperty(key2);
|
|
855
|
+
}
|
|
856
|
+
}
|
|
857
|
+
});
|
|
858
|
+
}
|
|
859
|
+
|
|
860
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/blocks/each.js
|
|
861
|
+
function index(_, i) {
|
|
862
|
+
return i;
|
|
863
|
+
}
|
|
864
|
+
function pause_effects(state2, to_destroy, controlled_anchor) {
|
|
865
|
+
var transitions = [];
|
|
866
|
+
var length = to_destroy.length;
|
|
867
|
+
var group;
|
|
868
|
+
var remaining = to_destroy.length;
|
|
869
|
+
for (var i = 0; i < length; i++) {
|
|
870
|
+
let effect2 = to_destroy[i];
|
|
871
|
+
pause_effect(
|
|
872
|
+
effect2,
|
|
873
|
+
() => {
|
|
874
|
+
if (group) {
|
|
875
|
+
group.pending.delete(effect2);
|
|
876
|
+
group.done.add(effect2);
|
|
877
|
+
if (group.pending.size === 0) {
|
|
878
|
+
var groups = (
|
|
879
|
+
/** @type {Set<EachOutroGroup>} */
|
|
880
|
+
state2.outrogroups
|
|
881
|
+
);
|
|
882
|
+
destroy_effects(state2, array_from(group.done));
|
|
883
|
+
groups.delete(group);
|
|
884
|
+
if (groups.size === 0) {
|
|
885
|
+
state2.outrogroups = null;
|
|
886
|
+
}
|
|
887
|
+
}
|
|
888
|
+
} else {
|
|
889
|
+
remaining -= 1;
|
|
890
|
+
}
|
|
891
|
+
},
|
|
892
|
+
false
|
|
893
|
+
);
|
|
894
|
+
}
|
|
895
|
+
if (remaining === 0) {
|
|
896
|
+
var fast_path = transitions.length === 0 && controlled_anchor !== null;
|
|
897
|
+
if (fast_path) {
|
|
898
|
+
var anchor = (
|
|
899
|
+
/** @type {Element} */
|
|
900
|
+
controlled_anchor
|
|
901
|
+
);
|
|
902
|
+
var parent_node = (
|
|
903
|
+
/** @type {Element} */
|
|
904
|
+
anchor.parentNode
|
|
905
|
+
);
|
|
906
|
+
clear_text_content(parent_node);
|
|
907
|
+
parent_node.append(anchor);
|
|
908
|
+
state2.items.clear();
|
|
909
|
+
}
|
|
910
|
+
destroy_effects(state2, to_destroy, !fast_path);
|
|
911
|
+
} else {
|
|
912
|
+
group = {
|
|
913
|
+
pending: new Set(to_destroy),
|
|
914
|
+
done: /* @__PURE__ */ new Set()
|
|
915
|
+
};
|
|
916
|
+
(state2.outrogroups ??= /* @__PURE__ */ new Set()).add(group);
|
|
917
|
+
}
|
|
918
|
+
}
|
|
919
|
+
function destroy_effects(state2, to_destroy, remove_dom = true) {
|
|
920
|
+
var preserved_effects;
|
|
921
|
+
if (state2.pending.size > 0) {
|
|
922
|
+
preserved_effects = /* @__PURE__ */ new Set();
|
|
923
|
+
for (const keys of state2.pending.values()) {
|
|
924
|
+
for (const key2 of keys) {
|
|
925
|
+
preserved_effects.add(
|
|
926
|
+
/** @type {EachItem} */
|
|
927
|
+
state2.items.get(key2).e
|
|
928
|
+
);
|
|
929
|
+
}
|
|
930
|
+
}
|
|
931
|
+
}
|
|
932
|
+
for (var i = 0; i < to_destroy.length; i++) {
|
|
933
|
+
var e = to_destroy[i];
|
|
934
|
+
if (preserved_effects?.has(e)) {
|
|
935
|
+
e.f |= EFFECT_OFFSCREEN;
|
|
936
|
+
const fragment = document.createDocumentFragment();
|
|
937
|
+
move_effect(e, fragment);
|
|
938
|
+
} else {
|
|
939
|
+
destroy_effect(to_destroy[i], remove_dom);
|
|
940
|
+
}
|
|
941
|
+
}
|
|
942
|
+
}
|
|
943
|
+
var offscreen_anchor;
|
|
944
|
+
function each(node, flags, get_collection, get_key, render_fn, fallback_fn = null) {
|
|
945
|
+
var anchor = node;
|
|
946
|
+
var items = /* @__PURE__ */ new Map();
|
|
947
|
+
var is_controlled = (flags & EACH_IS_CONTROLLED) !== 0;
|
|
948
|
+
if (is_controlled) {
|
|
949
|
+
var parent_node = (
|
|
950
|
+
/** @type {Element} */
|
|
951
|
+
node
|
|
952
|
+
);
|
|
953
|
+
anchor = hydrating ? set_hydrate_node(get_first_child(parent_node)) : parent_node.appendChild(create_text());
|
|
954
|
+
}
|
|
955
|
+
if (hydrating) {
|
|
956
|
+
hydrate_next();
|
|
957
|
+
}
|
|
958
|
+
var fallback2 = null;
|
|
959
|
+
var each_array = derived_safe_equal(() => {
|
|
960
|
+
var collection = get_collection();
|
|
961
|
+
return is_array(collection) ? collection : collection == null ? [] : array_from(collection);
|
|
962
|
+
});
|
|
963
|
+
var array;
|
|
964
|
+
var pending3 = /* @__PURE__ */ new Map();
|
|
965
|
+
var first_run = true;
|
|
966
|
+
function commit(batch) {
|
|
967
|
+
if ((state2.effect.f & DESTROYED) !== 0) {
|
|
968
|
+
return;
|
|
969
|
+
}
|
|
970
|
+
state2.pending.delete(batch);
|
|
971
|
+
state2.fallback = fallback2;
|
|
972
|
+
reconcile(state2, array, anchor, flags, get_key);
|
|
973
|
+
if (fallback2 !== null) {
|
|
974
|
+
if (array.length === 0) {
|
|
975
|
+
if ((fallback2.f & EFFECT_OFFSCREEN) === 0) {
|
|
976
|
+
resume_effect(fallback2);
|
|
977
|
+
} else {
|
|
978
|
+
fallback2.f ^= EFFECT_OFFSCREEN;
|
|
979
|
+
move(fallback2, null, anchor);
|
|
980
|
+
}
|
|
981
|
+
} else {
|
|
982
|
+
pause_effect(fallback2, () => {
|
|
983
|
+
fallback2 = null;
|
|
984
|
+
});
|
|
985
|
+
}
|
|
986
|
+
}
|
|
987
|
+
}
|
|
988
|
+
function discard(batch) {
|
|
989
|
+
state2.pending.delete(batch);
|
|
990
|
+
}
|
|
991
|
+
var effect2 = block(() => {
|
|
992
|
+
array = /** @type {V[]} */
|
|
993
|
+
get(each_array);
|
|
994
|
+
var length = array.length;
|
|
995
|
+
let mismatch = false;
|
|
996
|
+
if (hydrating) {
|
|
997
|
+
var is_else = read_hydration_instruction(anchor) === HYDRATION_START_ELSE;
|
|
998
|
+
if (is_else !== (length === 0)) {
|
|
999
|
+
anchor = skip_nodes();
|
|
1000
|
+
set_hydrate_node(anchor);
|
|
1001
|
+
set_hydrating(false);
|
|
1002
|
+
mismatch = true;
|
|
1003
|
+
}
|
|
1004
|
+
}
|
|
1005
|
+
var keys = /* @__PURE__ */ new Set();
|
|
1006
|
+
var batch = (
|
|
1007
|
+
/** @type {Batch} */
|
|
1008
|
+
current_batch
|
|
1009
|
+
);
|
|
1010
|
+
var defer = should_defer_append();
|
|
1011
|
+
for (var index2 = 0; index2 < length; index2 += 1) {
|
|
1012
|
+
if (hydrating && hydrate_node.nodeType === COMMENT_NODE && /** @type {Comment} */
|
|
1013
|
+
hydrate_node.data === HYDRATION_END) {
|
|
1014
|
+
anchor = /** @type {Comment} */
|
|
1015
|
+
hydrate_node;
|
|
1016
|
+
mismatch = true;
|
|
1017
|
+
set_hydrating(false);
|
|
1018
|
+
}
|
|
1019
|
+
var value = array[index2];
|
|
1020
|
+
var key2 = get_key(value, index2);
|
|
1021
|
+
if (true_default) {
|
|
1022
|
+
var key_again = get_key(value, index2);
|
|
1023
|
+
if (key2 !== key_again) {
|
|
1024
|
+
each_key_volatile(String(index2), String(key2), String(key_again));
|
|
1025
|
+
}
|
|
1026
|
+
}
|
|
1027
|
+
var item = first_run ? null : items.get(key2);
|
|
1028
|
+
if (item) {
|
|
1029
|
+
if (item.v) internal_set(item.v, value);
|
|
1030
|
+
if (item.i) internal_set(item.i, index2);
|
|
1031
|
+
if (defer) {
|
|
1032
|
+
batch.unskip_effect(item.e);
|
|
1033
|
+
}
|
|
1034
|
+
} else {
|
|
1035
|
+
item = create_item(
|
|
1036
|
+
items,
|
|
1037
|
+
first_run ? anchor : offscreen_anchor ??= create_text(),
|
|
1038
|
+
value,
|
|
1039
|
+
key2,
|
|
1040
|
+
index2,
|
|
1041
|
+
render_fn,
|
|
1042
|
+
flags,
|
|
1043
|
+
get_collection
|
|
1044
|
+
);
|
|
1045
|
+
if (!first_run) {
|
|
1046
|
+
item.e.f |= EFFECT_OFFSCREEN;
|
|
1047
|
+
}
|
|
1048
|
+
items.set(key2, item);
|
|
1049
|
+
}
|
|
1050
|
+
keys.add(key2);
|
|
1051
|
+
}
|
|
1052
|
+
if (length === 0 && fallback_fn && !fallback2) {
|
|
1053
|
+
if (first_run) {
|
|
1054
|
+
fallback2 = branch(() => fallback_fn(anchor));
|
|
1055
|
+
} else {
|
|
1056
|
+
fallback2 = branch(() => fallback_fn(offscreen_anchor ??= create_text()));
|
|
1057
|
+
fallback2.f |= EFFECT_OFFSCREEN;
|
|
1058
|
+
}
|
|
1059
|
+
}
|
|
1060
|
+
if (length > keys.size) {
|
|
1061
|
+
if (true_default) {
|
|
1062
|
+
validate_each_keys(array, get_key);
|
|
1063
|
+
} else {
|
|
1064
|
+
each_key_duplicate("", "", "");
|
|
1065
|
+
}
|
|
1066
|
+
}
|
|
1067
|
+
if (hydrating && length > 0) {
|
|
1068
|
+
set_hydrate_node(skip_nodes());
|
|
1069
|
+
}
|
|
1070
|
+
if (!first_run) {
|
|
1071
|
+
pending3.set(batch, keys);
|
|
1072
|
+
if (defer) {
|
|
1073
|
+
for (const [key3, item2] of items) {
|
|
1074
|
+
if (!keys.has(key3)) {
|
|
1075
|
+
batch.skip_effect(item2.e);
|
|
1076
|
+
}
|
|
1077
|
+
}
|
|
1078
|
+
batch.oncommit(commit);
|
|
1079
|
+
batch.ondiscard(discard);
|
|
1080
|
+
} else {
|
|
1081
|
+
commit(batch);
|
|
1082
|
+
}
|
|
1083
|
+
}
|
|
1084
|
+
if (mismatch) {
|
|
1085
|
+
set_hydrating(true);
|
|
1086
|
+
}
|
|
1087
|
+
get(each_array);
|
|
1088
|
+
});
|
|
1089
|
+
var state2 = { effect: effect2, flags, items, pending: pending3, outrogroups: null, fallback: fallback2 };
|
|
1090
|
+
first_run = false;
|
|
1091
|
+
if (hydrating) {
|
|
1092
|
+
anchor = hydrate_node;
|
|
1093
|
+
}
|
|
1094
|
+
}
|
|
1095
|
+
function skip_to_branch(effect2) {
|
|
1096
|
+
while (effect2 !== null && (effect2.f & BRANCH_EFFECT) === 0) {
|
|
1097
|
+
effect2 = effect2.next;
|
|
1098
|
+
}
|
|
1099
|
+
return effect2;
|
|
1100
|
+
}
|
|
1101
|
+
function reconcile(state2, array, anchor, flags, get_key) {
|
|
1102
|
+
var is_animated = (flags & EACH_IS_ANIMATED) !== 0;
|
|
1103
|
+
var length = array.length;
|
|
1104
|
+
var items = state2.items;
|
|
1105
|
+
var current = skip_to_branch(state2.effect.first);
|
|
1106
|
+
var seen;
|
|
1107
|
+
var prev = null;
|
|
1108
|
+
var to_animate;
|
|
1109
|
+
var matched = [];
|
|
1110
|
+
var stashed = [];
|
|
1111
|
+
var value;
|
|
1112
|
+
var key2;
|
|
1113
|
+
var effect2;
|
|
1114
|
+
var i;
|
|
1115
|
+
if (is_animated) {
|
|
1116
|
+
for (i = 0; i < length; i += 1) {
|
|
1117
|
+
value = array[i];
|
|
1118
|
+
key2 = get_key(value, i);
|
|
1119
|
+
effect2 = /** @type {EachItem} */
|
|
1120
|
+
items.get(key2).e;
|
|
1121
|
+
if ((effect2.f & EFFECT_OFFSCREEN) === 0) {
|
|
1122
|
+
effect2.nodes?.a?.measure();
|
|
1123
|
+
(to_animate ??= /* @__PURE__ */ new Set()).add(effect2);
|
|
1124
|
+
}
|
|
1125
|
+
}
|
|
1126
|
+
}
|
|
1127
|
+
for (i = 0; i < length; i += 1) {
|
|
1128
|
+
value = array[i];
|
|
1129
|
+
key2 = get_key(value, i);
|
|
1130
|
+
effect2 = /** @type {EachItem} */
|
|
1131
|
+
items.get(key2).e;
|
|
1132
|
+
if (state2.outrogroups !== null) {
|
|
1133
|
+
for (const group of state2.outrogroups) {
|
|
1134
|
+
group.pending.delete(effect2);
|
|
1135
|
+
group.done.delete(effect2);
|
|
1136
|
+
}
|
|
1137
|
+
}
|
|
1138
|
+
if ((effect2.f & INERT) !== 0) {
|
|
1139
|
+
resume_effect(effect2);
|
|
1140
|
+
if (is_animated) {
|
|
1141
|
+
effect2.nodes?.a?.unfix();
|
|
1142
|
+
(to_animate ??= /* @__PURE__ */ new Set()).delete(effect2);
|
|
1143
|
+
}
|
|
1144
|
+
}
|
|
1145
|
+
if ((effect2.f & EFFECT_OFFSCREEN) !== 0) {
|
|
1146
|
+
effect2.f ^= EFFECT_OFFSCREEN;
|
|
1147
|
+
if (effect2 === current) {
|
|
1148
|
+
move(effect2, null, anchor);
|
|
1149
|
+
} else {
|
|
1150
|
+
var next2 = prev ? prev.next : current;
|
|
1151
|
+
if (effect2 === state2.effect.last) {
|
|
1152
|
+
state2.effect.last = effect2.prev;
|
|
1153
|
+
}
|
|
1154
|
+
if (effect2.prev) effect2.prev.next = effect2.next;
|
|
1155
|
+
if (effect2.next) effect2.next.prev = effect2.prev;
|
|
1156
|
+
link(state2, prev, effect2);
|
|
1157
|
+
link(state2, effect2, next2);
|
|
1158
|
+
move(effect2, next2, anchor);
|
|
1159
|
+
prev = effect2;
|
|
1160
|
+
matched = [];
|
|
1161
|
+
stashed = [];
|
|
1162
|
+
current = skip_to_branch(prev.next);
|
|
1163
|
+
continue;
|
|
1164
|
+
}
|
|
1165
|
+
}
|
|
1166
|
+
if (effect2 !== current) {
|
|
1167
|
+
if (seen !== void 0 && seen.has(effect2)) {
|
|
1168
|
+
if (matched.length < stashed.length) {
|
|
1169
|
+
var start = stashed[0];
|
|
1170
|
+
var j;
|
|
1171
|
+
prev = start.prev;
|
|
1172
|
+
var a = matched[0];
|
|
1173
|
+
var b = matched[matched.length - 1];
|
|
1174
|
+
for (j = 0; j < matched.length; j += 1) {
|
|
1175
|
+
move(matched[j], start, anchor);
|
|
1176
|
+
}
|
|
1177
|
+
for (j = 0; j < stashed.length; j += 1) {
|
|
1178
|
+
seen.delete(stashed[j]);
|
|
1179
|
+
}
|
|
1180
|
+
link(state2, a.prev, b.next);
|
|
1181
|
+
link(state2, prev, a);
|
|
1182
|
+
link(state2, b, start);
|
|
1183
|
+
current = start;
|
|
1184
|
+
prev = b;
|
|
1185
|
+
i -= 1;
|
|
1186
|
+
matched = [];
|
|
1187
|
+
stashed = [];
|
|
1188
|
+
} else {
|
|
1189
|
+
seen.delete(effect2);
|
|
1190
|
+
move(effect2, current, anchor);
|
|
1191
|
+
link(state2, effect2.prev, effect2.next);
|
|
1192
|
+
link(state2, effect2, prev === null ? state2.effect.first : prev.next);
|
|
1193
|
+
link(state2, prev, effect2);
|
|
1194
|
+
prev = effect2;
|
|
1195
|
+
}
|
|
1196
|
+
continue;
|
|
1197
|
+
}
|
|
1198
|
+
matched = [];
|
|
1199
|
+
stashed = [];
|
|
1200
|
+
while (current !== null && current !== effect2) {
|
|
1201
|
+
(seen ??= /* @__PURE__ */ new Set()).add(current);
|
|
1202
|
+
stashed.push(current);
|
|
1203
|
+
current = skip_to_branch(current.next);
|
|
1204
|
+
}
|
|
1205
|
+
if (current === null) {
|
|
1206
|
+
continue;
|
|
1207
|
+
}
|
|
1208
|
+
}
|
|
1209
|
+
if ((effect2.f & EFFECT_OFFSCREEN) === 0) {
|
|
1210
|
+
matched.push(effect2);
|
|
1211
|
+
}
|
|
1212
|
+
prev = effect2;
|
|
1213
|
+
current = skip_to_branch(effect2.next);
|
|
1214
|
+
}
|
|
1215
|
+
if (state2.outrogroups !== null) {
|
|
1216
|
+
for (const group of state2.outrogroups) {
|
|
1217
|
+
if (group.pending.size === 0) {
|
|
1218
|
+
destroy_effects(state2, array_from(group.done));
|
|
1219
|
+
state2.outrogroups?.delete(group);
|
|
1220
|
+
}
|
|
1221
|
+
}
|
|
1222
|
+
if (state2.outrogroups.size === 0) {
|
|
1223
|
+
state2.outrogroups = null;
|
|
1224
|
+
}
|
|
1225
|
+
}
|
|
1226
|
+
if (current !== null || seen !== void 0) {
|
|
1227
|
+
var to_destroy = [];
|
|
1228
|
+
if (seen !== void 0) {
|
|
1229
|
+
for (effect2 of seen) {
|
|
1230
|
+
if ((effect2.f & INERT) === 0) {
|
|
1231
|
+
to_destroy.push(effect2);
|
|
1232
|
+
}
|
|
1233
|
+
}
|
|
1234
|
+
}
|
|
1235
|
+
while (current !== null) {
|
|
1236
|
+
if ((current.f & INERT) === 0 && current !== state2.fallback) {
|
|
1237
|
+
to_destroy.push(current);
|
|
1238
|
+
}
|
|
1239
|
+
current = skip_to_branch(current.next);
|
|
1240
|
+
}
|
|
1241
|
+
var destroy_length = to_destroy.length;
|
|
1242
|
+
if (destroy_length > 0) {
|
|
1243
|
+
var controlled_anchor = (flags & EACH_IS_CONTROLLED) !== 0 && length === 0 ? anchor : null;
|
|
1244
|
+
if (is_animated) {
|
|
1245
|
+
for (i = 0; i < destroy_length; i += 1) {
|
|
1246
|
+
to_destroy[i].nodes?.a?.measure();
|
|
1247
|
+
}
|
|
1248
|
+
for (i = 0; i < destroy_length; i += 1) {
|
|
1249
|
+
to_destroy[i].nodes?.a?.fix();
|
|
1250
|
+
}
|
|
1251
|
+
}
|
|
1252
|
+
pause_effects(state2, to_destroy, controlled_anchor);
|
|
1253
|
+
}
|
|
1254
|
+
}
|
|
1255
|
+
if (is_animated) {
|
|
1256
|
+
queue_micro_task(() => {
|
|
1257
|
+
if (to_animate === void 0) return;
|
|
1258
|
+
for (effect2 of to_animate) {
|
|
1259
|
+
effect2.nodes?.a?.apply();
|
|
1260
|
+
}
|
|
1261
|
+
});
|
|
1262
|
+
}
|
|
1263
|
+
}
|
|
1264
|
+
function create_item(items, anchor, value, key2, index2, render_fn, flags, get_collection) {
|
|
1265
|
+
var v = (flags & EACH_ITEM_REACTIVE) !== 0 ? (flags & EACH_ITEM_IMMUTABLE) === 0 ? mutable_source(value, false, false) : source(value) : null;
|
|
1266
|
+
var i = (flags & EACH_INDEX_REACTIVE) !== 0 ? source(index2) : null;
|
|
1267
|
+
if (true_default && v) {
|
|
1268
|
+
v.trace = () => {
|
|
1269
|
+
get_collection()[i?.v ?? index2];
|
|
1270
|
+
};
|
|
1271
|
+
}
|
|
1272
|
+
return {
|
|
1273
|
+
v,
|
|
1274
|
+
i,
|
|
1275
|
+
e: branch(() => {
|
|
1276
|
+
render_fn(anchor, v ?? value, i ?? index2, get_collection);
|
|
1277
|
+
return () => {
|
|
1278
|
+
items.delete(key2);
|
|
1279
|
+
};
|
|
1280
|
+
})
|
|
1281
|
+
};
|
|
1282
|
+
}
|
|
1283
|
+
function move(effect2, next2, anchor) {
|
|
1284
|
+
if (!effect2.nodes) return;
|
|
1285
|
+
var node = effect2.nodes.start;
|
|
1286
|
+
var end = effect2.nodes.end;
|
|
1287
|
+
var dest = next2 && (next2.f & EFFECT_OFFSCREEN) === 0 ? (
|
|
1288
|
+
/** @type {EffectNodes} */
|
|
1289
|
+
next2.nodes.start
|
|
1290
|
+
) : anchor;
|
|
1291
|
+
while (node !== null) {
|
|
1292
|
+
var next_node = (
|
|
1293
|
+
/** @type {TemplateNode} */
|
|
1294
|
+
get_next_sibling(node)
|
|
1295
|
+
);
|
|
1296
|
+
dest.before(node);
|
|
1297
|
+
if (node === end) {
|
|
1298
|
+
return;
|
|
1299
|
+
}
|
|
1300
|
+
node = next_node;
|
|
1301
|
+
}
|
|
1302
|
+
}
|
|
1303
|
+
function link(state2, prev, next2) {
|
|
1304
|
+
if (prev === null) {
|
|
1305
|
+
state2.effect.first = next2;
|
|
1306
|
+
} else {
|
|
1307
|
+
prev.next = next2;
|
|
1308
|
+
}
|
|
1309
|
+
if (next2 === null) {
|
|
1310
|
+
state2.effect.last = prev;
|
|
1311
|
+
} else {
|
|
1312
|
+
next2.prev = prev;
|
|
1313
|
+
}
|
|
1314
|
+
}
|
|
1315
|
+
function validate_each_keys(array, key_fn) {
|
|
1316
|
+
const keys = /* @__PURE__ */ new Map();
|
|
1317
|
+
const length = array.length;
|
|
1318
|
+
for (let i = 0; i < length; i++) {
|
|
1319
|
+
const key2 = key_fn(array[i], i);
|
|
1320
|
+
if (keys.has(key2)) {
|
|
1321
|
+
const a = String(keys.get(key2));
|
|
1322
|
+
const b = String(i);
|
|
1323
|
+
let k = String(key2);
|
|
1324
|
+
if (k.startsWith("[object ")) k = null;
|
|
1325
|
+
each_key_duplicate(a, b, k);
|
|
1326
|
+
}
|
|
1327
|
+
keys.set(key2, i);
|
|
1328
|
+
}
|
|
1329
|
+
}
|
|
1330
|
+
|
|
1331
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/blocks/html.js
|
|
1332
|
+
function check_hash(element2, server_hash, value) {
|
|
1333
|
+
if (!server_hash || server_hash === hash(String(value ?? ""))) return;
|
|
1334
|
+
let location;
|
|
1335
|
+
const loc = element2.__svelte_meta?.loc;
|
|
1336
|
+
if (loc) {
|
|
1337
|
+
location = `near ${loc.file}:${loc.line}:${loc.column}`;
|
|
1338
|
+
} else if (dev_current_component_function?.[FILENAME]) {
|
|
1339
|
+
location = `in ${dev_current_component_function[FILENAME]}`;
|
|
1340
|
+
}
|
|
1341
|
+
hydration_html_changed(sanitize_location(location));
|
|
1342
|
+
}
|
|
1343
|
+
function html(node, get_value, is_controlled = false, svg = false, mathml = false, skip_warning = false) {
|
|
1344
|
+
var anchor = node;
|
|
1345
|
+
var value = "";
|
|
1346
|
+
if (is_controlled) {
|
|
1347
|
+
var parent_node = (
|
|
1348
|
+
/** @type {Element} */
|
|
1349
|
+
node
|
|
1350
|
+
);
|
|
1351
|
+
if (hydrating) {
|
|
1352
|
+
anchor = set_hydrate_node(get_first_child(parent_node));
|
|
1353
|
+
}
|
|
1354
|
+
}
|
|
1355
|
+
template_effect(() => {
|
|
1356
|
+
var effect2 = (
|
|
1357
|
+
/** @type {Effect} */
|
|
1358
|
+
active_effect
|
|
1359
|
+
);
|
|
1360
|
+
if (value === (value = get_value() ?? "")) {
|
|
1361
|
+
if (hydrating) hydrate_next();
|
|
1362
|
+
return;
|
|
1363
|
+
}
|
|
1364
|
+
if (is_controlled && !hydrating) {
|
|
1365
|
+
effect2.nodes = null;
|
|
1366
|
+
parent_node.innerHTML = /** @type {string} */
|
|
1367
|
+
value;
|
|
1368
|
+
if (value !== "") {
|
|
1369
|
+
assign_nodes(
|
|
1370
|
+
/** @type {TemplateNode} */
|
|
1371
|
+
get_first_child(parent_node),
|
|
1372
|
+
/** @type {TemplateNode} */
|
|
1373
|
+
parent_node.lastChild
|
|
1374
|
+
);
|
|
1375
|
+
}
|
|
1376
|
+
return;
|
|
1377
|
+
}
|
|
1378
|
+
if (effect2.nodes !== null) {
|
|
1379
|
+
remove_effect_dom(
|
|
1380
|
+
effect2.nodes.start,
|
|
1381
|
+
/** @type {TemplateNode} */
|
|
1382
|
+
effect2.nodes.end
|
|
1383
|
+
);
|
|
1384
|
+
effect2.nodes = null;
|
|
1385
|
+
}
|
|
1386
|
+
if (value === "") return;
|
|
1387
|
+
if (hydrating) {
|
|
1388
|
+
var hash2 = (
|
|
1389
|
+
/** @type {Comment} */
|
|
1390
|
+
hydrate_node.data
|
|
1391
|
+
);
|
|
1392
|
+
var next2 = hydrate_next();
|
|
1393
|
+
var last = next2;
|
|
1394
|
+
while (next2 !== null && (next2.nodeType !== COMMENT_NODE || /** @type {Comment} */
|
|
1395
|
+
next2.data !== "")) {
|
|
1396
|
+
last = next2;
|
|
1397
|
+
next2 = get_next_sibling(next2);
|
|
1398
|
+
}
|
|
1399
|
+
if (next2 === null) {
|
|
1400
|
+
hydration_mismatch();
|
|
1401
|
+
throw HYDRATION_ERROR;
|
|
1402
|
+
}
|
|
1403
|
+
if (true_default && !skip_warning) {
|
|
1404
|
+
check_hash(
|
|
1405
|
+
/** @type {Element} */
|
|
1406
|
+
next2.parentNode,
|
|
1407
|
+
hash2,
|
|
1408
|
+
value
|
|
1409
|
+
);
|
|
1410
|
+
}
|
|
1411
|
+
assign_nodes(hydrate_node, last);
|
|
1412
|
+
anchor = set_hydrate_node(next2);
|
|
1413
|
+
return;
|
|
1414
|
+
}
|
|
1415
|
+
var ns = svg ? NAMESPACE_SVG : mathml ? NAMESPACE_MATHML : void 0;
|
|
1416
|
+
var wrapper = (
|
|
1417
|
+
/** @type {HTMLTemplateElement | SVGElement | MathMLElement} */
|
|
1418
|
+
create_element(svg ? "svg" : mathml ? "math" : "template", ns)
|
|
1419
|
+
);
|
|
1420
|
+
wrapper.innerHTML = /** @type {any} */
|
|
1421
|
+
value;
|
|
1422
|
+
var node2 = svg || mathml ? wrapper : (
|
|
1423
|
+
/** @type {HTMLTemplateElement} */
|
|
1424
|
+
wrapper.content
|
|
1425
|
+
);
|
|
1426
|
+
assign_nodes(
|
|
1427
|
+
/** @type {TemplateNode} */
|
|
1428
|
+
get_first_child(node2),
|
|
1429
|
+
/** @type {TemplateNode} */
|
|
1430
|
+
node2.lastChild
|
|
1431
|
+
);
|
|
1432
|
+
if (svg || mathml) {
|
|
1433
|
+
while (get_first_child(node2)) {
|
|
1434
|
+
anchor.before(
|
|
1435
|
+
/** @type {TemplateNode} */
|
|
1436
|
+
get_first_child(node2)
|
|
1437
|
+
);
|
|
1438
|
+
}
|
|
1439
|
+
} else {
|
|
1440
|
+
anchor.before(node2);
|
|
1441
|
+
}
|
|
1442
|
+
});
|
|
1443
|
+
}
|
|
1444
|
+
|
|
1445
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/blocks/slot.js
|
|
1446
|
+
function slot(anchor, $$props, name, slot_props, fallback_fn) {
|
|
1447
|
+
if (hydrating) {
|
|
1448
|
+
hydrate_next();
|
|
1449
|
+
}
|
|
1450
|
+
var slot_fn = $$props.$$slots?.[name];
|
|
1451
|
+
var is_interop = false;
|
|
1452
|
+
if (slot_fn === true) {
|
|
1453
|
+
slot_fn = $$props[name === "default" ? "children" : name];
|
|
1454
|
+
is_interop = true;
|
|
1455
|
+
}
|
|
1456
|
+
if (slot_fn === void 0) {
|
|
1457
|
+
if (fallback_fn !== null) {
|
|
1458
|
+
fallback_fn(anchor);
|
|
1459
|
+
}
|
|
1460
|
+
} else {
|
|
1461
|
+
slot_fn(anchor, is_interop ? () => slot_props : slot_props);
|
|
1462
|
+
}
|
|
1463
|
+
}
|
|
1464
|
+
function sanitize_slots(props) {
|
|
1465
|
+
const sanitized = {};
|
|
1466
|
+
if (props.children) sanitized.default = true;
|
|
1467
|
+
for (const key2 in props.$$slots) {
|
|
1468
|
+
sanitized[key2] = true;
|
|
1469
|
+
}
|
|
1470
|
+
return sanitized;
|
|
1471
|
+
}
|
|
1472
|
+
|
|
1473
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/shared/validate.js
|
|
1474
|
+
function validate_void_dynamic_element(tag_fn) {
|
|
1475
|
+
const tag2 = tag_fn();
|
|
1476
|
+
if (tag2 && is_void(tag2)) {
|
|
1477
|
+
dynamic_void_element_content(tag2);
|
|
1478
|
+
}
|
|
1479
|
+
}
|
|
1480
|
+
function validate_dynamic_element_tag(tag_fn) {
|
|
1481
|
+
const tag2 = tag_fn();
|
|
1482
|
+
const is_string = typeof tag2 === "string";
|
|
1483
|
+
if (tag2 && !is_string) {
|
|
1484
|
+
svelte_element_invalid_this_value();
|
|
1485
|
+
}
|
|
1486
|
+
}
|
|
1487
|
+
function validate_store(store, name) {
|
|
1488
|
+
if (store != null && typeof store.subscribe !== "function") {
|
|
1489
|
+
store_invalid_shape(name);
|
|
1490
|
+
}
|
|
1491
|
+
}
|
|
1492
|
+
function prevent_snippet_stringification(fn) {
|
|
1493
|
+
fn.toString = () => {
|
|
1494
|
+
snippet_without_render_tag();
|
|
1495
|
+
return "";
|
|
1496
|
+
};
|
|
1497
|
+
return fn;
|
|
1498
|
+
}
|
|
1499
|
+
|
|
1500
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/blocks/snippet.js
|
|
1501
|
+
function snippet(node, get_snippet, ...args) {
|
|
1502
|
+
var branches = new BranchManager(node);
|
|
1503
|
+
block(() => {
|
|
1504
|
+
const snippet2 = get_snippet() ?? null;
|
|
1505
|
+
if (true_default && snippet2 == null) {
|
|
1506
|
+
invalid_snippet();
|
|
1507
|
+
}
|
|
1508
|
+
branches.ensure(snippet2, snippet2 && ((anchor) => snippet2(anchor, ...args)));
|
|
1509
|
+
}, EFFECT_TRANSPARENT);
|
|
1510
|
+
}
|
|
1511
|
+
function wrap_snippet(component2, fn) {
|
|
1512
|
+
const snippet2 = (node, ...args) => {
|
|
1513
|
+
var previous_component_function = dev_current_component_function;
|
|
1514
|
+
set_dev_current_component_function(component2);
|
|
1515
|
+
try {
|
|
1516
|
+
return fn(node, ...args);
|
|
1517
|
+
} finally {
|
|
1518
|
+
set_dev_current_component_function(previous_component_function);
|
|
1519
|
+
}
|
|
1520
|
+
};
|
|
1521
|
+
prevent_snippet_stringification(snippet2);
|
|
1522
|
+
return snippet2;
|
|
1523
|
+
}
|
|
1524
|
+
function createRawSnippet(fn) {
|
|
1525
|
+
return (anchor, ...params) => {
|
|
1526
|
+
var snippet2 = fn(...params);
|
|
1527
|
+
var element2;
|
|
1528
|
+
if (hydrating) {
|
|
1529
|
+
element2 = /** @type {Element} */
|
|
1530
|
+
hydrate_node;
|
|
1531
|
+
hydrate_next();
|
|
1532
|
+
} else {
|
|
1533
|
+
var html2 = snippet2.render().trim();
|
|
1534
|
+
var fragment = create_fragment_from_html(html2);
|
|
1535
|
+
element2 = /** @type {Element} */
|
|
1536
|
+
get_first_child(fragment);
|
|
1537
|
+
if (true_default && (get_next_sibling(element2) !== null || element2.nodeType !== ELEMENT_NODE)) {
|
|
1538
|
+
invalid_raw_snippet_render();
|
|
1539
|
+
}
|
|
1540
|
+
anchor.before(element2);
|
|
1541
|
+
}
|
|
1542
|
+
const result = snippet2.setup?.(element2);
|
|
1543
|
+
assign_nodes(element2, element2);
|
|
1544
|
+
if (typeof result === "function") {
|
|
1545
|
+
teardown(result);
|
|
1546
|
+
}
|
|
1547
|
+
};
|
|
1548
|
+
}
|
|
1549
|
+
|
|
1550
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/blocks/svelte-component.js
|
|
1551
|
+
function component(node, get_component, render_fn) {
|
|
1552
|
+
var hydration_start_node;
|
|
1553
|
+
if (hydrating) {
|
|
1554
|
+
hydration_start_node = hydrate_node;
|
|
1555
|
+
hydrate_next();
|
|
1556
|
+
}
|
|
1557
|
+
var branches = new BranchManager(node);
|
|
1558
|
+
block(() => {
|
|
1559
|
+
var component2 = get_component() ?? null;
|
|
1560
|
+
if (hydrating) {
|
|
1561
|
+
var data = read_hydration_instruction(
|
|
1562
|
+
/** @type {TemplateNode} */
|
|
1563
|
+
hydration_start_node
|
|
1564
|
+
);
|
|
1565
|
+
var server_had_component = data === HYDRATION_START;
|
|
1566
|
+
var client_has_component = component2 !== null;
|
|
1567
|
+
if (server_had_component !== client_has_component) {
|
|
1568
|
+
var anchor = skip_nodes();
|
|
1569
|
+
set_hydrate_node(anchor);
|
|
1570
|
+
branches.anchor = anchor;
|
|
1571
|
+
set_hydrating(false);
|
|
1572
|
+
branches.ensure(component2, component2 && ((target) => render_fn(target, component2)));
|
|
1573
|
+
set_hydrating(true);
|
|
1574
|
+
return;
|
|
1575
|
+
}
|
|
1576
|
+
}
|
|
1577
|
+
branches.ensure(component2, component2 && ((target) => render_fn(target, component2)));
|
|
1578
|
+
}, EFFECT_TRANSPARENT);
|
|
1579
|
+
}
|
|
1580
|
+
|
|
1581
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/timing.js
|
|
1582
|
+
var now = true_default ? () => performance.now() : () => Date.now();
|
|
1583
|
+
var raf = {
|
|
1584
|
+
// don't access requestAnimationFrame eagerly outside method
|
|
1585
|
+
// this allows basic testing of user code without JSDOM
|
|
1586
|
+
// bunder will eval and remove ternary when the user's app is built
|
|
1587
|
+
tick: (
|
|
1588
|
+
/** @param {any} _ */
|
|
1589
|
+
(_) => (true_default ? requestAnimationFrame : noop)(_)
|
|
1590
|
+
),
|
|
1591
|
+
now: () => now(),
|
|
1592
|
+
tasks: /* @__PURE__ */ new Set()
|
|
1593
|
+
};
|
|
1594
|
+
|
|
1595
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/loop.js
|
|
1596
|
+
function run_tasks() {
|
|
1597
|
+
const now2 = raf.now();
|
|
1598
|
+
raf.tasks.forEach((task) => {
|
|
1599
|
+
if (!task.c(now2)) {
|
|
1600
|
+
raf.tasks.delete(task);
|
|
1601
|
+
task.f();
|
|
1602
|
+
}
|
|
1603
|
+
});
|
|
1604
|
+
if (raf.tasks.size !== 0) {
|
|
1605
|
+
raf.tick(run_tasks);
|
|
1606
|
+
}
|
|
1607
|
+
}
|
|
1608
|
+
function loop(callback) {
|
|
1609
|
+
let task;
|
|
1610
|
+
if (raf.tasks.size === 0) {
|
|
1611
|
+
raf.tick(run_tasks);
|
|
1612
|
+
}
|
|
1613
|
+
return {
|
|
1614
|
+
promise: new Promise((fulfill) => {
|
|
1615
|
+
raf.tasks.add(task = { c: callback, f: fulfill });
|
|
1616
|
+
}),
|
|
1617
|
+
abort() {
|
|
1618
|
+
raf.tasks.delete(task);
|
|
1619
|
+
}
|
|
1620
|
+
};
|
|
1621
|
+
}
|
|
1622
|
+
|
|
1623
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/elements/transitions.js
|
|
1624
|
+
function dispatch_event(element2, type) {
|
|
1625
|
+
without_reactive_context(() => {
|
|
1626
|
+
element2.dispatchEvent(new CustomEvent(type));
|
|
1627
|
+
});
|
|
1628
|
+
}
|
|
1629
|
+
function css_property_to_camelcase(style) {
|
|
1630
|
+
if (style === "float") return "cssFloat";
|
|
1631
|
+
if (style === "offset") return "cssOffset";
|
|
1632
|
+
if (style.startsWith("--")) return style;
|
|
1633
|
+
const parts = style.split("-");
|
|
1634
|
+
if (parts.length === 1) return parts[0];
|
|
1635
|
+
return parts[0] + parts.slice(1).map(
|
|
1636
|
+
/** @param {any} word */
|
|
1637
|
+
(word) => word[0].toUpperCase() + word.slice(1)
|
|
1638
|
+
).join("");
|
|
1639
|
+
}
|
|
1640
|
+
function css_to_keyframe(css) {
|
|
1641
|
+
const keyframe = {};
|
|
1642
|
+
const parts = css.split(";");
|
|
1643
|
+
for (const part of parts) {
|
|
1644
|
+
const [property, value] = part.split(":");
|
|
1645
|
+
if (!property || value === void 0) break;
|
|
1646
|
+
const formatted_property = css_property_to_camelcase(property.trim());
|
|
1647
|
+
keyframe[formatted_property] = value.trim();
|
|
1648
|
+
}
|
|
1649
|
+
return keyframe;
|
|
1650
|
+
}
|
|
1651
|
+
var linear = (t) => t;
|
|
1652
|
+
var animation_effect_override = null;
|
|
1653
|
+
function set_animation_effect_override(v) {
|
|
1654
|
+
animation_effect_override = v;
|
|
1655
|
+
}
|
|
1656
|
+
function animation(element2, get_fn, get_params) {
|
|
1657
|
+
var effect2 = animation_effect_override ?? /** @type {Effect} */
|
|
1658
|
+
active_effect;
|
|
1659
|
+
var nodes = (
|
|
1660
|
+
/** @type {EffectNodes} */
|
|
1661
|
+
effect2.nodes
|
|
1662
|
+
);
|
|
1663
|
+
var from;
|
|
1664
|
+
var to;
|
|
1665
|
+
var animation2;
|
|
1666
|
+
var original_styles = null;
|
|
1667
|
+
nodes.a ??= {
|
|
1668
|
+
element: element2,
|
|
1669
|
+
measure() {
|
|
1670
|
+
from = this.element.getBoundingClientRect();
|
|
1671
|
+
},
|
|
1672
|
+
apply() {
|
|
1673
|
+
animation2?.abort();
|
|
1674
|
+
to = this.element.getBoundingClientRect();
|
|
1675
|
+
if (from.left !== to.left || from.right !== to.right || from.top !== to.top || from.bottom !== to.bottom) {
|
|
1676
|
+
const options = get_fn()(this.element, { from, to }, get_params?.());
|
|
1677
|
+
animation2 = animate(this.element, options, void 0, 1, () => {
|
|
1678
|
+
animation2?.abort();
|
|
1679
|
+
animation2 = void 0;
|
|
1680
|
+
});
|
|
1681
|
+
}
|
|
1682
|
+
},
|
|
1683
|
+
fix() {
|
|
1684
|
+
if (element2.getAnimations().length) return;
|
|
1685
|
+
var { position, width, height } = getComputedStyle(element2);
|
|
1686
|
+
if (position !== "absolute" && position !== "fixed") {
|
|
1687
|
+
var style = (
|
|
1688
|
+
/** @type {HTMLElement | SVGElement} */
|
|
1689
|
+
element2.style
|
|
1690
|
+
);
|
|
1691
|
+
original_styles = {
|
|
1692
|
+
position: style.position,
|
|
1693
|
+
width: style.width,
|
|
1694
|
+
height: style.height,
|
|
1695
|
+
transform: style.transform
|
|
1696
|
+
};
|
|
1697
|
+
style.position = "absolute";
|
|
1698
|
+
style.width = width;
|
|
1699
|
+
style.height = height;
|
|
1700
|
+
var to2 = element2.getBoundingClientRect();
|
|
1701
|
+
if (from.left !== to2.left || from.top !== to2.top) {
|
|
1702
|
+
var transform = `translate(${from.left - to2.left}px, ${from.top - to2.top}px)`;
|
|
1703
|
+
style.transform = style.transform ? `${style.transform} ${transform}` : transform;
|
|
1704
|
+
}
|
|
1705
|
+
}
|
|
1706
|
+
},
|
|
1707
|
+
unfix() {
|
|
1708
|
+
if (original_styles) {
|
|
1709
|
+
var style = (
|
|
1710
|
+
/** @type {HTMLElement | SVGElement} */
|
|
1711
|
+
element2.style
|
|
1712
|
+
);
|
|
1713
|
+
style.position = original_styles.position;
|
|
1714
|
+
style.width = original_styles.width;
|
|
1715
|
+
style.height = original_styles.height;
|
|
1716
|
+
style.transform = original_styles.transform;
|
|
1717
|
+
}
|
|
1718
|
+
}
|
|
1719
|
+
};
|
|
1720
|
+
nodes.a.element = element2;
|
|
1721
|
+
}
|
|
1722
|
+
function transition(flags, element2, get_fn, get_params) {
|
|
1723
|
+
var is_intro = (flags & TRANSITION_IN) !== 0;
|
|
1724
|
+
var is_outro = (flags & TRANSITION_OUT) !== 0;
|
|
1725
|
+
var is_both = is_intro && is_outro;
|
|
1726
|
+
var is_global = (flags & TRANSITION_GLOBAL) !== 0;
|
|
1727
|
+
var direction = is_both ? "both" : is_intro ? "in" : "out";
|
|
1728
|
+
var current_options;
|
|
1729
|
+
var inert = element2.inert;
|
|
1730
|
+
var overflow = element2.style.overflow;
|
|
1731
|
+
var intro;
|
|
1732
|
+
var outro;
|
|
1733
|
+
function get_options() {
|
|
1734
|
+
return without_reactive_context(() => {
|
|
1735
|
+
return current_options ??= get_fn()(element2, get_params?.() ?? /** @type {P} */
|
|
1736
|
+
{}, {
|
|
1737
|
+
direction
|
|
1738
|
+
});
|
|
1739
|
+
});
|
|
1740
|
+
}
|
|
1741
|
+
var transition2 = {
|
|
1742
|
+
is_global,
|
|
1743
|
+
in() {
|
|
1744
|
+
element2.inert = inert;
|
|
1745
|
+
if (!is_intro) {
|
|
1746
|
+
outro?.abort();
|
|
1747
|
+
outro?.reset?.();
|
|
1748
|
+
return;
|
|
1749
|
+
}
|
|
1750
|
+
if (!is_outro) {
|
|
1751
|
+
intro?.abort();
|
|
1752
|
+
}
|
|
1753
|
+
intro = animate(element2, get_options(), outro, 1, () => {
|
|
1754
|
+
dispatch_event(element2, "introend");
|
|
1755
|
+
intro?.abort();
|
|
1756
|
+
intro = current_options = void 0;
|
|
1757
|
+
element2.style.overflow = overflow;
|
|
1758
|
+
});
|
|
1759
|
+
},
|
|
1760
|
+
out(fn) {
|
|
1761
|
+
if (!is_outro) {
|
|
1762
|
+
fn?.();
|
|
1763
|
+
current_options = void 0;
|
|
1764
|
+
return;
|
|
1765
|
+
}
|
|
1766
|
+
element2.inert = true;
|
|
1767
|
+
outro = animate(element2, get_options(), intro, 0, () => {
|
|
1768
|
+
dispatch_event(element2, "outroend");
|
|
1769
|
+
fn?.();
|
|
1770
|
+
});
|
|
1771
|
+
},
|
|
1772
|
+
stop: () => {
|
|
1773
|
+
intro?.abort();
|
|
1774
|
+
outro?.abort();
|
|
1775
|
+
}
|
|
1776
|
+
};
|
|
1777
|
+
var e = (
|
|
1778
|
+
/** @type {Effect & { nodes: EffectNodes }} */
|
|
1779
|
+
active_effect
|
|
1780
|
+
);
|
|
1781
|
+
(e.nodes.t ??= []).push(transition2);
|
|
1782
|
+
if (is_intro && should_intro) {
|
|
1783
|
+
var run3 = is_global;
|
|
1784
|
+
if (!run3) {
|
|
1785
|
+
var block2 = (
|
|
1786
|
+
/** @type {Effect | null} */
|
|
1787
|
+
e.parent
|
|
1788
|
+
);
|
|
1789
|
+
while (block2 && (block2.f & EFFECT_TRANSPARENT) !== 0) {
|
|
1790
|
+
while (block2 = block2.parent) {
|
|
1791
|
+
if ((block2.f & BLOCK_EFFECT) !== 0) break;
|
|
1792
|
+
}
|
|
1793
|
+
}
|
|
1794
|
+
run3 = !block2 || (block2.f & REACTION_RAN) !== 0;
|
|
1795
|
+
}
|
|
1796
|
+
if (run3) {
|
|
1797
|
+
effect(() => {
|
|
1798
|
+
untrack(() => transition2.in());
|
|
1799
|
+
});
|
|
1800
|
+
}
|
|
1801
|
+
}
|
|
1802
|
+
}
|
|
1803
|
+
function animate(element2, options, counterpart, t2, on_finish) {
|
|
1804
|
+
var is_intro = t2 === 1;
|
|
1805
|
+
if (is_function(options)) {
|
|
1806
|
+
var a;
|
|
1807
|
+
var aborted2 = false;
|
|
1808
|
+
queue_micro_task(() => {
|
|
1809
|
+
if (aborted2) return;
|
|
1810
|
+
var o = options({ direction: is_intro ? "in" : "out" });
|
|
1811
|
+
a = animate(element2, o, counterpart, t2, on_finish);
|
|
1812
|
+
});
|
|
1813
|
+
return {
|
|
1814
|
+
abort: () => {
|
|
1815
|
+
aborted2 = true;
|
|
1816
|
+
a?.abort();
|
|
1817
|
+
},
|
|
1818
|
+
deactivate: () => a.deactivate(),
|
|
1819
|
+
reset: () => a.reset(),
|
|
1820
|
+
t: () => a.t()
|
|
1821
|
+
};
|
|
1822
|
+
}
|
|
1823
|
+
counterpart?.deactivate();
|
|
1824
|
+
if (!options?.duration && !options?.delay) {
|
|
1825
|
+
dispatch_event(element2, is_intro ? "introstart" : "outrostart");
|
|
1826
|
+
on_finish();
|
|
1827
|
+
return {
|
|
1828
|
+
abort: noop,
|
|
1829
|
+
deactivate: noop,
|
|
1830
|
+
reset: noop,
|
|
1831
|
+
t: () => t2
|
|
1832
|
+
};
|
|
1833
|
+
}
|
|
1834
|
+
const { delay = 0, css, tick: tick2, easing = linear } = options;
|
|
1835
|
+
var keyframes = [];
|
|
1836
|
+
if (is_intro && counterpart === void 0) {
|
|
1837
|
+
if (tick2) {
|
|
1838
|
+
tick2(0, 1);
|
|
1839
|
+
}
|
|
1840
|
+
if (css) {
|
|
1841
|
+
var styles = css_to_keyframe(css(0, 1));
|
|
1842
|
+
keyframes.push(styles, styles);
|
|
1843
|
+
}
|
|
1844
|
+
}
|
|
1845
|
+
var get_t = () => 1 - t2;
|
|
1846
|
+
var animation2 = element2.animate(keyframes, { duration: delay, fill: "forwards" });
|
|
1847
|
+
animation2.onfinish = () => {
|
|
1848
|
+
animation2.cancel();
|
|
1849
|
+
dispatch_event(element2, is_intro ? "introstart" : "outrostart");
|
|
1850
|
+
var t1 = counterpart?.t() ?? 1 - t2;
|
|
1851
|
+
counterpart?.abort();
|
|
1852
|
+
var delta = t2 - t1;
|
|
1853
|
+
var duration = (
|
|
1854
|
+
/** @type {number} */
|
|
1855
|
+
options.duration * Math.abs(delta)
|
|
1856
|
+
);
|
|
1857
|
+
var keyframes2 = [];
|
|
1858
|
+
if (duration > 0) {
|
|
1859
|
+
var needs_overflow_hidden = false;
|
|
1860
|
+
if (css) {
|
|
1861
|
+
var n = Math.ceil(duration / (1e3 / 60));
|
|
1862
|
+
for (var i = 0; i <= n; i += 1) {
|
|
1863
|
+
var t = t1 + delta * easing(i / n);
|
|
1864
|
+
var styles2 = css_to_keyframe(css(t, 1 - t));
|
|
1865
|
+
keyframes2.push(styles2);
|
|
1866
|
+
needs_overflow_hidden ||= styles2.overflow === "hidden";
|
|
1867
|
+
}
|
|
1868
|
+
}
|
|
1869
|
+
if (needs_overflow_hidden) {
|
|
1870
|
+
element2.style.overflow = "hidden";
|
|
1871
|
+
}
|
|
1872
|
+
get_t = () => {
|
|
1873
|
+
var time = (
|
|
1874
|
+
/** @type {number} */
|
|
1875
|
+
/** @type {globalThis.Animation} */
|
|
1876
|
+
animation2.currentTime
|
|
1877
|
+
);
|
|
1878
|
+
return t1 + delta * easing(time / duration);
|
|
1879
|
+
};
|
|
1880
|
+
if (tick2) {
|
|
1881
|
+
loop(() => {
|
|
1882
|
+
if (animation2.playState !== "running") return false;
|
|
1883
|
+
var t3 = get_t();
|
|
1884
|
+
tick2(t3, 1 - t3);
|
|
1885
|
+
return true;
|
|
1886
|
+
});
|
|
1887
|
+
}
|
|
1888
|
+
}
|
|
1889
|
+
animation2 = element2.animate(keyframes2, { duration, fill: "forwards" });
|
|
1890
|
+
animation2.onfinish = () => {
|
|
1891
|
+
get_t = () => t2;
|
|
1892
|
+
tick2?.(t2, 1 - t2);
|
|
1893
|
+
on_finish();
|
|
1894
|
+
};
|
|
1895
|
+
};
|
|
1896
|
+
return {
|
|
1897
|
+
abort: () => {
|
|
1898
|
+
if (animation2) {
|
|
1899
|
+
animation2.cancel();
|
|
1900
|
+
animation2.effect = null;
|
|
1901
|
+
animation2.onfinish = noop;
|
|
1902
|
+
}
|
|
1903
|
+
},
|
|
1904
|
+
deactivate: () => {
|
|
1905
|
+
on_finish = noop;
|
|
1906
|
+
},
|
|
1907
|
+
reset: () => {
|
|
1908
|
+
if (t2 === 0) {
|
|
1909
|
+
tick2?.(1, 0);
|
|
1910
|
+
}
|
|
1911
|
+
},
|
|
1912
|
+
t: () => get_t()
|
|
1913
|
+
};
|
|
1914
|
+
}
|
|
1915
|
+
|
|
1916
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/blocks/svelte-element.js
|
|
1917
|
+
function element(node, get_tag, is_svg, render_fn, get_namespace, location) {
|
|
1918
|
+
let was_hydrating = hydrating;
|
|
1919
|
+
if (hydrating) {
|
|
1920
|
+
hydrate_next();
|
|
1921
|
+
}
|
|
1922
|
+
var filename = true_default && location && component_context?.function[FILENAME];
|
|
1923
|
+
var element2 = null;
|
|
1924
|
+
if (hydrating && hydrate_node.nodeType === ELEMENT_NODE) {
|
|
1925
|
+
element2 = /** @type {Element} */
|
|
1926
|
+
hydrate_node;
|
|
1927
|
+
hydrate_next();
|
|
1928
|
+
}
|
|
1929
|
+
var anchor = (
|
|
1930
|
+
/** @type {TemplateNode} */
|
|
1931
|
+
hydrating ? hydrate_node : node
|
|
1932
|
+
);
|
|
1933
|
+
var parent_effect = (
|
|
1934
|
+
/** @type {Effect} */
|
|
1935
|
+
active_effect
|
|
1936
|
+
);
|
|
1937
|
+
var branches = new BranchManager(anchor, false);
|
|
1938
|
+
block(() => {
|
|
1939
|
+
const next_tag = get_tag() || null;
|
|
1940
|
+
var ns = get_namespace ? get_namespace() : is_svg || next_tag === "svg" ? NAMESPACE_SVG : void 0;
|
|
1941
|
+
if (next_tag === null) {
|
|
1942
|
+
branches.ensure(null, null);
|
|
1943
|
+
set_should_intro(true);
|
|
1944
|
+
return;
|
|
1945
|
+
}
|
|
1946
|
+
branches.ensure(next_tag, (anchor2) => {
|
|
1947
|
+
if (next_tag) {
|
|
1948
|
+
element2 = hydrating ? (
|
|
1949
|
+
/** @type {Element} */
|
|
1950
|
+
element2
|
|
1951
|
+
) : create_element(next_tag, ns);
|
|
1952
|
+
if (true_default && location) {
|
|
1953
|
+
element2.__svelte_meta = {
|
|
1954
|
+
parent: dev_stack,
|
|
1955
|
+
loc: {
|
|
1956
|
+
file: filename,
|
|
1957
|
+
line: location[0],
|
|
1958
|
+
column: location[1]
|
|
1959
|
+
}
|
|
1960
|
+
};
|
|
1961
|
+
}
|
|
1962
|
+
assign_nodes(element2, element2);
|
|
1963
|
+
if (render_fn) {
|
|
1964
|
+
if (hydrating && is_raw_text_element(next_tag)) {
|
|
1965
|
+
element2.append(document.createComment(""));
|
|
1966
|
+
}
|
|
1967
|
+
var child_anchor = hydrating ? get_first_child(element2) : element2.appendChild(create_text());
|
|
1968
|
+
if (hydrating) {
|
|
1969
|
+
if (child_anchor === null) {
|
|
1970
|
+
set_hydrating(false);
|
|
1971
|
+
} else {
|
|
1972
|
+
set_hydrate_node(child_anchor);
|
|
1973
|
+
}
|
|
1974
|
+
}
|
|
1975
|
+
set_animation_effect_override(parent_effect);
|
|
1976
|
+
render_fn(element2, child_anchor);
|
|
1977
|
+
set_animation_effect_override(null);
|
|
1978
|
+
}
|
|
1979
|
+
active_effect.nodes.end = element2;
|
|
1980
|
+
anchor2.before(element2);
|
|
1981
|
+
}
|
|
1982
|
+
if (hydrating) {
|
|
1983
|
+
set_hydrate_node(anchor2);
|
|
1984
|
+
}
|
|
1985
|
+
});
|
|
1986
|
+
set_should_intro(true);
|
|
1987
|
+
return () => {
|
|
1988
|
+
if (next_tag) {
|
|
1989
|
+
set_should_intro(false);
|
|
1990
|
+
}
|
|
1991
|
+
};
|
|
1992
|
+
}, EFFECT_TRANSPARENT);
|
|
1993
|
+
teardown(() => {
|
|
1994
|
+
set_should_intro(true);
|
|
1995
|
+
});
|
|
1996
|
+
if (was_hydrating) {
|
|
1997
|
+
set_hydrating(true);
|
|
1998
|
+
set_hydrate_node(anchor);
|
|
1999
|
+
}
|
|
2000
|
+
}
|
|
2001
|
+
|
|
2002
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/blocks/svelte-head.js
|
|
2003
|
+
function head(hash2, render_fn) {
|
|
2004
|
+
let previous_hydrate_node = null;
|
|
2005
|
+
let was_hydrating = hydrating;
|
|
2006
|
+
var anchor;
|
|
2007
|
+
if (hydrating) {
|
|
2008
|
+
previous_hydrate_node = hydrate_node;
|
|
2009
|
+
var head_anchor = get_first_child(document.head);
|
|
2010
|
+
while (head_anchor !== null && (head_anchor.nodeType !== COMMENT_NODE || /** @type {Comment} */
|
|
2011
|
+
head_anchor.data !== hash2)) {
|
|
2012
|
+
head_anchor = get_next_sibling(head_anchor);
|
|
2013
|
+
}
|
|
2014
|
+
if (head_anchor === null) {
|
|
2015
|
+
set_hydrating(false);
|
|
2016
|
+
} else {
|
|
2017
|
+
var start = (
|
|
2018
|
+
/** @type {TemplateNode} */
|
|
2019
|
+
get_next_sibling(head_anchor)
|
|
2020
|
+
);
|
|
2021
|
+
head_anchor.remove();
|
|
2022
|
+
set_hydrate_node(start);
|
|
2023
|
+
}
|
|
2024
|
+
}
|
|
2025
|
+
if (!hydrating) {
|
|
2026
|
+
anchor = document.head.appendChild(create_text());
|
|
2027
|
+
}
|
|
2028
|
+
try {
|
|
2029
|
+
block(() => render_fn(anchor), HEAD_EFFECT | EFFECT_PRESERVED);
|
|
2030
|
+
} finally {
|
|
2031
|
+
if (was_hydrating) {
|
|
2032
|
+
set_hydrating(true);
|
|
2033
|
+
set_hydrate_node(
|
|
2034
|
+
/** @type {TemplateNode} */
|
|
2035
|
+
previous_hydrate_node
|
|
2036
|
+
);
|
|
2037
|
+
}
|
|
2038
|
+
}
|
|
2039
|
+
}
|
|
2040
|
+
|
|
2041
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/css.js
|
|
2042
|
+
function append_styles(anchor, css) {
|
|
2043
|
+
effect(() => {
|
|
2044
|
+
var root = anchor.getRootNode();
|
|
2045
|
+
var target = (
|
|
2046
|
+
/** @type {ShadowRoot} */
|
|
2047
|
+
root.host ? (
|
|
2048
|
+
/** @type {ShadowRoot} */
|
|
2049
|
+
root
|
|
2050
|
+
) : (
|
|
2051
|
+
/** @type {Document} */
|
|
2052
|
+
root.head ?? /** @type {Document} */
|
|
2053
|
+
root.ownerDocument.head
|
|
2054
|
+
)
|
|
2055
|
+
);
|
|
2056
|
+
if (!target.querySelector("#" + css.hash)) {
|
|
2057
|
+
const style = create_element("style");
|
|
2058
|
+
style.id = css.hash;
|
|
2059
|
+
style.textContent = css.code;
|
|
2060
|
+
target.appendChild(style);
|
|
2061
|
+
if (true_default) {
|
|
2062
|
+
register_style(css.hash, style);
|
|
2063
|
+
}
|
|
2064
|
+
}
|
|
2065
|
+
});
|
|
2066
|
+
}
|
|
2067
|
+
|
|
2068
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/elements/actions.js
|
|
2069
|
+
function action(dom, action2, get_value) {
|
|
2070
|
+
effect(() => {
|
|
2071
|
+
var payload = untrack(() => action2(dom, get_value?.()) || {});
|
|
2072
|
+
if (get_value && payload?.update) {
|
|
2073
|
+
var inited = false;
|
|
2074
|
+
var prev = (
|
|
2075
|
+
/** @type {any} */
|
|
2076
|
+
{}
|
|
2077
|
+
);
|
|
2078
|
+
render_effect(() => {
|
|
2079
|
+
var value = get_value();
|
|
2080
|
+
deep_read_state(value);
|
|
2081
|
+
if (inited && safe_not_equal(prev, value)) {
|
|
2082
|
+
prev = value;
|
|
2083
|
+
payload.update(value);
|
|
2084
|
+
}
|
|
2085
|
+
});
|
|
2086
|
+
inited = true;
|
|
2087
|
+
}
|
|
2088
|
+
if (payload?.destroy) {
|
|
2089
|
+
return () => (
|
|
2090
|
+
/** @type {Function} */
|
|
2091
|
+
payload.destroy()
|
|
2092
|
+
);
|
|
2093
|
+
}
|
|
2094
|
+
});
|
|
2095
|
+
}
|
|
2096
|
+
|
|
2097
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/elements/attachments.js
|
|
2098
|
+
function attach(node, get_fn) {
|
|
2099
|
+
var fn = void 0;
|
|
2100
|
+
var e;
|
|
2101
|
+
managed(() => {
|
|
2102
|
+
if (fn !== (fn = get_fn())) {
|
|
2103
|
+
if (e) {
|
|
2104
|
+
destroy_effect(e);
|
|
2105
|
+
e = null;
|
|
2106
|
+
}
|
|
2107
|
+
if (fn) {
|
|
2108
|
+
e = branch(() => {
|
|
2109
|
+
effect(() => (
|
|
2110
|
+
/** @type {(node: Element) => void} */
|
|
2111
|
+
fn(node)
|
|
2112
|
+
));
|
|
2113
|
+
});
|
|
2114
|
+
}
|
|
2115
|
+
}
|
|
2116
|
+
});
|
|
2117
|
+
}
|
|
2118
|
+
|
|
2119
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/escaping.js
|
|
2120
|
+
var ATTR_REGEX = /[&"<]/g;
|
|
2121
|
+
var CONTENT_REGEX = /[&<]/g;
|
|
2122
|
+
function escape_html(value, is_attr) {
|
|
2123
|
+
const str = String(value ?? "");
|
|
2124
|
+
const pattern = is_attr ? ATTR_REGEX : CONTENT_REGEX;
|
|
2125
|
+
pattern.lastIndex = 0;
|
|
2126
|
+
let escaped = "";
|
|
2127
|
+
let last = 0;
|
|
2128
|
+
while (pattern.test(str)) {
|
|
2129
|
+
const i = pattern.lastIndex - 1;
|
|
2130
|
+
const ch = str[i];
|
|
2131
|
+
escaped += str.substring(last, i) + (ch === "&" ? "&" : ch === '"' ? """ : "<");
|
|
2132
|
+
last = i + 1;
|
|
2133
|
+
}
|
|
2134
|
+
return escaped + str.substring(last);
|
|
2135
|
+
}
|
|
2136
|
+
|
|
2137
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/shared/attributes.js
|
|
2138
|
+
var replacements = {
|
|
2139
|
+
translate: /* @__PURE__ */ new Map([
|
|
2140
|
+
[true, "yes"],
|
|
2141
|
+
[false, "no"]
|
|
2142
|
+
])
|
|
2143
|
+
};
|
|
2144
|
+
function attr(name, value, is_boolean = false) {
|
|
2145
|
+
if (name === "hidden" && value !== "until-found") {
|
|
2146
|
+
is_boolean = true;
|
|
2147
|
+
}
|
|
2148
|
+
if (value == null || !value && is_boolean) return "";
|
|
2149
|
+
const normalized = has_own_property.call(replacements, name) && replacements[name].get(value) || value;
|
|
2150
|
+
const assignment = is_boolean ? `=""` : `="${escape_html(normalized, true)}"`;
|
|
2151
|
+
return ` ${name}${assignment}`;
|
|
2152
|
+
}
|
|
2153
|
+
function clsx2(value) {
|
|
2154
|
+
if (typeof value === "object") {
|
|
2155
|
+
return clsx(value);
|
|
2156
|
+
} else {
|
|
2157
|
+
return value ?? "";
|
|
2158
|
+
}
|
|
2159
|
+
}
|
|
2160
|
+
var whitespace = [..." \n\r\f \v\uFEFF"];
|
|
2161
|
+
function to_class(value, hash2, directives) {
|
|
2162
|
+
var classname = value == null ? "" : "" + value;
|
|
2163
|
+
if (hash2) {
|
|
2164
|
+
classname = classname ? classname + " " + hash2 : hash2;
|
|
2165
|
+
}
|
|
2166
|
+
if (directives) {
|
|
2167
|
+
for (var key2 of Object.keys(directives)) {
|
|
2168
|
+
if (directives[key2]) {
|
|
2169
|
+
classname = classname ? classname + " " + key2 : key2;
|
|
2170
|
+
} else if (classname.length) {
|
|
2171
|
+
var len = key2.length;
|
|
2172
|
+
var a = 0;
|
|
2173
|
+
while ((a = classname.indexOf(key2, a)) >= 0) {
|
|
2174
|
+
var b = a + len;
|
|
2175
|
+
if ((a === 0 || whitespace.includes(classname[a - 1])) && (b === classname.length || whitespace.includes(classname[b]))) {
|
|
2176
|
+
classname = (a === 0 ? "" : classname.substring(0, a)) + classname.substring(b + 1);
|
|
2177
|
+
} else {
|
|
2178
|
+
a = b;
|
|
2179
|
+
}
|
|
2180
|
+
}
|
|
2181
|
+
}
|
|
2182
|
+
}
|
|
2183
|
+
}
|
|
2184
|
+
return classname === "" ? null : classname;
|
|
2185
|
+
}
|
|
2186
|
+
function append_styles2(styles, important = false) {
|
|
2187
|
+
var separator = important ? " !important;" : ";";
|
|
2188
|
+
var css = "";
|
|
2189
|
+
for (var key2 of Object.keys(styles)) {
|
|
2190
|
+
var value = styles[key2];
|
|
2191
|
+
if (value != null && value !== "") {
|
|
2192
|
+
css += " " + key2 + ": " + value + separator;
|
|
2193
|
+
}
|
|
2194
|
+
}
|
|
2195
|
+
return css;
|
|
2196
|
+
}
|
|
2197
|
+
function to_css_name(name) {
|
|
2198
|
+
if (name[0] !== "-" || name[1] !== "-") {
|
|
2199
|
+
return name.toLowerCase();
|
|
2200
|
+
}
|
|
2201
|
+
return name;
|
|
2202
|
+
}
|
|
2203
|
+
function to_style(value, styles) {
|
|
2204
|
+
if (styles) {
|
|
2205
|
+
var new_style = "";
|
|
2206
|
+
var normal_styles;
|
|
2207
|
+
var important_styles;
|
|
2208
|
+
if (Array.isArray(styles)) {
|
|
2209
|
+
normal_styles = styles[0];
|
|
2210
|
+
important_styles = styles[1];
|
|
2211
|
+
} else {
|
|
2212
|
+
normal_styles = styles;
|
|
2213
|
+
}
|
|
2214
|
+
if (value) {
|
|
2215
|
+
value = String(value).replaceAll(/\s*\/\*.*?\*\/\s*/g, "").trim();
|
|
2216
|
+
var in_str = false;
|
|
2217
|
+
var in_apo = 0;
|
|
2218
|
+
var in_comment = false;
|
|
2219
|
+
var reserved_names = [];
|
|
2220
|
+
if (normal_styles) {
|
|
2221
|
+
reserved_names.push(...Object.keys(normal_styles).map(to_css_name));
|
|
2222
|
+
}
|
|
2223
|
+
if (important_styles) {
|
|
2224
|
+
reserved_names.push(...Object.keys(important_styles).map(to_css_name));
|
|
2225
|
+
}
|
|
2226
|
+
var start_index = 0;
|
|
2227
|
+
var name_index = -1;
|
|
2228
|
+
const len = value.length;
|
|
2229
|
+
for (var i = 0; i < len; i++) {
|
|
2230
|
+
var c = value[i];
|
|
2231
|
+
if (in_comment) {
|
|
2232
|
+
if (c === "/" && value[i - 1] === "*") {
|
|
2233
|
+
in_comment = false;
|
|
2234
|
+
}
|
|
2235
|
+
} else if (in_str) {
|
|
2236
|
+
if (in_str === c) {
|
|
2237
|
+
in_str = false;
|
|
2238
|
+
}
|
|
2239
|
+
} else if (c === "/" && value[i + 1] === "*") {
|
|
2240
|
+
in_comment = true;
|
|
2241
|
+
} else if (c === '"' || c === "'") {
|
|
2242
|
+
in_str = c;
|
|
2243
|
+
} else if (c === "(") {
|
|
2244
|
+
in_apo++;
|
|
2245
|
+
} else if (c === ")") {
|
|
2246
|
+
in_apo--;
|
|
2247
|
+
}
|
|
2248
|
+
if (!in_comment && in_str === false && in_apo === 0) {
|
|
2249
|
+
if (c === ":" && name_index === -1) {
|
|
2250
|
+
name_index = i;
|
|
2251
|
+
} else if (c === ";" || i === len - 1) {
|
|
2252
|
+
if (name_index !== -1) {
|
|
2253
|
+
var name = to_css_name(value.substring(start_index, name_index).trim());
|
|
2254
|
+
if (!reserved_names.includes(name)) {
|
|
2255
|
+
if (c !== ";") {
|
|
2256
|
+
i++;
|
|
2257
|
+
}
|
|
2258
|
+
var property = value.substring(start_index, i).trim();
|
|
2259
|
+
new_style += " " + property + ";";
|
|
2260
|
+
}
|
|
2261
|
+
}
|
|
2262
|
+
start_index = i + 1;
|
|
2263
|
+
name_index = -1;
|
|
2264
|
+
}
|
|
2265
|
+
}
|
|
2266
|
+
}
|
|
2267
|
+
}
|
|
2268
|
+
if (normal_styles) {
|
|
2269
|
+
new_style += append_styles2(normal_styles);
|
|
2270
|
+
}
|
|
2271
|
+
if (important_styles) {
|
|
2272
|
+
new_style += append_styles2(important_styles, true);
|
|
2273
|
+
}
|
|
2274
|
+
new_style = new_style.trim();
|
|
2275
|
+
return new_style === "" ? null : new_style;
|
|
2276
|
+
}
|
|
2277
|
+
return value == null ? null : String(value);
|
|
2278
|
+
}
|
|
2279
|
+
|
|
2280
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/elements/class.js
|
|
2281
|
+
function set_class(dom, is_html, value, hash2, prev_classes, next_classes) {
|
|
2282
|
+
var prev = dom.__className;
|
|
2283
|
+
if (hydrating || prev !== value || prev === void 0) {
|
|
2284
|
+
var next_class_name = to_class(value, hash2, next_classes);
|
|
2285
|
+
if (!hydrating || next_class_name !== dom.getAttribute("class")) {
|
|
2286
|
+
if (next_class_name == null) {
|
|
2287
|
+
dom.removeAttribute("class");
|
|
2288
|
+
} else if (is_html) {
|
|
2289
|
+
dom.className = next_class_name;
|
|
2290
|
+
} else {
|
|
2291
|
+
dom.setAttribute("class", next_class_name);
|
|
2292
|
+
}
|
|
2293
|
+
}
|
|
2294
|
+
dom.__className = value;
|
|
2295
|
+
} else if (next_classes && prev_classes !== next_classes) {
|
|
2296
|
+
for (var key2 in next_classes) {
|
|
2297
|
+
var is_present = !!next_classes[key2];
|
|
2298
|
+
if (prev_classes == null || is_present !== !!prev_classes[key2]) {
|
|
2299
|
+
dom.classList.toggle(key2, is_present);
|
|
2300
|
+
}
|
|
2301
|
+
}
|
|
2302
|
+
}
|
|
2303
|
+
return next_classes;
|
|
2304
|
+
}
|
|
2305
|
+
|
|
2306
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/elements/style.js
|
|
2307
|
+
function update_styles(dom, prev = {}, next2, priority) {
|
|
2308
|
+
for (var key2 in next2) {
|
|
2309
|
+
var value = next2[key2];
|
|
2310
|
+
if (prev[key2] !== value) {
|
|
2311
|
+
if (next2[key2] == null) {
|
|
2312
|
+
dom.style.removeProperty(key2);
|
|
2313
|
+
} else {
|
|
2314
|
+
dom.style.setProperty(key2, value, priority);
|
|
2315
|
+
}
|
|
2316
|
+
}
|
|
2317
|
+
}
|
|
2318
|
+
}
|
|
2319
|
+
function set_style(dom, value, prev_styles, next_styles) {
|
|
2320
|
+
var prev = dom.__style;
|
|
2321
|
+
if (hydrating || prev !== value) {
|
|
2322
|
+
var next_style_attr = to_style(value, next_styles);
|
|
2323
|
+
if (!hydrating || next_style_attr !== dom.getAttribute("style")) {
|
|
2324
|
+
if (next_style_attr == null) {
|
|
2325
|
+
dom.removeAttribute("style");
|
|
2326
|
+
} else {
|
|
2327
|
+
dom.style.cssText = next_style_attr;
|
|
2328
|
+
}
|
|
2329
|
+
}
|
|
2330
|
+
dom.__style = value;
|
|
2331
|
+
} else if (next_styles) {
|
|
2332
|
+
if (Array.isArray(next_styles)) {
|
|
2333
|
+
update_styles(dom, prev_styles?.[0], next_styles[0]);
|
|
2334
|
+
update_styles(dom, prev_styles?.[1], next_styles[1], "important");
|
|
2335
|
+
} else {
|
|
2336
|
+
update_styles(dom, prev_styles, next_styles);
|
|
2337
|
+
}
|
|
2338
|
+
}
|
|
2339
|
+
return next_styles;
|
|
2340
|
+
}
|
|
2341
|
+
|
|
2342
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/elements/bindings/select.js
|
|
2343
|
+
function select_option(select, value, mounting = false) {
|
|
2344
|
+
if (select.multiple) {
|
|
2345
|
+
if (value == void 0) {
|
|
2346
|
+
return;
|
|
2347
|
+
}
|
|
2348
|
+
if (!is_array(value)) {
|
|
2349
|
+
return select_multiple_invalid_value();
|
|
2350
|
+
}
|
|
2351
|
+
for (var option of select.options) {
|
|
2352
|
+
option.selected = value.includes(get_option_value(option));
|
|
2353
|
+
}
|
|
2354
|
+
return;
|
|
2355
|
+
}
|
|
2356
|
+
for (option of select.options) {
|
|
2357
|
+
var option_value = get_option_value(option);
|
|
2358
|
+
if (is(option_value, value)) {
|
|
2359
|
+
option.selected = true;
|
|
2360
|
+
return;
|
|
2361
|
+
}
|
|
2362
|
+
}
|
|
2363
|
+
if (!mounting || value !== void 0) {
|
|
2364
|
+
select.selectedIndex = -1;
|
|
2365
|
+
}
|
|
2366
|
+
}
|
|
2367
|
+
function init_select(select) {
|
|
2368
|
+
var observer = new MutationObserver(() => {
|
|
2369
|
+
select_option(select, select.__value);
|
|
2370
|
+
});
|
|
2371
|
+
observer.observe(select, {
|
|
2372
|
+
// Listen to option element changes
|
|
2373
|
+
childList: true,
|
|
2374
|
+
subtree: true,
|
|
2375
|
+
// because of <optgroup>
|
|
2376
|
+
// Listen to option element value attribute changes
|
|
2377
|
+
// (doesn't get notified of select value changes,
|
|
2378
|
+
// because that property is not reflected as an attribute)
|
|
2379
|
+
attributes: true,
|
|
2380
|
+
attributeFilter: ["value"]
|
|
2381
|
+
});
|
|
2382
|
+
teardown(() => {
|
|
2383
|
+
observer.disconnect();
|
|
2384
|
+
});
|
|
2385
|
+
}
|
|
2386
|
+
function bind_select_value(select, get2, set2 = get2) {
|
|
2387
|
+
var batches = /* @__PURE__ */ new WeakSet();
|
|
2388
|
+
var mounting = true;
|
|
2389
|
+
listen_to_event_and_reset_event(select, "change", (is_reset) => {
|
|
2390
|
+
var query = is_reset ? "[selected]" : ":checked";
|
|
2391
|
+
var value;
|
|
2392
|
+
if (select.multiple) {
|
|
2393
|
+
value = [].map.call(select.querySelectorAll(query), get_option_value);
|
|
2394
|
+
} else {
|
|
2395
|
+
var selected_option = select.querySelector(query) ?? // will fall back to first non-disabled option if no option is selected
|
|
2396
|
+
select.querySelector("option:not([disabled])");
|
|
2397
|
+
value = selected_option && get_option_value(selected_option);
|
|
2398
|
+
}
|
|
2399
|
+
set2(value);
|
|
2400
|
+
select.__value = value;
|
|
2401
|
+
if (current_batch !== null) {
|
|
2402
|
+
batches.add(current_batch);
|
|
2403
|
+
}
|
|
2404
|
+
});
|
|
2405
|
+
effect(() => {
|
|
2406
|
+
var value = get2();
|
|
2407
|
+
if (select === document.activeElement) {
|
|
2408
|
+
var batch = (
|
|
2409
|
+
/** @type {Batch} */
|
|
2410
|
+
async_mode_flag ? previous_batch : current_batch
|
|
2411
|
+
);
|
|
2412
|
+
if (batches.has(batch)) {
|
|
2413
|
+
return;
|
|
2414
|
+
}
|
|
2415
|
+
}
|
|
2416
|
+
select_option(select, value, mounting);
|
|
2417
|
+
if (mounting && value === void 0) {
|
|
2418
|
+
var selected_option = select.querySelector(":checked");
|
|
2419
|
+
if (selected_option !== null) {
|
|
2420
|
+
value = get_option_value(selected_option);
|
|
2421
|
+
set2(value);
|
|
2422
|
+
}
|
|
2423
|
+
}
|
|
2424
|
+
select.__value = value;
|
|
2425
|
+
mounting = false;
|
|
2426
|
+
});
|
|
2427
|
+
init_select(select);
|
|
2428
|
+
}
|
|
2429
|
+
function get_option_value(option) {
|
|
2430
|
+
if ("__value" in option) {
|
|
2431
|
+
return option.__value;
|
|
2432
|
+
} else {
|
|
2433
|
+
return option.value;
|
|
2434
|
+
}
|
|
2435
|
+
}
|
|
2436
|
+
|
|
2437
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/elements/attributes.js
|
|
2438
|
+
var CLASS = /* @__PURE__ */ Symbol("class");
|
|
2439
|
+
var STYLE = /* @__PURE__ */ Symbol("style");
|
|
2440
|
+
var IS_CUSTOM_ELEMENT = /* @__PURE__ */ Symbol("is custom element");
|
|
2441
|
+
var IS_HTML = /* @__PURE__ */ Symbol("is html");
|
|
2442
|
+
var LINK_TAG = IS_XHTML ? "link" : "LINK";
|
|
2443
|
+
var INPUT_TAG = IS_XHTML ? "input" : "INPUT";
|
|
2444
|
+
var OPTION_TAG = IS_XHTML ? "option" : "OPTION";
|
|
2445
|
+
var SELECT_TAG = IS_XHTML ? "select" : "SELECT";
|
|
2446
|
+
var PROGRESS_TAG = IS_XHTML ? "progress" : "PROGRESS";
|
|
2447
|
+
function remove_input_defaults(input) {
|
|
2448
|
+
if (!hydrating) return;
|
|
2449
|
+
var already_removed = false;
|
|
2450
|
+
var remove_defaults = () => {
|
|
2451
|
+
if (already_removed) return;
|
|
2452
|
+
already_removed = true;
|
|
2453
|
+
if (input.hasAttribute("value")) {
|
|
2454
|
+
var value = input.value;
|
|
2455
|
+
set_attribute(input, "value", null);
|
|
2456
|
+
input.value = value;
|
|
2457
|
+
}
|
|
2458
|
+
if (input.hasAttribute("checked")) {
|
|
2459
|
+
var checked = input.checked;
|
|
2460
|
+
set_attribute(input, "checked", null);
|
|
2461
|
+
input.checked = checked;
|
|
2462
|
+
}
|
|
2463
|
+
};
|
|
2464
|
+
input.__on_r = remove_defaults;
|
|
2465
|
+
queue_micro_task(remove_defaults);
|
|
2466
|
+
add_form_reset_listener();
|
|
2467
|
+
}
|
|
2468
|
+
function set_value(element2, value) {
|
|
2469
|
+
var attributes = get_attributes(element2);
|
|
2470
|
+
if (attributes.value === (attributes.value = // treat null and undefined the same for the initial value
|
|
2471
|
+
value ?? void 0) || // @ts-expect-error
|
|
2472
|
+
// `progress` elements always need their value set when it's `0`
|
|
2473
|
+
element2.value === value && (value !== 0 || element2.nodeName !== PROGRESS_TAG)) {
|
|
2474
|
+
return;
|
|
2475
|
+
}
|
|
2476
|
+
element2.value = value ?? "";
|
|
2477
|
+
}
|
|
2478
|
+
function set_checked(element2, checked) {
|
|
2479
|
+
var attributes = get_attributes(element2);
|
|
2480
|
+
if (attributes.checked === (attributes.checked = // treat null and undefined the same for the initial value
|
|
2481
|
+
checked ?? void 0)) {
|
|
2482
|
+
return;
|
|
2483
|
+
}
|
|
2484
|
+
element2.checked = checked;
|
|
2485
|
+
}
|
|
2486
|
+
function set_selected(element2, selected) {
|
|
2487
|
+
if (selected) {
|
|
2488
|
+
if (!element2.hasAttribute("selected")) {
|
|
2489
|
+
element2.setAttribute("selected", "");
|
|
2490
|
+
}
|
|
2491
|
+
} else {
|
|
2492
|
+
element2.removeAttribute("selected");
|
|
2493
|
+
}
|
|
2494
|
+
}
|
|
2495
|
+
function set_default_checked(element2, checked) {
|
|
2496
|
+
const existing_value = element2.checked;
|
|
2497
|
+
element2.defaultChecked = checked;
|
|
2498
|
+
element2.checked = existing_value;
|
|
2499
|
+
}
|
|
2500
|
+
function set_default_value(element2, value) {
|
|
2501
|
+
const existing_value = element2.value;
|
|
2502
|
+
element2.defaultValue = value;
|
|
2503
|
+
element2.value = existing_value;
|
|
2504
|
+
}
|
|
2505
|
+
function set_attribute(element2, attribute, value, skip_warning) {
|
|
2506
|
+
var attributes = get_attributes(element2);
|
|
2507
|
+
if (hydrating) {
|
|
2508
|
+
attributes[attribute] = element2.getAttribute(attribute);
|
|
2509
|
+
if (attribute === "src" || attribute === "srcset" || attribute === "href" && element2.nodeName === LINK_TAG) {
|
|
2510
|
+
if (!skip_warning) {
|
|
2511
|
+
check_src_in_dev_hydration(element2, attribute, value ?? "");
|
|
2512
|
+
}
|
|
2513
|
+
return;
|
|
2514
|
+
}
|
|
2515
|
+
}
|
|
2516
|
+
if (attributes[attribute] === (attributes[attribute] = value)) return;
|
|
2517
|
+
if (attribute === "loading") {
|
|
2518
|
+
element2[LOADING_ATTR_SYMBOL] = value;
|
|
2519
|
+
}
|
|
2520
|
+
if (value == null) {
|
|
2521
|
+
element2.removeAttribute(attribute);
|
|
2522
|
+
} else if (typeof value !== "string" && get_setters(element2).includes(attribute)) {
|
|
2523
|
+
element2[attribute] = value;
|
|
2524
|
+
} else {
|
|
2525
|
+
element2.setAttribute(attribute, value);
|
|
2526
|
+
}
|
|
2527
|
+
}
|
|
2528
|
+
function set_xlink_attribute(dom, attribute, value) {
|
|
2529
|
+
dom.setAttributeNS("http://www.w3.org/1999/xlink", attribute, value);
|
|
2530
|
+
}
|
|
2531
|
+
function set_custom_element_data(node, prop2, value) {
|
|
2532
|
+
var previous_reaction = active_reaction;
|
|
2533
|
+
var previous_effect = active_effect;
|
|
2534
|
+
let was_hydrating = hydrating;
|
|
2535
|
+
if (hydrating) {
|
|
2536
|
+
set_hydrating(false);
|
|
2537
|
+
}
|
|
2538
|
+
set_active_reaction(null);
|
|
2539
|
+
set_active_effect(null);
|
|
2540
|
+
try {
|
|
2541
|
+
if (
|
|
2542
|
+
// `style` should use `set_attribute` rather than the setter
|
|
2543
|
+
prop2 !== "style" && // Don't compute setters for custom elements while they aren't registered yet,
|
|
2544
|
+
// because during their upgrade/instantiation they might add more setters.
|
|
2545
|
+
// Instead, fall back to a simple "an object, then set as property" heuristic.
|
|
2546
|
+
(setters_cache.has(node.getAttribute("is") || node.nodeName) || // customElements may not be available in browser extension contexts
|
|
2547
|
+
!customElements || customElements.get(node.getAttribute("is") || node.nodeName.toLowerCase()) ? get_setters(node).includes(prop2) : value && typeof value === "object")
|
|
2548
|
+
) {
|
|
2549
|
+
node[prop2] = value;
|
|
2550
|
+
} else {
|
|
2551
|
+
set_attribute(node, prop2, value == null ? value : String(value));
|
|
2552
|
+
}
|
|
2553
|
+
} finally {
|
|
2554
|
+
set_active_reaction(previous_reaction);
|
|
2555
|
+
set_active_effect(previous_effect);
|
|
2556
|
+
if (was_hydrating) {
|
|
2557
|
+
set_hydrating(true);
|
|
2558
|
+
}
|
|
2559
|
+
}
|
|
2560
|
+
}
|
|
2561
|
+
function set_attributes(element2, prev, next2, css_hash, should_remove_defaults = false, skip_warning = false) {
|
|
2562
|
+
if (hydrating && should_remove_defaults && element2.nodeName === INPUT_TAG) {
|
|
2563
|
+
var input = (
|
|
2564
|
+
/** @type {HTMLInputElement} */
|
|
2565
|
+
element2
|
|
2566
|
+
);
|
|
2567
|
+
var attribute = input.type === "checkbox" ? "defaultChecked" : "defaultValue";
|
|
2568
|
+
if (!(attribute in next2)) {
|
|
2569
|
+
remove_input_defaults(input);
|
|
2570
|
+
}
|
|
2571
|
+
}
|
|
2572
|
+
var attributes = get_attributes(element2);
|
|
2573
|
+
var is_custom_element = attributes[IS_CUSTOM_ELEMENT];
|
|
2574
|
+
var preserve_attribute_case = !attributes[IS_HTML];
|
|
2575
|
+
let is_hydrating_custom_element = hydrating && is_custom_element;
|
|
2576
|
+
if (is_hydrating_custom_element) {
|
|
2577
|
+
set_hydrating(false);
|
|
2578
|
+
}
|
|
2579
|
+
var current = prev || {};
|
|
2580
|
+
var is_option_element = element2.nodeName === OPTION_TAG;
|
|
2581
|
+
for (var key2 in prev) {
|
|
2582
|
+
if (!(key2 in next2)) {
|
|
2583
|
+
next2[key2] = null;
|
|
2584
|
+
}
|
|
2585
|
+
}
|
|
2586
|
+
if (next2.class) {
|
|
2587
|
+
next2.class = clsx2(next2.class);
|
|
2588
|
+
} else if (css_hash || next2[CLASS]) {
|
|
2589
|
+
next2.class = null;
|
|
2590
|
+
}
|
|
2591
|
+
if (next2[STYLE]) {
|
|
2592
|
+
next2.style ??= null;
|
|
2593
|
+
}
|
|
2594
|
+
var setters = get_setters(element2);
|
|
2595
|
+
for (const key3 in next2) {
|
|
2596
|
+
let value = next2[key3];
|
|
2597
|
+
if (is_option_element && key3 === "value" && value == null) {
|
|
2598
|
+
element2.value = element2.__value = "";
|
|
2599
|
+
current[key3] = value;
|
|
2600
|
+
continue;
|
|
2601
|
+
}
|
|
2602
|
+
if (key3 === "class") {
|
|
2603
|
+
var is_html = element2.namespaceURI === "http://www.w3.org/1999/xhtml";
|
|
2604
|
+
set_class(element2, is_html, value, css_hash, prev?.[CLASS], next2[CLASS]);
|
|
2605
|
+
current[key3] = value;
|
|
2606
|
+
current[CLASS] = next2[CLASS];
|
|
2607
|
+
continue;
|
|
2608
|
+
}
|
|
2609
|
+
if (key3 === "style") {
|
|
2610
|
+
set_style(element2, value, prev?.[STYLE], next2[STYLE]);
|
|
2611
|
+
current[key3] = value;
|
|
2612
|
+
current[STYLE] = next2[STYLE];
|
|
2613
|
+
continue;
|
|
2614
|
+
}
|
|
2615
|
+
var prev_value = current[key3];
|
|
2616
|
+
if (value === prev_value && !(value === void 0 && element2.hasAttribute(key3))) {
|
|
2617
|
+
continue;
|
|
2618
|
+
}
|
|
2619
|
+
current[key3] = value;
|
|
2620
|
+
var prefix = key3[0] + key3[1];
|
|
2621
|
+
if (prefix === "$$") continue;
|
|
2622
|
+
if (prefix === "on") {
|
|
2623
|
+
const opts = {};
|
|
2624
|
+
const event_handle_key = "$$" + key3;
|
|
2625
|
+
let event_name = key3.slice(2);
|
|
2626
|
+
var is_delegated = can_delegate_event(event_name);
|
|
2627
|
+
if (is_capture_event(event_name)) {
|
|
2628
|
+
event_name = event_name.slice(0, -7);
|
|
2629
|
+
opts.capture = true;
|
|
2630
|
+
}
|
|
2631
|
+
if (!is_delegated && prev_value) {
|
|
2632
|
+
if (value != null) continue;
|
|
2633
|
+
element2.removeEventListener(event_name, current[event_handle_key], opts);
|
|
2634
|
+
current[event_handle_key] = null;
|
|
2635
|
+
}
|
|
2636
|
+
if (is_delegated) {
|
|
2637
|
+
delegated(event_name, element2, value);
|
|
2638
|
+
delegate([event_name]);
|
|
2639
|
+
} else if (value != null) {
|
|
2640
|
+
let handle = function(evt) {
|
|
2641
|
+
current[key3].call(this, evt);
|
|
2642
|
+
};
|
|
2643
|
+
current[event_handle_key] = create_event(event_name, element2, handle, opts);
|
|
2644
|
+
}
|
|
2645
|
+
} else if (key3 === "style") {
|
|
2646
|
+
set_attribute(element2, key3, value);
|
|
2647
|
+
} else if (key3 === "autofocus") {
|
|
2648
|
+
autofocus(
|
|
2649
|
+
/** @type {HTMLElement} */
|
|
2650
|
+
element2,
|
|
2651
|
+
Boolean(value)
|
|
2652
|
+
);
|
|
2653
|
+
} else if (!is_custom_element && (key3 === "__value" || key3 === "value" && value != null)) {
|
|
2654
|
+
element2.value = element2.__value = value;
|
|
2655
|
+
} else if (key3 === "selected" && is_option_element) {
|
|
2656
|
+
set_selected(
|
|
2657
|
+
/** @type {HTMLOptionElement} */
|
|
2658
|
+
element2,
|
|
2659
|
+
value
|
|
2660
|
+
);
|
|
2661
|
+
} else {
|
|
2662
|
+
var name = key3;
|
|
2663
|
+
if (!preserve_attribute_case) {
|
|
2664
|
+
name = normalize_attribute(name);
|
|
2665
|
+
}
|
|
2666
|
+
var is_default = name === "defaultValue" || name === "defaultChecked";
|
|
2667
|
+
if (value == null && !is_custom_element && !is_default) {
|
|
2668
|
+
attributes[key3] = null;
|
|
2669
|
+
if (name === "value" || name === "checked") {
|
|
2670
|
+
let input2 = (
|
|
2671
|
+
/** @type {HTMLInputElement} */
|
|
2672
|
+
element2
|
|
2673
|
+
);
|
|
2674
|
+
const use_default = prev === void 0;
|
|
2675
|
+
if (name === "value") {
|
|
2676
|
+
let previous = input2.defaultValue;
|
|
2677
|
+
input2.removeAttribute(name);
|
|
2678
|
+
input2.defaultValue = previous;
|
|
2679
|
+
input2.value = input2.__value = use_default ? previous : null;
|
|
2680
|
+
} else {
|
|
2681
|
+
let previous = input2.defaultChecked;
|
|
2682
|
+
input2.removeAttribute(name);
|
|
2683
|
+
input2.defaultChecked = previous;
|
|
2684
|
+
input2.checked = use_default ? previous : false;
|
|
2685
|
+
}
|
|
2686
|
+
} else {
|
|
2687
|
+
element2.removeAttribute(key3);
|
|
2688
|
+
}
|
|
2689
|
+
} else if (is_default || setters.includes(name) && (is_custom_element || typeof value !== "string")) {
|
|
2690
|
+
element2[name] = value;
|
|
2691
|
+
if (name in attributes) attributes[name] = UNINITIALIZED;
|
|
2692
|
+
} else if (typeof value !== "function") {
|
|
2693
|
+
set_attribute(element2, name, value, skip_warning);
|
|
2694
|
+
}
|
|
2695
|
+
}
|
|
2696
|
+
}
|
|
2697
|
+
if (is_hydrating_custom_element) {
|
|
2698
|
+
set_hydrating(true);
|
|
2699
|
+
}
|
|
2700
|
+
return current;
|
|
2701
|
+
}
|
|
2702
|
+
function attribute_effect(element2, fn, sync = [], async2 = [], blockers = [], css_hash, should_remove_defaults = false, skip_warning = false) {
|
|
2703
|
+
flatten(blockers, sync, async2, (values) => {
|
|
2704
|
+
var prev = void 0;
|
|
2705
|
+
var effects = {};
|
|
2706
|
+
var is_select = element2.nodeName === SELECT_TAG;
|
|
2707
|
+
var inited = false;
|
|
2708
|
+
managed(() => {
|
|
2709
|
+
var next2 = fn(...values.map(get));
|
|
2710
|
+
var current = set_attributes(
|
|
2711
|
+
element2,
|
|
2712
|
+
prev,
|
|
2713
|
+
next2,
|
|
2714
|
+
css_hash,
|
|
2715
|
+
should_remove_defaults,
|
|
2716
|
+
skip_warning
|
|
2717
|
+
);
|
|
2718
|
+
if (inited && is_select && "value" in next2) {
|
|
2719
|
+
select_option(
|
|
2720
|
+
/** @type {HTMLSelectElement} */
|
|
2721
|
+
element2,
|
|
2722
|
+
next2.value
|
|
2723
|
+
);
|
|
2724
|
+
}
|
|
2725
|
+
for (let symbol of Object.getOwnPropertySymbols(effects)) {
|
|
2726
|
+
if (!next2[symbol]) destroy_effect(effects[symbol]);
|
|
2727
|
+
}
|
|
2728
|
+
for (let symbol of Object.getOwnPropertySymbols(next2)) {
|
|
2729
|
+
var n = next2[symbol];
|
|
2730
|
+
if (symbol.description === ATTACHMENT_KEY && (!prev || n !== prev[symbol])) {
|
|
2731
|
+
if (effects[symbol]) destroy_effect(effects[symbol]);
|
|
2732
|
+
effects[symbol] = branch(() => attach(element2, () => n));
|
|
2733
|
+
}
|
|
2734
|
+
current[symbol] = n;
|
|
2735
|
+
}
|
|
2736
|
+
prev = current;
|
|
2737
|
+
});
|
|
2738
|
+
if (is_select) {
|
|
2739
|
+
var select = (
|
|
2740
|
+
/** @type {HTMLSelectElement} */
|
|
2741
|
+
element2
|
|
2742
|
+
);
|
|
2743
|
+
effect(() => {
|
|
2744
|
+
select_option(
|
|
2745
|
+
select,
|
|
2746
|
+
/** @type {Record<string | symbol, any>} */
|
|
2747
|
+
prev.value,
|
|
2748
|
+
true
|
|
2749
|
+
);
|
|
2750
|
+
init_select(select);
|
|
2751
|
+
});
|
|
2752
|
+
}
|
|
2753
|
+
inited = true;
|
|
2754
|
+
});
|
|
2755
|
+
}
|
|
2756
|
+
function get_attributes(element2) {
|
|
2757
|
+
return (
|
|
2758
|
+
/** @type {Record<string | symbol, unknown>} **/
|
|
2759
|
+
// @ts-expect-error
|
|
2760
|
+
element2.__attributes ??= {
|
|
2761
|
+
[IS_CUSTOM_ELEMENT]: element2.nodeName.includes("-"),
|
|
2762
|
+
[IS_HTML]: element2.namespaceURI === NAMESPACE_HTML
|
|
2763
|
+
}
|
|
2764
|
+
);
|
|
2765
|
+
}
|
|
2766
|
+
var setters_cache = /* @__PURE__ */ new Map();
|
|
2767
|
+
function get_setters(element2) {
|
|
2768
|
+
var cache_key = element2.getAttribute("is") || element2.nodeName;
|
|
2769
|
+
var setters = setters_cache.get(cache_key);
|
|
2770
|
+
if (setters) return setters;
|
|
2771
|
+
setters_cache.set(cache_key, setters = []);
|
|
2772
|
+
var descriptors;
|
|
2773
|
+
var proto = element2;
|
|
2774
|
+
var element_proto = Element.prototype;
|
|
2775
|
+
while (element_proto !== proto) {
|
|
2776
|
+
descriptors = get_descriptors(proto);
|
|
2777
|
+
for (var key2 in descriptors) {
|
|
2778
|
+
if (descriptors[key2].set) {
|
|
2779
|
+
setters.push(key2);
|
|
2780
|
+
}
|
|
2781
|
+
}
|
|
2782
|
+
proto = get_prototype_of(proto);
|
|
2783
|
+
}
|
|
2784
|
+
return setters;
|
|
2785
|
+
}
|
|
2786
|
+
function check_src_in_dev_hydration(element2, attribute, value) {
|
|
2787
|
+
if (!true_default) return;
|
|
2788
|
+
if (attribute === "srcset" && srcset_url_equal(element2, value)) return;
|
|
2789
|
+
if (src_url_equal(element2.getAttribute(attribute) ?? "", value)) return;
|
|
2790
|
+
hydration_attribute_changed(
|
|
2791
|
+
attribute,
|
|
2792
|
+
element2.outerHTML.replace(element2.innerHTML, element2.innerHTML && "..."),
|
|
2793
|
+
String(value)
|
|
2794
|
+
);
|
|
2795
|
+
}
|
|
2796
|
+
function src_url_equal(element_src, url) {
|
|
2797
|
+
if (element_src === url) return true;
|
|
2798
|
+
return new URL(element_src, document.baseURI).href === new URL(url, document.baseURI).href;
|
|
2799
|
+
}
|
|
2800
|
+
function split_srcset(srcset) {
|
|
2801
|
+
return srcset.split(",").map((src) => src.trim().split(" ").filter(Boolean));
|
|
2802
|
+
}
|
|
2803
|
+
function srcset_url_equal(element2, srcset) {
|
|
2804
|
+
var element_urls = split_srcset(element2.srcset);
|
|
2805
|
+
var urls = split_srcset(srcset);
|
|
2806
|
+
return urls.length === element_urls.length && urls.every(
|
|
2807
|
+
([url, width], i) => width === element_urls[i][1] && // We need to test both ways because Vite will create an a full URL with
|
|
2808
|
+
// `new URL(asset, import.meta.url).href` for the client when `base: './'`, and the
|
|
2809
|
+
// relative URLs inside srcset are not automatically resolved to absolute URLs by
|
|
2810
|
+
// browsers (in contrast to img.src). This means both SSR and DOM code could
|
|
2811
|
+
// contain relative or absolute URLs.
|
|
2812
|
+
(src_url_equal(element_urls[i][0], url) || src_url_equal(url, element_urls[i][0]))
|
|
2813
|
+
);
|
|
2814
|
+
}
|
|
2815
|
+
|
|
2816
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/elements/customizable-select.js
|
|
2817
|
+
var supported = null;
|
|
2818
|
+
function is_supported() {
|
|
2819
|
+
if (supported === null) {
|
|
2820
|
+
var select = create_element("select");
|
|
2821
|
+
select.innerHTML = create_trusted_html("<option><span>t</span></option>");
|
|
2822
|
+
supported = /** @type {Element} */
|
|
2823
|
+
select.firstChild?.firstChild?.nodeType === 1;
|
|
2824
|
+
}
|
|
2825
|
+
return supported;
|
|
2826
|
+
}
|
|
2827
|
+
function selectedcontent(element2, update_element) {
|
|
2828
|
+
if (!is_supported()) return;
|
|
2829
|
+
attach(element2, () => () => {
|
|
2830
|
+
const select = element2.closest("select");
|
|
2831
|
+
if (!select) return;
|
|
2832
|
+
const observer = new MutationObserver((entries) => {
|
|
2833
|
+
var selected = false;
|
|
2834
|
+
for (const entry of entries) {
|
|
2835
|
+
if (entry.target === element2) {
|
|
2836
|
+
return;
|
|
2837
|
+
}
|
|
2838
|
+
selected ||= !!entry.target.parentElement?.closest("option")?.selected;
|
|
2839
|
+
}
|
|
2840
|
+
if (selected) {
|
|
2841
|
+
element2.replaceWith(element2 = /** @type {HTMLElement} */
|
|
2842
|
+
element2.cloneNode(true));
|
|
2843
|
+
update_element(element2);
|
|
2844
|
+
}
|
|
2845
|
+
});
|
|
2846
|
+
observer.observe(select, {
|
|
2847
|
+
childList: true,
|
|
2848
|
+
characterData: true,
|
|
2849
|
+
subtree: true
|
|
2850
|
+
});
|
|
2851
|
+
return () => {
|
|
2852
|
+
observer.disconnect();
|
|
2853
|
+
};
|
|
2854
|
+
});
|
|
2855
|
+
}
|
|
2856
|
+
function customizable_select(element2, rich_fn) {
|
|
2857
|
+
var was_hydrating = hydrating;
|
|
2858
|
+
if (!is_supported()) {
|
|
2859
|
+
set_hydrating(false);
|
|
2860
|
+
element2.textContent = "";
|
|
2861
|
+
element2.append(create_comment(""));
|
|
2862
|
+
}
|
|
2863
|
+
try {
|
|
2864
|
+
rich_fn();
|
|
2865
|
+
} finally {
|
|
2866
|
+
if (was_hydrating) {
|
|
2867
|
+
if (hydrating) {
|
|
2868
|
+
reset(element2);
|
|
2869
|
+
} else {
|
|
2870
|
+
set_hydrating(true);
|
|
2871
|
+
set_hydrate_node(element2);
|
|
2872
|
+
}
|
|
2873
|
+
}
|
|
2874
|
+
}
|
|
2875
|
+
}
|
|
2876
|
+
|
|
2877
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/elements/bindings/document.js
|
|
2878
|
+
function bind_active_element(update2) {
|
|
2879
|
+
listen(document, ["focusin", "focusout"], (event2) => {
|
|
2880
|
+
if (event2 && event2.type === "focusout" && /** @type {FocusEvent} */
|
|
2881
|
+
event2.relatedTarget) {
|
|
2882
|
+
return;
|
|
2883
|
+
}
|
|
2884
|
+
update2(document.activeElement);
|
|
2885
|
+
});
|
|
2886
|
+
}
|
|
2887
|
+
|
|
2888
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/elements/bindings/input.js
|
|
2889
|
+
function bind_value(input, get2, set2 = get2) {
|
|
2890
|
+
var batches = /* @__PURE__ */ new WeakSet();
|
|
2891
|
+
listen_to_event_and_reset_event(input, "input", async (is_reset) => {
|
|
2892
|
+
if (true_default && input.type === "checkbox") {
|
|
2893
|
+
bind_invalid_checkbox_value();
|
|
2894
|
+
}
|
|
2895
|
+
var value = is_reset ? input.defaultValue : input.value;
|
|
2896
|
+
value = is_numberlike_input(input) ? to_number(value) : value;
|
|
2897
|
+
set2(value);
|
|
2898
|
+
if (current_batch !== null) {
|
|
2899
|
+
batches.add(current_batch);
|
|
2900
|
+
}
|
|
2901
|
+
await tick();
|
|
2902
|
+
if (value !== (value = get2())) {
|
|
2903
|
+
var start = input.selectionStart;
|
|
2904
|
+
var end = input.selectionEnd;
|
|
2905
|
+
var length = input.value.length;
|
|
2906
|
+
input.value = value ?? "";
|
|
2907
|
+
if (end !== null) {
|
|
2908
|
+
var new_length = input.value.length;
|
|
2909
|
+
if (start === end && end === length && new_length > length) {
|
|
2910
|
+
input.selectionStart = new_length;
|
|
2911
|
+
input.selectionEnd = new_length;
|
|
2912
|
+
} else {
|
|
2913
|
+
input.selectionStart = start;
|
|
2914
|
+
input.selectionEnd = Math.min(end, new_length);
|
|
2915
|
+
}
|
|
2916
|
+
}
|
|
2917
|
+
}
|
|
2918
|
+
});
|
|
2919
|
+
if (
|
|
2920
|
+
// If we are hydrating and the value has since changed,
|
|
2921
|
+
// then use the updated value from the input instead.
|
|
2922
|
+
hydrating && input.defaultValue !== input.value || // If defaultValue is set, then value == defaultValue
|
|
2923
|
+
// TODO Svelte 6: remove input.value check and set to empty string?
|
|
2924
|
+
untrack(get2) == null && input.value
|
|
2925
|
+
) {
|
|
2926
|
+
set2(is_numberlike_input(input) ? to_number(input.value) : input.value);
|
|
2927
|
+
if (current_batch !== null) {
|
|
2928
|
+
batches.add(current_batch);
|
|
2929
|
+
}
|
|
2930
|
+
}
|
|
2931
|
+
render_effect(() => {
|
|
2932
|
+
if (true_default && input.type === "checkbox") {
|
|
2933
|
+
bind_invalid_checkbox_value();
|
|
2934
|
+
}
|
|
2935
|
+
var value = get2();
|
|
2936
|
+
if (input === document.activeElement) {
|
|
2937
|
+
var batch = (
|
|
2938
|
+
/** @type {Batch} */
|
|
2939
|
+
async_mode_flag ? previous_batch : current_batch
|
|
2940
|
+
);
|
|
2941
|
+
if (batches.has(batch)) {
|
|
2942
|
+
return;
|
|
2943
|
+
}
|
|
2944
|
+
}
|
|
2945
|
+
if (is_numberlike_input(input) && value === to_number(input.value)) {
|
|
2946
|
+
return;
|
|
2947
|
+
}
|
|
2948
|
+
if (input.type === "date" && !value && !input.value) {
|
|
2949
|
+
return;
|
|
2950
|
+
}
|
|
2951
|
+
if (value !== input.value) {
|
|
2952
|
+
input.value = value ?? "";
|
|
2953
|
+
}
|
|
2954
|
+
});
|
|
2955
|
+
}
|
|
2956
|
+
var pending = /* @__PURE__ */ new Set();
|
|
2957
|
+
function bind_group(inputs, group_index, input, get2, set2 = get2) {
|
|
2958
|
+
var is_checkbox = input.getAttribute("type") === "checkbox";
|
|
2959
|
+
var binding_group = inputs;
|
|
2960
|
+
let hydration_mismatch2 = false;
|
|
2961
|
+
if (group_index !== null) {
|
|
2962
|
+
for (var index2 of group_index) {
|
|
2963
|
+
binding_group = binding_group[index2] ??= [];
|
|
2964
|
+
}
|
|
2965
|
+
}
|
|
2966
|
+
binding_group.push(input);
|
|
2967
|
+
listen_to_event_and_reset_event(
|
|
2968
|
+
input,
|
|
2969
|
+
"change",
|
|
2970
|
+
() => {
|
|
2971
|
+
var value = input.__value;
|
|
2972
|
+
if (is_checkbox) {
|
|
2973
|
+
value = get_binding_group_value(binding_group, value, input.checked);
|
|
2974
|
+
}
|
|
2975
|
+
set2(value);
|
|
2976
|
+
},
|
|
2977
|
+
// TODO better default value handling
|
|
2978
|
+
() => set2(is_checkbox ? [] : null)
|
|
2979
|
+
);
|
|
2980
|
+
render_effect(() => {
|
|
2981
|
+
var value = get2();
|
|
2982
|
+
if (hydrating && input.defaultChecked !== input.checked) {
|
|
2983
|
+
hydration_mismatch2 = true;
|
|
2984
|
+
return;
|
|
2985
|
+
}
|
|
2986
|
+
if (is_checkbox) {
|
|
2987
|
+
value = value || [];
|
|
2988
|
+
input.checked = value.includes(input.__value);
|
|
2989
|
+
} else {
|
|
2990
|
+
input.checked = is(input.__value, value);
|
|
2991
|
+
}
|
|
2992
|
+
});
|
|
2993
|
+
teardown(() => {
|
|
2994
|
+
var index3 = binding_group.indexOf(input);
|
|
2995
|
+
if (index3 !== -1) {
|
|
2996
|
+
binding_group.splice(index3, 1);
|
|
2997
|
+
}
|
|
2998
|
+
});
|
|
2999
|
+
if (!pending.has(binding_group)) {
|
|
3000
|
+
pending.add(binding_group);
|
|
3001
|
+
queue_micro_task(() => {
|
|
3002
|
+
binding_group.sort((a, b) => a.compareDocumentPosition(b) === 4 ? -1 : 1);
|
|
3003
|
+
pending.delete(binding_group);
|
|
3004
|
+
});
|
|
3005
|
+
}
|
|
3006
|
+
queue_micro_task(() => {
|
|
3007
|
+
if (hydration_mismatch2) {
|
|
3008
|
+
var value;
|
|
3009
|
+
if (is_checkbox) {
|
|
3010
|
+
value = get_binding_group_value(binding_group, value, input.checked);
|
|
3011
|
+
} else {
|
|
3012
|
+
var hydration_input = binding_group.find((input2) => input2.checked);
|
|
3013
|
+
value = hydration_input?.__value;
|
|
3014
|
+
}
|
|
3015
|
+
set2(value);
|
|
3016
|
+
}
|
|
3017
|
+
});
|
|
3018
|
+
}
|
|
3019
|
+
function bind_checked(input, get2, set2 = get2) {
|
|
3020
|
+
listen_to_event_and_reset_event(input, "change", (is_reset) => {
|
|
3021
|
+
var value = is_reset ? input.defaultChecked : input.checked;
|
|
3022
|
+
set2(value);
|
|
3023
|
+
});
|
|
3024
|
+
if (
|
|
3025
|
+
// If we are hydrating and the value has since changed,
|
|
3026
|
+
// then use the update value from the input instead.
|
|
3027
|
+
hydrating && input.defaultChecked !== input.checked || // If defaultChecked is set, then checked == defaultChecked
|
|
3028
|
+
untrack(get2) == null
|
|
3029
|
+
) {
|
|
3030
|
+
set2(input.checked);
|
|
3031
|
+
}
|
|
3032
|
+
render_effect(() => {
|
|
3033
|
+
var value = get2();
|
|
3034
|
+
input.checked = Boolean(value);
|
|
3035
|
+
});
|
|
3036
|
+
}
|
|
3037
|
+
function get_binding_group_value(group, __value, checked) {
|
|
3038
|
+
var value = /* @__PURE__ */ new Set();
|
|
3039
|
+
for (var i = 0; i < group.length; i += 1) {
|
|
3040
|
+
if (group[i].checked) {
|
|
3041
|
+
value.add(group[i].__value);
|
|
3042
|
+
}
|
|
3043
|
+
}
|
|
3044
|
+
if (!checked) {
|
|
3045
|
+
value.delete(__value);
|
|
3046
|
+
}
|
|
3047
|
+
return Array.from(value);
|
|
3048
|
+
}
|
|
3049
|
+
function is_numberlike_input(input) {
|
|
3050
|
+
var type = input.type;
|
|
3051
|
+
return type === "number" || type === "range";
|
|
3052
|
+
}
|
|
3053
|
+
function to_number(value) {
|
|
3054
|
+
return value === "" ? null : +value;
|
|
3055
|
+
}
|
|
3056
|
+
function bind_files(input, get2, set2 = get2) {
|
|
3057
|
+
listen_to_event_and_reset_event(input, "change", () => {
|
|
3058
|
+
set2(input.files);
|
|
3059
|
+
});
|
|
3060
|
+
if (
|
|
3061
|
+
// If we are hydrating and the value has since changed,
|
|
3062
|
+
// then use the updated value from the input instead.
|
|
3063
|
+
hydrating && input.files
|
|
3064
|
+
) {
|
|
3065
|
+
set2(input.files);
|
|
3066
|
+
}
|
|
3067
|
+
render_effect(() => {
|
|
3068
|
+
input.files = get2();
|
|
3069
|
+
});
|
|
3070
|
+
}
|
|
3071
|
+
|
|
3072
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/elements/bindings/media.js
|
|
3073
|
+
function time_ranges_to_array(ranges) {
|
|
3074
|
+
var array = [];
|
|
3075
|
+
for (var i = 0; i < ranges.length; i += 1) {
|
|
3076
|
+
array.push({ start: ranges.start(i), end: ranges.end(i) });
|
|
3077
|
+
}
|
|
3078
|
+
return array;
|
|
3079
|
+
}
|
|
3080
|
+
function bind_current_time(media, get2, set2 = get2) {
|
|
3081
|
+
var raf_id;
|
|
3082
|
+
var value;
|
|
3083
|
+
var callback = () => {
|
|
3084
|
+
cancelAnimationFrame(raf_id);
|
|
3085
|
+
if (!media.paused) {
|
|
3086
|
+
raf_id = requestAnimationFrame(callback);
|
|
3087
|
+
}
|
|
3088
|
+
var next_value = media.currentTime;
|
|
3089
|
+
if (value !== next_value) {
|
|
3090
|
+
set2(value = next_value);
|
|
3091
|
+
}
|
|
3092
|
+
};
|
|
3093
|
+
raf_id = requestAnimationFrame(callback);
|
|
3094
|
+
media.addEventListener("timeupdate", callback);
|
|
3095
|
+
render_effect(() => {
|
|
3096
|
+
var next_value = Number(get2());
|
|
3097
|
+
if (value !== next_value && !isNaN(
|
|
3098
|
+
/** @type {any} */
|
|
3099
|
+
next_value
|
|
3100
|
+
)) {
|
|
3101
|
+
media.currentTime = value = next_value;
|
|
3102
|
+
}
|
|
3103
|
+
});
|
|
3104
|
+
teardown(() => {
|
|
3105
|
+
cancelAnimationFrame(raf_id);
|
|
3106
|
+
media.removeEventListener("timeupdate", callback);
|
|
3107
|
+
});
|
|
3108
|
+
}
|
|
3109
|
+
function bind_buffered(media, set2) {
|
|
3110
|
+
var current;
|
|
3111
|
+
listen(media, ["loadedmetadata", "progress", "timeupdate", "seeking"], () => {
|
|
3112
|
+
var ranges = media.buffered;
|
|
3113
|
+
if (!current || current.length !== ranges.length || current.some((range, i) => ranges.start(i) !== range.start || ranges.end(i) !== range.end)) {
|
|
3114
|
+
current = time_ranges_to_array(ranges);
|
|
3115
|
+
set2(current);
|
|
3116
|
+
}
|
|
3117
|
+
});
|
|
3118
|
+
}
|
|
3119
|
+
function bind_seekable(media, set2) {
|
|
3120
|
+
listen(media, ["loadedmetadata"], () => set2(time_ranges_to_array(media.seekable)));
|
|
3121
|
+
}
|
|
3122
|
+
function bind_played(media, set2) {
|
|
3123
|
+
listen(media, ["timeupdate"], () => set2(time_ranges_to_array(media.played)));
|
|
3124
|
+
}
|
|
3125
|
+
function bind_seeking(media, set2) {
|
|
3126
|
+
listen(media, ["seeking", "seeked"], () => set2(media.seeking));
|
|
3127
|
+
}
|
|
3128
|
+
function bind_ended(media, set2) {
|
|
3129
|
+
listen(media, ["timeupdate", "ended"], () => set2(media.ended));
|
|
3130
|
+
}
|
|
3131
|
+
function bind_ready_state(media, set2) {
|
|
3132
|
+
listen(
|
|
3133
|
+
media,
|
|
3134
|
+
["loadedmetadata", "loadeddata", "canplay", "canplaythrough", "playing", "waiting", "emptied"],
|
|
3135
|
+
() => set2(media.readyState)
|
|
3136
|
+
);
|
|
3137
|
+
}
|
|
3138
|
+
function bind_playback_rate(media, get2, set2 = get2) {
|
|
3139
|
+
effect(() => {
|
|
3140
|
+
var value = Number(get2());
|
|
3141
|
+
if (value !== media.playbackRate && !isNaN(value)) {
|
|
3142
|
+
media.playbackRate = value;
|
|
3143
|
+
}
|
|
3144
|
+
});
|
|
3145
|
+
effect(() => {
|
|
3146
|
+
listen(media, ["ratechange"], () => {
|
|
3147
|
+
set2(media.playbackRate);
|
|
3148
|
+
});
|
|
3149
|
+
});
|
|
3150
|
+
}
|
|
3151
|
+
function bind_paused(media, get2, set2 = get2) {
|
|
3152
|
+
var paused = get2();
|
|
3153
|
+
var update2 = () => {
|
|
3154
|
+
if (paused !== media.paused) {
|
|
3155
|
+
set2(paused = media.paused);
|
|
3156
|
+
}
|
|
3157
|
+
};
|
|
3158
|
+
listen(media, ["play", "pause", "canplay"], update2, paused == null);
|
|
3159
|
+
effect(() => {
|
|
3160
|
+
if ((paused = !!get2()) !== media.paused) {
|
|
3161
|
+
if (paused) {
|
|
3162
|
+
media.pause();
|
|
3163
|
+
} else {
|
|
3164
|
+
media.play().catch((error) => {
|
|
3165
|
+
set2(paused = true);
|
|
3166
|
+
throw error;
|
|
3167
|
+
});
|
|
3168
|
+
}
|
|
3169
|
+
}
|
|
3170
|
+
});
|
|
3171
|
+
}
|
|
3172
|
+
function bind_volume(media, get2, set2 = get2) {
|
|
3173
|
+
var callback = () => {
|
|
3174
|
+
set2(media.volume);
|
|
3175
|
+
};
|
|
3176
|
+
if (get2() == null) {
|
|
3177
|
+
callback();
|
|
3178
|
+
}
|
|
3179
|
+
listen(media, ["volumechange"], callback, false);
|
|
3180
|
+
render_effect(() => {
|
|
3181
|
+
var value = Number(get2());
|
|
3182
|
+
if (value !== media.volume && !isNaN(value)) {
|
|
3183
|
+
media.volume = value;
|
|
3184
|
+
}
|
|
3185
|
+
});
|
|
3186
|
+
}
|
|
3187
|
+
function bind_muted(media, get2, set2 = get2) {
|
|
3188
|
+
var callback = () => {
|
|
3189
|
+
set2(media.muted);
|
|
3190
|
+
};
|
|
3191
|
+
if (get2() == null) {
|
|
3192
|
+
callback();
|
|
3193
|
+
}
|
|
3194
|
+
listen(media, ["volumechange"], callback, false);
|
|
3195
|
+
render_effect(() => {
|
|
3196
|
+
var value = !!get2();
|
|
3197
|
+
if (media.muted !== value) media.muted = value;
|
|
3198
|
+
});
|
|
3199
|
+
}
|
|
3200
|
+
|
|
3201
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/elements/bindings/navigator.js
|
|
3202
|
+
function bind_online(update2) {
|
|
3203
|
+
listen(window, ["online", "offline"], () => {
|
|
3204
|
+
update2(navigator.onLine);
|
|
3205
|
+
});
|
|
3206
|
+
}
|
|
3207
|
+
|
|
3208
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/elements/bindings/props.js
|
|
3209
|
+
function bind_prop(props, prop2, value) {
|
|
3210
|
+
var desc = get_descriptor(props, prop2);
|
|
3211
|
+
if (desc && desc.set) {
|
|
3212
|
+
props[prop2] = value;
|
|
3213
|
+
teardown(() => {
|
|
3214
|
+
props[prop2] = null;
|
|
3215
|
+
});
|
|
3216
|
+
}
|
|
3217
|
+
}
|
|
3218
|
+
|
|
3219
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/elements/bindings/size.js
|
|
3220
|
+
var ResizeObserverSingleton = class _ResizeObserverSingleton {
|
|
3221
|
+
/** */
|
|
3222
|
+
#listeners = /* @__PURE__ */ new WeakMap();
|
|
3223
|
+
/** @type {ResizeObserver | undefined} */
|
|
3224
|
+
#observer;
|
|
3225
|
+
/** @type {ResizeObserverOptions} */
|
|
3226
|
+
#options;
|
|
3227
|
+
/** @static */
|
|
3228
|
+
static entries = /* @__PURE__ */ new WeakMap();
|
|
3229
|
+
/** @param {ResizeObserverOptions} options */
|
|
3230
|
+
constructor(options) {
|
|
3231
|
+
this.#options = options;
|
|
3232
|
+
}
|
|
3233
|
+
/**
|
|
3234
|
+
* @param {Element} element
|
|
3235
|
+
* @param {(entry: ResizeObserverEntry) => any} listener
|
|
3236
|
+
*/
|
|
3237
|
+
observe(element2, listener) {
|
|
3238
|
+
var listeners = this.#listeners.get(element2) || /* @__PURE__ */ new Set();
|
|
3239
|
+
listeners.add(listener);
|
|
3240
|
+
this.#listeners.set(element2, listeners);
|
|
3241
|
+
this.#getObserver().observe(element2, this.#options);
|
|
3242
|
+
return () => {
|
|
3243
|
+
var listeners2 = this.#listeners.get(element2);
|
|
3244
|
+
listeners2.delete(listener);
|
|
3245
|
+
if (listeners2.size === 0) {
|
|
3246
|
+
this.#listeners.delete(element2);
|
|
3247
|
+
this.#observer.unobserve(element2);
|
|
3248
|
+
}
|
|
3249
|
+
};
|
|
3250
|
+
}
|
|
3251
|
+
#getObserver() {
|
|
3252
|
+
return this.#observer ?? (this.#observer = new ResizeObserver(
|
|
3253
|
+
/** @param {any} entries */
|
|
3254
|
+
(entries) => {
|
|
3255
|
+
for (var entry of entries) {
|
|
3256
|
+
_ResizeObserverSingleton.entries.set(entry.target, entry);
|
|
3257
|
+
for (var listener of this.#listeners.get(entry.target) || []) {
|
|
3258
|
+
listener(entry);
|
|
3259
|
+
}
|
|
3260
|
+
}
|
|
3261
|
+
}
|
|
3262
|
+
));
|
|
3263
|
+
}
|
|
3264
|
+
};
|
|
3265
|
+
var resize_observer_content_box = new ResizeObserverSingleton({
|
|
3266
|
+
box: "content-box"
|
|
3267
|
+
});
|
|
3268
|
+
var resize_observer_border_box = new ResizeObserverSingleton({
|
|
3269
|
+
box: "border-box"
|
|
3270
|
+
});
|
|
3271
|
+
var resize_observer_device_pixel_content_box = new ResizeObserverSingleton({
|
|
3272
|
+
box: "device-pixel-content-box"
|
|
3273
|
+
});
|
|
3274
|
+
function bind_resize_observer(element2, type, set2) {
|
|
3275
|
+
var observer = type === "contentRect" || type === "contentBoxSize" ? resize_observer_content_box : type === "borderBoxSize" ? resize_observer_border_box : resize_observer_device_pixel_content_box;
|
|
3276
|
+
var unsub = observer.observe(
|
|
3277
|
+
element2,
|
|
3278
|
+
/** @param {any} entry */
|
|
3279
|
+
(entry) => set2(entry[type])
|
|
3280
|
+
);
|
|
3281
|
+
teardown(unsub);
|
|
3282
|
+
}
|
|
3283
|
+
function bind_element_size(element2, type, set2) {
|
|
3284
|
+
var unsub = resize_observer_border_box.observe(element2, () => set2(element2[type]));
|
|
3285
|
+
effect(() => {
|
|
3286
|
+
untrack(() => set2(element2[type]));
|
|
3287
|
+
return unsub;
|
|
3288
|
+
});
|
|
3289
|
+
}
|
|
3290
|
+
|
|
3291
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/elements/bindings/this.js
|
|
3292
|
+
function is_bound_this(bound_value, element_or_component) {
|
|
3293
|
+
return bound_value === element_or_component || bound_value?.[STATE_SYMBOL] === element_or_component;
|
|
3294
|
+
}
|
|
3295
|
+
function bind_this(element_or_component = {}, update2, get_value, get_parts) {
|
|
3296
|
+
var component_effect = (
|
|
3297
|
+
/** @type {ComponentContext} */
|
|
3298
|
+
component_context.r
|
|
3299
|
+
);
|
|
3300
|
+
var parent = (
|
|
3301
|
+
/** @type {Effect} */
|
|
3302
|
+
active_effect
|
|
3303
|
+
);
|
|
3304
|
+
effect(() => {
|
|
3305
|
+
var old_parts;
|
|
3306
|
+
var parts;
|
|
3307
|
+
render_effect(() => {
|
|
3308
|
+
old_parts = parts;
|
|
3309
|
+
parts = get_parts?.() || [];
|
|
3310
|
+
untrack(() => {
|
|
3311
|
+
if (element_or_component !== get_value(...parts)) {
|
|
3312
|
+
update2(element_or_component, ...parts);
|
|
3313
|
+
if (old_parts && is_bound_this(get_value(...old_parts), element_or_component)) {
|
|
3314
|
+
update2(null, ...old_parts);
|
|
3315
|
+
}
|
|
3316
|
+
}
|
|
3317
|
+
});
|
|
3318
|
+
});
|
|
3319
|
+
return () => {
|
|
3320
|
+
let p = parent;
|
|
3321
|
+
while (p !== component_effect && p.parent !== null && p.parent.f & DESTROYING) {
|
|
3322
|
+
p = p.parent;
|
|
3323
|
+
}
|
|
3324
|
+
const teardown2 = () => {
|
|
3325
|
+
if (parts && is_bound_this(get_value(...parts), element_or_component)) {
|
|
3326
|
+
update2(null, ...parts);
|
|
3327
|
+
}
|
|
3328
|
+
};
|
|
3329
|
+
const original_teardown = p.teardown;
|
|
3330
|
+
p.teardown = () => {
|
|
3331
|
+
teardown2();
|
|
3332
|
+
original_teardown?.();
|
|
3333
|
+
};
|
|
3334
|
+
};
|
|
3335
|
+
});
|
|
3336
|
+
return element_or_component;
|
|
3337
|
+
}
|
|
3338
|
+
|
|
3339
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/elements/bindings/universal.js
|
|
3340
|
+
function bind_content_editable(property, element2, get2, set2 = get2) {
|
|
3341
|
+
element2.addEventListener("input", () => {
|
|
3342
|
+
set2(element2[property]);
|
|
3343
|
+
});
|
|
3344
|
+
render_effect(() => {
|
|
3345
|
+
var value = get2();
|
|
3346
|
+
if (element2[property] !== value) {
|
|
3347
|
+
if (value == null) {
|
|
3348
|
+
var non_null_value = element2[property];
|
|
3349
|
+
set2(non_null_value);
|
|
3350
|
+
} else {
|
|
3351
|
+
element2[property] = value + "";
|
|
3352
|
+
}
|
|
3353
|
+
}
|
|
3354
|
+
});
|
|
3355
|
+
}
|
|
3356
|
+
function bind_property(property, event_name, element2, set2, get2) {
|
|
3357
|
+
var handler = () => {
|
|
3358
|
+
set2(element2[property]);
|
|
3359
|
+
};
|
|
3360
|
+
element2.addEventListener(event_name, handler);
|
|
3361
|
+
if (get2) {
|
|
3362
|
+
render_effect(() => {
|
|
3363
|
+
element2[property] = get2();
|
|
3364
|
+
});
|
|
3365
|
+
} else {
|
|
3366
|
+
handler();
|
|
3367
|
+
}
|
|
3368
|
+
if (element2 === document.body || element2 === window || element2 === document) {
|
|
3369
|
+
teardown(() => {
|
|
3370
|
+
element2.removeEventListener(event_name, handler);
|
|
3371
|
+
});
|
|
3372
|
+
}
|
|
3373
|
+
}
|
|
3374
|
+
function bind_focused(element2, set2) {
|
|
3375
|
+
listen(element2, ["focus", "blur"], () => {
|
|
3376
|
+
set2(element2 === document.activeElement);
|
|
3377
|
+
});
|
|
3378
|
+
}
|
|
3379
|
+
|
|
3380
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/elements/bindings/window.js
|
|
3381
|
+
function bind_window_scroll(type, get2, set2 = get2) {
|
|
3382
|
+
var is_scrolling_x = type === "x";
|
|
3383
|
+
var target_handler = () => without_reactive_context(() => {
|
|
3384
|
+
scrolling = true;
|
|
3385
|
+
clearTimeout(timeout);
|
|
3386
|
+
timeout = setTimeout(clear, 100);
|
|
3387
|
+
set2(window[is_scrolling_x ? "scrollX" : "scrollY"]);
|
|
3388
|
+
});
|
|
3389
|
+
addEventListener("scroll", target_handler, {
|
|
3390
|
+
passive: true
|
|
3391
|
+
});
|
|
3392
|
+
var scrolling = false;
|
|
3393
|
+
var timeout;
|
|
3394
|
+
var clear = () => {
|
|
3395
|
+
scrolling = false;
|
|
3396
|
+
};
|
|
3397
|
+
var first = true;
|
|
3398
|
+
render_effect(() => {
|
|
3399
|
+
var latest_value = get2();
|
|
3400
|
+
if (first) {
|
|
3401
|
+
first = false;
|
|
3402
|
+
} else if (!scrolling && latest_value != null) {
|
|
3403
|
+
scrolling = true;
|
|
3404
|
+
clearTimeout(timeout);
|
|
3405
|
+
if (is_scrolling_x) {
|
|
3406
|
+
scrollTo(latest_value, window.scrollY);
|
|
3407
|
+
} else {
|
|
3408
|
+
scrollTo(window.scrollX, latest_value);
|
|
3409
|
+
}
|
|
3410
|
+
timeout = setTimeout(clear, 100);
|
|
3411
|
+
}
|
|
3412
|
+
});
|
|
3413
|
+
effect(target_handler);
|
|
3414
|
+
teardown(() => {
|
|
3415
|
+
removeEventListener("scroll", target_handler);
|
|
3416
|
+
});
|
|
3417
|
+
}
|
|
3418
|
+
function bind_window_size(type, set2) {
|
|
3419
|
+
listen(window, ["resize"], () => without_reactive_context(() => set2(window[type])));
|
|
3420
|
+
}
|
|
3421
|
+
|
|
3422
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/legacy/lifecycle.js
|
|
3423
|
+
function init(immutable = false) {
|
|
3424
|
+
const context = (
|
|
3425
|
+
/** @type {ComponentContextLegacy} */
|
|
3426
|
+
component_context
|
|
3427
|
+
);
|
|
3428
|
+
const callbacks = context.l.u;
|
|
3429
|
+
if (!callbacks) return;
|
|
3430
|
+
let props = () => deep_read_state(context.s);
|
|
3431
|
+
if (immutable) {
|
|
3432
|
+
let version = 0;
|
|
3433
|
+
let prev = (
|
|
3434
|
+
/** @type {Record<string, any>} */
|
|
3435
|
+
{}
|
|
3436
|
+
);
|
|
3437
|
+
const d = derived(() => {
|
|
3438
|
+
let changed = false;
|
|
3439
|
+
const props2 = context.s;
|
|
3440
|
+
for (const key2 in props2) {
|
|
3441
|
+
if (props2[key2] !== prev[key2]) {
|
|
3442
|
+
prev[key2] = props2[key2];
|
|
3443
|
+
changed = true;
|
|
3444
|
+
}
|
|
3445
|
+
}
|
|
3446
|
+
if (changed) version++;
|
|
3447
|
+
return version;
|
|
3448
|
+
});
|
|
3449
|
+
props = () => get(d);
|
|
3450
|
+
}
|
|
3451
|
+
if (callbacks.b.length) {
|
|
3452
|
+
user_pre_effect(() => {
|
|
3453
|
+
observe_all(context, props);
|
|
3454
|
+
run_all(callbacks.b);
|
|
3455
|
+
});
|
|
3456
|
+
}
|
|
3457
|
+
user_effect(() => {
|
|
3458
|
+
const fns = untrack(() => callbacks.m.map(run));
|
|
3459
|
+
return () => {
|
|
3460
|
+
for (const fn of fns) {
|
|
3461
|
+
if (typeof fn === "function") {
|
|
3462
|
+
fn();
|
|
3463
|
+
}
|
|
3464
|
+
}
|
|
3465
|
+
};
|
|
3466
|
+
});
|
|
3467
|
+
if (callbacks.a.length) {
|
|
3468
|
+
user_effect(() => {
|
|
3469
|
+
observe_all(context, props);
|
|
3470
|
+
run_all(callbacks.a);
|
|
3471
|
+
});
|
|
3472
|
+
}
|
|
3473
|
+
}
|
|
3474
|
+
function observe_all(context, props) {
|
|
3475
|
+
if (context.l.s) {
|
|
3476
|
+
for (const signal of context.l.s) get(signal);
|
|
3477
|
+
}
|
|
3478
|
+
props();
|
|
3479
|
+
}
|
|
3480
|
+
|
|
3481
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/legacy/misc.js
|
|
3482
|
+
function reactive_import(fn) {
|
|
3483
|
+
var s = source(0);
|
|
3484
|
+
return function() {
|
|
3485
|
+
if (arguments.length === 1) {
|
|
3486
|
+
set(s, get(s) + 1);
|
|
3487
|
+
return arguments[0];
|
|
3488
|
+
} else {
|
|
3489
|
+
get(s);
|
|
3490
|
+
return fn();
|
|
3491
|
+
}
|
|
3492
|
+
};
|
|
3493
|
+
}
|
|
3494
|
+
function bubble_event($$props, event2) {
|
|
3495
|
+
var events = (
|
|
3496
|
+
/** @type {Record<string, Function[] | Function>} */
|
|
3497
|
+
$$props.$$events?.[event2.type]
|
|
3498
|
+
);
|
|
3499
|
+
var callbacks = is_array(events) ? events.slice() : events == null ? [] : [events];
|
|
3500
|
+
for (var fn of callbacks) {
|
|
3501
|
+
fn.call(this, event2);
|
|
3502
|
+
}
|
|
3503
|
+
}
|
|
3504
|
+
function add_legacy_event_listener($$props, event_name, event_callback) {
|
|
3505
|
+
$$props.$$events ||= {};
|
|
3506
|
+
$$props.$$events[event_name] ||= [];
|
|
3507
|
+
$$props.$$events[event_name].push(event_callback);
|
|
3508
|
+
}
|
|
3509
|
+
function update_legacy_props($$new_props) {
|
|
3510
|
+
for (var key2 in $$new_props) {
|
|
3511
|
+
if (key2 in this) {
|
|
3512
|
+
this[key2] = $$new_props[key2];
|
|
3513
|
+
}
|
|
3514
|
+
}
|
|
3515
|
+
}
|
|
3516
|
+
|
|
3517
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/reactivity/props.js
|
|
3518
|
+
function update_prop(fn, d = 1) {
|
|
3519
|
+
const value = fn();
|
|
3520
|
+
fn(value + d);
|
|
3521
|
+
return value;
|
|
3522
|
+
}
|
|
3523
|
+
function update_pre_prop(fn, d = 1) {
|
|
3524
|
+
const value = fn() + d;
|
|
3525
|
+
fn(value);
|
|
3526
|
+
return value;
|
|
3527
|
+
}
|
|
3528
|
+
var rest_props_handler = {
|
|
3529
|
+
get(target, key2) {
|
|
3530
|
+
if (target.exclude.includes(key2)) return;
|
|
3531
|
+
return target.props[key2];
|
|
3532
|
+
},
|
|
3533
|
+
set(target, key2) {
|
|
3534
|
+
if (true_default) {
|
|
3535
|
+
props_rest_readonly(`${target.name}.${String(key2)}`);
|
|
3536
|
+
}
|
|
3537
|
+
return false;
|
|
3538
|
+
},
|
|
3539
|
+
getOwnPropertyDescriptor(target, key2) {
|
|
3540
|
+
if (target.exclude.includes(key2)) return;
|
|
3541
|
+
if (key2 in target.props) {
|
|
3542
|
+
return {
|
|
3543
|
+
enumerable: true,
|
|
3544
|
+
configurable: true,
|
|
3545
|
+
value: target.props[key2]
|
|
3546
|
+
};
|
|
3547
|
+
}
|
|
3548
|
+
},
|
|
3549
|
+
has(target, key2) {
|
|
3550
|
+
if (target.exclude.includes(key2)) return false;
|
|
3551
|
+
return key2 in target.props;
|
|
3552
|
+
},
|
|
3553
|
+
ownKeys(target) {
|
|
3554
|
+
return Reflect.ownKeys(target.props).filter((key2) => !target.exclude.includes(key2));
|
|
3555
|
+
}
|
|
3556
|
+
};
|
|
3557
|
+
function rest_props(props, exclude, name) {
|
|
3558
|
+
return new Proxy(
|
|
3559
|
+
true_default ? { props, exclude, name, other: {}, to_proxy: [] } : { props, exclude },
|
|
3560
|
+
rest_props_handler
|
|
3561
|
+
);
|
|
3562
|
+
}
|
|
3563
|
+
var legacy_rest_props_handler = {
|
|
3564
|
+
get(target, key2) {
|
|
3565
|
+
if (target.exclude.includes(key2)) return;
|
|
3566
|
+
get(target.version);
|
|
3567
|
+
return key2 in target.special ? target.special[key2]() : target.props[key2];
|
|
3568
|
+
},
|
|
3569
|
+
set(target, key2, value) {
|
|
3570
|
+
if (!(key2 in target.special)) {
|
|
3571
|
+
var previous_effect = active_effect;
|
|
3572
|
+
try {
|
|
3573
|
+
set_active_effect(target.parent_effect);
|
|
3574
|
+
target.special[key2] = prop(
|
|
3575
|
+
{
|
|
3576
|
+
get [key2]() {
|
|
3577
|
+
return target.props[key2];
|
|
3578
|
+
}
|
|
3579
|
+
},
|
|
3580
|
+
/** @type {string} */
|
|
3581
|
+
key2,
|
|
3582
|
+
PROPS_IS_UPDATED
|
|
3583
|
+
);
|
|
3584
|
+
} finally {
|
|
3585
|
+
set_active_effect(previous_effect);
|
|
3586
|
+
}
|
|
3587
|
+
}
|
|
3588
|
+
target.special[key2](value);
|
|
3589
|
+
update(target.version);
|
|
3590
|
+
return true;
|
|
3591
|
+
},
|
|
3592
|
+
getOwnPropertyDescriptor(target, key2) {
|
|
3593
|
+
if (target.exclude.includes(key2)) return;
|
|
3594
|
+
if (key2 in target.props) {
|
|
3595
|
+
return {
|
|
3596
|
+
enumerable: true,
|
|
3597
|
+
configurable: true,
|
|
3598
|
+
value: target.props[key2]
|
|
3599
|
+
};
|
|
3600
|
+
}
|
|
3601
|
+
},
|
|
3602
|
+
deleteProperty(target, key2) {
|
|
3603
|
+
if (target.exclude.includes(key2)) return true;
|
|
3604
|
+
target.exclude.push(key2);
|
|
3605
|
+
update(target.version);
|
|
3606
|
+
return true;
|
|
3607
|
+
},
|
|
3608
|
+
has(target, key2) {
|
|
3609
|
+
if (target.exclude.includes(key2)) return false;
|
|
3610
|
+
return key2 in target.props;
|
|
3611
|
+
},
|
|
3612
|
+
ownKeys(target) {
|
|
3613
|
+
return Reflect.ownKeys(target.props).filter((key2) => !target.exclude.includes(key2));
|
|
3614
|
+
}
|
|
3615
|
+
};
|
|
3616
|
+
function legacy_rest_props(props, exclude) {
|
|
3617
|
+
return new Proxy(
|
|
3618
|
+
{
|
|
3619
|
+
props,
|
|
3620
|
+
exclude,
|
|
3621
|
+
special: {},
|
|
3622
|
+
version: source(0),
|
|
3623
|
+
// TODO this is only necessary because we need to track component
|
|
3624
|
+
// destruction inside `prop`, because of `bind:this`, but it
|
|
3625
|
+
// seems likely that we can simplify `bind:this` instead
|
|
3626
|
+
parent_effect: (
|
|
3627
|
+
/** @type {Effect} */
|
|
3628
|
+
active_effect
|
|
3629
|
+
)
|
|
3630
|
+
},
|
|
3631
|
+
legacy_rest_props_handler
|
|
3632
|
+
);
|
|
3633
|
+
}
|
|
3634
|
+
var spread_props_handler = {
|
|
3635
|
+
get(target, key2) {
|
|
3636
|
+
let i = target.props.length;
|
|
3637
|
+
while (i--) {
|
|
3638
|
+
let p = target.props[i];
|
|
3639
|
+
if (is_function(p)) p = p();
|
|
3640
|
+
if (typeof p === "object" && p !== null && key2 in p) return p[key2];
|
|
3641
|
+
}
|
|
3642
|
+
},
|
|
3643
|
+
set(target, key2, value) {
|
|
3644
|
+
let i = target.props.length;
|
|
3645
|
+
while (i--) {
|
|
3646
|
+
let p = target.props[i];
|
|
3647
|
+
if (is_function(p)) p = p();
|
|
3648
|
+
const desc = get_descriptor(p, key2);
|
|
3649
|
+
if (desc && desc.set) {
|
|
3650
|
+
desc.set(value);
|
|
3651
|
+
return true;
|
|
3652
|
+
}
|
|
3653
|
+
}
|
|
3654
|
+
return false;
|
|
3655
|
+
},
|
|
3656
|
+
getOwnPropertyDescriptor(target, key2) {
|
|
3657
|
+
let i = target.props.length;
|
|
3658
|
+
while (i--) {
|
|
3659
|
+
let p = target.props[i];
|
|
3660
|
+
if (is_function(p)) p = p();
|
|
3661
|
+
if (typeof p === "object" && p !== null && key2 in p) {
|
|
3662
|
+
const descriptor = get_descriptor(p, key2);
|
|
3663
|
+
if (descriptor && !descriptor.configurable) {
|
|
3664
|
+
descriptor.configurable = true;
|
|
3665
|
+
}
|
|
3666
|
+
return descriptor;
|
|
3667
|
+
}
|
|
3668
|
+
}
|
|
3669
|
+
},
|
|
3670
|
+
has(target, key2) {
|
|
3671
|
+
if (key2 === STATE_SYMBOL || key2 === LEGACY_PROPS) return false;
|
|
3672
|
+
for (let p of target.props) {
|
|
3673
|
+
if (is_function(p)) p = p();
|
|
3674
|
+
if (p != null && key2 in p) return true;
|
|
3675
|
+
}
|
|
3676
|
+
return false;
|
|
3677
|
+
},
|
|
3678
|
+
ownKeys(target) {
|
|
3679
|
+
const keys = [];
|
|
3680
|
+
for (let p of target.props) {
|
|
3681
|
+
if (is_function(p)) p = p();
|
|
3682
|
+
if (!p) continue;
|
|
3683
|
+
for (const key2 in p) {
|
|
3684
|
+
if (!keys.includes(key2)) keys.push(key2);
|
|
3685
|
+
}
|
|
3686
|
+
for (const key2 of Object.getOwnPropertySymbols(p)) {
|
|
3687
|
+
if (!keys.includes(key2)) keys.push(key2);
|
|
3688
|
+
}
|
|
3689
|
+
}
|
|
3690
|
+
return keys;
|
|
3691
|
+
}
|
|
3692
|
+
};
|
|
3693
|
+
function spread_props(...props) {
|
|
3694
|
+
return new Proxy({ props }, spread_props_handler);
|
|
3695
|
+
}
|
|
3696
|
+
function prop(props, key2, flags, fallback2) {
|
|
3697
|
+
var runes = !legacy_mode_flag || (flags & PROPS_IS_RUNES) !== 0;
|
|
3698
|
+
var bindable = (flags & PROPS_IS_BINDABLE) !== 0;
|
|
3699
|
+
var lazy = (flags & PROPS_IS_LAZY_INITIAL) !== 0;
|
|
3700
|
+
var fallback_value = (
|
|
3701
|
+
/** @type {V} */
|
|
3702
|
+
fallback2
|
|
3703
|
+
);
|
|
3704
|
+
var fallback_dirty = true;
|
|
3705
|
+
var get_fallback = () => {
|
|
3706
|
+
if (fallback_dirty) {
|
|
3707
|
+
fallback_dirty = false;
|
|
3708
|
+
fallback_value = lazy ? untrack(
|
|
3709
|
+
/** @type {() => V} */
|
|
3710
|
+
fallback2
|
|
3711
|
+
) : (
|
|
3712
|
+
/** @type {V} */
|
|
3713
|
+
fallback2
|
|
3714
|
+
);
|
|
3715
|
+
}
|
|
3716
|
+
return fallback_value;
|
|
3717
|
+
};
|
|
3718
|
+
let setter;
|
|
3719
|
+
if (bindable) {
|
|
3720
|
+
var is_entry_props = STATE_SYMBOL in props || LEGACY_PROPS in props;
|
|
3721
|
+
setter = get_descriptor(props, key2)?.set ?? (is_entry_props && key2 in props ? (v) => props[key2] = v : void 0);
|
|
3722
|
+
}
|
|
3723
|
+
var initial_value;
|
|
3724
|
+
var is_store_sub = false;
|
|
3725
|
+
if (bindable) {
|
|
3726
|
+
[initial_value, is_store_sub] = capture_store_binding(() => (
|
|
3727
|
+
/** @type {V} */
|
|
3728
|
+
props[key2]
|
|
3729
|
+
));
|
|
3730
|
+
} else {
|
|
3731
|
+
initial_value = /** @type {V} */
|
|
3732
|
+
props[key2];
|
|
3733
|
+
}
|
|
3734
|
+
if (initial_value === void 0 && fallback2 !== void 0) {
|
|
3735
|
+
initial_value = get_fallback();
|
|
3736
|
+
if (setter) {
|
|
3737
|
+
if (runes) props_invalid_value(key2);
|
|
3738
|
+
setter(initial_value);
|
|
3739
|
+
}
|
|
3740
|
+
}
|
|
3741
|
+
var getter;
|
|
3742
|
+
if (runes) {
|
|
3743
|
+
getter = () => {
|
|
3744
|
+
var value = (
|
|
3745
|
+
/** @type {V} */
|
|
3746
|
+
props[key2]
|
|
3747
|
+
);
|
|
3748
|
+
if (value === void 0) return get_fallback();
|
|
3749
|
+
fallback_dirty = true;
|
|
3750
|
+
return value;
|
|
3751
|
+
};
|
|
3752
|
+
} else {
|
|
3753
|
+
getter = () => {
|
|
3754
|
+
var value = (
|
|
3755
|
+
/** @type {V} */
|
|
3756
|
+
props[key2]
|
|
3757
|
+
);
|
|
3758
|
+
if (value !== void 0) {
|
|
3759
|
+
fallback_value = /** @type {V} */
|
|
3760
|
+
void 0;
|
|
3761
|
+
}
|
|
3762
|
+
return value === void 0 ? fallback_value : value;
|
|
3763
|
+
};
|
|
3764
|
+
}
|
|
3765
|
+
if (runes && (flags & PROPS_IS_UPDATED) === 0) {
|
|
3766
|
+
return getter;
|
|
3767
|
+
}
|
|
3768
|
+
if (setter) {
|
|
3769
|
+
var legacy_parent = props.$$legacy;
|
|
3770
|
+
return (
|
|
3771
|
+
/** @type {() => V} */
|
|
3772
|
+
(function(value, mutation) {
|
|
3773
|
+
if (arguments.length > 0) {
|
|
3774
|
+
if (!runes || !mutation || legacy_parent || is_store_sub) {
|
|
3775
|
+
setter(mutation ? getter() : value);
|
|
3776
|
+
}
|
|
3777
|
+
return value;
|
|
3778
|
+
}
|
|
3779
|
+
return getter();
|
|
3780
|
+
})
|
|
3781
|
+
);
|
|
3782
|
+
}
|
|
3783
|
+
var overridden = false;
|
|
3784
|
+
var d = ((flags & PROPS_IS_IMMUTABLE) !== 0 ? derived : derived_safe_equal)(() => {
|
|
3785
|
+
overridden = false;
|
|
3786
|
+
return getter();
|
|
3787
|
+
});
|
|
3788
|
+
if (true_default) {
|
|
3789
|
+
d.label = key2;
|
|
3790
|
+
}
|
|
3791
|
+
if (bindable) get(d);
|
|
3792
|
+
var parent_effect = (
|
|
3793
|
+
/** @type {Effect} */
|
|
3794
|
+
active_effect
|
|
3795
|
+
);
|
|
3796
|
+
return (
|
|
3797
|
+
/** @type {() => V} */
|
|
3798
|
+
(function(value, mutation) {
|
|
3799
|
+
if (arguments.length > 0) {
|
|
3800
|
+
const new_value = mutation ? get(d) : runes && bindable ? proxy(value) : value;
|
|
3801
|
+
set(d, new_value);
|
|
3802
|
+
overridden = true;
|
|
3803
|
+
if (fallback_value !== void 0) {
|
|
3804
|
+
fallback_value = new_value;
|
|
3805
|
+
}
|
|
3806
|
+
return value;
|
|
3807
|
+
}
|
|
3808
|
+
if (is_destroying_effect && overridden || (parent_effect.f & DESTROYED) !== 0) {
|
|
3809
|
+
return d.v;
|
|
3810
|
+
}
|
|
3811
|
+
return get(d);
|
|
3812
|
+
})
|
|
3813
|
+
);
|
|
3814
|
+
}
|
|
3815
|
+
|
|
3816
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/validate.js
|
|
3817
|
+
function validate_binding(binding, blockers, get_object, get_property, line, column) {
|
|
3818
|
+
run_after_blockers(blockers, () => {
|
|
3819
|
+
var warned = false;
|
|
3820
|
+
var filename = dev_current_component_function?.[FILENAME];
|
|
3821
|
+
render_effect(() => {
|
|
3822
|
+
if (warned) return;
|
|
3823
|
+
var [object, is_store_sub] = capture_store_binding(get_object);
|
|
3824
|
+
if (is_store_sub) return;
|
|
3825
|
+
var property = get_property();
|
|
3826
|
+
var ran = false;
|
|
3827
|
+
var effect2 = render_effect(() => {
|
|
3828
|
+
if (ran) return;
|
|
3829
|
+
object[property];
|
|
3830
|
+
});
|
|
3831
|
+
ran = true;
|
|
3832
|
+
if (effect2.deps === null) {
|
|
3833
|
+
var location = `${filename}:${line}:${column}`;
|
|
3834
|
+
binding_property_non_reactive(binding, location);
|
|
3835
|
+
warned = true;
|
|
3836
|
+
}
|
|
3837
|
+
});
|
|
3838
|
+
});
|
|
3839
|
+
}
|
|
3840
|
+
|
|
3841
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dom/elements/custom-element.js
|
|
3842
|
+
var SvelteElement;
|
|
3843
|
+
if (typeof HTMLElement === "function") {
|
|
3844
|
+
SvelteElement = class extends HTMLElement {
|
|
3845
|
+
/** The Svelte component constructor */
|
|
3846
|
+
$$ctor;
|
|
3847
|
+
/** Slots */
|
|
3848
|
+
$$s;
|
|
3849
|
+
/** @type {any} The Svelte component instance */
|
|
3850
|
+
$$c;
|
|
3851
|
+
/** Whether or not the custom element is connected */
|
|
3852
|
+
$$cn = false;
|
|
3853
|
+
/** @type {Record<string, any>} Component props data */
|
|
3854
|
+
$$d = {};
|
|
3855
|
+
/** `true` if currently in the process of reflecting component props back to attributes */
|
|
3856
|
+
$$r = false;
|
|
3857
|
+
/** @type {Record<string, CustomElementPropDefinition>} Props definition (name, reflected, type etc) */
|
|
3858
|
+
$$p_d = {};
|
|
3859
|
+
/** @type {Record<string, EventListenerOrEventListenerObject[]>} Event listeners */
|
|
3860
|
+
$$l = {};
|
|
3861
|
+
/** @type {Map<EventListenerOrEventListenerObject, Function>} Event listener unsubscribe functions */
|
|
3862
|
+
$$l_u = /* @__PURE__ */ new Map();
|
|
3863
|
+
/** @type {any} The managed render effect for reflecting attributes */
|
|
3864
|
+
$$me;
|
|
3865
|
+
/** @type {ShadowRoot | null} The ShadowRoot of the custom element */
|
|
3866
|
+
$$shadowRoot = null;
|
|
3867
|
+
/**
|
|
3868
|
+
* @param {*} $$componentCtor
|
|
3869
|
+
* @param {*} $$slots
|
|
3870
|
+
* @param {ShadowRootInit | undefined} shadow_root_init
|
|
3871
|
+
*/
|
|
3872
|
+
constructor($$componentCtor, $$slots, shadow_root_init) {
|
|
3873
|
+
super();
|
|
3874
|
+
this.$$ctor = $$componentCtor;
|
|
3875
|
+
this.$$s = $$slots;
|
|
3876
|
+
if (shadow_root_init) {
|
|
3877
|
+
this.$$shadowRoot = this.attachShadow(shadow_root_init);
|
|
3878
|
+
}
|
|
3879
|
+
}
|
|
3880
|
+
/**
|
|
3881
|
+
* @param {string} type
|
|
3882
|
+
* @param {EventListenerOrEventListenerObject} listener
|
|
3883
|
+
* @param {boolean | AddEventListenerOptions} [options]
|
|
3884
|
+
*/
|
|
3885
|
+
addEventListener(type, listener, options) {
|
|
3886
|
+
this.$$l[type] = this.$$l[type] || [];
|
|
3887
|
+
this.$$l[type].push(listener);
|
|
3888
|
+
if (this.$$c) {
|
|
3889
|
+
const unsub = this.$$c.$on(type, listener);
|
|
3890
|
+
this.$$l_u.set(listener, unsub);
|
|
3891
|
+
}
|
|
3892
|
+
super.addEventListener(type, listener, options);
|
|
3893
|
+
}
|
|
3894
|
+
/**
|
|
3895
|
+
* @param {string} type
|
|
3896
|
+
* @param {EventListenerOrEventListenerObject} listener
|
|
3897
|
+
* @param {boolean | AddEventListenerOptions} [options]
|
|
3898
|
+
*/
|
|
3899
|
+
removeEventListener(type, listener, options) {
|
|
3900
|
+
super.removeEventListener(type, listener, options);
|
|
3901
|
+
if (this.$$c) {
|
|
3902
|
+
const unsub = this.$$l_u.get(listener);
|
|
3903
|
+
if (unsub) {
|
|
3904
|
+
unsub();
|
|
3905
|
+
this.$$l_u.delete(listener);
|
|
3906
|
+
}
|
|
3907
|
+
}
|
|
3908
|
+
}
|
|
3909
|
+
async connectedCallback() {
|
|
3910
|
+
this.$$cn = true;
|
|
3911
|
+
if (!this.$$c) {
|
|
3912
|
+
let create_slot = function(name) {
|
|
3913
|
+
return (anchor) => {
|
|
3914
|
+
const slot2 = create_element("slot");
|
|
3915
|
+
if (name !== "default") slot2.name = name;
|
|
3916
|
+
append(anchor, slot2);
|
|
3917
|
+
};
|
|
3918
|
+
};
|
|
3919
|
+
await Promise.resolve();
|
|
3920
|
+
if (!this.$$cn || this.$$c) {
|
|
3921
|
+
return;
|
|
3922
|
+
}
|
|
3923
|
+
const $$slots = {};
|
|
3924
|
+
const existing_slots = get_custom_elements_slots(this);
|
|
3925
|
+
for (const name of this.$$s) {
|
|
3926
|
+
if (name in existing_slots) {
|
|
3927
|
+
if (name === "default" && !this.$$d.children) {
|
|
3928
|
+
this.$$d.children = create_slot(name);
|
|
3929
|
+
$$slots.default = true;
|
|
3930
|
+
} else {
|
|
3931
|
+
$$slots[name] = create_slot(name);
|
|
3932
|
+
}
|
|
3933
|
+
}
|
|
3934
|
+
}
|
|
3935
|
+
for (const attribute of this.attributes) {
|
|
3936
|
+
const name = this.$$g_p(attribute.name);
|
|
3937
|
+
if (!(name in this.$$d)) {
|
|
3938
|
+
this.$$d[name] = get_custom_element_value(name, attribute.value, this.$$p_d, "toProp");
|
|
3939
|
+
}
|
|
3940
|
+
}
|
|
3941
|
+
for (const key2 in this.$$p_d) {
|
|
3942
|
+
if (!(key2 in this.$$d) && this[key2] !== void 0) {
|
|
3943
|
+
this.$$d[key2] = this[key2];
|
|
3944
|
+
delete this[key2];
|
|
3945
|
+
}
|
|
3946
|
+
}
|
|
3947
|
+
this.$$c = createClassComponent({
|
|
3948
|
+
component: this.$$ctor,
|
|
3949
|
+
target: this.$$shadowRoot || this,
|
|
3950
|
+
props: {
|
|
3951
|
+
...this.$$d,
|
|
3952
|
+
$$slots,
|
|
3953
|
+
$$host: this
|
|
3954
|
+
}
|
|
3955
|
+
});
|
|
3956
|
+
this.$$me = effect_root(() => {
|
|
3957
|
+
render_effect(() => {
|
|
3958
|
+
this.$$r = true;
|
|
3959
|
+
for (const key2 of object_keys(this.$$c)) {
|
|
3960
|
+
if (!this.$$p_d[key2]?.reflect) continue;
|
|
3961
|
+
this.$$d[key2] = this.$$c[key2];
|
|
3962
|
+
const attribute_value = get_custom_element_value(
|
|
3963
|
+
key2,
|
|
3964
|
+
this.$$d[key2],
|
|
3965
|
+
this.$$p_d,
|
|
3966
|
+
"toAttribute"
|
|
3967
|
+
);
|
|
3968
|
+
if (attribute_value == null) {
|
|
3969
|
+
this.removeAttribute(this.$$p_d[key2].attribute || key2);
|
|
3970
|
+
} else {
|
|
3971
|
+
this.setAttribute(this.$$p_d[key2].attribute || key2, attribute_value);
|
|
3972
|
+
}
|
|
3973
|
+
}
|
|
3974
|
+
this.$$r = false;
|
|
3975
|
+
});
|
|
3976
|
+
});
|
|
3977
|
+
for (const type in this.$$l) {
|
|
3978
|
+
for (const listener of this.$$l[type]) {
|
|
3979
|
+
const unsub = this.$$c.$on(type, listener);
|
|
3980
|
+
this.$$l_u.set(listener, unsub);
|
|
3981
|
+
}
|
|
3982
|
+
}
|
|
3983
|
+
this.$$l = {};
|
|
3984
|
+
}
|
|
3985
|
+
}
|
|
3986
|
+
// We don't need this when working within Svelte code, but for compatibility of people using this outside of Svelte
|
|
3987
|
+
// and setting attributes through setAttribute etc, this is helpful
|
|
3988
|
+
/**
|
|
3989
|
+
* @param {string} attr
|
|
3990
|
+
* @param {string} _oldValue
|
|
3991
|
+
* @param {string} newValue
|
|
3992
|
+
*/
|
|
3993
|
+
attributeChangedCallback(attr2, _oldValue, newValue) {
|
|
3994
|
+
if (this.$$r) return;
|
|
3995
|
+
attr2 = this.$$g_p(attr2);
|
|
3996
|
+
this.$$d[attr2] = get_custom_element_value(attr2, newValue, this.$$p_d, "toProp");
|
|
3997
|
+
this.$$c?.$set({ [attr2]: this.$$d[attr2] });
|
|
3998
|
+
}
|
|
3999
|
+
disconnectedCallback() {
|
|
4000
|
+
this.$$cn = false;
|
|
4001
|
+
Promise.resolve().then(() => {
|
|
4002
|
+
if (!this.$$cn && this.$$c) {
|
|
4003
|
+
this.$$c.$destroy();
|
|
4004
|
+
this.$$me();
|
|
4005
|
+
this.$$c = void 0;
|
|
4006
|
+
}
|
|
4007
|
+
});
|
|
4008
|
+
}
|
|
4009
|
+
/**
|
|
4010
|
+
* @param {string} attribute_name
|
|
4011
|
+
*/
|
|
4012
|
+
$$g_p(attribute_name) {
|
|
4013
|
+
return object_keys(this.$$p_d).find(
|
|
4014
|
+
(key2) => this.$$p_d[key2].attribute === attribute_name || !this.$$p_d[key2].attribute && key2.toLowerCase() === attribute_name
|
|
4015
|
+
) || attribute_name;
|
|
4016
|
+
}
|
|
4017
|
+
};
|
|
4018
|
+
}
|
|
4019
|
+
function get_custom_element_value(prop2, value, props_definition, transform) {
|
|
4020
|
+
const type = props_definition[prop2]?.type;
|
|
4021
|
+
value = type === "Boolean" && typeof value !== "boolean" ? value != null : value;
|
|
4022
|
+
if (!transform || !props_definition[prop2]) {
|
|
4023
|
+
return value;
|
|
4024
|
+
} else if (transform === "toAttribute") {
|
|
4025
|
+
switch (type) {
|
|
4026
|
+
case "Object":
|
|
4027
|
+
case "Array":
|
|
4028
|
+
return value == null ? null : JSON.stringify(value);
|
|
4029
|
+
case "Boolean":
|
|
4030
|
+
return value ? "" : null;
|
|
4031
|
+
case "Number":
|
|
4032
|
+
return value == null ? null : value;
|
|
4033
|
+
default:
|
|
4034
|
+
return value;
|
|
4035
|
+
}
|
|
4036
|
+
} else {
|
|
4037
|
+
switch (type) {
|
|
4038
|
+
case "Object":
|
|
4039
|
+
case "Array":
|
|
4040
|
+
return value && JSON.parse(value);
|
|
4041
|
+
case "Boolean":
|
|
4042
|
+
return value;
|
|
4043
|
+
// conversion already handled above
|
|
4044
|
+
case "Number":
|
|
4045
|
+
return value != null ? +value : value;
|
|
4046
|
+
default:
|
|
4047
|
+
return value;
|
|
4048
|
+
}
|
|
4049
|
+
}
|
|
4050
|
+
}
|
|
4051
|
+
function get_custom_elements_slots(element2) {
|
|
4052
|
+
const result = {};
|
|
4053
|
+
element2.childNodes.forEach((node) => {
|
|
4054
|
+
result[
|
|
4055
|
+
/** @type {Element} node */
|
|
4056
|
+
node.slot || "default"
|
|
4057
|
+
] = true;
|
|
4058
|
+
});
|
|
4059
|
+
return result;
|
|
4060
|
+
}
|
|
4061
|
+
function create_custom_element(Component, props_definition, slots, exports, shadow_root_init, extend) {
|
|
4062
|
+
let Class = class extends SvelteElement {
|
|
4063
|
+
constructor() {
|
|
4064
|
+
super(Component, slots, shadow_root_init);
|
|
4065
|
+
this.$$p_d = props_definition;
|
|
4066
|
+
}
|
|
4067
|
+
static get observedAttributes() {
|
|
4068
|
+
return object_keys(props_definition).map(
|
|
4069
|
+
(key2) => (props_definition[key2].attribute || key2).toLowerCase()
|
|
4070
|
+
);
|
|
4071
|
+
}
|
|
4072
|
+
};
|
|
4073
|
+
object_keys(props_definition).forEach((prop2) => {
|
|
4074
|
+
define_property(Class.prototype, prop2, {
|
|
4075
|
+
get() {
|
|
4076
|
+
return this.$$c && prop2 in this.$$c ? this.$$c[prop2] : this.$$d[prop2];
|
|
4077
|
+
},
|
|
4078
|
+
set(value) {
|
|
4079
|
+
value = get_custom_element_value(prop2, value, props_definition);
|
|
4080
|
+
this.$$d[prop2] = value;
|
|
4081
|
+
var component2 = this.$$c;
|
|
4082
|
+
if (component2) {
|
|
4083
|
+
var setter = get_descriptor(component2, prop2)?.get;
|
|
4084
|
+
if (setter) {
|
|
4085
|
+
component2[prop2] = value;
|
|
4086
|
+
} else {
|
|
4087
|
+
component2.$set({ [prop2]: value });
|
|
4088
|
+
}
|
|
4089
|
+
}
|
|
4090
|
+
}
|
|
4091
|
+
});
|
|
4092
|
+
});
|
|
4093
|
+
exports.forEach((property) => {
|
|
4094
|
+
define_property(Class.prototype, property, {
|
|
4095
|
+
get() {
|
|
4096
|
+
return this.$$c?.[property];
|
|
4097
|
+
}
|
|
4098
|
+
});
|
|
4099
|
+
});
|
|
4100
|
+
if (extend) {
|
|
4101
|
+
Class = extend(Class);
|
|
4102
|
+
}
|
|
4103
|
+
Component.element = /** @type {any} */
|
|
4104
|
+
Class;
|
|
4105
|
+
return Class;
|
|
4106
|
+
}
|
|
4107
|
+
|
|
4108
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/dev/console-log.js
|
|
4109
|
+
function log_if_contains_state(method, ...objects) {
|
|
4110
|
+
untrack(() => {
|
|
4111
|
+
try {
|
|
4112
|
+
let has_state = false;
|
|
4113
|
+
const transformed = [];
|
|
4114
|
+
for (const obj of objects) {
|
|
4115
|
+
if (obj && typeof obj === "object" && STATE_SYMBOL in obj) {
|
|
4116
|
+
transformed.push(snapshot(obj, true));
|
|
4117
|
+
has_state = true;
|
|
4118
|
+
} else {
|
|
4119
|
+
transformed.push(obj);
|
|
4120
|
+
}
|
|
4121
|
+
}
|
|
4122
|
+
if (has_state) {
|
|
4123
|
+
console_log_state(method);
|
|
4124
|
+
console.log("%c[snapshot]", "color: grey", ...transformed);
|
|
4125
|
+
}
|
|
4126
|
+
} catch {
|
|
4127
|
+
}
|
|
4128
|
+
});
|
|
4129
|
+
return objects;
|
|
4130
|
+
}
|
|
4131
|
+
|
|
4132
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/internal/client/hydratable.js
|
|
4133
|
+
function hydratable(key2, fn) {
|
|
4134
|
+
if (!async_mode_flag) {
|
|
4135
|
+
experimental_async_required("hydratable");
|
|
4136
|
+
}
|
|
4137
|
+
if (hydrating) {
|
|
4138
|
+
const store = window.__svelte?.h;
|
|
4139
|
+
if (store?.has(key2)) {
|
|
4140
|
+
return (
|
|
4141
|
+
/** @type {T} */
|
|
4142
|
+
store.get(key2)
|
|
4143
|
+
);
|
|
4144
|
+
}
|
|
4145
|
+
if (true_default) {
|
|
4146
|
+
hydratable_missing_but_required(key2);
|
|
4147
|
+
} else {
|
|
4148
|
+
hydratable_missing_but_expected(key2);
|
|
4149
|
+
}
|
|
4150
|
+
}
|
|
4151
|
+
return fn();
|
|
4152
|
+
}
|
|
4153
|
+
|
|
4154
|
+
// ../node_modules/.pnpm/svelte@5.54.1/node_modules/svelte/src/index-client.js
|
|
4155
|
+
if (true_default) {
|
|
4156
|
+
let throw_rune_error = function(rune) {
|
|
4157
|
+
if (!(rune in globalThis)) {
|
|
4158
|
+
let value;
|
|
4159
|
+
Object.defineProperty(globalThis, rune, {
|
|
4160
|
+
configurable: true,
|
|
4161
|
+
// eslint-disable-next-line getter-return
|
|
4162
|
+
get: () => {
|
|
4163
|
+
if (value !== void 0) {
|
|
4164
|
+
return value;
|
|
4165
|
+
}
|
|
4166
|
+
rune_outside_svelte(rune);
|
|
4167
|
+
},
|
|
4168
|
+
set: (v) => {
|
|
4169
|
+
value = v;
|
|
4170
|
+
}
|
|
4171
|
+
});
|
|
4172
|
+
}
|
|
4173
|
+
};
|
|
4174
|
+
throw_rune_error("$state");
|
|
4175
|
+
throw_rune_error("$effect");
|
|
4176
|
+
throw_rune_error("$derived");
|
|
4177
|
+
throw_rune_error("$inspect");
|
|
4178
|
+
throw_rune_error("$props");
|
|
4179
|
+
throw_rune_error("$bindable");
|
|
4180
|
+
}
|
|
4181
|
+
function getAbortSignal() {
|
|
4182
|
+
if (active_reaction === null) {
|
|
4183
|
+
get_abort_signal_outside_reaction();
|
|
4184
|
+
}
|
|
4185
|
+
return (active_reaction.ac ??= new AbortController()).signal;
|
|
4186
|
+
}
|
|
4187
|
+
function onMount(fn) {
|
|
4188
|
+
if (component_context === null) {
|
|
4189
|
+
lifecycle_outside_component("onMount");
|
|
4190
|
+
}
|
|
4191
|
+
if (legacy_mode_flag && component_context.l !== null) {
|
|
4192
|
+
init_update_callbacks(component_context).m.push(fn);
|
|
4193
|
+
} else {
|
|
4194
|
+
user_effect(() => {
|
|
4195
|
+
const cleanup = untrack(fn);
|
|
4196
|
+
if (typeof cleanup === "function") return (
|
|
4197
|
+
/** @type {() => void} */
|
|
4198
|
+
cleanup
|
|
4199
|
+
);
|
|
4200
|
+
});
|
|
4201
|
+
}
|
|
4202
|
+
}
|
|
4203
|
+
function onDestroy(fn) {
|
|
4204
|
+
if (component_context === null) {
|
|
4205
|
+
lifecycle_outside_component("onDestroy");
|
|
4206
|
+
}
|
|
4207
|
+
onMount(() => () => untrack(fn));
|
|
4208
|
+
}
|
|
4209
|
+
function create_custom_event(type, detail, { bubbles = false, cancelable = false } = {}) {
|
|
4210
|
+
return new CustomEvent(type, { detail, bubbles, cancelable });
|
|
4211
|
+
}
|
|
4212
|
+
function createEventDispatcher() {
|
|
4213
|
+
const active_component_context = component_context;
|
|
4214
|
+
if (active_component_context === null) {
|
|
4215
|
+
lifecycle_outside_component("createEventDispatcher");
|
|
4216
|
+
}
|
|
4217
|
+
return (type, detail, options) => {
|
|
4218
|
+
const events = (
|
|
4219
|
+
/** @type {Record<string, Function | Function[]>} */
|
|
4220
|
+
active_component_context.s.$$events?.[
|
|
4221
|
+
/** @type {string} */
|
|
4222
|
+
type
|
|
4223
|
+
]
|
|
4224
|
+
);
|
|
4225
|
+
if (events) {
|
|
4226
|
+
const callbacks = is_array(events) ? events.slice() : [events];
|
|
4227
|
+
const event2 = create_custom_event(
|
|
4228
|
+
/** @type {string} */
|
|
4229
|
+
type,
|
|
4230
|
+
detail,
|
|
4231
|
+
options
|
|
4232
|
+
);
|
|
4233
|
+
for (const fn of callbacks) {
|
|
4234
|
+
fn.call(active_component_context.x, event2);
|
|
4235
|
+
}
|
|
4236
|
+
return !event2.defaultPrevented;
|
|
4237
|
+
}
|
|
4238
|
+
return true;
|
|
4239
|
+
};
|
|
4240
|
+
}
|
|
4241
|
+
function beforeUpdate(fn) {
|
|
4242
|
+
if (component_context === null) {
|
|
4243
|
+
lifecycle_outside_component("beforeUpdate");
|
|
4244
|
+
}
|
|
4245
|
+
if (component_context.l === null) {
|
|
4246
|
+
lifecycle_legacy_only("beforeUpdate");
|
|
4247
|
+
}
|
|
4248
|
+
init_update_callbacks(component_context).b.push(fn);
|
|
4249
|
+
}
|
|
4250
|
+
function afterUpdate(fn) {
|
|
4251
|
+
if (component_context === null) {
|
|
4252
|
+
lifecycle_outside_component("afterUpdate");
|
|
4253
|
+
}
|
|
4254
|
+
if (component_context.l === null) {
|
|
4255
|
+
lifecycle_legacy_only("afterUpdate");
|
|
4256
|
+
}
|
|
4257
|
+
init_update_callbacks(component_context).a.push(fn);
|
|
4258
|
+
}
|
|
4259
|
+
function init_update_callbacks(context) {
|
|
4260
|
+
var l = (
|
|
4261
|
+
/** @type {ComponentContextLegacy} */
|
|
4262
|
+
context.l
|
|
4263
|
+
);
|
|
4264
|
+
return l.u ??= { a: [], b: [], m: [] };
|
|
4265
|
+
}
|
|
4266
|
+
|
|
4267
|
+
export {
|
|
4268
|
+
hydratable,
|
|
4269
|
+
validate_void_dynamic_element,
|
|
4270
|
+
validate_dynamic_element_tag,
|
|
4271
|
+
validate_store,
|
|
4272
|
+
prevent_snippet_stringification,
|
|
4273
|
+
snippet,
|
|
4274
|
+
wrap_snippet,
|
|
4275
|
+
createRawSnippet,
|
|
4276
|
+
getAbortSignal,
|
|
4277
|
+
onMount,
|
|
4278
|
+
onDestroy,
|
|
4279
|
+
createEventDispatcher,
|
|
4280
|
+
beforeUpdate,
|
|
4281
|
+
afterUpdate,
|
|
4282
|
+
createAttachmentKey,
|
|
4283
|
+
fromAction,
|
|
4284
|
+
assign,
|
|
4285
|
+
assign_async,
|
|
4286
|
+
cleanup_styles,
|
|
4287
|
+
add_locations,
|
|
4288
|
+
hmr,
|
|
4289
|
+
create_ownership_validator,
|
|
4290
|
+
check_target,
|
|
4291
|
+
legacy_api,
|
|
4292
|
+
inspect,
|
|
4293
|
+
async,
|
|
4294
|
+
validate_snippet_args,
|
|
4295
|
+
await_block,
|
|
4296
|
+
if_block,
|
|
4297
|
+
key,
|
|
4298
|
+
css_props,
|
|
4299
|
+
index,
|
|
4300
|
+
each,
|
|
4301
|
+
html,
|
|
4302
|
+
slot,
|
|
4303
|
+
sanitize_slots,
|
|
4304
|
+
component,
|
|
4305
|
+
raf,
|
|
4306
|
+
loop,
|
|
4307
|
+
animation,
|
|
4308
|
+
transition,
|
|
4309
|
+
element,
|
|
4310
|
+
head,
|
|
4311
|
+
append_styles,
|
|
4312
|
+
action,
|
|
4313
|
+
attach,
|
|
4314
|
+
attr,
|
|
4315
|
+
clsx2 as clsx,
|
|
4316
|
+
set_class,
|
|
4317
|
+
set_style,
|
|
4318
|
+
select_option,
|
|
4319
|
+
init_select,
|
|
4320
|
+
bind_select_value,
|
|
4321
|
+
CLASS,
|
|
4322
|
+
STYLE,
|
|
4323
|
+
remove_input_defaults,
|
|
4324
|
+
set_value,
|
|
4325
|
+
set_checked,
|
|
4326
|
+
set_selected,
|
|
4327
|
+
set_default_checked,
|
|
4328
|
+
set_default_value,
|
|
4329
|
+
set_attribute,
|
|
4330
|
+
set_xlink_attribute,
|
|
4331
|
+
set_custom_element_data,
|
|
4332
|
+
attribute_effect,
|
|
4333
|
+
selectedcontent,
|
|
4334
|
+
customizable_select,
|
|
4335
|
+
bind_active_element,
|
|
4336
|
+
bind_value,
|
|
4337
|
+
bind_group,
|
|
4338
|
+
bind_checked,
|
|
4339
|
+
bind_files,
|
|
4340
|
+
bind_current_time,
|
|
4341
|
+
bind_buffered,
|
|
4342
|
+
bind_seekable,
|
|
4343
|
+
bind_played,
|
|
4344
|
+
bind_seeking,
|
|
4345
|
+
bind_ended,
|
|
4346
|
+
bind_ready_state,
|
|
4347
|
+
bind_playback_rate,
|
|
4348
|
+
bind_paused,
|
|
4349
|
+
bind_volume,
|
|
4350
|
+
bind_muted,
|
|
4351
|
+
bind_online,
|
|
4352
|
+
bind_prop,
|
|
4353
|
+
bind_resize_observer,
|
|
4354
|
+
bind_element_size,
|
|
4355
|
+
bind_this,
|
|
4356
|
+
bind_content_editable,
|
|
4357
|
+
bind_property,
|
|
4358
|
+
bind_focused,
|
|
4359
|
+
bind_window_scroll,
|
|
4360
|
+
bind_window_size,
|
|
4361
|
+
init,
|
|
4362
|
+
reactive_import,
|
|
4363
|
+
bubble_event,
|
|
4364
|
+
add_legacy_event_listener,
|
|
4365
|
+
update_legacy_props,
|
|
4366
|
+
update_prop,
|
|
4367
|
+
update_pre_prop,
|
|
4368
|
+
rest_props,
|
|
4369
|
+
legacy_rest_props,
|
|
4370
|
+
spread_props,
|
|
4371
|
+
prop,
|
|
4372
|
+
validate_binding,
|
|
4373
|
+
create_custom_element,
|
|
4374
|
+
log_if_contains_state
|
|
4375
|
+
};
|
|
4376
|
+
//# sourceMappingURL=chunk-HNCLEOC5.js.map
|