qc-trousse-sdg 1.4.0 → 1.4.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. package/README.md +9 -0
  2. package/dist/css/qc-sdg-no-grid.min.css +1 -1
  3. package/dist/css/qc-sdg.min.css +1 -1
  4. package/dist/js/qc-sdg.min.js +1 -1
  5. package/index.html +6 -0
  6. package/package.json +2 -2
  7. package/plugins/buildSvelteTests.js +36 -0
  8. package/public/css/qc-sdg-no-grid.css +18 -28
  9. package/public/css/qc-sdg.css +18 -28
  10. package/public/js/qc-doc-sdg.js +1382 -451
  11. package/public/js/qc-sdg.js +1832 -797
  12. package/rollup.config.js +5 -0
  13. package/src/sdg/components/DropdownList/DropdownListButton/DropdownListButton.svelte +7 -8
  14. package/src/sdg/components/DropdownList/DropdownListButton/_dropdownListButton.scss +2 -12
  15. package/src/sdg/components/TextField/TextField.svelte +7 -5
  16. package/src/sdg/components/TextField/TextFieldWC.svelte +1 -1
  17. package/src/sdg/qc-sdg-test.js +1 -1
  18. package/tests/buildSvelteTestsIgnore.json +4 -0
  19. package/tests/{button.spec.ts → button-baseline.spec.ts} +2 -2
  20. package/tests/choice-group-baseline.spec.ts +20 -0
  21. package/tests/choice-group-svelte.spec.ts +20 -0
  22. package/tests/{dropdown-list.spec.ts → dropdown-list-baseline.spec.ts} +1 -1
  23. package/tests/{icon.spec.ts → icon-baseline.spec.ts} +1 -9
  24. package/tests/icon-svelte.spec.ts +11 -0
  25. package/tests/piv-header-baseline.spec.ts +11 -0
  26. package/tests/piv-header-svelte.spec.ts +11 -0
  27. package/tests/textfield-baseline.spec.ts +28 -0
  28. package/tests/textfield-svelte.spec.ts +28 -0
  29. package/tests/toggle-switch-baseline.spec.ts +11 -0
  30. package/tests/toggle-switch-svelte.spec.ts +11 -0
  31. package/tests/choice-group.spec.ts +0 -36
  32. package/tests/pivHeader.spec.ts +0 -22
  33. package/tests/textfield.spec.ts +0 -21
  34. package/tests/toggle-switch.spec.ts +0 -20
  35. /package/src/sdg/bases/Icon/Test/{IconEmbeddedTest.html → IconSvelteTest.html} +0 -0
  36. /package/src/sdg/bases/Icon/Test/{iconTest.html → iconBaselineTest.html} +0 -0
  37. /package/src/sdg/components/Button/Test/{buttonTest.html → buttonBaselineTest.html} +0 -0
  38. /package/src/sdg/components/ChoiceGroup/Test/{checkboxTest.html → checkboxBaselineTest.html} +0 -0
  39. /package/src/sdg/components/ChoiceGroup/Test/{checkboxEmbeddedTest.html → checkboxSvelteTest.html} +0 -0
  40. /package/src/sdg/components/ChoiceGroup/Test/{radiosTest.html → radiosBaselineTest.html} +0 -0
  41. /package/src/sdg/components/ChoiceGroup/Test/{radiosEmbeddedTest.html → radiosSvelteTest.html} +0 -0
  42. /package/src/sdg/components/DropdownList/Test/{DropdownListEmbeddedTest.svelte → DropdownListSvelteTest.svelte} +0 -0
  43. /package/src/sdg/components/DropdownList/Test/{dropdownListEmbeddedTest.html → dropdownListSvelteTest.html} +0 -0
  44. /package/src/sdg/components/PivHeader/Test/{pivHeaderTest.html → pivHeaderBaselineTest.html} +0 -0
  45. /package/src/sdg/components/PivHeader/Test/{pivHeaderEmbeddedTest.html → pivHeaderSvelteTest.html} +0 -0
  46. /package/src/sdg/components/TextField/Test/{textFieldTest.html → textFieldBaselineTest.html} +0 -0
  47. /package/src/sdg/components/TextField/Test/{textFieldEmbeddedTest.html → textFieldSvelteTest.html} +0 -0
  48. /package/src/sdg/components/ToggleSwitch/Test/{toggleSwitchTest.html → toggleSwitchBaselineTest.html} +0 -0
  49. /package/src/sdg/components/ToggleSwitch/Test/{toggleSwitchEmbeddedTest.html → toggleSwitchSvelteTest.html} +0 -0
@@ -33,6 +33,9 @@
33
33
 
34
34
  const UNINITIALIZED = Symbol();
35
35
 
36
+ // Dev-time component properties
37
+ const FILENAME = Symbol('filename');
38
+
36
39
  const NAMESPACE_HTML = 'http://www.w3.org/1999/xhtml';
37
40
  const NAMESPACE_SVG = 'http://www.w3.org/2000/svg';
38
41
 
@@ -41,6 +44,16 @@
41
44
  /* This file is generated by scripts/process-messages/index.js. Do not edit! */
42
45
 
43
46
 
47
+ /**
48
+ * A snippet function was passed invalid arguments. Snippets should only be instantiated via `{@render ...}`
49
+ * @returns {never}
50
+ */
51
+ function invalid_snippet_arguments() {
52
+ {
53
+ throw new Error(`https://svelte.dev/e/invalid_snippet_arguments`);
54
+ }
55
+ }
56
+
44
57
  /**
45
58
  * `%name%(...)` can only be used during component initialisation
46
59
  * @param {string} name
@@ -52,6 +65,26 @@
52
65
  }
53
66
  }
54
67
 
68
+ /**
69
+ * Attempted to render a snippet without a `{@render}` block. This would cause the snippet code to be stringified instead of its content being rendered to the DOM. To fix this, change `{snippet}` to `{@render snippet()}`.
70
+ * @returns {never}
71
+ */
72
+ function snippet_without_render_tag() {
73
+ {
74
+ throw new Error(`https://svelte.dev/e/snippet_without_render_tag`);
75
+ }
76
+ }
77
+
78
+ /**
79
+ * The `this` prop on `<svelte:element>` must be a string, if defined
80
+ * @returns {never}
81
+ */
82
+ function svelte_element_invalid_this_value() {
83
+ {
84
+ throw new Error(`https://svelte.dev/e/svelte_element_invalid_this_value`);
85
+ }
86
+ }
87
+
55
88
  // Store the references to globals in case someone tries to monkey patch these, causing the below
56
89
  // to de-opt (this occurs often when using popular extensions).
57
90
  var is_array = Array.isArray;
@@ -112,6 +145,7 @@
112
145
  const EFFECT_RAN = 1 << 15;
113
146
  /** 'Transparent' effects do not create a transition boundary */
114
147
  const EFFECT_TRANSPARENT = 1 << 16;
148
+ const INSPECT_EFFECT = 1 << 18;
115
149
  const HEAD_EFFECT = 1 << 19;
116
150
  const EFFECT_HAS_DERIVED = 1 << 20;
117
151
  const EFFECT_IS_UPDATING = 1 << 21;
@@ -123,6 +157,43 @@
123
157
  /* This file is generated by scripts/process-messages/index.js. Do not edit! */
124
158
 
125
159
 
160
+ /**
161
+ * Calling `%method%` on a component instance (of %component%) is no longer valid in Svelte 5
162
+ * @param {string} method
163
+ * @param {string} component
164
+ * @returns {never}
165
+ */
166
+ function component_api_changed(method, component) {
167
+ {
168
+ throw new Error(`https://svelte.dev/e/component_api_changed`);
169
+ }
170
+ }
171
+
172
+ /**
173
+ * Attempted to instantiate %component% with `new %name%`, which is no longer valid in Svelte 5. If this component is not under your control, set the `compatibility.componentApi` compiler option to `4` to keep it working.
174
+ * @param {string} component
175
+ * @param {string} name
176
+ * @returns {never}
177
+ */
178
+ function component_api_invalid_new(component, name) {
179
+ {
180
+ throw new Error(`https://svelte.dev/e/component_api_invalid_new`);
181
+ }
182
+ }
183
+
184
+ /**
185
+ * Keyed each block has duplicate key `%value%` at indexes %a% and %b%
186
+ * @param {string} a
187
+ * @param {string} b
188
+ * @param {string | undefined | null} [value]
189
+ * @returns {never}
190
+ */
191
+ function each_key_duplicate(a, b, value) {
192
+ {
193
+ throw new Error(`https://svelte.dev/e/each_key_duplicate`);
194
+ }
195
+ }
196
+
126
197
  /**
127
198
  * `%rune%` cannot be used inside an effect cleanup function
128
199
  * @param {string} rune
@@ -219,6 +290,49 @@
219
290
  /* This file is generated by scripts/process-messages/index.js. Do not edit! */
220
291
 
221
292
 
293
+ /**
294
+ * Assignment to `%property%` property (%location%) will evaluate to the right-hand side, not the value of `%property%` following the assignment. This may result in unexpected behaviour.
295
+ * @param {string} property
296
+ * @param {string} location
297
+ */
298
+ function assignment_value_stale(property, location) {
299
+ {
300
+ console.warn(`https://svelte.dev/e/assignment_value_stale`);
301
+ }
302
+ }
303
+
304
+ /**
305
+ * `%binding%` (%location%) is binding to a non-reactive property
306
+ * @param {string} binding
307
+ * @param {string | undefined | null} [location]
308
+ */
309
+ function binding_property_non_reactive(binding, location) {
310
+ {
311
+ console.warn(`https://svelte.dev/e/binding_property_non_reactive`);
312
+ }
313
+ }
314
+
315
+ /**
316
+ * Your `console.%method%` contained `$state` proxies. Consider using `$inspect(...)` or `$state.snapshot(...)` instead
317
+ * @param {string} method
318
+ */
319
+ function console_log_state(method) {
320
+ {
321
+ console.warn(`https://svelte.dev/e/console_log_state`);
322
+ }
323
+ }
324
+
325
+ /**
326
+ * %handler% should be a function. Did you mean to %suggestion%?
327
+ * @param {string} handler
328
+ * @param {string} suggestion
329
+ */
330
+ function event_handler_invalid(handler, suggestion) {
331
+ {
332
+ console.warn(`https://svelte.dev/e/event_handler_invalid`);
333
+ }
334
+ }
335
+
222
336
  /**
223
337
  * Hydration failed because the initial UI does not match what was rendered on the server. The error occurred near %location%
224
338
  * @param {string | undefined | null} [location]
@@ -229,6 +343,42 @@
229
343
  }
230
344
  }
231
345
 
346
+ /**
347
+ * %parent% passed property `%prop%` to %child% with `bind:`, but its parent component %owner% did not declare `%prop%` as a binding. Consider creating a binding between %owner% and %parent% (e.g. `bind:%prop%={...}` instead of `%prop%={...}`)
348
+ * @param {string} parent
349
+ * @param {string} prop
350
+ * @param {string} child
351
+ * @param {string} owner
352
+ */
353
+ function ownership_invalid_binding(parent, prop, child, owner) {
354
+ {
355
+ console.warn(`https://svelte.dev/e/ownership_invalid_binding`);
356
+ }
357
+ }
358
+
359
+ /**
360
+ * Mutating unbound props (`%name%`, at %location%) is strongly discouraged. Consider using `bind:%prop%={...}` in %parent% (or using a callback) instead
361
+ * @param {string} name
362
+ * @param {string} location
363
+ * @param {string} prop
364
+ * @param {string} parent
365
+ */
366
+ function ownership_invalid_mutation(name, location, prop, parent) {
367
+ {
368
+ console.warn(`https://svelte.dev/e/ownership_invalid_mutation`);
369
+ }
370
+ }
371
+
372
+ /**
373
+ * Reactive `$state(...)` proxies and the values they proxy have different identities. Because of this, comparisons with `%operator%` will produce unexpected results
374
+ * @param {string} operator
375
+ */
376
+ function state_proxy_equality_mismatch(operator) {
377
+ {
378
+ console.warn(`https://svelte.dev/e/state_proxy_equality_mismatch`);
379
+ }
380
+ }
381
+
232
382
  /** @import { TemplateNode } from '#client' */
233
383
 
234
384
 
@@ -317,6 +467,19 @@
317
467
  }
318
468
  }
319
469
 
470
+ /* This file is generated by scripts/process-messages/index.js. Do not edit! */
471
+
472
+
473
+ /**
474
+ * `<svelte:element this="%tag%">` is a void element — it cannot have content
475
+ * @param {string} tag
476
+ */
477
+ function dynamic_void_element_content(tag) {
478
+ {
479
+ console.warn(`https://svelte.dev/e/dynamic_void_element_content`);
480
+ }
481
+ }
482
+
320
483
  /** @import { Snapshot } from './types' */
321
484
 
322
485
  /**
@@ -725,6 +888,24 @@
725
888
  return Object.is(get_proxied_value(a), get_proxied_value(b));
726
889
  }
727
890
 
891
+ /**
892
+ * @param {any} a
893
+ * @param {any} b
894
+ * @param {boolean} equal
895
+ * @returns {boolean}
896
+ */
897
+ function strict_equals(a, b, equal = true) {
898
+ // try-catch needed because this tries to read properties of `a` and `b`,
899
+ // which could be disallowed for example in a secure context
900
+ try {
901
+ if ((a === b) !== (get_proxied_value(a) === get_proxied_value(b))) {
902
+ state_proxy_equality_mismatch(equal ? '===' : '!==');
903
+ }
904
+ } catch {}
905
+
906
+ return (a === b) === equal;
907
+ }
908
+
728
909
  /** @import { TemplateNode } from '#client' */
729
910
 
730
911
  // export these for reference in the compiled code, making global name deduplication unnecessary
@@ -1218,6 +1399,11 @@
1218
1399
  }
1219
1400
  }
1220
1401
 
1402
+ /** @param {() => void | (() => void)} fn */
1403
+ function inspect_effect(fn) {
1404
+ return create_effect(INSPECT_EFFECT, fn, true);
1405
+ }
1406
+
1221
1407
  /**
1222
1408
  * Internal representation of `$effect.root(...)`
1223
1409
  * @param {() => void | (() => void)} fn
@@ -2565,6 +2751,23 @@
2565
2751
  component_context = context;
2566
2752
  }
2567
2753
 
2754
+ /**
2755
+ * The current component function. Different from current component context:
2756
+ * ```html
2757
+ * <!-- App.svelte -->
2758
+ * <Foo>
2759
+ * <Bar /> <!-- context == Foo.svelte, function == App.svelte -->
2760
+ * </Foo>
2761
+ * ```
2762
+ * @type {ComponentContext['function']}
2763
+ */
2764
+ let dev_current_component_function = null;
2765
+
2766
+ /** @param {ComponentContext['function']} fn */
2767
+ function set_dev_current_component_function(fn) {
2768
+ dev_current_component_function = fn;
2769
+ }
2770
+
2568
2771
  /**
2569
2772
  * Retrieves the context that belongs to the closest parent component with the specified `key`.
2570
2773
  * Must be called during component initialisation.
@@ -2671,6 +2874,33 @@
2671
2874
  return null;
2672
2875
  }
2673
2876
 
2877
+ const VOID_ELEMENT_NAMES = [
2878
+ 'area',
2879
+ 'base',
2880
+ 'br',
2881
+ 'col',
2882
+ 'command',
2883
+ 'embed',
2884
+ 'hr',
2885
+ 'img',
2886
+ 'input',
2887
+ 'keygen',
2888
+ 'link',
2889
+ 'meta',
2890
+ 'param',
2891
+ 'source',
2892
+ 'track',
2893
+ 'wbr'
2894
+ ];
2895
+
2896
+ /**
2897
+ * Returns `true` if `name` is of a void element
2898
+ * @param {string} name
2899
+ */
2900
+ function is_void(name) {
2901
+ return VOID_ELEMENT_NAMES.includes(name) || name.toLowerCase() === '!doctype';
2902
+ }
2903
+
2674
2904
  /**
2675
2905
  * @param {string} name
2676
2906
  */
@@ -2770,6 +3000,105 @@
2770
3000
  return RAW_TEXT_ELEMENTS.includes(/** @type {RAW_TEXT_ELEMENTS[number]} */ (name));
2771
3001
  }
2772
3002
 
