@officesdk/editor-sdk-core 0.0.0-12 → 0.0.0-14
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/cjs/docx/context-menu.js +1 -1
- package/cjs/docx/index.js +1 -1
- package/cjs/docx/menu.js +1 -1
- package/cjs/pdf/menu.js +1 -1
- package/cjs/presentation/menu.js +1 -1
- package/cjs/shared/context-menu.js +1 -1
- package/cjs/shared/index.js +1 -1
- package/cjs/shared/menu.js +1 -1
- package/cjs/shared/toolbar.js +1 -1
- package/cjs/sheet/index.js +1 -1
- package/cjs/sheet/menu.js +1 -1
- package/cjs/sheet/sdk.js +1 -1
- package/cjs/sheet/toolbar.js +3 -0
- package/esm/docx/context-menu.js +1 -1
- package/esm/docx/index.js +1 -1
- package/esm/docx/menu.js +1 -1
- package/esm/pdf/menu.js +1 -1
- package/esm/presentation/menu.js +1 -1
- package/esm/shared/context-menu.js +1 -1
- package/esm/shared/index.js +1 -1
- package/esm/shared/menu.js +1 -1
- package/esm/shared/toolbar.js +1 -1
- package/esm/sheet/index.js +1 -1
- package/esm/sheet/menu.js +1 -1
- package/esm/sheet/sdk.js +1 -1
- package/esm/sheet/toolbar.js +2 -0
- package/package.json +1 -1
- package/types/diagram.d.ts +110 -166
- package/types/docs.d.ts +110 -166
- package/types/docx.d.ts +146 -182
- package/types/pdf.d.ts +111 -167
- package/types/presentation.d.ts +112 -168
- package/types/shared.d.ts +110 -166
- package/types/sheet.d.ts +139 -171
- package/types/table.d.ts +110 -166
package/types/docx.d.ts
CHANGED
|
@@ -66,19 +66,41 @@ export declare abstract class AbstractedEditorFileUploader {
|
|
|
66
66
|
}
|
|
67
67
|
|
|
68
68
|
/**
|
|
69
|
-
*
|
|
69
|
+
* 传统文档右键菜单功能按钮
|
|
70
70
|
*/
|
|
71
|
-
export declare type
|
|
72
|
-
|
|
71
|
+
export declare type DocxContextMenuFeatureButtonName =
|
|
73
72
|
/**
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
73
|
+
* 剪切
|
|
74
|
+
*/
|
|
75
|
+
'cut'
|
|
78
76
|
/**
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
77
|
+
* 复制
|
|
78
|
+
*/
|
|
79
|
+
| 'copy'
|
|
80
|
+
/**
|
|
81
|
+
* 粘贴
|
|
82
|
+
*/
|
|
83
|
+
| 'paste'
|
|
84
|
+
/**
|
|
85
|
+
* 删除
|
|
86
|
+
*/
|
|
87
|
+
| 'delete'
|
|
88
|
+
/**
|
|
89
|
+
* 字体
|
|
90
|
+
*/
|
|
91
|
+
| 'font'
|
|
92
|
+
/**
|
|
93
|
+
* 段落
|
|
94
|
+
*/
|
|
95
|
+
| 'paragraph'
|
|
96
|
+
/**
|
|
97
|
+
* 下载附件
|
|
98
|
+
*/
|
|
99
|
+
| 'downloadAttachment'
|
|
100
|
+
/**
|
|
101
|
+
* 转换PDF
|
|
102
|
+
*/
|
|
103
|
+
| 'transformPDF';
|
|
82
104
|
|
|
83
105
|
export declare type DocxContextMenuOptions = EditorContextMenuOptions<DocxContextMenuFeatureButtonName>;
|
|
84
106
|
|
|
@@ -187,20 +209,18 @@ export declare interface DocxInfoOptions {
|
|
|
187
209
|
}
|
|
188
210
|
|
|
189
211
|
/**
|
|
190
|
-
*
|
|
212
|
+
* 传统文档菜单栏一级菜单
|
|
191
213
|
*/
|
|
192
214
|
export declare type DocxMenuEntryConfig = EditorMenuEntryConfig<DocxMenuFeatureButtonName>;
|
|
193
215
|
|
|
194
216
|
/**
|
|
195
|
-
*
|
|
217
|
+
* 传统文档菜单栏内置功能按钮
|
|
196
218
|
*/
|
|
197
|
-
export declare type
|
|
219
|
+
export declare type DocxMenuFeatureButtonName = 'file' | 'edit' | 'insert' | 'undo' | 'redo' | 'cut' | 'copy' | 'paste' | 'selectAll' | 'export' | 'saveTemplate' | 'viewHistory' | 'saveHistory' | 'exportImage' | 'exportPDF' | 'exportWPS' | 'exportImagePDF' | 'insertAttachment' | 'insertCloudFile' | 'insertSignature' | 'insertImageFromUrl';
|
|
198
220
|
|
|
199
221
|
/**
|
|
200
|
-
*
|
|
222
|
+
* 传统文档菜单栏相关配置,目前菜单栏不是所有套件都支持,
|
|
201
223
|
*/
|
|
202
|
-
export declare type DocxMenuFeatureButtonName = 'file' | 'edit' | 'insert' | 'undo' | 'redo' | 'cut' | 'copy' | 'paste' | 'selectAll' | 'export' | 'saveTemplate' | 'viewHistory' | 'saveHistory' | 'exportImage' | 'exportPDF' | 'exportWPS' | 'exportImagePDF' | 'insertAttachment' | 'insertCloudFile' | 'insertSignature' | 'insertImageFromUrl';
|
|
203
|
-
|
|
204
224
|
export declare type DocxMenuOptions = EditorMenuOptions<DocxMenuFeatureButtonName>;
|
|
205
225
|
|
|
206
226
|
/**
|
|
@@ -1319,27 +1339,6 @@ export declare interface EditorContent<Delta = EditorDelta> {
|
|
|
1319
1339
|
addChangeListener: (listener: (change: Delta) => void) => () => void;
|
|
1320
1340
|
}
|
|
1321
1341
|
|
|
1322
|
-
/**
|
|
1323
|
-
* 右键菜单栏二级以下的菜单入口
|
|
1324
|
-
*/
|
|
1325
|
-
export declare type EditorContextMenuEntryButton<TName extends string> = EditorMenuEntryButton<TName>;
|
|
1326
|
-
|
|
1327
|
-
/**
|
|
1328
|
-
* 右键菜单栏一级菜单配置,此处用于定义一级菜单的操作入口,
|
|
1329
|
-
* 右键菜单栏一级菜单指点击右键弹出菜单时的菜单项
|
|
1330
|
-
*/
|
|
1331
|
-
export declare type EditorContextMenuEntryConfig<TName extends string> = EditorMenuEntryConfig<TName>;
|
|
1332
|
-
|
|
1333
|
-
/**
|
|
1334
|
-
* 右键菜单栏功能按钮配置
|
|
1335
|
-
*/
|
|
1336
|
-
export declare type EditorContextMenuFeatureButton<TName extends string> = EditorMenuFeatureButton<TName>;
|
|
1337
|
-
|
|
1338
|
-
/**
|
|
1339
|
-
* 右键菜单栏按钮配置
|
|
1340
|
-
*/
|
|
1341
|
-
export declare type EditorContextMenuFeatureButtonConfig<TName extends string> = EditorMenuFeatureButtonConfig<TName>;
|
|
1342
|
-
|
|
1343
1342
|
/**
|
|
1344
1343
|
* 右键菜单栏相关配置
|
|
1345
1344
|
* 右键菜单栏是指的编辑器中点击右键弹出的菜单栏。目前等于菜单栏配置,可扩展
|
|
@@ -1533,120 +1532,137 @@ export declare interface EditorLocalUploadableFile extends EditorBaseUploadableF
|
|
|
1533
1532
|
}
|
|
1534
1533
|
|
|
1535
1534
|
/**
|
|
1536
|
-
*
|
|
1535
|
+
* 基础菜单项配置,所有菜单项类型都包含这些属性
|
|
1537
1536
|
*/
|
|
1538
|
-
export declare
|
|
1539
|
-
/**
|
|
1540
|
-
* 按钮名称
|
|
1541
|
-
*/
|
|
1542
|
-
name: string;
|
|
1543
|
-
/**
|
|
1544
|
-
* 链接
|
|
1545
|
-
*/
|
|
1546
|
-
type: 'link';
|
|
1537
|
+
export declare interface EditorMenuBaseMenuItemConfig<TName extends string> {
|
|
1547
1538
|
/**
|
|
1548
|
-
*
|
|
1539
|
+
* 菜单项的唯一标识,用以确定配置的是哪个菜单
|
|
1549
1540
|
*/
|
|
1550
|
-
|
|
1551
|
-
/**
|
|
1552
|
-
* 链接地址
|
|
1553
|
-
*/
|
|
1554
|
-
url: string;
|
|
1555
|
-
} | {
|
|
1541
|
+
name: TName;
|
|
1556
1542
|
/**
|
|
1557
|
-
*
|
|
1543
|
+
* 菜单项类型
|
|
1558
1544
|
*/
|
|
1559
|
-
|
|
1545
|
+
type: EditorMenuItemType;
|
|
1546
|
+
}
|
|
1547
|
+
|
|
1548
|
+
/**
|
|
1549
|
+
* 按钮菜单项配置
|
|
1550
|
+
*/
|
|
1551
|
+
export declare interface EditorMenuButtonMenuItemConfig<TName extends string> extends EditorMenuBaseMenuItemConfig<TName> {
|
|
1552
|
+
type: 'button';
|
|
1560
1553
|
/**
|
|
1561
|
-
*
|
|
1554
|
+
* 是否禁用菜单项,禁用后菜单项依旧显示不过变为灰色,不可点击
|
|
1562
1555
|
*/
|
|
1563
|
-
|
|
1556
|
+
disabled?: boolean;
|
|
1564
1557
|
/**
|
|
1565
|
-
*
|
|
1558
|
+
* 菜单项显示文本,修改该值可以替换此菜单项默认显示文案
|
|
1566
1559
|
*/
|
|
1567
|
-
label
|
|
1560
|
+
label?: string;
|
|
1568
1561
|
/**
|
|
1569
|
-
*
|
|
1562
|
+
* 菜单项图标,可以是 base64 的图片信息,也可以是图片 url
|
|
1563
|
+
* 配置为空字符串则可以隐藏菜单项默认的图标
|
|
1570
1564
|
*/
|
|
1571
1565
|
icon?: string;
|
|
1572
1566
|
/**
|
|
1573
|
-
*
|
|
1567
|
+
* 菜单项点击事件,接受一个函数,可以自定义点击事件
|
|
1574
1568
|
*/
|
|
1575
|
-
callback
|
|
1576
|
-
}
|
|
1569
|
+
callback?: () => void;
|
|
1570
|
+
}
|
|
1577
1571
|
|
|
1578
1572
|
/**
|
|
1579
|
-
*
|
|
1573
|
+
* 编辑器菜单配置类型
|
|
1574
|
+
* 联合类型,表示可以是任意一种菜单项配置
|
|
1580
1575
|
*/
|
|
1581
|
-
export declare
|
|
1576
|
+
export declare type EditorMenuEntryConfig<TName extends string> = EditorMenuHiddenMenuItemConfig<TName> | EditorMenuButtonMenuItemConfig<TName> | EditorMenuLinkMenuItemConfig<TName> | EditorMenuEntryMenuItemConfig<TName>;
|
|
1577
|
+
|
|
1578
|
+
/**
|
|
1579
|
+
* 子菜单入口配置
|
|
1580
|
+
*/
|
|
1581
|
+
export declare interface EditorMenuEntryMenuItemConfig<TName extends string> extends EditorMenuBaseMenuItemConfig<TName> {
|
|
1582
1582
|
type: 'entry';
|
|
1583
1583
|
/**
|
|
1584
|
-
*
|
|
1584
|
+
* 是否禁用菜单项,禁用后菜单项依旧显示不过变为灰色,不可点击
|
|
1585
1585
|
*/
|
|
1586
|
-
|
|
1586
|
+
disabled?: boolean;
|
|
1587
1587
|
/**
|
|
1588
|
-
*
|
|
1588
|
+
* 菜单项显示文本,修改该值可以替换此菜单项默认显示文案
|
|
1589
|
+
*/
|
|
1590
|
+
label?: string;
|
|
1591
|
+
/**
|
|
1592
|
+
* 菜单项图标,可以是 base64 的图片信息,也可以是图片 url
|
|
1593
|
+
* 配置为空字符串则可以隐藏菜单项默认的图标
|
|
1589
1594
|
*/
|
|
1590
1595
|
icon?: string;
|
|
1591
1596
|
/**
|
|
1592
|
-
*
|
|
1597
|
+
* 下一级菜单配置,下一级菜单配置项和上一级相同
|
|
1598
|
+
* 如果下一级仍然是 entry 类型,可以无限向下扩展
|
|
1593
1599
|
*/
|
|
1594
|
-
children?:
|
|
1600
|
+
children?: EditorMenuEntryConfig<TName>[];
|
|
1595
1601
|
}
|
|
1596
1602
|
|
|
1597
1603
|
/**
|
|
1598
|
-
*
|
|
1599
|
-
* 一级菜单在鼠标悬停时展示二级列表
|
|
1604
|
+
* 菜单功能按钮配置
|
|
1600
1605
|
*/
|
|
1601
|
-
export declare interface
|
|
1606
|
+
export declare interface EditorMenuFeatureConfig {
|
|
1602
1607
|
/**
|
|
1603
|
-
*
|
|
1608
|
+
* 是否隐藏菜单项,设置为true则隐藏菜单项
|
|
1604
1609
|
*/
|
|
1605
|
-
|
|
1606
|
-
/**
|
|
1607
|
-
* 二级菜单定义,定一个二维数组,用于定义二级菜单的结构,
|
|
1608
|
-
* 将第一层数组中的所有按钮放到一个区域内用分隔符隔开,
|
|
1609
|
-
* 第二层数组为按钮的定义,可以是功能按钮也可以是一个下拉入口。
|
|
1610
|
-
*/
|
|
1611
|
-
children: Array<EditorMenuFeatureButton<TName> | EditorMenuEntryButton<TName>>[];
|
|
1610
|
+
hidden?: boolean;
|
|
1612
1611
|
/**
|
|
1613
|
-
*
|
|
1612
|
+
* 是否禁用菜单项,设置为true则变为灰色不可点击
|
|
1614
1613
|
*/
|
|
1615
|
-
|
|
1614
|
+
disabled?: boolean;
|
|
1616
1615
|
}
|
|
1617
1616
|
|
|
1618
1617
|
/**
|
|
1619
|
-
*
|
|
1618
|
+
* 菜单功能按钮配置
|
|
1620
1619
|
*/
|
|
1621
|
-
export declare
|
|
1620
|
+
export declare interface EditorMenuFeatureConfig {
|
|
1622
1621
|
/**
|
|
1623
|
-
*
|
|
1622
|
+
* 是否隐藏菜单项,设置为true则隐藏菜单项
|
|
1624
1623
|
*/
|
|
1625
|
-
|
|
1624
|
+
hidden?: boolean;
|
|
1626
1625
|
/**
|
|
1627
|
-
*
|
|
1626
|
+
* 是否禁用菜单项,设置为true则变为灰色不可点击
|
|
1628
1627
|
*/
|
|
1629
|
-
|
|
1630
|
-
}
|
|
1631
|
-
|
|
1628
|
+
disabled?: boolean;
|
|
1629
|
+
}
|
|
1630
|
+
|
|
1631
|
+
/**
|
|
1632
|
+
* 隐藏菜单项配置
|
|
1633
|
+
*/
|
|
1634
|
+
export declare interface EditorMenuHiddenMenuItemConfig<TName extends string> extends EditorMenuBaseMenuItemConfig<TName> {
|
|
1635
|
+
type: 'hidden';
|
|
1636
|
+
}
|
|
1637
|
+
|
|
1638
|
+
/**
|
|
1639
|
+
* 菜单项类型
|
|
1640
|
+
*/
|
|
1641
|
+
export declare type EditorMenuItemType = 'hidden' | 'button' | 'link' | 'entry';
|
|
1642
|
+
|
|
1643
|
+
/**
|
|
1644
|
+
* 链接菜单项配置
|
|
1645
|
+
*/
|
|
1646
|
+
export declare interface EditorMenuLinkMenuItemConfig<TName extends string> extends EditorMenuBaseMenuItemConfig<TName> {
|
|
1647
|
+
type: 'link';
|
|
1632
1648
|
/**
|
|
1633
|
-
*
|
|
1649
|
+
* 是否禁用菜单项,禁用后菜单项依旧显示不过变为灰色,不可点击
|
|
1634
1650
|
*/
|
|
1635
|
-
|
|
1651
|
+
disabled?: boolean;
|
|
1636
1652
|
/**
|
|
1637
|
-
*
|
|
1653
|
+
* 菜单项显示文本,修改该值可以替换此菜单项默认显示文案
|
|
1638
1654
|
*/
|
|
1639
|
-
|
|
1655
|
+
text?: string;
|
|
1640
1656
|
/**
|
|
1641
|
-
*
|
|
1657
|
+
* 菜单项图标,可以是 base64 的图片信息,也可以是图片 url
|
|
1658
|
+
* 配置为空字符串则可以隐藏菜单项默认的图标
|
|
1642
1659
|
*/
|
|
1643
1660
|
icon?: string;
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
|
|
1649
|
-
export declare type EditorMenuFeatureButtonConfig<TName extends string> = Record<TName, EditorMenuFeatureButton<TName>>;
|
|
1661
|
+
/**
|
|
1662
|
+
* 跳转链接地址
|
|
1663
|
+
*/
|
|
1664
|
+
url?: string;
|
|
1665
|
+
}
|
|
1650
1666
|
|
|
1651
1667
|
/**
|
|
1652
1668
|
* 菜单栏相关配置,目前菜单栏不是所有套件都支持,
|
|
@@ -1654,25 +1670,26 @@ export declare type EditorMenuFeatureButtonConfig<TName extends string> = Record
|
|
|
1654
1670
|
*/
|
|
1655
1671
|
export declare interface EditorMenuOptions<TName extends string> {
|
|
1656
1672
|
/**
|
|
1657
|
-
*
|
|
1673
|
+
* 菜单栏是否隐藏,设置为true, 则整个菜单栏不显示
|
|
1658
1674
|
*/
|
|
1659
1675
|
hidden?: boolean;
|
|
1660
1676
|
/**
|
|
1661
|
-
*
|
|
1677
|
+
* 是否禁用菜单栏所有功能。设置为true,菜单栏依旧显示,但所有菜单项为灰色不可点击
|
|
1662
1678
|
*/
|
|
1663
1679
|
disabled?: boolean;
|
|
1664
1680
|
/**
|
|
1665
|
-
*
|
|
1681
|
+
* 菜单栏一级菜单配置,指显示在菜单栏上的菜单项。
|
|
1666
1682
|
*/
|
|
1667
1683
|
entries?: EditorMenuEntryConfig<TName>[];
|
|
1668
1684
|
/**
|
|
1669
1685
|
* 菜单栏功能按钮配置
|
|
1686
|
+
* TODO 此配置目前没有用到,后续看是保留还是和custom合并
|
|
1670
1687
|
*/
|
|
1671
|
-
features?:
|
|
1688
|
+
features?: Record<TName, EditorMenuFeatureConfig>;
|
|
1672
1689
|
/**
|
|
1673
1690
|
* 自定义按钮配置
|
|
1674
1691
|
*/
|
|
1675
|
-
custom?:
|
|
1692
|
+
custom?: (EditorMenuButtonMenuItemConfig<string> | EditorMenuLinkMenuItemConfig<string>)[];
|
|
1676
1693
|
}
|
|
1677
1694
|
|
|
1678
1695
|
/**
|
|
@@ -2035,43 +2052,15 @@ export declare interface EditorTextOptions<Color = string> {
|
|
|
2035
2052
|
}
|
|
2036
2053
|
|
|
2037
2054
|
/**
|
|
2038
|
-
*
|
|
2039
|
-
*/
|
|
2040
|
-
export declare interface EditorToolbarCustomButton extends Omit<EditorToolbarFeatureButton, 'name'> {
|
|
2041
|
-
/**
|
|
2042
|
-
* 自定义按钮名称
|
|
2043
|
-
*/
|
|
2044
|
-
name: string;
|
|
2045
|
-
/**
|
|
2046
|
-
* 按钮点击事件
|
|
2047
|
-
*/
|
|
2048
|
-
callback: () => void;
|
|
2049
|
-
/**
|
|
2050
|
-
* 按钮在工具栏中的位置,默认添加到工具栏所有按钮后面
|
|
2051
|
-
*/
|
|
2052
|
-
index?: number;
|
|
2053
|
-
}
|
|
2054
|
-
|
|
2055
|
-
/**
|
|
2056
|
-
* 工具栏自定义按钮配置
|
|
2057
|
-
*/
|
|
2058
|
-
export declare interface EditorToolbarCustomButtonConfig {
|
|
2059
|
-
/**
|
|
2060
|
-
* 按钮配置
|
|
2061
|
-
*/
|
|
2062
|
-
[key: string]: EditorToolbarCustomButton;
|
|
2063
|
-
}
|
|
2064
|
-
|
|
2065
|
-
/**
|
|
2066
|
-
* 工具栏内置功能按钮配置
|
|
2055
|
+
* 工具栏功能按钮配置(包括内置按钮和自定义按钮)
|
|
2067
2056
|
*/
|
|
2068
|
-
export declare interface EditorToolbarFeatureButton<
|
|
2057
|
+
export declare interface EditorToolbarFeatureButton<TName extends string> {
|
|
2069
2058
|
/**
|
|
2070
|
-
*
|
|
2059
|
+
* 按钮的唯一标识,用以确定配置的是哪个按钮。
|
|
2071
2060
|
*/
|
|
2072
|
-
name:
|
|
2061
|
+
name: TName;
|
|
2073
2062
|
/**
|
|
2074
|
-
*
|
|
2063
|
+
* 按钮标签(显示文本)一般工具栏上的按钮不会显示文本,如果需要显示文本,配置此项。
|
|
2075
2064
|
*/
|
|
2076
2065
|
label?: string;
|
|
2077
2066
|
/**
|
|
@@ -2079,63 +2068,38 @@ export declare interface EditorToolbarFeatureButton<ToolButtonName extends strin
|
|
|
2079
2068
|
*/
|
|
2080
2069
|
icon?: string;
|
|
2081
2070
|
/**
|
|
2082
|
-
*
|
|
2071
|
+
* 按钮是否隐藏,设置为true则隐藏按钮
|
|
2083
2072
|
*/
|
|
2084
2073
|
hidden?: boolean;
|
|
2085
2074
|
/**
|
|
2086
|
-
*
|
|
2075
|
+
* 按钮是否禁用,设置为true则变为灰色不可点击
|
|
2087
2076
|
*/
|
|
2088
2077
|
disabled?: boolean;
|
|
2089
2078
|
/**
|
|
2090
|
-
*
|
|
2079
|
+
* 按钮点击事件.接受一个函数,可以自定义点击事件。
|
|
2080
|
+
*/
|
|
2081
|
+
callback?: () => void;
|
|
2082
|
+
/**
|
|
2083
|
+
* 按钮提示文本,鼠标悬浮到按钮上时显示的tooltip文字
|
|
2091
2084
|
*/
|
|
2092
2085
|
tooltip?: string;
|
|
2086
|
+
/**
|
|
2087
|
+
* 按钮在工具栏中位置,不设置则按照默认位置
|
|
2088
|
+
*/
|
|
2089
|
+
index?: number;
|
|
2093
2090
|
}
|
|
2094
2091
|
|
|
2095
2092
|
/**
|
|
2096
2093
|
* 工具栏内置功能按钮配置
|
|
2097
2094
|
*/
|
|
2098
|
-
export declare type EditorToolbarFeatureButtonConfig<
|
|
2099
|
-
[key in
|
|
2095
|
+
export declare type EditorToolbarFeatureButtonConfig<TName extends string> = {
|
|
2096
|
+
[key in TName]?: EditorToolbarFeatureButton<key>;
|
|
2100
2097
|
};
|
|
2101
2098
|
|
|
2102
|
-
/**
|
|
2103
|
-
* 工具栏内置功能按钮
|
|
2104
|
-
*/
|
|
2105
|
-
export declare type EditorToolbarFeatureButtonName =
|
|
2106
|
-
/**
|
|
2107
|
-
* 加粗
|
|
2108
|
-
*/
|
|
2109
|
-
'bold'
|
|
2110
|
-
/**
|
|
2111
|
-
* 斜体
|
|
2112
|
-
*/
|
|
2113
|
-
| 'italic'
|
|
2114
|
-
/**
|
|
2115
|
-
* 下划线
|
|
2116
|
-
*/
|
|
2117
|
-
| 'underline'
|
|
2118
|
-
/**
|
|
2119
|
-
* 删除线
|
|
2120
|
-
*/
|
|
2121
|
-
| 'strikethrough'
|
|
2122
|
-
/**
|
|
2123
|
-
* 插入图片
|
|
2124
|
-
*/
|
|
2125
|
-
| 'insertImage'
|
|
2126
|
-
/**
|
|
2127
|
-
* 插入链接
|
|
2128
|
-
*/
|
|
2129
|
-
| 'insertLink'
|
|
2130
|
-
/**
|
|
2131
|
-
* 限制编辑
|
|
2132
|
-
*/
|
|
2133
|
-
| 'restriction';
|
|
2134
|
-
|
|
2135
2099
|
/**
|
|
2136
2100
|
* 工具栏相关设置,可以控制工具栏的显示内容
|
|
2137
2101
|
*/
|
|
2138
|
-
export declare interface EditorToolbarOptions<
|
|
2102
|
+
export declare interface EditorToolbarOptions<TName extends string> {
|
|
2139
2103
|
/**
|
|
2140
2104
|
* 控制工具栏显隐状态
|
|
2141
2105
|
*/
|
|
@@ -2147,11 +2111,11 @@ export declare interface EditorToolbarOptions<ToolButtonName extends string = Ed
|
|
|
2147
2111
|
/**
|
|
2148
2112
|
* 现有按钮的功能配置
|
|
2149
2113
|
*/
|
|
2150
|
-
features?: EditorToolbarFeatureButtonConfig<
|
|
2114
|
+
features?: EditorToolbarFeatureButtonConfig<TName>;
|
|
2151
2115
|
/**
|
|
2152
2116
|
* 自定义按钮
|
|
2153
2117
|
*/
|
|
2154
|
-
custom?:
|
|
2118
|
+
custom?: EditorToolbarFeatureButtonConfig<string>;
|
|
2155
2119
|
}
|
|
2156
2120
|
|
|
2157
2121
|
export declare type EditorUploadableFile = EditorLocalUploadableFile;
|