@harbour-enterprises/superdoc 0.10.63 → 0.10.65
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/chunks/{super-editor.es-DB2c7BO2.es.js → super-editor.es-Br9eH3cn.es.js} +9 -7
- package/dist/chunks/{super-editor.es-hVKxdScp.cjs → super-editor.es-zve2N3NE.cjs} +4 -4
- package/dist/super-editor/ai-writer.es.js +2 -3
- package/dist/super-editor/chunks/{converter-Dq3TlpdQ.js → converter-CPw1nhKU.js} +7 -4
- package/dist/super-editor/chunks/{docx-zipper-Sybgd_NX.js → docx-zipper-DmUudu9K.js} +1 -1
- package/dist/super-editor/chunks/{editor-8LEG4GZ5.js → editor-ByusZHOE.js} +3 -3
- package/dist/super-editor/chunks/{toolbar-DK1oYzms.js → toolbar-BwyACjtB.js} +2 -2
- package/dist/super-editor/components/toolbar/ai-helpers.d.ts.map +1 -1
- package/dist/super-editor/converter.es.js +1 -1
- package/dist/super-editor/docx-zipper.es.js +2 -2
- package/dist/super-editor/editor.es.js +3 -3
- package/dist/super-editor/file-zipper.es.js +1 -1
- package/dist/super-editor/super-editor.es.js +6 -6
- package/dist/super-editor/toolbar.es.js +2 -2
- package/dist/super-editor.cjs +1 -1
- package/dist/super-editor.es.js +1 -1
- package/dist/superdoc.cjs +2 -2
- package/dist/superdoc.es.js +3 -3
- package/dist/superdoc.umd.js +10 -8
- package/dist/superdoc.umd.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ref as l, onMounted as R, onUnmounted as K, computed as I, createElementBlock as f, openBlock as g, withModifiers as S, createElementVNode as m, withDirectives as V, unref as w, vModelText as W, createCommentVNode as j, nextTick as B } from "vue";
|
|
2
|
-
import { _ as G } from "./chunks/editor-
|
|
2
|
+
import { _ as G } from "./chunks/editor-ByusZHOE.js";
|
|
3
3
|
const X = "https://sd-dev-express-gateway-i6xtm.ondigitalocean.app/insights", C = "You are an expert copywriter and you are immersed in a document editor. You are to provide document related text responses based on the user prompts. Only write what is asked for. Do not provide explanations. Try to keep placeholders as short as possible. Do not output your prompt. Your instructions are: ";
|
|
4
4
|
async function E(a, e = {}) {
|
|
5
5
|
const n = e.apiKey, r = e.endpoint || X;
|
|
@@ -11,8 +11,7 @@ async function E(a, e = {}) {
|
|
|
11
11
|
const o = await fetch(r, {
|
|
12
12
|
method: "POST",
|
|
13
13
|
headers: s,
|
|
14
|
-
body: JSON.stringify(a)
|
|
15
|
-
credentials: "include"
|
|
14
|
+
body: JSON.stringify(a)
|
|
16
15
|
});
|
|
17
16
|
if (!o.ok) {
|
|
18
17
|
const c = await o.text();
|
|
@@ -16493,7 +16493,10 @@ function xp(r) {
|
|
|
16493
16493
|
const Ap = (r, e, t) => {
|
|
16494
16494
|
const i = r["word/_rels/document.xml.rels"].elements.find((g) => g.name === "Relationships"), { elements: s } = i, o = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/header", a = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/footer", u = s.filter((g) => g.attributes.Type === o), f = s.filter((g) => g.attributes.Type === a), h = (Eu(r["word/document.xml"]) || []).flatMap((g) => g.elements);
|
|
16495
16495
|
u.forEach((g) => {
|
|
16496
|
-
const { rId: v, referenceFile: A, currentFileName: E } = qo(g, r)
|
|
16496
|
+
const { rId: v, referenceFile: A, currentFileName: E } = qo(g, r);
|
|
16497
|
+
let w = h.find((D) => D.name === "w:headerReference" && D.attributes["r:id"] === v)?.attributes["w:type"];
|
|
16498
|
+
e.headerIds[w] && (w = null);
|
|
16499
|
+
const B = Jt(), R = B.handler({
|
|
16497
16500
|
nodes: A.elements[0].elements,
|
|
16498
16501
|
nodeListHandler: B,
|
|
16499
16502
|
docx: r,
|
|
@@ -16501,7 +16504,7 @@ const Ap = (r, e, t) => {
|
|
|
16501
16504
|
editor: t,
|
|
16502
16505
|
filename: E
|
|
16503
16506
|
});
|
|
16504
|
-
e.headerIds.ids || (e.headerIds.ids = []), e.headerIds.ids.push(v), e.headers[v] = { type: "doc", content: [...R] }, e.headerIds[w] = v;
|
|
16507
|
+
e.headerIds.ids || (e.headerIds.ids = []), e.headerIds.ids.push(v), e.headers[v] = { type: "doc", content: [...R] }, w && (e.headerIds[w] = v);
|
|
16505
16508
|
}), f.forEach((g) => {
|
|
16506
16509
|
const { rId: v, referenceFile: A, currentFileName: E } = qo(g, r), w = h.find((D) => D.name === "w:footerReference" && D.attributes["r:id"] === v)?.attributes["w:type"], B = Jt(), R = B.handler({
|
|
16507
16510
|
nodes: A.elements[0].elements,
|
|
@@ -16575,7 +16578,7 @@ const mt = class mt {
|
|
|
16575
16578
|
return;
|
|
16576
16579
|
}
|
|
16577
16580
|
}
|
|
16578
|
-
static updateDocumentVersion(e = this.convertedXml, t = "0.10.
|
|
16581
|
+
static updateDocumentVersion(e = this.convertedXml, t = "0.10.65") {
|
|
16579
16582
|
const n = "docProps/custom.xml";
|
|
16580
16583
|
e[n] || (e[n] = Fu());
|
|
16581
16584
|
const i = e["docProps/custom.xml"];
|
|
@@ -16836,7 +16839,7 @@ function vp(r) {
|
|
|
16836
16839
|
function Fu() {
|
|
16837
16840
|
return Gf;
|
|
16838
16841
|
}
|
|
16839
|
-
function Bu(r = 2, e = "0.10.
|
|
16842
|
+
function Bu(r = 2, e = "0.10.65") {
|
|
16840
16843
|
return {
|
|
16841
16844
|
type: "element",
|
|
16842
16845
|
name: "property",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { p as Tt, a0 as wt, B as ut, a1 as Bt, a2 as Rt } from "./converter-
|
|
1
|
+
import { p as Tt, a0 as wt, B as ut, a1 as Bt, a2 as Rt } from "./converter-CPw1nhKU.js";
|
|
2
2
|
function kt(bt) {
|
|
3
3
|
throw new Error('Could not dynamically require "' + bt + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.');
|
|
4
4
|
}
|
|
@@ -7,9 +7,9 @@ var I = (e, t, n) => vf(e, typeof t != "symbol" ? t + "" : t, n), Xo = (e, t, n)
|
|
|
7
7
|
var Qe = (e, t, n) => (Xo(e, t, "read from private field"), n ? n.call(e) : t.get(e)), ft = (e, t, n) => t.has(e) ? ta("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), Jo = (e, t, n, r) => (Xo(e, t, "write to private field"), r ? r.call(e, n) : t.set(e, n), n), N = (e, t, n) => (Xo(e, t, "access private method"), n);
|
|
8
8
|
import * as T from "yjs";
|
|
9
9
|
import { UndoManager as kf, Item as xf, ContentType as Cf, Text as Mf, XmlElement as Sf } from "yjs";
|
|
10
|
-
import { P as Y, a as G, M as dr, c as X, N as z, S as Q, T as j, b as W, D as Vn, F as P, d as nn, e as Af, f as tc, A as Or, p as oe, B as Of, i as Tf, g as nc, h as Df, j as wt, l as Tr, k as Ht, m as rc, r as oc, R as ln, o as ur, n as na, q as $t, s as xi, t as ic, u as Nf, v as Ef, w as de, x as Ve, y as Ro, z as xn, C as yo, E as Pf, G as Ce, H as io, I as sc, J as Cn, K as Yo, L as Go, O as Zo, Q as so, U as Rt, V as Lo, W as If, X as ra, Y as oa, Z as Rf, _ as Lf, $ as Ff } from "./converter-
|
|
10
|
+
import { P as Y, a as G, M as dr, c as X, N as z, S as Q, T as j, b as W, D as Vn, F as P, d as nn, e as Af, f as tc, A as Or, p as oe, B as Of, i as Tf, g as nc, h as Df, j as wt, l as Tr, k as Ht, m as rc, r as oc, R as ln, o as ur, n as na, q as $t, s as xi, t as ic, u as Nf, v as Ef, w as de, x as Ve, y as Ro, z as xn, C as yo, E as Pf, G as Ce, H as io, I as sc, J as Cn, K as Yo, L as Go, O as Zo, Q as so, U as Rt, V as Lo, W as If, X as ra, Y as oa, Z as Rf, _ as Lf, $ as Ff } from "./converter-CPw1nhKU.js";
|
|
11
11
|
import { ref as ia, computed as Bf, createElementBlock as Kt, openBlock as Xt, withModifiers as Qo, Fragment as zf, renderList as _f, normalizeClass as $f, createCommentVNode as sa, toDisplayString as ei, createElementVNode as Vf, createApp as Hf } from "vue";
|
|
12
|
-
import { D as aa } from "./docx-zipper-
|
|
12
|
+
import { D as aa } from "./docx-zipper-DmUudu9K.js";
|
|
13
13
|
function Fo(e) {
|
|
14
14
|
const { from: t, to: n, empty: r } = e.selection, o = [];
|
|
15
15
|
return r ? (e.storedMarks && o.push(...e.storedMarks), o.push(...e.selection.$head.marks())) : e.doc.nodesBetween(t, n, (i) => {
|
|
@@ -10048,7 +10048,7 @@ const Qs = class Qs extends bg {
|
|
|
10048
10048
|
* @returns {Y.Doc | undefined} Updated Y.Doc if any, otherwise undefined
|
|
10049
10049
|
*/
|
|
10050
10050
|
processCollaborationMigrations() {
|
|
10051
|
-
if (console.debug("[checkVersionMigrations] Current editor version", "0.10.
|
|
10051
|
+
if (console.debug("[checkVersionMigrations] Current editor version", "0.10.65"), !this.options.ydoc) return;
|
|
10052
10052
|
let r = this.options.ydoc.getMap("meta").get("version");
|
|
10053
10053
|
r || (r = "initial"), console.debug("[checkVersionMigrations] Document version", r);
|
|
10054
10054
|
const o = ol(r) || [], s = this.state.plugins.find((c) => c.key.startsWith("y-sync"));
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { computed as _, createElementBlock as se, openBlock as q, createElementVNode as pn, createCommentVNode as pe, normalizeClass as Jt, normalizeStyle as Et, ref as R, unref as W, createBlock as Ge, toDisplayString as ni, withDirectives as dt, withKeys as Nr, withModifiers as Hr, vModelText as jr, getCurrentInstance as It, createVNode as At, readonly as Qt, watch as we, onMounted as Ke, onBeforeUnmount as Be, reactive as Ks, onBeforeMount as dr, inject as te, onActivated as Vs, onDeactivated as ri, createTextVNode as Mt, Fragment as _e, Comment as fr, defineComponent as ee, provide as Se, h as A, Teleport as Us, toRef as ie, nextTick as Gs, renderSlot as Xs, isVNode as qs, shallowRef as Ys, watchEffect as ft, mergeProps as pt, Transition as en, vShow as Zs, cloneVNode as Js, Text as Qs, renderList as el, withCtx as Bn } from "vue";
|
|
2
|
-
import { p as tn } from "./converter-
|
|
3
|
-
import { _ as vt, g as Pt } from "./editor-
|
|
2
|
+
import { p as tn } from "./converter-CPw1nhKU.js";
|
|
3
|
+
import { _ as vt, g as Pt } from "./editor-ByusZHOE.js";
|
|
4
4
|
const B0 = (e, t) => {
|
|
5
5
|
let n = e.replace(/[^0-9.]/g, "");
|
|
6
6
|
return n = parseFloat(n), isNaN(n) && (n = t), n = parseFloat(n), n;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ai-helpers.d.ts","sourceRoot":"","sources":["../../../src/components/toolbar/ai-helpers.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ai-helpers.d.ts","sourceRoot":"","sources":["../../../src/components/toolbar/ai-helpers.js"],"names":[],"mappings":"AAuJA;;;;;;;;;;GAUG;AACH,uCATW,MAAM,WAEd;IAAwB,OAAO,EAAvB,MAAM;IACU,WAAW,EAA3B,MAAM;IACU,GAAG,EAAnB,MAAM;IACU,MAAM;CAC9B,mCACU,OAAO,CAAC,MAAM,CAAC,CA6B3B;AAED;;;;;;;;;GASG;AACH,8BARW,MAAM,YAEd;IAAwB,OAAO,EAAvB,MAAM;IACU,WAAW,EAA3B,MAAM;IACU,GAAG,EAAnB,MAAM;IACU,MAAM;CAC9B,GAAU,OAAO,CAAC,MAAM,CAAC,CAsB3B;AAED;;;;;;;;;;GAUG;AACH,uCATW,MAAM,UACN,MAAM,WAEd;IAAwB,WAAW,EAA3B,MAAM;IACU,GAAG,EAAnB,MAAM;IACU,MAAM;CAC9B,mCACU,OAAO,CAAC,MAAM,CAAC,CA4B3B;AAED;;;;;;;;;GASG;AACH,8BARW,MAAM,WACN,MAAM,YAEd;IAAwB,WAAW,EAA3B,MAAM;IACU,GAAG,EAAnB,MAAM;IACU,MAAM;CAC9B,GAAU,OAAO,CAAC,MAAM,CAAC,CA0B3B"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { E as m } from "./chunks/editor-
|
|
2
|
-
import "./chunks/converter-
|
|
3
|
-
import "./chunks/docx-zipper-
|
|
1
|
+
import { E as m } from "./chunks/editor-ByusZHOE.js";
|
|
2
|
+
import "./chunks/converter-CPw1nhKU.js";
|
|
3
|
+
import "./chunks/docx-zipper-DmUudu9K.js";
|
|
4
4
|
export {
|
|
5
5
|
m as Editor
|
|
6
6
|
};
|
|
@@ -6,14 +6,14 @@ var pt = (t, l, o) => l in t ? mt(t, l, { enumerable: !0, configurable: !0, writ
|
|
|
6
6
|
var He = (t, l, o) => pt(t, typeof l != "symbol" ? l + "" : l, o), je = (t, l, o) => l.has(t) || Ve("Cannot " + o);
|
|
7
7
|
var Se = (t, l, o) => (je(t, l, "read from private field"), o ? o.call(t) : l.get(t)), Be = (t, l, o) => l.has(t) ? Ve("Cannot add the same private member more than once") : l instanceof WeakSet ? l.add(t) : l.set(t, o);
|
|
8
8
|
var W = (t, l, o) => (je(t, l, "access private method"), o);
|
|
9
|
-
import { _ as K, a as Ke, b as ft, I as Re, f as ht, c as Ue, d as gt, i as vt, u as yt, r as bt, E as Oe, e as wt, P as kt, h as Ct, M as _t, j as xt, A as Et, N as St } from "./chunks/editor-
|
|
10
|
-
import { C as Lo, T as Mo, l as Do, n as $o, k as Ho, m as Bo } from "./chunks/editor-
|
|
11
|
-
import { a1 as At, y as Tt, a3 as Ft, T as Xe, a as It } from "./chunks/converter-
|
|
12
|
-
import { O as Oo } from "./chunks/converter-
|
|
9
|
+
import { _ as K, a as Ke, b as ft, I as Re, f as ht, c as Ue, d as gt, i as vt, u as yt, r as bt, E as Oe, e as wt, P as kt, h as Ct, M as _t, j as xt, A as Et, N as St } from "./chunks/editor-ByusZHOE.js";
|
|
10
|
+
import { C as Lo, T as Mo, l as Do, n as $o, k as Ho, m as Bo } from "./chunks/editor-ByusZHOE.js";
|
|
11
|
+
import { a1 as At, y as Tt, a3 as Ft, T as Xe, a as It } from "./chunks/converter-CPw1nhKU.js";
|
|
12
|
+
import { O as Oo } from "./chunks/converter-CPw1nhKU.js";
|
|
13
13
|
import { ref as y, createElementBlock as k, openBlock as w, createElementVNode as _, unref as D, getCurrentInstance as Lt, computed as j, watch as Mt, onMounted as we, createCommentVNode as Q, withDirectives as Dt, withKeys as $t, normalizeClass as ne, withModifiers as be, vModelText as Ht, createTextVNode as Ze, toDisplayString as oe, Fragment as U, renderList as ee, normalizeStyle as J, createVNode as V, h as N, createApp as Bt, reactive as qe, onUnmounted as Rt, shallowRef as Ye, onBeforeUnmount as Je, createBlock as Ot } from "vue";
|
|
14
|
-
import { t as G, s as Nt, T as zt, N as Y } from "./chunks/toolbar-
|
|
14
|
+
import { t as G, s as Nt, T as zt, N as Y } from "./chunks/toolbar-BwyACjtB.js";
|
|
15
15
|
import Wt from "./ai-writer.es.js";
|
|
16
|
-
import { D as zo } from "./chunks/docx-zipper-
|
|
16
|
+
import { D as zo } from "./chunks/docx-zipper-DmUudu9K.js";
|
|
17
17
|
import { createZip as Po } from "./file-zipper.es.js";
|
|
18
18
|
var Qe = { exports: {} };
|
|
19
19
|
(function(t) {
|
package/dist/super-editor.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./chunks/super-editor.es-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./chunks/super-editor.es-zve2N3NE.cjs");require("./chunks/vue-Ckf0DkDN.cjs");exports.AIWriter=e.de;exports.BasicUpload=e.So;exports.CommentsPluginKey=e.ge;exports.DocxZipper=e.Nt;exports.Editor=e.Ki;exports.Extensions=e.To;exports.SuperConverter=e.Pt;exports.SuperEditor=e.Eo;exports.SuperInput=e.Ao;exports.SuperToolbar=e.xo;exports.Toolbar=e.O0;exports.TrackChangesBasePluginKey=e.ce;exports.createZip=e.c;exports.fieldAnnotationHelpers=e.ax;exports.getActiveFormatting=e.jf;exports.getAllowedImageDimensions=e.oo;exports.getMarksFromSelection=e.Fo;exports.getRichTextExtensions=e.Jk;exports.getStarterExtensions=e.Yk;exports.helpers=e.Nd;exports.trackChangesHelpers=e.cx;
|
package/dist/super-editor.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { d as r, S as t, g as o, N as i, K as n, T as p, P as g, E as l, A as c, x as m, O as u, c as x, a as S, b as d, j as E, o as A, F as T, J as h, Y as C, e as b, f } from "./chunks/super-editor.es-
|
|
1
|
+
import { d as r, S as t, g as o, N as i, K as n, T as p, P as g, E as l, A as c, x as m, O as u, c as x, a as S, b as d, j as E, o as A, F as T, J as h, Y as C, e as b, f } from "./chunks/super-editor.es-Br9eH3cn.es.js";
|
|
2
2
|
import "./chunks/vue-D254cI7X.es.js";
|
|
3
3
|
export {
|
|
4
4
|
r as AIWriter,
|