docblocks-react-ui 0.19.0 → 0.19.1

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/CHANGELOG.md CHANGED
@@ -1,5 +1,33 @@
1
1
  # docblocks-react-ui
2
2
 
3
+ ## 0.19.1
4
+
5
+ ### Patch Changes
6
+
7
+ - a093e2f: The canvas connector tool's press no longer starts a native text selection over
8
+ the page miniature's text under the pointer: the press's default stands
9
+ suppressed for the whole gesture, like the move and resize sessions.
10
+ - 89f6cf0: A dragged canvas item (and the page card) now gets its own composited layer
11
+ while the move or resize session is live: the WebKit family repaints the moved
12
+ item's selection ring unreliably over a transform-only change, leaving the ring
13
+ trailing behind the drag.
14
+ - 33cc913: A page-frame block whose canvas frame is wider than the page column is now
15
+ drawn uniformly downscaled to the column's width instead of being clipped at
16
+ its left and right edges; a frame that fits keeps its 1:1 scale.
17
+ - 9c9f55f: The caret seat at a mention chip's boundary now prefers the adjacent editable
18
+ text node over the chip's parent element slot: the WebKit family places a caret
19
+ next to a `contenteditable="false"` inline island unreliably and collapsed the
20
+ pick's caret to the block's end. The element slot stays the fallback when no
21
+ text stands on that side.
22
+ - 18386b1: The divider picked from the slash menu over a block with text no longer does
23
+ nothing: it lands right after the caret block (the trigger phrase strips, the
24
+ block keeps its text, the caret stays in it). A phrase-only block without
25
+ followers still takes the divider's slot.
26
+ - eed613c: The page view's transient surfaces no longer hang over the canvas: the slash
27
+ menu (with its pickers), the mention picker and its hover card, the link editor,
28
+ and the floating format toolbar close on the switch to the canvas view and are
29
+ not resurrected by switching back.
30
+
3
31
  ## 0.19.0
4
32
 
5
33
  ### Minor Changes
package/README.md CHANGED
@@ -1054,6 +1054,36 @@ dark set, so the swatch follows the theme flip). Override them on
1054
1054
  of hex or `var(…)` entries) to replace the swatches outright; a picked
1055
1055
  swatch always commits a concrete hex to the document.
1056
1056
 
