@dineug/erd-editor 4.1.0 → 4.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +17 -4
- package/dist/components/dictionary/Dictionary.d.ts +12 -0
- package/dist/components/dictionary/Dictionary.styles.d.ts +33 -0
- package/dist/components/dictionary/checkCount.d.ts +28 -0
- package/dist/components/dictionary/checkSheet.d.ts +41 -0
- package/dist/components/dictionary/dictionary-context-menu/DictionaryContextMenu.d.ts +30 -0
- package/dist/components/dictionary/dictionaryCommit.d.ts +83 -0
- package/dist/components/dictionary/dictionaryFile.d.ts +23 -0
- package/dist/components/dictionary/dictionaryKeys.d.ts +48 -0
- package/dist/components/dictionary/dictionaryView.d.ts +65 -0
- package/dist/components/dictionary/domain-cell-editor/DomainCellEditor.d.ts +22 -0
- package/dist/components/dictionary/domain-cell-editor/DomainCellEditor.styles.d.ts +7 -0
- package/dist/components/dictionary/domain-cell-editor/openDomainCellEditor.d.ts +9 -0
- package/dist/components/dictionary/gridTheme.d.ts +18 -0
- package/dist/components/dictionary/sheets.d.ts +65 -0
- package/dist/components/erd/automatic-table-placement/flowPlacement.d.ts +4 -4
- package/dist/components/erd/canvas/EditOverlay.styles.d.ts +6 -0
- package/dist/components/erd/canvas/sceneHit.d.ts +5 -0
- package/dist/components/erd/canvas/sceneTokens.d.ts +6 -0
- package/dist/components/erd/canvas/table/Table.d.ts +6 -0
- package/dist/components/erd/canvas/table/blankLogicalName.d.ts +19 -0
- package/dist/components/erd/canvas/table/cellLayout.d.ts +4 -4
- package/dist/components/erd/canvas/table/column/Column.d.ts +32 -5
- package/dist/components/erd/canvas/table/dictionaryMarks.d.ts +29 -0
- package/dist/components/erd/canvas/table/useFocusTable.d.ts +1 -0
- package/dist/components/erd/diff-viewer/diff-tree/DiffTree.styles.d.ts +1 -0
- package/dist/components/erd/diff-viewer/diff-tree/diffTreeModel.d.ts +4 -1
- package/dist/components/erd/erd-context-menu/menus/nameViewMenus.d.ts +22 -0
- package/dist/components/erd/floating-toolbar/FloatingToolbar.d.ts +1 -1
- package/dist/components/erd/floating-toolbar/nameViewDropdown.d.ts +16 -0
- package/dist/components/erd/floating-toolbar/nameViewDropdown.styles.d.ts +5 -0
- package/dist/components/erd/readerNameView.d.ts +15 -0
- package/dist/components/explorer/explorerTree.d.ts +4 -1
- package/dist/components/explorer/fieldIcon.d.ts +4 -1
- package/dist/components/explorer/matchTarget.d.ts +6 -6
- package/dist/components/export-image/ExportImage.d.ts +10 -0
- package/dist/components/export-image/exportImageActions.d.ts +2 -2
- package/dist/components/flowCenters.d.ts +9 -0
- package/dist/components/map-columns/nameOf.d.ts +11 -3
- package/dist/components/primitives/icon/icons.d.ts +5 -0
- package/dist/components/quick-search/actions.d.ts +3 -1
- package/dist/components/quick-search/scopedActions.d.ts +2 -2
- package/dist/components/schema-sql/schema-sql-options/SchemaSQLOptions.d.ts +2 -2
- package/dist/components/schema-sql/schema-sql-options/SchemaSQLOptions.styles.d.ts +2 -0
- package/dist/components/schema-sql/schemaSQLView.d.ts +2 -0
- package/dist/components/settings/lockSettingRows.d.ts +2 -1
- package/dist/components/table-view/column/column-domain/ColumnDomain.d.ts +19 -0
- package/dist/components/table-view/column/column-domain/domainOptions.d.ts +13 -0
- package/dist/components/table-view/column/column-logical-name/ColumnLogicalName.d.ts +22 -0
- package/dist/components/table-view/column/column-logical-name/ColumnLogicalName.styles.d.ts +4 -0
- package/dist/components/table-view/column/columnViewText.d.ts +33 -0
- package/dist/components/table-view/column/useHintList.d.ts +24 -0
- package/dist/components/visualization/createVisualization.d.ts +2 -0
- package/dist/components/visualization/flowLayout.d.ts +2 -1
- package/dist/components/visualization/table/column/Column.d.ts +4 -0
- package/dist/components/visualization/visualization-toolbar/VisualizationToolbar.d.ts +2 -2
- package/dist/components/visualization/visualizationView.d.ts +15 -4
- package/dist/constants/layout.d.ts +11 -0
- package/dist/constants/schema.d.ts +15 -2
- package/dist/engine/actions.d.ts +5 -2
- package/dist/engine/history.actions.d.ts +8 -0
- package/dist/engine/history.d.ts +11 -3
- package/dist/engine/index.js +17 -17
- package/dist/engine/modules/dictionary/actions.d.ts +74 -0
- package/dist/engine/modules/dictionary/atom.actions.d.ts +74 -0
- package/dist/engine/modules/dictionary/checks.d.ts +76 -0
- package/dist/engine/modules/dictionary/derive.d.ts +54 -0
- package/dist/engine/modules/dictionary/derivedNames.d.ts +23 -0
- package/dist/engine/modules/dictionary/dictionaryIndex.d.ts +73 -0
- package/dist/engine/modules/dictionary/domainLinks.d.ts +9 -0
- package/dist/engine/modules/dictionary/domainTypes.d.ts +27 -0
- package/dist/engine/modules/dictionary/entryWrites.d.ts +63 -0
- package/dist/engine/modules/dictionary/generator.actions.d.ts +126 -0
- package/dist/engine/modules/dictionary/history.d.ts +14 -0
- package/dist/engine/modules/dictionary/membership.d.ts +28 -0
- package/dist/engine/modules/dictionary/orderKeys.d.ts +13 -0
- package/dist/engine/modules/dictionary/termIndex.d.ts +24 -0
- package/dist/engine/modules/editor/actions.d.ts +18 -3
- package/dist/engine/modules/editor/atom.actions.d.ts +24 -6
- package/dist/engine/modules/editor/generator.actions.d.ts +22 -8
- package/dist/engine/modules/editor/state.d.ts +24 -0
- package/dist/engine/modules/editor/utils/nameView.d.ts +103 -0
- package/dist/engine/modules/editor/view.actions.d.ts +24 -1
- package/dist/engine/modules/editor/view.d.ts +8 -0
- package/dist/engine/modules/relationship/fkColumns.d.ts +10 -4
- package/dist/engine/modules/settings/actions.d.ts +13 -3
- package/dist/engine/modules/settings/atom.actions.d.ts +49 -5
- package/dist/engine/modules/settings/generator.actions.d.ts +2 -2
- package/dist/engine/modules/table/actions.d.ts +7 -0
- package/dist/engine/modules/table/atom.actions.d.ts +46 -0
- package/dist/engine/modules/table/generator.actions.d.ts +7 -0
- package/dist/engine/modules/table/history.d.ts +2 -0
- package/dist/engine/modules/table-column/actions.d.ts +7 -0
- package/dist/engine/modules/table-column/atom.actions.d.ts +49 -0
- package/dist/engine/modules/table-column/generator.actions.d.ts +5 -0
- package/dist/engine/modules/table-column/history.d.ts +3 -0
- package/dist/engine/modules/table-column/utils/dataType.d.ts +3 -1
- package/dist/engine/rx-store.d.ts +6 -0
- package/dist/engine/tag.d.ts +8 -0
- package/dist/erd-editor.umd.js +1163 -817
- package/dist/i18n/messages/ar-SA.d.ts +125 -0
- package/dist/i18n/messages/de-DE.d.ts +93 -0
- package/dist/i18n/messages/en/common.d.ts +11 -0
- package/dist/i18n/messages/en/contextMenu.d.ts +1 -0
- package/dist/i18n/messages/en/dictionary.d.ts +79 -0
- package/dist/i18n/messages/en/findReplace.d.ts +2 -0
- package/dist/i18n/messages/en/index.d.ts +93 -0
- package/dist/i18n/messages/en/palette.d.ts +4 -0
- package/dist/i18n/messages/en/schemaSql.d.ts +1 -0
- package/dist/i18n/messages/en/settings.d.ts +1 -0
- package/dist/i18n/messages/en/visualization.d.ts +2 -0
- package/dist/i18n/messages/es-ES.d.ts +101 -0
- package/dist/i18n/messages/eu-ES.d.ts +93 -0
- package/dist/i18n/messages/fa-IR.d.ts +93 -0
- package/dist/i18n/messages/fr-FR.d.ts +101 -0
- package/dist/i18n/messages/he-IL.d.ts +101 -0
- package/dist/i18n/messages/id-ID.d.ts +85 -0
- package/dist/i18n/messages/it-IT.d.ts +101 -0
- package/dist/i18n/messages/ja-JP.d.ts +85 -0
- package/dist/i18n/messages/ko-KR.d.ts +85 -0
- package/dist/i18n/messages/nl-NL.d.ts +93 -0
- package/dist/i18n/messages/pl-PL.d.ts +109 -0
- package/dist/i18n/messages/pt-BR.d.ts +101 -0
- package/dist/i18n/messages/pt-PT.d.ts +101 -0
- package/dist/i18n/messages/ro-RO.d.ts +101 -0
- package/dist/i18n/messages/ru-RU.d.ts +109 -0
- package/dist/i18n/messages/sk-SK.d.ts +109 -0
- package/dist/i18n/messages/sl-SI.d.ts +109 -0
- package/dist/i18n/messages/sv-SE.d.ts +93 -0
- package/dist/i18n/messages/tr-TR.d.ts +93 -0
- package/dist/i18n/messages/uk-UA.d.ts +109 -0
- package/dist/i18n/messages/zh-CN.d.ts +85 -0
- package/dist/i18n/messages/zh-TW.d.ts +85 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +25195 -18014
- package/dist/internal-types/index.d.ts +6 -0
- package/dist/konva/scene/columnDropTarget.d.ts +2 -2
- package/dist/loadValue-B5ojYrZ-.js +14682 -0
- package/dist/peer/index.d.ts +4 -0
- package/dist/peer/index.js +61 -60
- package/dist/services/export-png/ExportScene.d.ts +1 -1
- package/dist/services/export-png/documentScene.d.ts +7 -1
- package/dist/services/export-png/index.d.ts +11 -5
- package/dist/services/export-png/renderPng.d.ts +4 -1
- package/dist/services/export-png/renderSvg.d.ts +4 -1
- package/dist/shared-store-S7YWEz3E.js +1656 -0
- package/dist/themes/tokens.d.ts +12 -0
- package/dist/utils/calcTable.d.ts +20 -4
- package/dist/utils/collection/domain.entity.d.ts +3 -0
- package/dist/utils/collection/term.entity.d.ts +3 -0
- package/dist/utils/collection/word.entity.d.ts +3 -0
- package/dist/utils/dictionary-csv/csv.d.ts +13 -0
- package/dist/utils/dictionary-csv/decode.d.ts +7 -0
- package/dist/utils/dictionary-csv/dictionaryCsv.d.ts +55 -0
- package/dist/utils/dictionary-csv/index.d.ts +4 -0
- package/dist/utils/diff/types.d.ts +4 -0
- package/dist/utils/file/exportFile.d.ts +10 -0
- package/dist/utils/find-replace/findMatches.d.ts +10 -4
- package/dist/utils/find-replace/present.d.ts +1 -1
- package/dist/utils/find-replace/replaceActions.d.ts +9 -5
- package/dist/utils/focus.d.ts +2 -0
- package/dist/utils/formatCount.d.ts +10 -0
- package/dist/utils/keyboard-shortcut/index.d.ts +1 -1
- package/dist/utils/map-columns/alignTypes.d.ts +3 -3
- package/dist/utils/schema-sql/Databricks.d.ts +2 -2
- package/dist/utils/schema-sql/MSSQL.d.ts +1 -1
- package/dist/utils/schema-sql/MariaDB.d.ts +2 -2
- package/dist/utils/schema-sql/MySQL.d.ts +2 -2
- package/dist/utils/schema-sql/Oracle.d.ts +1 -1
- package/dist/utils/schema-sql/PostgreSQL.d.ts +1 -1
- package/dist/utils/schema-sql/SQLite.d.ts +2 -2
- package/dist/utils/schema-sql/Snowflake.d.ts +2 -2
- package/dist/utils/schema-sql/options.d.ts +2 -0
- package/dist/utils/schema-sql/utils.d.ts +14 -0
- package/dist/utils/table-clipboard/copy.d.ts +2 -3
- package/dist/utils/table-clipboard/index.d.ts +9 -1
- package/dist/utils/table-clipboard/paste.d.ts +2 -2
- package/dist/utils/table-clipboard/payload.d.ts +12 -0
- package/dist/utils/validation.d.ts +1 -0
- package/dist/workers/exportPng.shared-worker.js +30 -29
- package/package.json +7 -5
- package/dist/konva/batchDraw.d.ts +0 -42
- package/dist/konva/host.d.ts +0 -30
- package/dist/konva/jsx-types.test-d.d.ts +0 -2
- package/dist/loadValue-BKvXDYoC.js +0 -12925
- package/dist/shared-store-2IUOt99m.js +0 -1341
package/dist/peer/index.d.ts
CHANGED
|
@@ -4,6 +4,10 @@ export { type DatabaseVendor, DatabaseVendorList, DatabaseVendorToDatabase, } fr
|
|
|
4
4
|
export { type ActionType, ChangeActionTypes, SharedFollowingActionTypes, StreamActionTypes, } from '../engine/actions';
|
|
5
5
|
export { createEngineContext, type EngineContext } from '../engine/context';
|
|
6
6
|
export type { GeneratorAction } from '../engine/generator.actions';
|
|
7
|
+
export { actions as dictionaryActions } from '../engine/modules/dictionary/atom.actions';
|
|
8
|
+
export { type DictionaryCheck, type DictionaryCheckCode, DictionaryCheckLevel, DictionaryCheckLevelOf, listDictionaryChecks, } from '../engine/modules/dictionary/checks';
|
|
9
|
+
export { validateDictionaryValues } from '../engine/modules/dictionary/entryWrites';
|
|
10
|
+
export { actions$ as dictionaryActions$ } from '../engine/modules/dictionary/generator.actions';
|
|
7
11
|
export { actions$ as editorActions$ } from '../engine/modules/editor/generator.actions';
|
|
8
12
|
export { FocusType, SelectType } from '../engine/modules/editor/state';
|
|
9
13
|
export { actions as indexActions } from '../engine/modules/index/atom.actions';
|
package/dist/peer/index.js
CHANGED
|
@@ -1,62 +1,63 @@
|
|
|
1
|
-
import { $ as e,
|
|
2
|
-
import {
|
|
1
|
+
import { $ as e, $i as t, $n as n, $s as r, B as i, Bn as a, Br as o, C as s, Cc as c, Cn as l, Dc as u, Dr as d, Ec as f, F as p, Ht as m, In as ee, Js as h, Kn as g, Ln as _, Ns as v, Or as y, P as b, Pc as x, Pt as S, Qs as C, Tr as w, U as T, Ys as E, Zs as D, _c as O, bc as k, bs as A, cn as j, cs as te, ec as ne, f as M, fc as re, fr as ie, fs as ae, gc as oe, io as se, jc as N, k as P, kc as F, kr as I, lc as L, m as R, mc as z, nn as B, nr as V, oo as H, pc as U, rr as W, sr as G, t as K, tc as q, ti as ce, u as J, us as le, va as ue, wc as de, wt as fe, x as pe, xc as me, yc as he } from "../loadValue-B5ojYrZ-.js";
|
|
2
|
+
import { C as ge, f as _e, h as ve, m as ye, n as be, p as xe, t as Se, w as Ce, y as we } from "../shared-store-S7YWEz3E.js";
|
|
3
3
|
//#region src/engine/presence.ts
|
|
4
|
-
var
|
|
4
|
+
var Te = G / 3, Ee = (e) => {
|
|
5
5
|
e?.unref?.();
|
|
6
|
-
},
|
|
6
|
+
}, De = [
|
|
7
7
|
"sharedMouseTrackerMap",
|
|
8
8
|
"sharedFocusTrackerMap",
|
|
9
9
|
"sharedSelectionTrackerMap",
|
|
10
10
|
"sharedDragSelectTrackerMap"
|
|
11
11
|
];
|
|
12
|
-
function
|
|
13
|
-
for (let t of
|
|
12
|
+
function Oe(e) {
|
|
13
|
+
for (let t of De) {
|
|
14
14
|
let n = e[t];
|
|
15
15
|
for (let e of Object.keys(n)) clearTimeout(n[e].timeoutId), Reflect.deleteProperty(n, e);
|
|
16
16
|
}
|
|
17
17
|
}
|
|
18
|
-
function
|
|
18
|
+
function ke(e) {
|
|
19
19
|
let t = "", n = (n) => {
|
|
20
|
-
let r =
|
|
21
|
-
(i !== t || n) && (t = i, e.dispatch(
|
|
20
|
+
let r = _e(e.state.editor.focusTable), i = xe(r);
|
|
21
|
+
(i !== t || n) && (t = i, e.dispatch(o({ focus: r })));
|
|
22
22
|
}, r = e.subscribe((e) => {
|
|
23
|
-
n(e.some((e) => e.type ===
|
|
23
|
+
n(e.some((e) => e.type === I.type));
|
|
24
24
|
}), i = setInterval(() => {
|
|
25
25
|
t && n(!0);
|
|
26
|
-
},
|
|
27
|
-
return
|
|
26
|
+
}, Te);
|
|
27
|
+
return Ee(i), Object.freeze({ destroy: () => {
|
|
28
28
|
r(), clearInterval(i);
|
|
29
29
|
} });
|
|
30
30
|
}
|
|
31
31
|
//#endregion
|
|
32
32
|
//#region src/engine/stream-flush.ts
|
|
33
|
-
function
|
|
33
|
+
function Ae(e, t) {
|
|
34
34
|
return Object.freeze({ flush: () => {
|
|
35
35
|
e.flushStreamBuffers(), t.flushStreamBuffers();
|
|
36
36
|
} });
|
|
37
37
|
}
|
|
38
38
|
//#endregion
|
|
39
39
|
//#region src/engine/to-width.ts
|
|
40
|
-
var
|
|
40
|
+
var je = 2, Y = 10, X = (e) => Math.round(e.length * Y) + je, Z = {
|
|
41
41
|
readonly: "readonly",
|
|
42
42
|
destroyed: "destroyed"
|
|
43
|
-
},
|
|
43
|
+
}, Me = {
|
|
44
44
|
readonly: "the document is readonly, so no edit was made",
|
|
45
45
|
destroyed: "this document session was closed; open the document again"
|
|
46
46
|
}, Q = class extends Error {
|
|
47
47
|
constructor(e, t) {
|
|
48
|
-
super(
|
|
48
|
+
super(Me[e]), M(this, "code", void 0), M(this, "operation", void 0), this.name = "PeerStoreError", this.code = e, this.operation = t;
|
|
49
49
|
}
|
|
50
|
-
}, $ =
|
|
50
|
+
}, $ = q(R), Ne = q(s), Pe = q([
|
|
51
51
|
"table.add",
|
|
52
52
|
"column.add",
|
|
53
53
|
"memo.add",
|
|
54
54
|
"index.add",
|
|
55
55
|
"indexColumn.add",
|
|
56
56
|
"relationship.add",
|
|
57
|
-
"tableGroup.add"
|
|
57
|
+
"tableGroup.add",
|
|
58
|
+
"dictionary.add"
|
|
58
59
|
]);
|
|
59
|
-
function
|
|
60
|
+
function Fe(e) {
|
|
60
61
|
let t = 0, n = 0;
|
|
61
62
|
return {
|
|
62
63
|
history: Object.freeze({
|
|
@@ -83,13 +84,13 @@ function ke(e) {
|
|
|
83
84
|
getLimit: () => n
|
|
84
85
|
};
|
|
85
86
|
}
|
|
86
|
-
function
|
|
87
|
+
function Ie(e) {
|
|
87
88
|
if (!e) return [];
|
|
88
89
|
let { tableId: t, columnId: n, focusType: r } = e;
|
|
89
|
-
return n === void 0 ? [
|
|
90
|
+
return n === void 0 ? [d({
|
|
90
91
|
tableId: t,
|
|
91
92
|
focusType: r
|
|
92
|
-
})] : [
|
|
93
|
+
})] : [w({
|
|
93
94
|
tableId: t,
|
|
94
95
|
columnId: n,
|
|
95
96
|
focusType: r,
|
|
@@ -97,53 +98,53 @@ function Ae(e) {
|
|
|
97
98
|
shiftKey: !1
|
|
98
99
|
})];
|
|
99
100
|
}
|
|
100
|
-
function
|
|
101
|
-
let a = null, o = ge(
|
|
101
|
+
function Le({ nickname: t, toWidth: n = X, presence: r = !0, readonly: i = !1 }) {
|
|
102
|
+
let a = null, o = ge(J({
|
|
102
103
|
toWidth: n,
|
|
103
104
|
routes: !1
|
|
104
105
|
}), {
|
|
105
106
|
manualStreamFlush: !0,
|
|
106
107
|
observable: !1,
|
|
107
|
-
getHistory: (e) => (a =
|
|
108
|
-
}), s = () => a?.getPushes() ?? 0, c = () => a?.getLimit() ?? 0, l =
|
|
109
|
-
o.dispatchSync(
|
|
108
|
+
getHistory: (e) => (a = Fe(Ce(e)), a.history)
|
|
109
|
+
}), s = () => a?.getPushes() ?? 0, c = () => a?.getLimit() ?? 0, l = Se(o, { getNickname: () => t }, { manualStreamFlush: !0 }), u = Ae(o, l), d = /* @__PURE__ */ new Set(), f = o.state.editor.id, p = i, m = !1, h = null, g = !1, _ = 0, v = [], b = [], S = null;
|
|
110
|
+
o.dispatchSync(ie({
|
|
110
111
|
width: 0,
|
|
111
112
|
height: 0
|
|
112
113
|
}));
|
|
113
|
-
let
|
|
114
|
+
let C = r ? ke(o) : null, w = () => {
|
|
114
115
|
h ||= l.subscribe((e) => {
|
|
115
116
|
e.some((e) => $(e.type)) && _++;
|
|
116
|
-
for (let t of Array.from(d))
|
|
117
|
+
for (let t of Array.from(d)) ee(t, e);
|
|
117
118
|
});
|
|
118
|
-
}, C = (e) => {
|
|
119
|
-
if (m) throw new Q(Z.destroyed, e);
|
|
120
|
-
}, w = (e) => {
|
|
121
|
-
if (b) throw Error(`${e} cannot run inside a group`);
|
|
122
119
|
}, T = (e) => {
|
|
123
|
-
if (
|
|
124
|
-
}, E = () => {
|
|
120
|
+
if (m) throw new Q(Z.destroyed, e);
|
|
121
|
+
}, E = (e) => {
|
|
122
|
+
if (S) throw Error(`${e} cannot run inside a group`);
|
|
123
|
+
}, D = (e) => {
|
|
124
|
+
if (T(e), p) throw new Q(Z.readonly, e);
|
|
125
|
+
}, O = () => {
|
|
125
126
|
let e = c();
|
|
126
127
|
if (!e) return;
|
|
127
128
|
let t = v.reduce((e, { historyEntries: t }) => e + t, 0);
|
|
128
129
|
for (; t > e;) t -= v.shift().historyEntries;
|
|
129
130
|
for (; v.length > e;) v.splice(v.findIndex(({ historyEntries: e }) => !e), 1);
|
|
130
|
-
},
|
|
131
|
-
|
|
132
|
-
let n = _, r = s(), i =
|
|
133
|
-
o.dispatchSync(i), i.some((e) =>
|
|
131
|
+
}, k = (e, t = {}) => {
|
|
132
|
+
D("dispatch"), w();
|
|
133
|
+
let n = _, r = s(), i = x(o.state, o.context, [...Ie(t.focus), ...e]);
|
|
134
|
+
o.dispatchSync(i), i.some((e) => Ne(e.type)) && u.flush();
|
|
134
135
|
let a = {
|
|
135
136
|
label: t.label ?? null,
|
|
136
137
|
actions: i.filter((e) => $(e.type)),
|
|
137
|
-
createdIds: i.filter((e) =>
|
|
138
|
+
createdIds: i.filter((e) => Pe(e.type)).map((e) => e.payload.id),
|
|
138
139
|
batches: _ - n,
|
|
139
140
|
historyEntries: s() - r
|
|
140
141
|
};
|
|
141
|
-
return
|
|
142
|
+
return S ? (S.unit.historyEntries += a.historyEntries, S.dispatched = !0) : v.push({
|
|
142
143
|
label: a.label,
|
|
143
144
|
historyEntries: a.historyEntries
|
|
144
|
-
}), a.historyEntries && (
|
|
145
|
-
},
|
|
146
|
-
if (
|
|
145
|
+
}), a.historyEntries && (b = []), S || O(), a;
|
|
146
|
+
}, A = (e, t) => {
|
|
147
|
+
if (D("group"), S) return t();
|
|
147
148
|
let n = {
|
|
148
149
|
unit: {
|
|
149
150
|
label: e,
|
|
@@ -151,23 +152,23 @@ function je({ nickname: t, toWidth: n = X, presence: r = !0, readonly: i = !1 })
|
|
|
151
152
|
},
|
|
152
153
|
dispatched: !1
|
|
153
154
|
};
|
|
154
|
-
|
|
155
|
+
S = n;
|
|
155
156
|
try {
|
|
156
157
|
return t();
|
|
157
158
|
} finally {
|
|
158
|
-
|
|
159
|
+
S = null, n.dispatched && (v.push(n.unit), O());
|
|
159
160
|
}
|
|
160
|
-
},
|
|
161
|
+
}, j = (e, t) => {
|
|
161
162
|
for (let n = 0; n < e.historyEntries; n++) t();
|
|
162
163
|
u.flush();
|
|
163
164
|
};
|
|
164
165
|
return Object.freeze({
|
|
165
166
|
editorId: f,
|
|
166
167
|
get value() {
|
|
167
|
-
return
|
|
168
|
+
return F(o.state);
|
|
168
169
|
},
|
|
169
170
|
get runtimeValue() {
|
|
170
|
-
return
|
|
171
|
+
return N(o.state);
|
|
171
172
|
},
|
|
172
173
|
get state() {
|
|
173
174
|
return o.state;
|
|
@@ -182,21 +183,21 @@ function je({ nickname: t, toWidth: n = X, presence: r = !0, readonly: i = !1 })
|
|
|
182
183
|
p = e;
|
|
183
184
|
},
|
|
184
185
|
setInitialValue: (t) => {
|
|
185
|
-
|
|
186
|
+
T("setInitialValue"), E("setInitialValue"), o.dispatchSync(y(), e(K(t))), o.resetHistory(), v = [], b = [];
|
|
186
187
|
},
|
|
187
188
|
mergeClock: (e) => {
|
|
188
189
|
o.context.clock.merge(e);
|
|
189
190
|
},
|
|
190
|
-
dispatch:
|
|
191
|
+
dispatch: k,
|
|
191
192
|
receive: (e) => {
|
|
192
193
|
m || l.dispatchSync(e);
|
|
193
194
|
},
|
|
194
|
-
group:
|
|
195
|
+
group: A,
|
|
195
196
|
undo: () => {
|
|
196
|
-
|
|
197
|
+
D("undo"), E("undo"), w();
|
|
197
198
|
let e = [], t = v.pop();
|
|
198
199
|
for (; t && !t.historyEntries;) t.label !== null && e.push(t.label), t = v.pop();
|
|
199
|
-
return t ? (
|
|
200
|
+
return t ? (j(t, o.undo), b.push(t), {
|
|
200
201
|
label: t.label,
|
|
201
202
|
entries: t.historyEntries,
|
|
202
203
|
skipped: e
|
|
@@ -207,9 +208,9 @@ function je({ nickname: t, toWidth: n = X, presence: r = !0, readonly: i = !1 })
|
|
|
207
208
|
};
|
|
208
209
|
},
|
|
209
210
|
redo: () => {
|
|
210
|
-
|
|
211
|
-
let e =
|
|
212
|
-
return e ? (
|
|
211
|
+
D("redo"), E("redo"), w();
|
|
212
|
+
let e = b.pop();
|
|
213
|
+
return e ? (j(e, o.redo), v.push(e), {
|
|
213
214
|
label: e.label,
|
|
214
215
|
entries: e.historyEntries,
|
|
215
216
|
skipped: []
|
|
@@ -219,16 +220,16 @@ function je({ nickname: t, toWidth: n = X, presence: r = !0, readonly: i = !1 })
|
|
|
219
220
|
skipped: []
|
|
220
221
|
};
|
|
221
222
|
},
|
|
222
|
-
subscribe: (e) => (
|
|
223
|
+
subscribe: (e) => (T("subscribe"), d.add(e), g || (g = !0, h ? o.dispatchSync(I()) : w()), () => {
|
|
223
224
|
d.delete(e);
|
|
224
225
|
}),
|
|
225
226
|
flushStreamBuffers: () => {
|
|
226
227
|
m || u.flush();
|
|
227
228
|
},
|
|
228
229
|
destroy: () => {
|
|
229
|
-
m || (m = !0,
|
|
230
|
+
m || (m = !0, C?.destroy(), h?.(), h = null, d.clear(), l.destroy(), o.destroy(), Oe(o.state.editor), v = [], b = []);
|
|
230
231
|
}
|
|
231
232
|
});
|
|
232
233
|
}
|
|
233
234
|
//#endregion
|
|
234
|
-
export {
|
|
235
|
+
export { L as BracketType, re as CanvasType, R as ChangeActionTypes, U as ColumnOption, z as ColumnType, oe as DDLScriptPosition, O as Database, h as DatabaseVendorList, E as DatabaseVendorToDatabase, ye as DictionaryCheckLevel, ve as DictionaryCheckLevelOf, le as FocusType, he as Language, k as LockSettingType, D as MEMO_MIN_HEIGHT, C as MEMO_MIN_WIDTH, me as NameCase, c as OrderType, Q as PeerStoreError, Z as PeerStoreErrorCode, de as ReferentialAction, f as RelationshipType, se as SchemaSQLHeaderList, H as SchemaSQLStatementsList, ae as SelectType, pe as SharedFollowingActionTypes, u as Show, s as StreamActionTypes, r as TABLE_GROUP_MIN_HEIGHT, ne as TABLE_GROUP_MIN_WIDTH, te as bHas, J as createEngineContext, Le as createPeerStore, be as createSchemaSQL, X as defaultToWidth, A as dictionaryActions, j as dictionaryActions$, T as editorActions$, t as getTablesGroupRect, W as indexActions, i as indexActions$, V as indexColumnActions, p as indexColumnActions$, we as listDictionaryChecks, ue as measureTableSize, n as memoActions, B as memoActions$, g as relationshipActions, b as relationshipActions$, ce as settingsActions, P as settingsActions$, a as tableActions, m as tableActions$, v as tableColumnActions, S as tableColumnActions$, _ as tableGroupActions, fe as tableGroupActions$, l as validateDictionaryValues };
|
|
@@ -9,7 +9,7 @@ export type ExportSceneProps = {
|
|
|
9
9
|
/**
|
|
10
10
|
* Everything the document draws on one layer, the groups behind it all, with
|
|
11
11
|
* no culling and every table in full, as at the export's zoom. The scroll and
|
|
12
|
-
* the viewport do not reach it, so the whole document is held.
|
|
12
|
+
* the viewport do not reach it, so the whole document is held, no check marked.
|
|
13
13
|
*/
|
|
14
14
|
declare const ExportScene: FC<ExportSceneProps>;
|
|
15
15
|
export default ExportScene;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Stage } from 'konva/lib/Stage';
|
|
2
2
|
import { LocaleMessages } from '../../i18n/translate';
|
|
3
|
+
import { Settings } from '../../internal-types';
|
|
3
4
|
import { Rect } from '../../konva/scene/metrics';
|
|
4
5
|
import { Theme } from '../../themes/tokens';
|
|
5
6
|
export type DocumentSceneOptions = {
|
|
@@ -17,6 +18,11 @@ export type DocumentSceneOptions = {
|
|
|
17
18
|
* with no name say. Left out, the scene draws them in English.
|
|
18
19
|
*/
|
|
19
20
|
i18n?: LocaleMessages;
|
|
21
|
+
/**
|
|
22
|
+
* The names the scene draws, the reader's view, which a lock never saved.
|
|
23
|
+
* Left out, the scene draws the view the document holds.
|
|
24
|
+
*/
|
|
25
|
+
nameViewMode?: Settings['nameViewMode'];
|
|
20
26
|
};
|
|
21
27
|
export type DocumentScene = {
|
|
22
28
|
stage: Stage;
|
|
@@ -34,5 +40,5 @@ export type DocumentScene = {
|
|
|
34
40
|
* @example
|
|
35
41
|
* const scene = await renderDocumentScene({ doc, theme, toWidth });
|
|
36
42
|
*/
|
|
37
|
-
export declare function renderDocumentScene({ doc, theme, toWidth, maxSide, i18n, }: DocumentSceneOptions): Promise<DocumentScene>;
|
|
43
|
+
export declare function renderDocumentScene({ doc, theme, toWidth, maxSide, i18n, nameViewMode, }: DocumentSceneOptions): Promise<DocumentScene>;
|
|
38
44
|
//# sourceMappingURL=documentScene.d.ts.map
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { LocaleMessages } from '../../i18n/translate';
|
|
2
|
+
import { Settings } from '../../internal-types';
|
|
2
3
|
import { Theme } from '../../themes/tokens';
|
|
3
4
|
import { ResolutionReduction } from './renderPng';
|
|
4
5
|
import { ToWidth } from './textWidth';
|
|
@@ -35,6 +36,11 @@ export type DocumentPngOptions = {
|
|
|
35
36
|
* Left out, the scene draws them in English.
|
|
36
37
|
*/
|
|
37
38
|
i18n?: LocaleMessages;
|
|
39
|
+
/**
|
|
40
|
+
* The names the scene draws, the reader's view rather than the one a lock
|
|
41
|
+
* saves. Left out, the scene draws the view the document holds.
|
|
42
|
+
*/
|
|
43
|
+
nameViewMode?: Settings['nameViewMode'];
|
|
38
44
|
/**
|
|
39
45
|
* Called once, after a file exists, when the pixels the scale asked for
|
|
40
46
|
* outran what a canvas holds, with those and the pixels written. A caller
|
|
@@ -52,8 +58,8 @@ export type DocumentPngOptions = {
|
|
|
52
58
|
* @example
|
|
53
59
|
* const blob = await createDocumentPng({ doc: toJson(store.state), theme, toWidth });
|
|
54
60
|
*/
|
|
55
|
-
export declare function createDocumentPng({ doc, theme, toWidth, pixelRatio, i18n, onResolutionReduced, onProgress, }: DocumentPngOptions): Promise<Blob>;
|
|
56
|
-
export type DocumentPreviewOptions = Pick<DocumentPngOptions, 'doc' | 'theme' | 'toWidth' | 'i18n'> & {
|
|
61
|
+
export declare function createDocumentPng({ doc, theme, toWidth, pixelRatio, i18n, nameViewMode, onResolutionReduced, onProgress, }: DocumentPngOptions): Promise<Blob>;
|
|
62
|
+
export type DocumentPreviewOptions = Pick<DocumentPngOptions, 'doc' | 'theme' | 'toWidth' | 'i18n' | 'nameViewMode'> & {
|
|
57
63
|
/** The longest side the preview may take, in pixels. */
|
|
58
64
|
maxSide: number;
|
|
59
65
|
};
|
|
@@ -74,8 +80,8 @@ export type DocumentPreview = {
|
|
|
74
80
|
* @example
|
|
75
81
|
* const preview = await createDocumentPreview({ doc, theme, toWidth, maxSide: 1280 });
|
|
76
82
|
*/
|
|
77
|
-
export declare function createDocumentPreview({ doc, theme, toWidth, maxSide, i18n, }: DocumentPreviewOptions): Promise<DocumentPreview>;
|
|
78
|
-
export type DocumentSvgOptions = Pick<DocumentPngOptions, 'doc' | 'theme' | 'toWidth' | 'i18n'>;
|
|
83
|
+
export declare function createDocumentPreview({ doc, theme, toWidth, maxSide, i18n, nameViewMode, }: DocumentPreviewOptions): Promise<DocumentPreview>;
|
|
84
|
+
export type DocumentSvgOptions = Pick<DocumentPngOptions, 'doc' | 'theme' | 'toWidth' | 'i18n' | 'nameViewMode'>;
|
|
79
85
|
/**
|
|
80
86
|
* An svg of everything the document draws, at 100% as the png is. It takes
|
|
81
87
|
* the png's path, worker first, and leaves the scale out, since a vector is
|
|
@@ -84,5 +90,5 @@ export type DocumentSvgOptions = Pick<DocumentPngOptions, 'doc' | 'theme' | 'toW
|
|
|
84
90
|
* @example
|
|
85
91
|
* const svg = await createDocumentSvg({ doc, theme, toWidth });
|
|
86
92
|
*/
|
|
87
|
-
export declare function createDocumentSvg({ doc, theme, toWidth, i18n, }: DocumentSvgOptions): Promise<string>;
|
|
93
|
+
export declare function createDocumentSvg({ doc, theme, toWidth, i18n, nameViewMode, }: DocumentSvgOptions): Promise<string>;
|
|
88
94
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { LocaleMessages } from '../../i18n/translate';
|
|
2
|
+
import { Settings } from '../../internal-types';
|
|
2
3
|
import { Theme } from '../../themes/tokens';
|
|
3
4
|
import { ExportSize } from './exportBox';
|
|
4
5
|
import { ToWidth } from './textWidth';
|
|
@@ -19,6 +20,8 @@ export type RenderPngRequest = {
|
|
|
19
20
|
maxSide?: number;
|
|
20
21
|
/** The language the scene's own words are drawn in; English when left out. */
|
|
21
22
|
i18n?: LocaleMessages;
|
|
23
|
+
/** The names the scene draws; the document's own view when left out. */
|
|
24
|
+
nameViewMode?: Settings['nameViewMode'];
|
|
22
25
|
};
|
|
23
26
|
export type RenderPngResult = {
|
|
24
27
|
blob: Blob;
|
|
@@ -42,7 +45,7 @@ export type RenderPngResult = {
|
|
|
42
45
|
* @example
|
|
43
46
|
* const { blob } = await renderDocumentPng({ doc, theme, pixelRatio: 1, toWidth });
|
|
44
47
|
*/
|
|
45
|
-
export declare function renderDocumentPng({ doc, theme, pixelRatio, maxSide, i18n, toWidth, }: RenderPngRequest & {
|
|
48
|
+
export declare function renderDocumentPng({ doc, theme, pixelRatio, maxSide, i18n, nameViewMode, toWidth, }: RenderPngRequest & {
|
|
46
49
|
toWidth: ToWidth;
|
|
47
50
|
}): Promise<RenderPngResult>;
|
|
48
51
|
//# sourceMappingURL=renderPng.d.ts.map
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { LocaleMessages } from '../../i18n/translate';
|
|
2
|
+
import { Settings } from '../../internal-types';
|
|
2
3
|
import { Theme } from '../../themes/tokens';
|
|
3
4
|
import { ToWidth } from './textWidth';
|
|
4
5
|
/** Everything an svg needs that survives a structured clone to another realm. */
|
|
@@ -7,6 +8,8 @@ export type RenderSvgRequest = {
|
|
|
7
8
|
theme: Theme;
|
|
8
9
|
/** The language the scene's own words are drawn in; English when left out. */
|
|
9
10
|
i18n?: LocaleMessages;
|
|
11
|
+
/** The names the scene draws; the document's own view when left out. */
|
|
12
|
+
nameViewMode?: Settings['nameViewMode'];
|
|
10
13
|
};
|
|
11
14
|
/**
|
|
12
15
|
* The whole document as an svg, at the export's zoom and with no scale, since
|
|
@@ -16,7 +19,7 @@ export type RenderSvgRequest = {
|
|
|
16
19
|
* @example
|
|
17
20
|
* const svg = await renderDocumentSvg({ doc, theme, toWidth });
|
|
18
21
|
*/
|
|
19
|
-
export declare function renderDocumentSvg({ doc, theme, i18n, toWidth, }: RenderSvgRequest & {
|
|
22
|
+
export declare function renderDocumentSvg({ doc, theme, i18n, nameViewMode, toWidth, }: RenderSvgRequest & {
|
|
20
23
|
toWidth: ToWidth;
|
|
21
24
|
}): Promise<string>;
|
|
22
25
|
//# sourceMappingURL=renderSvg.d.ts.map
|