@cosxai/ui 0.25.0 → 1.0.0-alpha.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 (133) hide show
  1. package/CHANGELOG.md +577 -0
  2. package/NOTICE +11 -0
  3. package/README.md +52 -0
  4. package/package.json +33 -7
  5. package/src/fonts.css +20 -0
  6. package/src/index.ts +8 -25
  7. package/src/lib/cn.ts +23 -6
  8. package/src/styles.css +17 -0
  9. package/src/theme.css +132 -0
  10. package/src/tokens/colors.css +112 -0
  11. package/src/tokens/compat.css +36 -0
  12. package/src/tokens/elevation.css +14 -0
  13. package/src/tokens/motion.css +42 -0
  14. package/src/tokens/spacing.css +55 -0
  15. package/src/tokens/typography-cjk.css +42 -0
  16. package/src/tokens/typography.css +81 -0
  17. package/src/actionbar/ActionBar.tsx +0 -837
  18. package/src/actionbar/ActionBarButton.tsx +0 -111
  19. package/src/actionbar/ActionBarMenuGroup.tsx +0 -116
  20. package/src/actionbar/ActionBarModeHandle.tsx +0 -171
  21. package/src/actionbar/ActionBarProvider.tsx +0 -91
  22. package/src/actionbar/actionbar-context.ts +0 -45
  23. package/src/actionbar/index.ts +0 -28
  24. package/src/actionbar/types.ts +0 -147
  25. package/src/actionbar/useActionBarItems.ts +0 -60
  26. package/src/actionbar/useActionBarMode.ts +0 -144
  27. package/src/actionbar/useActionBarPanel.ts +0 -56
  28. package/src/actionbar/useActionBarStatusDot.ts +0 -49
  29. package/src/actionbar/useActionBarToast.ts +0 -33
  30. package/src/ambient/AmbientBackdrop.tsx +0 -74
  31. package/src/ambient/CommandInput.tsx +0 -107
  32. package/src/ambient/SuperbarStrip.tsx +0 -36
  33. package/src/ambient/index.ts +0 -6
  34. package/src/bento/BentoCell.tsx +0 -66
  35. package/src/bento/BentoGrid.tsx +0 -42
  36. package/src/bento/index.ts +0 -2
  37. package/src/command/CommandPalette.tsx +0 -329
  38. package/src/command/CommandProvider.tsx +0 -57
  39. package/src/command/command-context.ts +0 -12
  40. package/src/command/index.ts +0 -6
  41. package/src/command/rank.ts +0 -50
  42. package/src/command/types.ts +0 -37
  43. package/src/command/useCommandSource.ts +0 -37
  44. package/src/dialogs/DialogsProvider.tsx +0 -216
  45. package/src/dialogs/Modal.tsx +0 -260
  46. package/src/dialogs/Toast.tsx +0 -85
  47. package/src/dialogs/dialogs-context.ts +0 -6
  48. package/src/dialogs/index.ts +0 -10
  49. package/src/dialogs/types.ts +0 -37
  50. package/src/dialogs/useDialogs.ts +0 -8
  51. package/src/editorial/EditorialSpotlight.tsx +0 -63
  52. package/src/editorial/Folio.tsx +0 -52
  53. package/src/editorial/PlateMarker.tsx +0 -33
  54. package/src/editorial/RomanSection.tsx +0 -65
  55. package/src/editorial/RunningMarginalia.tsx +0 -65
  56. package/src/editorial/index.ts +0 -10
  57. package/src/hooks/index.ts +0 -5
  58. package/src/hooks/useKeyboardHotkey.ts +0 -93
  59. package/src/hooks/useReducedMotion.ts +0 -20
  60. package/src/hooks/useViewport.ts +0 -61
  61. package/src/layout/Breadcrumb.tsx +0 -74
  62. package/src/layout/LeftNavRail.tsx +0 -139
  63. package/src/layout/MobileTabBar.tsx +0 -101
  64. package/src/layout/NavItem.tsx +0 -128
  65. package/src/layout/NavSearchTrigger.tsx +0 -88
  66. package/src/layout/NavSection.tsx +0 -40
  67. package/src/layout/RightSidebarPanel.tsx +0 -111
  68. package/src/layout/Shell.tsx +0 -91
  69. package/src/layout/SidePanel.tsx +0 -316
  70. package/src/layout/StickyBanner.tsx +0 -83
  71. package/src/layout/Topbar.tsx +0 -68
  72. package/src/layout/index.ts +0 -24
  73. package/src/layout/useNavRailState.ts +0 -69
  74. package/src/lib/time-utils.ts +0 -44
  75. package/src/neobrutalism/Marquee.tsx +0 -81
  76. package/src/neobrutalism/Sticker.tsx +0 -71
  77. package/src/neobrutalism/index.ts +0 -4
  78. package/src/primitives/Avatar.tsx +0 -53
  79. package/src/primitives/Button.tsx +0 -67
  80. package/src/primitives/Card.tsx +0 -41
  81. package/src/primitives/Checkbox.tsx +0 -87
  82. package/src/primitives/Chip.tsx +0 -191
  83. package/src/primitives/Combobox.tsx +0 -507
  84. package/src/primitives/CopyField.tsx +0 -139
  85. package/src/primitives/CountBadge.tsx +0 -50
  86. package/src/primitives/Input.tsx +0 -204
  87. package/src/primitives/Kbd.tsx +0 -45
  88. package/src/primitives/MentionCombobox.tsx +0 -612
  89. package/src/primitives/MultiCombobox.tsx +0 -327
  90. package/src/primitives/PageHeader.tsx +0 -77
  91. package/src/primitives/Radio.tsx +0 -131
  92. package/src/primitives/SegmentedControl.tsx +0 -135
  93. package/src/primitives/Select.tsx +0 -779
  94. package/src/primitives/SignaturePad.tsx +0 -461
  95. package/src/primitives/Tag.tsx +0 -56
  96. package/src/primitives/Textarea.tsx +0 -62
  97. package/src/primitives/ToggleSwitch.tsx +0 -79
  98. package/src/primitives/Tooltip.tsx +0 -213
  99. package/src/primitives/index.ts +0 -53
  100. package/src/pwa/InstallPromptBanner.tsx +0 -132
  101. package/src/pwa/index.ts +0 -4
  102. package/src/pwa/manifest.template.json +0 -20
  103. package/src/pwa/registerSW.ts +0 -55
  104. package/src/riso/Halftone.tsx +0 -85
  105. package/src/riso/Misregister.tsx +0 -63
  106. package/src/riso/RisoStamp.tsx +0 -76
  107. package/src/riso/index.ts +0 -3
  108. package/src/sketch/HandUnderline.tsx +0 -53
  109. package/src/sketch/RoughArrow.tsx +0 -91
  110. package/src/sketch/RoughBox.tsx +0 -73
  111. package/src/sketch/StickyNote.tsx +0 -56
  112. package/src/sketch/index.ts +0 -4
  113. package/src/styles/base.css +0 -186
  114. package/src/styles/chrome-ambient.css +0 -235
  115. package/src/styles/chrome-bento.css +0 -192
  116. package/src/styles/chrome-editorial.css +0 -168
  117. package/src/styles/chrome-neobrutalism.css +0 -326
  118. package/src/styles/chrome-riso.css +0 -339
  119. package/src/styles/chrome-sketch.css +0 -362
  120. package/src/styles/chrome-swiss.css +0 -265
  121. package/src/styles/chrome-terminal.css +0 -272
  122. package/src/styles/fonts.css +0 -1034
  123. package/src/styles/index.css +0 -343
  124. package/src/styles/tokens.css +0 -941
  125. package/src/terminal/AsciiBox.tsx +0 -65
  126. package/src/terminal/BrailleSpinner.tsx +0 -46
  127. package/src/terminal/index.ts +0 -4
  128. package/src/theme/ThemeProvider.tsx +0 -99
  129. package/src/theme/index.ts +0 -6
  130. package/src/theme/inline-script.ts +0 -40
  131. package/src/theme/theme-context.ts +0 -7
  132. package/src/theme/types.ts +0 -39
  133. package/src/theme/useTheme.ts +0 -8
