@meowdown/core 0.29.2 → 0.30.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 (3) hide show
  1. package/README.md +14 -20
  2. package/dist/style.css +554 -542
  3. package/package.json +2 -2
package/README.md CHANGED
@@ -75,29 +75,23 @@ const markdown = docToMarkdown(editor.state.doc)
75
75
 
76
76
  ## Styling
77
77
 
78
- `@meowdown/core/style.css` ships a default editor theme. Colors use `light-dark()`, so they follow the page's `color-scheme` (set `color-scheme: light dark` on `:root` for automatic dark mode). Customize by overriding these variables on `:root` or any ancestor:
79
-
80
- - `--meowdown-text`: body text color.
81
- - `--meowdown-heading`: heading color.
82
- - `--meowdown-muted`: secondary text (blockquotes).
83
- - `--meowdown-accent`: links, wikilinks, caret, inline code, tags.
84
- - `--meowdown-mark`: Markdown syntax characters.
85
- - `--meowdown-border`: horizontal rules and table borders.
86
- - `--meowdown-code-bg`: code block background.
87
- - `--meowdown-table-header-bg`: table header row background.
88
- - `--meowdown-image-radius`: corner radius of rendered inline images.
89
- - `--meowdown-placeholder`: placeholder text color (defaults to `--meowdown-muted`).
90
- - `--meowdown-font-mono`: monospace font stack.
91
- - `--meowdown-gutter`: horizontal editor padding. Applied to the editable root's `.meowdown-content` class (set by `@meowdown/react`), not `.ProseMirror`, so the block handle's drag preview stays unpadded. Floating UI such as the block handle lives inside it; keep it at least `3.5rem`.
92
- - `--meowdown-selection`: text `::selection` background.
93
- - `--meowdown-node-outline`: outline of a selected node; border color of selected tables and cells.
94
- - `--meowdown-node-selection`: background wash of a selected node or selected cells.
95
-
96
- Selection colors are standalone variables, not derived from `--meowdown-accent`, so selection can be restyled independently.
78
+ `@meowdown/core/style.css` ships a default editor theme. Colors use `light-dark()`, so they follow the page's `color-scheme` (set `color-scheme: light dark` on `:root` for automatic dark mode). Theme it by overriding the `--meowdown-*` variables on `:root` or any ancestor. The full list, with a one-line description and default for each, lives in the commented `:root` block at the top of [`style.css`](./src/style.css), which is the single source of truth.
79
+
80
+ meowdown's CSS is wrapped in a cascade layer, `@layer meowdown` (with sub-layers `meowdown.base` for the bundled ProseMirror / prosekit base styles, `meowdown.theme` for the variables, and `meowdown.editor` for the editor rules). Because an un-layered rule always beats a layered one, **any plain rule you write overrides meowdown with no `!important` and no specificity hacks** (e.g. `.ProseMirror h1 { font-size: 2rem }` wins over meowdown's layered heading rule). Put your overrides outside any `@layer`, or in a layer you declare after `meowdown`.
81
+
82
+ **With Tailwind CSS v4**, import `@meowdown/core/style.css` _after_ `@import 'tailwindcss'` so the `meowdown` layer sorts after Tailwind's `theme` / `base` / `components` / `utilities`. That keeps meowdown's editor styles from being reset by Tailwind's `base` (Preflight) while your own un-layered rules still win. One caveat: with that order the `meowdown` layer also sorts after `utilities`, so a Tailwind utility _class_ placed directly on an editor element will not beat meowdown. If you need utilities to win (while meowdown still beats Preflight), declare the layer order yourself with `utilities` last, referencing the umbrella `meowdown` layer (not its sub-layers). Doing this at the top of your CSS also pins the order even when meowdown's stylesheet is code-split / lazy-loaded:
83
+
84
+ ```css
85
+ @layer theme, base, components, meowdown, utilities;
86
+ @import 'tailwindcss';
87
+ @import '@meowdown/core/style.css';
88
+ ```
89
+
90
+ Two things the variable list cannot show: `--meowdown-gutter` is the horizontal editor padding, applied to the editable root's `.meowdown-content` class (set by `@meowdown/react`), not `.ProseMirror`, so the block handle's drag preview stays unpadded; floating UI such as the block handle lives inside it, so keep it at least `3.5rem`. The selection variables (`--meowdown-selection`, `--meowdown-node-outline`, `--meowdown-node-selection`) are standalone, not derived from `--meowdown-accent`, so selection can be restyled independently.
97
91
 