1057
+ ### Page width
1058
+
1059
+ The page view renders the document's blocks in a centered column: the block
1060
+ content zone defaults to a 900 px maximum width (the `--docblocks-page-max-width`
1061
+ token), and the column's box adds the two gutter paddings around it (the derived
1062
+ `--docblocks-page-column-max-width`). A narrower viewport renders at the full
1063
+ available width — the maximum never over-constrains. The gutter (the row grip and
1064
+ its quick-insert) follows the column's edge, so it stays clear of the blocks at
1065
+ any width. The canvas view ignores the token: it owns its own full-bleed
1066
+ viewport.
1067
+
1068
+ Change the width by overriding the token on the editor root (the "Overriding
1069
+ individual values" pattern) — any length or percentage stands for a custom
1070
+ width:
1071
+
1072
+ ```css
1073
+ [data-slot="docblocks/editor"] {
1074
+ --docblocks-page-max-width: 1200px; /* a wider content zone */
1075
+ }
1076
+ ```
1077
+
1078
+ `none` stands for the full available width (the blocks span the editor's whole
1079
+ width, the gutter at the viewport's edge):
1080
+
1081
+ ```css
1082
+ [data-slot="docblocks/editor"] {
1083
+ --docblocks-page-max-width: none;
1084
+ }
1085
+ ```
1086
+
1057
1087
  ### Structure
1058
1088
 
1059
1089
  Structural styling hooks are `data-slot` attributes (`docblocks/editor`,
@@ -16551,6 +16551,32 @@ function lineAnchorOf(root) {
16551
16551
  * too: it carries no logical character.
16552
16552
  */
16553
16553
  /**
16554
+ * The caret's seat at a mention chip's boundary over the ADJACENT editable
16555
+ * text: a text node's boundary where one stands on that side and reads
16556
+ * back at the same flat offset. The island's element slot (the chip's
16557
+ * parent) is the seat of last resort: the WebKit family handles a caret
16558
+ * next to a contenteditable=false inline island poorly (the seat collapses
16559
+ * toward the block's end), while a text node's boundary is every engine's
16560
+ * native path. A text that does not read back at the boundary (another
16561
+ * island stands in between) is not adjacent — the element slot stands then.
16562
+ */
16563
+ function chipTextSeat(root, chipText, after, boundary) {
16564
+ const walker = document.createTreeWalker(root, NodeFilter.SHOW_TEXT);
16565
+ walker.currentNode = chipText;
16566
+ for (let node = after ? walker.nextNode() : walker.previousNode(); node !== null;) {
16567
+ if (node instanceof Text && !isLineAnchor$1(node) && mentionChipOf(node) === null) {
16568
+ const seat = {
16569
+ node,
16570
+ offset: after ? 0 : node.nodeValue?.length ?? 0
16571
+ };
16572
+ if (caretOffsetIn(root, seat.node, seat.offset) === boundary) return seat;
16573
+ return null;
16574
+ }
16575
+ node = after ? walker.nextNode() : walker.previousNode();
16576
+ }
16577
+ return null;
16578
+ }
16579
+ /**
16554
16580
  * The flat character offset of a DOM position (node + offset) inside the
16555
16581
  * block root. The node may be a text node (offset in characters) or an
16556
16582
  * element (offset in child slots). A caret on the line anchor (the final
@@ -16629,7 +16655,11 @@ function locatePosition(root, flatOffset) {
16629
16655
  const length = current.nodeValue?.length ?? 0;
16630
16656
  const chip = mentionChipOf(current);
16631
16657
  if (chip !== null) {
16632
- if (flatOffset <= total + length) return chipSlot(chip, (flatOffset - total > length / 2 || flatOffset === total + length) && flatOffset > total);
16658
+ if (flatOffset <= total + length) {
16659
+ const after = flatOffset - total > length / 2 || flatOffset === total + length;
16660
+ const past = after && flatOffset > total;
16661
+ return chipTextSeat(root, current, after, past ? total + length : total) ?? chipSlot(chip, past);
16662
+ }
16633
16663
  total += length;
16634
16664
  return null;
16635
16665
  }
@@ -17780,7 +17810,9 @@ function mentionMarkOf(chip) {
17780
17810
  }
17781
17811
  /** The editor root's mention card layer (the provider's `mentionInteractions`'
17782
17812
  * stand; the null's stand renders nothing). The returned node is the
17783
- * portaled host (or null) — the caller renders it over the root. */
17813
+ * portaled host (or null) — the caller renders it over the root. `close`
17814
+ * drops a standing card (and its pending open) — the caller's view
17815
+ * switch's stand. */
17784
17816
  function useMentionCard(rootRef) {
17785
17817
  const { mentionInteractions } = useEditorContext();
17786
17818
  const [open, setOpen] = useState(null);
@@ -17799,6 +17831,10 @@ function useMentionCard(rootRef) {
17799
17831
  closeTimerRef.current = null;
17800
17832
  }
17801
17833
  };
17834
+ const close = useCallback(() => {
17835
+ cancelTimers();
17836
+ setOpen(null);
17837
+ }, []);
17802
17838
  useEffect(() => {
17803
17839
  if (mentionInteractions === null) return;
17804
17840
  const interactions = mentionInteractions;
@@ -17928,23 +17964,29 @@ function useMentionCard(rootRef) {
17928
17964
  }, [open]);
17929
17965
  let content = null;
17930
17966
  if (open !== null && mentionInteractions !== null) content = mentionInteractions.renderCard(open.mention);
17931
- if (open === null || mentionInteractions === null || content === null) return null;
17932
- return createPortal(/* @__PURE__ */ jsx("div", {
17933
- ref: hostRef,
17934
- "data-slot": "docblocks/mention-card",
17935
- "data-mention-kind": open.mention.kind,
17936
- "data-mention-id": open.mention.id,
17937
- "aria-hidden": true,
17938
- className: "z-modal",
17939
- style: {
17940
- position: "fixed",
17941
- left: open.left,
17942
- top: open.top,
17943
- width: "fit-content",
17944
- visibility: open.placed ? "visible" : "hidden"
17945
- },
17946
- children: content
17947
- }), document.body);
17967
+ if (open === null || mentionInteractions === null || content === null) return {
17968
+ node: null,
17969
+ close
17970
+ };
17971
+ return {
17972
+ node: createPortal(/* @__PURE__ */ jsx("div", {
17973
+ ref: hostRef,
17974
+ "data-slot": "docblocks/mention-card",
17975
+ "data-mention-kind": open.mention.kind,
17976
+ "data-mention-id": open.mention.id,
17977
+ "aria-hidden": true,
17978
+ className: "z-modal",
17979
+ style: {
17980
+ position: "fixed",
17981
+ left: open.left,
17982
+ top: open.top,
17983
+ width: "fit-content",
17984
+ visibility: open.placed ? "visible" : "hidden"
17985
+ },
17986
+ children: content
17987
+ }), document.body),
17988
+ close
17989
+ };
17948
17990
  }
17949
17991
  //#endregion
17950
17992
  //#region src/editing/phrase/phrase.ts
@@ -18417,7 +18459,8 @@ function useMentionMenu(rootRef) {
18417
18459
  onHover: hoverItem,
18418
18460
  onPick: pick,
18419
18461
  onClose: close
18420
- }) : null
18462
+ }) : null,
18463
+ close
18421
18464
  };
