houdini-svelte 0.0.0-20240519095848 → 0.0.0-20240523222233

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.
@@ -154654,1197 +154654,799 @@ function apply_mutations(node, mutations) {
154654
154654
  return obj;
154655
154655
  }
154656
154656
 
154657
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/errors.js
154658
- var CompileError = class extends Error {
154659
- name = "CompileError";
154660
- filename = void 0;
154661
- position = void 0;
154662
- start = void 0;
154663
- end = void 0;
154664
- constructor(code, message, position) {
154665
- super(message);
154666
- this.code = code;
154667
- this.position = position;
154657
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/patterns.js
154658
+ var regex_whitespace = /\s/;
154659
+ var regex_whitespaces = /\s+/;
154660
+ var regex_starts_with_newline = /^\r?\n/;
154661
+ var regex_starts_with_whitespaces = /^[ \t\r\n]+/;
154662
+ var regex_ends_with_whitespaces = /[ \t\r\n]+$/;
154663
+ var regex_not_whitespace = /[^ \t\r\n]/;
154664
+ var regex_whitespaces_strict = /[ \t\n\r\f]+/g;
154665
+ var regex_only_whitespaces = /^[ \t\n\r\f]+$/;
154666
+ var regex_not_newline_characters = /[^\n]/g;
154667
+ var regex_is_valid_identifier = /^[a-zA-Z_$][a-zA-Z_$0-9]*$/;
154668
+ var regex_invalid_identifier_chars = /(^[^a-zA-Z_$]|[^a-zA-Z0-9_$])/g;
154669
+ var regex_starts_with_vowel = /^[aeiou]/;
154670
+ var regex_heading_tags = /^h[1-6]$/;
154671
+ var regex_illegal_attribute_character = /(^[0-9-.])|[\^$@%&#?!|()[\]{}^*+~;]/;
154672
+
154673
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/1-parse/utils/fuzzymatch.js
154674
+ function fuzzymatch(name, names) {
154675
+ if (names.length === 0)
154676
+ return null;
154677
+ const set2 = new FuzzySet(names);
154678
+ const matches = set2.get(name);
154679
+ return matches && matches[0][0] > 0.7 ? matches[0][1] : null;
154680
+ }
154681
+ var GRAM_SIZE_LOWER = 2;
154682
+ var GRAM_SIZE_UPPER = 3;
154683
+ function _distance(str1, str2) {
154684
+ if (str1 === null && str2 === null) {
154685
+ throw "Trying to compare two null values";
154668
154686
  }
154669
- toString() {
154670
- let out = `${this.name}: ${this.message}`;
154671
- out += `
154672
- (${this.code})`;
154673
- if (this.filename) {
154674
- out += `
154675
- ${this.filename}`;
154676
- if (this.start) {
154677
- out += `${this.start.line}:${this.start.column}`;
154687
+ if (str1 === null || str2 === null)
154688
+ return 0;
154689
+ str1 = String(str1);
154690
+ str2 = String(str2);
154691
+ const distance = levenshtein(str1, str2);
154692
+ return 1 - distance / Math.max(str1.length, str2.length);
154693
+ }
154694
+ function levenshtein(str1, str2) {
154695
+ const current2 = [];
154696
+ let prev = 0;
154697
+ let value = 0;
154698
+ for (let i3 = 0; i3 <= str2.length; i3++) {
154699
+ for (let j = 0; j <= str1.length; j++) {
154700
+ if (i3 && j) {
154701
+ if (str1.charAt(j - 1) === str2.charAt(i3 - 1)) {
154702
+ value = prev;
154703
+ } else {
154704
+ value = Math.min(current2[j], current2[j - 1], prev) + 1;
154705
+ }
154706
+ } else {
154707
+ value = i3 + j;
154678
154708
  }
154709
+ prev = current2[j];
154710
+ current2[j] = value;
154679
154711
  }
154680
- return out;
154681
154712
  }
154682
- };
154683
- function e3(node, code, message) {
154684
- const start = typeof node === "number" ? node : node?.start;
154685
- const end = typeof node === "number" ? node : node?.end;
154686
- throw new CompileError(code, message, start !== void 0 && end !== void 0 ? [start, end] : void 0);
154713
+ return current2.pop();
154687
154714
  }
154688
- function options_invalid_value(node, details) {
154689
- e3(node, "options_invalid_value", `Invalid compiler option: ${details}`);
154715
+ var non_word_regex = /[^\w, ]+/;
154716
+ function iterate_grams(value, gram_size = 2) {
154717
+ const simplified = "-" + value.toLowerCase().replace(non_word_regex, "") + "-";
154718
+ const len_diff = gram_size - simplified.length;
154719
+ const results = [];
154720
+ if (len_diff > 0) {
154721
+ for (let i3 = 0; i3 < len_diff; ++i3) {
154722
+ value += "-";
154723
+ }
154724
+ }
154725
+ for (let i3 = 0; i3 < simplified.length - gram_size + 1; ++i3) {
154726
+ results.push(simplified.slice(i3, i3 + gram_size));
154727
+ }
154728
+ return results;
154690
154729
  }
154691
- function options_removed(node, details) {
154692
- e3(node, "options_removed", `Invalid compiler option: ${details}`);
154730
+ function gram_counter(value, gram_size = 2) {
154731
+ const result = {};
154732
+ const grams = iterate_grams(value, gram_size);
154733
+ let i3 = 0;
154734
+ for (i3; i3 < grams.length; ++i3) {
154735
+ if (grams[i3] in result) {
154736
+ result[grams[i3]] += 1;
154737
+ } else {
154738
+ result[grams[i3]] = 1;
154739
+ }
154740
+ }
154741
+ return result;
154693
154742
  }
154694
- function options_unrecognised(node, keypath) {
154695
- e3(node, "options_unrecognised", `Unrecognised compiler option ${keypath}`);
154743
+ function sort_descending(a2, b2) {
154744
+ return b2[0] - a2[0];
154696
154745
  }
154697
- function bindable_invalid_location(node) {
154698
- e3(node, "bindable_invalid_location", "`$bindable()` can only be used inside a `$props()` declaration");
154746
+ var FuzzySet = class {
154747
+ exact_set = {};
154748
+ match_dict = {};
154749
+ items = {};
154750
+ constructor(arr) {
154751
+ for (let i3 = GRAM_SIZE_LOWER; i3 < GRAM_SIZE_UPPER + 1; ++i3) {
154752
+ this.items[i3] = [];
154753
+ }
154754
+ for (let i3 = 0; i3 < arr.length; ++i3) {
154755
+ this.add(arr[i3]);
154756
+ }
154757
+ }
154758
+ add(value) {
154759
+ const normalized_value = value.toLowerCase();
154760
+ if (normalized_value in this.exact_set) {
154761
+ return false;
154762
+ }
154763
+ let i3 = GRAM_SIZE_LOWER;
154764
+ for (i3; i3 < GRAM_SIZE_UPPER + 1; ++i3) {
154765
+ this._add(value, i3);
154766
+ }
154767
+ }
154768
+ _add(value, gram_size) {
154769
+ const normalized_value = value.toLowerCase();
154770
+ const items = this.items[gram_size] || [];
154771
+ const index = items.length;
154772
+ items.push(0);
154773
+ const gram_counts = gram_counter(normalized_value, gram_size);
154774
+ let sum_of_square_gram_counts = 0;
154775
+ let gram;
154776
+ let gram_count;
154777
+ for (gram in gram_counts) {
154778
+ gram_count = gram_counts[gram];
154779
+ sum_of_square_gram_counts += Math.pow(gram_count, 2);
154780
+ if (gram in this.match_dict) {
154781
+ this.match_dict[gram].push([index, gram_count]);
154782
+ } else {
154783
+ this.match_dict[gram] = [[index, gram_count]];
154784
+ }
154785
+ }
154786
+ const vector_normal = Math.sqrt(sum_of_square_gram_counts);
154787
+ items[index] = [vector_normal, normalized_value];
154788
+ this.items[gram_size] = items;
154789
+ this.exact_set[normalized_value] = value;
154790
+ }
154791
+ get(value) {
154792
+ const normalized_value = value.toLowerCase();
154793
+ const result = this.exact_set[normalized_value];
154794
+ if (result) {
154795
+ return [[1, result]];
154796
+ }
154797
+ for (let gram_size = GRAM_SIZE_UPPER; gram_size >= GRAM_SIZE_LOWER; --gram_size) {
154798
+ const results = this.__get(value, gram_size);
154799
+ if (results.length > 0)
154800
+ return results;
154801
+ }
154802
+ return null;
154803
+ }
154804
+ __get(value, gram_size) {
154805
+ const normalized_value = value.toLowerCase();
154806
+ const matches = {};
154807
+ const gram_counts = gram_counter(normalized_value, gram_size);
154808
+ const items = this.items[gram_size];
154809
+ let sum_of_square_gram_counts = 0;
154810
+ let gram;
154811
+ let gram_count;
154812
+ let i3;
154813
+ let index;
154814
+ let other_gram_count;
154815
+ for (gram in gram_counts) {
154816
+ gram_count = gram_counts[gram];
154817
+ sum_of_square_gram_counts += Math.pow(gram_count, 2);
154818
+ if (gram in this.match_dict) {
154819
+ for (i3 = 0; i3 < this.match_dict[gram].length; ++i3) {
154820
+ index = this.match_dict[gram][i3][0];
154821
+ other_gram_count = this.match_dict[gram][i3][1];
154822
+ if (index in matches) {
154823
+ matches[index] += gram_count * other_gram_count;
154824
+ } else {
154825
+ matches[index] = gram_count * other_gram_count;
154826
+ }
154827
+ }
154828
+ }
154829
+ }
154830
+ const vector_normal = Math.sqrt(sum_of_square_gram_counts);
154831
+ let results = [];
154832
+ let match_score;
154833
+ for (const match_index in matches) {
154834
+ match_score = matches[match_index];
154835
+ results.push([match_score / (vector_normal * items[match_index][0]), items[match_index][1]]);
154836
+ }
154837
+ results.sort(sort_descending);
154838
+ let new_results = [];
154839
+ const end_index = Math.min(50, results.length);
154840
+ for (let i4 = 0; i4 < end_index; ++i4) {
154841
+ new_results.push([_distance(results[i4][1], normalized_value), results[i4][1]]);
154842
+ }
154843
+ results = new_results;
154844
+ results.sort(sort_descending);
154845
+ new_results = [];
154846
+ for (let i4 = 0; i4 < results.length; ++i4) {
154847
+ if (results[i4][0] === results[0][0]) {
154848
+ new_results.push([results[i4][0], this.exact_set[results[i4][1]]]);
154849
+ }
154850
+ }
154851
+ return new_results;
154852
+ }
154853
+ };
154854
+
154855
+ // ../../node_modules/.pnpm/locate-character@3.0.0/node_modules/locate-character/src/index.js
154856
+ function rangeContains(range, index) {
154857
+ return range.start <= index && index < range.end;
154699
154858
  }
154700
- function constant_assignment(node, thing) {
154701
- e3(node, "constant_assignment", `Cannot assign to ${thing}`);
154859
+ function getLocator(source, options = {}) {
154860
+ const { offsetLine = 0, offsetColumn = 0 } = options;
154861
+ let start = 0;
154862
+ const ranges = source.split("\n").map((line, i4) => {
154863
+ const end = start + line.length + 1;
154864
+ const range = { start, end, line: i4 };
154865
+ start = end;
154866
+ return range;
154867
+ });
154868
+ let i3 = 0;
154869
+ function locator2(search, index) {
154870
+ if (typeof search === "string") {
154871
+ search = source.indexOf(search, index ?? 0);
154872
+ }
154873
+ if (search === -1)
154874
+ return void 0;
154875
+ let range = ranges[i3];
154876
+ const d2 = search >= range.end ? 1 : -1;
154877
+ while (range) {
154878
+ if (rangeContains(range, search)) {
154879
+ return {
154880
+ line: offsetLine + range.line,
154881
+ column: offsetColumn + search - range.start,
154882
+ character: search
154883
+ };
154884
+ }
154885
+ i3 += d2;
154886
+ range = ranges[i3];
154887
+ }
154888
+ }
154889
+ return locator2;
154702
154890
  }
154703
- function constant_binding(node, thing) {
154704
- e3(node, "constant_binding", `Cannot bind to ${thing}`);
154705
- }
154706
- function declaration_duplicate_module_import(node) {
154707
- e3(node, "declaration_duplicate_module_import", 'Cannot declare same variable name which is imported inside `<script context="module">`');
154891
+
154892
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/state.js
154893
+ var warnings = [];
154894
+ var filename;
154895
+ var locator = getLocator("", { offsetLine: 1 });
154896
+ var ignore_stack = [];
154897
+ function reset3(source, options) {
154898
+ const root_dir = options.rootDir?.replace(/\\/g, "/");
154899
+ filename = options.filename?.replace(/\\/g, "/");
154900
+ if (typeof filename === "string" && typeof root_dir === "string" && filename.startsWith(root_dir)) {
154901
+ filename = filename.replace(root_dir, "").replace(/^[/\\]/, "");
154902
+ }
154903
+ locator = getLocator(source, { offsetLine: 1 });
154904
+ warnings = [];
154905
+ ignore_stack = [];
154708
154906
  }
154709
- function derived_invalid_export(node) {
154710
- e3(node, "derived_invalid_export", "Cannot export derived state from a module. To expose the current derived value, export a function returning its value");
154907
+
154908
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/warnings.js
154909
+ function w(node, code, message) {
154910
+ if (ignore_stack.at(-1)?.has(code))
154911
+ return;
154912
+ warnings.push({
154913
+ code,
154914
+ message,
154915
+ filename,
154916
+ start: node?.start !== void 0 ? locator(node.start) : void 0,
154917
+ end: node?.end !== void 0 ? locator(node.end) : void 0
154918
+ });
154711
154919
  }
154712
- function each_item_invalid_assignment(node) {
154713
- e3(node, "each_item_invalid_assignment", "Cannot reassign or bind to each block argument in runes mode. Use the array and index variables instead (e.g. `array[i] = value` instead of `entry = value`)");
154920
+ var codes = [
154921
+ "a11y_accesskey",
154922
+ "a11y_aria_activedescendant_has_tabindex",
154923
+ "a11y_aria_attributes",
154924
+ "a11y_autocomplete_valid",
154925
+ "a11y_autofocus",
154926
+ "a11y_click_events_have_key_events",
154927
+ "a11y_distracting_elements",
154928
+ "a11y_figcaption_index",
154929
+ "a11y_figcaption_parent",
154930
+ "a11y_hidden",
154931
+ "a11y_img_redundant_alt",
154932
+ "a11y_incorrect_aria_attribute_type",
154933
+ "a11y_incorrect_aria_attribute_type_boolean",
154934
+ "a11y_incorrect_aria_attribute_type_id",
154935
+ "a11y_incorrect_aria_attribute_type_idlist",
154936
+ "a11y_incorrect_aria_attribute_type_integer",
154937
+ "a11y_incorrect_aria_attribute_type_token",
154938
+ "a11y_incorrect_aria_attribute_type_tokenlist",
154939
+ "a11y_incorrect_aria_attribute_type_tristate",
154940
+ "a11y_interactive_supports_focus",
154941
+ "a11y_invalid_attribute",
154942
+ "a11y_label_has_associated_control",
154943
+ "a11y_media_has_caption",
154944
+ "a11y_misplaced_role",
154945
+ "a11y_misplaced_scope",
154946
+ "a11y_missing_attribute",
154947
+ "a11y_missing_content",
154948
+ "a11y_mouse_events_have_key_events",
154949
+ "a11y_no_abstract_role",
154950
+ "a11y_no_interactive_element_to_noninteractive_role",
154951
+ "a11y_no_noninteractive_element_interactions",
154952
+ "a11y_no_noninteractive_element_to_interactive_role",
154953
+ "a11y_no_noninteractive_tabindex",
154954
+ "a11y_no_redundant_roles",
154955
+ "a11y_no_static_element_interactions",
154956
+ "a11y_positive_tabindex",
154957
+ "a11y_role_has_required_aria_props",
154958
+ "a11y_role_supports_aria_props",
154959
+ "a11y_role_supports_aria_props_implicit",
154960
+ "a11y_unknown_aria_attribute",
154961
+ "a11y_unknown_role",
154962
+ "legacy_code",
154963
+ "unknown_code",
154964
+ "options_deprecated_accessors",
154965
+ "options_deprecated_immutable",
154966
+ "options_missing_custom_element",
154967
+ "options_removed_enable_sourcemap",
154968
+ "options_removed_hydratable",
154969
+ "options_removed_loop_guard_timeout",
154970
+ "options_renamed_ssr_dom",
154971
+ "derived_iife",
154972
+ "export_let_unused",
154973
+ "non_reactive_update",
154974
+ "perf_avoid_inline_class",
154975
+ "perf_avoid_nested_class",
154976
+ "reactive_declaration_invalid_placement",
154977
+ "reactive_declaration_module_script",
154978
+ "state_referenced_locally",
154979
+ "store_rune_conflict",
154980
+ "css_unused_selector",
154981
+ "attribute_avoid_is",
154982
+ "attribute_global_event_reference",
154983
+ "attribute_illegal_colon",
154984
+ "attribute_invalid_property_name",
154985
+ "bind_invalid_each_rest",
154986
+ "block_empty",
154987
+ "component_name_lowercase",
154988
+ "element_invalid_self_closing_tag",
154989
+ "event_directive_deprecated",
154990
+ "slot_element_deprecated",
154991
+ "svelte_element_invalid_this"
154992
+ ];
154993
+ function a11y_accesskey(node) {
154994
+ w(node, "a11y_accesskey", "Avoid using accesskey");
154714
154995
  }
154715
- function effect_invalid_placement(node) {
154716
- e3(node, "effect_invalid_placement", "`$effect()` can only be used as an expression statement");
154996
+ function a11y_aria_activedescendant_has_tabindex(node) {
154997
+ w(node, "a11y_aria_activedescendant_has_tabindex", "An element with an aria-activedescendant attribute should have a tabindex value");
154717
154998
  }
154718
- function host_invalid_placement(node) {
154719
- e3(node, "host_invalid_placement", "`$host()` can only be used inside custom element component instances");
154999
+ function a11y_aria_attributes(node, name) {
155000
+ w(node, "a11y_aria_attributes", `\`<${name}>\` should not have aria-* attributes`);
154720
155001
  }
154721
- function legacy_export_invalid(node) {
154722
- e3(node, "legacy_export_invalid", "Cannot use `export let` in runes mode \u2014 use `$props()` instead");
155002
+ function a11y_autocomplete_valid(node, value, type) {
155003
+ w(node, "a11y_autocomplete_valid", `'${value}' is an invalid value for 'autocomplete' on \`<input type="${type}">\``);
154723
155004
  }
154724
- function legacy_reactive_statement_invalid(node) {
154725
- e3(node, "legacy_reactive_statement_invalid", "`$:` is not allowed in runes mode, use `$derived` or `$effect` instead");
155005
+ function a11y_autofocus(node) {
155006
+ w(node, "a11y_autofocus", "Avoid using autofocus");
154726
155007
  }
154727
- function module_illegal_default_export(node) {
154728
- e3(node, "module_illegal_default_export", "A component cannot have a default export");
155008
+ function a11y_click_events_have_key_events(node) {
155009
+ w(node, "a11y_click_events_have_key_events", 'Visible, non-interactive elements with a click event must be accompanied by a keyboard event handler. Consider whether an interactive element such as `<button type="button">` or `<a>` might be more appropriate. See https://svelte.dev/docs/accessibility-warnings#a11y-click-events-have-key-events for more details');
154729
155010
  }
154730
- function props_duplicate(node) {
154731
- e3(node, "props_duplicate", "Cannot use `$props()` more than once");
155011
+ function a11y_distracting_elements(node, name) {
155012
+ w(node, "a11y_distracting_elements", `Avoid \`<${name}>\` elements`);
154732
155013
  }
154733
- function props_invalid_identifier(node) {
154734
- e3(node, "props_invalid_identifier", "`$props()` can only be used with an object destructuring pattern");
155014
+ function a11y_figcaption_index(node) {
155015
+ w(node, "a11y_figcaption_index", "`<figcaption>` must be first or last child of `<figure>`");
154735
155016
  }
154736
- function props_invalid_pattern(node) {
154737
- e3(node, "props_invalid_pattern", "`$props()` assignment must not contain nested properties or computed keys");
155017
+ function a11y_figcaption_parent(node) {
155018
+ w(node, "a11y_figcaption_parent", "`<figcaption>` must be an immediate child of `<figure>`");
154738
155019
  }
154739
- function props_invalid_placement(node) {
154740
- e3(node, "props_invalid_placement", "`$props()` can only be used at the top level of components as a variable declaration initializer");
155020
+ function a11y_hidden(node, name) {
155021
+ w(node, "a11y_hidden", `\`<${name}>\` element should not be hidden`);
154741
155022
  }
154742
- function rune_invalid_arguments(node, rune) {
154743
- e3(node, "rune_invalid_arguments", `\`${rune}\` cannot be called with arguments`);
155023
+ function a11y_img_redundant_alt(node) {
155024
+ w(node, "a11y_img_redundant_alt", "Screenreaders already announce `<img>` elements as an image");
154744
155025
  }
154745
- function rune_invalid_arguments_length(node, rune, args) {
154746
- e3(node, "rune_invalid_arguments_length", `\`${rune}\` must be called with ${args}`);
155026
+ function a11y_incorrect_aria_attribute_type(node, attribute, type) {
155027
+ w(node, "a11y_incorrect_aria_attribute_type", `The value of '${attribute}' must be a ${type}`);
154747
155028
  }
154748
- function rune_invalid_computed_property(node) {
154749
- e3(node, "rune_invalid_computed_property", "Cannot access a computed property of a rune");
155029
+ function a11y_incorrect_aria_attribute_type_boolean(node, attribute) {
155030
+ w(node, "a11y_incorrect_aria_attribute_type_boolean", `The value of '${attribute}' must be either 'true' or 'false'. It cannot be empty`);
154750
155031
  }
154751
- function rune_invalid_name(node, name) {
154752
- e3(node, "rune_invalid_name", `\`${name}\` is not a valid rune`);
155032
+ function a11y_incorrect_aria_attribute_type_idlist(node, attribute) {
155033
+ w(node, "a11y_incorrect_aria_attribute_type_idlist", `The value of '${attribute}' must be a space-separated list of strings that represent DOM element IDs`);
154753
155034
  }
154754
- function rune_invalid_usage(node, rune) {
154755
- e3(node, "rune_invalid_usage", `Cannot use \`${rune}\` rune in non-runes mode`);
155035
+ function a11y_incorrect_aria_attribute_type_integer(node, attribute) {
155036
+ w(node, "a11y_incorrect_aria_attribute_type_integer", `The value of '${attribute}' must be an integer`);
154756
155037
  }
154757
- function rune_missing_parentheses(node) {
154758
- e3(node, "rune_missing_parentheses", "Cannot use rune without parentheses");
155038
+ function a11y_incorrect_aria_attribute_type_token(node, attribute, values) {
155039
+ w(node, "a11y_incorrect_aria_attribute_type_token", `The value of '${attribute}' must be exactly one of ${values}`);
154759
155040
  }
154760
- function runes_mode_invalid_import(node, name) {
154761
- e3(node, "runes_mode_invalid_import", `${name} cannot be used in runes mode`);
155041
+ function a11y_incorrect_aria_attribute_type_tokenlist(node, attribute, values) {
155042
+ w(node, "a11y_incorrect_aria_attribute_type_tokenlist", `The value of '${attribute}' must be a space-separated list of one or more of ${values}`);
154762
155043
  }
154763
- function snippet_parameter_assignment(node) {
154764
- e3(node, "snippet_parameter_assignment", "Cannot reassign or bind to snippet parameter");
155044
+ function a11y_incorrect_aria_attribute_type_tristate(node, attribute) {
155045
+ w(node, "a11y_incorrect_aria_attribute_type_tristate", `The value of '${attribute}' must be exactly one of true, false, or mixed`);
154765
155046
  }
154766
- function state_invalid_export(node) {
154767
- e3(node, "state_invalid_export", "Cannot export state from a module if it is reassigned. Either export a function returning the state value or only mutate the state value's properties");
155047
+ function a11y_interactive_supports_focus(node, role) {
155048
+ w(node, "a11y_interactive_supports_focus", `Elements with the '${role}' interactive role must have a tabindex value`);
154768
155049
  }
154769
- function state_invalid_placement(node, rune) {
154770
- e3(node, "state_invalid_placement", `\`${rune}(...)\` can only be used as a variable declaration initializer or a class field`);
155050
+ function a11y_invalid_attribute(node, href_value, href_attribute) {
155051
+ w(node, "a11y_invalid_attribute", `'${href_value}' is not a valid ${href_attribute} attribute`);
154771
155052
  }
154772
- function css_empty_declaration(node) {
154773
- e3(node, "css_empty_declaration", "Declaration cannot be empty");
155053
+ function a11y_label_has_associated_control(node) {
155054
+ w(node, "a11y_label_has_associated_control", "A form label must be associated with a control");
154774
155055
  }
154775
- function css_expected_identifier(node) {
154776
- e3(node, "css_expected_identifier", "Expected a valid CSS identifier");
155056
+ function a11y_media_has_caption(node) {
155057
+ w(node, "a11y_media_has_caption", '`<video>` elements must have a `<track kind="captions">`');
154777
155058
  }
154778
- function css_global_block_invalid_combinator(node, name) {
154779
- e3(node, "css_global_block_invalid_combinator", `A :global {...} block cannot follow a ${name} combinator`);
155059
+ function a11y_misplaced_role(node, name) {
155060
+ w(node, "a11y_misplaced_role", `\`<${name}>\` should not have role attribute`);
154780
155061
  }
154781
- function css_global_block_invalid_declaration(node) {
154782
- e3(node, "css_global_block_invalid_declaration", "A :global {...} block can only contain rules, not declarations");
155062
+ function a11y_misplaced_scope(node) {
155063
+ w(node, "a11y_misplaced_scope", "The scope attribute should only be used with `<th>` elements");
154783
155064
  }
154784
- function css_global_block_invalid_list(node) {
154785
- e3(node, "css_global_block_invalid_list", "A :global {...} block cannot be part of a selector list with more than one item");
155065
+ function a11y_missing_attribute(node, name, article, sequence3) {
155066
+ w(node, "a11y_missing_attribute", `\`<${name}>\` element should have ${article} ${sequence3} attribute`);
154786
155067
  }
154787
- function css_global_block_invalid_modifier(node) {
154788
- e3(node, "css_global_block_invalid_modifier", "A :global {...} block cannot modify an existing selector");
155068
+ function a11y_missing_content(node, name) {
155069
+ w(node, "a11y_missing_content", `\`<${name}>\` element should have child content`);
154789
155070
  }
154790
- function css_global_invalid_placement(node) {
154791
- e3(node, "css_global_invalid_placement", ":global(...) can be at the start or end of a selector sequence, but not in the middle");
155071
+ function a11y_mouse_events_have_key_events(node, event, accompanied_by) {
155072
+ w(node, "a11y_mouse_events_have_key_events", `'${event}' event must be accompanied by '${accompanied_by}' event`);
154792
155073
  }
154793
- function css_global_invalid_selector(node) {
154794
- e3(node, "css_global_invalid_selector", ":global(...) must contain exactly one selector");
155074
+ function a11y_no_abstract_role(node, role) {
155075
+ w(node, "a11y_no_abstract_role", `Abstract role '${role}' is forbidden`);
154795
155076
  }
154796
- function css_global_invalid_selector_list(node) {
154797
- e3(node, "css_global_invalid_selector_list", ":global(...) must not contain type or universal selectors when used in a compound selector");
155077
+ function a11y_no_interactive_element_to_noninteractive_role(node, element, role) {
155078
+ w(node, "a11y_no_interactive_element_to_noninteractive_role", `\`<${element}>\` cannot have role '${role}'`);
154798
155079
  }
154799
- function css_nesting_selector_invalid_placement(node) {
154800
- e3(node, "css_nesting_selector_invalid_placement", "Nesting selectors can only be used inside a rule");
155080
+ function a11y_no_noninteractive_element_interactions(node, element) {
155081
+ w(node, "a11y_no_noninteractive_element_interactions", `Non-interactive element \`<${element}>\` should not be assigned mouse or keyboard event listeners`);
154801
155082
  }
154802
- function css_selector_invalid(node) {
154803
- e3(node, "css_selector_invalid", "Invalid selector");
155083
+ function a11y_no_noninteractive_element_to_interactive_role(node, element, role) {
155084
+ w(node, "a11y_no_noninteractive_element_to_interactive_role", `Non-interactive element \`<${element}>\` cannot have interactive role '${role}'`);
154804
155085
  }
154805
- function css_type_selector_invalid_placement(node) {
154806
- e3(node, "css_type_selector_invalid_placement", ":global(...) must not be followed with a type selector");
155086
+ function a11y_no_noninteractive_tabindex(node) {
155087
+ w(node, "a11y_no_noninteractive_tabindex", "noninteractive element cannot have nonnegative tabIndex value");
154807
155088
  }
154808
- function animation_duplicate(node) {
154809
- e3(node, "animation_duplicate", "An element can only have one 'animate' directive");
155089
+ function a11y_no_redundant_roles(node, role) {
155090
+ w(node, "a11y_no_redundant_roles", `Redundant role '${role}'`);
154810
155091
  }
154811
- function animation_invalid_placement(node) {
154812
- e3(node, "animation_invalid_placement", "An element that uses the `animate:` directive must be the only child of a keyed `{#each ...}` block");
155092
+ function a11y_no_static_element_interactions(node, element, handler) {
155093
+ w(node, "a11y_no_static_element_interactions", `\`<${element}>\` with a ${handler} handler must have an ARIA role`);
154813
155094
  }
154814
- function animation_missing_key(node) {
154815
- e3(node, "animation_missing_key", "An element that uses the `animate:` directive must be the only child of a keyed `{#each ...}` block. Did you forget to add a key to your each block?");
155095
+ function a11y_positive_tabindex(node) {
155096
+ w(node, "a11y_positive_tabindex", "Avoid tabindex values above zero");
154816
155097
  }
154817
- function attribute_contenteditable_dynamic(node) {
154818
- e3(node, "attribute_contenteditable_dynamic", "'contenteditable' attribute cannot be dynamic if element uses two-way binding");
155098
+ function a11y_role_has_required_aria_props(node, role, props) {
155099
+ w(node, "a11y_role_has_required_aria_props", `Elements with the ARIA role "${role}" must have the following attributes defined: ${props}`);
154819
155100
  }
154820
- function attribute_contenteditable_missing(node) {
154821
- e3(node, "attribute_contenteditable_missing", "'contenteditable' attribute is required for textContent, innerHTML and innerText two-way bindings");
155101
+ function a11y_role_supports_aria_props(node, attribute, role) {
155102
+ w(node, "a11y_role_supports_aria_props", `The attribute '${attribute}' is not supported by the role '${role}'`);
154822
155103
  }
154823
- function attribute_duplicate(node) {
154824
- e3(node, "attribute_duplicate", "Attributes need to be unique");
155104
+ function a11y_role_supports_aria_props_implicit(node, attribute, role, name) {
155105
+ w(node, "a11y_role_supports_aria_props_implicit", `The attribute '${attribute}' is not supported by the role '${role}'. This role is implicit on the element \`<${name}>\``);
154825
155106
  }
154826
- function attribute_empty_shorthand(node) {
154827
- e3(node, "attribute_empty_shorthand", "Attribute shorthand cannot be empty");
155107
+ function a11y_unknown_aria_attribute(node, attribute, suggestion) {
155108
+ w(node, "a11y_unknown_aria_attribute", suggestion ? `Unknown aria attribute 'aria-${attribute}'. Did you mean '${suggestion}'?` : `Unknown aria attribute 'aria-${attribute}'`);
154828
155109
  }
154829
- function attribute_invalid_event_handler(node) {
154830
- e3(node, "attribute_invalid_event_handler", "Event attribute must be a JavaScript expression, not a string");
155110
+ function a11y_unknown_role(node, role, suggestion) {
155111
+ w(node, "a11y_unknown_role", suggestion ? `Unknown role '${role}'. Did you mean '${suggestion}'?` : `Unknown role '${role}'`);
154831
155112
  }
154832
- function attribute_invalid_multiple(node) {
154833
- e3(node, "attribute_invalid_multiple", "'multiple' attribute must be static if select uses two-way binding");
155113
+ function legacy_code(node, code, suggestion) {
155114
+ w(node, "legacy_code", `\`${code}\` is no longer valid \u2014 please use \`${suggestion}\` instead`);
154834
155115
  }
154835
- function attribute_invalid_name(node, name) {
154836
- e3(node, "attribute_invalid_name", `'${name}' is not a valid attribute name`);
154837
- }
154838
- function attribute_invalid_sequence_expression(node) {
154839
- e3(node, "attribute_invalid_sequence_expression", "Sequence expressions are not allowed as attribute/directive values in runes mode, unless wrapped in parentheses");
154840
- }
154841
- function attribute_invalid_type(node) {
154842
- e3(node, "attribute_invalid_type", "'type' attribute must be a static text value if input uses two-way binding");
154843
- }
154844
- function bind_invalid_expression(node) {
154845
- e3(node, "bind_invalid_expression", "Can only bind to an Identifier or MemberExpression");
154846
- }
154847
- function bind_invalid_name(node, name, explanation) {
154848
- e3(node, "bind_invalid_name", explanation ? `\`bind:${name}\` is not a valid binding. ${explanation}` : `\`bind:${name}\` is not a valid binding`);
154849
- }
154850
- function bind_invalid_target(node, name, elements) {
154851
- e3(node, "bind_invalid_target", `\`bind:${name}\` can only be used with ${elements}`);
154852
- }
154853
- function bind_invalid_value(node) {
154854
- e3(node, "bind_invalid_value", "Can only bind to state or props");
154855
- }
154856
- function block_duplicate_clause(node, name) {
154857
- e3(node, "block_duplicate_clause", `${name} cannot appear more than once within a block`);
154858
- }
154859
- function block_invalid_continuation_placement(node) {
154860
- e3(node, "block_invalid_continuation_placement", "{:...} block is invalid at this position (did you forget to close the preceeding element or block?)");
154861
- }
154862
- function block_invalid_elseif(node) {
154863
- e3(node, "block_invalid_elseif", "'elseif' should be 'else if'");
154864
- }
154865
- function block_invalid_placement(node, name, location) {
154866
- e3(node, "block_invalid_placement", `{#${name} ...} block cannot be ${location}`);
154867
- }
154868
- function block_unclosed(node) {
154869
- e3(node, "block_unclosed", "Block was left open");
154870
- }
154871
- function block_unexpected_close(node) {
154872
- e3(node, "block_unexpected_close", "Unexpected block closing tag");
154873
- }
154874
- function component_invalid_directive(node) {
154875
- e3(node, "component_invalid_directive", "This type of directive is not valid on components");
154876
- }
154877
- function const_tag_invalid_expression(node) {
154878
- e3(node, "const_tag_invalid_expression", "{@const ...} must consist of a single variable declaration");
154879
- }
154880
- function const_tag_invalid_placement(node) {
154881
- e3(node, "const_tag_invalid_placement", "`{@const}` must be the immediate child of `{#snippet}`, `{#if}`, `{:else if}`, `{:else}`, `{#each}`, `{:then}`, `{:catch}`, `<svelte:fragment>` or `<Component>`");
154882
- }
154883
- function debug_tag_invalid_arguments(node) {
154884
- e3(node, "debug_tag_invalid_arguments", "{@debug ...} arguments must be identifiers, not arbitrary expressions");
154885
- }
154886
- function directive_invalid_value(node) {
154887
- e3(node, "directive_invalid_value", "Directive value must be a JavaScript expression enclosed in curly braces");
154888
- }
154889
- function directive_missing_name(node, type) {
154890
- e3(node, "directive_missing_name", `\`${type}\` name cannot be empty`);
154891
- }
154892
- function element_invalid_closing_tag(node, name) {
154893
- e3(node, "element_invalid_closing_tag", `\`</${name}>\` attempted to close an element that was not open`);
154894
- }
154895
- function element_invalid_closing_tag_autoclosed(node, name, reason) {
154896
- e3(node, "element_invalid_closing_tag_autoclosed", `\`</${name}>\` attempted to close element that was already automatically closed by \`<${reason}>\` (cannot nest \`<${reason}>\` inside \`<${name}>\`)`);
154897
- }
154898
- function element_invalid_tag_name(node) {
154899
- e3(node, "element_invalid_tag_name", "Expected valid tag name");
154900
- }
154901
- function element_unclosed(node, name) {
154902
- e3(node, "element_unclosed", `\`<${name}>\` was left open`);
154903
- }
154904
- function event_handler_invalid_component_modifier(node) {
154905
- e3(node, "event_handler_invalid_component_modifier", "Event modifiers other than 'once' can only be used on DOM elements");
154906
- }
154907
- function event_handler_invalid_modifier(node, list3) {
154908
- e3(node, "event_handler_invalid_modifier", `Valid event modifiers are ${list3}`);
154909
- }
154910
- function event_handler_invalid_modifier_combination(node, modifier1, modifier2) {
154911
- e3(node, "event_handler_invalid_modifier_combination", `The '${modifier1}' and '${modifier2}' modifiers cannot be used together`);
154912
- }
154913
- function expected_attribute_value(node) {
154914
- e3(node, "expected_attribute_value", "Expected attribute value");
154915
- }
154916
- function expected_block_type(node) {
154917
- e3(node, "expected_block_type", "Expected 'if', 'each', 'await', 'key' or 'snippet'");
154918
- }
154919
- function expected_identifier(node) {
154920
- e3(node, "expected_identifier", "Expected an identifier");
154921
- }
154922
- function expected_pattern(node) {
154923
- e3(node, "expected_pattern", "Expected identifier or destructure pattern");
154924
- }
154925
- function expected_token(node, token) {
154926
- e3(node, "expected_token", `Expected token ${token}`);
154927
- }
154928
- function expected_whitespace(node) {
154929
- e3(node, "expected_whitespace", "Expected whitespace");
155116
+ function unknown_code(node, code, suggestion) {
155117
+ w(node, "unknown_code", suggestion ? `\`${code}\` is not a recognised code (did you mean \`${suggestion}\`?)` : `\`${code}\` is not a recognised code`);
154930
155118
  }
154931
- function js_parse_error(node, message) {
154932
- e3(node, "js_parse_error", `${message}`);
155119
+ function options_deprecated_accessors(node) {
155120
+ w(node, "options_deprecated_accessors", "The `accessors` option has been deprecated. It will have no effect in runes mode");
154933
155121
  }
154934
- function let_directive_invalid_placement(node) {
154935
- e3(node, "let_directive_invalid_placement", "`let:` directive at invalid position");
155122
+ function options_deprecated_immutable(node) {
155123
+ w(node, "options_deprecated_immutable", "The `immutable` option has been deprecated. It will have no effect in runes mode");
154936
155124
  }
154937
- function node_invalid_placement(node, thing, parent2) {
154938
- e3(node, "node_invalid_placement", `${thing} is invalid inside <${parent2}>`);
155125
+ function options_removed_enable_sourcemap(node) {
155126
+ w(node, "options_removed_enable_sourcemap", "The `enableSourcemap` option has been removed. Source maps are always generated now, and tooling can choose to ignore them");
154939
155127
  }
154940
- function render_tag_invalid_call_expression(node) {
154941
- e3(node, "render_tag_invalid_call_expression", "Calling a snippet function using apply, bind or call is not allowed");
155128
+ function options_removed_hydratable(node) {
155129
+ w(node, "options_removed_hydratable", "The `hydratable` option has been removed. Svelte components are always hydratable now");
154942
155130
  }
154943
- function render_tag_invalid_expression(node) {
154944
- e3(node, "render_tag_invalid_expression", "`{@render ...}` tags can only contain call expressions");
155131
+ function options_removed_loop_guard_timeout(node) {
155132
+ w(node, "options_removed_loop_guard_timeout", "The `loopGuardTimeout` option has been removed");
154945
155133
  }
154946
- function render_tag_invalid_spread_argument(node) {
154947
- e3(node, "render_tag_invalid_spread_argument", "cannot use spread arguments in `{@render ...}` tags");
155134
+ function options_renamed_ssr_dom(node) {
155135
+ w(node, "options_renamed_ssr_dom", '`generate: "dom"` and `generate: "ssr"` options have been renamed to "client" and "server" respectively');
154948
155136
  }
154949
- function script_duplicate(node) {
154950
- e3(node, "script_duplicate", 'A component can have a single top-level `<script>` element and/or a single top-level `<script context="module">` element');
155137
+ function derived_iife(node) {
155138
+ w(node, "derived_iife", "Use `$derived.by(() => {...})` instead of `$derived((() => {...})())`");
154951
155139
  }
154952
- function script_invalid_context(node) {
154953
- e3(node, "script_invalid_context", 'If the context attribute is supplied, its value must be "module"');
155140
+ function perf_avoid_inline_class(node) {
155141
+ w(node, "perf_avoid_inline_class", "Avoid 'new class' \u2014 instead, declare the class at the top level scope");
154954
155142
  }
154955
- function slot_attribute_duplicate(node, name, component) {
154956
- e3(node, "slot_attribute_duplicate", `Duplicate slot name '${name}' in <${component}>`);
155143
+ function perf_avoid_nested_class(node) {
155144
+ w(node, "perf_avoid_nested_class", "Avoid declaring classes below the top level scope");
154957
155145
  }
154958
- function slot_attribute_invalid(node) {
154959
- e3(node, "slot_attribute_invalid", "slot attribute must be a static value");
155146
+ function reactive_declaration_invalid_placement(node) {
155147
+ w(node, "reactive_declaration_invalid_placement", "Reactive declarations only exist at the top level of the instance script");
154960
155148
  }
154961
- function slot_attribute_invalid_placement(node) {
154962
- e3(node, "slot_attribute_invalid_placement", "Element with a slot='...' attribute must be a child of a component or a descendant of a custom element");
155149
+ function attribute_avoid_is(node) {
155150
+ w(node, "attribute_avoid_is", 'The "is" attribute is not supported cross-browser and should be avoided');
154963
155151
  }
154964
- function slot_default_duplicate(node) {
154965
- e3(node, "slot_default_duplicate", 'Found default slot content alongside an explicit slot="default"');
155152
+ function attribute_global_event_reference(node, name) {
155153
+ w(node, "attribute_global_event_reference", `You are referencing \`globalThis.${name}\`. Did you forget to declare a variable with that name?`);
154966
155154
  }
154967
- function slot_element_invalid_attribute(node) {
154968
- e3(node, "slot_element_invalid_attribute", "`<slot>` can only receive attributes and (optionally) let directives");
155155
+ function attribute_illegal_colon(node) {
155156
+ w(node, "attribute_illegal_colon", "Attributes should not contain ':' characters to prevent ambiguity with Svelte directives");
154969
155157
  }
154970
- function slot_element_invalid_name(node) {
154971
- e3(node, "slot_element_invalid_name", "slot attribute must be a static value");
155158
+ function attribute_invalid_property_name(node, wrong, right) {
155159
+ w(node, "attribute_invalid_property_name", `'${wrong}' is not a valid HTML attribute. Did you mean '${right}'?`);
154972
155160
  }
154973
- function slot_element_invalid_name_default(node) {
154974
- e3(node, "slot_element_invalid_name_default", "`default` is a reserved word \u2014 it cannot be used as a slot name");
155161
+ function bind_invalid_each_rest(node, name) {
155162
+ w(node, "bind_invalid_each_rest", `The rest operator (...) will create a new object and binding '${name}' with the original object will not work`);
154975
155163
  }
154976
- function snippet_conflict(node) {
154977
- e3(node, "snippet_conflict", "Cannot use explicit children snippet at the same time as implicit children content. Remove either the non-whitespace content or the children snippet block");
155164
+ function block_empty(node) {
155165
+ w(node, "block_empty", "Empty block");
154978
155166
  }
154979
- function style_directive_invalid_modifier(node) {
154980
- e3(node, "style_directive_invalid_modifier", "`style:` directive can only use the `important` modifier");
155167
+ function component_name_lowercase(node, name) {
155168
+ w(node, "component_name_lowercase", `\`<${name}>\` will be treated as an HTML element unless it begins with a capital letter`);
154981
155169
  }
154982
- function style_duplicate(node) {
154983
- e3(node, "style_duplicate", "A component can have a single top-level `<style>` element");
155170
+ function element_invalid_self_closing_tag(node, name) {
155171
+ w(node, "element_invalid_self_closing_tag", `Self-closing HTML tags for non-void elements are ambiguous \u2014 use \`<${name} ...></${name}>\` rather than \`<${name} ... />\``);
154984
155172
  }
154985
- function svelte_component_invalid_this(node) {
154986
- e3(node, "svelte_component_invalid_this", "Invalid component definition \u2014 must be an `{expression}`");
155173
+ function event_directive_deprecated(node, name) {
155174
+ w(node, "event_directive_deprecated", `Using \`on:${name}\` to listen to the ${name} event is deprecated. Use the event attribute \`on${name}\` instead`);
154987
155175
  }
154988
- function svelte_component_missing_this(node) {
154989
- e3(node, "svelte_component_missing_this", "`<svelte:component>` must have a 'this' attribute");
155176
+ function slot_element_deprecated(node) {
155177
+ w(node, "slot_element_deprecated", "Using `<slot>` to render parent content is deprecated. Use `{@render ...}` tags instead");
154990
155178
  }
154991
155179
  function svelte_element_invalid_this(node) {
154992
- e3(node, "svelte_element_invalid_this", "Invalid element definition \u2014 must be an `{expression}`");
154993
- }
154994
- function svelte_element_missing_this(node) {
154995
- e3(node, "svelte_element_missing_this", "`<svelte:element>` must have a 'this' attribute");
154996
- }
154997
- function svelte_fragment_invalid_attribute(node) {
154998
- e3(node, "svelte_fragment_invalid_attribute", "`<svelte:fragment>` can only have a slot attribute and (optionally) a let: directive");
154999
- }
155000
- function svelte_fragment_invalid_placement(node) {
155001
- e3(node, "svelte_fragment_invalid_placement", "`<svelte:fragment>` must be the direct child of a component");
155002
- }
155003
- function svelte_head_illegal_attribute(node) {
155004
- e3(node, "svelte_head_illegal_attribute", "`<svelte:head>` cannot have attributes nor directives");
155005
- }
155006
- function svelte_meta_duplicate(node, name) {
155007
- e3(node, "svelte_meta_duplicate", `A component can only have one \`<${name}>\` element`);
155008
- }
155009
- function svelte_meta_invalid_content(node, name) {
155010
- e3(node, "svelte_meta_invalid_content", `<${name}> cannot have children`);
155180
+ w(node, "svelte_element_invalid_this", "`this` should be an `{expression}`. Using a string attribute value will cause an error in future versions of Svelte");
155011
155181
  }
155012
- function svelte_meta_invalid_placement(node, name) {
155013
- e3(node, "svelte_meta_invalid_placement", `\`<${name}>\` tags cannot be inside elements or blocks`);
155014
- }
155015
- function svelte_meta_invalid_tag(node, list3) {
155016
- e3(node, "svelte_meta_invalid_tag", `Valid \`<svelte:...>\` tag names are ${list3}`);
155182
+
155183
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/utils/extract_svelte_ignore.js
155184
+ var regex_svelte_ignore = /^\s*svelte-ignore\s/;
155185
+ var replacements = {
155186
+ "non-top-level-reactive-declaration": "reactive_declaration_invalid_placement",
155187
+ "module-script-reactive-declaration": "reactive_declaration_module_script",
155188
+ "empty-block": "block_empty",
155189
+ "avoid-is": "attribute_avoid_is",
155190
+ "invalid-html-attribute": "attribute_invalid_property_name",
155191
+ "a11y-structure": "a11y_figcaption_parent",
155192
+ "illegal-attribute-character": "attribute_illegal_colon",
155193
+ "invalid-rest-eachblock-binding": "bind_invalid_each_rest"
155194
+ };
155195
+ function extract_svelte_ignore(offset2, text2, runes) {
155196
+ const match = regex_svelte_ignore.exec(text2);
155197
+ if (!match)
155198
+ return [];
155199
+ let length = match[0].length;
155200
+ offset2 += length;
155201
+ const ignores = [];
155202
+ if (runes) {
155203
+ for (const match2 of text2.slice(length).matchAll(/([\w$-]+)(,)?/gm)) {
155204
+ const code = match2[1];
155205
+ if (codes.includes(code)) {
155206
+ ignores.push(code);
155207
+ } else {
155208
+ const replacement = replacements[code] ?? code.replace(/-/g, "_");
155209
+ const start = offset2 + match2.index;
155210
+ const end = start + code.length;
155211
+ if (codes.includes(replacement)) {
155212
+ legacy_code({ start, end }, code, replacement);
155213
+ } else {
155214
+ const suggestion = fuzzymatch(code, codes);
155215
+ unknown_code({ start, end }, code, suggestion);
155216
+ }
155217
+ }
155218
+ if (!match2[2]) {
155219
+ break;
155220
+ }
155221
+ }
155222
+ } else {
155223
+ for (const match2 of text2.slice(length).matchAll(/[\w$-]+/gm)) {
155224
+ const code = match2[0];
155225
+ ignores.push(code);
155226
+ if (!codes.includes(code)) {
155227
+ const replacement = replacements[code] ?? code.replace(/-/g, "_");
155228
+ if (codes.includes(replacement)) {
155229
+ ignores.push(replacement);
155230
+ }
155231
+ }
155232
+ }
155233
+ }
155234
+ return ignores;
155017
155235
  }
155018
- function svelte_options_deprecated_tag(node) {
155019
- e3(node, "svelte_options_deprecated_tag", '"tag" option is deprecated \u2014 use "customElement" instead');
155236
+
155237
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/legacy.js
155238
+ function remove_surrounding_whitespace_nodes(nodes) {
155239
+ const first = nodes.at(0);
155240
+ const last = nodes.at(-1);
155241
+ if (first?.type === "Text") {
155242
+ if (!regex_not_whitespace.test(first.data)) {
155243
+ nodes.shift();
155244
+ } else {
155245
+ first.data = first.data.replace(regex_starts_with_whitespaces, "");
155246
+ }
155247
+ }
155248
+ if (last?.type === "Text") {
155249
+ if (!regex_not_whitespace.test(last.data)) {
155250
+ nodes.pop();
155251
+ } else {
155252
+ last.data = last.data.replace(regex_ends_with_whitespaces, "");
155253
+ }
155254
+ }
155020
155255
  }
155021
- function svelte_options_invalid_attribute(node) {
155022
- e3(node, "svelte_options_invalid_attribute", "`<svelte:options>` can only receive static attributes");
155023
- }
155024
- function svelte_options_invalid_attribute_value(node, list3) {
155025
- e3(node, "svelte_options_invalid_attribute_value", `Valid values are ${list3}`);
155026
- }
155027
- function svelte_options_invalid_customelement(node) {
155028
- e3(node, "svelte_options_invalid_customelement", '"customElement" must be a string literal defining a valid custom element name or an object of the form { tag: string; shadow?: "open" | "none"; props?: { [key: string]: { attribute?: string; reflect?: boolean; type: .. } } }');
155029
- }
155030
- function svelte_options_invalid_customelement_props(node) {
155031
- e3(node, "svelte_options_invalid_customelement_props", '"props" must be a statically analyzable object literal of the form "{ [key: string]: { attribute?: string; reflect?: boolean; type?: "String" | "Boolean" | "Number" | "Array" | "Object" }"');
155032
- }
155033
- function svelte_options_invalid_customelement_shadow(node) {
155034
- e3(node, "svelte_options_invalid_customelement_shadow", '"shadow" must be either "open" or "none"');
155035
- }
155036
- function svelte_options_invalid_tagname(node) {
155037
- e3(node, "svelte_options_invalid_tagname", 'Tag name must be two or more words joined by the "-" character');
155038
- }
155039
- function svelte_options_unknown_attribute(node, name) {
155040
- e3(node, "svelte_options_unknown_attribute", `\`<svelte:options>\` unknown attribute '${name}'`);
155041
- }
155042
- function svelte_self_invalid_placement(node) {
155043
- e3(node, "svelte_self_invalid_placement", "`<svelte:self>` components can only exist inside `{#if}` blocks, `{#each}` blocks, `{#snippet}` blocks or slots passed to components");
155044
- }
155045
- function tag_invalid_placement(node, name, location) {
155046
- e3(node, "tag_invalid_placement", `{@${name} ...} tag cannot be ${location}`);
155047
- }
155048
- function textarea_invalid_content(node) {
155049
- e3(node, "textarea_invalid_content", "A `<textarea>` can have either a value attribute or (equivalently) child content, but not both");
155050
- }
155051
- function title_illegal_attribute(node) {
155052
- e3(node, "title_illegal_attribute", "`<title>` cannot have attributes nor directives");
155053
- }
155054
- function title_invalid_content(node) {
155055
- e3(node, "title_invalid_content", "`<title>` can only contain text and {tags}");
155056
- }
155057
- function transition_conflict(node, type, existing) {
155058
- e3(node, "transition_conflict", `Cannot use \`${type}:\` alongside existing \`${existing}:\` directive`);
155059
- }
155060
- function transition_duplicate(node, type) {
155061
- e3(node, "transition_duplicate", `Cannot use multiple \`${type}:\` directives on a single element`);
155062
- }
155063
- function unexpected_eof(node) {
155064
- e3(node, "unexpected_eof", "Unexpected end of input");
155065
- }
155066
- function unexpected_reserved_word(node, word) {
155067
- e3(node, "unexpected_reserved_word", `'${word}' is a reserved word in JavaScript and cannot be used here`);
155068
- }
155069
- function void_element_invalid_content(node) {
155070
- e3(node, "void_element_invalid_content", "Void elements cannot have children or closing tags");
155071
- }
155072
-
155073
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/patterns.js
155074
- var regex_whitespace = /\s/;
155075
- var regex_whitespaces = /\s+/;
155076
- var regex_starts_with_newline = /^\r?\n/;
155077
- var regex_starts_with_whitespaces = /^[ \t\r\n]+/;
155078
- var regex_ends_with_whitespaces = /[ \t\r\n]+$/;
155079
- var regex_not_whitespace = /[^ \t\r\n]/;
155080
- var regex_whitespaces_strict = /[ \t\n\r\f]+/g;
155081
- var regex_only_whitespaces = /^[ \t\n\r\f]+$/;
155082
- var regex_not_newline_characters = /[^\n]/g;
155083
- var regex_is_valid_identifier = /^[a-zA-Z_$][a-zA-Z_$0-9]*$/;
155084
- var regex_invalid_identifier_chars = /(^[^a-zA-Z_$]|[^a-zA-Z0-9_$])/g;
155085
- var regex_starts_with_vowel = /^[aeiou]/;
155086
- var regex_heading_tags = /^h[1-6]$/;
155087
- var regex_illegal_attribute_character = /(^[0-9-.])|[\^$@%&#?!|()[\]{}^*+~;]/;
155088
-
155089
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/1-parse/utils/fuzzymatch.js
155090
- function fuzzymatch(name, names) {
155091
- if (names.length === 0)
155092
- return null;
155093
- const set2 = new FuzzySet(names);
155094
- const matches = set2.get(name);
155095
- return matches && matches[0][0] > 0.7 ? matches[0][1] : null;
155096
- }
155097
- var GRAM_SIZE_LOWER = 2;
155098
- var GRAM_SIZE_UPPER = 3;
155099
- function _distance(str1, str2) {
155100
- if (str1 === null && str2 === null) {
155101
- throw "Trying to compare two null values";
155102
- }
155103
- if (str1 === null || str2 === null)
155104
- return 0;
155105
- str1 = String(str1);
155106
- str2 = String(str2);
155107
- const distance = levenshtein(str1, str2);
155108
- return 1 - distance / Math.max(str1.length, str2.length);
155109
- }
155110
- function levenshtein(str1, str2) {
155111
- const current2 = [];
155112
- let prev = 0;
155113
- let value = 0;
155114
- for (let i3 = 0; i3 <= str2.length; i3++) {
155115
- for (let j = 0; j <= str1.length; j++) {
155116
- if (i3 && j) {
155117
- if (str1.charAt(j - 1) === str2.charAt(i3 - 1)) {
155118
- value = prev;
155119
- } else {
155120
- value = Math.min(current2[j], current2[j - 1], prev) + 1;
155256
+ function convert(source, ast) {
155257
+ const root = ast;
155258
+ return walk2(root, null, {
155259
+ _(node, { next: next2 }) {
155260
+ delete node.parent;
155261
+ delete node.metadata;
155262
+ next2();
155263
+ },
155264
+ Root(node, { visit: visit24 }) {
155265
+ const { instance, module: module2, options } = node;
155266
+ if (options?.__raw__) {
155267
+ let idx = node.fragment.nodes.findIndex((node2) => options.end <= node2.start);
155268
+ if (idx === -1) {
155269
+ idx = node.fragment.nodes.length;
155121
155270
  }
155122
- } else {
155123
- value = i3 + j;
155271
+ delete options.__raw__.parent;
155272
+ node.fragment.nodes.splice(idx, 0, options.__raw__);
155124
155273
  }
155125
- prev = current2[j];
155126
- current2[j] = value;
155127
- }
155128
- }
155129
- return current2.pop();
155130
- }
155131
- var non_word_regex = /[^\w, ]+/;
155132
- function iterate_grams(value, gram_size = 2) {
155133
- const simplified = "-" + value.toLowerCase().replace(non_word_regex, "") + "-";
155134
- const len_diff = gram_size - simplified.length;
155135
- const results = [];
155136
- if (len_diff > 0) {
155137
- for (let i3 = 0; i3 < len_diff; ++i3) {
155138
- value += "-";
155139
- }
155140
- }
155141
- for (let i3 = 0; i3 < simplified.length - gram_size + 1; ++i3) {
155142
- results.push(simplified.slice(i3, i3 + gram_size));
155143
- }
155144
- return results;
155145
- }
155146
- function gram_counter(value, gram_size = 2) {
155147
- const result = {};
155148
- const grams = iterate_grams(value, gram_size);
155149
- let i3 = 0;
155150
- for (i3; i3 < grams.length; ++i3) {
155151
- if (grams[i3] in result) {
155152
- result[grams[i3]] += 1;
155153
- } else {
155154
- result[grams[i3]] = 1;
155155
- }
155156
- }
155157
- return result;
155158
- }
155159
- function sort_descending(a2, b2) {
155160
- return b2[0] - a2[0];
155161
- }
155162
- var FuzzySet = class {
155163
- exact_set = {};
155164
- match_dict = {};
155165
- items = {};
155166
- constructor(arr) {
155167
- for (let i3 = GRAM_SIZE_LOWER; i3 < GRAM_SIZE_UPPER + 1; ++i3) {
155168
- this.items[i3] = [];
155169
- }
155170
- for (let i3 = 0; i3 < arr.length; ++i3) {
155171
- this.add(arr[i3]);
155172
- }
155173
- }
155174
- add(value) {
155175
- const normalized_value = value.toLowerCase();
155176
- if (normalized_value in this.exact_set) {
155177
- return false;
155178
- }
155179
- let i3 = GRAM_SIZE_LOWER;
155180
- for (i3; i3 < GRAM_SIZE_UPPER + 1; ++i3) {
155181
- this._add(value, i3);
155182
- }
155183
- }
155184
- _add(value, gram_size) {
155185
- const normalized_value = value.toLowerCase();
155186
- const items = this.items[gram_size] || [];
155187
- const index = items.length;
155188
- items.push(0);
155189
- const gram_counts = gram_counter(normalized_value, gram_size);
155190
- let sum_of_square_gram_counts = 0;
155191
- let gram;
155192
- let gram_count;
155193
- for (gram in gram_counts) {
155194
- gram_count = gram_counts[gram];
155195
- sum_of_square_gram_counts += Math.pow(gram_count, 2);
155196
- if (gram in this.match_dict) {
155197
- this.match_dict[gram].push([index, gram_count]);
155198
- } else {
155199
- this.match_dict[gram] = [[index, gram_count]];
155274
+ let start = null;
155275
+ let end = null;
155276
+ if (node.fragment.nodes.length > 0) {
155277
+ const first = node.fragment.nodes.at(0);
155278
+ const last = node.fragment.nodes.at(-1);
155279
+ start = first.start;
155280
+ end = last.end;
155281
+ while (/\s/.test(source[start]))
155282
+ start += 1;
155283
+ while (/\s/.test(source[end - 1]))
155284
+ end -= 1;
155200
155285
  }
155201
- }
155202
- const vector_normal = Math.sqrt(sum_of_square_gram_counts);
155203
- items[index] = [vector_normal, normalized_value];
155204
- this.items[gram_size] = items;
155205
- this.exact_set[normalized_value] = value;
155206
- }
155207
- get(value) {
155208
- const normalized_value = value.toLowerCase();
155209
- const result = this.exact_set[normalized_value];
155210
- if (result) {
155211
- return [[1, result]];
155212
- }
155213
- for (let gram_size = GRAM_SIZE_UPPER; gram_size >= GRAM_SIZE_LOWER; --gram_size) {
155214
- const results = this.__get(value, gram_size);
155215
- if (results.length > 0)
155216
- return results;
155217
- }
155218
- return null;
155219
- }
155220
- __get(value, gram_size) {
155221
- const normalized_value = value.toLowerCase();
155222
- const matches = {};
155223
- const gram_counts = gram_counter(normalized_value, gram_size);
155224
- const items = this.items[gram_size];
155225
- let sum_of_square_gram_counts = 0;
155226
- let gram;
155227
- let gram_count;
155228
- let i3;
155229
- let index;
155230
- let other_gram_count;
155231
- for (gram in gram_counts) {
155232
- gram_count = gram_counts[gram];
155233
- sum_of_square_gram_counts += Math.pow(gram_count, 2);
155234
- if (gram in this.match_dict) {
155235
- for (i3 = 0; i3 < this.match_dict[gram].length; ++i3) {
155236
- index = this.match_dict[gram][i3][0];
155237
- other_gram_count = this.match_dict[gram][i3][1];
155238
- if (index in matches) {
155239
- matches[index] += gram_count * other_gram_count;
155240
- } else {
155241
- matches[index] = gram_count * other_gram_count;
155242
- }
155243
- }
155286
+ if (instance) {
155287
+ delete instance.parent;
155288
+ delete instance.attributes;
155244
155289
  }
155245
- }
155246
- const vector_normal = Math.sqrt(sum_of_square_gram_counts);
155247
- let results = [];
155248
- let match_score;
155249
- for (const match_index in matches) {
155250
- match_score = matches[match_index];
155251
- results.push([match_score / (vector_normal * items[match_index][0]), items[match_index][1]]);
155252
- }
155253
- results.sort(sort_descending);
155254
- let new_results = [];
155255
- const end_index = Math.min(50, results.length);
155256
- for (let i4 = 0; i4 < end_index; ++i4) {
155257
- new_results.push([_distance(results[i4][1], normalized_value), results[i4][1]]);
155258
- }
155259
- results = new_results;
155260
- results.sort(sort_descending);
155261
- new_results = [];
155262
- for (let i4 = 0; i4 < results.length; ++i4) {
155263
- if (results[i4][0] === results[0][0]) {
155264
- new_results.push([results[i4][0], this.exact_set[results[i4][1]]]);
155290
+ if (module2) {
155291
+ delete module2.parent;
155292
+ delete module2.attributes;
155265
155293
  }
155266
- }
155267
- return new_results;
155268
- }
155269
- };
155270
-
155271
- // ../../node_modules/.pnpm/locate-character@3.0.0/node_modules/locate-character/src/index.js
155272
- function rangeContains(range, index) {
155273
- return range.start <= index && index < range.end;
155274
- }
155275
- function getLocator(source, options = {}) {
155276
- const { offsetLine = 0, offsetColumn = 0 } = options;
155277
- let start = 0;
155278
- const ranges = source.split("\n").map((line, i4) => {
155279
- const end = start + line.length + 1;
155280
- const range = { start, end, line: i4 };
155281
- start = end;
155282
- return range;
155283
- });
155284
- let i3 = 0;
155285
- function locator2(search, index) {
155286
- if (typeof search === "string") {
155287
- search = source.indexOf(search, index ?? 0);
155288
- }
155289
- if (search === -1)
155290
- return void 0;
155291
- let range = ranges[i3];
155292
- const d2 = search >= range.end ? 1 : -1;
155293
- while (range) {
155294
- if (rangeContains(range, search)) {
155295
- return {
155296
- line: offsetLine + range.line,
155297
- column: offsetColumn + search - range.start,
155298
- character: search
155299
- };
155300
- }
155301
- i3 += d2;
155302
- range = ranges[i3];
155303
- }
155304
- }
155305
- return locator2;
155306
- }
155307
-
155308
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/state.js
155309
- var warnings = [];
155310
- var filename;
155311
- var locator = getLocator("", { offsetLine: 1 });
155312
- var ignore_stack = [];
155313
- function reset3(options) {
155314
- filename = options.filename;
155315
- locator = getLocator(options.source, { offsetLine: 1 });
155316
- warnings = [];
155317
- ignore_stack = [];
155318
- }
155319
-
155320
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/warnings.js
155321
- function w(node, code, message) {
155322
- if (ignore_stack.at(-1)?.has(code))
155323
- return;
155324
- warnings.push({
155325
- code,
155326
- message,
155327
- filename,
155328
- start: node?.start !== void 0 ? locator(node.start) : void 0,
155329
- end: node?.end !== void 0 ? locator(node.end) : void 0
155330
- });
155331
- }
155332
- var codes = [
155333
- "a11y_accesskey",
155334
- "a11y_aria_activedescendant_has_tabindex",
155335
- "a11y_aria_attributes",
155336
- "a11y_autocomplete_valid",
155337
- "a11y_autofocus",
155338
- "a11y_click_events_have_key_events",
155339
- "a11y_distracting_elements",
155340
- "a11y_figcaption_index",
155341
- "a11y_figcaption_parent",
155342
- "a11y_hidden",
155343
- "a11y_img_redundant_alt",
155344
- "a11y_incorrect_aria_attribute_type",
155345
- "a11y_incorrect_aria_attribute_type_boolean",
155346
- "a11y_incorrect_aria_attribute_type_id",
155347
- "a11y_incorrect_aria_attribute_type_idlist",
155348
- "a11y_incorrect_aria_attribute_type_integer",
155349
- "a11y_incorrect_aria_attribute_type_token",
155350
- "a11y_incorrect_aria_attribute_type_tokenlist",
155351
- "a11y_incorrect_aria_attribute_type_tristate",
155352
- "a11y_interactive_supports_focus",
155353
- "a11y_invalid_attribute",
155354
- "a11y_label_has_associated_control",
155355
- "a11y_media_has_caption",
155356
- "a11y_misplaced_role",
155357
- "a11y_misplaced_scope",
155358
- "a11y_missing_attribute",
155359
- "a11y_missing_content",
155360
- "a11y_mouse_events_have_key_events",
155361
- "a11y_no_abstract_role",
155362
- "a11y_no_interactive_element_to_noninteractive_role",
155363
- "a11y_no_noninteractive_element_interactions",
155364
- "a11y_no_noninteractive_element_to_interactive_role",
155365
- "a11y_no_noninteractive_tabindex",
155366
- "a11y_no_redundant_roles",
155367
- "a11y_no_static_element_interactions",
155368
- "a11y_positive_tabindex",
155369
- "a11y_role_has_required_aria_props",
155370
- "a11y_role_supports_aria_props",
155371
- "a11y_role_supports_aria_props_implicit",
155372
- "a11y_unknown_aria_attribute",
155373
- "a11y_unknown_role",
155374
- "legacy_code",
155375
- "unknown_code",
155376
- "options_deprecated_accessors",
155377
- "options_deprecated_immutable",
155378
- "options_missing_custom_element",
155379
- "options_removed_enable_sourcemap",
155380
- "options_removed_hydratable",
155381
- "options_removed_loop_guard_timeout",
155382
- "options_renamed_ssr_dom",
155383
- "derived_iife",
155384
- "export_let_unused",
155385
- "non_reactive_update",
155386
- "perf_avoid_inline_class",
155387
- "perf_avoid_nested_class",
155388
- "reactive_declaration_invalid_placement",
155389
- "reactive_declaration_module_script",
155390
- "state_referenced_locally",
155391
- "store_rune_conflict",
155392
- "css_unused_selector",
155393
- "attribute_avoid_is",
155394
- "attribute_global_event_reference",
155395
- "attribute_illegal_colon",
155396
- "attribute_invalid_property_name",
155397
- "bind_invalid_each_rest",
155398
- "block_empty",
155399
- "component_name_lowercase",
155400
- "element_invalid_self_closing_tag",
155401
- "event_directive_deprecated",
155402
- "slot_element_deprecated"
155403
- ];
155404
- function a11y_accesskey(node) {
155405
- w(node, "a11y_accesskey", "Avoid using accesskey");
155406
- }
155407
- function a11y_aria_activedescendant_has_tabindex(node) {
155408
- w(node, "a11y_aria_activedescendant_has_tabindex", "An element with an aria-activedescendant attribute should have a tabindex value");
155409
- }
155410
- function a11y_aria_attributes(node, name) {
155411
- w(node, "a11y_aria_attributes", `\`<${name}>\` should not have aria-* attributes`);
155412
- }
155413
- function a11y_autocomplete_valid(node, value, type) {
155414
- w(node, "a11y_autocomplete_valid", `'${value}' is an invalid value for 'autocomplete' on \`<input type="${type}">\``);
155415
- }
155416
- function a11y_autofocus(node) {
155417
- w(node, "a11y_autofocus", "Avoid using autofocus");
155418
- }
155419
- function a11y_click_events_have_key_events(node) {
155420
- w(node, "a11y_click_events_have_key_events", 'Visible, non-interactive elements with a click event must be accompanied by a keyboard event handler. Consider whether an interactive element such as `<button type="button">` or `<a>` might be more appropriate. See https://svelte.dev/docs/accessibility-warnings#a11y-click-events-have-key-events for more details.');
155421
- }
155422
- function a11y_distracting_elements(node, name) {
155423
- w(node, "a11y_distracting_elements", `Avoid \`<${name}>\` elements`);
155424
- }
155425
- function a11y_figcaption_index(node) {
155426
- w(node, "a11y_figcaption_index", "`<figcaption>` must be first or last child of `<figure>`");
155427
- }
155428
- function a11y_figcaption_parent(node) {
155429
- w(node, "a11y_figcaption_parent", "`<figcaption>` must be an immediate child of `<figure>`");
155430
- }
155431
- function a11y_hidden(node, name) {
155432
- w(node, "a11y_hidden", `\`<${name}>\` element should not be hidden`);
155433
- }
155434
- function a11y_img_redundant_alt(node) {
155435
- w(node, "a11y_img_redundant_alt", "Screenreaders already announce `<img>` elements as an image.");
155436
- }
155437
- function a11y_incorrect_aria_attribute_type(node, attribute, type) {
155438
- w(node, "a11y_incorrect_aria_attribute_type", `The value of '${attribute}' must be a ${type}`);
155439
- }
155440
- function a11y_incorrect_aria_attribute_type_boolean(node, attribute) {
155441
- w(node, "a11y_incorrect_aria_attribute_type_boolean", `The value of '${attribute}' must be either 'true' or 'false'. It cannot be empty`);
155442
- }
155443
- function a11y_incorrect_aria_attribute_type_idlist(node, attribute) {
155444
- w(node, "a11y_incorrect_aria_attribute_type_idlist", `The value of '${attribute}' must be a space-separated list of strings that represent DOM element IDs`);
155445
- }
155446
- function a11y_incorrect_aria_attribute_type_integer(node, attribute) {
155447
- w(node, "a11y_incorrect_aria_attribute_type_integer", `The value of '${attribute}' must be an integer`);
155448
- }
155449
- function a11y_incorrect_aria_attribute_type_token(node, attribute, values) {
155450
- w(node, "a11y_incorrect_aria_attribute_type_token", `The value of '${attribute}' must be exactly one of ${values}`);
155451
- }
155452
- function a11y_incorrect_aria_attribute_type_tokenlist(node, attribute, values) {
155453
- w(node, "a11y_incorrect_aria_attribute_type_tokenlist", `The value of '${attribute}' must be a space-separated list of one or more of ${values}`);
155454
- }
155455
- function a11y_incorrect_aria_attribute_type_tristate(node, attribute) {
155456
- w(node, "a11y_incorrect_aria_attribute_type_tristate", `The value of '${attribute}' must be exactly one of true, false, or mixed`);
155457
- }
155458
- function a11y_interactive_supports_focus(node, role) {
155459
- w(node, "a11y_interactive_supports_focus", `Elements with the '${role}' interactive role must have a tabindex value.`);
155460
- }
155461
- function a11y_invalid_attribute(node, href_value, href_attribute) {
155462
- w(node, "a11y_invalid_attribute", `'${href_value}' is not a valid ${href_attribute} attribute`);
155463
- }
155464
- function a11y_label_has_associated_control(node) {
155465
- w(node, "a11y_label_has_associated_control", "A form label must be associated with a control.");
155466
- }
155467
- function a11y_media_has_caption(node) {
155468
- w(node, "a11y_media_has_caption", '`<video>` elements must have a `<track kind="captions">`');
155469
- }
155470
- function a11y_misplaced_role(node, name) {
155471
- w(node, "a11y_misplaced_role", `\`<${name}>\` should not have role attribute`);
155472
- }
155473
- function a11y_misplaced_scope(node) {
155474
- w(node, "a11y_misplaced_scope", "The scope attribute should only be used with `<th>` elements");
155475
- }
155476
- function a11y_missing_attribute(node, name, article, sequence3) {
155477
- w(node, "a11y_missing_attribute", `\`<${name}>\` element should have ${article} ${sequence3} attribute`);
155478
- }
155479
- function a11y_missing_content(node, name) {
155480
- w(node, "a11y_missing_content", `\`<${name}>\` element should have child content`);
155481
- }
155482
- function a11y_mouse_events_have_key_events(node, event, accompanied_by) {
155483
- w(node, "a11y_mouse_events_have_key_events", `'${event}' event must be accompanied by '${accompanied_by}' event`);
155484
- }
155485
- function a11y_no_abstract_role(node, role) {
155486
- w(node, "a11y_no_abstract_role", `Abstract role '${role}' is forbidden`);
155487
- }
155488
- function a11y_no_interactive_element_to_noninteractive_role(node, element, role) {
155489
- w(node, "a11y_no_interactive_element_to_noninteractive_role", `\`<${element}>\` cannot have role '${role}'`);
155490
- }
155491
- function a11y_no_noninteractive_element_interactions(node, element) {
155492
- w(node, "a11y_no_noninteractive_element_interactions", `Non-interactive element \`<${element}>\` should not be assigned mouse or keyboard event listeners.`);
155493
- }
155494
- function a11y_no_noninteractive_element_to_interactive_role(node, element, role) {
155495
- w(node, "a11y_no_noninteractive_element_to_interactive_role", `Non-interactive element \`<${element}>\` cannot have interactive role '${role}'`);
155496
- }
155497
- function a11y_no_noninteractive_tabindex(node) {
155498
- w(node, "a11y_no_noninteractive_tabindex", "noninteractive element cannot have nonnegative tabIndex value");
155499
- }
155500
- function a11y_no_redundant_roles(node, role) {
155501
- w(node, "a11y_no_redundant_roles", `Redundant role '${role}'`);
155502
- }
155503
- function a11y_no_static_element_interactions(node, element, handler) {
155504
- w(node, "a11y_no_static_element_interactions", `\`<${element}>\` with a ${handler} handler must have an ARIA role`);
155505
- }
155506
- function a11y_positive_tabindex(node) {
155507
- w(node, "a11y_positive_tabindex", "Avoid tabindex values above zero");
155508
- }
155509
- function a11y_role_has_required_aria_props(node, role, props) {
155510
- w(node, "a11y_role_has_required_aria_props", `Elements with the ARIA role "${role}" must have the following attributes defined: ${props}`);
155511
- }
155512
- function a11y_role_supports_aria_props(node, attribute, role) {
155513
- w(node, "a11y_role_supports_aria_props", `The attribute '${attribute}' is not supported by the role '${role}'`);
155514
- }
155515
- function a11y_role_supports_aria_props_implicit(node, attribute, role, name) {
155516
- w(node, "a11y_role_supports_aria_props_implicit", `The attribute '${attribute}' is not supported by the role '${role}'. This role is implicit on the element \`<${name}>\``);
155517
- }
155518
- function a11y_unknown_aria_attribute(node, attribute, suggestion) {
155519
- w(node, "a11y_unknown_aria_attribute", suggestion ? `Unknown aria attribute 'aria-${attribute}'. Did you mean '${suggestion}'?` : `Unknown aria attribute 'aria-${attribute}'`);
155520
- }
155521
- function a11y_unknown_role(node, role, suggestion) {
155522
- w(node, "a11y_unknown_role", suggestion ? `Unknown role '${role}'. Did you mean '${suggestion}'?` : `Unknown role '${role}'`);
155523
- }
155524
- function legacy_code(node, code, suggestion) {
155525
- w(node, "legacy_code", `\`${code}\` is no longer valid \u2014 please use \`${suggestion}\` instead`);
155526
- }
155527
- function unknown_code(node, code, suggestion) {
155528
- w(node, "unknown_code", suggestion ? `\`${code}\` is not a recognised code (did you mean \`${suggestion}\`?)` : `\`${code}\` is not a recognised code`);
155529
- }
155530
- function options_deprecated_accessors(node) {
155531
- w(node, "options_deprecated_accessors", "The `accessors` option has been deprecated. It will have no effect in runes mode");
155532
- }
155533
- function options_deprecated_immutable(node) {
155534
- w(node, "options_deprecated_immutable", "The `immutable` option has been deprecated. It will have no effect in runes mode");
155535
- }
155536
- function options_removed_enable_sourcemap(node) {
155537
- w(node, "options_removed_enable_sourcemap", "The `enableSourcemap` option has been removed. Source maps are always generated now, and tooling can choose to ignore them");
155538
- }
155539
- function options_removed_hydratable(node) {
155540
- w(node, "options_removed_hydratable", "The `hydratable` option has been removed. Svelte components are always hydratable now");
155541
- }
155542
- function options_removed_loop_guard_timeout(node) {
155543
- w(node, "options_removed_loop_guard_timeout", "The `loopGuardTimeout` option has been removed");
155544
- }
155545
- function options_renamed_ssr_dom(node) {
155546
- w(node, "options_renamed_ssr_dom", '`generate: "dom"` and `generate: "ssr"` options have been renamed to "client" and "server" respectively');
155547
- }
155548
- function derived_iife(node) {
155549
- w(node, "derived_iife", "Use `$derived.by(() => {...})` instead of `$derived((() => {...})())`");
155550
- }
155551
- function perf_avoid_inline_class(node) {
155552
- w(node, "perf_avoid_inline_class", "Avoid 'new class' \u2014 instead, declare the class at the top level scope");
155553
- }
155554
- function perf_avoid_nested_class(node) {
155555
- w(node, "perf_avoid_nested_class", "Avoid declaring classes below the top level scope");
155556
- }
155557
- function reactive_declaration_invalid_placement(node) {
155558
- w(node, "reactive_declaration_invalid_placement", "Reactive declarations only exist at the top level of the instance script");
155559
- }
155560
- function attribute_avoid_is(node) {
155561
- w(node, "attribute_avoid_is", 'The "is" attribute is not supported cross-browser and should be avoided');
155562
- }
155563
- function attribute_global_event_reference(node, name) {
155564
- w(node, "attribute_global_event_reference", `You are referencing \`globalThis.${name}\`. Did you forget to declare a variable with that name?`);
155565
- }
155566
- function attribute_illegal_colon(node) {
155567
- w(node, "attribute_illegal_colon", "Attributes should not contain ':' characters to prevent ambiguity with Svelte directives");
155568
- }
155569
- function attribute_invalid_property_name(node, wrong, right) {
155570
- w(node, "attribute_invalid_property_name", `'${wrong}' is not a valid HTML attribute. Did you mean '${right}'?`);
155571
- }
155572
- function bind_invalid_each_rest(node, name) {
155573
- w(node, "bind_invalid_each_rest", `The rest operator (...) will create a new object and binding '${name}' with the original object will not work`);
155574
- }
155575
- function block_empty(node) {
155576
- w(node, "block_empty", "Empty block");
155577
- }
155578
- function component_name_lowercase(node, name) {
155579
- w(node, "component_name_lowercase", `\`<${name}>\` will be treated as an HTML element unless it begins with a capital letter`);
155580
- }
155581
- function element_invalid_self_closing_tag(node, name) {
155582
- w(node, "element_invalid_self_closing_tag", `Self-closing HTML tags for non-void elements are ambiguous \u2014 use \`<${name} ...></${name}>\` rather than \`<${name} ... />\``);
155583
- }
155584
- function event_directive_deprecated(node, name) {
155585
- w(node, "event_directive_deprecated", `Using \`on:${name}\` to listen to the ${name} event is deprecated. Use the event attribute \`on${name}\` instead.`);
155586
- }
155587
- function slot_element_deprecated(node) {
155588
- w(node, "slot_element_deprecated", "Using `<slot>` to render parent content is deprecated. Use `{@render ...}` tags instead.");
155589
- }
155590
-
155591
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/utils/extract_svelte_ignore.js
155592
- var regex_svelte_ignore = /^\s*svelte-ignore\s/;
155593
- var replacements = {
155594
- "non-top-level-reactive-declaration": "reactive_declaration_invalid_placement",
155595
- "module-script-reactive-declaration": "reactive_declaration_module_script",
155596
- "empty-block": "block_empty",
155597
- "avoid-is": "attribute_avoid_is",
155598
- "invalid-html-attribute": "attribute_invalid_property_name",
155599
- "a11y-structure": "a11y_figcaption_parent",
155600
- "illegal-attribute-character": "attribute_illegal_colon",
155601
- "invalid-rest-eachblock-binding": "bind_invalid_each_rest"
155602
- };
155603
- function extract_svelte_ignore(offset2, text2, runes) {
155604
- const match = regex_svelte_ignore.exec(text2);
155605
- if (!match)
155606
- return [];
155607
- let length = match[0].length;
155608
- offset2 += length;
155609
- const ignores = [];
155610
- for (const match2 of text2.slice(length).matchAll(/([\w$-]+)(,)?/gm)) {
155611
- const code = match2[1];
155612
- ignores.push(code);
155613
- if (!codes.includes(code)) {
155614
- const replacement = replacements[code] ?? code.replace(/-/g, "_");
155615
- if (runes) {
155616
- const start = offset2 + match2.index;
155617
- const end = start + code.length;
155618
- if (codes.includes(replacement)) {
155619
- legacy_code({ start, end }, code, replacement);
155620
- } else {
155621
- const suggestion = fuzzymatch(code, codes);
155622
- unknown_code({ start, end }, code, suggestion);
155623
- }
155624
- } else if (codes.includes(replacement)) {
155625
- ignores.push(replacement);
155626
- }
155627
- }
155628
- if (!match2[2]) {
155629
- break;
155630
- }
155631
- }
155632
- return ignores;
155633
- }
155634
-
155635
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/legacy.js
155636
- function remove_surrounding_whitespace_nodes(nodes) {
155637
- const first = nodes.at(0);
155638
- const last = nodes.at(-1);
155639
- if (first?.type === "Text") {
155640
- if (!regex_not_whitespace.test(first.data)) {
155641
- nodes.shift();
155642
- } else {
155643
- first.data = first.data.replace(regex_starts_with_whitespaces, "");
155644
- }
155645
- }
155646
- if (last?.type === "Text") {
155647
- if (!regex_not_whitespace.test(last.data)) {
155648
- nodes.pop();
155649
- } else {
155650
- last.data = last.data.replace(regex_ends_with_whitespaces, "");
155651
- }
155652
- }
155653
- }
155654
- function convert(source, ast) {
155655
- const root = ast;
155656
- return walk2(root, null, {
155657
- _(node, { next: next2 }) {
155658
- delete node.parent;
155659
- delete node.metadata;
155660
- next2();
155661
- },
155662
- Root(node, { visit: visit24 }) {
155663
- const { instance, module: module2, options } = node;
155664
- if (options?.__raw__) {
155665
- let idx = node.fragment.nodes.findIndex((node2) => options.end <= node2.start);
155666
- if (idx === -1) {
155667
- idx = node.fragment.nodes.length;
155668
- }
155669
- delete options.__raw__.parent;
155670
- node.fragment.nodes.splice(idx, 0, options.__raw__);
155671
- }
155672
- let start = null;
155673
- let end = null;
155674
- if (node.fragment.nodes.length > 0) {
155675
- const first = node.fragment.nodes.at(0);
155676
- const last = node.fragment.nodes.at(-1);
155677
- start = first.start;
155678
- end = last.end;
155679
- while (/\s/.test(source[start]))
155680
- start += 1;
155681
- while (/\s/.test(source[end - 1]))
155682
- end -= 1;
155683
- }
155684
- if (instance) {
155685
- delete instance.parent;
155686
- delete instance.attributes;
155687
- }
155688
- if (module2) {
155689
- delete module2.parent;
155690
- delete module2.attributes;
155691
- }
155692
- return {
155693
- html: {
155694
- type: "Fragment",
155695
- start,
155696
- end,
155697
- children: node.fragment.nodes.map((child) => visit24(child))
155698
- },
155699
- instance,
155700
- module: module2,
155701
- css: ast.css ? visit24(ast.css) : void 0
155702
- };
155703
- },
155704
- AnimateDirective(node) {
155705
- return { ...node, type: "Animation" };
155706
- },
155707
- AwaitBlock(node, { visit: visit24 }) {
155708
- let pendingblock = {
155709
- type: "PendingBlock",
155710
- start: null,
155711
- end: null,
155712
- children: node.pending?.nodes.map((child) => visit24(child)) ?? [],
155713
- skip: true
155714
- };
155715
- let thenblock = {
155716
- type: "ThenBlock",
155717
- start: null,
155718
- end: null,
155719
- children: node.then?.nodes.map((child) => visit24(child)) ?? [],
155720
- skip: true
155721
- };
155722
- let catchblock = {
155723
- type: "CatchBlock",
155724
- start: null,
155725
- end: null,
155726
- children: node.catch?.nodes.map((child) => visit24(child)) ?? [],
155727
- skip: true
155728
- };
155729
- if (node.pending) {
155730
- const first = node.pending.nodes.at(0);
155731
- const last = node.pending.nodes.at(-1);
155732
- pendingblock.start = first?.start ?? source.indexOf("}", node.expression.end) + 1;
155733
- pendingblock.end = last?.end ?? pendingblock.start;
155734
- pendingblock.skip = false;
155735
- }
155736
- if (node.then) {
155737
- const first = node.then.nodes.at(0);
155738
- const last = node.then.nodes.at(-1);
155739
- thenblock.start = pendingblock.end ?? first?.start ?? source.indexOf("}", node.expression.end) + 1;
155740
- thenblock.end = last?.end ?? source.lastIndexOf("}", pendingblock.end ?? node.expression.end) + 1;
155741
- thenblock.skip = false;
155742
- }
155743
- if (node.catch) {
155744
- const first = node.catch.nodes.at(0);
155745
- const last = node.catch.nodes.at(-1);
155746
- catchblock.start = thenblock.end ?? pendingblock.end ?? first?.start ?? source.indexOf("}", node.expression.end) + 1;
155747
- catchblock.end = last?.end ?? source.lastIndexOf("}", thenblock.end ?? pendingblock.end ?? node.expression.end) + 1;
155748
- catchblock.skip = false;
155749
- }
155750
- return {
155751
- type: "AwaitBlock",
155752
- start: node.start,
155753
- end: node.end,
155754
- expression: node.expression,
155755
- value: node.value,
155756
- error: node.error,
155757
- pending: pendingblock,
155758
- then: thenblock,
155759
- catch: catchblock
155760
- };
155761
- },
155762
- BindDirective(node) {
155763
- return { ...node, type: "Binding" };
155764
- },
155765
- ClassDirective(node) {
155766
- return { ...node, type: "Class" };
155767
- },
155768
- Comment(node) {
155769
- return {
155770
- ...node,
155771
- ignores: extract_svelte_ignore(node.start, node.data, false)
155772
- };
155773
- },
155774
- ComplexSelector(node) {
155775
- const children = [];
155776
- for (const child of node.children) {
155777
- if (child.combinator) {
155778
- children.push(child.combinator);
155779
- }
155780
- children.push(...child.selectors);
155781
- }
155782
- return {
155783
- type: "Selector",
155784
- start: node.start,
155785
- end: node.end,
155786
- children
155787
- };
155788
- },
155789
- Component(node, { visit: visit24 }) {
155790
- return {
155791
- type: "InlineComponent",
155792
- start: node.start,
155793
- end: node.end,
155794
- name: node.name,
155795
- attributes: node.attributes.map(
155796
- (child) => visit24(child)
155797
- ),
155798
- children: node.fragment.nodes.map(
155799
- (child) => visit24(child)
155800
- )
155801
- };
155802
- },
155803
- ConstTag(node) {
155804
- if (node.expression !== void 0) {
155805
- return node;
155806
- }
155807
- const modern_node = node;
155808
- const { id: left } = { ...modern_node.declaration.declarations[0] };
155809
- delete left.typeAnnotation;
155810
- return {
155811
- type: "ConstTag",
155812
- start: modern_node.start,
155813
- end: node.end,
155814
- expression: {
155815
- type: "AssignmentExpression",
155816
- start: (modern_node.declaration.start ?? 0) + "const ".length,
155817
- end: modern_node.declaration.end ?? 0,
155818
- operator: "=",
155819
- left,
155820
- right: modern_node.declaration.declarations[0].init
155821
- }
155822
- };
155823
- },
155824
- KeyBlock(node, { visit: visit24 }) {
155825
- remove_surrounding_whitespace_nodes(node.fragment.nodes);
155826
- return {
155827
- type: "KeyBlock",
155828
- start: node.start,
155829
- end: node.end,
155830
- expression: node.expression,
155831
- children: node.fragment.nodes.map(
155832
- (child) => visit24(child)
155833
- )
155834
- };
155835
- },
155836
- EachBlock(node, { visit: visit24 }) {
155837
- let elseblock = void 0;
155838
- if (node.fallback) {
155839
- const first = node.fallback.nodes.at(0);
155840
- const end = source.lastIndexOf("{", node.end - 1);
155841
- const start = first?.start ?? end;
155842
- remove_surrounding_whitespace_nodes(node.fallback.nodes);
155843
- elseblock = {
155844
- type: "ElseBlock",
155845
- start,
155846
- end,
155847
- children: node.fallback.nodes.map((child) => visit24(child))
155294
+ return {
155295
+ html: {
155296
+ type: "Fragment",
155297
+ start,
155298
+ end,
155299
+ children: node.fragment.nodes.map((child) => visit24(child))
155300
+ },
155301
+ instance,
155302
+ module: module2,
155303
+ css: ast.css ? visit24(ast.css) : void 0
155304
+ };
155305
+ },
155306
+ AnimateDirective(node) {
155307
+ return { ...node, type: "Animation" };
155308
+ },
155309
+ AwaitBlock(node, { visit: visit24 }) {
155310
+ let pendingblock = {
155311
+ type: "PendingBlock",
155312
+ start: null,
155313
+ end: null,
155314
+ children: node.pending?.nodes.map((child) => visit24(child)) ?? [],
155315
+ skip: true
155316
+ };
155317
+ let thenblock = {
155318
+ type: "ThenBlock",
155319
+ start: null,
155320
+ end: null,
155321
+ children: node.then?.nodes.map((child) => visit24(child)) ?? [],
155322
+ skip: true
155323
+ };
155324
+ let catchblock = {
155325
+ type: "CatchBlock",
155326
+ start: null,
155327
+ end: null,
155328
+ children: node.catch?.nodes.map((child) => visit24(child)) ?? [],
155329
+ skip: true
155330
+ };
155331
+ if (node.pending) {
155332
+ const first = node.pending.nodes.at(0);
155333
+ const last = node.pending.nodes.at(-1);
155334
+ pendingblock.start = first?.start ?? source.indexOf("}", node.expression.end) + 1;
155335
+ pendingblock.end = last?.end ?? pendingblock.start;
155336
+ pendingblock.skip = false;
155337
+ }
155338
+ if (node.then) {
155339
+ const first = node.then.nodes.at(0);
155340
+ const last = node.then.nodes.at(-1);
155341
+ thenblock.start = pendingblock.end ?? first?.start ?? source.indexOf("}", node.expression.end) + 1;
155342
+ thenblock.end = last?.end ?? source.lastIndexOf("}", pendingblock.end ?? node.expression.end) + 1;
155343
+ thenblock.skip = false;
155344
+ }
155345
+ if (node.catch) {
155346
+ const first = node.catch.nodes.at(0);
155347
+ const last = node.catch.nodes.at(-1);
155348
+ catchblock.start = thenblock.end ?? pendingblock.end ?? first?.start ?? source.indexOf("}", node.expression.end) + 1;
155349
+ catchblock.end = last?.end ?? source.lastIndexOf("}", thenblock.end ?? pendingblock.end ?? node.expression.end) + 1;
155350
+ catchblock.skip = false;
155351
+ }
155352
+ return {
155353
+ type: "AwaitBlock",
155354
+ start: node.start,
155355
+ end: node.end,
155356
+ expression: node.expression,
155357
+ value: node.value,
155358
+ error: node.error,
155359
+ pending: pendingblock,
155360
+ then: thenblock,
155361
+ catch: catchblock
155362
+ };
155363
+ },
155364
+ BindDirective(node) {
155365
+ return { ...node, type: "Binding" };
155366
+ },
155367
+ ClassDirective(node) {
155368
+ return { ...node, type: "Class" };
155369
+ },
155370
+ Comment(node) {
155371
+ return {
155372
+ ...node,
155373
+ ignores: extract_svelte_ignore(node.start, node.data, false)
155374
+ };
155375
+ },
155376
+ ComplexSelector(node) {
155377
+ const children = [];
155378
+ for (const child of node.children) {
155379
+ if (child.combinator) {
155380
+ children.push(child.combinator);
155381
+ }
155382
+ children.push(...child.selectors);
155383
+ }
155384
+ return {
155385
+ type: "Selector",
155386
+ start: node.start,
155387
+ end: node.end,
155388
+ children
155389
+ };
155390
+ },
155391
+ Component(node, { visit: visit24 }) {
155392
+ return {
155393
+ type: "InlineComponent",
155394
+ start: node.start,
155395
+ end: node.end,
155396
+ name: node.name,
155397
+ attributes: node.attributes.map(
155398
+ (child) => visit24(child)
155399
+ ),
155400
+ children: node.fragment.nodes.map(
155401
+ (child) => visit24(child)
155402
+ )
155403
+ };
155404
+ },
155405
+ ConstTag(node) {
155406
+ if (node.expression !== void 0) {
155407
+ return node;
155408
+ }
155409
+ const modern_node = node;
155410
+ const { id: left } = { ...modern_node.declaration.declarations[0] };
155411
+ delete left.typeAnnotation;
155412
+ return {
155413
+ type: "ConstTag",
155414
+ start: modern_node.start,
155415
+ end: node.end,
155416
+ expression: {
155417
+ type: "AssignmentExpression",
155418
+ start: (modern_node.declaration.start ?? 0) + "const ".length,
155419
+ end: modern_node.declaration.end ?? 0,
155420
+ operator: "=",
155421
+ left,
155422
+ right: modern_node.declaration.declarations[0].init
155423
+ }
155424
+ };
155425
+ },
155426
+ KeyBlock(node, { visit: visit24 }) {
155427
+ remove_surrounding_whitespace_nodes(node.fragment.nodes);
155428
+ return {
155429
+ type: "KeyBlock",
155430
+ start: node.start,
155431
+ end: node.end,
155432
+ expression: node.expression,
155433
+ children: node.fragment.nodes.map(
155434
+ (child) => visit24(child)
155435
+ )
155436
+ };
155437
+ },
155438
+ EachBlock(node, { visit: visit24 }) {
155439
+ let elseblock = void 0;
155440
+ if (node.fallback) {
155441
+ const first = node.fallback.nodes.at(0);
155442
+ const end = source.lastIndexOf("{", node.end - 1);
155443
+ const start = first?.start ?? end;
155444
+ remove_surrounding_whitespace_nodes(node.fallback.nodes);
155445
+ elseblock = {
155446
+ type: "ElseBlock",
155447
+ start,
155448
+ end,
155449
+ children: node.fallback.nodes.map((child) => visit24(child))
155848
155450
  };
155849
155451
  }
155850
155452
  remove_surrounding_whitespace_nodes(node.body.nodes);
@@ -163288,165 +162890,588 @@ function D(e4) {
163288
162890
  return z;
163289
162891
  };
163290
162892
  }
163291
-
163292
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/1-parse/acorn.js
163293
- var ParserWithTS = Parser.extend(D({ allowSatisfies: true }));
163294
- function parse14(source, typescript) {
163295
- const parser = typescript ? ParserWithTS : Parser;
163296
- const { onComment, add_comments } = get_comment_handlers(source);
163297
- const ast = parser.parse(source, {
163298
- onComment,
163299
- sourceType: "module",
163300
- ecmaVersion: 13,
163301
- locations: true
163302
- });
163303
- if (typescript)
163304
- amend(source, ast);
163305
- add_comments(ast);
163306
- return ast;
162893
+
162894
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/1-parse/acorn.js
162895
+ var ParserWithTS = Parser.extend(D({ allowSatisfies: true }));
162896
+ function parse14(source, typescript) {
162897
+ const parser = typescript ? ParserWithTS : Parser;
162898
+ const { onComment, add_comments } = get_comment_handlers(source);
162899
+ const ast = parser.parse(source, {
162900
+ onComment,
162901
+ sourceType: "module",
162902
+ ecmaVersion: 13,
162903
+ locations: true
162904
+ });
162905
+ if (typescript)
162906
+ amend(source, ast);
162907
+ add_comments(ast);
162908
+ return ast;
162909
+ }
162910
+ function parse_expression_at(source, typescript, index) {
162911
+ const parser = typescript ? ParserWithTS : Parser;
162912
+ const { onComment, add_comments } = get_comment_handlers(source);
162913
+ const ast = parser.parseExpressionAt(source, index, {
162914
+ onComment,
162915
+ sourceType: "module",
162916
+ ecmaVersion: 13,
162917
+ locations: true
162918
+ });
162919
+ if (typescript)
162920
+ amend(source, ast);
162921
+ add_comments(ast);
162922
+ return ast;
162923
+ }
162924
+ function get_comment_handlers(source) {
162925
+ const comments = [];
162926
+ return {
162927
+ onComment: (block4, value, start, end) => {
162928
+ if (block4 && /\n/.test(value)) {
162929
+ let a2 = start;
162930
+ while (a2 > 0 && source[a2 - 1] !== "\n")
162931
+ a2 -= 1;
162932
+ let b2 = a2;
162933
+ while (/[ \t]/.test(source[b2]))
162934
+ b2 += 1;
162935
+ const indentation = source.slice(a2, b2);
162936
+ value = value.replace(new RegExp(`^${indentation}`, "gm"), "");
162937
+ }
162938
+ comments.push({ type: block4 ? "Block" : "Line", value, start, end });
162939
+ },
162940
+ add_comments(ast) {
162941
+ if (comments.length === 0)
162942
+ return;
162943
+ walk2(ast, null, {
162944
+ _(node, { next: next2 }) {
162945
+ let comment;
162946
+ while (comments[0] && comments[0].start < node.start) {
162947
+ comment = comments.shift();
162948
+ (node.leadingComments ||= []).push(comment);
162949
+ }
162950
+ next2();
162951
+ if (comments[0]) {
162952
+ const slice = source.slice(node.end, comments[0].start);
162953
+ if (/^[,) \t]*$/.test(slice)) {
162954
+ node.trailingComments = [comments.shift()];
162955
+ }
162956
+ }
162957
+ }
162958
+ });
162959
+ }
162960
+ };
162961
+ }
162962
+ function amend(source, node) {
162963
+ return walk2(node, null, {
162964
+ _(node2, context) {
162965
+ delete node2.loc.start.index;
162966
+ delete node2.loc.end.index;
162967
+ if (node2.typeAnnotation && node2.end === void 0) {
162968
+ let end = node2.typeAnnotation.start;
162969
+ while (/\s/.test(source[end - 1]))
162970
+ end -= 1;
162971
+ node2.end = end;
162972
+ }
162973
+ context.next();
162974
+ }
162975
+ });
162976
+ }
162977
+
162978
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/1-parse/utils/names.js
162979
+ var reserved = [
162980
+ "arguments",
162981
+ "await",
162982
+ "break",
162983
+ "case",
162984
+ "catch",
162985
+ "class",
162986
+ "const",
162987
+ "continue",
162988
+ "debugger",
162989
+ "default",
162990
+ "delete",
162991
+ "do",
162992
+ "else",
162993
+ "enum",
162994
+ "eval",
162995
+ "export",
162996
+ "extends",
162997
+ "false",
162998
+ "finally",
162999
+ "for",
163000
+ "function",
163001
+ "if",
163002
+ "implements",
163003
+ "import",
163004
+ "in",
163005
+ "instanceof",
163006
+ "interface",
163007
+ "let",
163008
+ "new",
163009
+ "null",
163010
+ "package",
163011
+ "private",
163012
+ "protected",
163013
+ "public",
163014
+ "return",
163015
+ "static",
163016
+ "super",
163017
+ "switch",
163018
+ "this",
163019
+ "throw",
163020
+ "true",
163021
+ "try",
163022
+ "typeof",
163023
+ "var",
163024
+ "void",
163025
+ "while",
163026
+ "with",
163027
+ "yield"
163028
+ ];
163029
+ var void_element_names = [
163030
+ "area",
163031
+ "base",
163032
+ "br",
163033
+ "col",
163034
+ "command",
163035
+ "embed",
163036
+ "hr",
163037
+ "img",
163038
+ "input",
163039
+ "keygen",
163040
+ "link",
163041
+ "meta",
163042
+ "param",
163043
+ "source",
163044
+ "track",
163045
+ "wbr"
163046
+ ];
163047
+ function is_void(name) {
163048
+ return void_element_names.includes(name) || name.toLowerCase() === "!doctype";
163049
+ }
163050
+
163051
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/errors.js
163052
+ var CompileError = class extends Error {
163053
+ name = "CompileError";
163054
+ filename = filename;
163055
+ position = void 0;
163056
+ start = void 0;
163057
+ end = void 0;
163058
+ constructor(code, message, position) {
163059
+ super(message);
163060
+ this.code = code;
163061
+ this.position = position;
163062
+ if (position) {
163063
+ this.start = locator(position[0]);
163064
+ this.end = locator(position[1]);
163065
+ }
163066
+ }
163067
+ toString() {
163068
+ let out = `${this.name}: ${this.message}`;
163069
+ out += `
163070
+ (${this.code})`;
163071
+ if (this.filename) {
163072
+ out += `
163073
+ ${this.filename}`;
163074
+ if (this.start) {
163075
+ out += `${this.start.line}:${this.start.column}`;
163076
+ }
163077
+ }
163078
+ return out;
163079
+ }
163080
+ };
163081
+ function e3(node, code, message) {
163082
+ const start = typeof node === "number" ? node : node?.start;
163083
+ const end = typeof node === "number" ? node : node?.end;
163084
+ throw new CompileError(code, message, start !== void 0 && end !== void 0 ? [start, end] : void 0);
163085
+ }
163086
+ function options_invalid_value(node, details) {
163087
+ e3(node, "options_invalid_value", `Invalid compiler option: ${details}`);
163088
+ }
163089
+ function options_removed(node, details) {
163090
+ e3(node, "options_removed", `Invalid compiler option: ${details}`);
163091
+ }
163092
+ function options_unrecognised(node, keypath) {
163093
+ e3(node, "options_unrecognised", `Unrecognised compiler option ${keypath}`);
163094
+ }
163095
+ function bindable_invalid_location(node) {
163096
+ e3(node, "bindable_invalid_location", "`$bindable()` can only be used inside a `$props()` declaration");
163097
+ }
163098
+ function constant_assignment(node, thing) {
163099
+ e3(node, "constant_assignment", `Cannot assign to ${thing}`);
163100
+ }
163101
+ function constant_binding(node, thing) {
163102
+ e3(node, "constant_binding", `Cannot bind to ${thing}`);
163103
+ }
163104
+ function declaration_duplicate_module_import(node) {
163105
+ e3(node, "declaration_duplicate_module_import", 'Cannot declare same variable name which is imported inside `<script context="module">`');
163106
+ }
163107
+ function derived_invalid_export(node) {
163108
+ e3(node, "derived_invalid_export", "Cannot export derived state from a module. To expose the current derived value, export a function returning its value");
163109
+ }
163110
+ function each_item_invalid_assignment(node) {
163111
+ e3(node, "each_item_invalid_assignment", "Cannot reassign or bind to each block argument in runes mode. Use the array and index variables instead (e.g. `array[i] = value` instead of `entry = value`)");
163112
+ }
163113
+ function effect_invalid_placement(node) {
163114
+ e3(node, "effect_invalid_placement", "`$effect()` can only be used as an expression statement");
163115
+ }
163116
+ function host_invalid_placement(node) {
163117
+ e3(node, "host_invalid_placement", "`$host()` can only be used inside custom element component instances");
163118
+ }
163119
+ function import_svelte_internal_forbidden(node) {
163120
+ e3(node, "import_svelte_internal_forbidden", "Imports of `svelte/internal/*` are forbidden. It contains private runtime code which is subject to change without notice. If you're importing from `svelte/internal/*` to work around a limitation of Svelte, please open an issue at https://github.com/sveltejs/svelte and explain your use case");
163121
+ }
163122
+ function legacy_export_invalid(node) {
163123
+ e3(node, "legacy_export_invalid", "Cannot use `export let` in runes mode \u2014 use `$props()` instead");
163124
+ }
163125
+ function legacy_reactive_statement_invalid(node) {
163126
+ e3(node, "legacy_reactive_statement_invalid", "`$:` is not allowed in runes mode, use `$derived` or `$effect` instead");
163127
+ }
163128
+ function module_illegal_default_export(node) {
163129
+ e3(node, "module_illegal_default_export", "A component cannot have a default export");
163130
+ }
163131
+ function props_duplicate(node) {
163132
+ e3(node, "props_duplicate", "Cannot use `$props()` more than once");
163133
+ }
163134
+ function props_invalid_identifier(node) {
163135
+ e3(node, "props_invalid_identifier", "`$props()` can only be used with an object destructuring pattern");
163136
+ }
163137
+ function props_invalid_pattern(node) {
163138
+ e3(node, "props_invalid_pattern", "`$props()` assignment must not contain nested properties or computed keys");
163139
+ }
163140
+ function props_invalid_placement(node) {
163141
+ e3(node, "props_invalid_placement", "`$props()` can only be used at the top level of components as a variable declaration initializer");
163142
+ }
163143
+ function rune_invalid_arguments(node, rune) {
163144
+ e3(node, "rune_invalid_arguments", `\`${rune}\` cannot be called with arguments`);
163145
+ }
163146
+ function rune_invalid_arguments_length(node, rune, args) {
163147
+ e3(node, "rune_invalid_arguments_length", `\`${rune}\` must be called with ${args}`);
163148
+ }
163149
+ function rune_invalid_computed_property(node) {
163150
+ e3(node, "rune_invalid_computed_property", "Cannot access a computed property of a rune");
163151
+ }
163152
+ function rune_invalid_name(node, name) {
163153
+ e3(node, "rune_invalid_name", `\`${name}\` is not a valid rune`);
163154
+ }
163155
+ function rune_invalid_usage(node, rune) {
163156
+ e3(node, "rune_invalid_usage", `Cannot use \`${rune}\` rune in non-runes mode`);
163157
+ }
163158
+ function rune_missing_parentheses(node) {
163159
+ e3(node, "rune_missing_parentheses", "Cannot use rune without parentheses");
163160
+ }
163161
+ function runes_mode_invalid_import(node, name) {
163162
+ e3(node, "runes_mode_invalid_import", `${name} cannot be used in runes mode`);
163163
+ }
163164
+ function snippet_parameter_assignment(node) {
163165
+ e3(node, "snippet_parameter_assignment", "Cannot reassign or bind to snippet parameter");
163166
+ }
163167
+ function state_invalid_export(node) {
163168
+ e3(node, "state_invalid_export", "Cannot export state from a module if it is reassigned. Either export a function returning the state value or only mutate the state value's properties");
163169
+ }
163170
+ function state_invalid_placement(node, rune) {
163171
+ e3(node, "state_invalid_placement", `\`${rune}(...)\` can only be used as a variable declaration initializer or a class field`);
163172
+ }
163173
+ function css_empty_declaration(node) {
163174
+ e3(node, "css_empty_declaration", "Declaration cannot be empty");
163175
+ }
163176
+ function css_expected_identifier(node) {
163177
+ e3(node, "css_expected_identifier", "Expected a valid CSS identifier");
163178
+ }
163179
+ function css_global_block_invalid_combinator(node, name) {
163180
+ e3(node, "css_global_block_invalid_combinator", `A :global {...} block cannot follow a ${name} combinator`);
163181
+ }
163182
+ function css_global_block_invalid_declaration(node) {
163183
+ e3(node, "css_global_block_invalid_declaration", "A :global {...} block can only contain rules, not declarations");
163184
+ }
163185
+ function css_global_block_invalid_list(node) {
163186
+ e3(node, "css_global_block_invalid_list", "A :global {...} block cannot be part of a selector list with more than one item");
163187
+ }
163188
+ function css_global_block_invalid_modifier(node) {
163189
+ e3(node, "css_global_block_invalid_modifier", "A :global {...} block cannot modify an existing selector");
163190
+ }
163191
+ function css_global_invalid_placement(node) {
163192
+ e3(node, "css_global_invalid_placement", ":global(...) can be at the start or end of a selector sequence, but not in the middle");
163193
+ }
163194
+ function css_global_invalid_selector(node) {
163195
+ e3(node, "css_global_invalid_selector", ":global(...) must contain exactly one selector");
163196
+ }
163197
+ function css_global_invalid_selector_list(node) {
163198
+ e3(node, "css_global_invalid_selector_list", ":global(...) must not contain type or universal selectors when used in a compound selector");
163199
+ }
163200
+ function css_nesting_selector_invalid_placement(node) {
163201
+ e3(node, "css_nesting_selector_invalid_placement", "Nesting selectors can only be used inside a rule");
163202
+ }
163203
+ function css_selector_invalid(node) {
163204
+ e3(node, "css_selector_invalid", "Invalid selector");
163205
+ }
163206
+ function css_type_selector_invalid_placement(node) {
163207
+ e3(node, "css_type_selector_invalid_placement", ":global(...) must not be followed with a type selector");
163208
+ }
163209
+ function animation_duplicate(node) {
163210
+ e3(node, "animation_duplicate", "An element can only have one 'animate' directive");
163211
+ }
163212
+ function animation_invalid_placement(node) {
163213
+ e3(node, "animation_invalid_placement", "An element that uses the `animate:` directive must be the only child of a keyed `{#each ...}` block");
163214
+ }
163215
+ function animation_missing_key(node) {
163216
+ e3(node, "animation_missing_key", "An element that uses the `animate:` directive must be the only child of a keyed `{#each ...}` block. Did you forget to add a key to your each block?");
163217
+ }
163218
+ function attribute_contenteditable_dynamic(node) {
163219
+ e3(node, "attribute_contenteditable_dynamic", "'contenteditable' attribute cannot be dynamic if element uses two-way binding");
163220
+ }
163221
+ function attribute_contenteditable_missing(node) {
163222
+ e3(node, "attribute_contenteditable_missing", "'contenteditable' attribute is required for textContent, innerHTML and innerText two-way bindings");
163223
+ }
163224
+ function attribute_duplicate(node) {
163225
+ e3(node, "attribute_duplicate", "Attributes need to be unique");
163226
+ }
163227
+ function attribute_empty_shorthand(node) {
163228
+ e3(node, "attribute_empty_shorthand", "Attribute shorthand cannot be empty");
163229
+ }
163230
+ function attribute_invalid_event_handler(node) {
163231
+ e3(node, "attribute_invalid_event_handler", "Event attribute must be a JavaScript expression, not a string");
163307
163232
  }
163308
- function parse_expression_at(source, typescript, index) {
163309
- const parser = typescript ? ParserWithTS : Parser;
163310
- const { onComment, add_comments } = get_comment_handlers(source);
163311
- const ast = parser.parseExpressionAt(source, index, {
163312
- onComment,
163313
- sourceType: "module",
163314
- ecmaVersion: 13,
163315
- locations: true
163316
- });
163317
- if (typescript)
163318
- amend(source, ast);
163319
- add_comments(ast);
163320
- return ast;
163233
+ function attribute_invalid_multiple(node) {
163234
+ e3(node, "attribute_invalid_multiple", "'multiple' attribute must be static if select uses two-way binding");
163235
+ }
163236
+ function attribute_invalid_name(node, name) {
163237
+ e3(node, "attribute_invalid_name", `'${name}' is not a valid attribute name`);
163238
+ }
163239
+ function attribute_invalid_sequence_expression(node) {
163240
+ e3(node, "attribute_invalid_sequence_expression", "Sequence expressions are not allowed as attribute/directive values in runes mode, unless wrapped in parentheses");
163241
+ }
163242
+ function attribute_invalid_type(node) {
163243
+ e3(node, "attribute_invalid_type", "'type' attribute must be a static text value if input uses two-way binding");
163244
+ }
163245
+ function bind_invalid_expression(node) {
163246
+ e3(node, "bind_invalid_expression", "Can only bind to an Identifier or MemberExpression");
163247
+ }
163248
+ function bind_invalid_name(node, name, explanation) {
163249
+ e3(node, "bind_invalid_name", explanation ? `\`bind:${name}\` is not a valid binding. ${explanation}` : `\`bind:${name}\` is not a valid binding`);
163250
+ }
163251
+ function bind_invalid_target(node, name, elements) {
163252
+ e3(node, "bind_invalid_target", `\`bind:${name}\` can only be used with ${elements}`);
163253
+ }
163254
+ function bind_invalid_value(node) {
163255
+ e3(node, "bind_invalid_value", "Can only bind to state or props");
163256
+ }
163257
+ function block_duplicate_clause(node, name) {
163258
+ e3(node, "block_duplicate_clause", `${name} cannot appear more than once within a block`);
163259
+ }
163260
+ function block_invalid_continuation_placement(node) {
163261
+ e3(node, "block_invalid_continuation_placement", "{:...} block is invalid at this position (did you forget to close the preceeding element or block?)");
163262
+ }
163263
+ function block_invalid_elseif(node) {
163264
+ e3(node, "block_invalid_elseif", "'elseif' should be 'else if'");
163265
+ }
163266
+ function block_invalid_placement(node, name, location) {
163267
+ e3(node, "block_invalid_placement", `{#${name} ...} block cannot be ${location}`);
163268
+ }
163269
+ function block_unclosed(node) {
163270
+ e3(node, "block_unclosed", "Block was left open");
163271
+ }
163272
+ function block_unexpected_close(node) {
163273
+ e3(node, "block_unexpected_close", "Unexpected block closing tag");
163274
+ }
163275
+ function component_invalid_directive(node) {
163276
+ e3(node, "component_invalid_directive", "This type of directive is not valid on components");
163277
+ }
163278
+ function const_tag_invalid_expression(node) {
163279
+ e3(node, "const_tag_invalid_expression", "{@const ...} must consist of a single variable declaration");
163280
+ }
163281
+ function const_tag_invalid_placement(node) {
163282
+ e3(node, "const_tag_invalid_placement", "`{@const}` must be the immediate child of `{#snippet}`, `{#if}`, `{:else if}`, `{:else}`, `{#each}`, `{:then}`, `{:catch}`, `<svelte:fragment>` or `<Component>`");
163283
+ }
163284
+ function debug_tag_invalid_arguments(node) {
163285
+ e3(node, "debug_tag_invalid_arguments", "{@debug ...} arguments must be identifiers, not arbitrary expressions");
163286
+ }
163287
+ function directive_invalid_value(node) {
163288
+ e3(node, "directive_invalid_value", "Directive value must be a JavaScript expression enclosed in curly braces");
163289
+ }
163290
+ function directive_missing_name(node, type) {
163291
+ e3(node, "directive_missing_name", `\`${type}\` name cannot be empty`);
163292
+ }
163293
+ function element_invalid_closing_tag(node, name) {
163294
+ e3(node, "element_invalid_closing_tag", `\`</${name}>\` attempted to close an element that was not open`);
163295
+ }
163296
+ function element_invalid_closing_tag_autoclosed(node, name, reason) {
163297
+ e3(node, "element_invalid_closing_tag_autoclosed", `\`</${name}>\` attempted to close element that was already automatically closed by \`<${reason}>\` (cannot nest \`<${reason}>\` inside \`<${name}>\`)`);
163298
+ }
163299
+ function element_invalid_tag_name(node) {
163300
+ e3(node, "element_invalid_tag_name", "Expected valid tag name");
163301
+ }
163302
+ function element_unclosed(node, name) {
163303
+ e3(node, "element_unclosed", `\`<${name}>\` was left open`);
163304
+ }
163305
+ function event_handler_invalid_component_modifier(node) {
163306
+ e3(node, "event_handler_invalid_component_modifier", "Event modifiers other than 'once' can only be used on DOM elements");
163307
+ }
163308
+ function event_handler_invalid_modifier(node, list3) {
163309
+ e3(node, "event_handler_invalid_modifier", `Valid event modifiers are ${list3}`);
163310
+ }
163311
+ function event_handler_invalid_modifier_combination(node, modifier1, modifier2) {
163312
+ e3(node, "event_handler_invalid_modifier_combination", `The '${modifier1}' and '${modifier2}' modifiers cannot be used together`);
163313
+ }
163314
+ function expected_attribute_value(node) {
163315
+ e3(node, "expected_attribute_value", "Expected attribute value");
163316
+ }
163317
+ function expected_block_type(node) {
163318
+ e3(node, "expected_block_type", "Expected 'if', 'each', 'await', 'key' or 'snippet'");
163319
+ }
163320
+ function expected_identifier(node) {
163321
+ e3(node, "expected_identifier", "Expected an identifier");
163322
+ }
163323
+ function expected_pattern(node) {
163324
+ e3(node, "expected_pattern", "Expected identifier or destructure pattern");
163325
+ }
163326
+ function expected_token(node, token) {
163327
+ e3(node, "expected_token", `Expected token ${token}`);
163328
+ }
163329
+ function expected_whitespace(node) {
163330
+ e3(node, "expected_whitespace", "Expected whitespace");
163331
+ }
163332
+ function js_parse_error(node, message) {
163333
+ e3(node, "js_parse_error", `${message}`);
163334
+ }
163335
+ function let_directive_invalid_placement(node) {
163336
+ e3(node, "let_directive_invalid_placement", "`let:` directive at invalid position");
163337
+ }
163338
+ function node_invalid_placement(node, thing, parent2) {
163339
+ e3(node, "node_invalid_placement", `${thing} is invalid inside <${parent2}>`);
163340
+ }
163341
+ function render_tag_invalid_call_expression(node) {
163342
+ e3(node, "render_tag_invalid_call_expression", "Calling a snippet function using apply, bind or call is not allowed");
163343
+ }
163344
+ function render_tag_invalid_expression(node) {
163345
+ e3(node, "render_tag_invalid_expression", "`{@render ...}` tags can only contain call expressions");
163346
+ }
163347
+ function render_tag_invalid_spread_argument(node) {
163348
+ e3(node, "render_tag_invalid_spread_argument", "cannot use spread arguments in `{@render ...}` tags");
163349
+ }
163350
+ function script_duplicate(node) {
163351
+ e3(node, "script_duplicate", 'A component can have a single top-level `<script>` element and/or a single top-level `<script context="module">` element');
163352
+ }
163353
+ function script_invalid_context(node) {
163354
+ e3(node, "script_invalid_context", 'If the context attribute is supplied, its value must be "module"');
163355
+ }
163356
+ function slot_attribute_duplicate(node, name, component) {
163357
+ e3(node, "slot_attribute_duplicate", `Duplicate slot name '${name}' in <${component}>`);
163358
+ }
163359
+ function slot_attribute_invalid(node) {
163360
+ e3(node, "slot_attribute_invalid", "slot attribute must be a static value");
163361
+ }
163362
+ function slot_attribute_invalid_placement(node) {
163363
+ e3(node, "slot_attribute_invalid_placement", "Element with a slot='...' attribute must be a child of a component or a descendant of a custom element");
163364
+ }
163365
+ function slot_default_duplicate(node) {
163366
+ e3(node, "slot_default_duplicate", 'Found default slot content alongside an explicit slot="default"');
163367
+ }
163368
+ function slot_element_invalid_attribute(node) {
163369
+ e3(node, "slot_element_invalid_attribute", "`<slot>` can only receive attributes and (optionally) let directives");
163370
+ }
163371
+ function slot_element_invalid_name(node) {
163372
+ e3(node, "slot_element_invalid_name", "slot attribute must be a static value");
163373
+ }
163374
+ function slot_element_invalid_name_default(node) {
163375
+ e3(node, "slot_element_invalid_name_default", "`default` is a reserved word \u2014 it cannot be used as a slot name");
163376
+ }
163377
+ function snippet_conflict(node) {
163378
+ e3(node, "snippet_conflict", "Cannot use explicit children snippet at the same time as implicit children content. Remove either the non-whitespace content or the children snippet block");
163379
+ }
163380
+ function snippet_shadowing_prop(node, prop2) {
163381
+ e3(node, "snippet_shadowing_prop", `This snippet is shadowing the prop \`${prop2}\` with the same name`);
163382
+ }
163383
+ function style_directive_invalid_modifier(node) {
163384
+ e3(node, "style_directive_invalid_modifier", "`style:` directive can only use the `important` modifier");
163385
+ }
163386
+ function style_duplicate(node) {
163387
+ e3(node, "style_duplicate", "A component can have a single top-level `<style>` element");
163388
+ }
163389
+ function svelte_component_invalid_this(node) {
163390
+ e3(node, "svelte_component_invalid_this", "Invalid component definition \u2014 must be an `{expression}`");
163391
+ }
163392
+ function svelte_component_missing_this(node) {
163393
+ e3(node, "svelte_component_missing_this", "`<svelte:component>` must have a 'this' attribute");
163394
+ }
163395
+ function svelte_element_missing_this(node) {
163396
+ e3(node, "svelte_element_missing_this", "`<svelte:element>` must have a 'this' attribute with a value");
163397
+ }
163398
+ function svelte_fragment_invalid_attribute(node) {
163399
+ e3(node, "svelte_fragment_invalid_attribute", "`<svelte:fragment>` can only have a slot attribute and (optionally) a let: directive");
163400
+ }
163401
+ function svelte_fragment_invalid_placement(node) {
163402
+ e3(node, "svelte_fragment_invalid_placement", "`<svelte:fragment>` must be the direct child of a component");
163403
+ }
163404
+ function svelte_head_illegal_attribute(node) {
163405
+ e3(node, "svelte_head_illegal_attribute", "`<svelte:head>` cannot have attributes nor directives");
163406
+ }
163407
+ function svelte_meta_duplicate(node, name) {
163408
+ e3(node, "svelte_meta_duplicate", `A component can only have one \`<${name}>\` element`);
163409
+ }
163410
+ function svelte_meta_invalid_content(node, name) {
163411
+ e3(node, "svelte_meta_invalid_content", `<${name}> cannot have children`);
163412
+ }
163413
+ function svelte_meta_invalid_placement(node, name) {
163414
+ e3(node, "svelte_meta_invalid_placement", `\`<${name}>\` tags cannot be inside elements or blocks`);
163415
+ }
163416
+ function svelte_meta_invalid_tag(node, list3) {
163417
+ e3(node, "svelte_meta_invalid_tag", `Valid \`<svelte:...>\` tag names are ${list3}`);
163418
+ }
163419
+ function svelte_options_deprecated_tag(node) {
163420
+ e3(node, "svelte_options_deprecated_tag", '"tag" option is deprecated \u2014 use "customElement" instead');
163421
+ }
163422
+ function svelte_options_invalid_attribute(node) {
163423
+ e3(node, "svelte_options_invalid_attribute", "`<svelte:options>` can only receive static attributes");
163424
+ }
163425
+ function svelte_options_invalid_attribute_value(node, list3) {
163426
+ e3(node, "svelte_options_invalid_attribute_value", `Valid values are ${list3}`);
163427
+ }
163428
+ function svelte_options_invalid_customelement(node) {
163429
+ e3(node, "svelte_options_invalid_customelement", '"customElement" must be a string literal defining a valid custom element name or an object of the form { tag: string; shadow?: "open" | "none"; props?: { [key: string]: { attribute?: string; reflect?: boolean; type: .. } } }');
163430
+ }
163431
+ function svelte_options_invalid_customelement_props(node) {
163432
+ e3(node, "svelte_options_invalid_customelement_props", '"props" must be a statically analyzable object literal of the form "{ [key: string]: { attribute?: string; reflect?: boolean; type?: "String" | "Boolean" | "Number" | "Array" | "Object" }"');
163433
+ }
163434
+ function svelte_options_invalid_customelement_shadow(node) {
163435
+ e3(node, "svelte_options_invalid_customelement_shadow", '"shadow" must be either "open" or "none"');
163436
+ }
163437
+ function svelte_options_invalid_tagname(node) {
163438
+ e3(node, "svelte_options_invalid_tagname", 'Tag name must be two or more words joined by the "-" character');
163439
+ }
163440
+ function svelte_options_unknown_attribute(node, name) {
163441
+ e3(node, "svelte_options_unknown_attribute", `\`<svelte:options>\` unknown attribute '${name}'`);
163442
+ }
163443
+ function svelte_self_invalid_placement(node) {
163444
+ e3(node, "svelte_self_invalid_placement", "`<svelte:self>` components can only exist inside `{#if}` blocks, `{#each}` blocks, `{#snippet}` blocks or slots passed to components");
163445
+ }
163446
+ function tag_invalid_placement(node, name, location) {
163447
+ e3(node, "tag_invalid_placement", `{@${name} ...} tag cannot be ${location}`);
163448
+ }
163449
+ function textarea_invalid_content(node) {
163450
+ e3(node, "textarea_invalid_content", "A `<textarea>` can have either a value attribute or (equivalently) child content, but not both");
163451
+ }
163452
+ function title_illegal_attribute(node) {
163453
+ e3(node, "title_illegal_attribute", "`<title>` cannot have attributes nor directives");
163454
+ }
163455
+ function title_invalid_content(node) {
163456
+ e3(node, "title_invalid_content", "`<title>` can only contain text and {tags}");
163457
+ }
163458
+ function transition_conflict(node, type, existing) {
163459
+ e3(node, "transition_conflict", `Cannot use \`${type}:\` alongside existing \`${existing}:\` directive`);
163460
+ }
163461
+ function transition_duplicate(node, type) {
163462
+ e3(node, "transition_duplicate", `Cannot use multiple \`${type}:\` directives on a single element`);
163321
163463
  }
163322
- function get_comment_handlers(source) {
163323
- const comments = [];
163324
- return {
163325
- onComment: (block4, value, start, end) => {
163326
- if (block4 && /\n/.test(value)) {
163327
- let a2 = start;
163328
- while (a2 > 0 && source[a2 - 1] !== "\n")
163329
- a2 -= 1;
163330
- let b2 = a2;
163331
- while (/[ \t]/.test(source[b2]))
163332
- b2 += 1;
163333
- const indentation = source.slice(a2, b2);
163334
- value = value.replace(new RegExp(`^${indentation}`, "gm"), "");
163335
- }
163336
- comments.push({ type: block4 ? "Block" : "Line", value, start, end });
163337
- },
163338
- add_comments(ast) {
163339
- if (comments.length === 0)
163340
- return;
163341
- walk2(ast, null, {
163342
- _(node, { next: next2 }) {
163343
- let comment;
163344
- while (comments[0] && comments[0].start < node.start) {
163345
- comment = comments.shift();
163346
- (node.leadingComments ||= []).push(comment);
163347
- }
163348
- next2();
163349
- if (comments[0]) {
163350
- const slice = source.slice(node.end, comments[0].start);
163351
- if (/^[,) \t]*$/.test(slice)) {
163352
- node.trailingComments = [comments.shift()];
163353
- }
163354
- }
163355
- }
163356
- });
163357
- }
163358
- };
163464
+ function unexpected_eof(node) {
163465
+ e3(node, "unexpected_eof", "Unexpected end of input");
163359
163466
  }
163360
- function amend(source, node) {
163361
- return walk2(node, null, {
163362
- _(node2, context) {
163363
- delete node2.loc.start.index;
163364
- delete node2.loc.end.index;
163365
- if (node2.typeAnnotation && node2.end === void 0) {
163366
- let end = node2.typeAnnotation.start;
163367
- while (/\s/.test(source[end - 1]))
163368
- end -= 1;
163369
- node2.end = end;
163370
- }
163371
- context.next();
163372
- }
163373
- });
163467
+ function unexpected_reserved_word(node, word) {
163468
+ e3(node, "unexpected_reserved_word", `'${word}' is a reserved word in JavaScript and cannot be used here`);
163374
163469
  }
163375
-
163376
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/1-parse/utils/names.js
163377
- var reserved = [
163378
- "arguments",
163379
- "await",
163380
- "break",
163381
- "case",
163382
- "catch",
163383
- "class",
163384
- "const",
163385
- "continue",
163386
- "debugger",
163387
- "default",
163388
- "delete",
163389
- "do",
163390
- "else",
163391
- "enum",
163392
- "eval",
163393
- "export",
163394
- "extends",
163395
- "false",
163396
- "finally",
163397
- "for",
163398
- "function",
163399
- "if",
163400
- "implements",
163401
- "import",
163402
- "in",
163403
- "instanceof",
163404
- "interface",
163405
- "let",
163406
- "new",
163407
- "null",
163408
- "package",
163409
- "private",
163410
- "protected",
163411
- "public",
163412
- "return",
163413
- "static",
163414
- "super",
163415
- "switch",
163416
- "this",
163417
- "throw",
163418
- "true",
163419
- "try",
163420
- "typeof",
163421
- "var",
163422
- "void",
163423
- "while",
163424
- "with",
163425
- "yield"
163426
- ];
163427
- var void_element_names = [
163428
- "area",
163429
- "base",
163430
- "br",
163431
- "col",
163432
- "command",
163433
- "embed",
163434
- "hr",
163435
- "img",
163436
- "input",
163437
- "keygen",
163438
- "link",
163439
- "meta",
163440
- "param",
163441
- "source",
163442
- "track",
163443
- "wbr"
163444
- ];
163445
- function is_void(name) {
163446
- return void_element_names.includes(name) || name.toLowerCase() === "!doctype";
163470
+ function void_element_invalid_content(node) {
163471
+ e3(node, "void_element_invalid_content", "Void elements cannot have children or closing tags");
163447
163472
  }
163448
163473
 
163449
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/1-parse/read/expression.js
163474
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/1-parse/read/expression.js
163450
163475
  function read_expression(parser) {
163451
163476
  try {
163452
163477
  const node = parse_expression_at(parser.template, parser.ts, parser.index);
@@ -163472,7 +163497,7 @@ function read_expression(parser) {
163472
163497
  }
163473
163498
  }
163474
163499
 
163475
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/1-parse/read/script.js
163500
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/1-parse/read/script.js
163476
163501
  var regex_closing_script_tag = /<\/script\s*>/;
163477
163502
  var regex_starts_with_closing_script_tag = /^<\/script\s*>/;
163478
163503
  function get_context(attributes) {
@@ -163516,7 +163541,7 @@ function read_script(parser, start, attributes) {
163516
163541
  };
163517
163542
  }
163518
163543
 
163519
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/1-parse/read/style.js
163544
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/1-parse/read/style.js
163520
163545
  var REGEX_MATCHER = /^[~^$*|]?=/;
163521
163546
  var REGEX_CLOSING_BRACKET = /[\s\]]/;
163522
163547
  var REGEX_ATTRIBUTE_FLAGS = /^[a-zA-Z]+/;
@@ -163604,7 +163629,7 @@ function read_selector_list(parser, inside_pseudo_class = false) {
163604
163629
  while (parser.index < parser.template.length) {
163605
163630
  children.push(read_selector(parser, inside_pseudo_class));
163606
163631
  const end = parser.index;
163607
- parser.allow_whitespace();
163632
+ allow_comment_or_whitespace(parser);
163608
163633
  if (inside_pseudo_class ? parser.match(")") : parser.match("{")) {
163609
163634
  return {
163610
163635
  type: "SelectorList",
@@ -163746,7 +163771,7 @@ function read_selector(parser, inside_pseudo_class = false) {
163746
163771
  });
163747
163772
  }
163748
163773
  const index = parser.index;
163749
- parser.allow_whitespace();
163774
+ allow_comment_or_whitespace(parser);
163750
163775
  if (parser.match(",") || (inside_pseudo_class ? parser.match(")") : parser.match("{"))) {
163751
163776
  parser.index = index;
163752
163777
  relative_selector.end = index;
@@ -163952,7 +163977,7 @@ function allow_comment_or_whitespace(parser) {
163952
163977
  }
163953
163978
  }
163954
163979
 
163955
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/constants.js
163980
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/constants.js
163956
163981
  var EACH_ITEM_REACTIVE = 1;
163957
163982
  var EACH_INDEX_REACTIVE = 1 << 1;
163958
163983
  var EACH_KEYED = 1 << 2;
@@ -163971,6 +163996,8 @@ var TEMPLATE_USE_IMPORT_NODE = 1 << 1;
163971
163996
  var HYDRATION_START = "[";
163972
163997
  var HYDRATION_END = "]";
163973
163998
  var HYDRATION_END_ELSE = `${HYDRATION_END}!`;
163999
+ var ELEMENT_IS_NAMESPACED = 1;
164000
+ var ELEMENT_PRESERVE_ATTRIBUTE_CASE = 1 << 1;
163974
164001
  var UNINITIALIZED = Symbol();
163975
164002
  var AttributeAliases = {
163976
164003
  formnovalidate: "formNoValidate",
@@ -164104,7 +164131,7 @@ function is_tag_valid_with_parent(tag2, parent_tag) {
164104
164131
  return true;
164105
164132
  }
164106
164133
 
164107
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/1-parse/utils/entities.js
164134
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/1-parse/utils/entities.js
164108
164135
  var entities_default = {
164109
164136
  "CounterClockwiseContourIntegral;": 8755,
164110
164137
  "ClockwiseContourIntegral;": 8754,
@@ -166339,7 +166366,7 @@ var entities_default = {
166339
166366
  lt: 60
166340
166367
  };
166341
166368
 
166342
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/1-parse/utils/html.js
166369
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/1-parse/utils/html.js
166343
166370
  var windows_1252 = [
166344
166371
  8364,
166345
166372
  129,
@@ -166470,7 +166497,7 @@ function closing_tag_omitted(current2, next2) {
166470
166497
  return false;
166471
166498
  }
166472
166499
 
166473
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/1-parse/utils/create.js
166500
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/1-parse/utils/create.js
166474
166501
  function create_fragment(transparent = false) {
166475
166502
  return {
166476
166503
  type: "Fragment",
@@ -166479,7 +166506,7 @@ function create_fragment(transparent = false) {
166479
166506
  };
166480
166507
  }
166481
166508
 
166482
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/nodes.js
166509
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/nodes.js
166483
166510
  var element_nodes = [
166484
166511
  "SvelteElement",
166485
166512
  "RegularElement",
@@ -166493,7 +166520,7 @@ function is_element_node(node) {
166493
166520
  return element_nodes.includes(node.type);
166494
166521
  }
166495
166522
  function is_custom_element_node(node) {
166496
- return node.name.includes("-");
166523
+ return node.type === "RegularElement" && node.name.includes("-");
166497
166524
  }
166498
166525
  function create_attribute(name, start, end, value) {
166499
166526
  return {
@@ -166510,7 +166537,7 @@ function create_attribute(name, start, end, value) {
166510
166537
  };
166511
166538
  }
166512
166539
 
166513
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/1-parse/state/element.js
166540
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/1-parse/state/element.js
166514
166541
  var valid_tag_name = /^\!?[a-zA-Z]{1,}:?[a-zA-Z0-9\-]*/;
166515
166542
  var regex_starts_with_invalid_attr_value = /^(\/>|[\s"'=<>`])/;
166516
166543
  var root_only_meta_tags = /* @__PURE__ */ new Map([
@@ -166657,7 +166684,7 @@ function tag(parser) {
166657
166684
  while (attribute = read(parser)) {
166658
166685
  if (attribute.type === "Attribute" || attribute.type === "BindDirective") {
166659
166686
  if (unique_names.includes(attribute.name)) {
166660
- attribute_duplicate(attribute.start);
166687
+ attribute_duplicate(attribute);
166661
166688
  } else if (attribute.name !== "this") {
166662
166689
  unique_names.push(attribute.name);
166663
166690
  }
@@ -166686,11 +166713,23 @@ function tag(parser) {
166686
166713
  svelte_element_missing_this(start);
166687
166714
  }
166688
166715
  const definition = element.attributes.splice(index, 1)[0];
166689
- if (definition.value === true || definition.value.length !== 1) {
166690
- svelte_element_invalid_this(definition.start);
166716
+ if (definition.value === true) {
166717
+ svelte_element_missing_this(definition);
166691
166718
  }
166692
166719
  const chunk = definition.value[0];
166693
- element.tag = chunk.type === "Text" ? { type: "Literal", value: chunk.data, raw: `'${chunk.raw}'` } : chunk.expression;
166720
+ if (definition.value.length !== 1 || chunk.type !== "ExpressionTag") {
166721
+ chunk.type;
166722
+ svelte_element_invalid_this(definition);
166723
+ element.tag = chunk.type === "Text" ? {
166724
+ type: "Literal",
166725
+ value: chunk.data,
166726
+ raw: `'${chunk.raw}'`,
166727
+ start: chunk.start,
166728
+ end: chunk.end
166729
+ } : chunk.expression;
166730
+ } else {
166731
+ element.tag = chunk.expression;
166732
+ }
166694
166733
  }
166695
166734
  if (is_top_level_script_or_style) {
166696
166735
  parser.eat(">", true);
@@ -167083,7 +167122,7 @@ function read_sequence(parser, done, location) {
167083
167122
  unexpected_eof(parser.template.length);
167084
167123
  }
167085
167124
 
167086
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/1-parse/utils/full_char_code_at.js
167125
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/1-parse/utils/full_char_code_at.js
167087
167126
  function full_char_code_at(str, i3) {
167088
167127
  const code = str.charCodeAt(i3);
167089
167128
  if (code <= 55295 || code >= 57344)
@@ -167092,7 +167131,7 @@ function full_char_code_at(str, i3) {
167092
167131
  return (code << 10) + next2 - 56613888;
167093
167132
  }
167094
167133
 
167095
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/1-parse/utils/bracket.js
167134
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/1-parse/utils/bracket.js
167096
167135
  var SQUARE_BRACKET_OPEN = "[".charCodeAt(0);
167097
167136
  var SQUARE_BRACKET_CLOSE = "]".charCodeAt(0);
167098
167137
  var CURLY_BRACKET_OPEN = "{".charCodeAt(0);
@@ -167115,7 +167154,7 @@ function get_bracket_close(open2) {
167115
167154
  }
167116
167155
  }
167117
167156
 
167118
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/1-parse/read/context.js
167157
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/1-parse/read/context.js
167119
167158
  function read_pattern(parser, optional_allowed = false) {
167120
167159
  const start = parser.index;
167121
167160
  let i3 = parser.index;
@@ -167204,7 +167243,7 @@ function read_type_annotation(parser, optional_allowed = false) {
167204
167243
  };
167205
167244
  }
167206
167245
 
167207
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/1-parse/state/tag.js
167246
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/1-parse/state/tag.js
167208
167247
  var regex_whitespace_with_closing_curly_brace = /^\s*}/;
167209
167248
  function mustache(parser) {
167210
167249
  const start = parser.index;
@@ -167644,7 +167683,7 @@ function special(parser) {
167644
167683
  }
167645
167684
  }
167646
167685
 
167647
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/1-parse/state/text.js
167686
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/1-parse/state/text.js
167648
167687
  function text(parser) {
167649
167688
  const start = parser.index;
167650
167689
  let data2 = "";
@@ -167660,7 +167699,7 @@ function text(parser) {
167660
167699
  });
167661
167700
  }
167662
167701
 
167663
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/1-parse/state/fragment.js
167702
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/1-parse/state/fragment.js
167664
167703
  function fragment(parser) {
167665
167704
  if (parser.match("<")) {
167666
167705
  return tag;
@@ -167671,7 +167710,7 @@ function fragment(parser) {
167671
167710
  return text;
167672
167711
  }
167673
167712
 
167674
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/1-parse/read/options.js
167713
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/1-parse/read/options.js
167675
167714
  var regex_valid_tag_name = /^[a-zA-Z][a-zA-Z0-9]*-[a-zA-Z0-9-]+$/;
167676
167715
  function read_options(node) {
167677
167716
  const component_options = {
@@ -167846,7 +167885,7 @@ function validate_tag(attribute, tag2) {
167846
167885
  }
167847
167886
  }
167848
167887
 
167849
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/1-parse/index.js
167888
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/1-parse/index.js
167850
167889
  var regex_position_indicator = / \(\d+:\d+\)$/;
167851
167890
  var regex_lang_attribute = /<!--[^]*?-->|<script\s+(?:[^>]*|(?:[^=>'"/]+=(?:"[^"]*"|'[^']*'|[^>\s]+)\s+)*)lang=(["'])?([^"' >]+)\1[^>]*>/g;
167852
167891
  var Parser3 = class {
@@ -168030,12 +168069,12 @@ function parse15(template2) {
168030
168069
  return parser.root;
168031
168070
  }
168032
168071
 
168033
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/utils/sanitize_template_string.js
168072
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/utils/sanitize_template_string.js
168034
168073
  function sanitize_template_string(str) {
168035
168074
  return str.replace(/(`|\${|\\)/g, "\\$1");
168036
168075
  }
168037
168076
 
168038
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/utils/builders.js
168077
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/utils/builders.js
168039
168078
  function array(elements = []) {
168040
168079
  return { type: "ArrayExpression", elements };
168041
168080
  }
@@ -168307,7 +168346,7 @@ function is_reference(node, parent2) {
168307
168346
  return false;
168308
168347
  }
168309
168348
 
168310
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/utils/ast.js
168349
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/utils/ast.js
168311
168350
  function object2(expression) {
168312
168351
  while (expression.type === "MemberExpression") {
168313
168352
  expression = expression.object;
@@ -168578,7 +168617,7 @@ function is_expression_async(expression) {
168578
168617
  }
168579
168618
  }
168580
168619
 
168581
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/constants.js
168620
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/constants.js
168582
168621
  var DOMProperties = [
168583
168622
  ...Object.values(AttributeAliases),
168584
168623
  "value",
@@ -168608,6 +168647,7 @@ var Runes = [
168608
168647
  "$state",
168609
168648
  "$state.frozen",
168610
168649
  "$state.snapshot",
168650
+ "$state.is",
168611
168651
  "$props",
168612
168652
  "$bindable",
168613
168653
  "$derived",
@@ -168622,6 +168662,17 @@ var Runes = [
168622
168662
  ];
168623
168663
  var WhitespaceInsensitiveAttributes = ["class", "style"];
168624
168664
  var ContentEditableBindings = ["textContent", "innerHTML", "innerText"];
168665
+ var LoadErrorElements = [
168666
+ "body",
168667
+ "embed",
168668
+ "iframe",
168669
+ "img",
168670
+ "link",
168671
+ "object",
168672
+ "script",
168673
+ "style",
168674
+ "track"
168675
+ ];
168625
168676
  var SVGElements = [
168626
168677
  "altGlyph",
168627
168678
  "altGlyphDef",
@@ -168722,7 +168773,7 @@ var EventModifiers = [
168722
168773
  "trusted"
168723
168774
  ];
168724
168775
 
168725
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/scope.js
168776
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/scope.js
168726
168777
  function get_rune(node, scope) {
168727
168778
  if (!node)
168728
168779
  return null;
@@ -168753,7 +168804,7 @@ function get_rune(node, scope) {
168753
168804
  return joined;
168754
168805
  }
168755
168806
 
168756
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/visitors.js
168807
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/visitors.js
168757
168808
  var overrides = {
168758
168809
  visit() {
168759
168810
  throw new Error("Cannot call visit() during analysis");
@@ -168800,7 +168851,7 @@ function merge(...tasks) {
168800
168851
  return combined;
168801
168852
  }
168802
168853
 
168803
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/bindings.js
168854
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/bindings.js
168804
168855
  var binding_properties = {
168805
168856
  currentTime: {
168806
168857
  valid_elements: ["audio", "video"],
@@ -168916,28 +168967,36 @@ var binding_properties = {
168916
168967
  omit_in_ssr: true
168917
168968
  },
168918
168969
  clientWidth: {
168919
- omit_in_ssr: true
168970
+ omit_in_ssr: true,
168971
+ invalid_elements: ["svelte:window", "svelte:document"]
168920
168972
  },
168921
168973
  clientHeight: {
168922
- omit_in_ssr: true
168974
+ omit_in_ssr: true,
168975
+ invalid_elements: ["svelte:window", "svelte:document"]
168923
168976
  },
168924
168977
  offsetWidth: {
168925
- omit_in_ssr: true
168978
+ omit_in_ssr: true,
168979
+ invalid_elements: ["svelte:window", "svelte:document"]
168926
168980
  },
168927
168981
  offsetHeight: {
168928
- omit_in_ssr: true
168982
+ omit_in_ssr: true,
168983
+ invalid_elements: ["svelte:window", "svelte:document"]
168929
168984
  },
168930
168985
  contentRect: {
168931
- omit_in_ssr: true
168986
+ omit_in_ssr: true,
168987
+ invalid_elements: ["svelte:window", "svelte:document"]
168932
168988
  },
168933
168989
  contentBoxSize: {
168934
- omit_in_ssr: true
168990
+ omit_in_ssr: true,
168991
+ invalid_elements: ["svelte:window", "svelte:document"]
168935
168992
  },
168936
168993
  borderBoxSize: {
168937
- omit_in_ssr: true
168994
+ omit_in_ssr: true,
168995
+ invalid_elements: ["svelte:window", "svelte:document"]
168938
168996
  },
168939
168997
  devicePixelContentBoxSize: {
168940
- omit_in_ssr: true
168998
+ omit_in_ssr: true,
168999
+ invalid_elements: ["svelte:window", "svelte:document"]
168941
169000
  },
168942
169001
  indeterminate: {
168943
169002
  event: "change",
@@ -168954,9 +169013,15 @@ var binding_properties = {
168954
169013
  this: {
168955
169014
  omit_in_ssr: true
168956
169015
  },
168957
- innerText: {},
168958
- innerHTML: {},
168959
- textContent: {},
169016
+ innerText: {
169017
+ invalid_elements: ["svelte:window", "svelte:document"]
169018
+ },
169019
+ innerHTML: {
169020
+ invalid_elements: ["svelte:window", "svelte:document"]
169021
+ },
169022
+ textContent: {
169023
+ invalid_elements: ["svelte:window", "svelte:document"]
169024
+ },
168960
169025
  open: {
168961
169026
  event: "toggle",
168962
169027
  type: "set",
@@ -168971,11 +169036,11 @@ var binding_properties = {
168971
169036
  }
168972
169037
  };
168973
169038
 
168974
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/2-analyze/a11y.js
169039
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/2-analyze/a11y.js
168975
169040
  var import_aria_query = __toESM(require_lib8(), 1);
168976
169041
  var import_axobject_query = __toESM(require_lib9(), 1);
168977
169042
 
168978
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/utils/string.js
169043
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/utils/string.js
168979
169044
  function list(strings, conjunction = "or") {
168980
169045
  if (strings.length === 1)
168981
169046
  return strings[0];
@@ -168984,7 +169049,7 @@ function list(strings, conjunction = "or") {
168984
169049
  return `${strings.slice(0, -1).join(", ")} ${conjunction} ${strings[strings.length - 1]}`;
168985
169050
  }
168986
169051
 
168987
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/2-analyze/a11y.js
169052
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/2-analyze/a11y.js
168988
169053
  var aria_roles = import_aria_query.roles.keys();
168989
169054
  var abstract_roles = aria_roles.filter((role) => import_aria_query.roles.get(role)?.abstract);
168990
169055
  var non_abstract_roles = aria_roles.filter((name) => !abstract_roles.includes(name));
@@ -169806,7 +169871,7 @@ var a11y_validators = {
169806
169871
  }
169807
169872
  };
169808
169873
 
169809
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/2-analyze/validation.js
169874
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/2-analyze/validation.js
169810
169875
  function validate_component(node, context) {
169811
169876
  for (const attribute of node.attributes) {
169812
169877
  if (attribute.type !== "Attribute" && attribute.type !== "SpreadAttribute" && attribute.type !== "LetDirective" && attribute.type !== "OnDirective" && attribute.type !== "BindDirective") {
@@ -170043,6 +170108,16 @@ var validation = {
170043
170108
  property.valid_elements.map((valid_element) => `<${valid_element}>`).join(", ")
170044
170109
  );
170045
170110
  }
170111
+ if (property.invalid_elements && property.invalid_elements.includes(parent2.name)) {
170112
+ const valid_bindings = Object.entries(binding_properties).filter(([_, binding_property]) => {
170113
+ return binding_property.valid_elements?.includes(parent2.name) || !binding_property.valid_elements && !binding_property.invalid_elements?.includes(parent2.name);
170114
+ }).map(([property_name]) => property_name);
170115
+ bind_invalid_name(
170116
+ node,
170117
+ node.name,
170118
+ `Possible bindings for <${parent2.name}> are ${valid_bindings.join(", ")}`
170119
+ );
170120
+ }
170046
170121
  if (parent2.name === "input" && node.name !== "this") {
170047
170122
  const type = parent2.attributes.find((a2) => a2.type === "Attribute" && a2.name === "type");
170048
170123
  if (type && !is_text_attribute(type)) {
@@ -170174,16 +170249,6 @@ var validation = {
170174
170249
  if (callee.type === "MemberExpression" && callee.property.type === "Identifier" && ["bind", "apply", "call"].includes(callee.property.name)) {
170175
170250
  render_tag_invalid_call_expression(node);
170176
170251
  }
170177
- const is_inside_textarea = context.path.find((n2) => {
170178
- return n2.type === "SvelteElement" && n2.name === "svelte:element" && n2.tag.type === "Literal" && n2.tag.value === "textarea";
170179
- });
170180
- if (is_inside_textarea) {
170181
- tag_invalid_placement(
170182
- node,
170183
- 'inside <textarea> or <svelte:element this="textarea">',
170184
- "render"
170185
- );
170186
- }
170187
170252
  },
170188
170253
  IfBlock(node, context) {
170189
170254
  validate_block_not_empty(node.consequent, context);
@@ -170204,12 +170269,17 @@ var validation = {
170204
170269
  SnippetBlock(node, context) {
170205
170270
  validate_block_not_empty(node.body, context);
170206
170271
  context.next({ ...context.state, parent_element: null });
170207
- if (node.expression.name !== "children")
170208
- return;
170209
170272
  const { path: path3 } = context;
170210
170273
  const parent2 = path3.at(-2);
170211
170274
  if (!parent2)
170212
170275
  return;
170276
+ if (parent2.type === "Component" && parent2.attributes.some(
170277
+ (attribute) => (attribute.type === "Attribute" || attribute.type === "BindDirective") && attribute.name === node.expression.name
170278
+ )) {
170279
+ snippet_shadowing_prop(node, node.expression.name);
170280
+ }
170281
+ if (node.expression.name !== "children")
170282
+ return;
170213
170283
  if (parent2.type === "Component" || parent2.type === "SvelteComponent" || parent2.type === "SvelteSelf") {
170214
170284
  if (parent2.fragment.nodes.some(
170215
170285
  (node2) => node2.type !== "SnippetBlock" && (node2.type !== "Text" || node2.data.trim())
@@ -170401,6 +170471,11 @@ function validate_call_expression(node, scope, path3) {
170401
170471
  rune_invalid_arguments_length(node, rune, "exactly one argument");
170402
170472
  }
170403
170473
  }
170474
+ if (rune === "$state.is") {
170475
+ if (node.arguments.length !== 2) {
170476
+ rune_invalid_arguments_length(node, rune, "exactly two arguments");
170477
+ }
170478
+ }
170404
170479
  }
170405
170480
  function ensure_no_module_import_conflict(node, state) {
170406
170481
  const ids = extract_identifiers(node.id);
@@ -170411,6 +170486,11 @@ function ensure_no_module_import_conflict(node, state) {
170411
170486
  }
170412
170487
  }
170413
170488
  var validation_runes_js = {
170489
+ ImportDeclaration(node) {
170490
+ if (typeof node.source.value === "string" && node.source.value.startsWith("svelte/internal")) {
170491
+ import_svelte_internal_forbidden(node);
170492
+ }
170493
+ },
170414
170494
  ExportSpecifier(node, { state }) {
170415
170495
  validate_export(node, state.scope, node.local.name);
170416
170496
  },
@@ -170533,6 +170613,11 @@ function validate_assignment(node, argument, state) {
170533
170613
  }
170534
170614
  }
170535
170615
  var validation_runes = merge(validation, a11y_validators, {
170616
+ ImportDeclaration(node) {
170617
+ if (typeof node.source.value === "string" && node.source.value.startsWith("svelte/internal")) {
170618
+ import_svelte_internal_forbidden(node);
170619
+ }
170620
+ },
170536
170621
  Identifier(node, { path: path3, state }) {
170537
170622
  let i3 = path3.length;
170538
170623
  let parent2 = path3[--i3];
@@ -170664,7 +170749,7 @@ var validation_runes = merge(validation, a11y_validators, {
170664
170749
  NewExpression: validation_runes_js.NewExpression
170665
170750
  });
170666
170751
 
170667
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/3-transform/client/utils.js
170752
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/3-transform/client/utils.js
170668
170753
  function get_assignment_value(node, { state, visit: visit24 }) {
170669
170754
  if (node.left.type === "Identifier") {
170670
170755
  const operator = node.operator;
@@ -171025,14 +171110,14 @@ function with_loc(target, source) {
171025
171110
  return target;
171026
171111
  }
171027
171112
 
171028
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/css.js
171113
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/css.js
171029
171114
  var regex_css_browser_prefix = /^-((webkit)|(moz)|(o)|(ms))-/;
171030
171115
  function remove_css_prefix(name) {
171031
171116
  return name.replace(regex_css_browser_prefix, "");
171032
171117
  }
171033
171118
  var is_keyframes_node = (node) => remove_css_prefix(node.name) === "keyframes";
171034
171119
 
171035
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/2-analyze/css/css-analyze.js
171120
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/2-analyze/css/css-analyze.js
171036
171121
  function is_global(relative_selector) {
171037
171122
  const first = relative_selector.selectors[0];
171038
171123
  return first.type === "PseudoClassSelector" && first.name === "global" && relative_selector.selectors.every(
@@ -172223,7 +172308,7 @@ if (typeof window !== "undefined" && typeof window.btoa === "function") {
172223
172308
  btoa2 = (str) => Buffer.from(str, "utf-8").toString("base64");
172224
172309
  }
172225
172310
 
172226
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/3-transform/utils.js
172311
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/3-transform/utils.js
172227
172312
  function is_hoistable_function(node) {
172228
172313
  if (node.type === "ArrowFunctionExpression" || node.type === "FunctionExpression" || node.type === "FunctionDeclaration") {
172229
172314
  return node.metadata?.hoistable === true;
@@ -172380,7 +172465,7 @@ function transform_inspect_rune(node, context) {
172380
172465
  }
172381
172466
  }
172382
172467
 
172383
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/escaping.js
172468
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/escaping.js
172384
172469
  var ATTR_REGEX = /[&"<]/g;
172385
172470
  var CONTENT_REGEX = /[&<]/g;
172386
172471
  function escape_html(value, is_attr) {
@@ -172398,12 +172483,12 @@ function escape_html(value, is_attr) {
172398
172483
  return escaped + str.substring(last);
172399
172484
  }
172400
172485
 
172401
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/internal/server/hydration.js
172486
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/internal/server/hydration.js
172402
172487
  var BLOCK_OPEN = `<!--${HYDRATION_START}-->`;
172403
172488
  var BLOCK_CLOSE = `<!--${HYDRATION_END}-->`;
172404
172489
  var BLOCK_CLOSE_ELSE = `<!--${HYDRATION_END_ELSE}-->`;
172405
172490
 
172406
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/3-transform/server/transform-server.js
172491
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/3-transform/server/transform-server.js
172407
172492
  var block_open = t_string(`<!--${HYDRATION_START}-->`);
172408
172493
  var block_close = t_string(`<!--${HYDRATION_END}-->`);
172409
172494
  function t_string(value) {
@@ -172750,6 +172835,12 @@ var javascript_visitors_runes = {
172750
172835
  if (rune === "$state.snapshot") {
172751
172836
  return context.visit(node.arguments[0]);
172752
172837
  }
172838
+ if (rune === "$state.is") {
172839
+ return call(
172840
+ "Object.is",
172841
+ context.visit(node.arguments[0])
172842
+ );
172843
+ }
172753
172844
  if (rune === "$inspect" || rune === "$inspect().with") {
172754
172845
  return transform_inspect_rune(node, context);
172755
172846
  }
@@ -172810,52 +172901,50 @@ function serialize_attribute_value(attribute_value, context, trim_whitespace = f
172810
172901
  return template(quasis, expressions);
172811
172902
  }
172812
172903
  function serialize_element_spread_attributes(element, attributes, style_directives, class_directives, context) {
172813
- const values = [];
172814
- for (const attribute of attributes) {
172815
- if (attribute.type === "Attribute") {
172816
- const name = get_attribute_name(element, attribute, context);
172817
- const value = serialize_attribute_value(
172818
- attribute.value,
172819
- context,
172820
- WhitespaceInsensitiveAttributes.includes(name)
172821
- );
172822
- values.push(object([prop("init", literal2(name), value)]));
172823
- } else {
172824
- values.push(context.visit(attribute));
172904
+ let classes;
172905
+ let styles;
172906
+ let flags = 0;
172907
+ if (class_directives.length > 0 || context.state.analysis.css.hash) {
172908
+ const properties = class_directives.map(
172909
+ (directive) => init(
172910
+ directive.name,
172911
+ directive.expression.type === "Identifier" && directive.expression.name === directive.name ? id(directive.name) : context.visit(directive.expression)
172912
+ )
172913
+ );
172914
+ if (context.state.analysis.css.hash) {
172915
+ properties.unshift(init(context.state.analysis.css.hash, literal2(true)));
172825
172916
  }
172917
+ classes = object(properties);
172826
172918
  }
172827
- const lowercase_attributes = element.metadata.svg || element.metadata.mathml || element.type === "RegularElement" && is_custom_element_node(element) ? false_instance : true_instance;
172828
- const is_html = element.metadata.svg || element.metadata.mathml ? false_instance : true_instance;
172829
- const args = [
172830
- array(values),
172831
- lowercase_attributes,
172832
- is_html,
172833
- literal2(context.state.analysis.css.hash)
172834
- ];
172835
- if (style_directives.length > 0 || class_directives.length > 0) {
172836
- const styles = style_directives.map(
172919
+ if (style_directives.length > 0) {
172920
+ const properties = style_directives.map(
172837
172921
  (directive) => init(
172838
172922
  directive.name,
172839
172923
  directive.value === true ? id(directive.name) : serialize_attribute_value(directive.value, context, true)
172840
172924
  )
172841
172925
  );
172842
- const expressions = class_directives.map(
172843
- (directive) => conditional(directive.expression, literal2(directive.name), literal2(""))
172844
- );
172845
- const classes = expressions.length ? call(
172846
- member(
172847
- call(member(array(expressions), id("filter")), id("Boolean")),
172848
- id("join")
172849
- ),
172850
- literal2(" ")
172851
- ) : literal2("");
172852
- args.push(
172853
- object([
172854
- init("styles", styles.length === 0 ? literal2(null) : object(styles)),
172855
- init("classes", classes)
172856
- ])
172857
- );
172926
+ styles = object(properties);
172858
172927
  }
172928
+ if (element.metadata.svg || element.metadata.mathml) {
172929
+ flags |= ELEMENT_IS_NAMESPACED | ELEMENT_PRESERVE_ATTRIBUTE_CASE;
172930
+ } else if (is_custom_element_node(element)) {
172931
+ flags |= ELEMENT_PRESERVE_ATTRIBUTE_CASE;
172932
+ }
172933
+ const object4 = object(
172934
+ attributes.map((attribute) => {
172935
+ if (attribute.type === "Attribute") {
172936
+ const name = get_attribute_name(element, attribute, context);
172937
+ const value = serialize_attribute_value(
172938
+ attribute.value,
172939
+ context,
172940
+ WhitespaceInsensitiveAttributes.includes(name)
172941
+ );
172942
+ return prop("init", key(name), value);
172943
+ }
172944
+ return spread(context.visit(attribute));
172945
+ })
172946
+ );
172947
+ const args = [object4, classes, styles, flags ? literal2(flags) : void 0];
172859
172948
  context.state.template.push(t_expression(call("$.spread_attributes", ...args)));
172860
172949
  }
172861
172950
  function serialize_inline_component(node, component_name, context) {
@@ -172864,6 +172953,7 @@ function serialize_inline_component(node, component_name, context) {
172864
172953
  const lets = [];
172865
172954
  const children = {};
172866
172955
  let slot_scope_applies_to_itself = false;
172956
+ let has_children_prop = false;
172867
172957
  function push_prop(prop2) {
172868
172958
  const current2 = props_and_spreads.at(-1);
172869
172959
  const current_is_props = Array.isArray(current2);
@@ -172887,6 +172977,9 @@ function serialize_inline_component(node, component_name, context) {
172887
172977
  if (attribute.name === "slot") {
172888
172978
  slot_scope_applies_to_itself = true;
172889
172979
  }
172980
+ if (attribute.name === "children") {
172981
+ has_children_prop = true;
172982
+ }
172890
172983
  const value = serialize_attribute_value(attribute.value, context, false, true);
172891
172984
  push_prop(prop("init", key(attribute.name), value));
172892
172985
  } else if (attribute.type === "BindDirective" && attribute.name !== "this") {
@@ -172939,7 +173032,7 @@ function serialize_inline_component(node, component_name, context) {
172939
173032
  [id("$$payload"), id("$$slotProps")],
172940
173033
  block3([...slot_name === "default" && !slot_scope_applies_to_itself ? lets : [], ...body])
172941
173034
  );
172942
- if (slot_name === "default") {
173035
+ if (slot_name === "default" && !has_children_prop) {
172943
173036
  push_prop(
172944
173037
  prop(
172945
173038
  "init",
@@ -172947,6 +173040,7 @@ function serialize_inline_component(node, component_name, context) {
172947
173040
  context.state.options.dev ? call("$.add_snippet_symbol", slot_fn) : slot_fn
172948
173041
  )
172949
173042
  );
173043
+ serialized_slots.push(init("default", true_instance));
172950
173044
  } else {
172951
173045
  const slot = prop("init", literal2(slot_name), slot_fn);
172952
173046
  serialized_slots.push(slot);
@@ -173089,8 +173183,19 @@ var template_visitors = {
173089
173183
  inner_context.visit(node2, state);
173090
173184
  }
173091
173185
  if (context.state.options.dev) {
173186
+ const location = locator(node.start);
173092
173187
  context.state.template.push(
173093
- t_statement(stmt(call("$.push_element", literal2(node.name), id("$$payload"))))
173188
+ t_statement(
173189
+ stmt(
173190
+ call(
173191
+ "$.push_element",
173192
+ id("$$payload"),
173193
+ literal2(node.name),
173194
+ literal2(location.line),
173195
+ literal2(location.column)
173196
+ )
173197
+ )
173198
+ )
173094
173199
  );
173095
173200
  }
173096
173201
  process_children(trimmed, node, inner_context);
@@ -173388,7 +173493,7 @@ var template_visitors = {
173388
173493
  const props = [];
173389
173494
  const spreads = [];
173390
173495
  const lets = [];
173391
- let expression = member_id("$$props.children");
173496
+ let expression = call("$.default_slot", id("$$props"));
173392
173497
  for (const attribute of node.attributes) {
173393
173498
  if (attribute.type === "SpreadAttribute") {
173394
173499
  spreads.push(context.visit(attribute));
@@ -173434,14 +173539,26 @@ function serialize_element_attributes(node, context) {
173434
173539
  let has_spread = false;
173435
173540
  let class_attribute_idx = -1;
173436
173541
  let style_attribute_idx = -1;
173542
+ let events_to_capture = /* @__PURE__ */ new Set();
173437
173543
  for (const attribute of node.attributes) {
173438
173544
  if (attribute.type === "Attribute") {
173439
- if (attribute.name === "value" && node.name === "textarea") {
173440
- if (attribute.value !== true && attribute.value[0].type === "Text" && regex_starts_with_newline.test(attribute.value[0].data)) {
173441
- attribute.value[0].data = "\n" + attribute.value[0].data;
173545
+ if (attribute.name === "value") {
173546
+ if (node.name === "textarea") {
173547
+ if (attribute.value !== true && attribute.value[0].type === "Text" && regex_starts_with_newline.test(attribute.value[0].data)) {
173548
+ attribute.value[0].data = "\n" + attribute.value[0].data;
173549
+ }
173550
+ content = {
173551
+ escape: true,
173552
+ expression: serialize_attribute_value(attribute.value, context)
173553
+ };
173554
+ } else if (node.name !== "select") {
173555
+ attributes.push(attribute);
173556
+ }
173557
+ } else if (is_event_attribute(attribute)) {
173558
+ if ((attribute.name === "onload" || attribute.name === "onerror") && LoadErrorElements.includes(node.name)) {
173559
+ events_to_capture.add(attribute.name);
173442
173560
  }
173443
- content = { escape: true, expression: serialize_attribute_value(attribute.value, context) };
173444
- } else if (!is_event_attribute(attribute)) {
173561
+ } else {
173445
173562
  if (attribute.name === "class") {
173446
173563
  class_attribute_idx = attributes.length;
173447
173564
  } else if (attribute.name === "style") {
@@ -173521,6 +173638,15 @@ function serialize_element_attributes(node, context) {
173521
173638
  } else if (attribute.type === "SpreadAttribute") {
173522
173639
  attributes.push(attribute);
173523
173640
  has_spread = true;
173641
+ if (LoadErrorElements.includes(node.name)) {
173642
+ events_to_capture.add("onload");
173643
+ events_to_capture.add("onerror");
173644
+ }
173645
+ } else if (attribute.type === "UseDirective") {
173646
+ if (LoadErrorElements.includes(node.name)) {
173647
+ events_to_capture.add("onload");
173648
+ events_to_capture.add("onerror");
173649
+ }
173524
173650
  } else if (attribute.type === "ClassDirective") {
173525
173651
  class_directives.push(attribute);
173526
173652
  } else if (attribute.type === "StyleDirective") {
@@ -173589,6 +173715,11 @@ function serialize_element_attributes(node, context) {
173589
173715
  );
173590
173716
  }
173591
173717
  }
173718
+ if (events_to_capture.size !== 0) {
173719
+ for (const event of events_to_capture) {
173720
+ context.state.template.push(t_string(` ${event}="this.__e=event"`));
173721
+ }
173722
+ }
173592
173723
  return content;
173593
173724
  }
173594
173725
  function serialize_class_directives(class_directives, class_attribute) {
@@ -173654,13 +173785,13 @@ function serialize_style_directives(style_directives, style_attribute, context)
173654
173785
  }
173655
173786
  }
173656
173787
 
173657
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/utils/assert.js
173788
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/utils/assert.js
173658
173789
  function equal(actual, expected) {
173659
173790
  if (actual !== expected)
173660
173791
  throw new Error("Assertion failed");
173661
173792
  }
173662
173793
 
173663
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/3-transform/client/visitors/javascript-runes.js
173794
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/3-transform/client/visitors/javascript-runes.js
173664
173795
  var javascript_visitors_runes2 = {
173665
173796
  ClassBody(node, { state, visit: visit24 }) {
173666
173797
  const public_state = /* @__PURE__ */ new Map();
@@ -173792,7 +173923,7 @@ var javascript_visitors_runes2 = {
173792
173923
  for (const declarator2 of node.declarations) {
173793
173924
  const init2 = declarator2.init;
173794
173925
  const rune = get_rune(init2, state.scope);
173795
- if (!rune || rune === "$effect.active" || rune === "$effect.root" || rune === "$inspect" || rune === "$state.snapshot") {
173926
+ if (!rune || rune === "$effect.active" || rune === "$effect.root" || rune === "$inspect" || rune === "$state.snapshot" || rune === "$state.is") {
173796
173927
  if (init2 != null && is_hoistable_function(init2)) {
173797
173928
  const hoistable_function = visit24(init2);
173798
173929
  state.hoisted.push(
@@ -173960,6 +174091,13 @@ var javascript_visitors_runes2 = {
173960
174091
  context.visit(node.arguments[0])
173961
174092
  );
173962
174093
  }
174094
+ if (rune === "$state.is") {
174095
+ return call(
174096
+ "$.is",
174097
+ context.visit(node.arguments[0]),
174098
+ context.visit(node.arguments[1])
174099
+ );
174100
+ }
173963
174101
  if (rune === "$effect.root") {
173964
174102
  const args = node.arguments.map((arg) => context.visit(arg));
173965
174103
  return call("$.effect_root", ...args);
@@ -173968,6 +174106,28 @@ var javascript_visitors_runes2 = {
173968
174106
  return transform_inspect_rune(node, context);
173969
174107
  }
173970
174108
  context.next();
174109
+ },
174110
+ BinaryExpression(node, { state, visit: visit24, next: next2 }) {
174111
+ const operator = node.operator;
174112
+ if (state.options.dev) {
174113
+ if (operator === "===" || operator === "!==") {
174114
+ return call(
174115
+ "$.strict_equals",
174116
+ visit24(node.left),
174117
+ visit24(node.right),
174118
+ operator === "!==" && literal2(false)
174119
+ );
174120
+ }
174121
+ if (operator === "==" || operator === "!=") {
174122
+ return call(
174123
+ "$.equals",
174124
+ visit24(node.left),
174125
+ visit24(node.right),
174126
+ operator === "!=" && literal2(false)
174127
+ );
174128
+ }
174129
+ }
174130
+ next2();
173971
174131
  }
173972
174132
  };
173973
174133
  function get_name(node) {
@@ -173978,7 +174138,7 @@ function get_name(node) {
173978
174138
  }
173979
174139
  }
173980
174140
 
173981
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/phases/3-transform/client/visitors/template.js
174141
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/phases/3-transform/client/visitors/template.js
173982
174142
  function get_attribute_name2(element, attribute, context) {
173983
174143
  let name = attribute.name;
173984
174144
  if (!element.metadata.svg && !element.metadata.mathml && context.state.metadata.namespace !== "foreign") {
@@ -174251,6 +174411,10 @@ function serialize_element_attribute_update_assignment(element, node_id, attribu
174251
174411
  value
174252
174412
  )
174253
174413
  );
174414
+ } else if (name === "value") {
174415
+ update2 = stmt(call("$.set_value", node_id, value));
174416
+ } else if (name === "checked") {
174417
+ update2 = stmt(call("$.set_checked", node_id, value));
174254
174418
  } else if (DOMProperties.includes(name)) {
174255
174419
  update2 = stmt(assignment("=", member(node_id, id(name)), value));
174256
174420
  } else {
@@ -174327,6 +174491,9 @@ function serialize_update_assignment(state, id2, init2, value, update2) {
174327
174491
  function collect_parent_each_blocks(context) {
174328
174492
  return context.path.filter((node) => node.type === "EachBlock");
174329
174493
  }
174494
+ function create_derived(state, arg) {
174495
+ return call(state.analysis.runes ? "$.derived" : "$.derived_safe_equal", arg);
174496
+ }
174330
174497
  function serialize_inline_component2(node, component_name, context) {
174331
174498
  const props_and_spreads = [];
174332
174499
  const lets = [];
@@ -174336,6 +174503,7 @@ function serialize_inline_component2(node, component_name, context) {
174336
174503
  let bind_this = null;
174337
174504
  const binding_initializers = [];
174338
174505
  let slot_scope_applies_to_itself = false;
174506
+ let has_children_prop = false;
174339
174507
  function push_prop(prop2) {
174340
174508
  const current2 = props_and_spreads.at(-1);
174341
174509
  const current_is_props = Array.isArray(current2);
@@ -174378,6 +174546,9 @@ function serialize_inline_component2(node, component_name, context) {
174378
174546
  if (attribute.name === "slot") {
174379
174547
  slot_scope_applies_to_itself = true;
174380
174548
  }
174549
+ if (attribute.name === "children") {
174550
+ has_children_prop = true;
174551
+ }
174381
174552
  const [, value] = serialize_attribute_value2(attribute.value, context);
174382
174553
  if (attribute.metadata.dynamic) {
174383
174554
  let arg = value;
@@ -174386,7 +174557,7 @@ function serialize_inline_component2(node, component_name, context) {
174386
174557
  });
174387
174558
  if (should_wrap_in_derived) {
174388
174559
  const id2 = id(context.state.scope.generate(attribute.name));
174389
- context.state.init.push(var_builder(id2, call("$.derived", thunk(value))));
174560
+ context.state.init.push(var_builder(id2, create_derived(context.state, thunk(value))));
174390
174561
  arg = call("$.get", id2);
174391
174562
  }
174392
174563
  push_prop(get(attribute.name, [return_builder(arg)]));
@@ -174455,10 +174626,11 @@ function serialize_inline_component2(node, component_name, context) {
174455
174626
  [id("$$anchor"), id("$$slotProps")],
174456
174627
  block3([...slot_name === "default" && !slot_scope_applies_to_itself ? lets : [], ...body])
174457
174628
  );
174458
- if (slot_name === "default") {
174629
+ if (slot_name === "default" && !has_children_prop) {
174459
174630
  push_prop(
174460
174631
  init("children", context.state.options.dev ? call("$.wrap_snippet", slot_fn) : slot_fn)
174461
174632
  );
174633
+ serialized_slots.push(init(slot_name, true_instance));
174462
174634
  } else {
174463
174635
  serialized_slots.push(init(slot_name, slot_fn));
174464
174636
  }
@@ -174967,8 +175139,8 @@ function serialize_template_literal(values, visit24, state) {
174967
175139
  state.init.push(
174968
175140
  const_builder(
174969
175141
  id2,
174970
- call(
174971
- state.analysis.runes ? "$.derived" : "$.derived_safe_equal",
175142
+ create_derived(
175143
+ state,
174972
175144
  thunk(visit24(node.expression))
174973
175145
  )
174974
175146
  )
@@ -175010,8 +175182,8 @@ var template_visitors2 = {
175010
175182
  state.init.push(
175011
175183
  const_builder(
175012
175184
  declaration2.id,
175013
- call(
175014
- state.analysis.runes ? "$.derived" : "$.derived_safe_equal",
175185
+ create_derived(
175186
+ state,
175015
175187
  thunk(visit24(declaration2.init))
175016
175188
  )
175017
175189
  )
@@ -175036,9 +175208,7 @@ var template_visitors2 = {
175036
175208
  return_builder(object(identifiers.map((node2) => prop("init", node2, node2))))
175037
175209
  ])
175038
175210
  );
175039
- state.init.push(
175040
- const_builder(tmp, call(state.analysis.runes ? "$.derived" : "$.derived_safe_equal", fn))
175041
- );
175211
+ state.init.push(const_builder(tmp, create_derived(state, fn)));
175042
175212
  if (state.options.dev) {
175043
175213
  state.init.push(stmt(call("$.get", tmp)));
175044
175214
  }
@@ -175174,6 +175344,7 @@ var template_visitors2 = {
175174
175344
  let is_content_editable = false;
175175
175345
  let has_content_editable_binding = false;
175176
175346
  let img_might_be_lazy = false;
175347
+ let might_need_event_replaying = false;
175177
175348
  if (is_custom_element) {
175178
175349
  metadata.context.template_needs_import_node = true;
175179
175350
  }
@@ -175193,6 +175364,9 @@ var template_visitors2 = {
175193
175364
  attributes.push(attribute);
175194
175365
  needs_input_reset = true;
175195
175366
  needs_content_reset = true;
175367
+ if (LoadErrorElements.includes(node.name)) {
175368
+ might_need_event_replaying = true;
175369
+ }
175196
175370
  } else if (attribute.type === "ClassDirective") {
175197
175371
  class_directives.push(attribute);
175198
175372
  } else if (attribute.type === "StyleDirective") {
@@ -175211,6 +175385,8 @@ var template_visitors2 = {
175211
175385
  } else if (attribute.name === "innerHTML" || attribute.name === "innerText" || attribute.name === "textContent") {
175212
175386
  has_content_editable_binding = true;
175213
175387
  }
175388
+ } else if (attribute.type === "UseDirective" && LoadErrorElements.includes(node.name)) {
175389
+ might_need_event_replaying = true;
175214
175390
  }
175215
175391
  context.visit(attribute);
175216
175392
  }
@@ -175224,7 +175400,7 @@ var template_visitors2 = {
175224
175400
  if (is_content_editable && has_content_editable_binding) {
175225
175401
  child_metadata.bound_contenteditable = true;
175226
175402
  }
175227
- if (needs_input_reset && (node.name === "input" || node.name === "select")) {
175403
+ if (needs_input_reset && node.name === "input") {
175228
175404
  context.state.init.push(stmt(call("$.remove_input_attr_defaults", context.state.node)));
175229
175405
  }
175230
175406
  if (needs_content_reset && node.name === "textarea") {
@@ -175251,6 +175427,9 @@ var template_visitors2 = {
175251
175427
  } else {
175252
175428
  for (const attribute of attributes) {
175253
175429
  if (is_event_attribute(attribute)) {
175430
+ if ((attribute.name === "onload" || attribute.name === "onerror") && LoadErrorElements.includes(node.name)) {
175431
+ might_need_event_replaying = true;
175432
+ }
175254
175433
  serialize_event_attribute(attribute, context);
175255
175434
  continue;
175256
175435
  }
@@ -175278,6 +175457,9 @@ var template_visitors2 = {
175278
175457
  }
175279
175458
  serialize_class_directives2(class_directives, node_id, context, is_attributes_reactive);
175280
175459
  serialize_style_directives2(style_directives, node_id, context, is_attributes_reactive);
175460
+ if (might_need_event_replaying) {
175461
+ context.state.after_update.push(stmt(call("$.replay_events", node_id)));
175462
+ }
175281
175463
  context.state.template.push(">");
175282
175464
  const child_locations = [];
175283
175465
  const state = {
@@ -175950,10 +176132,7 @@ var template_visitors2 = {
175950
176132
  const name = node.expression === null ? node.name : node.expression.name;
175951
176133
  return const_builder(
175952
176134
  name,
175953
- call(
175954
- state.analysis.runes ? "$.derived" : "$.derived_safe_equal",
175955
- thunk(member(id("$$slotProps"), id(node.name)))
175956
- )
176135
+ create_derived(state, thunk(member(id("$$slotProps"), id(node.name))))
175957
176136
  );
175958
176137
  }
175959
176138
  },
@@ -176018,7 +176197,7 @@ var template_visitors2 = {
176018
176197
  [id("$$anchor")],
176019
176198
  block3(create_block2(node, "fallback", node.fragment.nodes, context))
176020
176199
  );
176021
- const expression = is_default ? member(id("$$props"), id("children")) : member(member(id("$$props"), id("$$slots")), name, true, true);
176200
+ const expression = is_default ? call("$.default_slot", id("$$props")) : member(member(id("$$props"), id("$$slots")), name, true, true);
176022
176201
  const slot = call("$.slot", context.state.node, expression, props_expression, fallback);
176023
176202
  context.state.init.push(stmt(slot));
176024
176203
  },
@@ -177068,14 +177247,14 @@ function remapping(input, loader, options) {
177068
177247
  return new SourceMap(traceMappings(tree), opts);
177069
177248
  }
177070
177249
 
177071
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/utils/push_array.js
177250
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/utils/push_array.js
177072
177251
  function push_array(array2, items) {
177073
177252
  for (let i3 = 0; i3 < items.length; i3++) {
177074
177253
  array2.push(items[i3]);
177075
177254
  }
177076
177255
  }
177077
177256
 
177078
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/utils/mapped_code.js
177257
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/utils/mapped_code.js
177079
177258
  function last_line_length(s3) {
177080
177259
  return s3.length - s3.lastIndexOf("\n") - 1;
177081
177260
  }
@@ -177307,9 +177486,10 @@ function get_basename(filename2) {
177307
177486
  return filename2.split(/[/\\]/).pop();
177308
177487
  }
177309
177488
 
177310
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/validate-options.js
177489
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/validate-options.js
177311
177490
  var common = {
177312
177491
  filename: string(void 0),
177492
+ rootDir: string(typeof process !== "undefined" ? process.cwd?.() : void 0),
177313
177493
  dev: boolean(false),
177314
177494
  generate: validator("client", (input, keypath) => {
177315
177495
  if (input === "dom" || input === "ssr") {
@@ -177480,7 +177660,7 @@ function throw_error2(msg) {
177480
177660
  options_invalid_value(null, msg);
177481
177661
  }
177482
177662
 
177483
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/preprocess/decode_sourcemap.js
177663
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/preprocess/decode_sourcemap.js
177484
177664
  function decoded_sourcemap_from_generator(generator) {
177485
177665
  let previous_generated_line = 1;
177486
177666
  const converted_mappings = [[]];
@@ -177537,7 +177717,7 @@ function decode_map(processed) {
177537
177717
  return decoded_map;
177538
177718
  }
177539
177719
 
177540
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/preprocess/replace_in_code.js
177720
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/preprocess/replace_in_code.js
177541
177721
  function slice_source(code_slice, offset2, { file_basename, filename: filename2, get_location }) {
177542
177722
  return {
177543
177723
  source: code_slice,
@@ -177580,7 +177760,7 @@ async function replace_in_code(regex, get_replacement, location) {
177580
177760
  return perform_replacements(replacements2, location);
177581
177761
  }
177582
177762
 
177583
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/preprocess/index.js
177763
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/preprocess/index.js
177584
177764
  var PreprocessResult = class {
177585
177765
  source;
177586
177766
  filename;
@@ -177763,29 +177943,11 @@ async function preprocess(source, preprocessor, options) {
177763
177943
  return result.to_processed();
177764
177944
  }
177765
177945
 
177766
- // ../../node_modules/.pnpm/svelte@5.0.0-next.133/node_modules/svelte/src/compiler/index.js
177767
- function handle_compile_error(error, filename2, source) {
177768
- error.filename = filename2;
177769
- if (error.position) {
177770
- const start = locator(error.position[0]);
177771
- const end = locator(error.position[1]);
177772
- error.start = start;
177773
- error.end = end;
177774
- }
177775
- throw error;
177776
- }
177777
- function parse16(source, options = {}) {
177778
- reset3({ source, filename: options.filename });
177779
- let ast;
177780
- try {
177781
- ast = parse15(source);
177782
- } catch (e4) {
177783
- if (e4 instanceof CompileError) {
177784
- handle_compile_error(e4, options.filename, source);
177785
- }
177786
- throw e4;
177787
- }
177788
- return to_public_ast(source, ast, options.modern);
177946
+ // ../../node_modules/.pnpm/svelte@5.0.0-next.138/node_modules/svelte/src/compiler/index.js
177947
+ function parse16(source, { filename: filename2, rootDir, modern } = {}) {
177948
+ reset3(source, { filename: filename2, rootDir });
177949
+ const ast = parse15(source);
177950
+ return to_public_ast(source, ast, modern);
177789
177951
  }
177790
177952
  function to_public_ast(source, ast, modern) {
177791
177953
  if (modern) {
@@ -177822,6 +177984,7 @@ var svelteRunes = [
177822
177984
  "$state",
177823
177985
  "$state.frozen",
177824
177986
  "$state.snapshot",
177987
+ "$state.is",
177825
177988
  "$props",
177826
177989
  "$bindable",
177827
177990
  "$derived",