cursedbelt 5.55.0 → 5.55.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/react/activity-bar/ActivityBar.js +1 -1
- package/dist/react/activity-bar/ActivityBar.js.map +1 -1
- package/dist/react/charts/HeatmapChart.js +1 -1
- package/dist/react/charts/HeatmapChart.js.map +1 -1
- package/dist/react/charts/IntervalTimeline.js +1 -1
- package/dist/react/charts/IntervalTimeline.js.map +1 -1
- package/dist/react/components/AddItemsMenu.js +1 -1
- package/dist/react/components/AddItemsMenu.js.map +1 -1
- package/dist/react/components/Button.js +1 -1
- package/dist/react/components/Button.js.map +1 -1
- package/dist/react/components/Collapsible.js +1 -1
- package/dist/react/components/Collapsible.js.map +1 -1
- package/dist/react/components/DataTable/ColumnChecklist.js +1 -1
- package/dist/react/components/DataTable/ColumnChecklist.js.map +1 -1
- package/dist/react/components/DataTable/SortStack.js +1 -1
- package/dist/react/components/DataTable/SortStack.js.map +1 -1
- package/dist/react/components/DataTable/TableFilterBuilder.js +1 -1
- package/dist/react/components/DataTable/TableFilterBuilder.js.map +1 -1
- package/dist/react/components/DatePicker.js +1 -1
- package/dist/react/components/DatePicker.js.map +1 -1
- package/dist/react/components/DateRangePicker.js +1 -1
- package/dist/react/components/DateRangePicker.js.map +1 -1
- package/dist/react/components/DisclosureButton.js +1 -1
- package/dist/react/components/DisclosureButton.js.map +1 -1
- package/dist/react/components/DragHandle.js +1 -1
- package/dist/react/components/DragHandle.js.map +1 -1
- package/dist/react/components/EmojiField.js +1 -1
- package/dist/react/components/EmojiField.js.map +1 -1
- package/dist/react/components/ExpandableRow.js +1 -1
- package/dist/react/components/ExpandableRow.js.map +1 -1
- package/dist/react/components/InlineEditableText.js +1 -1
- package/dist/react/components/InlineEditableText.js.map +1 -1
- package/dist/react/components/Menu.js +1 -1
- package/dist/react/components/Menu.js.map +1 -1
- package/dist/react/components/RatingField.js +1 -1
- package/dist/react/components/RatingField.js.map +1 -1
- package/dist/react/components/ReactionBar.js +1 -1
- package/dist/react/components/ReactionBar.js.map +1 -1
- package/dist/react/components/RevealAction.js +1 -1
- package/dist/react/components/RevealAction.js.map +1 -1
- package/dist/react/components/SelectableRow.js +1 -1
- package/dist/react/components/SelectableRow.js.map +1 -1
- package/dist/react/components/StarRating.js +1 -1
- package/dist/react/components/StarRating.js.map +1 -1
- package/dist/react/components/TooltipImpl.js +1 -1
- package/dist/react/components/TooltipImpl.js.map +1 -1
- package/dist/react/components/TreeView.js +1 -1
- package/dist/react/components/TreeView.js.map +1 -1
- package/dist/react/components/UnstyledButton.js +1 -1
- package/dist/react/components/UnstyledButton.js.map +1 -1
- package/dist/react/components/calendar/EventChip.js +1 -1
- package/dist/react/components/calendar/EventChip.js.map +1 -1
- package/dist/react/components/sharing/RecipientPicker.js +1 -1
- package/dist/react/components/sharing/RecipientPicker.js.map +1 -1
- package/dist/react/emoji/EmojiAutocomplete.js +1 -1
- package/dist/react/emoji/EmojiAutocomplete.js.map +1 -1
- package/dist/react/file-tree/FileTree.js +1 -1
- package/dist/react/file-tree/FileTree.js.map +1 -1
- package/dist/react/filter-rail/FilterRail.js +1 -1
- package/dist/react/filter-rail/FilterRail.js.map +1 -1
- package/dist/react/filter-rail/RailSection.js +1 -1
- package/dist/react/filter-rail/RailSection.js.map +1 -1
- package/dist/react/folder-tree/FolderPicker.js +1 -1
- package/dist/react/folder-tree/FolderPicker.js.map +1 -1
- package/dist/react/folder-tree/FolderTreeRail.js +1 -1
- package/dist/react/folder-tree/FolderTreeRail.js.map +1 -1
- package/dist/react/hooks/useScrollMemory.d.ts +5 -0
- package/dist/react/hooks/useScrollMemory.d.ts.map +1 -1
- package/dist/react/hooks/useScrollMemory.js +48 -23
- package/dist/react/hooks/useScrollMemory.js.map +1 -1
- package/dist/react/layoutEngine/NodeInspector.js +1 -1
- package/dist/react/layoutEngine/NodeInspector.js.map +1 -1
- package/dist/react/lib/daypicker.js +1 -1
- package/dist/react/lib/daypicker.js.map +1 -1
- package/dist/react/master-detail/MasterDetail.js +1 -1
- package/dist/react/master-detail/MasterDetail.js.map +1 -1
- package/dist/react/master-lock/MasterLockProvider.js +1 -1
- package/dist/react/master-lock/MasterLockProvider.js.map +1 -1
- package/dist/react/media/DenseGalleryShell.js +1 -1
- package/dist/react/media/DenseGalleryShell.js.map +1 -1
- package/dist/react/media/FocusViewer.js +1 -1
- package/dist/react/media/FocusViewer.js.map +1 -1
- package/dist/react/media/FrameGrabber.js +1 -1
- package/dist/react/media/FrameGrabber.js.map +1 -1
- package/dist/react/media/HoverScrubVideoThumb.js +1 -1
- package/dist/react/media/HoverScrubVideoThumb.js.map +1 -1
- package/dist/react/media/PictureEditor.js +1 -1
- package/dist/react/media/PictureEditor.js.map +1 -1
- package/dist/react/media/PlayerStrip.js +1 -1
- package/dist/react/media/PlayerStrip.js.map +1 -1
- package/dist/react/media/VideoChapterEditor.js +1 -1
- package/dist/react/media/VideoChapterEditor.js.map +1 -1
- package/dist/react/media/VideoCutEditor.js +1 -1
- package/dist/react/media/VideoCutEditor.js.map +1 -1
- package/dist/react/media/VideoTurner.js +1 -1
- package/dist/react/media/VideoTurner.js.map +1 -1
- package/dist/react/media/controlBar.js +1 -1
- package/dist/react/media/controlBar.js.map +1 -1
- package/dist/react/media-gallery/GalleryTable.js +1 -1
- package/dist/react/media-gallery/GalleryTable.js.map +1 -1
- package/dist/react/media-gallery/MediaGallery.js +1 -1
- package/dist/react/media-gallery/MediaGallery.js.map +1 -1
- package/dist/react/nav/BreadcrumbTrail.js +1 -1
- package/dist/react/nav/BreadcrumbTrail.js.map +1 -1
- package/dist/react/nav/HubTileGrid.js +1 -1
- package/dist/react/nav/HubTileGrid.js.map +1 -1
- package/dist/react/nav/SideNavCustomize.js +1 -1
- package/dist/react/nav/SideNavCustomize.js.map +1 -1
- package/dist/testing/designBaseline.d.ts +1 -1
- package/dist/testing/designBaseline.d.ts.map +1 -1
- package/dist/testing/designBaseline.js +1 -1
- package/dist/testing/designBaseline.js.map +1 -1
- package/package.json +1 -1
- package/src/react/activity-bar/ActivityBar.tsx +1 -1
- package/src/react/charts/HeatmapChart.tsx +1 -1
- package/src/react/charts/IntervalTimeline.tsx +1 -1
- package/src/react/components/AddItemsMenu.tsx +1 -1
- package/src/react/components/Button.tsx +1 -1
- package/src/react/components/Collapsible.tsx +1 -1
- package/src/react/components/DataTable/ColumnChecklist.tsx +1 -1
- package/src/react/components/DataTable/SortStack.tsx +1 -1
- package/src/react/components/DataTable/TableFilterBuilder.tsx +1 -1
- package/src/react/components/DatePicker.tsx +1 -1
- package/src/react/components/DateRangePicker.tsx +1 -1
- package/src/react/components/DisclosureButton.tsx +1 -1
- package/src/react/components/DragHandle.tsx +1 -1
- package/src/react/components/EmojiField.tsx +1 -1
- package/src/react/components/ExpandableRow.tsx +1 -1
- package/src/react/components/InlineEditableText.tsx +1 -1
- package/src/react/components/Menu.tsx +1 -1
- package/src/react/components/RatingField.tsx +1 -1
- package/src/react/components/ReactionBar.tsx +1 -1
- package/src/react/components/RevealAction.tsx +1 -1
- package/src/react/components/SelectableRow.tsx +1 -1
- package/src/react/components/StarRating.tsx +1 -1
- package/src/react/components/TooltipImpl.tsx +1 -1
- package/src/react/components/TreeView.tsx +1 -1
- package/src/react/components/UnstyledButton.tsx +1 -1
- package/src/react/components/calendar/EventChip.tsx +1 -1
- package/src/react/components/sharing/RecipientPicker.tsx +1 -1
- package/src/react/emoji/EmojiAutocomplete.tsx +1 -1
- package/src/react/file-tree/FileTree.tsx +1 -1
- package/src/react/filter-rail/FilterRail.tsx +1 -1
- package/src/react/filter-rail/RailSection.tsx +1 -1
- package/src/react/folder-tree/FolderPicker.tsx +1 -1
- package/src/react/folder-tree/FolderTreeRail.tsx +1 -1
- package/src/react/hooks/useScrollMemory.spec.tsx +46 -0
- package/src/react/hooks/useScrollMemory.ts +47 -20
- package/src/react/layoutEngine/NodeInspector.tsx +1 -1
- package/src/react/lib/daypicker.tsx +1 -1
- package/src/react/master-detail/MasterDetail.tsx +1 -1
- package/src/react/master-lock/MasterLockProvider.tsx +1 -1
- package/src/react/media/DenseGalleryShell.tsx +1 -1
- package/src/react/media/FocusViewer.tsx +1 -1
- package/src/react/media/FrameGrabber.tsx +1 -1
- package/src/react/media/HoverScrubVideoThumb.tsx +1 -1
- package/src/react/media/PictureEditor.tsx +1 -1
- package/src/react/media/PlayerStrip.tsx +1 -1
- package/src/react/media/VideoChapterEditor.tsx +1 -1
- package/src/react/media/VideoCutEditor.tsx +1 -1
- package/src/react/media/VideoTurner.tsx +1 -1
- package/src/react/media/controlBar.tsx +1 -1
- package/src/react/media-gallery/GalleryTable.tsx +1 -1
- package/src/react/media-gallery/MediaGallery.tsx +1 -1
- package/src/react/nav/BreadcrumbTrail.tsx +1 -1
- package/src/react/nav/HubTileGrid.tsx +1 -1
- package/src/react/nav/SideNavCustomize.tsx +1 -1
- package/src/relativeSpecifiersCarryJs.spec.ts +44 -0
- package/src/testing/designBaseline.ts +1 -1
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
* Plain `node:fs` and a plain `Error`, so it runs under `bun:test` and Node's Playwright alike.
|
|
19
19
|
*/
|
|
20
20
|
import { existsSync, readFileSync, writeFileSync } from 'node:fs';
|
|
21
|
-
import { auditDesign, DESIGN_RULES, formatDesignViolations, } from './designAudit';
|
|
21
|
+
import { auditDesign, DESIGN_RULES, formatDesignViolations, } from './designAudit.js';
|
|
22
22
|
/** The color-scheme store's key (cursedbelt-core `COLOR_SCHEME_STORAGE_KEY`), said here so the
|
|
23
23
|
* ledger stays free of a runtime import from the React half. */
|
|
24
24
|
const SCHEME_KEY = 'cwip.colorScheme';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"designBaseline.js","sourceRoot":"","sources":["../../src/testing/designBaseline.ts"],"names":[],"mappings":"AAAA,iGAAiG;AACjG,kGAAkG;AAClG,6FAA6F;AAC7F,8BAA8B;AAC9B;;;;;;;;;;;;;;GAcG;AACH,OAAO,EAAE,UAAU,EA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AAG,OAAO,CAAC,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,wBAAwB,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAC7E,CAAC;YACJ,CAAC;YACD,IAAI,OAAO,CAAC,IAAI,CAAC,MAAM,EAAE,CAAC;gBACxB,IAAI,IAAI,KAAK,OAAO,EAAE,CAAC;oBACrB,aAAa,CAAC,YAAY,EAAE,oBAAoB,CAAC,KAAK,CAAC,CAAC,CAAC;oBACzD,OAAO,OAAO,CAAC;gBACjB,CAAC;gBACD,MAAM,IAAI,KAAK,CACb,iBAAiB,OAAO,CAAC,IAAI,CAAC,MAAM,wBAAwB,YAAY,uEAAuE;oBAC7I,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,CAC5B,CAAC;YACJ,CAAC;YACD,OAAO,OAAO,CAAC;QACjB,CAAC;KACF,CAAC;AACJ,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "cursedbelt",
|
|
3
|
-
"version": "5.55.
|
|
3
|
+
"version": "5.55.2",
|
|
4
4
|
"license": "ISC",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"description": "The React design system of the cursedbelt split — components, styles, theme. cursedbelt-core below it; server tier in cursedbelt-server.",
|
|
@@ -3,7 +3,7 @@ import { cn } from '../lib/cn.js';
|
|
|
3
3
|
import { sequentialStep } from './categorical.js';
|
|
4
4
|
import { type ChartTokens, type ChartTone, toneColor, useChartTokens } from './tokens.js';
|
|
5
5
|
import { Tooltip } from '../components/Tooltip.js';
|
|
6
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
6
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
7
7
|
|
|
8
8
|
/** One cell. `value === null` means NO OBSERVATION — rendered distinctly from zero. */
|
|
9
9
|
export type HeatmapCell = {
|
|
@@ -3,7 +3,7 @@ import { concurrencyProfile } from 'cursedbelt-core/analytics/schedule';
|
|
|
3
3
|
import { Tooltip } from '../components/Tooltip.js';
|
|
4
4
|
import { cn } from '../lib/cn.js';
|
|
5
5
|
import { type ChartTone, toneColor, useChartTokens } from './tokens.js';
|
|
6
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
6
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
7
7
|
|
|
8
8
|
/** One thing that ran, or is planned to run, between two instants. */
|
|
9
9
|
export interface TimelineInterval {
|
|
@@ -3,7 +3,7 @@ import { type ReactNode, useState } from 'react';
|
|
|
3
3
|
import { cn } from '../lib/cn.js';
|
|
4
4
|
import { Button, type ButtonSize, type ButtonVariant } from './Button.js';
|
|
5
5
|
import { Popover } from './Popover.js';
|
|
6
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
6
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
7
7
|
|
|
8
8
|
export interface AddItemsGroup<T> {
|
|
9
9
|
/** Section heading; omit for an ungrouped flat list. */
|
|
@@ -14,7 +14,7 @@ import { toast } from 'sonner';
|
|
|
14
14
|
import { cn } from '../lib/cn.js';
|
|
15
15
|
import { Tooltip, type TooltipMobile, type TooltipPlacement } from './Tooltip.js';
|
|
16
16
|
import { TAP_TARGET_HEIGHT } from '../lib/tapTarget.js';
|
|
17
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
17
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
18
18
|
|
|
19
19
|
/**
|
|
20
20
|
* The single source of truth for every interactive element that triggers an action.
|
|
@@ -3,7 +3,7 @@ import { ChevronDown } from 'lucide-react';
|
|
|
3
3
|
import type { ReactNode } from 'react';
|
|
4
4
|
import { cn } from '../lib/cn.js';
|
|
5
5
|
import { TAP_TARGET_HEIGHT } from '../lib/tapTarget.js';
|
|
6
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
6
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
7
7
|
|
|
8
8
|
export interface CollapsibleProps {
|
|
9
9
|
/** The always-visible clickable header content (shown left of the chevron). */
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Check } from 'lucide-react';
|
|
2
2
|
import { cn } from '../../lib/cn.js';
|
|
3
3
|
import { TAP_TARGET_HEIGHT } from '../../lib/tapTarget.js';
|
|
4
|
-
import { RAW_BUTTON } from '../../lib/cn';
|
|
4
|
+
import { RAW_BUTTON } from '../../lib/cn.js';
|
|
5
5
|
|
|
6
6
|
export interface ColumnChecklistItem {
|
|
7
7
|
key: string;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { SortingState } from '@tanstack/react-table';
|
|
2
2
|
import { ArrowDown, ArrowUp, X } from 'lucide-react';
|
|
3
3
|
import { cn } from '../../lib/cn.js';
|
|
4
|
-
import { RAW_BUTTON } from '../../lib/cn';
|
|
4
|
+
import { RAW_BUTTON } from '../../lib/cn.js';
|
|
5
5
|
|
|
6
6
|
export interface SortStackProps {
|
|
7
7
|
sorting: SortingState;
|
|
@@ -18,7 +18,7 @@ import {
|
|
|
18
18
|
VALUELESS_OPS,
|
|
19
19
|
} from './filterQuery.js';
|
|
20
20
|
import { Surface } from '../Surface.js';
|
|
21
|
-
import { RAW_BUTTON } from '../../lib/cn';
|
|
21
|
+
import { RAW_BUTTON } from '../../lib/cn.js';
|
|
22
22
|
|
|
23
23
|
export interface TableFilterBuilderColumn {
|
|
24
24
|
key: string;
|
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
import { type ControlSize, declareFieldWidth, fieldControlClass } from '../lib/field.js';
|
|
15
15
|
import { Drawer } from './Drawer.js';
|
|
16
16
|
import { Popover } from './Popover.js';
|
|
17
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
17
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
18
18
|
|
|
19
19
|
export interface DatePickerProps {
|
|
20
20
|
/** ISO date string 'YYYY-MM-DD'. Empty string or undefined = no selection. */
|
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
import { type ControlSize, fieldControlClass } from '../lib/field.js';
|
|
15
15
|
import { Drawer } from './Drawer.js';
|
|
16
16
|
import { Popover } from './Popover.js';
|
|
17
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
17
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
18
18
|
|
|
19
19
|
/** A date range with optional start and end as ISO 'YYYY-MM-DD' strings. */
|
|
20
20
|
export interface DateRangeValue {
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
import { ChevronDown } from 'lucide-react';
|
|
6
6
|
import type { ReactNode } from 'react';
|
|
7
7
|
import { cn } from '../lib/cn.js';
|
|
8
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
8
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
9
9
|
|
|
10
10
|
export interface DisclosureArrowProps {
|
|
11
11
|
open: boolean;
|
|
@@ -4,7 +4,7 @@ import { cn } from '../lib/cn.js';
|
|
|
4
4
|
import { REVEAL_ON_HOVER } from './revealOnHover.js';
|
|
5
5
|
import { Tooltip } from './Tooltip.js';
|
|
6
6
|
import { TAP_TARGET } from '../lib/tapTarget.js';
|
|
7
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
7
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
8
8
|
|
|
9
9
|
export interface DragHandleProps {
|
|
10
10
|
/** Spread from a drag hook's `handleProps` — the pointer/keyboard drag wiring. */
|
|
@@ -2,7 +2,7 @@ import { useState } from 'react';
|
|
|
2
2
|
import { EmojiPicker } from '../emoji/EmojiPicker.js';
|
|
3
3
|
import { cn } from '../lib/cn.js';
|
|
4
4
|
import { TAP_TARGET } from '../lib/tapTarget.js';
|
|
5
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
5
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
6
6
|
|
|
7
7
|
export interface EmojiFieldProps {
|
|
8
8
|
/** The current emoji (a single grapheme), or '' for none. */
|
|
@@ -9,7 +9,7 @@ import {
|
|
|
9
9
|
} from 'react';
|
|
10
10
|
import { cn } from '../lib/cn.js';
|
|
11
11
|
import './formKit.css';
|
|
12
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
12
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
13
13
|
|
|
14
14
|
export interface ExpandableRowProps {
|
|
15
15
|
/** The row's identity — a name, or the input that edits it. Always visible. */
|
|
@@ -6,7 +6,7 @@ import { IconButton } from './IconButton.js';
|
|
|
6
6
|
import { Input } from './Input.js';
|
|
7
7
|
import { Tooltip } from './Tooltip.js';
|
|
8
8
|
import { TAP_TARGET_HEIGHT } from '../lib/tapTarget.js';
|
|
9
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
9
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
10
10
|
|
|
11
11
|
export interface InlineEditableTextProps {
|
|
12
12
|
value: string;
|
|
@@ -3,7 +3,7 @@ import { type KeyboardEvent, type ReactNode, useId } from 'react';
|
|
|
3
3
|
import { cn } from '../lib/cn.js';
|
|
4
4
|
import { TAP_TARGET_HEIGHT } from '../lib/tapTarget.js';
|
|
5
5
|
import { Tooltip } from './Tooltip.js';
|
|
6
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
6
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
7
7
|
|
|
8
8
|
/*
|
|
9
9
|
A menu that goes wherever its panel goes.
|
|
@@ -2,7 +2,7 @@ import { Star } from 'lucide-react';
|
|
|
2
2
|
import type { KeyboardEvent } from 'react';
|
|
3
3
|
import { cn } from '../lib/cn.js';
|
|
4
4
|
import { TAP_TARGET } from '../lib/tapTarget.js';
|
|
5
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
5
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
6
6
|
|
|
7
7
|
export interface RatingFieldProps {
|
|
8
8
|
/** The current rating (0 = unrated). */
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { cn } from '../lib/cn.js';
|
|
2
2
|
import { ReactionPicker } from './ReactionPicker.js';
|
|
3
3
|
import { Tooltip } from './Tooltip.js';
|
|
4
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
4
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
5
5
|
|
|
6
6
|
export interface ReactionGroup {
|
|
7
7
|
emoji: string;
|
|
@@ -2,7 +2,7 @@ import { Plus } from 'lucide-react';
|
|
|
2
2
|
import { type ReactNode, useEffect, useRef, useState } from 'react';
|
|
3
3
|
import { cn } from '../lib/cn.js';
|
|
4
4
|
import './formKit.css';
|
|
5
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
5
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
6
6
|
|
|
7
7
|
export interface RevealActionProps {
|
|
8
8
|
/** The door's words — *"Add conditional logic"*. Drawn after a `+`. */
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { ReactNode } from 'react';
|
|
2
2
|
import { cn } from '../lib/cn.js';
|
|
3
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
3
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
4
4
|
|
|
5
5
|
export interface SelectableRowProps {
|
|
6
6
|
/** Fired on click and on Enter/Space (a real `<button>` gives both for free). */
|
|
@@ -2,7 +2,7 @@ import { useId, useRef, useState } from 'react';
|
|
|
2
2
|
import { cn } from '../lib/cn.js';
|
|
3
3
|
import { Tooltip } from './Tooltip.js';
|
|
4
4
|
import { TAP_TARGET, TAP_TARGET_HEIGHT } from '../lib/tapTarget.js';
|
|
5
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
5
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* The fleet's one star rating.
|
|
@@ -7,7 +7,7 @@ import { useFloatingContainer } from '../lib/floatingContainer.js';
|
|
|
7
7
|
import { FLOATING_COLLISION_PADDING } from '../lib/floatingStyles.js';
|
|
8
8
|
import { HOVER_HINT_INSTANT_MS, useHoverHintDelay } from '../lib/hoverIntent.js';
|
|
9
9
|
import type { TooltipArm, TooltipProps } from './Tooltip.js';
|
|
10
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
10
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
11
11
|
|
|
12
12
|
/**
|
|
13
13
|
* The real, Radix-backed tooltip. 🔴 **Nothing imports this module directly** —
|
|
@@ -14,7 +14,7 @@ import type { DragItemApi } from '../hooks/dragShared.js';
|
|
|
14
14
|
import { useDragReorder } from '../hooks/useDragReorder.js';
|
|
15
15
|
import { cn } from '../lib/cn.js';
|
|
16
16
|
import { DragHandle } from './DragHandle.js';
|
|
17
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
17
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
18
18
|
|
|
19
19
|
// --- Public types ---------------------------------------------------------------
|
|
20
20
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { ButtonHTMLAttributes, KeyboardEvent, MouseEvent, ReactNode, Ref } from 'react';
|
|
2
2
|
import { Tooltip, type TooltipPlacement } from './Tooltip.js';
|
|
3
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
3
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
4
4
|
|
|
5
5
|
export interface UnstyledButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
6
6
|
/** Hover/focus hint, drawn by the belt's {@link Tooltip}. Optional: the caller's own look usually names the control. */
|
|
@@ -4,7 +4,7 @@ import { cn } from '../../lib/cn.js';
|
|
|
4
4
|
import { Tooltip } from '../Tooltip.js';
|
|
5
5
|
import { calendarColorClasses } from './colorUtils.js';
|
|
6
6
|
import type { CalendarEventBase } from './types.js';
|
|
7
|
-
import { RAW_BUTTON } from '../../lib/cn';
|
|
7
|
+
import { RAW_BUTTON } from '../../lib/cn.js';
|
|
8
8
|
|
|
9
9
|
export interface EventChipProps {
|
|
10
10
|
occurrence: Occurrence<CalendarEventBase>;
|
|
@@ -8,7 +8,7 @@ import { Input } from '../Input.js';
|
|
|
8
8
|
import { ScrollArea } from '../ScrollArea.js';
|
|
9
9
|
import { RecipientAvatar } from './RecipientAvatar.js';
|
|
10
10
|
import { recipientSubtitle, type ShareRecipient } from './types.js';
|
|
11
|
-
import { RAW_BUTTON } from '../../lib/cn';
|
|
11
|
+
import { RAW_BUTTON } from '../../lib/cn.js';
|
|
12
12
|
|
|
13
13
|
const DEBOUNCE_MS = 250;
|
|
14
14
|
|
|
@@ -2,7 +2,7 @@ import { autoUpdate, FloatingPortal, flip, offset, shift, useFloating } from '@f
|
|
|
2
2
|
import { type RefObject, useEffect, useRef, useState } from 'react';
|
|
3
3
|
import { cn } from '../lib/cn.js';
|
|
4
4
|
import { type EmojiSearchHit, searchEmojis } from './emojiSearch.js';
|
|
5
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
5
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
6
6
|
|
|
7
7
|
export interface EmojiAutocompleteProps {
|
|
8
8
|
/** The partial name AFTER the `:` trigger — e.g. "smi" for ":smi". Empty/falsy
|
|
@@ -208,7 +208,7 @@ import {
|
|
|
208
208
|
import type { TreePanelProps } from './FolderViewPanels.js';
|
|
209
209
|
import type { FolderView, FolderViewPoint } from './useFolderView.js';
|
|
210
210
|
import './fileTree.css';
|
|
211
|
-
import { cn, RAW_BUTTON } from '../lib/cn';
|
|
211
|
+
import { cn, RAW_BUTTON } from '../lib/cn.js';
|
|
212
212
|
|
|
213
213
|
/**
|
|
214
214
|
* The right-click panels — row menu, view menu, tag editor — fetched on demand. They reach
|
|
@@ -7,7 +7,7 @@ import { TAP_TARGET, TAP_TARGET_ALWAYS, TAP_TARGET_HEIGHT } from '../lib/tapTarg
|
|
|
7
7
|
import { RailResizeHandle, useRailResize } from './railResize.js';
|
|
8
8
|
import { type HeaderContextMenuHandler, useHeaderContextMenu } from './headerContextMenu.js';
|
|
9
9
|
import { RailSection } from './RailSection.js';
|
|
10
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
10
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
11
11
|
|
|
12
12
|
export interface FilterRailItem {
|
|
13
13
|
/** Stable key, and the value handed to `onSelect`. */
|
|
@@ -4,7 +4,7 @@ import { useRememberedPreference } from '../media-gallery/rememberedPreference.j
|
|
|
4
4
|
import { cn } from '../lib/cn.js';
|
|
5
5
|
import { TAP_TARGET_HEIGHT } from '../lib/tapTarget.js';
|
|
6
6
|
import { type HeaderContextMenuHandler, useHeaderContextMenu } from './headerContextMenu.js';
|
|
7
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
7
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
8
8
|
|
|
9
9
|
/**
|
|
10
10
|
* One named, collapsible group of a sidebar — "Library", "Playlists", "Tags", "Folders".
|
|
@@ -23,7 +23,7 @@ import { FolderBreadcrumb } from "./FolderBreadcrumb.js";
|
|
|
23
23
|
import { formatFolderPath, isValidFolderName, normalizeFolderName } from "cursedbelt-core/folder-tree/path";
|
|
24
24
|
import { type FolderNode, flattenFolderTree } from "cursedbelt-core/folder-tree/tree";
|
|
25
25
|
import { Surface } from "../components/Surface.js";
|
|
26
|
-
import { cn, RAW_BUTTON } from '../lib/cn';
|
|
26
|
+
import { cn, RAW_BUTTON } from '../lib/cn.js';
|
|
27
27
|
|
|
28
28
|
export interface FolderPickerProps {
|
|
29
29
|
/** The current derived tree (from the items' folder paths). */
|
|
@@ -35,7 +35,7 @@ import { ChevronRight } from 'lucide-react';
|
|
|
35
35
|
import { Tooltip } from '../components/Tooltip.js';
|
|
36
36
|
import { NewFolderControl } from './NewFolderControl.js';
|
|
37
37
|
import { TAP_TARGET_HEIGHT } from "../lib/tapTarget.js";
|
|
38
|
-
import { cn, RAW_BUTTON } from '../lib/cn';
|
|
38
|
+
import { cn, RAW_BUTTON } from '../lib/cn.js';
|
|
39
39
|
|
|
40
40
|
export interface FolderTreeRailProps {
|
|
41
41
|
nodes: readonly FolderNode[];
|
|
@@ -3,6 +3,9 @@ import { act, cleanup, fireEvent, render } from '@testing-library/react';
|
|
|
3
3
|
import { StrictMode } from 'react';
|
|
4
4
|
import { useScrollMemory } from './useScrollMemory.js';
|
|
5
5
|
|
|
6
|
+
/** `HOLD_MS` in the hook, and a margin — written out so this spec stands without the hold. */
|
|
7
|
+
const PAST_THE_HOLD_MS = 1_600;
|
|
8
|
+
|
|
6
9
|
afterEach(cleanup);
|
|
7
10
|
|
|
8
11
|
/**
|
|
@@ -118,6 +121,49 @@ describe('useScrollMemory', () => {
|
|
|
118
121
|
expect(s.el.scrollTop).toBe(500);
|
|
119
122
|
});
|
|
120
123
|
|
|
124
|
+
/**
|
|
125
|
+
* 🔴 forge task 2784: music's phone list came back from Lyrics on 12,343px and, 800ms later,
|
|
126
|
+
* sat 153px deeper — moved by a write that was not the viewer's. The hold puts it back.
|
|
127
|
+
*/
|
|
128
|
+
test('a late scroll the viewer did not make, just after the restore lands, is put back', () => {
|
|
129
|
+
const s = fakeScroller(20_000);
|
|
130
|
+
const { rerender } = render(<Shell at='/' el={s.el} />);
|
|
131
|
+
s.scrollTo(12_343);
|
|
132
|
+
const list = { state: window.history.state, path: '/' };
|
|
133
|
+
push('/lyrics');
|
|
134
|
+
rerender(<Shell at='/lyrics' el={s.el} />);
|
|
135
|
+
|
|
136
|
+
back(list);
|
|
137
|
+
rerender(<Shell at='/' el={s.el} />);
|
|
138
|
+
expect(s.el.scrollTop).toBe(12_343);
|
|
139
|
+
s.scrollTo(12_496); // the late move: no touch, wheel, key or pointer behind it
|
|
140
|
+
expect(s.el.scrollTop).toBe(12_343);
|
|
141
|
+
});
|
|
142
|
+
|
|
143
|
+
test('the hold yields to the viewer, and ends on its own', async () => {
|
|
144
|
+
const s = fakeScroller(20_000);
|
|
145
|
+
const { rerender } = render(<Shell at='/' el={s.el} />);
|
|
146
|
+
s.scrollTo(9_000);
|
|
147
|
+
const list = { state: window.history.state, path: '/' };
|
|
148
|
+
push('/item/7');
|
|
149
|
+
rerender(<Shell at='/item/7' el={s.el} />);
|
|
150
|
+
|
|
151
|
+
back(list);
|
|
152
|
+
rerender(<Shell at='/' el={s.el} />);
|
|
153
|
+
fireEvent.touchStart(window);
|
|
154
|
+
s.scrollTo(8_000); // the viewer's own scroll, inside the hold
|
|
155
|
+
expect(s.el.scrollTop).toBe(8_000);
|
|
156
|
+
|
|
157
|
+
push('/item/8');
|
|
158
|
+
rerender(<Shell at='/item/8' el={s.el} />);
|
|
159
|
+
back(list);
|
|
160
|
+
rerender(<Shell at='/' el={s.el} />);
|
|
161
|
+
expect(s.el.scrollTop).toBe(8_000);
|
|
162
|
+
await act(() => new Promise((r) => setTimeout(r, PAST_THE_HOLD_MS)));
|
|
163
|
+
s.scrollTo(3_000); // an app's own jump, after the hold — not undone
|
|
164
|
+
expect(s.el.scrollTop).toBe(3_000);
|
|
165
|
+
});
|
|
166
|
+
|
|
121
167
|
test('leaving mid-restore files the TARGET, not the shallow offset it had reached', async () => {
|
|
122
168
|
const s = fakeScroller(20_000);
|
|
123
169
|
const { rerender } = render(<Shell at='/' el={s.el} />);
|
|
@@ -28,6 +28,11 @@ import { type RefObject, useLayoutEffect, useRef } from 'react';
|
|
|
28
28
|
* until {@link ScrollMemoryOptions.deadlineMs}. Keep the list's pages across the trip
|
|
29
29
|
* (`usePagedList` does, through the query cache) and it lands in the first frame.
|
|
30
30
|
* - **The viewer always wins**: a touch, wheel, key or pointer press while it waits cancels it.
|
|
31
|
+
* - **Landed means landed.** For {@link HOLD_MS} after the restore reaches its target, a scroll
|
|
32
|
+
* the viewer did not make is put back. 🔴 music's phone list came back from Lyrics on 12,343px
|
|
33
|
+
* and sat at 12,496px 800ms later, about one gate run in 17 under load (forge task 2784) — a
|
|
34
|
+
* late write by something on the page (a virtualizer settling, the browser's scroll anchoring)
|
|
35
|
+
* that no instrumented run could catch in the act. Whatever writes it, the viewer's place wins.
|
|
31
36
|
* - **A replaced URL is the same place**: when the location changes but the history entry does
|
|
32
37
|
* not (a filter written with `replaceState`), the scroll is left alone.
|
|
33
38
|
*
|
|
@@ -93,14 +98,18 @@ function begin(
|
|
|
93
98
|
// the partial offset on screen — leaving mid-restore (or StrictMode's rehearsal unmount) must
|
|
94
99
|
// not overwrite a deep position with a shallow one.
|
|
95
100
|
let offset = scroller.get();
|
|
96
|
-
|
|
101
|
+
/** True until the restore has landed or given up — while it is, `offset` stays the target. */
|
|
102
|
+
let restoring = false;
|
|
103
|
+
/** Stops the restore, or the hold after it, reporting nothing. */
|
|
104
|
+
let stopRestore: (() => void) | null = null;
|
|
97
105
|
|
|
98
106
|
if (!replacedInPlace) {
|
|
99
107
|
const target = recalled(id);
|
|
100
108
|
if (target > 0) {
|
|
101
109
|
offset = target;
|
|
102
|
-
|
|
103
|
-
|
|
110
|
+
restoring = true;
|
|
111
|
+
stopRestore = restore(scroller, target, deadlineMs, (outcome) => {
|
|
112
|
+
restoring = false;
|
|
104
113
|
if (outcome !== 'reached') offset = scroller.get();
|
|
105
114
|
});
|
|
106
115
|
} else {
|
|
@@ -110,7 +119,7 @@ function begin(
|
|
|
110
119
|
}
|
|
111
120
|
|
|
112
121
|
const onScroll = () => {
|
|
113
|
-
if (!
|
|
122
|
+
if (!restoring) offset = scroller.get();
|
|
114
123
|
};
|
|
115
124
|
const onHide = () => file(id, offset);
|
|
116
125
|
scroller.events.addEventListener('scroll', onScroll, { passive: true });
|
|
@@ -119,9 +128,9 @@ function begin(
|
|
|
119
128
|
location,
|
|
120
129
|
target: scroller.events,
|
|
121
130
|
end() {
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
131
|
+
restoring = false;
|
|
132
|
+
stopRestore?.();
|
|
133
|
+
stopRestore = null;
|
|
125
134
|
scroller.events.removeEventListener('scroll', onScroll);
|
|
126
135
|
window.removeEventListener('pagehide', onHide);
|
|
127
136
|
file(id, offset);
|
|
@@ -150,6 +159,12 @@ export interface ScrollMemoryOptions {
|
|
|
150
159
|
}
|
|
151
160
|
|
|
152
161
|
const RESTORE_DEADLINE_MS = 3_000;
|
|
162
|
+
/**
|
|
163
|
+
* How long a landed restore holds its target against a scroll the viewer did not make. Long
|
|
164
|
+
* enough for a list to finish settling (the late move in forge task 2784 came inside 800ms, under
|
|
165
|
+
* load); short enough that an app's own jump a moment later is not undone.
|
|
166
|
+
*/
|
|
167
|
+
const HOLD_MS = 1_500;
|
|
153
168
|
const ENTRY_KEY = 'cbScrollEntry';
|
|
154
169
|
const STORE_KEY = 'cursedbelt:scroll-memory';
|
|
155
170
|
/** Entries kept in `sessionStorage` — a tab's history, not a cache; the oldest go first. */
|
|
@@ -246,7 +261,10 @@ function file(id: string, y: number): void {
|
|
|
246
261
|
|
|
247
262
|
type RestoreOutcome = 'reached' | 'input' | 'deadline';
|
|
248
263
|
|
|
249
|
-
/**
|
|
264
|
+
/**
|
|
265
|
+
* Scroll to `target` once there is room for it, then HOLD it for {@link HOLD_MS}; returns a
|
|
266
|
+
* cancel that reports nothing. `settled` is called once, when it lands or gives up.
|
|
267
|
+
*/
|
|
250
268
|
function restore(
|
|
251
269
|
scroller: Scroller,
|
|
252
270
|
target: number,
|
|
@@ -255,37 +273,46 @@ function restore(
|
|
|
255
273
|
): () => void {
|
|
256
274
|
const deadline = performance.now() + deadlineMs;
|
|
257
275
|
let frame = 0;
|
|
258
|
-
let
|
|
276
|
+
let holdTimer: ReturnType<typeof setTimeout> | undefined;
|
|
277
|
+
let phase: 'waiting' | 'holding' | 'done' = 'waiting';
|
|
259
278
|
|
|
260
|
-
const
|
|
261
|
-
|
|
262
|
-
done = true;
|
|
279
|
+
const finish = () => {
|
|
280
|
+
phase = 'done';
|
|
263
281
|
cancelAnimationFrame(frame);
|
|
282
|
+
clearTimeout(holdTimer);
|
|
264
283
|
for (const type of INPUT_EVENTS) window.removeEventListener(type, onInput);
|
|
265
|
-
|
|
284
|
+
scroller.events.removeEventListener('scroll', onStray);
|
|
266
285
|
};
|
|
267
286
|
const onInput = () => {
|
|
268
|
-
|
|
287
|
+
const was = phase;
|
|
288
|
+
finish();
|
|
289
|
+
if (was === 'waiting') settled('input');
|
|
290
|
+
};
|
|
291
|
+
// Landed, and something that is not the viewer moved it: put it back.
|
|
292
|
+
const onStray = () => {
|
|
293
|
+
if (phase === 'holding' && Math.abs(scroller.get() - target) > 1) scroller.set(target);
|
|
269
294
|
};
|
|
270
295
|
|
|
271
296
|
const attempt = () => {
|
|
272
|
-
if (
|
|
297
|
+
if (phase !== 'waiting') return;
|
|
273
298
|
const room = scroller.room();
|
|
274
299
|
if (room >= target) {
|
|
275
300
|
scroller.set(target);
|
|
276
|
-
|
|
301
|
+
phase = 'holding';
|
|
302
|
+
scroller.events.addEventListener('scroll', onStray, { passive: true });
|
|
303
|
+
holdTimer = setTimeout(finish, HOLD_MS);
|
|
304
|
+
settled('reached');
|
|
277
305
|
return;
|
|
278
306
|
}
|
|
279
307
|
// Short of it: go as far as the page allows — that is what asks an infinite list for more.
|
|
280
308
|
scroller.set(Math.max(0, room));
|
|
281
309
|
if (performance.now() >= deadline) {
|
|
282
|
-
|
|
310
|
+
finish();
|
|
311
|
+
settled('deadline');
|
|
283
312
|
} else frame = requestAnimationFrame(attempt);
|
|
284
313
|
};
|
|
285
314
|
|
|
286
315
|
for (const type of INPUT_EVENTS) window.addEventListener(type, onInput, { passive: true });
|
|
287
316
|
attempt();
|
|
288
|
-
return
|
|
289
|
-
stop();
|
|
290
|
-
};
|
|
317
|
+
return finish;
|
|
291
318
|
}
|
|
@@ -19,7 +19,7 @@ import type { BindingResolver } from './LayoutRenderer.js';
|
|
|
19
19
|
import { compatibleWidgets, widgetDef } from './registry.js';
|
|
20
20
|
import type { WidgetRegistry } from './types.js';
|
|
21
21
|
import { Surface } from '../components/Surface.js';
|
|
22
|
-
import { RAW_BUTTON } from '../lib/cn';
|
|
22
|
+
import { RAW_BUTTON } from '../lib/cn.js';
|
|
23
23
|
|
|
24
24
|
// The property panel for the selected node — rebuilt for NON-TECHNICAL editing. The
|
|
25
25
|
// primary layer answers "what should this block look like?" in plain language: pick a
|
|
@@ -3,7 +3,7 @@ import { formatDateLocal, formatDateRangeLocal } from 'cwip/date';
|
|
|
3
3
|
import { ChevronLeft, ChevronRight } from 'lucide-react';
|
|
4
4
|
import type { SVGProps } from 'react';
|
|
5
5
|
import { cn } from './cn.js';
|
|
6
|
-
import { RAW_BUTTON } from './cn';
|
|
6
|
+
import { RAW_BUTTON } from './cn.js';
|
|
7
7
|
|
|
8
8
|
/**
|
|
9
9
|
* Token-themed classNames for DayPicker v10 — maps UI elements to Tailwind utilities
|
|
@@ -35,7 +35,7 @@ import { EmptyState } from "../components/EmptyState.js";
|
|
|
35
35
|
import { Input } from "../components/Input.js";
|
|
36
36
|
import { ScrollArea } from "../components/ScrollArea.js";
|
|
37
37
|
import { SplitPane } from "../components/SplitPane.js";
|
|
38
|
-
import { cn, RAW_BUTTON } from '../lib/cn';
|
|
38
|
+
import { cn, RAW_BUTTON } from '../lib/cn.js';
|
|
39
39
|
|
|
40
40
|
export interface MasterDetailItem {
|
|
41
41
|
id: string;
|