tinacms 2.7.1 → 2.7.2

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/dist/index.js CHANGED
@@ -10193,7 +10193,7 @@ flowchart TD
10193
10193
  "Event Log"
10194
10194
  ));
10195
10195
  };
10196
- const version = "2.7.1";
10196
+ const version = "2.7.2";
10197
10197
  const Nav = ({
10198
10198
  isLocalMode,
10199
10199
  className = "",
@@ -10829,7 +10829,7 @@ flowchart TD
10829
10829
  className: "h-5 w-auto -mx-1 text-blue-500",
10830
10830
  stroke: "currentColor",
10831
10831
  fill: "currentColor",
10832
- "stroke-width": "0",
10832
+ strokeWidth: "0",
10833
10833
  viewBox: "0 0 24 24",
10834
10834
  xmlns: "http://www.w3.org/2000/svg"
10835
10835
  },
@@ -14209,7 +14209,7 @@ flowchart TD
14209
14209
  const CodeBlockToolbarButton = cn$1.withRef(({ clear, ...rest }, ref) => {
14210
14210
  const state = useCodeBlockToolbarButtonState();
14211
14211
  const { props } = useCodeBlockToolbarButton(state);
14212
- return /* @__PURE__ */ React.createElement(ToolbarButton, { ref, tooltip: "Link", ...rest, ...props }, /* @__PURE__ */ React.createElement(Icons.codeBlock, null));
14212
+ return /* @__PURE__ */ React.createElement(ToolbarButton, { ref, tooltip: "Code Block", ...rest, ...props }, /* @__PURE__ */ React.createElement(Icons.codeBlock, null));
14213
14213
  });
14214
14214
  const useImageToolbarButtonState = () => {
14215
14215
  const editor = plateCommon.useEditorState();
@@ -14241,36 +14241,54 @@ flowchart TD
14241
14241
  const ImageToolbarButton = cn$1.withRef(({ clear, ...rest }, ref) => {
14242
14242
  const state = useImageToolbarButtonState();
14243
14243
  const { props } = useImageToolbarButton(state);
14244
- return /* @__PURE__ */ React.createElement(ToolbarButton, { ref, tooltip: "Link", ...rest, ...props }, /* @__PURE__ */ React.createElement(Icons.image, null));
14245
- });
14246
- const IndentListToolbarButton = cn$1.withRef(({ nodeType = plate.ELEMENT_UL }, ref) => {
14247
- const editor = plateCommon.useEditorState();
14248
- const state = plate.useListToolbarButtonState({ nodeType });
14249
- const { props } = plate.useListToolbarButton(state);
14250
- return /* @__PURE__ */ React.createElement(
14251
- ToolbarButton,
14252
- {
14253
- ref,
14254
- tooltip: nodeType === plate.ELEMENT_UL ? "Bulleted List" : "Numbered List",
14255
- ...props,
14256
- onClick: (e) => {
14257
- e.preventDefault();
14258
- e.stopPropagation();
14259
- plate.toggleList(editor, { type: nodeType });
14260
- }
14261
- },
14262
- nodeType === plate.ELEMENT_UL ? /* @__PURE__ */ React.createElement(Icons.ul, null) : /* @__PURE__ */ React.createElement(Icons.ol, null)
14263
- );
14244
+ return /* @__PURE__ */ React.createElement(ToolbarButton, { ref, tooltip: "Image", ...rest, ...props }, /* @__PURE__ */ React.createElement(Icons.image, null));
14264
14245
  });
14246
+ const UnorderedListToolbarButton = cn$1.withRef(
14247
+ (props, ref) => {
14248
+ const editor = plateCommon.useEditorState();
14249
+ const state = plate.useListToolbarButtonState({ nodeType: plate.ELEMENT_UL });
14250
+ const { props: buttonProps } = plate.useListToolbarButton(state);
14251
+ return /* @__PURE__ */ React.createElement(
14252
+ ToolbarButton,
14253
+ {
14254
+ ref,
14255
+ tooltip: "Bulleted List",
14256
+ ...buttonProps,
14257
+ onClick: (e) => {
14258
+ e.preventDefault();
14259
+ e.stopPropagation();
14260
+ plate.toggleList(editor, { type: plate.ELEMENT_UL });
14261
+ }
14262
+ },
14263
+ /* @__PURE__ */ React.createElement(Icons.ul, null)
14264
+ );
14265
+ }
14266
+ );
14267
+ const OrderedListToolbarButton = cn$1.withRef(
14268
+ (props, ref) => {
14269
+ const editor = plateCommon.useEditorState();
14270
+ const state = plate.useListToolbarButtonState({ nodeType: plate.ELEMENT_OL });
14271
+ const { props: buttonProps } = plate.useListToolbarButton(state);
14272
+ return /* @__PURE__ */ React.createElement(
14273
+ ToolbarButton,
14274
+ {
14275
+ ref,
14276
+ tooltip: "Numbered List",
14277
+ ...buttonProps,
14278
+ onClick: (e) => {
14279
+ e.preventDefault();
14280
+ e.stopPropagation();
14281
+ plate.toggleList(editor, { type: plate.ELEMENT_OL });
14282
+ }
14283
+ },
14284
+ /* @__PURE__ */ React.createElement(Icons.ol, null)
14285
+ );
14286
+ }
14287
+ );
14265
14288
  const LinkToolbarButton = cn$1.withRef((rest, ref) => {
14266
14289
  const state = plateLink.useLinkToolbarButtonState();
14267
14290
  const { props } = plateLink.useLinkToolbarButton(state);
14268
- return /* @__PURE__ */ React.createElement(ToolbarButton, { ref, tooltip: "Link", ...props, ...rest }, /* @__PURE__ */ React.createElement(Icons.link, null));
14269
- });
14270
- const MarkToolbarButton = cn$1.withRef(({ clear, nodeType, ...rest }, ref) => {
14271
- const state = plateCommon.useMarkToolbarButtonState({ clear, nodeType });
14272
- const { props } = plateCommon.useMarkToolbarButton(state);
14273
- return /* @__PURE__ */ React.createElement(ToolbarButton, { ref, ...props, ...rest });
14291
+ return /* @__PURE__ */ React.createElement(ToolbarButton, { ref, ...props, ...rest, tooltip: "Link" }, /* @__PURE__ */ React.createElement(Icons.link, null));
14274
14292
  });
14275
14293
  const useMermaidToolbarButtonState = () => {
14276
14294
  const editor = plateCommon.useEditorState();
@@ -14351,7 +14369,7 @@ flowchart TD
14351
14369
  const QuoteToolbarButton = cn$1.withRef(({ clear, ...rest }, ref) => {
14352
14370
  const state = useBlockQuoteToolbarButtonState();
14353
14371
  const { props } = useBlockQuoteToolbarButton(state);
14354
- return /* @__PURE__ */ React.createElement(ToolbarButton, { ref, tooltip: "Link", ...rest, ...props }, /* @__PURE__ */ React.createElement(Icons.quote, null));
14372
+ return /* @__PURE__ */ React.createElement(ToolbarButton, { ref, tooltip: "Quote (⌘+⇧+.)", ...rest, ...props }, /* @__PURE__ */ React.createElement(Icons.quote, null));
14355
14373
  });
14356
14374
  const useRawMarkdownToolbarButton = () => {
14357
14375
  const { setRawMode } = useEditorContext();
@@ -14371,7 +14389,7 @@ flowchart TD
14371
14389
  ToolbarButton,
14372
14390
  {
14373
14391
  ref,
14374
- tooltip: "Link",
14392
+ tooltip: "Raw Markdown",
14375
14393
  ...rest,
14376
14394
  ...props,
14377
14395
  "data-testid": "markdown-button"
@@ -14524,6 +14542,15 @@ flowchart TD
14524
14542
  template.label || template.name
14525
14543
  ))));
14526
14544
  };
