{"version":3,"sources":["jsdelivr-header.js","/npm/@tiptap/extension-table-cell@2.5.8/src/table-cell.ts"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA,uTCSa,MAAA,EAAY,OAAK,OAAyB,CACrD,KAAM,YAEN,WAAU,KACD,CACL,eAAgB,KAIpB,QAAS,SAET,cAAa,KACJ,CACL,QAAS,CACP,QAAS,GAEX,QAAS,CACP,QAAS,GAEX,SAAU,CACR,QAAS,KACT,UAAW,IACT,MAAM,EAAW,EAAQ,aAAa,YAKtC,OAJc,EACV,CAAC,SAAS,EAAU,KACpB,IAEQ,KAMpB,UAAW,OAEX,WAAW,EAEX,UAAS,IACA,CACL,CAAE,IAAK,OAIX,UAAA,EAAW,eAAE,IACX,MAAO,CAAC,KAAM,kBAAgB,KAAK,QAAQ,eAAgB,GAAiB,E","file":"/npm/@tiptap/extension-table-cell@2.5.8/dist/index.umd.js","sourceRoot":"","sourcesContent":["/**\n * Minified by jsDelivr using Terser v5.39.0.\n * Original file: /npm/@tiptap/extension-table-cell@2.5.8/dist/index.umd.js\n *\n * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files\n */\n","import { mergeAttributes, Node } from '@tiptap/core'\n\nexport interface TableCellOptions {\n  /**\n   * The HTML attributes for a table cell node.\n   * @default {}\n   * @example { class: 'foo' }\n   */\n  HTMLAttributes: Record<string, any>,\n}\n\n/**\n * This extension allows you to create table cells.\n * @see https://www.tiptap.dev/api/nodes/table-cell\n */\nexport const TableCell = Node.create<TableCellOptions>({\n  name: 'tableCell',\n\n  addOptions() {\n    return {\n      HTMLAttributes: {},\n    }\n  },\n\n  content: 'block+',\n\n  addAttributes() {\n    return {\n      colspan: {\n        default: 1,\n      },\n      rowspan: {\n        default: 1,\n      },\n      colwidth: {\n        default: null,\n        parseHTML: element => {\n          const colwidth = element.getAttribute('colwidth')\n          const value = colwidth\n            ? [parseInt(colwidth, 10)]\n            : null\n\n          return value\n        },\n      },\n    }\n  },\n\n  tableRole: 'cell',\n\n  isolating: true,\n\n  parseHTML() {\n    return [\n      { tag: 'td' },\n    ]\n  },\n\n  renderHTML({ HTMLAttributes }) {\n    return ['td', mergeAttributes(this.options.HTMLAttributes, HTMLAttributes), 0]\n  },\n\n})\n"]}