18422
18465
  }
18423
18466
  //#endregion
@@ -19238,10 +19281,11 @@ function sameAttrs(block, command) {
19238
19281
  * its whole text. The replace path needs both an empty result and a type
19239
19282
  * change — and a block that owns a derived segment cannot be removed (the
19240
19283
  * removal cascades its followers), so it converts in place instead. The
19241
- * divider over a phrase-only block is a no-op close when the block owns a
19242
- * derived segment (a removal would cascade its followers) — the replace
19243
- * path stands only for a phrase-only block without followers (a divider
19244
- * insert is contentless, nothing is lost).
19284
+ * divider over a phrase-only block without followers takes the replace
19285
+ * path (a contentless insert loses nothing); over any block whose text
19286
+ * survives the strip it is an insert after the block instead — the
19287
+ * divider cannot take the block's text (the core rejects the type change),
19288
+ * nor replace a segment-owning block (the removal cascades).
19245
19289
  */
19246
19290
  function planSlashApply(command, block, text, slashOffset, hasFollowers) {
19247
19291
  if (sameAttrs(block, command)) return { kind: "noop" };
@@ -19252,7 +19296,11 @@ function planSlashApply(command, block, text, slashOffset, hasFollowers) {
19252
19296
  deleteTo: queryEnd
19253
19297
  };
19254
19298
  if (text.slice(0, slashOffset) + text.slice(queryEnd) === "" && !hasFollowers && command.type !== block.type) return { kind: "replace" };
19255
- if (command.type === "divider") return { kind: "noop" };
19299
+ if (command.type === "divider") return {
19300
+ kind: "update",
19301
+ deleteFrom: slashOffset,
19302
+ deleteTo: queryEnd
19303
+ };
19256
19304
  if (command.type === block.type) return {
19257
19305
  kind: "update",
19258
19306
  deleteFrom: slashOffset,
@@ -19377,6 +19425,10 @@ function applySlashPlan(doc, plan, command, blockId, parentId, indent, scope) {
19377
19425
  parent: parentId,
19378
19426
  after: blockId
19379
19427
  }, indent);
19428
+ else if (command.type === "divider") insertCommand(doc, command, {
19429
+ parent: parentId,
19430
+ after: blockId
19431
+ }, indent);
19380
19432
  });
19381
19433
  } catch (error) {
19382
19434
  if (error instanceof InvalidAttrsError || error instanceof InvalidOperationError) return;
@@ -20148,7 +20200,8 @@ function useSlashMenu(rootRef) {
20148
20200
  embedForm,
20149
20201
  cancelEmbedForm,
20150
20202
  commitEmbed
20151
- })
20203
+ }),
20204
+ close
20152
20205
  };
20153
20206
  }
20154
20207
  //#endregion
@@ -24002,6 +24055,10 @@ function useLinkPopover(rootRef) {
24002
24055
  suppressTransientSelection();
24003
24056
  parkFocusRef.current = true;
24004
24057
  }, [rootRef, selectionRef]);
24058
+ const dismiss = useCallback(() => {
24059
+ setPopover(null);
24060
+ setMenu(null);
24061
+ }, []);
24005
24062
  useEffect(() => {
24006
24063
  if (!parkFocusRef.current) return;
24007
24064
  parkFocusRef.current = false;
@@ -24165,7 +24222,8 @@ function useLinkPopover(rootRef) {
24165
24222
  rootRef,
24166
24223
  state: popover,
24167
24224
  onClose: closeAll
24168
- })] })
24225
+ })] }),
24226
+ close: dismiss
24169
24227
  };