3003
+ /**
3004
+ * Prevent devtools trying to make `location` a clickable link by inserting a zero-width space
3005
+ * @template {string | undefined} T
3006
+ * @param {T} location
3007
+ * @returns {T};
3008
+ */
3009
+ function sanitize_location(location) {
3010
+ return /** @type {T} */ (location?.replace(/\//g, '/\u200b'));
3011
+ }
3012
+
3013
+ /**
3014
+ *
3015
+ * @param {any} a
3016
+ * @param {any} b
3017
+ * @param {string} property
3018
+ * @param {string} location
3019
+ */
3020
+ function compare(a, b, property, location) {
3021
+ if (a !== b) {
3022
+ assignment_value_stale(property, /** @type {string} */ (sanitize_location(location)));
3023
+ }
3024
+
3025
+ return a;
3026
+ }
3027
+
3028
+ /**
3029
+ * @param {any} object
3030
+ * @param {string} property
3031
+ * @param {any} value
3032
+ * @param {string} location
3033
+ */
3034
+ function assign(object, property, value, location) {
3035
+ return compare(
3036
+ (object[property] = value),
3037
+ untrack(() => object[property]),
3038
+ property,
3039
+ location
3040
+ );
3041
+ }
3042
+
3043
+ /** @import { SourceLocation } from '#shared' */
3044
+
3045
+ /**
3046
+ * @param {any} fn
3047
+ * @param {string} filename
3048
+ * @param {SourceLocation[]} locations
3049
+ * @returns {any}
3050
+ */
3051
+ function add_locations(fn, filename, locations) {
3052
+ return (/** @type {any[]} */ ...args) => {
3053
+ const dom = fn(...args);
3054
+
3055
+ var node = hydrating ? dom : dom.nodeType === 11 ? dom.firstChild : dom;
3056
+ assign_locations(node, filename, locations);
3057
+
3058
+ return dom;
3059
+ };
3060
+ }
3061
+
3062
+ /**
3063
+ * @param {Element} element
3064
+ * @param {string} filename
3065
+ * @param {SourceLocation} location
3066
+ */
3067
+ function assign_location(element, filename, location) {
3068
+ // @ts-expect-error
3069
+ element.__svelte_meta = {
3070
+ loc: { file: filename, line: location[0], column: location[1] }
3071
+ };
3072
+
3073
+ if (location[2]) {
3074
+ assign_locations(element.firstChild, filename, location[2]);
3075
+ }
3076
+ }
3077
+
3078
+ /**
3079
+ * @param {Node | null} node
3080
+ * @param {string} filename
3081
+ * @param {SourceLocation[]} locations
3082
+ */
3083
+ function assign_locations(node, filename, locations) {
3084
+ var i = 0;
3085
+ var depth = 0;
3086
+
3087
+ while (node && i < locations.length) {
3088
+ if (hydrating && node.nodeType === 8) {
3089
+ var comment = /** @type {Comment} */ (node);
3090
+ if (comment.data === HYDRATION_START || comment.data === HYDRATION_START_ELSE) depth += 1;
3091
+ else if (comment.data[0] === HYDRATION_END) depth -= 1;
3092
+ }
3093
+
3094
+ if (depth === 0 && node.nodeType === 1) {
3095
+ assign_location(/** @type {Element} */ (node), filename, locations[i++]);
3096
+ }
3097
+
3098
+ node = node.nextSibling;
3099
+ }
3100
+ }
3101
+
2773
3102
  /**
2774
3103
  * @param {HTMLElement} dom
2775
3104
  * @param {boolean} value
@@ -3082,6 +3411,48 @@
3082
3411
  }
3083
3412
  }
3084
3413
 
3414
+ /**
3415
+ * In dev, warn if an event handler is not a function, as it means the
3416
+ * user probably called the handler or forgot to add a `() =>`
3417
+ * @param {() => (event: Event, ...args: any) => void} thunk
3418
+ * @param {EventTarget} element
3419
+ * @param {[Event, ...any]} args
3420
+ * @param {any} component
3421
+ * @param {[number, number]} [loc]
3422
+ * @param {boolean} [remove_parens]
3423
+ */
3424
+ function apply(
3425
+ thunk,
3426
+ element,
3427
+ args,
3428
+ component,
3429
+ loc,
3430
+ has_side_effects = false,
3431
+ remove_parens = false
3432
+ ) {
3433
+ let handler;
3434
+ let error;
3435
+
3436
+ try {
3437
+ handler = thunk();
3438
+ } catch (e) {
3439
+ error = e;
3440
+ }
3441
+
3442
+ if (typeof handler !== 'function' && (has_side_effects || handler != null || error)) {
3443
+ component?.[FILENAME];
3444
+ const phase = args[0]?.eventPhase < Event.BUBBLING_PHASE ? 'capture' : '';
3445
+ args[0]?.type + phase;
3446
+
3447
+ event_handler_invalid();
3448
+
3449
+ if (error) {
3450
+ throw error;
3451
+ }
3452
+ }
3453
+ handler?.apply(element, args);
3454
+ }
3455
+
3085
3456
  /** @param {string} html */
3086
3457
  function create_fragment_from_html(html) {
3087
3458
  var elem = document.createElement('template');
@@ -3445,6 +3816,152 @@
3445
3816
  return Promise.resolve();
3446
3817
  }
3447
3818
 
3819
+ /** @typedef {{ file: string, line: number, column: number }} Location */
3820
+
3821
+
3822
+ /**
3823
+ * Sets up a validator that
3824
+ * - traverses the path of a prop to find out if it is allowed to be mutated
3825
+ * - checks that the binding chain is not interrupted
3826
+ * @param {Record<string, any>} props
3827
+ */
3828
+ function create_ownership_validator(props) {
3829
+ const component = component_context?.function;
3830
+ const parent = component_context?.p?.function;
3831
+
3832
+ return {
3833
+ /**
3834
+ * @param {string} prop
3835
+ * @param {any[]} path
3836
+ * @param {any} result
3837
+ * @param {number} line
3838
+ * @param {number} column
3839
+ */
3840
+ mutation: (prop, path, result, line, column) => {
3841
+ const name = path[0];
3842
+ if (is_bound_or_unset(props, name) || !parent) {
3843
+ return result;
3844
+ }
3845
+
3846
+ /** @type {any} */
3847
+ let value = props;
3848
+
3849
+ for (let i = 0; i < path.length - 1; i++) {
3850
+ value = value[path[i]];
3851
+ if (!value?.[STATE_SYMBOL]) {
3852
+ return result;
3853
+ }
3854
+ }
3855
+
3856
+ const location = sanitize_location(`${component[FILENAME]}:${line}:${column}`);
3857
+
3858
+ ownership_invalid_mutation(name, location, prop, parent[FILENAME]);
3859
+
3860
+ return result;
3861
+ },
3862
+ /**
3863
+ * @param {any} key
3864
+ * @param {any} child_component
3865
+ * @param {() => any} value
3866
+ */
3867
+ binding: (key, child_component, value) => {
3868
+ if (!is_bound_or_unset(props, key) && parent && value()?.[STATE_SYMBOL]) {
3869
+ ownership_invalid_binding(
3870
+ component[FILENAME],
3871
+ key,
3872
+ child_component[FILENAME],
3873
+ parent[FILENAME]
3874
+ );
3875
+ }
3876
+ }
3877
+ };
3878
+ }
3879
+
3880
+ /**
3881
+ * @param {Record<string, any>} props
3882
+ * @param {string} prop_name
3883
+ */
3884
+ function is_bound_or_unset(props, prop_name) {
3885
+ // Can be the case when someone does `mount(Component, props)` with `let props = $state({...})`
3886
+ // or `createClassComponent(Component, props)`
3887
+ const is_entry_props = STATE_SYMBOL in props || LEGACY_PROPS in props;
3888
+ return (
3889
+ !!get_descriptor(props, prop_name)?.set ||
3890
+ (is_entry_props && prop_name in props) ||
3891
+ !(prop_name in props)
3892
+ );
3893
+ }
3894
+
3895
+ /** @param {Function & { [FILENAME]: string }} target */
3896
+ function check_target(target) {
3897
+ if (target) {
3898
+ component_api_invalid_new(target[FILENAME] ?? 'a component', target.name);
3899
+ }
3900
+ }
3901
+
3902
+ function legacy_api() {
3903
+ const component = component_context?.function;
3904
+
3905
+ /** @param {string} method */
3906
+ function error(method) {
3907
+ component_api_changed(method, component[FILENAME]);
3908
+ }
3909
+
3910
+ return {
3911
+ $destroy: () => error('$destroy()'),
3912
+ $on: () => error('$on(...)'),
3913
+ $set: () => error('$set(...)')
3914
+ };
3915
+ }
3916
+
3917
+ /**
3918
+ * @param {() => any[]} get_value
3919
+ * @param {Function} [inspector]
3920
+ */
3921
+ // eslint-disable-next-line no-console
3922
+ function inspect(get_value, inspector = console.log) {
3923
+ validate_effect();
3924
+
3925
+ let initial = true;
3926
+
3927
+ inspect_effect(() => {
3928
+ /** @type {any} */
3929
+ var value = UNINITIALIZED;
3930
+
3931
+ // Capturing the value might result in an exception due to the inspect effect being
3932
+ // sync and thus operating on stale data. In the case we encounter an exception we
3933
+ // can bail-out of reporting the value. Instead we simply console.error the error
3934
+ // so at least it's known that an error occured, but we don't stop execution
3935
+ try {
3936
+ value = get_value();
3937
+ } catch (error) {
3938
+ // eslint-disable-next-line no-console
3939
+ console.error(error);
3940
+ }
3941
+
3942
+ if (value !== UNINITIALIZED) {
3943
+ inspector(initial ? 'init' : 'update', ...snapshot(value, true));
3944
+ }
3945
+
3946
+ initial = false;
3947
+ });
3948
+ }
3949
+
3950
+ /**
3951
+ * @param {Node} anchor
3952
+ * @param {...(()=>any)[]} args
3953
+ */
3954
+ function validate_snippet_args(anchor, ...args) {
3955
+ if (typeof anchor !== 'object' || !(anchor instanceof Node)) {
3956
+ invalid_snippet_arguments();
3957
+ }
3958
+ for (let arg of args) {
3959
+ if (typeof arg !== 'function') {
3960
+ invalid_snippet_arguments();
3961
+ }
3962
+ }
3963
+ }
3964
+
3448
3965
  /** @import { Effect, Source, TemplateNode } from '#client' */
3449
3966
 
3450
3967
  const PENDING = 0;
@@ -4390,6 +4907,41 @@
4390
4907
  });
4391
4908
  }
4392
4909
 
4910
+ /** @import { TemplateNode } from '#client' */
4911
+ /** @import { Getters } from '#shared' */
4912
+
4913
+ /**
4914
+ * @param {() => string} tag_fn
4915
+ * @returns {void}
4916
+ */
4917
+ function validate_void_dynamic_element(tag_fn) {
4918
+ const tag = tag_fn();
4919
+ if (tag && is_void(tag)) {
4920
+ dynamic_void_element_content();
4921
+ }
4922
+ }
4923
+
4924
+ /** @param {() => unknown} tag_fn */
4925
+ function validate_dynamic_element_tag(tag_fn) {
4926
+ const tag = tag_fn();
4927
+ const is_string = typeof tag === 'string';
4928
+ if (tag && !is_string) {
4929
+ svelte_element_invalid_this_value();
4930
+ }
4931
+ }
4932
+
4933
+ /**
4934
+ * @template {() => unknown} T
4935
+ * @param {T} fn
4936
+ */
4937
+ function prevent_snippet_stringification(fn) {
4938
+ fn.toString = () => {
4939
+ snippet_without_render_tag();
4940
+ return '';
4941
+ };
4942
+ return fn;
4943
+ }
4944
+
4393
4945
  /** @import { Snippet } from 'svelte' */
4394
4946
  /** @import { Effect, TemplateNode } from '#client' */
4395
4947
  /** @import { Getters } from '#shared' */
@@ -4427,6 +4979,29 @@
4427
4979
  }
4428
4980
  }
4429
4981
 
4982
+ /**
4983
+ * In development, wrap the snippet function so that it passes validation, and so that the
4984
+ * correct component context is set for ownership checks
4985
+ * @param {any} component
4986
+ * @param {(node: TemplateNode, ...args: any[]) => void} fn
4987
+ */
4988
+ function wrap_snippet(component, fn) {
4989
+ const snippet = (/** @type {TemplateNode} */ node, /** @type {any[]} */ ...args) => {
4990
+ var previous_component_function = dev_current_component_function;
4991
+ set_dev_current_component_function(component);
4992
+
4993
+ try {
4994
+ return fn(node, ...args);
4995
+ } finally {
4996
+ set_dev_current_component_function(previous_component_function);
4997
+ }
4998
+ };
4999
+
5000
+ prevent_snippet_stringification(snippet);
5001
+
5002
+ return snippet;
5003
+ }
5004
+
4430
5005
  /** @import { Effect, TemplateNode } from '#client' */
4431
5006
 
4432
5007
  /**
@@ -5849,6 +6424,80 @@
5849
6424
  };
5850
6425
  }
5851
6426
 
6427
+ /**
6428
+ * @param {() => any} collection
6429
+ * @param {(item: any, index: number) => string} key_fn
6430
+ * @returns {void}
6431
+ */
6432
+ function validate_each_keys(collection, key_fn) {
6433
+ render_effect(() => {
6434
+ const keys = new Map();
6435
+ const maybe_array = collection();
6436
+ const array = is_array(maybe_array)
6437
+ ? maybe_array
6438
+ : maybe_array == null
6439
+ ? []
6440
+ : Array.from(maybe_array);
6441
+ const length = array.length;
6442
+ for (let i = 0; i < length; i++) {
6443
+ const key = key_fn(array[i], i);
6444
+ if (keys.has(key)) {
6445
+ String(keys.get(key));
6446
+
6447
+ /** @type {string | null} */
6448
+ let k = String(key);
6449
+ if (k.startsWith('[object ')) k = null;
6450
+
6451
+ each_key_duplicate();
6452
+ }
6453
+ keys.set(key, i);
6454
+ }
6455
+ });
6456
+ }
6457
+
6458
+ /**
6459
+ * @param {string} binding
6460
+ * @param {() => Record<string, any>} get_object
6461
+ * @param {() => string} get_property
6462
+ * @param {number} line
6463
+ * @param {number} column
6464
+ */
6465
+ function validate_binding(binding, get_object, get_property, line, column) {
6466
+ var warned = false;
6467
+
6468
+ dev_current_component_function?.[FILENAME];
6469
+
6470
+ render_effect(() => {
6471
+ if (warned) return;
6472
+
6473
+ var [object, is_store_sub] = capture_store_binding(get_object);
6474
+
6475
+ if (is_store_sub) return;
6476
+
6477
+ var property = get_property();
6478
+
6479
+ var ran = false;
6480
+
6481
+ // by making the (possibly false, but it would be an extreme edge case) assumption
6482
+ // that a getter has a corresponding setter, we can determine if a property is
6483
+ // reactive by seeing if this effect has dependencies
6484
+ var effect = render_effect(() => {
6485
+ if (ran) return;
6486
+
6487
+ // eslint-disable-next-line @typescript-eslint/no-unused-expressions
6488
+ object[property];
6489
+ });
6490
+
6491
+ ran = true;
6492
+
6493
+ if (effect.deps === null) {
6494
+ binding_property_non_reactive();
6495
+
6496
+ warned = true;
6497
+ }
6498
+ });
6499
+ }
6500
+
5852
6501
  /** @import { ComponentConstructorOptions, ComponentType, SvelteComponent, Component } from 'svelte' */
5853
6502
 
5854
6503
  /**
@@ -6319,6 +6968,37 @@
6319
6968
  return Class;
6320
6969
  }
6321
6970
 
6971
+ /**
6972
+ * @param {string} method
6973
+ * @param {...any} objects
6974
+ */
6975
+ function log_if_contains_state(method, ...objects) {
6976
+ untrack(() => {
6977
+ try {
6978
+ let has_state = false;
6979
+ const transformed = [];
6980
+
6981
+ for (const obj of objects) {
6982
+ if (obj && typeof obj === 'object' && STATE_SYMBOL in obj) {
6983
+ transformed.push(snapshot(obj, true));
6984
+ has_state = true;
6985
+ } else {
6986
+ transformed.push(obj);
6987
+ }
6988
+ }
6989
+
6990
+ if (has_state) {
6991
+ console_log_state(method);
6992
+
6993
+ // eslint-disable-next-line no-console
6994
+ console.log('%c[snapshot]', 'color: grey', ...transformed);
6995
+ }
6996
+ } catch {}
6997
+ });
6998
+
6999
+ return objects;
7000
+ }
7001
+
6322
7002
  function getDefaultExportFromCjs (x) {
6323
7003
  return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
6324
7004
  }
@@ -74244,6 +74924,8 @@
74244
74924
  var jsExports = requireJs();
74245
74925
  var jsBeautify = /*@__PURE__*/getDefaultExportFromCjs(jsExports);
74246
74926
 
74927
+ Code[FILENAME] = 'src/doc/components/Code.svelte';
74928
+
74247
74929
  function copy(_, prettyCode) {
74248
74930
  navigator.clipboard.writeText(get(prettyCode));
74249
74931
  this.classList.add('copied');
@@ -74256,17 +74938,34 @@
74256
74938
  );
74257
74939
  }
74258
74940
 
74259
- var root$f = template(`<pre class="qc-hash-1fxiy4n"><code class="hljs"><button class="qc-button qc-compact qc-primary">
74941
+ var root$f = add_locations(
74942
+ template(`<pre class="qc-hash-1fxiy4n"><code class="hljs"><button class="qc-button qc-compact qc-primary">
74260
74943
  <span class="copy">copier</span>
74261
74944
  <span class="copied">copié !</span>
74262
- </button><!></code></pre>`);
74945
+ </button><!></code></pre>`),
74946
+ Code[FILENAME],
74947
+ [
74948
+ [
74949
+ 54,
74950
+ 0,
74951
+ [
74952
+ [
74953
+ 55,
74954
+ 5,
74955
+ [[56, 9, [[58, 12], [59, 12]]]]
74956
+ ]
74957
+ ]
74958
+ ]
74959
+ ]
74960
+ );
74263
74961
 
74264
74962
  const $$css$5 = {
74265
74963
  hash: 'qc-hash-1fxiy4n',
74266
- code: 'pre.qc-hash-1fxiy4n {max-inline-size:var(--qc-max-content-width);}'
74964
+ code: 'pre.qc-hash-1fxiy4n {\n max-inline-size: var(--qc-max-content-width);\n}'
74267
74965
  };
74268
74966
 
74269
74967
  function Code($$anchor, $$props) {
74968
+ check_target(new.target);
74270
74969
  push($$props, true);
74271
74970
  append_styles$1($$anchor, $$css$5);
74272
74971
 
@@ -74285,7 +74984,7 @@
74285
74984
 
74286
74985
  rawCode.replace('class="mounted"', '').replace('/qc-hash-.*/g', '').replace('/is-external=""/g', 'is-external');
74287
74986
  // prettyCode = pretty(rawCode, prettyOptions);
74288
- set(prettyCode, language() === 'javascript' ? jsBeautify(rawCode) : pretty(rawCode, { wrap_attributes: 'force-aligned' }), true);
74987
+ set(prettyCode, strict_equals(language(), 'javascript') ? jsBeautify(rawCode) : pretty(rawCode, { wrap_attributes: 'force-aligned' }), true);
74289
74988
  set(hlCode, HighlightJS.highlight(get(prettyCode), { language: language() }).value, true);
74290
74989
  }
74291
74990
 
@@ -74332,7 +75031,8 @@
74332
75031
  set outerHTML($$value = false) {
74333
75032
  outerHTML($$value);
74334
75033
  flushSync();
74335
- }
75034
+ },
75035
+ ...legacy_api()
74336
75036
  });
74337
75037
  }
