@stll/ui 0.65.0 → 0.66.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/dist/calendar/day-calendar.d.ts +8 -3
- package/dist/calendar/day-calendar.js +7 -10
- package/dist/calendar/day-calendar.logic.d.ts +0 -2
- package/dist/calendar/day-calendar.logic.js +1 -2
- package/dist/calendar/primitives.d.ts +1 -3
- package/dist/calendar/primitives.js +1 -2
- package/dist/calendar/resource-calendar.d.ts +0 -2
- package/dist/calendar/resource-calendar.js +1 -2
- package/dist/calendar/resource-calendar.logic.d.ts +1 -3
- package/dist/calendar/resource-calendar.logic.js +1 -2
- package/dist/components/accordion.d.ts +18 -4
- package/dist/components/accordion.js +25 -9
- package/dist/components/ai-label.d.ts +0 -2
- package/dist/components/ai-label.js +1 -2
- package/dist/components/alert-dialog.d.ts +0 -2
- package/dist/components/alert-dialog.js +1 -2
- package/dist/components/animated-count.d.ts +0 -2
- package/dist/components/animated-count.js +1 -2
- package/dist/components/animated-preview.css +152 -0
- package/dist/components/animated-preview.d.ts +75 -0
- package/dist/components/animated-preview.js +105 -0
- package/dist/components/application-rail.d.ts +1 -3
- package/dist/components/application-rail.js +1 -2
- package/dist/components/avatar.d.ts +0 -2
- package/dist/components/avatar.js +1 -2
- package/dist/components/badge.d.ts +0 -2
- package/dist/components/badge.js +1 -2
- package/dist/components/bidi-text.d.ts +0 -2
- package/dist/components/bidi-text.js +1 -2
- package/dist/components/brand-icons.d.ts +0 -2
- package/dist/components/brand-icons.js +1 -2
- package/dist/components/breadcrumb.d.ts +0 -2
- package/dist/components/breadcrumb.js +1 -2
- package/dist/components/button.d.ts +0 -2
- package/dist/components/button.js +35 -13
- package/dist/components/button.native-classes.d.ts +0 -2
- package/dist/components/button.native-classes.js +1 -2
- package/dist/components/button.native.d.ts +0 -2
- package/dist/components/button.native.js +1 -2
- package/dist/components/button.shared.d.ts +1 -3
- package/dist/components/button.shared.js +1 -2
- package/dist/components/checkbox.d.ts +0 -2
- package/dist/components/checkbox.js +1 -2
- package/dist/components/collapsible.d.ts +10 -6
- package/dist/components/collapsible.js +12 -6
- package/dist/components/color-picker.d.ts +12 -5
- package/dist/components/color-picker.js +4 -6
- package/dist/components/combobox.d.ts +0 -2
- package/dist/components/combobox.js +1 -2
- package/dist/components/command.d.ts +0 -2
- package/dist/components/command.js +1 -2
- package/dist/components/composer-tokens.d.ts +1 -3
- package/dist/components/composer-tokens.js +1 -2
- package/dist/components/composer.d.ts +0 -2
- package/dist/components/composer.js +1 -2
- package/dist/components/context-menu.d.ts +1 -3
- package/dist/components/context-menu.js +1 -2
- package/dist/components/copy-button.d.ts +0 -2
- package/dist/components/copy-button.js +1 -2
- package/dist/components/court-badge.d.ts +0 -2
- package/dist/components/court-badge.js +1 -2
- package/dist/components/court-filter.d.ts +0 -2
- package/dist/components/court-filter.js +1 -2
- package/dist/components/date-picker-popover.d.ts +0 -2
- package/dist/components/date-picker-popover.js +4 -68
- package/dist/components/date-picker-popover.logic.d.ts +1 -3
- package/dist/components/date-picker-popover.logic.js +1 -2
- package/dist/components/date-range-filter.d.ts +0 -2
- package/dist/components/date-range-filter.js +1 -2
- package/dist/components/destructive-action-confirmation.d.ts +0 -2
- package/dist/components/destructive-action-confirmation.js +1 -2
- package/dist/components/destructive-confirm-dialog.d.ts +0 -2
- package/dist/components/destructive-confirm-dialog.js +1 -2
- package/dist/components/details-grid.d.ts +13 -5
- package/dist/components/details-grid.js +69 -14
- package/dist/components/dialog-form-state.d.ts +1 -3
- package/dist/components/dialog-form-state.js +1 -2
- package/dist/components/dialog.d.ts +0 -2
- package/dist/components/dialog.js +1 -2
- package/dist/components/directional-icon.d.ts +0 -2
- package/dist/components/directional-icon.js +1 -2
- package/dist/components/document-identity-badge.d.ts +0 -2
- package/dist/components/document-identity-badge.js +1 -2
- package/dist/components/document-identity-badge.logic.d.ts +1 -3
- package/dist/components/document-identity-badge.logic.js +1 -2
- package/dist/components/document-mark.d.ts +9 -0
- package/dist/components/document-mark.js +29 -0
- package/dist/components/document-mark.native.d.ts +11 -0
- package/dist/components/document-mark.native.js +36 -0
- package/dist/components/document-mark.shared.d.ts +378 -0
- package/dist/components/document-mark.shared.js +756 -0
- package/dist/components/field.d.ts +0 -2
- package/dist/components/field.js +1 -2
- package/dist/components/file-input.d.ts +0 -2
- package/dist/components/file-input.js +1 -2
- package/dist/components/form.d.ts +0 -2
- package/dist/components/form.js +1 -2
- package/dist/components/frame.d.ts +0 -2
- package/dist/components/frame.js +1 -2
- package/dist/components/hex-color-picker.d.ts +0 -2
- package/dist/components/hex-color-picker.js +1 -2
- package/dist/components/horizontal-scroller.d.ts +0 -2
- package/dist/components/horizontal-scroller.js +1 -2
- package/dist/components/identity-text.d.ts +0 -2
- package/dist/components/identity-text.js +1 -2
- package/dist/components/inline-drop-indicator.d.ts +1 -3
- package/dist/components/inline-drop-indicator.js +1 -2
- package/dist/components/inline-rename.d.ts +0 -2
- package/dist/components/inline-rename.js +1 -2
- package/dist/components/input-control.d.ts +1 -3
- package/dist/components/input-control.js +1 -2
- package/dist/components/input-group.d.ts +0 -2
- package/dist/components/input-group.js +1 -2
- package/dist/components/input-otp.d.ts +0 -2
- package/dist/components/input-otp.js +1 -2
- package/dist/components/input.d.ts +0 -2
- package/dist/components/input.js +1 -2
- package/dist/components/input.native.d.ts +0 -2
- package/dist/components/input.native.js +1 -2
- package/dist/components/input.shared.d.ts +1 -3
- package/dist/components/kbd.d.ts +58 -0
- package/dist/components/kbd.js +90 -0
- package/dist/components/label.d.ts +0 -2
- package/dist/components/label.js +1 -2
- package/dist/components/landing.d.ts +0 -2
- package/dist/components/landing.js +1 -2
- package/dist/components/list.d.ts +0 -2
- package/dist/components/list.js +1 -2
- package/dist/components/loader.d.ts +0 -2
- package/dist/components/loader.js +1 -2
- package/dist/components/loader.native.d.ts +0 -2
- package/dist/components/loader.native.js +1 -2
- package/dist/components/loader.shared.d.ts +1 -3
- package/dist/components/loader.shared.js +1 -2
- package/dist/components/matter-icon.d.ts +0 -2
- package/dist/components/matter-icon.js +1 -2
- package/dist/components/matter-icon.native.d.ts +0 -2
- package/dist/components/matter-icon.native.js +2 -3
- package/dist/components/matter-icon.shared.d.ts +1 -3
- package/dist/components/matter-icon.shared.js +1 -2
- package/dist/components/menu-section.d.ts +0 -2
- package/dist/components/menu-section.js +1 -2
- package/dist/components/menu.d.ts +18 -4
- package/dist/components/menu.js +27 -7
- package/dist/components/middle-truncate.d.ts +0 -2
- package/dist/components/middle-truncate.js +1 -2
- package/dist/components/middle-truncate.logic.d.ts +0 -2
- package/dist/components/middle-truncate.logic.js +1 -2
- package/dist/components/number-input.d.ts +0 -2
- package/dist/components/number-input.js +1 -2
- package/dist/components/outline-rail.d.ts +12 -3
- package/dist/components/outline-rail.js +61 -9
- package/dist/components/outline-rail.logic.d.ts +0 -2
- package/dist/components/outline-rail.logic.js +7 -3
- package/dist/components/pagination.d.ts +0 -2
- package/dist/components/pagination.js +1 -2
- package/dist/components/popover.d.ts +0 -2
- package/dist/components/popover.js +1 -2
- package/dist/components/preview-card.d.ts +0 -2
- package/dist/components/preview-card.js +1 -2
- package/dist/components/preview-pane.d.ts +0 -2
- package/dist/components/preview-pane.js +1 -2
- package/dist/components/prose.d.ts +0 -2
- package/dist/components/prose.js +1 -2
- package/dist/components/scroll-area.d.ts +0 -2
- package/dist/components/scroll-area.js +1 -2
- package/dist/components/scroll-to-top.d.ts +1 -3
- package/dist/components/scroll-to-top.js +1 -2
- package/dist/components/search-field.d.ts +0 -2
- package/dist/components/search-field.js +1 -2
- package/dist/components/secret-input.d.ts +0 -2
- package/dist/components/secret-input.js +1 -2
- package/dist/components/segmented-icon-toggle.d.ts +0 -2
- package/dist/components/segmented-icon-toggle.js +1 -2
- package/dist/components/select.d.ts +0 -2
- package/dist/components/select.js +1 -2
- package/dist/components/separator.d.ts +0 -2
- package/dist/components/separator.js +1 -2
- package/dist/components/separator.native.d.ts +1 -3
- package/dist/components/separator.native.js +1 -2
- package/dist/components/separator.shared.d.ts +1 -3
- package/dist/components/sheet.d.ts +0 -2
- package/dist/components/sheet.js +1 -2
- package/dist/components/sheet.native.d.ts +1 -3
- package/dist/components/sheet.native.js +1 -2
- package/dist/components/sheet.shared.d.ts +1 -3
- package/dist/components/sidebar.d.ts +0 -2
- package/dist/components/sidebar.js +1 -2
- package/dist/components/sidebar.logic.d.ts +1 -3
- package/dist/components/sidebar.logic.js +1 -2
- package/dist/components/skeleton.d.ts +0 -2
- package/dist/components/skeleton.js +1 -2
- package/dist/components/split-button.d.ts +0 -2
- package/dist/components/split-button.js +1 -2
- package/dist/components/status-mark.d.ts +0 -2
- package/dist/components/status-mark.js +1 -2
- package/dist/components/stella-mark.d.ts +1 -3
- package/dist/components/stella-mark.js +1 -2
- package/dist/components/stella-mark.native.d.ts +1 -3
- package/dist/components/stella-mark.native.js +1 -2
- package/dist/components/stella-mark.shared.d.ts +1 -3
- package/dist/components/stella-mark.shared.js +1 -2
- package/dist/components/stella-wordmark.d.ts +1 -3
- package/dist/components/stella-wordmark.js +1 -2
- package/dist/components/stella-wordmark.native.d.ts +1 -3
- package/dist/components/stella-wordmark.native.js +1 -2
- package/dist/components/stella-wordmark.shared.d.ts +1 -3
- package/dist/components/stella-wordmark.shared.js +1 -2
- package/dist/components/steps.d.ts +0 -2
- package/dist/components/steps.js +1 -2
- package/dist/components/swap-text.d.ts +0 -2
- package/dist/components/swap-text.js +1 -2
- package/dist/components/switch.d.ts +0 -2
- package/dist/components/switch.js +1 -2
- package/dist/components/switch.native.d.ts +0 -2
- package/dist/components/switch.native.js +1 -2
- package/dist/components/switch.shared.d.ts +1 -3
- package/dist/components/table-chart.d.ts +1 -3
- package/dist/components/table-chart.js +1 -2
- package/dist/components/table.d.ts +0 -2
- package/dist/components/table.js +1 -2
- package/dist/components/tabs.d.ts +0 -2
- package/dist/components/tabs.js +1 -2
- package/dist/components/text.d.ts +0 -2
- package/dist/components/text.js +1 -2
- package/dist/components/text.native.d.ts +0 -2
- package/dist/components/text.native.js +1 -2
- package/dist/components/text.shared.d.ts +1 -3
- package/dist/components/text.shared.js +1 -2
- package/dist/components/textarea.d.ts +11 -3
- package/dist/components/textarea.js +51 -13
- package/dist/components/textarea.native.d.ts +1 -3
- package/dist/components/textarea.native.js +1 -2
- package/dist/components/textarea.shared.d.ts +1 -3
- package/dist/components/time-field.d.ts +25 -0
- package/dist/components/time-field.js +108 -0
- package/dist/components/toast.d.ts +0 -2
- package/dist/components/toast.js +1 -2
- package/dist/components/toggle-group.d.ts +0 -2
- package/dist/components/toggle-group.js +1 -2
- package/dist/components/toggle.d.ts +0 -2
- package/dist/components/toggle.js +1 -2
- package/dist/components/toolbar-icon-action.d.ts +0 -2
- package/dist/components/toolbar-icon-action.js +1 -2
- package/dist/components/tooltip-trigger-helper.d.ts +0 -2
- package/dist/components/tooltip-trigger-helper.js +1 -2
- package/dist/components/tooltip.d.ts +7 -3
- package/dist/components/tooltip.js +9 -5
- package/dist/components/truncated-text.d.ts +0 -2
- package/dist/components/truncated-text.js +1 -2
- package/dist/components/view-toolbar.d.ts +0 -2
- package/dist/components/view-toolbar.js +1 -2
- package/dist/components/workspace-shell.d.ts +0 -2
- package/dist/components/workspace-shell.js +1 -2
- package/dist/css.d.ts +0 -1
- package/dist/data-table/schema.d.ts +1 -3
- package/dist/data-table/schema.js +1 -2
- package/dist/data-table/table.d.ts +0 -2
- package/dist/data-table/table.js +1 -2
- package/dist/hooks/use-contained-handler.d.ts +0 -2
- package/dist/hooks/use-contained-handler.js +1 -2
- package/dist/hooks/use-content-dir.d.ts +0 -2
- package/dist/hooks/use-content-dir.js +1 -2
- package/dist/hooks/use-latest.d.ts +1 -3
- package/dist/hooks/use-latest.js +1 -2
- package/dist/hooks/use-mobile.d.ts +1 -3
- package/dist/hooks/use-mobile.js +1 -2
- package/dist/hooks/use-prefers-reduced-motion.d.ts +6 -0
- package/dist/hooks/use-prefers-reduced-motion.js +17 -0
- package/dist/hooks/use-viewport-width.d.ts +1 -3
- package/dist/hooks/use-viewport-width.js +1 -2
- package/dist/index.d.ts +5 -4
- package/dist/index.js +5 -4
- package/dist/inspector/chrome.d.ts +1 -3
- package/dist/inspector/chrome.js +1 -2
- package/dist/inspector/dock.d.ts +0 -2
- package/dist/inspector/dock.js +1 -2
- package/dist/inspector/entity-tab.d.ts +0 -2
- package/dist/inspector/entity-tab.js +1 -2
- package/dist/inspector/entity-tab.logic.d.ts +1 -3
- package/dist/inspector/entity-tab.logic.js +1 -2
- package/dist/inspector/facet-bar.d.ts +1 -3
- package/dist/inspector/facet-bar.js +1 -2
- package/dist/inspector/facet-bar.logic.d.ts +1 -3
- package/dist/inspector/facet-bar.logic.js +1 -2
- package/dist/inspector/layout-tokens.d.ts +1 -3
- package/dist/inspector/layout-tokens.js +1 -2
- package/dist/inspector/pane-width.d.ts +0 -2
- package/dist/inspector/pane-width.js +1 -2
- package/dist/inspector/use-pane-width.d.ts +0 -2
- package/dist/inspector/use-pane-width.js +1 -2
- package/dist/kanban/band-peek.d.ts +1 -3
- package/dist/kanban/band-peek.js +1 -2
- package/dist/kanban/card-properties.d.ts +1 -3
- package/dist/kanban/card-properties.js +1 -2
- package/dist/kanban/card-shell.d.ts +1 -3
- package/dist/kanban/card-shell.js +1 -2
- package/dist/kanban/cell-action.d.ts +1 -3
- package/dist/kanban/cell-action.js +1 -2
- package/dist/kanban/column-band-header.d.ts +1 -3
- package/dist/kanban/column-band-header.js +1 -2
- package/dist/kanban/column-bands.d.ts +1 -3
- package/dist/kanban/column-bands.js +1 -2
- package/dist/kanban/column-header.d.ts +1 -3
- package/dist/kanban/column-header.js +1 -2
- package/dist/kanban/drag-interactions.d.ts +0 -2
- package/dist/kanban/drag-interactions.js +1 -2
- package/dist/kanban/grouping.d.ts +1 -3
- package/dist/kanban/grouping.js +1 -2
- package/dist/kanban/layout-tokens.d.ts +1 -3
- package/dist/kanban/layout-tokens.js +1 -2
- package/dist/kanban/matrix.d.ts +1 -3
- package/dist/kanban/matrix.js +1 -2
- package/dist/kanban/sortable-edge.d.ts +0 -2
- package/dist/kanban/sortable-edge.js +1 -2
- package/dist/kanban/sortable-interactions.d.ts +0 -2
- package/dist/kanban/sortable-interactions.js +1 -2
- package/dist/kanban/sortable-interactions.logic.d.ts +0 -2
- package/dist/kanban/sortable-interactions.logic.js +1 -2
- package/dist/kanban/sticky-lane.d.ts +0 -2
- package/dist/kanban/sticky-lane.js +1 -2
- package/dist/kanban/subgroup-board.d.ts +0 -2
- package/dist/kanban/subgroup-board.js +1 -2
- package/dist/kanban/touch-identity.d.ts +0 -2
- package/dist/kanban/touch-identity.js +1 -2
- package/dist/kanban/virtual-cell.d.ts +1 -3
- package/dist/kanban/virtual-cell.js +1 -2
- package/dist/lib/button-disposition.d.ts +0 -2
- package/dist/lib/button-disposition.js +1 -2
- package/dist/lib/control-size.d.ts +0 -2
- package/dist/lib/control-size.js +1 -2
- package/dist/lib/field-trigger.d.ts +1 -3
- package/dist/lib/field-trigger.js +1 -2
- package/dist/lib/file-picker.d.ts +0 -2
- package/dist/lib/file-picker.js +1 -2
- package/dist/lib/initials.d.ts +1 -3
- package/dist/lib/initials.js +1 -2
- package/dist/lib/inline-reorder.d.ts +0 -2
- package/dist/lib/inline-reorder.js +1 -2
- package/dist/lib/matter-colors.d.ts +0 -2
- package/dist/lib/matter-colors.js +1 -2
- package/dist/lib/menu-row.d.ts +1 -3
- package/dist/lib/menu-row.js +1 -2
- package/dist/lib/option-color.d.ts +1 -3
- package/dist/lib/option-color.js +1 -2
- package/dist/lib/overlay-layer.d.ts +1 -3
- package/dist/lib/overlay-layer.js +1 -2
- package/dist/lib/panel-inset.d.ts +1 -3
- package/dist/lib/panel-inset.js +1 -2
- package/dist/lib/positioner-sizing.d.ts +1 -3
- package/dist/lib/positioner-sizing.js +1 -2
- package/dist/lib/renders-nothing.d.ts +8 -0
- package/dist/lib/renders-nothing.js +14 -0
- package/dist/lib/safe-area.d.ts +1 -3
- package/dist/lib/safe-area.js +1 -2
- package/dist/lib/scroll-edge-fade.d.ts +1 -3
- package/dist/lib/scroll-edge-fade.js +1 -2
- package/dist/lib/slot.d.ts +0 -2
- package/dist/lib/slot.js +1 -2
- package/dist/lib/tab-order.d.ts +0 -2
- package/dist/lib/tab-order.js +1 -2
- package/dist/lib/tooltip-content.d.ts +1 -3
- package/dist/lib/tooltip-content.js +1 -2
- package/dist/lib/typed-character.d.ts +1 -3
- package/dist/lib/typed-character.js +1 -2
- package/dist/lib/utils.d.ts +1 -3
- package/dist/lib/utils.js +1 -2
- package/dist/lib/week.d.ts +1 -3
- package/dist/lib/week.js +1 -2
- package/dist/review/review-author-avatar.d.ts +0 -2
- package/dist/review/review-author-avatar.js +1 -2
- package/dist/review/review-comment-card.d.ts +0 -2
- package/dist/review/review-comment-card.js +1 -2
- package/dist/review/review-decision-actions.d.ts +0 -2
- package/dist/review/review-decision-actions.js +1 -2
- package/dist/review/review-diff-text.d.ts +0 -2
- package/dist/review/review-diff-text.js +1 -2
- package/dist/review/review-out-of-date-notice.d.ts +0 -2
- package/dist/review/review-out-of-date-notice.js +1 -2
- package/dist/review/review-severity-dot.d.ts +0 -2
- package/dist/review/review-severity-dot.js +1 -2
- package/dist/review/review-status-badge.d.ts +0 -2
- package/dist/review/review-status-badge.js +1 -2
- package/dist/review/review-word-diff.d.ts +1 -3
- package/dist/review/review-word-diff.js +1 -2
- package/dist/review/text-mark.d.ts +0 -2
- package/dist/review/text-mark.js +1 -2
- package/dist/styles/theme.css +27 -0
- package/dist/testing/browser-clock.d.ts +1 -3
- package/dist/testing/browser-clock.js +1 -2
- package/package.json +37 -5
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
// src/lib/renders-nothing.ts
|
|
2
|
+
/**
|
|
3
|
+
* Whether React draws nothing for this node: `null`, `undefined`, a boolean,
|
|
4
|
+
* an empty string, or a list of only such nodes. A slot that sits empty
|
|
5
|
+
* (an `icon=""`, a `{flag && value}` that came out `true`, an empty `.map`)
|
|
6
|
+
* is then treated as absent rather than given a box.
|
|
7
|
+
*/
|
|
8
|
+
function rendersNothing(node) {
|
|
9
|
+
if (node === null || node === void 0 || typeof node === "boolean") return true;
|
|
10
|
+
if (typeof node === "string") return node === "";
|
|
11
|
+
if (Array.isArray(node)) return node.every((child) => rendersNothing(child));
|
|
12
|
+
return false;
|
|
13
|
+
}
|
|
14
|
+
export { rendersNothing };
|
package/dist/lib/safe-area.d.ts
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
//#region src/lib/safe-area.d.ts
|
|
2
1
|
/** A centred overlay viewport: the usual 1rem gutter, or the inset when larger. */
|
|
3
2
|
export declare const SAFE_AREA_OVERLAY_GUTTER_CLASS_NAME = "pt-[max(--spacing(4),var(--safe-area-top))] pb-[max(--spacing(4),var(--safe-area-bottom))] ps-[max(--spacing(4),var(--safe-area-inline-start))] pe-[max(--spacing(4),var(--safe-area-inline-end))]";
|
|
4
3
|
/** A surface pinned to the bottom edge keeps its last row above the home indicator. */
|
|
@@ -7,5 +6,4 @@ export declare const SAFE_AREA_BOTTOM_EDGE_CLASS_NAME = "pb-(--safe-area-bottom)
|
|
|
7
6
|
export declare const SAFE_AREA_TOP_EDGE_CLASS_NAME = "pt-(--safe-area-top)";
|
|
8
7
|
/** A surface spanning the full width keeps both sides clear of a landscape notch. */
|
|
9
8
|
export declare const SAFE_AREA_INLINE_CLASS_NAME = "ps-(--safe-area-inline-start) pe-(--safe-area-inline-end)";
|
|
10
|
-
export declare const SAFE_AREA_TOAST_GEOMETRY_CLASS_NAME = "[--toast-safe-width:max(0px,calc(100vw-var(--toast-inset)*2-var(--safe-area-inline-start)-var(--safe-area-inline-end)))] [--toast-offset:0px] md:data-[position*=right]:[--toast-offset:clamp(0px,var(--stella-toast-right-offset,0px),max(0px,calc(var(--toast-safe-width)-10rem)))] w-[max(0px,calc(var(--toast-safe-width)-var(--toast-offset)))] data-[position*=left]:start-[calc(var(--toast-inset)+var(--safe-area-inline-start))] data-[position*=right]:end-[calc(var(--toast-inset)+var(--safe-area-inline-end)+var(--toast-offset))] data-[position*=center]:start-[calc(var(--toast-inset)+var(--safe-area-inline-start)+var(--toast-safe-width)/2)] data-[position*=center]:-translate-x-1/2 rtl:data-[position*=center]:translate-x-1/2";
|
|
11
|
-
//#endregion
|
|
9
|
+
export declare const SAFE_AREA_TOAST_GEOMETRY_CLASS_NAME = "[--toast-safe-width:max(0px,calc(100vw-var(--toast-inset)*2-var(--safe-area-inline-start)-var(--safe-area-inline-end)))] [--toast-offset:0px] md:data-[position*=right]:[--toast-offset:clamp(0px,var(--stella-toast-right-offset,0px),max(0px,calc(var(--toast-safe-width)-10rem)))] w-[max(0px,calc(var(--toast-safe-width)-var(--toast-offset)))] data-[position*=left]:start-[calc(var(--toast-inset)+var(--safe-area-inline-start))] data-[position*=right]:end-[calc(var(--toast-inset)+var(--safe-area-inline-end)+var(--toast-offset))] data-[position*=center]:start-[calc(var(--toast-inset)+var(--safe-area-inline-start)+var(--toast-safe-width)/2)] data-[position*=center]:-translate-x-1/2 rtl:data-[position*=center]:translate-x-1/2";
|
package/dist/lib/safe-area.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
// src/lib/safe-area.ts
|
|
2
2
|
/** A centred overlay viewport: the usual 1rem gutter, or the inset when larger. */
|
|
3
3
|
const SAFE_AREA_OVERLAY_GUTTER_CLASS_NAME = "pt-[max(--spacing(4),var(--safe-area-top))] pb-[max(--spacing(4),var(--safe-area-bottom))] ps-[max(--spacing(4),var(--safe-area-inline-start))] pe-[max(--spacing(4),var(--safe-area-inline-end))]";
|
|
4
4
|
/** A surface pinned to the bottom edge keeps its last row above the home indicator. */
|
|
@@ -8,5 +8,4 @@ const SAFE_AREA_TOP_EDGE_CLASS_NAME = "pt-(--safe-area-top)";
|
|
|
8
8
|
/** A surface spanning the full width keeps both sides clear of a landscape notch. */
|
|
9
9
|
const SAFE_AREA_INLINE_CLASS_NAME = "ps-(--safe-area-inline-start) pe-(--safe-area-inline-end)";
|
|
10
10
|
const SAFE_AREA_TOAST_GEOMETRY_CLASS_NAME = "[--toast-safe-width:max(0px,calc(100vw-var(--toast-inset)*2-var(--safe-area-inline-start)-var(--safe-area-inline-end)))] [--toast-offset:0px] md:data-[position*=right]:[--toast-offset:clamp(0px,var(--stella-toast-right-offset,0px),max(0px,calc(var(--toast-safe-width)-10rem)))] w-[max(0px,calc(var(--toast-safe-width)-var(--toast-offset)))] data-[position*=left]:start-[calc(var(--toast-inset)+var(--safe-area-inline-start))] data-[position*=right]:end-[calc(var(--toast-inset)+var(--safe-area-inline-end)+var(--toast-offset))] data-[position*=center]:start-[calc(var(--toast-inset)+var(--safe-area-inline-start)+var(--toast-safe-width)/2)] data-[position*=center]:-translate-x-1/2 rtl:data-[position*=center]:translate-x-1/2";
|
|
11
|
-
//#endregion
|
|
12
11
|
export { SAFE_AREA_BOTTOM_EDGE_CLASS_NAME, SAFE_AREA_INLINE_CLASS_NAME, SAFE_AREA_OVERLAY_GUTTER_CLASS_NAME, SAFE_AREA_TOAST_GEOMETRY_CLASS_NAME, SAFE_AREA_TOP_EDGE_CLASS_NAME };
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
//#region src/lib/scroll-edge-fade.d.ts
|
|
2
1
|
/**
|
|
3
2
|
* Fades a horizontal scroller's edges while content continues past them.
|
|
4
3
|
*
|
|
@@ -19,5 +18,4 @@ export declare const writeScrollEdgeFade: (node: HTMLElement) => void;
|
|
|
19
18
|
* item added, removed or relabelled), so mutations re-measure too, once per
|
|
20
19
|
* frame.
|
|
21
20
|
*/
|
|
22
|
-
export declare const fadeScrollEdges: (node: HTMLElement | null) => (() => void) | undefined;
|
|
23
|
-
//#endregion
|
|
21
|
+
export declare const fadeScrollEdges: (node: HTMLElement | null) => (() => void) | undefined;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
// src/lib/scroll-edge-fade.ts
|
|
2
2
|
/**
|
|
3
3
|
* Fades a horizontal scroller's edges while content continues past them.
|
|
4
4
|
*
|
|
@@ -58,5 +58,4 @@ const fadeScrollEdges = (node) => {
|
|
|
58
58
|
mutations.disconnect();
|
|
59
59
|
};
|
|
60
60
|
};
|
|
61
|
-
//#endregion
|
|
62
61
|
export { SCROLL_EDGE_FADE_CLASS, fadeScrollEdges, writeScrollEdgeFade };
|
package/dist/lib/slot.d.ts
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
//#region src/lib/slot.d.ts
|
|
2
1
|
/**
|
|
3
2
|
* Minimal replacement for `@radix-ui/react-slot`.
|
|
4
3
|
*
|
|
@@ -24,5 +23,4 @@ type SlotProps = React.HTMLAttributes<HTMLElement> & {
|
|
|
24
23
|
ref?: React.Ref<HTMLElement> | undefined;
|
|
25
24
|
};
|
|
26
25
|
declare const Slot: ({ ref: parentRef, children, className, style, ...rest }: SlotProps) => React.ReactNode;
|
|
27
|
-
//#endregion
|
|
28
26
|
export { Slot };
|
package/dist/lib/slot.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { cn } from "./utils.js";
|
|
2
2
|
import { Children, Fragment, cloneElement, isValidElement } from "react";
|
|
3
|
-
|
|
3
|
+
// src/lib/slot.tsx
|
|
4
4
|
/**
|
|
5
5
|
* Minimal replacement for `@radix-ui/react-slot`.
|
|
6
6
|
*
|
|
@@ -60,5 +60,4 @@ const setSlotRef = (ref, node) => {
|
|
|
60
60
|
}
|
|
61
61
|
if (typeof ref === "object" && ref !== null && "current" in ref) ref.current = node;
|
|
62
62
|
};
|
|
63
|
-
//#endregion
|
|
64
63
|
export { Slot };
|
package/dist/lib/tab-order.d.ts
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
//#region src/lib/tab-order.d.ts
|
|
2
1
|
/**
|
|
3
2
|
* Whether a committed tab list holds different elements, or the same elements
|
|
4
3
|
* in a different order, than the previous commit.
|
|
@@ -28,5 +27,4 @@ type TabStrip = {
|
|
|
28
27
|
*/
|
|
29
28
|
export declare const revealActiveTab: (list: TabStrip) => void;
|
|
30
29
|
export declare const hasTabOrderChanged: <T>(previous: readonly T[], next: readonly T[]) => boolean;
|
|
31
|
-
//#endregion
|
|
32
30
|
export {};
|
package/dist/lib/tab-order.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
// src/lib/tab-order.ts
|
|
2
2
|
/**
|
|
3
3
|
* Brings the active tab back inside a horizontal strip that scrolled it out of
|
|
4
4
|
* view. Moves the strip only, never an ancestor, and works from rendered edges
|
|
@@ -13,5 +13,4 @@ const revealActiveTab = (list) => {
|
|
|
13
13
|
else if (tab.right > strip.right) list.scrollLeft += tab.right - strip.right;
|
|
14
14
|
};
|
|
15
15
|
const hasTabOrderChanged = (previous, next) => previous.length !== next.length || next.some((tab, index) => tab !== previous[index]);
|
|
16
|
-
//#endregion
|
|
17
16
|
export { hasTabOrderChanged, revealActiveTab };
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import * as React$1 from "react";
|
|
2
|
-
//#region src/lib/tooltip-content.d.ts
|
|
3
2
|
/**
|
|
4
3
|
* Whether a tooltip value would actually render a popup.
|
|
5
4
|
*
|
|
@@ -8,5 +7,4 @@ import * as React$1 from "react";
|
|
|
8
7
|
* a disabled button has to stay hoverable so that popup can open. Two copies of
|
|
9
8
|
* this predicate would drift into a button that suppresses its own tooltip.
|
|
10
9
|
*/
|
|
11
|
-
export declare const hasTooltipContent: (content: React$1.ReactNode) => boolean;
|
|
12
|
-
//#endregion
|
|
10
|
+
export declare const hasTooltipContent: (content: React$1.ReactNode) => boolean;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
// src/lib/tooltip-content.ts
|
|
2
2
|
/**
|
|
3
3
|
* Whether a tooltip value would actually render a popup.
|
|
4
4
|
*
|
|
@@ -8,5 +8,4 @@
|
|
|
8
8
|
* this predicate would drift into a button that suppresses its own tooltip.
|
|
9
9
|
*/
|
|
10
10
|
const hasTooltipContent = (content) => content !== void 0 && content !== null && content !== "" && content !== false;
|
|
11
|
-
//#endregion
|
|
12
11
|
export { hasTooltipContent };
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
//#region src/lib/typed-character.d.ts
|
|
2
1
|
/** The keyboard event fields {@link typedCharacter} reads. */
|
|
3
2
|
export type TypedCharacterEvent = Pick<KeyboardEvent, "altKey" | "ctrlKey" | "getModifierState" | "isComposing" | "key" | "metaKey">;
|
|
4
3
|
/**
|
|
@@ -12,5 +11,4 @@ export type TypedCharacterEvent = Pick<KeyboardEvent, "altKey" | "ctrlKey" | "ge
|
|
|
12
11
|
* usually but not always with the AltGraph state. Only Cmd/Win, or Ctrl
|
|
13
12
|
* without Alt or AltGraph, is a command chord.
|
|
14
13
|
*/
|
|
15
|
-
export declare const typedCharacter: (event: TypedCharacterEvent) => string | null;
|
|
16
|
-
//#endregion
|
|
14
|
+
export declare const typedCharacter: (event: TypedCharacterEvent) => string | null;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
// src/lib/typed-character.ts
|
|
2
2
|
const graphemes = new Intl.Segmenter(void 0, { granularity: "grapheme" });
|
|
3
3
|
const isSingleGrapheme = (text) => {
|
|
4
4
|
const first = graphemes.segment(text)[Symbol.iterator]().next();
|
|
@@ -21,5 +21,4 @@ const typedCharacter = (event) => {
|
|
|
21
21
|
if (event.ctrlKey && !isAltGraph) return null;
|
|
22
22
|
return isSingleGrapheme(event.key) ? event.key : null;
|
|
23
23
|
};
|
|
24
|
-
//#endregion
|
|
25
24
|
export { typedCharacter };
|
package/dist/lib/utils.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import * as React$1 from "react";
|
|
2
2
|
import { ClassValue } from "clsx";
|
|
3
|
-
//#region src/lib/utils.d.ts
|
|
4
3
|
export declare function cn(...inputs: ClassValue[]): string;
|
|
5
4
|
/**
|
|
6
5
|
* Compose multiple refs into a single ref callback.
|
|
@@ -15,5 +14,4 @@ export declare function cn(...inputs: ClassValue[]): string;
|
|
|
15
14
|
* their callback happened to return as a cleanup, and warn
|
|
16
15
|
* when it is neither a function nor `undefined`.
|
|
17
16
|
*/
|
|
18
|
-
export declare const composeRefs: <T>(...refs: (React$1.Ref<T> | undefined)[]) => ((node: T | null) => (() => void) | undefined);
|
|
19
|
-
//#endregion
|
|
17
|
+
export declare const composeRefs: <T>(...refs: (React$1.Ref<T> | undefined)[]) => ((node: T | null) => (() => void) | undefined);
|
package/dist/lib/utils.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { clsx } from "clsx";
|
|
2
2
|
import { twMerge } from "tailwind-merge";
|
|
3
|
-
|
|
3
|
+
// src/lib/utils.ts
|
|
4
4
|
function cn(...inputs) {
|
|
5
5
|
return twMerge(clsx(inputs));
|
|
6
6
|
}
|
|
@@ -37,5 +37,4 @@ const composeRefs = (...refs) => (node) => {
|
|
|
37
37
|
for (const cleanup of cleanups) cleanup();
|
|
38
38
|
};
|
|
39
39
|
};
|
|
40
|
-
//#endregion
|
|
41
40
|
export { cn, composeRefs };
|
package/dist/lib/week.d.ts
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
//#region src/lib/week.d.ts
|
|
2
1
|
/**
|
|
3
2
|
* Locale week data (first weekday, weekend) derived from CLDR via Intl.
|
|
4
3
|
* Shared so the app shell and the date picker resolve week starts identically.
|
|
@@ -20,5 +19,4 @@ export declare const getFirstWeekday: (locale: string) => number;
|
|
|
20
19
|
* Saturday/Sunday across the West, Friday/Saturday across much of the Gulf.
|
|
21
20
|
* Falls back to Saturday/Sunday when the runtime lacks week info.
|
|
22
21
|
*/
|
|
23
|
-
export declare const getWeekendDays: (locale: string) => ReadonlySet<number>;
|
|
24
|
-
//#endregion
|
|
22
|
+
export declare const getWeekendDays: (locale: string) => ReadonlySet<number>;
|
package/dist/lib/week.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
// src/lib/week.ts
|
|
2
2
|
/**
|
|
3
3
|
* Locale week data (first weekday, weekend) derived from CLDR via Intl.
|
|
4
4
|
* Shared so the app shell and the date picker resolve week starts identically.
|
|
@@ -38,5 +38,4 @@ const getWeekendDays = (locale) => {
|
|
|
38
38
|
if (weekend && weekend.length > 0) return new Set(weekend.map((day) => day % 7));
|
|
39
39
|
return /* @__PURE__ */ new Set([0, 6]);
|
|
40
40
|
};
|
|
41
|
-
//#endregion
|
|
42
41
|
export { getFirstWeekday, getLocaleWeekInfo, getWeekendDays };
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { Avatar } from "../components/avatar.js";
|
|
2
2
|
import { ComponentProps } from "react";
|
|
3
|
-
//#region src/review/review-author-avatar.d.ts
|
|
4
3
|
/**
|
|
5
4
|
* Shown when an author has neither a name nor anything to fall back on. This
|
|
6
5
|
* package carries no catalogs, so a localized host passes `fallbackLabel`;
|
|
@@ -19,5 +18,4 @@ type ReviewAuthorAvatarProps = Omit<ComponentProps<typeof Avatar>, "children" |
|
|
|
19
18
|
/** The author's face on any review surface: image when there is one, initials
|
|
20
19
|
* otherwise, dimmed once the account is gone. */
|
|
21
20
|
export declare const ReviewAuthorAvatar: ({ deleted, image, name, fallbackLabel, className, fallbackClassName, ...avatarProps }: ReviewAuthorAvatarProps) => import("react").JSX.Element;
|
|
22
|
-
//#endregion
|
|
23
21
|
export {};
|
|
@@ -2,7 +2,7 @@ import { cn } from "../lib/utils.js";
|
|
|
2
2
|
import { Avatar, AvatarFallback, AvatarImage } from "../components/avatar.js";
|
|
3
3
|
import { getInitials } from "../lib/initials.js";
|
|
4
4
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
5
|
-
|
|
5
|
+
// src/review/review-author-avatar.tsx
|
|
6
6
|
/**
|
|
7
7
|
* Shown when an author has neither a name nor anything to fall back on. This
|
|
8
8
|
* package carries no catalogs, so a localized host passes `fallbackLabel`;
|
|
@@ -26,5 +26,4 @@ const ReviewAuthorAvatar = ({ deleted = false, image, name, fallbackLabel = UNKN
|
|
|
26
26
|
})]
|
|
27
27
|
});
|
|
28
28
|
};
|
|
29
|
-
//#endregion
|
|
30
29
|
export { ReviewAuthorAvatar, UNKNOWN_AUTHOR_LABEL };
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { ReactNode } from "react";
|
|
2
|
-
//#region src/review/review-comment-card.d.ts
|
|
3
2
|
export type ReviewCommentAuthor = {
|
|
4
3
|
name: string | null;
|
|
5
4
|
image?: string | null | undefined;
|
|
@@ -29,5 +28,4 @@ type ReviewCommentCardProps = {
|
|
|
29
28
|
/** One comment on a reviewed surface: who wrote it, when, what it says, what
|
|
30
29
|
* it points at, and the two things a reader can do to it. */
|
|
31
30
|
export declare const ReviewCommentCard: ({ author, timestamp, formattedTime, body, anchorText, isStale, staleLabel, resolved, onToggleResolved, resolveLabel, reopenLabel, canDelete, onDelete, deleteLabel, className }: ReviewCommentCardProps) => import("react").JSX.Element;
|
|
32
|
-
//#endregion
|
|
33
31
|
export {};
|
|
@@ -5,7 +5,7 @@ import { Button } from "../components/button.js";
|
|
|
5
5
|
import { ReviewAuthorAvatar } from "./review-author-avatar.js";
|
|
6
6
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
7
7
|
import { Temporal } from "temporal-polyfill/full";
|
|
8
|
-
|
|
8
|
+
// src/review/review-comment-card.tsx
|
|
9
9
|
/** One comment on a reviewed surface: who wrote it, when, what it says, what
|
|
10
10
|
* it points at, and the two things a reader can do to it. */
|
|
11
11
|
const ReviewCommentCard = ({ author, timestamp, formattedTime, body, anchorText, isStale = false, staleLabel, resolved = false, onToggleResolved, resolveLabel, reopenLabel, canDelete = false, onDelete, deleteLabel, className }) => /* @__PURE__ */ jsxs("article", {
|
|
@@ -73,5 +73,4 @@ const toIsoInstant = (timestamp) => {
|
|
|
73
73
|
if (typeof timestamp === "string") return timestamp;
|
|
74
74
|
return Number.isNaN(timestamp.getTime()) ? void 0 : Temporal.Instant.fromEpochMilliseconds(timestamp.getTime()).toString({ fractionalSecondDigits: 3 });
|
|
75
75
|
};
|
|
76
|
-
//#endregion
|
|
77
76
|
export { ReviewCommentCard };
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { ReactNode } from "react";
|
|
2
|
-
//#region src/review/review-decision-actions.d.ts
|
|
3
2
|
/**
|
|
4
3
|
* Where a reviewable item stands. Undecided items offer accept/reject;
|
|
5
4
|
* decided ones offer the way back (revert the applied change, or reopen the
|
|
@@ -28,5 +27,4 @@ type ReviewDecisionActionsProps = {
|
|
|
28
27
|
};
|
|
29
28
|
/** Accept / reject / revert / reopen, in one shape, for every review surface. */
|
|
30
29
|
export declare const ReviewDecisionActions: ({ state, onAccept, onReject, onRevert, onReopen, size, acceptLabel, rejectLabel, revertLabel, reopenLabel, acceptTooltip, rejectTooltip, disabled, className }: ReviewDecisionActionsProps) => import("react").JSX.Element | null;
|
|
31
|
-
//#endregion
|
|
32
30
|
export {};
|
|
@@ -3,7 +3,7 @@ import { cn } from "../lib/utils.js";
|
|
|
3
3
|
import { Button } from "../components/button.js";
|
|
4
4
|
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
5
5
|
import { panic } from "better-result";
|
|
6
|
-
|
|
6
|
+
// src/review/review-decision-actions.tsx
|
|
7
7
|
/** Accept / reject / revert / reopen, in one shape, for every review surface. */
|
|
8
8
|
const ReviewDecisionActions = ({ state, onAccept, onReject, onRevert, onReopen, size = "sm", acceptLabel, rejectLabel, revertLabel, reopenLabel, acceptTooltip, rejectTooltip, disabled = false, className }) => {
|
|
9
9
|
const controls = renderControls({
|
|
@@ -70,5 +70,4 @@ const renderControls = ({ acceptLabel, acceptTooltip, disabled, onAccept, onReje
|
|
|
70
70
|
default: return panic(`Unhandled state: ${String(state)}`);
|
|
71
71
|
}
|
|
72
72
|
};
|
|
73
|
-
//#endregion
|
|
74
73
|
export { ReviewDecisionActions };
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { CSSProperties, ReactNode } from "react";
|
|
2
|
-
//#region src/review/review-diff-text.d.ts
|
|
3
2
|
export declare const TRACKED_DELETION_STYLE: CSSProperties;
|
|
4
3
|
export declare const TRACKED_INSERTION_STYLE: CSSProperties;
|
|
5
4
|
export type ReviewDiffSegmentType = "equal" | "insert" | "delete";
|
|
@@ -29,5 +28,4 @@ export declare const ReviewDiffText: ({ segments, className }: ReviewDiffTextPro
|
|
|
29
28
|
* never falls back to the array index.
|
|
30
29
|
*/
|
|
31
30
|
export declare const reviewDiffSegmentKeys: (segments: readonly ReviewDiffSegment[]) => string[];
|
|
32
|
-
//#endregion
|
|
33
31
|
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { cn } from "../lib/utils.js";
|
|
2
2
|
import { jsx } from "react/jsx-runtime";
|
|
3
3
|
import { panic } from "better-result";
|
|
4
|
-
|
|
4
|
+
// src/review/review-diff-text.tsx
|
|
5
5
|
const TRACKED_DELETION_STYLE = {
|
|
6
6
|
color: "color-mix(in oklch, var(--destructive) 35%, var(--muted-foreground))",
|
|
7
7
|
textDecorationLine: "line-through",
|
|
@@ -64,5 +64,4 @@ const ReviewDiffSegmentSpan = ({ segment }) => {
|
|
|
64
64
|
return panic(`Unhandled type: ${String(segment.type)}`);
|
|
65
65
|
}
|
|
66
66
|
};
|
|
67
|
-
//#endregion
|
|
68
67
|
export { ReviewDiffDeletion, ReviewDiffInsertion, ReviewDiffText, TRACKED_DELETION_STYLE, TRACKED_INSERTION_STYLE, reviewDiffSegmentKeys };
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { ReactNode } from "react";
|
|
2
|
-
//#region src/review/review-out-of-date-notice.d.ts
|
|
3
2
|
export type ReviewOutOfDateTone = "warning" | "muted";
|
|
4
3
|
/**
|
|
5
4
|
* One reason a review has fallen behind. Carries its own key so the list is
|
|
@@ -24,5 +23,4 @@ type ReviewOutOfDateNoticeProps = {
|
|
|
24
23
|
* through findings should see each one rather than the first.
|
|
25
24
|
*/
|
|
26
25
|
export declare const ReviewOutOfDateNotice: ({ reasons, actionLabel, onAction, tone, className }: ReviewOutOfDateNoticeProps) => import("react").JSX.Element | null;
|
|
27
|
-
//#endregion
|
|
28
26
|
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { cn } from "../lib/utils.js";
|
|
2
2
|
import { Button } from "../components/button.js";
|
|
3
3
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
4
|
-
|
|
4
|
+
// src/review/review-out-of-date-notice.tsx
|
|
5
5
|
/**
|
|
6
6
|
* What a review no longer reflects. Every applicable reason is listed
|
|
7
7
|
* together: they are different reasons to run again, and a reviewer working
|
|
@@ -28,5 +28,4 @@ const TONE_CLASS = {
|
|
|
28
28
|
warning: "border-warning/30 bg-warning/10 text-warning-foreground",
|
|
29
29
|
muted: "border-border bg-muted/50 text-muted-foreground"
|
|
30
30
|
};
|
|
31
|
-
//#endregion
|
|
32
31
|
export { ReviewOutOfDateNotice };
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { ReviewStatusTone } from "./review-status-badge.js";
|
|
2
|
-
//#region src/review/review-severity-dot.d.ts
|
|
3
2
|
/**
|
|
4
3
|
* How bad a finding is, on the one scale every review surface reports against.
|
|
5
4
|
* Vocabularies that stop short of five levels (a playbook's blocker/high/
|
|
@@ -23,5 +22,4 @@ type ReviewStatusDotProps = {
|
|
|
23
22
|
export declare const ReviewStatusDot: ({ tone, className }: ReviewStatusDotProps) => import("react").JSX.Element;
|
|
24
23
|
/** The tone a severity level carries, so a badge and its dot cannot disagree. */
|
|
25
24
|
export declare const reviewSeverityTone: (level: ReviewSeverityLevel) => ReviewStatusTone;
|
|
26
|
-
//#endregion
|
|
27
25
|
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { cn } from "../lib/utils.js";
|
|
2
2
|
import { jsx } from "react/jsx-runtime";
|
|
3
|
-
|
|
3
|
+
// src/review/review-severity-dot.tsx
|
|
4
4
|
/** The dot that precedes a severity label, and the one place a severity level
|
|
5
5
|
* turns into a colour. */
|
|
6
6
|
const ReviewSeverityDot = ({ level, className }) => /* @__PURE__ */ jsx(ReviewStatusDot, {
|
|
@@ -31,5 +31,4 @@ const TONE_DOT_CLASS = {
|
|
|
31
31
|
destructive: "bg-destructive",
|
|
32
32
|
highlight: "bg-highlight-foreground"
|
|
33
33
|
};
|
|
34
|
-
//#endregion
|
|
35
34
|
export { ReviewSeverityDot, ReviewStatusDot, reviewSeverityTone };
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { ReactNode } from "react";
|
|
2
|
-
//#region src/review/review-status-badge.d.ts
|
|
3
2
|
/**
|
|
4
3
|
* The semantic weight of a review status, independent of the words a surface
|
|
5
4
|
* uses for it. Playbook verdicts, overall risk, proposal states, suggestion
|
|
@@ -26,5 +25,4 @@ type ReviewStatusBadgeProps = {
|
|
|
26
25
|
/** One status pill for every review surface: one radius, one padding scale,
|
|
27
26
|
* one tone vocabulary. */
|
|
28
27
|
export declare const ReviewStatusBadge: ({ tone, variant, size, icon, className, children }: ReviewStatusBadgeProps) => import("react").JSX.Element;
|
|
29
|
-
//#endregion
|
|
30
28
|
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { cn } from "../lib/utils.js";
|
|
2
2
|
import { jsxs } from "react/jsx-runtime";
|
|
3
|
-
|
|
3
|
+
// src/review/review-status-badge.tsx
|
|
4
4
|
/** One status pill for every review surface: one radius, one padding scale,
|
|
5
5
|
* one tone vocabulary. */
|
|
6
6
|
const ReviewStatusBadge = ({ tone, variant = "outline", size = "xs", icon, className, children }) => /* @__PURE__ */ jsxs("span", {
|
|
@@ -41,5 +41,4 @@ const VARIANT_CLASS = {
|
|
|
41
41
|
solid: "",
|
|
42
42
|
strong: "[&_[data-slot=review-status-dot]]:bg-current"
|
|
43
43
|
};
|
|
44
|
-
//#endregion
|
|
45
44
|
export { ReviewStatusBadge };
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
//#region src/review/review-word-diff.d.ts
|
|
2
1
|
/**
|
|
3
2
|
* Tiny word-level LCS differ for the aligned-pair language view. Tokens are
|
|
4
3
|
* words and whitespace runs, so equal spacing collapses into "equal" ops and
|
|
@@ -9,5 +8,4 @@ export type WordDiffOp = {
|
|
|
9
8
|
token: string;
|
|
10
9
|
};
|
|
11
10
|
/** Diffs `before` (standard wording) against `after` (target wording). */
|
|
12
|
-
export declare const diffWords: (before: string, after: string) => WordDiffOp[];
|
|
13
|
-
//#endregion
|
|
11
|
+
export declare const diffWords: (before: string, after: string) => WordDiffOp[];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
// src/review/review-word-diff.ts
|
|
2
2
|
const tokenize = (text) => text.split(/(\s+)/u).filter((token) => token.length > 0);
|
|
3
3
|
const MAX_LCS_CELLS = 25e4;
|
|
4
4
|
/** Diffs `before` (standard wording) against `after` (target wording). */
|
|
@@ -74,5 +74,4 @@ const backtrack = (a, b, lengths) => {
|
|
|
74
74
|
});
|
|
75
75
|
return ops;
|
|
76
76
|
};
|
|
77
|
-
//#endregion
|
|
78
77
|
export { diffWords };
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { ComponentProps } from "react";
|
|
2
|
-
//#region src/review/text-mark.d.ts
|
|
3
2
|
/**
|
|
4
3
|
* One mark for words in running text: a search or find hit, a reader's own
|
|
5
4
|
* highlight, a verdict under a claim. Every surface that points at words
|
|
@@ -83,5 +82,4 @@ type TextMarkHighlightRuleOptions = {
|
|
|
83
82
|
* wash alone.
|
|
84
83
|
*/
|
|
85
84
|
export declare const textMarkHighlightRule: ({ name, variant, tone, state }: TextMarkHighlightRuleOptions) => string;
|
|
86
|
-
//#endregion
|
|
87
85
|
export {};
|
package/dist/review/text-mark.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { cn } from "../lib/utils.js";
|
|
2
2
|
import { jsx } from "react/jsx-runtime";
|
|
3
|
-
|
|
3
|
+
// src/review/text-mark.tsx
|
|
4
4
|
/**
|
|
5
5
|
* One mark for words in running text: a search or find hit, a reader's own
|
|
6
6
|
* highlight, a verdict under a claim. Every surface that points at words
|
|
@@ -180,5 +180,4 @@ const WEIGHT_CLASS = {
|
|
|
180
180
|
inherit: "",
|
|
181
181
|
medium: "font-medium"
|
|
182
182
|
};
|
|
183
|
-
//#endregion
|
|
184
183
|
export { SEARCH_HIT_DESCENDANT_MARK_CLASS, SEARCH_HIT_MARK, TEXT_MARK_TONE_COLOR, TextMark, textMarkBoxClass, textMarkClass, textMarkHighlightRule };
|
package/dist/styles/theme.css
CHANGED
|
@@ -15,6 +15,7 @@
|
|
|
15
15
|
* is already in scope (the palettes derive from `--color-*-500`).
|
|
16
16
|
*/
|
|
17
17
|
@import "./inline-rename.css";
|
|
18
|
+
@import "../components/animated-preview.css";
|
|
18
19
|
|
|
19
20
|
@custom-variant dark (&:is(.dark *));
|
|
20
21
|
|
|
@@ -1393,3 +1394,29 @@
|
|
|
1393
1394
|
display: none;
|
|
1394
1395
|
}
|
|
1395
1396
|
}
|
|
1397
|
+
|
|
1398
|
+
/* ---- Screen and elevation accents, the same in every palette ----
|
|
1399
|
+
* The tint the sign-in and error screens fade into, and a cool near-black for
|
|
1400
|
+
* the shadows of cards floating over light surfaces. */
|
|
1401
|
+
:root {
|
|
1402
|
+
--auth-gradient-end: #cbe1fc;
|
|
1403
|
+
--error-gradient-end: #fbe9e4;
|
|
1404
|
+
--shadow-tint: rgb(23 28 38);
|
|
1405
|
+
}
|
|
1406
|
+
|
|
1407
|
+
.dark {
|
|
1408
|
+
--auth-gradient-end: #1a3a5c;
|
|
1409
|
+
--error-gradient-end: #261815;
|
|
1410
|
+
}
|
|
1411
|
+
|
|
1412
|
+
/* A category's tile takes its hue from the category (`--cat-hue`, set inline);
|
|
1413
|
+
* the lightness and chroma are fixed per colour scheme. */
|
|
1414
|
+
@utility category-tile {
|
|
1415
|
+
background-color: oklch(0.94 0.045 var(--cat-hue));
|
|
1416
|
+
color: oklch(0.45 0.13 var(--cat-hue));
|
|
1417
|
+
|
|
1418
|
+
@variant dark {
|
|
1419
|
+
background-color: oklch(0.32 0.05 var(--cat-hue));
|
|
1420
|
+
color: oklch(0.85 0.11 var(--cat-hue));
|
|
1421
|
+
}
|
|
1422
|
+
}
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import { Page } from "@playwright/test";
|
|
2
|
-
//#region src/testing/browser-clock.d.ts
|
|
3
2
|
/** Keep native and polyfilled Temporal on Playwright's controlled page clock. */
|
|
4
3
|
export declare const setFixedBrowserTime: (page: Page, time: Date | number | string) => Promise<void>;
|
|
5
4
|
/** Install advancing time and keep native Temporal on the same clock. */
|
|
6
|
-
export declare const installBrowserClock: (page: Page, time: Date | number | string) => Promise<void>;
|
|
7
|
-
//#endregion
|
|
5
|
+
export declare const installBrowserClock: (page: Page, time: Date | number | string) => Promise<void>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
// src/testing/browser-clock.ts
|
|
2
2
|
const TEMPORAL_CLOCK_INIT = `
|
|
3
3
|
{
|
|
4
4
|
const temporal = globalThis.Temporal;
|
|
@@ -37,5 +37,4 @@ const installBrowserClock = async (page, time) => {
|
|
|
37
37
|
await page.clock.install({ time });
|
|
38
38
|
await page.addInitScript({ content: TEMPORAL_CLOCK_INIT });
|
|
39
39
|
};
|
|
40
|
-
//#endregion
|
|
41
40
|
export { installBrowserClock, setFixedBrowserTime };
|