@kolkrabbi/kol-component 0.379.0 → 0.381.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.
Files changed (65) hide show
  1. package/package.json +4 -4
  2. package/src/atoms/Badge.jsx +1 -5
  3. package/src/atoms/Button.jsx +4 -11
  4. package/src/atoms/Input.jsx +2 -6
  5. package/src/atoms/Pill.jsx +1 -3
  6. package/src/atoms/ProgressBar.jsx +3 -6
  7. package/src/atoms/SectionLabel.jsx +0 -22
  8. package/src/atoms/Tag.jsx +4 -7
  9. package/src/atoms/Textarea.jsx +1 -5
  10. package/src/atoms/ToggleCheckbox.jsx +3 -5
  11. package/src/atoms/ToggleSwitch.jsx +2 -7
  12. package/src/atoms/ViewToggle.jsx +0 -27
  13. package/src/index.js +1 -1
  14. package/src/molecules/AccountMenu.jsx +2 -2
  15. package/src/molecules/ButtonGroup.jsx +5 -14
  16. package/src/molecules/ButtonSplit.jsx +12 -26
  17. package/src/molecules/ContentRow.jsx +1 -29
  18. package/src/molecules/ContextMenu.jsx +0 -1
  19. package/src/molecules/DocsToc.jsx +1 -16
  20. package/src/molecules/Dropdown.jsx +4 -17
  21. package/src/molecules/EmptyState.jsx +1 -15
  22. package/src/molecules/FieldPair.jsx +1 -1
  23. package/src/molecules/Header.jsx +4 -4
  24. package/src/molecules/IndexRow.jsx +1 -1
  25. package/src/molecules/InlineAddRow.jsx +2 -2
  26. package/src/molecules/LabeledControl.jsx +5 -11
  27. package/src/molecules/LayerRow.jsx +1 -1
  28. package/src/molecules/LinkAddRow.jsx +5 -7
  29. package/src/molecules/Menu.jsx +11 -30
  30. package/src/molecules/MenuFloat.jsx +6 -12
  31. package/src/molecules/MenuList.jsx +5 -11
  32. package/src/molecules/Modal.jsx +16 -48
  33. package/src/molecules/ModalHeader.jsx +12 -20
  34. package/src/molecules/ModalShell.jsx +4 -7
  35. package/src/molecules/NoticeBanner.jsx +1 -1
  36. package/src/molecules/PanelsMenu.jsx +2 -2
  37. package/src/molecules/PasswordInput.jsx +1 -1
  38. package/src/molecules/QuantityInput.jsx +2 -18
  39. package/src/molecules/QuickLookFrame.jsx +2 -31
  40. package/src/molecules/RailHeader.jsx +11 -20
  41. package/src/molecules/ReadingActions.jsx +2 -2
  42. package/src/molecules/ReadingNotes.jsx +3 -3
  43. package/src/molecules/ReadingSettings.jsx +8 -8
  44. package/src/molecules/SearchInput.jsx +4 -5
  45. package/src/molecules/SectionText.jsx +2 -9
  46. package/src/molecules/SettingsControls.jsx +23 -23
  47. package/src/molecules/Slider.jsx +3 -54
  48. package/src/molecules/SpecList.jsx +1 -21
  49. package/src/molecules/TabsRow.jsx +6 -50
  50. package/src/molecules/TaskRow.jsx +2 -2
  51. package/src/molecules/TocRow.jsx +1 -1
  52. package/src/molecules/WorkspaceSwitcher.jsx +3 -6
  53. package/src/organisms/CommandOverlay.jsx +16 -116
  54. package/src/organisms/ContentFilters.jsx +4 -12
  55. package/src/organisms/MediaLibrary.jsx +0 -55
  56. package/src/organisms/NavRail.jsx +1 -4
  57. package/src/organisms/ReadingContents.jsx +2 -2
  58. package/src/organisms/ReadingOverview.jsx +5 -5
  59. package/src/organisms/ReadingPanel.jsx +1 -1
  60. package/src/organisms/SettingsPanel.jsx +19 -40
  61. package/src/organisms/Table.jsx +1 -49
  62. package/src/utilities/Popover.jsx +2 -4
  63. package/src/utilities/SelectionOverlay.jsx +1 -45
  64. package/src/molecules/FloatModuleHeader.jsx +0 -11
  65. package/src/organisms/NavRailFloat.jsx +0 -139
@@ -9,19 +9,12 @@ import SearchInput from '../molecules/SearchInput.jsx'
9
9
  import ModalShell from '../molecules/ModalShell.jsx'
10
10
  import Tag from '../atoms/Tag.jsx'
11
11
  import TabsRow from '../molecules/TabsRow.jsx'
12
- import Button from '../atoms/Button.jsx'
13
- import { floatSurfaceClass } from '../utilities/tone.js'
14
- import { floatMotion } from '../utilities/motion.js'
15
- import useFloatPresence from '../hooks/useFloatPresence.js'
16
12
  import { shortcutInScope } from './ShortcutsOverlay.jsx'
17
13
 
18
14
  /* ONE COLUMN (2026-09-30): rows, headings and footer sit on the field's own
19
15
  * geometry — the p-2 inset, then the md control's 1px ring + 16px pad — so
20
16
  * every glyph and word lines up under the field's icon and caret. */
21
17
 
22
- /* the foot's rule runs the card's full width: out through the card's inset, the hints 12 in from the rows' edge */
23
- const RULE = { margin: '6px calc(-1 * var(--kol-float-inset)) calc(-1 * var(--kol-float-inset))', paddingInline: 'calc(var(--kol-float-inset) + 12px)' }
24
-
25
18
  /* Rows bucketed by `group` in first-seen order, rank kept inside a group —
26
19
  * one heading per group; arrows rove this order, not the engine's. */