74338
75038
 
@@ -74351,14 +75051,30 @@
74351
75051
  false
74352
75052
  ));
74353
75053
 
74354
- var root$e = template(`<div class="color-details qc-hash-1we8qc0"><div></div> <div class="color-description qc-hash-1we8qc0"><strong> </strong><br> <code> </code></div></div>`);
75054
+ Color_doc[FILENAME] = 'src/doc/components/color-doc.svelte';
75055
+
75056
+ var root$e = add_locations(template(`<div class="color-details qc-hash-1we8qc0"><div></div> <div class="color-description qc-hash-1we8qc0"><strong> </strong><br> <code> </code></div></div>`), Color_doc[FILENAME], [
75057
+ [
75058
+ 16,
75059
+ 0,
75060
+ [
75061
+ [17, 4],
75062
+ [
75063
+ 19,
75064
+ 4,
75065
+ [[20, 8], [20, 32], [21, 8]]
75066
+ ]
75067
+ ]
75068
+ ]
75069
+ ]);
74355
75070
 
74356
75071
  const $$css$4 = {
74357
75072
  hash: 'qc-hash-1we8qc0',
74358
- code: '.qc-bg-color-white.qc-hash-1we8qc0 {background-color:var(--qc-color-white);}.qc-bg-color-blue-extra-pale.qc-hash-1we8qc0 {background-color:var(--qc-color-blue-extra-pale);}.qc-bg-color-blue-pale.qc-hash-1we8qc0 {background-color:var(--qc-color-blue-pale);}.qc-bg-color-blue-light.qc-hash-1we8qc0 {background-color:var(--qc-color-blue-light);}.qc-bg-color-blue-regular_light.qc-hash-1we8qc0 {background-color:var(--qc-color-blue-regular_light);}.qc-bg-color-blue-regular.qc-hash-1we8qc0 {background-color:var(--qc-color-blue-regular);}.qc-bg-color-blue-piv.qc-hash-1we8qc0 {background-color:var(--qc-color-blue-piv);}.qc-bg-color-blue-medium.qc-hash-1we8qc0 {background-color:var(--qc-color-blue-medium);}.qc-bg-color-blue-dark.qc-hash-1we8qc0 {background-color:var(--qc-color-blue-dark);}.qc-bg-color-purple.qc-hash-1we8qc0 {background-color:var(--qc-color-purple);}.qc-bg-color-grey-extra-pale.qc-hash-1we8qc0 {background-color:var(--qc-color-grey-extra-pale);}.qc-bg-color-grey-pale.qc-hash-1we8qc0 {background-color:var(--qc-color-grey-pale);}.qc-bg-color-grey-light.qc-hash-1we8qc0 {background-color:var(--qc-color-grey-light);}.qc-bg-color-grey-regular.qc-hash-1we8qc0 {background-color:var(--qc-color-grey-regular);}.qc-bg-color-grey-medium.qc-hash-1we8qc0 {background-color:var(--qc-color-grey-medium);}.qc-bg-color-grey-dark.qc-hash-1we8qc0 {background-color:var(--qc-color-grey-dark);}.qc-bg-color-pink-pale.qc-hash-1we8qc0 {background-color:var(--qc-color-pink-pale);}.qc-bg-color-pink-regular.qc-hash-1we8qc0 {background-color:var(--qc-color-pink-regular);}.qc-bg-color-red-pale.qc-hash-1we8qc0 {background-color:var(--qc-color-red-pale);}.qc-bg-color-red-light.qc-hash-1we8qc0 {background-color:var(--qc-color-red-light);}.qc-bg-color-red-regular_light.qc-hash-1we8qc0 {background-color:var(--qc-color-red-regular_light);}.qc-bg-color-red-regular.qc-hash-1we8qc0 {background-color:var(--qc-color-red-regular);}.qc-bg-color-red-medium.qc-hash-1we8qc0 {background-color:var(--qc-color-red-medium);}.qc-bg-color-red-dark.qc-hash-1we8qc0 {background-color:var(--qc-color-red-dark);}.qc-bg-color-green-pale.qc-hash-1we8qc0 {background-color:var(--qc-color-green-pale);}.qc-bg-color-green-regular.qc-hash-1we8qc0 {background-color:var(--qc-color-green-regular);}.qc-bg-color-green-dark.qc-hash-1we8qc0 {background-color:var(--qc-color-green-dark);}.qc-bg-color-yellow-pale.qc-hash-1we8qc0 {background-color:var(--qc-color-yellow-pale);}.qc-bg-color-yellow-regular.qc-hash-1we8qc0 {background-color:var(--qc-color-yellow-regular);}.qc-bg-color-yellow-dark.qc-hash-1we8qc0 {background-color:var(--qc-color-yellow-dark);}.qc-bg-color-background.qc-hash-1we8qc0 {background-color:var(--qc-color-background);}.qc-bg-color-text-primary.qc-hash-1we8qc0 {background-color:var(--qc-color-text-primary);}.qc-bg-color-accent.qc-hash-1we8qc0 {background-color:var(--qc-color-accent);}.qc-bg-color-success.qc-hash-1we8qc0 {background-color:var(--qc-color-success);}.qc-bg-color-error.qc-hash-1we8qc0 {background-color:var(--qc-color-error);}.qc-bg-color-danger.qc-hash-1we8qc0 {background-color:var(--qc-color-danger);}.qc-bg-color-link-text.qc-hash-1we8qc0 {background-color:var(--qc-color-link-text);}.qc-bg-color-link-hover.qc-hash-1we8qc0 {background-color:var(--qc-color-link-hover);}.qc-bg-color-link-visited.qc-hash-1we8qc0 {background-color:var(--qc-color-link-visited);}.qc-bg-color-link-active.qc-hash-1we8qc0 {background-color:var(--qc-color-link-active);}.qc-bg-color-link-focus-outline.qc-hash-1we8qc0 {background-color:var(--qc-color-link-focus-outline);}.qc-bg-color-formfield-border.qc-hash-1we8qc0 {background-color:var(--qc-color-formfield-border);}.qc-bg-color-formfield-focus-border.qc-hash-1we8qc0 {background-color:var(--qc-color-formfield-focus-border);}.qc-bg-color-formfield-focus-outline.qc-hash-1we8qc0 {background-color:var(--qc-color-formfield-focus-outline);}.qc-bg-color-searchinput-icon.qc-hash-1we8qc0 {background-color:var(--qc-color-searchinput-icon);}.qc-bg-color-box_shadow.qc-hash-1we8qc0 {background-color:var(--qc-color-box_shadow);}.color-details.qc-hash-1we8qc0 {display:flex;justify-content:flex-start;align-items:center;}.color-details.qc-hash-1we8qc0 > div:where(.qc-hash-1we8qc0) + div:where(.qc-hash-1we8qc0) {margin-left:var(--qc-spacer-md);}.color-sample.qc-hash-1we8qc0 {width:4.8rem;height:4.8rem;border-radius:50%;flex-shrink:0;}.border.qc-hash-1we8qc0 {border:1px solid var(--qc-color-grey-light);}'
75073
+ code: '.qc-bg-color-white.qc-hash-1we8qc0 {\n background-color: var(--qc-color-white);\n}\n\n.qc-bg-color-blue-extra-pale.qc-hash-1we8qc0 {\n background-color: var(--qc-color-blue-extra-pale);\n}\n\n.qc-bg-color-blue-pale.qc-hash-1we8qc0 {\n background-color: var(--qc-color-blue-pale);\n}\n\n.qc-bg-color-blue-light.qc-hash-1we8qc0 {\n background-color: var(--qc-color-blue-light);\n}\n\n.qc-bg-color-blue-regular_light.qc-hash-1we8qc0 {\n background-color: var(--qc-color-blue-regular_light);\n}\n\n.qc-bg-color-blue-regular.qc-hash-1we8qc0 {\n background-color: var(--qc-color-blue-regular);\n}\n\n.qc-bg-color-blue-piv.qc-hash-1we8qc0 {\n background-color: var(--qc-color-blue-piv);\n}\n\n.qc-bg-color-blue-medium.qc-hash-1we8qc0 {\n background-color: var(--qc-color-blue-medium);\n}\n\n.qc-bg-color-blue-dark.qc-hash-1we8qc0 {\n background-color: var(--qc-color-blue-dark);\n}\n\n.qc-bg-color-purple.qc-hash-1we8qc0 {\n background-color: var(--qc-color-purple);\n}\n\n.qc-bg-color-grey-extra-pale.qc-hash-1we8qc0 {\n background-color: var(--qc-color-grey-extra-pale);\n}\n\n.qc-bg-color-grey-pale.qc-hash-1we8qc0 {\n background-color: var(--qc-color-grey-pale);\n}\n\n.qc-bg-color-grey-light.qc-hash-1we8qc0 {\n background-color: var(--qc-color-grey-light);\n}\n\n.qc-bg-color-grey-regular.qc-hash-1we8qc0 {\n background-color: var(--qc-color-grey-regular);\n}\n\n.qc-bg-color-grey-medium.qc-hash-1we8qc0 {\n background-color: var(--qc-color-grey-medium);\n}\n\n.qc-bg-color-grey-dark.qc-hash-1we8qc0 {\n background-color: var(--qc-color-grey-dark);\n}\n\n.qc-bg-color-pink-pale.qc-hash-1we8qc0 {\n background-color: var(--qc-color-pink-pale);\n}\n\n.qc-bg-color-pink-regular.qc-hash-1we8qc0 {\n background-color: var(--qc-color-pink-regular);\n}\n\n.qc-bg-color-red-pale.qc-hash-1we8qc0 {\n background-color: var(--qc-color-red-pale);\n}\n\n.qc-bg-color-red-light.qc-hash-1we8qc0 {\n background-color: var(--qc-color-red-light);\n}\n\n.qc-bg-color-red-regular_light.qc-hash-1we8qc0 {\n background-color: var(--qc-color-red-regular_light);\n}\n\n.qc-bg-color-red-regular.qc-hash-1we8qc0 {\n background-color: var(--qc-color-red-regular);\n}\n\n.qc-bg-color-red-medium.qc-hash-1we8qc0 {\n background-color: var(--qc-color-red-medium);\n}\n\n.qc-bg-color-red-dark.qc-hash-1we8qc0 {\n background-color: var(--qc-color-red-dark);\n}\n\n.qc-bg-color-green-pale.qc-hash-1we8qc0 {\n background-color: var(--qc-color-green-pale);\n}\n\n.qc-bg-color-green-regular.qc-hash-1we8qc0 {\n background-color: var(--qc-color-green-regular);\n}\n\n.qc-bg-color-green-dark.qc-hash-1we8qc0 {\n background-color: var(--qc-color-green-dark);\n}\n\n.qc-bg-color-yellow-pale.qc-hash-1we8qc0 {\n background-color: var(--qc-color-yellow-pale);\n}\n\n.qc-bg-color-yellow-regular.qc-hash-1we8qc0 {\n background-color: var(--qc-color-yellow-regular);\n}\n\n.qc-bg-color-yellow-dark.qc-hash-1we8qc0 {\n background-color: var(--qc-color-yellow-dark);\n}\n\n.qc-bg-color-background.qc-hash-1we8qc0 {\n background-color: var(--qc-color-background);\n}\n\n.qc-bg-color-text-primary.qc-hash-1we8qc0 {\n background-color: var(--qc-color-text-primary);\n}\n\n.qc-bg-color-accent.qc-hash-1we8qc0 {\n background-color: var(--qc-color-accent);\n}\n\n.qc-bg-color-success.qc-hash-1we8qc0 {\n background-color: var(--qc-color-success);\n}\n\n.qc-bg-color-error.qc-hash-1we8qc0 {\n background-color: var(--qc-color-error);\n}\n\n.qc-bg-color-danger.qc-hash-1we8qc0 {\n background-color: var(--qc-color-danger);\n}\n\n.qc-bg-color-link-text.qc-hash-1we8qc0 {\n background-color: var(--qc-color-link-text);\n}\n\n.qc-bg-color-link-hover.qc-hash-1we8qc0 {\n background-color: var(--qc-color-link-hover);\n}\n\n.qc-bg-color-link-visited.qc-hash-1we8qc0 {\n background-color: var(--qc-color-link-visited);\n}\n\n.qc-bg-color-link-active.qc-hash-1we8qc0 {\n background-color: var(--qc-color-link-active);\n}\n\n.qc-bg-color-link-focus-outline.qc-hash-1we8qc0 {\n background-color: var(--qc-color-link-focus-outline);\n}\n\n.qc-bg-color-formfield-border.qc-hash-1we8qc0 {\n background-color: var(--qc-color-formfield-border);\n}\n\n.qc-bg-color-formfield-focus-border.qc-hash-1we8qc0 {\n background-color: var(--qc-color-formfield-focus-border);\n}\n\n.qc-bg-color-formfield-focus-outline.qc-hash-1we8qc0 {\n background-color: var(--qc-color-formfield-focus-outline);\n}\n\n.qc-bg-color-searchinput-icon.qc-hash-1we8qc0 {\n background-color: var(--qc-color-searchinput-icon);\n}\n\n.qc-bg-color-box_shadow.qc-hash-1we8qc0 {\n background-color: var(--qc-color-box_shadow);\n}\n\n.color-details.qc-hash-1we8qc0 {\n display: flex;\n justify-content: flex-start;\n align-items: center;\n}\n.color-details.qc-hash-1we8qc0 > div:where(.qc-hash-1we8qc0) + div:where(.qc-hash-1we8qc0) {\n margin-left: var(--qc-spacer-md);\n}\n\n.color-sample.qc-hash-1we8qc0 {\n width: 4.8rem;\n height: 4.8rem;\n border-radius: 50%;\n flex-shrink: 0;\n}\n\n.border.qc-hash-1we8qc0 {\n border: 1px solid var(--qc-color-grey-light);\n}'
74359
75074
  };
74360
75075
 
74361
75076
  function Color_doc($$anchor, $$props) {
75077
+ check_target(new.target);
74362
75078
  push($$props, true);
74363
75079
  append_styles$1($$anchor, $$css$4);
74364
75080
 
@@ -74418,7 +75134,8 @@
74418
75134
  set border($$value = null) {
74419
75135
  border($$value);
74420
75136
  flushSync();
74421
- }
75137
+ },
75138
+ ...legacy_api()
74422
75139
  });
74423
75140
  }
74424
75141
 
@@ -74436,9 +75153,18 @@
74436
75153
  true
74437
75154
  ));
74438
75155
 
74439
- var root$d = template(`<label><input type="checkbox" role="switch"> <span><!></span> <span class="qc-switch-slider"></span></label>`);
75156
+ ToggleSwitch[FILENAME] = 'src/sdg/components/ToggleSwitch/ToggleSwitch.svelte';
75157
+
75158
+ var root$d = add_locations(template(`<label><input type="checkbox" role="switch"> <span><!></span> <span class="qc-switch-slider"></span></label>`), ToggleSwitch[FILENAME], [
75159
+ [
75160
+ 17,
75161
+ 0,
75162
+ [[20, 4], [28, 4], [33, 4]]
75163
+ ]
75164
+ ]);
74440
75165
 
74441
75166
  function ToggleSwitch($$anchor, $$props) {
75167
+ check_target(new.target);
74442
75168
  push($$props, true);
74443
75169
 
74444
75170
  let label = prop($$props, 'label', 7),
@@ -74449,7 +75175,7 @@
74449
75175
  textAlign = prop($$props, 'textAlign', 7);
74450
75176
 
74451
75177
  const usedId = "toggle-switch-" + (id() ? id() : Math.random().toString(36));
74452
- let usedLabelTextAlignment = textAlign()?.toLowerCase() === "end" ? "end" : "start";
75178
+ let usedLabelTextAlignment = strict_equals(textAlign()?.toLowerCase(), "end") ? "end" : "start";
74453
75179
  var label_1 = root$d();
74454
75180
 
74455
75181
  set_attribute(label_1, 'for', usedId);
@@ -74463,7 +75189,7 @@
74463
75189
 
74464
75190
  set_class(span, 1, clsx([
74465
75191
  "qc-switch-label",
74466
- usedLabelTextAlignment === "end" && "qc-switch-label-end"
75192
+ strict_equals(usedLabelTextAlignment, "end") && "qc-switch-label-end"
74467
75193
  ]));
74468
75194
 
74469
75195
  var node = child(span);
@@ -74527,7 +75253,8 @@
74527
75253
  set textAlign($$value) {
74528
75254
  textAlign($$value);
74529
75255
  flushSync();
74530
- }
75256
+ },
75257
+ ...legacy_api()
74531
75258
  });
74532
75259
  }
74533
75260
 
@@ -74546,18 +75273,23 @@
74546
75273
  true
74547
75274
  );
74548
75275
 
74549
- var root$c = template(`<div role="complementary" class="qc-hash-1qt294a"><div class="qc-container top-nav qc-hash-1qt294a"><div class="switch-control qc-hash-1qt294a"><!></div></div></div>`);
75276
+ TopNav[FILENAME] = 'src/doc/components/TopNav.svelte';
75277
+
75278
+ var root$c = add_locations(template(`<div role="complementary" class="qc-hash-1qt294a"><div class="qc-container top-nav qc-hash-1qt294a"><div class="switch-control qc-hash-1qt294a"><!></div></div></div>`), TopNav[FILENAME], [
75279
+ [17, 0, [[18, 4, [[19, 8]]]]]
75280
+ ]);
74550
75281
 