@@ -1,326 +0,0 @@
1
- /* Neobrutalism chrome — component overrides.
2
- Token overrides live in tokens.css (palette + typography +
3
- shadow primitives). This file ships the signature interactions:
4
- 2 px black borders everywhere, 4 px offset hard shadows on
5
- interactive elements, and the hover-translate effect that
6
- pushes elements toward their shadow.
7
- Loads alongside index.css; takes effect only when
8
- html[data-ck-chrome="neobrutalism"] is set on the root. */
9
-
10
- html[data-ck-chrome="neobrutalism"] body {
11
- font-weight: 500;
12
- font-feature-settings: "kern", "ss01";
13
- }
14
-
15
- /* ===== Buttons ============================================== */
16
-
17
- /* Standard neobrut button — thick border, hard offset shadow.
18
- On hover the element translates toward its shadow and the
19
- shadow shrinks; on active it fully merges with the shadow.
20
- This "physical push" reads as the signature interaction. */
21
- html[data-ck-chrome="neobrutalism"] .ck-btn,
22
- html[data-ck-chrome="neobrutalism"] .ck-actionbar-btn {
23
- border: 2px solid var(--neobrut-ink);
24
- border-radius: 5px;
25
- box-shadow: 4px 4px 0 0 var(--neobrut-ink);
26
- font-family: var(--ck-font-sans);
27
- font-weight: 700;
28
- text-transform: none;
29
- letter-spacing: 0;
30
- transition: transform 120ms ease, box-shadow 120ms ease, background 120ms ease;
31
- }
32
- html[data-ck-chrome="neobrutalism"] .ck-btn:hover:not(:disabled),
33
- html[data-ck-chrome="neobrutalism"] .ck-actionbar-btn:hover:not(:disabled) {
34
- transform: translate(2px, 2px);
35
- box-shadow: 2px 2px 0 0 var(--neobrut-ink);
36
- }
37
- html[data-ck-chrome="neobrutalism"] .ck-btn:active:not(:disabled),
38
- html[data-ck-chrome="neobrutalism"] .ck-actionbar-btn:active:not(:disabled) {
39
- transform: translate(4px, 4px);
40
- box-shadow: 0 0 0 0 var(--neobrut-ink);
41
- }
42
-
43
- html[data-ck-chrome="neobrutalism"] .ck-btn--primary {
44
- background: var(--ck-accent);
45
- /* Defaults to black to pair with neobrutalism's saturated pastel
46
- accent; consumer apps may stamp --ck-accent-fg when overriding
47
- --ck-accent-light-override. */
48
- color: var(--ck-accent-fg, #000);
49
- }
50
- html[data-ck-chrome="neobrutalism"] .ck-btn--primary:hover:not(:disabled) {
51
- background: var(--ck-accent);
52
- }
53
- html[data-ck-chrome="neobrutalism"] .ck-btn--secondary,
54
- html[data-ck-chrome="neobrutalism"] .ck-btn--ghost {
55
- background: var(--ck-bg-surface);
56
- color: var(--ck-text-primary);
57
- }
58
- html[data-ck-chrome="neobrutalism"] .ck-btn--secondary:hover:not(:disabled),
59
- html[data-ck-chrome="neobrutalism"] .ck-btn--ghost:hover:not(:disabled) {
60
- background: var(--ck-bg-surface);
61
- }
62
-
63
- /* ===== Cards ================================================ */
64
-
65
- html[data-ck-chrome="neobrutalism"] .ck-card {
66
- background: var(--ck-bg-surface);
67
- border: 2px solid var(--neobrut-ink);
68
- border-radius: 5px;
69
- box-shadow: 4px 4px 0 0 var(--neobrut-ink);
70
- }
71
- /* No internal dividers + no footer tint — the reference card is
72
- one cohesive chunky surface. Header eyebrow / body / footer
73
- buttons all sit on the same near-black plane; chunky buttons
74
- inside the footer provide their own visual separation via
75
- border + shadow. */
76
- html[data-ck-chrome="neobrutalism"] .ck-card__head {
77
- border-bottom: none;
78
- padding: 24px 24px 0;
79
- }
80
- html[data-ck-chrome="neobrutalism"] .ck-card__body {
81
- padding: 16px 24px;
82
- }
83
- html[data-ck-chrome="neobrutalism"] .ck-card__foot {
84
- border-top: none;
85
- background: transparent;
86
- padding: 0 24px 24px;
87
- }
88
-
89
- /* ===== Inputs / Textareas =================================== */
90
-
91
- html[data-ck-chrome="neobrutalism"] .ck-input,
92
- html[data-ck-chrome="neobrutalism"] .ck-textarea {
93
- border: 2px solid var(--neobrut-ink);
94
- border-radius: 5px;
95
- font-family: var(--ck-font-sans);
96
- font-weight: 500;
97
- background: #FFFFFF;
98
- color: #000000;
99
- transition: box-shadow 120ms ease;
100
- }
101
- html[data-ck-theme="dark"][data-ck-chrome="neobrutalism"] .ck-input,
102
- html[data-ck-theme="dark"][data-ck-chrome="neobrutalism"] .ck-textarea {
103
- background: var(--ck-bg-surface);
104
- color: var(--ck-text-primary);
105
- }
106
- html[data-ck-chrome="neobrutalism"] .ck-input:focus-visible,
107
- html[data-ck-chrome="neobrutalism"] .ck-textarea:focus-visible {
108
- outline: none;
109
- border-color: var(--neobrut-ink) !important;
110
- box-shadow: 4px 4px 0 0 var(--neobrut-ink);
111
- }
112
-
113
- /* ===== Typography =========================================== */
114
-
115
- html[data-ck-chrome="neobrutalism"] h1,
116
- html[data-ck-chrome="neobrutalism"] .ck-h1 {
117
- font-family: var(--ck-font-display);
118
- font-weight: 900;
119
- letter-spacing: -0.02em;
120
- line-height: 1;
121
- }
122
- html[data-ck-chrome="neobrutalism"] h2,
123
- html[data-ck-chrome="neobrutalism"] .ck-h2 {
124
- font-family: var(--ck-font-display);
125
- font-weight: 800;
126
- letter-spacing: -0.01em;
127
- line-height: 1.05;
128
- }
129
- html[data-ck-chrome="neobrutalism"] h3,
130
- html[data-ck-chrome="neobrutalism"] .ck-h3 {
131
- font-weight: 700;
132
- letter-spacing: -0.005em;
133
- }
134
-
135
- /* Eyebrow / tag — neobrut versions are filled pills, not the
136
- tracked uppercase the editorial chrome uses. */
137
- html[data-ck-chrome="neobrutalism"] .ck-tag {
138
- letter-spacing: 0.02em;
139
- font-weight: 700;
140
- }
141
-
142
- /* ===== Action bar =========================================== */
143
-
144
- html[data-ck-chrome="neobrutalism"] [data-ck-actionbar] {
145
- border: 2px solid var(--neobrut-ink);
146
- border-radius: 5px;
147
- box-shadow: 4px 4px 0 0 var(--neobrut-ink);
148
- background: var(--ck-bg-surface);
149
- }
150
-
151
- /* ===== Layout chrome ======================================== */
152
-
153
- /* Sidebar + topbar both pin to --ck-bg-surface so the chrome
154
- layer is visually unified (light: paper white; dark: dark
155
- gray near-black). The canvas behind the main content stays
156
- the distinctive hue — cream in light, navy in dark — and the
157
- chrome reads as a separate band around it.
158
- Topbar gets !important too because <Topbar> sets bg via
159
- inline style and we want this override to win across chromes. */
160
- html[data-ck-chrome="neobrutalism"] [data-ck-leftnav],
161
- html[data-ck-chrome="neobrutalism"] [data-ck-topbar] {
162
- background: var(--ck-bg-surface) !important;
163
- }
164
- html[data-ck-chrome="neobrutalism"] [data-ck-leftnav] {
165
- border-right: 2px solid var(--neobrut-ink);
166
- }
167
- html[data-ck-chrome="neobrutalism"] [data-ck-topbar] {
168
- border-bottom: 2px solid var(--neobrut-ink);
169
- }
170
-
171
- /* ===== NavItem ============================================== */
172
-
173
- /* Active state — accent fill, 2 px black border, hard black
174
- offset shadow, black text. The reference site reserves the
175
- chunky treatment for the active item; inactive rows are flat
176
- text on the sidebar surface so the active one truly stands
177
- out. Earlier I made every row chunky and it read noisy. */
178
- html[data-ck-chrome="neobrutalism"] [data-ck-navitem][data-active="true"] {
179
- background: var(--ck-accent) !important;
180
- color: #000 !important;
181
- border: 2px solid var(--neobrut-ink) !important;
182
- box-shadow: 3px 3px 0 0 var(--neobrut-ink) !important;
183
- border-radius: 5px !important;
184
- font-weight: 700 !important;
185
- }
186
- html[data-ck-chrome="neobrutalism"] [data-ck-navitem]:not([data-active="true"]) {
187
- background: transparent !important;
188
- border: 2px solid transparent !important;
189
- font-weight: 600 !important;
190
- color: var(--ck-text-primary) !important;
191
- }
192
- html[data-ck-chrome="neobrutalism"] [data-ck-navitem]:not([data-active="true"]):hover {
193
- background: var(--ck-bg-canvas) !important;
194
- }
195
-
196
- /* ===== Search trigger ====================================== */
197
-
198
- html[data-ck-chrome="neobrutalism"] [data-ck-search-trigger] {
199
- background: var(--ck-bg-surface) !important;
200
- border: 2px solid var(--neobrut-ink) !important;
201
- border-radius: 5px !important;
202
- box-shadow: 3px 3px 0 0 var(--neobrut-ink) !important;
203
- }
204
- html[data-ck-chrome="neobrutalism"] [data-ck-search-trigger]:hover {
205
- transform: translate(1.5px, 1.5px);
206
- box-shadow: 1.5px 1.5px 0 0 var(--neobrut-ink) !important;
207
- transition: transform 120ms ease, box-shadow 120ms ease;
208
- }
209
-
210
- /* ===== Tags ================================================= */
211
-
212
- /* Every tag becomes a chunky filled pill with 2 px border + a
213
- small hard shadow. Both filled and bare variants get the same
214
- physical treatment — neobrutalism doesn't do "bare label".
215
- Tone-specific colours come from the inline style on the
216
- component; we just add the structural overrides. */
217
- html[data-ck-chrome="neobrutalism"] [data-ck-tag] {
218
- padding: 3px 8px !important;
219
- border: 2px solid var(--neobrut-ink) !important;
220
- border-radius: 4px !important;
221
- box-shadow: 2px 2px 0 0 var(--neobrut-ink) !important;
222
- font-weight: 700 !important;
223
- letter-spacing: 0.04em !important;
224
- /* Text on the saturated-tone fill is pure black in both modes —
225
- same as main-foreground in the reference. */
226
- color: #000 !important;
227
- }
228
-
229
- /* Bare tags (no `filled` prop) — set background from tone via
230
- data-tone selector so the chunky pill still pops. */
231
- html[data-ck-chrome="neobrutalism"] [data-ck-tag]:not([data-filled="true"])[data-tone="accent"] {
232
- background: var(--ck-accent) !important;
233
- }
234
- html[data-ck-chrome="neobrutalism"] [data-ck-tag]:not([data-filled="true"])[data-tone="success"] {
235
- background: var(--ck-success) !important;
236
- }
237
- html[data-ck-chrome="neobrutalism"] [data-ck-tag]:not([data-filled="true"])[data-tone="warning"] {
238
- background: var(--ck-warning) !important;
239
- }
240
- html[data-ck-chrome="neobrutalism"] [data-ck-tag]:not([data-filled="true"])[data-tone="critical"] {
241
- background: var(--ck-critical) !important;
242
- }
243
- html[data-ck-chrome="neobrutalism"] [data-ck-tag]:not([data-filled="true"])[data-tone="neutral"] {
244
- background: var(--ck-bg-surface) !important;
245
- }
246
-
247
- /* ===== Modal backdrop ======================================= */
248
-
249
- html[data-ck-chrome="neobrutalism"] [role="dialog"] > div:first-child {
250
- background: rgba(0, 0, 0, 0.4);
251
- backdrop-filter: none;
252
- }
253
- /* Modals get a bigger 8 px shadow per brief — heavier than
254
- ambient cards because they demand attention. */
255
- html[data-ck-chrome="neobrutalism"] [role="dialog"] > div > div {
256
- border: 2px solid var(--neobrut-ink);
257
- border-radius: 8px;
258
- box-shadow: 8px 8px 0 0 var(--neobrut-ink);
259
- }
260
-
261
- /* ===== ChromeCard (docs theming page) =======================
262
- Any button with aria-pressed (the chrome-picker cards on
263
- /theming) — both active and inactive get the chunky 2 px
264
- border + offset shadow. Active also gets the accent fill +
265
- black-text override. */
266
- html[data-ck-chrome="neobrutalism"] button[aria-pressed] {
267
- border: 2px solid var(--neobrut-ink) !important;
268
- border-radius: 6px !important;
269
- box-shadow: 4px 4px 0 0 var(--neobrut-ink) !important;
270
- transition: transform 120ms ease, box-shadow 120ms ease,
271
- background 120ms ease !important;
272
- }
273
- html[data-ck-chrome="neobrutalism"] button[aria-pressed]:hover {
274
- transform: translate(2px, 2px);
275
- box-shadow: 2px 2px 0 0 var(--neobrut-ink) !important;
276
- }
277
- html[data-ck-chrome="neobrutalism"] button[aria-pressed="true"] {
278
- background: var(--ck-accent) !important;
279
- color: #000 !important;
280
- }
281
- html[data-ck-chrome="neobrutalism"] button[aria-pressed="true"] * {
282
- color: #000 !important;
283
- }
284
-
285
- /* ===== Marquee animation ==================================== */
286
-
287
- @keyframes ck-neobrut-marquee {
288
- from {
289
- transform: translateX(0);
290
- }
291
- to {
292
- transform: translateX(-50%);
293
- }
294
- }
295
-
296
- /* ===== Toggle / Checkbox visual touch ======================== */
297
-
298
- html[data-ck-chrome="neobrutalism"] [role="checkbox"],
299
- html[data-ck-chrome="neobrutalism"] [role="switch"] {
300
- border-width: 2px !important;
301
- border-color: var(--neobrut-ink) !important;
302
- border-radius: 4px;
303
- }
304
- html[data-ck-chrome="neobrutalism"] [role="switch"] {
305
- border-radius: 999px;
306
- }
307
-
308
- @media (prefers-reduced-motion: reduce) {
309
- html[data-ck-chrome="neobrutalism"] .ck-btn,
310
- html[data-ck-chrome="neobrutalism"] .ck-actionbar-btn {
311
- transition: none;
312
- }
313
- html[data-ck-chrome="neobrutalism"] .ck-btn:hover:not(:disabled),
314
- html[data-ck-chrome="neobrutalism"] .ck-actionbar-btn:hover:not(:disabled) {
315
- transform: none;
316
- box-shadow: 4px 4px 0 0 var(--neobrut-ink);
317
- }
318
- }
319
-
320
- html[data-ck-chrome="neobrutalism"] .ck-actionbar-panel,
321
- html[data-ck-chrome="neobrutalism"] .ck-actionbar-toast {
322
- border: 2px solid var(--neobrut-ink);
323
- border-radius: 5px;
324
- box-shadow: 4px 4px 0 0 var(--neobrut-ink);
325
- background: var(--ck-bg-surface);
326
- }
@@ -1,339 +0,0 @@
1
- /* Risograph / Zine Print chrome — DIY print culture as a digital
2
- aesthetic. Paper canvas + fluorescent ink + halftone dots + ink-
3
- offset duplicates instead of soft drop shadows + slight rotation
4
- on tags / cards. Anti-glossy, anti-gradient.
5
-
6
- Implementation notes:
7
- - Paper noise is stamped on body via ::before so it sits behind
8
- all content but inside the chrome scope.
9
- - "Shadows" in this chrome are not box-shadow blur — they are
10
- offset solid blocks (3-4px translate, second ink color, no blur).
11
- - Tags/cards get a tiny rotation via `transform: rotate(...)`.
12
- We override the existing transform so neobrutalism-style
13
- hover-translate isn't accidentally inherited.
14
- - Body is set to a display-leaning sans; we don't bundle a
15
- specific indie face — consumers can layer one on top via
16
- `--ck-font-sans`. */
17
-
18
- html[data-ck-chrome="riso"] body {
19
- font-family: "Helvetica Neue", "Inter", var(--ck-font-sans);
20
- font-weight: 500;
21
- position: relative;
22
- }
23
-
24
- /* Paper grain overlay — sits on body, pointer-events off. */
25
- html[data-ck-chrome="riso"] body::before {
26
- content: "";
27
- position: fixed;
28
- inset: 0;
29
- pointer-events: none;
30
- background-image: var(--ck-riso-paper);
31
- background-size: 240px 240px;
32
- mix-blend-mode: multiply;
33
- opacity: 0.55;
34
- z-index: 9999;
35
- }
36
- html[data-ck-theme="dark"][data-ck-chrome="riso"] body::before {
37
- mix-blend-mode: screen;
38
- opacity: 0.18;
39
- }
40
-
41
- /* Display headings — chunky, slightly tighter tracking, raw ink */
42
- html[data-ck-chrome="riso"] h1,
43
- html[data-ck-chrome="riso"] .ck-h1 {
44
- font-weight: 900;
45
- letter-spacing: -0.02em;
46
- line-height: 0.95;
47
- text-transform: none;
48
- }
49
- html[data-ck-chrome="riso"] h2,
50
- html[data-ck-chrome="riso"] .ck-h2 {
51
- font-weight: 800;
52
- letter-spacing: -0.01em;
53
- line-height: 1.05;
54
- }
55
- html[data-ck-chrome="riso"] h3,
56
- html[data-ck-chrome="riso"] .ck-h3 {
57
- font-weight: 700;
58
- letter-spacing: -0.005em;
59
- }
60
-
61
- /* ---------- Buttons — flat ink + offset duplicate "shadow" ---------- */
62
- html[data-ck-chrome="riso"] .ck-btn,
63
- html[data-ck-chrome="riso"] .ck-actionbar-btn {
64
- border-radius: 4px;
65
- font-weight: 700;
66
- letter-spacing: 0.01em;
67
- text-transform: uppercase;
68
- font-size: 12px;
69
- height: 38px;
70
- padding: 0 16px;
71
- border: 2px solid var(--ck-text-primary);
72
- box-shadow: 3px 3px 0 var(--ck-text-primary);
73
- transition: transform 90ms ease, box-shadow 90ms ease, background 90ms ease;
74
- }
75
- html[data-ck-chrome="riso"] .ck-btn:hover:not(:disabled),
76
- html[data-ck-chrome="riso"] .ck-actionbar-btn:hover:not(:disabled) {
77
- transform: translate(1px, 1px);
78
- box-shadow: 2px 2px 0 var(--ck-text-primary);
79
- }
80
- html[data-ck-chrome="riso"] .ck-btn:active:not(:disabled),
81
- html[data-ck-chrome="riso"] .ck-actionbar-btn:active:not(:disabled) {
82
- transform: translate(3px, 3px);
83
- box-shadow: 0 0 0 var(--ck-text-primary);
84
- }
85
-
86
- html[data-ck-chrome="riso"] .ck-btn--primary,
87
- html[data-ck-chrome="riso"] .ck-actionbar-btn--primary {
88
- background: var(--ck-accent);
89
- /* Defaults to near-black to pair with riso's pink ink accent;
90
- consumer apps may stamp --ck-accent-fg when overriding
91
- --ck-accent-light-override. */
92
- color: var(--ck-accent-fg, #1A1A1A);
93
- box-shadow: 3px 3px 0 var(--ck-riso-blue);
94
- }
95
- html[data-ck-chrome="riso"] .ck-btn--primary:hover:not(:disabled),
96
- html[data-ck-chrome="riso"] .ck-actionbar-btn--primary:hover:not(:disabled) {
97
- background: var(--ck-accent-hover);
98
- box-shadow: 2px 2px 0 var(--ck-riso-blue);
99
- }
100
- html[data-ck-chrome="riso"] .ck-btn--primary:active:not(:disabled),
101
- html[data-ck-chrome="riso"] .ck-actionbar-btn--primary:active:not(:disabled) {
102
- box-shadow: 0 0 0 var(--ck-riso-blue);
103
- }
104
-
105
- html[data-ck-chrome="riso"] .ck-btn--secondary {
106
- background: var(--ck-bg-surface);
107
- color: var(--ck-text-primary);
108
- }
109
- html[data-ck-chrome="riso"] .ck-btn--ghost {
110
- background: transparent;
111
- border-color: transparent;
112
- box-shadow: none;
113
- color: var(--ck-text-primary);
114
- text-decoration: underline;
115
- text-decoration-thickness: 2px;
116
- text-underline-offset: 4px;
117
- }
118
- html[data-ck-chrome="riso"] .ck-btn--ghost:hover:not(:disabled) {
119
- background: transparent;
120
- transform: none;
121
- box-shadow: none;
122
- color: var(--ck-accent);
123
- }
124
-
125
- /* ---------- Inputs — underline-only, ink underline ---------- */
126
- html[data-ck-chrome="riso"] .ck-input,
127
- html[data-ck-chrome="riso"] .ck-textarea {
128
- background: transparent;
129
- border: none;
130
- border-bottom: 2px solid var(--ck-text-primary);
131
- border-radius: 0;
132
- padding-left: 0;
133
- padding-right: 0;
134
- box-shadow: none;
135
- font-weight: 500;
136
- color: var(--ck-text-primary);
137
- }
138
- html[data-ck-chrome="riso"] .ck-input::placeholder,
139
- html[data-ck-chrome="riso"] .ck-textarea::placeholder {
140
- color: var(--ck-text-tertiary);
141
- font-style: italic;
142
- }
143
- html[data-ck-chrome="riso"] .ck-input:focus-visible,
144
- html[data-ck-chrome="riso"] .ck-textarea:focus-visible {
145
- outline: none;
146
- border-bottom-color: var(--ck-accent) !important;
147
- box-shadow: none !important;
148
- }
149
-
150
- /* ---------- Cards — paper plate with offset ink block ---------- */
151
- html[data-ck-chrome="riso"] .ck-card {
152
- background: var(--ck-bg-surface);
153
- border: 2px solid var(--ck-text-primary);
154
- border-radius: 4px;
155
- box-shadow: 5px 5px 0 var(--ck-riso-pink);
156
- overflow: visible;
157
- }
158
- html[data-ck-chrome="riso"] .ck-card__head {
159
- background: transparent;
160
- border-bottom: 2px dashed var(--ck-border-subtle);
161
- padding: 14px 20px;
162
- font-weight: 700;
163
- letter-spacing: 0.02em;
164
- text-transform: uppercase;
165
- font-size: 12px;
166
- }
167
- html[data-ck-chrome="riso"] .ck-card__foot {
168
- background: transparent;
169
- border-top: 2px dashed var(--ck-border-subtle);
170
- padding: 12px 20px;
171
- }
172
-
173
- /* Dark mode — switch offset ink to a more legible color on navy */
174
- html[data-ck-theme="dark"][data-ck-chrome="riso"] .ck-card {
175
- box-shadow: 5px 5px 0 var(--ck-riso-pink);
176
- border-color: var(--ck-text-primary);
177
- }
178
-
179
- /* ---------- Tags — rubber-stamp feel ---------- */
180
- html[data-ck-chrome="riso"] [data-ck-tag] {
181
- background: transparent !important;
182
- border: 2px solid var(--ck-text-primary) !important;
183
- border-radius: 4px !important;
184
- padding: 3px 8px !important;
185
- font-weight: 800 !important;
186
- font-size: 10px !important;
187
- letter-spacing: 0.08em !important;
188
- text-transform: uppercase !important;
189
- box-shadow: 2px 2px 0 var(--ck-text-primary) !important;
190
- color: var(--ck-text-primary) !important;
191
- display: inline-block !important;
192
- transform: rotate(-2deg);
193
- transform-origin: center;
194
- }
195
- html[data-ck-chrome="riso"] [data-ck-tag][data-tone="accent"] {
196
- background: var(--ck-riso-pink) !important;
197
- color: #1A1A1A !important;
198
- box-shadow: 2px 2px 0 var(--ck-riso-blue) !important;
199
- }
200
- html[data-ck-chrome="riso"] [data-ck-tag][data-tone="success"] {
201
- background: var(--ck-riso-yellow) !important;
202
- color: #1A1A1A !important;
203
- box-shadow: 2px 2px 0 var(--ck-riso-green) !important;
204
- }
205
- html[data-ck-chrome="riso"] [data-ck-tag][data-tone="warning"] {
206
- background: var(--ck-riso-orange) !important;
207
- color: #1A1A1A !important;
208
- box-shadow: 2px 2px 0 var(--ck-text-primary) !important;
209
- }
210
- html[data-ck-chrome="riso"] [data-ck-tag][data-tone="critical"] {
211
- background: var(--ck-riso-red) !important;
212
- color: #F8F1DE !important;
213
- box-shadow: 2px 2px 0 var(--ck-text-primary) !important;
214
- }
215
- html[data-ck-chrome="riso"] [data-ck-tag][data-tone="neutral"] {
216
- background: transparent !important;
217
- color: var(--ck-text-primary) !important;
218
- box-shadow: 2px 2px 0 var(--ck-text-primary) !important;
219
- }
220
-
221
- /* ---------- Layout chrome — paper sidebar + topbar ---------- */
222
- html[data-ck-chrome="riso"] [data-ck-leftnav] {
223
- background: var(--ck-bg-sidebar) !important;
224
- border-right: 2px solid var(--ck-text-primary);
225
- }
226
-
227
- html[data-ck-chrome="riso"] [data-ck-topbar] {
228
- background: var(--ck-bg-canvas) !important;
229
- border-bottom: 2px solid var(--ck-text-primary);
230
- }
231
-
232
- /* NavItem — flat hover, riso ink block on active */
233
- html[data-ck-chrome="riso"] [data-ck-navitem] {
234
- background: transparent !important;
235
- border-radius: 4px !important;
236
- font-weight: 600 !important;
237
- color: var(--ck-text-primary) !important;
238
- transition: background 120ms ease, color 120ms ease;
239
- }
240
- html[data-ck-chrome="riso"] [data-ck-navitem]:not([data-active="true"]):hover {
241
- background: var(--ck-bg-muted) !important;
242
- }
243
- html[data-ck-chrome="riso"] [data-ck-navitem][data-active="true"] {
244
- background: var(--ck-riso-pink) !important;
245
- color: #1A1A1A !important;
246
- font-weight: 800 !important;
247
- box-shadow: 3px 3px 0 var(--ck-riso-blue) !important;
248
- }
249
-
250
- /* Search trigger — underlined input feel */
251
- html[data-ck-chrome="riso"] [data-ck-search-trigger] {
252
- background: var(--ck-bg-surface) !important;
253
- border: 2px solid var(--ck-text-primary) !important;
254
- border-radius: 4px !important;
255
- box-shadow: 3px 3px 0 var(--ck-riso-yellow) !important;
256
- color: var(--ck-text-primary) !important;
257
- font-weight: 600 !important;
258
- text-transform: uppercase;
259
- letter-spacing: 0.05em;
260
- font-size: 11px;
261
- }
262
-
263
- /* Action bar — paper plate with offset ink block, no rounding */
264
- html[data-ck-chrome="riso"] [data-ck-actionbar] {
265
- background: var(--ck-bg-surface) !important;
266
- border: 2px solid var(--ck-text-primary);
267
- border-radius: 4px;
268
- box-shadow: 5px 5px 0 var(--ck-riso-blue);
269
- }
270
-
271
- /* Modal — paper plate, no blur */
272
- html[data-ck-chrome="riso"] [role="dialog"] > div:first-child {
273
- background: rgba(26, 26, 26, 0.45);
274
- backdrop-filter: none;
275
- }
276
- html[data-ck-chrome="riso"] [role="dialog"] > div > div {
277
- background: var(--ck-bg-surface) !important;
278
- border: 2px solid var(--ck-text-primary);
279
- border-radius: 4px;
280
- box-shadow: 6px 6px 0 var(--ck-riso-pink);
281
- }
282
-
283
- /* Code blocks — bordered paper with offset block */
284
- html[data-ck-chrome="riso"] pre {
285
- background: var(--ck-bg-surface) !important;
286
- border: 2px solid var(--ck-text-primary);
287
- border-radius: 4px;
288
- box-shadow: 4px 4px 0 var(--ck-riso-yellow);
289
- font-family: "Courier Prime", "Courier New", var(--ck-font-mono);
290
- }
291
- html[data-ck-chrome="riso"] code {
292
- background: var(--ck-riso-yellow) !important;
293
- color: var(--ck-text-primary) !important;
294
- padding: 1px 6px;
295
- font-family: "Courier Prime", "Courier New", var(--ck-font-mono);
296
- border-radius: 2px;
297
- }
298
-
299
- /* Dividers — dashed by default under riso */
300
- html[data-ck-chrome="riso"] hr {
301
- border: none;
302
- border-top: 2px dashed var(--ck-text-primary);
303
- margin: 24px 0;
304
- opacity: 0.6;
305
- }
306
-
307
- /* Halftone helper class — apply to any element for shaded ink fill.
308
- Set `color: var(--ck-riso-pink)` on the element to control the
309
- dot color, then add this class. */
310
- .ck-riso-halftone {
311
- background-image: var(--ck-riso-halftone, radial-gradient(circle, currentColor 1.4px, transparent 1.6px));
312
- background-size: 7px 7px;
313
- background-repeat: repeat;
314
- }
315
-
316
- /* Crop-mark helper — opt-in via .ck-riso-marks on a positioned
317
- container; corners get registration `+` glyphs. */
318
- .ck-riso-marks {
319
- position: relative;
320
- }
321
- .ck-riso-marks::before,
322
- .ck-riso-marks::after {
323
- content: "+";
324
- position: absolute;
325
- font: 700 18px/1 "Courier Prime", "Courier New", monospace;
326
- color: currentColor;
327
- opacity: 0.5;
328
- pointer-events: none;
329
- }
330
- .ck-riso-marks::before { top: 4px; left: 8px; }
331
- .ck-riso-marks::after { bottom: 4px; right: 8px; }
332
-
333
- html[data-ck-chrome="riso"] .ck-actionbar-panel,
334
- html[data-ck-chrome="riso"] .ck-actionbar-toast {
335
- background: var(--ck-bg-surface);
336
- border: 2px solid var(--ck-text-primary);
337
- border-radius: 4px;
338
- box-shadow: 5px 5px 0 var(--ck-riso-blue);
339
- }