@custardui/custardui 1.0.0 → 2.0.1-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (66) hide show
  1. package/dist/custardui.js +2630 -901
  2. package/dist/custardui.js.map +1 -1
  3. package/dist/custardui.min.js +2 -2
  4. package/dist/custardui.min.js.map +1 -1
  5. package/dist/types/src/lib/app/types.d.ts +36 -0
  6. package/dist/types/src/lib/app/types.d.ts.map +1 -0
  7. package/dist/types/src/lib/app/ui-manager.d.ts +2 -35
  8. package/dist/types/src/lib/app/ui-manager.d.ts.map +1 -1
  9. package/dist/types/src/lib/features/adaptation/adaptation-manager.d.ts +1 -1
  10. package/dist/types/src/lib/features/adaptation/adaptation-manager.d.ts.map +1 -1
  11. package/dist/types/src/lib/features/anchor/descriptor.d.ts +6 -0
  12. package/dist/types/src/lib/features/anchor/descriptor.d.ts.map +1 -0
  13. package/dist/types/src/lib/features/anchor/index.d.ts +5 -0
  14. package/dist/types/src/lib/features/anchor/index.d.ts.map +1 -0
  15. package/dist/types/src/lib/features/anchor/resolver.d.ts +8 -0
  16. package/dist/types/src/lib/features/anchor/resolver.d.ts.map +1 -0
  17. package/dist/types/src/lib/features/anchor/serializer.d.ts +21 -0
  18. package/dist/types/src/lib/features/anchor/serializer.d.ts.map +1 -0
  19. package/dist/types/src/lib/features/anchor/stable-text.d.ts +41 -0
  20. package/dist/types/src/lib/features/anchor/stable-text.d.ts.map +1 -0
  21. package/dist/types/src/lib/features/anchor/types.d.ts +17 -0
  22. package/dist/types/src/lib/features/anchor/types.d.ts.map +1 -0
  23. package/dist/types/src/lib/features/focus/services/focus-service.svelte.d.ts +2 -2
  24. package/dist/types/src/lib/features/focus/services/focus-service.svelte.d.ts.map +1 -1
  25. package/dist/types/src/lib/features/highlight/highlight-logic.d.ts +6 -1
  26. package/dist/types/src/lib/features/highlight/highlight-logic.d.ts.map +1 -1
  27. package/dist/types/src/lib/features/highlight/services/highlight-annotations.d.ts +10 -0
  28. package/dist/types/src/lib/features/highlight/services/highlight-annotations.d.ts.map +1 -0
  29. package/dist/types/src/lib/features/highlight/services/highlight-colors.d.ts +24 -0
  30. package/dist/types/src/lib/features/highlight/services/highlight-colors.d.ts.map +1 -0
  31. package/dist/types/src/lib/features/highlight/services/highlight-service.svelte.d.ts +6 -1
  32. package/dist/types/src/lib/features/highlight/services/highlight-service.svelte.d.ts.map +1 -1
  33. package/dist/types/src/lib/features/highlight/services/highlight-types.d.ts +5 -0
  34. package/dist/types/src/lib/features/highlight/services/highlight-types.d.ts.map +1 -1
  35. package/dist/types/src/lib/features/placeholder/placeholder-binder.d.ts +13 -1
  36. package/dist/types/src/lib/features/placeholder/placeholder-binder.d.ts.map +1 -1
  37. package/dist/types/src/lib/features/placeholder/placeholder-manager.d.ts +6 -0
  38. package/dist/types/src/lib/features/placeholder/placeholder-manager.d.ts.map +1 -1
  39. package/dist/types/src/lib/features/placeholder/types.d.ts +6 -0
  40. package/dist/types/src/lib/features/placeholder/types.d.ts.map +1 -1
  41. package/dist/types/src/lib/features/settings/intro-manager.svelte.d.ts +3 -6
  42. package/dist/types/src/lib/features/settings/intro-manager.svelte.d.ts.map +1 -1
  43. package/dist/types/src/lib/features/settings/stores/icon-settings-store.svelte.d.ts +18 -0
  44. package/dist/types/src/lib/features/settings/stores/icon-settings-store.svelte.d.ts.map +1 -0
  45. package/dist/types/src/lib/features/settings/types.d.ts +1 -1
  46. package/dist/types/src/lib/features/settings/types.d.ts.map +1 -1
  47. package/dist/types/src/lib/features/share/stores/share-store.svelte.d.ts +12 -1
  48. package/dist/types/src/lib/features/share/stores/share-store.svelte.d.ts.map +1 -1
  49. package/dist/types/src/lib/features/url/url-state-manager.d.ts.map +1 -1
  50. package/dist/types/src/lib/runtime.svelte.d.ts +4 -6
  51. package/dist/types/src/lib/runtime.svelte.d.ts.map +1 -1
  52. package/dist/types/src/lib/stores/active-state-store.svelte.d.ts +16 -7
  53. package/dist/types/src/lib/stores/active-state-store.svelte.d.ts.map +1 -1
  54. package/dist/types/src/lib/stores/derived-store.svelte.d.ts +1 -0
  55. package/dist/types/src/lib/stores/derived-store.svelte.d.ts.map +1 -1
  56. package/dist/types/src/lib/utils/scroll-utils.d.ts +41 -15
  57. package/dist/types/src/lib/utils/scroll-utils.d.ts.map +1 -1
  58. package/dist/types/tests/lib/features/anchor/anchor.test.d.ts +2 -0
  59. package/dist/types/tests/lib/features/anchor/anchor.test.d.ts.map +1 -0
  60. package/dist/types/tests/lib/features/settings/stores/icon-settings-store.test.d.ts +2 -0
  61. package/dist/types/tests/lib/features/settings/stores/icon-settings-store.test.d.ts.map +1 -0
  62. package/package.json +2 -2
  63. package/dist/types/src/lib/utils/dom-element-locator.d.ts +0 -30
  64. package/dist/types/src/lib/utils/dom-element-locator.d.ts.map +0 -1
  65. package/dist/types/tests/lib/utils/dom-element-locator.test.d.ts +0 -2
  66. package/dist/types/tests/lib/utils/dom-element-locator.test.d.ts.map +0 -1