74551
75282
  const $$css$3 = {
74552
75283
  hash: 'qc-hash-1qt294a',
74553
- code: '[role=complementary].qc-hash-1qt294a {position:sticky;z-index:100;top:0;background-color:var(--qc-color-blue-medium);color:var(--qc-color-grey-pale);min-height:7.2rem;height:7.2rem;}.top-nav.qc-hash-1qt294a {position:absolute;inset:0;display:flex;align-items:end;padding-bottom:var(--qc-spacer-sm);}.top-nav.qc-hash-1qt294a .switch-control:where(.qc-hash-1qt294a) {margin-left:auto;margin-right:0;display:flex;align-items:center;}'
75284
+ code: '[role=complementary].qc-hash-1qt294a {\n position: sticky;\n z-index: 100;\n top: 0;\n background-color: var(--qc-color-blue-medium);\n color: var(--qc-color-grey-pale);\n min-height: 7.2rem;\n height: 7.2rem;\n}\n\n.top-nav.qc-hash-1qt294a {\n position: absolute;\n inset: 0;\n display: flex;\n align-items: end;\n padding-bottom: var(--qc-spacer-sm);\n}\n.top-nav.qc-hash-1qt294a .switch-control:where(.qc-hash-1qt294a) {\n margin-left: auto;\n margin-right: 0;\n display: flex;\n align-items: center;\n}\n/* (unused) .top-nav .switch-control label:first-child {\n margin-right: 1.6rem;\n}*/'
74554
75285
  };
74555
75286
 
74556
75287
  function TopNav($$anchor, $$props) {
75288
+ check_target(new.target);
74557
75289
  push($$props, true);
74558
75290
  append_styles$1($$anchor, $$css$3);
74559
75291
 
74560
- let value = state(localStorage.getItem('dark-theme') === "true");
75292
+ let value = state(proxy(strict_equals(localStorage.getItem('dark-theme'), "true")));
74561
75293
 
74562
75294
  user_effect(() => {
74563
75295
  document.documentElement.classList.toggle('qc-dark-theme', get(value));
@@ -74583,19 +75315,22 @@
74583
75315
  reset(div_1);
74584
75316
  reset(div);
74585
75317
  append($$anchor, div);
74586
- pop();
75318
+ return pop({ ...legacy_api() });
74587
75319
  }
74588
75320
 
74589
75321
  customElements.define('qc-doc-top-nav', create_custom_element(TopNav, {}, [], [], false));
74590
75322
 
74591
- var root$b = template(`<div class="switch qc-hash-qsg5d6"><input> <span class="slider round qc-hash-qsg5d6"></span></div>`);
75323
+ Switch[FILENAME] = 'src/doc/components/Switch.svelte';
75324
+
75325
+ var root$b = add_locations(template(`<div class="switch qc-hash-qsg5d6"><input> <span class="slider round qc-hash-qsg5d6"></span></div>`), Switch[FILENAME], [[18, 0, [[24, 4], [31, 4]]]]);
74592
75326
 
74593
75327
  const $$css$2 = {
74594
75328
  hash: 'qc-hash-qsg5d6',
74595
- code: '/* The switch - the box around the slider */.switch.qc-hash-qsg5d6 {position:relative;display:inline-block;width:5.6rem;height:3.2rem;}\n\n/* Hide default HTML checkbox */input.qc-hash-qsg5d6 {z-index:10;opacity:0;position:absolute;cursor:pointer;margin:0;padding:0;inset:0;height:auto;width:auto;}\n\n/* The slider */.slider.qc-hash-qsg5d6 {z-index:5;position:absolute;top:0;left:0;right:0;bottom:0;background-color:var(--unchecked-bg-color);-webkit-transition:0.4s;transition:0.4s;}.slider.qc-hash-qsg5d6::before {position:absolute;content:"";height:2.8rem;width:2.8rem;left:0.2rem;bottom:0.2rem;background-color:var(--slider-color);-webkit-transition:0.4s;transition:0.4s;}input.qc-hash-qsg5d6:checked + .slider:where(.qc-hash-qsg5d6) {background-color:var(--checked-bg-color);}input.qc-hash-qsg5d6:focus + .slider:where(.qc-hash-qsg5d6) {box-shadow:0 0 1px var(--qc-bok-shadow-color);}input.qc-hash-qsg5d6:checked + .slider:where(.qc-hash-qsg5d6)::before {transform:translateX(2.4rem);}.slider.round.qc-hash-qsg5d6, input.qc-hash-qsg5d6 {border-radius:3.2rem;}.slider.round.qc-hash-qsg5d6::before {border-radius:50%;}'
75329
+ code: '/* The switch - the box around the slider */\n.switch.qc-hash-qsg5d6 {\n position: relative;\n display: inline-block;\n width: 5.6rem;\n height: 3.2rem;\n}\n\n/* Hide default HTML checkbox */\ninput.qc-hash-qsg5d6 {\n z-index: 10;\n opacity: 0;\n position: absolute;\n cursor: pointer;\n margin: 0;\n padding: 0;\n inset: 0;\n height: auto;\n width: auto;\n}\n\n/* The slider */\n.slider.qc-hash-qsg5d6 {\n z-index: 5;\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background-color: var(--unchecked-bg-color);\n -webkit-transition: 0.4s;\n transition: 0.4s;\n}\n\n.slider.qc-hash-qsg5d6::before {\n position: absolute;\n content: "";\n height: 2.8rem;\n width: 2.8rem;\n left: 0.2rem;\n bottom: 0.2rem;\n background-color: var(--slider-color);\n -webkit-transition: 0.4s;\n transition: 0.4s;\n}\n\ninput.qc-hash-qsg5d6:checked + .slider:where(.qc-hash-qsg5d6) {\n background-color: var(--checked-bg-color);\n}\n\ninput.qc-hash-qsg5d6:focus + .slider:where(.qc-hash-qsg5d6) {\n box-shadow: 0 0 1px var(--qc-bok-shadow-color);\n}\n\ninput.qc-hash-qsg5d6:checked + .slider:where(.qc-hash-qsg5d6)::before {\n transform: translateX(2.4rem);\n}\n\n.slider.round.qc-hash-qsg5d6, input.qc-hash-qsg5d6 {\n border-radius: 3.2rem;\n}\n\n.slider.round.qc-hash-qsg5d6::before {\n border-radius: 50%;\n}'
74596
75330
  };
74597
75331
 
74598
75332
  function Switch($$anchor, $$props) {
75333
+ check_target(new.target);
74599
75334
  push($$props, true);
74600
75335
  append_styles$1($$anchor, $$css$2);
74601
75336
 
@@ -74606,15 +75341,17 @@
74606
75341
  checked: 'blue-regular',
74607
75342
  slider: 'background'
74608
75343
  })),
74609
- rest = rest_props($$props, [
74610
- '$$slots',
74611
- '$$events',
74612
- '$$legacy',
74613
- '$$host',
74614
- 'value',
74615
- 'name',
74616
- 'color'
74617
- ]);
75344
+ rest = rest_props(
75345
+ $$props,
75346
+ [
75347
+ '$$slots',
75348
+ '$$events',
75349
+ '$$legacy',
75350
+ '$$host',
75351
+ 'value',
75352
+ 'name',
75353
+ 'color'
75354
+ ]);
74618
75355
 
74619
75356
  var div = root$b();
74620
75357
  var input = child(div);
@@ -74676,20 +75413,30 @@
74676
75413
  ) {
74677
75414
  color($$value);
74678
75415
  flushSync();
74679
- }
75416
+ },
75417
+ ...legacy_api()
74680
75418
  });
74681
75419
  }
74682
75420
 
74683
75421
  customElements.define('qc-switch', create_custom_element(Switch, { value: {}, name: {}, color: {} }, [], [], false));
74684
75422
 
74685
- var root$a = template(`<div class="exemple-area"><figure><div class="exemple qc-hash-1u5h5rs"></div> <figcaption><!></figcaption></figure> <!></div>`);
75423
+ Exemple[FILENAME] = 'src/doc/components/Exemple.svelte';
75424
+
75425
+ var root$a = add_locations(template(`<div class="exemple-area"><figure><div class="exemple qc-hash-1u5h5rs"></div> <figcaption><!></figcaption></figure> <!></div>`), Exemple[FILENAME], [
75426
+ [
75427
+ 45,
75428
+ 0,
75429
+ [[48, 4, [[51, 8], [54, 8]]]]
75430
+ ]
75431
+ ]);
74686
75432
 
74687
75433
  const $$css$1 = {
74688
75434
  hash: 'qc-hash-1u5h5rs',
74689
- code: 'figure.qc-hash-1u5h5rs {max-width:var(--qc-max-content-width);width:100%;border:1px solid var(--qc-box_shadow-0-color);margin-bottom:var(--qc-spacer-content-block-mb);}figure.qc-hash-1u5h5rs .exemple:where(.qc-hash-1u5h5rs) {padding:var(--qc-spacer-sm) var(--qc-spacer-sm) 0 var(--qc-spacer-sm);margin-bottom:var(--qc-spacer-sm);}'
75435
+ code: 'figure.qc-hash-1u5h5rs {\n max-width: var(--qc-max-content-width);\n width: 100%;\n border: 1px solid var(--qc-box_shadow-0-color);\n margin-bottom: var(--qc-spacer-content-block-mb);\n}\nfigure.qc-hash-1u5h5rs .exemple:where(.qc-hash-1u5h5rs) {\n padding: var(--qc-spacer-sm) var(--qc-spacer-sm) 0 var(--qc-spacer-sm);\n margin-bottom: var(--qc-spacer-sm);\n}'
74690
75436
  };
74691
75437
 
74692
75438
  function Exemple($$anchor, $$props) {
75439
+ check_target(new.target);
74693
75440
  push($$props, true);
74694
75441
  append_styles$1($$anchor, $$css$1);
74695
75442
 
@@ -74697,16 +75444,18 @@
74697
75444
  codeTargetId = prop($$props, 'codeTargetId', 7),
74698
75445
  hideCode = prop($$props, 'hideCode', 7, false),
74699
75446
  rawCode = prop($$props, 'rawCode', 7),
74700
- restProps = rest_props($$props, [
74701
- '$$slots',
74702
- '$$events',
74703
- '$$legacy',
74704
- '$$host',
74705
- 'caption',
74706
- 'codeTargetId',
74707
- 'hideCode',
74708
- 'rawCode'
74709
- ]);
75447
+ restProps = rest_props(
75448
+ $$props,
75449
+ [
75450
+ '$$slots',
75451
+ '$$events',
75452
+ '$$legacy',
75453
+ '$$host',
75454
+ 'caption',
75455
+ 'codeTargetId',
75456
+ 'hideCode',
75457
+ 'rawCode'
75458
+ ]);
74710
75459
 
74711
75460
  let exempleCode = state(void 0);
74712
75461
  let figure = state(void 0);
@@ -74716,11 +75465,11 @@
74716
75465
 
74717
75466
  onMount(() => {
74718
75467
  get(rootElement).parentElement.childNodes.forEach((node) => {
74719
- if (node.nodeType === 3) {
75468
+ if (strict_equals(node.nodeType, 3)) {
74720
75469
  return;
74721
75470
  }
74722
75471
 
74723
- if (node !== get(rootElement)) {
75472
+ if (strict_equals(node, get(rootElement), false)) {
74724
75473
  get(exempleArea).appendChild(node);
74725
75474
  }
74726
75475
 
@@ -74793,7 +75542,8 @@
74793
75542
  set rawCode($$value) {
74794
75543
  rawCode($$value);
74795
75544
  flushSync();
74796
- }
75545
+ },
75546
+ ...legacy_api()
74797
75547
  });
74798
75548
  }
74799
75549
 
@@ -74949,10 +75699,13 @@
74949
75699
  }
74950
75700
  }
74951
75701
 
74952
- var root_1$6 = template(`<span class="qc-required" aria-hidden="true">*</span>`);
74953
- var root$9 = template(`<!><!>`, 1);
75702
+ LabelText[FILENAME] = 'src/sdg/components/Label/LabelText.svelte';
75703
+
75704
+ var root_1$6 = add_locations(template(`<span class="qc-required" aria-hidden="true">*</span>`), LabelText[FILENAME], [[4, 26]]);
75705
+ var root$9 = add_locations(template(`<!><!>`, 1), LabelText[FILENAME], []);
74954
75706
 
74955
75707
  function LabelText($$anchor, $$props) {
75708
+ check_target(new.target);
74956
75709
  push($$props, true);
74957
75710
 
74958
75711
  let text = prop($$props, 'text', 7),
@@ -74993,15 +75746,19 @@
74993
75746
  set required($$value) {
74994
75747
  required($$value);
74995
75748
  flushSync();
74996
- }
75749
+ },
75750
+ ...legacy_api()
74997
75751
  });
74998
75752
  }
74999
75753
 
75000
75754
  create_custom_element(LabelText, { text: {}, required: {} }, [], [], true);
75001
75755
 
75002
- var root$8 = template(`<label><!></label>`);
75756
+ Label[FILENAME] = 'src/sdg/components/Label/Label.svelte';
75757
+
75758
+ var root$8 = add_locations(template(`<label><!></label>`), Label[FILENAME], [[16, 0]]);
75003
75759
 
75004
75760
  function Label($$anchor, $$props) {
75761
+ check_target(new.target);
75005
75762
  push($$props, true);
75006
75763
 
75007
75764
  let forId = prop($$props, 'forId', 7),
@@ -75011,19 +75768,21 @@
75011
75768
  bold = prop($$props, 'bold', 7, false),
75012
75769
  disabled = prop($$props, 'disabled', 7, false),
75013
75770
  rootElement = prop($$props, 'rootElement', 15),
75014
- rest = rest_props($$props, [
75015
- '$$slots',
75016
- '$$events',
75017
- '$$legacy',
75018
- '$$host',
75019
- 'forId',
75020
- 'text',
75021
- 'required',
75022
- 'compact',
75023
- 'bold',
75024
- 'disabled',
75025
- 'rootElement'
75026
- ]);
75771
+ rest = rest_props(
75772
+ $$props,
75773
+ [
75774
+ '$$slots',
75775
+ '$$events',
75776
+ '$$legacy',
75777
+ '$$host',
75778
+ 'forId',
75779
+ 'text',
75780
+ 'required',
75781
+ 'compact',
75782
+ 'bold',
75783
+ 'disabled',
75784
+ 'rootElement'
75785
+ ]);
75027
75786
 
75028
75787
  var label = root$8();
75029
75788
  let attributes;
@@ -75103,7 +75862,8 @@
75103
75862
  set rootElement($$value) {
75104
75863
  rootElement($$value);
75105
75864
  flushSync();
75106
- }
75865
+ },
75866
+ ...legacy_api()
75107
75867
  });
75108
75868
  }
75109
75869
 
@@ -75123,9 +75883,12 @@
75123
75883
  true
75124
75884
  );
75125
75885
 
75126
- var root$7 = template(`<div></div>`);
75886
+ Icon[FILENAME] = 'src/sdg/bases/Icon/Icon.svelte';
75887
+
75888
+ var root$7 = add_locations(template(`<div></div>`), Icon[FILENAME], [[16, 0]]);
75127
75889
 
75128
75890
  function Icon($$anchor, $$props) {
75891
+ check_target(new.target);
75129
75892
  push($$props, true);
75130
75893
 
75131
75894
  let type = prop($$props, 'type', 7),
@@ -75136,22 +75899,24 @@
75136
75899
  height = prop($$props, 'height', 7, 'auto'),
75137
75900
  src = prop($$props, 'src', 7, ''),
75138
75901
  rotate = prop($$props, 'rotate', 7, 0),
75139
- rest = rest_props($$props, [
75140
- '$$slots',
75141
- '$$events',
75142
- '$$legacy',
75143
- '$$host',
75144
- 'type',
75145
- 'label',
75146
- 'size',
75147
- 'color',
75148
- 'width',
75149
- 'height',
75150
- 'src',
75151
- 'rotate'
75152
- ]);
75153
-
75154
- let attributes = user_derived(() => width() === 'auto' ? { 'data-img-size': size() } : {});
75902
+ rest = rest_props(
75903
+ $$props,
75904
+ [
75905
+ '$$slots',
75906
+ '$$events',
75907
+ '$$legacy',
75908
+ '$$host',
75909
+ 'type',
75910
+ 'label',
75911
+ 'size',
75912
+ 'color',
75913
+ 'width',
75914
+ 'height',
75915
+ 'src',
75916
+ 'rotate'
75917
+ ]);
75918
+
75919
+ let attributes = user_derived(() => strict_equals(width(), 'auto') ? { 'data-img-size': size() } : {});
75155
75920
  var div = root$7();
75156
75921
  let attributes_1;
75157
75922
 
@@ -75230,7 +75995,8 @@
75230
75995
  set rotate($$value = 0) {
75231
75996
  rotate($$value);
75232
75997
  flushSync();
75233
- }
75998
+ },
75999
+ ...legacy_api()
75234
76000
  });
75235
76001
  }
75236
76002
 
@@ -75251,10 +76017,13 @@
75251
76017
  true
75252
76018
  );
75253
76019
 
75254
- var root_2$7 = template(`<!> <span><!></span>`, 1);
75255
- var root_1$5 = template(`<div role="alert"><!></div>`);
76020
+ FormError[FILENAME] = 'src/sdg/components/FormError/FormError.svelte';
76021
+
76022
+ var root_2$7 = add_locations(template(`<!> <span><!></span>`, 1), FormError[FILENAME], [[48, 8]]);
76023
+ var root_1$5 = add_locations(template(`<div role="alert"><!></div>`), FormError[FILENAME], [[35, 0]]);
75256
76024
 
75257
76025
  function FormError($$anchor, $$props) {
76026
+ check_target(new.target);
75258
76027
  push($$props, true);
75259
76028
 
75260
76029
  const lang = Utils.getPageLanguage();
@@ -75267,7 +76036,7 @@
75267
76036
  rootElement = prop($$props, 'rootElement', 15);
75268
76037
 
75269
76038
  let cleanLabel = user_derived(() => label().replace(/:\s*$/, '')),
75270
- defaultInvalidText = user_derived(() => label() ? lang === 'fr' ? `Le champ ${get(cleanLabel)} est obligatoire.` : `${get(cleanLabel)} field is required.` : lang === 'fr' ? `Ce champ est obligatoire.` : `This field is required.`);
76039
+ defaultInvalidText = user_derived(() => label() ? strict_equals(lang, 'fr') ? `Le champ ${get(cleanLabel)} est obligatoire.` : `${get(cleanLabel)} field is required.` : strict_equals(lang, 'fr') ? `Ce champ est obligatoire.` : `This field is required.`);
75271
76040
 
75272
76041
  onMount(() => {
75273
76042
  if (id()) return;
@@ -75366,7 +76135,8 @@
75366
76135
  set rootElement($$value) {
75367
76136
  rootElement($$value);
75368
76137
  flushSync();
75369
- }
76138
+ },
76139
+ ...legacy_api()
75370
76140
  });