24170
24228
  }
24171
24229
  //#endregion
@@ -28111,6 +28169,7 @@ const CanvasItem = memo(function CanvasItem({ id, pendingConnector = null, inter
28111
28169
  const parts = ["translate(-50%, -50%)"];
28112
28170
  if (moveActive) parts.push(`translate(${movePreview.dx}px, ${movePreview.dy}px)`);
28113
28171
  style.transform = parts.join(" ");
28172
+ style.willChange = "transform";
28114
28173
  }
28115
28174
  if (block.type === "canvas-text") {
28116
28175
  const attrs = block.attrs;
@@ -28407,10 +28466,10 @@ function FrameWindowContent({ surfaceId, offset, excludedIds = EMPTY_IDS$1, clas
28407
28466
  * 1:1 (no fit/zoom controls — the v1 boundary). The canvas frame stands the
28408
28467
  * boundary only (a region marker) — this page block is the sole renderer
28409
28468
  * of the frame's content. The box's height is the
28410
- * referenced frame's 1:1; the width is the frame's width clipped to the
28411
- * row's measured width (the window's center stays at the frame's center —
28412
- * a narrow row clips the wide window horizontally, the offset and the dot
28413
- * grid's phase re-derive over the clipped width). The reference is a weak
28469
+ * referenced frame's 1:1; a frame wider than the row is drawn uniformly
28470
+ * downscaled to the row's width (the WHOLE frame area stands — a clipped
28471
+ * window would hide the frame's edges), the 1:1 stand otherwise. The
28472
+ * reference is a weak
28414
28473
  * one: the absent / gone / surface-less reference stands the lenient
28415
28474
  * placeholder (the dangling stand — the render never throws). The
28416
28475
  * window's content is inert (the copies' pointer-transparent stand — the
@@ -28484,21 +28543,16 @@ function FramePageWindow({ id, frameId, surfaceId, referenced }) {
28484
28543
  return () => observer.disconnect();
28485
28544
  }, []);
28486
28545
  const box = effectiveGeometry(referenced);
28487
- const boxW = rowWidth > 0 ? Math.min(box.w, rowWidth) : box.w;
28488
- const boxH = box.h;
28546
+ const scale = rowWidth > 0 && box.w > rowWidth ? rowWidth / box.w : 1;
28547
+ const winW = box.w * scale;
28548
+ const winH = box.h * scale;
28489
28549
  const offset = frameWindowOffset({
28490
28550
  x: box.x,
28491
28551
  y: box.y,
28492
- w: boxW,
28493
- h: boxH
28552
+ w: box.w,
28553
+ h: box.h
28494
28554
  });
28495
- const boxStyle = {
28496
- backgroundColor: "var(--docblocks-canvas-background)",
28497
- ...frameDotBackground(box.x - boxW / 2, box.y - boxH / 2),
28498
- boxShadow: "inset 0 0 0 1px var(--docblocks-canvas-group-border-color)",
28499
- width: boxW,
28500
- height: boxH
28501
- };
28555
+ const dotStyle = frameDotBackground(box.x - box.w / 2, box.y - box.h / 2);
28502
28556
  const title = referenced.attrs?.title ?? "";
28503
28557
  const excludedIds = useMemo(() => [frameId], [frameId]);
28504
28558
  return /* @__PURE__ */ jsx("div", {
@@ -28515,11 +28569,25 @@ function FramePageWindow({ id, frameId, surfaceId, referenced }) {
28515
28569
  role: "img",
28516
28570
  "aria-label": title !== "" ? t("page.windowTitle", { title }) : t("page.windowLabel"),
28517
28571
  className: "relative mx-auto overflow-hidden rounded-(--docblocks-radius)",
28518
- style: boxStyle,
28519
- children: /* @__PURE__ */ jsx(FrameWindowContent, {
28520
- surfaceId,
28521
- offset,
28522
- excludedIds
28572
+ style: {
28573
+ width: winW,
28574
+ height: winH,
28575
+ boxShadow: "inset 0 0 0 1px var(--docblocks-canvas-group-border-color)"
28576
+ },
28577
+ children: /* @__PURE__ */ jsx("div", {
28578
+ className: "absolute top-0 left-0 origin-top-left",
28579
+ style: {
28580
+ width: box.w,
28581
+ height: box.h,
28582
+ backgroundColor: "var(--docblocks-canvas-background)",
28583
+ ...dotStyle,
28584
+ transform: scale === 1 ? void 0 : `scale(${scale})`
28585
+ },
28586
+ children: /* @__PURE__ */ jsx(FrameWindowContent, {
28587
+ surfaceId,
28588
+ offset,
28589
+ excludedIds
28590
+ })
28523
28591
  })
28524
28592
  })
28525
28593
  });
@@ -32589,6 +32657,7 @@ function pageCardDisplayStyleOf(root, handleTarget, rootBlockId, viewport) {
32589
32657
  const parts = ["translate(-50%, -50%)"];
32590
32658
  if (isMoving) parts.push(`translate(${viewport.movePreview.dx}px, ${viewport.movePreview.dy}px)`);
32591
32659
  style.transform = parts.join(" ");
32660
+ style.willChange = "transform";
32592
32661
  return style;
32593
32662
  }
32594
32663
  //#endregion
@@ -33626,6 +33695,8 @@ function toolPress(ctx, event, point) {
33626
33695
  /** The connector tool's press: a press on an item stands the block stand (the two-click's first pick; the press-drag's press on a block), a press off the items stands the FREE stand (the empty-canvas press — the press point is the first endpoint, the release commits). A press with a stand already standing cancels (the second stand commits on the release / the second click). The press's edge snap stands the pressed point — the port ref at the port's stick disk, the free point over the continuous edge (the frozen direction = the snapped side), the plain block ref over the interior (the auto anchor). */
33627
33696
  function connectorToolPress(ctx, event, point) {
33628
33697
  if (ctx.viewport.activeTool !== "connector") return false;
33698
+ ctx.cardPressRef.current = true;
33699
+ ctx.containerRef.current?.focus();
33629
33700
  const id = ctx.standItemAt(event.target)?.getAttribute("data-block-id") ?? null;
33630
33701
  const hasStand = ctx.viewport.pendingConnector !== null || ctx.viewport.pendingFree !== null;
33631
33702
  const canvasPoint = screenToCanvas(point, ctx.viewport.zoom, ctx.viewport.pan);
@@ -39052,6 +39123,28 @@ function Editor({ view = "page", formatPalette = FORMAT_PALETTE }) {
39052
39123
  const mention = useMentionMenu(rootRef);
39053
39124
  const mentionCard = useMentionCard(rootRef);
39054
39125
  const format = useFormatToolbar(rootRef, formatPalette);
39126
+ const pageView = view === "page";
39127
+ const previousViewRef = useRef(view);
39128
+ const closeSlash = slash.close;
39129
+ const closeMention = mention.close;
39130
+ const closeMentionCard = mentionCard.close;
39131
+ const closeLink = linkPopover.close;
39132
+ useEffect(() => {
39133
+ const previous = previousViewRef.current;
39134
+ previousViewRef.current = view;
39135
+ if (previous !== "page" || pageView) return;
39136
+ closeSlash();
39137
+ closeMention();
39138
+ closeMentionCard();
39139
+ closeLink();
39140
+ }, [
39141
+ view,
39142
+ pageView,
39143
+ closeSlash,
39144
+ closeMention,
39145
+ closeMentionCard,
39146
+ closeLink
39147
+ ]);
39055
39148
  useTypingFlag(rootRef);
39056
39149
  const enterGate = useEnterAnimationGate(rootRef);
39057
39150
  const { order, draggingKey, previewIndent, layoutSlide, onRowDragStart, onRowDragMove, onRowDragEnd, onRowReorder } = useMotionDrag({
@@ -39123,14 +39216,14 @@ function Editor({ view = "page", formatPalette = FORMAT_PALETTE }) {
39123
39216
  })
39124
39217
  })
39125
39218
  }),
39126
- slash.menuNode,
39127
- mention.menuNode,
39128
- mentionCard,
39219
+ pageView ? slash.menuNode : null,
39220
+ pageView ? mention.menuNode : null,
39221
+ pageView ? mentionCard.node : null,
39129
39222
  /* @__PURE__ */ jsx(LinkPopoverContext.Provider, {
39130
39223
  value: linkPopover.api,
39131
- children: viewMode ? null : format.toolbarNode
39224
+ children: viewMode || !pageView ? null : format.toolbarNode
39132
39225
  }),
39133
- linkPopover.node
39226
+ pageView ? linkPopover.node : null
39134
39227
  ] })]
39135
39228
  })
