docblocks-react-ui 0.29.2 → 0.31.0
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 +80 -0
- package/README.md +14 -0
- package/dist/{Editor-y3dFOZE4.mjs → Editor-CAU0NkdR.mjs} +976 -197
- package/dist/index.d.mts +2 -2
- package/dist/index.mjs +1 -1
- package/dist/mermaid/index.mjs +1 -1
- package/dist/styles.css +20 -9
- package/package.json +2 -2
package/dist/index.d.mts
CHANGED
|
@@ -404,14 +404,14 @@ declare function Alert({ className, variant, ...props }: React$1.ComponentProps<
|
|
|
404
404
|
declare function AlertTitle({ className, ...props }: React$1.ComponentProps<"div">): React$1.JSX.Element;
|
|
405
405
|
declare function AlertDescription({ className, ...props }: React$1.ComponentProps<"div">): React$1.JSX.Element;
|
|
406
406
|
declare const badgeVariants: (props?: ({
|
|
407
|
-
variant?: "
|
|
407
|
+
variant?: "custom" | "default" | "secondary" | "destructive" | "outline" | null | undefined;
|
|
408
408
|
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
409
409
|
declare function Badge({ className, variant, asChild, ...props }: React$1.ComponentProps<"span"> & VariantProps<typeof badgeVariants> & {
|
|
410
410
|
asChild?: boolean;
|
|
411
411
|
}): React$1.JSX.Element;
|
|
412
412
|
declare function BareSelect({ className, children, ...props }: React$1.ComponentProps<"select">): React$1.JSX.Element;
|
|
413
413
|
declare const buttonVariants: (props?: ({
|
|
414
|
-
variant?: "default" | "
|
|
414
|
+
variant?: "default" | "secondary" | "destructive" | "outline" | "ghost" | "link" | null | undefined;
|
|
415
415
|
size?: "default" | "sm" | "lg" | "icon" | "xl" | null | undefined;
|
|
416
416
|
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
417
417
|
declare function Button({ className, variant, size, asChild, type, ...props }: React$1.ComponentProps<"button"> & VariantProps<typeof buttonVariants> & {
|
package/dist/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $ as DropdownMenuShortcut, $t as useText, A as Select, At as columnAnnotation, B as Label, Bt as CardDescription, C as cellValueEqual, Ct as isBridgeErrorCode, D as filterIsComplete, Dt as conditionMatches, E as emptyFilter, Et as ENUM_OPTION_NAME_COLUMN, F as SelectScrollDownButton, Ft as BookOpen, G as DropdownMenuContent, Gt as badgeVariants, H as Input, Ht as CardHeader, I as SelectScrollUpButton, It as Skeleton, J as DropdownMenuLabel, Jt as useMeta, K as DropdownMenuGroup, Kt as useBlock, L as SelectSeparator, Lt as Card, M as SelectGroup, Mt as Pen, N as SelectItem, Nt as Eye, O as SegmentSelector, Ot as parseCellValue, P as SelectLabel, Q as DropdownMenuSeparator, Qt as useSelectionView, R as SelectTrigger, Rt as CardAction, S as useDatabaseTable, St as isBridgeError, T as FilterBuilder, Tt as ENUM_OPTION_COLOR_COLUMN, U as DropdownMenu, Ut as CardTitle, V as InlineEditInput, Vt as CardFooter, W as DropdownMenuCheckboxItem, Wt as Badge, X as DropdownMenuRadioGroup, Xt as usePresenceSharing, Y as DropdownMenuPortal, Yt as usePresence, Z as DropdownMenuRadioItem, Zt as useSelection, _ as mapFrontmatter, _t as PROTOCOL_VERSION, a as DEFAULT_EMBED_SANDBOX, at as Popover, b as renderRuns, bt as BRIDGE_ERROR_CODES, c as SHAPE_FONT_OPTIONS, ct as PopoverDescription, d as FORMAT_PALETTE, dt as PopoverTrigger, en as DocblocksI18nProvider, et as DropdownMenuSub, ft as Checkbox, g as parseFrontmatter, gt as BASELINE_CAPABILITIES, h as mdToBlocks, ht as AlertTitle, i as useEditorContext, in as buttonVariants, it as Separator, j as SelectContent, k as ScrollArea, kt as TEXT_TYPES, l as SHAPE_FONT_STACKS, lt as PopoverHeader, m as insertNative, mt as AlertDescription, n as useCoverAverageColor, nn as EditorErrorBoundary, nt as DropdownMenuSubTrigger, ot as PopoverAnchor, p as htmlToBlocks, pt as Alert, q as DropdownMenuItem, qt as useDoc, r as EditorProvider, rn as Button, rt as DropdownMenuTrigger, st as PopoverContent, t as Editor, tn as createMemoryBlobStore, tt as DropdownMenuSubContent, ut as PopoverTitle, v as markToggleAction, vt as isDatabaseBridge, w as newMutationContext, wt as toBridgeError, x as GridBody, xt as BridgeError, yt as validateProtocolDescriptor, z as SelectValue, zt as CardContent } from "./Editor-
|
|
1
|
+
import { $ as DropdownMenuShortcut, $t as useText, A as Select, At as columnAnnotation, B as Label, Bt as CardDescription, C as cellValueEqual, Ct as isBridgeErrorCode, D as filterIsComplete, Dt as conditionMatches, E as emptyFilter, Et as ENUM_OPTION_NAME_COLUMN, F as SelectScrollDownButton, Ft as BookOpen, G as DropdownMenuContent, Gt as badgeVariants, H as Input, Ht as CardHeader, I as SelectScrollUpButton, It as Skeleton, J as DropdownMenuLabel, Jt as useMeta, K as DropdownMenuGroup, Kt as useBlock, L as SelectSeparator, Lt as Card, M as SelectGroup, Mt as Pen, N as SelectItem, Nt as Eye, O as SegmentSelector, Ot as parseCellValue, P as SelectLabel, Q as DropdownMenuSeparator, Qt as useSelectionView, R as SelectTrigger, Rt as CardAction, S as useDatabaseTable, St as isBridgeError, T as FilterBuilder, Tt as ENUM_OPTION_COLOR_COLUMN, U as DropdownMenu, Ut as CardTitle, V as InlineEditInput, Vt as CardFooter, W as DropdownMenuCheckboxItem, Wt as Badge, X as DropdownMenuRadioGroup, Xt as usePresenceSharing, Y as DropdownMenuPortal, Yt as usePresence, Z as DropdownMenuRadioItem, Zt as useSelection, _ as mapFrontmatter, _t as PROTOCOL_VERSION, a as DEFAULT_EMBED_SANDBOX, at as Popover, b as renderRuns, bt as BRIDGE_ERROR_CODES, c as SHAPE_FONT_OPTIONS, ct as PopoverDescription, d as FORMAT_PALETTE, dt as PopoverTrigger, en as DocblocksI18nProvider, et as DropdownMenuSub, ft as Checkbox, g as parseFrontmatter, gt as BASELINE_CAPABILITIES, h as mdToBlocks, ht as AlertTitle, i as useEditorContext, in as buttonVariants, it as Separator, j as SelectContent, k as ScrollArea, kt as TEXT_TYPES, l as SHAPE_FONT_STACKS, lt as PopoverHeader, m as insertNative, mt as AlertDescription, n as useCoverAverageColor, nn as EditorErrorBoundary, nt as DropdownMenuSubTrigger, ot as PopoverAnchor, p as htmlToBlocks, pt as Alert, q as DropdownMenuItem, qt as useDoc, r as EditorProvider, rn as Button, rt as DropdownMenuTrigger, st as PopoverContent, t as Editor, tn as createMemoryBlobStore, tt as DropdownMenuSubContent, ut as PopoverTitle, v as markToggleAction, vt as isDatabaseBridge, w as newMutationContext, wt as toBridgeError, x as GridBody, xt as BridgeError, yt as validateProtocolDescriptor, z as SelectValue, zt as CardContent } from "./Editor-CAU0NkdR.mjs";
|
|
2
2
|
import { useTranslation } from "react-i18next";
|
|
3
3
|
import { useCallback, useEffect, useRef, useState } from "react";
|
|
4
4
|
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-CBPODzZc.mjs";
|
package/dist/mermaid/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { It as Skeleton, Nt as Eye, O as SegmentSelector, Pt as CodeXml, f as textOf, ht as AlertTitle, i as useEditorContext, jt as RotateCcw, mt as AlertDescription, o as childrenSlot, pt as Alert, rn as Button, s as CodeHeader, u as TextBlock, y as INLINE_CODE_CLASS } from "../Editor-
|
|
1
|
+
import { It as Skeleton, Nt as Eye, O as SegmentSelector, Pt as CodeXml, f as textOf, ht as AlertTitle, i as useEditorContext, jt as RotateCcw, mt as AlertDescription, o as childrenSlot, pt as Alert, rn as Button, s as CodeHeader, u as TextBlock, y as INLINE_CODE_CLASS } from "../Editor-CAU0NkdR.mjs";
|
|
2
2
|
import mermaid from "mermaid";
|
|
3
3
|
import { useTranslation } from "react-i18next";
|
|
4
4
|
import { useEffect, useRef, useState } from "react";
|
package/dist/styles.css
CHANGED
|
@@ -754,6 +754,9 @@
|
|
|
754
754
|
.max-h-full {
|
|
755
755
|
max-height: 100%;
|
|
756
756
|
}
|
|
757
|
+
.min-h-\(--docblocks-line-box-height\) {
|
|
758
|
+
min-height: var(--docblocks-line-box-height);
|
|
759
|
+
}
|
|
757
760
|
.min-h-0 {
|
|
758
761
|
min-height: 0px;
|
|
759
762
|
}
|
|
@@ -3942,10 +3945,12 @@
|
|
|
3942
3945
|
/* The connect indicator (the endpoint drag's port snap: the badge's
|
|
3943
3946
|
green + the snapped port dot). */
|
|
3944
3947
|
--docblocks-canvas-connect-color: #16a34a;
|
|
3945
|
-
/* The canvas
|
|
3946
|
-
|
|
3947
|
-
|
|
3948
|
-
|
|
3948
|
+
/* The canvas container's resting outline (the group / the frame box):
|
|
3949
|
+
the muted line, strong enough to read over brightly stroked figures
|
|
3950
|
+
at a low zoom. Declared once, theme-independent (the color-mix
|
|
3951
|
+
follows the theme flip); the width stands the box's ring. */
|
|
3952
|
+
--docblocks-canvas-group-border-color: color-mix(in srgb, var(--muted-foreground, #afb8c1) 85%, transparent);
|
|
3953
|
+
--docblocks-canvas-group-border-width: 2px;
|
|
3949
3954
|
|
|
3950
3955
|
/* The floating format toolbar (the selection's formatting layer). */
|
|
3951
3956
|
--docblocks-formatbar-background: var(--popover, #ffffff);
|
|
@@ -4141,23 +4146,29 @@
|
|
|
4141
4146
|
/* The empty-block hint: rendered into an empty text block's content box
|
|
4142
4147
|
only while the block holds the caret (the pseudo-element content is not
|
|
4143
4148
|
text content — the input layer and the run rendering ignore it); the
|
|
4144
|
-
attribute carries the provider's placeholder text.
|
|
4149
|
+
attribute carries the provider's placeholder text. The empty page's
|
|
4150
|
+
input stand shows its hint over its :empty stand (the page holds no
|
|
4151
|
+
blocks, so the stand is the page's only affordance — it stands visible
|
|
4152
|
+
before the first focus, inviting the first input). */
|
|
4145
4153
|
[data-slot="docblocks/block-content"]:empty:focus::before,
|
|
4146
|
-
[data-slot="docblocks/block-content"]:empty[data-caret-inside]::before
|
|
4154
|
+
[data-slot="docblocks/block-content"]:empty[data-caret-inside]::before,
|
|
4155
|
+
[data-slot="docblocks/empty-page"]:empty::before {
|
|
4147
4156
|
content: attr(data-placeholder);
|
|
4148
4157
|
color: var(--docblocks-placeholder-color);
|
|
4149
4158
|
pointer-events: none;
|
|
4150
4159
|
}
|
|
4151
4160
|
|
|
4152
|
-
/* The zero-width caret seat: an empty editable (the text block's inner
|
|
4153
|
-
|
|
4161
|
+
/* The zero-width caret seat: an empty editable (the text block's inner, the
|
|
4162
|
+
empty-cell activation layer, and the empty page's input stand) renders a
|
|
4163
|
+
zero-width space while it
|
|
4154
4164
|
stands :empty, so the browser can seat the caret on focus (an empty
|
|
4155
4165
|
contenteditable has no box to take a caret). Structural — a utility
|
|
4156
4166
|
arbitrary-value class cannot carry the CSS escape (the component
|
|
4157
4167
|
source is compiled before the class attribute stands, and the escape
|
|
4158
4168
|
is eaten as a JS octal literal). */
|
|
4159
4169
|
[data-slot="docblocks/block-content"]:empty::after,
|
|
4160
|
-
[data-slot="docblocks/cell-activation"]:empty::after
|
|
4170
|
+
[data-slot="docblocks/cell-activation"]:empty::after,
|
|
4171
|
+
[data-slot="docblocks/empty-page"]:empty::after {
|
|
4161
4172
|
content: "\200b";
|
|
4162
4173
|
}
|
|
4163
4174
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "docblocks-react-ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.31.0",
|
|
4
4
|
"description": "React rendering + editing layer for docblocks: hooks, block renderers, caret/selection, keyboard, clipboard.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
"access": "public"
|
|
37
37
|
},
|
|
38
38
|
"peerDependencies": {
|
|
39
|
-
"docblocks-core": "^0.
|
|
39
|
+
"docblocks-core": "^0.14.0",
|
|
40
40
|
"framer-motion": "^11.0.0 || ^12.0.0 || ^13.0.0 || ^14.0.0",
|
|
41
41
|
"mermaid": "^12.0.0",
|
|
42
42
|
"pdfjs-dist": "^6.0.0",
|