75371
76141
  }
75372
76142
 
@@ -75403,15 +76173,22 @@
75403
76173
  setTextFieldRow(input.closest('.qc-formfield-row'));
75404
76174
  }
75405
76175
 
75406
- var root_3$2 = template(`<div class="qc-description"><!></div>`);
75407
- var root_4$3 = template(`<div aria-live="polite"><!></div>`);
75408
- var root_1$4 = template(`<!> <!> <!> <!> <!>`, 1);
75409
- var root_6$1 = template(`<div class="qc-textfield"><!></div>`);
76176
+ TextField[FILENAME] = 'src/sdg/components/TextField/TextField.svelte';
76177
+
76178
+ var root_3$2 = add_locations(template(`<div class="qc-description"><!></div>`), TextField[FILENAME], [[131, 8]]);
76179
+ var root_4$3 = add_locations(template(`<div aria-live="polite"><!></div>`), TextField[FILENAME], [[142, 8]]);
76180
+ var root_1$4 = add_locations(template(`<!> <!> <!> <!> <!>`, 1), TextField[FILENAME], []);
76181
+ var root_6$1 = add_locations(template(`<div class="qc-textfield"><!></div>`), TextField[FILENAME], [[166, 4]]);
75410
76182
 
75411
76183
  function TextField($$anchor, $$props) {
76184
+ check_target(new.target);
75412
76185
  push($$props, true);
75413
76186
 
75414
- const textfield = ($$anchor) => {
76187
+ var $$ownership_validator = create_ownership_validator($$props);
76188
+
76189
+ const textfield = wrap_snippet(TextField, function ($$anchor) {
76190
+ validate_snippet_args(...arguments);
76191
+
75415
76192
  var fragment = root_1$4();
75416
76193
  var node = first_child(fragment);
75417
76194
 
@@ -75420,26 +76197,30 @@
75420
76197
  const expression = user_derived(() => input()?.disabled);
75421
76198
  const expression_1 = user_derived(() => input()?.id);
75422
76199
 
75423
- Label($$anchor, {
75424
- get required() {
75425
- return required();
75426
- },
75427
- get disabled() {
75428
- return get(expression);
75429
- },
75430
- get text() {
75431
- return label();
75432
- },
75433
- get forId() {
75434
- return get(expression_1);
75435
- },
75436
- get rootElement() {
75437
- return labelElement();
75438
- },
75439
- set rootElement($$value) {
75440
- labelElement($$value);
75441
- }
75442
- });
76200
+ {
76201
+ $$ownership_validator.binding('labelElement', Label, labelElement);
76202
+
76203
+ Label($$anchor, {
76204
+ get required() {
76205
+ return required();
76206
+ },
76207
+ get disabled() {
76208
+ return get(expression);
76209
+ },
76210
+ get text() {
76211
+ return label();
76212
+ },
76213
+ get forId() {
76214
+ return get(expression_1);
76215
+ },
76216
+ get rootElement() {
76217
+ return labelElement();
76218
+ },
76219
+ set rootElement($$value) {
76220
+ labelElement($$value);
76221
+ }
76222
+ });
76223
+ }
75443
76224
  };
75444
76225
 
75445
76226
  if_block(node, ($$render) => {
@@ -75495,7 +76276,7 @@
75495
76276
  };
75496
76277
 
75497
76278
  if_block(node_4, ($$render) => {
75498
- if (maxlength() !== null) $$render(consequent_2);
76279
+ if (strict_equals(maxlength(), null, false)) $$render(consequent_2);
75499
76280
  });
75500
76281
  }
75501
76282
 
@@ -75503,45 +76284,49 @@
75503
76284
  const expression_2 = user_derived(() => invalidText() ? invalidText() : get(defaultInvalidText));
75504
76285
  const expression_3 = user_derived(() => label() ? label() : input()?.getAttribute("aria-label"));
75505
76286
 
75506
- FormError(node_6, {
75507
- get invalid() {
75508
- return invalid();
75509
- },
75510
- get invalidText() {
75511
- return get(expression_2);
75512
- },
75513
- get label() {
75514
- return get(expression_3);
75515
- },
75516
- extraClasses: ['qc-xs-mt'],
75517
- get id() {
75518
- return get(errorId);
75519
- },
75520
- set id($$value) {
75521
- set(errorId, $$value, true);
75522
- },
75523
- get rootElement() {
75524
- return formErrorElement();
75525
- },
75526
- set rootElement($$value) {
75527
- formErrorElement($$value);
75528
- }
75529
- });
76287
+ {
76288
+ $$ownership_validator.binding('formErrorElement', FormError, formErrorElement);
76289
+
76290
+ FormError(node_6, {
76291
+ get invalid() {
76292
+ return invalid();
76293
+ },
76294
+ get invalidText() {
76295
+ return get(expression_2);
76296
+ },
76297
+ get label() {
76298
+ return get(expression_3);
76299
+ },
76300
+ extraClasses: ['qc-xs-mt'],
76301
+ get id() {
76302
+ return get(errorId);
76303
+ },
76304
+ set id($$value) {
76305
+ set(errorId, $$value, true);
76306
+ },
76307
+ get rootElement() {
76308
+ return formErrorElement();
76309
+ },
76310
+ set rootElement($$value) {
76311
+ formErrorElement($$value);
76312
+ }
76313
+ });
76314
+ }
75530
76315
 
75531
76316
  append($$anchor, fragment);
75532
- };
76317
+ });
75533
76318
 
75534
76319
  const lang = Utils.getPageLanguage();
75535
76320
 
75536
76321
  let label = prop($$props, 'label', 7, ''),
75537
- required = prop($$props, 'required', 15),
76322
+ required = prop($$props, 'required', 15, false),
75538
76323
  description = prop($$props, 'description', 7),
75539
76324
  size = prop($$props, 'size', 7),
75540
76325
  maxlength = prop($$props, 'maxlength', 7),
75541
76326
  maxlengthReached = prop($$props, 'maxlengthReached', 15, false),
75542
76327
  invalidAtSubmit = prop($$props, 'invalidAtSubmit', 15, false),
75543
- value = prop($$props, 'value', 7, ""),
75544
- invalid = prop($$props, 'invalid', 15),
76328
+ value = prop($$props, 'value', 15, ""),
76329
+ invalid = prop($$props, 'invalid', 15, false),
75545
76330
  invalidText = prop($$props, 'invalidText', 7),
75546
76331
  describedBy = prop($$props, 'describedBy', 31, () => proxy([])),
75547
76332
  labelElement = prop($$props, 'labelElement', 15),
@@ -75559,7 +76344,7 @@
75559
76344
  textFieldRow = state(void 0),
75560
76345
  defaultInvalidText = user_derived(() => {
75561
76346
  if (!maxlengthReached()) return '';
75562
- return lang === 'fr' ? `La limite de caractères du champ ${label()} est dépassée.` : `The character limit for the ${label()} field has been exceeded.`;
76347
+ return strict_equals(lang, 'fr') ? `La limite de caractères du champ ${label()} est dépassée.` : `The character limit for the ${label()} field has been exceeded.`;
75563
76348
  });
75564
76349
 
75565
76350
  onMount(() => {
@@ -75602,7 +76387,7 @@
75602
76387
 
75603
76388
  const s = over > 1 ? 's' : '';
75604
76389
 
75605
- set(charCountText, remaining >= 0 ? lang === 'fr' ? `${remaining} caractère${s} restant${s}` : `${remaining} character${s} remaining` : lang === 'fr' ? `${over} caractère${s} en trop` : `${over} character${s} over the limit`, true);
76390
+ set(charCountText, remaining >= 0 ? strict_equals(lang, 'fr') ? `${remaining} caractère${s} restant${s}` : `${remaining} character${s} remaining` : strict_equals(lang, 'fr') ? `${over} caractère${s} en trop` : `${over} character${s} over the limit`, true);
75606
76391
  });
75607
76392
 
75608
76393
  // Génération des ID pour le aria-describedby
@@ -75618,8 +76403,8 @@
75618
76403
  maxlength() && charCountId
75619
76404
  ].filter(Boolean).join(' '));
75620
76405
 
75621
- if (invalid()) input().setAttribute('aria-invalid', invalid());
75622
- if (required()) input().setAttribute('aria-required', required());
76406
+ input().setAttribute('aria-invalid', invalid());
76407
+ input().setAttribute('aria-required', required());
75623
76408
  });
75624
76409
 
75625
76410
  var fragment_2 = comment();
@@ -75664,7 +76449,7 @@
75664
76449
  get required() {
75665
76450
  return required();
75666
76451
  },
75667
- set required($$value) {
76452
+ set required($$value = false) {
75668
76453
  required($$value);
75669
76454
  flushSync();
75670
76455
  },
@@ -75713,7 +76498,7 @@
75713
76498
  get invalid() {
75714
76499
  return invalid();
75715
76500
  },
75716
- set invalid($$value) {
76501
+ set invalid($$value = false) {
75717
76502
  invalid($$value);
75718
76503
  flushSync();
75719
76504
  },
@@ -75772,7 +76557,8 @@
75772
76557
  set children($$value) {
75773
76558
  children($$value);
75774
76559
  flushSync();
75775
- }
76560
+ },
76561
+ ...legacy_api()
75776
76562
  });
75777
76563
  }
75778
76564
 
@@ -75814,7 +76600,7 @@
75814
76600
  name
75815
76601
  ) {
75816
76602
  if (!input) return;
75817
- if (input.role === "switch") return;
76603
+ if (strict_equals(input.role, "switch")) return;
75818
76604
 
75819
76605
  let label = input.closest('label');
75820
76606
 
@@ -75836,13 +76622,18 @@
75836
76622
  input.addEventListener('change', () => setInvalid(false));
75837
76623
  }
75838
76624
 
75839
- var root_2$6 = template(`<span class="qc-required" aria-hidden="true">*</span>`);
75840
- var root$6 = template(`<div><!> <!> <!></div>`);
76625
+ Checkbox[FILENAME] = 'src/sdg/components/Checkbox/Checkbox.svelte';
76626
+
76627
+ var root_2$6 = add_locations(template(`<span class="qc-required" aria-hidden="true">*</span>`), Checkbox[FILENAME], [[56, 4]]);
76628
+ var root$6 = add_locations(template(`<div><!> <!> <!></div>`), Checkbox[FILENAME], [[64, 4]]);
75841
76629
 
75842
76630
  function Checkbox($$anchor, $$props) {
76631
+ check_target(new.target);
75843
76632
  push($$props, true);
75844
76633
 
75845
- const requiredSpanSnippet = ($$anchor) => {
76634
+ const requiredSpanSnippet = wrap_snippet(Checkbox, function ($$anchor) {
76635
+ validate_snippet_args(...arguments);
76636
+
75846
76637
  var fragment = comment();
75847
76638
  var node = first_child(fragment);
75848
76639
 
@@ -75860,7 +76651,7 @@
75860
76651
  }
75861
76652
 
75862
76653
  append($$anchor, fragment);
75863
- };
76654
+ });
75864
76655
 
75865
76656
  Utils.getPageLanguage();
75866
76657
  const qcCheckoxContext = getContext("qc-checkbox");
@@ -76039,7 +76830,8 @@
76039
76830
  set input($$value) {
76040
76831
  input($$value);
76041
76832
  flushSync();
76042
- }
76833
+ },
76834
+ ...legacy_api()
76043
76835
  });
76044
76836
  }
76045
76837
 
@@ -76066,9 +76858,12 @@
76066
76858
  true
76067
76859
  );
76068
76860
 
76069
- var root$5 = template(`<button><!></button>`);
76861
+ IconButton[FILENAME] = 'src/sdg/components/IconButton/IconButton.svelte';
76862
+
76863
+ var root$5 = add_locations(template(`<button><!></button>`), IconButton[FILENAME], [[16, 0]]);
76070
76864
 
76071
76865
  function IconButton($$anchor, $$props) {
76866
+ check_target(new.target);
76072
76867
  push($$props, true);
76073
76868
 
76074
76869
  const size = prop($$props, 'size', 7, 'xl'),
@@ -76077,18 +76872,20 @@
76077
76872
  iconSize = prop($$props, 'iconSize', 7),
76078
76873
  iconColor = prop($$props, 'iconColor', 7),
76079
76874
  className = prop($$props, 'class', 7, ''),
76080
- rest = rest_props($$props, [
76081
- '$$slots',
76082
- '$$events',
76083
- '$$legacy',
76084
- '$$host',
76085
- 'size',
76086
- 'label',
76087
- 'icon',
76088
- 'iconSize',
76089
- 'iconColor',
76090
- 'class'
76091
- ]);
76875
+ rest = rest_props(
76876
+ $$props,
76877
+ [
76878
+ '$$slots',
76879
+ '$$events',
76880
+ '$$legacy',
76881
+ '$$host',
76882
+ 'size',
76883
+ 'label',
76884
+ 'icon',
76885
+ 'iconSize',
76886
+ 'iconColor',
76887
+ 'class'
76888
+ ]);
76092
76889
 
76093
76890
  var button = root$5();
76094
76891
  let attributes;
@@ -76170,7 +76967,8 @@
76170
76967
  set class($$value = '') {
76171
76968
  className($$value);
76172
76969
  flushSync();
76173
- }
76970
+ },
76971
+ ...legacy_api()
76174
76972
  });
76175
76973
  }
76176
76974
 
@@ -76189,33 +76987,38 @@
76189
76987
  true
76190
76988
  );
76191
76989
 
76192
- var root$4 = template(`<div><!> <input> <!></div>`);
76990
+ SearchInput[FILENAME] = 'src/sdg/components/SearchInput/SearchInput.svelte';
76991
+
76992
+ var root$4 = add_locations(template(`<div><!> <input> <!></div>`), SearchInput[FILENAME], [[28, 0, [[39, 4]]]]);
76193
76993
 
76194
76994
  function SearchInput($$anchor, $$props) {
76995
+ check_target(new.target);
76195
76996
  push($$props, true);
76196
76997
 
76197
76998
  const lang = Utils.getPageLanguage();
76198
76999
 
76199
77000
  let value = prop($$props, 'value', 15, ''),
76200
- ariaLabel = prop($$props, 'ariaLabel', 7, lang === "fr" ? "Rechercher..." : "Search..."),
76201
- clearAriaLabel = prop($$props, 'clearAriaLabel', 7, lang === "fr" ? "Effacer le texte" : "Clear text"),
77001
+ ariaLabel = prop($$props, 'ariaLabel', 23, () => strict_equals(lang, "fr") ? "Rechercher..." : "Search..."),
77002
+ clearAriaLabel = prop($$props, 'clearAriaLabel', 23, () => strict_equals(lang, "fr") ? "Effacer le texte" : "Clear text"),
76202
77003
  leftIcon = prop($$props, 'leftIcon', 7, false),
76203
77004
  id = prop($$props, 'id', 23, () => `qc-search-input-${Math.random().toString(36).slice(2, 11)}`),
76204
- rest = rest_props($$props, [
76205
- '$$slots',
76206
- '$$events',
76207
- '$$legacy',
76208
- '$$host',
76209
- 'value',
76210
- 'ariaLabel',
76211
- 'clearAriaLabel',
76212
- 'leftIcon',
76213
- 'id'
76214
- ]);
76215
-
76216
- leftIcon(leftIcon() === true || leftIcon() === "true" || leftIcon() === "");
76217
-
76218
- const isDisabled = $$props.disabled === true || $$props.disabled === "true" || $$props.disabled === "";
77005
+ rest = rest_props(
77006
+ $$props,
77007
+ [
77008
+ '$$slots',
77009
+ '$$events',
77010
+ '$$legacy',
77011
+ '$$host',
77012
+ 'value',
77013
+ 'ariaLabel',
77014
+ 'clearAriaLabel',
77015
+ 'leftIcon',
77016
+ 'id'
77017
+ ]);
77018
+
77019
+ leftIcon(strict_equals(leftIcon(), true) || strict_equals(leftIcon(), "true") || strict_equals(leftIcon(), ""));
77020
+
77021
+ const isDisabled = strict_equals($$props.disabled, true) || strict_equals($$props.disabled, "true") || strict_equals($$props.disabled, "");
76219
77022
  let searchInput;
76220
77023
 
76221
77024
  function focus() {
@@ -76295,7 +77098,9 @@
76295
77098
  append($$anchor, div);
76296
77099
 
76297
77100
  return pop({
76298
- focus,
77101
+ get focus() {
77102
+ return focus;
77103
+ },
76299
77104
  get value() {
76300
77105
  return value();
76301
77106
  },
@@ -76336,7 +77141,8 @@
76336
77141
  ) {
76337
77142
  id($$value);
76338
77143
  flushSync();
76339
- }
77144
+ },
77145
+ ...legacy_api()
76340
77146
  });
76341
77147
  }
76342
77148
 
@@ -76354,12 +77160,15 @@
76354
77160
  true
76355
77161
  );
76356
77162
 
77163
+ DropdownListItemsSingle[FILENAME] = 'src/sdg/components/DropdownList/DropdownListItems/DropdownListItemsSingle/DropdownListItemsSingle.svelte';
77164
+
76357
77165
  var on_click$1 = (event, handleMouseUp, item) => handleMouseUp(event, get(item));
76358
- var root_3$1 = template(`<span class="qc-sr-only"><!></span>`);
76359
- var root_2$5 = template(`<li tabindex="0" role="option"><!></li>`);
76360
- var root_1$3 = template(`<ul></ul>`);
77166
+ var root_3$1 = add_locations(template(`<span class="qc-sr-only"><!></span>`), DropdownListItemsSingle[FILENAME], [[129, 20]]);
77167
+ var root_2$5 = add_locations(template(`<li tabindex="0" role="option"><!></li>`), DropdownListItemsSingle[FILENAME], [[113, 12]]);
77168
+ var root_1$3 = add_locations(template(`<ul></ul>`), DropdownListItemsSingle[FILENAME], [[111, 4]]);
76361
77169
 