27
20
  function groupRows(rows) {
@@ -160,23 +153,10 @@ function unfold(rows, opened) {
160
153
  * @param {string} [selectLabel] the footer's Enter line while a row is highlighted (default
161
154
  * `Go to page`) — a modal whose rows are not pages says what
162
155
  * Enter does instead (the rack's module search: `Add module`)
163
- * @param {'default'|'float'|'kolbox'|'folio'} [variant='default'] the look. `folio`: Folio's search modal and command list (`mode`
156
+ * @param {'default'|'kolbox'|'folio'} [variant='default'] the look. `folio`: Folio's search modal and command list (`mode`
164
157
  * search, commands), see `CommandOverlayFolio`. `default` is the KOL search modal (the overlay
165
158
  * panel on oq-04, the field in a grey tone, OptionRow rows, the Kbd footer), as it was
166
- * drawn up to 0.341.1. `float` is the float card (plan-2026-11-05-float-editor 7.7, his
167
- * frame float-more 30:914): RailTrigger's (`kol-more-sheet-float` on `--kol-float-menu-r`,
168
- * the float surface and shadow), the float SearchInput, the float rows (Inter,
169
- * `--kol-float-row`, the lit row fg-16, the hint right), eyebrow groups, and the key-hint
170
- * foot under a full-width rule. Float apps only (his ruling 2026-11-20, plan W17.1)
171
- * @param {'solid'|'glass-dark'|'glass-light'} [surface='solid'] with `variant="float"`, what the card is made of
172
- * @param {Array} [tabs] `[{ id, label }]` — his All · Actions · Tools · Pages: the first shows every row, the
173
- * rest the rows whose `tab` is their id. Tab / ⇧Tab step through them from the field
174
- * @param {Object|Element} [anchor] a ref (or element) the card ANCHORS ABOVE — the dock's ⌘K: the card takes the anchor's
175
- * left and width, 16 over its top, the page undimmed. Unset, the card is centred
176
- * @param {string} [shortcutHint] the field's key cap while it is empty (his `⌘K`)
177
- * @param {boolean|Object} [motion=true] with `surface`, the card fades and scales in and out over a fading scrim, held in
178
- * the tree while it leaves (FloatActionStatesAndMotion, 2026-11-04): `true` the
179
- * `--kol-float-*` tokens · `false` none · `{ duration, ease }` per app
159
+ * drawn up to 0.341.1.
180
160
  */
