@wangeditor-next/list-module 1.3.0 → 2.0.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/LICENSE +21 -21
- package/README.md +3 -3
- package/dist/basic-modules/src/modules/image/custom-types.d.ts +22 -0
- package/dist/core/src/config/index.d.ts +13 -0
- package/dist/core/src/config/interface.d.ts +270 -0
- package/dist/core/src/config/register.d.ts +12 -0
- package/dist/core/src/config/style-mode.d.ts +8 -0
- package/dist/core/src/constants/index.d.ts +1 -0
- package/dist/core/src/constants/svg.d.ts +12 -0
- package/dist/core/src/create/bind-node-relation.d.ts +15 -0
- package/dist/core/src/create/create-editor.d.ts +10 -0
- package/dist/core/src/create/create-toolbar.d.ts +14 -0
- package/dist/core/src/create/helper.d.ts +37 -0
- package/dist/core/src/create/index.d.ts +7 -0
- package/dist/core/src/editor/dom-editor.d.ts +144 -0
- package/dist/core/src/editor/interface.d.ts +73 -0
- package/dist/core/src/editor/plugins/with-config.d.ts +7 -0
- package/dist/core/src/editor/plugins/with-content.d.ts +7 -0
- package/dist/core/src/editor/plugins/with-dom.d.ts +10 -0
- package/dist/core/src/editor/plugins/with-emitter.d.ts +7 -0
- package/dist/core/src/editor/plugins/with-event-data.d.ts +7 -0
- package/dist/core/src/editor/plugins/with-max-length.d.ts +7 -0
- package/dist/core/src/editor/plugins/with-selection.d.ts +7 -0
- package/dist/core/src/i18n/index.d.ts +32 -0
- package/dist/core/src/index.d.ts +33 -0
- package/dist/core/src/menus/bar/HoverBar.d.ts +48 -0
- package/dist/core/src/menus/bar/Toolbar.d.ts +36 -0
- package/dist/core/src/menus/bar-item/BaseButton.d.ts +26 -0
- package/dist/core/src/menus/bar-item/DropPanelButton.d.ts +14 -0
- package/dist/core/src/menus/bar-item/GroupButton.d.ts +17 -0
- package/dist/core/src/menus/bar-item/ModalButton.d.ts +25 -0
- package/dist/core/src/menus/bar-item/Select.d.ts +22 -0
- package/dist/core/src/menus/bar-item/SimpleButton.d.ts +11 -0
- package/dist/core/src/menus/bar-item/index.d.ts +24 -0
- package/dist/core/src/menus/bar-item/tooltip.d.ts +6 -0
- package/dist/core/src/menus/helpers/helpers.d.ts +18 -0
- package/dist/core/src/menus/helpers/position.d.ts +36 -0
- package/dist/core/src/menus/index.d.ts +9 -0
- package/dist/core/src/menus/interface.d.ts +65 -0
- package/dist/core/src/menus/panel-and-modal/BaseClass.d.ts +26 -0
- package/dist/core/src/menus/panel-and-modal/DropPanel.d.ts +14 -0
- package/dist/core/src/menus/panel-and-modal/Modal.d.ts +44 -0
- package/dist/core/src/menus/panel-and-modal/SelectList.d.ts +20 -0
- package/dist/core/src/menus/register.d.ts +15 -0
- package/dist/core/src/parse-html/helper.d.ts +10 -0
- package/dist/core/src/parse-html/index.d.ts +35 -0
- package/dist/core/src/parse-html/parse-common-elem-html.d.ts +15 -0
- package/dist/core/src/parse-html/parse-elem-html.d.ts +15 -0
- package/dist/core/src/parse-html/parse-text-elem-html.d.ts +16 -0
- package/dist/core/src/render/element/getRenderElem.d.ts +11 -0
- package/dist/core/src/render/element/renderElement.d.ts +9 -0
- package/dist/core/src/render/element/renderStyle.d.ts +15 -0
- package/dist/core/src/render/helper.d.ts +7 -0
- package/dist/core/src/render/index.d.ts +27 -0
- package/dist/core/src/render/node2Vnode.d.ts +15 -0
- package/dist/core/src/render/text/genVnode.d.ts +9 -0
- package/dist/core/src/render/text/renderStyle.d.ts +15 -0
- package/dist/core/src/render/text/renderText.d.ts +9 -0
- package/dist/core/src/text-area/TextArea.d.ts +52 -0
- package/dist/core/src/text-area/event-handlers/beforeInput.d.ts +8 -0
- package/dist/core/src/text-area/event-handlers/blur.d.ts +8 -0
- package/dist/core/src/text-area/event-handlers/click.d.ts +8 -0
- package/dist/core/src/text-area/event-handlers/composition.d.ts +27 -0
- package/dist/core/src/text-area/event-handlers/copy.d.ts +8 -0
- package/dist/core/src/text-area/event-handlers/cut.d.ts +8 -0
- package/dist/core/src/text-area/event-handlers/drag.d.ts +9 -0
- package/dist/core/src/text-area/event-handlers/drop.d.ts +8 -0
- package/dist/core/src/text-area/event-handlers/focus.d.ts +8 -0
- package/dist/core/src/text-area/event-handlers/index.d.ts +35 -0
- package/dist/core/src/text-area/event-handlers/keydown.d.ts +8 -0
- package/dist/core/src/text-area/event-handlers/keypress.d.ts +8 -0
- package/dist/core/src/text-area/event-handlers/paste.d.ts +8 -0
- package/dist/core/src/text-area/helpers.d.ts +30 -0
- package/dist/core/src/text-area/place-holder.d.ts +18 -0
- package/dist/core/src/text-area/syncSelection.d.ts +19 -0
- package/dist/core/src/text-area/update-view.d.ts +13 -0
- package/dist/core/src/to-html/elem2html.d.ts +8 -0
- package/dist/core/src/to-html/index.d.ts +32 -0
- package/dist/core/src/to-html/node2html.d.ts +8 -0
- package/dist/core/src/to-html/text2html.d.ts +8 -0
- package/dist/core/src/upload/createUploader.d.ts +12 -0
- package/dist/core/src/upload/createUppyUploader.d.ts +7 -0
- package/dist/core/src/upload/index.d.ts +9 -0
- package/dist/core/src/upload/interface.d.ts +72 -0
- package/dist/core/src/utils/dom.d.ts +103 -0
- package/dist/core/src/utils/hotkeys.d.ts +35 -0
- package/dist/core/src/utils/key.d.ts +11 -0
- package/dist/core/src/utils/line.d.ts +14 -0
- package/dist/core/src/utils/sanitize-html.d.ts +5 -0
- package/dist/core/src/utils/ua.d.ts +14 -0
- package/dist/core/src/utils/util.d.ts +28 -0
- package/dist/core/src/utils/vdom.d.ts +34 -0
- package/dist/core/src/utils/weak-maps.d.ts +60 -0
- package/dist/css/style.css +1 -0
- package/dist/index.js +2 -0
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +2 -0
- package/dist/index.mjs.map +1 -0
- package/dist/list-module/src/constants/svg.d.ts +11 -0
- package/dist/list-module/src/index.d.ts +8 -0
- package/dist/list-module/src/locale/en.d.ts +11 -0
- package/dist/list-module/src/locale/index.d.ts +5 -0
- package/dist/list-module/src/locale/zh-CN.d.ts +11 -0
- package/dist/list-module/src/module/custom-types.d.ts +11 -0
- package/dist/list-module/src/module/elem-to-html.d.ts +16 -0
- package/dist/list-module/src/module/helpers.d.ts +13 -0
- package/dist/list-module/src/module/index.d.ts +7 -0
- package/dist/list-module/src/module/menu/BaseMenu.d.ts +18 -0
- package/dist/list-module/src/module/menu/BulletedListMenu.d.ts +11 -0
- package/dist/list-module/src/module/menu/NumberedListMenu.d.ts +11 -0
- package/dist/list-module/src/module/menu/index.d.ts +14 -0
- package/dist/list-module/src/module/parse-elem-html.d.ts +19 -0
- package/dist/list-module/src/module/plugin.d.ts +7 -0
- package/dist/list-module/src/module/render-elem.d.ts +13 -0
- package/dist/list-module/src/module/style-class.d.ts +6 -0
- package/dist/list-module/src/utils/dom.d.ts +19 -0
- package/dist/list-module/src/utils/maps.d.ts +6 -0
- package/dist/list-module/src/utils/util.d.ts +6 -0
- package/dist/table-module/src/utils/has-common.d.ts +7 -0
- package/dist/table-module/src/utils/index.d.ts +5 -0
- package/dist/table-module/src/utils/is-of-type.d.ts +6 -0
- package/dist/table-module/src/utils/matrices.d.ts +9 -0
- package/dist/table-module/src/utils/options.d.ts +25 -0
- package/dist/table-module/src/utils/point.d.ts +7 -0
- package/dist/table-module/src/utils/types.d.ts +19 -0
- package/dist/video-module/src/module/custom-types.d.ts +23 -0
- package/package.json +29 -23
- package/CHANGELOG.md +0 -115
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @description icon svg
|
|
3
|
+
* @author wangfupeng
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* 【注意】svg 字符串的长度 ,否则会导致代码体积过大
|
|
7
|
+
* 尽量选择 https://www.iconfont.cn/collections/detail?spm=a313x.7781069.0.da5a778a4&cid=20293
|
|
8
|
+
* 找不到再从 iconfont.com 搜索
|
|
9
|
+
*/
|
|
10
|
+
export declare const BULLETED_LIST_SVG = "<svg viewBox=\"0 0 1024 1024\"><path d=\"M384 64h640v128H384V64z m0 384h640v128H384v-128z m0 384h640v128H384v-128zM0 128a128 128 0 1 1 256 0 128 128 0 0 1-256 0z m0 384a128 128 0 1 1 256 0 128 128 0 0 1-256 0z m0 384a128 128 0 1 1 256 0 128 128 0 0 1-256 0z\"></path></svg>";
|
|
11
|
+
export declare const NUMBERED_LIST_SVG = "<svg viewBox=\"0 0 1024 1024\"><path d=\"M384 832h640v128H384z m0-384h640v128H384z m0-384h640v128H384zM192 0v256H128V64H64V0zM128 526.016v50.016h128v64H64v-146.016l128-60V384H64v-64h192v146.016zM256 704v320H64v-64h128v-64H64v-64h128v-64H64v-64z\"></path></svg>";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @description to html
|
|
3
|
+
* @author wangfupeng
|
|
4
|
+
*/
|
|
5
|
+
import { IDomEditor } from '@wangeditor-next/core';
|
|
6
|
+
import { Element } from 'slate';
|
|
7
|
+
declare function elemToHtml(elem: Element, childrenHtml: string, editor?: IDomEditor): {
|
|
8
|
+
html: string;
|
|
9
|
+
prefix?: string;
|
|
10
|
+
suffix?: string;
|
|
11
|
+
};
|
|
12
|
+
declare const listItemToHtmlConf: {
|
|
13
|
+
type: string;
|
|
14
|
+
elemToHtml: typeof elemToHtml;
|
|
15
|
+
};
|
|
16
|
+
export default listItemToHtmlConf;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @description table menu helpers
|
|
3
|
+
* @author wangfupeng
|
|
4
|
+
*/
|
|
5
|
+
import { IDomEditor } from '@wangeditor-next/core';
|
|
6
|
+
import { ListItemElement } from './custom-types';
|
|
7
|
+
/**
|
|
8
|
+
* 获取上一个同一 level 的 list item
|
|
9
|
+
* @param editor 编辑器实例
|
|
10
|
+
* @param elem elem
|
|
11
|
+
*/
|
|
12
|
+
export declare function getBrotherListNodeByLevel(editor: IDomEditor, elem: ListItemElement, level?: number): ListItemElement | null;
|
|
13
|
+
export declare function hasSameOrderWithBrother(editor: IDomEditor, elem: ListItemElement, level?: number): boolean;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @description base menu
|
|
3
|
+
* @author wangfupeng
|
|
4
|
+
*/
|
|
5
|
+
import { IButtonMenu, IDomEditor } from '@wangeditor-next/core';
|
|
6
|
+
declare abstract class BaseMenu implements IButtonMenu {
|
|
7
|
+
readonly type = "list-item";
|
|
8
|
+
abstract readonly ordered: boolean;
|
|
9
|
+
abstract readonly title: string;
|
|
10
|
+
abstract readonly iconSvg: string;
|
|
11
|
+
readonly tag = "button";
|
|
12
|
+
private getListNode;
|
|
13
|
+
getValue(_editor: IDomEditor): string | boolean;
|
|
14
|
+
isActive(editor: IDomEditor): boolean;
|
|
15
|
+
isDisabled(editor: IDomEditor): boolean;
|
|
16
|
+
exec(editor: IDomEditor, _value: string | boolean): void;
|
|
17
|
+
}
|
|
18
|
+
export default BaseMenu;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @description bulleted list menu
|
|
3
|
+
* @author wangfupeng
|
|
4
|
+
*/
|
|
5
|
+
import BaseMenu from './BaseMenu';
|
|
6
|
+
declare class BulletedListMenu extends BaseMenu {
|
|
7
|
+
readonly ordered = false;
|
|
8
|
+
readonly title: string;
|
|
9
|
+
readonly iconSvg = "<svg viewBox=\"0 0 1024 1024\"><path d=\"M384 64h640v128H384V64z m0 384h640v128H384v-128z m0 384h640v128H384v-128zM0 128a128 128 0 1 1 256 0 128 128 0 0 1-256 0z m0 384a128 128 0 1 1 256 0 128 128 0 0 1-256 0z m0 384a128 128 0 1 1 256 0 128 128 0 0 1-256 0z\"></path></svg>";
|
|
10
|
+
}
|
|
11
|
+
export default BulletedListMenu;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @description numbered list menu
|
|
3
|
+
* @author wangfupeng
|
|
4
|
+
*/
|
|
5
|
+
import BaseMenu from './BaseMenu';
|
|
6
|
+
declare class NumberedListMenu extends BaseMenu {
|
|
7
|
+
readonly ordered = true;
|
|
8
|
+
readonly title: string;
|
|
9
|
+
readonly iconSvg = "<svg viewBox=\"0 0 1024 1024\"><path d=\"M384 832h640v128H384z m0-384h640v128H384z m0-384h640v128H384zM192 0v256H128V64H64V0zM128 526.016v50.016h128v64H64v-146.016l128-60V384H64v-64h192v146.016zM256 704v320H64v-64h128v-64H64v-64h128v-64H64v-64z\"></path></svg>";
|
|
10
|
+
}
|
|
11
|
+
export default NumberedListMenu;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @description menu entry
|
|
3
|
+
* @author wangfupeng
|
|
4
|
+
*/
|
|
5
|
+
import BulletedListMenu from './BulletedListMenu';
|
|
6
|
+
import NumberedListMenu from './NumberedListMenu';
|
|
7
|
+
export declare const bulletedListMenuConf: {
|
|
8
|
+
key: string;
|
|
9
|
+
factory(): BulletedListMenu;
|
|
10
|
+
};
|
|
11
|
+
export declare const numberedListMenuConf: {
|
|
12
|
+
key: string;
|
|
13
|
+
factory(): NumberedListMenu;
|
|
14
|
+
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @description parse elem html
|
|
3
|
+
* @author wangfupeng
|
|
4
|
+
*/
|
|
5
|
+
import { IDomEditor } from '@wangeditor-next/core';
|
|
6
|
+
import { Descendant } from 'slate';
|
|
7
|
+
import { DOMElement } from '../utils/dom';
|
|
8
|
+
import { ListItemElement } from './custom-types';
|
|
9
|
+
declare function parseItemHtml(elem: DOMElement, children: Descendant[], editor: IDomEditor): ListItemElement;
|
|
10
|
+
export declare const parseItemHtmlConf: {
|
|
11
|
+
selector: string;
|
|
12
|
+
parseElemHtml: typeof parseItemHtml;
|
|
13
|
+
};
|
|
14
|
+
declare function parseListHtml(_elem: DOMElement, children: Descendant[], _editor: IDomEditor): ListItemElement[];
|
|
15
|
+
export declare const parseListHtmlConf: {
|
|
16
|
+
selector: string;
|
|
17
|
+
parseElemHtml: typeof parseListHtml;
|
|
18
|
+
};
|
|
19
|
+
export {};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @description render list elem
|
|
3
|
+
* @author wangfupeng
|
|
4
|
+
*/
|
|
5
|
+
import { IDomEditor } from '@wangeditor-next/core';
|
|
6
|
+
import { Element as SlateElement } from 'slate';
|
|
7
|
+
import { VNode } from 'snabbdom';
|
|
8
|
+
declare function renderListElem(elemNode: SlateElement, children: VNode[] | null, editor: IDomEditor): VNode;
|
|
9
|
+
declare const renderListItemConf: {
|
|
10
|
+
type: string;
|
|
11
|
+
renderElem: typeof renderListElem;
|
|
12
|
+
};
|
|
13
|
+
export default renderListItemConf;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @description list style class utils
|
|
3
|
+
*/
|
|
4
|
+
import { IDomEditor } from '@wangeditor-next/core';
|
|
5
|
+
export declare function genListColorClassName(color: string): string;
|
|
6
|
+
export declare function resolveListColorAction(editor: IDomEditor | undefined, color: string): 'class' | 'preserve-data' | 'inline';
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @description DOM 操作
|
|
3
|
+
* @author wangfupeng
|
|
4
|
+
*/
|
|
5
|
+
import $, { Dom7Array } from 'dom7';
|
|
6
|
+
import DOMNode = globalThis.Node;
|
|
7
|
+
import DOMComment = globalThis.Comment;
|
|
8
|
+
import DOMElement = globalThis.Element;
|
|
9
|
+
import DOMText = globalThis.Text;
|
|
10
|
+
import DOMRange = globalThis.Range;
|
|
11
|
+
import DOMSelection = globalThis.Selection;
|
|
12
|
+
import DOMStaticRange = globalThis.StaticRange;
|
|
13
|
+
export default $;
|
|
14
|
+
export { DOMComment, DOMElement, DOMNode, DOMRange, DOMSelection, DOMStaticRange, DOMText, };
|
|
15
|
+
/**
|
|
16
|
+
* 获取 tagName lower-case
|
|
17
|
+
* @param $elem $elem
|
|
18
|
+
*/
|
|
19
|
+
export declare function getTagName($elem: Dom7Array): string;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { Editor, Span } from 'slate';
|
|
2
|
+
import { WithTableOptions } from './options';
|
|
3
|
+
/**
|
|
4
|
+
* Determines whether two paths belong to the same types by checking
|
|
5
|
+
* if they share a common ancestor node of type table
|
|
6
|
+
*/
|
|
7
|
+
export declare function hasCommon(editor: Editor, [path, another]: Span, ...types: Array<keyof WithTableOptions['blocks']>): boolean;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { Editor, Element, Node, NodeMatch } from 'slate';
|
|
2
|
+
import { WithTableOptions } from './options';
|
|
3
|
+
import { WithType } from './types';
|
|
4
|
+
export declare function isElement<T extends Element>(node: Node): node is WithType<T>;
|
|
5
|
+
/** @returns a `NodeMatch` function which is used to match the elements of a specific `type`. */
|
|
6
|
+
export declare function isOfType<T extends WithType<Element>>(editor: Editor, ...types: Array<keyof WithTableOptions['blocks']>): NodeMatch<T>;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Editor, Location, NodeEntry } from 'slate';
|
|
2
|
+
import { CellElement, NodeEntryWithContext } from './types';
|
|
3
|
+
/** Generates a matrix for each table section (`thead`, `tbody`, `tfoot`) */
|
|
4
|
+
export declare function matrices(editor: Editor, options?: {
|
|
5
|
+
at?: Location;
|
|
6
|
+
}): Generator<NodeEntry<CellElement>[][]>;
|
|
7
|
+
export declare function filledMatrix(editor: Editor, options?: {
|
|
8
|
+
at?: Location;
|
|
9
|
+
}): NodeEntryWithContext[][];
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { CustomTypes, ExtendedType } from 'slate';
|
|
2
|
+
type ElementType = ExtendedType<'Element', CustomTypes>['type'];
|
|
3
|
+
export interface WithTableOptions {
|
|
4
|
+
blocks: {
|
|
5
|
+
td: ElementType;
|
|
6
|
+
th: ElementType;
|
|
7
|
+
content: ElementType;
|
|
8
|
+
tr: ElementType;
|
|
9
|
+
table: ElementType;
|
|
10
|
+
tbody: ElementType;
|
|
11
|
+
tfoot: ElementType;
|
|
12
|
+
thead: ElementType;
|
|
13
|
+
};
|
|
14
|
+
}
|
|
15
|
+
export declare const DEFAULT_WITH_TABLE_OPTIONS: {
|
|
16
|
+
blocks: {
|
|
17
|
+
td: string;
|
|
18
|
+
th: string;
|
|
19
|
+
content: string;
|
|
20
|
+
tr: string;
|
|
21
|
+
table: string;
|
|
22
|
+
tbody: string;
|
|
23
|
+
};
|
|
24
|
+
};
|
|
25
|
+
export {};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Element, NodeEntry } from 'slate';
|
|
2
|
+
export type CellElement = WithType<{
|
|
3
|
+
rowSpan?: number;
|
|
4
|
+
colSpan?: number;
|
|
5
|
+
hidden?: boolean;
|
|
6
|
+
} & Element>;
|
|
7
|
+
/** Extends an element with the "type" property */
|
|
8
|
+
export type WithType<T extends Element> = T & Record<'type', unknown>;
|
|
9
|
+
export type NodeEntryWithContext = [
|
|
10
|
+
NodeEntry<CellElement>,
|
|
11
|
+
{
|
|
12
|
+
rtl: number;
|
|
13
|
+
ltr: number;
|
|
14
|
+
ttb: number;
|
|
15
|
+
btt: number;
|
|
16
|
+
}
|
|
17
|
+
];
|
|
18
|
+
export type SelectionMode = 'start' | 'end' | 'all';
|
|
19
|
+
export type Edge = 'start' | 'end' | 'top' | 'bottom';
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @description video element
|
|
3
|
+
* @author wangfupeng
|
|
4
|
+
*/
|
|
5
|
+
type EmptyText = {
|
|
6
|
+
text: '';
|
|
7
|
+
};
|
|
8
|
+
export type videoStyle = {
|
|
9
|
+
width?: string;
|
|
10
|
+
height?: string;
|
|
11
|
+
};
|
|
12
|
+
export type VideoElement = {
|
|
13
|
+
type: 'video';
|
|
14
|
+
key?: string;
|
|
15
|
+
src: string;
|
|
16
|
+
poster?: string;
|
|
17
|
+
textAlign?: string;
|
|
18
|
+
width?: string;
|
|
19
|
+
height?: string;
|
|
20
|
+
style?: videoStyle;
|
|
21
|
+
children: EmptyText[];
|
|
22
|
+
};
|
|
23
|
+
export {};
|
package/package.json
CHANGED
|
@@ -1,17 +1,21 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wangeditor-next/list-module",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "2.0.0",
|
|
4
4
|
"description": "wangEditor list module",
|
|
5
|
-
"author": "
|
|
6
|
-
"
|
|
7
|
-
"homepage": "https://github.com/
|
|
5
|
+
"author": "cycleccc <2991205548@qq.com>",
|
|
6
|
+
"type": "module",
|
|
7
|
+
"homepage": "https://github.com/wangeditor-next/wangeditor-next#readme",
|
|
8
8
|
"license": "MIT",
|
|
9
9
|
"types": "dist/list-module/src/index.d.ts",
|
|
10
10
|
"main": "dist/index.js",
|
|
11
|
-
"module": "dist/index.
|
|
12
|
-
"
|
|
13
|
-
"
|
|
14
|
-
|
|
11
|
+
"module": "dist/index.mjs",
|
|
12
|
+
"exports": {
|
|
13
|
+
".": {
|
|
14
|
+
"types": "./dist/list-module/src/index.d.ts",
|
|
15
|
+
"import": "./dist/index.mjs",
|
|
16
|
+
"require": "./dist/index.js"
|
|
17
|
+
},
|
|
18
|
+
"./dist/css/style.css": "./dist/css/style.css"
|
|
15
19
|
},
|
|
16
20
|
"directories": {
|
|
17
21
|
"lib": "dist",
|
|
@@ -25,25 +29,27 @@
|
|
|
25
29
|
},
|
|
26
30
|
"repository": {
|
|
27
31
|
"type": "git",
|
|
28
|
-
"url": "git+https://github.com/
|
|
32
|
+
"url": "git+https://github.com/wangeditor-next/wangEditor-next.git"
|
|
33
|
+
},
|
|
34
|
+
"bugs": {
|
|
35
|
+
"url": "https://github.com/wangeditor-next/wangeditor-next/issues"
|
|
36
|
+
},
|
|
37
|
+
"peerDependencies": {
|
|
38
|
+
"@wangeditor-next/core": "1.8.0",
|
|
39
|
+
"dom7": "^3.0.0 || ^4.0.0",
|
|
40
|
+
"slate": "^0.123.0",
|
|
41
|
+
"snabbdom": "^3.6.0"
|
|
42
|
+
},
|
|
43
|
+
"devDependencies": {
|
|
44
|
+
"@wangeditor-next-shared/rollup-config": "^0.0.2"
|
|
29
45
|
},
|
|
30
46
|
"scripts": {
|
|
31
|
-
"test": "
|
|
32
|
-
"test-c": "
|
|
47
|
+
"test": "vitest run",
|
|
48
|
+
"test-c": "vitest run --coverage",
|
|
33
49
|
"dev": "cross-env NODE_ENV=development rollup -c rollup.config.js",
|
|
34
50
|
"dev-watch": "cross-env NODE_ENV=development rollup -c rollup.config.js -w",
|
|
35
51
|
"build": "cross-env NODE_ENV=production rollup -c rollup.config.js",
|
|
36
52
|
"dev-size-stats": "cross-env NODE_ENV=development:size_stats rollup -c rollup.config.js",
|
|
37
53
|
"size-stats": "cross-env NODE_ENV=production:size_stats rollup -c rollup.config.js"
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
"url": "https://github.com/cycleccc/wangEditor/issues"
|
|
41
|
-
},
|
|
42
|
-
"peerDependencies": {
|
|
43
|
-
"@wangeditor-next/core": "1.x",
|
|
44
|
-
"dom7": "^3.0.0",
|
|
45
|
-
"slate": "^0.72.0",
|
|
46
|
-
"snabbdom": "^3.1.0"
|
|
47
|
-
},
|
|
48
|
-
"gitHead": "b761338b91d1b6133d648b0343fe5c42559c8822"
|
|
49
|
-
}
|
|
54
|
+
}
|
|
55
|
+
}
|
package/CHANGELOG.md
DELETED
|
@@ -1,115 +0,0 @@
|
|
|
1
|
-
# Change Log
|
|
2
|
-
|
|
3
|
-
All notable changes to this project will be documented in this file.
|
|
4
|
-
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
|
-
|
|
6
|
-
# 1.3.0 (2024-05-13)
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
### Bug Fixes
|
|
10
|
-
|
|
11
|
-
* 更新各包之间依赖版本 ([75c552c](https://github.com/cycleccc/wangEditor/commit/75c552cc8ed54765bebb86a7ec5329a7fc79e85f))
|
|
12
|
-
* 两个 list 时回车报错 ([1aebf49](https://github.com/cycleccc/wangEditor/commit/1aebf492d2ab0c79b602b4902a87bcd2ec0f8587))
|
|
13
|
-
* 修复 pnpm 安装 @wangeditor/editor 出现警告的问题 ([4087fbe](https://github.com/cycleccc/wangEditor/commit/4087fbee01c76bdd55e747a5e86c5e4a8d6a8353))
|
|
14
|
-
* 修复列表为editor第一个节点无法删除问题 ([793d252](https://github.com/cycleccc/wangEditor/commit/793d25239921c89e7721a4c57466128099388b7e))
|
|
15
|
-
* 移除了每个包下的 publishConfig directory 配置 ([16559f0](https://github.com/cycleccc/wangEditor/commit/16559f052545c111318be760e64291a521bdcc65))
|
|
16
|
-
* 优化 custom-types.d.ts 中类型声明,修复测试文件 ts 报错 ([3a6c455](https://github.com/cycleccc/wangEditor/commit/3a6c4553245bc734dae1e17d605af389971782a2))
|
|
17
|
-
* list - disabled ([a6c1083](https://github.com/cycleccc/wangEditor/commit/a6c1083a38da888526587180e5de0a4c8129d866))
|
|
18
|
-
* list 无法设置line-height ([6545d06](https://github.com/cycleccc/wangEditor/commit/6545d065f2fa1c664860cbf35f3628df8227f31e))
|
|
19
|
-
* list check ([e4c076f](https://github.com/cycleccc/wangEditor/commit/e4c076fb1ea98bef868f6ab6b862d9b6d6623307))
|
|
20
|
-
* list-item - 遇到 style 是 toHtml 出错 ([9854308](https://github.com/cycleccc/wangEditor/commit/98543083a1cb09207aceb2a4d8f3c1ce020b106d))
|
|
21
|
-
* parse html - 有些 elem children 需要过滤 ([63cbb80](https://github.com/cycleccc/wangEditor/commit/63cbb804c8c7a778a4ee1f4ba8717a11b4b6b5a3))
|
|
22
|
-
* rename es module filename ([1821d4e](https://github.com/cycleccc/wangEditor/commit/1821d4eef49e64efcb41b848849ca7a5e6472044))
|
|
23
|
-
* table - elemToHtml ([e36e609](https://github.com/cycleccc/wangEditor/commit/e36e6092ef721723169afc8bf0560a47ac9f4dfc))
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
### Features
|
|
27
|
-
|
|
28
|
-
* basic text paste ([f0a5b98](https://github.com/cycleccc/wangEditor/commit/f0a5b980c95fa1e2fc59a898c6e0d0723c276c28))
|
|
29
|
-
* i18n ([c11b244](https://github.com/cycleccc/wangEditor/commit/c11b2440f91b99d40bca18b675c66a22b6e160c9))
|
|
30
|
-
* parse html ([2a5eace](https://github.com/cycleccc/wangEditor/commit/2a5eace00f33cded50b68e8164748ec2480213fd))
|
|
31
|
-
* toHtml 机制 ([1c4d872](https://github.com/cycleccc/wangEditor/commit/1c4d8729f84aaab6a448f23064b34a20596305e9))
|
|
32
|
-
* upload video ([ac8e6f8](https://github.com/cycleccc/wangEditor/commit/ac8e6f8b5258e593714676a6f6be359ba525833c))
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
# 1.2.0 (2024-05-13)
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
### Bug Fixes
|
|
42
|
-
|
|
43
|
-
* 更新各包之间依赖版本 ([75c552c](https://github.com/cycleccc/wangEditor/commit/75c552cc8ed54765bebb86a7ec5329a7fc79e85f))
|
|
44
|
-
* 两个 list 时回车报错 ([1aebf49](https://github.com/cycleccc/wangEditor/commit/1aebf492d2ab0c79b602b4902a87bcd2ec0f8587))
|
|
45
|
-
* 修复 pnpm 安装 @wangeditor/editor 出现警告的问题 ([4087fbe](https://github.com/cycleccc/wangEditor/commit/4087fbee01c76bdd55e747a5e86c5e4a8d6a8353))
|
|
46
|
-
* 修复列表为editor第一个节点无法删除问题 ([793d252](https://github.com/cycleccc/wangEditor/commit/793d25239921c89e7721a4c57466128099388b7e))
|
|
47
|
-
* 移除了每个包下的 publishConfig directory 配置 ([16559f0](https://github.com/cycleccc/wangEditor/commit/16559f052545c111318be760e64291a521bdcc65))
|
|
48
|
-
* 优化 custom-types.d.ts 中类型声明,修复测试文件 ts 报错 ([3a6c455](https://github.com/cycleccc/wangEditor/commit/3a6c4553245bc734dae1e17d605af389971782a2))
|
|
49
|
-
* list - disabled ([a6c1083](https://github.com/cycleccc/wangEditor/commit/a6c1083a38da888526587180e5de0a4c8129d866))
|
|
50
|
-
* list 无法设置line-height ([6545d06](https://github.com/cycleccc/wangEditor/commit/6545d065f2fa1c664860cbf35f3628df8227f31e))
|
|
51
|
-
* list check ([e4c076f](https://github.com/cycleccc/wangEditor/commit/e4c076fb1ea98bef868f6ab6b862d9b6d6623307))
|
|
52
|
-
* list-item - 遇到 style 是 toHtml 出错 ([9854308](https://github.com/cycleccc/wangEditor/commit/98543083a1cb09207aceb2a4d8f3c1ce020b106d))
|
|
53
|
-
* parse html - 有些 elem children 需要过滤 ([63cbb80](https://github.com/cycleccc/wangEditor/commit/63cbb804c8c7a778a4ee1f4ba8717a11b4b6b5a3))
|
|
54
|
-
* rename es module filename ([1821d4e](https://github.com/cycleccc/wangEditor/commit/1821d4eef49e64efcb41b848849ca7a5e6472044))
|
|
55
|
-
* table - elemToHtml ([e36e609](https://github.com/cycleccc/wangEditor/commit/e36e6092ef721723169afc8bf0560a47ac9f4dfc))
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
### Features
|
|
59
|
-
|
|
60
|
-
* basic text paste ([f0a5b98](https://github.com/cycleccc/wangEditor/commit/f0a5b980c95fa1e2fc59a898c6e0d0723c276c28))
|
|
61
|
-
* i18n ([c11b244](https://github.com/cycleccc/wangEditor/commit/c11b2440f91b99d40bca18b675c66a22b6e160c9))
|
|
62
|
-
* parse html ([2a5eace](https://github.com/cycleccc/wangEditor/commit/2a5eace00f33cded50b68e8164748ec2480213fd))
|
|
63
|
-
* toHtml 机制 ([1c4d872](https://github.com/cycleccc/wangEditor/commit/1c4d8729f84aaab6a448f23064b34a20596305e9))
|
|
64
|
-
* upload video ([ac8e6f8](https://github.com/cycleccc/wangEditor/commit/ac8e6f8b5258e593714676a6f6be359ba525833c))
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
# 1.1.0 (2024-05-13)
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
### Bug Fixes
|
|
74
|
-
|
|
75
|
-
* 更新各包之间依赖版本 ([75c552c](https://github.com/cycleccc/wangEditor/commit/75c552cc8ed54765bebb86a7ec5329a7fc79e85f))
|
|
76
|
-
* 两个 list 时回车报错 ([1aebf49](https://github.com/cycleccc/wangEditor/commit/1aebf492d2ab0c79b602b4902a87bcd2ec0f8587))
|
|
77
|
-
* 修复 pnpm 安装 @wangeditor/editor 出现警告的问题 ([4087fbe](https://github.com/cycleccc/wangEditor/commit/4087fbee01c76bdd55e747a5e86c5e4a8d6a8353))
|
|
78
|
-
* 修复列表为editor第一个节点无法删除问题 ([793d252](https://github.com/cycleccc/wangEditor/commit/793d25239921c89e7721a4c57466128099388b7e))
|
|
79
|
-
* 移除了每个包下的 publishConfig directory 配置 ([16559f0](https://github.com/cycleccc/wangEditor/commit/16559f052545c111318be760e64291a521bdcc65))
|
|
80
|
-
* 优化 custom-types.d.ts 中类型声明,修复测试文件 ts 报错 ([3a6c455](https://github.com/cycleccc/wangEditor/commit/3a6c4553245bc734dae1e17d605af389971782a2))
|
|
81
|
-
* list - disabled ([a6c1083](https://github.com/cycleccc/wangEditor/commit/a6c1083a38da888526587180e5de0a4c8129d866))
|
|
82
|
-
* list 无法设置line-height ([6545d06](https://github.com/cycleccc/wangEditor/commit/6545d065f2fa1c664860cbf35f3628df8227f31e))
|
|
83
|
-
* list check ([e4c076f](https://github.com/cycleccc/wangEditor/commit/e4c076fb1ea98bef868f6ab6b862d9b6d6623307))
|
|
84
|
-
* list-item - 遇到 style 是 toHtml 出错 ([9854308](https://github.com/cycleccc/wangEditor/commit/98543083a1cb09207aceb2a4d8f3c1ce020b106d))
|
|
85
|
-
* parse html - 有些 elem children 需要过滤 ([63cbb80](https://github.com/cycleccc/wangEditor/commit/63cbb804c8c7a778a4ee1f4ba8717a11b4b6b5a3))
|
|
86
|
-
* rename es module filename ([1821d4e](https://github.com/cycleccc/wangEditor/commit/1821d4eef49e64efcb41b848849ca7a5e6472044))
|
|
87
|
-
* table - elemToHtml ([e36e609](https://github.com/cycleccc/wangEditor/commit/e36e6092ef721723169afc8bf0560a47ac9f4dfc))
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
### Features
|
|
91
|
-
|
|
92
|
-
* basic text paste ([f0a5b98](https://github.com/cycleccc/wangEditor/commit/f0a5b980c95fa1e2fc59a898c6e0d0723c276c28))
|
|
93
|
-
* i18n ([c11b244](https://github.com/cycleccc/wangEditor/commit/c11b2440f91b99d40bca18b675c66a22b6e160c9))
|
|
94
|
-
* parse html ([2a5eace](https://github.com/cycleccc/wangEditor/commit/2a5eace00f33cded50b68e8164748ec2480213fd))
|
|
95
|
-
* toHtml 机制 ([1c4d872](https://github.com/cycleccc/wangEditor/commit/1c4d8729f84aaab6a448f23064b34a20596305e9))
|
|
96
|
-
* upload video ([ac8e6f8](https://github.com/cycleccc/wangEditor/commit/ac8e6f8b5258e593714676a6f6be359ba525833c))
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
## [1.0.5](https://github.com/wangeditor-team/wangEditor/compare/@wangeditor/list-module@1.0.4...@wangeditor/list-module@1.0.5) (2022-09-27)
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
### Bug Fixes
|
|
106
|
-
|
|
107
|
-
* list-item - 遇到 style 是 toHtml 出错 ([9854308](https://github.com/wangeditor-team/wangEditor/commit/98543083a1cb09207aceb2a4d8f3c1ce020b106d))
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
## [1.0.4](https://github.com/wangeditor-team/wangEditor/compare/@wangeditor/list-module@1.0.3...@wangeditor/list-module@1.0.4) (2022-09-27)
|
|
114
|
-
|
|
115
|
-
**Note:** Version bump only for package @wangeditor/list-module
|