@ai-matrx/summon 0.0.0 → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +13 -0
- package/LICENSE +21 -0
- package/README.md +379 -1
- package/dist/closeBinding-C6raC3qJ.d.cts +20 -0
- package/dist/closeBinding-C6raC3qJ.d.ts +20 -0
- package/dist/dialog.cjs +60 -0
- package/dist/dialog.cjs.map +1 -0
- package/dist/dialog.d.cts +16 -0
- package/dist/dialog.d.ts +16 -0
- package/dist/dialog.js +38 -0
- package/dist/dialog.js.map +1 -0
- package/dist/errors-eJrKXq33.d.cts +30 -0
- package/dist/errors-eJrKXq33.d.ts +30 -0
- package/dist/handles.cjs +411 -0
- package/dist/handles.cjs.map +1 -0
- package/dist/handles.d.cts +166 -0
- package/dist/handles.d.ts +166 -0
- package/dist/handles.js +388 -0
- package/dist/handles.js.map +1 -0
- package/dist/index.cjs +2383 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +1259 -0
- package/dist/index.d.ts +1259 -0
- package/dist/index.js +2363 -0
- package/dist/index.js.map +1 -0
- package/dist/lite.cjs +460 -0
- package/dist/lite.cjs.map +1 -0
- package/dist/lite.d.cts +56 -0
- package/dist/lite.d.ts +56 -0
- package/dist/lite.js +444 -0
- package/dist/lite.js.map +1 -0
- package/dist/next.cjs +61 -0
- package/dist/next.cjs.map +1 -0
- package/dist/next.d.cts +5 -0
- package/dist/next.d.ts +5 -0
- package/dist/next.js +39 -0
- package/dist/next.js.map +1 -0
- package/dist/persistence-data.cjs +143 -0
- package/dist/persistence-data.cjs.map +1 -0
- package/dist/persistence-data.d.cts +72 -0
- package/dist/persistence-data.d.ts +72 -0
- package/dist/persistence-data.js +120 -0
- package/dist/persistence-data.js.map +1 -0
- package/dist/persistence.cjs +1073 -0
- package/dist/persistence.cjs.map +1 -0
- package/dist/persistence.d.cts +236 -0
- package/dist/persistence.d.ts +236 -0
- package/dist/persistence.js +1077 -0
- package/dist/persistence.js.map +1 -0
- package/dist/react.cjs +733 -0
- package/dist/react.cjs.map +1 -0
- package/dist/react.d.cts +261 -0
- package/dist/react.d.ts +261 -0
- package/dist/react.js +718 -0
- package/dist/react.js.map +1 -0
- package/dist/sheet.cjs +71 -0
- package/dist/sheet.cjs.map +1 -0
- package/dist/sheet.d.cts +17 -0
- package/dist/sheet.d.ts +17 -0
- package/dist/sheet.js +49 -0
- package/dist/sheet.js.map +1 -0
- package/dist/styles.css +78 -0
- package/dist/testing.cjs +132 -0
- package/dist/testing.cjs.map +1 -0
- package/dist/testing.d.cts +44 -0
- package/dist/testing.d.ts +44 -0
- package/dist/testing.js +115 -0
- package/dist/testing.js.map +1 -0
- package/dist/url.cjs +362 -0
- package/dist/url.cjs.map +1 -0
- package/dist/url.d.cts +153 -0
- package/dist/url.d.ts +153 -0
- package/dist/url.js +352 -0
- package/dist/url.js.map +1 -0
- package/dist/window-host.cjs +123 -0
- package/dist/window-host.cjs.map +1 -0
- package/dist/window-host.d.cts +72 -0
- package/dist/window-host.d.ts +72 -0
- package/dist/window-host.js +104 -0
- package/dist/window-host.js.map +1 -0
- package/dist/window.cjs +3978 -0
- package/dist/window.cjs.map +1 -0
- package/dist/window.d.cts +796 -0
- package/dist/window.d.ts +796 -0
- package/dist/window.js +4003 -0
- package/dist/window.js.map +1 -0
- package/package.json +239 -1
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
import * as react from 'react';
|
|
2
|
+
import { ComponentType, ReactNode } from 'react';
|
|
3
|
+
|
|
4
|
+
interface WindowSelectionSurfaceProps {
|
|
5
|
+
readonly children: ReactNode;
|
|
6
|
+
}
|
|
7
|
+
interface WindowConfig {
|
|
8
|
+
/**
|
|
9
|
+
* Visible elements matching this selector own the Escape key: a window with `closeOnEscape`
|
|
10
|
+
* yields to them (menus, popovers, listboxes and open dialogs always do). Default
|
|
11
|
+
* `[data-overlay-escape-yield]` — mark any host surface that must take Escape first.
|
|
12
|
+
*/
|
|
13
|
+
readonly escapeYieldSelector: string;
|
|
14
|
+
/** Top offset of a phone fullscreen window (below the host's header). Default `var(--header-height, 0px)`. */
|
|
15
|
+
readonly mobileTopOffset: string;
|
|
16
|
+
/**
|
|
17
|
+
* Wraps every window body (desktop, popped out, and all three phone presentations). Default:
|
|
18
|
+
* passthrough. AI Matrx injects its selection toolbar + right-click menu here.
|
|
19
|
+
*/
|
|
20
|
+
readonly selectionSurface: ComponentType<WindowSelectionSurfaceProps>;
|
|
21
|
+
}
|
|
22
|
+
declare const DEFAULT_ESCAPE_YIELD_SELECTOR = "[data-overlay-escape-yield]";
|
|
23
|
+
declare const DEFAULT_MOBILE_TOP_OFFSET = "var(--header-height, 0px)";
|
|
24
|
+
declare const DEFAULT_WINDOW_CONFIG: WindowConfig;
|
|
25
|
+
interface WindowsProviderProps extends Partial<WindowConfig> {
|
|
26
|
+
readonly children?: ReactNode;
|
|
27
|
+
}
|
|
28
|
+
declare function WindowsProvider({ escapeYieldSelector, mobileTopOffset, selectionSurface, children }: WindowsProviderProps): react.JSX.Element;
|
|
29
|
+
declare function useWindowConfig(): WindowConfig;
|
|
30
|
+
/** The configured selection surface, as a component. */
|
|
31
|
+
declare function WindowSelectionSurface({ children }: WindowSelectionSurfaceProps): react.JSX.Element;
|
|
32
|
+
|
|
33
|
+
declare function WindowTraySync(): null;
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
* Tray previews — overlay id → a semantic minimized preview and/or a custom snapshot capture.
|
|
37
|
+
*
|
|
38
|
+
* The host registers its previews once (AI Matrx keeps its own preview components in the app):
|
|
39
|
+
*
|
|
40
|
+
* registerTrayPreview("notesWindow", NotesTrayPreview);
|
|
41
|
+
* registerTrayPreview("canvasWindow", { captureTraySnapshot: captureCanvas });
|
|
42
|
+
*
|
|
43
|
+
* A window with a preview component skips snapshot capture entirely (cheaper, higher fidelity).
|
|
44
|
+
* A window with neither gets the default capture (`defaultTraySnapshotCapture`, html-to-image when
|
|
45
|
+
* the host installed it). State lives in a global slot (kit globalSlot, D9).
|
|
46
|
+
*/
|
|
47
|
+
|
|
48
|
+
interface TrayPreviewContext {
|
|
49
|
+
/** The window's allowlisted semantic data (open data merged with what `onCollectData` returned). */
|
|
50
|
+
readonly data: Readonly<Record<string, unknown>>;
|
|
51
|
+
/** Stable overlay id (the registry key). */
|
|
52
|
+
readonly overlayId: string;
|
|
53
|
+
/** Instance id — `"default"` for singleton windows. */
|
|
54
|
+
readonly instanceId: string;
|
|
55
|
+
/** The display title. */
|
|
56
|
+
readonly title: string;
|
|
57
|
+
}
|
|
58
|
+
type TraySnapshotCapture = (bodyEl: HTMLElement) => Promise<Blob | null>;
|
|
59
|
+
interface TrayPreviewEntry {
|
|
60
|
+
readonly Preview?: ComponentType<TrayPreviewContext>;
|
|
61
|
+
readonly captureTraySnapshot?: TraySnapshotCapture;
|
|
62
|
+
}
|
|
63
|
+
/**
|
|
64
|
+
* Register the minimized preview for an overlay (or any window id). Pass a component, or an entry
|
|
65
|
+
* with `Preview` and/or `captureTraySnapshot`. Re-registering replaces. Returns an unregister.
|
|
66
|
+
*/
|
|
67
|
+
declare function registerTrayPreview(overlayId: string, preview: ComponentType<TrayPreviewContext> | TrayPreviewEntry): () => void;
|
|
68
|
+
declare function getTrayPreviewEntry(overlayId: string): TrayPreviewEntry;
|
|
69
|
+
/** Test-only. */
|
|
70
|
+
declare function resetTrayPreviews(): void;
|
|
71
|
+
|
|
72
|
+
export { DEFAULT_ESCAPE_YIELD_SELECTOR, DEFAULT_MOBILE_TOP_OFFSET, DEFAULT_WINDOW_CONFIG, type TrayPreviewContext, type TrayPreviewEntry, type TraySnapshotCapture, type WindowConfig, WindowSelectionSurface, type WindowSelectionSurfaceProps, WindowTraySync, WindowsProvider, type WindowsProviderProps, getTrayPreviewEntry, registerTrayPreview, resetTrayPreviews, useWindowConfig };
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// src/window/config.tsx
|
|
4
|
+
import { createContext, useContext, useMemo } from "react";
|
|
5
|
+
import { Fragment, jsx } from "react/jsx-runtime";
|
|
6
|
+
function PassthroughSurface({ children }) {
|
|
7
|
+
return /* @__PURE__ */ jsx(Fragment, { children });
|
|
8
|
+
}
|
|
9
|
+
var DEFAULT_ESCAPE_YIELD_SELECTOR = "[data-overlay-escape-yield]";
|
|
10
|
+
var DEFAULT_MOBILE_TOP_OFFSET = "var(--header-height, 0px)";
|
|
11
|
+
var DEFAULT_WINDOW_CONFIG = {
|
|
12
|
+
escapeYieldSelector: DEFAULT_ESCAPE_YIELD_SELECTOR,
|
|
13
|
+
mobileTopOffset: DEFAULT_MOBILE_TOP_OFFSET,
|
|
14
|
+
selectionSurface: PassthroughSurface
|
|
15
|
+
};
|
|
16
|
+
var WindowConfigContext = createContext(DEFAULT_WINDOW_CONFIG);
|
|
17
|
+
WindowConfigContext.displayName = "WindowConfigContext";
|
|
18
|
+
function WindowsProvider({ escapeYieldSelector, mobileTopOffset, selectionSurface, children }) {
|
|
19
|
+
const value = useMemo(
|
|
20
|
+
() => ({
|
|
21
|
+
escapeYieldSelector: escapeYieldSelector ?? DEFAULT_WINDOW_CONFIG.escapeYieldSelector,
|
|
22
|
+
mobileTopOffset: mobileTopOffset ?? DEFAULT_WINDOW_CONFIG.mobileTopOffset,
|
|
23
|
+
selectionSurface: selectionSurface ?? DEFAULT_WINDOW_CONFIG.selectionSurface
|
|
24
|
+
}),
|
|
25
|
+
[escapeYieldSelector, mobileTopOffset, selectionSurface]
|
|
26
|
+
);
|
|
27
|
+
return /* @__PURE__ */ jsx(WindowConfigContext.Provider, { value, children });
|
|
28
|
+
}
|
|
29
|
+
function useWindowConfig() {
|
|
30
|
+
return useContext(WindowConfigContext);
|
|
31
|
+
}
|
|
32
|
+
function WindowSelectionSurface({ children }) {
|
|
33
|
+
const Surface = useWindowConfig().selectionSurface;
|
|
34
|
+
return /* @__PURE__ */ jsx(Surface, { children });
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
// src/window/WindowTraySync.tsx
|
|
38
|
+
import { useEffect } from "react";
|
|
39
|
+
import { useSummonDispatch } from "@ai-matrx/summon/react";
|
|
40
|
+
import {
|
|
41
|
+
recomputeTrayPositions,
|
|
42
|
+
clampAllWindowRects
|
|
43
|
+
} from "@ai-matrx/summon";
|
|
44
|
+
import { safeViewportDims } from "@ai-matrx/summon";
|
|
45
|
+
var DEBOUNCE_MS = 500;
|
|
46
|
+
function WindowTraySync() {
|
|
47
|
+
const dispatch = useSummonDispatch();
|
|
48
|
+
useEffect(() => {
|
|
49
|
+
let timer = null;
|
|
50
|
+
const syncWindowGeometry = () => {
|
|
51
|
+
const { vw, vh, degenerate } = safeViewportDims();
|
|
52
|
+
if (degenerate) return;
|
|
53
|
+
dispatch(
|
|
54
|
+
recomputeTrayPositions({ viewportWidth: vw, viewportHeight: vh })
|
|
55
|
+
);
|
|
56
|
+
dispatch(clampAllWindowRects({ viewportWidth: vw, viewportHeight: vh }));
|
|
57
|
+
};
|
|
58
|
+
syncWindowGeometry();
|
|
59
|
+
const handleResize = () => {
|
|
60
|
+
if (timer !== null) clearTimeout(timer);
|
|
61
|
+
timer = setTimeout(() => {
|
|
62
|
+
timer = null;
|
|
63
|
+
syncWindowGeometry();
|
|
64
|
+
}, DEBOUNCE_MS);
|
|
65
|
+
};
|
|
66
|
+
window.addEventListener("resize", handleResize, { passive: true });
|
|
67
|
+
return () => {
|
|
68
|
+
window.removeEventListener("resize", handleResize);
|
|
69
|
+
if (timer !== null) clearTimeout(timer);
|
|
70
|
+
};
|
|
71
|
+
}, [dispatch]);
|
|
72
|
+
return null;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
// src/window/tray/trayPreviewRegistry.ts
|
|
76
|
+
import { globalSlot } from "@ai-matrx/kit/global-slot";
|
|
77
|
+
var EMPTY = {};
|
|
78
|
+
var registry = () => globalSlot("ai-matrx.summon.window.trayPreviews", () => /* @__PURE__ */ new Map());
|
|
79
|
+
function registerTrayPreview(overlayId, preview) {
|
|
80
|
+
const entry = typeof preview === "function" ? { Preview: preview } : preview;
|
|
81
|
+
registry().set(overlayId, entry);
|
|
82
|
+
return () => {
|
|
83
|
+
if (registry().get(overlayId) === entry) registry().delete(overlayId);
|
|
84
|
+
};
|
|
85
|
+
}
|
|
86
|
+
function getTrayPreviewEntry(overlayId) {
|
|
87
|
+
return registry().get(overlayId) ?? EMPTY;
|
|
88
|
+
}
|
|
89
|
+
function resetTrayPreviews() {
|
|
90
|
+
registry().clear();
|
|
91
|
+
}
|
|
92
|
+
export {
|
|
93
|
+
DEFAULT_ESCAPE_YIELD_SELECTOR,
|
|
94
|
+
DEFAULT_MOBILE_TOP_OFFSET,
|
|
95
|
+
DEFAULT_WINDOW_CONFIG,
|
|
96
|
+
WindowSelectionSurface,
|
|
97
|
+
WindowTraySync,
|
|
98
|
+
WindowsProvider,
|
|
99
|
+
getTrayPreviewEntry,
|
|
100
|
+
registerTrayPreview,
|
|
101
|
+
resetTrayPreviews,
|
|
102
|
+
useWindowConfig
|
|
103
|
+
};
|
|
104
|
+
//# sourceMappingURL=window-host.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/window/config.tsx","../src/window/WindowTraySync.tsx","../src/window/tray/trayPreviewRegistry.ts"],"sourcesContent":["\"use client\";\n\n/**\n * WindowsProvider — the window section's host options, read by every WindowPanel through context.\n * Everything has a working default, so no provider is needed at all; a host passes only what it\n * has (AI Matrx: its right-click selection menu and its header offset).\n */\nimport { createContext, useContext, useMemo, type ComponentType, type ReactNode } from \"react\";\n\nexport interface WindowSelectionSurfaceProps {\n readonly children: ReactNode;\n}\n\nexport interface WindowConfig {\n /**\n * Visible elements matching this selector own the Escape key: a window with `closeOnEscape`\n * yields to them (menus, popovers, listboxes and open dialogs always do). Default\n * `[data-overlay-escape-yield]` — mark any host surface that must take Escape first.\n */\n readonly escapeYieldSelector: string;\n /** Top offset of a phone fullscreen window (below the host's header). Default `var(--header-height, 0px)`. */\n readonly mobileTopOffset: string;\n /**\n * Wraps every window body (desktop, popped out, and all three phone presentations). Default:\n * passthrough. AI Matrx injects its selection toolbar + right-click menu here.\n */\n readonly selectionSurface: ComponentType<WindowSelectionSurfaceProps>;\n}\n\nfunction PassthroughSurface({ children }: WindowSelectionSurfaceProps) {\n return <>{children}</>;\n}\n\nexport const DEFAULT_ESCAPE_YIELD_SELECTOR = \"[data-overlay-escape-yield]\";\nexport const DEFAULT_MOBILE_TOP_OFFSET = \"var(--header-height, 0px)\";\n\nexport const DEFAULT_WINDOW_CONFIG: WindowConfig = {\n escapeYieldSelector: DEFAULT_ESCAPE_YIELD_SELECTOR,\n mobileTopOffset: DEFAULT_MOBILE_TOP_OFFSET,\n selectionSurface: PassthroughSurface,\n};\n\nconst WindowConfigContext = createContext<WindowConfig>(DEFAULT_WINDOW_CONFIG);\nWindowConfigContext.displayName = \"WindowConfigContext\";\n\nexport interface WindowsProviderProps extends Partial<WindowConfig> {\n readonly children?: ReactNode;\n}\n\nexport function WindowsProvider({ escapeYieldSelector, mobileTopOffset, selectionSurface, children }: WindowsProviderProps) {\n const value = useMemo<WindowConfig>(\n () => ({\n escapeYieldSelector: escapeYieldSelector ?? DEFAULT_WINDOW_CONFIG.escapeYieldSelector,\n mobileTopOffset: mobileTopOffset ?? DEFAULT_WINDOW_CONFIG.mobileTopOffset,\n selectionSurface: selectionSurface ?? DEFAULT_WINDOW_CONFIG.selectionSurface,\n }),\n [escapeYieldSelector, mobileTopOffset, selectionSurface],\n );\n return <WindowConfigContext.Provider value={value}>{children}</WindowConfigContext.Provider>;\n}\n\nexport function useWindowConfig(): WindowConfig {\n return useContext(WindowConfigContext);\n}\n\n/** The configured selection surface, as a component. */\nexport function WindowSelectionSurface({ children }: WindowSelectionSurfaceProps) {\n const Surface = useWindowConfig().selectionSurface;\n return <Surface>{children}</Surface>;\n}\n","\"use client\";\n\n/**\n * WindowTraySync\n *\n * Mounts ONCE in the root layout. Attaches a single debounced resize listener\n * that:\n * 1. Recomputes the positions of all minimized windows (tray slots can change\n * when chips-per-row shifts on viewport resize).\n * 2. Clamps every docked windowed window into the new viewport so windows\n * positioned for a larger screen stay reachable after a downsize.\n *\n * Zero re-renders — fires and forgets.\n *\n * Debounce: 500ms — a continuous window-drag generates exactly one dispatch\n * when the user stops moving. Short bursts (e.g. snapping) are ignored.\n *\n * Usage (in both authenticated and SSR root layouts):\n * <WindowTraySync />\n */\n\nimport { useEffect } from \"react\";\nimport { useSummonDispatch } from \"@ai-matrx/summon/react\";\nimport {\n recomputeTrayPositions,\n clampAllWindowRects,\n} from \"@ai-matrx/summon\";\nimport { safeViewportDims } from \"@ai-matrx/summon\";\n\nconst DEBOUNCE_MS = 500;\n\nexport function WindowTraySync() {\n const dispatch = useSummonDispatch();\n\n useEffect(() => {\n let timer: ReturnType<typeof setTimeout> | null = null;\n\n const syncWindowGeometry = () => {\n // A resize that measures 0×0 is a hidden/undisplayed tab or a\n // display:none ancestor, never a real screen. Bail WITHOUT dispatching:\n // reacting to it would rewrite every window rect and every tray slot\n // against invented dimensions, and the next real measurement would\n // then have to undo it. No measurement, no write.\n const { vw, vh, degenerate } = safeViewportDims();\n if (degenerate) return;\n dispatch(\n recomputeTrayPositions({ viewportWidth: vw, viewportHeight: vh }),\n );\n dispatch(clampAllWindowRects({ viewportWidth: vw, viewportHeight: vh }));\n };\n\n // This island may load after the viewport already changed. Synchronising\n // once on mount closes that event-listener gap for persisted windows.\n syncWindowGeometry();\n\n const handleResize = () => {\n if (timer !== null) clearTimeout(timer);\n timer = setTimeout(() => {\n timer = null;\n syncWindowGeometry();\n }, DEBOUNCE_MS);\n };\n\n window.addEventListener(\"resize\", handleResize, { passive: true });\n\n return () => {\n window.removeEventListener(\"resize\", handleResize);\n if (timer !== null) clearTimeout(timer);\n };\n }, [dispatch]);\n\n return null;\n}\n\nexport default WindowTraySync;\n","/**\n * Tray previews — overlay id → a semantic minimized preview and/or a custom snapshot capture.\n *\n * The host registers its previews once (AI Matrx keeps its own preview components in the app):\n *\n * registerTrayPreview(\"notesWindow\", NotesTrayPreview);\n * registerTrayPreview(\"canvasWindow\", { captureTraySnapshot: captureCanvas });\n *\n * A window with a preview component skips snapshot capture entirely (cheaper, higher fidelity).\n * A window with neither gets the default capture (`defaultTraySnapshotCapture`, html-to-image when\n * the host installed it). State lives in a global slot (kit globalSlot, D9).\n */\nimport type { ComponentType } from \"react\";\nimport { globalSlot } from \"@ai-matrx/kit/global-slot\";\n\nexport interface TrayPreviewContext {\n /** The window's allowlisted semantic data (open data merged with what `onCollectData` returned). */\n readonly data: Readonly<Record<string, unknown>>;\n /** Stable overlay id (the registry key). */\n readonly overlayId: string;\n /** Instance id — `\"default\"` for singleton windows. */\n readonly instanceId: string;\n /** The display title. */\n readonly title: string;\n}\n\nexport type TraySnapshotCapture = (bodyEl: HTMLElement) => Promise<Blob | null>;\n\nexport interface TrayPreviewEntry {\n readonly Preview?: ComponentType<TrayPreviewContext>;\n readonly captureTraySnapshot?: TraySnapshotCapture;\n}\n\nconst EMPTY: TrayPreviewEntry = {};\n\nconst registry = (): Map<string, TrayPreviewEntry> =>\n globalSlot<Map<string, TrayPreviewEntry>>(\"ai-matrx.summon.window.trayPreviews\", () => new Map());\n\n/**\n * Register the minimized preview for an overlay (or any window id). Pass a component, or an entry\n * with `Preview` and/or `captureTraySnapshot`. Re-registering replaces. Returns an unregister.\n */\nexport function registerTrayPreview(\n overlayId: string,\n preview: ComponentType<TrayPreviewContext> | TrayPreviewEntry,\n): () => void {\n const entry: TrayPreviewEntry = typeof preview === \"function\" ? { Preview: preview } : preview;\n registry().set(overlayId, entry);\n return () => {\n if (registry().get(overlayId) === entry) registry().delete(overlayId);\n };\n}\n\nexport function getTrayPreviewEntry(overlayId: string): TrayPreviewEntry {\n return registry().get(overlayId) ?? EMPTY;\n}\n\n/** Test-only. */\nexport function resetTrayPreviews(): void {\n registry().clear();\n}\n"],"mappings":";;;AAOA,SAAS,eAAe,YAAY,eAAmD;AAuB9E;AADT,SAAS,mBAAmB,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