181
161
  function CommandOverlayDefault({
182
162
  open,
@@ -206,16 +186,10 @@ function CommandOverlayDefault({
206
186
  shortcuts = [],
207
187
  currentPath,
208
188
  variant = 'default',
209
- surface = 'solid',
210
189
  tabs,
211
190
  anchor,
212
191
  shortcutHint,
213
- motion = true,
214
192
  }) {
215
- const float = variant === 'float'
216
- const fm = floatMotion(motion)
217
- const presence = useFloatPresence(open, float ? fm.ms : 0)
218
- const exit = float && presence.exiting ? '' : undefined
219
193
  const panelRef = useRef(null)
220
194
  const listRef = useRef(null)
221
195
  const listId = useId()
@@ -244,7 +218,7 @@ function CommandOverlayDefault({
244
218
  window.addEventListener('resize', on)
245
219
  return () => window.removeEventListener('resize', on)
246
220
  }, [open, anchor])
247
- const anchorRect = presence.mounted && anchor ? (anchor.current ?? anchor)?.getBoundingClientRect?.() : null
221
+ const anchorRect = open && anchor ? (anchor.current ?? anchor)?.getBoundingClientRect?.() : null
248
222
  const place = anchorRect ? { left: anchorRect.left, width: anchorRect.width, bottom: window.innerHeight - anchorRect.top + 16 } : null
249
223
  const results = unfold(base, opened)
250
224
  /* a `disabled` row is drawn but never active: ↑↓ step over it, Enter and click never reach
@@ -281,7 +255,7 @@ function CommandOverlayDefault({
281
255
  listRef.current?.querySelectorAll('[role="option"]')[active]?.scrollIntoView({ block: 'nearest' })
282
256
  }, [active])
283
257
 
284
- if (!(float ? presence.mounted : open)) return null
258
+ if (!open) return null
285
259
 
286
260
  /* A row that KEEPS THE MODAL OPEN — `keepOpen`, or an `action` row (the contract below always said
287
261
  * so; until 0.252.0 every pick closed — ShellSearchOverlayActionKeepsOpen, kol-fxr 2026-10-13). It
@@ -362,11 +336,9 @@ function CommandOverlayDefault({
362
336
  const enterWord = results.length > 0
363
337
  ? (results[active]?.fold ? (opened.has(results[active].id) ? 'Collapse' : 'Expand') : noField ? 'Collapse' : selectLabel)
364
338
  : enterLabel
365
- const hint = 'flex items-center gap-1.5 text-oq-64'
366
- const hintBtn = `${hint} hover:text-fg-emphasis transition-colors cursor-pointer`
367
339
 
368
340
  return (
369
- <div className={`fixed inset-0 ${place ? '' : 'flex items-start justify-center pt-[20vh]'}`} style={{ zIndex: 'var(--kol-z-modal, 100)', ...(float ? fm.style : null) }}>
341
+ <div className={`fixed inset-0 ${place ? '' : 'flex items-start justify-center pt-[20vh]'}`} style={{ zIndex: 'var(--kol-z-modal, 100)' }}>
370
342
  {/* A BUTTON, not a div (OverlayScrimTapDismiss, 2026-09-01): iOS Safari
371
343
  * does not bubble tap-clicks from non-interactive elements, so the div's
372
344
  * onClick never fired on a phone and the only way out was the close
@@ -375,8 +347,7 @@ function CommandOverlayDefault({
375
347
  <button
376
348
  type="button"
377
349
  aria-label="Close search"
378
- className={`absolute inset-0 ${place ? 'cursor-default' : `kol-overlay-scrim${float ? ' kol-float-fade' : ''}`}`}
379
- data-exit={exit}
350
+ className={`absolute inset-0 ${place ? 'cursor-default' : 'kol-overlay-scrim'}`}
380
351
  onClick={onClose}
381
352
  />
382
353
  <div
@@ -387,36 +358,26 @@ function CommandOverlayDefault({
387
358
  role="dialog"
388
359
  aria-modal="true"
389
360
  aria-label="Search"
390
- data-exit={exit}
391
361
  data-side={place ? 'top' : undefined}
392
362
  style={place ? { position: 'fixed', left: place.left, width: place.width, bottom: place.bottom } : undefined}
393
- className={float
394
- ? `kol-command kol-more-sheet kol-more-sheet-float kol-float-chrome kol-float-motion ${floatSurfaceClass(surface, true)} overflow-hidden ${place ? '' : `relative w-full mx-4 ${expanded ? 'max-w-[var(--kol-content-panel)]' : 'max-w-xl'}`} ${noField ? 'outline-none' : ''}`.replace(/\s+/g, ' ').trim()
395
- : `kol-overlay-panel ${place ? '' : 'mx-4 '}${noField ? 'outline-none ' : ''}${expanded ? 'max-w-[var(--kol-content-panel)]' : 'max-w-lg'}`}
363
+ className={`kol-overlay-panel ${place ? '' : 'mx-4 '}${noField ? 'outline-none ' : ''}${expanded ? 'max-w-[var(--kol-content-panel)]' : 'max-w-lg'}`}
396
364
  >
397
365
  {/* THE MODE, said out loud (user 2026-08-01: "how do you set search
398
366
  * mode? theres no helper, message or mode clearly readble"). Two
399
367
  * modes exist — FILTER (tags narrow a set) and FIND (a keyword jumps
400
368
  * to a destination) — and the only signal was whether chips happened
401
369
  * to be present. The chips ARE the mode, so they get a label. */}
402
- {chips.length > 0 && (float ? (
403
- <div className="flex flex-wrap items-center gap-1.5 px-3 pt-2 pb-1">
404
- <span className="kol-float-label text-oq-64 shrink-0">Filtering by</span>
405
- {chips.map((t) => (
406
- <Tag key={t} onRemove={() => onRemoveChip?.(t)}>{t}</Tag>
407
- ))}
408
- </div>
409
- ) : (
370
+ {chips.length > 0 && (
410
371
  <div className="flex flex-wrap items-center gap-1.5 px-4 pt-3">
411
372
  <span className="kol-helper-10 text-fg-48 shrink-0">FILTERING BY</span>
412
373
  {chips.map((t) => (
413
374
  <Tag key={t} onRemove={() => onRemoveChip?.(t)}>{t}</Tag>
414
375
  ))}
415
376
  </div>
416
- ))}
377
+ )}
417
378
  {/* THE BACK ARROW TAKES THE SEARCH GLYPH'S SLOT (user 2026-10-18: *"why would the back move the input?!"*) —
418
379
  * a button beside the field shrank it and shifted the caret on every drill-in */}
419
- {!noField && !float && (
380
+ {!noField && (
420
381
  /* A REAL FIELD, inset in the panel (2026-09-30, shadcn's search modal as the aim) */
421
382
  <div className="kol-tone-grey p-2 flex items-center gap-2">
422
383
  <SearchInput
@@ -435,27 +396,9 @@ function CommandOverlayDefault({
435
396
  />
436
397
  </div>
437
398
  )}
438
- {!noField && float && (
439
- <SearchInput
440
- className="w-full min-w-0"
441
- value={query}
442
- onChange={(e) => onQueryChange?.(e.target.value)}
443
- placeholder={chips.length > 0 ? 'Narrow these results…' : placeholder}
444
- onKeyDown={handleKeyDown}
445
- onBack={back}
446
- backLabel={backLabel}
447
- shortcutHint={shortcutHint}
448
- variant="float"
449
- size="lg"
450
- role="combobox"
451
- aria-expanded={results.length > 0}
452
- aria-controls={listId}
453
- aria-activedescendant={active >= 0 ? optionId(results[active]) : undefined}
454
- />
455
- )}
456
- {/* his tabs — All · Actions · Tools · Pages — the float TabsRow under the field */}
399
+ {/* his tabs — All · Actions · Tools · Pages */}
457
400
  {tabs?.length > 0 && !expanded && (
458
- <TabsRow variant={float ? 'float' : undefined} size="md" tabs={tabs} value={tabNow} onChange={setTab} className={float ? 'pt-2' : 'px-2 pt-2'} />
401
+ <TabsRow size="md" tabs={tabs} value={tabNow} onChange={setTab} className="px-2 pt-2" />
459
402
  )}
460
403
 
461
404
  {/* WHY THIS IS NOT `molecules/Dropdown` (asked 2026-08-01). Dropdown is
@@ -479,41 +422,18 @@ function CommandOverlayDefault({
479
422
  * its items, a "← All" row back); the consumer swaps `suggestions`/`results`
480
423
  * Built by `buildShellSearchItems` (showcase/src/nav/shell-nav.js). */}
481
424
  {expanded ? (
482
- <div className="border-t border-fg-08 max-h-[70vh] overflow-y-auto" style={float ? RULE : undefined}>{children}</div>
425
+ <div className="border-t border-fg-08 max-h-[70vh] overflow-y-auto">{children}</div>
483
426
  ) : results.length > 0 && (
484
427
  /* FIXED BODY HEIGHT — the panel holds still while the list narrows. */
485
- <ul ref={listRef} id={listId} role="listbox" className={float ? 'flex h-80 flex-col gap-[var(--kol-spacing-0-5)] overflow-y-auto' : `kol-tone-grey h-80 overflow-y-auto px-2 pb-2${noField ? ' pt-2' : ''}`}>
428
+ <ul ref={listRef} id={listId} role="listbox" className={`kol-tone-grey h-80 overflow-y-auto px-2 pb-2${noField ? ' pt-2' : ''}`}>
486
429
  {results.map((item, i) => {
487
430
  const heading = (item.group ?? '') !== (results[i - 1]?.group ?? '') || i === 0
488
431
  return (
489
432
  <li key={item.id} role="presentation">
490
433
  {heading && item.group && (
491
434
  /* the rail's eyebrow (user 2026-10-18: *"sections shoudl be uppercase eyebrow like in siderail"*) */
492
- <p className={float ? 'kol-eyebrow text-oq-64 px-3 pt-3 pb-2' : 'kol-eyebrow text-fg-80 px-4 border-x border-transparent pt-3 pb-2'}>{item.group}</p>
435
+ <p className="kol-eyebrow text-fg-80 px-4 border-x border-transparent pt-3 pb-2">{item.group}</p>
493
436
  )}
494
- {float ? (
495
- /* the float row: RailTrigger's card row, lit on the float selection while it is the cursor */
496
- <Button
497
- id={optionId(item)}
498
- role="option"
499
- aria-selected={i === active}
500
- aria-disabled={item.disabled || undefined}
501
- tabIndex={-1}
502
- variant="nav"
503
- size="lg"
504
- className={`kol-btn-float w-full justify-start${i === active ? ' kol-btn-pressed' : ''}${item.disabled ? ' opacity-40' : ''}`}
505
- onMouseDown={(e) => e.preventDefault()}
506
- onClick={() => select(item)}
507
- onMouseEnter={() => { if (!item.disabled) { setActiveIndex(i); setNavigated(true) } }}
508
- >
509
- {/* the glyph drawn here, not as `iconLeft` — Button would wrap it and the label in a span that does not take the row */}
510
- <span className="flex min-w-0 flex-1 items-center" style={{ gap: 'var(--kol-float-gap-ic)' }}>
511
- {item.indent ? <span className="inline-block w-4 shrink-0" /> : item.icon && (typeof item.icon === 'string' ? <IconLoader name={item.icon} size="var(--kol-float-ic)" className="shrink-0 text-oq-88" /> : item.icon)}
512
- <span className="truncate text-left"><HighlightMatch label={item.label} query={query} ranges={item.highlights} /></span>
513
- {((item.disabled && item.disabledHint) || item.hint) && <span className="kol-float-hint ml-auto truncate pl-3 text-oq-64">{(item.disabled && item.disabledHint) || item.hint}</span>}
514
- </span>
515
- </Button>
516
- ) : (
517
437
  <OptionRow
518
438
  id={optionId(item)}
519
439
  role="option"
@@ -531,14 +451,13 @@ function CommandOverlayDefault({
531
451
  onClick={() => select(item)}
532
452
  onMouseEnter={() => { if (!item.disabled) { setActiveIndex(i); setNavigated(true) } }}
533
453
  />
534
- )}
535
454
  </li>
536
455
  )
537
456
  })}
538
457
  </ul>
539
458
  )}
540
459
  {/* THE FOOT — his key hints under a rule that runs the card's full width; it always says what Enter does. */}
541
- {!expanded && !float && (results.length > 0 || (query && (enterLabel || onOpenResults))) && (
460
+ {!expanded && (results.length > 0 || (query && (enterLabel || onOpenResults))) && (
542
461
  <div className="border-t border-fg-08 py-2">
543
462
  {/* Enter's line names what Enter does NOW: a row is highlighted → it opens that row; no rows → it commits the query */}
544
463
  {enterWord && (
@@ -574,25 +493,6 @@ function CommandOverlayDefault({
574
493
  )}
575
494
  </div>
576
495
  )}
577
- {!expanded && float && (results.length > 0 || (query && (enterLabel || onOpenResults))) && (
578
- <div className="kol-float-hint flex flex-wrap items-center gap-x-5 gap-y-1 border-t border-fg-08 py-3 pointer-coarse:min-h-11" style={RULE}>
579
- {results.length > 1 && <span className={hint}><span aria-hidden>↑↓</span>Navigate</span>}
580
- {enterWord && <span className={hint}><span aria-hidden>↵</span>{enterWord}</span>}
581
- <button type="button" className={hintBtn} onMouseDown={(e) => e.preventDefault()} onClick={onClose}><span aria-hidden>Esc</span>Close</button>
582
- {/* ⌘↵ — the other one: every fold open or shut, or THE RESULTS LINK (user 2026-10-01: *"make 'all
583
- * results...' at the bottom also be a link to the results page"*) — the door ⌘Enter opens */}
584
- {folds.length > 0 && !query && (
585
- <button type="button" className={`${hintBtn} ml-auto`} onMouseDown={(e) => e.preventDefault()} onClick={toggleAll}>
586
- <span aria-hidden>⌘↵</span>{allOpen ? 'Collapse all' : 'Expand all'}
587
- </button>
588
- )}
589
- {query && onOpenResults && (
590
- <button type="button" className={`${hintBtn} ml-auto min-w-0`} onMouseDown={(e) => e.preventDefault()} onClick={() => { onOpenResults(query); onClose?.() }}>
591
- <span aria-hidden>⌘↵</span><span className="truncate">{resultsLabel}</span>
592
- </button>
593
- )}
594
- </div>
595
- )}
596
496
  </div>
597
497
  </div>
598
498
  )
@@ -70,13 +70,9 @@ import { filterItems } from '../utilities/searchItems.js'
70
70
  * @param {string} props.countClassName — the "N of N" type/ink
71
71
  * @param {string} props.tone — 'default' | 'inverse' — forwarded to the search field (ControlToneInverse,
72
72
  * 2026-08-27): a page on a wash sets its header row's tone in one place
73
- * @param {'float'} props.variant — the float filter bar (float-everything W4 row 56, 2026-11-04): each group's
74
- * chips are `Tag variant="float" size="md"` capsules with the count of items
75
- * each would show, in a capsule track 5 in. Everything else stays.
76
73
  */
77
74
  const ContentFilters = ({
78
75
  tone = 'default',
79
- variant,
80
76
  items,
81
77
  title,
82
78
  totalCount,
@@ -324,9 +320,6 @@ const ContentFilters = ({
324
320
  * rule sits in the components layer. */
325
321
  const stacked = group.stack ?? index === 0
326
322
  const first = index === 0 && stacked
327
- const float = variant === 'float'
328
- /* the float chip carries the count of items it would show (row 56) */
329
- const countOf = (value) => items.filter((item) => { const v = item[group.key]; return Array.isArray(v) ? v.includes(value) : v === value }).length
330
323
  return (
331
324
  <div key={group.key} className={`flex flex-col gap-3 ${first ? 'kol-filters-first' : stacked ? 'shrink-0' : 'min-w-0 flex-1'} ${group.className ?? ''}`.trim()}>
332
325
  {/* THE CATEGORY LABEL IS THE ACTIVE INK — `kol-helper-12` at `text-fg-96`,
@@ -344,17 +337,16 @@ const ContentFilters = ({
344
337
  </h4>
345
338
  {/* the fluid group keeps 48px of room on its right (it ran flush to the
346
339
  * panel's edge); `group.wrapClassName` is the per-group seam */}
347
- <div className={`${float ? 'inline-flex self-start flex-wrap items-center gap-1 rounded-full bg-oq-04 p-[5px]' : stacked ? 'flex flex-col items-start gap-2' : 'flex flex-wrap gap-2 pr-12'} ${group.wrapClassName ?? ''}`.trim()}>
340
+ <div className={`${stacked ? 'flex flex-col items-start gap-2' : 'flex flex-wrap gap-2 pr-12'} ${group.wrapClassName ?? ''}`.trim()}>
348
341
  {group.values.map((value) => (
349
342
  <Tag
350
343
  key={value}
351
- size={float ? 'md' : tagSize}
352
- variant={float ? 'float' : tagVariant}
344
+ size={tagSize}
345
+ variant={tagVariant}
353
346
  hash={false}
354
- count={float ? countOf(value) : undefined}
355
347
  active={activeFilters.has(`${group.key}:${value}`)}
356
348
  onClick={() => toggleFilter(group.key, value)}
357
- className={float ? undefined : activeFilters.has(`${group.key}:${value}`) ? tagActiveClassName : tagRestClassName}
349
+ className={activeFilters.has(`${group.key}:${value}`) ? tagActiveClassName : tagRestClassName}
358
350
  >
359
351
  {value}
360
352
  </Tag>
@@ -6,7 +6,6 @@ import Divider from '../atoms/Divider.jsx'
6
6
  import Dropdown from '../molecules/Dropdown.jsx'
7
7
  import Input from '../atoms/Input.jsx'
8
8
  import ViewToggle from '../atoms/ViewToggle.jsx'
9
- import SearchInput from '../molecules/SearchInput.jsx'
10
9
  import FullscreenOverlay from '../molecules/FullscreenOverlay.jsx'
11
10
  import ModalShell from '../molecules/ModalShell.jsx'
12
11
  import { Tooltip } from '../utilities/Popover.jsx'
@@ -1051,14 +1050,6 @@ function PickerShell({ onClose, onPick }) {
1051
1050
  * @param {boolean} flat start in flat mode
1052
1051
  * @param {Function} onClose modal only — Esc, backdrop, close button
1053
1052
  * @param {Function} onSelect `(url, { contentType, kind })`. In `modal` it also closes.
1054
- *
1055
- * `float` (float-everything W6 row 87, 2026-11-04 — kol-float--style 46:2960): the asset window — a 310 float panel,
1056
- * non-modal (no scrim, the scene stays live), `kol-float-solid` on the sheet radius, 20 in. The title in
1057
- * `kol-float-window` with the × · a float SearchInput · the files as rows (a 44 × 54 cover on 6, the name in Inter 13,
1058
- * `ext · size` in mono 10, a check on the picked one) — a press picks (`onSelect`) · `onImport` draws `+ Import`
1059
- * (a float button, secondary) beside the count. Same `open` · `client` · `accept` · `onClose` · `onSelect` as `modal`.
1060
- * @param {string} title float: the window's title (default `Assets`)
1061
- * @param {Function} onImport float: shows the import button · {string} importLabel (default `Import`)
1062
1053
  */
1063
1054
  export default function MediaLibrary({
1064
1055
  variant = 'page',
@@ -1073,7 +1064,6 @@ export default function MediaLibrary({
1073
1064
  ...pageProps
1074
1065
  }) {
1075
1066
  const opts = { client, accept, pageSize, defaultSort, flat }
1076
- if (variant === 'float') return open ? withProvider(<FloatPicker onClose={onClose} onPick={onSelect} {...pageProps} />, opts) : null
1077
1067
  if (variant === 'modal') {
1078
1068
  if (!open) return null
1079
1069
  return withProvider(<PickerShell onClose={onClose} onPick={onSelect} />, opts)
@@ -1150,51 +1140,6 @@ function PickerBrowse({ client, accept, onClose, onSelect, title = 'MEDIA', ...b
1150
1140
  )
1151
1141
  }
1152
1142
 
1153
- /* THE ASSET WINDOW (`variant="float"`, W6 row 87) — read-only, a picker: rows from the provider, the search its own */
1154
- function FloatPicker({ onClose, onPick, onImport, importLabel = 'Import', title = 'Assets', className = '' }) {
1155
- const { sorted, search, setSearch, mediaUrl, loading, error } = useMediaLibrary()
1156
- const [picked, setPicked] = useState(null)
1157
- const files = sorted.filter((o) => o.type !== 'folder')
1158
- const pick = (o) => { setPicked(o.key); onPick?.(mediaUrl(o.fullKey ?? o.key), { contentType: o.contentType, kind: o.kind }) }
1159
- return (
1160
- <section role="dialog" aria-label={title} className={`kol-float-solid flex w-[310px] max-w-full flex-col gap-4 rounded-[var(--kol-float-menu-r)] p-5 ${className}`.trim()}>
1161
- <div className="flex items-center gap-3">
1162
- <span className="kol-float-window min-w-0 flex-1 truncate text-fg-emphasis">{title}</span>
1163
- {onClose && (
1164
- <button type="button" aria-label="Close" onClick={onClose} className="inline-flex size-6 shrink-0 items-center justify-center rounded-full text-oq-64 hover:bg-fg-08 hover:text-oq-96 cursor-pointer focus-visible:outline-none focus-visible:shadow-[var(--kol-float-focus)]">
1165
- <IconLoader name="x" size={16} />
1166
- </button>
1167
- )}
1168
- </div>
1169
- <SearchInput variant="float" value={search ?? ''} onChange={(e) => setSearch(e.target.value)} placeholder="Search assets…" />
1170
- <ul className="m-0 flex max-h-[320px] list-none flex-col gap-1 overflow-y-auto p-0 [scrollbar-width:none]">
1171
- {error && <li className="kol-float-hint text-ui-error">Couldn’t load: {error}</li>}
1172
- {!error && loading && <li className="kol-float-hint text-fg-64">Loading…</li>}
1173
- {!error && !loading && files.length === 0 && <li className="kol-float-hint text-fg-64">Nothing here.</li>}
1174
- {files.map((o) => (
1175
- <li key={o.key}>
1176
- <button type="button" onClick={() => pick(o)} aria-pressed={picked === o.key}
1177
- className={`flex w-full items-center gap-3 rounded-[var(--kol-float-list-r)] p-1 text-left cursor-pointer focus-visible:outline-none focus-visible:shadow-[var(--kol-float-focus)] ${picked === o.key ? 'bg-fg-12' : 'hover:bg-fg-04'}`}>
1178
- <span className="h-[54px] w-11 shrink-0 overflow-hidden rounded-md bg-fg-08"><Thumb row={o} mediaUrl={mediaUrl} /></span>
1179
- <span className="flex min-w-0 flex-1 flex-col gap-0.5">
1180
- <span className="kol-float-hint truncate text-fg-emphasis" style={{ fontSize: 13 }}>{o.displayKey}</span>
1181
- <span className="kol-float-ruler truncate uppercase text-fg-64">{[o.key.split('.').pop(), formatSize(o.size)].filter(Boolean).join(' · ')}</span>
1182
- </span>
1183
- {picked === o.key && <IconLoader name="check" size={14} className="mr-2 shrink-0 text-oq-96" />}
1184
- </button>
1185
- </li>
1186
- ))}
1187
- </ul>
1188
- {(onImport || files.length > 0) && (
1189
- <div className="flex items-center gap-3">
1190
- {onImport && <Button variant="float" tone="secondary" size="md" iconLeft="plus" onClick={onImport}>{importLabel}</Button>}
1191
- <span className="kol-float-label text-fg-64">{files.length} {files.length === 1 ? 'asset' : 'assets'}</span>
1192
- </div>
1193
- )}
1194
- </section>
1195
- )
1196
- }
1197
-
1198
1143
  /** @deprecated 2026-08-01 — alias of `MediaLibrary variant="modal"`. Kept so
1199
1144
  * existing call sites and the fxr editor's `onPick` naming keep working;
1200
1145
  * drops when nobody imports it (04-retirements.md). */
@@ -18,7 +18,6 @@ import VectorLoader from '../atoms/VectorLoader.jsx'
18
18
  import { useRailSlot } from '../hooks/railSlot.jsx'
19
19
  import { RAIL_ROW } from '../hooks/railRow.js'
20
20
  import NavRailSite from './NavRailSite.jsx'
21
- import NavRailFloat from './NavRailFloat.jsx'
22
21
 
23
22
  /**
24
23
  * NavRail — the flat rail. ONE fixed column, every child a direct child of it
@@ -83,8 +82,7 @@ import NavRailFloat from './NavRailFloat.jsx'
83
82
  * EXPANDS (its rows open under it in place) and COLLAPSES. No other words, in code or docs.
84
83
  *
85
84
  * @param {'app'|'site'|'workshop'} preset which rail (default `app`); `variant="site"` is the old spelling of `preset="site"`
86
- * @param {'top'|'float'} variant `top` — the horizontal top rail (TopRail): logomark · items · `actions` (the right slot);
87
- * `float` — the float sidebar, expanded 264 · collapsed 72 (NavRailFloat.jsx, float-everything W9 rows 127 · 128)
85
+ * @param {'top'} variant `top` — the horizontal top rail (TopRail): logomark · items · `actions` (the right slot)
88
86
  * @param {Array} items `{ icon, path, label, sub?: [{ icon?, path, label }] }`
89
87
  * a section (`sub`) with `to` is a FOLDER NOTE: its icon and label open `to`, its chevron expands or enters
90
88
  * @param {Array} bottomItems pinned below the rule (Settings)
@@ -331,7 +329,6 @@ export function registerRailPreset(name, Component) { RAIL_PRESETS[name] = { ...
331
329
 
332
330
  export default function NavRail({ variant, preset, ...props }) {
333
331
  if (variant === 'top') return <TopRail {...props} />
334
- if (variant === 'float') return <NavRailFloat {...props} />
335
332
  const name = preset ?? (variant === 'site' ? 'site' : 'app')
336
333
  if (name === 'app') return <AppRail {...props} sections={props.sections ?? RAIL_PRESETS.app.sections} />
337
334
  const Named = RAIL_PRESETS[name]?.component
@@ -38,7 +38,7 @@ function ReadingContentsDefault({ book, author, count, chapters = [], current, o
38
38
  </div>
39
39
  )}
40
40
  {(count || chapters.length > 0) && (
41
- <LabeledControlSection variant="float" as="nav" aria-label="Contents" rowGap={1}
41
+ <LabeledControlSection as="nav" aria-label="Contents" rowGap={1}
42
42
  label={count && <span className="kol-float-ruler uppercase text-fg-64">{count}</span>}>
43
43
  {chapters.map((c, i) => (
44
44
  <TocRow key={c.id} number={i + 1} label={c.label} href={c.href} current={c.id === current} onClick={onSelect ? () => onSelect(c.id) : undefined} className="h-9" />
@@ -51,7 +51,7 @@ function ReadingContentsDefault({ book, author, count, chapters = [], current, o
51
51
  <span className="kol-float-hint text-fg-64">{progressLabel}</span>
52
52
  <span className="kol-float-timecode tabular-nums text-fg-emphasis">{Math.round(progress)}%</span>
53
53
  </div>
54
- <ProgressBar variant="float" value={progress} ariaLabel={progressLabel} />
54
+ <ProgressBar value={progress} ariaLabel={progressLabel} />
55
55
  </div>
56
56
  )}
57
57
  </div>
@@ -28,13 +28,13 @@ import { floatSurfaceClass } from '../utilities/tone.js'
28
28
  export default function ReadingOverview({ onBack, backLabel = 'Back to my library', cover, title, author, meta = [], description, place, onResume, resumeLabel = 'Resume reading', onCollect, collectLabel = 'Add to collection', font = "'Literata', Georgia, serif", className = '' }) {
29
29
  return (
30
30
  <section className={`flex flex-col gap-8 ${className}`.trim()}>
31
- {onBack && <Button variant="float" tone="ghost" size="sm" iconLeft="arrow-left" onClick={onBack} className="-ml-3 self-start">{backLabel}</Button>}
31
+ {onBack && <Button tone="ghost" size="sm" iconLeft="arrow-left" onClick={onBack} className="-ml-3 self-start">{backLabel}</Button>}
32
32
  <div className="flex flex-col gap-8 md:flex-row md:gap-[52px]">
33
33
  {cover && <div className="aspect-[300/420] w-full max-w-[300px] shrink-0 self-start overflow-hidden rounded-sm">{cover}</div>}
34
34
  <div className="flex min-w-0 flex-1 flex-col">
35
35
  <h1 className="m-0 text-[52px] font-normal leading-[1.45] text-fg-emphasis" style={{ fontFamily: font }}>{title}</h1>
36
36
  {author && <span className="kol-float-window mt-3 font-normal text-fg-64">{author}</span>}
37
- {meta.length > 0 && <div className="mt-5 flex flex-wrap gap-3">{meta.map((m) => <Tag key={m} variant="float" size="md" hash={false}>{m}</Tag>)}</div>}
37
+ {meta.length > 0 && <div className="mt-5 flex flex-wrap gap-3">{meta.map((m) => <Tag key={m} size="md" hash={false}>{m}</Tag>)}</div>}
38
38
  {description && <p className="kol-float-body-lg m-0 mt-6 text-fg-64">{description}</p>}
39
39
  {place && (
40
40
  <div className="mt-10 flex flex-col rounded-[var(--kol-float-menu-r)] bg-surface-secondary px-6 py-4">
@@ -44,13 +44,13 @@ export default function ReadingOverview({ onBack, backLabel = 'Back to my librar
44
44
  <span className="kol-float-hint text-fg-64">{place.line}</span>
45
45
  {place.progress != null && <span className="kol-float-timecode tabular-nums text-fg-emphasis">{Math.round(place.progress)}%</span>}
46
46
  </div>
47
- {place.progress != null && <ProgressBar variant="float" value={place.progress} ariaLabel={place.label ?? 'Your place'} className="mt-2" />}
47
+ {place.progress != null && <ProgressBar value={place.progress} ariaLabel={place.label ?? 'Your place'} className="mt-2" />}
48
48
  </div>
49
49
  )}
50
50
  {(onResume || onCollect) && (
51
51
  <div className="mt-5 flex flex-wrap gap-4">
52
- {onResume && <Button variant="float" tone="inverted" size="lg" iconRight="arrow-right" onClick={onResume}>{resumeLabel}</Button>}
53
- {onCollect && <Button variant="float" tone="secondary" size="lg" onClick={onCollect} className={floatSurfaceClass('solid')}>{collectLabel}</Button>}
52
+ {onResume && <Button size="lg" iconRight="arrow-right" onClick={onResume}>{resumeLabel}</Button>}
53
+ {onCollect && <Button tone="secondary" size="lg" onClick={onCollect} className={floatSurfaceClass('solid')}>{collectLabel}</Button>}
54
54
  </div>
55
55
  )}
56
56
  </div>
@@ -28,7 +28,7 @@ export default function ReadingPanel({ title = 'Reading panel', tabs = TABS, tab
28
28
  {/* the one Header (property), its collapse-v chevron the 12 token (plan-2026-11-12-one-header W1.1 leftover); the title
29
29
  * keeps its body-lg face as the title slot */}
30
30
  <Header variant="property" title={<span className="kol-float-body-lg text-fg-emphasis truncate">{title}</span>} onCollapseV={onCollapseV ?? onFold} className="h-7 [&>span:last-child]:-mr-1.5" />
31
- <TabsRow variant="float" size="xs" overflow="wrap" tabs={tabs} value={tab} onChange={onTab} ariaLabel={title} className={`mt-4 ${TRACK}`} />
31
+ <TabsRow size="xs" overflow="wrap" tabs={tabs} value={tab} onChange={onTab} ariaLabel={title} className={`mt-4 ${TRACK}`} />
32
32
  <div className="mt-6">{children}</div>
33
33
  </aside>
34
34
  )
@@ -189,15 +189,7 @@ export function SettingsSwitch({ on = false, onChange, disabled = false, disable
189
189
  * user ruling: it named the place it was first used, not what it is; kol-fxr
190
190
  * took it for a params rail the same day). RENAMED, NO ALIAS — the render is
191
191
  * the 0.104.0 locked composition, untouched.
192
- *
193
- * `variant="float"` — the one float section (plan-2026-11-12-float-rails-figma W10.1, the user: *"this should be a
194
- * component with slots that has multiple items?"*): a `head` (the `label`, any node, a string in the float label role,
195
- * and `end`, a + button or a meta, at the far end) over the items (children, any number). PropertyRail's sections and
196
- * subheads, ReadingContents' chapters and NavRail float's groups all draw it. The head renders only when a label or an
197
- * end is given, the items only when there are any. `gap` is head to items, `rowGap` items to items, each a spacing step
198
- * (0.5 · 1 · 1.5 · 2 · 3) or `'module'` (`--kol-float-module-gap`); float defaults 3 (12) and 2 (8). `as` the element
199
- * (`nav` for a list of links), the rest of the props on it. */
200
- const GAP = { 0.5: 'gap-0.5', 1: 'gap-1', 1.5: 'gap-1.5', 2: 'gap-2', 3: 'gap-3', module: 'gap-[var(--kol-float-module-gap)]' }
192
+ */
201
193
  const SETTINGS_GAP = { 3: 'gap-3', 4: 'gap-4', settings: 'gap-[7px]' }
202
194
  /* `variant="kolbox"` (plan-2026-11-18-kolbox-system W31.2 batch 5, 2026-11-18): kolbox's RailSection (Figma 27:9309),
203
195
  * carried from apps/kolbox/src/ui/RailSection.jsx. A 1px rule at the section's top, then the head: a 40 row, the `label`
@@ -264,39 +256,26 @@ function LabeledControlSectionBody({ label, end, variant, divided = false, gap,
264
256
  </Tag>
265
257
  )
266
258
  }
267
- if (variant === 'float') {
268
- const items = Children.toArray(children)
269
- const hasLabel = label != null && label !== false && label !== ''
270
- const head = hasLabel && (typeof label === 'string' ? <span className="kol-float-label text-oq-64">{label}</span> : label)
271
- /* `collapsible` (plan-2026-11-12-one-header W10.1): the head is the toggle, ONE indicator — the 12 chevron at its right
272
- * end (⌄ open, › closed), the Header's chevron; `open` controlled or `defaultOpen`, `onToggle(open)`. `end` sits before
273
- * the chevron and must not be interactive. The items hide while closed. */
274
- const isOpen = !collapsible || (open ?? ownOpen)
275
- const toggle = () => { const next = !isOpen; if (open === undefined) setOwnOpen(next); onToggle?.(next) }
276
- return (
277
- <Tag data-labeled-control-section="" data-open={collapsible ? String(isOpen) : undefined} className={`flex flex-col ${GAP[gap ?? 3]} ${className}`.trim()} {...rest}>
278
- {collapsible ? (
279
- <button type="button" aria-expanded={isOpen} onClick={toggle}
280
- className="flex w-full items-center gap-2 text-left rounded-sm cursor-pointer focus-visible:outline-none focus-visible:shadow-[var(--kol-float-focus)]">
281
- <span className="flex min-w-0 flex-1 items-center">{head}</span>
282
- {end}
283
- <IconLoader name={isOpen ? 'chevron-down' : 'chevron-right'} size="var(--kol-float-chev-sm)" className="shrink-0 text-oq-64" />
284
- </button>
285
- ) : (hasLabel || end) && (
286
- <div className="flex items-center justify-between">
287
- {head}
288
- {end}
289
- </div>
290
- )}
291
- {isOpen && items.length > 0 && <div className={`flex flex-col ${GAP[rowGap ?? 2]}`}>{items}</div>}
292
- </Tag>
293
- )
294
- }
295
259
  rowGap ??= 2
260
+ /* `end` and `collapsible` (restored 2026-11-27 on the one component, ARCHITECTURE §8; they lived only in the retired
261
+ * float branch, which PropertyRail used): `end` sits at the head's right; `collapsible` makes the head the toggle, the
262
+ * 12 chevron at its right end (⌄ open, › closed), `open` controlled or `defaultOpen`, `onToggle(open)`. `end` must not be
263
+ * interactive on a collapsible head. The rows hide while closed. */
264
+ const isOpen = !collapsible || (open ?? ownOpen)
265
+ const toggle = () => { const next = !isOpen; if (open === undefined) setOwnOpen(next); onToggle?.(next) }
266
+ const head = label && (typeof label === 'string' ? <p className="kol-eyebrow text-fg-80">{label}</p> : label)
296
267
  return (
297
- <div className={`flex flex-col gap-3 ${divided ? 'kol-section--divided' : ''} ${className}`.replace(/\s+/g, ' ').trim()}>
298
- {label && <p className="kol-eyebrow text-fg-80">{label}</p>}
299
- <div className={`flex flex-col ${rowGap === 1 ? 'gap-1' : 'gap-2'}`}>{children}</div>
268
+ <div data-labeled-control-section="" data-open={collapsible ? String(isOpen) : undefined} className={`flex flex-col gap-3 ${divided ? 'kol-section--divided' : ''} ${className}`.replace(/\s+/g, ' ').trim()} {...rest}>
269
+ {collapsible ? (
270
+ <button type="button" aria-expanded={isOpen} onClick={toggle} className="flex w-full cursor-pointer items-center gap-2 text-left">
271
+ <span className="flex min-w-0 flex-1 items-center">{head}</span>
272
+ {end}
273
+ <IconLoader name={isOpen ? 'chevron-down' : 'chevron-right'} size={12} className="shrink-0 text-oq-64" />
274
+ </button>
275
+ ) : end ? (
276
+ <div className="flex items-center justify-between gap-2">{head}{end}</div>
277
+ ) : head}
278
+ {isOpen && <div className={`flex flex-col ${rowGap === 1 ? 'gap-1' : 'gap-2'}`}>{children}</div>}
300
279
  </div>
301
280
  )
302
281
  }