notra-editor 0.7.0 → 0.8.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.
@@ -1,16 +1,971 @@
1
- @import './shared.css';
1
+ @charset "UTF-8";
2
+ :root {
3
+ /******************
4
+ Basics
5
+ ******************/
6
+ overflow-wrap: break-word;
7
+ text-size-adjust: none;
8
+ text-rendering: optimizeLegibility;
9
+ -webkit-font-smoothing: antialiased;
10
+ -moz-osx-font-smoothing: grayscale;
11
+ /******************
12
+ Colors variables
13
+ ******************/
14
+ /* Gray alpha (light mode) */
15
+ --tt-gray-light-a-50: rgba(56, 56, 56, 0.04);
16
+ --tt-gray-light-a-100: rgba(15, 22, 36, 0.05);
17
+ --tt-gray-light-a-200: rgba(37, 39, 45, 0.1);
18
+ --tt-gray-light-a-300: rgba(47, 50, 55, 0.2);
19
+ --tt-gray-light-a-400: rgba(40, 44, 51, 0.42);
20
+ --tt-gray-light-a-500: rgba(52, 55, 60, 0.64);
21
+ --tt-gray-light-a-600: rgba(36, 39, 46, 0.78);
22
+ --tt-gray-light-a-700: rgba(35, 37, 42, 0.87);
23
+ --tt-gray-light-a-800: rgba(30, 32, 36, 0.95);
24
+ --tt-gray-light-a-900: rgba(29, 30, 32, 0.98);
25
+ /* Gray (light mode) */
26
+ --tt-gray-light-50: rgba(250, 250, 250, 1);
27
+ --tt-gray-light-100: rgba(244, 244, 245, 1);
28
+ --tt-gray-light-200: rgba(234, 234, 235, 1);
29
+ --tt-gray-light-300: rgba(213, 214, 215, 1);
30
+ --tt-gray-light-400: rgba(166, 167, 171, 1);
31
+ --tt-gray-light-500: rgba(125, 127, 130, 1);
32
+ --tt-gray-light-600: rgba(83, 86, 90, 1);
33
+ --tt-gray-light-700: rgba(64, 65, 69, 1);
34
+ --tt-gray-light-800: rgba(44, 45, 48, 1);
35
+ --tt-gray-light-900: rgba(34, 35, 37, 1);
36
+ /* Gray alpha (dark mode) */
37
+ --tt-gray-dark-a-50: rgba(232, 232, 253, 0.05);
38
+ --tt-gray-dark-a-100: rgba(231, 231, 243, 0.07);
39
+ --tt-gray-dark-a-200: rgba(238, 238, 246, 0.11);
40
+ --tt-gray-dark-a-300: rgba(239, 239, 245, 0.22);
41
+ --tt-gray-dark-a-400: rgba(244, 244, 255, 0.37);
42
+ --tt-gray-dark-a-500: rgba(236, 238, 253, 0.5);
43
+ --tt-gray-dark-a-600: rgba(247, 247, 253, 0.64);
44
+ --tt-gray-dark-a-700: rgba(251, 251, 254, 0.75);
45
+ --tt-gray-dark-a-800: rgba(253, 253, 253, 0.88);
46
+ --tt-gray-dark-a-900: rgba(255, 255, 255, 0.96);
47
+ /* Gray (dark mode) */
48
+ --tt-gray-dark-50: rgba(25, 25, 26, 1);
49
+ --tt-gray-dark-100: rgba(32, 32, 34, 1);
50
+ --tt-gray-dark-200: rgba(45, 45, 47, 1);
51
+ --tt-gray-dark-300: rgba(70, 70, 73, 1);
52
+ --tt-gray-dark-400: rgba(99, 99, 105, 1);
53
+ --tt-gray-dark-500: rgba(124, 124, 131, 1);
54
+ --tt-gray-dark-600: rgba(163, 163, 168, 1);
55
+ --tt-gray-dark-700: rgba(192, 192, 195, 1);
56
+ --tt-gray-dark-800: rgba(224, 224, 225, 1);
57
+ --tt-gray-dark-900: rgba(245, 245, 245, 1);
58
+ /* Brand colors */
59
+ --tt-brand-color-50: rgba(239, 238, 255, 1);
60
+ --tt-brand-color-100: rgba(222, 219, 255, 1);
61
+ --tt-brand-color-200: rgba(195, 189, 255, 1);
62
+ --tt-brand-color-300: rgba(157, 138, 255, 1);
63
+ --tt-brand-color-400: rgba(122, 82, 255, 1);
64
+ --tt-brand-color-500: rgba(98, 41, 255, 1);
65
+ --tt-brand-color-600: rgba(84, 0, 229, 1);
66
+ --tt-brand-color-700: rgba(75, 0, 204, 1);
67
+ --tt-brand-color-800: rgba(56, 0, 153, 1);
68
+ --tt-brand-color-900: rgba(43, 25, 102, 1);
69
+ --tt-brand-color-950: hsla(257, 100%, 9%, 1);
70
+ /* Green */
71
+ --tt-color-green-inc-5: hsla(129, 100%, 97%, 1);
72
+ --tt-color-green-inc-4: hsla(129, 100%, 92%, 1);
73
+ --tt-color-green-inc-3: hsla(131, 100%, 86%, 1);
74
+ --tt-color-green-inc-2: hsla(133, 98%, 78%, 1);
75
+ --tt-color-green-inc-1: hsla(137, 99%, 70%, 1);
76
+ --tt-color-green-base: hsla(147, 99%, 50%, 1);
77
+ --tt-color-green-dec-1: hsla(147, 97%, 41%, 1);
78
+ --tt-color-green-dec-2: hsla(146, 98%, 32%, 1);
79
+ --tt-color-green-dec-3: hsla(146, 100%, 24%, 1);
80
+ --tt-color-green-dec-4: hsla(144, 100%, 16%, 1);
81
+ --tt-color-green-dec-5: hsla(140, 100%, 9%, 1);
82
+ /* Yellow */
83
+ --tt-color-yellow-inc-5: hsla(50, 100%, 97%, 1);
84
+ --tt-color-yellow-inc-4: hsla(50, 100%, 91%, 1);
85
+ --tt-color-yellow-inc-3: hsla(50, 100%, 84%, 1);
86
+ --tt-color-yellow-inc-2: hsla(50, 100%, 77%, 1);
87
+ --tt-color-yellow-inc-1: hsla(50, 100%, 68%, 1);
88
+ --tt-color-yellow-base: hsla(52, 100%, 50%, 1);
89
+ --tt-color-yellow-dec-1: hsla(52, 100%, 41%, 1);
90
+ --tt-color-yellow-dec-2: hsla(52, 100%, 32%, 1);
91
+ --tt-color-yellow-dec-3: hsla(52, 100%, 24%, 1);
92
+ --tt-color-yellow-dec-4: hsla(51, 100%, 16%, 1);
93
+ --tt-color-yellow-dec-5: hsla(50, 100%, 9%, 1);
94
+ /* Red */
95
+ --tt-color-red-inc-5: hsla(11, 100%, 96%, 1);
96
+ --tt-color-red-inc-4: hsla(11, 100%, 88%, 1);
97
+ --tt-color-red-inc-3: hsla(10, 100%, 80%, 1);
98
+ --tt-color-red-inc-2: hsla(9, 100%, 73%, 1);
99
+ --tt-color-red-inc-1: hsla(7, 100%, 64%, 1);
100
+ --tt-color-red-base: hsla(7, 100%, 54%, 1);
101
+ --tt-color-red-dec-1: hsla(7, 100%, 41%, 1);
102
+ --tt-color-red-dec-2: hsla(5, 100%, 32%, 1);
103
+ --tt-color-red-dec-3: hsla(4, 100%, 24%, 1);
104
+ --tt-color-red-dec-4: hsla(3, 100%, 16%, 1);
105
+ --tt-color-red-dec-5: hsla(1, 100%, 9%, 1);
106
+ /* Basic colors */
107
+ --white: rgba(255, 255, 255, 1);
108
+ --black: rgba(14, 14, 17, 1);
109
+ --transparent: rgba(255, 255, 255, 0);
110
+ /******************
111
+ Shadow variables
112
+ ******************/
113
+ /* Shadows Light */
114
+ --tt-shadow-elevated-md:
115
+ 0px 16px 48px 0px rgba(17, 24, 39, 0.04),
116
+ 0px 12px 24px 0px rgba(17, 24, 39, 0.04),
117
+ 0px 6px 8px 0px rgba(17, 24, 39, 0.02),
118
+ 0px 2px 3px 0px rgba(17, 24, 39, 0.02);
119
+ /**************************************************
120
+ Radius variables
121
+ **************************************************/
122
+ --tt-radius-xxs: 0.125rem; /* 2px */
123
+ --tt-radius-xs: 0.25rem; /* 4px */
124
+ --tt-radius-sm: 0.375rem; /* 6px */
125
+ --tt-radius-md: 0.5rem; /* 8px */
126
+ --tt-radius-lg: 0.75rem; /* 12px */
127
+ --tt-radius-xl: 1rem; /* 16px */
128
+ /**************************************************
129
+ Transition variables
130
+ **************************************************/
131
+ --tt-transition-duration-short: 0.1s;
132
+ --tt-transition-duration-default: 0.2s;
133
+ --tt-transition-duration-long: 0.64s;
134
+ --tt-transition-easing-default: cubic-bezier(0.46, 0.03, 0.52, 0.96);
135
+ --tt-transition-easing-cubic: cubic-bezier(0.65, 0.05, 0.36, 1);
136
+ --tt-transition-easing-quart: cubic-bezier(0.77, 0, 0.18, 1);
137
+ --tt-transition-easing-circ: cubic-bezier(0.79, 0.14, 0.15, 0.86);
138
+ --tt-transition-easing-back: cubic-bezier(0.68, -0.55, 0.27, 1.55);
139
+ /******************
140
+ Contrast variables
141
+ ******************/
142
+ --tt-accent-contrast: 8%;
143
+ --tt-destructive-contrast: 8%;
144
+ --tt-foreground-contrast: 8%;
145
+ }
146
+ :root,
147
+ :root *,
148
+ :root ::before,
149
+ :root ::after {
150
+ box-sizing: border-box;
151
+ transition: none var(--tt-transition-duration-default) var(--tt-transition-easing-default);
152
+ }
153
+
154
+ :root {
155
+ /**************************************************
156
+ Global colors
157
+ **************************************************/
158
+ /* Global colors - Light mode */
159
+ --tt-bg-color: var(--white);
160
+ --tt-border-color: var(--tt-gray-light-a-200);
161
+ --tt-border-color-tint: var(--tt-gray-light-a-100);
162
+ --tt-sidebar-bg-color: var(--tt-gray-light-100);
163
+ --tt-scrollbar-color: var(--tt-gray-light-a-200);
164
+ --tt-cursor-color: var(--tt-brand-color-500);
165
+ --tt-selection-color: rgba(157, 138, 255, 0.2);
166
+ --tt-card-bg-color: var(--white);
167
+ --tt-card-border-color: var(--tt-gray-light-a-100);
168
+ }
169
+
170
+ /* Global colors - Dark mode */
171
+ .dark {
172
+ --tt-bg-color: var(--black);
173
+ --tt-border-color: var(--tt-gray-dark-a-200);
174
+ --tt-border-color-tint: var(--tt-gray-dark-a-100);
175
+ --tt-sidebar-bg-color: var(--tt-gray-dark-100);
176
+ --tt-scrollbar-color: var(--tt-gray-dark-a-200);
177
+ --tt-cursor-color: var(--tt-brand-color-400);
178
+ --tt-selection-color: rgba(122, 82, 255, 0.2);
179
+ --tt-card-bg-color: var(--tt-gray-dark-50);
180
+ --tt-card-border-color: var(--tt-gray-dark-a-50);
181
+ --tt-shadow-elevated-md:
182
+ 0px 16px 48px 0px rgba(0, 0, 0, 0.5), 0px 12px 24px 0px rgba(0, 0, 0, 0.24),
183
+ 0px 6px 8px 0px rgba(0, 0, 0, 0.22), 0px 2px 3px 0px rgba(0, 0, 0, 0.12);
184
+ }
185
+
186
+ /* Text colors */
187
+ :root {
188
+ --tt-color-text-gray: hsl(45, 2%, 46%);
189
+ --tt-color-text-brown: hsl(19, 31%, 47%);
190
+ --tt-color-text-orange: hsl(30, 89%, 45%);
191
+ --tt-color-text-yellow: hsl(38, 62%, 49%);
192
+ --tt-color-text-green: hsl(148, 32%, 39%);
193
+ --tt-color-text-blue: hsl(202, 54%, 43%);
194
+ --tt-color-text-purple: hsl(274, 32%, 54%);
195
+ --tt-color-text-pink: hsl(328, 49%, 53%);
196
+ --tt-color-text-red: hsl(2, 62%, 55%);
197
+ --tt-color-text-gray-contrast: hsla(39, 26%, 26%, 0.15);
198
+ --tt-color-text-brown-contrast: hsla(18, 43%, 69%, 0.35);
199
+ --tt-color-text-orange-contrast: hsla(24, 73%, 55%, 0.27);
200
+ --tt-color-text-yellow-contrast: hsla(44, 82%, 59%, 0.39);
201
+ --tt-color-text-green-contrast: hsla(126, 29%, 60%, 0.27);
202
+ --tt-color-text-blue-contrast: hsla(202, 54%, 59%, 0.27);
203
+ --tt-color-text-purple-contrast: hsla(274, 37%, 64%, 0.27);
204
+ --tt-color-text-pink-contrast: hsla(331, 60%, 71%, 0.27);
205
+ --tt-color-text-red-contrast: hsla(8, 79%, 79%, 0.4);
206
+ }
207
+
208
+ .dark {
209
+ --tt-color-text-gray: hsl(0, 0%, 61%);
210
+ --tt-color-text-brown: hsl(18, 35%, 58%);
211
+ --tt-color-text-orange: hsl(25, 53%, 53%);
212
+ --tt-color-text-yellow: hsl(36, 54%, 55%);
213
+ --tt-color-text-green: hsl(145, 32%, 47%);
214
+ --tt-color-text-blue: hsl(202, 64%, 52%);
215
+ --tt-color-text-purple: hsl(270, 55%, 62%);
216
+ --tt-color-text-pink: hsl(329, 57%, 58%);
217
+ --tt-color-text-red: hsl(1, 69%, 60%);
218
+ --tt-color-text-gray-contrast: hsla(0, 0%, 100%, 0.09);
219
+ --tt-color-text-brown-contrast: hsla(17, 45%, 50%, 0.25);
220
+ --tt-color-text-orange-contrast: hsla(27, 82%, 53%, 0.2);
221
+ --tt-color-text-yellow-contrast: hsla(35, 49%, 47%, 0.2);
222
+ --tt-color-text-green-contrast: hsla(151, 55%, 39%, 0.2);
223
+ --tt-color-text-blue-contrast: hsla(202, 54%, 43%, 0.2);
224
+ --tt-color-text-purple-contrast: hsla(271, 56%, 60%, 0.18);
225
+ --tt-color-text-pink-contrast: hsla(331, 67%, 58%, 0.22);
226
+ --tt-color-text-red-contrast: hsla(0, 67%, 60%, 0.25);
227
+ }
228
+
229
+ /* Highlight colors */
230
+ :root {
231
+ --tt-color-highlight-yellow: #fef9c3;
232
+ --tt-color-highlight-green: #dcfce7;
233
+ --tt-color-highlight-blue: #e0f2fe;
234
+ --tt-color-highlight-purple: #f3e8ff;
235
+ --tt-color-highlight-red: #ffe4e6;
236
+ --tt-color-highlight-gray: rgb(248, 248, 247);
237
+ --tt-color-highlight-brown: rgb(244, 238, 238);
238
+ --tt-color-highlight-orange: rgb(251, 236, 221);
239
+ --tt-color-highlight-pink: rgb(252, 241, 246);
240
+ --tt-color-highlight-yellow-contrast: #fbe604;
241
+ --tt-color-highlight-green-contrast: #c7fad8;
242
+ --tt-color-highlight-blue-contrast: #ceeafd;
243
+ --tt-color-highlight-purple-contrast: #e4ccff;
244
+ --tt-color-highlight-red-contrast: #ffccd0;
245
+ --tt-color-highlight-gray-contrast: rgba(84, 72, 49, 0.15);
246
+ --tt-color-highlight-brown-contrast: rgba(210, 162, 141, 0.35);
247
+ --tt-color-highlight-orange-contrast: rgba(224, 124, 57, 0.27);
248
+ --tt-color-highlight-pink-contrast: rgba(225, 136, 179, 0.27);
249
+ }
250
+
251
+ .dark {
252
+ --tt-color-highlight-yellow: #6b6524;
253
+ --tt-color-highlight-green: #509568;
254
+ --tt-color-highlight-blue: #6e92aa;
255
+ --tt-color-highlight-purple: #583e74;
256
+ --tt-color-highlight-red: #743e42;
257
+ --tt-color-highlight-gray: rgb(47, 47, 47);
258
+ --tt-color-highlight-brown: rgb(74, 50, 40);
259
+ --tt-color-highlight-orange: rgb(92, 59, 35);
260
+ --tt-color-highlight-pink: rgb(78, 44, 60);
261
+ --tt-color-highlight-yellow-contrast: #58531e;
262
+ --tt-color-highlight-green-contrast: #47855d;
263
+ --tt-color-highlight-blue-contrast: #5e86a1;
264
+ --tt-color-highlight-purple-contrast: #4c3564;
265
+ --tt-color-highlight-red-contrast: #643539;
266
+ --tt-color-highlight-gray-contrast: rgba(255, 255, 255, 0.094);
267
+ --tt-color-highlight-brown-contrast: rgba(184, 101, 69, 0.25);
268
+ --tt-color-highlight-orange-contrast: rgba(233, 126, 37, 0.2);
269
+ --tt-color-highlight-pink-contrast: rgba(220, 76, 145, 0.22);
270
+ }
271
+
272
+ .notra-prose {
273
+ --tt-collaboration-carets-label: var(--tt-gray-light-900);
274
+ --link-text-color: var(--tt-brand-color-500);
275
+ --thread-text: var(--tt-gray-light-900);
276
+ --placeholder-color: var(--tt-gray-light-a-400);
277
+ --thread-bg-color: var(--tt-color-yellow-inc-2);
278
+ --tiptap-ai-insertion-color: var(--tt-brand-color-600);
279
+ }
280
+ .dark .notra-prose {
281
+ --tt-collaboration-carets-label: var(--tt-gray-dark-100);
282
+ --link-text-color: var(--tt-brand-color-400);
283
+ --thread-text: var(--tt-gray-dark-900);
284
+ --placeholder-color: var(--tt-gray-dark-a-400);
285
+ --thread-bg-color: var(--tt-color-yellow-dec-2);
286
+ --tiptap-ai-insertion-color: var(--tt-brand-color-400);
287
+ }
288
+
289
+ /* Ensure each top-level node has relative positioning
290
+ so absolutely positioned placeholders work correctly */
291
+ .notra-prose > * {
292
+ position: relative;
293
+ }
294
+
295
+ /* =====================
296
+ CORE EDITOR STYLES
297
+ ===================== */
298
+ .notra-prose {
299
+ white-space: pre-wrap;
300
+ outline: none;
301
+ caret-color: var(--tt-cursor-color);
302
+ }
303
+ .notra-prose p:not(:first-child):not(td p):not(th p) {
304
+ font-size: 1rem;
305
+ line-height: 1.6;
306
+ font-weight: normal;
307
+ margin-top: 20px;
308
+ }
309
+ .notra-prose:not(.readonly):not(.ProseMirror-hideselection) ::selection {
310
+ background-color: var(--tt-selection-color);
311
+ }
312
+ .notra-prose:not(.readonly):not(.ProseMirror-hideselection) .selection::selection {
313
+ background: transparent;
314
+ }
315
+ .notra-prose .selection {
316
+ display: inline;
317
+ background-color: var(--tt-selection-color);
318
+ }
319
+ .notra-prose .ProseMirror-selectednode:not(img):not(pre):not(.react-renderer) {
320
+ border-radius: var(--tt-radius-md);
321
+ background-color: var(--tt-selection-color);
322
+ }
323
+ .notra-prose .ProseMirror-hideselection {
324
+ caret-color: transparent;
325
+ }
326
+ .notra-prose.resize-cursor {
327
+ cursor: ew-resize;
328
+ cursor: col-resize;
329
+ }
330
+
331
+ /* =====================
332
+ TEXT DECORATION
333
+ ===================== */
334
+ .notra-prose a span {
335
+ text-decoration: underline;
336
+ }
337
+ .notra-prose s span {
338
+ text-decoration: line-through;
339
+ }
340
+ .notra-prose u span {
341
+ text-decoration: underline;
342
+ }
343
+ .notra-prose .tiptap-ai-insertion {
344
+ color: var(--tiptap-ai-insertion-color);
345
+ }
346
+
347
+ /* =====================
348
+ COLLABORATION
349
+ ===================== */
350
+ .notra-prose .collaboration-carets__caret {
351
+ border-right: 1px solid transparent;
352
+ border-left: 1px solid transparent;
353
+ pointer-events: none;
354
+ margin-left: -1px;
355
+ margin-right: -1px;
356
+ position: relative;
357
+ word-break: normal;
358
+ }
359
+ .notra-prose .collaboration-carets__label {
360
+ color: var(--tt-collaboration-carets-label);
361
+ border-radius: 0.25rem;
362
+ border-bottom-left-radius: 0;
363
+ font-size: 0.75rem;
364
+ font-weight: 600;
365
+ left: -1px;
366
+ line-height: 1;
367
+ padding: 0.125rem 0.375rem;
368
+ position: absolute;
369
+ top: -1.3em;
370
+ user-select: none;
371
+ white-space: nowrap;
372
+ }
373
+
374
+ /* =====================
375
+ EMOJI
376
+ ===================== */
377
+ .notra-prose [data-type=emoji] img {
378
+ display: inline-block;
379
+ width: 1.25em;
380
+ height: 1.25em;
381
+ cursor: text;
382
+ }
383
+
384
+ /* =====================
385
+ LINKS
386
+ ===================== */
387
+ .notra-prose a {
388
+ color: var(--link-text-color);
389
+ text-decoration: underline;
390
+ }
391
+
392
+ /* =====================
393
+ MENTION
394
+ ===================== */
395
+ .notra-prose [data-type=mention] {
396
+ display: inline-block;
397
+ color: var(--tt-brand-color-500);
398
+ }
399
+
400
+ /* =====================
401
+ THREADS
402
+ ===================== */
403
+ .notra-prose .tiptap-thread.tiptap-thread--unresolved.tiptap-thread--inline {
404
+ transition: color 0.2s ease-in-out, background-color 0.2s ease-in-out;
405
+ color: var(--thread-text);
406
+ border-bottom: 2px dashed var(--tt-color-yellow-base);
407
+ font-weight: 600;
408
+ }
409
+ .notra-prose .tiptap-thread.tiptap-thread--unresolved.tiptap-thread--inline.tiptap-thread--selected, .notra-prose .tiptap-thread.tiptap-thread--unresolved.tiptap-thread--inline.tiptap-thread--hovered {
410
+ background-color: var(--thread-bg-color);
411
+ border-bottom-color: transparent;
412
+ }
413
+ .notra-prose .tiptap-thread.tiptap-thread--unresolved.tiptap-thread--block:has(img) {
414
+ outline: 0.125rem solid var(--tt-color-yellow-base);
415
+ border-radius: var(--tt-radius-xs, 0.25rem);
416
+ overflow: hidden;
417
+ width: fit-content;
418
+ }
419
+ .notra-prose .tiptap-thread.tiptap-thread--unresolved.tiptap-thread--block:has(img).tiptap-thread--selected {
420
+ outline-width: 0.25rem;
421
+ outline-color: var(--tt-color-yellow-base);
422
+ }
423
+ .notra-prose .tiptap-thread.tiptap-thread--unresolved.tiptap-thread--block:has(img).tiptap-thread--hovered {
424
+ outline-width: 0.25rem;
425
+ }
426
+ .notra-prose .tiptap-thread.tiptap-thread--unresolved.tiptap-thread--block:not(:has(img)) {
427
+ border-radius: 0.25rem;
428
+ border-bottom: 0.125rem dashed var(--tt-color-yellow-base);
429
+ border-top: 0.125rem dashed var(--tt-color-yellow-base);
430
+ outline: 0.25rem solid transparent;
431
+ }
432
+ .notra-prose .tiptap-thread.tiptap-thread--unresolved.tiptap-thread--block:not(:has(img)).tiptap-thread--hovered, .notra-prose .tiptap-thread.tiptap-thread--unresolved.tiptap-thread--block:not(:has(img)).tiptap-thread--selected {
433
+ background-color: var(--tt-color-yellow-base);
434
+ outline-color: var(--tt-color-yellow-base);
435
+ }
436
+ .notra-prose .tiptap-thread.tiptap-thread--resolved.tiptap-thread--inline.tiptap-thread--selected {
437
+ background-color: var(--tt-color-yellow-base);
438
+ border-color: transparent;
439
+ opacity: 0.5;
440
+ }
441
+ .notra-prose .tiptap-thread.tiptap-thread--block:has(.react-renderer) {
442
+ margin-top: 3rem;
443
+ margin-bottom: 3rem;
444
+ }
445
+
446
+ /* =====================
447
+ PLACEHOLDER
448
+ ===================== */
449
+ .is-empty:not(.with-slash)[data-placeholder]:has(> .ProseMirror-trailingBreak:only-child)::before {
450
+ content: attr(data-placeholder);
451
+ }
452
+
453
+ .is-empty.with-slash[data-placeholder]:has(> .ProseMirror-trailingBreak:only-child)::before {
454
+ content: "Write, type '/' for commands…";
455
+ font-style: italic;
456
+ }
457
+
458
+ .is-empty[data-placeholder]:has(> .ProseMirror-trailingBreak:only-child):before {
459
+ pointer-events: none;
460
+ height: 0;
461
+ position: absolute;
462
+ width: 100%;
463
+ text-align: inherit;
464
+ left: 0;
465
+ right: 0;
466
+ }
467
+
468
+ .is-empty[data-placeholder]:has(> .ProseMirror-trailingBreak):before {
469
+ color: var(--placeholder-color);
470
+ }
471
+
472
+ /* =====================
473
+ DROPCURSOR
474
+ ===================== */
475
+ .prosemirror-dropcursor-block,
476
+ .prosemirror-dropcursor-inline {
477
+ background: var(--tt-brand-color-400) !important;
478
+ border-radius: 0.25rem;
479
+ margin-left: -1px;
480
+ margin-right: -1px;
481
+ width: 100%;
482
+ height: 0.188rem;
483
+ cursor: grabbing;
484
+ }
485
+
486
+ /* =====================
487
+ INDENT
488
+ ===================== */
489
+ .notra-prose {
490
+ --tt-indent-unit: 24px;
491
+ }
492
+ .notra-prose [data-indent] {
493
+ transition: margin-left 0.2s ease-in-out;
494
+ margin-left: calc(var(--tt-indent-unit) * var(--tt-indent-level, 0));
495
+ }
496
+
497
+ .notra-prose h1,
498
+ .notra-prose h2,
499
+ .notra-prose h3,
500
+ .notra-prose h4 {
501
+ position: relative;
502
+ color: inherit;
503
+ font-style: inherit;
504
+ }
505
+ .notra-prose > h1:first-child,
506
+ .notra-prose > h2:first-child,
507
+ .notra-prose > h3:first-child,
508
+ .notra-prose > h4:first-child,
509
+ .notra-prose > .ProseMirror-widget + h1,
510
+ .notra-prose > .ProseMirror-widget + h2,
511
+ .notra-prose > .ProseMirror-widget + h3,
512
+ .notra-prose > .ProseMirror-widget + h4 {
513
+ margin-top: 0;
514
+ }
515
+ .notra-prose h1 {
516
+ font-size: 1.5em;
517
+ font-weight: 700;
518
+ margin-top: 3em;
519
+ }
520
+ .notra-prose h2 {
521
+ font-size: 1.25em;
522
+ font-weight: 700;
523
+ margin-top: 2.5em;
524
+ }
525
+ .notra-prose h3 {
526
+ font-size: 1.125em;
527
+ font-weight: 600;
528
+ margin-top: 2em;
529
+ }
530
+ .notra-prose h4 {
531
+ font-size: 1em;
532
+ font-weight: 600;
533
+ margin-top: 2em;
534
+ }
535
+
536
+ .notra-prose {
537
+ --tt-checklist-bg-color: var(--tt-gray-light-a-100);
538
+ --tt-checklist-bg-active-color: var(--tt-gray-light-a-900);
539
+ --tt-checklist-border-color: var(--tt-gray-light-a-200);
540
+ --tt-checklist-border-active-color: var(--tt-gray-light-a-900);
541
+ --tt-checklist-check-icon-color: var(--white);
542
+ --tt-checklist-text-active: var(--tt-gray-light-a-500);
543
+ }
544
+ .dark .notra-prose {
545
+ --tt-checklist-bg-color: var(--tt-gray-dark-a-100);
546
+ --tt-checklist-bg-active-color: var(--tt-gray-dark-a-900);
547
+ --tt-checklist-border-color: var(--tt-gray-dark-a-200);
548
+ --tt-checklist-border-active-color: var(--tt-gray-dark-a-900);
549
+ --tt-checklist-check-icon-color: var(--black);
550
+ --tt-checklist-text-active: var(--tt-gray-dark-a-500);
551
+ }
552
+
553
+ /* =====================
554
+ LISTS
555
+ ===================== */
556
+ .notra-prose ol,
557
+ .notra-prose ul {
558
+ margin-top: 1.5em;
559
+ margin-bottom: 1.5em;
560
+ padding-left: 1.5em;
561
+ }
562
+ .notra-prose ol:first-child,
563
+ .notra-prose ul:first-child {
564
+ margin-top: 0;
565
+ }
566
+ .notra-prose ol:last-child,
567
+ .notra-prose ul:last-child {
568
+ margin-bottom: 0;
569
+ }
570
+ .notra-prose ol ol,
571
+ .notra-prose ol ul,
572
+ .notra-prose ul ol,
573
+ .notra-prose ul ul {
574
+ margin-top: 0;
575
+ margin-bottom: 0;
576
+ }
577
+ .notra-prose li p {
578
+ margin-top: 0;
579
+ line-height: 1.6;
580
+ }
581
+ .notra-prose ol {
582
+ list-style: decimal;
583
+ }
584
+ .notra-prose ol ol {
585
+ list-style: lower-alpha;
586
+ }
587
+ .notra-prose ol ol ol {
588
+ list-style: lower-roman;
589
+ }
590
+ .notra-prose ol ol ol ol {
591
+ list-style: decimal;
592
+ }
593
+ .notra-prose ol ol ol ol ol {
594
+ list-style: lower-alpha;
595
+ }
596
+ .notra-prose ol ol ol ol ol ol {
597
+ list-style: lower-roman;
598
+ }
599
+ .notra-prose ol ol ol ol ol ol ol {
600
+ list-style: decimal;
601
+ }
602
+ .notra-prose ol ol ol ol ol ol ol ol {
603
+ list-style: lower-alpha;
604
+ }
605
+ .notra-prose ol ol ol ol ol ol ol ol ol {
606
+ list-style: lower-roman;
607
+ }
608
+ .notra-prose ul:not([data-type=taskList]) {
609
+ list-style: disc;
610
+ }
611
+ .notra-prose ul:not([data-type=taskList]) ul {
612
+ list-style: circle;
613
+ }
614
+ .notra-prose ul:not([data-type=taskList]) ul ul {
615
+ list-style: square;
616
+ }
617
+ .notra-prose ul:not([data-type=taskList]) ul ul ul {
618
+ list-style: disc;
619
+ }
620
+ .notra-prose ul:not([data-type=taskList]) ul ul ul ul {
621
+ list-style: circle;
622
+ }
623
+ .notra-prose ul:not([data-type=taskList]) ul ul ul ul ul {
624
+ list-style: square;
625
+ }
626
+ .notra-prose ul:not([data-type=taskList]) ul ul ul ul ul ul {
627
+ list-style: disc;
628
+ }
629
+ .notra-prose ul:not([data-type=taskList]) ul ul ul ul ul ul ul {
630
+ list-style: circle;
631
+ }
632
+ .notra-prose ul:not([data-type=taskList]) ul ul ul ul ul ul ul ul {
633
+ list-style: square;
634
+ }
635
+ .notra-prose ul[data-type=taskList] {
636
+ padding-left: 0.25em;
637
+ }
638
+ .notra-prose ul[data-type=taskList] li {
639
+ display: flex;
640
+ flex-direction: row;
641
+ align-items: flex-start;
642
+ }
643
+ .notra-prose ul[data-type=taskList] li:not(:has(> p:first-child)) {
644
+ list-style-type: none;
645
+ }
646
+ .notra-prose ul[data-type=taskList] li[data-checked=true] > div > p {
647
+ opacity: 0.5;
648
+ text-decoration: line-through;
649
+ }
650
+ .notra-prose ul[data-type=taskList] li[data-checked=true] > div > p span {
651
+ text-decoration: line-through;
652
+ }
653
+ .notra-prose ul[data-type=taskList] li label {
654
+ position: relative;
655
+ padding-top: 0.375rem;
656
+ padding-right: 0.5rem;
657
+ }
658
+ .notra-prose ul[data-type=taskList] li label input[type=checkbox] {
659
+ position: absolute;
660
+ opacity: 0;
661
+ width: 0;
662
+ height: 0;
663
+ }
664
+ .notra-prose ul[data-type=taskList] li label span {
665
+ display: block;
666
+ width: 1em;
667
+ height: 1em;
668
+ border: 1px solid var(--tt-checklist-border-color);
669
+ border-radius: var(--tt-radius-xs, 0.25rem);
670
+ position: relative;
671
+ cursor: pointer;
672
+ background-color: var(--tt-checklist-bg-color);
673
+ transition: background-color 80ms ease-out, border-color 80ms ease-out;
674
+ }
675
+ .notra-prose ul[data-type=taskList] li label span::before {
676
+ content: "";
677
+ position: absolute;
678
+ left: 50%;
679
+ top: 50%;
680
+ transform: translate(-50%, -50%);
681
+ width: 0.75em;
682
+ height: 0.75em;
683
+ background-color: var(--tt-checklist-check-icon-color);
684
+ opacity: 0;
685
+ -webkit-mask: url("data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22currentColor%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20fill-rule%3D%22evenodd%22%20clip-rule%3D%22evenodd%22%20d%3D%22M21.4142%204.58579C22.1953%205.36683%2022.1953%206.63317%2021.4142%207.41421L10.4142%2018.4142C9.63317%2019.1953%208.36684%2019.1953%207.58579%2018.4142L2.58579%2013.4142C1.80474%2012.6332%201.80474%2011.3668%202.58579%2010.5858C3.36683%209.80474%204.63317%209.80474%205.41421%2010.5858L9%2014.1716L18.5858%204.58579C19.3668%203.80474%2020.6332%203.80474%2021.4142%204.58579Z%22%20fill%3D%22currentColor%22%2F%3E%3C%2Fsvg%3E") center/contain no-repeat;
686
+ mask: url("data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22currentColor%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20fill-rule%3D%22evenodd%22%20clip-rule%3D%22evenodd%22%20d%3D%22M21.4142%204.58579C22.1953%205.36683%2022.1953%206.63317%2021.4142%207.41421L10.4142%2018.4142C9.63317%2019.1953%208.36684%2019.1953%207.58579%2018.4142L2.58579%2013.4142C1.80474%2012.6332%201.80474%2011.3668%202.58579%2010.5858C3.36683%209.80474%204.63317%209.80474%205.41421%2010.5858L9%2014.1716L18.5858%204.58579C19.3668%203.80474%2020.6332%203.80474%2021.4142%204.58579Z%22%20fill%3D%22currentColor%22%2F%3E%3C%2Fsvg%3E") center/contain no-repeat;
687
+ }
688
+ .notra-prose ul[data-type=taskList] li label input[type=checkbox]:checked + span {
689
+ background: var(--tt-checklist-bg-active-color);
690
+ border-color: var(--tt-checklist-border-active-color);
691
+ }
692
+ .notra-prose ul[data-type=taskList] li label input[type=checkbox]:checked + span::before {
693
+ opacity: 1;
694
+ }
695
+ .notra-prose ul[data-type=taskList] li div {
696
+ flex: 1 1 0%;
697
+ min-width: 0;
698
+ }
699
+
700
+ .notra-prose {
701
+ --blockquote-bg-color: var(--tt-gray-light-900);
702
+ }
703
+ .dark .notra-prose {
704
+ --blockquote-bg-color: var(--tt-gray-dark-900);
705
+ }
706
+
707
+ /* =====================
708
+ BLOCKQUOTE
709
+ ===================== */
710
+ .notra-prose blockquote {
711
+ position: relative;
712
+ padding-left: 1em;
713
+ padding-top: 0.375em;
714
+ padding-bottom: 0.375em;
715
+ margin: 1.5rem 0;
716
+ }
717
+ .notra-prose blockquote p {
718
+ margin-top: 0;
719
+ }
720
+ .notra-prose blockquote::before, .notra-prose blockquote.is-empty::before {
721
+ position: absolute;
722
+ bottom: 0;
723
+ left: 0;
724
+ top: 0;
725
+ height: 100%;
726
+ width: 0.25em;
727
+ background-color: var(--blockquote-bg-color);
728
+ content: "";
729
+ border-radius: 0;
730
+ }
731
+
732
+ .notra-prose {
733
+ --tt-inline-code-bg-color: var(--tt-gray-light-a-100);
734
+ --tt-inline-code-text-color: var(--tt-gray-light-a-700);
735
+ --tt-inline-code-border-color: var(--tt-gray-light-a-200);
736
+ --tt-codeblock-bg: var(--tt-gray-light-a-50);
737
+ --tt-codeblock-text: var(--tt-gray-light-a-800);
738
+ --tt-codeblock-border: var(--tt-gray-light-a-200);
739
+ }
740
+ .dark .notra-prose {
741
+ --tt-inline-code-bg-color: var(--tt-gray-dark-a-100);
742
+ --tt-inline-code-text-color: var(--tt-gray-dark-a-700);
743
+ --tt-inline-code-border-color: var(--tt-gray-dark-a-200);
744
+ --tt-codeblock-bg: var(--tt-gray-dark-a-50);
745
+ --tt-codeblock-text: var(--tt-gray-dark-a-800);
746
+ --tt-codeblock-border: var(--tt-gray-dark-a-200);
747
+ }
748
+
749
+ /* =====================
750
+ CODE FORMATTING
751
+ ===================== */
752
+ .notra-prose code {
753
+ background-color: var(--tt-inline-code-bg-color);
754
+ color: var(--tt-inline-code-text-color);
755
+ border: 1px solid var(--tt-inline-code-border-color);
756
+ font-family: "JetBrains Mono NL", monospace;
757
+ font-size: 0.875em;
758
+ line-height: 1.4;
759
+ border-radius: 6px/0.375rem;
760
+ padding: 0.1em 0.2em;
761
+ }
762
+ .notra-prose pre {
763
+ background-color: var(--tt-codeblock-bg);
764
+ color: var(--tt-codeblock-text);
765
+ border: 1px solid var(--tt-codeblock-border);
766
+ margin-top: 1.5em;
767
+ margin-bottom: 1.5em;
768
+ padding: 1em;
769
+ font-size: 1rem;
770
+ border-radius: 6px/0.375rem;
771
+ }
772
+ .notra-prose pre code {
773
+ background-color: transparent;
774
+ border: none;
775
+ border-radius: 0;
776
+ -webkit-text-fill-color: inherit;
777
+ color: inherit;
778
+ }
2
779
 
