@tiptap/extension-task-list
Advanced tools
Comparing version 2.0.0-alpha.4 to 2.0.0-alpha.5
@@ -6,2 +6,10 @@ # Change Log | ||
# [2.0.0-alpha.5](https://github.com/ueberdosis/tiptap-next/compare/@tiptap/extension-task-list@2.0.0-alpha.4...@tiptap/extension-task-list@2.0.0-alpha.5) (2020-12-18) | ||
**Note:** Version bump only for package @tiptap/extension-task-list | ||
# [2.0.0-alpha.4](https://github.com/ueberdosis/tiptap-next/compare/@tiptap/extension-task-list@2.0.0-alpha.3...@tiptap/extension-task-list@2.0.0-alpha.4) (2020-12-02) | ||
@@ -8,0 +16,0 @@ |
@@ -1,18 +0,3 @@ | ||
import { Command, Node } from '@tiptap/core'; | ||
export interface TaskListOptions { | ||
HTMLAttributes: { | ||
[key: string]: any; | ||
}; | ||
} | ||
declare const TaskList: Node<TaskListOptions, { | ||
/** | ||
* Toggle a task list | ||
*/ | ||
toggleTaskList: () => Command; | ||
}>; | ||
import { TaskList } from './task-list'; | ||
export * from './task-list'; | ||
export default TaskList; | ||
declare module '@tiptap/core' { | ||
interface AllExtensions { | ||
TaskList: typeof TaskList; | ||
} | ||
} |
@@ -1,2 +0,2 @@ | ||
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("@tiptap/core")):"function"==typeof define&&define.amd?define(["@tiptap/core"],e):(t="undefined"!=typeof globalThis?globalThis:t||self)["@tiptap/extension-task-list"]=e(t["@tiptap/core"])}(this,(function(t){"use strict";return t.Node.create({name:"taskList",defaultOptions:{HTMLAttributes:{}},group:"block list",content:"taskItem+",parseHTML:()=>[{tag:'ul[data-type="taskList"]',priority:51}],renderHTML:({HTMLAttributes:e})=>["ul",t.mergeAttributes(e,{"data-type":"taskList"}),0],addCommands:()=>({toggleTaskList:()=>({commands:t})=>t.toggleList("taskList","taskItem")}),addKeyboardShortcuts(){return{"Mod-Shift-l":()=>this.editor.commands.toggleTaskList()}}})})); | ||
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("@tiptap/core")):"function"==typeof define&&define.amd?define(["exports","@tiptap/core"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self)["@tiptap/extension-task-list"]={},t["@tiptap/core"])}(this,(function(t,e){"use strict";const s=e.Node.create({name:"taskList",defaultOptions:{HTMLAttributes:{}},group:"block list",content:"taskItem+",parseHTML:()=>[{tag:'ul[data-type="taskList"]',priority:51}],renderHTML:({HTMLAttributes:t})=>["ul",e.mergeAttributes(t,{"data-type":"taskList"}),0],addCommands:()=>({toggleTaskList:()=>({commands:t})=>t.toggleList("taskList","taskItem")}),addKeyboardShortcuts(){return{"Mod-Shift-l":()=>this.editor.commands.toggleTaskList()}}});t.TaskList=s,t.default=s,Object.defineProperty(t,"__esModule",{value:!0})})); | ||
//# sourceMappingURL=tiptap-extension-task-list.bundle.umd.min.js.map |
'use strict'; | ||
Object.defineProperty(exports, '__esModule', { value: true }); | ||
var core = require('@tiptap/core'); | ||
@@ -40,3 +42,4 @@ | ||
module.exports = TaskList; | ||
exports.TaskList = TaskList; | ||
exports.default = TaskList; | ||
//# sourceMappingURL=tiptap-extension-task-list.cjs.js.map |
@@ -39,2 +39,3 @@ import { Node, mergeAttributes } from '@tiptap/core'; | ||
export default TaskList; | ||
export { TaskList }; | ||
//# sourceMappingURL=tiptap-extension-task-list.esm.js.map |
(function (global, factory) { | ||
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('@tiptap/core')) : | ||
typeof define === 'function' && define.amd ? define(['@tiptap/core'], factory) : | ||
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global['@tiptap/extension-task-list'] = factory(global.core)); | ||
}(this, (function (core) { 'use strict'; | ||
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@tiptap/core')) : | ||
typeof define === 'function' && define.amd ? define(['exports', '@tiptap/core'], factory) : | ||
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global['@tiptap/extension-task-list'] = {}, global.core)); | ||
}(this, (function (exports, core) { 'use strict'; | ||
@@ -42,5 +42,8 @@ const TaskList = core.Node.create({ | ||
return TaskList; | ||
exports.TaskList = TaskList; | ||
exports.default = TaskList; | ||
Object.defineProperty(exports, '__esModule', { value: true }); | ||
}))); | ||
//# sourceMappingURL=tiptap-extension-task-list.umd.js.map |
{ | ||
"name": "@tiptap/extension-task-list", | ||
"description": "task list extension for tiptap", | ||
"version": "2.0.0-alpha.4", | ||
"version": "2.0.0-alpha.5", | ||
"homepage": "https://tiptap.dev", | ||
@@ -27,3 +27,3 @@ "keywords": [ | ||
}, | ||
"gitHead": "a884cb81de8783d0097741c1ddb97a82ea88ae0e" | ||
"gitHead": "0371cb0a5d803a44d93532aa34419ec7ffffdc24" | ||
} |
@@ -1,57 +0,5 @@ | ||
import { Command, Node, mergeAttributes } from '@tiptap/core' | ||
import { TaskList } from './task-list' | ||
export interface TaskListOptions { | ||
HTMLAttributes: { | ||
[key: string]: any | ||
}, | ||
} | ||
export * from './task-list' | ||
const TaskList = Node.create({ | ||
name: 'taskList', | ||
defaultOptions: <TaskListOptions>{ | ||
HTMLAttributes: {}, | ||
}, | ||
group: 'block list', | ||
content: 'taskItem+', | ||
parseHTML() { | ||
return [ | ||
{ | ||
tag: 'ul[data-type="taskList"]', | ||
priority: 51, | ||
}, | ||
] | ||
}, | ||
renderHTML({ HTMLAttributes }) { | ||
return ['ul', mergeAttributes(HTMLAttributes, { 'data-type': 'taskList' }), 0] | ||
}, | ||
addCommands() { | ||
return { | ||
/** | ||
* Toggle a task list | ||
*/ | ||
toggleTaskList: (): Command => ({ commands }) => { | ||
return commands.toggleList('taskList', 'taskItem') | ||
}, | ||
} | ||
}, | ||
addKeyboardShortcuts() { | ||
return { | ||
'Mod-Shift-l': () => this.editor.commands.toggleTaskList(), | ||
} | ||
}, | ||
}) | ||
export default TaskList | ||
declare module '@tiptap/core' { | ||
interface AllExtensions { | ||
TaskList: typeof TaskList, | ||
} | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
Found 1 instance in 1 package
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
Found 1 instance in 1 package
18271
16
195