@@ -0,0 +1,36 @@
1
+ import type { WidgetSettings, WidgetCalloutConfig, WidgetIconConfig } from '$features/settings/types';
2
+ import type { IconSettingsStore } from '$features/settings/stores/icon-settings-store.svelte';
3
+ import type { PersistenceManager } from '$lib/utils/persistence';
4
+ export declare const RUNTIME_CALLBACKS_CTX: unique symbol;
5
+ /**
6
+ * Callbacks that the UI layer needs from the runtime.
7
+ * This keeps the UI decoupled from the AppRuntime class.
8
+ */
9
+ export interface RuntimeCallbacks {
10
+ resetToDefault: () => void;
11
+ iconSettings: IconSettingsStore;
12
+ persistenceManager: PersistenceManager;
13
+ }
14
+ export interface UIManagerOptions extends Omit<WidgetSettings, 'enabled'> {
15
+ /** Callbacks from the runtime for persistence and reset */
16
+ callbacks: RuntimeCallbacks;
17
+ /** Container element where the settings widget should be rendered */
18
+ container?: HTMLElement;
19
+ /** Whether the settings feature (icon/modal) is enabled */
20
+ settingsEnabled?: boolean;
21
+ }
22
+ export type ResolvedUIManagerOptions = Omit<UIManagerOptions, 'container' | 'panel' | 'callout' | 'icon'> & {
23
+ container: HTMLElement;
24
+ settingsEnabled: boolean;
25
+ theme: 'light' | 'dark';
26
+ callout: Required<Pick<WidgetCalloutConfig, 'show' | 'message' | 'enablePulse'>> & {
27
+ backgroundColor?: string | undefined;
28
+ textColor?: string | undefined;
29
+ };
30
+ icon: Required<Pick<WidgetIconConfig, 'position' | 'scale' | 'show'>> & {
31
+ color?: string | undefined;
32
+ backgroundColor?: string | undefined;
33
+ opacity?: number | undefined;
34
+ };
35
+ };
36
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../src/lib/app/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,mBAAmB,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AACtG,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,sDAAsD,CAAC;AAC9F,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAC;AAEjE,eAAO,MAAM,qBAAqB,eAAiC,CAAC;AAEpE;;;GAGG;AACH,MAAM,WAAW,gBAAgB;IAC/B,cAAc,EAAE,MAAM,IAAI,CAAC;IAC3B,YAAY,EAAE,iBAAiB,CAAC;IAChC,kBAAkB,EAAE,kBAAkB,CAAC;CACxC;AAED,MAAM,WAAW,gBAAiB,SAAQ,IAAI,CAAC,cAAc,EAAE,SAAS,CAAC;IACvE,2DAA2D;IAC3D,SAAS,EAAE,gBAAgB,CAAC;IAE5B,qEAAqE;IACrE,SAAS,CAAC,EAAE,WAAW,CAAC;IAExB,2DAA2D;IAC3D,eAAe,CAAC,EAAE,OAAO,CAAC;CAC3B;AAED,MAAM,MAAM,wBAAwB,GAAG,IAAI,CACzC,gBAAgB,EAChB,WAAW,GAAG,OAAO,GAAG,SAAS,GAAG,MAAM,CAC3C,GAAG;IACF,SAAS,EAAE,WAAW,CAAC;IACvB,eAAe,EAAE,OAAO,CAAC;IACzB,KAAK,EAAE,OAAO,GAAG,MAAM,CAAC;IACxB,OAAO,EAAE,QAAQ,CAAC,IAAI,CAAC,mBAAmB,EAAE,MAAM,GAAG,SAAS,GAAG,aAAa,CAAC,CAAC,GAAG;QACjF,eAAe,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;QACrC,SAAS,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;KAChC,CAAC;IACF,IAAI,EAAE,QAAQ,CAAC,IAAI,CAAC,gBAAgB,EAAE,UAAU,GAAG,OAAO,GAAG,MAAM,CAAC,CAAC,GAAG;QACtE,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;QAC3B,eAAe,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;QACrC,OAAO,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;KAC9B,CAAC;CACH,CAAC"}
@@ -1,40 +1,7 @@
1
1
  import type { AppRuntime } from '../runtime.svelte';
2
2
  import type { ConfigFile } from '$lib/types/index';
