@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/themes/tokens.d.ts
CHANGED
|
@@ -40,6 +40,10 @@ export type Theme = {
|
|
|
40
40
|
columnSelect: string;
|
|
41
41
|
columnSelectHover: string;
|
|
42
42
|
columnHover: string;
|
|
43
|
+
columnHandleBackground: string;
|
|
44
|
+
columnHandleBorder: string;
|
|
45
|
+
columnHandleHoverBackground: string;
|
|
46
|
+
columnHandleHoverBorder: string;
|
|
43
47
|
relationshipHover: string;
|
|
44
48
|
visualizationLink: string;
|
|
45
49
|
visualizationColumn: string;
|
|
@@ -81,6 +85,14 @@ export type Theme = {
|
|
|
81
85
|
treeMatch: string;
|
|
82
86
|
explorerBackground: string;
|
|
83
87
|
explorerBorder: string;
|
|
88
|
+
dictionaryErrorForeground: string;
|
|
89
|
+
dictionaryErrorBackground: string;
|
|
90
|
+
dictionaryWarningForeground: string;
|
|
91
|
+
dictionaryWarningBackground: string;
|
|
92
|
+
dictionaryBackground: string;
|
|
93
|
+
dictionaryHeaderBackground: string;
|
|
94
|
+
dictionaryGridLine: string;
|
|
95
|
+
dictionaryHeaderSelect: string;
|
|
84
96
|
diffInsertForeground: string;
|
|
85
97
|
diffDeleteForeground: string;
|
|
86
98
|
diffModifyForeground: string;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { EngineContext } from '../engine/context';
|
|
2
|
+
import { FocusType } from '../engine/modules/editor/state';
|
|
2
3
|
import { RootState } from '../engine/state';
|
|
3
4
|
import { Table } from '../internal-types';
|
|
4
5
|
import { GeometrySource } from './draw-relationship/geometrySource';
|
|
@@ -24,23 +25,38 @@ export declare function invalidateTableWidths(): void;
|
|
|
24
25
|
* none, so only a table that shows one widens.
|
|
25
26
|
*/
|
|
26
27
|
export declare function calcAlternateKeyWidth(table: Table, state: RootState): number;
|
|
28
|
+
/**
|
|
29
|
+
* The width a document header gives the cell of a focus type: the comment at
|
|
30
|
+
* its clamp, and the logical name at its own width in the view of both names
|
|
31
|
+
* or, in the logical view, at the name's while it holds none, which that view draws.
|
|
32
|
+
*/
|
|
33
|
+
export declare function headerCellWidth(state: RootState, table: Table, focusType: FocusType): number;
|
|
27
34
|
export declare function calcTableWidths(table: Table, state: RootState): ColumnWidth;
|
|
35
|
+
/**
|
|
36
|
+
* The width of each cell a document row lays out in the view the settings
|
|
37
|
+
* show, at the widest row, 0 for a cell it leaves out. The name and the type
|
|
38
|
+
* are the cells in their places, which the logical view fills its own way.
|
|
39
|
+
*/
|
|
28
40
|
export type ColumnWidth = {
|
|
29
41
|
width: number;
|
|
30
42
|
/** The alternate key marks' room after a row's last cell, 0 while none is drawn. */
|
|
31
43
|
alternateKey: number;
|
|
32
44
|
name: number;
|
|
45
|
+
/** The logical name's own cell, which the view of both names alone lays out. */
|
|
46
|
+
logicalName: number;
|
|
33
47
|
comment: number;
|
|
34
48
|
dataType: number;
|
|
49
|
+
/** The domain's own cell, laid out while its show bit is set. */
|
|
50
|
+
domain: number;
|
|
35
51
|
default: number;
|
|
36
52
|
notNull: number;
|
|
37
53
|
autoIncrement: number;
|
|
38
54
|
unique: number;
|
|
39
55
|
};
|
|
40
56
|
/**
|
|
41
|
-
* The width a view draws a table at: the header
|
|
42
|
-
* the widest name
|
|
43
|
-
* are the caller's to name, and the show bits
|
|
57
|
+
* The width a view draws a table at: the header names, or the key badge with
|
|
58
|
+
* the widest of each cell its name view lays out among the rows given, whichever is wider.
|
|
59
|
+
* The rows are the caller's to name, and no view reads the show bits or the column order.
|
|
44
60
|
*/
|
|
45
61
|
export declare function calcViewTableWidths(table: Table, state: RootState, columnIds: string[]): ColumnWidth;
|
|
46
62
|
/**
|
|
@@ -59,7 +75,7 @@ export declare function tableHeaderHeight(source?: GeometrySource): number;
|
|
|
59
75
|
export declare function tableRowHeight(source?: GeometrySource): number;
|
|
60
76
|
/** The box height for the rows given, every row of the table unless a view shows fewer. */
|
|
61
77
|
export declare function calcTableHeight(table: Table, rowCount?: number, source?: GeometrySource): number;
|
|
62
|
-
export declare function recalculateTableWidth(
|
|
78
|
+
export declare function recalculateTableWidth(state: RootState, { toWidth }: EngineContext): void;
|
|
63
79
|
/**
|
|
64
80
|
* The box a table takes on the ERD canvas once toWidth has measured its text,
|
|
65
81
|
* the size recalculateTableWidth would leave it at. It works on copies, so it
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Reads CSV text as RFC 4180 writes it: a quoted field holds commas, line
|
|
3
|
+
* breaks and doubled quotes. A record ends at CRLF, LF or CR, a blank line is
|
|
4
|
+
* no record, and a stray quote stays as text, so no input throws.
|
|
5
|
+
*/
|
|
6
|
+
export declare function parseCsv(text: string): string[][];
|
|
7
|
+
/**
|
|
8
|
+
* Writes records as CSV text a spreadsheet opens as UTF-8: a byte order mark
|
|
9
|
+
* first and CRLF after every record. Only a field holding a quote, a comma or
|
|
10
|
+
* a line break is quoted, its quotes doubled.
|
|
11
|
+
*/
|
|
12
|
+
export declare function serializeCsv(records: ReadonlyArray<ReadonlyArray<string>>): string;
|
|
13
|
+
//# sourceMappingURL=csv.d.ts.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Reads a file's bytes as UTF-8 with its byte order mark dropped, or as EUC-KR
|
|
3
|
+
* when they are no valid UTF-8, as an older public-standard file is. Bytes
|
|
4
|
+
* neither reads come out as replacement characters, which no header matches.
|
|
5
|
+
*/
|
|
6
|
+
export declare function decodeCsvBytes(bytes: ArrayBuffer | Uint8Array): string;
|
|
7
|
+
//# sourceMappingURL=decode.d.ts.map
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { DictionaryKind } from '../../engine/modules/dictionary/actions';
|
|
2
|
+
import { Domain, Term, ValuesType, Word } from '../../internal-types';
|
|
3
|
+
/** The two layouts a dictionary file comes in: the editor's own and the public standard's. */
|
|
4
|
+
export declare const DictionaryCsvFormat: {
|
|
5
|
+
readonly own: "own";
|
|
6
|
+
readonly publicStandard: "publicStandard";
|
|
7
|
+
};
|
|
8
|
+
export type DictionaryCsvFormat = ValuesType<typeof DictionaryCsvFormat>;
|
|
9
|
+
/** What a file's row of each dictionary holds; a term names its domain by the domain's name. */
|
|
10
|
+
export type DictionaryCsvValues = {
|
|
11
|
+
[DictionaryKind.word]: Omit<Word, 'id' | 'order'>;
|
|
12
|
+
[DictionaryKind.term]: Omit<Term, 'id' | 'domainId' | 'order'> & {
|
|
13
|
+
domain: string;
|
|
14
|
+
};
|
|
15
|
+
[DictionaryKind.domain]: Omit<Domain, 'id' | 'order'>;
|
|
16
|
+
};
|
|
17
|
+
export type DictionaryCsvField<K extends DictionaryKind> = Extract<keyof DictionaryCsvValues[K], string>;
|
|
18
|
+
/**
|
|
19
|
+
* The columns of the editor's own format, in the order an export writes them,
|
|
20
|
+
* each headed by its field's name. No id rides, since every document mints its
|
|
21
|
+
* own, so a file carries into another document whole.
|
|
22
|
+
*/
|
|
23
|
+
export declare const DictionaryCsvColumns: {
|
|
24
|
+
readonly [K in DictionaryKind]: ReadonlyArray<DictionaryCsvField<K>>;
|
|
25
|
+
};
|
|
26
|
+
/** A row a file brings: its name, and each other field the file has a column for. */
|
|
27
|
+
export type DictionaryCsvRow<K extends DictionaryKind> = {
|
|
28
|
+
name: string;
|
|
29
|
+
} & Partial<DictionaryCsvValues[K]>;
|
|
30
|
+
/** A dictionary file as read: its kind and format, told by its header, and its rows in file order. */
|
|
31
|
+
export type DictionaryCsvRead = {
|
|
32
|
+
[K in DictionaryKind]: {
|
|
33
|
+
kind: K;
|
|
34
|
+
format: DictionaryCsvFormat;
|
|
35
|
+
/** The fields the file has columns for, the name first, in the own format's order. */
|
|
36
|
+
fields: Array<DictionaryCsvField<K>>;
|
|
37
|
+
/** Every row with a name, each holding exactly the fields above. */
|
|
38
|
+
rows: Array<DictionaryCsvRow<K>>;
|
|
39
|
+
/** The rows left out for an empty name; a record of empty cells is no row at all. */
|
|
40
|
+
skipped: number;
|
|
41
|
+
};
|
|
42
|
+
}[DictionaryKind];
|
|
43
|
+
/**
|
|
44
|
+
* Reads a dictionary file's text by the one layout its header names, else null.
|
|
45
|
+
* The own format's cells stay as written, so an export reads back to its rows;
|
|
46
|
+
* the public standard's are trimmed, and a domain's type columns join in one.
|
|
47
|
+
*/
|
|
48
|
+
export declare function readDictionaryCsv(text: string): DictionaryCsvRead | null;
|
|
49
|
+
/**
|
|
50
|
+
* Writes one dictionary's rows in the editor's own format: the field names as
|
|
51
|
+
* the header over one record per row, in the order given. A term's row names
|
|
52
|
+
* its domain, which the caller looks up by the term's domain id.
|
|
53
|
+
*/
|
|
54
|
+
export declare function writeDictionaryCsv<K extends DictionaryKind>(kind: K, rows: ReadonlyArray<DictionaryCsvValues[K]>): string;
|
|
55
|
+
//# sourceMappingURL=dictionaryCsv.d.ts.map
|
|
@@ -59,6 +59,10 @@ export type DiffEntry = {
|
|
|
59
59
|
name: string;
|
|
60
60
|
/** What the saved document calls it, the same as name unless renamed or added. */
|
|
61
61
|
prevName: string;
|
|
62
|
+
/** A table's or column's logical name, as name is taken, which a label shows and no change counts; '' for any other. */
|
|
63
|
+
logicalName: string;
|
|
64
|
+
/** The saved document's logical name, as prevName is taken. */
|
|
65
|
+
prevLogicalName: string;
|
|
62
66
|
changes: DiffChange[];
|
|
63
67
|
/** A table's columns, indexes and foreign keys, in that order. */
|
|
64
68
|
children: DiffEntry[];
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { DictionaryKind } from '../../engine/modules/dictionary/actions';
|
|
1
2
|
import { DocumentPngOptions, DocumentSvgOptions } from '../../services/export-png';
|
|
2
3
|
type ExportOptions = {
|
|
3
4
|
fileName: string;
|
|
@@ -6,6 +7,15 @@ type ExportFileCallback = (blob: Blob, options: ExportOptions) => void;
|
|
|
6
7
|
export declare function setExportFileCallback(callback: ExportFileCallback | null): void;
|
|
7
8
|
export declare function exportJSON(json: string, name?: string): void;
|
|
8
9
|
export declare function exportSchemaSQL(sql: string, name?: string): void;
|
|
10
|
+
/**
|
|
11
|
+
* One dictionary's sheet as a CSV file, named as the other exports are with
|
|
12
|
+
* the sheet after the time. The text is written as given, so the byte order
|
|
13
|
+
* mark and the CRLF line ends the dictionary codec writes reach the file.
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* exportCSV(writeDictionaryCsv('word', words), 'word', databaseName);
|
|
17
|
+
*/
|
|
18
|
+
export declare function exportCSV(csv: string, sheet: DictionaryKind, name?: string): void;
|
|
9
19
|
/** The Code Generator's text, named as the other exports are, with its language's extension. */
|
|
10
20
|
export declare function exportCode(code: string, extension: string, name?: string): void;
|
|
11
21
|
/**
|
|
@@ -10,13 +10,14 @@ export declare const FindField: {
|
|
|
10
10
|
readonly memo: "memo";
|
|
11
11
|
readonly indexName: "indexName";
|
|
12
12
|
readonly tableGroupName: "tableGroupName";
|
|
13
|
+
readonly logicalName: "logicalName";
|
|
13
14
|
};
|
|
14
15
|
export type FindField = ValuesType<typeof FindField>;
|
|
15
16
|
export declare const FindFieldList: ReadonlyArray<FindField>;
|
|
16
17
|
/**
|
|
17
18
|
* The kinds of text Find and Replace first opens on, the names alone of
|
|
18
|
-
* tables, columns, indexes and table groups
|
|
19
|
-
* memo is prose a rename should not reach unasked.
|
|
19
|
+
* tables, columns, indexes and table groups and the logical names (owner
|
|
20
|
+
* decisions): a comment or memo is prose a rename should not reach unasked.
|
|
20
21
|
*/
|
|
21
22
|
export declare const DEFAULT_FIND_FIELDS: ReadonlyArray<FindField>;
|
|
22
23
|
export type FindMatch = {
|
|
@@ -32,6 +33,11 @@ export type FindMatch = {
|
|
|
32
33
|
end: number;
|
|
33
34
|
};
|
|
34
35
|
type Field = Omit<FindMatch, 'start' | 'end'>;
|
|
36
|
+
/**
|
|
37
|
+
* Whether a logical name field is a table's, which bears its table's id as
|
|
38
|
+
* its own, rather than a column's: the one field kind both of them hold.
|
|
39
|
+
*/
|
|
40
|
+
export declare const isTableLogicalName: ({ field, id, tableId, }: Pick<FindMatch, "field" | "id" | "tableId">) => boolean;
|
|
35
41
|
/**
|
|
36
42
|
* What changes a text the search reads, or which fields it walks: the actions
|
|
37
43
|
* a search on screen runs again on. A hover, a selection or a scroll changes
|
|
@@ -50,8 +56,8 @@ export type FieldOrder = {
|
|
|
50
56
|
/** The tables and the table groups by name, as the tree lists them, ties in document order. */
|
|
51
57
|
export declare function treeOrderOf({ doc, collections }: RootState): FieldOrder;
|
|
52
58
|
/**
|
|
53
|
-
* Every text field the fields given cover: each table's name
|
|
54
|
-
* its columns'
|
|
59
|
+
* Every text field the fields given cover: each table's logical name, name
|
|
60
|
+
* and comment, its columns' alike and its index names, then the table groups'
|
|
55
61
|
* names and the memos, in document order or in the order given.
|
|
56
62
|
*/
|
|
57
63
|
export declare function walkFields(state: RootState, fields: ReadonlyArray<FindField>, order?: FieldOrder): Field[];
|
|
@@ -8,7 +8,7 @@ export declare const FindFieldLabel: Record<FindField, PlainMessageKey>;
|
|
|
8
8
|
* table and column, the table an index belongs to, and nothing for a memo or
|
|
9
9
|
* a table group, which stand on their own.
|
|
10
10
|
*/
|
|
11
|
-
export declare function locationOf({ collections }: RootState,
|
|
11
|
+
export declare function locationOf({ collections }: RootState, match: FindMatch, i18n?: Pick<I18n, 't'>): string;
|
|
12
12
|
/** A result row's second line: where the match sits, then the kind of text it was found in. */
|
|
13
13
|
export declare function describeMatch(state: RootState, match: FindMatch, i18n?: Pick<I18n, 't'>): string;
|
|
14
14
|
export type Snippet = {
|
|
@@ -1,15 +1,19 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { CompositionAction } from '@dineug/r-html';
|
|
2
2
|
import { FindMatch } from './findMatches';
|
|
3
3
|
import { Matcher } from './matcher';
|
|
4
|
-
/**
|
|
5
|
-
|
|
4
|
+
/**
|
|
5
|
+
* What writes a new value into the field a match was found in, as an edit by
|
|
6
|
+
* hand does: a name through the generator that turns its derived flag off, a
|
|
7
|
+
* logical name through the one that derives its name, the rest by atom action.
|
|
8
|
+
*/
|
|
9
|
+
export declare function toFieldAction(match: Pick<FindMatch, 'field' | 'id' | 'tableId'>, value: string): CompositionAction;
|
|
6
10
|
export type ReplaceActions = {
|
|
7
|
-
actions:
|
|
11
|
+
actions: CompositionAction[];
|
|
8
12
|
/** The matches the replacement changed, leaving out one it wrote back as it was. */
|
|
9
13
|
replaced: number;
|
|
10
14
|
};
|
|
11
15
|
/**
|
|
12
|
-
* One
|
|
16
|
+
* One field action per field whose text the replacement changes, for a single
|
|
13
17
|
* dispatch: one undo entry, and the same LWW writes a peer receives from an
|
|
14
18
|
* edit by hand. Given one match, only that occurrence is replaced.
|
|
15
19
|
*
|
package/dist/utils/focus.d.ts
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { FocusTable, FocusType, SharedFocus } from '../engine/modules/editor/state';
|
|
2
2
|
export declare function isFocus(focusTable: Pick<FocusTable, 'tableId' | 'columnId' | 'focusType'> | null, focusType: FocusType, tableId: string, columnId?: string | null): boolean;
|
|
3
3
|
export declare const isSelectColumn: (focusTable: FocusTable | null, tableId: string, columnId: string) => boolean;
|
|
4
|
+
/** Whether the focus stands on any cell of this column. */
|
|
5
|
+
export declare const isFocusColumn: (focusTable: Pick<FocusTable, "tableId" | "columnId"> | null, tableId: string, columnId: string) => boolean;
|
|
4
6
|
export declare function isEdit(focusTable: FocusTable | null, focusType: FocusType, tableId: string, columnId?: string | null): boolean;
|
|
5
7
|
export declare function lastCursorFocus(input: HTMLInputElement | HTMLTextAreaElement): void;
|
|
6
8
|
export declare const toSharedFocus: (focusTable: FocusTable | null) => SharedFocus | null;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A count shown beside a name, a Dictionary sheet's or an Explorer folder's, its
|
|
3
|
+
* thousands grouped as the language groups them, in the digits 0 to 9 every
|
|
4
|
+
* other number in the editor is written in.
|
|
5
|
+
*
|
|
6
|
+
* @example
|
|
7
|
+
* formatCount('de-DE', 13176); // '13.176'
|
|
8
|
+
*/
|
|
9
|
+
export declare function formatCount(locale: string, count: number): string;
|
|
10
|
+
//# sourceMappingURL=formatCount.d.ts.map
|
|
@@ -37,7 +37,7 @@ export declare const KeyBindingName: {
|
|
|
37
37
|
readonly zenMode: "zenMode";
|
|
38
38
|
};
|
|
39
39
|
export type KeyBindingName = ValuesType<typeof KeyBindingName>;
|
|
40
|
-
export declare const KeyBindingNameList: ("undo" | "redo" | "
|
|
40
|
+
export declare const KeyBindingNameList: ("undo" | "redo" | "addColumn" | "removeColumn" | "search" | "stop" | "selectAllColumn" | "primaryKey" | "edit" | "addMemo" | "addTable" | "removeTable" | "addTableGroup" | "findReplace" | "groupSelectedTables" | "removeSelection" | "selectAllTable" | "relationshipZeroOne" | "relationshipZeroN" | "relationshipOneOnly" | "relationshipOneN" | "tableProperties" | "focusView" | "zoomIn" | "zoomOut" | "zoomReset" | "handTool" | "zenMode")[];
|
|
41
41
|
/**
|
|
42
42
|
* The chords a press inside a floating panel still carries to the editor:
|
|
43
43
|
* Find and Replace's own, search, the document's undo and redo, and the zoom.
|
|
@@ -14,9 +14,9 @@ export type AlignTypesInput = {
|
|
|
14
14
|
newColumnIds: string[];
|
|
15
15
|
};
|
|
16
16
|
/**
|
|
17
|
-
*
|
|
18
|
-
*
|
|
19
|
-
*
|
|
17
|
+
* While the sync is on, the type changes the sync makes over the relationships
|
|
18
|
+
* as they will stand to bring each existing child column to its parent's, none
|
|
19
|
+
* for one already there, then the unlink of each left off its domain's type.
|
|
20
20
|
*/
|
|
21
21
|
export declare function toAlignTypeActions(state: RootState, { relationshipId, start, end, newColumnIds }: AlignTypesInput): AnyAction[];
|
|
22
22
|
/**
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { RootState } from '../../engine/state';
|
|
2
2
|
import { SchemaSQLHeader } from './options';
|
|
3
3
|
import { CreateSchemaOptions, FormatIndexOptions, FormatTableOptions, WrittenObjects } from './utils';
|
|
4
|
-
export declare function createSchema(state: RootState, tableIds?: readonly string[], { statements, written }?: CreateSchemaOptions): string;
|
|
5
|
-
export declare function formatTable(state: RootState, { buffer, table, statements }: FormatTableOptions): void;
|
|
4
|
+
export declare function createSchema(state: RootState, tableIds?: readonly string[], { statements, written, logicalNameAsComment }?: CreateSchemaOptions): string;
|
|
5
|
+
export declare function formatTable(state: RootState, { buffer, table, statements, logicalNameAsComment }: FormatTableOptions): void;
|
|
6
6
|
/**
|
|
7
7
|
* A comment per column the diagram marks unique, after the table: UNIQUE is not
|
|
8
8
|
* one of the constraints Databricks accepts, so it is reported, never dropped.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { RootState } from '../../engine/state';
|
|
2
2
|
import { SchemaSQLHeader } from './options';
|
|
3
3
|
import { CreateSchemaOptions, FormatIndexOptions, FormatTableOptions, WrittenObjects } from './utils';
|
|
4
|
-
export declare function createSchema(state: RootState, tableIds?: readonly string[], { written }?: CreateSchemaOptions): string;
|
|
4
|
+
export declare function createSchema(state: RootState, tableIds?: readonly string[], { written, logicalNameAsComment }?: CreateSchemaOptions): string;
|
|
5
5
|
export declare function formatTable(state: RootState, { buffer, table }: FormatTableOptions): void;
|
|
6
6
|
/**
|
|
7
7
|
* One named constraint per column the diagram marks unique, after the table.
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { RootState } from '../../engine/state';
|
|
2
2
|
import { CreateSchemaOptions, FormatIndexOptions, FormatTableOptions } from './utils';
|
|
3
3
|
export { formatDropBlock, formatHeader } from './MySQL';
|
|
4
|
-
export declare function createSchema(state: RootState, tableIds?: readonly string[], { statements, written }?: CreateSchemaOptions): string;
|
|
5
|
-
export declare function formatTable(state: RootState, { buffer, table, statements }: FormatTableOptions): void;
|
|
4
|
+
export declare function createSchema(state: RootState, tableIds?: readonly string[], { statements, written, logicalNameAsComment }?: CreateSchemaOptions): string;
|
|
5
|
+
export declare function formatTable(state: RootState, { buffer, table, statements, logicalNameAsComment }: FormatTableOptions): void;
|
|
6
6
|
/**
|
|
7
7
|
* One named constraint per column the diagram marks unique, after the table.
|
|
8
8
|
* The whole export and the per-table Schema SQL tab both write it.
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { RootState } from '../../engine/state';
|
|
2
2
|
import { SchemaSQLHeader } from './options';
|
|
3
3
|
import { CreateSchemaOptions, FormatIndexOptions, FormatTableOptions, WrittenObjects } from './utils';
|
|
4
|
-
export declare function createSchema(state: RootState, tableIds?: readonly string[], { statements, written }?: CreateSchemaOptions): string;
|
|
5
|
-
export declare function formatTable(state: RootState, { buffer, table, statements }: FormatTableOptions): void;
|
|
4
|
+
export declare function createSchema(state: RootState, tableIds?: readonly string[], { statements, written, logicalNameAsComment }?: CreateSchemaOptions): string;
|
|
5
|
+
export declare function formatTable(state: RootState, { buffer, table, statements, logicalNameAsComment }: FormatTableOptions): void;
|
|
6
6
|
/**
|
|
7
7
|
* One named constraint per column the diagram marks unique, after the table.
|
|
8
8
|
* The whole export and the per-table Schema SQL tab both write it.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { RootState } from '../../engine/state';
|
|
2
2
|
import { SchemaSQLHeader } from './options';
|
|
3
3
|
import { CreateSchemaOptions, FormatIndexOptions, FormatTableOptions, WrittenObjects } from './utils';
|
|
4
|
-
export declare function createSchema(state: RootState, tableIds?: readonly string[], { written }?: CreateSchemaOptions): string;
|
|
4
|
+
export declare function createSchema(state: RootState, tableIds?: readonly string[], { written, logicalNameAsComment }?: CreateSchemaOptions): string;
|
|
5
5
|
export declare function formatTable(state: RootState, { buffer, table, written }: FormatTableOptions): void;
|
|
6
6
|
/**
|
|
7
7
|
* One named constraint per column the diagram marks unique, after the table.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { RootState } from '../../engine/state';
|
|
2
2
|
import { SchemaSQLHeader } from './options';
|
|
3
3
|
import { CreateSchemaOptions, FormatIndexOptions, FormatTableOptions, WrittenObjects } from './utils';
|
|
4
|
-
export declare function createSchema(state: RootState, tableIds?: readonly string[], { statements, written }?: CreateSchemaOptions): string;
|
|
4
|
+
export declare function createSchema(state: RootState, tableIds?: readonly string[], { statements, written, logicalNameAsComment }?: CreateSchemaOptions): string;
|
|
5
5
|
export declare function formatTable(state: RootState, { buffer, table, statements }: FormatTableOptions): void;
|
|
6
6
|
export declare function formatIndex({ settings: { bracketType }, collections }: RootState, { buffer, index, indexNames, statements }: FormatIndexOptions): void;
|
|
7
7
|
/**
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { RootState } from '../../engine/state';
|
|
2
2
|
import { CreateSchemaOptions, FormatIndexOptions, FormatTableOptions, WrittenObjects } from './utils';
|
|
3
|
-
export declare function createSchema(state: RootState, tableIds?: readonly string[], { statements, written }?: CreateSchemaOptions): string;
|
|
3
|
+
export declare function createSchema(state: RootState, tableIds?: readonly string[], { statements, written, logicalNameAsComment }?: CreateSchemaOptions): string;
|
|
4
4
|
/**
|
|
5
5
|
* An integer type name, with or without a width, which an AUTOINCREMENT key
|
|
6
6
|
* is written as INTEGER for; the rest keep their type and lose the keyword.
|
|
7
7
|
*/
|
|
8
8
|
export declare function isIntegerFamily(dataType: string): boolean;
|
|
9
|
-
export declare function formatTable(state: RootState, { buffer, table, statements }: FormatTableOptions): void;
|
|
9
|
+
export declare function formatTable(state: RootState, { buffer, table, statements, logicalNameAsComment }: FormatTableOptions): void;
|
|
10
10
|
export declare function formatIndex({ settings: { bracketType }, collections }: RootState, { buffer, index, indexNames, statements }: FormatIndexOptions): void;
|
|
11
11
|
/** SQLite has no database or schema to create or select in a script. */
|
|
12
12
|
export declare function formatHeader(): string;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { RootState } from '../../engine/state';
|
|
2
2
|
import { SchemaSQLHeader } from './options';
|
|
3
3
|
import { CreateSchemaOptions, FormatIndexOptions, FormatTableOptions } from './utils';
|
|
4
|
-
export declare function createSchema(state: RootState, tableIds?: readonly string[], { statements, written }?: CreateSchemaOptions): string;
|
|
5
|
-
export declare function formatTable(state: RootState, { buffer, table, statements }: FormatTableOptions): void;
|
|
4
|
+
export declare function createSchema(state: RootState, tableIds?: readonly string[], { statements, written, logicalNameAsComment }?: CreateSchemaOptions): string;
|
|
5
|
+
export declare function formatTable(state: RootState, { buffer, table, statements, logicalNameAsComment }: FormatTableOptions): void;
|
|
6
6
|
export declare function formatIndex({ collections, settings: { bracketType } }: RootState, { buffer, index, indexNames }: FormatIndexOptions): void;
|
|
7
7
|
/** USE SCHEMA, after CREATE SCHEMA IF NOT EXISTS for createAndUse. */
|
|
8
8
|
export declare function formatHeader({ settings: { bracketType } }: RootState, header: Exclude<SchemaSQLHeader, 'none'>, name: string): string;
|
|
@@ -19,6 +19,8 @@ export type SchemaSQLOptions = {
|
|
|
19
19
|
statements?: SchemaSQLStatements;
|
|
20
20
|
/** none when left out. */
|
|
21
21
|
header?: SchemaSQLHeader;
|
|
22
|
+
/** Whether a table or column with an empty comment writes its logical name as one; off when left out. */
|
|
23
|
+
logicalNameAsComment?: boolean;
|
|
22
24
|
};
|
|
23
25
|
/** The name a header may write: a plain identifier, so no vendor needs it escaped. */
|
|
24
26
|
export declare const HEADER_NAME_PATTERN: RegExp;
|
|
@@ -15,6 +15,8 @@ export interface CreateSchemaOptions {
|
|
|
15
15
|
/** Already what the database writes (resolveSchemaSQLOptions); create when left out. */
|
|
16
16
|
statements?: SchemaSQLStatements;
|
|
17
17
|
written?: WrittenObjects;
|
|
18
|
+
/** Whether an empty comment writes the logical name (commentToWrite); off when left out. */
|
|
19
|
+
logicalNameAsComment?: boolean;
|
|
18
20
|
}
|
|
19
21
|
export interface FormatTableOptions {
|
|
20
22
|
buffer: string[];
|
|
@@ -22,12 +24,16 @@ export interface FormatTableOptions {
|
|
|
22
24
|
/** create when left out. */
|
|
23
25
|
statements?: SchemaSQLStatements;
|
|
24
26
|
written?: WrittenObjects;
|
|
27
|
+
/** off when left out. */
|
|
28
|
+
logicalNameAsComment?: boolean;
|
|
25
29
|
}
|
|
26
30
|
export interface FormatColumnOptions {
|
|
27
31
|
buffer: string[];
|
|
28
32
|
column: Column;
|
|
29
33
|
isComma: boolean;
|
|
30
34
|
spaceSize: MaxLength;
|
|
35
|
+
/** off when left out. */
|
|
36
|
+
logicalNameAsComment?: boolean;
|
|
31
37
|
}
|
|
32
38
|
export interface FormatRelationOptions {
|
|
33
39
|
buffer: string[];
|
|
@@ -48,7 +54,15 @@ export interface FormatIndexOptions {
|
|
|
48
54
|
export interface FormatCommentOptions {
|
|
49
55
|
buffer: string[];
|
|
50
56
|
table: Table;
|
|
57
|
+
/** off when left out. */
|
|
58
|
+
logicalNameAsComment?: boolean;
|
|
51
59
|
}
|
|
60
|
+
/**
|
|
61
|
+
* The comment the DDL writes on a table or column: its own while not blank,
|
|
62
|
+
* else its logical name while logicalNameAsComment is on and that is not
|
|
63
|
+
* blank, else the empty string, which writes no comment.
|
|
64
|
+
*/
|
|
65
|
+
export declare function commentToWrite({ comment, logicalName }: Pick<Table | Column, 'comment' | 'logicalName'>, logicalNameAsComment?: boolean): string;
|
|
52
66
|
export interface Name {
|
|
53
67
|
id: string;
|
|
54
68
|
name: string;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { RootState } from '../../engine/state';
|
|
2
|
-
import { Settings } from '../../internal-types';
|
|
3
2
|
import { ClipboardIndex, ClipboardPayload, ClipboardRelationship } from '.';
|
|
4
3
|
export declare function tableCopyToText(state: RootState): string;
|
|
5
4
|
export declare function tableCopyToHtml(state: RootState): string;
|
|
@@ -17,7 +16,7 @@ export declare function toClipboardRelationships({ doc, collections }: Pick<Root
|
|
|
17
16
|
*/
|
|
18
17
|
export declare function toClipboardIndexes({ doc, collections }: Pick<RootState, 'doc' | 'collections'>, tableIds: string[]): ClipboardIndex[];
|
|
19
18
|
export declare function columnsCopyToPayload({ editor: { focusTable }, collections, }: RootState): ClipboardPayload | null;
|
|
20
|
-
export declare function entitiesToTsv(payload: ClipboardPayload,
|
|
21
|
-
export declare function entitiesToHtmlTable(payload: ClipboardPayload,
|
|
19
|
+
export declare function entitiesToTsv(payload: ClipboardPayload, state: RootState): string;
|
|
20
|
+
export declare function entitiesToHtmlTable(payload: ClipboardPayload, state: RootState): string;
|
|
22
21
|
export declare function payloadToHtml(payload: ClipboardPayload, tableHtml: string): string;
|
|
23
22
|
//# sourceMappingURL=copy.d.ts.map
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { RootState } from '../../engine/state';
|
|
1
2
|
import { ValuesType } from '../../internal-types';
|
|
2
3
|
export * from './payload';
|
|
3
4
|
export * from './placement';
|
|
@@ -11,8 +12,15 @@ export declare const CellType: {
|
|
|
11
12
|
readonly columnAutoIncrement: "columnAutoIncrement";
|
|
12
13
|
readonly columnDefault: "columnDefault";
|
|
13
14
|
readonly columnComment: "columnComment";
|
|
15
|
+
readonly columnLogicalName: "columnLogicalName";
|
|
16
|
+
readonly columnDomain: "columnDomain";
|
|
14
17
|
};
|
|
15
18
|
export type CellType = ValuesType<typeof CellType>;
|
|
16
19
|
export declare const hasCellType: (value: string) => boolean;
|
|
17
|
-
|
|
20
|
+
/**
|
|
21
|
+
* The column types of a row's cells in their order, as the name view lays
|
|
22
|
+
* them out: the logical view's name cell holds the logical name. A column
|
|
23
|
+
* type this release does not know has no cell.
|
|
24
|
+
*/
|
|
25
|
+
export declare function getShowColumnOrder(show: number, columnOrder: number[], nameViewMode: RootState['settings']['nameViewMode']): number[];
|
|
18
26
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { RootState } from '../../engine/state';
|
|
2
2
|
import { Column } from '../../internal-types';
|
|
3
3
|
import { ClipboardPayload, ParseResult } from './payload';
|
|
4
|
-
export declare function tablePasteFromTextToColumns(
|
|
5
|
-
export declare function tablePasteFromHtmlToColumns(
|
|
4
|
+
export declare function tablePasteFromTextToColumns(state: RootState, text: string): Column[];
|
|
5
|
+
export declare function tablePasteFromHtmlToColumns(state: RootState, html: string): Column[];
|
|
6
6
|
export declare function readClipboardPayload(dataTransfer: DataTransfer): ParseResult;
|
|
7
7
|
export declare function payloadToColumns({ columns }: ClipboardPayload): Column[];
|
|
8
8
|
//# sourceMappingURL=paste.d.ts.map
|
|
@@ -10,11 +10,17 @@ export declare const PayloadKind: {
|
|
|
10
10
|
readonly columns: "columns";
|
|
11
11
|
};
|
|
12
12
|
export type PayloadKind = ValuesType<typeof PayloadKind>;
|
|
13
|
+
/**
|
|
14
|
+
* A copied table. Its logical name and derived flag, like a column's logical
|
|
15
|
+
* name and domain, are absent from a copy made before the dictionaries.
|
|
16
|
+
*/
|
|
13
17
|
export type ClipboardTable = {
|
|
14
18
|
sourceId: string;
|
|
15
19
|
name: string;
|
|
20
|
+
logicalName?: string;
|
|
16
21
|
comment: string;
|
|
17
22
|
columnIds: string[];
|
|
23
|
+
nameDerived?: boolean;
|
|
18
24
|
ui: {
|
|
19
25
|
x: number;
|
|
20
26
|
y: number;
|
|
@@ -32,6 +38,12 @@ export type ClipboardColumn = {
|
|
|
32
38
|
dataType: string;
|
|
33
39
|
default: string;
|
|
34
40
|
options: number;
|
|
41
|
+
logicalName?: string;
|
|
42
|
+
/**
|
|
43
|
+
* The domain the column linked where it was copied, which a paste keeps
|
|
44
|
+
* only while the document it lands in lists it.
|
|
45
|
+
*/
|
|
46
|
+
domainId?: string;
|
|
35
47
|
ui: {
|
|
36
48
|
keys: number;
|
|
37
49
|
widthName: number;
|
|
@@ -12,6 +12,7 @@ export declare const hasLanguage: (value: number) => boolean;
|
|
|
12
12
|
export declare const hasColumnType: (value: number) => boolean;
|
|
13
13
|
export declare const hasDatabaseVendor: (value: string) => boolean;
|
|
14
14
|
export declare const hasCanvasType: (value: string) => boolean;
|
|
15
|
+
export declare const hasNameViewMode: (value: string) => boolean;
|
|
15
16
|
export declare function textInRange(width: number): number;
|
|
16
17
|
export declare function toSafeString(value: any): string;
|
|
17
18
|
export declare function isHighLevelTable(zoomLevel: number): boolean;
|