quill-table-up 3.4.0 → 3.5.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 CHANGED
@@ -65,16 +65,18 @@ const quill = new Quill('#editor', {
65
65
 
66
66
  **Full options usage see [demo](https://github.com/quill-modules/quill-table-up/blob/master/docs/index.js#L38)**
67
67
 
68
- | Attribute | Description | Type | Default |
69
- | ------------- | --------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | ------------------------------------------ |
70
- | full | if set `true`. width max will be 100% | `boolean` | `false` |
71
- | fullSwitch | enable to choose insert a full width table | `boolean` | `true` |
72
- | texts | the text used to create the table | `TableTextOptions \| ((key: string) => string)` | `defaultTexts` |
73
- | customSelect | display a custom select to custom row and column number add a table. module provides default selector `defaultCustomSelect` | `(tableModule: TableUp, picker: Picker) => Promise<HTMLElement> \| HTMLElement` | - |
74
- | customBtn | display a custom button to custom row and column number add a table. it only when use `defaultCustomSelect` will effect | `boolean` | `false` |
75
- | icon | picker svg icon string. it will set with `innerHTML` | `string` | `origin table icon` |
76
- | autoMergeCell | empty row or column will auto merge to one | `boolean` | `true` |
77
- | modules | the module plugin to help user control about table operate. see [`Export Internal Module`](#export-internal-module) | `[]` | `{ module: Contstructor, options: any }[]` |
68
+ | Attribute | Description | Type | Default |
69
+ | -------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | ------------------------------------------ |
70
+ | full | if set `true`. width max will be 100% | `boolean` | `false` |
71
+ | fullSwitch | enable to choose insert a full width table | `boolean` | `true` |
72
+ | texts | the text used to create the table | `TableTextOptions \| ((key: string) => string)` | `defaultTexts` |
73
+ | customSelect | display a custom select to custom row and column number add a table. module provides default selector `defaultCustomSelect` | `(tableModule: TableUp, picker: Picker) => Promise<HTMLElement> \| HTMLElement` | - |
74
+ | customBtn | display a custom button to custom row and column number add a table. it only when use `defaultCustomSelect` will effect | `boolean` | `false` |
75
+ | icon | picker svg icon string. it will set with `innerHTML` | `string` | `origin table icon` |
76
+ | autoMergeCell | empty row or column will auto merge to one | `boolean` | `true` |
77
+ | pasteStyleSheet | resolve `<style>` stylesheet rules to inline styles on table cells when pasting. note: when enabled, it processes **all** pasted HTML (not just tables), which may affect non-table paste content and add extra overhead for large pastes | `boolean` | `false` |
78
+ | pasteDefaultTagStyle | when `pasteStyleSheet` is enabled, also apply rules with tag-only selectors (e.g. `td`, `table td`). otherwise only class/id/attribute selectors are applied | `boolean` | `false` |
79
+ | modules | the module plugin to help user control about table operate. see [`Export Internal Module`](#export-internal-module) | `[]` | `{ module: Contstructor, options: any }[]` |
78
80
 
79
81
  > I'm not suggest to use `TableVirtualScrollbar` and `TableResizeLine` at same time, because it have a little conflict when user hover on it. Just like the first editor in [demo](https://quill-modules.github.io/quill-table-up/)
80
82
 
package/dist/index.d.ts CHANGED
@@ -442,6 +442,7 @@ declare class TableClipboard extends Clipboard {
442
442
  cellCount: number;
443
443
  colCount: number;
444
444
  constructor(quill: Quill, options: Partial<ClipboardOptions>);
445
+ normalizeHTML(doc: Document): void;
445
446
  getStyleBackgroundColor(node: Node, delta: Delta$1): void;
446
447
  matchTable(node: Node, delta: Delta$1): Delta$1;
447
448
  matchTbody(node: Node, delta: Delta$1): Delta$1;
@@ -919,8 +920,8 @@ declare class TableSelection extends TableDomSelector {
919
920
  updateWithSelectedTds(): void;
920
921
  update(): void;
921
922
  getTableViewScroll(): {
922
- x: number;
923
923
  y: number;
924
+ x: number;
924
925
  };
925
926
  setSelectionTable(table: HTMLTableElement | undefined): void;
926
927
  showDisplay(): void;
@@ -999,6 +1000,8 @@ interface TableUpOptions {
999
1000
  texts: TableTextOptions;
1000
1001
  icon: string;
1001
1002
  autoMergeCell: boolean;
1003
+ pasteStyleSheet: boolean;
1004
+ pasteDefaultTagStyle: boolean;
1002
1005
  modules: TableUpModule[];
1003
1006
  }
1004
1007
  interface TableUpOptionsInput extends Partial<Omit<TableUpOptions, 'texts'>> {