@synnaxlabs/pluto 0.50.0 → 0.50.1
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/dist/{Animated-eavjaVoD.js → Animated-BbeJdao0.js} +2 -2
- package/dist/{Animated-DxBr38YY.js → Animated-C4xrEVd-.js} +3 -3
- package/dist/{Animated-DpzwlYqX.cjs → Animated-Dvm2k_z_.cjs} +1 -1
- package/dist/{Animated-Bm-WM4BW.cjs → Animated-umWjgTzy.cjs} +1 -1
- package/dist/{Button-Cj2hR9EM.cjs → Button-BSek5HG5.cjs} +1 -1
- package/dist/{Button-DulIBpNI.js → Button-DLtxKGH5.js} +4 -4
- package/dist/{Dialog-DJJQBUgw.cjs → Dialog-BpjxXSmw.cjs} +1 -1
- package/dist/{Dialog-CwTHvHHD.js → Dialog-BspO7uo8.js} +1 -1
- package/dist/{Haul-CofQrOeX.js → Haul-DBy-2ds_.js} +1 -1
- package/dist/{Haul-gTF4QDh3.cjs → Haul-WgPKptr9.cjs} +1 -1
- package/dist/{Items-DjAwxhhi.cjs → Items-07R286kW.cjs} +2 -2
- package/dist/{Items-B5aeU-Pt.js → Items-CX11yLMf.js} +7 -5
- package/dist/{Menu-BqfIul2o.cjs → Menu-58O-OOPJ.cjs} +1 -1
- package/dist/{Menu-Bjfeoaln.js → Menu-GBo3ayoP.js} +4 -4
- package/dist/Provider-BA3zQVbv.cjs +1 -0
- package/dist/{Provider-BoQtgQtU.js → Provider-BkxUzTWS.js} +54 -51
- package/dist/Tags-DWsEZD9t.cjs +1 -0
- package/dist/{Tags-C38F7I5z.js → Tags-V7sNuGZv.js} +41 -36
- package/dist/{Text-IFQH97iK.cjs → Text-DW5FpCk9.cjs} +1 -1
- package/dist/{Text-TzKJ38En.js → Text-XeD58Fq8.js} +444 -439
- package/dist/button.cjs +1 -1
- package/dist/button.js +1 -1
- package/dist/color.cjs +1 -1
- package/dist/color.js +1 -1
- package/dist/dialog.cjs +1 -1
- package/dist/dialog.js +1 -1
- package/dist/{eraser-DZxY0pWe.cjs → eraser-Bocga8Eb.cjs} +1 -1
- package/dist/{eraser-Bd14L_5k.js → eraser-DuAfpO0P.js} +1 -1
- package/dist/ether.cjs +1 -1
- package/dist/ether.js +6 -6
- package/dist/{external-D4rp1QBE.cjs → external-5_uHky7w.cjs} +1 -1
- package/dist/{external-6HkYP0wd.js → external-B-JsNciM.js} +4 -4
- package/dist/{external-BIW55htp.cjs → external-B9omdiDK.cjs} +1 -1
- package/dist/{external-CkwpcNCW.cjs → external-BIbdeWQE.cjs} +1 -1
- package/dist/{external-D7qXEQQM.cjs → external-BRA_zA83.cjs} +1 -1
- package/dist/{external-BWI-FZRf.cjs → external-Bjh6lsVm.cjs} +1 -1
- package/dist/{external-DPow1FDR.cjs → external-BwRkgEyo.cjs} +1 -1
- package/dist/{external-BKkDVUP_.js → external-CLQdSLv0.js} +2 -2
- package/dist/{external-CVzhqlPH.js → external-CdHyPhLI.js} +1 -1
- package/dist/{external-DKc3PiyN.js → external-Ct1k30Nd.js} +3 -3
- package/dist/{external-DlHNhR1y.cjs → external-Ct2A_YCT.cjs} +1 -1
- package/dist/{external-Bl8zTvKt.js → external-DNbIzfVy.js} +43 -42
- package/dist/{external-CUHCzUJE.cjs → external-DT82RBon.cjs} +1 -1
- package/dist/{external-gDa9Z0SY.js → external-DXWEyk9d.js} +2 -2
- package/dist/{external-BU5fnKG8.cjs → external-DojNoICL.cjs} +1 -1
- package/dist/{external-DqaHmzvp.js → external-Dp5OkGYV.js} +5 -5
- package/dist/{external-BoAcV4dI.js → external-DxmgAHkn.js} +3 -3
- package/dist/{external-DAmwuDsu.cjs → external-DyTk_hS7.cjs} +1 -1
- package/dist/{external-B0R_yw6F.cjs → external-PXU0gc_j.cjs} +1 -1
- package/dist/{external-BsdKmL37.js → external-g_vt4Lku.js} +10 -10
- package/dist/{external-DCZMzNZX.js → external-sYHm9OG8.js} +3 -3
- package/dist/{external-DrcMI5oa.js → external-xfkS0zGI.js} +8 -8
- package/dist/{fontString-BtjO8Met.js → fontString-CSWLcJcC.js} +1 -1
- package/dist/{fontString-CeR_vHX_.cjs → fontString-TocVNWmy.cjs} +1 -1
- package/dist/header.cjs +1 -1
- package/dist/header.js +1 -1
- package/dist/{hooks-Ddqh5NVY.js → hooks-BeSuo_di.js} +1 -1
- package/dist/{hooks-Dxvxse16.cjs → hooks-Eb94kuDd.cjs} +1 -1
- package/dist/index.cjs +2 -2
- package/dist/index.js +2718 -2713
- package/dist/input.cjs +1 -1
- package/dist/input.js +1 -1
- package/dist/list.cjs +1 -1
- package/dist/list.js +1 -1
- package/dist/menu.cjs +1 -1
- package/dist/menu.js +1 -1
- package/dist/pluto.css +1 -1
- package/dist/{provider-CfFukcDe.js → provider-D0K9E52u.js} +88 -79
- package/dist/{provider-BmDwHwF4.cjs → provider-DksyuJua.cjs} +6 -6
- package/dist/src/flux/list.d.ts.map +1 -1
- package/dist/src/form/useField.d.ts.map +1 -1
- package/dist/src/icon/registry.d.ts +1 -0
- package/dist/src/icon/registry.d.ts.map +1 -1
- package/dist/src/list/Frame.d.ts.map +1 -1
- package/dist/src/select/Frame.d.ts.map +1 -1
- package/dist/src/theming/aether/provider.d.ts +63 -0
- package/dist/src/theming/aether/provider.d.ts.map +1 -1
- package/dist/src/theming/base/theme.d.ts +39 -0
- package/dist/src/theming/base/theme.d.ts.map +1 -1
- package/dist/src/theming/css.d.ts.map +1 -1
- package/dist/src/tree/external.d.ts +1 -0
- package/dist/src/tree/external.d.ts.map +1 -1
- package/dist/tabs.cjs +1 -1
- package/dist/tabs.js +1 -1
- package/dist/theme.css +135 -123
- package/dist/theming.cjs +1 -1
- package/dist/theming.js +2 -2
- package/dist/tree.cjs +1 -1
- package/dist/tree.js +1 -1
- package/dist/triggers.cjs +1 -1
- package/dist/triggers.js +1 -1
- package/dist/{value-C-e017qO.js → value-BmuhX6zs.js} +3 -3
- package/dist/{value-0g5Cxim9.cjs → value-CZfzRi_x.cjs} +1 -1
- package/package.json +7 -7
- package/dist/Provider-CKROy_xK.cjs +0 -1
- package/dist/Tags-B3m_Kzbp.cjs +0 -1
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import { d as w, b as A, C as i } from "./css-BkBrZtKZ.js";
|
|
2
|
+
import { c as G, L as z } from "./Text-XeD58Fq8.js";
|
|
2
3
|
import { j as p } from "./jsx-runtime-BbD0H88J.js";
|
|
3
|
-
import { A as
|
|
4
|
-
import {
|
|
5
|
-
import
|
|
6
|
-
import "./Button-DulIBpNI.js";
|
|
4
|
+
import { A as K } from "./Animated-BbeJdao0.js";
|
|
5
|
+
import { L as U, F as Y } from "./Tags-V7sNuGZv.js";
|
|
6
|
+
import "./Button-DLtxKGH5.js";
|
|
7
7
|
import "./Box-DLO7l9hM.js";
|
|
8
|
-
import { a as
|
|
9
|
-
import "./Animated-
|
|
10
|
-
import { useMemo as
|
|
11
|
-
import { d as
|
|
12
|
-
import { b as
|
|
13
|
-
import "./Provider-
|
|
8
|
+
import { a as J } from "./Items-CX11yLMf.js";
|
|
9
|
+
import "./Animated-C4xrEVd-.js";
|
|
10
|
+
import { useMemo as Q, useCallback as g } from "react";
|
|
11
|
+
import { d as V, c as R } from "./Editable-DjQORuR1.js";
|
|
12
|
+
import { b as W } from "./types-B5-Tni3G.js";
|
|
13
|
+
import "./Provider-BkxUzTWS.js";
|
|
14
14
|
import "react-dom";
|
|
15
|
-
import "./Haul-
|
|
16
|
-
import "./provider-
|
|
17
|
-
import { b as
|
|
15
|
+
import "./Haul-DBy-2ds_.js";
|
|
16
|
+
import "./provider-D0K9E52u.js";
|
|
17
|
+
import { b as X } from "./hooks-BeSuo_di.js";
|
|
18
18
|
const T = (e, n) => n.includes(e.key), I = ({
|
|
19
19
|
nodes: e,
|
|
20
20
|
expanded: n,
|
|
@@ -38,7 +38,7 @@ const T = (e, n) => n.includes(e.key), I = ({
|
|
|
38
38
|
r.keys.push(...d), r.nodes.push(...f);
|
|
39
39
|
}
|
|
40
40
|
}), r;
|
|
41
|
-
},
|
|
41
|
+
}, Z = ({
|
|
42
42
|
tree: e,
|
|
43
43
|
destination: n,
|
|
44
44
|
keys: t
|
|
@@ -87,7 +87,7 @@ const T = (e, n) => n.includes(e.key), I = ({
|
|
|
87
87
|
...r,
|
|
88
88
|
...l.children.filter((d) => !s.includes(d.key))
|
|
89
89
|
], e;
|
|
90
|
-
},
|
|
90
|
+
}, ee = ({
|
|
91
91
|
tree: e,
|
|
92
92
|
key: n,
|
|
93
93
|
updater: t,
|
|
@@ -109,7 +109,7 @@ const T = (e, n) => n.includes(e.key), I = ({
|
|
|
109
109
|
t(r)
|
|
110
110
|
);
|
|
111
111
|
return e;
|
|
112
|
-
},
|
|
112
|
+
}, ne = ({
|
|
113
113
|
tree: e,
|
|
114
114
|
parent: n,
|
|
115
115
|
updater: t,
|
|
@@ -164,21 +164,21 @@ const T = (e, n) => n.includes(e.key), I = ({
|
|
|
164
164
|
return e.forEach((t) => {
|
|
165
165
|
n.push(t), t.children != null && n.push(...H(...t.children));
|
|
166
166
|
}), n;
|
|
167
|
-
},
|
|
167
|
+
}, te = (e, n) => {
|
|
168
168
|
const t = { keys: [], nodes: [] };
|
|
169
169
|
return e.keys.forEach((o, r) => {
|
|
170
170
|
n(o, e.nodes[r].depth) && (t.keys.push(o), t.nodes.push(e.nodes[r]));
|
|
171
171
|
}), t;
|
|
172
|
-
},
|
|
172
|
+
}, re = (e) => {
|
|
173
173
|
const n = Math.min(...e.nodes.map((t) => t.depth));
|
|
174
174
|
return e.keys.filter((t, o) => e.nodes[o].depth === n);
|
|
175
|
-
},
|
|
175
|
+
}, oe = (e, n) => {
|
|
176
176
|
const t = n.keys.findIndex((o) => o === e);
|
|
177
177
|
return n.nodes[t].depth;
|
|
178
178
|
}, O = (e, n) => {
|
|
179
179
|
const t = e.keys.findIndex((o) => o === n);
|
|
180
180
|
return e.nodes[t];
|
|
181
|
-
}, [
|
|
181
|
+
}, [se, $] = G({
|
|
182
182
|
displayName: "Tree.Context",
|
|
183
183
|
providerName: "Tree.Provider"
|
|
184
184
|
}), le = ({
|
|
@@ -190,9 +190,9 @@ const T = (e, n) => n.includes(e.key), I = ({
|
|
|
190
190
|
offsetMultiplier: s = 2.5,
|
|
191
191
|
...l
|
|
192
192
|
}) => {
|
|
193
|
-
const { index: d } = l, { expanded: f, depth: m, hasChildren: x } =
|
|
193
|
+
const { index: d } = l, { expanded: f, depth: m, hasChildren: x } = $("Tree.Item")[d];
|
|
194
194
|
return /* @__PURE__ */ p.jsxs(
|
|
195
|
-
|
|
195
|
+
U,
|
|
196
196
|
{
|
|
197
197
|
className: i(
|
|
198
198
|
i.BE("tree", "item"),
|
|
@@ -209,7 +209,7 @@ const T = (e, n) => n.includes(e.key), I = ({
|
|
|
209
209
|
...l,
|
|
210
210
|
children: [
|
|
211
211
|
x && /* @__PURE__ */ p.jsx(
|
|
212
|
-
|
|
212
|
+
K,
|
|
213
213
|
{
|
|
214
214
|
className: i.BE("tree", "expansion-indicator"),
|
|
215
215
|
enabled: f,
|
|
@@ -231,14 +231,14 @@ const T = (e, n) => n.includes(e.key), I = ({
|
|
|
231
231
|
onSelectedChange: r,
|
|
232
232
|
sort: s
|
|
233
233
|
}) => {
|
|
234
|
-
const [l, d, f] =
|
|
234
|
+
const [l, d, f] = V(t), [m, x] = W({
|
|
235
235
|
initial: [],
|
|
236
236
|
value: o,
|
|
237
237
|
onChange: r
|
|
238
|
-
}), E =
|
|
238
|
+
}), E = Q(
|
|
239
239
|
() => I({ nodes: n, expanded: l, sort: s }),
|
|
240
240
|
[n, l, s]
|
|
241
|
-
), N = R(n), S = R(E), b =
|
|
241
|
+
), N = R(n), S = R(E), b = X({ triggers: ce }), k = g(
|
|
242
242
|
(u, { clicked: c }) => {
|
|
243
243
|
if (x((h) => u.length === 0 && h.length > 0 ? h.slice(0, 1) : u), c == null || b.current.held) return;
|
|
244
244
|
const y = O(S.current, c);
|
|
@@ -248,25 +248,25 @@ const T = (e, n) => n.includes(e.key), I = ({
|
|
|
248
248
|
j === "contract" ? _ = v.filter((h) => h !== c) : _ = [...v, c], d(_), e?.({ current: _, action: j, clicked: c });
|
|
249
249
|
},
|
|
250
250
|
[e, N, d, x]
|
|
251
|
-
),
|
|
251
|
+
), B = g(
|
|
252
252
|
(u) => {
|
|
253
253
|
d((c) => A.unique([...c, u])), e?.({ current: l, action: "expand", clicked: u });
|
|
254
254
|
},
|
|
255
255
|
[d]
|
|
256
|
-
),
|
|
256
|
+
), F = g(
|
|
257
257
|
(...u) => {
|
|
258
258
|
d((c) => c.filter((y) => !u.includes(y))), u.forEach((c) => {
|
|
259
259
|
e?.({ current: l, action: "contract", clicked: c });
|
|
260
260
|
});
|
|
261
261
|
},
|
|
262
262
|
[d]
|
|
263
|
-
),
|
|
263
|
+
), q = g(() => d([]), [d]);
|
|
264
264
|
return {
|
|
265
265
|
selected: m,
|
|
266
266
|
expanded: l,
|
|
267
|
-
contract:
|
|
268
|
-
expand:
|
|
269
|
-
clearExpanded:
|
|
267
|
+
contract: F,
|
|
268
|
+
expand: B,
|
|
269
|
+
clearExpanded: q,
|
|
270
270
|
shape: E,
|
|
271
271
|
onSelect: k
|
|
272
272
|
};
|
|
@@ -288,8 +288,8 @@ const T = (e, n) => n.includes(e.key), I = ({
|
|
|
288
288
|
...b
|
|
289
289
|
}) => {
|
|
290
290
|
const { keys: k } = e;
|
|
291
|
-
return /* @__PURE__ */ p.jsx(
|
|
292
|
-
|
|
291
|
+
return /* @__PURE__ */ p.jsx(se, { value: e.nodes, children: /* @__PURE__ */ p.jsx(
|
|
292
|
+
Y,
|
|
293
293
|
{
|
|
294
294
|
multiple: !0,
|
|
295
295
|
value: t,
|
|
@@ -301,7 +301,7 @@ const T = (e, n) => n.includes(e.key), I = ({
|
|
|
301
301
|
itemHeight: 27,
|
|
302
302
|
virtual: S,
|
|
303
303
|
children: /* @__PURE__ */ p.jsx(
|
|
304
|
-
|
|
304
|
+
J,
|
|
305
305
|
{
|
|
306
306
|
full: "y",
|
|
307
307
|
className: i(i.B("tree"), l, N && i.M("show-rules")),
|
|
@@ -317,22 +317,23 @@ const T = (e, n) => n.includes(e.key), I = ({
|
|
|
317
317
|
Item: le,
|
|
318
318
|
Tree: ue,
|
|
319
319
|
deepCopy: D,
|
|
320
|
-
filterShape:
|
|
320
|
+
filterShape: te,
|
|
321
321
|
findNode: a,
|
|
322
322
|
findNodeParent: C,
|
|
323
323
|
findNodes: P,
|
|
324
324
|
flatten: I,
|
|
325
|
-
getAllNodesOfMinDepth:
|
|
326
|
-
getDepth:
|
|
325
|
+
getAllNodesOfMinDepth: re,
|
|
326
|
+
getDepth: oe,
|
|
327
327
|
getDescendants: H,
|
|
328
328
|
getNodeShape: O,
|
|
329
|
-
moveNode:
|
|
329
|
+
moveNode: Z,
|
|
330
330
|
removeNode: L,
|
|
331
331
|
setNode: M,
|
|
332
332
|
shouldExpand: T,
|
|
333
|
-
updateNode:
|
|
334
|
-
updateNodeChildren:
|
|
335
|
-
use: ie
|
|
333
|
+
updateNode: ee,
|
|
334
|
+
updateNodeChildren: ne,
|
|
335
|
+
use: ie,
|
|
336
|
+
useContext: $
|
|
336
337
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
337
338
|
export {
|
|
338
339
|
Ie as e
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const o=require("./jsx-runtime-nZSsnGb7.cjs"),e=require("./css-D3NdC2sx.cjs"),u=require("./Box-D27bV7QJ.cjs"),x=require("./Button-
|
|
1
|
+
"use strict";const o=require("./jsx-runtime-nZSsnGb7.cjs"),e=require("./css-D3NdC2sx.cjs"),u=require("./Box-D27bV7QJ.cjs"),x=require("./Button-BSek5HG5.cjs"),S=require("react"),d=require("./Text-DW5FpCk9.cjs"),m=require("./Editable-C-z-stcD.cjs"),j=require("./types-C0tUDfsz.cjs"),p=({children:s=[],...t})=>o.jsxRuntimeExports.jsx(u.Box$1,{x:!0,gap:"small",align:"center",className:e.CSS.BE("header","actions"),...t,children:s}),[C,l]=d.create({defaultValue:{divided:!1,level:"h1"},displayName:"Header.Context"}),B=({className:s,level:t="p",divided:r=!1,bordered:n=!0,padded:a=!1,...c})=>{const i=S.useMemo(()=>({level:t,divided:r}),[t,r]);return o.jsxRuntimeExports.jsx(C,{value:i,children:o.jsxRuntimeExports.jsx(u.Box$1,{el:"header",x:!0,align:"center",justify:"between",className:e.CSS(e.CSS.B("header"),n&&e.CSS.bordered("bottom"),r&&e.CSS.BM("header","divided"),a&&e.CSS.BM("header","padded"),s),...c})})},E=({children:s="",className:t,onClick:r,...n})=>{const{level:a}=l();return o.jsxRuntimeExports.jsx(x.Button,{variant:"text",size:j.LEVEL_COMPONENT_SIZES[a],onClick:r,className:e.CSS(e.CSS.B("header-button-title"),t),sharp:!0,...n,children:s})},h=({className:s,level:t,...r})=>{const{level:n}=l();return o.jsxRuntimeExports.jsx(m.Text,{className:e.CSS(e.CSS.BE("header","text"),s),level:t??n,gap:1.5,...r})},b=Object.freeze(Object.defineProperty({__proto__:null,Actions:p,ButtonTitle:E,Header:B,Title:h,useContext:l},Symbol.toStringTag,{value:"Module"}));exports.external=b;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { u as E, a as p, b as x } from "./hooks-
|
|
2
|
-
import { u as d, A as S, b as _, K as b, M as R, e as y, g as T, h as K, P as U, T as A, i as C, j as L, d as O, k as h, f as j, l as v, m as k, n as w, o as H, q as N, r as P, s as Z, t as I, p as Y, v as B, w as F, x as q, y as z } from "./Text-
|
|
1
|
+
import { u as E, a as p, b as x } from "./hooks-BeSuo_di.js";
|
|
2
|
+
import { u as d, A as S, b as _, K as b, M as R, e as y, g as T, h as K, P as U, T as A, i as C, j as L, d as O, k as h, f as j, l as v, m as k, n as w, o as H, q as N, r as P, s as Z, t as I, p as Y, v as B, w as F, x as q, y as z } from "./Text-XeD58Fq8.js";
|
|
3
3
|
import { j as G } from "./jsx-runtime-BbD0H88J.js";
|
|
4
4
|
import { useState as $, useEffect as J, useRef as f, useCallback as g } from "react";
|
|
5
5
|
import { T as Q } from "./Editable-DjQORuR1.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const r=require("./provider-
|
|
1
|
+
"use strict";const r=require("./provider-DksyuJua.cjs"),e=require("./Provider-BA3zQVbv.cjs"),n=require("./fontString-TocVNWmy.cjs"),i=o=>{const{theme:t}=e.useContext(),s=t.typography[o];return{...s,toString:()=>n.fontString(t,{level:o}),baseSize:t.sizes.base,lineHeightPx:s.lineHeight*t.sizes.base,sizePx:s.size*t.sizes.base}},S=Object.freeze(Object.defineProperty({__proto__:null,Provider:e.Provider,SYNNAX_DARK:r.SYNNAX_DARK,SYNNAX_LIGHT:r.SYNNAX_LIGHT,SYNNAX_THEMES:r.SYNNAX_THEMES,themeZ:r.themeZ,toCSSVars:e.toCSSVars,use:e.use,useContext:e.useContext,useProvider:e.useProvider,useTypography:i},Symbol.toStringTag,{value:"Module"}));exports.external=S;exports.useTypography=i;
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { j as s } from "./jsx-runtime-BbD0H88J.js";
|
|
2
2
|
import { C as r, E as y, A as $, T as z, v as G } from "./css-BkBrZtKZ.js";
|
|
3
3
|
import { useState as A, useCallback as C } from "react";
|
|
4
|
-
import { B as w } from "./Button-
|
|
4
|
+
import { B as w } from "./Button-DLtxKGH5.js";
|
|
5
5
|
import { a as B } from "./Box-DLO7l9hM.js";
|
|
6
|
-
import { c as H, z as U, B as q, D as J, E as Q, L as W } from "./Text-
|
|
7
|
-
import { a as Y, C as K } from "./Menu-
|
|
6
|
+
import { c as H, z as U, B as q, D as J, E as Q, L as W } from "./Text-XeD58Fq8.js";
|
|
7
|
+
import { a as Y, C as K } from "./Menu-GBo3ayoP.js";
|
|
8
8
|
/* empty css */
|
|
9
|
-
import { d as ee, c as te } from "./Animated-
|
|
9
|
+
import { d as ee, c as te } from "./Animated-C4xrEVd-.js";
|
|
10
10
|
import { T as ne, E as oe, c as se } from "./Editable-DjQORuR1.js";
|
|
11
11
|
import { C as k, u as le } from "./types-B5-Tni3G.js";
|
|
12
|
-
import "./Provider-
|
|
12
|
+
import "./Provider-BkxUzTWS.js";
|
|
13
13
|
import { z as p } from "zod";
|
|
14
14
|
const [re, M] = H({
|
|
15
15
|
defaultValue: { tabs: [] },
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { S as a, a as r, b as i, t as n } from "./provider-
|
|
2
|
-
import { u as o, P as S, t as p, a as u, b } from "./Provider-
|
|
3
|
-
import { f as m } from "./fontString-
|
|
1
|
+
import { S as a, a as r, b as i, t as n } from "./provider-D0K9E52u.js";
|
|
2
|
+
import { u as o, P as S, t as p, a as u, b } from "./Provider-BkxUzTWS.js";
|
|
3
|
+
import { f as m } from "./fontString-CSWLcJcC.js";
|
|
4
4
|
const g = (t) => {
|
|
5
5
|
const { theme: e } = o(), s = e.typography[t];
|
|
6
6
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const r=require("./Button-
|
|
1
|
+
"use strict";const r=require("./Button-BSek5HG5.cjs"),c=require("./jsx-runtime-nZSsnGb7.cjs"),u=({value:e,onClick:s,onChange:n,checkedVariant:i="filled",uncheckedVariant:l,rightClickToggle:o=!1,...a})=>c.jsxRuntimeExports.jsx(r.Button,{onClick:t=>{s?.(t),!o&&n(!e)},onContextMenu:t=>{o&&(t.preventDefault(),t.stopPropagation(),n(!e))},variant:e?i:l,...a}),f=Object.freeze(Object.defineProperty({__proto__:null,Button:r.Button,Toggle:u},Symbol.toStringTag,{value:"Module"}));exports.Toggle=u;exports.external=f;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const Ne=require("./jsx-runtime-nZSsnGb7.cjs"),Pn=require("./Button-Cj2hR9EM.cjs"),ve=require("./css-D3NdC2sx.cjs"),cr=require("react"),LN=require("./Provider-CKROy_xK.cjs"),ka=require("./Text-IFQH97iK.cjs"),Ys=require("./event-BxvV3arE.cjs"),ja=require("./Tags-B3m_Kzbp.cjs"),HN=require("./Dialog-DJJQBUgw.cjs"),Ub=require("./Animated-DpzwlYqX.cjs"),ir=require("./Box-D27bV7QJ.cjs"),on=require("./Editable-C-z-stcD.cjs");require("./types-C0tUDfsz.cjs");const Il=require("./Items-DjAwxhhi.cjs"),GN=require("./useStaticData-BTwIe0Il.cjs");;/* empty css */require("./eraser-DZxY0pWe.cjs");require("./Haul-gTF4QDh3.cjs");require("./provider-BmDwHwF4.cjs");const Wb=({format:e="dateTime",suppliedTZ:t="UTC",displayTZ:r="local",children:n,...a})=>Ne.jsxRuntimeExports.jsx(on.Text,{...a,children:new ve.d(n,t).toString(e,r)}),VN=(e,t,r)=>e==="preview"&&r===!0?"var(--pluto-primary-z)":t,Jb=({ref:e,className:t,value:r,ghost:n,disabled:a,onChange:i,inputType:o,size:s,variant:u="text",style:l,color:c,borderColor:f,borderWidth:m,bordered:d,rounded:h,background:p,textColor:y,onClick:w,...D})=>Ne.jsxRuntimeExports.jsx(Pn.Button,{el:"label",variant:u,className:ve.CSS(ve.CSS.BE("input",o),t),ghost:n,disabled:a,size:s,preventClick:!0,style:l,color:c,borderColor:f,borderWidth:m,bordered:d,rounded:h,background:p,textColor:VN(u,y,r),onClick:w,children:u!=="preview"?Ne.jsxRuntimeExports.jsxs(Ne.jsxRuntimeExports.Fragment,{children:[Ne.jsxRuntimeExports.jsx("input",{className:ve.CSS.BE("input",o,"input"),type:"checkbox",ref:e,checked:r,onChange:v=>{v.stopPropagation(),i?.(v.target.checked)},value:"",disabled:a,onClick:w,...D}),Ne.jsxRuntimeExports.jsx("span",{className:ve.CSS.BE("input",o,"indicator"),onClick:w})]}):r?"True":"False"}),UN=e=>Ne.jsxRuntimeExports.jsx(Jb,{...e,inputType:"checkbox"}),Kb="cursor-style",mh=(e,t=document.head)=>{Yb();const r=document.createElement("style");r.innerHTML=`*{cursor: ${e} !important;}`,r.id=Kb,t.appendChild(r)},Yb=()=>{const e=document.getElementById(Kb);e?.remove()},dh=(e,t,r,n,a)=>{const{x:i,y:o}=n??ve.Au.construct(ve.Eu.dims(a));if(ve.Eu.width(t)>i&&ve.Eu.width(t)>ve.Eu.height(t)){const s=ve.Eu.signedWidth(t)<0?i:-i;e+=(ve.Eu.signedWidth(t)+s)*r.x,mh("ew-resize")}if(ve.Eu.height(t)>o&&ve.Eu.height(t)>ve.Eu.width(t)){const s=ve.Eu.signedHeight(t)<0?o:-o;e+=(ve.Eu.signedHeight(t)+s)*r.y,mh("ns-resize")}return e},vc=({direction:e,className:t,dragScale:r={x:10,y:1},dragThreshold:n=15,dragDirection:a,onChange:i,value:o,resetValue:s,onDragEnd:u,...l})=>{const c=cr.useRef({dragging:!1,curr:o,prev:o}),f=cr.useRef(null);c.current.dragging||(c.current.prev=o);const m=cr.useMemo(()=>{const p=ve.Au.construct(r);return a==="x"?ve.Au.construct(p.x,0):a==="y"?ve.Au.construct(0,p.y):p},[r,a]),d=cr.useMemo(()=>n!=null?ve.Au.construct(n):null,[n]);LN.useVirtualCursorDragWebKit({ref:f,onMove:cr.useCallback(p=>{if(f.current==null)return;let y=c.current.prev;c.current.dragging=!0,y=dh(y,p,m,d,ve.Eu.construct(f.current)),c.current.curr=y,i(y)},[i,m,d]),onEnd:cr.useCallback((p,y)=>{if(f.current==null)return;let w=c.current.prev;w=dh(w,p,m,d,ve.Eu.construct(f.current)),c.current.prev=w,c.current.dragging=!1,Yb(),u?.(w),l.onBlur?.()},[l.onBlur,u,m,d])});const h=cr.useCallback(()=>{i(s??c.current.prev)},[i,s]);return Ne.jsxRuntimeExports.jsx(Pn.Button,{ref:f,variant:"outlined",className:ve.CSS(ve.CSS.BE("input","drag-btn"),e!=null&&ve.CSS.BEM("input","drag-btn","direction",e),t),tabIndex:-1,onDoubleClick:h,onClick:Ys.preventDefault,contrast:0,textColor:9,...l,children:Ne.jsxRuntimeExports.jsx(ka.Drag,{})})},WN={x:Number(ve.d.HOUR.valueOf()),y:Number(ve.d.days(.75).valueOf())},Zb=({value:e,onChange:t})=>{const r=new ve.d(e,"UTC");cr.useLayoutEffect(()=>{const i=r.sub(ve.d.utcOffset);if(i.remainder(ve.d.DAY).isZero)return;const o=i.sub(i.remainder(ve.d.DAY));t(Number(new ve.d(o,"local").valueOf()))},[e]);const n=i=>{let o;if(typeof i=="number")o=new ve.d(i,"UTC");else{if(i.length===0)return;o=new ve.d(i,"local")}t(Number(o.valueOf()))};return{value:r.toString("ISODate","local"),onChange:n}},JN=({ref:e,onChange:t,value:r,className:n,showDragHandle:a=!0,children:i,...o})=>{const{value:s,onChange:u}=Zb({value:r,onChange:t});return Ne.jsxRuntimeExports.jsxs(ja.Text,{ref:e,value:s,className:ve.CSS(ve.CSS.B("input-date"),n),onChange:u,type:"date",...o,children:[a&&Ne.jsxRuntimeExports.jsx(vc,{value:r,onChange:u,dragScale:WN}),i]})},KN={one:{},two:{},three:{},four:{}},YN={one:{},two:{},three:{}},ZN={},QN=[],Yf={methods:KN,model:YN,compute:ZN,hooks:QN},XN=e=>Object.prototype.toString.call(e)==="[object Array]",eA={compute:function(e){const{world:t}=this,r=t.compute;return typeof e=="string"&&r.hasOwnProperty(e)?r[e](this):XN(e)?e.forEach(n=>{t.compute.hasOwnProperty(n)?r[n](this):console.warn("no compute:",e)}):typeof e=="function"?e(this):console.warn("no compute:",e),this}},tA=function(e){return this.fullPointer.forEach((r,n)=>{const a=this.update([r]);e(a,n)}),this},rA=function(e,t){const n=this.fullPointer.map((i,o)=>{const s=this.update([i]),u=e(s,o);return u===void 0?this.none():u});if(n.length===0)return t||this.update([]);if(n[0]!==void 0&&(typeof n[0]=="string"||typeof n[0]=="object"&&(n[0]===null||!n[0].isView)))return n;let a=[];return n.forEach(i=>{a=a.concat(i.fullPointer)}),this.toView(a)},nA=function(e){let t=this.fullPointer;return t=t.filter((n,a)=>{const i=this.update([n]);return e(i,a)}),this.update(t)},aA=function(e){const r=this.fullPointer.find((n,a)=>{const i=this.update([n]);return e(i,a)});return this.update([r])},iA=function(e){return this.fullPointer.some((r,n)=>{const a=this.update([r]);return e(a,n)})},oA=function(e=1){let t=this.fullPointer,r=Math.floor(Math.random()*t.length);return r+e>this.length&&(r=this.length-e,r=r<0?0:r),t=t.slice(r,r+e),this.update(t)},sA={forEach:tA,map:rA,filter:nA,find:aA,some:iA,random:oA},Zn={termList:function(){return this.methods.one.termList(this.docs)},terms:function(e){const t=this.match(".");return typeof e=="number"?t.eq(e):t},groups:function(e){if(e||e===0)return this.update(this._groups[e]||[]);const t={};return Object.keys(this._groups).forEach(r=>{t[r]=this.update(this._groups[r])}),t},eq:function(e){let t=this.pointer;return t||(t=this.docs.map((r,n)=>[n])),t[e]?this.update([t[e]]):this.none()},first:function(){return this.eq(0)},last:function(){const e=this.fullPointer.length-1;return this.eq(e)},firstTerms:function(){return this.match("^.")},lastTerms:function(){return this.match(".$")},slice:function(e,t){let r=this.pointer||this.docs.map((n,a)=>[a]);return r=r.slice(e,t),this.update(r)},all:function(){return this.update().toView()},fullSentences:function(){const e=this.fullPointer.map(t=>[t[0]]);return this.update(e).toView()},none:function(){return this.update([])},isDoc:function(e){if(!e||!e.isView)return!1;const t=this.fullPointer,r=e.fullPointer;return!t.length===r.length?!1:t.every((n,a)=>r[a]?n[0]===r[a][0]&&n[1]===r[a][1]&&n[2]===r[a][2]:!1)},wordCount:function(){return this.docs.reduce((e,t)=>(e+=t.filter(r=>r.text!=="").length,e),0)},isFull:function(){const e=this.pointer;if(!e)return!0;if(e.length===0||e[0][0]!==0)return!1;let t=0,r=0;return this.document.forEach(n=>t+=n.length),this.docs.forEach(n=>r+=n.length),t===r},getNth:function(e){return typeof e=="number"?this.eq(e):typeof e=="string"?this.if(e):this}};Zn.group=Zn.groups;Zn.fullSentence=Zn.fullSentences;Zn.sentence=Zn.fullSentences;Zn.lastTerm=Zn.lastTerms;Zn.firstTerm=Zn.firstTerms;const Zf=Object.assign({},Zn,eA,sA);Zf.get=Zf.eq;class si{constructor(t,r,n={}){[["document",t],["world",Yf],["_groups",n],["_cache",null],["viewType","View"]].forEach(i=>{Object.defineProperty(this,i[0],{value:i[1],writable:!0})}),this.ptrs=r}get docs(){let t=this.document;return this.ptrs&&(t=Yf.methods.one.getDoc(this.ptrs,this.document)),t}get pointer(){return this.ptrs}get methods(){return this.world.methods}get model(){return this.world.model}get hooks(){return this.world.hooks}get isView(){return!0}get found(){return this.docs.length>0}get length(){return this.docs.length}get fullPointer(){const{docs:t,ptrs:r,document:n}=this;return(r||t.map((i,o)=>[o])).map(i=>{let[o,s,u,l,c]=i;return s=s||0,u=u||(n[o]||[]).length,n[o]&&n[o][s]&&(l=l||n[o][s].id,n[o][u-1]&&(c=c||n[o][u-1].id)),[o,s,u,l,c]})}update(t){const r=new si(this.document,t);if(this._cache&&t&&t.length>0){const n=[];t.forEach((a,i)=>{const[o,s,u]=a;a.length===1?n[i]=this._cache[o]:s===0&&this.document[o].length===u&&(n[i]=this._cache[o])}),n.length>0&&(r._cache=n)}return r.world=this.world,r}toView(t){return new si(this.document,t||this.pointer)}fromText(t){const{methods:r}=this,n=r.one.tokenize.fromString(t,this.world),a=new si(n);return a.world=this.world,a.compute(["normal","freeze","lexicon"]),this.world.compute.preTagger&&a.compute("preTagger"),a.compute("unfreeze"),a}clone(){let t=this.document.slice(0);t=t.map(n=>n.map(a=>(a=Object.assign({},a),a.tags=new Set(a.tags),a)));const r=this.update(this.pointer);return r.document=t,r._cache=this._cache,r}}Object.assign(si.prototype,Zf);const uA="14.14.5",hh=function(e){return e&&typeof e=="object"&&!Array.isArray(e)},lA=function(e){return Object.prototype.toString.call(e)==="[object Array]"};function Qb(e,t){if(hh(t))for(const r in t)hh(t[r])?(e[r]||Object.assign(e,{[r]:{}}),Qb(e[r],t[r])):Object.assign(e,{[r]:t[r]});return e}function cA(e,t){for(const r in t)e[r]=e[r]||{},Object.assign(e[r],t[r]);return e}const fA=function(e,t){const r=e.two.models||{};Object.keys(t).forEach(n=>{t[n].pastTense&&(r.toPast&&(r.toPast.ex[n]=t[n].pastTense),r.fromPast&&(r.fromPast.ex[t[n].pastTense]=n)),t[n].presentTense&&(r.toPresent&&(r.toPresent.ex[n]=t[n].presentTense),r.fromPresent&&(r.fromPresent.ex[t[n].presentTense]=n)),t[n].gerund&&(r.toGerund&&(r.toGerund.ex[n]=t[n].gerund),r.fromGerund&&(r.fromGerund.ex[t[n].gerund]=n)),t[n].comparative&&(r.toComparative&&(r.toComparative.ex[n]=t[n].comparative),r.fromComparative&&(r.fromComparative.ex[t[n].comparative]=n)),t[n].superlative&&(r.toSuperlative&&(r.toSuperlative.ex[n]=t[n].superlative),r.fromSuperlative&&(r.fromSuperlative.ex[t[n].superlative]=n))})},Xb=function(e,t,r,n){if(lA(e)){e.forEach(u=>Xb(u,t,r,n));return}const{methods:a,model:i,compute:o,hooks:s}=t;e.methods&&cA(a,e.methods),e.model&&Qb(i,e.model),e.irregulars&&fA(i,e.irregulars),e.compute&&Object.assign(o,e.compute),s&&(t.hooks=s.concat(e.hooks||[])),e.api&&e.api(r),e.lib&&Object.keys(e.lib).forEach(u=>n[u]=e.lib[u]),e.tags&&n.addTags(e.tags),e.words&&n.addWords(e.words),e.frozen&&n.addWords(e.frozen,!0),e.mutate&&e.mutate(t,n)},mA=function(e){const t=typeof process>"u"||!process.env?self.env||{}:process.env;return t.DEBUG_TAGS=e==="tagger"||e===!0?!0:"",t.DEBUG_MATCH=e==="match"||e===!0?!0:"",t.DEBUG_CHUNKS=e==="chunker"||e===!0?!0:"",this},dA=e=>Object.prototype.toString.call(e)==="[object Object]",Qf=function(e){return Object.prototype.toString.call(e)==="[object Array]"},hA=function(e){return e.map(t=>t.terms.map(r=>(Qf(r.tags)&&(r.tags=new Set(r.tags)),r)))},pA=function(e){return e.map(t=>t.map(r=>({text:r,normal:r,pre:"",post:" ",tags:new Set})))},ew=function(e,t,r){const{methods:n}=r,a=new t([]);if(a.world=r,typeof e=="number"&&(e=String(e)),!e)return a;if(typeof e=="string"){const i=n.one.tokenize.fromString(e,r);return new t(i)}if(dA(e)&&e.isView)return new t(e.document,e.ptrs);if(Qf(e)){if(Qf(e[0])){const o=pA(e);return new t(o)}const i=hA(e);return new t(i)}return a},zl=Object.assign({},Yf),tt=function(e,t){t&&tt.addWords(t);const r=ew(e,si,zl);return e&&r.compute(zl.hooks),r};Object.defineProperty(tt,"_world",{value:zl,writable:!0});tt.tokenize=function(e,t){const{compute:r}=this._world;t&&tt.addWords(t);const n=ew(e,si,zl);return r.contractions&&n.compute(["alias","normal","machine","contractions"]),n};tt.plugin=function(e){return Xb(e,this._world,si,this),this};tt.extend=tt.plugin;tt.world=function(){return this._world};tt.model=function(){return this._world.model};tt.methods=function(){return this._world.methods};tt.hooks=function(){return this._world.hooks};tt.verbose=mA;tt.version=uA;const gA=function(e){return e.map(r=>{const n=new Set;return r.forEach(a=>{a.normal!==""&&n.add(a.normal),a.switch&&n.add(`%${a.switch}%`),a.implicit&&n.add(a.implicit),a.machine&&n.add(a.machine),a.root&&n.add(a.root),a.alias&&a.alias.forEach(o=>n.add(o));const i=Array.from(a.tags);for(let o=0;o<i.length;o+=1)n.add("#"+i[o])}),n})},vA={one:{cacheDoc:gA}},yA={cache:function(){return this._cache=this.methods.one.cacheDoc(this.document),this},uncache:function(){return this._cache=null,this}},bA=function(e){Object.assign(e.prototype,yA)},wA={cache:function(e){e._cache=e.methods.one.cacheDoc(e.document)}},xA={api:bA,compute:wA,methods:vA},DA={toLowerCase:function(){return this.termList().forEach(e=>{e.text=e.text.toLowerCase()}),this},toUpperCase:function(){return this.termList().forEach(e=>{e.text=e.text.toUpperCase()}),this},toTitleCase:function(){return this.termList().forEach(e=>{e.text=e.text.replace(/^ *[a-z\u00C0-\u00FF]/,t=>t.toUpperCase())}),this},toCamelCase:function(){return this.docs.forEach(e=>{e.forEach((t,r)=>{r!==0&&(t.text=t.text.replace(/^ *[a-z\u00C0-\u00FF]/,n=>n.toUpperCase())),r!==e.length-1&&(t.post="")})}),this}},ph=e=>new RegExp("^\\p{Lu}[\\p{Ll}'’]","u").test(e)||new RegExp("^\\p{Lu}$","u").test(e),NA=e=>e.replace(new RegExp("^\\p{Ll}","u"),t=>t.toUpperCase()),AA=e=>e.replace(new RegExp("^\\p{Lu}","u"),t=>t.toLowerCase()),tw=(e,t,r)=>{if(r.forEach(n=>n.dirty=!0),e){const n=[t,0].concat(r);Array.prototype.splice.apply(e,n)}return e},$o=function(e){const t=/ $/,r=/[-–—]/,n=e[e.length-1];n&&!t.test(n.post)&&!r.test(n.post)&&(n.post+=" ")},gh=(e,t,r)=>{const n=/[-.?!,;:)–—'"]/g,a=e[t-1];if(!a)return;const i=a.post;if(n.test(i)){const o=i.match(n).join(""),s=r[r.length-1];s.post=o+s.post,a.post=a.post.replace(n,"")}},CA=function(e,t,r){const n=e[t];if(t!==0||!ph(n.text))return;r[0].text=NA(r[0].text);const a=e[t];a.tags.has("ProperNoun")||a.tags.has("Acronym")||ph(a.text)&&a.text.length>1&&(a.text=AA(a.text))},EA=function(e,t,r,n){const[a,i,o]=t;i===0||o===n[a].length?$o(r):($o(r),$o([e[t[1]]])),CA(e,i,r),tw(e,i,r)},SA=function(e,t,r,n){const[a,,i]=t,o=(n[a]||[]).length;i<o?(gh(e,i,r),$o(r)):o===i&&($o(e),gh(e,i,r),n[a+1]&&(r[r.length-1].post+=" ")),tw(e,t[2],r),t[4]=r[r.length-1].id};let gs=0;const vh=e=>(e=e.length<3?"0"+e:e,e.length<3?"0"+e:e),rw=function(e){let[t,r]=e.index||[0,0];gs+=1,gs=gs>46655?0:gs,t=t>46655?0:t,r=r>1294?0:r;let n=vh(gs.toString(36));n+=vh(t.toString(36));let a=r.toString(36);a=a.length<2?"0"+a:a,n+=a;const i=parseInt(Math.random()*36,10);return n+=i.toString(36),e.normal+"|"+n.toUpperCase()},yh=function(e){e.has("@hasContraction")&&typeof e.contractions=="function"&&e.grow("@hasContraction").contractions().expand()},bh=e=>Object.prototype.toString.call(e)==="[object Array]",MA=function(e){return e=e.map(t=>(t.id=rw(t),t)),e},TA=function(e,t){const{methods:r}=t;return typeof e=="string"?r.one.tokenize.fromString(e,t)[0]:typeof e=="object"&&e.isView?e.clone().docs[0]||[]:bh(e)?bh(e[0])?e[0]:e:[]},wh=function(e,t,r){const{document:n,world:a}=t;t.uncache();const i=t.fullPointer,o=t.fullPointer;t.forEach((u,l)=>{const c=u.fullPointer[0],[f]=c,m=n[f];let d=TA(e,a);d.length!==0&&(d=MA(d),r?(yh(t.update([c]).firstTerm()),EA(m,c,d,n)):(yh(t.update([c]).lastTerm()),SA(m,c,d,n)),n[f]&&n[f][c[1]]&&(c[3]=n[f][c[1]].id),o[l]=c,c[2]+=d.length,i[l]=c)});const s=t.toView(i);return t.ptrs=o,s.compute(["id","index","freeze","lexicon"]),s.world.compute.preTagger&&s.compute("preTagger"),s.compute("unfreeze"),s},Yi={insertAfter:function(e){return wh(e,this,!1)},insertBefore:function(e){return wh(e,this,!0)}};Yi.append=Yi.insertAfter;Yi.prepend=Yi.insertBefore;Yi.insert=Yi.insertAfter;const FA=/\$[0-9a-z]+/g,od={},PA=e=>new RegExp("^\\p{Lu}[\\p{Ll}'’]","u").test(e)||new RegExp("^\\p{Lu}$","u").test(e),kA=e=>e.replace(new RegExp("^\\p{Ll}","u"),t=>t.toUpperCase()),OA=e=>e.replace(new RegExp("^\\p{Lu}","u"),t=>t.toLowerCase()),$A=function(e,t,r){return e.forEach(n=>{const a=t(n);n.replaceWith(a,r)}),e},BA=function(e,t){if(typeof e!="string")return e;const r=t.groups();return e=e.replace(FA,n=>{const a=n.replace(/\$/,"");return r.hasOwnProperty(a)?r[a].text():n}),e};od.replaceWith=function(e,t={}){let r=this.fullPointer;const n=this;if(this.uncache(),typeof e=="function")return $A(n,e,t);const a=n.docs[0];if(!a)return n;const i=t.possessives&&a[a.length-1].tags.has("Possessive"),o=t.case&&PA(a[0].text);e=BA(e,n);const s=this.update(r);r=r.map(m=>m.slice(0,3));const u=(s.docs[0]||[]).map(m=>Array.from(m.tags)),l=s.docs[0][0].pre,c=s.docs[0][s.docs[0].length-1].post;if(typeof e=="string"&&(e=this.fromText(e).compute("id")),n.insertAfter(e),s.has("@hasContraction")&&n.contractions&&n.grow("@hasContraction+").contractions().expand(),n.delete(s),i){const m=n.docs[0],d=m[m.length-1];d.tags.has("Possessive")||(d.text+="'s",d.normal+="'s",d.tags.add("Possessive"))}if(l&&n.docs[0]&&(n.docs[0][0].pre=l),c&&n.docs[0]){const m=n.docs[0][n.docs[0].length-1];m.post.trim()||(m.post=c)}const f=n.toView(r).compute(["index","freeze","lexicon"]);if(f.world.compute.preTagger&&f.compute("preTagger"),f.compute("unfreeze"),t.tags&&f.terms().forEach((m,d)=>{m.tagSafe(u[d])}),!f.docs[0]||!f.docs[0][0])return f;if(t.case){const m=o?kA:OA;f.docs[0][0].text=m(f.docs[0][0].text)}return f};od.replace=function(e,t,r){if(e&&!t)return this.replaceWith(e,r);const n=this.match(e);return n.found?(this.soften(),n.replaceWith(t,r)):this};const _A=function(e,t){const r=e.length-1,n=e[r],a=e[r-t];a&&n&&(a.post+=n.post,a.post=a.post.replace(/ +([.?!,;:])/,"$1"),a.post=a.post.replace(/[,;:]+([.?!])/,"$1"))},IA=function(e,t){t.forEach(r=>{const[n,a,i]=r,o=i-a;e[n]&&(i===e[n].length&&i>1&&_A(e[n],o),e[n].splice(a,o))});for(let r=e.length-1;r>=0;r-=1)if(e[r].length===0&&(e.splice(r,1),r===e.length&&e[r-1])){const n=e[r-1],a=n[n.length-1];a&&(a.post=a.post.trimEnd())}return e},zA=function(e,t){return e=e.map(r=>{const[n]=r;return t[n]&&t[n].forEach(a=>{const i=a[2]-a[1];r[1]<=a[1]&&r[2]>=a[2]&&(r[2]-=i)}),r}),e.forEach((r,n)=>{if(r[1]===0&&r[2]==0)for(let a=n+1;a<e.length;a+=1)e[a][0]-=1,e[a][0]<0&&(e[a][0]=0)}),e=e.filter(r=>r[2]-r[1]>0),e=e.map(r=>(r[3]=null,r[4]=null,r)),e},Xf={remove:function(e){const{indexN:t}=this.methods.one.pointer;this.uncache();let r=this.all(),n=this;e&&(r=this,n=this.match(e));const a=!r.ptrs;n.has("@hasContraction")&&n.contractions&&n.grow("@hasContraction").contractions().expand();let i=r.fullPointer;const o=n.fullPointer.reverse(),s=IA(this.document,o),u=t(o);return i=zA(i,u),r.ptrs=i,r.document=s,r.compute("index"),a&&(r.ptrs=void 0),e?r.toView(i):(this.ptrs=[],r.none())}};Xf.delete=Xf.remove;const Is={pre:function(e,t){return e===void 0&&this.found?this.docs[0][0].pre:(this.docs.forEach(r=>{const n=r[0];t===!0?n.pre+=e:n.pre=e}),this)},post:function(e,t){if(e===void 0){const r=this.docs[this.docs.length-1];return r[r.length-1].post}return this.docs.forEach(r=>{const n=r[r.length-1];t===!0?n.post+=e:n.post=e}),this},trim:function(){if(!this.found)return this;const e=this.docs,t=e[0][0];t.pre=t.pre.trimStart();const r=e[e.length-1],n=r[r.length-1];return n.post=n.post.trimEnd(),this},hyphenate:function(){return this.docs.forEach(e=>{e.forEach((t,r)=>{r!==0&&(t.pre=""),e[r+1]&&(t.post="-")})}),this},dehyphenate:function(){const e=/[-–—]/;return this.docs.forEach(t=>{t.forEach(r=>{e.test(r.post)&&(r.post=" ")})}),this},toQuotations:function(e,t){return e=e||'"',t=t||'"',this.docs.forEach(r=>{r[0].pre=e+r[0].pre;const n=r[r.length-1];n.post=t+n.post}),this},toParentheses:function(e,t){return e=e||"(",t=t||")",this.docs.forEach(r=>{r[0].pre=e+r[0].pre;const n=r[r.length-1];n.post=t+n.post}),this}};Is.deHyphenate=Is.dehyphenate;Is.toQuotation=Is.toQuotations;const jA=(e,t)=>e.normal<t.normal?-1:e.normal>t.normal?1:0,qA=(e,t)=>{const r=e.normal.trim().length,n=t.normal.trim().length;return r<n?1:r>n?-1:0},RA=(e,t)=>e.words<t.words?1:e.words>t.words?-1:0,LA=(e,t)=>e[0]<t[0]?1:e[0]>t[0]?-1:e[1]>t[1]?1:-1,HA=function(e){const t={};return e.forEach(r=>{t[r.normal]=t[r.normal]||0,t[r.normal]+=1}),e.sort((r,n)=>{const a=t[r.normal],i=t[n.normal];return a<i?1:a>i?-1:0}),e},Uc={alpha:jA,length:qA,wordCount:RA,sequential:LA,byFreq:HA},GA=new Set(["index","sequence","seq","sequential","chron","chronological"]),VA=new Set(["freq","frequency","topk","repeats"]),UA=new Set(["alpha","alphabetical"]),WA=function(e,t){let r=e.fullPointer;return r=r.sort((n,a)=>(n=e.update([n]),a=e.update([a]),t(n,a))),e.ptrs=r,e},JA=function(e){const{docs:t,pointer:r}=this;if(this.uncache(),typeof e=="function")return WA(this,e);e=e||"alpha";const n=r||t.map((i,o)=>[o]);let a=t.map((i,o)=>({index:o,words:i.length,normal:i.map(s=>s.machine||s.normal||"").join(" "),pointer:n[o]}));return GA.has(e)&&(e="sequential"),UA.has(e)&&(e="alpha"),VA.has(e)?(a=Uc.byFreq(a),this.update(a.map(i=>i.pointer))):typeof Uc[e]=="function"?(a=a.sort(Uc[e]),this.update(a.map(i=>i.pointer))):this},KA=function(){let e=this.pointer||this.docs.map((t,r)=>[r]);return e=[].concat(e),e=e.reverse(),this._cache&&(this._cache=this._cache.reverse()),this.update(e)},YA=function(){const e=new Set;return this.filter(r=>{const n=r.text("machine");return e.has(n)?!1:(e.add(n),!0)})},ZA={unique:YA,reverse:KA,sort:JA},QA=e=>Object.prototype.toString.call(e)==="[object Array]",nw=function(e,t){if(e.length>0){const r=e[e.length-1],n=r[r.length-1];/ /.test(n.post)===!1&&(n.post+=" ")}return e=e.concat(t),e},XA=function(e,t){if(e.document===t.document){const n=e.fullPointer.concat(t.fullPointer);return e.toView(n).compute("index")}return t.fullPointer.forEach(n=>{n[0]+=e.document.length}),e.document=nw(e.document,t.docs),e.all()},e3={concat:function(e){if(typeof e=="string"){const t=this.fromText(e);if(!this.found||!this.ptrs)this.document=this.document.concat(t.document);else{const r=this.fullPointer,n=r[r.length-1][0];this.document.splice(n,0,...t.document)}return this.all().compute("index")}if(typeof e=="object"&&e.isView)return XA(this,e);if(QA(e)){const t=nw(this.document,e);return this.document=t,this.all()}return this}},t3=function(){return this.ptrs=this.fullPointer,this},r3=function(){let e=this.ptrs;return!e||e.length<1?this:(e=e.map(t=>t.slice(0,3)),this.ptrs=e,this)},n3={harden:t3,soften:r3},a3=Object.assign({},DA,Yi,od,Xf,Is,ZA,e3,n3),i3=function(e){Object.assign(e.prototype,a3)},o3={id:function(e){const t=e.docs;for(let r=0;r<t.length;r+=1)for(let n=0;n<t[r].length;n+=1){const a=t[r][n];a.id=a.id||rw(a)}}},s3={api:i3,compute:o3},u3=[{word:"@",out:["at"]},{word:"arent",out:["are","not"]},{word:"alot",out:["a","lot"]},{word:"brb",out:["be","right","back"]},{word:"cannot",out:["can","not"]},{word:"dun",out:["do","not"]},{word:"can't",out:["can","not"]},{word:"shan't",out:["should","not"]},{word:"won't",out:["will","not"]},{word:"that's",out:["that","is"]},{word:"what's",out:["what","is"]},{word:"let's",out:["let","us"]},{word:"dunno",out:["do","not","know"]},{word:"gonna",out:["going","to"]},{word:"gotta",out:["have","got","to"]},{word:"gimme",out:["give","me"]},{word:"outta",out:["out","of"]},{word:"tryna",out:["trying","to"]},{word:"gtg",out:["got","to","go"]},{word:"im",out:["i","am"]},{word:"imma",out:["I","will"]},{word:"imo",out:["in","my","opinion"]},{word:"irl",out:["in","real","life"]},{word:"ive",out:["i","have"]},{word:"rn",out:["right","now"]},{word:"tbh",out:["to","be","honest"]},{word:"wanna",out:["want","to"]},{word:"c'mere",out:["come","here"]},{word:"c'mon",out:["come","on"]},{word:"shoulda",out:["should","have"]},{word:"coulda",out:["coulda","have"]},{word:"woulda",out:["woulda","have"]},{word:"musta",out:["must","have"]},{word:"tis",out:["it","is"]},{word:"twas",out:["it","was"]},{word:"y'know",out:["you","know"]},{word:"ne'er",out:["never"]},{word:"o'er",out:["over"]},{after:"ll",out:["will"]},{after:"ve",out:["have"]},{after:"re",out:["are"]},{after:"m",out:["am"]},{before:"c",out:["ce"]},{before:"m",out:["me"]},{before:"n",out:["ne"]},{before:"qu",out:["que"]},{before:"s",out:["se"]},{before:"t",out:["tu"]},{word:"shouldnt",out:["should","not"]},{word:"couldnt",out:["could","not"]},{word:"wouldnt",out:["would","not"]},{word:"hasnt",out:["has","not"]},{word:"wasnt",out:["was","not"]},{word:"isnt",out:["is","not"]},{word:"cant",out:["can","not"]},{word:"dont",out:["do","not"]},{word:"wont",out:["will","not"]},{word:"howd",out:["how","did"]},{word:"whatd",out:["what","did"]},{word:"whend",out:["when","did"]},{word:"whered",out:["where","did"]}],ln=!0,l3={st:ln,nd:ln,rd:ln,th:ln,am:ln,pm:ln,max:ln,"°":ln,s:ln,e:ln,er:ln,ère:ln,ème:ln},c3={one:{contractions:u3,numberSuffixes:l3}},Wc=function(e,t,r){const[n,a]=t;!r||r.length===0||(r=r.map((i,o)=>(i.implicit=i.text,i.machine=i.text,i.pre="",i.post="",i.text="",i.normal="",i.index=[n,a+o],i)),r[0]&&(r[0].pre=e[n][a].pre,r[r.length-1].post=e[n][a].post,r[0].text=e[n][a].text,r[0].normal=e[n][a].normal),e[n].splice(a,1,...r))},f3=/'/,m3=new Set(["what","how","when","where","why"]),d3=new Set(["be","go","start","think","need"]),h3=new Set(["been","gone"]),p3=function(e,t){const r=e[t].normal.split(f3)[0];if(m3.has(r))return[r,"did"];if(e[t+1]){if(h3.has(e[t+1].normal))return[r,"had"];if(d3.has(e[t+1].normal))return[r,"would"]}return null},g3=function(e,t){return e[t].normal==="ain't"||e[t].normal==="aint"?null:[e[t].normal.replace(/n't/,""),"not"]},sd=/'/,v3=/(e|é|aison|sion|tion)$/,y3=/(age|isme|acle|ege|oire)$/,b3=(e,t)=>{const r=e[t].normal.split(sd)[1];return r&&r.endsWith("e")?["la",r]:["le",r]},w3=(e,t)=>{const r=e[t].normal.split(sd)[1];return r&&v3.test(r)&&!y3.test(r)?["du",r]:r&&r.endsWith("s")?["des",r]:["de",r]},x3=(e,t)=>["je",e[t].normal.split(sd)[1]],Jc={preJ:x3,preL:b3,preD:w3},D3=/^([0-9.]{1,4}[a-z]{0,2}) ?[-–—] ?([0-9]{1,4}[a-z]{0,2})$/i,N3=/^([0-9]{1,2}(:[0-9][0-9])?(am|pm)?) ?[-–—] ?([0-9]{1,2}(:[0-9][0-9])?(am|pm)?)$/i,A3=/^[0-9]{3}-[0-9]{4}$/,C3=function(e,t){const r=e[t];let n=r.text.match(D3);return n!==null?r.tags.has("PhoneNumber")===!0||A3.test(r.text)?null:[n[1],"to",n[2]]:(n=r.text.match(N3),n!==null?[n[1],"to",n[4]]:null)},E3=/^([+-]?[0-9][.,0-9]*)([a-z°²³µ/]+)$/,S3=function(e,t,r){const n=r.model.one.numberSuffixes||{},i=e[t].text.match(E3);if(i!==null){const o=i[2].toLowerCase().trim();return n.hasOwnProperty(o)?null:[i[1],o]}return null},xh=/'/,M3=/^[0-9][^-–—]*[-–—].*?[0-9]/,Dh=function(e,t,r,n){const a=t.update();a.document=[e];let i=r+n;r>0&&(r-=1),e[i]&&(i+=1),a.ptrs=[[0,r,i]]},Nh={t:(e,t)=>g3(e,t),d:(e,t)=>p3(e,t)},Ah={j:(e,t)=>Jc.preJ(e,t),l:(e,t)=>Jc.preL(e,t),d:(e,t)=>Jc.preD(e,t)},T3=function(e,t,r,n){for(let a=0;a<e.length;a+=1){const i=e[a];if(i.word===t.normal)return i.out;if(n!==null&&n===i.after)return[r].concat(i.out);if(r!==null&&r===i.before&&n&&n.length>2)return i.out.concat(n)}return null},Kc=function(e,t){const r=t.fromText(e.join(" "));return r.compute(["id","alias"]),r.docs[0]},F3=function(e,t){for(let r=t+1;r<5&&e[r];r+=1)if(e[r].normal==="been")return["there","has"];return["there","is"]},P3=e=>{const{world:t,document:r}=e,{model:n,methods:a}=t,i=n.one.contractions||[];r.forEach((o,s)=>{for(let u=o.length-1;u>=0;u-=1){let l=null,c=null;if(xh.test(o[u].normal)===!0){const m=o[u].normal.split(xh);l=m[0],c=m[1]}let f=T3(i,o[u],l,c);if(!f&&Nh.hasOwnProperty(c)&&(f=Nh[c](o,u,t)),!f&&Ah.hasOwnProperty(l)&&(f=Ah[l](o,u)),l==="there"&&c==="s"&&(f=F3(o,u)),f){f=Kc(f,e),Wc(r,[s,u],f),Dh(r[s],e,u,f.length);continue}if(M3.test(o[u].normal)){f=C3(o,u),f&&(f=Kc(f,e),Wc(r,[s,u],f),a.one.setTag(f,"NumberRange",t),f[2]&&f[2].tags.has("Time")&&a.one.setTag([f[0]],"Time",t,null,"time-range"),Dh(r[s],e,u,f.length));continue}f=S3(o,u,t),f&&(f=Kc(f,e),Wc(r,[s,u],f),a.one.setTag([f[1]],"Unit",t,null,"contraction-unit"))}})},k3={contractions:P3},O3={model:c3,compute:k3,hooks:["contractions"]},Ch=function(e){const t=e.world,{model:r,methods:n}=e.world,a=n.one.setTag,{frozenLex:i}=r.one,o=r.one._multiCache||{};e.docs.forEach(s=>{for(let u=0;u<s.length;u+=1){const l=s[u],c=l.machine||l.normal;if(o[c]!==void 0&&s[u+1]){const f=u+o[c]-1;for(let m=f;m>u;m-=1){const d=s.slice(u,m+1),h=d.map(p=>p.machine||p.normal).join(" ");if(i.hasOwnProperty(h)===!0){a(d,i[h],t,!1,"1-frozen-multi-lexicon"),d.forEach(p=>p.frozen=!0);continue}}}if(i[c]!==void 0&&i.hasOwnProperty(c)){a([l],i[c],t,!1,"1-freeze-lexicon"),l.frozen=!0;continue}}})},$3=function(e){return e.docs.forEach(t=>{t.forEach(r=>{delete r.frozen})}),e},B3={frozen:Ch,freeze:Ch,unfreeze:$3},Eh=e=>"\x1B[34m"+e+"\x1B[0m",Sh=e=>"\x1B[3m\x1B[2m"+e+"\x1B[0m",Mh=function(e){e.docs.forEach(t=>{console.log(Eh(`
|
|
1
|
+
"use strict";const Ne=require("./jsx-runtime-nZSsnGb7.cjs"),Pn=require("./Button-BSek5HG5.cjs"),ve=require("./css-D3NdC2sx.cjs"),cr=require("react"),LN=require("./Provider-BA3zQVbv.cjs"),ka=require("./Text-DW5FpCk9.cjs"),Ys=require("./event-BxvV3arE.cjs"),ja=require("./Tags-DWsEZD9t.cjs"),HN=require("./Dialog-BpjxXSmw.cjs"),Ub=require("./Animated-Dvm2k_z_.cjs"),ir=require("./Box-D27bV7QJ.cjs"),on=require("./Editable-C-z-stcD.cjs");require("./types-C0tUDfsz.cjs");const Il=require("./Items-07R286kW.cjs"),GN=require("./useStaticData-BTwIe0Il.cjs");;/* empty css */require("./eraser-Bocga8Eb.cjs");require("./Haul-WgPKptr9.cjs");require("./provider-DksyuJua.cjs");const Wb=({format:e="dateTime",suppliedTZ:t="UTC",displayTZ:r="local",children:n,...a})=>Ne.jsxRuntimeExports.jsx(on.Text,{...a,children:new ve.d(n,t).toString(e,r)}),VN=(e,t,r)=>e==="preview"&&r===!0?"var(--pluto-primary-z)":t,Jb=({ref:e,className:t,value:r,ghost:n,disabled:a,onChange:i,inputType:o,size:s,variant:u="text",style:l,color:c,borderColor:f,borderWidth:m,bordered:d,rounded:h,background:p,textColor:y,onClick:w,...D})=>Ne.jsxRuntimeExports.jsx(Pn.Button,{el:"label",variant:u,className:ve.CSS(ve.CSS.BE("input",o),t),ghost:n,disabled:a,size:s,preventClick:!0,style:l,color:c,borderColor:f,borderWidth:m,bordered:d,rounded:h,background:p,textColor:VN(u,y,r),onClick:w,children:u!=="preview"?Ne.jsxRuntimeExports.jsxs(Ne.jsxRuntimeExports.Fragment,{children:[Ne.jsxRuntimeExports.jsx("input",{className:ve.CSS.BE("input",o,"input"),type:"checkbox",ref:e,checked:r,onChange:v=>{v.stopPropagation(),i?.(v.target.checked)},value:"",disabled:a,onClick:w,...D}),Ne.jsxRuntimeExports.jsx("span",{className:ve.CSS.BE("input",o,"indicator"),onClick:w})]}):r?"True":"False"}),UN=e=>Ne.jsxRuntimeExports.jsx(Jb,{...e,inputType:"checkbox"}),Kb="cursor-style",mh=(e,t=document.head)=>{Yb();const r=document.createElement("style");r.innerHTML=`*{cursor: ${e} !important;}`,r.id=Kb,t.appendChild(r)},Yb=()=>{const e=document.getElementById(Kb);e?.remove()},dh=(e,t,r,n,a)=>{const{x:i,y:o}=n??ve.Au.construct(ve.Eu.dims(a));if(ve.Eu.width(t)>i&&ve.Eu.width(t)>ve.Eu.height(t)){const s=ve.Eu.signedWidth(t)<0?i:-i;e+=(ve.Eu.signedWidth(t)+s)*r.x,mh("ew-resize")}if(ve.Eu.height(t)>o&&ve.Eu.height(t)>ve.Eu.width(t)){const s=ve.Eu.signedHeight(t)<0?o:-o;e+=(ve.Eu.signedHeight(t)+s)*r.y,mh("ns-resize")}return e},vc=({direction:e,className:t,dragScale:r={x:10,y:1},dragThreshold:n=15,dragDirection:a,onChange:i,value:o,resetValue:s,onDragEnd:u,...l})=>{const c=cr.useRef({dragging:!1,curr:o,prev:o}),f=cr.useRef(null);c.current.dragging||(c.current.prev=o);const m=cr.useMemo(()=>{const p=ve.Au.construct(r);return a==="x"?ve.Au.construct(p.x,0):a==="y"?ve.Au.construct(0,p.y):p},[r,a]),d=cr.useMemo(()=>n!=null?ve.Au.construct(n):null,[n]);LN.useVirtualCursorDragWebKit({ref:f,onMove:cr.useCallback(p=>{if(f.current==null)return;let y=c.current.prev;c.current.dragging=!0,y=dh(y,p,m,d,ve.Eu.construct(f.current)),c.current.curr=y,i(y)},[i,m,d]),onEnd:cr.useCallback((p,y)=>{if(f.current==null)return;let w=c.current.prev;w=dh(w,p,m,d,ve.Eu.construct(f.current)),c.current.prev=w,c.current.dragging=!1,Yb(),u?.(w),l.onBlur?.()},[l.onBlur,u,m,d])});const h=cr.useCallback(()=>{i(s??c.current.prev)},[i,s]);return Ne.jsxRuntimeExports.jsx(Pn.Button,{ref:f,variant:"outlined",className:ve.CSS(ve.CSS.BE("input","drag-btn"),e!=null&&ve.CSS.BEM("input","drag-btn","direction",e),t),tabIndex:-1,onDoubleClick:h,onClick:Ys.preventDefault,contrast:0,textColor:9,...l,children:Ne.jsxRuntimeExports.jsx(ka.Drag,{})})},WN={x:Number(ve.d.HOUR.valueOf()),y:Number(ve.d.days(.75).valueOf())},Zb=({value:e,onChange:t})=>{const r=new ve.d(e,"UTC");cr.useLayoutEffect(()=>{const i=r.sub(ve.d.utcOffset);if(i.remainder(ve.d.DAY).isZero)return;const o=i.sub(i.remainder(ve.d.DAY));t(Number(new ve.d(o,"local").valueOf()))},[e]);const n=i=>{let o;if(typeof i=="number")o=new ve.d(i,"UTC");else{if(i.length===0)return;o=new ve.d(i,"local")}t(Number(o.valueOf()))};return{value:r.toString("ISODate","local"),onChange:n}},JN=({ref:e,onChange:t,value:r,className:n,showDragHandle:a=!0,children:i,...o})=>{const{value:s,onChange:u}=Zb({value:r,onChange:t});return Ne.jsxRuntimeExports.jsxs(ja.Text,{ref:e,value:s,className:ve.CSS(ve.CSS.B("input-date"),n),onChange:u,type:"date",...o,children:[a&&Ne.jsxRuntimeExports.jsx(vc,{value:r,onChange:u,dragScale:WN}),i]})},KN={one:{},two:{},three:{},four:{}},YN={one:{},two:{},three:{}},ZN={},QN=[],Yf={methods:KN,model:YN,compute:ZN,hooks:QN},XN=e=>Object.prototype.toString.call(e)==="[object Array]",eA={compute:function(e){const{world:t}=this,r=t.compute;return typeof e=="string"&&r.hasOwnProperty(e)?r[e](this):XN(e)?e.forEach(n=>{t.compute.hasOwnProperty(n)?r[n](this):console.warn("no compute:",e)}):typeof e=="function"?e(this):console.warn("no compute:",e),this}},tA=function(e){return this.fullPointer.forEach((r,n)=>{const a=this.update([r]);e(a,n)}),this},rA=function(e,t){const n=this.fullPointer.map((i,o)=>{const s=this.update([i]),u=e(s,o);return u===void 0?this.none():u});if(n.length===0)return t||this.update([]);if(n[0]!==void 0&&(typeof n[0]=="string"||typeof n[0]=="object"&&(n[0]===null||!n[0].isView)))return n;let a=[];return n.forEach(i=>{a=a.concat(i.fullPointer)}),this.toView(a)},nA=function(e){let t=this.fullPointer;return t=t.filter((n,a)=>{const i=this.update([n]);return e(i,a)}),this.update(t)},aA=function(e){const r=this.fullPointer.find((n,a)=>{const i=this.update([n]);return e(i,a)});return this.update([r])},iA=function(e){return this.fullPointer.some((r,n)=>{const a=this.update([r]);return e(a,n)})},oA=function(e=1){let t=this.fullPointer,r=Math.floor(Math.random()*t.length);return r+e>this.length&&(r=this.length-e,r=r<0?0:r),t=t.slice(r,r+e),this.update(t)},sA={forEach:tA,map:rA,filter:nA,find:aA,some:iA,random:oA},Zn={termList:function(){return this.methods.one.termList(this.docs)},terms:function(e){const t=this.match(".");return typeof e=="number"?t.eq(e):t},groups:function(e){if(e||e===0)return this.update(this._groups[e]||[]);const t={};return Object.keys(this._groups).forEach(r=>{t[r]=this.update(this._groups[r])}),t},eq:function(e){let t=this.pointer;return t||(t=this.docs.map((r,n)=>[n])),t[e]?this.update([t[e]]):this.none()},first:function(){return this.eq(0)},last:function(){const e=this.fullPointer.length-1;return this.eq(e)},firstTerms:function(){return this.match("^.")},lastTerms:function(){return this.match(".$")},slice:function(e,t){let r=this.pointer||this.docs.map((n,a)=>[a]);return r=r.slice(e,t),this.update(r)},all:function(){return this.update().toView()},fullSentences:function(){const e=this.fullPointer.map(t=>[t[0]]);return this.update(e).toView()},none:function(){return this.update([])},isDoc:function(e){if(!e||!e.isView)return!1;const t=this.fullPointer,r=e.fullPointer;return!t.length===r.length?!1:t.every((n,a)=>r[a]?n[0]===r[a][0]&&n[1]===r[a][1]&&n[2]===r[a][2]:!1)},wordCount:function(){return this.docs.reduce((e,t)=>(e+=t.filter(r=>r.text!=="").length,e),0)},isFull:function(){const e=this.pointer;if(!e)return!0;if(e.length===0||e[0][0]!==0)return!1;let t=0,r=0;return this.document.forEach(n=>t+=n.length),this.docs.forEach(n=>r+=n.length),t===r},getNth:function(e){return typeof e=="number"?this.eq(e):typeof e=="string"?this.if(e):this}};Zn.group=Zn.groups;Zn.fullSentence=Zn.fullSentences;Zn.sentence=Zn.fullSentences;Zn.lastTerm=Zn.lastTerms;Zn.firstTerm=Zn.firstTerms;const Zf=Object.assign({},Zn,eA,sA);Zf.get=Zf.eq;class si{constructor(t,r,n={}){[["document",t],["world",Yf],["_groups",n],["_cache",null],["viewType","View"]].forEach(i=>{Object.defineProperty(this,i[0],{value:i[1],writable:!0})}),this.ptrs=r}get docs(){let t=this.document;return this.ptrs&&(t=Yf.methods.one.getDoc(this.ptrs,this.document)),t}get pointer(){return this.ptrs}get methods(){return this.world.methods}get model(){return this.world.model}get hooks(){return this.world.hooks}get isView(){return!0}get found(){return this.docs.length>0}get length(){return this.docs.length}get fullPointer(){const{docs:t,ptrs:r,document:n}=this;return(r||t.map((i,o)=>[o])).map(i=>{let[o,s,u,l,c]=i;return s=s||0,u=u||(n[o]||[]).length,n[o]&&n[o][s]&&(l=l||n[o][s].id,n[o][u-1]&&(c=c||n[o][u-1].id)),[o,s,u,l,c]})}update(t){const r=new si(this.document,t);if(this._cache&&t&&t.length>0){const n=[];t.forEach((a,i)=>{const[o,s,u]=a;a.length===1?n[i]=this._cache[o]:s===0&&this.document[o].length===u&&(n[i]=this._cache[o])}),n.length>0&&(r._cache=n)}return r.world=this.world,r}toView(t){return new si(this.document,t||this.pointer)}fromText(t){const{methods:r}=this,n=r.one.tokenize.fromString(t,this.world),a=new si(n);return a.world=this.world,a.compute(["normal","freeze","lexicon"]),this.world.compute.preTagger&&a.compute("preTagger"),a.compute("unfreeze"),a}clone(){let t=this.document.slice(0);t=t.map(n=>n.map(a=>(a=Object.assign({},a),a.tags=new Set(a.tags),a)));const r=this.update(this.pointer);return r.document=t,r._cache=this._cache,r}}Object.assign(si.prototype,Zf);const uA="14.14.5",hh=function(e){return e&&typeof e=="object"&&!Array.isArray(e)},lA=function(e){return Object.prototype.toString.call(e)==="[object Array]"};function Qb(e,t){if(hh(t))for(const r in t)hh(t[r])?(e[r]||Object.assign(e,{[r]:{}}),Qb(e[r],t[r])):Object.assign(e,{[r]:t[r]});return e}function cA(e,t){for(const r in t)e[r]=e[r]||{},Object.assign(e[r],t[r]);return e}const fA=function(e,t){const r=e.two.models||{};Object.keys(t).forEach(n=>{t[n].pastTense&&(r.toPast&&(r.toPast.ex[n]=t[n].pastTense),r.fromPast&&(r.fromPast.ex[t[n].pastTense]=n)),t[n].presentTense&&(r.toPresent&&(r.toPresent.ex[n]=t[n].presentTense),r.fromPresent&&(r.fromPresent.ex[t[n].presentTense]=n)),t[n].gerund&&(r.toGerund&&(r.toGerund.ex[n]=t[n].gerund),r.fromGerund&&(r.fromGerund.ex[t[n].gerund]=n)),t[n].comparative&&(r.toComparative&&(r.toComparative.ex[n]=t[n].comparative),r.fromComparative&&(r.fromComparative.ex[t[n].comparative]=n)),t[n].superlative&&(r.toSuperlative&&(r.toSuperlative.ex[n]=t[n].superlative),r.fromSuperlative&&(r.fromSuperlative.ex[t[n].superlative]=n))})},Xb=function(e,t,r,n){if(lA(e)){e.forEach(u=>Xb(u,t,r,n));return}const{methods:a,model:i,compute:o,hooks:s}=t;e.methods&&cA(a,e.methods),e.model&&Qb(i,e.model),e.irregulars&&fA(i,e.irregulars),e.compute&&Object.assign(o,e.compute),s&&(t.hooks=s.concat(e.hooks||[])),e.api&&e.api(r),e.lib&&Object.keys(e.lib).forEach(u=>n[u]=e.lib[u]),e.tags&&n.addTags(e.tags),e.words&&n.addWords(e.words),e.frozen&&n.addWords(e.frozen,!0),e.mutate&&e.mutate(t,n)},mA=function(e){const t=typeof process>"u"||!process.env?self.env||{}:process.env;return t.DEBUG_TAGS=e==="tagger"||e===!0?!0:"",t.DEBUG_MATCH=e==="match"||e===!0?!0:"",t.DEBUG_CHUNKS=e==="chunker"||e===!0?!0:"",this},dA=e=>Object.prototype.toString.call(e)==="[object Object]",Qf=function(e){return Object.prototype.toString.call(e)==="[object Array]"},hA=function(e){return e.map(t=>t.terms.map(r=>(Qf(r.tags)&&(r.tags=new Set(r.tags)),r)))},pA=function(e){return e.map(t=>t.map(r=>({text:r,normal:r,pre:"",post:" ",tags:new Set})))},ew=function(e,t,r){const{methods:n}=r,a=new t([]);if(a.world=r,typeof e=="number"&&(e=String(e)),!e)return a;if(typeof e=="string"){const i=n.one.tokenize.fromString(e,r);return new t(i)}if(dA(e)&&e.isView)return new t(e.document,e.ptrs);if(Qf(e)){if(Qf(e[0])){const o=pA(e);return new t(o)}const i=hA(e);return new t(i)}return a},zl=Object.assign({},Yf),tt=function(e,t){t&&tt.addWords(t);const r=ew(e,si,zl);return e&&r.compute(zl.hooks),r};Object.defineProperty(tt,"_world",{value:zl,writable:!0});tt.tokenize=function(e,t){const{compute:r}=this._world;t&&tt.addWords(t);const n=ew(e,si,zl);return r.contractions&&n.compute(["alias","normal","machine","contractions"]),n};tt.plugin=function(e){return Xb(e,this._world,si,this),this};tt.extend=tt.plugin;tt.world=function(){return this._world};tt.model=function(){return this._world.model};tt.methods=function(){return this._world.methods};tt.hooks=function(){return this._world.hooks};tt.verbose=mA;tt.version=uA;const gA=function(e){return e.map(r=>{const n=new Set;return r.forEach(a=>{a.normal!==""&&n.add(a.normal),a.switch&&n.add(`%${a.switch}%`),a.implicit&&n.add(a.implicit),a.machine&&n.add(a.machine),a.root&&n.add(a.root),a.alias&&a.alias.forEach(o=>n.add(o));const i=Array.from(a.tags);for(let o=0;o<i.length;o+=1)n.add("#"+i[o])}),n})},vA={one:{cacheDoc:gA}},yA={cache:function(){return this._cache=this.methods.one.cacheDoc(this.document),this},uncache:function(){return this._cache=null,this}},bA=function(e){Object.assign(e.prototype,yA)},wA={cache:function(e){e._cache=e.methods.one.cacheDoc(e.document)}},xA={api:bA,compute:wA,methods:vA},DA={toLowerCase:function(){return this.termList().forEach(e=>{e.text=e.text.toLowerCase()}),this},toUpperCase:function(){return this.termList().forEach(e=>{e.text=e.text.toUpperCase()}),this},toTitleCase:function(){return this.termList().forEach(e=>{e.text=e.text.replace(/^ *[a-z\u00C0-\u00FF]/,t=>t.toUpperCase())}),this},toCamelCase:function(){return this.docs.forEach(e=>{e.forEach((t,r)=>{r!==0&&(t.text=t.text.replace(/^ *[a-z\u00C0-\u00FF]/,n=>n.toUpperCase())),r!==e.length-1&&(t.post="")})}),this}},ph=e=>new RegExp("^\\p{Lu}[\\p{Ll}'’]","u").test(e)||new RegExp("^\\p{Lu}$","u").test(e),NA=e=>e.replace(new RegExp("^\\p{Ll}","u"),t=>t.toUpperCase()),AA=e=>e.replace(new RegExp("^\\p{Lu}","u"),t=>t.toLowerCase()),tw=(e,t,r)=>{if(r.forEach(n=>n.dirty=!0),e){const n=[t,0].concat(r);Array.prototype.splice.apply(e,n)}return e},$o=function(e){const t=/ $/,r=/[-–—]/,n=e[e.length-1];n&&!t.test(n.post)&&!r.test(n.post)&&(n.post+=" ")},gh=(e,t,r)=>{const n=/[-.?!,;:)–—'"]/g,a=e[t-1];if(!a)return;const i=a.post;if(n.test(i)){const o=i.match(n).join(""),s=r[r.length-1];s.post=o+s.post,a.post=a.post.replace(n,"")}},CA=function(e,t,r){const n=e[t];if(t!==0||!ph(n.text))return;r[0].text=NA(r[0].text);const a=e[t];a.tags.has("ProperNoun")||a.tags.has("Acronym")||ph(a.text)&&a.text.length>1&&(a.text=AA(a.text))},EA=function(e,t,r,n){const[a,i,o]=t;i===0||o===n[a].length?$o(r):($o(r),$o([e[t[1]]])),CA(e,i,r),tw(e,i,r)},SA=function(e,t,r,n){const[a,,i]=t,o=(n[a]||[]).length;i<o?(gh(e,i,r),$o(r)):o===i&&($o(e),gh(e,i,r),n[a+1]&&(r[r.length-1].post+=" ")),tw(e,t[2],r),t[4]=r[r.length-1].id};let gs=0;const vh=e=>(e=e.length<3?"0"+e:e,e.length<3?"0"+e:e),rw=function(e){let[t,r]=e.index||[0,0];gs+=1,gs=gs>46655?0:gs,t=t>46655?0:t,r=r>1294?0:r;let n=vh(gs.toString(36));n+=vh(t.toString(36));let a=r.toString(36);a=a.length<2?"0"+a:a,n+=a;const i=parseInt(Math.random()*36,10);return n+=i.toString(36),e.normal+"|"+n.toUpperCase()},yh=function(e){e.has("@hasContraction")&&typeof e.contractions=="function"&&e.grow("@hasContraction").contractions().expand()},bh=e=>Object.prototype.toString.call(e)==="[object Array]",MA=function(e){return e=e.map(t=>(t.id=rw(t),t)),e},TA=function(e,t){const{methods:r}=t;return typeof e=="string"?r.one.tokenize.fromString(e,t)[0]:typeof e=="object"&&e.isView?e.clone().docs[0]||[]:bh(e)?bh(e[0])?e[0]:e:[]},wh=function(e,t,r){const{document:n,world:a}=t;t.uncache();const i=t.fullPointer,o=t.fullPointer;t.forEach((u,l)=>{const c=u.fullPointer[0],[f]=c,m=n[f];let d=TA(e,a);d.length!==0&&(d=MA(d),r?(yh(t.update([c]).firstTerm()),EA(m,c,d,n)):(yh(t.update([c]).lastTerm()),SA(m,c,d,n)),n[f]&&n[f][c[1]]&&(c[3]=n[f][c[1]].id),o[l]=c,c[2]+=d.length,i[l]=c)});const s=t.toView(i);return t.ptrs=o,s.compute(["id","index","freeze","lexicon"]),s.world.compute.preTagger&&s.compute("preTagger"),s.compute("unfreeze"),s},Yi={insertAfter:function(e){return wh(e,this,!1)},insertBefore:function(e){return wh(e,this,!0)}};Yi.append=Yi.insertAfter;Yi.prepend=Yi.insertBefore;Yi.insert=Yi.insertAfter;const FA=/\$[0-9a-z]+/g,od={},PA=e=>new RegExp("^\\p{Lu}[\\p{Ll}'’]","u").test(e)||new RegExp("^\\p{Lu}$","u").test(e),kA=e=>e.replace(new RegExp("^\\p{Ll}","u"),t=>t.toUpperCase()),OA=e=>e.replace(new RegExp("^\\p{Lu}","u"),t=>t.toLowerCase()),$A=function(e,t,r){return e.forEach(n=>{const a=t(n);n.replaceWith(a,r)}),e},BA=function(e,t){if(typeof e!="string")return e;const r=t.groups();return e=e.replace(FA,n=>{const a=n.replace(/\$/,"");return r.hasOwnProperty(a)?r[a].text():n}),e};od.replaceWith=function(e,t={}){let r=this.fullPointer;const n=this;if(this.uncache(),typeof e=="function")return $A(n,e,t);const a=n.docs[0];if(!a)return n;const i=t.possessives&&a[a.length-1].tags.has("Possessive"),o=t.case&&PA(a[0].text);e=BA(e,n);const s=this.update(r);r=r.map(m=>m.slice(0,3));const u=(s.docs[0]||[]).map(m=>Array.from(m.tags)),l=s.docs[0][0].pre,c=s.docs[0][s.docs[0].length-1].post;if(typeof e=="string"&&(e=this.fromText(e).compute("id")),n.insertAfter(e),s.has("@hasContraction")&&n.contractions&&n.grow("@hasContraction+").contractions().expand(),n.delete(s),i){const m=n.docs[0],d=m[m.length-1];d.tags.has("Possessive")||(d.text+="'s",d.normal+="'s",d.tags.add("Possessive"))}if(l&&n.docs[0]&&(n.docs[0][0].pre=l),c&&n.docs[0]){const m=n.docs[0][n.docs[0].length-1];m.post.trim()||(m.post=c)}const f=n.toView(r).compute(["index","freeze","lexicon"]);if(f.world.compute.preTagger&&f.compute("preTagger"),f.compute("unfreeze"),t.tags&&f.terms().forEach((m,d)=>{m.tagSafe(u[d])}),!f.docs[0]||!f.docs[0][0])return f;if(t.case){const m=o?kA:OA;f.docs[0][0].text=m(f.docs[0][0].text)}return f};od.replace=function(e,t,r){if(e&&!t)return this.replaceWith(e,r);const n=this.match(e);return n.found?(this.soften(),n.replaceWith(t,r)):this};const _A=function(e,t){const r=e.length-1,n=e[r],a=e[r-t];a&&n&&(a.post+=n.post,a.post=a.post.replace(/ +([.?!,;:])/,"$1"),a.post=a.post.replace(/[,;:]+([.?!])/,"$1"))},IA=function(e,t){t.forEach(r=>{const[n,a,i]=r,o=i-a;e[n]&&(i===e[n].length&&i>1&&_A(e[n],o),e[n].splice(a,o))});for(let r=e.length-1;r>=0;r-=1)if(e[r].length===0&&(e.splice(r,1),r===e.length&&e[r-1])){const n=e[r-1],a=n[n.length-1];a&&(a.post=a.post.trimEnd())}return e},zA=function(e,t){return e=e.map(r=>{const[n]=r;return t[n]&&t[n].forEach(a=>{const i=a[2]-a[1];r[1]<=a[1]&&r[2]>=a[2]&&(r[2]-=i)}),r}),e.forEach((r,n)=>{if(r[1]===0&&r[2]==0)for(let a=n+1;a<e.length;a+=1)e[a][0]-=1,e[a][0]<0&&(e[a][0]=0)}),e=e.filter(r=>r[2]-r[1]>0),e=e.map(r=>(r[3]=null,r[4]=null,r)),e},Xf={remove:function(e){const{indexN:t}=this.methods.one.pointer;this.uncache();let r=this.all(),n=this;e&&(r=this,n=this.match(e));const a=!r.ptrs;n.has("@hasContraction")&&n.contractions&&n.grow("@hasContraction").contractions().expand();let i=r.fullPointer;const o=n.fullPointer.reverse(),s=IA(this.document,o),u=t(o);return i=zA(i,u),r.ptrs=i,r.document=s,r.compute("index"),a&&(r.ptrs=void 0),e?r.toView(i):(this.ptrs=[],r.none())}};Xf.delete=Xf.remove;const Is={pre:function(e,t){return e===void 0&&this.found?this.docs[0][0].pre:(this.docs.forEach(r=>{const n=r[0];t===!0?n.pre+=e:n.pre=e}),this)},post:function(e,t){if(e===void 0){const r=this.docs[this.docs.length-1];return r[r.length-1].post}return this.docs.forEach(r=>{const n=r[r.length-1];t===!0?n.post+=e:n.post=e}),this},trim:function(){if(!this.found)return this;const e=this.docs,t=e[0][0];t.pre=t.pre.trimStart();const r=e[e.length-1],n=r[r.length-1];return n.post=n.post.trimEnd(),this},hyphenate:function(){return this.docs.forEach(e=>{e.forEach((t,r)=>{r!==0&&(t.pre=""),e[r+1]&&(t.post="-")})}),this},dehyphenate:function(){const e=/[-–—]/;return this.docs.forEach(t=>{t.forEach(r=>{e.test(r.post)&&(r.post=" ")})}),this},toQuotations:function(e,t){return e=e||'"',t=t||'"',this.docs.forEach(r=>{r[0].pre=e+r[0].pre;const n=r[r.length-1];n.post=t+n.post}),this},toParentheses:function(e,t){return e=e||"(",t=t||")",this.docs.forEach(r=>{r[0].pre=e+r[0].pre;const n=r[r.length-1];n.post=t+n.post}),this}};Is.deHyphenate=Is.dehyphenate;Is.toQuotation=Is.toQuotations;const jA=(e,t)=>e.normal<t.normal?-1:e.normal>t.normal?1:0,qA=(e,t)=>{const r=e.normal.trim().length,n=t.normal.trim().length;return r<n?1:r>n?-1:0},RA=(e,t)=>e.words<t.words?1:e.words>t.words?-1:0,LA=(e,t)=>e[0]<t[0]?1:e[0]>t[0]?-1:e[1]>t[1]?1:-1,HA=function(e){const t={};return e.forEach(r=>{t[r.normal]=t[r.normal]||0,t[r.normal]+=1}),e.sort((r,n)=>{const a=t[r.normal],i=t[n.normal];return a<i?1:a>i?-1:0}),e},Uc={alpha:jA,length:qA,wordCount:RA,sequential:LA,byFreq:HA},GA=new Set(["index","sequence","seq","sequential","chron","chronological"]),VA=new Set(["freq","frequency","topk","repeats"]),UA=new Set(["alpha","alphabetical"]),WA=function(e,t){let r=e.fullPointer;return r=r.sort((n,a)=>(n=e.update([n]),a=e.update([a]),t(n,a))),e.ptrs=r,e},JA=function(e){const{docs:t,pointer:r}=this;if(this.uncache(),typeof e=="function")return WA(this,e);e=e||"alpha";const n=r||t.map((i,o)=>[o]);let a=t.map((i,o)=>({index:o,words:i.length,normal:i.map(s=>s.machine||s.normal||"").join(" "),pointer:n[o]}));return GA.has(e)&&(e="sequential"),UA.has(e)&&(e="alpha"),VA.has(e)?(a=Uc.byFreq(a),this.update(a.map(i=>i.pointer))):typeof Uc[e]=="function"?(a=a.sort(Uc[e]),this.update(a.map(i=>i.pointer))):this},KA=function(){let e=this.pointer||this.docs.map((t,r)=>[r]);return e=[].concat(e),e=e.reverse(),this._cache&&(this._cache=this._cache.reverse()),this.update(e)},YA=function(){const e=new Set;return this.filter(r=>{const n=r.text("machine");return e.has(n)?!1:(e.add(n),!0)})},ZA={unique:YA,reverse:KA,sort:JA},QA=e=>Object.prototype.toString.call(e)==="[object Array]",nw=function(e,t){if(e.length>0){const r=e[e.length-1],n=r[r.length-1];/ /.test(n.post)===!1&&(n.post+=" ")}return e=e.concat(t),e},XA=function(e,t){if(e.document===t.document){const n=e.fullPointer.concat(t.fullPointer);return e.toView(n).compute("index")}return t.fullPointer.forEach(n=>{n[0]+=e.document.length}),e.document=nw(e.document,t.docs),e.all()},e3={concat:function(e){if(typeof e=="string"){const t=this.fromText(e);if(!this.found||!this.ptrs)this.document=this.document.concat(t.document);else{const r=this.fullPointer,n=r[r.length-1][0];this.document.splice(n,0,...t.document)}return this.all().compute("index")}if(typeof e=="object"&&e.isView)return XA(this,e);if(QA(e)){const t=nw(this.document,e);return this.document=t,this.all()}return this}},t3=function(){return this.ptrs=this.fullPointer,this},r3=function(){let e=this.ptrs;return!e||e.length<1?this:(e=e.map(t=>t.slice(0,3)),this.ptrs=e,this)},n3={harden:t3,soften:r3},a3=Object.assign({},DA,Yi,od,Xf,Is,ZA,e3,n3),i3=function(e){Object.assign(e.prototype,a3)},o3={id:function(e){const t=e.docs;for(let r=0;r<t.length;r+=1)for(let n=0;n<t[r].length;n+=1){const a=t[r][n];a.id=a.id||rw(a)}}},s3={api:i3,compute:o3},u3=[{word:"@",out:["at"]},{word:"arent",out:["are","not"]},{word:"alot",out:["a","lot"]},{word:"brb",out:["be","right","back"]},{word:"cannot",out:["can","not"]},{word:"dun",out:["do","not"]},{word:"can't",out:["can","not"]},{word:"shan't",out:["should","not"]},{word:"won't",out:["will","not"]},{word:"that's",out:["that","is"]},{word:"what's",out:["what","is"]},{word:"let's",out:["let","us"]},{word:"dunno",out:["do","not","know"]},{word:"gonna",out:["going","to"]},{word:"gotta",out:["have","got","to"]},{word:"gimme",out:["give","me"]},{word:"outta",out:["out","of"]},{word:"tryna",out:["trying","to"]},{word:"gtg",out:["got","to","go"]},{word:"im",out:["i","am"]},{word:"imma",out:["I","will"]},{word:"imo",out:["in","my","opinion"]},{word:"irl",out:["in","real","life"]},{word:"ive",out:["i","have"]},{word:"rn",out:["right","now"]},{word:"tbh",out:["to","be","honest"]},{word:"wanna",out:["want","to"]},{word:"c'mere",out:["come","here"]},{word:"c'mon",out:["come","on"]},{word:"shoulda",out:["should","have"]},{word:"coulda",out:["coulda","have"]},{word:"woulda",out:["woulda","have"]},{word:"musta",out:["must","have"]},{word:"tis",out:["it","is"]},{word:"twas",out:["it","was"]},{word:"y'know",out:["you","know"]},{word:"ne'er",out:["never"]},{word:"o'er",out:["over"]},{after:"ll",out:["will"]},{after:"ve",out:["have"]},{after:"re",out:["are"]},{after:"m",out:["am"]},{before:"c",out:["ce"]},{before:"m",out:["me"]},{before:"n",out:["ne"]},{before:"qu",out:["que"]},{before:"s",out:["se"]},{before:"t",out:["tu"]},{word:"shouldnt",out:["should","not"]},{word:"couldnt",out:["could","not"]},{word:"wouldnt",out:["would","not"]},{word:"hasnt",out:["has","not"]},{word:"wasnt",out:["was","not"]},{word:"isnt",out:["is","not"]},{word:"cant",out:["can","not"]},{word:"dont",out:["do","not"]},{word:"wont",out:["will","not"]},{word:"howd",out:["how","did"]},{word:"whatd",out:["what","did"]},{word:"whend",out:["when","did"]},{word:"whered",out:["where","did"]}],ln=!0,l3={st:ln,nd:ln,rd:ln,th:ln,am:ln,pm:ln,max:ln,"°":ln,s:ln,e:ln,er:ln,ère:ln,ème:ln},c3={one:{contractions:u3,numberSuffixes:l3}},Wc=function(e,t,r){const[n,a]=t;!r||r.length===0||(r=r.map((i,o)=>(i.implicit=i.text,i.machine=i.text,i.pre="",i.post="",i.text="",i.normal="",i.index=[n,a+o],i)),r[0]&&(r[0].pre=e[n][a].pre,r[r.length-1].post=e[n][a].post,r[0].text=e[n][a].text,r[0].normal=e[n][a].normal),e[n].splice(a,1,...r))},f3=/'/,m3=new Set(["what","how","when","where","why"]),d3=new Set(["be","go","start","think","need"]),h3=new Set(["been","gone"]),p3=function(e,t){const r=e[t].normal.split(f3)[0];if(m3.has(r))return[r,"did"];if(e[t+1]){if(h3.has(e[t+1].normal))return[r,"had"];if(d3.has(e[t+1].normal))return[r,"would"]}return null},g3=function(e,t){return e[t].normal==="ain't"||e[t].normal==="aint"?null:[e[t].normal.replace(/n't/,""),"not"]},sd=/'/,v3=/(e|é|aison|sion|tion)$/,y3=/(age|isme|acle|ege|oire)$/,b3=(e,t)=>{const r=e[t].normal.split(sd)[1];return r&&r.endsWith("e")?["la",r]:["le",r]},w3=(e,t)=>{const r=e[t].normal.split(sd)[1];return r&&v3.test(r)&&!y3.test(r)?["du",r]:r&&r.endsWith("s")?["des",r]:["de",r]},x3=(e,t)=>["je",e[t].normal.split(sd)[1]],Jc={preJ:x3,preL:b3,preD:w3},D3=/^([0-9.]{1,4}[a-z]{0,2}) ?[-–—] ?([0-9]{1,4}[a-z]{0,2})$/i,N3=/^([0-9]{1,2}(:[0-9][0-9])?(am|pm)?) ?[-–—] ?([0-9]{1,2}(:[0-9][0-9])?(am|pm)?)$/i,A3=/^[0-9]{3}-[0-9]{4}$/,C3=function(e,t){const r=e[t];let n=r.text.match(D3);return n!==null?r.tags.has("PhoneNumber")===!0||A3.test(r.text)?null:[n[1],"to",n[2]]:(n=r.text.match(N3),n!==null?[n[1],"to",n[4]]:null)},E3=/^([+-]?[0-9][.,0-9]*)([a-z°²³µ/]+)$/,S3=function(e,t,r){const n=r.model.one.numberSuffixes||{},i=e[t].text.match(E3);if(i!==null){const o=i[2].toLowerCase().trim();return n.hasOwnProperty(o)?null:[i[1],o]}return null},xh=/'/,M3=/^[0-9][^-–—]*[-–—].*?[0-9]/,Dh=function(e,t,r,n){const a=t.update();a.document=[e];let i=r+n;r>0&&(r-=1),e[i]&&(i+=1),a.ptrs=[[0,r,i]]},Nh={t:(e,t)=>g3(e,t),d:(e,t)=>p3(e,t)},Ah={j:(e,t)=>Jc.preJ(e,t),l:(e,t)=>Jc.preL(e,t),d:(e,t)=>Jc.preD(e,t)},T3=function(e,t,r,n){for(let a=0;a<e.length;a+=1){const i=e[a];if(i.word===t.normal)return i.out;if(n!==null&&n===i.after)return[r].concat(i.out);if(r!==null&&r===i.before&&n&&n.length>2)return i.out.concat(n)}return null},Kc=function(e,t){const r=t.fromText(e.join(" "));return r.compute(["id","alias"]),r.docs[0]},F3=function(e,t){for(let r=t+1;r<5&&e[r];r+=1)if(e[r].normal==="been")return["there","has"];return["there","is"]},P3=e=>{const{world:t,document:r}=e,{model:n,methods:a}=t,i=n.one.contractions||[];r.forEach((o,s)=>{for(let u=o.length-1;u>=0;u-=1){let l=null,c=null;if(xh.test(o[u].normal)===!0){const m=o[u].normal.split(xh);l=m[0],c=m[1]}let f=T3(i,o[u],l,c);if(!f&&Nh.hasOwnProperty(c)&&(f=Nh[c](o,u,t)),!f&&Ah.hasOwnProperty(l)&&(f=Ah[l](o,u)),l==="there"&&c==="s"&&(f=F3(o,u)),f){f=Kc(f,e),Wc(r,[s,u],f),Dh(r[s],e,u,f.length);continue}if(M3.test(o[u].normal)){f=C3(o,u),f&&(f=Kc(f,e),Wc(r,[s,u],f),a.one.setTag(f,"NumberRange",t),f[2]&&f[2].tags.has("Time")&&a.one.setTag([f[0]],"Time",t,null,"time-range"),Dh(r[s],e,u,f.length));continue}f=S3(o,u,t),f&&(f=Kc(f,e),Wc(r,[s,u],f),a.one.setTag([f[1]],"Unit",t,null,"contraction-unit"))}})},k3={contractions:P3},O3={model:c3,compute:k3,hooks:["contractions"]},Ch=function(e){const t=e.world,{model:r,methods:n}=e.world,a=n.one.setTag,{frozenLex:i}=r.one,o=r.one._multiCache||{};e.docs.forEach(s=>{for(let u=0;u<s.length;u+=1){const l=s[u],c=l.machine||l.normal;if(o[c]!==void 0&&s[u+1]){const f=u+o[c]-1;for(let m=f;m>u;m-=1){const d=s.slice(u,m+1),h=d.map(p=>p.machine||p.normal).join(" ");if(i.hasOwnProperty(h)===!0){a(d,i[h],t,!1,"1-frozen-multi-lexicon"),d.forEach(p=>p.frozen=!0);continue}}}if(i[c]!==void 0&&i.hasOwnProperty(c)){a([l],i[c],t,!1,"1-freeze-lexicon"),l.frozen=!0;continue}}})},$3=function(e){return e.docs.forEach(t=>{t.forEach(r=>{delete r.frozen})}),e},B3={frozen:Ch,freeze:Ch,unfreeze:$3},Eh=e=>"\x1B[34m"+e+"\x1B[0m",Sh=e=>"\x1B[3m\x1B[2m"+e+"\x1B[0m",Mh=function(e){e.docs.forEach(t=>{console.log(Eh(`
|
|
2
2
|
┌─────────`)),t.forEach(r=>{let n=` ${Sh("│")} `;const a=r.implicit||r.text||"-";r.frozen===!0?n+=`${Eh(a)} ❄️`:n+=Sh(a),console.log(n)})})},_3={compute:B3,mutate:e=>{const t=e.methods.one;t.termMethods.isFrozen=r=>r.frozen===!0,t.debug.freeze=Mh,t.debug.frozen=Mh},api:function(e){e.prototype.freeze=function(){return this.docs.forEach(t=>{t.forEach(r=>{r.frozen=!0})}),this},e.prototype.unfreeze=function(){this.compute("unfreeze")},e.prototype.isFrozen=function(){return this.match("@isFrozen+")}},hooks:["freeze"]},I3=function(e,t,r){const{model:n,methods:a}=r,i=a.one.setTag,o=n.one._multiCache||{},{lexicon:s}=n.one||{},u=e[t],l=u.machine||u.normal;if(o[l]!==void 0&&e[t+1]){const c=t+o[l]-1;for(let f=c;f>t;f-=1){const m=e.slice(t,f+1);if(m.length<=1)return!1;const d=m.map(h=>h.machine||h.normal).join(" ");if(s.hasOwnProperty(d)===!0){const h=s[d];return i(m,h,r,!1,"1-multi-lexicon"),h&&h.length===2&&(h[0]==="PhrasalVerb"||h[1]==="PhrasalVerb")&&i([m[1]],"Particle",r,!1,"1-phrasal-particle"),!0}}return!1}return null},Th=/^(under|over|mis|re|un|dis|semi|pre|post)-?/,z3=new Set(["Verb","Infinitive","PastTense","Gerund","PresentTense","Adjective","Participle"]),j3=function(e,t,r){const{model:n,methods:a}=r,i=a.one.setTag,{lexicon:o}=n.one,s=e[t],u=s.machine||s.normal;if(o[u]!==void 0&&o.hasOwnProperty(u))return i([s],o[u],r,!1,"1-lexicon"),!0;if(s.alias){const l=s.alias.find(c=>o.hasOwnProperty(c));if(l)return i([s],o[l],r,!1,"1-lexicon-alias"),!0}if(Th.test(u)===!0){const l=u.replace(Th,"");if(o.hasOwnProperty(l)&&l.length>3&&z3.has(o[l]))return i([s],o[l],r,!1,"1-lexicon-prefix"),!0}return null},q3=function(e){const t=e.world;e.docs.forEach(r=>{for(let n=0;n<r.length;n+=1)if(r[n].tags.size===0){let a=null;a=a||I3(r,n,t),a=a||j3(r,n,t)}})},R3={lexicon:q3},L3=function(e){const t={},r={};return Object.keys(e).forEach(n=>{const a=e[n];n=n.toLowerCase().trim(),n=n.replace(/'s\b/,"");const i=n.split(/ /);i.length>1&&(r[i[0]]===void 0||i.length>r[i[0]])&&(r[i[0]]=i.length),t[n]=t[n]||a}),delete t[""],delete t[null],delete t[" "],{lex:t,_multi:r}},H3={one:{expandLexicon:L3}},G3=function(e,t=!1){const r=this.world(),{methods:n,model:a}=r;if(!e)return;if(Object.keys(e).forEach(s=>{typeof e[s]=="string"&&e[s].startsWith("#")&&(e[s]=e[s].replace(/^#/,""))}),t===!0){const{lex:s,_multi:u}=n.one.expandLexicon(e,r);Object.assign(a.one._multiCache,u),Object.assign(a.one.frozenLex,s);return}if(n.two.expandLexicon){const{lex:s,_multi:u}=n.two.expandLexicon(e,r);Object.assign(a.one.lexicon,s),Object.assign(a.one._multiCache,u)}const{lex:i,_multi:o}=n.one.expandLexicon(e,r);Object.assign(a.one.lexicon,i),Object.assign(a.one._multiCache,o)},V3={addWords:G3},U3={one:{lexicon:{},_multiCache:{},frozenLex:{}}},W3={model:U3,methods:H3,compute:R3,lib:V3,hooks:["lexicon"]},J3=function(e,t){const{methods:r,model:n}=t;return r.one.tokenize.splitTerms(e,n).map(i=>r.one.tokenize.splitWhitespace(i,n)).map(i=>i.text.toLowerCase())},aw=function(e,t){const r=[{}],n=[null],a=[0],i=[];let o=0;e.forEach(function(s){let u=0;const l=J3(s,t);for(let c=0;c<l.length;c++){const f=l[c];r[u]&&r[u].hasOwnProperty(f)?u=r[u][f]:(o++,r[u][f]=o,r[o]={},u=o,n[o]=null)}n[u]=[l.length]});for(const s in r[0])o=r[0][s],a[o]=0,i.push(o);for(;i.length;){const s=i.shift(),u=Object.keys(r[s]);for(let l=0;l<u.length;l+=1){const c=u[l],f=r[s][c];for(i.push(f),o=a[s];o>0&&!r[o].hasOwnProperty(c);)o=a[o];if(r.hasOwnProperty(o)){const m=r[o][c];a[f]=m,n[m]&&(n[f]=n[f]||[],n[f]=n[f].concat(n[m]))}else a[f]=0}}return{goNext:r,endAs:n,failTo:a}},K3=function(e,t,r){let n=0;const a=[];for(let i=0;i<e.length;i++){const o=e[i][r.form]||e[i].normal;for(;n>0&&(t.goNext[n]===void 0||!t.goNext[n].hasOwnProperty(o));)n=t.failTo[n]||0;if(t.goNext[n].hasOwnProperty(o)&&(n=t.goNext[n][o],t.endAs[n])){const s=t.endAs[n];for(let u=0;u<s.length;u++){const l=s[u],c=e[i-l+1],[f,m]=c.index;a.push([f,m,m+l,c.id])}}}return a},Y3=function(e,t){for(let r=0;r<e.length;r+=1)if(t.has(e[r])===!0)return!1;return!0},Z3=function(e,t,r){let n=[];r.form=r.form||"normal";const a=e.docs;if(!t.goNext||!t.goNext[0])return console.error("Compromise invalid lookup trie"),e.none();const i=Object.keys(t.goNext[0]);for(let o=0;o<a.length;o++){if(e._cache&&e._cache[o]&&Y3(i,e._cache[o])===!0)continue;const s=a[o],u=K3(s,t,r);u.length>0&&(n=n.concat(u))}return e.update(n)},Q3=e=>Object.prototype.toString.call(e)==="[object Object]";function X3(e){e.prototype.lookup=function(t,r={}){if(!t)return this.none();typeof t=="string"&&(t=[t]);const n=Q3(t)?t:aw(t,this.world);let a=Z3(this,n,r);return a=a.settle(),a}}const Yc=(e,t)=>{for(let r=e.length-1;r>=0;r-=1)if(e[r]!==t)return e=e.slice(0,r+1),e;return e},eC=function(e){return e.goNext=e.goNext.map(t=>{if(Object.keys(t).length!==0)return t}),e.goNext=Yc(e.goNext,void 0),e.failTo=Yc(e.failTo,0),e.endAs=Yc(e.endAs,null),e},em={buildTrie:function(e){const t=aw(e,this.world());return eC(t)}};em.compile=em.buildTrie;const tC={api:X3,lib:em},Fh=function(e,t){return t&&e.forEach(r=>{const n=r[0];t[n]&&(r[0]=t[n][0],r[1]+=t[n][1],r[2]+=t[n][1])}),e},iw=function(e,t){let{ptrs:r}=e;const{byGroup:n}=e;return r=Fh(r,t),Object.keys(n).forEach(a=>{n[a]=Fh(n[a],t)}),{ptrs:r,byGroup:n}},Zs=function(e,t,r){const n=r.methods.one;return typeof e=="number"&&(e=String(e)),typeof e=="string"&&(e=n.killUnicode(e,r),e=n.parseMatch(e,t,r)),e},ow=e=>Object.prototype.toString.call(e)==="[object Object]",Qs=e=>e&&ow(e)&&e.isView===!0,Xs=e=>e&&ow(e)&&e.isNet===!0,rC=function(e,t,r){const n=this.methods.one;if(Qs(e))return this.intersection(e);if(Xs(e))return this.sweep(e,{tagger:!1}).view.settle();e=Zs(e,r,this.world);const a={regs:e,group:t},i=n.match(this.docs,a,this._cache),{ptrs:o,byGroup:s}=iw(i,this.fullPointer),u=this.toView(o);return u._groups=s,u},nC=function(e,t,r){const n=this.methods.one;if(Qs(e))return this.intersection(e).eq(0);if(Xs(e))return this.sweep(e,{tagger:!1,matchOne:!0}).view;e=Zs(e,r,this.world);const a={regs:e,group:t,justOne:!0},i=n.match(this.docs,a,this._cache),{ptrs:o,byGroup:s}=iw(i,this.fullPointer),u=this.toView(o);return u._groups=s,u},aC=function(e,t,r){const n=this.methods.one;if(Qs(e))return this.intersection(e).fullPointer.length>0;if(Xs(e))return this.sweep(e,{tagger:!1}).view.found;e=Zs(e,r,this.world);const a={regs:e,group:t,justOne:!0};return n.match(this.docs,a,this._cache).ptrs.length>0},iC=function(e,t,r){const n=this.methods.one;if(Qs(e))return this.filter(u=>u.intersection(e).found);if(Xs(e)){const u=this.sweep(e,{tagger:!1}).view.settle();return this.if(u)}e=Zs(e,r,this.world);const a={regs:e,group:t,justOne:!0};let i=this.fullPointer;const o=this._cache||[];i=i.filter((u,l)=>{const c=this.update([u]);return n.match(c.docs,a,o[l]).ptrs.length>0});const s=this.update(i);return this._cache&&(s._cache=i.map(u=>o[u[0]])),s},oC=function(e,t,r){const{methods:n}=this,a=n.one;if(Qs(e))return this.filter(s=>!s.intersection(e).found);if(Xs(e)){const s=this.sweep(e,{tagger:!1}).view.settle();return this.ifNo(s)}e=Zs(e,r,this.world);const i=this._cache||[],o=this.filter((s,u)=>{const l={regs:e,group:t,justOne:!0};return a.match(s.docs,l,i[u]).ptrs.length===0});return this._cache&&(o._cache=o.ptrs.map(s=>i[s[0]])),o},sC={matchOne:nC,match:rC,has:aC,if:iC,ifNo:oC},uC=function(e,t,r){const{indexN:n}=this.methods.one.pointer,a=[],i=n(this.fullPointer);Object.keys(i).forEach(s=>{const u=i[s].sort((l,c)=>l[1]>c[1]?1:-1)[0];u[1]>0&&a.push([u[0],0,u[1]])});const o=this.toView(a);return e?o.match(e,t,r):o},lC=function(e,t,r){const{indexN:n}=this.methods.one.pointer,a=[],i=n(this.fullPointer),o=this.document;Object.keys(i).forEach(u=>{const l=i[u].sort((m,d)=>m[1]>d[1]?-1:1)[0],[c,,f]=l;f<o[c].length&&a.push([c,f,o[c].length])});const s=this.toView(a);return e?s.match(e,t,r):s},cC=function(e,t,r){typeof e=="string"&&(e=this.world.methods.one.parseMatch(e,r,this.world)),e[e.length-1].end=!0;const n=this.fullPointer;return this.forEach((a,i)=>{const o=a.before(e,t);if(o.found){const s=o.terms();n[i][1]-=s.length,n[i][3]=s.docs[0][0].id}}),this.update(n)},fC=function(e,t,r){typeof e=="string"&&(e=this.world.methods.one.parseMatch(e,r,this.world)),e[0].start=!0;const n=this.fullPointer;return this.forEach((a,i)=>{const o=a.after(e,t);if(o.found){const s=o.terms();n[i][2]+=s.length,n[i][4]=null}}),this.update(n)},mC=function(e,t,r){return this.growRight(e,t,r).growLeft(e,t,r)},dC={before:uC,after:lC,growLeft:cC,growRight:fC,grow:mC},sw=function(e,t){return[e[0],e[1],t[2]]},hC=function(e){return Object.prototype.toString.call(e)==="[object Array]"},ud=(e,t,r)=>typeof e=="string"||hC(e)?t.match(e,r):e||t.none(),ld=function(e,t){const[r,n,a]=e;return t.document[r]&&t.document[r][n]&&(e[3]=e[3]||t.document[r][n].id,t.document[r][a-1]&&(e[4]=e[4]||t.document[r][a-1].id)),e},Go={};Go.splitOn=function(e,t){const{splitAll:r}=this.methods.one.pointer,n=ud(e,this,t).fullPointer,a=r(this.fullPointer,n);let i=[];return a.forEach(o=>{i.push(o.passthrough),i.push(o.before),i.push(o.match),i.push(o.after)}),i=i.filter(o=>o),i=i.map(o=>ld(o,this)),this.update(i)};Go.splitBefore=function(e,t){const{splitAll:r}=this.methods.one.pointer,n=ud(e,this,t).fullPointer,a=r(this.fullPointer,n);for(let o=0;o<a.length;o+=1)!a[o].after&&a[o+1]&&a[o+1].before&&a[o].match&&a[o].match[0]===a[o+1].before[0]&&(a[o].after=a[o+1].before,delete a[o+1].before);let i=[];return a.forEach(o=>{i.push(o.passthrough),i.push(o.before),o.match&&o.after?i.push(sw(o.match,o.after)):i.push(o.match)}),i=i.filter(o=>o),i=i.map(o=>ld(o,this)),this.update(i)};Go.splitAfter=function(e,t){const{splitAll:r}=this.methods.one.pointer,n=ud(e,this,t).fullPointer,a=r(this.fullPointer,n);let i=[];return a.forEach(o=>{i.push(o.passthrough),o.before&&o.match?i.push(sw(o.before,o.match)):(i.push(o.before),i.push(o.match)),i.push(o.after)}),i=i.filter(o=>o),i=i.map(o=>ld(o,this)),this.update(i)};Go.split=Go.splitAfter;const pC=function(e,t){return!e||!t||e[0]!==t[0]?!1:e[2]===t[1]},Ph=function(e,t,r){const n=e.world,a=n.methods.one.parseMatch;t=t||".$",r=r||"^.";const i=a(t,{},n),o=a(r,{},n);i[i.length-1].end=!0,o[0].start=!0;const s=e.fullPointer,u=[s[0]];for(let l=1;l<s.length;l+=1){const c=u[u.length-1],f=s[l],m=e.update([c]),d=e.update([f]);pC(c,f)&&m.has(i)&&d.has(o)?u[u.length-1]=[c[0],c[1],f[2],c[3],f[4]]:u.push(f)}return e.update(u)},gC={joinIf:function(e,t){return Ph(this,e,t)},join:function(){return Ph(this)}},Qn=Object.assign({},sC,dC,Go,gC);Qn.lookBehind=Qn.before;Qn.lookBefore=Qn.before;Qn.lookAhead=Qn.after;Qn.lookAfter=Qn.after;Qn.notIf=Qn.ifNo;const vC=function(e){Object.assign(e.prototype,Qn)},yC=/(?:^|\s)([![^]*(?:<[^<]*>)?\/.*?[^\\/]\/[?\]+*$~]*)(?:\s|$)/,bC=/([!~[^]*(?:<[^<]*>)?\([^)]+[^\\)]\)[?\]+*$~]*)(?:\s|$)/,wC=/ /g,xC=e=>/^[![^]*(<[^<]*>)?\(/.test(e)&&/\)[?\]+*$~]*$/.test(e),kh=e=>/^[![^]*(<[^<]*>)?\//.test(e)&&/\/[?\]+*$~]*$/.test(e),Oh=function(e){return e=e.map(t=>t.trim()),e=e.filter(t=>t),e},DC=function(e){const t=e.split(yC);let r=[];t.forEach(a=>{if(kh(a)){r.push(a);return}r=r.concat(a.split(bC))}),r=Oh(r);let n=[];return r.forEach(a=>{xC(a)||kh(a)?n.push(a):n=n.concat(a.split(wC))}),n=Oh(n),n},$h=/\{([0-9]+)?(, *[0-9]*)?\}/,Bh=/&&/,NC=new RegExp(/^<\s*(\S+)\s*>/),_h=e=>e.charAt(0).toUpperCase()+e.substring(1),xn=e=>e.charAt(e.length-1),cn=e=>e.charAt(0),Po=e=>e.substring(1),ko=e=>e.substring(0,e.length-1),vs=function(e){return e=Po(e),e=ko(e),e},uw=function(e,t){const r={};for(let n=0;n<2;n+=1){if(xn(e)==="$"&&(r.end=!0,e=ko(e)),cn(e)==="^"&&(r.start=!0,e=Po(e)),xn(e)==="?"&&(r.optional=!0,e=ko(e)),(cn(e)==="["||xn(e)==="]")&&(r.group=null,cn(e)==="["&&(r.groupStart=!0),xn(e)==="]"&&(r.groupEnd=!0),e=e.replace(/^\[/,""),e=e.replace(/\]$/,""),cn(e)==="<")){const a=NC.exec(e);a.length>=2&&(r.group=a[1],e=e.replace(a[0],""))}if(xn(e)==="+"&&(r.greedy=!0,e=ko(e)),e!=="*"&&xn(e)==="*"&&e!=="\\*"&&(r.greedy=!0,e=ko(e)),cn(e)==="!"&&(r.negative=!0,e=Po(e)),cn(e)==="~"&&xn(e)==="~"&&e.length>2&&(e=vs(e),r.fuzzy=!0,r.min=t.fuzzy||.85,/\(/.test(e)===!1))return r.word=e,r;if(cn(e)==="/"&&xn(e)==="/")return e=vs(e),t.caseSensitive&&(r.use="text"),r.regex=new RegExp(e),r;if($h.test(e)===!0&&(e=e.replace($h,(a,i,o)=>(o===void 0?(r.min=Number(i),r.max=Number(i)):(o=o.replace(/, */,""),i===void 0?(r.min=0,r.max=Number(o)):(r.min=Number(i),r.max=Number(o||999))),r.greedy=!0,r.min||(r.optional=!0),""))),cn(e)==="("&&xn(e)===")"){Bh.test(e)?(r.choices=e.split(Bh),r.operator="and"):(r.choices=e.split("|"),r.operator="or"),r.choices[0]=Po(r.choices[0]);const a=r.choices.length-1;r.choices[a]=ko(r.choices[a]),r.choices=r.choices.map(i=>i.trim()),r.choices=r.choices.filter(i=>i),r.choices=r.choices.map(i=>i.split(/ /g).map(o=>uw(o,t))),e=""}if(cn(e)==="{"&&xn(e)==="}"){if(e=vs(e),r.root=e,/\//.test(e)){const a=r.root.split(/\//);r.root=a[0],r.pos=a[1],r.pos==="adj"&&(r.pos="Adjective"),r.pos=r.pos.charAt(0).toUpperCase()+r.pos.substr(1).toLowerCase(),a[2]!==void 0&&(r.sense=a[2])}return r}if(cn(e)==="<"&&xn(e)===">")return e=vs(e),r.chunk=_h(e),r.greedy=!0,r;if(cn(e)==="%"&&xn(e)==="%")return e=vs(e),r.switch=e,r}return cn(e)==="#"?(r.tag=Po(e),r.tag=_h(r.tag),r):cn(e)==="@"?(r.method=Po(e),r):e==="."?(r.anything=!0,r):e==="*"?(r.anything=!0,r.greedy=!0,r.optional=!0,r):(e&&(e=e.replace("\\*","*"),e=e.replace("\\.","."),t.caseSensitive?r.use="text":e=e.toLowerCase(),r.word=e),r)},AC=/[a-z0-9][-–—][a-z]/i,CC=function(e,t){const r=t.model.one.prefixes;for(let n=e.length-1;n>=0;n-=1){const a=e[n];if(a.word&&AC.test(a.word)){let i=a.word.split(/[-–—]/g);if(r.hasOwnProperty(i[0]))continue;i=i.filter(o=>o).reverse(),e.splice(n,1),i.forEach(o=>{const s=Object.assign({},a);s.word=o,e.splice(n,0,s)})}}return e},Ih=function(e,t){const{all:r}=t.methods.two.transform.verb||{},n=e.root;return r?r(n,t.model):[]},zh=function(e,t){const{all:r}=t.methods.two.transform.noun||{};return r?r(e.root,t.model):[e.root]},jh=function(e,t){const{all:r}=t.methods.two.transform.adjective||{};return r?r(e.root,t.model):[e.root]},EC=function(e,t){return e=e.map(r=>{if(r.root)if(t.methods.two&&t.methods.two.transform){let n=[];r.pos?r.pos==="Verb"?n=n.concat(Ih(r,t)):r.pos==="Noun"?n=n.concat(zh(r,t)):r.pos==="Adjective"&&(n=n.concat(jh(r,t))):(n=n.concat(Ih(r,t)),n=n.concat(zh(r,t)),n=n.concat(jh(r,t))),n=n.filter(a=>a),n.length>0&&(r.operator="or",r.fastOr=new Set(n))}else r.machine=r.root,delete r.id,delete r.root;return r}),e},SC=function(e){let t=0,r=null;for(let n=0;n<e.length;n++){const a=e[n];a.groupStart===!0&&(r=a.group,r===null&&(r=String(t),t+=1)),r!==null&&(a.group=r),a.groupEnd===!0&&(r=null)}return e},MC=function(e){return e.map(t=>{if(t.choices!==void 0){if(t.operator!=="or"||t.fuzzy===!0)return t;t.choices.every(n=>{if(n.length!==1)return!1;const a=n[0];return a.fuzzy===!0||a.start||a.end?!1:a.word!==void 0&&a.negative!==!0&&a.optional!==!0&&a.method!==!0})===!0&&(t.fastOr=new Set,t.choices.forEach(n=>{t.fastOr.add(n[0].word)}),delete t.choices)}return t})},TC=function(e){return e.map(t=>(t.fuzzy&&t.choices&&t.choices.forEach(r=>{r.length===1&&r[0].word&&(r[0].fuzzy=!0,r[0].min=t.min)}),t))},FC=function(e){return e=SC(e),e=MC(e),e=TC(e),e},PC=function(e,t,r){if(e==null||e==="")return[];t=t||{},typeof e=="number"&&(e=String(e));let n=DC(e);return n=n.map(a=>uw(a,t)),n=CC(n,r),n=EC(n,r),n=FC(n),n},kC=function(e,t){for(const r of t)if(e.has(r))return!0;return!1},OC=function(e,t){for(let r=0;r<e.length;r+=1){const n=e[r];if(!(n.optional===!0||n.negative===!0||n.fuzzy===!0)){if(n.word!==void 0&&t.has(n.word)===!1||n.tag!==void 0&&t.has("#"+n.tag)===!1)return!0;if(n.fastOr&&kC(n.fastOr,t)===!1)return!1}}return!1},$C=function(e,t){const r=e.length,n=t.length;if(r===0)return n;if(n===0)return r;const a=(n>r?n:r)+1;if(Math.abs(r-n)>(a||100))return a||100;const i=[];for(let m=0;m<a;m++)i[m]=[m],i[m].length=a;for(let m=0;m<a;m++)i[0][m]=m;let o,s,u,l,c,f;for(let m=1;m<=r;++m)for(s=e[m-1],o=1;o<=n;++o){if(m===o&&i[m][o]>4)return r;u=t[o-1],l=s===u?0:1,c=i[m-1][o]+1,(f=i[m][o-1]+1)<c&&(c=f),(f=i[m-1][o-1]+l)<c&&(c=f),m>1&&o>1&&s===t[o-2]&&e[m-2]===u&&(f=i[m-2][o-2]+l)<c?i[m][o]=f:i[m][o]=c}return i[r][n]},BC=function(e,t,r=3){if(e===t)return 1;if(e.length<r||t.length<r)return 0;const n=$C(e,t),a=Math.max(e.length,t.length);return 1-(a===0?0:n/a)},_C=/([\u0022\uFF02\u0027\u201C\u2018\u201F\u201B\u201E\u2E42\u201A\u00AB\u2039\u2035\u2036\u2037\u301D\u0060\u301F])/,IC=/([\u0022\uFF02\u0027\u201D\u2019\u00BB\u203A\u2032\u2033\u2034\u301E\u00B4])/,qh=/^[-–—]$/,Rh=/ [-–—]{1,3} /,ia=(e,t)=>e.post.indexOf(t)!==-1,zs={hasQuote:e=>_C.test(e.pre)||IC.test(e.post),hasComma:e=>ia(e,","),hasPeriod:e=>ia(e,".")===!0&&ia(e,"...")===!1,hasExclamation:e=>ia(e,"!"),hasQuestionMark:e=>ia(e,"?")||ia(e,"¿"),hasEllipses:e=>ia(e,"..")||ia(e,"…"),hasSemicolon:e=>ia(e,";"),hasColon:e=>ia(e,":"),hasSlash:e=>/\//.test(e.text),hasHyphen:e=>qh.test(e.post)||qh.test(e.pre),hasDash:e=>Rh.test(e.post)||Rh.test(e.pre),hasContraction:e=>!!e.implicit,isAcronym:e=>e.tags.has("Acronym"),isKnown:e=>e.tags.size>0,isTitleCase:e=>new RegExp("^\\p{Lu}[a-z'\\u00C0-\\u00FF]","u").test(e.text),isUpperCase:e=>new RegExp("^\\p{Lu}+$","u").test(e.text)};zs.hasQuotation=zs.hasQuote;let Nr=function(){};const zC=function(e,t,r,n){if(t.anything===!0)return!0;if(t.start===!0&&r!==0||t.end===!0&&r!==n-1)return!1;if(t.id!==void 0&&t.id===e.id)return!0;if(t.word!==void 0)return t.use?t.word===e[t.use]:e.machine!==null&&e.machine===t.word||e.alias!==void 0&&e.alias.hasOwnProperty(t.word)||t.fuzzy===!0&&(t.word===e.root||BC(t.word,e.normal)>=t.min)||e.alias&&e.alias.some(a=>a===t.word)?!0:t.word===e.text||t.word===e.normal;if(t.tag!==void 0)return e.tags.has(t.tag)===!0;if(t.method!==void 0)return typeof zs[t.method]=="function"&&zs[t.method](e)===!0;if(t.pre!==void 0)return e.pre&&e.pre.includes(t.pre);if(t.post!==void 0)return e.post&&e.post.includes(t.post);if(t.regex!==void 0){let a=e.normal;return t.use&&(a=e[t.use]),t.regex.test(a)}if(t.chunk!==void 0)return e.chunk===t.chunk;if(t.switch!==void 0)return e.switch===t.switch;if(t.machine!==void 0)return e.normal===t.machine||e.machine===t.machine||e.root===t.machine;if(t.sense!==void 0)return e.sense===t.sense;if(t.fastOr!==void 0){if(t.pos&&!e.tags.has(t.pos))return null;const a=e.root||e.implicit||e.machine||e.normal;return t.fastOr.has(a)||t.fastOr.has(e.text)}return t.choices!==void 0?t.operator==="and"?t.choices.every(a=>Nr(e,a,r,n)):t.choices.some(a=>Nr(e,a,r,n)):!1};Nr=function(e,t,r,n){const a=zC(e,t,r,n);return t.negative===!0?!a:a};const jC=function(e,t){const r=Object.assign({},e.regs[e.r],{start:!1,end:!1}),n=e.t;for(;e.t<e.terms.length;e.t+=1){if(t&&Nr(e.terms[e.t],t,e.start_i+e.t,e.phrase_length))return e.t;const a=e.t-n+1;if(r.max!==void 0&&a===r.max)return e.t;if(Nr(e.terms[e.t],r,e.start_i+e.t,e.phrase_length)===!1)return r.min!==void 0&&a<r.min?null:e.t}return e.t},qC=function(e,t){let r=e.t;if(!t)return e.terms.length;for(;r<e.terms.length;r+=1)if(Nr(e.terms[r],t,e.start_i+r,e.phrase_length)===!0)return r;return null},RC=function(e,t){if(e.end===!0&&e.greedy===!0&&t.start_i+t.t<t.phrase_length-1){const r=Object.assign({},e,{end:!1});if(Nr(t.terms[t.t],r,t.start_i+t.t,t.phrase_length)===!0)return!0}return!1},yc=function(e,t){return e.groups[e.inGroup]||(e.groups[e.inGroup]={start:t,length:0}),e.groups[e.inGroup]},LC=function(e){const{regs:t}=e,r=t[e.r],n=qC(e,t[e.r+1]);if(n===null||n===0||r.min!==void 0&&n-e.t<r.min)return null;if(r.max!==void 0&&n-e.t>r.max)return e.t=e.t+r.max,!0;if(e.hasGroup===!0){const a=yc(e,e.t);a.length=n-e.t}return e.t=n,!0},HC=function(e){return Object.prototype.toString.call(e)==="[object Array]"},lw=function(e,t=0){const r=e.regs[e.r];let n=!1;for(let a=0;a<r.choices.length;a+=1){const i=r.choices[a];if(!HC(i))return!1;if(n=i.every((o,s)=>{let u=0;const l=e.t+s+t+u;if(e.terms[l]===void 0)return!1;const c=Nr(e.terms[l],o,l+e.start_i,e.phrase_length);if(c===!0&&o.greedy===!0)for(let f=1;f<e.terms.length;f+=1){const m=e.terms[l+f];if(m)if(Nr(m,o,e.start_i+f,e.phrase_length)===!0)u+=1;else break}return t+=u,c}),n){t+=i.length;break}}return n&&r.greedy===!0?lw(e,t):t},GC=function(e){let t=0;return e.regs[e.r].choices.every(a=>{const i=a.every((o,s)=>{const u=e.t+s;return e.terms[u]===void 0?!1:Nr(e.terms[u],o,u,e.phrase_length)});return i===!0&&a.length>t&&(t=a.length),i})===!0?t:!1},VC=function(e){const{regs:t}=e,r=t[e.r],n=lw(e);if(n){if(r.negative===!0)return null;if(e.hasGroup===!0){const a=yc(e,e.t);a.length+=n}if(r.end===!0){const a=e.phrase_length;if(e.t+e.start_i+n!==a)return null}return e.t+=n,!0}else if(!r.optional)return null;return!0},UC=function(e){const{regs:t}=e,r=t[e.r],n=GC(e);if(n){if(r.negative===!0)return null;if(e.hasGroup===!0){const a=yc(e,e.t);a.length+=n}if(r.end===!0){const a=e.phrase_length-1;if(e.t+e.start_i!==a)return null}return e.t+=n,!0}else if(!r.optional)return null;return!0},WC=function(e,t,r){let n=0;for(let a=e.t;a<e.terms.length;a+=1){let i=Nr(e.terms[a],t,e.start_i+e.t,e.phrase_length);if(i||r&&(i=Nr(e.terms[a],r,e.start_i+e.t,e.phrase_length),i)||(n+=1,t.max!==void 0&&n===t.max))break}return n===0||t.min&&t.min>n?!1:(e.t+=n,!0)},JC=function(e){const{regs:t}=e,r=t[e.r],n=Object.assign({},r);if(n.negative=!1,Nr(e.terms[e.t],n,e.start_i+e.t,e.phrase_length))return!1;if(r.optional){const i=t[e.r+1];i&&(Nr(e.terms[e.t],i,e.start_i+e.t,e.phrase_length)?e.r+=1:i.optional&&t[e.r+2]&&Nr(e.terms[e.t],t[e.r+2],e.start_i+e.t,e.phrase_length)&&(e.r+=2))}return r.greedy?WC(e,n,t[e.r+1]):(e.t+=1,!0)},KC=function(e){const{regs:t}=e,r=t[e.r],n=e.terms[e.t],a=Nr(n,t[e.r+1],e.start_i+e.t,e.phrase_length);if(r.negative||a){const i=e.terms[e.t+1];(!i||!Nr(i,t[e.r+1],e.start_i+e.t,e.phrase_length))&&(e.r+=1)}},YC=function(e){const{regs:t,phrase_length:r}=e,n=t[e.r];return e.t=jC(e,t[e.r+1]),e.t===null||n.min&&n.min>e.t||n.end===!0&&e.start_i+e.t!==r?null:!0},ZC=function(e){const t=e.terms[e.t],r=e.regs[e.r];if(t.implicit&&e.terms[e.t+1]){if(!e.terms[e.t+1].implicit)return;r.word===t.normal&&(e.t+=1),r.method==="hasContraction"&&(e.t+=1)}},QC=function(e,t){const r=e.regs[e.r],n=yc(e,t);e.t>1&&r.greedy?n.length+=e.t-t:n.length++},Zc=function(e){const{regs:t}=e,r=t[e.r],n=e.terms[e.t],a=e.t;return r.optional&&t[e.r+1]&&r.negative?!0:(r.optional&&t[e.r+1]&&KC(e),n.implicit&&e.terms[e.t+1]&&ZC(e),e.t+=1,r.end===!0&&e.t!==e.terms.length&&r.greedy!==!0||r.greedy===!0&&!YC(e)?null:(e.hasGroup===!0&&QC(e,a),!0))},cd=function(e,t,r,n){if(e.length===0||t.length===0)return null;const a={t:0,terms:e,r:0,regs:t,groups:{},start_i:r,phrase_length:n,inGroup:null};for(;a.r<t.length;a.r+=1){const s=t[a.r];if(a.hasGroup=!!s.group,a.hasGroup===!0?a.inGroup=s.group:a.inGroup=null,!a.terms[a.t]){if(t.slice(a.r).some(c=>!c.optional)===!1)break;return null}if(s.anything===!0&&s.greedy===!0){if(!LC(a))return null;continue}if(s.choices!==void 0&&s.operator==="or"){if(!VC(a))return null;continue}if(s.choices!==void 0&&s.operator==="and"){if(!UC(a))return null;continue}if(s.anything===!0){if(s.negative&&s.anything||!Zc(a))return null;continue}if(RC(s,a)===!0){if(!Zc(a))return null;continue}if(s.negative){if(!JC(a))return null;continue}if(Nr(a.terms[a.t],s,a.start_i+a.t,a.phrase_length)===!0){if(!Zc(a))return null;continue}if(s.optional!==!0)return null}const i=[null,r,a.t+r];if(i[1]===i[2])return null;const o={};return Object.keys(a.groups).forEach(s=>{const u=a.groups[s],l=r+u.start;o[s]=[null,l,l+u.length]}),{pointer:i,groups:o}},XC=function(e,t){const r=[],n={};return e.length===0?{ptrs:r,byGroup:n}:(typeof t=="number"&&(t=String(t)),t?e.forEach(a=>{a.groups[t]&&r.push(a.groups[t])}):e.forEach(a=>{r.push(a.pointer),Object.keys(a.groups).forEach(i=>{n[i]=n[i]||[],n[i].push(a.groups[i])})}),{ptrs:r,byGroup:n})},eE=function(e,t,r){return e=e.filter(n=>{const[a,i,o]=n.pointer,s=r[a].slice(i,o);for(let u=0;u<s.length;u+=1){const l=s.slice(u);if(cd(l,t,u,s.length)!==null)return!1}return!0}),e},cw=function(e,t){return e.pointer[0]=t,Object.keys(e.groups).forEach(r=>{e.groups[r][0]=t}),e},tE=function(e,t,r){let n=cd(e,t,0,e.length);return n?(n=cw(n,r),n):null},rE=function(e,t,r){r=r||[];const{regs:n,group:a,justOne:i}=t;let o=[];if(!n||n.length===0)return{ptrs:[],byGroup:{}};const s=n.filter(u=>u.optional!==!0&&u.negative!==!0).length;e:for(let u=0;u<e.length;u+=1){const l=e[u];if(!(r[u]&&OC(n,r[u]))){if(n[0].start===!0){const c=tE(l,n,u);c&&o.push(c);continue}for(let c=0;c<l.length;c+=1){const f=l.slice(c);if(f.length<s)break;let m=cd(f,n,c,l.length);if(m){if(m=cw(m,u),o.push(m),i===!0)break e;const d=m.pointer[2];Math.abs(d-1)>c&&(c=Math.abs(d-1))}}}}return n[n.length-1].end===!0&&(o=o.filter(u=>{const l=u.pointer[0];return e[l].length===u.pointer[2]})),t.notIf&&(o=eE(o,t.notIf,e)),o=XC(o,a),o.ptrs.forEach(u=>{const[l,c,f]=u;u[3]=e[l][c].id,u[4]=e[l][f-1].id}),o},nE={one:{termMethods:zs,parseMatch:PC,match:rE}},aE={parseMatch:function(e,t){const r=this.world(),n=r.methods.one.killUnicode;return n&&(e=n(e,r)),r.methods.one.parseMatch(e,t,r)}},iE={api:vC,methods:nE,lib:aE},oE=/^\../,sE=/^#./,uE=e=>(e=e.replace(/&/g,"&"),e=e.replace(/</g,"<"),e=e.replace(/>/g,">"),e=e.replace(/"/g,"""),e=e.replace(/'/g,"'"),e),lE=function(e){let t="",r="</span>";return e=uE(e),oE.test(e)?t=`<span class="${e.replace(/^\./,"")}"`:sE.test(e)?t=`<span id="${e.replace(/^#/,"")}"`:(t=`<${e}`,r=`</${e}>`),t+=">",{start:t,end:r}},cE=function(e,t){const r={},n={};return Object.keys(t).forEach(a=>{let i=t[a];const o=lE(a);typeof i=="string"&&(i=e.match(i)),i.docs.forEach(s=>{if(s.every(c=>c.implicit))return;const u=s[0].id;r[u]=r[u]||[],r[u].push(o.start);const l=s[s.length-1].id;n[l]=n[l]||[],n[l].push(o.end)})}),{starts:r,ends:n}},fE=function(e){const{starts:t,ends:r}=cE(this,e);let n="";return this.docs.forEach(a=>{for(let i=0;i<a.length;i+=1){const o=a[i];t.hasOwnProperty(o.id)&&(n+=t[o.id].join("")),n+=o.pre||"",n+=o.text||"",r.hasOwnProperty(o.id)&&(n+=r[o.id].join("")),n+=o.post||""}}),n},mE={html:fE},fw=/[,:;)\]*.?~!\u0022\uFF02\u201D\u2019\u00BB\u203A\u2032\u2033\u2034\u301E\u00B4—-]+$/,tm=/^[(['"*~\uFF02\u201C\u2018\u201F\u201B\u201E\u2E42\u201A\u00AB\u2039\u2035\u2036\u2037\u301D\u0060\u301F]+/,dE=/[,:;)('"\u201D\]]/,hE=/^[-–—]$/,pE=/ /,_i=function(e,t,r=!0){let n="";return e.forEach(a=>{let i=a.pre||"",o=a.post||"";t.punctuation==="some"&&(i=i.replace(tm,""),hE.test(o)&&(o=" "),o=o.replace(dE,""),o=o.replace(/\?!+/,"?"),o=o.replace(/!+/,"!"),o=o.replace(/\?+/,"?"),o=o.replace(/\.{2,}/,""),a.tags.has("Abbreviation")&&(o=o.replace(/\./,""))),t.whitespace==="some"&&(i=i.replace(/\s/,""),o=o.replace(/\s+/," ")),t.keepPunct||(i=i.replace(tm,""),o==="-"?o=" ":o=o.replace(fw,""));let s=a[t.form||"text"]||a.normal||"";t.form==="implicit"&&(s=a.implicit||a.text),t.form==="root"&&a.implicit&&(s=a.root||a.implicit||a.normal),(t.form==="machine"||t.form==="implicit"||t.form==="root")&&a.implicit&&(!o||!pE.test(o))&&(o+=" "),n+=i+s+o}),r===!1&&(n=n.trim()),t.lowerCase===!0&&(n=n.toLowerCase()),n},gE=function(e,t){let r="";if(!e||!e[0]||!e[0][0])return r;for(let n=0;n<e.length;n+=1)r+=_i(e[n],t,!0);if(t.keepSpace||(r=r.trim()),t.keepEndPunct===!1){e[0][0].tags.has("Emoticon")||(r=r.replace(tm,""));const n=e[e.length-1];n[n.length-1].tags.has("Emoticon")||(r=r.replace(fw,"")),r.endsWith("'")&&!r.endsWith("s'")&&(r=r.replace(/'/,""))}return t.cleanWhitespace===!0&&(r=r.trim()),r},ci={text:{form:"text"},normal:{whitespace:"some",punctuation:"some",case:"some",unicode:"some",form:"normal"},machine:{keepSpace:!1,whitespace:"some",punctuation:"some",case:"none",unicode:"some",form:"machine"},root:{keepSpace:!1,whitespace:"some",punctuation:"some",case:"some",unicode:"some",form:"root"},implicit:{form:"implicit"}};ci.clean=ci.normal;ci.reduced=ci.root;const mw=[];let Ri=0;for(;Ri<64;)mw[Ri]=0|Math.sin(++Ri%Math.PI)*4294967296;const fd=function(e){let t,r,n,a=decodeURI(encodeURI(e))+"",i=a.length;const o=[t=1732584193,r=4023233417,~t,~r],s=[];for(e=--i/4+2|15,s[--e]=i*8;~i;)s[i>>2]|=a.charCodeAt(i)<<8*i--;for(Ri=a=0;Ri<e;Ri+=16){for(i=o;a<64;i=[n=i[3],t+((n=i[0]+[t&r|~t&n,n&t|~n&r,t^r^n,r^(t|~n)][i=a>>4]+mw[a]+~~s[Ri|[a,5*a+1,3*a+5,7*a][i]&15])<<(i=[7,12,17,22,5,9,14,20,4,11,16,23,6,10,15,21][4*i+a++%4])|n>>>-i),t,r])t=i[1]|0,r=i[2];for(a=4;a;)o[--a]+=i[a]}for(e="";a<32;)e+=(o[a>>3]>>(1^a++)*4&15).toString(16);return e},vE={text:!0,terms:!0},Lh={case:"none",unicode:"some",form:"machine",punctuation:"some"},Qc=function(e,t){return Object.assign({},e,t)},qa={text:e=>_i(e,{keepPunct:!0},!1),normal:e=>_i(e,Qc(ci.normal,{keepPunct:!0}),!1),implicit:e=>_i(e,Qc(ci.implicit,{keepPunct:!0}),!1),machine:e=>_i(e,Lh,!1),root:e=>_i(e,Qc(Lh,{form:"root"}),!1),hash:e=>fd(_i(e,{keepPunct:!0},!1)),offset:e=>{const t=qa.text(e).length;return{index:e[0].offset.index,start:e[0].offset.start,length:t}},terms:e=>e.map(t=>{const r=Object.assign({},t);return r.tags=Array.from(t.tags),r}),confidence:(e,t,r)=>t.eq(r).confidence(),syllables:(e,t,r)=>t.eq(r).syllables(),sentence:(e,t,r)=>t.eq(r).fullSentence().text(),dirty:e=>e.some(t=>t.dirty===!0)};qa.sentences=qa.sentence;qa.clean=qa.normal;qa.reduced=qa.root;const yE=function(e,t){return t=t||{},typeof t=="string"&&(t={}),t=Object.assign({},vE,t),t.offset&&e.compute("offset"),e.docs.map((r,n)=>{const a={};return Object.keys(t).forEach(i=>{t[i]&&qa[i]&&(a[i]=qa[i](r,e,n))}),a})},rm={json:function(e){const t=yE(this,e);return typeof e=="number"?t[e]:t}};rm.data=rm.json;const bE=()=>typeof window<"u"&&window.document,wE=function(e){const t=this.methods.one.debug||{};return e&&t.hasOwnProperty(e)?(t[e](this),this):bE()?(t.clientSide(this),this):(t.tags(this),this)},xE=function(e){const t=e.pre||"",r=e.post||"";return t+e.text+r},DE=function(e,t){const r={};return Object.keys(t).forEach(n=>{e.match(n).fullPointer.forEach(i=>{r[i[3]]={fn:t[n],end:i[2]}})}),r},dw=function(e,t){const r=DE(e,t);let n="";return e.docs.forEach((a,i)=>{for(let o=0;o<a.length;o+=1){const s=a[o];if(r.hasOwnProperty(s.id)){const{fn:u,end:l}=r[s.id],c=e.update([[i,o,l]]);n+=a[o].pre||"",n+=u(c),o=l-1,n+=a[o].post||""}else n+=xE(s)}}),n},NE=e=>Object.prototype.toString.call(e)==="[object Object]",AE=function(e){const t={};return e.forEach(n=>{t[n]=t[n]||0,t[n]+=1}),Object.keys(t).map(n=>({normal:n,count:t[n]})).sort((n,a)=>n.count>a.count?-1:0)},CE=function(e){if(NE(e))return dw(this,e);if(e==="text")return this.text();if(e==="normal")return this.text("normal");if(e==="root")return this.text("root");if(e==="machine"||e==="reduced")return this.text("machine");if(e==="hash"||e==="md5")return fd(this.text());if(e==="json")return this.json();if(e==="offset"||e==="offsets")return this.compute("offset"),this.json({offset:!0});if(e==="array")return this.docs.map(r=>r.reduce((n,a)=>n+a.pre+a.text+a.post,"").trim()).filter(r=>r);if(e==="freq"||e==="frequency"||e==="topk")return AE(this.json({normal:!0}).map(t=>t.normal));if(e==="terms"){let t=[];return this.docs.forEach(r=>{let n=r.map(a=>a.text);n=n.filter(a=>a),t=t.concat(n)}),t}return e==="tags"?this.docs.map(t=>t.reduce((r,n)=>(r[n.implicit||n.normal]=Array.from(n.tags),r),{})):e==="debug"?this.debug():this.text()},EE={debug:wE,out:CE,wrap:function(e){return dw(this,e)}},SE=e=>Object.prototype.toString.call(e)==="[object Object]",ME={text:function(e){let t={};if(e&&typeof e=="string"&&ci.hasOwnProperty(e)?t=Object.assign({},ci[e]):e&&SE(e)&&(t=Object.assign({},e)),t.keepSpace===void 0&&!this.isFull()&&(t.keepSpace=!1),t.keepEndPunct===void 0&&this.pointer){const r=this.pointer[0];r&&r[1]?t.keepEndPunct=!1:t.keepEndPunct=!0}return t.keepPunct===void 0&&(t.keepPunct=!0),t.keepSpace===void 0&&(t.keepSpace=!0),gE(this.docs,t)}},TE=Object.assign({},EE,ME,rm,mE),FE=function(e){Object.assign(e.prototype,TE)},PE=function(e){console.log("%c -=-=- ","background-color:#6699cc;"),e.forEach(t=>{console.groupCollapsed(t.text());const n=t.docs[0].map(a=>{let i=a.text||"-";a.implicit&&(i="["+a.implicit+"]");const o="["+Array.from(a.tags).join(", ")+"]";return{text:i,tags:o}});console.table(n,["text","tags"]),console.groupEnd()})},va="\x1B[0m",dn={green:e=>"\x1B[32m"+e+va,red:e=>"\x1B[31m"+e+va,blue:e=>"\x1B[34m"+e+va,magenta:e=>"\x1B[35m"+e+va,cyan:e=>"\x1B[36m"+e+va,yellow:e=>"\x1B[33m"+e+va,black:e=>"\x1B[30m"+e+va,dim:e=>"\x1B[2m"+e+va,i:e=>"\x1B[3m"+e+va},kE=function(e,t){return t.one.tagSet&&(e=e.map(r=>{if(!t.one.tagSet.hasOwnProperty(r))return r;const n=t.one.tagSet[r].color||"blue";return dn[n](r)})),e.join(", ")},OE=function(e){const{docs:t,model:r}=e;t.length===0&&console.log(dn.blue(`
|
|
3
3
|
──────`)),t.forEach(n=>{console.log(dn.blue(`
|
|
4
4
|
┌─────────`)),n.forEach(a=>{const i=[...a.tags||[]];let o=a.text||"-";a.sense&&(o=`{${a.normal}/${a.sense}}`),a.implicit&&(o="["+a.implicit+"]"),o=dn.yellow(o);let s="'"+o+"'";if(a.reference){const l=e.update([a.reference]).text("normal");s+=` - ${dn.dim(dn.i("["+l+"]"))}`}s=s.padEnd(18);const u=dn.blue(" │ ")+dn.i(s)+" - "+kE(i,r);console.log(u)})}),console.log(`
|
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
import { j as De } from "./jsx-runtime-BbD0H88J.js";
|
|
2
|
-
import { B as sa, r as rw } from "./Button-
|
|
2
|
+
import { B as sa, r as rw } from "./Button-DLtxKGH5.js";
|
|
3
3
|
import { e as Zt, C as nt, A as Ps, E as mn, I as go, M as Yc, v as tm, g as ji, o as ZN } from "./css-BkBrZtKZ.js";
|
|
4
4
|
import QN, { useRef as yh, useMemo as bh, useCallback as ei, useLayoutEffect as XN, useEffect as eA, useState as Rl } from "react";
|
|
5
|
-
import { d as tA } from "./Provider-
|
|
6
|
-
import {
|
|
5
|
+
import { d as tA } from "./Provider-BkxUzTWS.js";
|
|
6
|
+
import { at as rA, k as nA, a6 as aA, D as iA, T as oA, C as Du } from "./Text-XeD58Fq8.js";
|
|
7
7
|
import { p as sA, g as md, a as uA } from "./event-nNH_pXSr.js";
|
|
8
|
-
import { T as rs, F as nw, L as lA } from "./Tags-
|
|
9
|
-
import { D as cA } from "./Dialog-
|
|
10
|
-
import { F as fA, u as mA } from "./Animated-
|
|
8
|
+
import { T as rs, F as nw, L as lA } from "./Tags-V7sNuGZv.js";
|
|
9
|
+
import { D as cA } from "./Dialog-BspO7uo8.js";
|
|
10
|
+
import { F as fA, u as mA } from "./Animated-C4xrEVd-.js";
|
|
11
11
|
import { a as cr, p as dA } from "./Box-DLO7l9hM.js";
|
|
12
12
|
import { T as ca, d as wh, c as xh } from "./Editable-DjQORuR1.js";
|
|
13
13
|
import "./types-B5-Tni3G.js";
|
|
14
|
-
import { a as aw, b as hA, I as pA } from "./Items-
|
|
14
|
+
import { a as aw, b as hA, I as pA } from "./Items-CX11yLMf.js";
|
|
15
15
|
import { u as gA } from "./useStaticData-p8sk2VCJ.js";
|
|
16
16
|
/* empty css */
|
|
17
|
-
import "./eraser-
|
|
18
|
-
import "./Haul-
|
|
19
|
-
import "./provider-
|
|
17
|
+
import "./eraser-DuAfpO0P.js";
|
|
18
|
+
import "./Haul-DBy-2ds_.js";
|
|
19
|
+
import "./provider-D0K9E52u.js";
|
|
20
20
|
const vA = ({
|
|
21
21
|
format: e = "dateTime",
|
|
22
22
|
suppliedTZ: t = "UTC",
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { u as n, C as _, M as v, a as T } from "./Menu-
|
|
1
|
+
import { u as n, C as _, M as v, a as T } from "./Menu-GBo3ayoP.js";
|
|
2
2
|
import { j as a } from "./jsx-runtime-BbD0H88J.js";
|
|
3
3
|
import { C as e } from "./css-BkBrZtKZ.js";
|
|
4
4
|
/* empty css */
|
|
5
5
|
import { a as E } from "./Box-DLO7l9hM.js";
|
|
6
|
-
import { B as j } from "./Button-
|
|
7
|
-
import { C as S, c as b, d as g } from "./Animated-
|
|
6
|
+
import { B as j } from "./Button-DLtxKGH5.js";
|
|
7
|
+
import { C as S, c as b, d as g } from "./Animated-C4xrEVd-.js";
|
|
8
8
|
const i = ({
|
|
9
9
|
className: o,
|
|
10
10
|
padded: t = !1,
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import { j as X } from "./jsx-runtime-BbD0H88J.js";
|
|
2
2
|
import { A as xt, E as Fe, F as rh, Z as te, C as J, e as Dc, T as th, O as nh, u as ah } from "./css-BkBrZtKZ.js";
|
|
3
3
|
import f, { useCallback as Se, isValidElement as ih, PureComponent as jr, Component as Fr, useMemo as Bc, useRef as Mo } from "react";
|
|
4
|
-
import { B as $c } from "./Button-
|
|
5
|
-
import { u as oh, f as Io, a as sh } from "./Haul-
|
|
6
|
-
import { a as uh } from "./Provider-
|
|
7
|
-
import "./provider-
|
|
4
|
+
import { B as $c } from "./Button-DLtxKGH5.js";
|
|
5
|
+
import { u as oh, f as Io, a as sh } from "./Haul-DBy-2ds_.js";
|
|
6
|
+
import { a as uh } from "./Provider-BkxUzTWS.js";
|
|
7
|
+
import "./provider-D0K9E52u.js";
|
|
8
8
|
import { b as lh } from "./types-B5-Tni3G.js";
|
|
9
9
|
import { c as zr, g as nt, s as ch } from "./event-nNH_pXSr.js";
|
|
10
10
|
import { z as de } from "zod";
|
|
11
|
-
import { s as fh, c as hh, H as ph } from "./Text-
|
|
11
|
+
import { s as fh, c as hh, H as ph } from "./Text-XeD58Fq8.js";
|
|
12
12
|
import { c as Lc, T as Hc, d as dh, E as gh } from "./Editable-DjQORuR1.js";
|
|
13
13
|
import { a as qr } from "./Box-DLO7l9hM.js";
|
|
14
|
-
import { D as vh } from "./Dialog-
|
|
15
|
-
import { F as bh } from "./Animated-
|
|
16
|
-
import { u as yh } from "./hooks-
|
|
14
|
+
import { D as vh } from "./Dialog-BspO7uo8.js";
|
|
15
|
+
import { F as bh } from "./Animated-C4xrEVd-.js";
|
|
16
|
+
import { u as yh } from "./hooks-BeSuo_di.js";
|
|
17
17
|
const mh = ({
|
|
18
18
|
onMove: r,
|
|
19
19
|
onStart: e,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const g=require("./provider-
|
|
1
|
+
"use strict";const g=require("./provider-DksyuJua.cjs");require("./css-D3NdC2sx.cjs");const y=require("./types-C0tUDfsz.cjs"),n=[{weight:200,style:"light",value:"Inter 200, sans-serif"},{weight:300,value:"Inter Threee, sans-serif"},{weight:400,value:"Inter Four, sans-serif"},{weight:500,value:"Inter Five, sans-serif"},{weight:600,value:"Inter Six, sans-serif"},{weight:700,value:"Inter Seven, sans-serif"},{weight:800,value:"Inter Eight, sans-serif"},{weight:900,style:"bold",value:"Inter Nine, sans-serif"}],v=s=>n.find((t,e)=>e===n.length-1?!0:typeof s=="number"?s>=t.weight&&s<n[e+1].weight:t.style===s),I=(s,{level:t,weight:e,code:l})=>{const{typography:i,sizes:{base:f}}=s;let r=i.family;if(l)r=i.codeFamily;else if(e!=null){const u=v(e);u!=null?r=u.value:r="Inter Light, sans-serif"}const o=i[g.isSize(t)?y.COMPONENT_SIZE_LEVELS[t]:t].size,a=(f*o).toFixed(1),[h,c]=r.split(", ");return e!=null?` ${e} ${a}px ${h}, ${c}`:` ${a}px ${r}`};exports.fontString=I;
|