3
- import type { WidgetSettings, WidgetCalloutConfig, WidgetIconConfig } from '$features/settings/types';
4
- /**
5
- * Callbacks that the UI layer needs from the runtime.
6
- * This keeps the UI decoupled from the AppRuntime class.
7
- */
8
- export interface RuntimeCallbacks {
9
- resetToDefault: () => void;
10
- getIconPosition: () => number | null;
11
- saveIconPosition: (offset: number) => void;
12
- clearIconPosition: () => void;
13
- isIntroSeen: () => boolean;
14
- markIntroSeen: () => void;
15
- }
16
- export interface UIManagerOptions extends Omit<WidgetSettings, 'enabled'> {
17
- /** Callbacks from the runtime for persistence and reset */
18
- callbacks: RuntimeCallbacks;
19
- /** Container element where the settings widget should be rendered */
20
- container?: HTMLElement;
21
- /** Whether the settings feature (icon/modal) is enabled */
22
- settingsEnabled?: boolean;
23
- }
24
- export type ResolvedUIManagerOptions = Omit<UIManagerOptions, 'container' | 'panel' | 'callout' | 'icon'> & {
25
- container: HTMLElement;
26
- settingsEnabled: boolean;
27
- theme: 'light' | 'dark';
28
- callout: Required<Pick<WidgetCalloutConfig, 'show' | 'message' | 'enablePulse'>> & {
29
- backgroundColor?: string | undefined;
30
- textColor?: string | undefined;
31
- };
32
- icon: Required<Pick<WidgetIconConfig, 'position' | 'scale' | 'show'>> & {
33
- color?: string | undefined;
34
- backgroundColor?: string | undefined;
35
- opacity?: number | undefined;
36
- };
37
- };
3
+ import { type UIManagerOptions } from './types';
4
+ export * from './types';
38
5
  export declare class CustardUIManager {
39
6
  private app;
40
7
  private options;
@@ -1 +1 @@
1
- {"version":3,"file":"ui-manager.d.ts","sourceRoot":"","sources":["../../../../../src/lib/app/ui-manager.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAInD,OAAO,KAAK,EAAE,cAAc,EAAE,mBAAmB,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAEtG;;;GAGG;AACH,MAAM,WAAW,gBAAgB;IAC/B,cAAc,EAAE,MAAM,IAAI,CAAC;IAC3B,eAAe,EAAE,MAAM,MAAM,GAAG,IAAI,CAAC;IACrC,gBAAgB,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;IAC3C,iBAAiB,EAAE,MAAM,IAAI,CAAC;IAC9B,WAAW,EAAE,MAAM,OAAO,CAAC;IAC3B,aAAa,EAAE,MAAM,IAAI,CAAC;CAC3B;AAED,MAAM,WAAW,gBAAiB,SAAQ,IAAI,CAAC,cAAc,EAAE,SAAS,CAAC;IACvE,2DAA2D;IAC3D,SAAS,EAAE,gBAAgB,CAAC;IAE5B,qEAAqE;IACrE,SAAS,CAAC,EAAE,WAAW,CAAC;IAExB,2DAA2D;IAC3D,eAAe,CAAC,EAAE,OAAO,CAAC;CAC3B;AAED,MAAM,MAAM,wBAAwB,GAAG,IAAI,CACzC,gBAAgB,EAChB,WAAW,GAAG,OAAO,GAAG,SAAS,GAAG,M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AAO,CAAC,GAAG,CAAyC;IACpD,OAAO,CAAC,OAAO,CAA2B;gBAE9B,OAAO,EAAE,gBAAgB;IAyBrC;;OAEG;IACI,MAAM,IAAI,IAAI;IAoBrB;;OAEG;IACI,OAAO,IAAI,IAAI;CAMvB;AAED;;GAEG;AACH,wBAAgB,aAAa,CAC3B,OAAO,EAAE,UAAU,EACnB,MAAM,EAAE,UAAU,GACjB,gBAAgB,GAAG,SAAS,CAgB9B"}
@@ -14,7 +14,7 @@ export declare class AdaptationManager {
14
14
  *
15
15
  * Adaptation JSON files are resolved relative to the site's baseUrl:
16
16
  * `{baseUrl}/{id}/{id}.json`
17
- * e.g. baseUrl="/customviews", id="ntu" → "/customviews/ntu/ntu.json"
17
+ * e.g. baseUrl="/base", id="nus" → "/base/nus/nus.json"
18
18
  *
19
19
  * @param baseUrl The site's base URL (from data-base-url, default: '')
20
20
  * @param storageKey The project's unique storageKey prefix to use for saving preferences
@@ -1 +1 @@
1
- {"version":3,"file":"adaptation-manager.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/features/adaptation/adaptation-manager.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAKhD;;;GAGG;AACH,qBAAa,iBAAiB;IAC5B,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,WAAW,CAAW;IAC9C,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,WAAW,CAAQ;IAE3C;;;;;;;;;;;;;OAaG;WACU,IAAI,CAAC,OAAO,SAAK,EAAE,UAAU,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,gBAAgB,GAAG,IAAI,CAAC;IA2DtF;;;;;;;;;;;OAWG;IACH,MAAM,CAAC,mBAAmB,CAAC,YAAY,EAAE,MAAM,GAAG,IAAI;IAiBtD;;;OAGG;IACH,OAAO,CAAC,MAAM,CAAC,UAAU;IA0BzB,OAAO,CAAC,MAAM,CAAC,aAAa;IAI5B,OAAO,CAAC,MAAM,CAAC,mBAAmB;IAIlC,OAAO,CAAC,MAAM,CAAC,mBAAmB;IAUlC,OAAO,CAAC,MAAM,CAAC,mBAAmB;IAIlC;;OAEG;IACH,OAAO,CAAC,MAAM,CAAC,mBAAmB;IAIlC,OAAO,CAAC,MAAM,CAAC,sBAAsB;IAKrC,OAAO,CAAC,MAAM,CAAC,gBAAgB;mBAKV,oBAAoB;CA4C1C"}
1
+ {"version":3,"file":"adaptation-manager.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/features/adaptation/adaptation-manager.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAKhD;;;GAGG;AACH,qBAAa,iBAAiB;IAC5B,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,WAAW,CAAW;IAC9C,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,WAAW,CAAQ;IAE3C;;;;;;;;;;;;;OAaG;WACU,IAAI,CAAC,OAAO,SAAK,EAAE,UAAU,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,gBAAgB,GAAG,IAAI,CAAC;IAiEtF;;;;;;;;;;;OAWG;IACH,MAAM,CAAC,mBAAmB,CAAC,YAAY,EAAE,MAAM,GAAG,IAAI;IAqBtD;;;OAGG;IACH,OAAO,CAAC,MAAM,CAAC,UAAU;IA0BzB,OAAO,CAAC,MAAM,CAAC,aAAa;IAI5B,OAAO,CAAC,MAAM,CAAC,mBAAmB;IAIlC,OAAO,CAAC,MAAM,CAAC,mBAAmB;IAUlC,OAAO,CAAC,MAAM,CAAC,mBAAmB;IAIlC;;OAEG;IACH,OAAO,CAAC,MAAM,CAAC,mBAAmB;IAIlC,OAAO,CAAC,MAAM,CAAC,sBAAsB;IAKrC,OAAO,CAAC,MAAM,CAAC,gBAAgB;mBAKV,oBAAoB;CA4C1C"}
@@ -0,0 +1,6 @@
1
+ import { type AnchorDescriptor } from './types';
2
+ /**
3
+ * Creates an AnchorDescriptor for a given DOM element.
4
+ */
5
+ export declare function createDescriptor(el: HTMLElement): AnchorDescriptor;
6
+ //# sourceMappingURL=descriptor.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"descriptor.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/features/anchor/descriptor.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAGhD;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,EAAE,EAAE,WAAW,GAAG,gBAAgB,CAiClE"}
@@ -0,0 +1,5 @@
1
+ export type { AnchorDescriptor } from './types';
2
+ export { createDescriptor } from './descriptor';
3
+ export { serialize, deserialize } from './serializer';
4
+ export { resolve } from './resolver';
5
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/features/anchor/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAChD,OAAO,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAChD,OAAO,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AACtD,OAAO,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC"}
@@ -0,0 +1,8 @@
1
+ import { type AnchorDescriptor } from './types';
2
+ /**
3
+ * Finds the best DOM element match(es) for a descriptor.
4
+ * Returns an array of elements. For specific descriptors, usually contains 0 or 1 element.
5
+ * For ID-only descriptors (tag='ANY'), may return multiple if duplicates exist.
6
+ */
7
+ export declare function resolve(root: HTMLElement, descriptor: AnchorDescriptor): HTMLElement[];
8
+ //# sourceMappingURL=resolver.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"resolver.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/features/anchor/resolver.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAShD;;;;GAIG;AACH,wBAAgB,OAAO,CAAC,IAAI,EAAE,WAAW,EAAE,UAAU,EAAE,gBAAgB,GAAG,WAAW,EAAE,CAoFtF"}
@@ -0,0 +1,21 @@
1
+ import { type AnchorDescriptor } from './types';
2
+ /**
3
+ * Serializes a list of AnchorDescriptors into a URL-safe string.
4
+ */
5
+ export declare function serialize(descriptors: AnchorDescriptor[]): string;
6
+ /**
7
+ * Deserializes a URL-safe string back into a list of AnchorDescriptors.
8
+ */
9
+ export declare function deserialize(encoded: string): AnchorDescriptor[];
10
+ /**
11
+ * Parses a space-separated, plus-separated, or comma-separated list of IDs into a list of AnchorDescriptors.
12
+ * Supports:
13
+ * "id" — ID only
14
+ * "id:color" — with color
15
+ * "id:color:corner" — color + corner, no note
16
+ * "id::corner" — corner only, no color, no note
17
+ * "id:color:corner:note" — with color + annotation (note is percent-encoded)
18
+ * "id::corner:note" — annotation, no color
19
+ */
20
+ export declare function parseIds(encoded: string): AnchorDescriptor[];
21
+ //# sourceMappingURL=serializer.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"serializer.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/features/anchor/serializer.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAKhD;;GAEG;AACH,wBAAgB,SAAS,CAAC,WAAW,EAAE,gBAAgB,EAAE,GAAG,MAAM,CAoDjE;AAED;;GAEG;AACH,wBAAgB,WAAW,CAAC,OAAO,EAAE,MAAM,GAAG,gBAAgB,EAAE,CAqD/D;AAED;;;;;;;;;GASG;AACH,wBAAgB,QAAQ,CAAC,OAAO,EAAE,MAAM,GAAG,gBAAgB,EAAE,CAsD5D"}
@@ -0,0 +1,41 @@
1
+ /**
2
+ * Generates a simple hash code for a string.
3
+ */
4
+ export declare function hashCode(str: string): number;
5
+ /**
6
+ * Matches raw (un-hydrated) placeholder tokens in text content, including
7
+ * escaped forms like \[[ name ]]:
8
+ * [[ name ]], [[ name : fallback ]], [[ name ? truthy : falsy ]], \[[ name ]]
9
+ * Captures the placeholder name in group 1. Used to normalize tokens before hashing.
10
+ *
11
+ * The optional `(?:\\)?` prefix intentionally consumes the leading backslash so that
12
+ * \[[ name ]] normalizes to [[name]] — the same canonical form that PlaceholderBinder
13
+ * emits for escaped tokens ([[ name ]] literal text). This keeps the hash stable
14
+ * across raw and hydrated DOM states.
15
+ */
16
+ export declare const RAW_PLACEHOLDER_RE: RegExp;
17
+ /**
18
+ * Recursively walks `node`, appending stable placeholder-canonical text to `parts`.
19
+ * - Text nodes: raw [[ ... ]] tokens are normalized to [[name]] before appending.
20
+ * - <cv-placeholder> elements: appends [[name]] from the `name` attribute; skips children
21
+ * (children hold the live resolved value, not the canonical template form).
22
+ * - All other elements: recurse into children.
23
+ */
24
+ export declare function collectStableText(node: Node, parts: string[]): void;
25
+ /**
26
+ * Returns the text content of an element with all <cv-placeholder> custom elements
27
+ * replaced by their canonical [[name]] template form.
28
+ *
29
+ * This produces a stable string regardless of the placeholder's current resolved value
30
+ * or whether it has been hydrated yet — enabling consistent hashing across share and load time.
31
+ *
32
+ * Without this, an element containing [[username]] resolved to "alice" would hash as
33
+ * "Hello alice!" at share-time but "Hello [[username]]!" at load-time, causing resolution to fail.
34
+ */
35
+ export declare function getStableTextContent(el: HTMLElement): string;
36
+ /**
37
+ * Combines getStableTextContent and normalizeText into a single call.
38
+ * Used wherever element text is computed for hashing or comparison.
39
+ */
40
+ export declare function getStableNormalizedText(el: HTMLElement): string;
41
+ //# sourceMappingURL=stable-text.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"stable-text.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/features/anchor/stable-text.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,wBAAgB,QAAQ,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAS5C;AAED;;;;;;;;;;GAUG;AACH,eAAO,MAAM,kBAAkB,QAA8C,CAAC;AAE9E;;;;;;GAMG;AACH,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,EAAE,GAAG,IAAI,CAcnE;AAED;;;;;;;;;GASG;AACH,wBAAgB,oBAAoB,CAAC,EAAE,EAAE,WAAW,GAAG,MAAM,CAsB5D;AAED;;;GAGG;AACH,wBAAgB,uBAAuB,CAAC,EAAE,EAAE,WAAW,GAAG,MAAM,CAE/D"}
@@ -0,0 +1,17 @@
1
+ import { type HighlightColorKey } from '$features/highlight/services/highlight-colors';
2
+ import { type AnnotationCorner } from '$features/highlight/services/highlight-annotations';
3
+ /**
4
+ * Descriptor for an anchor that represents a DOM element.
5
+ */
6
+ export interface AnchorDescriptor {
7
+ tag: string;
8
+ index: number;
9
+ parentId?: string;
10
+ textSnippet: string;
11
+ textHash: number;
12
+ elementId?: string;
13
+ color?: HighlightColorKey;
14
+ annotation?: string;
15
+ annotationCorner?: AnnotationCorner;
16
+ }
17
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/features/anchor/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,iBAAiB,EAAE,MAAM,+CAA+C,CAAC;AACvF,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,oDAAoD,CAAC;AAE3F;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,iBAAiB,CAAC;IAC1B,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,gBAAgB,CAAC,EAAE,gBAAgB,CAAC;CACrC"}
@@ -23,8 +23,8 @@ export declare class FocusService {
23
23
  * Applies focus mode to the specified descriptors.
24
24
  * @param encodedDescriptors - The encoded descriptors to apply.
25
25
  */
26
- applyShowMode(encodedDescriptors: string): void;
27
- applyHideMode(encodedDescriptors: string): void;
26
+ applyShowMode(encodedDescriptors: string, keepTargets?: HTMLElement[]): void;
27
+ applyHideMode(encodedDescriptors: string, excludeTargets?: HTMLElement[]): void;
28
28
  applyHighlightMode(encodedDescriptors: string): void;
29
29
  private renderHiddenView;
30
30
  private renderShowView;
@@ -1 +1 @@
1
- {"version":3,"file":"focus-service.svelte.d.ts","sourceRoot":"","sources":["../../../../../../../src/lib/features/focus/services/focus-service.svelte.ts"],"names":[],"mappings":"AAsBA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAE7D,MAAM,WAAW,mBAAmB;IAClC,eAAe,CAAC,EAAE,eAAe,CAAC;CACnC;AAED,qBAAa,YAAY;IAUrB,OAAO,CAAC,MAAM;IAThB,OAAO,CAAC,cAAc,CAAgC;IACtD,OAAO,CAAC,QAAQ,CAAwB;IACxC,OAAO,CAAC,YAAY,CAAc;IAClC,OAAO,CAAC,WAAW,CAAc;IAEjC,OAAO,CAAC,WAAW,CAAa;IAChC,OAAO,CAAC,gBAAgB,CAAmB;gBAGjC,MAAM,EAAE,WAAW,EAC3B,OAAO,EAAE,mBAAmB;IAiC9B;;OAEG;IACH,OAAO,CAAC,cAAc,CAEpB;IAEF;;OAEG;IACH,OAAO,CAAC,iBAAiB;IAuBzB;;;OAGG;IACI,aAAa,CAAC,kBAAkB,EAAE,MAAM,GAAG,IAAI;IAwC/C,aAAa,CAAC,kBAAkB,EAAE,MAAM,GAAG,IAAI;IAoC/C,kBAAkB,CAAC,kBAAkB,EAAE,MAAM,GAAG,IAAI;IAU3D,OAAO,CAAC,gBAAgB;IAkBxB,OAAO,CAAC,cAAc;IA0CtB,OAAO,CAAC,0BAA0B;IAYlC,OAAO,CAAC,aAAa;IAkBrB,OAAO,CAAC,aAAa;IAwBd,YAAY,CAAC,SAAS,UAAO,GAAG,IAAI;IA6CpC,OAAO;CAKf"}
1
+ {"version":3,"file":"focus-service.svelte.d.ts","sourceRoot":"","sources":["../../../../../../../src/lib/features/focus/services/focus-service.svelte.ts"],"names":[],"mappings":"AAsBA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAE7D,MAAM,WAAW,mBAAmB;IAClC,eAAe,CAAC,EAAE,eAAe,CAAC;CACnC;AAED,qBAAa,YAAY;IAUrB,OAAO,CAAC,MAAM;IAThB,OAAO,CAAC,cAAc,CAAgC;IACtD,OAAO,CAAC,QAAQ,CAAwB;IACxC,OAAO,CAAC,YAAY,CAAc;IAClC,OAAO,CAAC,WAAW,CAAc;IAEjC,OAAO,CAAC,WAAW,CAAa;IAChC,OAAO,CAAC,gBAAgB,CAAmB;gBAGjC,MAAM,EAAE,WAAW,EAC3B,OAAO,EAAE,mBAAmB;IAiC9B;;OAEG;IACH,OAAO,CAAC,cAAc,CAEpB;IAEF;;OAEG;IACH,OAAO,CAAC,iBAAiB;IAgDzB;;;OAGG;IACI,aAAa,CAAC,kBAAkB,EAAE,MAAM,EAAE,WAAW,GAAE,WAAW,EAAO,GAAG,IAAI;IAyChF,aAAa,CAAC,kBAAkB,EAAE,MAAM,EAAE,cAAc,GAAE,WAAW,EAAO,GAAG,IAAI;IA0CnF,kBAAkB,CAAC,kBAAkB,EAAE,MAAM,GAAG,IAAI;IAU3D,OAAO,CAAC,gBAAgB;IAkBxB,OAAO,CAAC,cAAc;IA0CtB,OAAO,CAAC,0BAA0B;IAYlC,OAAO,CAAC,aAAa;IAkBrB,OAAO,CAAC,aAAa;IAwBd,YAAY,CAAC,SAAS,UAAO,GAAG,IAAI;IA6CpC,OAAO;CAKf"}
@@ -1,5 +1,7 @@
1
1
  import { SvelteMap } from 'svelte/reactivity';
2
2
  import { type RectData } from './services/highlight-types';
3
+ import { type HighlightColorKey } from './services/highlight-colors';
4
+ import { type AnnotationCorner } from './services/highlight-annotations';
3
5
  /**
4
6
  * Groups elements by their parent.
5
7
  * Returns a Map where keys are parent elements and values are lists of child elements.
@@ -25,5 +27,8 @@ export interface SimpleRect {
25
27
  export declare function calculateMergedRects(groups: SvelteMap<HTMLElement, HTMLElement[]>, getRect: (el: HTMLElement) => SimpleRect, getScroll: () => {
26
28
  scrollTop: number;
27
29
  scrollLeft: number;
28
- }): RectData[];
30
+ }, colorMap?: Map<HTMLElement, HighlightColorKey>, annotationMap?: Map<HTMLElement, {
31
+ text: string;
32
+ corner: AnnotationCorner;
33
+ }>): RectData[];
29
34
  //# sourceMappingURL=highlight-logic.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"highlight-logic.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/features/highlight/highlight-logic.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAa,MAAM,mBAAmB,CAAC;AACzD,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,4BAA4B,CAAC;AAE3D;;;GAGG;AACH,wBAAgB,aAAa,CAAC,QAAQ,EAAE,WAAW,EAAE,GAAG,SAAS,CAAC,WAAW,EAAE,WAAW,EAAE,CAAC,CAY5F;AAED;;GAEG;AACH,MAAM,WAAW,UAAU;IACzB,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;CAChB;AAED;;;;;;;GAOG;AACH,wBAAgB,oBAAoB,CAClC,MAAM,EAAE,SAAS,CAAC,WAAW,EAAE,WAAW,EAAE,CAAC,EAC7C,OAAO,EAAE,CAAC,EAAE,EAAE,WAAW,KAAK,UAAU,EACxC,SAAS,EAAE,MAAM;IAAE,SAAS,EAAE,MAAM,CAAC;IAAC,UAAU,EAAE,MAAM,CAAA;CAAE,GACzD,QAAQ,EAAE,CAwCZ"}
1
+ {"version":3,"file":"highlight-logic.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/features/highlight/highlight-logic.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAa,MAAM,mBAAmB,CAAC;AACzD,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,4BAA4B,CAAC;AAC3D,OAAO,EAAE,KAAK,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AACrE,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AAEzE;;;GAGG;AACH,wBAAgB,aAAa,CAAC,QAAQ,EAAE,WAAW,EAAE,GAAG,SAAS,CAAC,WAAW,EAAE,WAAW,EAAE,CAAC,CAY5F;AAED;;GAEG;AACH,MAAM,WAAW,UAAU;IACzB,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;CAChB;AAED;;;;;;;GAOG;AACH,wBAAgB,oBAAoB,CAClC,MAAM,EAAE,SAAS,CAAC,WAAW,EAAE,WAAW,EAAE,CAAC,EAC7C,OAAO,EAAE,CAAC,EAAE,EAAE,WAAW,KAAK,UAAU,EACxC,SAAS,EAAE,MAAM;IAAE,SAAS,EAAE,MAAM,CAAC;IAAC,UAAU,EAAE,MAAM,CAAA;CAAE,EAC1D,QAAQ,CAAC,EAAE,GAAG,CAAC,WAAW,EAAE,iBAAiB,CAAC,EAC9C,aAAa,CAAC,EAAE,GAAG,CAAC,WAAW,EAAE;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,gBAAgB,CAAA;CAAE,CAAC,GAC3E,QAAQ,EAAE,CAgDZ"}
@@ -0,0 +1,10 @@
1
+ export type AnnotationCorner = 'tl' | 'tr' | 'bl' | 'br';
2
+ export declare const ANNOTATION_CORNERS: AnnotationCorner[];
3
+ export declare const CORNER_ICONS: {
4
+ key: AnnotationCorner;
5
+ icon: string;
6
+ }[];
7
+ export declare const DEFAULT_ANNOTATION_CORNER: AnnotationCorner;
8
+ export declare const MAX_ANNOTATION_LENGTH = 280;
9
+ export declare const ANNOTATION_PREVIEW_LENGTH = 40;
10
+ //# sourceMappingURL=highlight-annotations.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"highlight-annotations.d.ts","sourceRoot":"","sources":["../../../../../../../src/lib/features/highlight/services/highlight-annotations.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,gBAAgB,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;AACzD,eAAO,MAAM,kBAAkB,EAAE,gBAAgB,EAA6B,CAAC;AAC/E,eAAO,MAAM,YAAY,EAAE;IAAE,GAAG,EAAE,gBAAgB,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,EAKjE,CAAC;AACF,eAAO,MAAM,yBAAyB,EAAE,gBAAuB,CAAC;AAChE,eAAO,MAAM,qBAAqB,MAAM,CAAC;AACzC,eAAO,MAAM,yBAAyB,KAAK,CAAC"}
@@ -0,0 +1,24 @@
1
+ export declare const HIGHLIGHT_COLORS: readonly [{
2
+ readonly key: "yellow";
3
+ readonly label: "Yellow";
4
+ readonly hex: "#f5f521";
5
+ }, {
6
+ readonly key: "blue";
7
+ readonly label: "Blue";
8
+ readonly hex: "#3b82f6";
9
+ }, {
10
+ readonly key: "red";
11
+ readonly label: "Red";
12
+ readonly hex: "#ef4444";
13
+ }, {
14
+ readonly key: "black";
15
+ readonly label: "Black";
16
+ readonly hex: "#1a1a1a";
17
+ }, {
18
+ readonly key: "green";
19
+ readonly label: "Green";
20
+ readonly hex: "#22c55e";
21
+ }];
22
+ export type HighlightColorKey = 'yellow' | 'blue' | 'red' | 'black' | 'green';
23
+ export declare const DEFAULT_COLOR_KEY: HighlightColorKey;
24
+ //# sourceMappingURL=highlight-colors.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"highlight-colors.d.ts","sourceRoot":"","sources":["../../../../../../../src/lib/features/highlight/services/highlight-colors.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;EAMnB,CAAC;AAEX,MAAM,MAAM,iBAAiB,GAAG,QAAQ,GAAG,MAAM,GAAG,KAAK,GAAG,OAAO,GAAG,OAAO,CAAC;AAC9E,eAAO,MAAM,iBAAiB,EAAE,iBAAyB,CAAC"}
@@ -10,11 +10,16 @@ export declare class HighlightService {
10
10
  private state;
11
11
  private resizeObserver;
12
12
  private activeTargets;
13
+ private activeColors;
14
+ private activeAnnotations;
13
15
  private onWindowResize;
14
16
  constructor(rootEl: HTMLElement);
15
- apply(encodedDescriptors: string): void;
17
+ resolveTargets(encodedDescriptors: string): HTMLElement[];
18
+ applyEncodedHighlights(encodedDescriptors: string): void;
16
19
  exit(): void;
17
20
  private renderHighlightOverlay;
21
+ private scrollToTarget;
22
+ private scrollToTargetSafely;
18
23
  private updatePositions;
19
24
  }
20
25
  //# sourceMappingURL=highlight-service.svelte.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"highlight-service.svelte.d.ts","sourceRoot":"","sources":["../../../../../../../src/lib/features/highlight/services/highlight-service.svelte.ts"],"names":[],"mappings":"AASA,eAAO,MAAM,eAAe,iBAAiB,CAAC;AAE9C,eAAO,MAAM,oBAAoB,sBAAsB,CAAC;AAGxD,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAElD,qBAAa,cAAc;IACzB,KAAK,aAA0B;CAChC;AAED,qBAAa,gBAAgB;IAOf,OAAO,CAAC,MAAM;IAN1B,OAAO,CAAC,UAAU,CAAM;IACxB,OAAO,CAAC,KAAK,CAAwB;IACrC,OAAO,CAAC,cAAc,CAAiB;IACvC,OAAO,CAAC,aAAa,CAAqB;IAC1C,OAAO,CAAC,cAAc,CAAgC;gBAElC,MAAM,EAAE,WAAW;IAMhC,KAAK,CAAC,kBAAkB,EAAE,MAAM,GAAG,IAAI;IAgDvC,IAAI,IAAI,IAAI;IAgBnB,OAAO,CAAC,sBAAsB;IAwB9B,OAAO,CAAC,eAAe;CAmBxB"}
1
+ {"version":3,"file":"highlight-service.svelte.d.ts","sourceRoot":"","sources":["../../../../../../../src/lib/features/highlight/services/highlight-service.svelte.ts"],"names":[],"mappings":"AAUA,eAAO,MAAM,eAAe,iBAAiB,CAAC;AAE9C,eAAO,MAAM,oBAAoB,sBAAsB,CAAC;AAGxD,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAIlD,qBAAa,cAAc;IACzB,KAAK,aAA0B;CAChC;AAED,qBAAa,gBAAgB;IASf,OAAO,CAAC,MAAM;IAR1B,OAAO,CAAC,UAAU,CAAM;IACxB,OAAO,CAAC,KAAK,CAAwB;IACrC,OAAO,CAAC,cAAc,CAAiB;IACvC,OAAO,CAAC,aAAa,CAAqB;IAC1C,OAAO,CAAC,YAAY,CAAkD;IACtE,OAAO,CAAC,iBAAiB,CAA2E;IACpG,OAAO,CAAC,cAAc,CAAgC;gBAElC,MAAM,EAAE,WAAW;IAMhC,cAAc,CAAC,kBAAkB,EAAE,MAAM,GAAG,WAAW,EAAE;IAWzD,sBAAsB,CAAC,kBAAkB,EAAE,MAAM,GAAG,IAAI;IA0DxD,IAAI,IAAI,IAAI;IAkBnB,OAAO,CAAC,sBAAsB;YAwBhB,cAAc;IAiC5B,OAAO,CAAC,oBAAoB;IAM5B,OAAO,CAAC,eAAe;CAqBxB"}
@@ -1,3 +1,5 @@
1
+ import { type HighlightColorKey } from './highlight-colors';
2
+ import { type AnnotationCorner } from './highlight-annotations';
1
3
  export type RectData = {
2
4
  top: number;
3
5
  left: number;
@@ -6,5 +8,8 @@ export type RectData = {
6
8
  right: number;
7
9
  bottom: number;
8
10
  element: HTMLElement;
11
+ color?: HighlightColorKey;
12
+ annotation?: string;
13
+ annotationCorner?: AnnotationCorner;
9
14
  };
10
15
  //# sourceMappingURL=highlight-types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"highlight-types.d.ts","sourceRoot":"","sources":["../../../../../../../src/lib/features/highlight/services/highlight-types.ts"],"names":[],"mappings":"AACA,MAAM,MAAM,QAAQ,GAAG;IACrB,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,WAAW,CAAC;CACtB,CAAC"}
1
+ {"version":3,"file":"highlight-types.d.ts","sourceRoot":"","sources":["../../../../../../../src/lib/features/highlight/services/highlight-types.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,iBAAiB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAEhE,MAAM,MAAM,QAAQ,GAAG;IACrB,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,WAAW,CAAC;IACrB,KAAK,CAAC,EAAE,iBAAiB,CAAC;IAC1B,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,gBAAgB,CAAC,EAAE,gBAAgB,CAAC;CACrC,CAAC"}
@@ -31,6 +31,18 @@ export declare class PlaceholderBinder {
31
31
  * Checks if a value is a relative URL path (e.g., /, ./, ../)
32
32
  */
33
33
  private static isRelativeUrl;
34
+ /**
35
+ * Resolves value for a placeholder using only user-set values (no registry defaults).
36
+ * Returns undefined if the user has not explicitly set a non-empty value.
37
+ *
38
+ * Used by conditional syntax `[[name ? truthy : falsy]]` (without `*`) and
39
+ * `<cv-toggle placeholder-id="name">` (without `*`).
40
+ *
41
+ * @param name - The placeholder name to resolve
42
+ * @param values - Record of user-set placeholder values
43
+ * @returns The user-set value, or undefined if not set
44
+ */
45
+ static resolveUserValue(name: string, values: Record<string, string>): string | undefined;
34
46
  /**
35
47
  * Resolves value for a placeholder by checking and using sources in order of:
36
48
  * 1. user-set value, 2. registry default value, 3. inline fallback value
@@ -42,7 +54,7 @@ export declare class PlaceholderBinder {
42
54
  * @param values - Record of user-set placeholder values
43
55
  * @returns The resolved value, or undefined if no value is available from any source
44
56
  */
45
- private static resolveValue;
57
+ static resolveValue(name: string, fallback: string | undefined, values: Record<string, string>): string | undefined;
46
58
  /**
47
59
  * Interpolates placeholder patterns in a template string with their resolved values.
48
60
  *
@@ -1 +1 @@
1
- {"version":3,"file":"placeholder-binder.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/features/placeholder/placeholder-binder.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAMH,eAAO,MAAM,SAAS,QAA0D,CAAC;AAOjF,qBAAa,iBAAiB;IAC5B;;;OAGG;IACH,MAAM,CAAC,cAAc,CAAC,IAAI,EAAE,WAAW;IAKvC;;;;OAIG;IACH,MAAM,CAAC,SAAS,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC;IAQ/C,OAAO,CAAC,MAAM,CAAC,aAAa;IA4B5B,OAAO,CAAC,MAAM,CAAC,qBAAqB;IAUpC,OAAO,CAAC,MAAM,CAAC,eAAe;IAiD9B,OAAO,CAAC,MAAM,CAAC,wBAAwB;IA2CvC,OAAO,CAAC,MAAM,CAAC,uBAAuB;IAqBtC;;;OAGG;IACH,OAAO,CAAC,MAAM,CAAC,SAAS;IAMxB;;OAEG;IACH,OAAO,CAAC,MAAM,CAAC,aAAa;IAI5B;;;;;;;;;;OAUG;IACH,OAAO,CAAC,MAAM,CAAC,YAAY;IAqB3B;;;;;;;;;;;;;;;OAeG;IACH,OAAO,CAAC,MAAM,CAAC,iBAAiB;CAsBjC"}
1
+ {"version":3,"file":"placeholder-binder.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/features/placeholder/placeholder-binder.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AASH,eAAO,MAAM,SAAS,QAAsF,CAAC;AAO7G,qBAAa,iBAAiB;IAC5B;;;OAGG;IACH,MAAM,CAAC,cAAc,CAAC,IAAI,EAAE,WAAW;IAKvC;;;;OAIG;IACH,MAAM,CAAC,SAAS,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC;IAQ/C,OAAO,CAAC,MAAM,CAAC,aAAa;IA4B5B,OAAO,CAAC,MAAM,CAAC,qBAAqB;IAUpC,OAAO,CAAC,MAAM,CAAC,eAAe;IAuD9B,OAAO,CAAC,MAAM,CAAC,wBAAwB;IA2CvC,OAAO,CAAC,MAAM,CAAC,uBAAuB;IAqBtC;;;OAGG;IACH,OAAO,CAAC,MAAM,CAAC,SAAS;IAMxB;;OAEG;IACH,OAAO,CAAC,MAAM,CAAC,aAAa;IAI5B;;;;;;;;;;OAUG;IACH,MAAM,CAAC,gBAAgB,CAAC,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,MAAM,GAAG,SAAS;IAKzF;;;;;;;;;;OAUG;IACH,MAAM,CAAC,YAAY,CACjB,IAAI,EAAE,MAAM,EACZ,QAAQ,EAAE,MAAM,GAAG,SAAS,EAC5B,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAC7B,MAAM,GAAG,SAAS;IAiBrB;;;;;;;;;;;;;;;OAeG;IACH,OAAO,CAAC,MAAM,CAAC,iBAAiB;CAoCjC"}
@@ -32,6 +32,12 @@ export declare class PlaceholderManager {
32
32
  * @returns A filtered record containing only registered placeholder keys.
33
33
  */
34
34
  filterValidPlaceholders(placeholders?: Record<string, string>): Record<string, string>;
35
+ /**
36
+ * Filters a record of incoming placeholders to only those that can be set by users.
37
+ * Extends filterValidPlaceholders() by also excluding adaptation-only placeholders.
38
+ * Use this for persistence loads and URL delta application.
39
+ */
40
+ filterUserSettablePlaceholders(placeholders?: Record<string, string>): Record<string, string>;
35
41
  private registerPlaceholderFromTabGroup;
36
42
  }
37
43
  export declare const placeholderManager: PlaceholderManager;
@@ -1 +1 @@
1
- {"version":3,"file":"placeholder-manager.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/features/placeholder/placeholder-manager.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAkB,MAAM,kBAAkB,CAAC;AAE/D,qBAAa,kBAAkB;IAC7B;;;OAGG;IACH,0BAA0B,CAAC,MAAM,EAAE,MAAM;IAWzC;;;;;OAKG;IACH,4BAA4B,CAAC,MAAM,EAAE,MAAM;IAQ3C;;;;;;;OAOG;IACH,mCAAmC,CAAC,UAAU,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG;QAAE,GAAG,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI;IAe7H;;;;;;OAMG;IACH,uBAAuB,CAAC,YAAY,GAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAM,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC;IAe1F,OAAO,CAAC,+BAA+B;CAqCxC;AAED,eAAO,MAAM,kBAAkB,oBAA2B,CAAC"}
1
+ {"version":3,"file":"placeholder-manager.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/features/placeholder/placeholder-manager.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAkB,MAAM,kBAAkB,CAAC;AAE/D,qBAAa,kBAAkB;IAC7B;;;OAGG;IACH,0BAA0B,CAAC,MAAM,EAAE,MAAM;IAazC;;;;;OAKG;IACH,4BAA4B,CAAC,MAAM,EAAE,MAAM;IAQ3C;;;;;;;OAOG;IACH,mCAAmC,CAAC,UAAU,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG;QAAE,GAAG,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI;IAe7H;;;;;;OAMG;IACH,uBAAuB,CAAC,YAAY,GAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAM,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC;IAa1F;;;;OAIG;IACH,8BAA8B,CAAC,YAAY,GAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAM,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC;IAiBjG,OAAO,CAAC,+BAA+B;CAqCxC;AAED,eAAO,MAAM,kBAAkB,oBAA2B,CAAC"}
@@ -10,6 +10,12 @@ export interface PlaceholderDefinition {
10
10
  hiddenFromSettings?: boolean | undefined;
11
11
  /** If true, this placeholder is only shown in settings if detected on the page */
12
12
  isLocal?: boolean | undefined;
13
+ /**
14
+ * If true, this placeholder can only be set by adaptations or the config defaultValue.
15
+ * It is hidden from settings and immune to user persistence / URL overrides.
16
+ * Implies hiddenFromSettings: true.
17
+ */
18
+ adaptationPlaceholder?: boolean | undefined;
13
19
  /** Internal tracking of where this definition came from to detect conflicts */
14
20
  source?: 'config' | 'tabgroup' | undefined;
15
21
  /** The ID of the component (e.g. TabGroup groupId) that registered this placeholder */
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/features/placeholder/types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,MAAM,WAAW,qBAAqB;IACpC,IAAI,EAAE,MAAM,CAAC;IACb,aAAa,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACnC,YAAY,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAClC,YAAY,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAClC,kBAAkB,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;IACzC,kFAAkF;IAClF,OAAO,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;IAC9B,+EAA+E;IAC/E,MAAM,CAAC,EAAE,QAAQ,GAAG,UAAU,GAAG,SAAS,CAAC;IAC3C,uFAAuF;IACvF,eAAe,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CACtC"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/features/placeholder/types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,MAAM,WAAW,qBAAqB;IACpC,IAAI,EAAE,MAAM,CAAC;IACb,aAAa,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACnC,YAAY,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAClC,YAAY,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAClC,kBAAkB,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;IACzC,kFAAkF;IAClF,OAAO,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;IAC9B;;;;OAIG;IACH,qBAAqB,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;IAC5C,+EAA+E;IAC/E,MAAM,CAAC,EAAE,QAAQ,GAAG,UAAU,GAAG,SAAS,CAAC;IAC3C,uFAAuF;IACvF,eAAe,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CACtC"}
@@ -1,8 +1,5 @@
1
- import type { UIManagerOptions } from '$lib/app/ui-manager';
2
- export interface IntroPersistence {
3
- isIntroSeen: () => boolean;
4
- markIntroSeen: () => void;
5
- }
1
+ import type { UIManagerOptions } from '$lib/app/types';
2
+ import type { PersistenceManager } from '$lib/utils/persistence';
6
3
  /**
7
4
  * IntroManager
8
5
  *
@@ -18,7 +15,7 @@ export declare class IntroManager {
18
15
  private persistence;
19
16
  private getOptions;
20
17
  private hasChecked;
21
- constructor(persistence: IntroPersistence, options: UIManagerOptions['callout'] | (() => UIManagerOptions['callout']));
18
+ constructor(persistence: PersistenceManager, options: UIManagerOptions['callout'] | (() => UIManagerOptions['callout']));
22
19
  /**
23
20
  * Initializes the manager. Should be called when the component is ready
24
21
  * and we know there are elements on the page.
@@ -1 +1 @@
1
- {"version":3,"file":"intro-manager.svelte.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/features/settings/intro-manager.svelte.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAE5D,MAAM,WAAW,gBAAgB;IAC/B,WAAW,EAAE,MAAM,OAAO,CAAC;IAC3B,aAAa,EAAE,MAAM,IAAI,CAAC;CAC3B;AAED;;;;;;;;GAQG;AACH,qBAAa,YAAY;IAEvB,WAAW,UAAiB;IAC5B,SAAS,UAAiB;IAE1B,OAAO,CAAC,WAAW,CAAmB;IACtC,OAAO,CAAC,UAAU,CAAoC;IACtD,OAAO,CAAC,UAAU,CAAS;gBAGzB,WAAW,EAAE,gBAAgB,EAC7B,OAAO,EAAE,gBAAgB,CAAC,SAAS,CAAC,GAAG,CAAC,MAAM,gBAAgB,CAAC,SAAS,CAAC,CAAC;IAS5E;;;OAGG;IACI,IAAI,CAAC,eAAe,EAAE,OAAO,EAAE,eAAe,EAAE,OAAO;IAU9D,OAAO,CAAC,YAAY;IASb,OAAO;CAKf"}
1
+ {"version":3,"file":"intro-manager.svelte.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/features/settings/intro-manager.svelte.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AACvD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAC;AAEjE;;;;;;;;GAQG;AACH,qBAAa,YAAY;IAEvB,WAAW,UAAiB;IAC5B,SAAS,UAAiB;IAE1B,OAAO,CAAC,WAAW,CAAqB;IACxC,OAAO,CAAC,UAAU,CAAoC;IACtD,OAAO,CAAC,UAAU,CAAS;gBAGzB,WAAW,EAAE,kBAAkB,EAC/B,OAAO,EAAE,gBAAgB,CAAC,SAAS,CAAC,GAAG,CAAC,MAAM,gBAAgB,CAAC,SAAS,CAAC,CAAC;IAS5E;;;OAGG;IACI,IAAI,CAAC,eAAe,EAAE,OAAO,EAAE,eAAe,EAAE,OAAO;IAU9D,OAAO,CAAC,YAAY;IASb,OAAO;CAKf"}
@@ -0,0 +1,18 @@
1
+ import type { PersistenceManager } from '$lib/utils/persistence';
2
+ export declare const ICON_SETTINGS_CTX: unique symbol;
3
+ /**
4
+ * Owns all icon UI state (collapsed, vertical offset) with persistence baked in.
5
+ * Constructed by AppRuntime (which owns PersistenceManager) and injected via Svelte context.
6
+ */
7
+ export declare class IconSettingsStore {
8
+ private persistence;
9
+ isCollapsed: boolean;
10
+ offset: number;
11
+ isDismissed: boolean;
12
+ constructor(persistence: PersistenceManager);
13
+ setCollapsed(value: boolean): void;
14
+ setOffset(value: number): void;
15
+ resetPositionAndCollapseState(): void;
16
+ dismiss(): void;
17
+ }
18
+ //# sourceMappingURL=icon-settings-store.svelte.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"icon-settings-store.svelte.d.ts","sourceRoot":"","sources":["../../../../../../../src/lib/features/settings/stores/icon-settings-store.svelte.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAC;AAKjE,eAAO,MAAM,iBAAiB,eAA0B,CAAC;AAEzD;;;GAGG;AACH,qBAAa,iBAAiB;IAKhB,OAAO,CAAC,WAAW;IAJ/B,WAAW,UAAiB;IAC5B,MAAM,SAAa;IACnB,WAAW,UAAiB;gBAER,WAAW,EAAE,kBAAkB;IAsBnD,YAAY,CAAC,KAAK,EAAE,OAAO,GAAG,IAAI;IAKlC,SAAS,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI;IAK9B,6BAA6B,IAAI,IAAI;IAYrC,OAAO,IAAI,IAAI;CAGhB"}
@@ -49,7 +49,7 @@ export interface WidgetIconConfig {
49
49
  * Top-level settings for the widget.
50
50
  */
51
51
  export interface WidgetSettings {
52
- /** Whether the settings widget is enabled */
52
+ /** Whether the settings widget is enabled (default: false) */
53
53
  enabled?: boolean;
54
54
  /** Settings panel configuration */
55
55
  panel?: WidgetPanelConfig;
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../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AE,iBAAiB,CAAC;IAC1B,oCAAoC;IACpC,OAAO,CAAC,EAAE,mBAAmB,CAAC;IAC9B,kCAAkC;IAClC,IAAI,CAAC,EAAE,gBAAgB,CAAC;CACzB"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/features/settings/types.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,mBAAmB;IACnB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,8BAA8B;IAC9B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,mEAAmE;IACnE,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,mCAAmC;IACnC,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,mBAAmB;IACnB,KAAK,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;CAC1B;AAED;;GAEG;AACH,MAAM,WAAW,mBAAmB;IAClC,mDAAmD;IACnD,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,wCAAwC;IACxC,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,wCAAwC;IACxC,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,8BAA8B;IAC9B,eAAe,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACrC,wBAAwB;IACxB,SAAS,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CAChC;AAED;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B,sBAAsB;IACtB,QAAQ,CAAC,EACL,WAAW,GACX,UAAU,GACV,cAAc,GACd,aAAa,GACb,aAAa,GACb,cAAc,CAAC;IACnB,wBAAwB;IACxB,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC3B,8BAA8B;IAC9B,eAAe,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACrC,2BAA2B;IAC3B,OAAO,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC7B,0BAA0B;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,+CAA+C;IAC/C,IAAI,CAAC,EAAE,OAAO,CAAC;CAChB;AAED;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,8DAA8D;IAC9D,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,mCAAmC;IACnC,KAAK,CAAC,EAAE,iBAAiB,CAAC;IAC1B,oCAAoC;IACpC,OAAO,CAAC,EAAE,mBAAmB,CAAC;IAC9B,kCAAkC;IAClC,IAAI,CAAC,EAAE,gBAAgB,CAAC;CACzB"}
@@ -1,10 +1,17 @@
1
- import { SvelteSet } from 'svelte/reactivity';
1
+ import { SvelteMap, SvelteSet } from 'svelte/reactivity';
2
+ import { type HighlightColorKey } from '$features/highlight/services/highlight-colors';
3
+ import { type AnnotationCorner } from '$features/highlight/services/highlight-annotations';
2
4
  export type SelectionMode = 'show' | 'hide' | 'highlight';
3
5
  export declare class ShareStore {
4
6
  isActive: boolean;
5
7
  selectionMode: SelectionMode;
6
8
  selectedElements: SvelteSet<HTMLElement>;
7
9
  currentHoverTarget: HTMLElement | null;
10
+ highlightColors: SvelteMap<HTMLElement, HighlightColorKey>;
11
+ highlightAnnotations: SvelteMap<HTMLElement, {
12
+ text: string;
13
+ corner: AnnotationCorner;
14
+ }>;
8
15
  shareCount: number;
9
16
  toggleActive(active?: boolean): void;
10
17
  setSelectionMode(mode: SelectionMode): void;
@@ -13,12 +20,16 @@ export declare class ShareStore {
13
20
  toggleElementSelection(el: HTMLElement): void;
14
21
  toggleMultipleElements(elements: HTMLElement[]): void;
15
22
  clearAllSelections(): void;
23
+ setAnnotation(el: HTMLElement, text: string, corner: AnnotationCorner): void;
24
+ setHighlightColor(el: HTMLElement, color: HighlightColorKey): void;
25
+ setAllHighlightColors(color: HighlightColorKey): void;
16
26
  private _addHighlightClass;
17
27
  private _removeHighlightClass;
18
28
  private _addSelectionClass;
19
29
  private _removeSelectionClass;
20
30
  generateLink(): void;
21
31
  previewLink(): void;
32
+ private _buildDescriptors;
22
33
  }
23
34
  export declare const shareStore: ShareStore;
24
35
  //# sourceMappingURL=share-store.svelte.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"share-store.svelte.d.ts","sourceRoot":"","sources":["../../../../../../../src/lib/features/share/stores/share-store.svelte.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAa9C,MAAM,MAAM,aAAa,GAAG,MAAM,GAAG,MAAM,GAAG,WAAW,CAAC;AAE1D,qBAAa,UAAU;IACrB,QAAQ,UAAiB;IACzB,aAAa,gBAAiC;IAC9C,gBAAgB,yBAAgE;IAChF,kBAAkB,qBAAoC;IAEtD,UAAU,SAAwC;IAElD,YAAY,CAAC,MAAM,CAAC,EAAE,OAAO;IAuB7B,gBAAgB,CAAC,IAAI,EAAE,aAAa;IAgBpC,eAAe;IASf,cAAc,CAAC,MAAM,EAAE,WAAW,GAAG,IAAI;IAczC,sBAAsB,CAAC,EAAE,EAAE,WAAW;IAwBtC,sBAAsB,CAAC,QAAQ,EAAE,WAAW,EAAE;IAO9C,kBAAkB;IAKlB,OAAO,CAAC,kBAAkB;IAU1B,OAAO,CAAC,qBAAqB;IAQ7B,OAAO,CAAC,kBAAkB;IAU1B,OAAO,CAAC,qBAAqB;IAI7B,YAAY;IA4CZ,WAAW;CA2BZ;AAED,eAAO,MAAM,UAAU,YAAmB,CAAC"}
1
+ {"version":3,"file":"share-store.svelte.d.ts","sourceRoot":"","sources":["../../../../../../../src/lib/features/share/stores/share-store.svelte.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AACzD,OAAO,EAAE,KAAK,iBAAiB,EAAE,MAAM,+CAA+C,CAAC;AACvF,OAAO,EAAE,KAAK,gBAAgB,EAAoD,MAAM,oDAAoD,CAAC;AAa7I,MAAM,MAAM,aAAa,GAAG,MAAM,GAAG,MAAM,GAAG,WAAW,CAAC;AAE1D,qBAAa,UAAU;IACrB,QAAQ,UAAiB;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