76362
77170
  function DropdownListItemsSingle($$anchor, $$props) {
77171
+ check_target(new.target);
76363
77172
  push($$props, true);
76364
77173
 
76365
77174
  const selectedElementCLass = "qc-dropdown-list-single-selected";
@@ -76388,7 +77197,7 @@
76388
77197
 
76389
77198
  function focusOnFirstMatchingElement(passedValue) {
76390
77199
  if (get(displayedItemsElements) && get(displayedItemsElements).length > 0) {
76391
- const foundElement = get(displayedItemsElements).find((el) => el.dataset.itemValue.toString() === passedValue.toString());
77200
+ const foundElement = get(displayedItemsElements).find((el) => strict_equals(el.dataset.itemValue.toString(), passedValue.toString()));
76392
77201
 
76393
77202
  if (foundElement) {
76394
77203
  foundElement.focus();
@@ -76400,8 +77209,8 @@
76400
77209
  event.preventDefault();
76401
77210
 
76402
77211
  if (!item.disabled) {
76403
- items().forEach((item) => item.checked = false);
76404
- items().find((option) => option.value === item.value).checked = true;
77212
+ items().forEach((item) => assign(item, 'checked', false, 'src/​sdg/​components/​DropdownList/​DropdownListItems/​DropdownListItemsSingle/​DropdownListItemsSingle.svelte:45:34'));
77213
+ items().find((option) => strict_equals(option.value, item.value)).checked = true;
76405
77214
  selectionCallback()();
76406
77215
  }
76407
77216
  }
@@ -76411,7 +77220,7 @@
76411
77220
  }
76412
77221
 
76413
77222
  function handleComboKey(event, index, item) {
76414
- if (event.key === "ArrowDown") {
77223
+ if (strict_equals(event.key, "ArrowDown")) {
76415
77224
  event.preventDefault();
76416
77225
  event.stopPropagation();
76417
77226
 
@@ -76420,7 +77229,7 @@
76420
77229
  }
76421
77230
  }
76422
77231
 
76423
- if (event.key === "ArrowUp") {
77232
+ if (strict_equals(event.key, "ArrowUp")) {
76424
77233
  event.preventDefault();
76425
77234
  event.stopPropagation();
76426
77235
 
@@ -76431,7 +77240,7 @@
76431
77240
  }
76432
77241
  }
76433
77242
 
76434
- if (event.key === "Enter" || event.key === " ") {
77243
+ if (strict_equals(event.key, "Enter") || strict_equals(event.key, " ")) {
76435
77244
  handleSelection(event, item);
76436
77245
  }
76437
77246
 
@@ -76451,7 +77260,7 @@
76451
77260
  }
76452
77261
 
76453
77262
  function canExit(event, index) {
76454
- return event.key === "Escape" || !event.shiftKey && event.key === "Tab" && index === displayedItems().length - 1;
77263
+ return strict_equals(event.key, "Escape") || !event.shiftKey && strict_equals(event.key, "Tab") && strict_equals(index, displayedItems().length - 1);
76455
77264
  }
76456
77265
 
76457
77266
  function itemsHaveIds() {
@@ -76473,6 +77282,8 @@
76473
77282
  var consequent_1 = ($$anchor) => {
76474
77283
  var ul = root_1$3();
76475
77284
 
77285
+ validate_each_keys(displayedItems, (item) => item.id);
77286
+
76476
77287
  each(ul, 23, displayedItems, (item) => item.id, ($$anchor, item, index) => {
76477
77288
  var li = root_2$5();
76478
77289
 
@@ -76505,6 +77316,7 @@
76505
77316
  }
76506
77317
 
76507
77318
  reset(li);
77319
+ validate_binding('bind:this={displayedItemsElements[index]}', () => get(displayedItemsElements), () => get(index));
76508
77320
  bind_this(li, ($$value, index) => get(displayedItemsElements)[index] = $$value, (index) => get(displayedItemsElements)?.[index], () => [get(index)]);
76509
77321
 
76510
77322
  template_effect(() => {
@@ -76535,9 +77347,15 @@
76535
77347
  append($$anchor, fragment);
76536
77348
 
76537
77349
  return pop({
76538
- focusOnFirstElement,
76539
- focusOnLastElement,
76540
- focusOnFirstMatchingElement,
77350
+ get focusOnFirstElement() {
77351
+ return focusOnFirstElement;
77352
+ },
77353
+ get focusOnLastElement() {
77354
+ return focusOnLastElement;
77355
+ },
77356
+ get focusOnFirstMatchingElement() {
77357
+ return focusOnFirstMatchingElement;
77358
+ },
76541
77359
  get items() {
76542
77360
  return items();
76543
77361
  },
@@ -76586,7 +77404,8 @@
76586
77404
  set handlePrintableCharacter($$value = () => {}) {
76587
77405
  handlePrintableCharacter($$value);
76588
77406
  flushSync();
76589
- }
77407
+ },
77408
+ ...legacy_api()
76590
77409
  });
76591
77410
  }
76592
77411
 
@@ -76612,17 +77431,32 @@
76612
77431
  true
76613
77432
  );
76614
77433
 
77434
+ DropdownListItemsMultiple[FILENAME] = 'src/sdg/components/DropdownList/DropdownListItems/DropdownListItemsMultiple/DropdownListItemsMultiple.svelte';
77435
+
76615
77436
  function handleChange(_, selectionCallback) {
76616
77437
  selectionCallback()();
76617
77438
  }
76618
77439
 
76619
77440
  var on_click = (e, handleLiClick, item) => handleLiClick(e, get(item));
76620
- var root_2$4 = template(`<li><label class="qc-choicefield-label" compact=""><input type="checkbox" class="qc-choicefield qc-compact"> <span> </span></label></li>`);
76621
- var root_1$2 = template(`<ul></ul>`);
77441
+
77442
+ var root_2$4 = add_locations(template(`<li><label class="qc-choicefield-label" compact=""><input type="checkbox" class="qc-choicefield qc-compact"> <span> </span></label></li>`), DropdownListItemsMultiple[FILENAME], [
77443
+ [
77444
+ 153,
77445
+ 12,
77446
+ [
77447
+ [163, 16, [[168, 20], [180, 20]]]
77448
+ ]
77449
+ ]
77450
+ ]);
77451
+
77452
+ var root_1$2 = add_locations(template(`<ul></ul>`), DropdownListItemsMultiple[FILENAME], [[147, 4]]);
76622
77453
 
76623
77454
  function DropdownListItemsMultiple($$anchor, $$props) {
77455
+ check_target(new.target);
76624
77456
  push($$props, true);
76625
77457
 
77458
+ var $$ownership_validator = create_ownership_validator($$props);
77459
+
76626
77460
  let displayedItems = prop($$props, 'displayedItems', 7),
76627
77461
  handleExit = prop($$props, 'handleExit', 7, () => {}),
76628
77462
  selectionCallback = prop($$props, 'selectionCallback', 7, () => {}),
@@ -76667,7 +77501,7 @@
76667
77501
  }
76668
77502
 
76669
77503
  function handleComboKey(event, index) {
76670
- if (event.key === "ArrowDown") {
77504
+ if (strict_equals(event.key, "ArrowDown")) {
76671
77505
  event.preventDefault();
76672
77506
  event.stopPropagation();
76673
77507
 
@@ -76680,7 +77514,7 @@
76680
77514
  }
76681
77515
  }
76682
77516
 
76683
- if (event.key === "ArrowUp") {
77517
+ if (strict_equals(event.key, "ArrowUp")) {
76684
77518
  event.preventDefault();
76685
77519
  event.stopPropagation();
76686
77520
 
@@ -76695,13 +77529,13 @@
76695
77529
  }
76696
77530
  }
76697
77531
 
76698
- if (event.key === "Enter") {
77532
+ if (strict_equals(event.key, "Enter")) {
76699
77533
  event.preventDefault();
76700
77534
  event.stopPropagation();
76701
77535
 
76702
77536
  if (displayedItems().length > 0 && !displayedItems()[index].disabled) {
76703
77537
  event.target.checked = !event.target.checked;
76704
- displayedItems()[index].checked = event.target.checked;
77538
+ $$ownership_validator.mutation('displayedItems', ['displayedItems', index, 'checked'], displayedItems()[index].checked = event.target.checked, 86, 16);
76705
77539
  }
76706
77540
  }
76707
77541
 
@@ -76721,10 +77555,10 @@
76721
77555
  }
76722
77556
 
76723
77557
  function handleLiKeyDown(event, index) {
76724
- if (event.target.tagName !== "INPUT") {
77558
+ if (strict_equals(event.target.tagName, "INPUT", false)) {
76725
77559
  handleKeyDown(event, index);
76726
77560
 
76727
- if (event.key !== "Tab") {
77561
+ if (strict_equals(event.key, "Tab", false)) {
76728
77562
  event.preventDefault();
76729
77563
  event.stopPropagation();
76730
77564
  }
@@ -76732,7 +77566,7 @@
76732
77566
  }
76733
77567
 
76734
77568
  function handleLiClick(event, item) {
76735
- if (event.target.tagName !== "INPUT") {
77569
+ if (strict_equals(event.target.tagName, "INPUT", false)) {
76736
77570
  event.preventDefault();
76737
77571
  event.stopPropagation();
76738
77572
 
@@ -76743,7 +77577,7 @@
76743
77577
  }
76744
77578
 
76745
77579
  function canExit(event, index) {
76746
- return event.key === "Escape" || !event.shiftKey && event.key === "Tab" && index === displayedItems().length - 1;
77580
+ return strict_equals(event.key, "Escape") || !event.shiftKey && strict_equals(event.key, "Tab") && strict_equals(index, displayedItems().length - 1);
76747
77581
  }
76748
77582
 
76749
77583
  function itemsHaveIds() {
@@ -76765,6 +77599,8 @@
76765
77599
  var consequent = ($$anchor) => {
76766
77600
  var ul = root_1$2();
76767
77601
 
77602
+ validate_each_keys(displayedItems, (item) => item.id);
77603
+
76768
77604
  each(ul, 23, displayedItems, (item) => item.id, ($$anchor, item, index) => {
76769
77605
  var li = root_2$4();
76770
77606
 
@@ -76781,6 +77617,8 @@
76781
77617
  set_attribute(input, 'name', name);
76782
77618
  input.__change = [handleChange, selectionCallback];
76783
77619
  input.__keydown = (e) => handleKeyDown(e, get(index));
77620
+ validate_binding('bind:checked={item.checked}', () => get(item), () => 'checked');
77621
+ validate_binding('bind:this={displayedItemsElements[index]}', () => get(displayedItemsElements), () => get(index));
76784
77622
  bind_this(input, ($$value, index) => get(displayedItemsElements)[index] = $$value, (index) => get(displayedItemsElements)?.[index], () => [get(index)]);
76785
77623
 
76786
77624
  var span = sibling(input, 2);
@@ -76824,9 +77662,15 @@
76824
77662
  append($$anchor, fragment);
76825
77663
 
76826
77664
  return pop({
76827
- focusOnFirstElement,
76828
- focusOnLastElement,
76829
- focusOnFirstMatchingElement,
77665
+ get focusOnFirstElement() {
77666
+ return focusOnFirstElement;
77667
+ },
77668
+ get focusOnLastElement() {
77669
+ return focusOnLastElement;
77670
+ },
77671
+ get focusOnFirstMatchingElement() {
77672
+ return focusOnFirstMatchingElement;
77673
+ },
76830
77674
  get displayedItems() {
76831
77675
  return displayedItems();
76832
77676
  },
@@ -76861,7 +77705,8 @@
76861
77705
  set handlePrintableCharacter($$value = () => {}) {
76862
77706
  handlePrintableCharacter($$value);
76863
77707
  flushSync();
76864
- }
77708
+ },
77709
+ ...legacy_api()
76865
77710
  });
76866
77711
  }
76867
77712
 
@@ -76885,10 +77730,13 @@
76885
77730
  true
76886
77731
  );
76887
77732
 
76888
- var root_4$2 = template(`<span class="qc-dropdown-list-no-options"><!></span>`);
76889
- var root$3 = template(`<div class="qc-dropdown-list-items" tabindex="-1"><!> <div class="qc-dropdown-list-no-options-container" role="status"><!></div></div>`);
77733
+ DropdownListItems[FILENAME] = 'src/sdg/components/DropdownList/DropdownListItems/DropdownListItems.svelte';
77734
+
77735
+ var root_4$2 = add_locations(template(`<span class="qc-dropdown-list-no-options"><!></span>`), DropdownListItems[FILENAME], [[105, 16]]);
77736
+ var root$3 = add_locations(template(`<div class="qc-dropdown-list-items" tabindex="-1"><!> <div class="qc-dropdown-list-no-options-container" role="status"><!></div></div>`), DropdownListItems[FILENAME], [[67, 0, [[102, 4]]]]);
76890
77737
 
76891
77738
  function DropdownListItems($$anchor, $$props) {
77739
+ check_target(new.target);
76892
77740
  push($$props, true);
76893
77741
 
76894
77742
  let id = prop($$props, 'id', 7),
@@ -77053,9 +77901,15 @@
77053
77901
  append($$anchor, div);
77054
77902
 
77055
77903
  return pop({
77056
- focus,
77057
- focusOnLastElement,
77058
- focusOnFirstMatchingElement,
77904
+ get focus() {
77905
+ return focus;
77906
+ },
77907
+ get focusOnLastElement() {
77908
+ return focusOnLastElement;
77909
+ },
77910
+ get focusOnFirstMatchingElement() {
77911
+ return focusOnFirstMatchingElement;
77912
+ },
77059
77913
  get id() {
77060
77914
  return id();
77061
77915
  },
@@ -77146,7 +78000,8 @@
77146
78000
  set placeholder($$value) {
77147
78001
  placeholder($$value);
77148
78002
  flushSync();
77149
- }
78003
+ },
78004
+ ...legacy_api()
77150
78005
  });
77151
78006
  }
77152
78007
 
@@ -77176,11 +78031,14 @@
77176
78031
  true
77177
78032
  );
77178
78033
 
77179
- var root_1$1 = template(`<span class="qc-dropdown-choice"><!></span>`);
77180
- var root_2$3 = template(`<span class="qc-dropdown-placeholder"><!></span>`);
77181
- var root$2 = template(`<button><span class="qc-dropdown-text"><!></span> <span><!></span></button>`);
78034
+ DropdownListButton[FILENAME] = 'src/sdg/components/DropdownList/DropdownListButton/DropdownListButton.svelte';
78035
+
78036
+ var root_1$1 = add_locations(template(`<span class="qc-dropdown-choice"><!></span>`), DropdownListButton[FILENAME], [[29, 8]]);
78037
+ var root_2$3 = add_locations(template(`<span class="qc-dropdown-placeholder"><!></span>`), DropdownListButton[FILENAME], [[31, 8]]);
78038
+ var root$2 = add_locations(template(`<button><!> <span><!></span></button>`), DropdownListButton[FILENAME], [[19, 0, [[34, 4]]]]);
77182
78039
 
77183
78040
  function DropdownListButton($$anchor, $$props) {
78041
+ check_target(new.target);
77184
78042
  push($$props, true);
77185
78043
 
77186
78044
  let inputId = prop($$props, 'inputId', 7),
@@ -77188,17 +78046,19 @@
77188
78046
  disabled = prop($$props, 'disabled', 7),
77189
78047
  selectedOptionsText = prop($$props, 'selectedOptionsText', 7, ""),
77190
78048
  placeholder = prop($$props, 'placeholder', 7),
77191
- rest = rest_props($$props, [
77192
- '$$slots',
77193
- '$$events',
77194
- '$$legacy',
77195
- '$$host',
77196
- 'inputId',
77197
- 'expanded',
77198
- 'disabled',
77199
- 'selectedOptionsText',
77200
- 'placeholder'
77201
- ]);
78049
+ rest = rest_props(
78050
+ $$props,
78051
+ [
78052
+ '$$slots',
78053
+ '$$events',
78054
+ '$$legacy',
78055
+ '$$host',
78056
+ 'inputId',
78057
+ 'expanded',
78058
+ 'disabled',
78059
+ 'selectedOptionsText',
78060
+ 'placeholder'
78061
+ ]);
77202
78062
 
77203
78063
  let button;
77204
78064
 
@@ -77208,26 +78068,25 @@
77208
78068
 
77209
78069
  var button_1 = root$2();
77210
78070
  let attributes;
77211
- var span = child(button_1);
77212
- var node = child(span);
78071
+ var node = child(button_1);
77213
78072
 
77214
78073
  {
77215
78074
  var consequent = ($$anchor) => {
77216
- var span_1 = root_1$1();
77217
- var node_1 = child(span_1);
78075
+ var span = root_1$1();
78076
+ var node_1 = child(span);
77218
78077
 
77219
78078
  html$1(node_1, selectedOptionsText);
77220
- reset(span_1);
77221
- append($$anchor, span_1);
78079
+ reset(span);
78080
+ append($$anchor, span);
77222
78081
  };
77223
78082
 
77224
78083
  var alternate = ($$anchor) => {
77225
- var span_2 = root_2$3();
77226
- var node_2 = child(span_2);
78084
+ var span_1 = root_2$3();
78085
+ var node_2 = child(span_1);
77227
78086
 
77228
78087
  html$1(node_2, placeholder);
77229
- reset(span_2);
77230
- append($$anchor, span_2);
78088
+ reset(span_1);
78089
+ append($$anchor, span_1);
77231
78090
  };
77232
78091
 
77233
78092
  if_block(node, ($$render) => {
@@ -77235,44 +78094,44 @@
77235
78094
  });
77236
78095
  }
77237
78096
 
77238
- reset(span);
78097
+ var span_2 = sibling(node, 2);
78098
+
78099
+ set_class(span_2, 1, clsx(["qc-dropdown-button-icon"]));
77239
78100
 
77240
- var span_3 = sibling(span, 2);
77241
- var node_3 = child(span_3);
78101
+ var node_3 = child(span_2);
77242
78102
  const expression = user_derived(() => disabled() ? "grey-regular" : "blue-piv");
78103
+ const expression_1 = user_derived(() => expanded() ? 0 : 180);
77243
78104
 
77244
78105
  Icon(node_3, {
77245
78106
  type: 'chevron-up-thin',
77246
78107
  get color() {
77247
78108
  return get(expression);
77248
78109
  },
77249
- size: 'sm'
78110
+ size: 'sm',
78111
+ get rotate() {
78112
+ return get(expression_1);
78113
+ }
77250
78114
  });
77251
78115
 
77252
- reset(span_3);
78116
+ reset(span_2);
77253
78117
  reset(button_1);
77254
78118
  bind_this(button_1, ($$value) => button = $$value, () => button);
77255
78119
 
77256
- template_effect(() => {
77257
- attributes = set_attributes(button_1, attributes, {
77258
- type: 'button',
77259
- id: inputId(),
77260
- disabled: disabled(),
77261
- class: 'qc-dropdown-button',
77262
- role: 'combobox',
77263
- ...rest
77264
- });
77265
-
77266
- set_class(span_3, 1, clsx([
77267
- "qc-dropdown-button-icon",
77268
- expanded() && "qc-dropdown-button-icon-expanded"
77269
- ]));
77270
- });
78120
+ template_effect(() => attributes = set_attributes(button_1, attributes, {
78121
+ type: 'button',
78122
+ id: inputId(),
78123
+ disabled: disabled(),
78124
+ class: 'qc-dropdown-button',
78125
+ role: 'combobox',
78126
+ ...rest
78127
+ }));
77271
78128
 
77272
78129
  append($$anchor, button_1);
77273
78130
 
77274
78131
  return pop({
77275
- focus,
78132
+ get focus() {
78133
+ return focus;
78134
+ },
77276
78135
  get inputId() {
77277
78136
  return inputId();
77278
78137
  },
@@ -77307,7 +78166,8 @@
77307
78166
  set placeholder($$value) {
77308
78167
  placeholder($$value);
77309
78168
  flushSync();
77310
- }
78169
+ },
78170
+ ...legacy_api()
77311
78171
  });
77312
78172
  }
77313
78173
 
@@ -77325,13 +78185,36 @@
77325
78185
  true
77326
78186
  );
77327
78187
 
77328
- var root_2$2 = template(`<div class="qc-dropdown-list-search"><!></div>`);
77329
- var root_3 = template(`<span> </span>`);
77330
- var root$1 = template(`<div><div><!> <div tabindex="-1"><!> <div class="qc-dropdown-list-expanded" tabindex="-1" role="listbox"><!> <!> <div role="status" class="qc-sr-only"><!></div></div></div></div> <!></div>`);
78188
+ DropdownList[FILENAME] = 'src/sdg/components/DropdownList/DropdownList.svelte';
78189
+
78190
+ var root_2$2 = add_locations(template(`<div class="qc-dropdown-list-search"><!></div>`), DropdownList[FILENAME], [[337, 20]]);
78191
+ var root_3 = add_locations(template(`<span> </span>`), DropdownList[FILENAME], [[379, 24]]);
78192
+
78193
+ var root$1 = add_locations(template(`<div><div><!> <div tabindex="-1"><!> <div class="qc-dropdown-list-expanded" tabindex="-1" role="listbox"><!> <!> <div role="status" class="qc-sr-only"><!></div></div></div></div> <!></div>`), DropdownList[FILENAME], [
78194
+ [
78195
+ 274,
78196
+ 0,
78197
+ [
78198
+ [
78199
+ 281,
78200
+ 4,
78201
+ [
78202
+ [
78203
+ 301,
78204
+ 8,
78205
+ [[328, 12, [[377, 16]]]]
78206
+ ]
78207
+ ]
78208
+ ]
78209
+ ]
78210
+ ]
78211
+ ]);
77331
78212
 
77332
78213
  function DropdownList($$anchor, $$props) {
78214
+ check_target(new.target);
77333
78215
  push($$props, true);
77334
78216
 
78217
+ var $$ownership_validator = create_ownership_validator($$props);
77335
78218
  const lang = Utils.getPageLanguage();
77336
78219
 
77337
78220
  let id = prop($$props, 'id', 23, () => Math.random().toString(36).substring(2, 15)),
@@ -77341,7 +78224,7 @@
77341
78224
  items = prop($$props, 'items', 23, () => []),
77342
78225
  value = prop($$props, 'value', 31, () => proxy([])),
77343
78226
  placeholder = prop($$props, 'placeholder', 7),
77344
- noOptionsMessage = prop($$props, 'noOptionsMessage', 7, lang === "fr" ? "Aucun élément" : "No item"),
78227
+ noOptionsMessage = prop($$props, 'noOptionsMessage', 23, () => strict_equals(lang, "fr") ? "Aucun élément" : "No item"),
77345
78228
  enableSearch = prop($$props, 'enableSearch', 7, false),
77346
78229
  required = prop($$props, 'required', 7, false),
77347
78230
  disabled = prop($$props, 'disabled', 7, false),
@@ -77354,7 +78237,7 @@
77354
78237
  webComponentMode = prop($$props, 'webComponentMode', 7, false),
77355
78238
  webComponentParentRow = prop($$props, 'webComponentParentRow', 7);
77356
78239
 
77357
- const defaultPlaceholder = lang === "fr" ? "Faire une sélection" : "Select an option",
78240
+ const defaultPlaceholder = strict_equals(lang, "fr") ? "Faire une sélection" : "Select an option",
77358
78241
  inputId = `${id()}-input`,
77359
78242
  popupId = `${id()}-popup`,
77360
78243
  itemsId = `${id()}-items`,
@@ -77370,7 +78253,7 @@
77370
78253
  selectedItems = user_derived(() => items().filter((item) => item.checked) ?? []),
77371
78254
  selectedOptionsText = user_derived(() => {
77372
78255
  if (get(selectedItems).length >= 3) {
77373
- if (lang === "fr") {
78256
+ if (strict_equals(lang, "fr")) {
77374
78257
  return `${get(selectedItems).length} options sélectionnées`;
77375
78258
  }
77376
78259
 
@@ -77413,7 +78296,7 @@
77413
78296
  const s = get(displayedItems).length > 1 ? "s" : "";
77414
78297
 
77415
78298
  if (get(displayedItems).length > 0) {
77416
- return lang === "fr" ? `${get(displayedItems).length} résultat${s} disponible${s}. Utilisez les flèches directionnelles haut et bas pour vous déplacer dans la liste.` : `${get(displayedItems).length} result${s} available. Use up and down arrow keys to navigate through the list.`;
78299
+ return strict_equals(lang, "fr") ? `${get(displayedItems).length} résultat${s} disponible${s}. Utilisez les flèches directionnelles haut et bas pour vous déplacer dans la liste.` : `${get(displayedItems).length} result${s} available. Use up and down arrow keys to navigate through the list.`;
77417
78300
  }
77418
78301
 
77419
78302
  return "";
@@ -77444,27 +78327,27 @@
77444
78327
  // Le changement de focus a lieu après le lancement de l'événement clavier.
77445
78328
  // Il faut donc faire un court sleep pour avoir le nouvel élément en focus.
77446
78329
  Utils.sleep(5).then(() => {
77447
- if (event.key === "Tab" && !Utils.componentIsActive(get(instance))) {
78330
+ if (strict_equals(event.key, "Tab") && !Utils.componentIsActive(get(instance))) {
77448
78331
  set(expanded, false);
77449
78332
  }
77450
78333
  }).catch(console.error);
77451
78334
  }
77452
78335
 
77453
78336
  function handleEscape(event) {
77454
- if (event.key === "Escape") {
78337
+ if (strict_equals(event.key, "Escape")) {
77455
78338
  set(expanded, false);
77456
78339
  }
77457
78340
  }
77458
78341
 
77459
78342
  function handleArrowUp(event, targetComponent) {
77460
- if (event.key === "ArrowUp" && targetComponent) {
78343
+ if (strict_equals(event.key, "ArrowUp") && targetComponent) {
77461
78344
  event.preventDefault();
77462
78345
  targetComponent.focus();
77463
78346
  }
77464
78347
  }
77465
78348
 
77466
78349
  function handleArrowDown(event, targetComponent) {
77467
- if (event.key === "ArrowDown" && targetComponent) {
78350
+ if (strict_equals(event.key, "ArrowDown") && targetComponent) {
77468
78351
  event.preventDefault();
77469
78352
  set(expanded, true);
77470
78353
  targetComponent.focus();
@@ -77475,7 +78358,7 @@
77475
78358
  handleEscape(event);
77476
78359
  handleTab(event);
77477
78360
 
77478
- if (event.key === "ArrowDown") {
78361
+ if (strict_equals(event.key, "ArrowDown")) {
77479
78362
  event.preventDefault();
77480
78363
 
77481
78364
  if (get(expanded)) {
@@ -77486,7 +78369,7 @@
77486
78369
  }
77487
78370
  }
77488
78371
 
77489
- if (event.key === "ArrowUp") {
78372
+ if (strict_equals(event.key, "ArrowUp")) {
77490
78373
  event.preventDefault();
77491
78374
 
77492
78375
  if (get(expanded)) {
@@ -77519,7 +78402,7 @@
77519
78402
  set(expanded, false);
77520
78403
  set(hiddenSearchText, "");
77521
78404
 
77522
- if (key === "Escape" && get(button)) {
78405
+ if (strict_equals(key, "Escape") && get(button)) {
77523
78406
  get(button).focus();
77524
78407
  }
77525
78408
  }
@@ -77541,7 +78424,7 @@
77541
78424
  });
77542
78425
 
77543
78426
  user_effect(() => {
77544
- if (get(previousValue)?.toString() !== value()?.toString()) {
78427
+ if (strict_equals(get(previousValue)?.toString(), value()?.toString(), false)) {
77545
78428
  invalid(false);
77546
78429
  }
77547
78430
  });
@@ -77556,7 +78439,7 @@
77556
78439
  user_effect(() => {
77557
78440
  const tempValue = get(selectedItems)?.map((item) => item.value);
77558
78441
 
77559
- if (tempValue?.toString() !== "") {
78442
+ if (strict_equals(tempValue?.toString(), "", false)) {
77560
78443
  value(tempValue);
77561
78444
  } else {
77562
78445
  value([]);
@@ -77583,11 +78466,11 @@
77583
78466
  const optionWithEmptyValue = findOptionWithEmptyValue();
77584
78467
 
77585
78468
  if (!optionWithEmptyValue) return;
77586
- placeholder(optionWithEmptyValue.label !== "" ? optionWithEmptyValue.label : defaultPlaceholder);
78469
+ placeholder(strict_equals(optionWithEmptyValue.label, "", false) ? optionWithEmptyValue.label : defaultPlaceholder);
77587
78470
  });
77588
78471
 
77589
78472
  function findOptionWithEmptyValue() {
77590
- return items()?.find((item) => item.value === "" || item.value === null || item.value === undefined);
78473
+ return items()?.find((item) => strict_equals(item.value, "") || strict_equals(item.value, null) || strict_equals(item.value, undefined));
77591
78474
  }
77592
78475
 
77593
78476
  var div = root$1();
@@ -77692,7 +78575,7 @@
77692
78575
  handleArrowDown(e, get(dropdownItems));
77693
78576
  handleArrowUp(e, get(button));
77694
78577
 
77695
- if (e.key === "Enter") {
78578
+ if (strict_equals(e.key, "Enter")) {
77696
78579
  e.preventDefault();
77697
78580
  }
77698
78581
  },
@@ -77718,45 +78601,49 @@
77718
78601
 
77719
78602
  var node_4 = sibling(node_2, 2);
77720
78603
 
77721
- bind_this(
77722
- DropdownListItems(node_4, {
77723
- id: itemsId,
77724
- get enableSearch() {
77725
- return enableSearch();
77726
- },
77727
- get placeholder() {
77728
- return placeholder();
77729
- },
77730
- get multiple() {
77731
- return multiple();
77732
- },
77733
- get items() {
77734
- return items();
77735
- },
77736
- get displayedItems() {
77737
- return get(displayedItems);
77738
- },
77739
- get noOptionsMessage() {
77740
- return noOptionsMessage();
77741
- },
77742
- selectionCallbackSingle: () => {
77743
- closeDropdown("");
77744
- get(button)?.focus();
77745
- },
77746
- handleExitSingle: (key) => closeDropdown(key),
77747
- handleExitMultiple: (key) => closeDropdown(key),
77748
- focusOnOuterElement: () => enableSearch() ? get(searchInput)?.focus() : get(button)?.focus(),
77749
- handlePrintableCharacter,
77750
- get value() {
77751
- return value();
77752
- },
77753
- set value($$value) {
77754
- value($$value);
77755
- }
77756
- }),
77757
- ($$value) => set(dropdownItems, $$value, true),
77758
- () => get(dropdownItems)
77759
- );
78604
+ {
78605
+ $$ownership_validator.binding('value', DropdownListItems, value);
78606
+
78607
+ bind_this(
78608
+ DropdownListItems(node_4, {
78609
+ id: itemsId,
78610
+ get enableSearch() {
78611
+ return enableSearch();
78612
+ },
78613
+ get placeholder() {
78614
+ return placeholder();
78615
+ },
78616
+ get multiple() {
78617
+ return multiple();
78618
+ },
78619
+ get items() {
78620
+ return items();
78621
+ },
78622
+ get displayedItems() {
78623
+ return get(displayedItems);
78624
+ },
78625
+ get noOptionsMessage() {
78626
+ return noOptionsMessage();
78627
+ },
78628
+ selectionCallbackSingle: () => {
78629
+ closeDropdown("");
78630
+ get(button)?.focus();
78631
+ },
78632
+ handleExitSingle: (key) => closeDropdown(key),
78633
+ handleExitMultiple: (key) => closeDropdown(key),
78634
+ focusOnOuterElement: () => enableSearch() ? get(searchInput)?.focus() : get(button)?.focus(),
78635
+ handlePrintableCharacter,
78636
+ get value() {
78637
+ return value();
78638
+ },
78639
+ set value($$value) {
78640
+ value($$value);
78641
+ }
78642
+ }),
78643
+ ($$value) => set(dropdownItems, $$value, true),
78644
+ () => get(dropdownItems)
78645
+ );
78646
+ }
77760
78647
 
77761
78648
  var div_5 = sibling(node_4, 2);
77762
78649
  var node_5 = child(div_5);
@@ -77779,25 +78666,29 @@
77779
78666
  var node_6 = sibling(div_1, 2);
77780
78667
  const expression_1 = user_derived(() => label() ?? ariaLabel());
77781
78668
 
77782
- FormError(node_6, {
77783
- id: errorId,
77784
- get invalid() {
77785
- return invalid();
77786
- },
77787
- get invalidText() {
77788
- return invalidText();
77789
- },
77790
- extraClasses: ["qc-xs-mt"],
77791
- get label() {
77792
- return get(expression_1);
77793
- },
77794
- get rootElement() {
77795
- return errorElement();
77796
- },
77797
- set rootElement($$value) {
77798
- errorElement($$value);
77799
- }
77800
- });
78669
+ {
78670
+ $$ownership_validator.binding('errorElement', FormError, errorElement);
78671
+
78672
+ FormError(node_6, {
78673
+ id: errorId,
78674
+ get invalid() {
78675
+ return invalid();
78676
+ },
78677
+ get invalidText() {
78678
+ return invalidText();
78679
+ },
78680
+ extraClasses: ["qc-xs-mt"],
78681
+ get label() {
78682
+ return get(expression_1);
78683
+ },
78684
+ get rootElement() {
78685
+ return errorElement();
78686
+ },
78687
+ set rootElement($$value) {
78688
+ errorElement($$value);
78689
+ }
78690
+ });
78691
+ }
77801
78692
 
77802
78693
  reset(div);
77803
78694
  bind_this(div, ($$value) => rootElement($$value), () => rootElement());
@@ -77961,7 +78852,8 @@
77961
78852
  set webComponentParentRow($$value) {
77962
78853
  webComponentParentRow($$value);
77963
78854
  flushSync();
77964
- }
78855
+ },
78856
+ ...legacy_api()
77965
78857
  });
77966
78858
  }
77967
78859
 
@@ -77993,20 +78885,25 @@
77993
78885
  true
77994
78886
  );
77995
78887
 
77996
- var root_2$1 = template(`<legend><!></legend>`);
77997
- var root_1 = template(`<fieldset><!> <div><!></div> <!></fieldset>`);
77998
- var root_4$1 = template(`<div class="qc-fieldset-invalid"><!></div>`);
78888
+ Fieldset[FILENAME] = 'src/sdg/components/Fieldset/Fieldset.svelte';
78889
+
78890
+ var root_2$1 = add_locations(template(`<legend><!></legend>`), Fieldset[FILENAME], [[43, 4]]);
78891
+ var root_1 = add_locations(template(`<fieldset><!> <div><!></div> <!></fieldset>`), Fieldset[FILENAME], [[31, 0, [[47, 4]]]]);
78892
+ var root_4$1 = add_locations(template(`<div class="qc-fieldset-invalid"><!></div>`), Fieldset[FILENAME], [[70, 4]]);
77999
78893
 
78000
78894
  function Fieldset($$anchor, $$props) {
78895
+ check_target(new.target);
78001
78896
  push($$props, true);
78002
78897
 
78003
- const fieldset = ($$anchor) => {
78898
+ const fieldset = wrap_snippet(Fieldset, function ($$anchor) {
78899
+ validate_snippet_args(...arguments);
78900
+
78004
78901
  var fieldset_1 = root_1();
78005
78902
 
78006
78903
  set_attribute(fieldset_1, 'aria-describedby', legendId);
78007
78904
 
78008
78905
  fieldset_1.__change = function (...$$args) {
78009
- onchange()?.apply(this, $$args);
78906
+ apply(onchange, this, $$args, Fieldset, [38, 11]);
78010
78907
  };
78011
78908
 
78012
78909
  var node = child(fieldset_1);
@@ -78086,7 +78983,7 @@
78086
78983
  });
78087
78984
 
78088
78985
  append($$anchor, fieldset_1);
78089
- };
78986
+ });
78090
78987
 
78091
78988
  let legend = prop($$props, 'legend', 7),
78092
78989
  name = prop($$props, 'name', 7),
@@ -78236,7 +79133,8 @@
78236
79133
  set rootElement($$value) {
78237
79134
  rootElement($$value);
78238
79135
  flushSync();
78239
- }
79136
+ },
79137
+ ...legacy_api()
78240
79138
  });
78241
79139
  }
78242
79140
 
@@ -78266,9 +79164,14 @@
78266
79164
  true
78267
79165
  );
78268
79166
 
79167
+ ChoiceGroup[FILENAME] = 'src/sdg/components/ChoiceGroup/ChoiceGroup.svelte';
79168
+
78269
79169
  function ChoiceGroup($$anchor, $$props) {
79170
+ check_target(new.target);
78270
79171
  push($$props, true);
78271
79172
 
79173
+ var $$ownership_validator = create_ownership_validator($$props);
79174
+
78272
79175
  let invalid = prop($$props, 'invalid', 15, false),
78273
79176
  invalidText = prop($$props, 'invalidText', 7),
78274
79177
  children = prop($$props, 'children', 7),
@@ -78278,21 +79181,23 @@
78278
79181
  host = prop($$props, 'host', 7),
78279
79182
  name = prop($$props, 'name', 7),
78280
79183
  required = prop($$props, 'required', 7),
78281
- restProps = rest_props($$props, [
78282
- '$$slots',
78283
- '$$events',
78284
- '$$legacy',
78285
- '$$host',
78286
- 'invalid',
78287
- 'invalidText',
78288
- 'children',
78289
- 'compact',
78290
- 'selectionButton',
78291
- 'inline',
78292
- 'host',
78293
- 'name',
78294
- 'required'
78295
- ]);
79184
+ restProps = rest_props(
79185
+ $$props,
79186
+ [
79187
+ '$$slots',
79188
+ '$$events',
79189
+ '$$legacy',
79190
+ '$$host',
79191
+ 'invalid',
79192
+ 'invalidText',
79193
+ 'children',
79194
+ 'compact',
79195
+ 'selectionButton',
79196
+ 'inline',
79197
+ 'host',
79198
+ 'name',
79199
+ 'required'
79200
+ ]);
78296
79201
 
78297
79202
  let fieldsetElement = state(void 0);
78298
79203
 
@@ -78306,49 +79211,53 @@
78306
79211
  (host() ? host() : get(fieldsetElement)).querySelectorAll('input, .qc-choicefield').forEach((input) => updateInput(input, required(), invalid(), compact(), selectionButton(), inline(), name()));
78307
79212
  });
78308
79213
 
78309
- Fieldset($$anchor, spread_props(
78310
- {
78311
- get required() {
78312
- return required();
78313
- },
78314
- get compact() {
78315
- return compact();
78316
- },
78317
- get selectionButton() {
78318
- return selectionButton();
78319
- },
78320
- get inline() {
78321
- return inline();
78322
- },
78323
- get invalidText() {
78324
- return invalidText();
78325
- },
78326
- onchange
78327
- },
78328
- () => restProps,
78329
- {
78330
- get invalid() {
78331
- return invalid();
78332
- },
78333
- set invalid($$value) {
78334
- invalid($$value);
78335
- },
78336
- get rootElement() {
78337
- return get(fieldsetElement);
78338
- },
78339
- set rootElement($$value) {
78340
- set(fieldsetElement, $$value, true);
78341
- },
78342
- children: ($$anchor, $$slotProps) => {
78343
- var fragment_1 = comment();
78344
- var node = first_child(fragment_1);
79214
+ {
79215
+ $$ownership_validator.binding('invalid', Fieldset, invalid);
78345
79216
 
78346
- snippet(node, children);
78347
- append($$anchor, fragment_1);
79217
+ Fieldset($$anchor, spread_props(
79218
+ {
79219
+ get required() {
79220
+ return required();
79221
+ },
79222
+ get compact() {
79223
+ return compact();
79224
+ },
79225
+ get selectionButton() {
79226
+ return selectionButton();
79227
+ },
79228
+ get inline() {
79229
+ return inline();
79230
+ },
79231
+ get invalidText() {
79232
+ return invalidText();
79233
+ },
79234
+ onchange
78348
79235
  },
78349
- $$slots: { default: true }
78350
- }
78351
- ));
79236
+ () => restProps,
79237
+ {
79238
+ get invalid() {
79239
+ return invalid();
79240
+ },
79241
+ set invalid($$value) {
79242
+ invalid($$value);
79243
+ },
79244
+ get rootElement() {
79245
+ return get(fieldsetElement);
79246
+ },
79247
+ set rootElement($$value) {
79248
+ set(fieldsetElement, $$value, true);
79249
+ },
79250
+ children: wrap_snippet(ChoiceGroup, ($$anchor, $$slotProps) => {
79251
+ var fragment_1 = comment();
79252
+ var node = first_child(fragment_1);
79253
+
79254
+ snippet(node, children);
79255
+ append($$anchor, fragment_1);
79256
+ }),
79257
+ $$slots: { default: true }
79258
+ }
79259
+ ));
79260
+ }
78352
79261
 
78353
79262
  return pop({
78354
79263
  get invalid() {
@@ -78413,7 +79322,8 @@
78413
79322
  set required($$value) {
78414
79323
  required($$value);
78415
79324
  flushSync();
78416
- }
79325
+ },
79326
+ ...legacy_api()
78417
79327
  });
78418
79328
  }
78419
79329
 
@@ -78435,24 +79345,27 @@
78435
79345
  true
78436
79346
  );
78437
79347
 
78438
- var root_2 = template(`<label><input type="checkbox"> Multiligne</label>`);
78439
- var root_4 = template(`<label><input type="radio" name="size"> </label>`);
78440
- var root_5 = template(`<label><input type="checkbox"> Required</label>`);
78441
- var root_6 = template(`<label><input type="checkbox"> Invalid</label>`);
78442
- var root_7 = template(`<input type="text">`);
78443
- var root_8 = template(`<input type="text">`);
78444
- var root_9 = template(`<input type="text">`);
78445
- var root_11 = template(`<input type="text">`);
78446
- var root_12 = template(`<input type="number">`);
78447
- var root_10 = template(`<!> <!>`, 1);
78448
- var root = template(`<!> <div class="attributes qc-hash-f0iu2z"><!> <!> <!> <!> <!> <!> <!> <!></div> <link rel="stylesheet">`, 1);
79348
+ TextFieldDemo[FILENAME] = 'src/sdg/components/TextField/Doc/TextFieldDemo.svelte';
79349
+
79350
+ var root_2 = add_locations(template(`<label><input type="checkbox"> Multiligne</label>`), TextFieldDemo[FILENAME], [[70, 8, [[71, 12]]]]);
79351
+ var root_4 = add_locations(template(`<label><input type="radio" name="size"> </label>`), TextFieldDemo[FILENAME], [[78, 12, [[79, 16]]]]);
79352
+ var root_5 = add_locations(template(`<label><input type="checkbox"> Required</label>`), TextFieldDemo[FILENAME], [[89, 8, [[90, 12]]]]);
79353
+ var root_6 = add_locations(template(`<label><input type="checkbox"> Invalid</label>`), TextFieldDemo[FILENAME], [[96, 8, [[97, 12]]]]);
79354
+ var root_7 = add_locations(template(`<input type="text">`), TextFieldDemo[FILENAME], [[103, 8]]);
79355
+ var root_8 = add_locations(template(`<input type="text">`), TextFieldDemo[FILENAME], [[107, 8]]);
79356
+ var root_9 = add_locations(template(`<input type="text">`), TextFieldDemo[FILENAME], [[112, 8]]);
79357
+ var root_11 = add_locations(template(`<input type="text">`), TextFieldDemo[FILENAME], [[120, 12]]);
79358
+ var root_12 = add_locations(template(`<input type="number">`), TextFieldDemo[FILENAME], [[127, 12]]);
79359
+ var root_10 = add_locations(template(`<!> <!>`, 1), TextFieldDemo[FILENAME], []);
79360
+ var root = add_locations(template(`<!> <div class="attributes qc-hash-f0iu2z"><!> <!> <!> <!> <!> <!> <!> <!></div> <link rel="stylesheet">`, 1), TextFieldDemo[FILENAME], [[68, 0], [142, 0]]);
78449
79361
 
78450
79362
  const $$css = {
78451
79363
  hash: 'qc-hash-f0iu2z',
78452
- code: '.attributes.qc-hash-f0iu2z {display:flex;flex-direction:column;flex-wrap:wrap;gap:0 24px;max-height:352px;}'
79364
+ code: '\n .attributes.qc-hash-f0iu2z {\n display: flex;\n flex-direction: column;\n flex-wrap: wrap;\n gap: 0 24px;\n max-height: 352px;\n }\n'
78453
79365
  };
78454
79366
 
78455
79367
  function TextFieldDemo($$anchor, $$props) {
79368
+ check_target(new.target);
78456
79369
  push($$props, true);
78457
79370
  append_styles$1($$anchor, $$css);
78458
79371
 
@@ -78474,8 +79387,14 @@
78474
79387
  inputType = state("text"),
78475
79388
  multiligne = state(false);
78476
79389
 
79390
+ inspect(() => [
79391
+ get(multiligne),
79392
+ get(inputTag),
79393
+ get(inputType)
79394
+ ]);
79395
+
78477
79396
  user_effect(() => {
78478
- console.log(get(multiligne), get(inputTag), get(inputType));
79397
+ console.log(...log_if_contains_state('log', get(multiligne), get(inputTag), get(inputType)));
78479
79398
 
78480
79399
  if (get(multiligne)) {
78481
79400
  set(inputTag, "textarea");
@@ -78513,23 +79432,33 @@
78513
79432
  get maxlength() {
78514
79433
  return get(expression_1);
78515
79434
  },
78516
- children: ($$anchor, $$slotProps) => {
79435
+ children: wrap_snippet(TextFieldDemo, ($$anchor, $$slotProps) => {
78517
79436
  var fragment_1 = comment();
78518
79437
  var node_1 = first_child(fragment_1);
78519
79438
 
78520
- element(node_1, () => get(inputTag), false, ($$element, $$anchor) => {
78521
- let attributes;
78522
-
78523
- template_effect(() => attributes = set_attributes($$element, attributes, {
78524
- inputType: get(inputType),
78525
- value: value(),
78526
- name: 'textfield-demo',
78527
- placeholder: placeholder()
78528
- }));
78529
- });
79439
+ validate_void_dynamic_element(() => get(inputTag));
79440
+ validate_dynamic_element_tag(() => get(inputTag));
79441
+
79442
+ element(
79443
+ node_1,
79444
+ () => get(inputTag),
79445
+ false,
79446
+ ($$element, $$anchor) => {
79447
+ let attributes;
79448
+
79449
+ template_effect(() => attributes = set_attributes($$element, attributes, {
79450
+ inputType: get(inputType),
79451
+ value: value(),
79452
+ name: 'textfield-demo',
79453
+ placeholder: placeholder()
79454
+ }));
79455
+ },
79456
+ undefined,
79457
+ [58, 4]
79458
+ );
78530
79459
 
78531
79460
  append($$anchor, fragment_1);
78532
- },
79461
+ }),
78533
79462
  $$slots: { default: true }
78534
79463
  });
78535
79464
 
@@ -78538,7 +79467,7 @@
78538
79467
 
78539
79468
  Checkbox(node_2, {
78540
79469
  compact: true,
78541
- children: ($$anchor, $$slotProps) => {
79470
+ children: wrap_snippet(TextFieldDemo, ($$anchor, $$slotProps) => {
78542
79471
  var label_1 = root_2();
78543
79472
  var input = child(label_1);
78544
79473
 
@@ -78547,7 +79476,7 @@
78547
79476
  reset(label_1);
78548
79477
  bind_checked(input, () => get(multiligne), ($$value) => set(multiligne, $$value));
78549
79478
  append($$anchor, label_1);
78550
- },
79479
+ }),
78551
79480
  $$slots: { default: true }
78552
79481
  });
78553
79482
 
@@ -78557,7 +79486,7 @@
78557
79486
  legend: 'Size',
78558
79487
  selectionButton: true,
78559
79488
  inline: true,
78560
- children: ($$anchor, $$slotProps) => {
79489
+ children: wrap_snippet(TextFieldDemo, ($$anchor, $$slotProps) => {
78561
79490
  var fragment_2 = comment();
78562
79491
  var node_4 = first_child(fragment_2);
78563
79492
 
@@ -78585,6 +79514,7 @@
78585
79514
  [],
78586
79515
  input_1,
78587
79516
  () => {
79517
+ _size;
78588
79518
  return size();
78589
79519
  },
78590
79520
  size
@@ -78594,7 +79524,7 @@
78594
79524
  });
78595
79525
 
78596
79526
  append($$anchor, fragment_2);
78597
- },
79527
+ }),
78598
79528
  $$slots: { default: true }
78599
79529
  });
78600
79530
 
@@ -78602,7 +79532,7 @@
78602
79532
 
78603
79533
  Checkbox(node_5, {
78604
79534
  compact: true,
78605
- children: ($$anchor, $$slotProps) => {
79535
+ children: wrap_snippet(TextFieldDemo, ($$anchor, $$slotProps) => {
78606
79536
  var label_3 = root_5();
78607
79537
  var input_2 = child(label_3);
78608
79538
 
@@ -78611,7 +79541,7 @@
78611
79541
  reset(label_3);
78612
79542
  bind_checked(input_2, required);
78613
79543
  append($$anchor, label_3);
78614
- },
79544
+ }),
78615
79545
  $$slots: { default: true }
78616
79546
  });
78617
79547
 
@@ -78619,7 +79549,7 @@
78619
79549
 
78620
79550
  Checkbox(node_6, {
78621
79551
  compact: true,
78622
- children: ($$anchor, $$slotProps) => {
79552
+ children: wrap_snippet(TextFieldDemo, ($$anchor, $$slotProps) => {
78623
79553
  var label_4 = root_6();
78624
79554
  var input_3 = child(label_4);
78625
79555
 
@@ -78628,7 +79558,7 @@
78628
79558
  reset(label_4);
78629
79559
  bind_checked(input_3, invalid);
78630
79560
  append($$anchor, label_4);
78631
- },
79561
+ }),
78632
79562
  $$slots: { default: true }
78633
79563
  });
78634
79564
 
@@ -78636,13 +79566,13 @@
78636
79566
 
78637
79567
  TextField(node_7, {
78638
79568
  label: 'placeholder',
78639
- children: ($$anchor, $$slotProps) => {
79569
+ children: wrap_snippet(TextFieldDemo, ($$anchor, $$slotProps) => {
78640
79570
  var input_4 = root_7();
78641
79571
 
78642
79572
  remove_input_defaults(input_4);
78643
79573
  bind_value(input_4, placeholder);
78644
79574
  append($$anchor, input_4);
78645
- },
79575
+ }),
78646
79576
  $$slots: { default: true }
78647
79577
  });
78648
79578
 
@@ -78650,13 +79580,13 @@
78650
79580
 
78651
79581
  TextField(node_8, {
78652
79582
  label: 'Libellé du champ',
78653
- children: ($$anchor, $$slotProps) => {
79583
+ children: wrap_snippet(TextFieldDemo, ($$anchor, $$slotProps) => {
78654
79584
  var input_5 = root_8();
78655
79585
 
78656
79586
  remove_input_defaults(input_5);
78657
79587
  bind_value(input_5, label);
78658
79588
  append($$anchor, input_5);
78659
- },
79589
+ }),
78660
79590
  $$slots: { default: true }
78661
79591
  });
78662
79592
 
@@ -78664,13 +79594,13 @@
78664
79594
 
78665
79595
  TextField(node_9, {
78666
79596
  label: 'Message d\'erreur',
78667
- children: ($$anchor, $$slotProps) => {
79597
+ children: wrap_snippet(TextFieldDemo, ($$anchor, $$slotProps) => {
78668
79598
  var input_6 = root_9();
78669
79599
 
78670
79600
  remove_input_defaults(input_6);
78671
79601
  bind_value(input_6, invalidText);
78672
79602
  append($$anchor, input_6);
78673
- },
79603
+ }),
78674
79604
  $$slots: { default: true }
78675
79605
  });
78676
79606
 
@@ -78684,13 +79614,13 @@
78684
79614
  TextField(node_11, {
78685
79615
  label: 'Description',
78686
79616
  size: 'lg',
78687
- children: ($$anchor, $$slotProps) => {
79617
+ children: wrap_snippet(TextFieldDemo, ($$anchor, $$slotProps) => {
78688
79618
  var input_7 = root_11();
78689
79619
 
78690
79620
  remove_input_defaults(input_7);
78691
79621
  bind_value(input_7, description);
78692
79622
  append($$anchor, input_7);
78693
- },
79623
+ }),
78694
79624
  $$slots: { default: true }
78695
79625
  });
78696
79626
 
@@ -78699,13 +79629,13 @@
78699
79629
  TextField(node_12, {
78700
79630
  label: 'Maxlength',
78701
79631
  size: 'xs',
78702
- children: ($$anchor, $$slotProps) => {
79632
+ children: wrap_snippet(TextFieldDemo, ($$anchor, $$slotProps) => {
78703
79633
  var input_8 = root_12();
78704
79634
 
78705
79635
  remove_input_defaults(input_8);
78706
79636
  bind_value(input_8, maxlength);
78707
79637
  append($$anchor, input_8);
78708
- },
79638
+ }),
78709
79639
  $$slots: { default: true }
78710
79640
  });
78711
79641
 
@@ -78806,7 +79736,8 @@
78806
79736
  set invalidAtSubmit($$value = false) {
78807
79737
  invalidAtSubmit($$value);
78808
79738
  flushSync();
78809
- }
79739
+ },
79740
+ ...legacy_api()
78810
79741
  });
78811
79742
  }
78812
79743
 
@@ -78835,7 +79766,7 @@
78835
79766
  ));
78836
79767
 
78837
79768
  if (document.getElementById("version")) {
78838
- document.getElementById("version").textContent = `v1.4.0`;
79769
+ document.getElementById("version").textContent = `v1.4.2`;
78839
79770
  }
78840
79771
 
78841
79772
  // Show maskable "general alert" component