98
92
  Tags (`#tag`) render as pills via the `.md-tag` class, tinted from `--meowdown-accent`. Wire click handling with `defineTagClickHandler(({ tag, event }) => ...)` (or `@meowdown/react`'s `onTagClick` prop); `tag` is read from the rendered text without the leading `#`.
99
93
 
100
- Wikilinks (`[[target]]`/`[[target|alias]]`) render in place via a mark view as an immutable label (the alias, or the target when there is no alias), with the raw source hidden in hide and focus modes and shown dimmed in show mode. The label uses the `.md-wikilink-label` class and the raw source the `.md-wikilink-source` class, both dashed-underlined and colored by `--meowdown-accent`. In every mark mode the link is a single immutable caret stop: arrowing onto it selects the whole source (ringed with `--meowdown-node-outline` in hide and focus, the native selection over the visible source in show), and Backspace/Delete remove it as a unit. Wire click navigation with `defineWikilinkClickHandler(({ target, event }) => ...)` (or `@meowdown/react`'s `onWikilinkClick` prop).
94
+ Wikilinks (`[[target]]`/`[[target|alias]]`) render in place via a mark view as an immutable label (the alias, or the target when there is no alias), with the raw source hidden in hide and focus modes and shown dimmed in show mode. The label uses the `.md-wikilink-view-label` class, dashed-underlined and colored by `--meowdown-accent`. In every mark mode the link is a single immutable caret stop: arrowing onto it selects the whole source (ringed with `--meowdown-node-outline` in hide and focus, the native selection over the visible source in show), and Backspace/Delete remove it as a unit. Wire click navigation with `defineWikilinkClickHandler(({ target, event }) => ...)` (or `@meowdown/react`'s `onWikilinkClick` prop).
101
95
 
102
96
  Markdown links (`[text](url)`) render the label as an `<a href>` with the `.md-link` class, colored by `--meowdown-accent`; the `[`, `]`, and `(url)` syntax dims in show mode and hides in hide and focus modes. Wire click handling with `defineLinkClickHandler(({ href, event }) => ...)` (or `@meowdown/react`'s `onLinkClick` prop).
103
97
 
package/dist/style.css CHANGED
@@ -1,669 +1,681 @@
1
- .ProseMirror {
2
- word-wrap: break-word;
3
- white-space: pre-wrap;
4
- white-space: break-spaces;
5
- -webkit-font-variant-ligatures: none;
6
- font-variant-ligatures: none;
7
- font-feature-settings: "liga" 0;
8
- position: relative;
9
- }
1
+ @layer meowdown.base {
2
+ .ProseMirror {
3
+ word-wrap: break-word;
4
+ white-space: pre-wrap;
5
+ white-space: break-spaces;
6
+ -webkit-font-variant-ligatures: none;
7
+ font-variant-ligatures: none;
8
+ font-feature-settings: "liga" 0;
9
+ position: relative;
10
+ }
10
11
 
11
- .ProseMirror pre {
12
- white-space: pre-wrap;
13
- }
12
+ .ProseMirror pre {
13
+ white-space: pre-wrap;
14
+ }
14
15
 
15
- .ProseMirror li {
16
- position: relative;
17
- }
16
+ .ProseMirror li {
17
+ position: relative;
18
+ }
18
19
 
19
- .ProseMirror-hideselection ::selection {
20
- background: none;
21
- }
20
+ .ProseMirror-hideselection ::selection {
21
+ background: none;
22
+ }
22
23
 
23
- .ProseMirror-hideselection {
24
- caret-color: #0000;
25
- }
24
+ .ProseMirror-hideselection {
25
+ caret-color: #0000;
26
+ }
26
27
 
27
- .ProseMirror [draggable][contenteditable="false"] {
28
- user-select: text;
29
- }
28
+ .ProseMirror [draggable][contenteditable="false"] {
29
+ user-select: text;
30
+ }
30
31
 
31
- .ProseMirror-selectednode {
32
- outline: 2px solid #8cf;
33
- }
32
+ .ProseMirror-selectednode {
33
+ outline: 2px solid #8cf;
34
+ }
34
35
 
35
- li.ProseMirror-selectednode {
36
- outline: none;
37
- }
36
+ li.ProseMirror-selectednode {
37
+ outline: none;
38
+ }
38
39
 
39
- li.ProseMirror-selectednode:after {
40
- content: "";
41
- pointer-events: none;
42
- border: 2px solid #8cf;
43
- position: absolute;
44
- inset: -2px -2px -2px -32px;
45
- }
40
+ li.ProseMirror-selectednode:after {
41
+ content: "";
42
+ pointer-events: none;
43
+ border: 2px solid #8cf;
44
+ position: absolute;
45
+ inset: -2px -2px -2px -32px;
46
+ }
46
47
 
47
- img.ProseMirror-separator {
48
- border: none !important;
49
- margin: 0 !important;
50
- display: inline !important;
51
- }
48
+ img.ProseMirror-separator {
49
+ border: none !important;
50
+ margin: 0 !important;
51
+ display: inline !important;
52
+ }
52
53
 
53
- :root {
54
- --prosekit-list-bullet-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='2.5' fill='currentColor'/%3E%3C/svg%3E");
55
- --prosekit-list-toggle-open-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24'%3E%3Cpolygon points='8,10 12,14 16,10' fill='currentColor'/%3E%3C/svg%3E");
56
- --prosekit-list-toggle-closed-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24'%3E%3Cpolygon points='10,8 14,12 10,16' fill='currentColor'/%3E%3C/svg%3E");
57
- }
54
+ :root {
55
+ --prosekit-list-bullet-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='2.5' fill='currentColor'/%3E%3C/svg%3E");
56
+ --prosekit-list-toggle-open-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24'%3E%3Cpolygon points='8,10 12,14 16,10' fill='currentColor'/%3E%3C/svg%3E");
57
+ --prosekit-list-toggle-closed-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24'%3E%3Cpolygon points='10,8 14,12 10,16' fill='currentColor'/%3E%3C/svg%3E");
58
+ }
58
59
 
59
- .prosemirror-flat-list {
60
- margin: 0;
61
- padding: 0;
62
- list-style: none;
63
- position: relative;
64
- }
60
+ .prosemirror-flat-list {
61
+ margin: 0;
62
+ padding: 0;
63
+ list-style: none;
64
+ position: relative;
65
+ }
65
66
 
66
- .prosemirror-flat-list > .list-marker {
67
- text-align: center;
68
- width: 1lh;
69
- height: 1lh;
70
- position: absolute;
71
- inset-inline-start: 0;
72
- }
67
+ .prosemirror-flat-list > .list-marker {
68
+ text-align: center;
69
+ width: 1lh;
70
+ height: 1lh;
71
+ position: absolute;
72
+ inset-inline-start: 0;
73
+ }
73
74
 
74
- .prosemirror-flat-list > .list-content {
75
- margin-inline-start: 1lh;
76
- }
75
+ .prosemirror-flat-list > .list-content {
76
+ margin-inline-start: 1lh;
77
+ }
77
78
 
78
- .prosemirror-flat-list[data-list-kind="bullet"] > .list-marker, .prosemirror-flat-list[data-list-kind="toggle"] > .list-marker {
79
- background-color: currentColor;
80
- mask-position: center;
81
- mask-size: contain;
82
- mask-repeat: no-repeat;
83
- }
79
+ .prosemirror-flat-list[data-list-kind="bullet"] > .list-marker, .prosemirror-flat-list[data-list-kind="toggle"] > .list-marker {
80
+ background-color: currentColor;
81
+ mask-position: center;
82
+ mask-size: contain;
83
+ mask-repeat: no-repeat;
84
+ }
84
85
 
85
- .prosemirror-flat-list[data-list-kind="bullet"] > .list-marker {
86
- mask-image: var(--prosekit-list-bullet-icon);
87
- }
86
+ .prosemirror-flat-list[data-list-kind="bullet"] > .list-marker {
87
+ mask-image: var(--prosekit-list-bullet-icon);
88
+ }
88
89
 
89
- .prosemirror-flat-list[data-list-kind="toggle"] > .list-marker {
90
- mask-image: var(--prosekit-list-toggle-open-icon);
91
- }
90
+ .prosemirror-flat-list[data-list-kind="toggle"] > .list-marker {
91
+ mask-image: var(--prosekit-list-toggle-open-icon);
92
+ }
92
93
 
93
- .prosemirror-flat-list[data-list-kind="toggle"][data-list-collapsable][data-list-collapsed] > .list-marker {
94
- mask-image: var(--prosekit-list-toggle-closed-icon);
95
- }
94
+ .prosemirror-flat-list[data-list-kind="toggle"][data-list-collapsable][data-list-collapsed] > .list-marker {
95
+ mask-image: var(--prosekit-list-toggle-closed-icon);
96
+ }
96
97
 
97
- .prosemirror-flat-list[data-list-kind="ordered"] > * {
98
- contain: style;
99
- }
98
+ .prosemirror-flat-list[data-list-kind="ordered"] > * {
99
+ contain: style;
100
+ }
100
101
 
101
- .prosemirror-flat-list[data-list-kind="ordered"]:before {
102
- content: counter(prosemirror-flat-list-counter, decimal) ". ";
103
- font-variant-numeric: tabular-nums;
104
- position: absolute;
105
- inset-inline-end: calc(100% - 1lh);
106
- }
102
+ .prosemirror-flat-list[data-list-kind="ordered"]:before {
103
+ content: counter(prosemirror-flat-list-counter, decimal) ". ";
104
+ font-variant-numeric: tabular-nums;
105
+ position: absolute;
106
+ inset-inline-end: calc(100% - 1lh);
107
+ }
107
108
 
108
- .prosemirror-flat-list[data-list-kind="ordered"] {
109
- counter-increment: prosemirror-flat-list-counter;
110
- }
109
+ .prosemirror-flat-list[data-list-kind="ordered"] {
110
+ counter-increment: prosemirror-flat-list-counter;
111
+ }
111
112
 
112
- .prosemirror-flat-list[data-list-kind="ordered"]:first-child, :not(.prosemirror-flat-list[data-list-kind="ordered"]) + .prosemirror-flat-list[data-list-kind="ordered"] {
113
- counter-reset: prosemirror-flat-list-counter;
114
- }
113
+ .prosemirror-flat-list[data-list-kind="ordered"]:first-child, :not(.prosemirror-flat-list[data-list-kind="ordered"]) + .prosemirror-flat-list[data-list-kind="ordered"] {
114
+ counter-reset: prosemirror-flat-list-counter;
115
+ }
115
116
 
116
- @supports (counter-set: prosemirror-flat-list-counter 1) {
117
- :is(.prosemirror-flat-list[data-list-kind="ordered"]:first-child, :not(.prosemirror-flat-list[data-list-kind="ordered"]) + .prosemirror-flat-list[data-list-kind="ordered"])[data-list-order] {
118
- counter-set: prosemirror-flat-list-counter var(--prosemirror-flat-list-order);
117
+ @supports (counter-set: prosemirror-flat-list-counter 1) {
118
+ :is(.prosemirror-flat-list[data-list-kind="ordered"]:first-child, :not(.prosemirror-flat-list[data-list-kind="ordered"]) + .prosemirror-flat-list[data-list-kind="ordered"])[data-list-order] {
119
+ counter-set: prosemirror-flat-list-counter var(--prosemirror-flat-list-order);
120
+ }
119
121
  }
120
- }
121
122
 
122
- @supports not (counter-set: prosemirror-flat-list-counter 1) {
123
- :is(.prosemirror-flat-list[data-list-kind="ordered"]:first-child, :not(.prosemirror-flat-list[data-list-kind="ordered"]) + .prosemirror-flat-list[data-list-kind="ordered"])[data-list-order] {
124
- counter-increment: prosemirror-flat-list-counter var(--prosemirror-flat-list-order);
123
+ @supports not (counter-set: prosemirror-flat-list-counter 1) {
124
+ :is(.prosemirror-flat-list[data-list-kind="ordered"]:first-child, :not(.prosemirror-flat-list[data-list-kind="ordered"]) + .prosemirror-flat-list[data-list-kind="ordered"])[data-list-order] {
125
+ counter-increment: prosemirror-flat-list-counter var(--prosemirror-flat-list-order);
126
+ }
125
127
  }
126
- }
127
128
 
128
- .prosemirror-flat-list[data-list-kind="task"] > .list-marker, .prosemirror-flat-list[data-list-kind="task"] > .list-marker * {
129
- cursor: pointer;
130
- justify-content: center;
131
- align-items: center;
132
- margin: 0;
133
- padding: 0;
134
- display: flex;
135
- }
129
+ .prosemirror-flat-list[data-list-kind="task"] > .list-marker, .prosemirror-flat-list[data-list-kind="task"] > .list-marker * {
130
+ cursor: pointer;
131
+ justify-content: center;
132
+ align-items: center;
133
+ margin: 0;
134
+ padding: 0;
135
+ display: flex;
136
+ }
136
137
 
137
- .prosemirror-flat-list[data-list-kind="toggle"][data-list-collapsable] > .list-marker {
138
- cursor: pointer;
139
- }
138
+ .prosemirror-flat-list[data-list-kind="toggle"][data-list-collapsable] > .list-marker {
139
+ cursor: pointer;
140
+ }
140
141
 
141
- .prosemirror-flat-list[data-list-kind="toggle"]:not([data-list-collapsable]) > .list-marker {
142
- opacity: .4;
143
- pointer-events: none;
144
- }
142
+ .prosemirror-flat-list[data-list-kind="toggle"]:not([data-list-collapsable]) > .list-marker {
143
+ opacity: .4;
144
+ pointer-events: none;
145
+ }
145
146
 
146
- .prosemirror-flat-list[data-list-kind="toggle"][data-list-collapsable][data-list-collapsed] > .list-content > :nth-child(n+2) {
147
- display: none;
147
+ .prosemirror-flat-list[data-list-kind="toggle"][data-list-collapsable][data-list-collapsed] > .list-content > :nth-child(n+2) {
148
+ display: none;
149
+ }
148
150
  }
149
151
 
150
- :root {
151
- --meowdown-text: light-dark(#3f3f46, #d4d4d8);
152
- --meowdown-heading: light-dark(#18181b, #fafafa);
153
- --meowdown-muted: light-dark(#52525b, #a1a1aa);
154
- --meowdown-accent: light-dark(#7c3aed, #c084fc);
155
- --meowdown-mark: light-dark(#a78bfa, #8b5cf6);
156
- --meowdown-highlight: light-dark(#fef08a, #854d0e);
157
- --meowdown-border: light-dark(#e4e4e7, #3f3f46);
158
- --meowdown-code-bg: light-dark(#f4f4f5, #18181b);
159
- --meowdown-image-loading-bg: light-dark(#f4f4f5, #27272a);
160
- --meowdown-table-header-bg: light-dark(#fafafa, #27272a);
161
- --meowdown-autocomplete-bg: light-dark(#fff, #18181b);
162
- --meowdown-autocomplete-highlight-bg: light-dark(#f4f4f5, #27272a);
163
- --meowdown-font-mono: ui-monospace, SFMono-Regular, Menlo, monospace;
164
- --meowdown-node-outline: light-dark(#53f, #8870ff);
165
- --meowdown-node-selection: light-dark(#5533ff1a, #8870ff1f);
166
- --meowdown-selection: light-dark(#5533ff38, #8870ff4d);
167
- --meowdown-fold-halo: var(--meowdown-accent);
168
- --meowdown-gutter: 3.5rem;
152
+ @layer meowdown.theme {
153
+ :root {
154
+ --meowdown-text: light-dark(oklch(37% .012 286), oklch(87.1% .005 286));
155
+ --meowdown-heading: light-dark(oklch(21% .006 286), oklch(98.5% 0 0));
156
+ --meowdown-muted: light-dark(oklch(44.2% .015 286), oklch(71.2% .013 286));
157
+ --meowdown-accent: light-dark(oklch(64.6% .194 41), oklch(75.8% .159 56));
158
+ --meowdown-mark: var(--meowdown-muted);
159
+ --meowdown-highlight: light-dark(oklch(94.5% .124 102), oklch(47.6% .103 62));
160
+ --meowdown-border: light-dark(oklch(92% .004 286), oklch(37% .012 286));
161
+ --meowdown-blockquote-border: color-mix(in oklab, var(--meowdown-accent) 35%, transparent);
162
+ --meowdown-code-bg: light-dark(oklch(96.7% 0 0), oklch(21% .006 286));
163
+ --meowdown-image-loading-bg: light-dark(oklch(96.7% 0 0), oklch(27.4% .005 286));
164
+ --meowdown-image-radius: .5rem;
165
+ --meowdown-table-header-bg: light-dark(oklch(98.5% 0 0), oklch(27.4% .005 286));
166
+ --meowdown-popover-bg: light-dark(oklch(100% 0 0), oklch(21% .006 286));
167
+ --meowdown-popover-hover-bg: light-dark(oklch(96.7% 0 0), oklch(27.4% .005 286));
168
+ --meowdown-danger: light-dark(oklch(63.7% .208 25), oklch(71.1% .166 22));
169
+ --meowdown-placeholder: var(--meowdown-muted);
170
+ --meowdown-font-mono: ui-monospace, SFMono-Regular, Menlo, monospace;
171
+ --meowdown-node-outline: light-dark(oklch(64.2% .178 46), oklch(74.1% .165 52));
172
+ --meowdown-node-selection: light-dark(oklch(69.3% .194 46 / .1), oklch(74.1% .165 52 / .12));
173
+ --meowdown-selection: light-dark(oklch(69.3% .194 46 / .22), oklch(74.1% .165 52 / .3));
174
+ --meowdown-bullet: var(--meowdown-muted);
175
+ --meowdown-bullet-radius: 2.5px;
176
+ --meowdown-bullet-halo-radius: 5.5px;
177
+ --meowdown-bullet-collapsed: var(--meowdown-accent);
178
+ --meowdown-gutter: 3.5rem;
179
+ }
169
180
  }
170
181
 
171
- .ProseMirror {
172
- box-sizing: border-box;
173
- color: var(--meowdown-text);
174
- caret-color: var(--meowdown-accent);
175
- -webkit-font-smoothing: antialiased;
176
- outline: none;
177
- font-size: 1.0625rem;
178
- line-height: 1.7;
179
- }
182
+ @layer meowdown.editor {
183
+ .ProseMirror {
184
+ box-sizing: border-box;
185
+ color: var(--meowdown-text);
186
+ caret-color: var(--meowdown-accent);
187
+ -webkit-font-smoothing: antialiased;
188
+ outline: none;
189
+ font-size: 1.0625rem;
190
+ line-height: 1.7;
191
+ }
180
192
 
181
- .meowdown-content {
182
- padding: 1.25rem var(--meowdown-gutter) 1.75rem;
183
- }
193
+ .meowdown-content {
194
+ padding-top: 1.25rem;
195
+ padding-right: var(--meowdown-gutter);
196
+ padding-bottom: 1.75rem;
197
+ padding-left: var(--meowdown-gutter);
198
+ }
184
199
 
185
- .ProseMirror > * + * {
186
- margin-top: .85em;
187
- }
200
+ .ProseMirror > * + * {
201
+ margin-top: .85em;
202
+ }
188
203
 
189
- .ProseMirror p {
190
- white-space: pre-wrap;
191
- }
204
+ .ProseMirror p {
205
+ white-space: pre-wrap;
206
+ }
192
207
 
193
- .ProseMirror h1, .ProseMirror h2, .ProseMirror h3, .ProseMirror h4, .ProseMirror h5, .ProseMirror h6 {
194
- letter-spacing: -.01em;
195
- color: var(--meowdown-heading);
196
- white-space: pre-wrap;
197
- font-weight: 600;
198
- line-height: 1.25;
199
- }
208
+ .ProseMirror h1, .ProseMirror h2, .ProseMirror h3, .ProseMirror h4, .ProseMirror h5, .ProseMirror h6 {
209
+ letter-spacing: -.01em;
210
+ color: var(--meowdown-heading);
211
+ white-space: pre-wrap;
212
+ font-weight: 600;
213
+ line-height: 1.25;
214
+ }
200
215
 
201
- .ProseMirror h1 {
202
- font-size: 1.75rem;
203
- }
216
+ .ProseMirror h1 {
217
+ font-size: 1.75rem;
218
+ }
204
219
 
205
- .ProseMirror h2 {
206
- font-size: 1.4rem;
207
- }
220
+ .ProseMirror h2 {
221
+ font-size: 1.4rem;
222
+ }
208
223
 
209
- .ProseMirror h3 {
210
- font-size: 1.2rem;
211
- }
224
+ .ProseMirror h3 {
225
+ font-size: 1.2rem;
226
+ }
212
227
 
213
- .ProseMirror h4 {
214
- font-size: 1.1rem;
215
- }
228
+ .ProseMirror h4 {
229
+ font-size: 1.1rem;
230
+ }
216
231
 
217
- .ProseMirror h5 {
218
- font-size: 1rem;
219
- }
232
+ .ProseMirror h5 {
233
+ font-size: 1rem;
234
+ }
220
235
 
221
- .ProseMirror h6 {
222
- font-size: .95rem;
223
- }
236
+ .ProseMirror h6 {
237
+ font-size: .95rem;
238
+ }
224
239
 
225
- .ProseMirror .md-link {
226
- color: var(--meowdown-accent);
227
- text-underline-offset: 2px;
228
- cursor: pointer;
229
- text-decoration: underline 1px;
230
- }
240
+ .ProseMirror .md-link {
241
+ color: var(--meowdown-accent);
242
+ text-underline-offset: 2px;
243
+ cursor: pointer;
244
+ text-decoration: underline 1px;
245
+ }
231
246
 
232
- .ProseMirror mark {
233
- background: var(--meowdown-highlight);
234
- color: inherit;
235
- -webkit-box-decoration-break: clone;
236
- box-decoration-break: clone;
237
- border-radius: 2px;
238
- padding: 0 1px;
239
- }
247
+ .ProseMirror mark {
248
+ background: var(--meowdown-highlight);
249
+ color: inherit;
250
+ -webkit-box-decoration-break: clone;
251
+ box-decoration-break: clone;
252
+ border-radius: 2px;
253
+ padding: 0 1px;
254
+ }
240
255
 
241
- .ProseMirror code {
242
- font-family: var(--meowdown-font-mono);
243
- background: color-mix(in oklab, var(--meowdown-accent) 10%, transparent);
244
- color: color-mix(in oklab, var(--meowdown-accent) 80%, var(--meowdown-heading));
245
- border-radius: .35rem;
246
- padding: .1em .35em;
247
- font-size: .9em;
248
- }
256
+ .ProseMirror code {
257
+ font-family: var(--meowdown-font-mono);
258
+ background: var(--meowdown-code-bg);
259
+ color: inherit;
260
+ border-radius: .35rem;
261
+ padding: .1em .35em;
262
+ font-size: .9em;
263
+ }
249
264
 
250
- .ProseMirror blockquote {
251
- border-left: 3px solid color-mix(in oklab, var(--meowdown-accent) 35%, transparent);
252
- color: var(--meowdown-muted);
253
- margin-left: 0;
254
- padding-left: 1rem;
255
- font-style: italic;
256
- }
265
+ .ProseMirror blockquote {
266
+ border-left: 3px solid var(--meowdown-blockquote-border);
267
+ color: var(--meowdown-muted);
268
+ margin-left: 0;
269
+ padding-left: 1rem;
270
+ }
257
271
 
258
- .ProseMirror ul, .ProseMirror ol {
259
- padding-left: 1.5rem;
260
- }
272
+ .ProseMirror ul, .ProseMirror ol {
273
+ padding-left: 1.5rem;
274
+ }
261
275
 
262
- .ProseMirror ul {
263
- list-style: outside;
264
- }
276
+ .ProseMirror ul {
277
+ list-style: outside;
278
+ }
265
279
 
266
- .ProseMirror ol {
267
- list-style: decimal;
268
- }
280
+ .ProseMirror ol {
281
+ list-style: decimal;
282
+ }
269
283
 
270
- .ProseMirror li {
271
- margin-top: .25em;
272
- }
284
+ .ProseMirror li {
285
+ margin-top: .25em;
286
+ }
273
287
 
274
- .ProseMirror .prosemirror-flat-list[data-list-kind="task"] {
275
- transition: opacity .2s;
288
+ .ProseMirror .prosemirror-flat-list[data-list-kind="bullet"] > .list-marker {
289
+ background: radial-gradient(circle at center,
290
+ var(--meowdown-bullet) 0 var(--meowdown-bullet-radius),
291
+ transparent var(--meowdown-bullet-radius));
292
+ -webkit-mask: none;
293
+ mask: none;
294
+ }
276
295
 
277
- &[data-list-checked] {
278
- opacity: .5;
296
+ .ProseMirror .prosemirror-flat-list[data-list-kind="task"] {
297
+ transition: opacity .2s;
279
298
 
280
- & .prosemirror-flat-list[data-list-kind="task"][data-list-checked] {
281
- opacity: 1;
299
+ &[data-list-checked] {
300
+ opacity: .5;
301
+
302
+ & .prosemirror-flat-list[data-list-kind="task"][data-list-checked] {
303
+ opacity: 1;
304
+ }
282
305
  }
283
- }
284
306
 
285
- & > .list-marker {
286
- transition: transform .12s;
307
+ & > .list-marker {
308
+ transition: transform .12s;
287
309
 
288
- &:hover {
289
- transform: scale(1.1);
290
- }
310
+ &:hover {
311
+ transform: scale(1.1);
312
+ }
291
313
 
292
- & input[type="checkbox"] {
293
- -webkit-appearance: none;
294
- appearance: none;
295
- box-sizing: border-box;
296
- border: 1.5px solid var(--meowdown-border);
297
- background: center / 100% 100% no-repeat;
298
- border-radius: .25rem;
299
- width: .95rem;
300
- height: .95rem;
301
- transition: background-color .15s, border-color .15s;
302
-
303
- &:checked {
304
- background-color: var(--meowdown-accent);
305
- background-image: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M12.207 4.793a1 1 0 010 1.414l-5 5a1 1 0 01-1.414 0l-2-2a1 1 0 011.414-1.414L6.5 9.086l4.293-4.293a1 1 0 011.414 0z'/%3e%3c/svg%3e");
306
- border-color: #0000;
314
+ & input[type="checkbox"] {
315
+ -webkit-appearance: none;
316
+ appearance: none;
317
+ box-sizing: border-box;
318
+ border: 1px solid var(--meowdown-muted);
319
+ background: center / 100% 100% no-repeat;
320
+ border-radius: .25rem;
321
+ width: .95rem;
322
+ height: .95rem;
323
+ transition: background-color .15s, border-color .15s;
324
+
325
+ &:checked {
326
+ background-color: var(--meowdown-accent);
327
+ background-image: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M12.207 4.793a1 1 0 010 1.414l-5 5a1 1 0 01-1.414 0l-2-2a1 1 0 011.414-1.414L6.5 9.086l4.293-4.293a1 1 0 011.414 0z'/%3e%3c/svg%3e");
328
+ border-color: #0000;
329
+ }
307
330
  }
308
331
  }
309
- }
310
332
 
311
- &[data-list-marker="+"] > .list-marker input[type="checkbox"] {
312
- border-radius: 100rem;
313
- width: 1.05rem;
314
- height: 1.05rem;
333
+ &[data-list-marker="+"] > .list-marker input[type="checkbox"] {
334
+ border-radius: 100rem;
335
+ width: 1.05rem;
336
+ height: 1.05rem;
337
+ }
315
338
  }
316
- }
317
339
 
318
- .ProseMirror .prosemirror-flat-list[data-list-kind="bullet"] {
319
- &[data-list-collapsable] > .list-marker {
320
- cursor: pointer;
321
- }
340
+ .ProseMirror .prosemirror-flat-list[data-list-kind="bullet"] {
341
+ &[data-list-collapsable] > .list-marker {
342
+ cursor: pointer;
343
+ }
322
344
 
323
- &[data-list-collapsable]:before {
324
- content: "";
325
- inset-inline-start: 0;
326
- background: radial-gradient(circle at center,
327
- var(--meowdown-fold-halo) 0 .45rem,
328
- transparent .45rem);
329
- opacity: 0;
330
- pointer-events: none;
331
- width: 1lh;
332
- height: 1lh;
333
- transition: opacity .12s;
334
- position: absolute;
335
- top: 0;
336
- }
345
+ &[data-list-collapsable] > .list-marker:hover {
346
+ background: radial-gradient(circle at center,
347
+ var(--meowdown-bullet) 0 var(--meowdown-bullet-radius),
348
+ color-mix(in oklab, var(--meowdown-bullet-collapsed) 20%, transparent)
349
+ var(--meowdown-bullet-radius) var(--meowdown-bullet-halo-radius),
350
+ transparent var(--meowdown-bullet-halo-radius));
351
+ }
337
352
 
338
- &[data-list-collapsable]:has( > .list-marker:hover):before {
339
- opacity: .2;
340
- }
353
+ &[data-list-collapsable][data-list-collapsed] > .list-marker {
354
+ background: radial-gradient(circle at center,
355
+ var(--meowdown-bullet-collapsed) 0 var(--meowdown-bullet-radius),
356
+ color-mix(in oklab, var(--meowdown-bullet-collapsed) 35%, transparent)
357
+ var(--meowdown-bullet-radius) var(--meowdown-bullet-halo-radius),
358
+ transparent var(--meowdown-bullet-halo-radius));
359
+ }
341
360
 
342
- &[data-list-collapsable][data-list-collapsed]:before {
343
- opacity: .35;
361
+ &[data-list-collapsable][data-list-collapsed] > .list-content > :nth-child(n+2) {
362
+ display: none;
363
+ }
344
364
  }
345
365
 
346
- &[data-list-collapsable][data-list-collapsed]:has( > .list-marker:hover):before {
347
- opacity: .45;
366
+ .ProseMirror pre {
367
+ background: var(--meowdown-code-bg);
368
+ font-family: var(--meowdown-font-mono);
369
+ border-radius: .6rem;
370
+ padding: .9rem 1rem;
371
+ font-size: .9em;
372
+ line-height: 1.5;
373
+ overflow-x: auto;
348
374
  }
349
375
 
350
- &[data-list-collapsable][data-list-collapsed] > .list-content > :nth-child(n+2) {
351
- display: none;
376
+ .ProseMirror pre code {
377
+ color: inherit;
378
+ background: none;
379
+ padding: 0;
352
380
  }
353
- }
354
-
355
- .ProseMirror pre {
356
- background: var(--meowdown-code-bg);
357
- font-family: var(--meowdown-font-mono);
358
- border-radius: .6rem;
359
- padding: .9rem 1rem;
360
- font-size: .9em;
361
- line-height: 1.5;
362
- overflow-x: auto;
363
- }
364
-
365
- .ProseMirror pre code {
366
- color: inherit;
367
- background: none;
368
- padding: 0;
369
- }
370
-
371
- .ProseMirror pre code .tok-keyword {
372
- color: light-dark(#cf222e, #ff7b72);
373
- }
374
381
 
375
- .ProseMirror pre code .tok-comment {
376
- color: light-dark(#6e7781, #8b949e);
377
- font-style: italic;
378
- }
379
-
380
- .ProseMirror pre code .tok-string, .ProseMirror pre code .tok-url {
381
- color: light-dark(#0a3069, #a5d6ff);
382
- }
382
+ .ProseMirror pre code .tok-keyword {
383
+ color: light-dark(#cf222e, #ff7b72);
384
+ }
383
385
 
384
- .ProseMirror pre code .tok-number, .ProseMirror pre code .tok-bool, .ProseMirror pre code .tok-atom, .ProseMirror pre code .tok-literal {
385
- color: light-dark(#0550ae, #79c0ff);
386
- }
386
+ .ProseMirror pre code .tok-comment {
387
+ color: light-dark(#6e7781, #8b949e);
388
+ font-style: italic;
389
+ }
387
390
 
388
- .ProseMirror pre code .tok-className, .ProseMirror pre code .tok-typeName, .ProseMirror pre code .tok-namespace {
389
- color: light-dark(#953800, #ffa657);
390
- }
391
+ .ProseMirror pre code .tok-string, .ProseMirror pre code .tok-url {
392
+ color: light-dark(#0a3069, #a5d6ff);
393
+ }
391
394
 
392
- .ProseMirror pre code .tok-definition {
393
- color: light-dark(#8250df, #d2a8ff);
394
- }
395
+ .ProseMirror pre code .tok-number, .ProseMirror pre code .tok-bool, .ProseMirror pre code .tok-atom, .ProseMirror pre code .tok-literal {
396
+ color: light-dark(#0550ae, #79c0ff);
397
+ }
395
398
 
396
- .ProseMirror pre code .tok-macroName, .ProseMirror pre code .tok-meta, .ProseMirror pre code .tok-inserted {
397
- color: light-dark(#116329, #7ee787);
398
- }
399
+ .ProseMirror pre code .tok-className, .ProseMirror pre code .tok-typeName, .ProseMirror pre code .tok-namespace {
400
+ color: light-dark(#953800, #ffa657);
401
+ }
399
402
 
400
- .ProseMirror pre code .tok-invalid, .ProseMirror pre code .tok-deleted {
401
- color: light-dark(#82071e, #ffa198);
402
- }
403
+ .ProseMirror pre code .tok-definition {
404
+ color: light-dark(#8250df, #d2a8ff);
405
+ }
403
406
 
404
- .ProseMirror pre code .tok-heading {
405
- color: light-dark(#0550ae, #79c0ff);
406
- font-weight: 600;
407
- }
407
+ .ProseMirror pre code .tok-macroName, .ProseMirror pre code .tok-meta, .ProseMirror pre code .tok-inserted {
408
+ color: light-dark(#116329, #7ee787);
409
+ }
408
410
 
409
- .ProseMirror pre code .tok-strong {
410
- font-weight: 600;
411
- }
411
+ .ProseMirror pre code .tok-invalid, .ProseMirror pre code .tok-deleted {
412
+ color: light-dark(#82071e, #ffa198);
413
+ }
412
414
 
413
- .ProseMirror pre code .tok-emphasis {
414
- font-style: italic;
415
- }
415
+ .ProseMirror pre code .tok-heading {
416
+ color: light-dark(#0550ae, #79c0ff);
417
+ font-weight: 600;
418
+ }
416
419
 
417
- .ProseMirror pre code .tok-link {
418
- text-decoration: underline;
419
- }
420
+ .ProseMirror pre code .tok-strong {
421
+ font-weight: 600;
422
+ }
420
423
 
421
- .ProseMirror hr {
422
- border: none;
423
- border-top: 1px solid var(--meowdown-border);
424
- margin: 1.5em 0;
425
- }
424
+ .ProseMirror pre code .tok-emphasis {
425
+ font-style: italic;
426
+ }
426
427
 
427
- .ProseMirror table {
428
- border-collapse: collapse;
429
- table-layout: fixed;
430
- width: 100%;
431
- overflow: hidden;
432
- }
428
+ .ProseMirror pre code .tok-link {
429
+ text-decoration: underline;
430
+ }
433
431
 
434
- .ProseMirror td, .ProseMirror th {
435
- box-sizing: border-box;
436
- border: 1px solid var(--meowdown-border);
437
- vertical-align: top;
438
- text-align: left;
439
- padding: .4rem .75rem;
440
- }
432
+ .ProseMirror hr {
433
+ border: none;
434
+ border-top: 1px solid var(--meowdown-border);
435
+ margin: 1.5em 0;
436
+ }
441
437
 
442
- .ProseMirror th {
443
- color: var(--meowdown-heading);
444
- background: var(--meowdown-table-header-bg);
445
- font-weight: 600;
446
- }
438
+ .ProseMirror table {
439
+ border-collapse: collapse;
440
+ table-layout: fixed;
441
+ width: 100%;
442
+ overflow: hidden;
443
+ }
447
444
 
448
- .ProseMirror table.ProseMirror-selectednode td, .ProseMirror table.ProseMirror-selectednode th {
449
- border-color: var(--meowdown-node-outline);
450
- }
445
+ .ProseMirror td, .ProseMirror th {
446
+ box-sizing: border-box;
447
+ border: 1px solid var(--meowdown-border);
448
+ vertical-align: top;
449
+ text-align: left;
450
+ padding: .4rem .75rem;
451
+ }
451
452
 
452
- .ProseMirror .selectedCell {
453
- border: 1px double var(--meowdown-node-outline);
454
- background: var(--meowdown-node-selection);
455
- caret-color: #0000;
456
- }
453
+ .ProseMirror th {
454
+ color: var(--meowdown-heading);
455
+ background: var(--meowdown-table-header-bg);
456
+ font-weight: 600;
457
+ }
457
458
 
458
- .ProseMirror ::selection, .ProseMirror .prosekit-virtual-selection {
459
- background: var(--meowdown-selection);
460
- }
459
+ .ProseMirror table.ProseMirror-selectednode td, .ProseMirror table.ProseMirror-selectednode th {
460
+ border-color: var(--meowdown-node-outline);
461
+ }
461
462
 
462
- .ProseMirror.ProseMirror-hideselection ::selection {
463
- --meowdown-selection: transparent;
464
- caret-color: #0000;
465
- }
463
+ .ProseMirror .selectedCell {
464
+ border: 1px double var(--meowdown-node-outline);
465
+ background: var(--meowdown-node-selection);
466
+ caret-color: #0000;
467
+ }
466
468
 
467
- .ProseMirror .ProseMirror-selectednode {
468
- outline: 1px solid var(--meowdown-node-outline);
469
- background: var(--meowdown-node-selection);
470
- border-radius: 2px;
471
- }
469
+ .ProseMirror ::selection, .ProseMirror .prosekit-virtual-selection {
470
+ background: var(--meowdown-selection);
471
+ }
472
472
 
473
- .ProseMirror pre.ProseMirror-selectednode {
474
- border-radius: .6rem;
475
- }
473
+ .ProseMirror.ProseMirror-hideselection ::selection {
474
+ caret-color: #0000;
475
+ background: none;
476
+ }
476
477
 
477
- .ProseMirror.prosekit-dragging {
478
- --meowdown-node-selection: transparent;
479
- }
478
+ .ProseMirror .ProseMirror-selectednode {
479
+ outline: 1px solid var(--meowdown-node-outline);
480
+ background: var(--meowdown-node-selection);
481
+ border-radius: 2px;
482
+ }
480
483
 
481
- .ProseMirror .md-tag {
482
- background: color-mix(in oklab, var(--meowdown-accent) 10%, transparent);
483
- color: color-mix(in oklab, var(--meowdown-accent) 80%, var(--meowdown-heading));
484
- cursor: pointer;
485
- border-radius: 6px;
486
- padding: 2px 6px;
487
- }
484
+ .ProseMirror pre.ProseMirror-selectednode {
485
+ border-radius: .6rem;
486
+ }
488
487
 
489
- .ProseMirror .md-embed-youtube {
490
- aspect-ratio: 16 / 9;
491
- border-radius: var(--meowdown-image-radius, .5rem);
492
- border: 0;
493
- width: 100%;
494
- display: block;
495
- }
488
+ .ProseMirror.prosekit-dragging .ProseMirror-selectednode, .ProseMirror.prosekit-dragging .selectedCell {
489
+ background: none;
490
+ }
496
491
 
497
- .ProseMirror .md-embed-tweet {
498
- border: 0;
499
- width: 100%;
500
- max-width: 550px;
501
- display: block;
502
- }
492
+ .ProseMirror .md-tag {
493
+ background: color-mix(in oklab, var(--meowdown-accent) 10%, transparent);
494
+ color: color-mix(in oklab, var(--meowdown-accent) 80%, var(--meowdown-heading));
495
+ cursor: pointer;
496
+ border-radius: 6px;
497
+ padding: 2px 6px;
498
+ }
503
499
 
504
- .ProseMirror .prosekit-placeholder:before {
505
- content: attr(data-placeholder);
506
- float: left;
507
- pointer-events: none;
508
- height: 0;
509
- color: var(--meowdown-placeholder, var(--meowdown-muted));
510
- }
500
+ .ProseMirror .md-embed-youtube {
501
+ aspect-ratio: 16 / 9;
502
+ border-radius: var(--meowdown-image-radius, .5rem);
503
+ border: 0;
504
+ width: 100%;
505
+ display: block;
506
+ }
511
507
 
512
- .ProseMirror .md-mark {
513
- color: var(--meowdown-mark);
514
- opacity: .7;
515
- }
508
+ .ProseMirror .md-embed-tweet {
509
+ border: 0;
510
+ width: 100%;
511
+ max-width: 550px;
512
+ display: block;
513
+ }
516
514
 
517
- .ProseMirror .md-link-uri, .ProseMirror .md-link-title {
518
- color: var(--meowdown-accent);
519
- text-underline-offset: 2px;
520
- opacity: .7;
521
- text-decoration: underline 1px;
522
- }
515
+ .ProseMirror .prosekit-placeholder:before {
516
+ content: attr(data-placeholder);
517
+ float: left;
518
+ pointer-events: none;
519
+ height: 0;
520
+ color: var(--meowdown-placeholder, var(--meowdown-muted));
521
+ }
523
522
 
524
- .ProseMirror .md-pack {
525
- display: contents;
526
- }
523
+ .ProseMirror .md-mark {
524
+ color: var(--meowdown-mark);
525
+ opacity: .7;
526
+ }
527
527
 
528
- .ProseMirror[data-mark-mode="hide"] {
529
- & .md-mark, & .md-link-uri, & .md-link-title {
530
- display: none;
528
+ .ProseMirror .md-link-uri, .ProseMirror .md-link-title {
529
+ color: var(--meowdown-accent);
530
+ text-underline-offset: 2px;
531
+ opacity: .7;
532
+ text-decoration: underline 1px;
531
533
  }
532
- }
533
534
 
534
- .ProseMirror[data-mark-mode="focus"] {
535
- & .md-mark, & .md-link-uri, & .md-link-title {
536
- vertical-align: bottom;
537
- letter-spacing: -2em;
538
- display: inline-block;
539
- overflow: hidden;
535
+ .ProseMirror .md-pack {
536
+ display: contents;
537
+ }
540
538
 
541
- &:has(.show) {
542
- letter-spacing: 0;
539
+ .ProseMirror[data-mark-mode="hide"] {
540
+ & .md-mark, & .md-link-uri, & .md-link-title {
541
+ display: none;
543
542
  }
544
543
  }
545
- }
546
544
 
547
- .ProseMirror {
548
- & .md-atom-view {
549
- vertical-align: bottom;
550
- display: inline-block;
551
- }
545
+ .ProseMirror[data-mark-mode="focus"] {
546
+ & .md-mark, & .md-link-uri, & .md-link-title {
547
+ vertical-align: bottom;
548
+ letter-spacing: -2em;
549
+ display: inline-block;
550
+ overflow: hidden;
552
551
 
553
- & .md-atom-view-preview {
554
- vertical-align: bottom;
555
- -webkit-user-select: none;
556
- user-select: none;
557
- border-radius: 6px;
558
- display: inline-block;
559
- overflow: hidden;
552
+ &:has(.show) {
553
+ letter-spacing: 0;
554
+ }
555
+ }
560
556
  }
561
557
 
562
- & .md-atom-view:has(.md-atom-selected) {
558
+ .ProseMirror {
559
+ & .md-atom-view {
560
+ vertical-align: bottom;
561
+ display: inline-block;
562
+ }
563
+
563
564
  & .md-atom-view-preview {
564
- outline: 2px solid var(--meowdown-node-outline);
565
- background: var(--meowdown-selection);
565
+ vertical-align: bottom;
566
+ -webkit-user-select: none;
567
+ user-select: none;
568
+ border-radius: 6px;
569
+ display: inline-block;
570
+ overflow: hidden;
566
571
  }
567
572
 
568
- & ::selection {
569
- background-color: #0000;
573
+ & .md-atom-view:has(.md-atom-selected) {
574
+ & .md-atom-view-preview {
575
+ outline: 2px solid var(--meowdown-node-outline);
576
+ background: var(--meowdown-selection);
577
+ }
578
+
579
+ & ::selection {
580
+ background-color: #0000;
581
+ }
570
582
  }
571
- }
572
583
 
573
- & .md-atom-view-content {
574
- letter-spacing: -2em;
575
- box-sizing: border-box;
576
- color: #0000;
577
- background-color: #0000;
578
- align-items: end;
579
- width: 2px;
580
- margin-left: 2px;
581
- margin-right: -4px;
582
- display: inline-flex;
583
- overflow: visible;
584
+ & .md-atom-view-content {
585
+ letter-spacing: -2em;
586
+ box-sizing: border-box;
587
+ color: #0000;
588
+ background-color: #0000;
589
+ align-items: end;
590
+ width: 2px;
591
+ margin-left: 2px;
592
+ margin-right: -4px;
593
+ display: inline-flex;
594
+ overflow: visible;
595
+ }
584
596
  }
585
- }
586
597
 
587
- .ProseMirror {
588
- & .md-image-view {
589
- max-width: 100%;
590
- margin-left: 2px;
591
- margin-right: 2px;
592
- }
598
+ .ProseMirror {
599
+ & .md-image-view {
600
+ max-width: 100%;
601
+ margin-left: 2px;
602
+ margin-right: 2px;
603
+ }
593
604
 
594
- & .md-image-view-preview {
595
- outline-offset: 2px;
596
- border-radius: 6px;
597
- max-width: 100%;
598
- display: inline-block;
599
- }
605
+ & .md-image-view-preview {
606
+ outline-offset: 2px;
607
+ border-radius: 6px;
608
+ max-width: 100%;
609
+ display: inline-block;
610
+ }
600
611
 
601
- & .md-image-resizable {
602
- vertical-align: bottom;
603
- isolation: isolate;
604
- min-width: 2.5rem;
605
- max-width: 100%;
606
- min-height: 2.5rem;
607
- display: inline-block;
608
- position: relative;
609
- }
612
+ & .md-image-resizable {
613
+ vertical-align: bottom;
614
+ isolation: isolate;
615
+ min-width: 2.5rem;
616
+ max-width: 100%;
617
+ min-height: 2.5rem;
618
+ display: inline-block;
619
+ position: relative;
620
+ }
610
621
 
611
- & .md-image-resizable[data-loading] {
612
- background: var(--meowdown-image-loading-bg);
613
- border-radius: var(--meowdown-image-radius, .5rem);
614
- }
622
+ & .md-image-resizable[data-loading] {
623
+ background: var(--meowdown-image-loading-bg);
624
+ border-radius: var(--meowdown-image-radius, .5rem);
625
+ }
615
626
 
616
- & .md-image-resizable img {
617
- object-fit: contain;
618
- border-radius: var(--meowdown-image-radius, .5rem);
619
- width: 100%;
620
- height: 100%;
621
- display: block;
622
- }
627
+ & .md-image-resizable img {
628
+ object-fit: contain;
629
+ border-radius: var(--meowdown-image-radius, .5rem);
630
+ width: 100%;
631
+ height: 100%;
632
+ display: block;
633
+ }
623
634
 
624
- & .md-image-resize-handle {
625
- box-sizing: border-box;
626
- mix-blend-mode: exclusion;
627
- cursor: nwse-resize;
628
- pointer-events: none;
629
- touch-action: none;
630
- opacity: 0;
631
- transform-origin: 100% 100%;
632
- border-bottom: 3px solid #fff;
633
- border-right: 3px solid #fff;
634
- border-bottom-right-radius: 5px;
635
- width: 14px;
636
- height: 14px;
637
- transition: opacity .12s, transform .12s;
638
- position: absolute;
639
- bottom: 4px;
640
- right: 4px;
641
- transform: scale(.8);
642
- }
635
+ & .md-image-resize-handle {
636
+ box-sizing: border-box;
637
+ mix-blend-mode: exclusion;
638
+ cursor: nwse-resize;
639
+ pointer-events: none;
640
+ touch-action: none;
641
+ opacity: 0;
642
+ transform-origin: 100% 100%;
643
+ border-bottom: 3px solid #fff;
644
+ border-right: 3px solid #fff;
645
+ border-bottom-right-radius: 5px;
646
+ width: 14px;
647
+ height: 14px;
648
+ transition: opacity .12s, transform .12s;
649
+ position: absolute;
650
+ bottom: 4px;
651
+ right: 4px;
652
+ transform: scale(.8);
653
+ }
643
654
 
644
- & .md-image-resizable:hover .md-image-resize-handle, & .md-image-resizable[data-resizing] .md-image-resize-handle {
645
- opacity: 1;
646
- pointer-events: auto;
647
- transform: scale(1);
655
+ & .md-image-resizable:hover .md-image-resize-handle, & .md-image-resizable[data-resizing] .md-image-resize-handle {
656
+ opacity: 1;
657
+ pointer-events: auto;
658
+ transform: scale(1);
659
+ }
648
660
  }
649
- }
650
661
 
651
- .ProseMirror {
652
- & .md-wikilink-view-label {
653
- background: color-mix(in oklab, var(--meowdown-accent) 10%, transparent);
654
- color: color-mix(in oklab, var(--meowdown-accent) 80%, var(--meowdown-heading));
655
- text-underline-offset: 2px;
656
- cursor: pointer;
657
- border-radius: 6px;
658
- padding: 2px 5px;
659
- text-decoration-line: underline;
660
- text-decoration-style: dashed;
661
- text-decoration-thickness: 1px;
662
- overflow: hidden;
663
- }
662
+ .ProseMirror {
663
+ & .md-wikilink-view-label {
664
+ background: color-mix(in oklab, var(--meowdown-accent) 10%, transparent);
665
+ color: color-mix(in oklab, var(--meowdown-accent) 80%, var(--meowdown-heading));
666
+ text-underline-offset: 2px;
667
+ cursor: pointer;
668
+ border-radius: 6px;
669
+ padding: 2px 5px;
670
+ text-decoration-line: underline;
671
+ text-decoration-style: dashed;
672
+ text-decoration-thickness: 1px;
673
+ overflow: hidden;
674
+ }
664
675
 
665
- & .md-wikilink-view:has(.md-atom-selected) .md-wikilink-view-label {
666
- background-color: #0000;
667
- outline-color: #0000;
676
+ & .md-wikilink-view:has(.md-atom-selected) .md-wikilink-view-label {
677
+ background-color: #0000;
678
+ outline-color: #0000;
679
+ }
668
680
  }
669
681
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@meowdown/core",
3
3
  "type": "module",
4
- "version": "0.29.2",
4
+ "version": "0.30.0",
5
5
  "license": "MIT",
6
6
  "repository": {
7
7
  "type": "git",
@@ -28,7 +28,7 @@
28
28
  "@prosekit/core": "^0.13.0-beta.4",
29
29
  "@prosekit/extensions": "^0.18.0-beta.11",
30
30
  "@prosekit/pm": "^0.1.19-beta.1",
31
- "@prosekit/web": "^0.9.0-beta.14",
31
+ "@prosekit/web": "^0.9.0-beta.15",
32
32
  "prosemirror-flat-list": "^0.6.0",
33
33
  "prosemirror-highlight": "^0.15.2",
34
34
  "rehype-parse": "^9.0.1",