@kolkrabbi/kol-theme 0.211.1 → 0.212.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/kol-animation.css CHANGED
@@ -569,3 +569,72 @@
569
569
  @media (prefers-reduced-motion: reduce) {
570
570
  .kol-animated-word, .animatedWord { opacity: 1; transform: none; }
571
571
  }
572
+
573
+ /* ═════════════════════════════════════════════════════════════════════
574
+ * THE FLOAT FAMILY'S MOTION (FloatActionStatesAndMotion, kol-website
575
+ * 2026-11-04 — user: *"everything is very.. quick, not smooth"*). CSS only,
576
+ * no gsap: every number is a `--kol-float-*` token (kol-design-tokens.css),
577
+ * and the `motion` prop on the float pieces and FloatLayout retunes or zeroes
578
+ * them per app (`floatMotion`, kol-component's utilities/motion.js).
579
+ *
580
+ * .kol-float-motion a float card (the + card, RailTrigger's card,
581
+ * RailFlyout, the float search modal): fades in from
582
+ * `--kol-float-enter-scale`, `--kol-float-enter-shift`
583
+ * off its trigger's side (`data-side`), and out the
584
+ * same way under `data-exit` before it unmounts
585
+ * .kol-float-fade opacity only (the search modal's scrim)
586
+ * .kol-float-rail NavRailFloat: expand and collapse ease the width,
587
+ * the new rows fade in; `is-entering` / `is-exiting`
588
+ * is FloatLayout's show and hide (the width opens from
589
+ * and closes to 0, so a pushed page eases with it)
590
+ * .kol-float-turn the + turning 45° into the × (`is-open`) and back
591
+ *
592
+ * `scale` and `translate` are the individual properties, so they compose
593
+ * with floating-ui's positioning `transform` instead of replacing it.
594
+ * ═════════════════════════════════════════════════════════════════════ */
595
+ @keyframes kol-float-in {
596
+ from { opacity: 0; scale: var(--kol-float-enter-scale); translate: var(--kol-float-from, 0 var(--kol-float-enter-shift)); }
597
+ }
598
+ @keyframes kol-float-out {
599
+ to { opacity: 0; scale: var(--kol-float-enter-scale); translate: var(--kol-float-from, 0 var(--kol-float-enter-shift)); }
600
+ }
601
+ @keyframes kol-float-fade-in { from { opacity: 0; } }
602
+ @keyframes kol-float-fade-out { to { opacity: 0; } }
603
+ @keyframes kol-float-rail-in { from { width: 0; padding-inline: 0; margin-right: calc(-1 * var(--kol-spacing-6)); opacity: 0; } }
604
+ @keyframes kol-float-rail-out { to { width: 0; padding-inline: 0; margin-right: calc(-1 * var(--kol-spacing-6)); opacity: 0; } }
605
+
606
+ .kol-float-motion { animation: kol-float-in var(--kol-float-duration) var(--kol-float-ease) both; transform-origin: top center; }
607
+ .kol-float-fade { animation: kol-float-fade-in var(--kol-float-duration) var(--kol-float-ease) both; }
608
+ .kol-float-motion[data-exit] { animation-name: kol-float-out; pointer-events: none; }
609
+ .kol-float-fade[data-exit] { animation-name: kol-float-fade-out; pointer-events: none; }
610
+ /* from the trigger's side: a card left of its button grows out of the button's edge, and so on round */
611
+ .kol-float-motion[data-side="left"] { --kol-float-from: var(--kol-float-enter-shift) 0; transform-origin: right top; }
612
+ .kol-float-motion[data-side="right"] { --kol-float-from: calc(-1 * var(--kol-float-enter-shift)) 0; transform-origin: left top; }
613
+ .kol-float-motion[data-side="bottom"] { --kol-float-from: 0 calc(-1 * var(--kol-float-enter-shift)); transform-origin: left top; }
614
+ .kol-float-motion[data-side="top"] { --kol-float-from: 0 var(--kol-float-enter-shift); transform-origin: left bottom; }
615
+
616
+ .kol-float-rail { transition: width var(--kol-float-duration-rail) var(--kol-float-ease); overflow: hidden; }
617
+ .kol-float-rail > * { animation: kol-float-fade-in var(--kol-float-duration-rail) var(--kol-float-ease) both; }
618
+ .kol-float-rail.is-entering { animation: kol-float-rail-in var(--kol-float-duration-rail) var(--kol-float-ease) backwards; } /* backwards, not both: a held width would mute the expand/collapse transition after */
619
+ .kol-float-rail.is-exiting { animation: kol-float-rail-out var(--kol-float-duration-rail) var(--kol-float-ease) forwards; pointer-events: none; }
620
+
621
+ .kol-float-turn > * { transition: rotate var(--kol-float-duration) var(--kol-float-ease); }
622
+ .kol-float-turn.is-open > * { rotate: 45deg; } /* the glyph's wrapper, not the svg: Icon re-renders its svg */
623
+
624
+ /* a float's rows and slots ease their hover on the same clock as its buttons */
625
+ .kol-float-rail button,
626
+ .kol-more-sheet-float button,
627
+ .kol-rail-flyout button,
628
+ .kol-menu-panel--float .kol-menu-row {
629
+ transition: background-color var(--kol-float-duration) var(--kol-float-ease), color var(--kol-float-duration) var(--kol-float-ease);
630
+ }
631
+
632
+ @media (prefers-reduced-motion: reduce) {
633
+ .kol-float-motion, .kol-float-fade, .kol-float-rail, .kol-float-rail > *, .kol-float-turn > *,
634
+ .kol-btn.kol-btn-float, .kol-btn.kol-float-action,
635
+ .kol-float-rail button, .kol-more-sheet-float button, .kol-rail-flyout button, .kol-menu-panel--float .kol-menu-row {
636
+ animation: none;
637
+ transition: none;
638
+ }
639
+ .kol-btn.kol-btn-float.kol-tone-inverted:not(:disabled):active, .kol-btn.kol-float-action:not(:disabled):active { scale: none; }
640
+ }
@@ -1501,6 +1501,30 @@ a.kol-icon-frame {
1501
1501
  .kol-control.kol-control--float:focus-within,
1502
1502
  .kol-seg--float .kol-seg-cell:focus-visible,
1503
1503
  .kol-tabs-float .kol-btn.kol-btn-float:focus-visible { outline: none; box-shadow: var(--kol-float-focus); }
1504
+ /* THE INVERTED FLOAT LADDER (FloatActionStatesAndMotion, kol-website 2026-11-04 — user: *"so default is dark - hover is grey -
1505
+ * active is grey and modal is white? that makes no sense?"*). rest the solid ink · hover the SAME fill at
1506
+ * `--kol-float-hover-opacity` · pressed the same fill at `--kol-float-press-scale` · open (pressed) the same fill. The
1507
+ * inverted tone's grey rungs (oq-inverse-40 · -48, control-chrome's "label stays light, no ink swap") stay the square
1508
+ * Button's; on a float the label still never swaps — only the fill stops greying. `.kol-float-action` is FloatActionMenu's
1509
+ * round trigger, which keeps its 40 circle and, as `variant="float"` (`is-float`), adds the float shadow. */
1510
+ .kol-btn.kol-btn-float.kol-tone-inverted,
1511
+ .kol-btn.kol-float-action {
1512
+ --kol-tone-hover-bg: var(--kol-surface-on-primary);
1513
+ --kol-tone-active-bg: var(--kol-surface-on-primary);
1514
+ }
1515
+ /* every float button eases its states on the float's own duration and curve (a row too — kol-animation.css) */
1516
+ .kol-btn.kol-btn-float,
1517
+ .kol-btn.kol-float-action {
1518
+ transition: background-color var(--kol-float-duration) var(--kol-float-ease), color var(--kol-float-duration) var(--kol-float-ease),
1519
+ opacity var(--kol-float-duration) var(--kol-float-ease), scale var(--kol-float-duration) var(--kol-float-ease);
1520
+ }
1521
+ .kol-btn.kol-float-action.is-float { box-shadow: var(--kol-shadow-float); }
1522
+ @media (hover: hover) {
1523
+ .kol-btn.kol-btn-float.kol-tone-inverted:not(:disabled):hover,
1524
+ .kol-btn.kol-float-action:not(:disabled):hover { opacity: var(--kol-float-hover-opacity); }
1525
+ }
1526
+ .kol-btn.kol-btn-float.kol-tone-inverted:not(:disabled):active,
1527
+ .kol-btn.kol-float-action:not(:disabled):active { scale: var(--kol-float-press-scale); }
1504
1528
  .kol-btn.kol-btn-float:disabled,
1505
1529
  .kol-btn.kol-btn-float[aria-disabled="true"],
1506
1530
  .kol-control.kol-control--float:has(input:disabled) { opacity: 0.4; }
@@ -196,6 +196,19 @@
196
196
  --kol-float-focus: 0 0 0 2px var(--kol-surface-on-primary);
197
197
  /* the field's well, on whatever float holds it — the light tier; dark below */
198
198
  --kol-float-well: rgb(0 0 0 / 0.06);
199
+ /* THE FLOAT STATE LADDER AND ITS MOTION (FloatActionStatesAndMotion, kol-website 2026-11-04 — user: *"normal state - hover -
200
+ * just a slight drop in opacity"* · *"everything is very.. quick, not smooth"*). hover-opacity and press-scale are the
201
+ * inverted float button's hover and press (the fill never changes); enter-scale and enter-shift are a float card's way in
202
+ * and out, from its trigger's side; duration is a card, a state or the + turning, duration-rail the rail's expand, collapse,
203
+ * hide and show. The durations are DURATION.base and .slow of motion.js, the curve the house's. A `motion` prop retunes them
204
+ * per app; reduced motion drops them (kol-animation.css). */
205
+ --kol-float-hover-opacity: 0.88;
206
+ --kol-float-press-scale: 0.96;
207
+ --kol-float-enter-scale: 0.96;
208
+ --kol-float-enter-shift: 4px;
209
+ --kol-float-duration: 200ms;
210
+ --kol-float-duration-rail: 300ms;
211
+ --kol-float-ease: var(--kol-ease-house);
199
212
 
200
213
  /* Transitions (consistent timing) */
201
214
  --kol-transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kolkrabbi/kol-theme",
3
- "version": "0.211.1",
3
+ "version": "0.212.0",
4
4
  "description": "Tokens and base CSS",
5
5
  "license": "MIT",
6
6
  "type": "module",