@adapttable/naive-ui 0.4.1 → 0.6.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/README.md +5 -5
- package/dist/{NaiveFilterSurface-DqUmkz-o.cjs → NaiveFilterField-CP2V5YLz.cjs} +183 -149
- package/dist/NaiveFilterField-CP2V5YLz.cjs.map +1 -0
- package/dist/{NaiveFilterSurface-CnhNSSF1.js → NaiveFilterField-SRraOkWU.js} +173 -151
- package/dist/NaiveFilterField-SRraOkWU.js.map +1 -0
- package/dist/{NaiveRowActions-BR140413.cjs → NaiveRowActions-DUlkorWa.cjs} +2 -2
- package/dist/NaiveRowActions-DUlkorWa.cjs.map +1 -0
- package/dist/{NaiveRowActions-DVyMXQJq.js → NaiveRowActions-DdHuWGCQ.js} +2 -2
- package/dist/NaiveRowActions-DdHuWGCQ.js.map +1 -0
- package/dist/assistant.cjs +360 -5
- package/dist/assistant.cjs.map +1 -0
- package/dist/assistant.js +356 -1
- package/dist/assistant.js.map +1 -0
- package/dist/batch-editing.cjs +1 -1
- package/dist/batch-editing.d.cts +1 -1
- package/dist/batch-editing.d.ts +1 -1
- package/dist/batch-editing.js +1 -1
- package/dist/cell-navigation.cjs.map +1 -1
- package/dist/cell-navigation.d.cts +1 -1
- package/dist/cell-navigation.d.cts.map +1 -1
- package/dist/cell-navigation.d.ts +1 -1
- package/dist/cell-navigation.d.ts.map +1 -1
- package/dist/cell-navigation.js.map +1 -1
- package/dist/column-layout.cjs +24 -0
- package/dist/column-layout.cjs.map +1 -0
- package/dist/column-layout.d.cts +12 -0
- package/dist/column-layout.d.cts.map +1 -0
- package/dist/column-layout.d.ts +12 -0
- package/dist/column-layout.d.ts.map +1 -0
- package/dist/column-layout.js +22 -0
- package/dist/column-layout.js.map +1 -0
- package/dist/{column-menu-GUeADLrH.cjs → column-menu-B-EhL5Ih.cjs} +3 -3
- package/dist/{column-menu-GUeADLrH.cjs.map → column-menu-B-EhL5Ih.cjs.map} +1 -1
- package/dist/{column-menu-BeNblq2u.js → column-menu-BwKtCGEo.js} +3 -3
- package/dist/{column-menu-BeNblq2u.js.map → column-menu-BwKtCGEo.js.map} +1 -1
- package/dist/column-menu.cjs +1 -1
- package/dist/column-menu.d.cts +24 -2
- package/dist/column-menu.d.cts.map +1 -0
- package/dist/column-menu.d.ts +24 -2
- package/dist/column-menu.d.ts.map +1 -0
- package/dist/column-menu.js +1 -1
- package/dist/command-palette.cjs +112 -2
- package/dist/command-palette.cjs.map +1 -0
- package/dist/command-palette.js +111 -1
- package/dist/command-palette.js.map +1 -0
- package/dist/context-menu.cjs +140 -2
- package/dist/context-menu.cjs.map +1 -0
- package/dist/context-menu.js +139 -1
- package/dist/context-menu.js.map +1 -0
- package/dist/{editing-DTOBwNI6.js → editing-Btr52gcG.js} +19 -5
- package/dist/{editing-DTOBwNI6.js.map → editing-Btr52gcG.js.map} +1 -1
- package/dist/{editing-BAUOl5Ox.cjs → editing-CIvf43jv.cjs} +23 -3
- package/dist/editing-CIvf43jv.cjs.map +1 -0
- package/dist/{editing-Dho3Y2RK.d.ts → editing-dN16BK0k.d.ts} +10 -2
- package/dist/{editing-Dho3Y2RK.d.ts.map → editing-dN16BK0k.d.ts.map} +1 -1
- package/dist/{editing-CdIoFGiK.d.cts → editing-xDGCcasQ.d.cts} +10 -2
- package/dist/{editing-CdIoFGiK.d.cts.map → editing-xDGCcasQ.d.cts.map} +1 -1
- package/dist/editing.cjs +4 -13
- package/dist/editing.d.cts +2 -2
- package/dist/editing.d.ts +2 -2
- package/dist/editing.js +2 -2
- package/dist/export-DLLCc4Lb.js +10 -0
- package/dist/export-DLLCc4Lb.js.map +1 -0
- package/dist/{export-csv.cjs → export-fT_9Xp5t.cjs} +7 -3
- package/dist/export-fT_9Xp5t.cjs.map +1 -0
- package/dist/export.cjs +2 -2
- package/dist/export.d.cts +9 -2
- package/dist/export.d.cts.map +1 -0
- package/dist/export.d.ts +9 -2
- package/dist/export.d.ts.map +1 -0
- package/dist/export.js +1 -1
- package/dist/filtering.cjs +22 -0
- package/dist/filtering.cjs.map +1 -0
- package/dist/filtering.d.cts +13 -0
- package/dist/filtering.d.cts.map +1 -0
- package/dist/filtering.d.ts +13 -0
- package/dist/filtering.d.ts.map +1 -0
- package/dist/filtering.js +21 -0
- package/dist/filtering.js.map +1 -0
- package/dist/{filters-DipcT7-T.js → filters-BxRu0r4j.js} +64 -9
- package/dist/filters-BxRu0r4j.js.map +1 -0
- package/dist/{filters-B5JX7H8p.cjs → filters-U0LYOQjA.cjs} +106 -9
- package/dist/filters-U0LYOQjA.cjs.map +1 -0
- package/dist/filters.cjs +11 -4
- package/dist/filters.d.cts +90 -2
- package/dist/filters.d.cts.map +1 -0
- package/dist/filters.d.ts +90 -2
- package/dist/filters.d.ts.map +1 -0
- package/dist/filters.js +3 -3
- package/dist/grouping-panel.cjs +146 -3
- package/dist/grouping-panel.cjs.map +1 -0
- package/dist/grouping-panel.js +145 -2
- package/dist/grouping-panel.js.map +1 -0
- package/dist/{header-filters-CWad6foD.js → header-filters-Bxb3snYP.js} +2 -2
- package/dist/{header-filters-CWad6foD.js.map → header-filters-Bxb3snYP.js.map} +1 -1
- package/dist/{header-filters-C8cAJJ7r.cjs → header-filters-CvStECsj.cjs} +5 -5
- package/dist/{header-filters-C8cAJJ7r.cjs.map → header-filters-CvStECsj.cjs.map} +1 -1
- package/dist/header-filters.cjs +1 -1
- package/dist/header-filters.d.cts +52 -2
- package/dist/header-filters.d.cts.map +1 -0
- package/dist/header-filters.d.ts +52 -2
- package/dist/header-filters.d.ts.map +1 -0
- package/dist/header-filters.js +1 -1
- package/dist/index.cjs +2 -27
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -2
- package/dist/index.d.cts.map +1 -1
- package/dist/index.d.ts +1 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -27
- package/dist/index.js.map +1 -1
- package/dist/preset.cjs +9 -10
- package/dist/preset.cjs.map +1 -1
- package/dist/preset.js +8 -9
- package/dist/preset.js.map +1 -1
- package/dist/row-actions.cjs +1 -1
- package/dist/row-actions.js +1 -1
- package/dist/row-pinning.cjs +1 -1
- package/dist/row-pinning.js +1 -1
- package/dist/row-reorder.cjs +185 -2
- package/dist/row-reorder.cjs.map +1 -0
- package/dist/row-reorder.d.cts +2 -1
- package/dist/row-reorder.d.cts.map +1 -1
- package/dist/row-reorder.d.ts +2 -1
- package/dist/row-reorder.d.ts.map +1 -1
- package/dist/row-reorder.js +185 -1
- package/dist/row-reorder.js.map +1 -0
- package/dist/selection.cjs +8 -0
- package/dist/selection.d.cts +2 -0
- package/dist/selection.d.ts +2 -0
- package/dist/selection.js +2 -0
- package/dist/side-panel.cjs +59 -2
- package/dist/side-panel.cjs.map +1 -0
- package/dist/side-panel.js +58 -1
- package/dist/side-panel.js.map +1 -0
- package/dist/styles.css +39 -39
- package/package.json +33 -23
- package/dist/NaiveFilterSurface-CnhNSSF1.js.map +0 -1
- package/dist/NaiveFilterSurface-DqUmkz-o.cjs.map +0 -1
- package/dist/NaiveRowActions-BR140413.cjs.map +0 -1
- package/dist/NaiveRowActions-DVyMXQJq.js.map +0 -1
- package/dist/assistant-DppW6EN1.cjs +0 -380
- package/dist/assistant-DppW6EN1.cjs.map +0 -1
- package/dist/assistant-_SYRZCOi.js +0 -357
- package/dist/assistant-_SYRZCOi.js.map +0 -1
- package/dist/column-menu-DdWVP1hz.d.cts +0 -23
- package/dist/column-menu-DdWVP1hz.d.cts.map +0 -1
- package/dist/column-menu-DdWVP1hz.d.ts +0 -23
- package/dist/column-menu-DdWVP1hz.d.ts.map +0 -1
- package/dist/command-palette-4qS9viir.cjs +0 -117
- package/dist/command-palette-4qS9viir.cjs.map +0 -1
- package/dist/command-palette-CSI-tgcP.js +0 -112
- package/dist/command-palette-CSI-tgcP.js.map +0 -1
- package/dist/context-menu-CsbLaMcR.js +0 -140
- package/dist/context-menu-CsbLaMcR.js.map +0 -1
- package/dist/context-menu-qVwE9S2V.cjs +0 -145
- package/dist/context-menu-qVwE9S2V.cjs.map +0 -1
- package/dist/editing-BAUOl5Ox.cjs.map +0 -1
- package/dist/export-csv-BU39yRSN.d.ts +0 -9
- package/dist/export-csv-BU39yRSN.d.ts.map +0 -1
- package/dist/export-csv-DRDjZuQj.d.cts +0 -9
- package/dist/export-csv-DRDjZuQj.d.cts.map +0 -1
- package/dist/export-csv.cjs.map +0 -1
- package/dist/export-csv.d.cts +0 -2
- package/dist/export-csv.d.ts +0 -2
- package/dist/export-csv.js +0 -10
- package/dist/export-csv.js.map +0 -1
- package/dist/features.cjs +0 -218
- package/dist/features.d.cts +0 -41
- package/dist/features.d.ts +0 -41
- package/dist/features.js +0 -37
- package/dist/filters-B5JX7H8p.cjs.map +0 -1
- package/dist/filters-BJ48GzqJ.d.ts +0 -66
- package/dist/filters-BJ48GzqJ.d.ts.map +0 -1
- package/dist/filters-C6DvAZ_T.d.cts +0 -66
- package/dist/filters-C6DvAZ_T.d.cts.map +0 -1
- package/dist/filters-DipcT7-T.js.map +0 -1
- package/dist/grouping-panel-BPaPG49S.cjs +0 -151
- package/dist/grouping-panel-BPaPG49S.cjs.map +0 -1
- package/dist/grouping-panel-CYUPSa0u.js +0 -146
- package/dist/grouping-panel-CYUPSa0u.js.map +0 -1
- package/dist/header-filters-CQg6clum.d.cts +0 -52
- package/dist/header-filters-CQg6clum.d.cts.map +0 -1
- package/dist/header-filters-CQg6clum.d.ts +0 -52
- package/dist/header-filters-CQg6clum.d.ts.map +0 -1
- package/dist/row-reorder-2Ztn7QRu.cjs +0 -191
- package/dist/row-reorder-2Ztn7QRu.cjs.map +0 -1
- package/dist/row-reorder-DBzbJ20V.js +0 -186
- package/dist/row-reorder-DBzbJ20V.js.map +0 -1
- package/dist/side-panel-Bf4zBlYZ.cjs +0 -64
- package/dist/side-panel-Bf4zBlYZ.cjs.map +0 -1
- package/dist/side-panel-CLTgXUnb.js +0 -59
- package/dist/side-panel-CLTgXUnb.js.map +0 -1
package/dist/assistant.cjs
CHANGED
|
@@ -1,6 +1,361 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
2
|
+
const require_button = require("./button-CaakTzYM.cjs");
|
|
3
|
+
const require_input = require("./input-DZV2IoAG.cjs");
|
|
4
|
+
const require_select = require("./select-C8UKnsWO.cjs");
|
|
5
|
+
let _adapttable_vue_adapter = require("@adapttable/vue/adapter");
|
|
6
|
+
let vue = require("vue");
|
|
7
|
+
let naive_ui = require("naive-ui");
|
|
8
|
+
//#region src/assistant/ExamplesMenu.ts
|
|
9
|
+
/** One shortcut as a menu item: its icon, title and optional description. */
|
|
10
|
+
function shortcut(item, choose) {
|
|
11
|
+
return require_button.naiveButton({
|
|
12
|
+
key: item.id,
|
|
13
|
+
role: "menuitem",
|
|
14
|
+
tabindex: -1,
|
|
15
|
+
"data-adapttable-part": item.part,
|
|
16
|
+
class: "adapttable-naive-assistant-shortcut",
|
|
17
|
+
onClick: () => choose(item.id)
|
|
18
|
+
}, [item.icon, (0, vue.h)("span", [(0, vue.h)("strong", item.title), item.description ? (0, vue.h)("small", item.description) : null])], { text: true });
|
|
19
|
+
}
|
|
20
|
+
/** The open menu: a Naive UI card holding one menu item per shortcut. */
|
|
21
|
+
function menuCard(props, card, keydown, choose) {
|
|
22
|
+
const items = props.items.map((item) => shortcut(item, choose));
|
|
23
|
+
return (0, vue.h)(naive_ui.NCard, {
|
|
24
|
+
ref: card,
|
|
25
|
+
size: "small",
|
|
26
|
+
role: "menu",
|
|
27
|
+
"aria-label": props.label,
|
|
28
|
+
class: "adapttable-naive-assistant-menu",
|
|
29
|
+
contentStyle: {
|
|
30
|
+
display: "flex",
|
|
31
|
+
flexDirection: "column",
|
|
32
|
+
gap: "4px"
|
|
33
|
+
},
|
|
34
|
+
style: {
|
|
35
|
+
maxHeight: props.maxHeight,
|
|
36
|
+
overflowY: "auto"
|
|
37
|
+
},
|
|
38
|
+
onKeydown: keydown
|
|
39
|
+
}, { default: () => items });
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* The assistant's shortcuts in a Naive UI popover menu under its trigger.
|
|
43
|
+
* The shared menu navigation moves focus; Escape and Tab close the menu and
|
|
44
|
+
* Escape returns focus to the trigger.
|
|
45
|
+
*/
|
|
46
|
+
const NaiveExamplesMenu = (0, vue.defineComponent)((props) => {
|
|
47
|
+
const active = (0, _adapttable_vue_adapter.useScopeActivity)();
|
|
48
|
+
const open = (0, vue.shallowRef)(false);
|
|
49
|
+
const trigger = (0, vue.shallowRef)(null);
|
|
50
|
+
const card = (0, vue.shallowRef)(null);
|
|
51
|
+
const navigation = (0, _adapttable_vue_adapter.createMenuNavigation)();
|
|
52
|
+
let generation = 0;
|
|
53
|
+
(0, vue.watch)([
|
|
54
|
+
active,
|
|
55
|
+
() => props.disabled,
|
|
56
|
+
() => props.items,
|
|
57
|
+
() => props.onSelect
|
|
58
|
+
], () => {
|
|
59
|
+
generation++;
|
|
60
|
+
open.value = false;
|
|
61
|
+
}, { flush: "sync" });
|
|
62
|
+
(0, vue.watch)(open, (expanded) => {
|
|
63
|
+
navigation.reset();
|
|
64
|
+
if (!expanded) return;
|
|
65
|
+
(0, _adapttable_vue_adapter.scheduleTick)(() => {
|
|
66
|
+
(card.value ? require_button.htmlRoot(card.value) : null)?.querySelector("[role=\"menuitem\"]")?.focus({ preventScroll: true });
|
|
67
|
+
});
|
|
68
|
+
});
|
|
69
|
+
const close = (restore) => {
|
|
70
|
+
open.value = false;
|
|
71
|
+
if (restore) trigger.value?.focus({ preventScroll: true });
|
|
72
|
+
};
|
|
73
|
+
const keydown = (event) => {
|
|
74
|
+
const panel = event.currentTarget;
|
|
75
|
+
if (!(panel instanceof HTMLElement)) return;
|
|
76
|
+
const items = [...panel.querySelectorAll("[role=\"menuitem\"]")];
|
|
77
|
+
const focusTargets = items;
|
|
78
|
+
const action = navigation.key(event, items.map((item) => ({
|
|
79
|
+
label: item.textContent ?? "",
|
|
80
|
+
disabled: item.disabled
|
|
81
|
+
})), focusTargets.indexOf(panel.ownerDocument.activeElement));
|
|
82
|
+
if (!action) return;
|
|
83
|
+
if (action.kind !== "close" || action.key !== "Tab") event.preventDefault();
|
|
84
|
+
event.stopPropagation();
|
|
85
|
+
if (action.kind === "close") close(action.key === "Escape");
|
|
86
|
+
else items[action.index]?.focus({ preventScroll: true });
|
|
87
|
+
};
|
|
88
|
+
return () => {
|
|
89
|
+
if (!active.value) return null;
|
|
90
|
+
const ticket = generation;
|
|
91
|
+
const choose = (id) => {
|
|
92
|
+
if (!active.value || props.disabled || ticket !== generation || !props.items.some((item) => item.id === id)) return;
|
|
93
|
+
close(false);
|
|
94
|
+
props.onSelect(id);
|
|
95
|
+
};
|
|
96
|
+
return (0, vue.h)(naive_ui.NPopover, {
|
|
97
|
+
trigger: "manual",
|
|
98
|
+
show: open.value,
|
|
99
|
+
placement: "bottom-start",
|
|
100
|
+
showArrow: false,
|
|
101
|
+
raw: true,
|
|
102
|
+
onClickoutside: (event) => {
|
|
103
|
+
if (event.target instanceof Node && trigger.value?.contains(event.target)) return;
|
|
104
|
+
close(false);
|
|
105
|
+
}
|
|
106
|
+
}, {
|
|
107
|
+
trigger: () => require_button.naiveButton({
|
|
108
|
+
ref: (element) => {
|
|
109
|
+
trigger.value = element;
|
|
110
|
+
},
|
|
111
|
+
disabled: props.disabled,
|
|
112
|
+
"aria-label": props.label,
|
|
113
|
+
"aria-haspopup": "menu",
|
|
114
|
+
"aria-expanded": open.value,
|
|
115
|
+
title: props.label,
|
|
116
|
+
class: props.className,
|
|
117
|
+
"data-adapttable-part": props.part,
|
|
118
|
+
onClick: () => {
|
|
119
|
+
if (active.value && !props.disabled) open.value = !open.value;
|
|
120
|
+
}
|
|
121
|
+
}, [props.icon ?? props.label]),
|
|
122
|
+
default: () => menuCard(props, card, keydown, choose)
|
|
123
|
+
});
|
|
124
|
+
};
|
|
125
|
+
}, {
|
|
126
|
+
name: "NaiveExamplesMenu",
|
|
127
|
+
props: {
|
|
128
|
+
label: { type: String },
|
|
129
|
+
part: { type: String },
|
|
130
|
+
className: { type: String },
|
|
131
|
+
icon: {
|
|
132
|
+
type: [
|
|
133
|
+
String,
|
|
134
|
+
Number,
|
|
135
|
+
Boolean,
|
|
136
|
+
Array,
|
|
137
|
+
Object
|
|
138
|
+
],
|
|
139
|
+
default: void 0
|
|
140
|
+
},
|
|
141
|
+
disabled: {
|
|
142
|
+
type: Boolean,
|
|
143
|
+
default: void 0
|
|
144
|
+
},
|
|
145
|
+
items: { type: Array },
|
|
146
|
+
onSelect: { type: Function },
|
|
147
|
+
maxHeight: { type: String }
|
|
148
|
+
}
|
|
149
|
+
});
|
|
150
|
+
//#endregion
|
|
151
|
+
//#region src/assistant/Sheet.ts
|
|
152
|
+
/**
|
|
153
|
+
* Chrome chooses initial and return focus; NDrawer contains focus and owns
|
|
154
|
+
* the portal. Escape and mask dismissal become one close request to the
|
|
155
|
+
* host, and the drawer stays open until the host closes it.
|
|
156
|
+
*/
|
|
157
|
+
const NaiveAssistantSheet = (0, vue.defineComponent)((props) => {
|
|
158
|
+
const active = (0, _adapttable_vue_adapter.useScopeActivity)();
|
|
159
|
+
const requestClose = () => {
|
|
160
|
+
if (active.value && props.open) props.onClose();
|
|
161
|
+
};
|
|
162
|
+
const keydown = (event) => {
|
|
163
|
+
if (event.key !== "Escape" || event.defaultPrevented || event.isComposing) return;
|
|
164
|
+
event.preventDefault();
|
|
165
|
+
event.stopPropagation();
|
|
166
|
+
requestClose();
|
|
167
|
+
};
|
|
168
|
+
return () => {
|
|
169
|
+
if (!active.value) return null;
|
|
170
|
+
return (0, vue.h)(naive_ui.NDrawer, {
|
|
171
|
+
show: props.open,
|
|
172
|
+
placement: props.dir === "rtl" ? "left" : "right",
|
|
173
|
+
width: "min(28rem, 100vw)",
|
|
174
|
+
autoFocus: false,
|
|
175
|
+
closeOnEsc: false,
|
|
176
|
+
maskClosable: false,
|
|
177
|
+
role: "dialog",
|
|
178
|
+
"aria-modal": "true",
|
|
179
|
+
"aria-label": props.label,
|
|
180
|
+
dir: props.dir,
|
|
181
|
+
class: ["adapttable-naive-assistant-sheet", props.className],
|
|
182
|
+
"data-adapttable-part": props.part,
|
|
183
|
+
onKeydown: keydown,
|
|
184
|
+
onMaskClick: requestClose
|
|
185
|
+
}, { default: () => (0, vue.h)(naive_ui.NDrawerContent, {}, { default: () => props.children }) });
|
|
186
|
+
};
|
|
187
|
+
}, {
|
|
188
|
+
name: "NaiveAssistantSheet",
|
|
189
|
+
props: {
|
|
190
|
+
label: { type: String },
|
|
191
|
+
part: { type: String },
|
|
192
|
+
className: { type: String },
|
|
193
|
+
dir: { type: String },
|
|
194
|
+
open: {
|
|
195
|
+
type: Boolean,
|
|
196
|
+
default: void 0
|
|
197
|
+
},
|
|
198
|
+
onClose: { type: Function },
|
|
199
|
+
children: {
|
|
200
|
+
type: [
|
|
201
|
+
String,
|
|
202
|
+
Number,
|
|
203
|
+
Boolean,
|
|
204
|
+
Array,
|
|
205
|
+
Object
|
|
206
|
+
],
|
|
207
|
+
default: void 0
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
});
|
|
211
|
+
//#endregion
|
|
212
|
+
//#region src/assistant/controls.ts
|
|
213
|
+
/** Naive UI tag types for the assistant's status tones. */
|
|
214
|
+
const TAG_TYPE = {
|
|
215
|
+
neutral: "default",
|
|
216
|
+
busy: "info",
|
|
217
|
+
warning: "warning",
|
|
218
|
+
danger: "error"
|
|
219
|
+
};
|
|
220
|
+
const surface = (props, classes) => (0, vue.h)(naive_ui.NCard, {
|
|
221
|
+
size: "small",
|
|
222
|
+
role: "region",
|
|
223
|
+
"data-adapttable-part": props.part,
|
|
224
|
+
"aria-label": props.label,
|
|
225
|
+
class: classes,
|
|
226
|
+
style: props.style,
|
|
227
|
+
contentStyle: {
|
|
228
|
+
display: "flex",
|
|
229
|
+
flexDirection: "column",
|
|
230
|
+
minHeight: 0
|
|
231
|
+
}
|
|
232
|
+
}, { default: () => props.children });
|
|
233
|
+
const naiveAssistantControls = {
|
|
234
|
+
Button: (props) => require_button.naiveButton({
|
|
235
|
+
"data-adapttable-part": props.part,
|
|
236
|
+
"aria-label": props.label,
|
|
237
|
+
"aria-expanded": props.expanded,
|
|
238
|
+
title: props.tooltip,
|
|
239
|
+
class: props.className,
|
|
240
|
+
disabled: props.disabled,
|
|
241
|
+
onClick: props.onClick
|
|
242
|
+
}, [props.icon, props.iconOnly && props.icon ? null : props.children ?? props.label], { size: props.part === "assistant-launcher" ? "medium" : "small" }),
|
|
243
|
+
Composer: (props) => require_input.naiveInput({
|
|
244
|
+
type: "textarea",
|
|
245
|
+
value: props.value,
|
|
246
|
+
themeOverrides: { placeholderColor: "var(--n-text-color)" },
|
|
247
|
+
attrs: {
|
|
248
|
+
"data-adapttable-part": props.part,
|
|
249
|
+
"aria-label": props.label,
|
|
250
|
+
placeholder: props.placeholder,
|
|
251
|
+
class: props.className,
|
|
252
|
+
disabled: props.disabled,
|
|
253
|
+
rows: 1,
|
|
254
|
+
onKeydown: props.onKeyDown
|
|
255
|
+
},
|
|
256
|
+
onChange: props.onChange
|
|
257
|
+
}),
|
|
258
|
+
Badge: (props) => (0, vue.h)(naive_ui.NTag, {
|
|
259
|
+
"data-adapttable-part": props.part,
|
|
260
|
+
"data-tone": props.tone,
|
|
261
|
+
type: TAG_TYPE[props.tone],
|
|
262
|
+
style: props.tone === "warning" ? { color: "inherit" } : void 0,
|
|
263
|
+
size: "small",
|
|
264
|
+
bordered: false,
|
|
265
|
+
class: props.className
|
|
266
|
+
}, { default: () => props.label }),
|
|
267
|
+
Panel: (props) => surface(props, ["adapttable-naive-assistant-panel", props.className]),
|
|
268
|
+
Window: (props) => surface(props, ["adapttable-naive-assistant-window", props.className]),
|
|
269
|
+
Sheet: (props) => (0, vue.h)(NaiveAssistantSheet, {
|
|
270
|
+
...props,
|
|
271
|
+
key: props.part
|
|
272
|
+
}),
|
|
273
|
+
Menu: (props) => (0, vue.h)(NaiveExamplesMenu, props),
|
|
274
|
+
LanguageChip: (props) => require_select.naiveSelect({
|
|
275
|
+
attrs: {
|
|
276
|
+
"data-adapttable-part": props.part,
|
|
277
|
+
"aria-label": props.label,
|
|
278
|
+
class: props.className,
|
|
279
|
+
disabled: props.disabled
|
|
280
|
+
},
|
|
281
|
+
value: props.value,
|
|
282
|
+
options: props.options,
|
|
283
|
+
onChange: props.onChange
|
|
284
|
+
})
|
|
285
|
+
};
|
|
286
|
+
const naiveApprovalControls = {
|
|
287
|
+
Approve: naiveAssistantControls.Button,
|
|
288
|
+
Reject: naiveAssistantControls.Button,
|
|
289
|
+
Action: naiveAssistantControls.Button,
|
|
290
|
+
List: (props) => (0, vue.h)("ul", {
|
|
291
|
+
"data-adapttable-part": props.part,
|
|
292
|
+
"aria-label": props.label,
|
|
293
|
+
class: ["adapttable-naive-approval-list", props.className]
|
|
294
|
+
}, [props.children])
|
|
295
|
+
};
|
|
296
|
+
//#endregion
|
|
297
|
+
//#region src/assistant.ts
|
|
298
|
+
const TableAssistant = (0, vue.defineComponent)((props) => {
|
|
299
|
+
const theme = (0, naive_ui.useThemeVars)();
|
|
300
|
+
return () => (0, vue.h)(_adapttable_vue_adapter.TableAssistantChrome, {
|
|
301
|
+
...props,
|
|
302
|
+
accent: props.accent ?? theme.value.primaryColor,
|
|
303
|
+
slots: naiveAssistantControls
|
|
304
|
+
});
|
|
305
|
+
}, {
|
|
306
|
+
name: "NaiveTableAssistant",
|
|
307
|
+
props: {
|
|
308
|
+
assistant: { type: Object },
|
|
309
|
+
speech: { type: Object },
|
|
310
|
+
open: {
|
|
311
|
+
type: Boolean,
|
|
312
|
+
default: void 0
|
|
313
|
+
},
|
|
314
|
+
onOpenChange: { type: Function },
|
|
315
|
+
presentation: { type: String },
|
|
316
|
+
labels: { type: Object },
|
|
317
|
+
accent: { type: String },
|
|
318
|
+
receipts: {
|
|
319
|
+
type: Boolean,
|
|
320
|
+
default: void 0
|
|
321
|
+
},
|
|
322
|
+
className: { type: String },
|
|
323
|
+
launcher: {
|
|
324
|
+
type: Boolean,
|
|
325
|
+
default: void 0
|
|
326
|
+
},
|
|
327
|
+
onSettings: { type: Function },
|
|
328
|
+
boundary: { type: [String, Object] },
|
|
329
|
+
note: { type: String },
|
|
330
|
+
greeting: { type: String },
|
|
331
|
+
avatars: { type: Object },
|
|
332
|
+
messageAction: { type: Function },
|
|
333
|
+
approval: { type: Object },
|
|
334
|
+
dir: { type: String }
|
|
335
|
+
}
|
|
336
|
+
});
|
|
337
|
+
const AgentApproval = (0, vue.defineComponent)((props) => () => (0, vue.h)(_adapttable_vue_adapter.AgentApprovalChrome, {
|
|
338
|
+
...props,
|
|
339
|
+
slots: naiveApprovalControls
|
|
340
|
+
}), {
|
|
341
|
+
name: "NaiveAgentApproval",
|
|
342
|
+
props: {
|
|
343
|
+
pending: { type: Object },
|
|
344
|
+
labels: { type: Object },
|
|
345
|
+
className: { type: String },
|
|
346
|
+
buttonClassName: { type: String }
|
|
347
|
+
}
|
|
348
|
+
});
|
|
349
|
+
function tableAssistant() {
|
|
350
|
+
return (0, _adapttable_vue_adapter.createAdapterTableAssistantFeature)((props) => (0, vue.h)(TableAssistant, props));
|
|
351
|
+
}
|
|
352
|
+
function agentApproval() {
|
|
353
|
+
return (0, _adapttable_vue_adapter.createAdapterAgentApprovalFeature)((props) => (0, vue.h)(AgentApproval, props));
|
|
354
|
+
}
|
|
355
|
+
//#endregion
|
|
356
|
+
exports.AgentApproval = AgentApproval;
|
|
357
|
+
exports.TableAssistant = TableAssistant;
|
|
358
|
+
exports.agentApproval = agentApproval;
|
|
359
|
+
exports.tableAssistant = tableAssistant;
|
|
360
|
+
|
|
361
|
+
//# sourceMappingURL=assistant.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"assistant.cjs","names":["naiveButton","h","NCard","defineComponent","useScopeActivity","shallowRef","createMenuNavigation","htmlRoot","NPopover","defineComponent","useScopeActivity","h","NDrawer","NDrawerContent","h","NCard","naiveButton","naiveInput","NTag","naiveSelect","defineComponent","useThemeVars","h","TableAssistantChrome","AgentApprovalChrome","createAdapterTableAssistantFeature","createAdapterAgentApprovalFeature"],"sources":["../src/assistant/ExamplesMenu.ts","../src/assistant/Sheet.ts","../src/assistant/controls.ts","../src/assistant.ts"],"sourcesContent":["import {\n createMenuNavigation,\n scheduleTick,\n type TableAssistantMenuProps,\n useScopeActivity,\n} from \"@adapttable/vue/adapter\";\nimport { NCard, NPopover } from \"naive-ui\";\nimport {\n type ComponentPublicInstance,\n defineComponent,\n h,\n type PropType,\n type ShallowRef,\n shallowRef,\n watch,\n} from \"vue\";\n\nimport { naiveButton } from \"../controls/button\";\nimport { htmlRoot } from \"../controls/elementTarget\";\n\n/** One shortcut as a menu item: its icon, title and optional description. */\nfunction shortcut(\n item: TableAssistantMenuProps[\"items\"][number],\n choose: (id: string) => void\n) {\n return naiveButton(\n {\n key: item.id,\n role: \"menuitem\",\n tabindex: -1,\n \"data-adapttable-part\": item.part,\n class: \"adapttable-naive-assistant-shortcut\",\n onClick: () => choose(item.id),\n },\n [\n item.icon,\n h(\"span\", [\n h(\"strong\", item.title),\n item.description ? h(\"small\", item.description) : null,\n ]),\n ],\n { text: true }\n );\n}\n\n/** The open menu: a Naive UI card holding one menu item per shortcut. */\nfunction menuCard(\n props: TableAssistantMenuProps,\n card: ShallowRef<ComponentPublicInstance | null>,\n keydown: (event: KeyboardEvent) => void,\n choose: (id: string) => void\n) {\n const items = props.items.map((item) => shortcut(item, choose));\n return h(\n NCard,\n {\n ref: card,\n size: \"small\",\n role: \"menu\",\n \"aria-label\": props.label,\n class: \"adapttable-naive-assistant-menu\",\n contentStyle: { display: \"flex\", flexDirection: \"column\", gap: \"4px\" },\n style: { maxHeight: props.maxHeight, overflowY: \"auto\" },\n onKeydown: keydown,\n },\n { default: () => items }\n );\n}\n\n/**\n * The assistant's shortcuts in a Naive UI popover menu under its trigger.\n * The shared menu navigation moves focus; Escape and Tab close the menu and\n * Escape returns focus to the trigger.\n */\nexport const NaiveExamplesMenu = defineComponent(\n (props: TableAssistantMenuProps) => {\n const active = useScopeActivity();\n const open = shallowRef(false);\n const trigger = shallowRef<HTMLElement | null>(null);\n const card = shallowRef<ComponentPublicInstance | null>(null);\n const navigation = createMenuNavigation();\n let generation = 0;\n watch(\n [active, () => props.disabled, () => props.items, () => props.onSelect],\n () => {\n generation++;\n open.value = false;\n },\n { flush: \"sync\" }\n );\n watch(open, (expanded) => {\n navigation.reset();\n if (!expanded) return;\n scheduleTick(() => {\n const panel = card.value ? htmlRoot(card.value) : null;\n panel\n ?.querySelector<HTMLElement>('[role=\"menuitem\"]')\n ?.focus({ preventScroll: true });\n });\n });\n const close = (restore: boolean) => {\n open.value = false;\n if (restore) trigger.value?.focus({ preventScroll: true });\n };\n const keydown = (event: KeyboardEvent) => {\n const panel = event.currentTarget;\n if (!(panel instanceof HTMLElement)) return;\n const items = [\n ...panel.querySelectorAll<HTMLButtonElement>('[role=\"menuitem\"]'),\n ];\n const focusTargets: readonly (EventTarget | null | undefined)[] = items;\n const action = navigation.key(\n event,\n items.map((item) => ({\n label: item.textContent ?? \"\",\n disabled: item.disabled,\n })),\n focusTargets.indexOf(panel.ownerDocument.activeElement)\n );\n if (!action) return;\n if (action.kind !== \"close\" || action.key !== \"Tab\")\n event.preventDefault();\n event.stopPropagation();\n if (action.kind === \"close\") close(action.key === \"Escape\");\n else items[action.index]?.focus({ preventScroll: true });\n };\n return () => {\n if (!active.value) return null;\n const ticket = generation;\n const choose = (id: string) => {\n if (\n !active.value ||\n props.disabled ||\n ticket !== generation ||\n !props.items.some((item) => item.id === id)\n )\n return;\n close(false);\n props.onSelect(id);\n };\n return h(\n NPopover,\n {\n trigger: \"manual\",\n show: open.value,\n placement: \"bottom-start\",\n showArrow: false,\n raw: true,\n onClickoutside: (event: MouseEvent) => {\n if (\n event.target instanceof Node &&\n trigger.value?.contains(event.target)\n )\n return;\n close(false);\n },\n },\n {\n trigger: () =>\n naiveButton(\n {\n ref: (element: HTMLElement | null) => {\n trigger.value = element;\n },\n disabled: props.disabled,\n \"aria-label\": props.label,\n \"aria-haspopup\": \"menu\",\n \"aria-expanded\": open.value,\n title: props.label,\n class: props.className,\n \"data-adapttable-part\": props.part,\n onClick: () => {\n if (active.value && !props.disabled) open.value = !open.value;\n },\n },\n [props.icon ?? props.label]\n ),\n default: () => menuCard(props, card, keydown, choose),\n }\n );\n };\n },\n {\n name: \"NaiveExamplesMenu\",\n props: {\n label: { type: String as PropType<TableAssistantMenuProps[\"label\"]> },\n part: { type: String as PropType<TableAssistantMenuProps[\"part\"]> },\n className: {\n type: String as PropType<TableAssistantMenuProps[\"className\"]>,\n },\n icon: {\n type: [String, Number, Boolean, Array, Object] as PropType<\n TableAssistantMenuProps[\"icon\"]\n >,\n default: undefined,\n },\n disabled: {\n type: Boolean as PropType<TableAssistantMenuProps[\"disabled\"]>,\n default: undefined,\n },\n items: { type: Array as PropType<TableAssistantMenuProps[\"items\"]> },\n onSelect: {\n type: Function as PropType<TableAssistantMenuProps[\"onSelect\"]>,\n },\n maxHeight: {\n type: String as PropType<TableAssistantMenuProps[\"maxHeight\"]>,\n },\n },\n }\n);\n","import {\n type TableAssistantSheetProps,\n useScopeActivity,\n} from \"@adapttable/vue/adapter\";\nimport { NDrawer, NDrawerContent } from \"naive-ui\";\nimport { defineComponent, h, type PropType } from \"vue\";\n\n/**\n * Chrome chooses initial and return focus; NDrawer contains focus and owns\n * the portal. Escape and mask dismissal become one close request to the\n * host, and the drawer stays open until the host closes it.\n */\nexport const NaiveAssistantSheet = defineComponent(\n (props: TableAssistantSheetProps) => {\n const active = useScopeActivity();\n const requestClose = () => {\n if (active.value && props.open) props.onClose();\n };\n const keydown = (event: KeyboardEvent) => {\n if (event.key !== \"Escape\" || event.defaultPrevented || event.isComposing)\n return;\n event.preventDefault();\n event.stopPropagation();\n requestClose();\n };\n return () => {\n if (!active.value) return null;\n return h(\n NDrawer,\n {\n show: props.open,\n placement: props.dir === \"rtl\" ? \"left\" : \"right\",\n width: \"min(28rem, 100vw)\",\n autoFocus: false,\n closeOnEsc: false,\n maskClosable: false,\n role: \"dialog\",\n \"aria-modal\": \"true\",\n \"aria-label\": props.label,\n dir: props.dir,\n class: [\"adapttable-naive-assistant-sheet\", props.className],\n \"data-adapttable-part\": props.part,\n onKeydown: keydown,\n onMaskClick: requestClose,\n },\n {\n default: () =>\n h(NDrawerContent, {}, { default: () => props.children }),\n }\n );\n };\n },\n {\n name: \"NaiveAssistantSheet\",\n props: {\n label: { type: String as PropType<TableAssistantSheetProps[\"label\"]> },\n part: { type: String as PropType<TableAssistantSheetProps[\"part\"]> },\n className: {\n type: String as PropType<TableAssistantSheetProps[\"className\"]>,\n },\n dir: { type: String as PropType<TableAssistantSheetProps[\"dir\"]> },\n open: {\n type: Boolean as PropType<TableAssistantSheetProps[\"open\"]>,\n default: undefined,\n },\n onClose: {\n type: Function as PropType<TableAssistantSheetProps[\"onClose\"]>,\n },\n children: {\n type: [String, Number, Boolean, Array, Object] as PropType<\n TableAssistantSheetProps[\"children\"]\n >,\n default: undefined,\n },\n },\n }\n);\n","import type {\n ApprovalReviewSlots,\n TableAssistantSlots,\n} from \"@adapttable/vue/adapter\";\nimport { NCard, NTag } from \"naive-ui\";\nimport { h, type StyleValue, type VNodeChild } from \"vue\";\n\nimport { naiveButton } from \"../controls/button\";\nimport { naiveInput } from \"../controls/input\";\nimport { naiveSelect } from \"../controls/select\";\nimport { NaiveExamplesMenu } from \"./ExamplesMenu\";\nimport { NaiveAssistantSheet } from \"./Sheet\";\n\n/** Naive UI tag types for the assistant's status tones. */\nconst TAG_TYPE = {\n neutral: \"default\",\n busy: \"info\",\n warning: \"warning\",\n danger: \"error\",\n} as const;\n\nconst surface = (\n props: {\n readonly part: string;\n readonly label: string;\n readonly children: VNodeChild;\n readonly style?: StyleValue;\n },\n classes: readonly (string | undefined)[]\n) =>\n h(\n NCard,\n {\n size: \"small\",\n role: \"region\",\n \"data-adapttable-part\": props.part,\n \"aria-label\": props.label,\n class: classes,\n style: props.style,\n contentStyle: { display: \"flex\", flexDirection: \"column\", minHeight: 0 },\n },\n { default: () => props.children }\n );\n\nexport const naiveAssistantControls: TableAssistantSlots = {\n Button: (props) =>\n naiveButton(\n {\n \"data-adapttable-part\": props.part,\n \"aria-label\": props.label,\n \"aria-expanded\": props.expanded,\n title: props.tooltip,\n class: props.className,\n disabled: props.disabled,\n onClick: props.onClick,\n },\n [\n props.icon,\n props.iconOnly && props.icon ? null : (props.children ?? props.label),\n ],\n { size: props.part === \"assistant-launcher\" ? \"medium\" : \"small\" }\n ),\n Composer: (props) =>\n naiveInput({\n type: \"textarea\",\n value: props.value,\n themeOverrides: { placeholderColor: \"var(--n-text-color)\" },\n attrs: {\n \"data-adapttable-part\": props.part,\n \"aria-label\": props.label,\n placeholder: props.placeholder,\n class: props.className,\n disabled: props.disabled,\n rows: 1,\n onKeydown: props.onKeyDown,\n },\n onChange: props.onChange,\n }),\n Badge: (props) =>\n h(\n NTag,\n {\n \"data-adapttable-part\": props.part,\n \"data-tone\": props.tone,\n type: TAG_TYPE[props.tone],\n style: props.tone === \"warning\" ? { color: \"inherit\" } : undefined,\n size: \"small\",\n bordered: false,\n class: props.className,\n },\n { default: () => props.label }\n ),\n Panel: (props) =>\n surface(props, [\"adapttable-naive-assistant-panel\", props.className]),\n Window: (props) =>\n surface(props, [\"adapttable-naive-assistant-window\", props.className]),\n Sheet: (props) => h(NaiveAssistantSheet, { ...props, key: props.part }),\n Menu: (props) => h(NaiveExamplesMenu, props),\n LanguageChip: (props) =>\n naiveSelect({\n attrs: {\n \"data-adapttable-part\": props.part,\n \"aria-label\": props.label,\n class: props.className,\n disabled: props.disabled,\n },\n value: props.value,\n options: props.options,\n onChange: props.onChange,\n }),\n};\n\nexport const naiveApprovalControls: ApprovalReviewSlots = {\n Approve: naiveAssistantControls.Button,\n Reject: naiveAssistantControls.Button,\n Action: naiveAssistantControls.Button,\n List: (props) =>\n h(\n \"ul\",\n {\n \"data-adapttable-part\": props.part,\n \"aria-label\": props.label,\n class: [\"adapttable-naive-approval-list\", props.className],\n },\n [props.children]\n ),\n};\n","/** Optional assistant presentation; all conversation and approval state stays in the binding. */\nimport \"./assistant/assistant.css\";\n\nimport type { StaticTableFeature } from \"@adapttable/vue\";\nimport {\n AgentApprovalChrome,\n type AgentApprovalProps,\n createAdapterAgentApprovalFeature,\n createAdapterTableAssistantFeature,\n TableAssistantChrome,\n type TableAssistantProps,\n} from \"@adapttable/vue/adapter\";\nimport { useThemeVars } from \"naive-ui\";\nimport { defineComponent, h, type PropType } from \"vue\";\n\nimport {\n naiveApprovalControls,\n naiveAssistantControls,\n} from \"./assistant/controls\";\n\nexport const TableAssistant = defineComponent(\n (props: TableAssistantProps) => {\n const theme = useThemeVars();\n return () =>\n h(TableAssistantChrome, {\n ...props,\n accent: props.accent ?? theme.value.primaryColor,\n slots: naiveAssistantControls,\n });\n },\n {\n name: \"NaiveTableAssistant\",\n props: {\n assistant: { type: Object as PropType<TableAssistantProps[\"assistant\"]> },\n speech: { type: Object as PropType<TableAssistantProps[\"speech\"]> },\n open: {\n type: Boolean as PropType<TableAssistantProps[\"open\"]>,\n default: undefined,\n },\n onOpenChange: {\n type: Function as PropType<TableAssistantProps[\"onOpenChange\"]>,\n },\n presentation: {\n type: String as PropType<TableAssistantProps[\"presentation\"]>,\n },\n labels: { type: Object as PropType<TableAssistantProps[\"labels\"]> },\n accent: { type: String as PropType<TableAssistantProps[\"accent\"]> },\n receipts: {\n type: Boolean as PropType<TableAssistantProps[\"receipts\"]>,\n default: undefined,\n },\n className: { type: String as PropType<TableAssistantProps[\"className\"]> },\n launcher: {\n type: Boolean as PropType<TableAssistantProps[\"launcher\"]>,\n default: undefined,\n },\n onSettings: {\n type: Function as PropType<TableAssistantProps[\"onSettings\"]>,\n },\n boundary: {\n type: [String, Object] as PropType<TableAssistantProps[\"boundary\"]>,\n },\n note: { type: String as PropType<TableAssistantProps[\"note\"]> },\n greeting: { type: String as PropType<TableAssistantProps[\"greeting\"]> },\n avatars: { type: Object as PropType<TableAssistantProps[\"avatars\"]> },\n messageAction: {\n type: Function as PropType<TableAssistantProps[\"messageAction\"]>,\n },\n approval: { type: Object as PropType<TableAssistantProps[\"approval\"]> },\n dir: { type: String as PropType<TableAssistantProps[\"dir\"]> },\n },\n }\n);\nexport const AgentApproval = defineComponent(\n (props: AgentApprovalProps) => () =>\n h(AgentApprovalChrome, { ...props, slots: naiveApprovalControls }),\n {\n name: \"NaiveAgentApproval\",\n props: {\n pending: { type: Object as PropType<AgentApprovalProps[\"pending\"]> },\n labels: { type: Object as PropType<AgentApprovalProps[\"labels\"]> },\n className: { type: String as PropType<AgentApprovalProps[\"className\"]> },\n buttonClassName: {\n type: String as PropType<AgentApprovalProps[\"buttonClassName\"]>,\n },\n },\n }\n);\nexport function tableAssistant(): StaticTableFeature {\n return createAdapterTableAssistantFeature((props) =>\n h(TableAssistant, props)\n );\n}\nexport function agentApproval(): StaticTableFeature {\n return createAdapterAgentApprovalFeature((props) => h(AgentApproval, props));\n}\nexport type {\n AgentApprovalProps,\n TableAssistantProps,\n} from \"@adapttable/vue/adapter\";\n"],"mappings":";;;;;;;;;AAqBA,SAAS,SACP,MACA,QACA;CACA,OAAOA,eAAAA,YACL;EACE,KAAK,KAAK;EACV,MAAM;EACN,UAAU;EACV,wBAAwB,KAAK;EAC7B,OAAO;EACP,eAAe,OAAO,KAAK,EAAE;CAC/B,GACA,CACE,KAAK,OAAA,GACLC,IAAAA,EAAAA,CAAE,QAAQ,EAAA,GACRA,IAAAA,EAAAA,CAAE,UAAU,KAAK,KAAK,GACtB,KAAK,eAAA,GAAcA,IAAAA,EAAAA,CAAE,SAAS,KAAK,WAAW,IAAI,IACpD,CAAC,CACH,GACA,EAAE,MAAM,KAAK,CACf;AACF;;AAGA,SAAS,SACP,OACA,MACA,SACA,QACA;CACA,MAAM,QAAQ,MAAM,MAAM,KAAK,SAAS,SAAS,MAAM,MAAM,CAAC;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