39136
39229
  })]
package/dist/index.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  import { C as UnknownSlashCommandError, S as UnhandledValueError, _ as CanvasPasteError, b as HookMisuseError, g as BlobNotFoundError, s as preventDefault, v as DocBlocksUiError, w as cn, x as PdfFetchError, y as EditorProviderError } from "./constants-D_3p65rk.mjs";
2
- import { $ as DropdownMenuShortcut, $t as DocblocksI18nProvider, A as Select, B as Label, Bt as CardFooter, C as cellValueEqual, Ct as isBridgeError, D as filterIsComplete, Dt as parseCellValue, E as emptyFilter, Et as conditionMatches, F as SelectScrollDownButton, Ft as Skeleton, G as DropdownMenuContent, Gt as useBlock, H as Input, Ht as CardTitle, I as SelectScrollUpButton, It as Card, J as DropdownMenuLabel, Jt as usePresence, K as DropdownMenuGroup, Kt as useDoc, L as SelectSeparator, Lt as CardAction, M as SelectGroup, Mt as Eye, N as SelectItem, O as SegmentSelector, Ot as TEXT_TYPES, P as SelectLabel, Pt as BookOpen, Q as DropdownMenuSeparator, Qt as useText, R as SelectTrigger, Rt as CardContent, S as useDatabaseTable, St as BridgeError, T as FilterBuilder, Tt as toBridgeError, U as DropdownMenu, Ut as Badge, V as InlineEditInput, Vt as CardHeader, W as DropdownMenuCheckboxItem, Wt as badgeVariants, X as DropdownMenuRadioGroup, Xt as useSelection, Y as DropdownMenuPortal, Yt as usePresenceSharing, Z as DropdownMenuRadioItem, Zt as useSelectionView, _ as mapFrontmatter, _t as BASELINE_CAPABILITIES, a as DEFAULT_EMBED_SANDBOX, at as Popover, b as renderRuns, bt as validateProtocolDescriptor, c as SHAPE_FONT_OPTIONS, ct as PopoverDescription, d as FORMAT_PALETTE, dt as PopoverTrigger, en as createMemoryBlobStore, et as DropdownMenuSub, ft as Checkbox, g as parseFrontmatter, gt as AlertTitle, h as mdToBlocks, ht as AlertDescription, i as useEditorContext, it as Separator, j as SelectContent, jt as Pen, k as ScrollArea, kt as columnAnnotation, l as SHAPE_FONT_STACKS, lt as PopoverHeader, m as insertNative, mt as Alert, n as useCoverAverageColor, nn as Button, nt as DropdownMenuSubTrigger, ot as PopoverAnchor, p as htmlToBlocks, pt as BareSelect, q as DropdownMenuItem, qt as useMeta, r as EditorProvider, rn as buttonVariants, rt as DropdownMenuTrigger, st as PopoverContent, t as Editor, tn as EditorErrorBoundary, tt as DropdownMenuSubContent, ut as PopoverTitle, v as markToggleAction, vt as PROTOCOL_VERSION, w as newMutationContext, wt as isBridgeErrorCode, x as GridBody, xt as BRIDGE_ERROR_CODES, yt as isDatabaseBridge, z as SelectValue, zt as CardDescription } from "./Editor-BvpTIQRO.mjs";
2
+ import { $ as DropdownMenuShortcut, $t as DocblocksI18nProvider, A as Select, B as Label, Bt as CardFooter, C as cellValueEqual, Ct as isBridgeError, D as filterIsComplete, Dt as parseCellValue, E as emptyFilter, Et as conditionMatches, F as SelectScrollDownButton, Ft as Skeleton, G as DropdownMenuContent, Gt as useBlock, H as Input, Ht as CardTitle, I as SelectScrollUpButton, It as Card, J as DropdownMenuLabel, Jt as usePresence, K as DropdownMenuGroup, Kt as useDoc, L as SelectSeparator, Lt as CardAction, M as SelectGroup, Mt as Eye, N as SelectItem, O as SegmentSelector, Ot as TEXT_TYPES, P as SelectLabel, Pt as BookOpen, Q as DropdownMenuSeparator, Qt as useText, R as SelectTrigger, Rt as CardContent, S as useDatabaseTable, St as BridgeError, T as FilterBuilder, Tt as toBridgeError, U as DropdownMenu, Ut as Badge, V as InlineEditInput, Vt as CardHeader, W as DropdownMenuCheckboxItem, Wt as badgeVariants, X as DropdownMenuRadioGroup, Xt as useSelection, Y as DropdownMenuPortal, Yt as usePresenceSharing, Z as DropdownMenuRadioItem, Zt as useSelectionView, _ as mapFrontmatter, _t as BASELINE_CAPABILITIES, a as DEFAULT_EMBED_SANDBOX, at as Popover, b as renderRuns, bt as validateProtocolDescriptor, c as SHAPE_FONT_OPTIONS, ct as PopoverDescription, d as FORMAT_PALETTE, dt as PopoverTrigger, en as createMemoryBlobStore, et as DropdownMenuSub, ft as Checkbox, g as parseFrontmatter, gt as AlertTitle, h as mdToBlocks, ht as AlertDescription, i as useEditorContext, it as Separator, j as SelectContent, jt as Pen, k as ScrollArea, kt as columnAnnotation, l as SHAPE_FONT_STACKS, lt as PopoverHeader, m as insertNative, mt as Alert, n as useCoverAverageColor, nn as Button, nt as DropdownMenuSubTrigger, ot as PopoverAnchor, p as htmlToBlocks, pt as BareSelect, q as DropdownMenuItem, qt as useMeta, r as EditorProvider, rn as buttonVariants, rt as DropdownMenuTrigger, st as PopoverContent, t as Editor, tn as EditorErrorBoundary, tt as DropdownMenuSubContent, ut as PopoverTitle, v as markToggleAction, vt as PROTOCOL_VERSION, w as newMutationContext, wt as isBridgeErrorCode, x as GridBody, xt as BRIDGE_ERROR_CODES, yt as isDatabaseBridge, z as SelectValue, zt as CardDescription } from "./Editor-C51vAW7_.mjs";
3
3
  import { useCallback, useEffect, useRef, useState } from "react";
