@stll/folio-vue 0.26.3 → 0.26.4
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/SplitCellDialog-Dge_CE-B.cjs +15 -0
- package/dist/{SplitCellDialog-bNeugz_3.js → SplitCellDialog-Vl4gq22E.js} +395 -407
- package/dist/{StylePicker-DfIQUq6G.js → StylePicker-bQuysXuB.js} +11 -21
- package/dist/{StylePicker-ynX3GzFu.cjs → StylePicker-hnZuzLnq.cjs} +1 -1
- package/dist/composables.js +8 -15
- package/dist/dialogs.cjs +1 -1
- package/dist/dialogs.js +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +30 -56
- package/dist/messages/ar.cjs +1 -1
- package/dist/messages/cs.cjs +1 -1
- package/dist/messages/de.cjs +1 -1
- package/dist/messages/en.cjs +1 -1
- package/dist/messages/es.cjs +1 -1
- package/dist/messages/et.cjs +1 -1
- package/dist/messages/fr.cjs +1 -1
- package/dist/messages/he.cjs +1 -1
- package/dist/messages/hi.cjs +1 -1
- package/dist/messages/hu.cjs +1 -1
- package/dist/messages/lt.cjs +1 -1
- package/dist/messages/lv.cjs +1 -1
- package/dist/messages/pl.cjs +1 -1
- package/dist/messages/pt-BR.cjs +1 -1
- package/dist/messages/sk.cjs +1 -1
- package/dist/messages/tr.cjs +1 -1
- package/dist/messages/zh-CN.cjs +1 -1
- package/dist/rolldown-runtime-5iZMYShA.cjs +1 -0
- package/dist/styles.js +2 -3
- package/dist/ui.cjs +1 -1
- package/dist/ui.js +5 -8
- package/dist/{useZoom-CX0mrPQY.js → useZoom-C_7cmUyk.js} +8 -16
- package/dist/{zIndex-Ei9BbHSW.js → zIndex-FOGfTBdc.js} +1 -2
- package/package.json +5 -5
- package/dist/SplitCellDialog-DfMw2Ev2.cjs +0 -15
- package/dist/rolldown-runtime-CYJQrBu7.cjs +0 -1
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { A as e, F as t, M as n, N as r, O as i, P as a, _ as o, a as s, c, d as l, f as u, g as d, l as f, m as p, n as m, o as h, p as g, r as _, s as v, t as ee, u as y, y as b } from "./SplitCellDialog-
|
|
2
|
-
import { a as x, c as te, d as ne, i as re, l as ie, o as S, r as ae, s as oe, t as se, u as ce } from "./useZoom-
|
|
3
|
-
import { t as le } from "./zIndex-
|
|
4
|
-
import { D as ue, E as de, d as fe, f as pe, i as me, n as he, r as ge, t as _e, v as ve, w as ye, y as be } from "./StylePicker-
|
|
1
|
+
import { A as e, F as t, M as n, N as r, O as i, P as a, _ as o, a as s, c, d as l, f as u, g as d, l as f, m as p, n as m, o as h, p as g, r as _, s as v, t as ee, u as y, y as b } from "./SplitCellDialog-Vl4gq22E.js";
|
|
2
|
+
import { a as x, c as te, d as ne, i as re, l as ie, o as S, r as ae, s as oe, t as se, u as ce } from "./useZoom-C_7cmUyk.js";
|
|
3
|
+
import { t as le } from "./zIndex-FOGfTBdc.js";
|
|
4
|
+
import { D as ue, E as de, d as fe, f as pe, i as me, n as he, r as ge, t as _e, v as ve, w as ye, y as be } from "./StylePicker-bQuysXuB.js";
|
|
5
5
|
import "./dialogs.js";
|
|
6
6
|
import { Fragment as C, Teleport as xe, computed as w, createApp as Se, createBlock as T, createCommentVNode as E, createElementBlock as D, createElementVNode as O, createSlots as Ce, createStaticVNode as k, createTextVNode as A, createVNode as j, defineComponent as M, h as N, inject as we, mergeProps as Te, nextTick as Ee, normalizeClass as P, normalizeStyle as F, onBeforeUnmount as I, onMounted as De, onScopeDispose as Oe, openBlock as L, provide as ke, ref as R, renderList as z, renderSlot as Ae, shallowRef as je, toDisplayString as B, toRaw as Me, toValue as Ne, unref as V, vModelText as Pe, vShow as Fe, watch as H, withCtx as Ie, withDirectives as Le, withKeys as Re, withModifiers as U } from "vue";
|
|
7
7
|
import { resolveActiveEditorStory as ze } from "@stll/folio-core/controller/activeEditorStory";
|
|
@@ -96,7 +96,7 @@ import { setAISuggestionsMeta as Fi, setFocusedSuggestionMeta as Ii } from "@stl
|
|
|
96
96
|
import { getFolioCaretViewportRect as Li, getFolioSelectionViewportRect as Ri } from "@stll/folio-core/paged-layout/selectionViewportRect";
|
|
97
97
|
import { createAICitationDecorationsPlugin as zi, setAICitationsMeta as Bi, setActiveCitationMeta as Vi } from "@stll/folio-core/prosemirror/plugins/aiCitationDecorations";
|
|
98
98
|
import { fromMarkdown as Hi, toMarkdown as Ui, toMarkdownResult as Wi } from "@stll/folio-core/markdown";
|
|
99
|
-
|
|
99
|
+
// src/composables/commentMarks.ts
|
|
100
100
|
function Gi(e, t) {
|
|
101
101
|
let n = Math.max(0, Math.min(t.from, e)), r = Math.max(n, Math.min(t.to, e));
|
|
102
102
|
return n === r ? null : {
|
|
@@ -118,8 +118,7 @@ function Ji(e, t) {
|
|
|
118
118
|
let n = e.state.schema.marks.comment, r = Gi(e.state.doc.content.size, t);
|
|
119
119
|
n && r && e.dispatch(e.state.tr.removeMark(r.from, r.to, n.create({ commentId: Pt })));
|
|
120
120
|
}
|
|
121
|
-
|
|
122
|
-
//#region src/composables/useCommentLifecycle.ts
|
|
121
|
+
// src/composables/useCommentLifecycle.ts
|
|
123
122
|
var Yi = 408, Xi = 12;
|
|
124
123
|
function Zi(e) {
|
|
125
124
|
let t = R(!1), n = R(null), r = R(null), i = R(null), a = R(null);
|
|
@@ -207,8 +206,7 @@ function Zi(e) {
|
|
|
207
206
|
handleCancelAddComment: d
|
|
208
207
|
};
|
|
209
208
|
}
|
|
210
|
-
|
|
211
|
-
//#region src/composables/useCommentManagement.ts
|
|
209
|
+
// src/composables/useCommentManagement.ts
|
|
212
210
|
function Qi(e) {
|
|
213
211
|
let t = Ft(), n = R([]), r = R(!1);
|
|
214
212
|
function i() {
|
|
@@ -374,8 +372,7 @@ function Qi(e) {
|
|
|
374
372
|
handleRejectChange: ie
|
|
375
373
|
};
|
|
376
374
|
}
|
|
377
|
-
|
|
378
|
-
//#region src/utils/imageClipboard.ts
|
|
375
|
+
// src/utils/imageClipboard.ts
|
|
379
376
|
function $i(e, t, n) {
|
|
380
377
|
let r = Y(e.state), i = e.state.schema.marks.insertion;
|
|
381
378
|
if (!r || !i) return;
|
|
@@ -488,8 +485,7 @@ function aa(e, t) {
|
|
|
488
485
|
} catch {}
|
|
489
486
|
}, r.click();
|
|
490
487
|
}
|
|
491
|
-
|
|
492
|
-
//#region src/composables/useContextMenus.ts
|
|
488
|
+
// src/composables/useContextMenus.ts
|
|
493
489
|
var oa = /* @__PURE__ */ new Set([
|
|
494
490
|
"inline",
|
|
495
491
|
"square",
|
|
@@ -712,8 +708,7 @@ function ua(e) {
|
|
|
712
708
|
handleContextMenuAction: p
|
|
713
709
|
};
|
|
714
710
|
}
|
|
715
|
-
|
|
716
|
-
//#region src/composables/useDocumentLifecycle.ts
|
|
711
|
+
// src/composables/useDocumentLifecycle.ts
|
|
717
712
|
function da(e) {
|
|
718
713
|
async function t(t) {
|
|
719
714
|
e.sidebarAutoOpenedRef.value = !1, await e.loadDocumentBuffer(t);
|
|
@@ -731,8 +726,7 @@ function da(e) {
|
|
|
731
726
|
r ? await t(r) : i && n(i);
|
|
732
727
|
});
|
|
733
728
|
}
|
|
734
|
-
|
|
735
|
-
//#region src/composables/useDocxEditorRefApi.ts
|
|
729
|
+
// src/composables/useDocxEditorRefApi.ts
|
|
736
730
|
var fa = Date.now(), pa = ({ createComment: e, publishComments: t, apply: n }) => {
|
|
737
731
|
let r = [], i = n((t) => {
|
|
738
732
|
let n = e(t);
|
|
@@ -1255,8 +1249,7 @@ function ha(e) {
|
|
|
1255
1249
|
}
|
|
1256
1250
|
} };
|
|
1257
1251
|
}
|
|
1258
|
-
|
|
1259
|
-
//#region src/utils/fontFaces.ts
|
|
1252
|
+
// src/utils/fontFaces.ts
|
|
1260
1253
|
function ga() {
|
|
1261
1254
|
return typeof document > "u" || !("fonts" in document) ? null : document.fonts;
|
|
1262
1255
|
}
|
|
@@ -1273,8 +1266,7 @@ function va(e) {
|
|
|
1273
1266
|
let t = ga();
|
|
1274
1267
|
if (t) for (let n of e) t.delete(n);
|
|
1275
1268
|
}
|
|
1276
|
-
|
|
1277
|
-
//#region src/utils/embeddedFonts.ts
|
|
1269
|
+
// src/utils/embeddedFonts.ts
|
|
1278
1270
|
var ya = {
|
|
1279
1271
|
faces: [],
|
|
1280
1272
|
familyMap: /* @__PURE__ */ new Map()
|
|
@@ -1296,8 +1288,7 @@ async function ba(e) {
|
|
|
1296
1288
|
familyMap: Tr(n)
|
|
1297
1289
|
};
|
|
1298
1290
|
}
|
|
1299
|
-
|
|
1300
|
-
//#region src/utils/hostFonts.ts
|
|
1291
|
+
// src/utils/hostFonts.ts
|
|
1301
1292
|
function xa(e) {
|
|
1302
1293
|
return typeof e == "string" && e.trim().length > 0;
|
|
1303
1294
|
}
|
|
@@ -1324,8 +1315,7 @@ async function wa(e) {
|
|
|
1324
1315
|
let n = Ca(e);
|
|
1325
1316
|
return n.length === 0 ? [] : (await Promise.all(n.map(({ family: e, source: n, descriptors: r }) => _a(t, e, n, r)))).filter((e) => e !== null);
|
|
1326
1317
|
}
|
|
1327
|
-
|
|
1328
|
-
//#region src/composables/useFontLifecycle.ts
|
|
1318
|
+
// src/composables/useFontLifecycle.ts
|
|
1329
1319
|
var Ta = {
|
|
1330
1320
|
loadEmbedded: ba,
|
|
1331
1321
|
loadHost: wa,
|
|
@@ -1353,8 +1343,7 @@ function Ea(e, t = Ta) {
|
|
|
1353
1343
|
t.loadHost(e).then(r);
|
|
1354
1344
|
}, { immediate: !0 });
|
|
1355
1345
|
}
|
|
1356
|
-
|
|
1357
|
-
//#region src/composables/useFormattingActions.ts
|
|
1346
|
+
// src/composables/useFormattingActions.ts
|
|
1358
1347
|
function Da(e) {
|
|
1359
1348
|
let t = () => e.activeView?.value ?? e.editorView.value;
|
|
1360
1349
|
function n() {
|
|
@@ -1400,8 +1389,7 @@ function Da(e) {
|
|
|
1400
1389
|
handleInsertSymbol: s
|
|
1401
1390
|
};
|
|
1402
1391
|
}
|
|
1403
|
-
|
|
1404
|
-
//#region src/composables/useHyperlinkManagement.ts
|
|
1392
|
+
// src/composables/useHyperlinkManagement.ts
|
|
1405
1393
|
function Oa(e) {
|
|
1406
1394
|
let t = R(null);
|
|
1407
1395
|
function n(e, t) {
|
|
@@ -1454,8 +1442,7 @@ function Oa(e) {
|
|
|
1454
1442
|
handleHyperlinkPopupRemove: s
|
|
1455
1443
|
};
|
|
1456
1444
|
}
|
|
1457
|
-
|
|
1458
|
-
//#region src/composables/useImageActions.ts
|
|
1445
|
+
// src/composables/useImageActions.ts
|
|
1459
1446
|
function ka(e) {
|
|
1460
1447
|
let t = je(null), n = R(!1), r = w(() => {
|
|
1461
1448
|
e.stateTick.value;
|
|
@@ -1504,8 +1491,7 @@ function ka(e) {
|
|
|
1504
1491
|
handleImageTransform: o
|
|
1505
1492
|
};
|
|
1506
1493
|
}
|
|
1507
|
-
|
|
1508
|
-
//#region src/composables/useKeyboardShortcuts.ts
|
|
1494
|
+
// src/composables/useKeyboardShortcuts.ts
|
|
1509
1495
|
function Aa(e) {
|
|
1510
1496
|
function t(t) {
|
|
1511
1497
|
if ($e(t, {
|
|
@@ -1520,8 +1506,7 @@ function Aa(e) {
|
|
|
1520
1506
|
}
|
|
1521
1507
|
return De(() => window.addEventListener("keydown", t)), I(() => window.removeEventListener("keydown", t)), { handleKeyDown: t };
|
|
1522
1508
|
}
|
|
1523
|
-
|
|
1524
|
-
//#region src/composables/useOutlineSidebar.ts
|
|
1509
|
+
// src/composables/useOutlineSidebar.ts
|
|
1525
1510
|
function ja(e) {
|
|
1526
1511
|
function t() {
|
|
1527
1512
|
let t = e.editorView.value;
|
|
@@ -1554,8 +1539,7 @@ function ja(e) {
|
|
|
1554
1539
|
recomputeHeadingsIfOpen: r
|
|
1555
1540
|
};
|
|
1556
1541
|
}
|
|
1557
|
-
|
|
1558
|
-
//#region src/composables/usePageSetupControls.ts
|
|
1542
|
+
// src/composables/usePageSetupControls.ts
|
|
1559
1543
|
function Ma(e) {
|
|
1560
1544
|
function t(t) {
|
|
1561
1545
|
if (e.readOnly.value) return;
|
|
@@ -1612,8 +1596,7 @@ function Ma(e) {
|
|
|
1612
1596
|
handleTabStopRemove: u
|
|
1613
1597
|
};
|
|
1614
1598
|
}
|
|
1615
|
-
|
|
1616
|
-
//#region src/utils/textSelection.ts
|
|
1599
|
+
// src/utils/textSelection.ts
|
|
1617
1600
|
var Na = /[\p{L}\p{N}\p{M}_''-]/u, Pa = /\s/;
|
|
1618
1601
|
function Fa(e) {
|
|
1619
1602
|
return !e || e.length === 0 ? !1 : Na.test(e);
|
|
@@ -1639,8 +1622,7 @@ function La(e, t) {
|
|
|
1639
1622
|
}
|
|
1640
1623
|
return [t, t + 1];
|
|
1641
1624
|
}
|
|
1642
|
-
|
|
1643
|
-
//#region src/utils/domQueries.ts
|
|
1625
|
+
// src/utils/domQueries.ts
|
|
1644
1626
|
function Ra(e, t, n) {
|
|
1645
1627
|
let r = n ? Array.from(e.querySelectorAll(`.layout-page-${n} span[data-pm-start][data-pm-end]`)) : Ge(e);
|
|
1646
1628
|
for (let e of r) {
|
|
@@ -1673,8 +1655,7 @@ function Ha(e, t, n, r) {
|
|
|
1673
1655
|
let o = Number(a.dataset.pmStart), s = Number(a.dataset.pmEnd);
|
|
1674
1656
|
!Number.isNaN(o) && !Number.isNaN(s) && o < s && n(o, s);
|
|
1675
1657
|
}
|
|
1676
|
-
|
|
1677
|
-
//#region src/utils/viewportPosition.ts
|
|
1658
|
+
// src/utils/viewportPosition.ts
|
|
1678
1659
|
var Ua = ({ clientX: e, clientY: t, viewport: n }) => ({
|
|
1679
1660
|
left: e - n.left,
|
|
1680
1661
|
top: t - n.top
|
|
@@ -2073,8 +2054,7 @@ function Ka(e) {
|
|
|
2073
2054
|
handleHfRemove: ae
|
|
2074
2055
|
};
|
|
2075
2056
|
}
|
|
2076
|
-
|
|
2077
|
-
//#region src/composables/usePortalClass.ts
|
|
2057
|
+
// src/composables/usePortalClass.ts
|
|
2078
2058
|
var qa = Symbol("docx-portal-class");
|
|
2079
2059
|
function Ja(e) {
|
|
2080
2060
|
ke(qa, w(() => ({
|
|
@@ -2085,8 +2065,7 @@ function Ja(e) {
|
|
|
2085
2065
|
function Ya() {
|
|
2086
2066
|
return we(qa, w(() => ({ "ep-root": !0 })));
|
|
2087
2067
|
}
|
|
2088
|
-
|
|
2089
|
-
//#region src/composables/useRemoteSelectionSync.ts
|
|
2068
|
+
// src/composables/useRemoteSelectionSync.ts
|
|
2090
2069
|
var Xa = (e) => {
|
|
2091
2070
|
let t = new ni(), n = null, r = () => {
|
|
2092
2071
|
n !== null && (cancelAnimationFrame(n), n = null);
|
|
@@ -3367,8 +3346,7 @@ var Xa = (e) => {
|
|
|
3367
3346
|
}), (e, t) => null;
|
|
3368
3347
|
}
|
|
3369
3348
|
});
|
|
3370
|
-
|
|
3371
|
-
//#region src/composables/imageOverlayRect.ts
|
|
3349
|
+
// src/composables/imageOverlayRect.ts
|
|
3372
3350
|
function fs(e) {
|
|
3373
3351
|
let t = Math.max(0, e.parentOffsetWidth - e.parentClientWidth) / 2, n = e.zoom || 1;
|
|
3374
3352
|
return {
|
|
@@ -3378,8 +3356,7 @@ function fs(e) {
|
|
|
3378
3356
|
height: e.imageRect.height / n
|
|
3379
3357
|
};
|
|
3380
3358
|
}
|
|
3381
|
-
|
|
3382
|
-
//#region src/components/ImageSelectionOverlay.vue?vue&type=script&setup=true&lang.ts
|
|
3359
|
+
// src/components/ImageSelectionOverlay.vue?vue&type=script&setup=true&lang.ts
|
|
3383
3360
|
var ps = ["data-handle", "onMousedown"], ms = ["title"], hs = {
|
|
3384
3361
|
key: 0,
|
|
3385
3362
|
class: "image-overlay__dim"
|
|
@@ -5635,13 +5612,11 @@ var ps = ["data-handle", "onMousedown"], ms = ["title"], hs = {
|
|
|
5635
5612
|
], 6));
|
|
5636
5613
|
}
|
|
5637
5614
|
}), [["__scopeId", "data-v-e209de76"]]);
|
|
5638
|
-
|
|
5639
|
-
//#region src/utils/listState.ts
|
|
5615
|
+
// src/utils/listState.ts
|
|
5640
5616
|
function ac() {
|
|
5641
5617
|
return ct;
|
|
5642
5618
|
}
|
|
5643
|
-
|
|
5644
|
-
//#region src/components/FormattingBar.vue?vue&type=script&setup=true&lang.ts
|
|
5619
|
+
// src/components/FormattingBar.vue?vue&type=script&setup=true&lang.ts
|
|
5645
5620
|
var oc = ["aria-label"], sc = ["aria-label"], cc = [
|
|
5646
5621
|
"disabled",
|
|
5647
5622
|
"title",
|
|
@@ -5957,5 +5932,4 @@ var oc = ["aria-label"], sc = ["aria-label"], cc = [
|
|
|
5957
5932
|
} }), l.use(r, a), l.use(te, i), l.mount(t);
|
|
5958
5933
|
});
|
|
5959
5934
|
};
|
|
5960
|
-
//#endregion
|
|
5961
5935
|
export { ro as AutocompleteCaretOverlay, Ai as DEFAULT_AI_SUGGESTION_PRESETS, pn as DEFAULT_AUTOCOMPLETE_DEAD_ZONE_NODES, Di as DOCUMENT_PRESET_VERSION, Oi as DOCUMENT_STYLE_SET_VERSION, ic as DocxEditor, p as FindReplaceDialog, d as FolioUIProvider, v as FootnotePropertiesDialog, mc as FormattingBar, g as HyperlinkDialog, h as ImagePositionDialog, u as ImagePropertiesDialog, s as InsertImageDialog, l as InsertSymbolDialog, _ as InsertTableDialog, y as PageSetupDialog, m as PasteSpecialDialog, wi as STELLA_STYLE_SET_NAME, ee as SplitCellDialog, f as TablePropertiesDialog, c as WatermarkDialog, gc as ZoomControl, mn as acceptAutocompleteSuggestion, hn as acceptAutocompleteWord, ln as anonymizationDecorationsKey, gn as appendAutocompleteToken, Wn as applyFolioAIEditOperations, ji as applySuggestions, _n as autocompleteSuggestionKey, vn as autocompleteSuggestionPlugin, Pi as buildPositionalText, yn as clearAutocompleteSuggestion, kn as clearTemplateSlashMenu, te as colorModePlugin, An as consumeTemplateSlashQuery, zi as createAICitationDecorationsPlugin, ki as createDocx, yi as createEmptyDocument, qn as createFolioAIEditSnapshot, Ti as createStellaStyleDocumentPreset, Ei as createStellaStyleSet, ie as defaultColorMode, n as defaultLocale, yr as deriveBlockId, Zn as diffWordSegments, bi as extractDocumentStyleSet, xi as extractDocumentStyleSetFromDocx, bn as finishAutocompleteSuggestion, Hi as fromMarkdown, un as getAnonymizationMatches, xn as getAutocompleteSuggestion, At as getDocumentWatermark, Li as getFolioCaretViewportRect, br as getFolioParaIdFromBlockId, Ri as getFolioSelectionViewportRect, Tn as getTemplateDirectives, jn as getTemplateSlashMenu, tr as hashFolioAIBlockText, r as i18nPlugin, ft as insertImageFromFile, mt as insertPageBreakInView, gt as insertTableInView, vt as insertTableOfContentsInView, Si as inspectDocumentStyles, Ci as inspectDocumentStylesFromDocx, Sr as isFolioBlockId, Cr as isSequentialFolioBlockId, Mi as isSuggestionStale, Z as normalizeFolioAIBlockText, ce as provideColorMode, a as provideLocale, _c as renderAsync, Mn as resetTemplateSlashQuery, Ni as resolveSuggestionAnchor, Dn as scanDirectives, ei as scrollFolioPositionIntoView, Bi as setAICitationsMeta, Fi as setAISuggestionsMeta, Vi as setActiveCitationMeta, fn as setAnonymizationTermsMeta, Mt as setDocumentWatermark, Ii as setFocusedSuggestionMeta, On as setTemplatePreviewValues, Cn as shouldTriggerAutocomplete, wn as startAutocompleteSuggestion, Nn as templateSlashMenuKey, Ui as toMarkdown, Wi as toMarkdownResult, ne as useColorMode, t as useTranslation, se as useWheelZoom };
|
package/dist/messages/ar.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-5iZMYShA.cjs");let t=require("@stll/folio-core/i18n/messages/ar");t=e.n(t,1),Object.defineProperty(exports,"default",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(exports,"messages",{enumerable:!0,get:function(){return t.messages}});
|
package/dist/messages/cs.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-5iZMYShA.cjs");let t=require("@stll/folio-core/i18n/messages/cs");t=e.n(t,1),Object.defineProperty(exports,"default",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(exports,"messages",{enumerable:!0,get:function(){return t.messages}});
|
package/dist/messages/de.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-5iZMYShA.cjs");let t=require("@stll/folio-core/i18n/messages/de");t=e.n(t,1),Object.defineProperty(exports,"default",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(exports,"messages",{enumerable:!0,get:function(){return t.messages}});
|
package/dist/messages/en.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-5iZMYShA.cjs");let t=require("@stll/folio-core/i18n/messages/en");t=e.n(t,1),Object.defineProperty(exports,"default",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(exports,"messages",{enumerable:!0,get:function(){return t.messages}});
|
package/dist/messages/es.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-5iZMYShA.cjs");let t=require("@stll/folio-core/i18n/messages/es");t=e.n(t,1),Object.defineProperty(exports,"default",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(exports,"messages",{enumerable:!0,get:function(){return t.messages}});
|
package/dist/messages/et.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-5iZMYShA.cjs");let t=require("@stll/folio-core/i18n/messages/et");t=e.n(t,1),Object.defineProperty(exports,"default",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(exports,"messages",{enumerable:!0,get:function(){return t.messages}});
|
package/dist/messages/fr.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-5iZMYShA.cjs");let t=require("@stll/folio-core/i18n/messages/fr");t=e.n(t,1),Object.defineProperty(exports,"default",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(exports,"messages",{enumerable:!0,get:function(){return t.messages}});
|
package/dist/messages/he.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-5iZMYShA.cjs");let t=require("@stll/folio-core/i18n/messages/he");t=e.n(t,1),Object.defineProperty(exports,"default",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(exports,"messages",{enumerable:!0,get:function(){return t.messages}});
|
package/dist/messages/hi.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-5iZMYShA.cjs");let t=require("@stll/folio-core/i18n/messages/hi");t=e.n(t,1),Object.defineProperty(exports,"default",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(exports,"messages",{enumerable:!0,get:function(){return t.messages}});
|
package/dist/messages/hu.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-5iZMYShA.cjs");let t=require("@stll/folio-core/i18n/messages/hu");t=e.n(t,1),Object.defineProperty(exports,"default",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(exports,"messages",{enumerable:!0,get:function(){return t.messages}});
|
package/dist/messages/lt.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-5iZMYShA.cjs");let t=require("@stll/folio-core/i18n/messages/lt");t=e.n(t,1),Object.defineProperty(exports,"default",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(exports,"messages",{enumerable:!0,get:function(){return t.messages}});
|
package/dist/messages/lv.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-5iZMYShA.cjs");let t=require("@stll/folio-core/i18n/messages/lv");t=e.n(t,1),Object.defineProperty(exports,"default",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(exports,"messages",{enumerable:!0,get:function(){return t.messages}});
|
package/dist/messages/pl.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-5iZMYShA.cjs");let t=require("@stll/folio-core/i18n/messages/pl");t=e.n(t,1),Object.defineProperty(exports,"default",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(exports,"messages",{enumerable:!0,get:function(){return t.messages}});
|
package/dist/messages/pt-BR.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-5iZMYShA.cjs");let t=require("@stll/folio-core/i18n/messages/pt-BR");t=e.n(t,1),Object.defineProperty(exports,"default",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(exports,"messages",{enumerable:!0,get:function(){return t.messages}});
|
package/dist/messages/sk.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-5iZMYShA.cjs");let t=require("@stll/folio-core/i18n/messages/sk");t=e.n(t,1),Object.defineProperty(exports,"default",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(exports,"messages",{enumerable:!0,get:function(){return t.messages}});
|
package/dist/messages/tr.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-5iZMYShA.cjs");let t=require("@stll/folio-core/i18n/messages/tr");t=e.n(t,1),Object.defineProperty(exports,"default",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(exports,"messages",{enumerable:!0,get:function(){return t.messages}});
|
package/dist/messages/zh-CN.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../rolldown-runtime-5iZMYShA.cjs");let t=require("@stll/folio-core/i18n/messages/zh-CN");t=e.n(t,1),Object.defineProperty(exports,"default",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(exports,"messages",{enumerable:!0,get:function(){return t.messages}});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t,t.exports),e=null),t.exports),s=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(var c=r(i),l=0,u=c.length,d;l<u;l++)d=c[l],!a.call(e,d)&&d!==o&&t(e,d,{get:(e=>i[e]).bind(null,d),enumerable:!(s=n(i,d))||s.enumerable});return e},c=(n,r,o)=>(o=n==null?{}:e(i(n)),s(r||!n||!n.__esModule||!a.call(n,`default`)?t(o,`default`,{value:n,enumerable:!0}):o,n));Object.defineProperty(exports,"n",{enumerable:!0,get:function(){return c}}),Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return o}});
|
package/dist/styles.js
CHANGED
package/dist/ui.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./SplitCellDialog-DfMw2Ev2.cjs"),t=require("./StylePicker-ynX3GzFu.cjs");let n=require("vue");require("@stll/folio-core/utils/units");var r={class:`docx-editor-toolbar`},i={class:`docx-editor-toolbar__title-row`},a={class:`docx-editor-toolbar__title-left`},o={class:`docx-editor-toolbar__title-center`},s={class:`docx-editor-toolbar__title-right`},c=(0,n.defineComponent)({inheritAttrs:!1,__name:`EditorToolbar`,props:{showMenuBar:{type:Boolean,default:!0}},emits:[`menu-action`],setup(e){return(c,l)=>((0,n.openBlock)(),(0,n.createElementBlock)(`div`,r,[(0,n.renderSlot)(c.$slots,`title-bar`,{},()=>[(0,n.createElementVNode)(`div`,i,[(0,n.createElementVNode)(`div`,a,[(0,n.renderSlot)(c.$slots,`title-bar-left`,{},void 0,!0)]),(0,n.createElementVNode)(`div`,o,[(0,n.renderSlot)(c.$slots,`document-name`,{},void 0,!0),e.showMenuBar?((0,n.openBlock)(),(0,n.createBlock)(t.w,{key:0,onAction:l[0]||=e=>c.$emit(`menu-action`,e)})):(0,n.createCommentVNode)(``,!0)]),(0,n.createElementVNode)(`div`,s,[(0,n.renderSlot)(c.$slots,`title-bar-right`,{},void 0,!0)])])],!0),(0,n.renderSlot)(c.$slots,`toolbar`,{},()=>[(0,n.createVNode)(t.y,(0,n.normalizeProps)((0,n.guardReactiveProps)(c.$attrs)),null,16)],!0)]))}}),l=e.A(c,[[`__scopeId`,`data-v-26fde83c`]]),u={},d={class:`docx-title-bar`},f={class:`docx-title-bar__left`},p={class:`docx-title-bar__center`},m={class:`docx-title-bar__right`};function h(e,t){return(0,n.openBlock)(),(0,n.createElementBlock)(`div`,d,[(0,n.createElementVNode)(`div`,f,[(0,n.renderSlot)(e.$slots,`left`,{},void 0,!0)]),(0,n.createElementVNode)(`div`,p,[(0,n.renderSlot)(e.$slots,`default`,{},void 0,!0)]),(0,n.createElementVNode)(`div`,m,[(0,n.renderSlot)(e.$slots,`right`,{},void 0,!0)])])}var g=e.A(u,[[`render`,h],[`__scopeId`,`data-v-44b23810`]]);function _(e){let t=e.trim();if(!t)return``;let n=null,r=``;for(let e of t)if((e===`"`||e===`'`)&&n===null)n=e,r+=e;else if(e===n)n=null,r+=e;else{if(e===`,`&&n===null)break;r+=e}return r.trim().replace(/^['"]|['"]$/g,``)}var v=[`value`,`disabled`],y={key:0,label:`Sans-serif`},b=[`value`],x={key:1,label:`Serif`},S=[`value`],C={key:2,label:`Monospace`},w=[`value`],T={key:3,label:`Other`},E=[`value`],D=(0,n.defineComponent)({__name:`FontPicker`,props:{value:{},fonts:{},disabled:{type:Boolean,default:!1},className:{},placeholder:{default:`Font`},showPreview:{type:Boolean,default:!0}},emits:[`change`],setup(e,{emit:t}){let r=e,i=t,a=[{name:`Arial`,fontFamily:`Arial, Helvetica, sans-serif`,category:`sans-serif`},{name:`Calibri`,fontFamily:`"Calibri", Arial, sans-serif`,category:`sans-serif`},{name:`Helvetica`,fontFamily:`Helvetica, Arial, sans-serif`,category:`sans-serif`},{name:`Verdana`,fontFamily:`Verdana, Geneva, sans-serif`,category:`sans-serif`},{name:`Open Sans`,fontFamily:`"Open Sans", sans-serif`,category:`sans-serif`},{name:`Roboto`,fontFamily:`Roboto, sans-serif`,category:`sans-serif`},{name:`Times New Roman`,fontFamily:`"Times New Roman", Times, serif`,category:`serif`},{name:`Georgia`,fontFamily:`Georgia, serif`,category:`serif`},{name:`Cambria`,fontFamily:`Cambria, Georgia, serif`,category:`serif`},{name:`Garamond`,fontFamily:`Garamond, serif`,category:`serif`},{name:`Courier New`,fontFamily:`"Courier New", monospace`,category:`monospace`},{name:`Consolas`,fontFamily:`Consolas, monospace`,category:`monospace`}],o=(0,n.computed)(()=>r.fonts??a),s=(0,n.computed)(()=>{let e={"sans-serif":[],serif:[],monospace:[],other:[]};for(let t of o.value)e[t.category??`other`].push(t);return e}),c=(0,n.computed)(()=>{let e=r.value;if(!e)return r.placeholder;let t=e.toLowerCase();return o.value.find(n=>n.fontFamily===e||n.name.toLowerCase()===t||_(n.fontFamily).toLowerCase()===t)?.name??e});function l(e){if(!(e.target instanceof HTMLSelectElement))return;let t=e.target.value,n=o.value.find(e=>e.name===t);i(`change`,n?_(n.fontFamily)||n.name:t)}return(t,r)=>((0,n.openBlock)(),(0,n.createElementBlock)(`select`,{class:(0,n.normalizeClass)([`docx-font-picker`,e.className]),value:c.value,disabled:e.disabled,"aria-label":`Font family`,onChange:l},[s.value[`sans-serif`].length?((0,n.openBlock)(),(0,n.createElementBlock)(`optgroup`,y,[((0,n.openBlock)(!0),(0,n.createElementBlock)(n.Fragment,null,(0,n.renderList)(s.value[`sans-serif`],t=>((0,n.openBlock)(),(0,n.createElementBlock)(`option`,{key:t.name,value:t.name,style:(0,n.normalizeStyle)(e.showPreview?{fontFamily:t.fontFamily}:void 0)},(0,n.toDisplayString)(t.name),13,b))),128))])):(0,n.createCommentVNode)(``,!0),s.value.serif.length?((0,n.openBlock)(),(0,n.createElementBlock)(`optgroup`,x,[((0,n.openBlock)(!0),(0,n.createElementBlock)(n.Fragment,null,(0,n.renderList)(s.value.serif,t=>((0,n.openBlock)(),(0,n.createElementBlock)(`option`,{key:t.name,value:t.name,style:(0,n.normalizeStyle)(e.showPreview?{fontFamily:t.fontFamily}:void 0)},(0,n.toDisplayString)(t.name),13,S))),128))])):(0,n.createCommentVNode)(``,!0),s.value.monospace.length?((0,n.openBlock)(),(0,n.createElementBlock)(`optgroup`,C,[((0,n.openBlock)(!0),(0,n.createElementBlock)(n.Fragment,null,(0,n.renderList)(s.value.monospace,t=>((0,n.openBlock)(),(0,n.createElementBlock)(`option`,{key:t.name,value:t.name,style:(0,n.normalizeStyle)(e.showPreview?{fontFamily:t.fontFamily}:void 0)},(0,n.toDisplayString)(t.name),13,w))),128))])):(0,n.createCommentVNode)(``,!0),s.value.other.length?((0,n.openBlock)(),(0,n.createElementBlock)(`optgroup`,T,[((0,n.openBlock)(!0),(0,n.createElementBlock)(n.Fragment,null,(0,n.renderList)(s.value.other,t=>((0,n.openBlock)(),(0,n.createElementBlock)(`option`,{key:t.name,value:t.name,style:(0,n.normalizeStyle)(e.showPreview?{fontFamily:t.fontFamily}:void 0)},(0,n.toDisplayString)(t.name),13,E))),128))])):(0,n.createCommentVNode)(``,!0)],42,v))}}),O=e.A(D,[[`__scopeId`,`data-v-2312782f`]]),k={class:`docx-font-size`},A=[`disabled`],j=[`value`,`disabled`,`placeholder`],M=[`disabled`],N=(0,n.defineComponent)({__name:`FontSizePicker`,props:{value:{},sizes:{},disabled:{type:Boolean,default:!1},minSize:{default:1},maxSize:{default:1638},placeholder:{default:`11`}},emits:[`change`],setup(e,{emit:t}){let r=e,i=t,a=[8,9,10,11,12,14,16,18,20,24,28,36,48,72],o=(0,n.computed)(()=>r.sizes??a),s=(0,n.computed)(()=>r.value??parseInt(r.placeholder,10)??11),c=(0,n.computed)(()=>r.value===void 0?r.placeholder:String(r.value));function l(e){return o.value.find(t=>t>e)??Math.min(e+1,r.maxSize)}function u(e){return[...o.value].reverse().find(t=>t<e)??Math.max(e-1,r.minSize)}function d(){r.disabled||i(`change`,u(s.value))}function f(){r.disabled||i(`change`,l(s.value))}function p(e){if(!(e.target instanceof HTMLInputElement))return;let t=parseFloat(e.target.value);!isNaN(t)&&t>=r.minSize&&t<=r.maxSize&&i(`change`,Math.round(t*2)/2)}return(t,r)=>((0,n.openBlock)(),(0,n.createElementBlock)(`div`,k,[(0,n.createElementVNode)(`button`,{type:`button`,class:`docx-font-size__btn`,disabled:e.disabled||s.value<=e.minSize,title:`Decrease font size`,onClick:(0,n.withModifiers)(d,[`prevent`])},` − `,8,A),(0,n.createElementVNode)(`input`,{class:`docx-font-size__input`,type:`text`,value:c.value,disabled:e.disabled,placeholder:e.placeholder,onKeydown:[r[0]||=(0,n.withKeys)((0,n.withModifiers)(e=>{d(),e.stopPropagation()},[`prevent`]),[`up`]),r[1]||=(0,n.withKeys)((0,n.withModifiers)(e=>{f(),e.stopPropagation()},[`prevent`]),[`down`]),r[2]||=(0,n.withKeys)((0,n.withModifiers)(e=>p(e),[`prevent`]),[`enter`])],onBlur:r[3]||=e=>p(e)},null,40,j),(0,n.createElementVNode)(`button`,{type:`button`,class:`docx-font-size__btn`,disabled:e.disabled||s.value>=e.maxSize,title:`Increase font size`,onClick:(0,n.withModifiers)(f,[`prevent`])},` + `,8,M)]))}}),P=e.A(N,[[`__scopeId`,`data-v-68e0de03`]]),F=[`value`,`disabled`],I=[`value`],L=(0,n.defineComponent)({__name:`LineSpacingPicker`,props:{value:{},options:{},disabled:{type:Boolean,default:!1},className:{}},emits:[`change`],setup(e,{emit:t}){let r=e,i=t,a=[{label:`Single`,value:1,twipsValue:240},{label:`1.15`,value:1.15,twipsValue:276},{label:`1.5`,value:1.5,twipsValue:360},{label:`Double`,value:2,twipsValue:480}],o=(0,n.computed)(()=>r.options??a),s=(0,n.computed)(()=>r.value??o.value[0]?.twipsValue??240);function c(e){if(!(e.target instanceof HTMLSelectElement))return;let t=parseInt(e.target.value,10);isNaN(t)||i(`change`,t)}return(t,r)=>((0,n.openBlock)(),(0,n.createElementBlock)(`select`,{class:(0,n.normalizeClass)([`docx-line-spacing`,e.className]),value:String(s.value),disabled:e.disabled,"aria-label":`Line spacing`,onChange:c},[((0,n.openBlock)(!0),(0,n.createElementBlock)(n.Fragment,null,(0,n.renderList)(o.value,e=>((0,n.openBlock)(),(0,n.createElementBlock)(`option`,{key:e.twipsValue,value:String(e.twipsValue)},(0,n.toDisplayString)(e.label),9,I))),128))],42,F))}}),R=e.A(L,[[`__scopeId`,`data-v-95197324`]]),z=[`disabled`,`aria-expanded`,`title`,`onClick`],B={class:`docx-table-grid__panel`},V={class:`docx-table-grid__label`},H=[`onMouseenter`,`onClick`],U=(0,n.defineComponent)({__name:`TableGridPicker`,props:{disabled:{type:Boolean,default:!1},gridRows:{default:5},gridColumns:{default:5},tooltip:{default:`Insert table`}},emits:[`insert`],setup(t,{emit:r}){let{Popover:i}=e.y(),a=t,o=r,s=(0,n.ref)(!1),c=(0,n.ref)({rows:1,cols:1}),l=(0,n.computed)(()=>{let e=[];for(let t=1;t<=a.gridRows;t++)for(let n=1;n<=a.gridColumns;n++)e.push({r:t,c:n});return e});function u(e,t){o(`insert`,e,t),s.value=!1}function d(){s.value=!1,c.value={rows:1,cols:1}}return(r,a)=>((0,n.openBlock)(),(0,n.createBlock)((0,n.unref)(i),{open:s.value,"onUpdate:open":a[0]||=e=>s.value=e,onClose:d},{trigger:(0,n.withCtx)(({toggle:r})=>[(0,n.createElementVNode)(`button`,{type:`button`,class:`docx-table-grid__btn`,disabled:t.disabled,"aria-expanded":s.value,"aria-haspopup":`grid`,title:t.tooltip,onClick:(0,n.withModifiers)(r,[`prevent`])},[(0,n.createVNode)(e.O,{name:`grid_on`,size:20})],8,z)]),panel:(0,n.withCtx)(()=>[(0,n.createElementVNode)(`div`,B,[(0,n.createElementVNode)(`div`,V,(0,n.toDisplayString)(c.value.rows)+` × `+(0,n.toDisplayString)(c.value.cols),1),(0,n.createElementVNode)(`div`,{class:`docx-table-grid__grid`,style:(0,n.normalizeStyle)({gridTemplateColumns:`repeat(${t.gridColumns}, 18px)`})},[((0,n.openBlock)(!0),(0,n.createElementBlock)(n.Fragment,null,(0,n.renderList)(l.value,e=>((0,n.openBlock)(),(0,n.createElementBlock)(`button`,{key:`${e.r}-${e.c}`,class:(0,n.normalizeClass)([`docx-table-grid__cell`,{"docx-table-grid__cell--active":e.r<=c.value.rows&&e.c<=c.value.cols}]),onMouseenter:t=>c.value={rows:e.r,cols:e.c},onClick:(0,n.withModifiers)(t=>u(e.r,e.c),[`prevent`])},null,42,H))),128))],4)])]),_:1},8,[`open`]))}}),W=e.A(U,[[`__scopeId`,`data-v-f503bba5`]]),G=[`disabled`,`title`],K={key:0,class:`print-btn__icon`},q=(0,n.defineComponent)({__name:`PrintButton`,props:{disabled:{type:Boolean,default:!1},label:{default:`Print`},compact:{type:Boolean,default:!1}},emits:[`print`],setup(e,{emit:t}){let r=e,i=t;function a(){r.disabled||(i(`print`),window.print())}return(t,r)=>((0,n.openBlock)(),(0,n.createElementBlock)(`button`,{class:`print-btn`,disabled:e.disabled,title:e.label,onMousedown:(0,n.withModifiers)(a,[`prevent`])},[(0,n.createTextVNode)((0,n.toDisplayString)(e.compact?``:e.label)+` `,1),e.compact?((0,n.openBlock)(),(0,n.createElementBlock)(`span`,K,`🖨`)):(0,n.createCommentVNode)(``,!0)],40,G))}}),J=e.A(q,[[`__scopeId`,`data-v-d5f13ca1`]]),Y={padding:`8px 10px`,borderRadius:8,backgroundColor:`var(--doc-card)`,cursor:`pointer`,boxShadow:`var(--doc-card-shadow)`},X={padding:`10px 12px`,borderRadius:8,backgroundColor:`var(--doc-surface)`,cursor:`pointer`,boxShadow:`var(--doc-card-shadow-strong)`};exports.AddCommentCard=t.u,exports.AlignmentButtons=t.r,exports.Button=e.j,exports.CARD_STYLE_COLLAPSED=Y,exports.CARD_STYLE_EXPANDED=X,exports.Checkbox=e.k,exports.ColorPicker=e.D,exports.CommentCard=t.s,exports.CommentMarginMarkers=t.D,exports.DEFAULT_COMPONENTS=e.h,exports.DatePickerPopover=e.E,exports.Dialog=e.T,exports.DocumentName=t.E,exports.EditingModeDropdown=t.C,exports.EditorToolbar=l,exports.FindReplaceDialog=e.m,exports.FontPicker=O,exports.FontSizePicker=P,exports.FootnotePropertiesDialog=e.s,exports.HorizontalRuler=t.v,exports.HyperlinkDialog=e.p,exports.IconGridDropdown=t.S,exports.ImagePositionDialog=e.o,exports.ImagePropertiesDialog=e.f,exports.ImageTransformDropdown=t.x,exports.ImageWrapDropdown=t.b,exports.Input=e.w,exports.InsertImageDialog=e.a,exports.InsertSymbolDialog=e.d,exports.InsertTableDialog=e.r,exports.LineSpacingPicker=R,exports.ListButtons=t.n,exports.MenuBar=t.w,exports.MenuDropdown=e.S,exports.OutlineRail=e.x,exports.PageSetupDialog=e.u,exports.PasteSpecialDialog=e.n,exports.Popover=e.C,exports.PrintButton=J,exports.ReplyInput=t.l,exports.ReplyThread=t.c,exports.ResolvedCommentMarker=t.o,exports.Select=e.b,exports.SplitCellDialog=e.t,exports.StylePicker=t.t,exports.TableBorderColorPicker=t._,exports.TableBorderPicker=t.g,exports.TableBorderWidthPicker=t.h,exports.TableCellFillPicker=t.m,exports.TableGridInline=t.T,exports.TableGridPicker=W,exports.TableMoreDropdown=t.p,exports.TablePropertiesDialog=e.l,exports.TableStyleGallery=e.i,exports.TableToolbar=t.f,exports.TitleBar=g,exports.Toolbar=t.y,exports.TrackedChangeCard=t.a,exports.UnifiedSidebar=t.i,exports.VerticalRuler=t.d,exports.WatermarkDialog=e.c,exports.provideFolioUI=e._,exports.resolveFolioComponents=e.v,exports.useFolioUI=e.y;
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./SplitCellDialog-Dge_CE-B.cjs"),t=require("./StylePicker-hnZuzLnq.cjs");let n=require("vue");require("@stll/folio-core/utils/units");var r={class:`docx-editor-toolbar`},i={class:`docx-editor-toolbar__title-row`},a={class:`docx-editor-toolbar__title-left`},o={class:`docx-editor-toolbar__title-center`},s={class:`docx-editor-toolbar__title-right`},c=(0,n.defineComponent)({inheritAttrs:!1,__name:`EditorToolbar`,props:{showMenuBar:{type:Boolean,default:!0}},emits:[`menu-action`],setup(e){return(c,l)=>((0,n.openBlock)(),(0,n.createElementBlock)(`div`,r,[(0,n.renderSlot)(c.$slots,`title-bar`,{},()=>[(0,n.createElementVNode)(`div`,i,[(0,n.createElementVNode)(`div`,a,[(0,n.renderSlot)(c.$slots,`title-bar-left`,{},void 0,!0)]),(0,n.createElementVNode)(`div`,o,[(0,n.renderSlot)(c.$slots,`document-name`,{},void 0,!0),e.showMenuBar?((0,n.openBlock)(),(0,n.createBlock)(t.w,{key:0,onAction:l[0]||=e=>c.$emit(`menu-action`,e)})):(0,n.createCommentVNode)(``,!0)]),(0,n.createElementVNode)(`div`,s,[(0,n.renderSlot)(c.$slots,`title-bar-right`,{},void 0,!0)])])],!0),(0,n.renderSlot)(c.$slots,`toolbar`,{},()=>[(0,n.createVNode)(t.y,(0,n.normalizeProps)((0,n.guardReactiveProps)(c.$attrs)),null,16)],!0)]))}}),l=e.A(c,[[`__scopeId`,`data-v-26fde83c`]]),u={},d={class:`docx-title-bar`},f={class:`docx-title-bar__left`},p={class:`docx-title-bar__center`},m={class:`docx-title-bar__right`};function h(e,t){return(0,n.openBlock)(),(0,n.createElementBlock)(`div`,d,[(0,n.createElementVNode)(`div`,f,[(0,n.renderSlot)(e.$slots,`left`,{},void 0,!0)]),(0,n.createElementVNode)(`div`,p,[(0,n.renderSlot)(e.$slots,`default`,{},void 0,!0)]),(0,n.createElementVNode)(`div`,m,[(0,n.renderSlot)(e.$slots,`right`,{},void 0,!0)])])}var g=e.A(u,[[`render`,h],[`__scopeId`,`data-v-44b23810`]]);function _(e){let t=e.trim();if(!t)return``;let n=null,r=``;for(let e of t)if((e===`"`||e===`'`)&&n===null)n=e,r+=e;else if(e===n)n=null,r+=e;else{if(e===`,`&&n===null)break;r+=e}return r.trim().replace(/^['"]|['"]$/g,``)}var v=[`value`,`disabled`],y={key:0,label:`Sans-serif`},b=[`value`],x={key:1,label:`Serif`},S=[`value`],C={key:2,label:`Monospace`},w=[`value`],T={key:3,label:`Other`},E=[`value`],D=(0,n.defineComponent)({__name:`FontPicker`,props:{value:{},fonts:{},disabled:{type:Boolean,default:!1},className:{},placeholder:{default:`Font`},showPreview:{type:Boolean,default:!0}},emits:[`change`],setup(e,{emit:t}){let r=e,i=t,a=[{name:`Arial`,fontFamily:`Arial, Helvetica, sans-serif`,category:`sans-serif`},{name:`Calibri`,fontFamily:`"Calibri", Arial, sans-serif`,category:`sans-serif`},{name:`Helvetica`,fontFamily:`Helvetica, Arial, sans-serif`,category:`sans-serif`},{name:`Verdana`,fontFamily:`Verdana, Geneva, sans-serif`,category:`sans-serif`},{name:`Open Sans`,fontFamily:`"Open Sans", sans-serif`,category:`sans-serif`},{name:`Roboto`,fontFamily:`Roboto, sans-serif`,category:`sans-serif`},{name:`Times New Roman`,fontFamily:`"Times New Roman", Times, serif`,category:`serif`},{name:`Georgia`,fontFamily:`Georgia, serif`,category:`serif`},{name:`Cambria`,fontFamily:`Cambria, Georgia, serif`,category:`serif`},{name:`Garamond`,fontFamily:`Garamond, serif`,category:`serif`},{name:`Courier New`,fontFamily:`"Courier New", monospace`,category:`monospace`},{name:`Consolas`,fontFamily:`Consolas, monospace`,category:`monospace`}],o=(0,n.computed)(()=>r.fonts??a),s=(0,n.computed)(()=>{let e={"sans-serif":[],serif:[],monospace:[],other:[]};for(let t of o.value)e[t.category??`other`].push(t);return e}),c=(0,n.computed)(()=>{let e=r.value;if(!e)return r.placeholder;let t=e.toLowerCase();return o.value.find(n=>n.fontFamily===e||n.name.toLowerCase()===t||_(n.fontFamily).toLowerCase()===t)?.name??e});function l(e){if(!(e.target instanceof HTMLSelectElement))return;let t=e.target.value,n=o.value.find(e=>e.name===t);i(`change`,n?_(n.fontFamily)||n.name:t)}return(t,r)=>((0,n.openBlock)(),(0,n.createElementBlock)(`select`,{class:(0,n.normalizeClass)([`docx-font-picker`,e.className]),value:c.value,disabled:e.disabled,"aria-label":`Font family`,onChange:l},[s.value[`sans-serif`].length?((0,n.openBlock)(),(0,n.createElementBlock)(`optgroup`,y,[((0,n.openBlock)(!0),(0,n.createElementBlock)(n.Fragment,null,(0,n.renderList)(s.value[`sans-serif`],t=>((0,n.openBlock)(),(0,n.createElementBlock)(`option`,{key:t.name,value:t.name,style:(0,n.normalizeStyle)(e.showPreview?{fontFamily:t.fontFamily}:void 0)},(0,n.toDisplayString)(t.name),13,b))),128))])):(0,n.createCommentVNode)(``,!0),s.value.serif.length?((0,n.openBlock)(),(0,n.createElementBlock)(`optgroup`,x,[((0,n.openBlock)(!0),(0,n.createElementBlock)(n.Fragment,null,(0,n.renderList)(s.value.serif,t=>((0,n.openBlock)(),(0,n.createElementBlock)(`option`,{key:t.name,value:t.name,style:(0,n.normalizeStyle)(e.showPreview?{fontFamily:t.fontFamily}:void 0)},(0,n.toDisplayString)(t.name),13,S))),128))])):(0,n.createCommentVNode)(``,!0),s.value.monospace.length?((0,n.openBlock)(),(0,n.createElementBlock)(`optgroup`,C,[((0,n.openBlock)(!0),(0,n.createElementBlock)(n.Fragment,null,(0,n.renderList)(s.value.monospace,t=>((0,n.openBlock)(),(0,n.createElementBlock)(`option`,{key:t.name,value:t.name,style:(0,n.normalizeStyle)(e.showPreview?{fontFamily:t.fontFamily}:void 0)},(0,n.toDisplayString)(t.name),13,w))),128))])):(0,n.createCommentVNode)(``,!0),s.value.other.length?((0,n.openBlock)(),(0,n.createElementBlock)(`optgroup`,T,[((0,n.openBlock)(!0),(0,n.createElementBlock)(n.Fragment,null,(0,n.renderList)(s.value.other,t=>((0,n.openBlock)(),(0,n.createElementBlock)(`option`,{key:t.name,value:t.name,style:(0,n.normalizeStyle)(e.showPreview?{fontFamily:t.fontFamily}:void 0)},(0,n.toDisplayString)(t.name),13,E))),128))])):(0,n.createCommentVNode)(``,!0)],42,v))}}),O=e.A(D,[[`__scopeId`,`data-v-2312782f`]]),k={class:`docx-font-size`},A=[`disabled`],j=[`value`,`disabled`,`placeholder`],M=[`disabled`],N=(0,n.defineComponent)({__name:`FontSizePicker`,props:{value:{},sizes:{},disabled:{type:Boolean,default:!1},minSize:{default:1},maxSize:{default:1638},placeholder:{default:`11`}},emits:[`change`],setup(e,{emit:t}){let r=e,i=t,a=[8,9,10,11,12,14,16,18,20,24,28,36,48,72],o=(0,n.computed)(()=>r.sizes??a),s=(0,n.computed)(()=>r.value??parseInt(r.placeholder,10)??11),c=(0,n.computed)(()=>r.value===void 0?r.placeholder:String(r.value));function l(e){return o.value.find(t=>t>e)??Math.min(e+1,r.maxSize)}function u(e){return[...o.value].reverse().find(t=>t<e)??Math.max(e-1,r.minSize)}function d(){r.disabled||i(`change`,u(s.value))}function f(){r.disabled||i(`change`,l(s.value))}function p(e){if(!(e.target instanceof HTMLInputElement))return;let t=parseFloat(e.target.value);!isNaN(t)&&t>=r.minSize&&t<=r.maxSize&&i(`change`,Math.round(t*2)/2)}return(t,r)=>((0,n.openBlock)(),(0,n.createElementBlock)(`div`,k,[(0,n.createElementVNode)(`button`,{type:`button`,class:`docx-font-size__btn`,disabled:e.disabled||s.value<=e.minSize,title:`Decrease font size`,onClick:(0,n.withModifiers)(d,[`prevent`])},` − `,8,A),(0,n.createElementVNode)(`input`,{class:`docx-font-size__input`,type:`text`,value:c.value,disabled:e.disabled,placeholder:e.placeholder,onKeydown:[r[0]||=(0,n.withKeys)((0,n.withModifiers)(e=>{d(),e.stopPropagation()},[`prevent`]),[`up`]),r[1]||=(0,n.withKeys)((0,n.withModifiers)(e=>{f(),e.stopPropagation()},[`prevent`]),[`down`]),r[2]||=(0,n.withKeys)((0,n.withModifiers)(e=>p(e),[`prevent`]),[`enter`])],onBlur:r[3]||=e=>p(e)},null,40,j),(0,n.createElementVNode)(`button`,{type:`button`,class:`docx-font-size__btn`,disabled:e.disabled||s.value>=e.maxSize,title:`Increase font size`,onClick:(0,n.withModifiers)(f,[`prevent`])},` + `,8,M)]))}}),P=e.A(N,[[`__scopeId`,`data-v-68e0de03`]]),F=[`value`,`disabled`],I=[`value`],L=(0,n.defineComponent)({__name:`LineSpacingPicker`,props:{value:{},options:{},disabled:{type:Boolean,default:!1},className:{}},emits:[`change`],setup(e,{emit:t}){let r=e,i=t,a=[{label:`Single`,value:1,twipsValue:240},{label:`1.15`,value:1.15,twipsValue:276},{label:`1.5`,value:1.5,twipsValue:360},{label:`Double`,value:2,twipsValue:480}],o=(0,n.computed)(()=>r.options??a),s=(0,n.computed)(()=>r.value??o.value[0]?.twipsValue??240);function c(e){if(!(e.target instanceof HTMLSelectElement))return;let t=parseInt(e.target.value,10);isNaN(t)||i(`change`,t)}return(t,r)=>((0,n.openBlock)(),(0,n.createElementBlock)(`select`,{class:(0,n.normalizeClass)([`docx-line-spacing`,e.className]),value:String(s.value),disabled:e.disabled,"aria-label":`Line spacing`,onChange:c},[((0,n.openBlock)(!0),(0,n.createElementBlock)(n.Fragment,null,(0,n.renderList)(o.value,e=>((0,n.openBlock)(),(0,n.createElementBlock)(`option`,{key:e.twipsValue,value:String(e.twipsValue)},(0,n.toDisplayString)(e.label),9,I))),128))],42,F))}}),R=e.A(L,[[`__scopeId`,`data-v-95197324`]]),z=[`disabled`,`aria-expanded`,`title`,`onClick`],B={class:`docx-table-grid__panel`},V={class:`docx-table-grid__label`},H=[`onMouseenter`,`onClick`],U=(0,n.defineComponent)({__name:`TableGridPicker`,props:{disabled:{type:Boolean,default:!1},gridRows:{default:5},gridColumns:{default:5},tooltip:{default:`Insert table`}},emits:[`insert`],setup(t,{emit:r}){let{Popover:i}=e.y(),a=t,o=r,s=(0,n.ref)(!1),c=(0,n.ref)({rows:1,cols:1}),l=(0,n.computed)(()=>{let e=[];for(let t=1;t<=a.gridRows;t++)for(let n=1;n<=a.gridColumns;n++)e.push({r:t,c:n});return e});function u(e,t){o(`insert`,e,t),s.value=!1}function d(){s.value=!1,c.value={rows:1,cols:1}}return(r,a)=>((0,n.openBlock)(),(0,n.createBlock)((0,n.unref)(i),{open:s.value,"onUpdate:open":a[0]||=e=>s.value=e,onClose:d},{trigger:(0,n.withCtx)(({toggle:r})=>[(0,n.createElementVNode)(`button`,{type:`button`,class:`docx-table-grid__btn`,disabled:t.disabled,"aria-expanded":s.value,"aria-haspopup":`grid`,title:t.tooltip,onClick:(0,n.withModifiers)(r,[`prevent`])},[(0,n.createVNode)(e.O,{name:`grid_on`,size:20})],8,z)]),panel:(0,n.withCtx)(()=>[(0,n.createElementVNode)(`div`,B,[(0,n.createElementVNode)(`div`,V,(0,n.toDisplayString)(c.value.rows)+` × `+(0,n.toDisplayString)(c.value.cols),1),(0,n.createElementVNode)(`div`,{class:`docx-table-grid__grid`,style:(0,n.normalizeStyle)({gridTemplateColumns:`repeat(${t.gridColumns}, 18px)`})},[((0,n.openBlock)(!0),(0,n.createElementBlock)(n.Fragment,null,(0,n.renderList)(l.value,e=>((0,n.openBlock)(),(0,n.createElementBlock)(`button`,{key:`${e.r}-${e.c}`,class:(0,n.normalizeClass)([`docx-table-grid__cell`,{"docx-table-grid__cell--active":e.r<=c.value.rows&&e.c<=c.value.cols}]),onMouseenter:t=>c.value={rows:e.r,cols:e.c},onClick:(0,n.withModifiers)(t=>u(e.r,e.c),[`prevent`])},null,42,H))),128))],4)])]),_:1},8,[`open`]))}}),W=e.A(U,[[`__scopeId`,`data-v-f503bba5`]]),G=[`disabled`,`title`],K={key:0,class:`print-btn__icon`},q=(0,n.defineComponent)({__name:`PrintButton`,props:{disabled:{type:Boolean,default:!1},label:{default:`Print`},compact:{type:Boolean,default:!1}},emits:[`print`],setup(e,{emit:t}){let r=e,i=t;function a(){r.disabled||(i(`print`),window.print())}return(t,r)=>((0,n.openBlock)(),(0,n.createElementBlock)(`button`,{class:`print-btn`,disabled:e.disabled,title:e.label,onMousedown:(0,n.withModifiers)(a,[`prevent`])},[(0,n.createTextVNode)((0,n.toDisplayString)(e.compact?``:e.label)+` `,1),e.compact?((0,n.openBlock)(),(0,n.createElementBlock)(`span`,K,`🖨`)):(0,n.createCommentVNode)(``,!0)],40,G))}}),J=e.A(q,[[`__scopeId`,`data-v-d5f13ca1`]]),Y={padding:`8px 10px`,borderRadius:8,backgroundColor:`var(--doc-card)`,cursor:`pointer`,boxShadow:`var(--doc-card-shadow)`},X={padding:`10px 12px`,borderRadius:8,backgroundColor:`var(--doc-surface)`,cursor:`pointer`,boxShadow:`var(--doc-card-shadow-strong)`};exports.AddCommentCard=t.u,exports.AlignmentButtons=t.r,exports.Button=e.j,exports.CARD_STYLE_COLLAPSED=Y,exports.CARD_STYLE_EXPANDED=X,exports.Checkbox=e.k,exports.ColorPicker=e.D,exports.CommentCard=t.s,exports.CommentMarginMarkers=t.D,exports.DEFAULT_COMPONENTS=e.h,exports.DatePickerPopover=e.E,exports.Dialog=e.T,exports.DocumentName=t.E,exports.EditingModeDropdown=t.C,exports.EditorToolbar=l,exports.FindReplaceDialog=e.m,exports.FontPicker=O,exports.FontSizePicker=P,exports.FootnotePropertiesDialog=e.s,exports.HorizontalRuler=t.v,exports.HyperlinkDialog=e.p,exports.IconGridDropdown=t.S,exports.ImagePositionDialog=e.o,exports.ImagePropertiesDialog=e.f,exports.ImageTransformDropdown=t.x,exports.ImageWrapDropdown=t.b,exports.Input=e.w,exports.InsertImageDialog=e.a,exports.InsertSymbolDialog=e.d,exports.InsertTableDialog=e.r,exports.LineSpacingPicker=R,exports.ListButtons=t.n,exports.MenuBar=t.w,exports.MenuDropdown=e.S,exports.OutlineRail=e.x,exports.PageSetupDialog=e.u,exports.PasteSpecialDialog=e.n,exports.Popover=e.C,exports.PrintButton=J,exports.ReplyInput=t.l,exports.ReplyThread=t.c,exports.ResolvedCommentMarker=t.o,exports.Select=e.b,exports.SplitCellDialog=e.t,exports.StylePicker=t.t,exports.TableBorderColorPicker=t._,exports.TableBorderPicker=t.g,exports.TableBorderWidthPicker=t.h,exports.TableCellFillPicker=t.m,exports.TableGridInline=t.T,exports.TableGridPicker=W,exports.TableMoreDropdown=t.p,exports.TablePropertiesDialog=e.l,exports.TableStyleGallery=e.i,exports.TableToolbar=t.f,exports.TitleBar=g,exports.Toolbar=t.y,exports.TrackedChangeCard=t.a,exports.UnifiedSidebar=t.i,exports.VerticalRuler=t.d,exports.WatermarkDialog=e.c,exports.provideFolioUI=e._,exports.resolveFolioComponents=e.v,exports.useFolioUI=e.y;
|
package/dist/ui.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { A as e, C as t, D as n, E as r, O as i, S as a, T as o, _ as s, a as c, b as l, c as u, d, f, h as ee, i as te, j as ne, k as re, l as ie, m as ae, n as oe, o as se, p as ce, r as p, s as le, t as ue, u as de, v as m, w as fe, x as pe, y as h } from "./SplitCellDialog-
|
|
2
|
-
import { C as me, D as he, E as ge, S as _e, T as ve, _ as ye, a as be, b as g, c as _, d as v, f as y, g as b, h as x, i as S, l as C, m as w, n as T, o as E, p as D, r as O, s as k, t as A, u as j, v as M, w as N, x as xe, y as P } from "./StylePicker-
|
|
1
|
+
import { A as e, C as t, D as n, E as r, O as i, S as a, T as o, _ as s, a as c, b as l, c as u, d, f, h as ee, i as te, j as ne, k as re, l as ie, m as ae, n as oe, o as se, p as ce, r as p, s as le, t as ue, u as de, v as m, w as fe, x as pe, y as h } from "./SplitCellDialog-Vl4gq22E.js";
|
|
2
|
+
import { C as me, D as he, E as ge, S as _e, T as ve, _ as ye, a as be, b as g, c as _, d as v, f as y, g as b, h as x, i as S, l as C, m as w, n as T, o as E, p as D, r as O, s as k, t as A, u as j, v as M, w as N, x as xe, y as P } from "./StylePicker-bQuysXuB.js";
|
|
3
3
|
import { Fragment as F, computed as I, createBlock as L, createCommentVNode as R, createElementBlock as z, createElementVNode as B, createTextVNode as Se, createVNode as V, defineComponent as H, guardReactiveProps as Ce, normalizeClass as U, normalizeProps as we, normalizeStyle as W, openBlock as G, ref as K, renderList as q, renderSlot as J, toDisplayString as Y, unref as Te, withCtx as X, withKeys as Z, withModifiers as Q } from "vue";
|
|
4
4
|
import "@stll/folio-core/utils/units";
|
|
5
|
-
|
|
5
|
+
// src/components/EditorToolbar.vue?vue&type=script&setup=true&lang.ts
|
|
6
6
|
var Ee = { class: "docx-editor-toolbar" }, De = { class: "docx-editor-toolbar__title-row" }, Oe = { class: "docx-editor-toolbar__title-left" }, ke = { class: "docx-editor-toolbar__title-center" }, Ae = { class: "docx-editor-toolbar__title-right" }, je = /*#__PURE__*/ e(/* @__PURE__ */ H({
|
|
7
7
|
inheritAttrs: !1,
|
|
8
8
|
__name: "EditorToolbar",
|
|
@@ -30,8 +30,7 @@ function Le(e, t) {
|
|
|
30
30
|
]);
|
|
31
31
|
}
|
|
32
32
|
var Re = /*#__PURE__*/ e(Me, [["render", Le], ["__scopeId", "data-v-44b23810"]]);
|
|
33
|
-
|
|
34
|
-
//#region src/components/ui/fontPickerValue.ts
|
|
33
|
+
// src/components/ui/fontPickerValue.ts
|
|
35
34
|
function $(e) {
|
|
36
35
|
let t = e.trim();
|
|
37
36
|
if (!t) return "";
|
|
@@ -44,8 +43,7 @@ function $(e) {
|
|
|
44
43
|
}
|
|
45
44
|
return r.trim().replace(/^['"]|['"]$/g, "");
|
|
46
45
|
}
|
|
47
|
-
|
|
48
|
-
//#region src/components/ui/FontPicker.vue?vue&type=script&setup=true&lang.ts
|
|
46
|
+
// src/components/ui/FontPicker.vue?vue&type=script&setup=true&lang.ts
|
|
49
47
|
var ze = ["value", "disabled"], Be = {
|
|
50
48
|
key: 0,
|
|
51
49
|
label: "Sans-serif"
|
|
@@ -435,5 +433,4 @@ var ze = ["value", "disabled"], Be = {
|
|
|
435
433
|
cursor: "pointer",
|
|
436
434
|
boxShadow: "var(--doc-card-shadow-strong)"
|
|
437
435
|
};
|
|
438
|
-
//#endregion
|
|
439
436
|
export { j as AddCommentCard, O as AlignmentButtons, ne as Button, dt as CARD_STYLE_COLLAPSED, ft as CARD_STYLE_EXPANDED, re as Checkbox, n as ColorPicker, k as CommentCard, he as CommentMarginMarkers, ee as DEFAULT_COMPONENTS, r as DatePickerPopover, o as Dialog, ge as DocumentName, me as EditingModeDropdown, je as EditorToolbar, ae as FindReplaceDialog, Je as FontPicker, $e as FontSizePicker, le as FootnotePropertiesDialog, M as HorizontalRuler, ce as HyperlinkDialog, _e as IconGridDropdown, se as ImagePositionDialog, f as ImagePropertiesDialog, xe as ImageTransformDropdown, g as ImageWrapDropdown, fe as Input, c as InsertImageDialog, d as InsertSymbolDialog, p as InsertTableDialog, nt as LineSpacingPicker, T as ListButtons, N as MenuBar, a as MenuDropdown, pe as OutlineRail, de as PageSetupDialog, oe as PasteSpecialDialog, t as Popover, ut as PrintButton, C as ReplyInput, _ as ReplyThread, E as ResolvedCommentMarker, l as Select, ue as SplitCellDialog, A as StylePicker, ye as TableBorderColorPicker, b as TableBorderPicker, x as TableBorderWidthPicker, w as TableCellFillPicker, ve as TableGridInline, st as TableGridPicker, D as TableMoreDropdown, ie as TablePropertiesDialog, te as TableStyleGallery, y as TableToolbar, Re as TitleBar, P as Toolbar, be as TrackedChangeCard, S as UnifiedSidebar, v as VerticalRuler, u as WatermarkDialog, s as provideFolioUI, m as resolveFolioComponents, h as useFolioUI };
|
|
@@ -43,7 +43,7 @@ import { createFindSearchKey as Ye, sameFindSearchKey as Xe } from "@stll/folio-
|
|
|
43
43
|
import { MIN_CELL_WIDTH_TWIPS as Ze, MIN_ROW_HEIGHT_TWIPS as D, TWIPS_PER_PIXEL as O, clampRowResizeDelta as Qe, commitColumnResize as $e, commitRightEdgeResize as et, commitRowResize as tt, readColumnWidthAt as nt, readColumnWidths as rt, readRowHeight as it } from "@stll/folio-core/prosemirror/tableResize";
|
|
44
44
|
import { extractTrackedChanges as at } from "@stll/folio-core/prosemirror/utils/extractTrackedChanges";
|
|
45
45
|
import { ZOOM_MAX as ot, ZOOM_MIN as k, ZOOM_STEP as A } from "@stll/folio-core/utils/zoom";
|
|
46
|
-
|
|
46
|
+
// src/utils/colorMode.ts
|
|
47
47
|
var st = "(prefers-color-scheme: dark)";
|
|
48
48
|
function j() {
|
|
49
49
|
return typeof window < "u" && typeof window.matchMedia == "function";
|
|
@@ -58,8 +58,7 @@ function N(e) {
|
|
|
58
58
|
let n = (t) => e(t.matches);
|
|
59
59
|
return t.addEventListener("change", n), () => t.removeEventListener("change", n);
|
|
60
60
|
}
|
|
61
|
-
|
|
62
|
-
//#region src/composables/useColorMode.ts
|
|
61
|
+
// src/composables/useColorMode.ts
|
|
63
62
|
var P = "light", F = Symbol("folioColorMode"), I = (t = P) => {
|
|
64
63
|
a(F, e(() => l(t)));
|
|
65
64
|
}, ct = { install(t, n = P) {
|
|
@@ -75,8 +74,7 @@ function L() {
|
|
|
75
74
|
}));
|
|
76
75
|
}), e(() => M(n.value, i.value && a.value));
|
|
77
76
|
}
|
|
78
|
-
|
|
79
|
-
//#region src/composables/useDocxEditor.ts
|
|
77
|
+
// src/composables/useDocxEditor.ts
|
|
80
78
|
var lt = 24, ut = "User", dt = 250, ft = [], pt = [];
|
|
81
79
|
function mt(e) {
|
|
82
80
|
let t = e?.columnCount ?? 1;
|
|
@@ -671,8 +669,7 @@ function yt(e) {
|
|
|
671
669
|
destroy: un
|
|
672
670
|
};
|
|
673
671
|
}
|
|
674
|
-
|
|
675
|
-
//#region src/composables/useFindReplace.ts
|
|
672
|
+
// src/composables/useFindReplace.ts
|
|
676
673
|
function bt({ editorView: t, pagesRef: n, getDocument: r, layout: a, commentRoot: l, revealComment: d, displayMode: f, readOnly: p, onReadonlyEditAttempt: m, onResultChange: h }) {
|
|
677
674
|
let g = new Ue(), _ = s(""), v = s(""), te = o(qe()), y = c([]), b = s(-1), x = e(() => y.value.at(b.value) ?? null), ne = () => ee({
|
|
678
675
|
editingMode: t.value?.editable === !1 ? "viewing" : "editing",
|
|
@@ -797,8 +794,7 @@ function z(e, t) {
|
|
|
797
794
|
}
|
|
798
795
|
return 0;
|
|
799
796
|
}
|
|
800
|
-
|
|
801
|
-
//#region src/composables/useDragAutoScroll.ts
|
|
797
|
+
// src/composables/useDragAutoScroll.ts
|
|
802
798
|
function B({ pagesContainer: e, onScrollExtendSelection: t }) {
|
|
803
799
|
let n = null, r = 0, a = 0, o = !1;
|
|
804
800
|
function s() {
|
|
@@ -830,8 +826,7 @@ function B({ pagesContainer: e, onScrollExtendSelection: t }) {
|
|
|
830
826
|
stopAutoScroll: c
|
|
831
827
|
};
|
|
832
828
|
}
|
|
833
|
-
|
|
834
|
-
//#region src/composables/useTableResize.ts
|
|
829
|
+
// src/composables/useTableResize.ts
|
|
835
830
|
function V() {
|
|
836
831
|
let e = {
|
|
837
832
|
active: !1,
|
|
@@ -939,13 +934,11 @@ function xt(e, t) {
|
|
|
939
934
|
let n = nt(e, t.tablePmStart, t.columnIndex);
|
|
940
935
|
n != null && (t.origWidth = n);
|
|
941
936
|
}
|
|
942
|
-
|
|
943
|
-
//#region src/composables/useTrackedChanges.ts
|
|
937
|
+
// src/composables/useTrackedChanges.ts
|
|
944
938
|
function W(t, n) {
|
|
945
939
|
return e(() => (n.value, at(t.value?.state ?? null)));
|
|
946
940
|
}
|
|
947
|
-
|
|
948
|
-
//#region src/composables/useZoom.ts
|
|
941
|
+
// src/composables/useZoom.ts
|
|
949
942
|
var St = k, Ct = ot, wt = [
|
|
950
943
|
.5,
|
|
951
944
|
.75,
|
|
@@ -992,5 +985,4 @@ function Tt(t = 1) {
|
|
|
992
985
|
ZOOM_PRESETS: wt
|
|
993
986
|
};
|
|
994
987
|
}
|
|
995
|
-
//#endregion
|
|
996
988
|
export { B as a, ct as c, L as d, V as i, P as l, at as n, bt as o, W as r, yt as s, Tt as t, I as u };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stll/folio-vue",
|
|
3
|
-
"version": "0.26.
|
|
3
|
+
"version": "0.26.4",
|
|
4
4
|
"description": "Vue 3 editor for folio: a Word-document (.docx) editor for the browser, built on @stll/folio-core and ProseMirror.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"document-editor",
|
|
@@ -87,8 +87,8 @@
|
|
|
87
87
|
"@fontsource/noto-sans-arabic": "^5.2.7",
|
|
88
88
|
"@fontsource/source-sans-3": "^5.3.1",
|
|
89
89
|
"@fontsource/tinos": "^5.2.7",
|
|
90
|
-
"@stll/folio-core": "^0.
|
|
91
|
-
"@stll/utf8-boundaries": "0.
|
|
90
|
+
"@stll/folio-core": "^0.65.0",
|
|
91
|
+
"@stll/utf8-boundaries": "0.2.0",
|
|
92
92
|
"better-result": "3.0.1",
|
|
93
93
|
"use-intl": "^4.14.9"
|
|
94
94
|
},
|
|
@@ -99,8 +99,8 @@
|
|
|
99
99
|
"prosemirror-model": "^1.25.9",
|
|
100
100
|
"prosemirror-state": "^1.4.4",
|
|
101
101
|
"prosemirror-tables": "^1.8.5",
|
|
102
|
-
"prosemirror-view": "^1.42.
|
|
103
|
-
"vite": "8.3.
|
|
102
|
+
"prosemirror-view": "^1.42.7",
|
|
103
|
+
"vite": "8.3.5",
|
|
104
104
|
"vite-plugin-dts": "^5.1.2",
|
|
105
105
|
"vue": "^3.5.44",
|
|
106
106
|
"vue-tsc": "^3.3.13",
|