@tiptap/extension-list-item 2.0.0-beta.14 → 2.0.0-beta.18

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@tiptap/extension-list-item",
3
3
  "description": "list item extension for tiptap",
4
- "version": "2.0.0-beta.14",
4
+ "version": "2.0.0-beta.18",
5
5
  "homepage": "https://tiptap.dev",
6
6
  "keywords": [
7
7
  "tiptap",
@@ -28,5 +28,5 @@
28
28
  "url": "https://github.com/ueberdosis/tiptap",
29
29
  "directory": "packages/extension-list-item"
30
30
  },
31
- "gitHead": "345ea8cf8abba6422dabc6e548594fb8e2c30409"
31
+ "gitHead": "fce16e805824972834d5a8ce8d60e3ff41d63c7e"
32
32
  }
package/src/list-item.ts CHANGED
@@ -7,8 +7,10 @@ export interface ListItemOptions {
7
7
  export const ListItem = Node.create<ListItemOptions>({
8
8
  name: 'listItem',
9
9
 
10
- defaultOptions: {
11
- HTMLAttributes: {},
10
+ addOptions() {
11
+ return {
12
+ HTMLAttributes: {},
13
+ }
12
14
  },
13
15
 
14
16
  content: 'paragraph block*',
package/CHANGELOG.md DELETED
@@ -1,228 +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
- # [2.0.0-beta.14](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-beta.13...@tiptap/extension-list-item@2.0.0-beta.14) (2021-07-26)
7
-
8
- **Note:** Version bump only for package @tiptap/extension-list-item
9
-
10
-
11
-
12
-
13
-
14
- # [2.0.0-beta.13](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-beta.12...@tiptap/extension-list-item@2.0.0-beta.13) (2021-05-18)
15
-
16
- **Note:** Version bump only for package @tiptap/extension-list-item
17
-
18
-
19
-
20
-
21
-
22
- # [2.0.0-beta.12](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-beta.11...@tiptap/extension-list-item@2.0.0-beta.12) (2021-05-13)
23
-
24
- **Note:** Version bump only for package @tiptap/extension-list-item
25
-
26
-
27
-
28
-
29
-
30
- # [2.0.0-beta.11](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-beta.10...@tiptap/extension-list-item@2.0.0-beta.11) (2021-05-07)
31
-
32
-
33
- ### Bug Fixes
34
-
35
- * revert adding exports ([bc320d0](https://github.com/ueberdosis/tiptap/commit/bc320d0b4b80b0e37a7e47a56e0f6daec6e65d98))
36
-
37
-
38
-
39
-
40
-
41
- # [2.0.0-beta.10](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-beta.9...@tiptap/extension-list-item@2.0.0-beta.10) (2021-05-06)
42
-
43
-
44
- ### Bug Fixes
45
-
46
- * revert adding type: module ([f8d6475](https://github.com/ueberdosis/tiptap/commit/f8d6475e2151faea6f96baecdd6bd75880d50d2c))
47
-
48
-
49
-
50
-
51
-
52
- # [2.0.0-beta.9](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-beta.8...@tiptap/extension-list-item@2.0.0-beta.9) (2021-05-06)
53
-
54
-
55
- ### Bug Fixes
56
-
57
- * add exports to package.json ([1277fa4](https://github.com/ueberdosis/tiptap/commit/1277fa47151e9c039508cdb219bdd0ffe647f4ee))
58
-
59
-
60
-
61
-
62
-
63
- # [2.0.0-beta.8](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-beta.7...@tiptap/extension-list-item@2.0.0-beta.8) (2021-05-06)
64
-
65
- **Note:** Version bump only for package @tiptap/extension-list-item
66
-
67
-
68
-
69
-
70
-
71
- # [2.0.0-beta.7](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-beta.6...@tiptap/extension-list-item@2.0.0-beta.7) (2021-05-05)
72
-
73
- **Note:** Version bump only for package @tiptap/extension-list-item
74
-
75
-
76
-
77
-
78
-
79
- # [2.0.0-beta.6](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-beta.5...@tiptap/extension-list-item@2.0.0-beta.6) (2021-04-23)
80
-
81
- **Note:** Version bump only for package @tiptap/extension-list-item
82
-
83
-
84
-
85
-
86
-
87
- # [2.0.0-beta.5](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-beta.4...@tiptap/extension-list-item@2.0.0-beta.5) (2021-04-22)
88
-
89
- **Note:** Version bump only for package @tiptap/extension-list-item
90
-
91
-
92
-
93
-
94
-
95
- # [2.0.0-beta.4](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-beta.3...@tiptap/extension-list-item@2.0.0-beta.4) (2021-04-21)
96
-
97
- **Note:** Version bump only for package @tiptap/extension-list-item
98
-
99
-
100
-
101
-
102
-
103
- # [2.0.0-beta.3](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-beta.2...@tiptap/extension-list-item@2.0.0-beta.3) (2021-04-16)
104
-
105
- **Note:** Version bump only for package @tiptap/extension-list-item
106
-
107
-
108
-
109
-
110
-
111
- # [2.0.0-beta.2](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-beta.1...@tiptap/extension-list-item@2.0.0-beta.2) (2021-04-15)
112
-
113
- **Note:** Version bump only for package @tiptap/extension-list-item
114
-
115
-
116
-
117
-
118
-
119
- # [2.0.0-beta.1](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-alpha.11...@tiptap/extension-list-item@2.0.0-beta.1) (2021-03-05)
120
-
121
- **Note:** Version bump only for package @tiptap/extension-list-item
122
-
123
-
124
-
125
-
126
-
127
- # [2.0.0-alpha.11](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-alpha.10...@tiptap/extension-list-item@2.0.0-alpha.11) (2021-02-16)
128
-
129
- **Note:** Version bump only for package @tiptap/extension-list-item
130
-
131
-
132
-
133
-
134
-
135
- # [2.0.0-alpha.10](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-alpha.9...@tiptap/extension-list-item@2.0.0-alpha.10) (2021-02-07)
136
-
137
- **Note:** Version bump only for package @tiptap/extension-list-item
138
-
139
-
140
-
141
-
142
-
143
- # [2.0.0-alpha.9](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-alpha.8...@tiptap/extension-list-item@2.0.0-alpha.9) (2021-02-05)
144
-
145
- **Note:** Version bump only for package @tiptap/extension-list-item
146
-
147
-
148
-
149
-
150
-
151
- # [2.0.0-alpha.8](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-alpha.7...@tiptap/extension-list-item@2.0.0-alpha.8) (2021-01-29)
152
-
153
- **Note:** Version bump only for package @tiptap/extension-list-item
154
-
155
-
156
-
157
-
158
-
159
- # [2.0.0-alpha.7](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-alpha.6...@tiptap/extension-list-item@2.0.0-alpha.7) (2021-01-29)
160
-
161
- **Note:** Version bump only for package @tiptap/extension-list-item
162
-
163
-
164
-
165
-
166
-
167
- # [2.0.0-alpha.6](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-alpha.5...@tiptap/extension-list-item@2.0.0-alpha.6) (2021-01-28)
168
-
169
- **Note:** Version bump only for package @tiptap/extension-list-item
170
-
171
-
172
-
173
-
174
-
175
- # [2.0.0-alpha.5](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-alpha.4...@tiptap/extension-list-item@2.0.0-alpha.5) (2020-12-18)
176
-
177
- **Note:** Version bump only for package @tiptap/extension-list-item
178
-
179
-
180
-
181
-
182
-
183
- # [2.0.0-alpha.4](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-alpha.3...@tiptap/extension-list-item@2.0.0-alpha.4) (2020-12-02)
184
-
185
- **Note:** Version bump only for package @tiptap/extension-list-item
186
-
187
-
188
-
189
-
190
-
191
- # [2.0.0-alpha.3](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-alpha.2...@tiptap/extension-list-item@2.0.0-alpha.3) (2020-11-19)
192
-
193
- **Note:** Version bump only for package @tiptap/extension-list-item
194
-
195
-
196
-
197
-
198
-
199
- # [2.0.0-alpha.2](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@2.0.0-alpha.1...@tiptap/extension-list-item@2.0.0-alpha.2) (2020-11-19)
200
-
201
- **Note:** Version bump only for package @tiptap/extension-list-item
202
-
203
-
204
-
205
-
206
-
207
- # [2.0.0-alpha.1](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@1.0.0-alpha.2...@tiptap/extension-list-item@2.0.0-alpha.1) (2020-11-18)
208
-
209
- **Note:** Version bump only for package @tiptap/extension-list-item
210
-
211
-
212
-
213
-
214
-
215
- # [1.0.0-alpha.2](https://github.com/ueberdosis/tiptap/compare/@tiptap/extension-list-item@1.0.0-alpha.1...@tiptap/extension-list-item@1.0.0-alpha.2) (2020-11-16)
216
-
217
- **Note:** Version bump only for package @tiptap/extension-list-item
218
-
219
-
220
-
221
-
222
-
223
- # 1.0.0-alpha.1 (2020-11-16)
224
-
225
-
226
- ### Reverts
227
-
228
- * Revert "use global namespace" ([0c9ce26](https://github.com/ueberdosis/tiptap/commit/0c9ce26c02c07d88a757c01b0a9d7f9e2b0b7502))
@@ -1,3 +0,0 @@
1
- import { ListItem } from './list-item';
2
- export * from './list-item';
3
- export default ListItem;
@@ -1,5 +0,0 @@
1
- import { Node } from '@tiptap/core';
2
- export interface ListItemOptions {
3
- HTMLAttributes: Record<string, any>;
4
- }
5
- export declare const ListItem: Node<ListItemOptions>;
@@ -1,35 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- var core = require('@tiptap/core');
6
-
7
- const ListItem = core.Node.create({
8
- name: 'listItem',
9
- defaultOptions: {
10
- HTMLAttributes: {},
11
- },
12
- content: 'paragraph block*',
13
- defining: true,
14
- parseHTML() {
15
- return [
16
- {
17
- tag: 'li',
18
- },
19
- ];
20
- },
21
- renderHTML({ HTMLAttributes }) {
22
- return ['li', core.mergeAttributes(this.options.HTMLAttributes, HTMLAttributes), 0];
23
- },
24
- addKeyboardShortcuts() {
25
- return {
26
- Enter: () => this.editor.commands.splitListItem('listItem'),
27
- Tab: () => this.editor.commands.sinkListItem('listItem'),
28
- 'Shift-Tab': () => this.editor.commands.liftListItem('listItem'),
29
- };
30
- },
31
- });
32
-
33
- exports.ListItem = ListItem;
34
- exports.default = ListItem;
35
- //# sourceMappingURL=tiptap-extension-list-item.cjs.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"tiptap-extension-list-item.cjs.js","sources":["../src/list-item.ts"],"sourcesContent":["import { Node, mergeAttributes } from '@tiptap/core'\n\nexport interface ListItemOptions {\n HTMLAttributes: Record<string, any>,\n}\n\nexport const ListItem = Node.create<ListItemOptions>({\n name: 'listItem',\n\n defaultOptions: {\n HTMLAttributes: {},\n },\n\n content: 'paragraph block*',\n\n defining: true,\n\n parseHTML() {\n return [\n {\n tag: 'li',\n },\n ]\n },\n\n renderHTML({ HTMLAttributes }) {\n return ['li', mergeAttributes(this.options.HTMLAttributes, HTMLAttributes), 0]\n },\n\n addKeyboardShortcuts() {\n return {\n Enter: () => this.editor.commands.splitListItem('listItem'),\n Tab: () => this.editor.commands.sinkListItem('listItem'),\n 'Shift-Tab': () => this.editor.commands.liftListItem('listItem'),\n }\n },\n})\n"],"names":["Node","mergeAttributes"],"mappings":";;;;;;MAMa,QAAQ,GAAGA,SAAI,CAAC,MAAM,CAAkB;IACnD,IAAI,EAAE,UAAU;IAEhB,cAAc,EAAE;QACd,cAAc,EAAE,EAAE;KACnB;IAED,OAAO,EAAE,kBAAkB;IAE3B,QAAQ,EAAE,IAAI;IAEd,SAAS;QACP,OAAO;YACL;gBACE,GAAG,EAAE,IAAI;aACV;SACF,CAAA;KACF;IAED,UAAU,CAAC,EAAE,cAAc,EAAE;QAC3B,OAAO,CAAC,IAAI,EAAEC,oBAAe,CAAC,IAAI,CAAC,OAAO,CAAC,cAAc,EAAE,cAAc,CAAC,EAAE,CAAC,CAAC,CAAA;KAC/E;IAED,oBAAoB;QAClB,OAAO;YACL,KAAK,EAAE,MAAM,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,aAAa,CAAC,UAAU,CAAC;YAC3D,GAAG,EAAE,MAAM,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,YAAY,CAAC,UAAU,CAAC;YACxD,WAAW,EAAE,MAAM,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,YAAY,CAAC,UAAU,CAAC;SACjE,CAAA;KACF;CACF;;;;;"}
@@ -1,31 +0,0 @@
1
- import { Node, mergeAttributes } from '@tiptap/core';
2
-
3
- const ListItem = Node.create({
4
- name: 'listItem',
5
- defaultOptions: {
6
- HTMLAttributes: {},
7
- },
8
- content: 'paragraph block*',
9
- defining: true,
10
- parseHTML() {
11
- return [
12
- {
13
- tag: 'li',
14
- },
15
- ];
16
- },
17
- renderHTML({ HTMLAttributes }) {
18
- return ['li', mergeAttributes(this.options.HTMLAttributes, HTMLAttributes), 0];
19
- },
20
- addKeyboardShortcuts() {
21
- return {
22
- Enter: () => this.editor.commands.splitListItem('listItem'),
23
- Tab: () => this.editor.commands.sinkListItem('listItem'),
24
- 'Shift-Tab': () => this.editor.commands.liftListItem('listItem'),
25
- };
26
- },
27
- });
28
-
29
- export default ListItem;
30
- export { ListItem };
31
- //# sourceMappingURL=tiptap-extension-list-item.esm.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"tiptap-extension-list-item.esm.js","sources":["../src/list-item.ts"],"sourcesContent":["import { Node, mergeAttributes } from '@tiptap/core'\n\nexport interface ListItemOptions {\n HTMLAttributes: Record<string, any>,\n}\n\nexport const ListItem = Node.create<ListItemOptions>({\n name: 'listItem',\n\n defaultOptions: {\n HTMLAttributes: {},\n },\n\n content: 'paragraph block*',\n\n defining: true,\n\n parseHTML() {\n return [\n {\n tag: 'li',\n },\n ]\n },\n\n renderHTML({ HTMLAttributes }) {\n return ['li', mergeAttributes(this.options.HTMLAttributes, HTMLAttributes), 0]\n },\n\n addKeyboardShortcuts() {\n return {\n Enter: () => this.editor.commands.splitListItem('listItem'),\n Tab: () => this.editor.commands.sinkListItem('listItem'),\n 'Shift-Tab': () => this.editor.commands.liftListItem('listItem'),\n }\n },\n})\n"],"names":[],"mappings":";;MAMa,QAAQ,GAAG,IAAI,CAAC,MAAM,CAAkB;IACnD,IAAI,EAAE,UAAU;IAEhB,cAAc,EAAE;QACd,cAAc,EAAE,EAAE;KACnB;IAED,OAAO,EAAE,kBAAkB;IAE3B,QAAQ,EAAE,IAAI;IAEd,SAAS;QACP,OAAO;YACL;gBACE,GAAG,EAAE,IAAI;aACV;SACF,CAAA;KACF;IAED,UAAU,CAAC,EAAE,cAAc,EAAE;QAC3B,OAAO,CAAC,IAAI,EAAE,eAAe,CAAC,IAAI,CAAC,OAAO,CAAC,cAAc,EAAE,cAAc,CAAC,EAAE,CAAC,CAAC,CAAA;KAC/E;IAED,oBAAoB;QAClB,OAAO;YACL,KAAK,EAAE,MAAM,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,aAAa,CAAC,UAAU,CAAC;YAC3D,GAAG,EAAE,MAAM,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,YAAY,CAAC,UAAU,CAAC;YACxD,WAAW,EAAE,MAAM,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,YAAY,CAAC,UAAU,CAAC;SACjE,CAAA;KACF;CACF;;;;;"}
@@ -1,39 +0,0 @@
1
- (function (global, factory) {
2
- typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@tiptap/core')) :
3
- typeof define === 'function' && define.amd ? define(['exports', '@tiptap/core'], factory) :
4
- (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global['@tiptap/extension-list-item'] = {}, global.core));
5
- }(this, (function (exports, core) { 'use strict';
6
-
7
- const ListItem = core.Node.create({
8
- name: 'listItem',
9
- defaultOptions: {
10
- HTMLAttributes: {},
11
- },
12
- content: 'paragraph block*',
13
- defining: true,
14
- parseHTML() {
15
- return [
16
- {
17
- tag: 'li',
18
- },
19
- ];
20
- },
21
- renderHTML({ HTMLAttributes }) {
22
- return ['li', core.mergeAttributes(this.options.HTMLAttributes, HTMLAttributes), 0];
23
- },
24
- addKeyboardShortcuts() {
25
- return {
26
- Enter: () => this.editor.commands.splitListItem('listItem'),
27
- Tab: () => this.editor.commands.sinkListItem('listItem'),
28
- 'Shift-Tab': () => this.editor.commands.liftListItem('listItem'),
29
- };
30
- },
31
- });
32
-
33
- exports.ListItem = ListItem;
34
- exports.default = ListItem;
35
-
36
- Object.defineProperty(exports, '__esModule', { value: true });
37
-
38
- })));
39
- //# sourceMappingURL=tiptap-extension-list-item.umd.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"tiptap-extension-list-item.umd.js","sources":["../src/list-item.ts"],"sourcesContent":["import { Node, mergeAttributes } from '@tiptap/core'\n\nexport interface ListItemOptions {\n HTMLAttributes: Record<string, any>,\n}\n\nexport const ListItem = Node.create<ListItemOptions>({\n name: 'listItem',\n\n defaultOptions: {\n HTMLAttributes: {},\n },\n\n content: 'paragraph block*',\n\n defining: true,\n\n parseHTML() {\n return [\n {\n tag: 'li',\n },\n ]\n },\n\n renderHTML({ HTMLAttributes }) {\n return ['li', mergeAttributes(this.options.HTMLAttributes, HTMLAttributes), 0]\n },\n\n addKeyboardShortcuts() {\n return {\n Enter: () => this.editor.commands.splitListItem('listItem'),\n Tab: () => this.editor.commands.sinkListItem('listItem'),\n 'Shift-Tab': () => this.editor.commands.liftListItem('listItem'),\n }\n },\n})\n"],"names":["Node","mergeAttributes"],"mappings":";;;;;;QAMa,QAAQ,GAAGA,SAAI,CAAC,MAAM,CAAkB;MACnD,IAAI,EAAE,UAAU;MAEhB,cAAc,EAAE;UACd,cAAc,EAAE,EAAE;OACnB;MAED,OAAO,EAAE,kBAAkB;MAE3B,QAAQ,EAAE,IAAI;MAEd,SAAS;UACP,OAAO;cACL;kBACE,GAAG,EAAE,IAAI;eACV;WACF,CAAA;OACF;MAED,UAAU,CAAC,EAAE,cAAc,EAAE;UAC3B,OAAO,CAAC,IAAI,EAAEC,oBAAe,CAAC,IAAI,CAAC,OAAO,CAAC,cAAc,EAAE,cAAc,CAAC,EAAE,CAAC,CAAC,CAAA;OAC/E;MAED,oBAAoB;UAClB,OAAO;cACL,KAAK,EAAE,MAAM,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,aAAa,CAAC,UAAU,CAAC;cAC3D,GAAG,EAAE,MAAM,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,YAAY,CAAC,UAAU,CAAC;cACxD,WAAW,EAAE,MAAM,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,YAAY,CAAC,UAAU,CAAC;WACjE,CAAA;OACF;GACF;;;;;;;;;;;"}