14545
+ const MarkToolbarButton = cn$1.withRef(({ clear, nodeType, ...rest }, ref) => {
14546
+ const state = plateCommon.useMarkToolbarButtonState({ clear, nodeType });
14547
+ const { props } = plateCommon.useMarkToolbarButton(state);
14548
+ return /* @__PURE__ */ React.createElement(ToolbarButton, { ref, ...props, ...rest });
14549
+ });
14550
+ const BoldToolbarButton = () => /* @__PURE__ */ React.createElement(MarkToolbarButton, { tooltip: "Bold (⌘+B)", nodeType: plate.MARK_BOLD }, /* @__PURE__ */ React.createElement(Icons.bold, null));
14551
+ const StrikethroughToolbarButton = () => /* @__PURE__ */ React.createElement(MarkToolbarButton, { tooltip: "Strikethrough", nodeType: plate.MARK_STRIKETHROUGH }, /* @__PURE__ */ React.createElement(Icons.strikethrough, null));
14552
+ const ItalicToolbarButton = () => /* @__PURE__ */ React.createElement(MarkToolbarButton, { tooltip: "Italic (⌘+I)", nodeType: plate.MARK_ITALIC }, /* @__PURE__ */ React.createElement(Icons.italic, null));
14553
+ const CodeToolbarButton = () => /* @__PURE__ */ React.createElement(MarkToolbarButton, { tooltip: "Code (⌘+E)", nodeType: plate.MARK_CODE }, /* @__PURE__ */ React.createElement(Icons.code, null));
14527
14554
  const toolbarItems = {
14528
14555
  heading: {
14529
14556
  label: HEADING_LABEL,
@@ -14544,37 +14571,37 @@ flowchart TD
14544
14571
  quote: {
14545
14572
  label: "Quote",
14546
14573
  width: () => STANDARD_ICON_WIDTH,
14547
- Component: /* @__PURE__ */ React.createElement(QuoteToolbarButton, { tooltip: "Quote Quote (⌘+⇧+.)" })
14574
+ Component: /* @__PURE__ */ React.createElement(QuoteToolbarButton, null)
14548
14575
  },
14549
14576
  ul: {
14550
14577
  label: "Unordered List",
14551
14578
  width: () => STANDARD_ICON_WIDTH,
14552
- Component: /* @__PURE__ */ React.createElement(IndentListToolbarButton, { nodeType: plate.ELEMENT_UL })
14579
+ Component: /* @__PURE__ */ React.createElement(UnorderedListToolbarButton, null)
14553
14580
  },
14554
14581
  ol: {
14555
14582
  label: "Ordered List",
14556
14583
  width: () => STANDARD_ICON_WIDTH,
14557
- Component: /* @__PURE__ */ React.createElement(IndentListToolbarButton, { nodeType: plate.ELEMENT_OL })
14584
+ Component: /* @__PURE__ */ React.createElement(OrderedListToolbarButton, null)
14558
14585
  },
14559
14586
  bold: {
14560
14587
  label: "Bold",
14561
14588
  width: () => STANDARD_ICON_WIDTH,
14562
- Component: /* @__PURE__ */ React.createElement(MarkToolbarButton, { tooltip: "Bold (⌘+B)", nodeType: plate.MARK_BOLD }, /* @__PURE__ */ React.createElement(Icons.bold, null))
14589
+ Component: /* @__PURE__ */ React.createElement(BoldToolbarButton, null)
14563
14590
  },
14564
14591
  strikethrough: {
14565
14592
  label: "Strikethrough",
14566
14593
  width: () => STANDARD_ICON_WIDTH,
14567
- Component: /* @__PURE__ */ React.createElement(MarkToolbarButton, { tooltip: "Strikethrough ", nodeType: plate.MARK_STRIKETHROUGH }, /* @__PURE__ */ React.createElement(Icons.strikethrough, null))
14594
+ Component: /* @__PURE__ */ React.createElement(StrikethroughToolbarButton, null)
14568
14595
  },
14569
14596
  italic: {
14570
14597
  label: "Italic",
14571
14598
  width: () => STANDARD_ICON_WIDTH,
14572
- Component: /* @__PURE__ */ React.createElement(MarkToolbarButton, { tooltip: "Italic (⌘+I)", nodeType: plate.MARK_ITALIC }, /* @__PURE__ */ React.createElement(Icons.italic, null))
14599
+ Component: /* @__PURE__ */ React.createElement(ItalicToolbarButton, null)
14573
14600
  },
14574
14601
  code: {
14575
14602
  label: "Code",
14576
14603
  width: () => STANDARD_ICON_WIDTH,
14577
- Component: /* @__PURE__ */ React.createElement(MarkToolbarButton, { tooltip: "Code (⌘+E)", nodeType: plate.MARK_CODE }, /* @__PURE__ */ React.createElement(Icons.code, null))
14604
+ Component: /* @__PURE__ */ React.createElement(CodeToolbarButton, null)
14578
14605
  },
14579
14606
  codeBlock: {
14580
14607
  label: "Code Block",
package/dist/index.mjs CHANGED
@@ -10,7 +10,7 @@ import React__default, { useState, useCallback, useEffect, useRef, createContext
10
10
  import { createPortal } from "react-dom";
11
11
  import { withRef, cn as cn$1, withVariants, withProps, withCn, createPrimitiveElement } from "@udecode/cn";
12
12
  import { toggleList, ELEMENT_UL, ELEMENT_OL, ELEMENT_H1 as ELEMENT_H1$1, ELEMENT_H2 as ELEMENT_H2$1, ELEMENT_H3 as ELEMENT_H3$1, ELEMENT_H4, ELEMENT_H5, ELEMENT_H6, ELEMENT_PARAGRAPH, ELEMENT_BLOCKQUOTE, ELEMENT_CODE_BLOCK, ELEMENT_CODE_LINE, ELEMENT_CODE_SYNTAX, ELEMENT_LI, ELEMENT_LINK, MARK_CODE, MARK_UNDERLINE, MARK_STRIKETHROUGH, MARK_ITALIC, MARK_BOLD, ELEMENT_HR, ELEMENT_TABLE, ELEMENT_TR, ELEMENT_TD, ELEMENT_TH, unwrapList, ELEMENT_TODO_LI, createTrailingBlockPlugin, createAutoformatPlugin, createExitBreakPlugin, KEYS_HEADING, createResetNodePlugin, createBasicMarksPlugin, createHeadingPlugin, createParagraphPlugin, createBlockquotePlugin, createUnderlinePlugin, createListPlugin, createIndentListPlugin, createHorizontalRulePlugin, createNodeIdPlugin, createTablePlugin, getListItemEntry, useListToolbarButtonState, useListToolbarButton } from "@udecode/plate";
13
- import { PlateElement, isCollapsed, findNodePath, getPointAfter, insertNodes, ELEMENT_DEFAULT, focusEditor, getPointBefore, setNodes, isElement, PlateLeaf, createPluginFactory, useComposedRef, useEditorRef, createPointRef, insertText, moveSelection, toggleNodeType, useElement, useRemoveNodeButton, useEditorSelector, isSelectionExpanded, withHOC, normalizeEditor, getBlockAbove, queryNode, getParentNode, isType, someNode, isSelectionAtBlockStart, setElements, insertNode, getPluginType, isBlock, isBlockAboveEmpty, findNode, PlateContent, getNodeEntries, useEditorState, collapseSelection, useMarkToolbarButtonState, useMarkToolbarButton, insertEmptyElement, usePlateSelectors, useEventEditorSelectors, PortalBody, useFormInputProps, createPlugins, Plate } from "@udecode/plate-common";
13
+ import { PlateElement, isCollapsed, findNodePath, getPointAfter, insertNodes, ELEMENT_DEFAULT, focusEditor, getPointBefore, setNodes, isElement, PlateLeaf, createPluginFactory, useComposedRef, useEditorRef, createPointRef, insertText, moveSelection, toggleNodeType, useElement, useRemoveNodeButton, useEditorSelector, isSelectionExpanded, withHOC, normalizeEditor, getBlockAbove, queryNode, getParentNode, isType, someNode, isSelectionAtBlockStart, setElements, insertNode, getPluginType, isBlock, isBlockAboveEmpty, findNode, PlateContent, getNodeEntries, useEditorState, collapseSelection, insertEmptyElement, useMarkToolbarButtonState, useMarkToolbarButton, usePlateSelectors, useEventEditorSelectors, PortalBody, useFormInputProps, createPlugins, Plate } from "@udecode/plate-common";
14
14
  import { ELEMENT_SLASH_INPUT, createSlashPlugin } from "@udecode/plate-slash-command";
15
15
  import { useSelected, useReadOnly, ReactEditor } from "slate-react";
16
16
  import { useCodeBlockElementState, useCodeSyntaxLeaf, ELEMENT_CODE_BLOCK as ELEMENT_CODE_BLOCK$1 } from "@udecode/plate-code-block";
@@ -10220,7 +10220,7 @@ const SyncStatus = ({ cms, setEventsOpen }) => {
10220
10220
  "Event Log"
10221
10221
  ));
10222
10222
  };
10223
- const version = "2.7.1";
10223
+ const version = "2.7.2";
10224
10224
  const Nav = ({
10225
10225
  isLocalMode,
10226
10226
  className = "",
@@ -10856,7 +10856,7 @@ const SidebarHeader = ({
10856
10856
  className: "h-5 w-auto -mx-1 text-blue-500",
10857
10857
  stroke: "currentColor",
10858
10858
  fill: "currentColor",
10859
- "stroke-width": "0",
10859
+ strokeWidth: "0",
10860
10860
  viewBox: "0 0 24 24",
10861
10861
  xmlns: "http://www.w3.org/2000/svg"
10862
10862
  },
@@ -14236,7 +14236,7 @@ const useCodeBlockToolbarButton = (state) => {
14236
14236
  const CodeBlockToolbarButton = withRef(({ clear, ...rest }, ref) => {
14237
14237
  const state = useCodeBlockToolbarButtonState();
14238
14238
  const { props } = useCodeBlockToolbarButton(state);
14239
- return /* @__PURE__ */ React__default.createElement(ToolbarButton, { ref, tooltip: "Link", ...rest, ...props }, /* @__PURE__ */ React__default.createElement(Icons.codeBlock, null));
14239
+ return /* @__PURE__ */ React__default.createElement(ToolbarButton, { ref, tooltip: "Code Block", ...rest, ...props }, /* @__PURE__ */ React__default.createElement(Icons.codeBlock, null));
14240
14240
  });
14241
14241
  const useImageToolbarButtonState = () => {
14242
14242
  const editor = useEditorState();
@@ -14268,36 +14268,54 @@ const useImageToolbarButton = (state) => {
14268
14268
  const ImageToolbarButton = withRef(({ clear, ...rest }, ref) => {
14269
14269
  const state = useImageToolbarButtonState();
14270
14270
  const { props } = useImageToolbarButton(state);
14271
- return /* @__PURE__ */ React__default.createElement(ToolbarButton, { ref, tooltip: "Link", ...rest, ...props }, /* @__PURE__ */ React__default.createElement(Icons.image, null));
14272
- });
14273
- const IndentListToolbarButton = withRef(({ nodeType = ELEMENT_UL }, ref) => {
14274
- const editor = useEditorState();
14275
- const state = useListToolbarButtonState({ nodeType });
14276
- const { props } = useListToolbarButton(state);
14277
- return /* @__PURE__ */ React__default.createElement(
14278
- ToolbarButton,
14279
- {
14280
- ref,
14281
- tooltip: nodeType === ELEMENT_UL ? "Bulleted List" : "Numbered List",
14282
- ...props,
14283
- onClick: (e) => {
14284
- e.preventDefault();
14285
- e.stopPropagation();
14286
- toggleList(editor, { type: nodeType });
14287
- }
14288
- },
14289
- nodeType === ELEMENT_UL ? /* @__PURE__ */ React__default.createElement(Icons.ul, null) : /* @__PURE__ */ React__default.createElement(Icons.ol, null)
14290
- );
14271
+ return /* @__PURE__ */ React__default.createElement(ToolbarButton, { ref, tooltip: "Image", ...rest, ...props }, /* @__PURE__ */ React__default.createElement(Icons.image, null));
14291
14272
  });
14273
+ const UnorderedListToolbarButton = withRef(
14274
+ (props, ref) => {
14275
+ const editor = useEditorState();
14276
+ const state = useListToolbarButtonState({ nodeType: ELEMENT_UL });
14277
+ const { props: buttonProps } = useListToolbarButton(state);
14278
+ return /* @__PURE__ */ React__default.createElement(
14279
+ ToolbarButton,
14280
+ {
14281
+ ref,
14282
+ tooltip: "Bulleted List",
14283
+ ...buttonProps,
14284
+ onClick: (e) => {
14285
+ e.preventDefault();
14286
+ e.stopPropagation();
14287
+ toggleList(editor, { type: ELEMENT_UL });
14288
+ }
14289
+ },
14290
+ /* @__PURE__ */ React__default.createElement(Icons.ul, null)
14291
+ );
14292
+ }
14293
+ );
14294
+ const OrderedListToolbarButton = withRef(
14295
+ (props, ref) => {
14296
+ const editor = useEditorState();
14297
+ const state = useListToolbarButtonState({ nodeType: ELEMENT_OL });
14298
+ const { props: buttonProps } = useListToolbarButton(state);
14299
+ return /* @__PURE__ */ React__default.createElement(
14300
+ ToolbarButton,
14301
+ {
14302
+ ref,
14303
+ tooltip: "Numbered List",
14304
+ ...buttonProps,
14305
+ onClick: (e) => {
14306
+ e.preventDefault();
14307
+ e.stopPropagation();
14308
+ toggleList(editor, { type: ELEMENT_OL });
14309
+ }
14310
+ },
14311
+ /* @__PURE__ */ React__default.createElement(Icons.ol, null)
14312
+ );
14313
+ }
14314
+ );
14292
14315
  const LinkToolbarButton = withRef((rest, ref) => {
14293
14316
  const state = useLinkToolbarButtonState();
14294
14317
  const { props } = useLinkToolbarButton(state);
14295
- return /* @__PURE__ */ React__default.createElement(ToolbarButton, { ref, tooltip: "Link", ...props, ...rest }, /* @__PURE__ */ React__default.createElement(Icons.link, null));
14296
- });
14297
- const MarkToolbarButton = withRef(({ clear, nodeType, ...rest }, ref) => {
14298
- const state = useMarkToolbarButtonState({ clear, nodeType });
14299
- const { props } = useMarkToolbarButton(state);
14300
- return /* @__PURE__ */ React__default.createElement(ToolbarButton, { ref, ...props, ...rest });
14318
+ return /* @__PURE__ */ React__default.createElement(ToolbarButton, { ref, ...props, ...rest, tooltip: "Link" }, /* @__PURE__ */ React__default.createElement(Icons.link, null));
14301
14319
  });
14302
14320
  const useMermaidToolbarButtonState = () => {
14303
14321
  const editor = useEditorState();
@@ -14378,7 +14396,7 @@ const useBlockQuoteToolbarButton = (state) => {
14378
14396
  const QuoteToolbarButton = withRef(({ clear, ...rest }, ref) => {
14379
14397
  const state = useBlockQuoteToolbarButtonState();
14380
14398
  const { props } = useBlockQuoteToolbarButton(state);
14381
- return /* @__PURE__ */ React__default.createElement(ToolbarButton, { ref, tooltip: "Link", ...rest, ...props }, /* @__PURE__ */ React__default.createElement(Icons.quote, null));
14399
+ return /* @__PURE__ */ React__default.createElement(ToolbarButton, { ref, tooltip: "Quote (⌘+⇧+.)", ...rest, ...props }, /* @__PURE__ */ React__default.createElement(Icons.quote, null));
14382
14400
  });
14383
14401
  const useRawMarkdownToolbarButton = () => {
14384
14402
  const { setRawMode } = useEditorContext();
@@ -14398,7 +14416,7 @@ const RawMarkdownToolbarButton = withRef(({ clear, ...rest }, ref) => {
14398
14416
  ToolbarButton,
14399
14417
  {
14400
14418
  ref,
14401
- tooltip: "Link",
14419
+ tooltip: "Raw Markdown",
14402
14420
  ...rest,
14403
14421
  ...props,
14404
14422
  "data-testid": "markdown-button"
@@ -14551,6 +14569,15 @@ const EmbedButton = ({ editor, templates }) => {
14551
14569
  template.label || template.name
14552
14570
  ))));
14553
14571
  };
14572
+ const MarkToolbarButton = withRef(({ clear, nodeType, ...rest }, ref) => {
14573
+ const state = useMarkToolbarButtonState({ clear, nodeType });
14574
+ const { props } = useMarkToolbarButton(state);
14575
+ return /* @__PURE__ */ React__default.createElement(ToolbarButton, { ref, ...props, ...rest });
14576
+ });
14577
+ const BoldToolbarButton = () => /* @__PURE__ */ React__default.createElement(MarkToolbarButton, { tooltip: "Bold (⌘+B)", nodeType: MARK_BOLD }, /* @__PURE__ */ React__default.createElement(Icons.bold, null));
14578
+ const StrikethroughToolbarButton = () => /* @__PURE__ */ React__default.createElement(MarkToolbarButton, { tooltip: "Strikethrough", nodeType: MARK_STRIKETHROUGH }, /* @__PURE__ */ React__default.createElement(Icons.strikethrough, null));
14579
+ const ItalicToolbarButton = () => /* @__PURE__ */ React__default.createElement(MarkToolbarButton, { tooltip: "Italic (⌘+I)", nodeType: MARK_ITALIC }, /* @__PURE__ */ React__default.createElement(Icons.italic, null));
14580
+ const CodeToolbarButton = () => /* @__PURE__ */ React__default.createElement(MarkToolbarButton, { tooltip: "Code (⌘+E)", nodeType: MARK_CODE }, /* @__PURE__ */ React__default.createElement(Icons.code, null));
14554
14581
  const toolbarItems = {
14555
14582
  heading: {
14556
14583
  label: HEADING_LABEL,
@@ -14571,37 +14598,37 @@ const toolbarItems = {
14571
14598
  quote: {
14572
14599
  label: "Quote",
14573
14600
  width: () => STANDARD_ICON_WIDTH,
14574
- Component: /* @__PURE__ */ React__default.createElement(QuoteToolbarButton, { tooltip: "Quote Quote (⌘+⇧+.)" })
14601
+ Component: /* @__PURE__ */ React__default.createElement(QuoteToolbarButton, null)
14575
14602
  },
14576
14603
  ul: {
14577
14604
  label: "Unordered List",
14578
14605
  width: () => STANDARD_ICON_WIDTH,
14579
- Component: /* @__PURE__ */ React__default.createElement(IndentListToolbarButton, { nodeType: ELEMENT_UL })
14606
+ Component: /* @__PURE__ */ React__default.createElement(UnorderedListToolbarButton, null)
14580
14607
  },
14581
14608
  ol: {
14582
14609
  label: "Ordered List",
14583
14610
  width: () => STANDARD_ICON_WIDTH,
14584
- Component: /* @__PURE__ */ React__default.createElement(IndentListToolbarButton, { nodeType: ELEMENT_OL })
14611
+ Component: /* @__PURE__ */ React__default.createElement(OrderedListToolbarButton, null)
14585
14612
  },
14586
14613
  bold: {
14587
14614
  label: "Bold",
14588
14615
  width: () => STANDARD_ICON_WIDTH,
14589
- Component: /* @__PURE__ */ React__default.createElement(MarkToolbarButton, { tooltip: "Bold (⌘+B)", nodeType: MARK_BOLD }, /* @__PURE__ */ React__default.createElement(Icons.bold, null))
14616
+ Component: /* @__PURE__ */ React__default.createElement(BoldToolbarButton, null)
14590
14617
  },
14591
14618
  strikethrough: {
14592
14619
  label: "Strikethrough",
14593
14620
  width: () => STANDARD_ICON_WIDTH,
14594
- Component: /* @__PURE__ */ React__default.createElement(MarkToolbarButton, { tooltip: "Strikethrough ", nodeType: MARK_STRIKETHROUGH }, /* @__PURE__ */ React__default.createElement(Icons.strikethrough, null))
14621
+ Component: /* @__PURE__ */ React__default.createElement(StrikethroughToolbarButton, null)
14595
14622
  },
14596
14623
  italic: {
14597
14624
  label: "Italic",
14598
14625
  width: () => STANDARD_ICON_WIDTH,
14599
- Component: /* @__PURE__ */ React__default.createElement(MarkToolbarButton, { tooltip: "Italic (⌘+I)", nodeType: MARK_ITALIC }, /* @__PURE__ */ React__default.createElement(Icons.italic, null))
14626
+ Component: /* @__PURE__ */ React__default.createElement(ItalicToolbarButton, null)
14600
14627
  },
14601
14628
  code: {
14602
14629
  label: "Code",
14603
14630
  width: () => STANDARD_ICON_WIDTH,
14604
- Component: /* @__PURE__ */ React__default.createElement(MarkToolbarButton, { tooltip: "Code (⌘+E)", nodeType: MARK_CODE }, /* @__PURE__ */ React__default.createElement(Icons.code, null))
14631
+ Component: /* @__PURE__ */ React__default.createElement(CodeToolbarButton, null)
14605
14632
  },
14606
14633
  codeBlock: {
14607
14634
  label: "Code Block",
@@ -1,8 +1,5 @@
1
1
  import React from 'react';
2
- import { type ELEMENT_OL, ELEMENT_UL } from '@udecode/plate';
3
- export declare const IndentListToolbarButton: React.ForwardRefExoticComponent<{
4
- nodeType?: typeof ELEMENT_UL | typeof ELEMENT_OL;
5
- } & Omit<Omit<{
2
+ export declare const UnorderedListToolbarButton: React.ForwardRefExoticComponent<Omit<Omit<{
6
3
  tooltip?: React.ReactNode;
7
4
  tooltipContentProps?: Omit<React.ComponentPropsWithoutRef<React.ForwardRefExoticComponent<import("@radix-ui/react-tooltip").TooltipContentProps & React.RefAttributes<HTMLDivElement>>>, "children">;
8
5
  tooltipProps?: Omit<React.ComponentPropsWithoutRef<React.FC<import("@radix-ui/react-tooltip").TooltipProps>>, "children">;
@@ -16,4 +13,19 @@ export declare const IndentListToolbarButton: React.ForwardRefExoticComponent<{
16
13
  } & import("class-variance-authority/dist/types").ClassProp) => string> & React.RefAttributes<HTMLButtonElement>, "ref">, "value" | "asChild"> & import("class-variance-authority").VariantProps<(props?: {
17
14
  size?: "default" | "sm" | "lg";
18
15
  variant?: "default" | "outline";
19
- } & import("class-variance-authority/dist/types").ClassProp) => string> & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>, "ref">, "nodeType"> & React.RefAttributes<HTMLButtonElement>>;
16
+ } & import("class-variance-authority/dist/types").ClassProp) => string> & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>, "ref">, never> & React.RefAttributes<HTMLButtonElement>>;
17
+ export declare const OrderedListToolbarButton: React.ForwardRefExoticComponent<Omit<Omit<{
18
+ tooltip?: React.ReactNode;
19
+ tooltipContentProps?: Omit<React.ComponentPropsWithoutRef<React.ForwardRefExoticComponent<import("@radix-ui/react-tooltip").TooltipContentProps & React.RefAttributes<HTMLDivElement>>>, "children">;
20
+ tooltipProps?: Omit<React.ComponentPropsWithoutRef<React.FC<import("@radix-ui/react-tooltip").TooltipProps>>, "children">;
21
+ } & Omit<{
22
+ isDropdown?: boolean;
23
+ pressed?: boolean;
24
+ showArrow?: boolean;
25
+ } & Omit<Omit<Omit<import("@radix-ui/react-toolbar").ToolbarToggleItemProps & React.RefAttributes<HTMLButtonElement>, "ref"> & import("class-variance-authority").VariantProps<(props?: {
26
+ size?: "default" | "sm" | "lg";
27
+ variant?: "default" | "outline";
28
+ } & import("class-variance-authority/dist/types").ClassProp) => string> & React.RefAttributes<HTMLButtonElement>, "ref">, "value" | "asChild"> & import("class-variance-authority").VariantProps<(props?: {
29
+ size?: "default" | "sm" | "lg";
30
+ variant?: "default" | "outline";
31
+ } & import("class-variance-authority/dist/types").ClassProp) => string> & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>, "ref">, never> & React.RefAttributes<HTMLButtonElement>>;
@@ -1,19 +1,5 @@
1
1
  import React from 'react';
2
- export declare const MarkToolbarButton: React.ForwardRefExoticComponent<{
3
- clear?: string | string[];
4
- nodeType: string;
5
- } & Omit<Omit<{
6
- tooltip?: React.ReactNode;
7
- tooltipContentProps?: Omit<React.ComponentPropsWithoutRef<React.ForwardRefExoticComponent<import("@radix-ui/react-tooltip").TooltipContentProps & React.RefAttributes<HTMLDivElement>>>, "children">;
8
- tooltipProps?: Omit<React.ComponentPropsWithoutRef<React.FC<import("@radix-ui/react-tooltip").TooltipProps>>, "children">;
9
- } & Omit<{
10
- isDropdown?: boolean;
11
- pressed?: boolean;
12
- showArrow?: boolean;
13
- } & Omit<Omit<Omit<import("@radix-ui/react-toolbar").ToolbarToggleItemProps & React.RefAttributes<HTMLButtonElement>, "ref"> & import("class-variance-authority").VariantProps<(props?: {
14
- size?: "default" | "sm" | "lg";
15
- variant?: "default" | "outline";
16
- } & import("class-variance-authority/dist/types").ClassProp) => string> & React.RefAttributes<HTMLButtonElement>, "ref">, "value" | "asChild"> & import("class-variance-authority").VariantProps<(props?: {
17
- size?: "default" | "sm" | "lg";
18
- variant?: "default" | "outline";
19
- } & import("class-variance-authority/dist/types").ClassProp) => string> & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>, "ref">, "clear" | "nodeType"> & React.RefAttributes<HTMLButtonElement>>;
2
+ export declare const BoldToolbarButton: () => React.JSX.Element;
3
+ export declare const StrikethroughToolbarButton: () => React.JSX.Element;
4
+ export declare const ItalicToolbarButton: () => React.JSX.Element;
5
+ export declare const CodeToolbarButton: () => React.JSX.Element;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tinacms",
3
- "version": "2.7.1",
3
+ "version": "2.7.2",
4
4
  "main": "dist/index.js",
5
5
  "module": "./dist/index.mjs",
6
6
  "exports": {
@@ -129,9 +129,9 @@
129
129
  "webfontloader": "1.6.28",
130
130
  "yup": "^1.6.1",
131
131
  "zod": "^3.24.2",
132
- "@tinacms/mdx": "1.6.0",
133
- "@tinacms/search": "1.0.40",
134
- "@tinacms/schema-tools": "1.7.1"
132
+ "@tinacms/mdx": "1.6.1",
133
+ "@tinacms/schema-tools": "1.7.2",
134
+ "@tinacms/search": "1.0.41"
135
135
  },
136
136
  "devDependencies": {
137
137
  "@graphql-tools/utils": "^10.8.1",
@@ -164,7 +164,7 @@
164
164
  "typescript": "^5.7.3",
165
165
  "vite": "^5.4.14",
166
166
  "vitest": "^2.1.9",
167
- "@tinacms/scripts": "1.3.2"
167
+ "@tinacms/scripts": "1.3.3"
168
168
  },
169
169
  "peerDependencies": {
170
170
  "react": ">=16.14.0",