4
4
  import { useTranslation } from "react-i18next";
5
5
  import { cva } from "class-variance-authority";
@@ -1,5 +1,5 @@
1
1
  import { a as clamp, d as Plus, f as Minus, p as LoaderCircle, s as preventDefault, u as TriangleAlert } from "../constants-D_3p65rk.mjs";
2
- import { At as RotateCcw, Ft as Skeleton, Mt as Eye, Nt as CodeXml, O as SegmentSelector, f as textOf, gt as AlertTitle, ht as AlertDescription, i as useEditorContext, mt as Alert, nn as Button, o as childrenSlot, s as CodeHeader, u as TextBlock, y as INLINE_CODE_CLASS } from "../Editor-BvpTIQRO.mjs";
2
+ import { At as RotateCcw, Ft as Skeleton, Mt as Eye, Nt as CodeXml, O as SegmentSelector, f as textOf, gt as AlertTitle, ht as AlertDescription, i as useEditorContext, mt as Alert, nn as Button, o as childrenSlot, s as CodeHeader, u as TextBlock, y as INLINE_CODE_CLASS } from "../Editor-C51vAW7_.mjs";
3
3
  import { t as Maximize } from "../Maximize-BBHnCDWL.mjs";
4
4
  import { useEffect, useRef, useState } from "react";
5
5
  import { useTranslation } from "react-i18next";
package/dist/styles.css CHANGED
@@ -919,6 +919,9 @@
919
919
  .origin-left {
920
920
  transform-origin: 0;
921
921
  }
922
+ .origin-top-left {
923
+ transform-origin: 0 0;
924
+ }
922
925
  .-translate-x-1\/2 {
923
926
  --tw-translate-x: calc(calc(1 / 2 * 100%) * -1);
924
927
  translate: var(--tw-translate-x) var(--tw-translate-y);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "docblocks-react-ui",
3
- "version": "0.19.0",
3
+ "version": "0.19.1",
4
4
  "description": "React rendering + editing layer for docblocks: hooks, block renderers, caret/selection, keyboard, clipboard.",
5
5
  "type": "module",
6
6
  "license": "MIT",