@marimo-team/islands 0.24.1-dev69 → 0.24.1-dev70
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{common-BQcRCkCg.js → common-C6L3WH7a.js} +1 -1
- package/dist/main.js +2 -2
- package/dist/{reveal-component-DrW90oHy.js → reveal-component-CfHpJ-YS.js} +1 -1
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/src/components/markdown/markdown-renderer.css +2 -13
- package/src/core/islands/main.ts +1 -0
- package/src/css/index.css +1 -0
- package/src/css/markdown-typography.css +51 -0
- package/src/css/md.css +0 -27
package/package.json
CHANGED
|
@@ -1,19 +1,8 @@
|
|
|
1
|
+
/* Tailwind scans Streamdown's compiled output for utility classes. */
|
|
2
|
+
/* stylelint-disable-next-line at-rule-no-unknown */
|
|
1
3
|
@source "../../../node_modules/streamdown/dist/index.js";
|
|
2
4
|
|
|
3
5
|
.mo-markdown-renderer {
|
|
4
|
-
/* Make headers a bit smaller */
|
|
5
|
-
--text-2xl: 1rem;
|
|
6
|
-
--text-3xl: 1.2rem;
|
|
7
|
-
|
|
8
|
-
h1,
|
|
9
|
-
h2,
|
|
10
|
-
h3,
|
|
11
|
-
h4,
|
|
12
|
-
h5,
|
|
13
|
-
h6 {
|
|
14
|
-
margin-top: 10px;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
6
|
hr {
|
|
18
7
|
margin-top: 8px;
|
|
19
8
|
margin-bottom: 12px;
|
package/src/core/islands/main.ts
CHANGED
package/src/css/index.css
CHANGED
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
/* Copyright 2026 Marimo. All rights reserved. */
|
|
2
|
+
|
|
3
|
+
:is(.markdown, .mo-markdown-renderer) {
|
|
4
|
+
:is(h1, h2, h3, h4, h5, h6) {
|
|
5
|
+
font-family: var(--heading-font);
|
|
6
|
+
font-weight: inherit;
|
|
7
|
+
margin-block: 1.5rem 1rem;
|
|
8
|
+
line-height: 1.25;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
/* Keep heading sizes relative to the renderer text size. */
|
|
12
|
+
/* stylelint-disable unit-allowed-list */
|
|
13
|
+
|
|
14
|
+
h1 {
|
|
15
|
+
font-size: 2.25em;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
h2 {
|
|
19
|
+
font-size: 1.5em;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
h3 {
|
|
23
|
+
font-size: 1.25em;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
:is(h4, h5, h6) {
|
|
27
|
+
font-size: 1em;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
/* stylelint-enable unit-allowed-list */
|
|
31
|
+
|
|
32
|
+
:is(ul, ol) > li {
|
|
33
|
+
margin-block: 0;
|
|
34
|
+
padding-block: 0;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
:is(.markdown, .mo-markdown-renderer) table {
|
|
39
|
+
font-variant-numeric: tabular-nums;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
:is(.markdown, .mo-markdown-renderer)
|
|
43
|
+
> :is(h1, h2, h3, h4, h5, h6, p, .paragraph, ul, ol, blockquote) {
|
|
44
|
+
max-inline-size: var(--markdown-max-width);
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
@supports (text-wrap: balance) {
|
|
48
|
+
:is(.markdown, .mo-markdown-renderer) :is(h1, h2, h3, h4, h5, h6) {
|
|
49
|
+
text-wrap: balance;
|
|
50
|
+
}
|
|
51
|
+
}
|
package/src/css/md.css
CHANGED
|
@@ -12,11 +12,6 @@
|
|
|
12
12
|
margin-block-end: 0;
|
|
13
13
|
}
|
|
14
14
|
|
|
15
|
-
.markdown ul li,
|
|
16
|
-
.markdown ol li {
|
|
17
|
-
margin-block: 0;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
15
|
/* Restore browser default bullet cycling that Tailwind Typography overrides */
|
|
21
16
|
.markdown ul ul {
|
|
22
17
|
list-style-type: revert;
|
|
@@ -41,28 +36,6 @@
|
|
|
41
36
|
margin-inline: 0;
|
|
42
37
|
}
|
|
43
38
|
|
|
44
|
-
.markdown h1,
|
|
45
|
-
.markdown h2,
|
|
46
|
-
.markdown h3,
|
|
47
|
-
.markdown h4,
|
|
48
|
-
.markdown h5,
|
|
49
|
-
.markdown h6 {
|
|
50
|
-
font-weight: inherit;
|
|
51
|
-
font-family: var(--heading-font);
|
|
52
|
-
|
|
53
|
-
/*
|
|
54
|
-
Anchor heading spacing to GitHub's markdown rhythm (Primer): a uniform
|
|
55
|
-
24px top / 16px bottom margin and 1.25 line-height across every level,
|
|
56
|
-
letting font-size — not margin — carry the hierarchy. Tailwind Typography's
|
|
57
|
-
prose defaults scale heading margins per-level up to ~2em (≈48px on h2),
|
|
58
|
-
which is tuned for long-form articles and reads as too airy in a notebook.
|
|
59
|
-
Ref: https://github.com/sindresorhus/github-markdown-css
|
|
60
|
-
*/
|
|
61
|
-
margin-top: 1.5rem;
|
|
62
|
-
margin-bottom: 1rem;
|
|
63
|
-
line-height: 1.25;
|
|
64
|
-
}
|
|
65
|
-
|
|
66
39
|
.markdown hr {
|
|
67
40
|
margin-block: 0.5rem;
|
|
68
41
|
}
|