3
780
  /* =====================
4
- Reader-specific Styles
781
+ Atom One Light (default)
5
782
  ===================== */
6
- .notra-reader {
7
- font-family: var(--notra-font-body);
8
- font-size: var(--notra-font-size);
9
- line-height: var(--notra-line-height);
10
- color: var(--notra-color-text);
783
+ .notra-prose .hljs {
784
+ color: #383a42;
785
+ background: #fafafa;
786
+ }
787
+
788
+ .notra-prose .hljs-comment,
789
+ .notra-prose .hljs-quote {
790
+ color: #a0a1a7;
791
+ font-style: italic;
792
+ }
793
+
794
+ .notra-prose .hljs-doctag,
795
+ .notra-prose .hljs-formula,
796
+ .notra-prose .hljs-keyword {
797
+ color: #a626a4;
11
798
  }
12
799
 
13
- /* Ensure native selection in reader mode */
14
- .notra-reader *::selection {
15
- background-color: highlight;
800
+ .notra-prose .hljs-deletion,
801
+ .notra-prose .hljs-name,
802
+ .notra-prose .hljs-section,
803
+ .notra-prose .hljs-selector-tag,
804
+ .notra-prose .hljs-subst {
805
+ color: #e45649;
806
+ }
807
+
808
+ .notra-prose .hljs-literal {
809
+ color: #0184bb;
810
+ }
811
+
812
+ .notra-prose .hljs-addition,
813
+ .notra-prose .hljs-attribute,
814
+ .notra-prose .hljs-meta .hljs-string,
815
+ .notra-prose .hljs-regexp,
816
+ .notra-prose .hljs-string {
817
+ color: #50a14f;
818
+ }
819
+
820
+ .notra-prose .hljs-built_in,
821
+ .notra-prose .hljs-class .hljs-title,
822
+ .notra-prose .hljs-title.class_ {
823
+ color: #c18401;
824
+ }
825
+
826
+ .notra-prose .hljs-attr,
827
+ .notra-prose .hljs-number,
828
+ .notra-prose .hljs-selector-attr,
829
+ .notra-prose .hljs-selector-class,
830
+ .notra-prose .hljs-selector-pseudo,
831
+ .notra-prose .hljs-template-variable,
832
+ .notra-prose .hljs-type,
833
+ .notra-prose .hljs-variable {
834
+ color: #986801;
835
+ }
836
+
837
+ .notra-prose .hljs-bullet,
838
+ .notra-prose .hljs-link,
839
+ .notra-prose .hljs-meta,
840
+ .notra-prose .hljs-selector-id,
841
+ .notra-prose .hljs-symbol,
842
+ .notra-prose .hljs-title {
843
+ color: #4078f2;
844
+ }
845
+
846
+ .notra-prose .hljs-emphasis {
847
+ font-style: italic;
848
+ }
849
+
850
+ .notra-prose .hljs-strong {
851
+ font-weight: bold;
852
+ }
853
+
854
+ .notra-prose .hljs-link {
855
+ text-decoration: underline;
856
+ }
857
+
858
+ /* =====================
859
+ Atom One Dark (.dark override)
860
+ ===================== */
861
+ .dark .notra-prose .hljs {
862
+ color: #abb2bf;
863
+ background: #282c34;
864
+ }
865
+
866
+ .dark .notra-prose .hljs-comment,
867
+ .dark .notra-prose .hljs-quote {
868
+ color: #5c6370;
869
+ font-style: italic;
870
+ }
871
+
872
+ .dark .notra-prose .hljs-doctag,
873
+ .dark .notra-prose .hljs-formula,
874
+ .dark .notra-prose .hljs-keyword {
875
+ color: #c678dd;
876
+ }
877
+
878
+ .dark .notra-prose .hljs-deletion,
879
+ .dark .notra-prose .hljs-name,
880
+ .dark .notra-prose .hljs-section,
881
+ .dark .notra-prose .hljs-selector-tag,
882
+ .dark .notra-prose .hljs-subst {
883
+ color: #e06c75;
884
+ }
885
+
886
+ .dark .notra-prose .hljs-literal {
887
+ color: #56b6c2;
888
+ }
889
+
890
+ .dark .notra-prose .hljs-addition,
891
+ .dark .notra-prose .hljs-attribute,
892
+ .dark .notra-prose .hljs-meta .hljs-string,
893
+ .dark .notra-prose .hljs-regexp,
894
+ .dark .notra-prose .hljs-string {
895
+ color: #98c379;
896
+ }
897
+
898
+ .dark .notra-prose .hljs-built_in,
899
+ .dark .notra-prose .hljs-class .hljs-title,
900
+ .dark .notra-prose .hljs-title.class_ {
901
+ color: #e6c07b;
902
+ }
903
+
904
+ .dark .notra-prose .hljs-attr,
905
+ .dark .notra-prose .hljs-number,
906
+ .dark .notra-prose .hljs-selector-attr,
907
+ .dark .notra-prose .hljs-selector-class,
908
+ .dark .notra-prose .hljs-selector-pseudo,
909
+ .dark .notra-prose .hljs-template-variable,
910
+ .dark .notra-prose .hljs-type,
911
+ .dark .notra-prose .hljs-variable {
912
+ color: #d19a66;
913
+ }
914
+
915
+ .dark .notra-prose .hljs-bullet,
916
+ .dark .notra-prose .hljs-link,
917
+ .dark .notra-prose .hljs-meta,
918
+ .dark .notra-prose .hljs-selector-id,
919
+ .dark .notra-prose .hljs-symbol,
920
+ .dark .notra-prose .hljs-title {
921
+ color: #61aeee;
922
+ }
923
+
924
+ .notra-prose {
925
+ --horizontal-rule-color: var(--tt-gray-light-a-200);
926
+ }
927
+ .dark .notra-prose {
928
+ --horizontal-rule-color: var(--tt-gray-dark-a-200);
929
+ }
930
+
931
+ /* =====================
932
+ HORIZONTAL RULE
933
+ ===================== */
934
+ .notra-prose hr {
935
+ border: none;
936
+ height: 1px;
937
+ background-color: var(--horizontal-rule-color);
938
+ }
939
+ .notra-prose [data-type=horizontalRule] {
940
+ margin-top: 2.25em;
941
+ margin-bottom: 2.25em;
942
+ padding-top: 0.75rem;
943
+ padding-bottom: 0.75rem;
944
+ }
945
+
946
+ .notra-prose img {
947
+ max-width: 100%;
948
+ height: auto;
949
+ display: block;
950
+ }
951
+ .notra-prose p > img {
952
+ display: inline-block;
953
+ }
954
+ .notra-prose > img:not([data-type=emoji] img) {
955
+ margin: 2rem 0;
956
+ outline: 0.125rem solid transparent;
957
+ border-radius: var(--tt-radius-xs, 0.25rem);
958
+ }
959
+ .notra-prose img:not([data-type=emoji] img).ProseMirror-selectednode {
960
+ outline-color: var(--tt-brand-color-500);
961
+ }
962
+ .notra-prose .tiptap-thread:has(> img) {
963
+ margin: 2rem 0;
964
+ }
965
+ .notra-prose .tiptap-thread:has(> img) img {
966
+ outline: 0.125rem solid transparent;
967
+ border-radius: var(--tt-radius-xs, 0.25rem);
968
+ }
969
+ .notra-prose .tiptap-thread img {
970
+ margin: 0;
16
971
  }