From b8b9732e99f3dfe11e2c395afaed84c1761655ce Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Wed, 11 Oct 2023 02:26:37 +0700 Subject: [PATCH 01/19] Regenerate GitHub CSS --- github-markdown-dark.css | 40 ++++++++++++-------- github-markdown-light.css | 38 +++++++++++-------- github-markdown.css | 78 ++++++++++++++++++++++++++++++++------- package.json | 5 ++- 4 files changed, 116 insertions(+), 45 deletions(-) diff --git a/github-markdown-dark.css b/github-markdown-dark.css index 3c5a8b3..529b678 100644 --- a/github-markdown-dark.css +++ b/github-markdown-dark.css @@ -1,9 +1,11 @@ +/*dark*/ + .markdown-body { color-scheme: dark; -ms-text-size-adjust: 100%; -webkit-text-size-adjust: 100%; margin: 0; - color: #c9d1d9; + color: #e6edf3; background-color: #0d1117; font-family: -apple-system,BlinkMacSystemFont,"Segoe UI","Noto Sans",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"; font-size: 16px; @@ -48,12 +50,13 @@ .markdown-body a { background-color: transparent; - color: #58a6ff; + color: #2f81f7; text-decoration: none; } .markdown-body abbr[title] { border-bottom: none; + -webkit-text-decoration: underline dotted; text-decoration: underline dotted; } @@ -76,7 +79,7 @@ .markdown-body mark { background-color: rgba(187,128,9,0.15); - color: #c9d1d9; + color: #e6edf3; } .markdown-body small { @@ -217,7 +220,7 @@ .markdown-body [role=button]:focus, .markdown-body input[type=radio]:focus, .markdown-body input[type=checkbox]:focus { - outline: 2px solid #58a6ff; + outline: 2px solid #2f81f7; outline-offset: -2px; box-shadow: none; } @@ -233,7 +236,7 @@ .markdown-body [role=button]:focus-visible, .markdown-body input[type=radio]:focus-visible, .markdown-body input[type=checkbox]:focus-visible { - outline: 2px solid #58a6ff; + outline: 2px solid #2f81f7; outline-offset: -2px; box-shadow: none; } @@ -252,7 +255,7 @@ padding: 3px 5px; font: 11px ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace; line-height: 10px; - color: #c9d1d9; + color: #e6edf3; vertical-align: middle; background-color: #161b22; border: solid 1px rgba(110,118,129,0.4); @@ -298,7 +301,7 @@ .markdown-body h6 { font-weight: 600; font-size: .85em; - color: #8b949e; + color: #7d8590; } .markdown-body p { @@ -309,7 +312,7 @@ .markdown-body blockquote { margin: 0; padding: 0 1em; - color: #8b949e; + color: #7d8590; border-left: .25em solid #30363d; } @@ -430,7 +433,7 @@ .markdown-body h4 .octicon-link, .markdown-body h5 .octicon-link, .markdown-body h6 .octicon-link { - color: #c9d1d9; + color: #e6edf3; vertical-align: middle; visibility: hidden; } @@ -499,19 +502,19 @@ list-style-type: none; } -.markdown-body ol[type=a] { +.markdown-body ol[type="a s"] { list-style-type: lower-alpha; } -.markdown-body ol[type=A] { +.markdown-body ol[type="A s"] { list-style-type: upper-alpha; } -.markdown-body ol[type=i] { +.markdown-body ol[type="i s"] { list-style-type: lower-roman; } -.markdown-body ol[type=I] { +.markdown-body ol[type="I s"] { list-style-type: upper-roman; } @@ -566,6 +569,10 @@ border: 1px solid #30363d; } +.markdown-body table td>:last-child { + margin-bottom: 0; +} + .markdown-body table tr { background-color: #0d1117; border-top: 1px solid #21262d; @@ -617,7 +624,7 @@ display: block; padding: 5px 0 0; clear: both; - color: #c9d1d9; + color: #e6edf3; } .markdown-body span.align-center { @@ -732,6 +739,7 @@ overflow: auto; font-size: 85%; line-height: 1.45; + color: #e6edf3; background-color: #161b22; border-radius: 6px; } @@ -786,7 +794,7 @@ .markdown-body .footnotes { font-size: 12px; - color: #8b949e; + color: #7d8590; border-top: 1px solid #30363d; } @@ -817,7 +825,7 @@ } .markdown-body .footnotes li:target { - color: #c9d1d9; + color: #e6edf3; } .markdown-body .footnotes .data-footnote-backref g-emoji { diff --git a/github-markdown-light.css b/github-markdown-light.css index 33766e8..5fe7d9e 100644 --- a/github-markdown-light.css +++ b/github-markdown-light.css @@ -1,8 +1,10 @@ +/*light*/ + .markdown-body { -ms-text-size-adjust: 100%; -webkit-text-size-adjust: 100%; margin: 0; - color: #24292f; + color: #1F2328; background-color: #ffffff; font-family: -apple-system,BlinkMacSystemFont,"Segoe UI","Noto Sans",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"; font-size: 16px; @@ -53,6 +55,7 @@ .markdown-body abbr[title] { border-bottom: none; + -webkit-text-decoration: underline dotted; text-decoration: underline dotted; } @@ -75,7 +78,7 @@ .markdown-body mark { background-color: #fff8c5; - color: #24292f; + color: #1F2328; } .markdown-body small { @@ -251,7 +254,7 @@ padding: 3px 5px; font: 11px ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace; line-height: 10px; - color: #24292f; + color: #1F2328; vertical-align: middle; background-color: #f6f8fa; border: solid 1px rgba(175,184,193,0.2); @@ -297,7 +300,7 @@ .markdown-body h6 { font-weight: 600; font-size: .85em; - color: #57606a; + color: #656d76; } .markdown-body p { @@ -308,7 +311,7 @@ .markdown-body blockquote { margin: 0; padding: 0 1em; - color: #57606a; + color: #656d76; border-left: .25em solid #d0d7de; } @@ -389,7 +392,7 @@ } .markdown-body .absent { - color: #cf222e; + color: #d1242f; } .markdown-body .anchor { @@ -429,7 +432,7 @@ .markdown-body h4 .octicon-link, .markdown-body h5 .octicon-link, .markdown-body h6 .octicon-link { - color: #24292f; + color: #1F2328; vertical-align: middle; visibility: hidden; } @@ -498,19 +501,19 @@ list-style-type: none; } -.markdown-body ol[type=a] { +.markdown-body ol[type="a s"] { list-style-type: lower-alpha; } -.markdown-body ol[type=A] { +.markdown-body ol[type="A s"] { list-style-type: upper-alpha; } -.markdown-body ol[type=i] { +.markdown-body ol[type="i s"] { list-style-type: lower-roman; } -.markdown-body ol[type=I] { +.markdown-body ol[type="I s"] { list-style-type: upper-roman; } @@ -565,6 +568,10 @@ border: 1px solid #d0d7de; } +.markdown-body table td>:last-child { + margin-bottom: 0; +} + .markdown-body table tr { background-color: #ffffff; border-top: 1px solid hsla(210,18%,87%,1); @@ -616,7 +623,7 @@ display: block; padding: 5px 0 0; clear: both; - color: #24292f; + color: #1F2328; } .markdown-body span.align-center { @@ -731,6 +738,7 @@ overflow: auto; font-size: 85%; line-height: 1.45; + color: #1F2328; background-color: #f6f8fa; border-radius: 6px; } @@ -785,7 +793,7 @@ .markdown-body .footnotes { font-size: 12px; - color: #57606a; + color: #656d76; border-top: 1px solid #d0d7de; } @@ -816,7 +824,7 @@ } .markdown-body .footnotes li:target { - color: #24292f; + color: #1F2328; } .markdown-body .footnotes .data-footnote-backref g-emoji { @@ -834,7 +842,7 @@ .markdown-body .pl-e, .markdown-body .pl-en { - color: #8250df; + color: #6639ba; } .markdown-body .pl-smi, diff --git a/github-markdown.css b/github-markdown.css index 0c333ba..c79ea68 100644 --- a/github-markdown.css +++ b/github-markdown.css @@ -1,5 +1,7 @@ @media (prefers-color-scheme: dark) { - .markdown-body { + .markdown-body, + [data-theme="dark"] { + /*dark*/ color-scheme: dark; --color-prettylights-syntax-comment: #8b949e; --color-prettylights-syntax-constant: #79c0ff; @@ -31,15 +33,15 @@ --color-prettylights-syntax-brackethighlighter-angle: #8b949e; --color-prettylights-syntax-sublimelinter-gutter-mark: #484f58; --color-prettylights-syntax-constant-other-reference-link: #a5d6ff; - --color-fg-default: #c9d1d9; - --color-fg-muted: #8b949e; + --color-fg-default: #e6edf3; + --color-fg-muted: #7d8590; --color-fg-subtle: #6e7681; --color-canvas-default: #0d1117; --color-canvas-subtle: #161b22; --color-border-default: #30363d; --color-border-muted: #21262d; --color-neutral-muted: rgba(110,118,129,0.4); - --color-accent-fg: #58a6ff; + --color-accent-fg: #2f81f7; --color-accent-emphasis: #1f6feb; --color-attention-subtle: rgba(187,128,9,0.15); --color-danger-fg: #f85149; @@ -47,11 +49,13 @@ } @media (prefers-color-scheme: light) { - .markdown-body { + .markdown-body, + [data-theme="light"] { + /*light*/ color-scheme: light; --color-prettylights-syntax-comment: #6e7781; --color-prettylights-syntax-constant: #0550ae; - --color-prettylights-syntax-entity: #8250df; + --color-prettylights-syntax-entity: #6639ba; --color-prettylights-syntax-storage-modifier-import: #24292f; --color-prettylights-syntax-entity-tag: #116329; --color-prettylights-syntax-keyword: #cf222e; @@ -79,8 +83,8 @@ --color-prettylights-syntax-brackethighlighter-angle: #57606a; --color-prettylights-syntax-sublimelinter-gutter-mark: #8c959f; --color-prettylights-syntax-constant-other-reference-link: #0a3069; - --color-fg-default: #24292f; - --color-fg-muted: #57606a; + --color-fg-default: #1F2328; + --color-fg-muted: #656d76; --color-fg-subtle: #6e7781; --color-canvas-default: #ffffff; --color-canvas-subtle: #f6f8fa; @@ -90,7 +94,49 @@ --color-accent-fg: #0969da; --color-accent-emphasis: #0969da; --color-attention-subtle: #fff8c5; - --color-danger-fg: #cf222e; + --color-danger-fg: #d1242f; + --color-prettylights-syntax-comment: #6e7781; + --color-prettylights-syntax-constant: #0550ae; + --color-prettylights-syntax-entity: #6639ba; + --color-prettylights-syntax-storage-modifier-import: #24292f; + --color-prettylights-syntax-entity-tag: #116329; + --color-prettylights-syntax-keyword: #cf222e; + --color-prettylights-syntax-string: #0a3069; + --color-prettylights-syntax-variable: #953800; + --color-prettylights-syntax-brackethighlighter-unmatched: #82071e; + --color-prettylights-syntax-invalid-illegal-text: #f6f8fa; + --color-prettylights-syntax-invalid-illegal-bg: #82071e; + --color-prettylights-syntax-carriage-return-text: #f6f8fa; + --color-prettylights-syntax-carriage-return-bg: #cf222e; + --color-prettylights-syntax-string-regexp: #116329; + --color-prettylights-syntax-markup-list: #3b2300; + --color-prettylights-syntax-markup-heading: #0550ae; + --color-prettylights-syntax-markup-italic: #24292f; + --color-prettylights-syntax-markup-bold: #24292f; + --color-prettylights-syntax-markup-deleted-text: #82071e; + --color-prettylights-syntax-markup-deleted-bg: #ffebe9; + --color-prettylights-syntax-markup-inserted-text: #116329; + --color-prettylights-syntax-markup-inserted-bg: #dafbe1; + --color-prettylights-syntax-markup-changed-text: #953800; + --color-prettylights-syntax-markup-changed-bg: #ffd8b5; + --color-prettylights-syntax-markup-ignored-text: #eaeef2; + --color-prettylights-syntax-markup-ignored-bg: #0550ae; + --color-prettylights-syntax-meta-diff-range: #8250df; + --color-prettylights-syntax-brackethighlighter-angle: #57606a; + --color-prettylights-syntax-sublimelinter-gutter-mark: #8c959f; + --color-prettylights-syntax-constant-other-reference-link: #0a3069; + --color-fg-default: #1F2328; + --color-fg-muted: #656d76; + --color-fg-subtle: #6e7781; + --color-canvas-default: #ffffff; + --color-canvas-subtle: #f6f8fa; + --color-border-default: #d0d7de; + --color-border-muted: hsla(210,18%,87%,1); + --color-neutral-muted: rgba(175,184,193,0.2); + --color-accent-fg: #0969da; + --color-accent-emphasis: #0969da; + --color-attention-subtle: #fff8c5; + --color-danger-fg: #d1242f; } } @@ -149,6 +195,7 @@ .markdown-body abbr[title] { border-bottom: none; + -webkit-text-decoration: underline dotted; text-decoration: underline dotted; } @@ -594,19 +641,19 @@ list-style-type: none; } -.markdown-body ol[type=a] { +.markdown-body ol[type="a s"] { list-style-type: lower-alpha; } -.markdown-body ol[type=A] { +.markdown-body ol[type="A s"] { list-style-type: upper-alpha; } -.markdown-body ol[type=i] { +.markdown-body ol[type="i s"] { list-style-type: lower-roman; } -.markdown-body ol[type=I] { +.markdown-body ol[type="I s"] { list-style-type: upper-roman; } @@ -661,6 +708,10 @@ border: 1px solid var(--color-border-default); } +.markdown-body table td>:last-child { + margin-bottom: 0; +} + .markdown-body table tr { background-color: var(--color-canvas-default); border-top: 1px solid var(--color-border-muted); @@ -827,6 +878,7 @@ overflow: auto; font-size: 85%; line-height: 1.45; + color: var(--color-fg-default); background-color: var(--color-canvas-subtle); border-radius: 6px; } diff --git a/package.json b/package.json index 54b3adc..2a89055 100644 --- a/package.json +++ b/package.json @@ -11,6 +11,9 @@ "url": "https://sindresorhus.com" }, "main": "github-markdown.css", + "engines": { + "node": ">=10" + }, "scripts": { "make:light": "github-markdown-css --type light > github-markdown-light.css", "make:dark": "github-markdown-css --type dark > github-markdown-dark.css", @@ -32,6 +35,6 @@ "stylesheet" ], "devDependencies": { - "generate-github-markdown-css": "^5.0.2" + "generate-github-markdown-css": "^6.0.1" } } From f45eec9fe1551112109abd0c3b0c4fe75e65b1f4 Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Wed, 11 Oct 2023 02:30:18 +0700 Subject: [PATCH 02/19] 5.3.0 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 2a89055..ccea0f4 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "github-markdown-css", - "version": "5.2.0", + "version": "5.3.0", "description": "The minimal amount of CSS to replicate the GitHub Markdown style", "license": "MIT", "repository": "sindresorhus/github-markdown-css", From 1363826bdf7720c18d812a5d6c6cceb878293978 Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Wed, 1 Nov 2023 16:11:31 +0700 Subject: [PATCH 03/19] Regenerate GitHub CSS --- github-markdown-dark.css | 63 +++++++++++++++++++++++++++++++++++ github-markdown-light.css | 63 +++++++++++++++++++++++++++++++++++ github-markdown.css | 69 +++++++++++++++++++++++++++++++++++++++ package.json | 2 +- 4 files changed, 196 insertions(+), 1 deletion(-) diff --git a/github-markdown-dark.css b/github-markdown-dark.css index 529b678..3b09f5f 100644 --- a/github-markdown-dark.css +++ b/github-markdown-dark.css @@ -368,6 +368,34 @@ appearance: none; } +.markdown-body .color-fg-accent { + color: #2f81f7 !important; +} + +.markdown-body .color-fg-attention { + color: #d29922 !important; +} + +.markdown-body .color-fg-done { + color: #a371f7 !important; +} + +.markdown-body .flex-items-center { + align-items: center !important; +} + +.markdown-body .mb-1 { + margin-bottom: var(--base-size-4, 4px) !important; +} + +.markdown-body .text-semibold { + font-weight: var(--base-text-weight-medium, 500) !important; +} + +.markdown-body .d-inline-flex { + display: inline-flex !important; +} + .markdown-body::before { display: table; content: ""; @@ -1010,6 +1038,41 @@ clip: auto; } +.markdown-body .QueryBuilder .qb-entity { + color: #d2a8ff; +} + +.markdown-body .QueryBuilder .qb-constant { + color: #79c0ff; +} + .markdown-body ::-webkit-calendar-picker-indicator { filter: invert(50%); } + +.markdown-body .markdown-alert { + padding: 0 1em; + margin-bottom: 16px; + color: inherit; + border-left: .25em solid #30363d; +} + +.markdown-body .markdown-alert>:first-child { + margin-top: 0; +} + +.markdown-body .markdown-alert>:last-child { + margin-bottom: 0; +} + +.markdown-body .markdown-alert.markdown-alert-note { + border-left-color: #2f81f7; +} + +.markdown-body .markdown-alert.markdown-alert-important { + border-left-color: #a371f7; +} + +.markdown-body .markdown-alert.markdown-alert-warning { + border-left-color: #d29922; +} diff --git a/github-markdown-light.css b/github-markdown-light.css index 5fe7d9e..8cf3a7d 100644 --- a/github-markdown-light.css +++ b/github-markdown-light.css @@ -367,6 +367,34 @@ appearance: none; } +.markdown-body .color-fg-accent { + color: #0969da !important; +} + +.markdown-body .color-fg-attention { + color: #9a6700 !important; +} + +.markdown-body .color-fg-done { + color: #8250df !important; +} + +.markdown-body .flex-items-center { + align-items: center !important; +} + +.markdown-body .mb-1 { + margin-bottom: var(--base-size-4, 4px) !important; +} + +.markdown-body .text-semibold { + font-weight: var(--base-text-weight-medium, 500) !important; +} + +.markdown-body .d-inline-flex { + display: inline-flex !important; +} + .markdown-body::before { display: table; content: ""; @@ -1009,6 +1037,41 @@ clip: auto; } +.markdown-body .QueryBuilder .qb-entity { + color: #6639ba; +} + +.markdown-body .QueryBuilder .qb-constant { + color: #0550ae; +} + .markdown-body ::-webkit-calendar-picker-indicator { filter: invert(50%); } + +.markdown-body .markdown-alert { + padding: 0 1em; + margin-bottom: 16px; + color: inherit; + border-left: .25em solid #d0d7de; +} + +.markdown-body .markdown-alert>:first-child { + margin-top: 0; +} + +.markdown-body .markdown-alert>:last-child { + margin-bottom: 0; +} + +.markdown-body .markdown-alert.markdown-alert-note { + border-left-color: #0969da; +} + +.markdown-body .markdown-alert.markdown-alert-important { + border-left-color: #8250df; +} + +.markdown-body .markdown-alert.markdown-alert-warning { + border-left-color: #9a6700; +} diff --git a/github-markdown.css b/github-markdown.css index c79ea68..b9fdf29 100644 --- a/github-markdown.css +++ b/github-markdown.css @@ -43,8 +43,10 @@ --color-neutral-muted: rgba(110,118,129,0.4); --color-accent-fg: #2f81f7; --color-accent-emphasis: #1f6feb; + --color-attention-fg: #d29922; --color-attention-subtle: rgba(187,128,9,0.15); --color-danger-fg: #f85149; + --color-done-fg: #a371f7; } } @@ -93,8 +95,10 @@ --color-neutral-muted: rgba(175,184,193,0.2); --color-accent-fg: #0969da; --color-accent-emphasis: #0969da; + --color-attention-fg: #9a6700; --color-attention-subtle: #fff8c5; --color-danger-fg: #d1242f; + --color-done-fg: #8250df; --color-prettylights-syntax-comment: #6e7781; --color-prettylights-syntax-constant: #0550ae; --color-prettylights-syntax-entity: #6639ba; @@ -135,8 +139,10 @@ --color-neutral-muted: rgba(175,184,193,0.2); --color-accent-fg: #0969da; --color-accent-emphasis: #0969da; + --color-attention-fg: #9a6700; --color-attention-subtle: #fff8c5; --color-danger-fg: #d1242f; + --color-done-fg: #8250df; } } @@ -507,6 +513,34 @@ appearance: none; } +.markdown-body .color-fg-accent { + color: var(--color-accent-fg) !important; +} + +.markdown-body .color-fg-attention { + color: var(--color-attention-fg) !important; +} + +.markdown-body .color-fg-done { + color: var(--color-done-fg) !important; +} + +.markdown-body .flex-items-center { + align-items: center !important; +} + +.markdown-body .mb-1 { + margin-bottom: var(--base-size-4, 4px) !important; +} + +.markdown-body .text-semibold { + font-weight: var(--base-text-weight-medium, 500) !important; +} + +.markdown-body .d-inline-flex { + display: inline-flex !important; +} + .markdown-body::before { display: table; content: ""; @@ -1149,6 +1183,41 @@ clip: auto; } +.markdown-body .QueryBuilder .qb-entity { + color: var(--color-prettylights-syntax-entity); +} + +.markdown-body .QueryBuilder .qb-constant { + color: var(--color-prettylights-syntax-constant); +} + .markdown-body ::-webkit-calendar-picker-indicator { filter: invert(50%); } + +.markdown-body .markdown-alert { + padding: 0 1em; + margin-bottom: 16px; + color: inherit; + border-left: .25em solid var(--color-border-default); +} + +.markdown-body .markdown-alert>:first-child { + margin-top: 0; +} + +.markdown-body .markdown-alert>:last-child { + margin-bottom: 0; +} + +.markdown-body .markdown-alert.markdown-alert-note { + border-left-color: var(--color-accent-fg); +} + +.markdown-body .markdown-alert.markdown-alert-important { + border-left-color: var(--color-done-fg); +} + +.markdown-body .markdown-alert.markdown-alert-warning { + border-left-color: var(--color-attention-fg); +} diff --git a/package.json b/package.json index ccea0f4..24dbaa2 100644 --- a/package.json +++ b/package.json @@ -35,6 +35,6 @@ "stylesheet" ], "devDependencies": { - "generate-github-markdown-css": "^6.0.1" + "generate-github-markdown-css": "^6.1.0" } } From b336b4215cde412ab0dc2562cdc1c6740e6078d3 Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Wed, 1 Nov 2023 16:13:19 +0700 Subject: [PATCH 04/19] 5.4.0 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 24dbaa2..2e826d7 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "github-markdown-css", - "version": "5.3.0", + "version": "5.4.0", "description": "The minimal amount of CSS to replicate the GitHub Markdown style", "license": "MIT", "repository": "sindresorhus/github-markdown-css", From f03290ff30902fe28a8e74710edb477980c5522b Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Mon, 11 Dec 2023 15:11:26 +0100 Subject: [PATCH 05/19] Regenerate GitHub CSS --- .github/funding.yml | 4 -- github-markdown-dark.css | 88 +++++++++++++----------- github-markdown-light.css | 78 +++++++++++---------- github-markdown.css | 140 +++++++++++++++----------------------- package.json | 3 +- 5 files changed, 147 insertions(+), 166 deletions(-) delete mode 100644 .github/funding.yml diff --git a/.github/funding.yml b/.github/funding.yml deleted file mode 100644 index bb3241e..0000000 --- a/.github/funding.yml +++ /dev/null @@ -1,4 +0,0 @@ -github: sindresorhus -open_collective: sindresorhus -tidelift: npm/github-markdown-css -custom: https://sindresorhus.com/donate diff --git a/github-markdown-dark.css b/github-markdown-dark.css index 3b09f5f..cc339ff 100644 --- a/github-markdown-dark.css +++ b/github-markdown-dark.css @@ -146,6 +146,7 @@ .markdown-body [type=reset], .markdown-body [type=submit] { -webkit-appearance: button; + appearance: button; } .markdown-body [type=checkbox], @@ -162,6 +163,7 @@ .markdown-body [type=search]::-webkit-search-cancel-button, .markdown-body [type=search]::-webkit-search-decoration { -webkit-appearance: none; + appearance: none; } .markdown-body ::-webkit-input-placeholder { @@ -171,6 +173,7 @@ .markdown-body ::-webkit-file-upload-button { -webkit-appearance: button; + appearance: button; font: inherit; } @@ -301,7 +304,7 @@ .markdown-body h6 { font-weight: 600; font-size: .85em; - color: #7d8590; + color: #848d97; } .markdown-body p { @@ -312,7 +315,7 @@ .markdown-body blockquote { margin: 0; padding: 0 1em; - color: #7d8590; + color: #848d97; border-left: .25em solid #30363d; } @@ -368,32 +371,8 @@ appearance: none; } -.markdown-body .color-fg-accent { - color: #2f81f7 !important; -} - -.markdown-body .color-fg-attention { - color: #d29922 !important; -} - -.markdown-body .color-fg-done { - color: #a371f7 !important; -} - -.markdown-body .flex-items-center { - align-items: center !important; -} - -.markdown-body .mb-1 { - margin-bottom: var(--base-size-4, 4px) !important; -} - -.markdown-body .text-semibold { - font-weight: var(--base-text-weight-medium, 500) !important; -} - -.markdown-body .d-inline-flex { - display: inline-flex !important; +.markdown-body .mr-2 { + margin-right: 8px !important; } .markdown-body::before { @@ -822,7 +801,7 @@ .markdown-body .footnotes { font-size: 12px; - color: #7d8590; + color: #848d97; border-top: 1px solid #30363d; } @@ -1038,20 +1017,12 @@ clip: auto; } -.markdown-body .QueryBuilder .qb-entity { - color: #d2a8ff; -} - -.markdown-body .QueryBuilder .qb-constant { - color: #79c0ff; -} - .markdown-body ::-webkit-calendar-picker-indicator { filter: invert(50%); } .markdown-body .markdown-alert { - padding: 0 1em; + padding: 8px 16px; margin-bottom: 16px; color: inherit; border-left: .25em solid #30363d; @@ -1065,14 +1036,49 @@ margin-bottom: 0; } +.markdown-body .markdown-alert .markdown-alert-title { + display: flex; + font-weight: 500; + align-items: center; + line-height: 1; +} + .markdown-body .markdown-alert.markdown-alert-note { - border-left-color: #2f81f7; + border-left-color: #1f6feb; +} + +.markdown-body .markdown-alert.markdown-alert-note .markdown-alert-title { + color: #2f81f7; } .markdown-body .markdown-alert.markdown-alert-important { - border-left-color: #a371f7; + border-left-color: #8957e5; +} + +.markdown-body .markdown-alert.markdown-alert-important .markdown-alert-title { + color: #a371f7; } .markdown-body .markdown-alert.markdown-alert-warning { - border-left-color: #d29922; + border-left-color: #9e6a03; +} + +.markdown-body .markdown-alert.markdown-alert-warning .markdown-alert-title { + color: #d29922; +} + +.markdown-body .markdown-alert.markdown-alert-tip { + border-left-color: #238636; +} + +.markdown-body .markdown-alert.markdown-alert-tip .markdown-alert-title { + color: #3fb950; +} + +.markdown-body .markdown-alert.markdown-alert-caution { + border-left-color: #da3633; +} + +.markdown-body .markdown-alert.markdown-alert-caution .markdown-alert-title { + color: #f85149; } diff --git a/github-markdown-light.css b/github-markdown-light.css index 8cf3a7d..b465116 100644 --- a/github-markdown-light.css +++ b/github-markdown-light.css @@ -145,6 +145,7 @@ .markdown-body [type=reset], .markdown-body [type=submit] { -webkit-appearance: button; + appearance: button; } .markdown-body [type=checkbox], @@ -161,6 +162,7 @@ .markdown-body [type=search]::-webkit-search-cancel-button, .markdown-body [type=search]::-webkit-search-decoration { -webkit-appearance: none; + appearance: none; } .markdown-body ::-webkit-input-placeholder { @@ -170,6 +172,7 @@ .markdown-body ::-webkit-file-upload-button { -webkit-appearance: button; + appearance: button; font: inherit; } @@ -367,32 +370,8 @@ appearance: none; } -.markdown-body .color-fg-accent { - color: #0969da !important; -} - -.markdown-body .color-fg-attention { - color: #9a6700 !important; -} - -.markdown-body .color-fg-done { - color: #8250df !important; -} - -.markdown-body .flex-items-center { - align-items: center !important; -} - -.markdown-body .mb-1 { - margin-bottom: var(--base-size-4, 4px) !important; -} - -.markdown-body .text-semibold { - font-weight: var(--base-text-weight-medium, 500) !important; -} - -.markdown-body .d-inline-flex { - display: inline-flex !important; +.markdown-body .mr-2 { + margin-right: 8px !important; } .markdown-body::before { @@ -860,7 +839,7 @@ } .markdown-body .pl-c { - color: #6e7781; + color: #57606a; } .markdown-body .pl-c1, @@ -1037,20 +1016,12 @@ clip: auto; } -.markdown-body .QueryBuilder .qb-entity { - color: #6639ba; -} - -.markdown-body .QueryBuilder .qb-constant { - color: #0550ae; -} - .markdown-body ::-webkit-calendar-picker-indicator { filter: invert(50%); } .markdown-body .markdown-alert { - padding: 0 1em; + padding: 8px 16px; margin-bottom: 16px; color: inherit; border-left: .25em solid #d0d7de; @@ -1064,14 +1035,49 @@ margin-bottom: 0; } +.markdown-body .markdown-alert .markdown-alert-title { + display: flex; + font-weight: 500; + align-items: center; + line-height: 1; +} + .markdown-body .markdown-alert.markdown-alert-note { border-left-color: #0969da; } +.markdown-body .markdown-alert.markdown-alert-note .markdown-alert-title { + color: #0969da; +} + .markdown-body .markdown-alert.markdown-alert-important { border-left-color: #8250df; } +.markdown-body .markdown-alert.markdown-alert-important .markdown-alert-title { + color: #8250df; +} + .markdown-body .markdown-alert.markdown-alert-warning { border-left-color: #9a6700; } + +.markdown-body .markdown-alert.markdown-alert-warning .markdown-alert-title { + color: #9a6700; +} + +.markdown-body .markdown-alert.markdown-alert-tip { + border-left-color: #1f883d; +} + +.markdown-body .markdown-alert.markdown-alert-tip .markdown-alert-title { + color: #1a7f37; +} + +.markdown-body .markdown-alert.markdown-alert-caution { + border-left-color: #cf222e; +} + +.markdown-body .markdown-alert.markdown-alert-caution .markdown-alert-title { + color: #d1242f; +} diff --git a/github-markdown.css b/github-markdown.css index b9fdf29..d32a314 100644 --- a/github-markdown.css +++ b/github-markdown.css @@ -34,7 +34,7 @@ --color-prettylights-syntax-sublimelinter-gutter-mark: #484f58; --color-prettylights-syntax-constant-other-reference-link: #a5d6ff; --color-fg-default: #e6edf3; - --color-fg-muted: #7d8590; + --color-fg-muted: #848d97; --color-fg-subtle: #6e7681; --color-canvas-default: #0d1117; --color-canvas-subtle: #161b22; @@ -43,10 +43,15 @@ --color-neutral-muted: rgba(110,118,129,0.4); --color-accent-fg: #2f81f7; --color-accent-emphasis: #1f6feb; + --color-success-fg: #3fb950; + --color-success-emphasis: #238636; --color-attention-fg: #d29922; + --color-attention-emphasis: #9e6a03; --color-attention-subtle: rgba(187,128,9,0.15); --color-danger-fg: #f85149; + --color-danger-emphasis: #da3633; --color-done-fg: #a371f7; + --color-done-emphasis: #8957e5; } } @@ -55,51 +60,7 @@ [data-theme="light"] { /*light*/ color-scheme: light; - --color-prettylights-syntax-comment: #6e7781; - --color-prettylights-syntax-constant: #0550ae; - --color-prettylights-syntax-entity: #6639ba; - --color-prettylights-syntax-storage-modifier-import: #24292f; - --color-prettylights-syntax-entity-tag: #116329; - --color-prettylights-syntax-keyword: #cf222e; - --color-prettylights-syntax-string: #0a3069; - --color-prettylights-syntax-variable: #953800; - --color-prettylights-syntax-brackethighlighter-unmatched: #82071e; - --color-prettylights-syntax-invalid-illegal-text: #f6f8fa; - --color-prettylights-syntax-invalid-illegal-bg: #82071e; - --color-prettylights-syntax-carriage-return-text: #f6f8fa; - --color-prettylights-syntax-carriage-return-bg: #cf222e; - --color-prettylights-syntax-string-regexp: #116329; - --color-prettylights-syntax-markup-list: #3b2300; - --color-prettylights-syntax-markup-heading: #0550ae; - --color-prettylights-syntax-markup-italic: #24292f; - --color-prettylights-syntax-markup-bold: #24292f; - --color-prettylights-syntax-markup-deleted-text: #82071e; - --color-prettylights-syntax-markup-deleted-bg: #ffebe9; - --color-prettylights-syntax-markup-inserted-text: #116329; - --color-prettylights-syntax-markup-inserted-bg: #dafbe1; - --color-prettylights-syntax-markup-changed-text: #953800; - --color-prettylights-syntax-markup-changed-bg: #ffd8b5; - --color-prettylights-syntax-markup-ignored-text: #eaeef2; - --color-prettylights-syntax-markup-ignored-bg: #0550ae; - --color-prettylights-syntax-meta-diff-range: #8250df; - --color-prettylights-syntax-brackethighlighter-angle: #57606a; - --color-prettylights-syntax-sublimelinter-gutter-mark: #8c959f; - --color-prettylights-syntax-constant-other-reference-link: #0a3069; - --color-fg-default: #1F2328; - --color-fg-muted: #656d76; - --color-fg-subtle: #6e7781; - --color-canvas-default: #ffffff; - --color-canvas-subtle: #f6f8fa; - --color-border-default: #d0d7de; - --color-border-muted: hsla(210,18%,87%,1); - --color-neutral-muted: rgba(175,184,193,0.2); - --color-accent-fg: #0969da; - --color-accent-emphasis: #0969da; - --color-attention-fg: #9a6700; - --color-attention-subtle: #fff8c5; - --color-danger-fg: #d1242f; - --color-done-fg: #8250df; - --color-prettylights-syntax-comment: #6e7781; + --color-prettylights-syntax-comment: #57606a; --color-prettylights-syntax-constant: #0550ae; --color-prettylights-syntax-entity: #6639ba; --color-prettylights-syntax-storage-modifier-import: #24292f; @@ -139,10 +100,15 @@ --color-neutral-muted: rgba(175,184,193,0.2); --color-accent-fg: #0969da; --color-accent-emphasis: #0969da; + --color-success-fg: #1a7f37; + --color-success-emphasis: #1f883d; --color-attention-fg: #9a6700; + --color-attention-emphasis: #9a6700; --color-attention-subtle: #fff8c5; --color-danger-fg: #d1242f; + --color-danger-emphasis: #cf222e; --color-done-fg: #8250df; + --color-done-emphasis: #8250df; } } @@ -291,6 +257,7 @@ .markdown-body [type=reset], .markdown-body [type=submit] { -webkit-appearance: button; + appearance: button; } .markdown-body [type=checkbox], @@ -307,6 +274,7 @@ .markdown-body [type=search]::-webkit-search-cancel-button, .markdown-body [type=search]::-webkit-search-decoration { -webkit-appearance: none; + appearance: none; } .markdown-body ::-webkit-input-placeholder { @@ -316,6 +284,7 @@ .markdown-body ::-webkit-file-upload-button { -webkit-appearance: button; + appearance: button; font: inherit; } @@ -513,32 +482,8 @@ appearance: none; } -.markdown-body .color-fg-accent { - color: var(--color-accent-fg) !important; -} - -.markdown-body .color-fg-attention { - color: var(--color-attention-fg) !important; -} - -.markdown-body .color-fg-done { - color: var(--color-done-fg) !important; -} - -.markdown-body .flex-items-center { - align-items: center !important; -} - -.markdown-body .mb-1 { - margin-bottom: var(--base-size-4, 4px) !important; -} - -.markdown-body .text-semibold { - font-weight: var(--base-text-weight-medium, 500) !important; -} - -.markdown-body .d-inline-flex { - display: inline-flex !important; +.markdown-body .mr-2 { + margin-right: var(--base-size-8, 8px) !important; } .markdown-body::before { @@ -1183,20 +1128,12 @@ clip: auto; } -.markdown-body .QueryBuilder .qb-entity { - color: var(--color-prettylights-syntax-entity); -} - -.markdown-body .QueryBuilder .qb-constant { - color: var(--color-prettylights-syntax-constant); -} - .markdown-body ::-webkit-calendar-picker-indicator { filter: invert(50%); } .markdown-body .markdown-alert { - padding: 0 1em; + padding: var(--base-size-8) var(--base-size-16); margin-bottom: 16px; color: inherit; border-left: .25em solid var(--color-border-default); @@ -1210,14 +1147,49 @@ margin-bottom: 0; } +.markdown-body .markdown-alert .markdown-alert-title { + display: flex; + font-weight: var(--base-text-weight-medium, 500); + align-items: center; + line-height: 1; +} + .markdown-body .markdown-alert.markdown-alert-note { - border-left-color: var(--color-accent-fg); + border-left-color: var(--color-accent-emphasis); +} + +.markdown-body .markdown-alert.markdown-alert-note .markdown-alert-title { + color: var(--color-accent-fg); } .markdown-body .markdown-alert.markdown-alert-important { - border-left-color: var(--color-done-fg); + border-left-color: var(--color-done-emphasis); +} + +.markdown-body .markdown-alert.markdown-alert-important .markdown-alert-title { + color: var(--color-done-fg); } .markdown-body .markdown-alert.markdown-alert-warning { - border-left-color: var(--color-attention-fg); + border-left-color: var(--color-attention-emphasis); +} + +.markdown-body .markdown-alert.markdown-alert-warning .markdown-alert-title { + color: var(--color-attention-fg); +} + +.markdown-body .markdown-alert.markdown-alert-tip { + border-left-color: var(--color-success-emphasis); +} + +.markdown-body .markdown-alert.markdown-alert-tip .markdown-alert-title { + color: var(--color-success-fg); +} + +.markdown-body .markdown-alert.markdown-alert-caution { + border-left-color: var(--color-danger-emphasis); +} + +.markdown-body .markdown-alert.markdown-alert-caution .markdown-alert-title { + color: var(--color-danger-fg); } diff --git a/package.json b/package.json index 2e826d7..f5a45e5 100644 --- a/package.json +++ b/package.json @@ -11,6 +11,7 @@ "url": "https://sindresorhus.com" }, "main": "github-markdown.css", + "sideEffects": false, "engines": { "node": ">=10" }, @@ -35,6 +36,6 @@ "stylesheet" ], "devDependencies": { - "generate-github-markdown-css": "^6.1.0" + "generate-github-markdown-css": "^6.2.0" } } From 220cab500ada98c999c57b42a2d444bc1b67eb0f Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Mon, 11 Dec 2023 15:12:33 +0100 Subject: [PATCH 06/19] 5.5.0 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index f5a45e5..7b70d92 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "github-markdown-css", - "version": "5.4.0", + "version": "5.5.0", "description": "The minimal amount of CSS to replicate the GitHub Markdown style", "license": "MIT", "repository": "sindresorhus/github-markdown-css", From 9411b377b5ecc0bddd37471a3f7be07ee3dc69ff Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Sun, 4 Feb 2024 13:15:34 +0700 Subject: [PATCH 07/19] Fix compatibility with Rollup Fixes #111 --- package.json | 1 - 1 file changed, 1 deletion(-) diff --git a/package.json b/package.json index 7b70d92..6bc29b0 100644 --- a/package.json +++ b/package.json @@ -11,7 +11,6 @@ "url": "https://sindresorhus.com" }, "main": "github-markdown.css", - "sideEffects": false, "engines": { "node": ">=10" }, From b3977a0367f753d1c58812c4218f69f013504c51 Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Sun, 4 Feb 2024 13:17:09 +0700 Subject: [PATCH 08/19] 5.5.1 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 6bc29b0..85dee64 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "github-markdown-css", - "version": "5.5.0", + "version": "5.5.1", "description": "The minimal amount of CSS to replicate the GitHub Markdown style", "license": "MIT", "repository": "sindresorhus/github-markdown-css", From 5e1d34a4add8501c31efb8c6eb378bcac9b20ef4 Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Fri, 14 Jun 2024 13:53:12 +0200 Subject: [PATCH 09/19] Regenerate GitHub CSS --- github-markdown-dark.css | 71 +++++++----- github-markdown-light.css | 79 ++++++++----- github-markdown.css | 231 ++++++++++++++++++++++---------------- package.json | 2 +- 4 files changed, 228 insertions(+), 155 deletions(-) diff --git a/github-markdown-dark.css b/github-markdown-dark.css index cc339ff..d1a68e7 100644 --- a/github-markdown-dark.css +++ b/github-markdown-dark.css @@ -11,6 +11,7 @@ font-size: 16px; line-height: 1.5; word-wrap: break-word; + scroll-behavior: auto; } .markdown-body .octicon { @@ -50,7 +51,7 @@ .markdown-body a { background-color: transparent; - color: #2f81f7; + color: #4493f8; text-decoration: none; } @@ -74,11 +75,11 @@ font-weight: 600; padding-bottom: .3em; font-size: 2em; - border-bottom: 1px solid #21262d; + border-bottom: 1px solid #30363db3; } .markdown-body mark { - background-color: rgba(187,128,9,0.15); + background-color: #bb800926; color: #e6edf3; } @@ -125,7 +126,7 @@ box-sizing: content-box; overflow: hidden; background: transparent; - border-bottom: 1px solid #21262d; + border-bottom: 1px solid #30363db3; height: .25em; padding: 0; margin: 24px 0; @@ -182,7 +183,7 @@ } .markdown-body ::placeholder { - color: #6e7681; + color: #8d96a0; opacity: 1; } @@ -216,14 +217,14 @@ } .markdown-body details:not([open])>*:not(summary) { - display: none !important; + display: none; } .markdown-body a:focus, .markdown-body [role=button]:focus, .markdown-body input[type=radio]:focus, .markdown-body input[type=checkbox]:focus { - outline: 2px solid #2f81f7; + outline: 2px solid #1f6feb; outline-offset: -2px; box-shadow: none; } @@ -239,7 +240,7 @@ .markdown-body [role=button]:focus-visible, .markdown-body input[type=radio]:focus-visible, .markdown-body input[type=checkbox]:focus-visible { - outline: 2px solid #2f81f7; + outline: 2px solid #1f6feb; outline-offset: -2px; box-shadow: none; } @@ -256,15 +257,15 @@ .markdown-body kbd { display: inline-block; padding: 3px 5px; - font: 11px ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace; + font: 11px ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace; line-height: 10px; color: #e6edf3; vertical-align: middle; background-color: #161b22; - border: solid 1px rgba(110,118,129,0.4); - border-bottom-color: rgba(110,118,129,0.4); + border: solid 1px #6e768166; + border-bottom-color: #6e768166; border-radius: 6px; - box-shadow: inset 0 -1px 0 rgba(110,118,129,0.4); + box-shadow: inset 0 -1px 0 #6e768166; } .markdown-body h1, @@ -283,7 +284,7 @@ font-weight: 600; padding-bottom: .3em; font-size: 1.5em; - border-bottom: 1px solid #21262d; + border-bottom: 1px solid #30363db3; } .markdown-body h3 { @@ -304,7 +305,7 @@ .markdown-body h6 { font-weight: 600; font-size: .85em; - color: #848d97; + color: #8d96a0; } .markdown-body p { @@ -315,7 +316,7 @@ .markdown-body blockquote { margin: 0; padding: 0 1em; - color: #848d97; + color: #8d96a0; border-left: .25em solid #30363d; } @@ -345,14 +346,14 @@ .markdown-body tt, .markdown-body code, .markdown-body samp { - font-family: ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace; + font-family: ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace; font-size: 12px; } .markdown-body pre { margin-top: 0; margin-bottom: 0; - font-family: ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace; + font-family: ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace; font-size: 12px; word-wrap: normal; } @@ -372,7 +373,7 @@ } .markdown-body .mr-2 { - margin-right: 8px !important; + margin-right: 0.5rem !important; } .markdown-body::before { @@ -582,7 +583,7 @@ .markdown-body table tr { background-color: #0d1117; - border-top: 1px solid #21262d; + border-top: 1px solid #30363db3; } .markdown-body table tr:nth-child(2n) { @@ -701,7 +702,7 @@ margin: 0; font-size: 85%; white-space: break-spaces; - background-color: rgba(110,118,129,0.4); + background-color: #6e768166; border-radius: 6px; } @@ -801,7 +802,7 @@ .markdown-body .footnotes { font-size: 12px; - color: #848d97; + color: #8d96a0; border-top: 1px solid #30363d; } @@ -959,6 +960,20 @@ color: #a5d6ff; } +.markdown-body [role=button]:focus:not(:focus-visible), +.markdown-body [role=tabpanel][tabindex="0"]:focus:not(:focus-visible), +.markdown-body button:focus:not(:focus-visible), +.markdown-body summary:focus:not(:focus-visible), +.markdown-body a:focus:not(:focus-visible) { + outline: none; + box-shadow: none; +} + +.markdown-body [tabindex="0"]:focus:not(:focus-visible), +.markdown-body details-dialog:focus:not(:focus-visible) { + outline: none; +} + .markdown-body g-emoji { display: inline-block; min-width: 1ch; @@ -988,7 +1003,7 @@ } .markdown-body .task-list-item+.task-list-item { - margin-top: 4px; + margin-top: 0.25rem; } .markdown-body .task-list-item .handle { @@ -1022,8 +1037,8 @@ } .markdown-body .markdown-alert { - padding: 8px 16px; - margin-bottom: 16px; + padding: 0.5rem 1rem; + margin-bottom: 1rem; color: inherit; border-left: .25em solid #30363d; } @@ -1048,7 +1063,7 @@ } .markdown-body .markdown-alert.markdown-alert-note .markdown-alert-title { - color: #2f81f7; + color: #4493f8; } .markdown-body .markdown-alert.markdown-alert-important { @@ -1056,7 +1071,7 @@ } .markdown-body .markdown-alert.markdown-alert-important .markdown-alert-title { - color: #a371f7; + color: #ab7df8; } .markdown-body .markdown-alert.markdown-alert-warning { @@ -1082,3 +1097,7 @@ .markdown-body .markdown-alert.markdown-alert-caution .markdown-alert-title { color: #f85149; } + +.markdown-body>*:first-child>.heading-element:first-child { + margin-top: 0 !important; +} diff --git a/github-markdown-light.css b/github-markdown-light.css index b465116..90b27c0 100644 --- a/github-markdown-light.css +++ b/github-markdown-light.css @@ -4,12 +4,13 @@ -ms-text-size-adjust: 100%; -webkit-text-size-adjust: 100%; margin: 0; - color: #1F2328; + color: #1f2328; background-color: #ffffff; font-family: -apple-system,BlinkMacSystemFont,"Segoe UI","Noto Sans",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"; font-size: 16px; line-height: 1.5; word-wrap: break-word; + scroll-behavior: auto; } .markdown-body .octicon { @@ -73,12 +74,12 @@ font-weight: 600; padding-bottom: .3em; font-size: 2em; - border-bottom: 1px solid hsla(210,18%,87%,1); + border-bottom: 1px solid #d0d7deb3; } .markdown-body mark { background-color: #fff8c5; - color: #1F2328; + color: #1f2328; } .markdown-body small { @@ -124,7 +125,7 @@ box-sizing: content-box; overflow: hidden; background: transparent; - border-bottom: 1px solid hsla(210,18%,87%,1); + border-bottom: 1px solid #d0d7deb3; height: .25em; padding: 0; margin: 24px 0; @@ -181,7 +182,7 @@ } .markdown-body ::placeholder { - color: #6e7781; + color: #636c76; opacity: 1; } @@ -215,7 +216,7 @@ } .markdown-body details:not([open])>*:not(summary) { - display: none !important; + display: none; } .markdown-body a:focus, @@ -255,15 +256,15 @@ .markdown-body kbd { display: inline-block; padding: 3px 5px; - font: 11px ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace; + font: 11px ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace; line-height: 10px; - color: #1F2328; + color: #1f2328; vertical-align: middle; background-color: #f6f8fa; - border: solid 1px rgba(175,184,193,0.2); - border-bottom-color: rgba(175,184,193,0.2); + border: solid 1px #afb8c133; + border-bottom-color: #afb8c133; border-radius: 6px; - box-shadow: inset 0 -1px 0 rgba(175,184,193,0.2); + box-shadow: inset 0 -1px 0 #afb8c133; } .markdown-body h1, @@ -282,7 +283,7 @@ font-weight: 600; padding-bottom: .3em; font-size: 1.5em; - border-bottom: 1px solid hsla(210,18%,87%,1); + border-bottom: 1px solid #d0d7deb3; } .markdown-body h3 { @@ -303,7 +304,7 @@ .markdown-body h6 { font-weight: 600; font-size: .85em; - color: #656d76; + color: #636c76; } .markdown-body p { @@ -314,7 +315,7 @@ .markdown-body blockquote { margin: 0; padding: 0 1em; - color: #656d76; + color: #636c76; border-left: .25em solid #d0d7de; } @@ -344,14 +345,14 @@ .markdown-body tt, .markdown-body code, .markdown-body samp { - font-family: ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace; + font-family: ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace; font-size: 12px; } .markdown-body pre { margin-top: 0; margin-bottom: 0; - font-family: ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace; + font-family: ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace; font-size: 12px; word-wrap: normal; } @@ -371,7 +372,7 @@ } .markdown-body .mr-2 { - margin-right: 8px !important; + margin-right: 0.5rem !important; } .markdown-body::before { @@ -439,7 +440,7 @@ .markdown-body h4 .octicon-link, .markdown-body h5 .octicon-link, .markdown-body h6 .octicon-link { - color: #1F2328; + color: #1f2328; vertical-align: middle; visibility: hidden; } @@ -581,7 +582,7 @@ .markdown-body table tr { background-color: #ffffff; - border-top: 1px solid hsla(210,18%,87%,1); + border-top: 1px solid #d0d7deb3; } .markdown-body table tr:nth-child(2n) { @@ -630,7 +631,7 @@ display: block; padding: 5px 0 0; clear: both; - color: #1F2328; + color: #1f2328; } .markdown-body span.align-center { @@ -700,7 +701,7 @@ margin: 0; font-size: 85%; white-space: break-spaces; - background-color: rgba(175,184,193,0.2); + background-color: #afb8c133; border-radius: 6px; } @@ -745,7 +746,7 @@ overflow: auto; font-size: 85%; line-height: 1.45; - color: #1F2328; + color: #1f2328; background-color: #f6f8fa; border-radius: 6px; } @@ -800,7 +801,7 @@ .markdown-body .footnotes { font-size: 12px; - color: #656d76; + color: #636c76; border-top: 1px solid #d0d7de; } @@ -831,7 +832,7 @@ } .markdown-body .footnotes li:target { - color: #1F2328; + color: #1f2328; } .markdown-body .footnotes .data-footnote-backref g-emoji { @@ -858,7 +859,7 @@ } .markdown-body .pl-ent { - color: #116329; + color: #0550ae; } .markdown-body .pl-k { @@ -958,6 +959,20 @@ color: #0a3069; } +.markdown-body [role=button]:focus:not(:focus-visible), +.markdown-body [role=tabpanel][tabindex="0"]:focus:not(:focus-visible), +.markdown-body button:focus:not(:focus-visible), +.markdown-body summary:focus:not(:focus-visible), +.markdown-body a:focus:not(:focus-visible) { + outline: none; + box-shadow: none; +} + +.markdown-body [tabindex="0"]:focus:not(:focus-visible), +.markdown-body details-dialog:focus:not(:focus-visible) { + outline: none; +} + .markdown-body g-emoji { display: inline-block; min-width: 1ch; @@ -987,7 +1002,7 @@ } .markdown-body .task-list-item+.task-list-item { - margin-top: 4px; + margin-top: 0.25rem; } .markdown-body .task-list-item .handle { @@ -1021,8 +1036,8 @@ } .markdown-body .markdown-alert { - padding: 8px 16px; - margin-bottom: 16px; + padding: 0.5rem 1rem; + margin-bottom: 1rem; color: inherit; border-left: .25em solid #d0d7de; } @@ -1059,7 +1074,7 @@ } .markdown-body .markdown-alert.markdown-alert-warning { - border-left-color: #9a6700; + border-left-color: #bf8700; } .markdown-body .markdown-alert.markdown-alert-warning .markdown-alert-title { @@ -1067,7 +1082,7 @@ } .markdown-body .markdown-alert.markdown-alert-tip { - border-left-color: #1f883d; + border-left-color: #1a7f37; } .markdown-body .markdown-alert.markdown-alert-tip .markdown-alert-title { @@ -1081,3 +1096,7 @@ .markdown-body .markdown-alert.markdown-alert-caution .markdown-alert-title { color: #d1242f; } + +.markdown-body>*:first-child>.heading-element:first-child { + margin-top: 0 !important; +} diff --git a/github-markdown.css b/github-markdown.css index d32a314..59bc0c4 100644 --- a/github-markdown.css +++ b/github-markdown.css @@ -3,8 +3,36 @@ [data-theme="dark"] { /*dark*/ color-scheme: dark; + --fontStack-monospace: ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace; + --base-text-weight-semibold: 600; + --base-text-weight-medium: 500; + --base-text-weight-normal: 400; + --base-size-16: 1rem; + --base-size-8: 0.5rem; + --base-size-4: 0.25rem; + --focus-outlineColor: #1f6feb; + --fgColor-default: #e6edf3; + --fgColor-muted: #8d96a0; + --fgColor-accent: #4493f8; + --fgColor-success: #3fb950; + --fgColor-attention: #d29922; + --fgColor-danger: #f85149; + --fgColor-done: #ab7df8; + --bgColor-default: #0d1117; + --bgColor-muted: #161b22; + --bgColor-neutral-muted: #6e768166; + --bgColor-attention-muted: #bb800926; + --borderColor-default: #30363d; + --borderColor-muted: #30363db3; + --borderColor-neutral-muted: #6e768166; + --borderColor-accent-emphasis: #1f6feb; + --borderColor-success-emphasis: #238636; + --borderColor-attention-emphasis: #9e6a03; + --borderColor-danger-emphasis: #da3633; + --borderColor-done-emphasis: #8957e5; --color-prettylights-syntax-comment: #8b949e; --color-prettylights-syntax-constant: #79c0ff; + --color-prettylights-syntax-constant-other-reference-link: #a5d6ff; --color-prettylights-syntax-entity: #d2a8ff; --color-prettylights-syntax-storage-modifier-import: #c9d1d9; --color-prettylights-syntax-entity-tag: #7ee787; @@ -12,6 +40,7 @@ --color-prettylights-syntax-string: #a5d6ff; --color-prettylights-syntax-variable: #ffa657; --color-prettylights-syntax-brackethighlighter-unmatched: #f85149; + --color-prettylights-syntax-brackethighlighter-angle: #8b949e; --color-prettylights-syntax-invalid-illegal-text: #f0f6fc; --color-prettylights-syntax-invalid-illegal-bg: #8e1519; --color-prettylights-syntax-carriage-return-text: #f0f6fc; @@ -30,28 +59,7 @@ --color-prettylights-syntax-markup-ignored-text: #c9d1d9; --color-prettylights-syntax-markup-ignored-bg: #1158c7; --color-prettylights-syntax-meta-diff-range: #d2a8ff; - --color-prettylights-syntax-brackethighlighter-angle: #8b949e; --color-prettylights-syntax-sublimelinter-gutter-mark: #484f58; - --color-prettylights-syntax-constant-other-reference-link: #a5d6ff; - --color-fg-default: #e6edf3; - --color-fg-muted: #848d97; - --color-fg-subtle: #6e7681; - --color-canvas-default: #0d1117; - --color-canvas-subtle: #161b22; - --color-border-default: #30363d; - --color-border-muted: #21262d; - --color-neutral-muted: rgba(110,118,129,0.4); - --color-accent-fg: #2f81f7; - --color-accent-emphasis: #1f6feb; - --color-success-fg: #3fb950; - --color-success-emphasis: #238636; - --color-attention-fg: #d29922; - --color-attention-emphasis: #9e6a03; - --color-attention-subtle: rgba(187,128,9,0.15); - --color-danger-fg: #f85149; - --color-danger-emphasis: #da3633; - --color-done-fg: #a371f7; - --color-done-emphasis: #8957e5; } } @@ -60,15 +68,44 @@ [data-theme="light"] { /*light*/ color-scheme: light; + --fontStack-monospace: ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace; + --base-text-weight-semibold: 600; + --base-text-weight-medium: 500; + --base-text-weight-normal: 400; + --base-size-16: 1rem; + --base-size-8: 0.5rem; + --base-size-4: 0.25rem; + --focus-outlineColor: #0969da; + --fgColor-default: #1f2328; + --fgColor-muted: #636c76; + --fgColor-accent: #0969da; + --fgColor-success: #1a7f37; + --fgColor-attention: #9a6700; + --fgColor-danger: #d1242f; + --fgColor-done: #8250df; + --bgColor-default: #ffffff; + --bgColor-muted: #f6f8fa; + --bgColor-neutral-muted: #afb8c133; + --bgColor-attention-muted: #fff8c5; + --borderColor-default: #d0d7de; + --borderColor-muted: #d0d7deb3; + --borderColor-neutral-muted: #afb8c133; + --borderColor-accent-emphasis: #0969da; + --borderColor-success-emphasis: #1a7f37; + --borderColor-attention-emphasis: #bf8700; + --borderColor-danger-emphasis: #cf222e; + --borderColor-done-emphasis: #8250df; --color-prettylights-syntax-comment: #57606a; --color-prettylights-syntax-constant: #0550ae; + --color-prettylights-syntax-constant-other-reference-link: #0a3069; --color-prettylights-syntax-entity: #6639ba; --color-prettylights-syntax-storage-modifier-import: #24292f; - --color-prettylights-syntax-entity-tag: #116329; + --color-prettylights-syntax-entity-tag: #0550ae; --color-prettylights-syntax-keyword: #cf222e; --color-prettylights-syntax-string: #0a3069; --color-prettylights-syntax-variable: #953800; --color-prettylights-syntax-brackethighlighter-unmatched: #82071e; + --color-prettylights-syntax-brackethighlighter-angle: #57606a; --color-prettylights-syntax-invalid-illegal-text: #f6f8fa; --color-prettylights-syntax-invalid-illegal-bg: #82071e; --color-prettylights-syntax-carriage-return-text: #f6f8fa; @@ -87,28 +124,7 @@ --color-prettylights-syntax-markup-ignored-text: #eaeef2; --color-prettylights-syntax-markup-ignored-bg: #0550ae; --color-prettylights-syntax-meta-diff-range: #8250df; - --color-prettylights-syntax-brackethighlighter-angle: #57606a; --color-prettylights-syntax-sublimelinter-gutter-mark: #8c959f; - --color-prettylights-syntax-constant-other-reference-link: #0a3069; - --color-fg-default: #1F2328; - --color-fg-muted: #656d76; - --color-fg-subtle: #6e7781; - --color-canvas-default: #ffffff; - --color-canvas-subtle: #f6f8fa; - --color-border-default: #d0d7de; - --color-border-muted: hsla(210,18%,87%,1); - --color-neutral-muted: rgba(175,184,193,0.2); - --color-accent-fg: #0969da; - --color-accent-emphasis: #0969da; - --color-success-fg: #1a7f37; - --color-success-emphasis: #1f883d; - --color-attention-fg: #9a6700; - --color-attention-emphasis: #9a6700; - --color-attention-subtle: #fff8c5; - --color-danger-fg: #d1242f; - --color-danger-emphasis: #cf222e; - --color-done-fg: #8250df; - --color-done-emphasis: #8250df; } } @@ -116,12 +132,13 @@ -ms-text-size-adjust: 100%; -webkit-text-size-adjust: 100%; margin: 0; - color: var(--color-fg-default); - background-color: var(--color-canvas-default); + color: var(--fgColor-default); + background-color: var(--bgColor-default); font-family: -apple-system,BlinkMacSystemFont,"Segoe UI","Noto Sans",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"; font-size: 16px; line-height: 1.5; word-wrap: break-word; + scroll-behavior: auto; } .markdown-body .octicon { @@ -161,7 +178,7 @@ .markdown-body a { background-color: transparent; - color: var(--color-accent-fg); + color: var(--fgColor-accent); text-decoration: none; } @@ -185,12 +202,12 @@ font-weight: var(--base-text-weight-semibold, 600); padding-bottom: .3em; font-size: 2em; - border-bottom: 1px solid var(--color-border-muted); + border-bottom: 1px solid var(--borderColor-muted); } .markdown-body mark { - background-color: var(--color-attention-subtle); - color: var(--color-fg-default); + background-color: var(--bgColor-attention-muted); + color: var(--fgColor-default); } .markdown-body small { @@ -217,7 +234,7 @@ border-style: none; max-width: 100%; box-sizing: content-box; - background-color: var(--color-canvas-default); + background-color: var(--bgColor-default); } .markdown-body code, @@ -236,11 +253,11 @@ box-sizing: content-box; overflow: hidden; background: transparent; - border-bottom: 1px solid var(--color-border-muted); + border-bottom: 1px solid var(--borderColor-muted); height: .25em; padding: 0; margin: 24px 0; - background-color: var(--color-border-default); + background-color: var(--borderColor-default); border: 0; } @@ -293,7 +310,7 @@ } .markdown-body ::placeholder { - color: var(--color-fg-subtle); + color: var(--fgColor-muted); opacity: 1; } @@ -327,14 +344,14 @@ } .markdown-body details:not([open])>*:not(summary) { - display: none !important; + display: none; } .markdown-body a:focus, .markdown-body [role=button]:focus, .markdown-body input[type=radio]:focus, .markdown-body input[type=checkbox]:focus { - outline: 2px solid var(--color-accent-fg); + outline: 2px solid var(--focus-outlineColor); outline-offset: -2px; box-shadow: none; } @@ -350,7 +367,7 @@ .markdown-body [role=button]:focus-visible, .markdown-body input[type=radio]:focus-visible, .markdown-body input[type=checkbox]:focus-visible { - outline: 2px solid var(--color-accent-fg); + outline: 2px solid var(--focus-outlineColor); outline-offset: -2px; box-shadow: none; } @@ -367,15 +384,15 @@ .markdown-body kbd { display: inline-block; padding: 3px 5px; - font: 11px ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace; + font: 11px var(--fontStack-monospace, ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace); line-height: 10px; - color: var(--color-fg-default); + color: var(--fgColor-default); vertical-align: middle; - background-color: var(--color-canvas-subtle); - border: solid 1px var(--color-neutral-muted); - border-bottom-color: var(--color-neutral-muted); + background-color: var(--bgColor-muted); + border: solid 1px var(--borderColor-neutral-muted); + border-bottom-color: var(--borderColor-neutral-muted); border-radius: 6px; - box-shadow: inset 0 -1px 0 var(--color-neutral-muted); + box-shadow: inset 0 -1px 0 var(--borderColor-neutral-muted); } .markdown-body h1, @@ -394,7 +411,7 @@ font-weight: var(--base-text-weight-semibold, 600); padding-bottom: .3em; font-size: 1.5em; - border-bottom: 1px solid var(--color-border-muted); + border-bottom: 1px solid var(--borderColor-muted); } .markdown-body h3 { @@ -415,7 +432,7 @@ .markdown-body h6 { font-weight: var(--base-text-weight-semibold, 600); font-size: .85em; - color: var(--color-fg-muted); + color: var(--fgColor-muted); } .markdown-body p { @@ -426,8 +443,8 @@ .markdown-body blockquote { margin: 0; padding: 0 1em; - color: var(--color-fg-muted); - border-left: .25em solid var(--color-border-default); + color: var(--fgColor-muted); + border-left: .25em solid var(--borderColor-default); } .markdown-body ul, @@ -456,14 +473,14 @@ .markdown-body tt, .markdown-body code, .markdown-body samp { - font-family: ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace; + font-family: var(--fontStack-monospace, ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace); font-size: 12px; } .markdown-body pre { margin-top: 0; margin-bottom: 0; - font-family: ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace; + font-family: var(--fontStack-monospace, ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace); font-size: 12px; word-wrap: normal; } @@ -511,7 +528,7 @@ } .markdown-body .absent { - color: var(--color-danger-fg); + color: var(--fgColor-danger); } .markdown-body .anchor { @@ -551,7 +568,7 @@ .markdown-body h4 .octicon-link, .markdown-body h5 .octicon-link, .markdown-body h6 .octicon-link { - color: var(--color-fg-default); + color: var(--fgColor-default); vertical-align: middle; visibility: hidden; } @@ -684,7 +701,7 @@ .markdown-body table th, .markdown-body table td { padding: 6px 13px; - border: 1px solid var(--color-border-default); + border: 1px solid var(--borderColor-default); } .markdown-body table td>:last-child { @@ -692,12 +709,12 @@ } .markdown-body table tr { - background-color: var(--color-canvas-default); - border-top: 1px solid var(--color-border-muted); + background-color: var(--bgColor-default); + border-top: 1px solid var(--borderColor-muted); } .markdown-body table tr:nth-child(2n) { - background-color: var(--color-canvas-subtle); + background-color: var(--bgColor-muted); } .markdown-body table img { @@ -730,7 +747,7 @@ padding: 7px; margin: 13px 0 0; overflow: hidden; - border: 1px solid var(--color-border-default); + border: 1px solid var(--borderColor-default); } .markdown-body span.frame span img { @@ -742,7 +759,7 @@ display: block; padding: 5px 0 0; clear: both; - color: var(--color-fg-default); + color: var(--fgColor-default); } .markdown-body span.align-center { @@ -812,7 +829,7 @@ margin: 0; font-size: 85%; white-space: break-spaces; - background-color: var(--color-neutral-muted); + background-color: var(--bgColor-neutral-muted); border-radius: 6px; } @@ -857,8 +874,8 @@ overflow: auto; font-size: 85%; line-height: 1.45; - color: var(--color-fg-default); - background-color: var(--color-canvas-subtle); + color: var(--fgColor-default); + background-color: var(--bgColor-muted); border-radius: 6px; } @@ -888,7 +905,7 @@ .markdown-body .csv-data .blob-num { padding: 10px 8px 9px; text-align: right; - background: var(--color-canvas-default); + background: var(--bgColor-default); border: 0; } @@ -898,7 +915,7 @@ .markdown-body .csv-data th { font-weight: var(--base-text-weight-semibold, 600); - background: var(--color-canvas-subtle); + background: var(--bgColor-muted); border-top: 0; } @@ -912,8 +929,8 @@ .markdown-body .footnotes { font-size: 12px; - color: var(--color-fg-muted); - border-top: 1px solid var(--color-border-default); + color: var(--fgColor-muted); + border-top: 1px solid var(--borderColor-default); } .markdown-body .footnotes ol { @@ -938,12 +955,12 @@ left: -24px; pointer-events: none; content: ""; - border: 2px solid var(--color-accent-emphasis); + border: 2px solid var(--borderColor-accent-emphasis); border-radius: 6px; } .markdown-body .footnotes li:target { - color: var(--color-fg-default); + color: var(--fgColor-default); } .markdown-body .footnotes .data-footnote-backref g-emoji { @@ -1070,6 +1087,20 @@ color: var(--color-prettylights-syntax-constant-other-reference-link); } +.markdown-body [role=button]:focus:not(:focus-visible), +.markdown-body [role=tabpanel][tabindex="0"]:focus:not(:focus-visible), +.markdown-body button:focus:not(:focus-visible), +.markdown-body summary:focus:not(:focus-visible), +.markdown-body a:focus:not(:focus-visible) { + outline: none; + box-shadow: none; +} + +.markdown-body [tabindex="0"]:focus:not(:focus-visible), +.markdown-body details-dialog:focus:not(:focus-visible) { + outline: none; +} + .markdown-body g-emoji { display: inline-block; min-width: 1ch; @@ -1099,7 +1130,7 @@ } .markdown-body .task-list-item+.task-list-item { - margin-top: 4px; + margin-top: var(--base-size-4); } .markdown-body .task-list-item .handle { @@ -1134,9 +1165,9 @@ .markdown-body .markdown-alert { padding: var(--base-size-8) var(--base-size-16); - margin-bottom: 16px; + margin-bottom: var(--base-size-16); color: inherit; - border-left: .25em solid var(--color-border-default); + border-left: .25em solid var(--borderColor-default); } .markdown-body .markdown-alert>:first-child { @@ -1155,41 +1186,45 @@ } .markdown-body .markdown-alert.markdown-alert-note { - border-left-color: var(--color-accent-emphasis); + border-left-color: var(--borderColor-accent-emphasis); } .markdown-body .markdown-alert.markdown-alert-note .markdown-alert-title { - color: var(--color-accent-fg); + color: var(--fgColor-accent); } .markdown-body .markdown-alert.markdown-alert-important { - border-left-color: var(--color-done-emphasis); + border-left-color: var(--borderColor-done-emphasis); } .markdown-body .markdown-alert.markdown-alert-important .markdown-alert-title { - color: var(--color-done-fg); + color: var(--fgColor-done); } .markdown-body .markdown-alert.markdown-alert-warning { - border-left-color: var(--color-attention-emphasis); + border-left-color: var(--borderColor-attention-emphasis); } .markdown-body .markdown-alert.markdown-alert-warning .markdown-alert-title { - color: var(--color-attention-fg); + color: var(--fgColor-attention); } .markdown-body .markdown-alert.markdown-alert-tip { - border-left-color: var(--color-success-emphasis); + border-left-color: var(--borderColor-success-emphasis); } .markdown-body .markdown-alert.markdown-alert-tip .markdown-alert-title { - color: var(--color-success-fg); + color: var(--fgColor-success); } .markdown-body .markdown-alert.markdown-alert-caution { - border-left-color: var(--color-danger-emphasis); + border-left-color: var(--borderColor-danger-emphasis); } .markdown-body .markdown-alert.markdown-alert-caution .markdown-alert-title { - color: var(--color-danger-fg); + color: var(--fgColor-danger); +} + +.markdown-body>*:first-child>.heading-element:first-child { + margin-top: 0 !important; } diff --git a/package.json b/package.json index 85dee64..c02d3cc 100644 --- a/package.json +++ b/package.json @@ -35,6 +35,6 @@ "stylesheet" ], "devDependencies": { - "generate-github-markdown-css": "^6.2.0" + "generate-github-markdown-css": "^6.2.2" } } From e9d22b2ce09ff67e3a7bfeaad63f4efc25bece25 Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Fri, 14 Jun 2024 13:53:38 +0200 Subject: [PATCH 10/19] 5.6.0 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index c02d3cc..9f81865 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "github-markdown-css", - "version": "5.5.1", + "version": "5.6.0", "description": "The minimal amount of CSS to replicate the GitHub Markdown style", "license": "MIT", "repository": "sindresorhus/github-markdown-css", From eb15d9072e9ccbac859da05c4ef5311b60b39c85 Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Tue, 18 Jun 2024 00:51:04 +0200 Subject: [PATCH 11/19] Regenerate GitHub CSS --- github-markdown.css | 24 ++++++++++-------------- package.json | 2 +- 2 files changed, 11 insertions(+), 15 deletions(-) diff --git a/github-markdown.css b/github-markdown.css index 59bc0c4..ebfca67 100644 --- a/github-markdown.css +++ b/github-markdown.css @@ -1,15 +1,18 @@ +.markdown-body { + --base-size-4: 0.25rem; + --base-size-8: 0.5rem; + --base-size-16: 1rem; + --base-text-weight-normal: 400; + --base-text-weight-medium: 500; + --base-text-weight-semibold: 600; + --fontStack-monospace: ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace; +} + @media (prefers-color-scheme: dark) { .markdown-body, [data-theme="dark"] { /*dark*/ color-scheme: dark; - --fontStack-monospace: ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace; - --base-text-weight-semibold: 600; - --base-text-weight-medium: 500; - --base-text-weight-normal: 400; - --base-size-16: 1rem; - --base-size-8: 0.5rem; - --base-size-4: 0.25rem; --focus-outlineColor: #1f6feb; --fgColor-default: #e6edf3; --fgColor-muted: #8d96a0; @@ -68,13 +71,6 @@ [data-theme="light"] { /*light*/ color-scheme: light; - --fontStack-monospace: ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace; - --base-text-weight-semibold: 600; - --base-text-weight-medium: 500; - --base-text-weight-normal: 400; - --base-size-16: 1rem; - --base-size-8: 0.5rem; - --base-size-4: 0.25rem; --focus-outlineColor: #0969da; --fgColor-default: #1f2328; --fgColor-muted: #636c76; diff --git a/package.json b/package.json index 9f81865..21c3614 100644 --- a/package.json +++ b/package.json @@ -35,6 +35,6 @@ "stylesheet" ], "devDependencies": { - "generate-github-markdown-css": "^6.2.2" + "generate-github-markdown-css": "^6.3.0" } } From 17cbdb0b87afa3dc75aa2e8d76f2b0880984c6c8 Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Tue, 18 Jun 2024 01:31:45 +0200 Subject: [PATCH 12/19] 5.6.1 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 21c3614..b7bb0ba 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "github-markdown-css", - "version": "5.6.0", + "version": "5.6.1", "description": "The minimal amount of CSS to replicate the GitHub Markdown style", "license": "MIT", "repository": "sindresorhus/github-markdown-css", From 382e6d0f94c1b8e67ac4946eb283c98d89a21b74 Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Thu, 26 Sep 2024 11:16:41 +0700 Subject: [PATCH 13/19] Regenerate GitHub CSS --- github-markdown-dark.css | 131 ++++++++++++++++++-------------------- github-markdown-light.css | 112 ++++++++++++++++---------------- github-markdown.css | 125 +++++++++++++++++------------------- package.json | 2 +- 4 files changed, 178 insertions(+), 192 deletions(-) diff --git a/github-markdown-dark.css b/github-markdown-dark.css index d1a68e7..df8f2c1 100644 --- a/github-markdown-dark.css +++ b/github-markdown-dark.css @@ -1,17 +1,16 @@ -/*dark*/ - +/* dark */ .markdown-body { color-scheme: dark; -ms-text-size-adjust: 100%; -webkit-text-size-adjust: 100%; margin: 0; - color: #e6edf3; + color: #f0f6fc; background-color: #0d1117; font-family: -apple-system,BlinkMacSystemFont,"Segoe UI","Noto Sans",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"; font-size: 16px; line-height: 1.5; word-wrap: break-word; - scroll-behavior: auto; + scroll-behavior: auto !important; } .markdown-body .octicon { @@ -75,12 +74,12 @@ font-weight: 600; padding-bottom: .3em; font-size: 2em; - border-bottom: 1px solid #30363db3; + border-bottom: 1px solid #3d444db3; } .markdown-body mark { background-color: #bb800926; - color: #e6edf3; + color: #f0f6fc; } .markdown-body small { @@ -107,7 +106,6 @@ border-style: none; max-width: 100%; box-sizing: content-box; - background-color: #0d1117; } .markdown-body code, @@ -119,18 +117,18 @@ } .markdown-body figure { - margin: 1em 40px; + margin: 1em 2.5rem; } .markdown-body hr { box-sizing: content-box; overflow: hidden; background: transparent; - border-bottom: 1px solid #30363db3; + border-bottom: 1px solid #3d444db3; height: .25em; padding: 0; - margin: 24px 0; - background-color: #30363d; + margin: 1.5rem 0; + background-color: #3d444d; border: 0; } @@ -183,7 +181,7 @@ } .markdown-body ::placeholder { - color: #8d96a0; + color: #9198a1; opacity: 1; } @@ -216,10 +214,6 @@ cursor: pointer; } -.markdown-body details:not([open])>*:not(summary) { - display: none; -} - .markdown-body a:focus, .markdown-body [role=button]:focus, .markdown-body input[type=radio]:focus, @@ -256,16 +250,16 @@ .markdown-body kbd { display: inline-block; - padding: 3px 5px; + padding: 0.25rem; font: 11px ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace; line-height: 10px; - color: #e6edf3; + color: #f0f6fc; vertical-align: middle; - background-color: #161b22; - border: solid 1px #6e768166; - border-bottom-color: #6e768166; + background-color: #151b23; + border: solid 1px #3d444db3; + border-bottom-color: #3d444db3; border-radius: 6px; - box-shadow: inset 0 -1px 0 #6e768166; + box-shadow: inset 0 -1px 0 #3d444db3; } .markdown-body h1, @@ -274,8 +268,8 @@ .markdown-body h4, .markdown-body h5, .markdown-body h6 { - margin-top: 24px; - margin-bottom: 16px; + margin-top: 1.5rem; + margin-bottom: 1rem; font-weight: 600; line-height: 1.25; } @@ -284,7 +278,7 @@ font-weight: 600; padding-bottom: .3em; font-size: 1.5em; - border-bottom: 1px solid #30363db3; + border-bottom: 1px solid #3d444db3; } .markdown-body h3 { @@ -305,7 +299,7 @@ .markdown-body h6 { font-weight: 600; font-size: .85em; - color: #8d96a0; + color: #9198a1; } .markdown-body p { @@ -316,8 +310,8 @@ .markdown-body blockquote { margin: 0; padding: 0 1em; - color: #8d96a0; - border-left: .25em solid #30363d; + color: #9198a1; + border-left: .25em solid #3d444d; } .markdown-body ul, @@ -406,7 +400,7 @@ .markdown-body .anchor { float: left; - padding-right: 4px; + padding-right: 0.25rem; margin-left: -20px; line-height: 1; } @@ -424,7 +418,7 @@ .markdown-body pre, .markdown-body details { margin-top: 0; - margin-bottom: 16px; + margin-bottom: 1rem; } .markdown-body blockquote>:first-child { @@ -441,7 +435,7 @@ .markdown-body h4 .octicon-link, .markdown-body h5 .octicon-link, .markdown-body h6 .octicon-link { - color: #e6edf3; + color: #f0f6fc; vertical-align: middle; visibility: hidden; } @@ -543,7 +537,7 @@ } .markdown-body li>p { - margin-top: 16px; + margin-top: 1rem; } .markdown-body li+li { @@ -556,15 +550,15 @@ .markdown-body dl dt { padding: 0; - margin-top: 16px; + margin-top: 1rem; font-size: 1em; font-style: italic; font-weight: 600; } .markdown-body dl dd { - padding: 0 16px; - margin-bottom: 16px; + padding: 0 1rem; + margin-bottom: 1rem; } .markdown-body table th { @@ -574,7 +568,7 @@ .markdown-body table th, .markdown-body table td { padding: 6px 13px; - border: 1px solid #30363d; + border: 1px solid #3d444d; } .markdown-body table td>:last-child { @@ -583,11 +577,11 @@ .markdown-body table tr { background-color: #0d1117; - border-top: 1px solid #30363db3; + border-top: 1px solid #3d444db3; } .markdown-body table tr:nth-child(2n) { - background-color: #161b22; + background-color: #151b23; } .markdown-body table img { @@ -620,7 +614,7 @@ padding: 7px; margin: 13px 0 0; overflow: hidden; - border: 1px solid #30363d; + border: 1px solid #3d444d; } .markdown-body span.frame span img { @@ -632,7 +626,7 @@ display: block; padding: 5px 0 0; clear: both; - color: #e6edf3; + color: #f0f6fc; } .markdown-body span.align-center { @@ -702,7 +696,7 @@ margin: 0; font-size: 85%; white-space: break-spaces; - background-color: #6e768166; + background-color: #656c7633; border-radius: 6px; } @@ -733,7 +727,7 @@ } .markdown-body .highlight { - margin-bottom: 16px; + margin-bottom: 1rem; } .markdown-body .highlight pre { @@ -743,12 +737,12 @@ .markdown-body .highlight pre, .markdown-body pre { - padding: 16px; + padding: 1rem; overflow: auto; font-size: 85%; line-height: 1.45; - color: #e6edf3; - background-color: #161b22; + color: #f0f6fc; + background-color: #151b23; border-radius: 6px; } @@ -776,7 +770,7 @@ } .markdown-body .csv-data .blob-num { - padding: 10px 8px 9px; + padding: 10px 0.5rem 9px; text-align: right; background: #0d1117; border: 0; @@ -788,7 +782,7 @@ .markdown-body .csv-data th { font-weight: 600; - background: #161b22; + background: #151b23; border-top: 0; } @@ -802,18 +796,18 @@ .markdown-body .footnotes { font-size: 12px; - color: #8d96a0; - border-top: 1px solid #30363d; + color: #9198a1; + border-top: 1px solid #3d444d; } .markdown-body .footnotes ol { - padding-left: 16px; + padding-left: 1rem; } .markdown-body .footnotes ol ul { display: inline-block; - padding-left: 16px; - margin-top: 16px; + padding-left: 1rem; + margin-top: 1rem; } .markdown-body .footnotes li { @@ -822,10 +816,10 @@ .markdown-body .footnotes li:target::before { position: absolute; - top: -8px; - right: -8px; - bottom: -8px; - left: -24px; + top: calc(0.5rem*-1); + right: calc(0.5rem*-1); + bottom: calc(0.5rem*-1); + left: calc(1.5rem*-1); pointer-events: none; content: ""; border: 2px solid #1f6feb; @@ -833,7 +827,7 @@ } .markdown-body .footnotes li:target { - color: #e6edf3; + color: #f0f6fc; } .markdown-body .footnotes .data-footnote-backref g-emoji { @@ -841,7 +835,7 @@ } .markdown-body .pl-c { - color: #8b949e; + color: #9198a1; } .markdown-body .pl-c1, @@ -856,7 +850,7 @@ .markdown-body .pl-smi, .markdown-body .pl-s .pl-s1 { - color: #c9d1d9; + color: #f0f6fc; } .markdown-body .pl-ent { @@ -914,12 +908,12 @@ .markdown-body .pl-mi { font-style: italic; - color: #c9d1d9; + color: #f0f6fc; } .markdown-body .pl-mb { font-weight: bold; - color: #c9d1d9; + color: #f0f6fc; } .markdown-body .pl-md { @@ -938,7 +932,7 @@ } .markdown-body .pl-mi2 { - color: #c9d1d9; + color: #f0f6fc; background-color: #1158c7; } @@ -948,11 +942,11 @@ } .markdown-body .pl-ba { - color: #8b949e; + color: #9198a1; } .markdown-body .pl-sg { - color: #484f58; + color: #3d444d; } .markdown-body .pl-corl { @@ -1015,12 +1009,12 @@ vertical-align: middle; } -.markdown-body .contains-task-list:dir(rtl) .task-list-item-checkbox { +.markdown-body ul:dir(rtl) .task-list-item-checkbox { margin: 0 -1.6em .25em .2em; } -.markdown-body .contains-task-list { - position: relative; +.markdown-body ol:dir(rtl) .task-list-item-checkbox { + margin: 0 -1.6em .25em .2em; } .markdown-body .contains-task-list:hover .task-list-item-convert-container, @@ -1040,7 +1034,7 @@ padding: 0.5rem 1rem; margin-bottom: 1rem; color: inherit; - border-left: .25em solid #30363d; + border-left: .25em solid #3d444d; } .markdown-body .markdown-alert>:first-child { @@ -1101,3 +1095,4 @@ .markdown-body>*:first-child>.heading-element:first-child { margin-top: 0 !important; } + diff --git a/github-markdown-light.css b/github-markdown-light.css index 90b27c0..6e7ddf3 100644 --- a/github-markdown-light.css +++ b/github-markdown-light.css @@ -1,6 +1,6 @@ -/*light*/ - +/* light */ .markdown-body { + color-scheme: light; -ms-text-size-adjust: 100%; -webkit-text-size-adjust: 100%; margin: 0; @@ -10,7 +10,7 @@ font-size: 16px; line-height: 1.5; word-wrap: break-word; - scroll-behavior: auto; + scroll-behavior: auto !important; } .markdown-body .octicon { @@ -74,7 +74,7 @@ font-weight: 600; padding-bottom: .3em; font-size: 2em; - border-bottom: 1px solid #d0d7deb3; + border-bottom: 1px solid #d1d9e0b3; } .markdown-body mark { @@ -106,7 +106,6 @@ border-style: none; max-width: 100%; box-sizing: content-box; - background-color: #ffffff; } .markdown-body code, @@ -118,18 +117,18 @@ } .markdown-body figure { - margin: 1em 40px; + margin: 1em 2.5rem; } .markdown-body hr { box-sizing: content-box; overflow: hidden; background: transparent; - border-bottom: 1px solid #d0d7deb3; + border-bottom: 1px solid #d1d9e0b3; height: .25em; padding: 0; - margin: 24px 0; - background-color: #d0d7de; + margin: 1.5rem 0; + background-color: #d1d9e0; border: 0; } @@ -182,7 +181,7 @@ } .markdown-body ::placeholder { - color: #636c76; + color: #59636e; opacity: 1; } @@ -215,10 +214,6 @@ cursor: pointer; } -.markdown-body details:not([open])>*:not(summary) { - display: none; -} - .markdown-body a:focus, .markdown-body [role=button]:focus, .markdown-body input[type=radio]:focus, @@ -255,16 +250,16 @@ .markdown-body kbd { display: inline-block; - padding: 3px 5px; + padding: 0.25rem; font: 11px ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace; line-height: 10px; color: #1f2328; vertical-align: middle; background-color: #f6f8fa; - border: solid 1px #afb8c133; - border-bottom-color: #afb8c133; + border: solid 1px #d1d9e0b3; + border-bottom-color: #d1d9e0b3; border-radius: 6px; - box-shadow: inset 0 -1px 0 #afb8c133; + box-shadow: inset 0 -1px 0 #d1d9e0b3; } .markdown-body h1, @@ -273,8 +268,8 @@ .markdown-body h4, .markdown-body h5, .markdown-body h6 { - margin-top: 24px; - margin-bottom: 16px; + margin-top: 1.5rem; + margin-bottom: 1rem; font-weight: 600; line-height: 1.25; } @@ -283,7 +278,7 @@ font-weight: 600; padding-bottom: .3em; font-size: 1.5em; - border-bottom: 1px solid #d0d7deb3; + border-bottom: 1px solid #d1d9e0b3; } .markdown-body h3 { @@ -304,7 +299,7 @@ .markdown-body h6 { font-weight: 600; font-size: .85em; - color: #636c76; + color: #59636e; } .markdown-body p { @@ -315,8 +310,8 @@ .markdown-body blockquote { margin: 0; padding: 0 1em; - color: #636c76; - border-left: .25em solid #d0d7de; + color: #59636e; + border-left: .25em solid #d1d9e0; } .markdown-body ul, @@ -405,7 +400,7 @@ .markdown-body .anchor { float: left; - padding-right: 4px; + padding-right: 0.25rem; margin-left: -20px; line-height: 1; } @@ -423,7 +418,7 @@ .markdown-body pre, .markdown-body details { margin-top: 0; - margin-bottom: 16px; + margin-bottom: 1rem; } .markdown-body blockquote>:first-child { @@ -542,7 +537,7 @@ } .markdown-body li>p { - margin-top: 16px; + margin-top: 1rem; } .markdown-body li+li { @@ -555,15 +550,15 @@ .markdown-body dl dt { padding: 0; - margin-top: 16px; + margin-top: 1rem; font-size: 1em; font-style: italic; font-weight: 600; } .markdown-body dl dd { - padding: 0 16px; - margin-bottom: 16px; + padding: 0 1rem; + margin-bottom: 1rem; } .markdown-body table th { @@ -573,7 +568,7 @@ .markdown-body table th, .markdown-body table td { padding: 6px 13px; - border: 1px solid #d0d7de; + border: 1px solid #d1d9e0; } .markdown-body table td>:last-child { @@ -582,7 +577,7 @@ .markdown-body table tr { background-color: #ffffff; - border-top: 1px solid #d0d7deb3; + border-top: 1px solid #d1d9e0b3; } .markdown-body table tr:nth-child(2n) { @@ -619,7 +614,7 @@ padding: 7px; margin: 13px 0 0; overflow: hidden; - border: 1px solid #d0d7de; + border: 1px solid #d1d9e0; } .markdown-body span.frame span img { @@ -701,7 +696,7 @@ margin: 0; font-size: 85%; white-space: break-spaces; - background-color: #afb8c133; + background-color: #818b981f; border-radius: 6px; } @@ -732,7 +727,7 @@ } .markdown-body .highlight { - margin-bottom: 16px; + margin-bottom: 1rem; } .markdown-body .highlight pre { @@ -742,7 +737,7 @@ .markdown-body .highlight pre, .markdown-body pre { - padding: 16px; + padding: 1rem; overflow: auto; font-size: 85%; line-height: 1.45; @@ -775,7 +770,7 @@ } .markdown-body .csv-data .blob-num { - padding: 10px 8px 9px; + padding: 10px 0.5rem 9px; text-align: right; background: #ffffff; border: 0; @@ -801,18 +796,18 @@ .markdown-body .footnotes { font-size: 12px; - color: #636c76; - border-top: 1px solid #d0d7de; + color: #59636e; + border-top: 1px solid #d1d9e0; } .markdown-body .footnotes ol { - padding-left: 16px; + padding-left: 1rem; } .markdown-body .footnotes ol ul { display: inline-block; - padding-left: 16px; - margin-top: 16px; + padding-left: 1rem; + margin-top: 1rem; } .markdown-body .footnotes li { @@ -821,10 +816,10 @@ .markdown-body .footnotes li:target::before { position: absolute; - top: -8px; - right: -8px; - bottom: -8px; - left: -24px; + top: calc(0.5rem*-1); + right: calc(0.5rem*-1); + bottom: calc(0.5rem*-1); + left: calc(1.5rem*-1); pointer-events: none; content: ""; border: 2px solid #0969da; @@ -840,7 +835,7 @@ } .markdown-body .pl-c { - color: #57606a; + color: #59636e; } .markdown-body .pl-c1, @@ -855,7 +850,7 @@ .markdown-body .pl-smi, .markdown-body .pl-s .pl-s1 { - color: #24292f; + color: #1f2328; } .markdown-body .pl-ent { @@ -913,12 +908,12 @@ .markdown-body .pl-mi { font-style: italic; - color: #24292f; + color: #1f2328; } .markdown-body .pl-mb { font-weight: bold; - color: #24292f; + color: #1f2328; } .markdown-body .pl-md { @@ -937,7 +932,7 @@ } .markdown-body .pl-mi2 { - color: #eaeef2; + color: #d1d9e0; background-color: #0550ae; } @@ -947,11 +942,11 @@ } .markdown-body .pl-ba { - color: #57606a; + color: #59636e; } .markdown-body .pl-sg { - color: #8c959f; + color: #818b98; } .markdown-body .pl-corl { @@ -1014,12 +1009,12 @@ vertical-align: middle; } -.markdown-body .contains-task-list:dir(rtl) .task-list-item-checkbox { +.markdown-body ul:dir(rtl) .task-list-item-checkbox { margin: 0 -1.6em .25em .2em; } -.markdown-body .contains-task-list { - position: relative; +.markdown-body ol:dir(rtl) .task-list-item-checkbox { + margin: 0 -1.6em .25em .2em; } .markdown-body .contains-task-list:hover .task-list-item-convert-container, @@ -1039,7 +1034,7 @@ padding: 0.5rem 1rem; margin-bottom: 1rem; color: inherit; - border-left: .25em solid #d0d7de; + border-left: .25em solid #d1d9e0; } .markdown-body .markdown-alert>:first-child { @@ -1074,7 +1069,7 @@ } .markdown-body .markdown-alert.markdown-alert-warning { - border-left-color: #bf8700; + border-left-color: #9a6700; } .markdown-body .markdown-alert.markdown-alert-warning .markdown-alert-title { @@ -1100,3 +1095,4 @@ .markdown-body>*:first-child>.heading-element:first-child { margin-top: 0 !important; } + diff --git a/github-markdown.css b/github-markdown.css index ebfca67..b7afaa4 100644 --- a/github-markdown.css +++ b/github-markdown.css @@ -2,48 +2,49 @@ --base-size-4: 0.25rem; --base-size-8: 0.5rem; --base-size-16: 1rem; + --base-size-24: 1.5rem; + --base-size-40: 2.5rem; --base-text-weight-normal: 400; --base-text-weight-medium: 500; --base-text-weight-semibold: 600; --fontStack-monospace: ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace; + --fgColor-accent: Highlight; } - @media (prefers-color-scheme: dark) { - .markdown-body, - [data-theme="dark"] { - /*dark*/ + .markdown-body, [data-theme="dark"] { + /* dark */ color-scheme: dark; --focus-outlineColor: #1f6feb; - --fgColor-default: #e6edf3; - --fgColor-muted: #8d96a0; + --fgColor-default: #f0f6fc; + --fgColor-muted: #9198a1; --fgColor-accent: #4493f8; --fgColor-success: #3fb950; --fgColor-attention: #d29922; --fgColor-danger: #f85149; --fgColor-done: #ab7df8; --bgColor-default: #0d1117; - --bgColor-muted: #161b22; - --bgColor-neutral-muted: #6e768166; + --bgColor-muted: #151b23; + --bgColor-neutral-muted: #656c7633; --bgColor-attention-muted: #bb800926; - --borderColor-default: #30363d; - --borderColor-muted: #30363db3; - --borderColor-neutral-muted: #6e768166; + --borderColor-default: #3d444d; + --borderColor-muted: #3d444db3; + --borderColor-neutral-muted: #3d444db3; --borderColor-accent-emphasis: #1f6feb; --borderColor-success-emphasis: #238636; --borderColor-attention-emphasis: #9e6a03; --borderColor-danger-emphasis: #da3633; --borderColor-done-emphasis: #8957e5; - --color-prettylights-syntax-comment: #8b949e; + --color-prettylights-syntax-comment: #9198a1; --color-prettylights-syntax-constant: #79c0ff; --color-prettylights-syntax-constant-other-reference-link: #a5d6ff; --color-prettylights-syntax-entity: #d2a8ff; - --color-prettylights-syntax-storage-modifier-import: #c9d1d9; + --color-prettylights-syntax-storage-modifier-import: #f0f6fc; --color-prettylights-syntax-entity-tag: #7ee787; --color-prettylights-syntax-keyword: #ff7b72; --color-prettylights-syntax-string: #a5d6ff; --color-prettylights-syntax-variable: #ffa657; --color-prettylights-syntax-brackethighlighter-unmatched: #f85149; - --color-prettylights-syntax-brackethighlighter-angle: #8b949e; + --color-prettylights-syntax-brackethighlighter-angle: #9198a1; --color-prettylights-syntax-invalid-illegal-text: #f0f6fc; --color-prettylights-syntax-invalid-illegal-bg: #8e1519; --color-prettylights-syntax-carriage-return-text: #f0f6fc; @@ -51,29 +52,27 @@ --color-prettylights-syntax-string-regexp: #7ee787; --color-prettylights-syntax-markup-list: #f2cc60; --color-prettylights-syntax-markup-heading: #1f6feb; - --color-prettylights-syntax-markup-italic: #c9d1d9; - --color-prettylights-syntax-markup-bold: #c9d1d9; + --color-prettylights-syntax-markup-italic: #f0f6fc; + --color-prettylights-syntax-markup-bold: #f0f6fc; --color-prettylights-syntax-markup-deleted-text: #ffdcd7; --color-prettylights-syntax-markup-deleted-bg: #67060c; --color-prettylights-syntax-markup-inserted-text: #aff5b4; --color-prettylights-syntax-markup-inserted-bg: #033a16; --color-prettylights-syntax-markup-changed-text: #ffdfb6; --color-prettylights-syntax-markup-changed-bg: #5a1e02; - --color-prettylights-syntax-markup-ignored-text: #c9d1d9; + --color-prettylights-syntax-markup-ignored-text: #f0f6fc; --color-prettylights-syntax-markup-ignored-bg: #1158c7; --color-prettylights-syntax-meta-diff-range: #d2a8ff; - --color-prettylights-syntax-sublimelinter-gutter-mark: #484f58; + --color-prettylights-syntax-sublimelinter-gutter-mark: #3d444d; } } - @media (prefers-color-scheme: light) { - .markdown-body, - [data-theme="light"] { - /*light*/ + .markdown-body, [data-theme="light"] { + /* light */ color-scheme: light; --focus-outlineColor: #0969da; --fgColor-default: #1f2328; - --fgColor-muted: #636c76; + --fgColor-muted: #59636e; --fgColor-accent: #0969da; --fgColor-success: #1a7f37; --fgColor-attention: #9a6700; @@ -81,27 +80,27 @@ --fgColor-done: #8250df; --bgColor-default: #ffffff; --bgColor-muted: #f6f8fa; - --bgColor-neutral-muted: #afb8c133; + --bgColor-neutral-muted: #818b981f; --bgColor-attention-muted: #fff8c5; - --borderColor-default: #d0d7de; - --borderColor-muted: #d0d7deb3; - --borderColor-neutral-muted: #afb8c133; + --borderColor-default: #d1d9e0; + --borderColor-muted: #d1d9e0b3; + --borderColor-neutral-muted: #d1d9e0b3; --borderColor-accent-emphasis: #0969da; --borderColor-success-emphasis: #1a7f37; - --borderColor-attention-emphasis: #bf8700; + --borderColor-attention-emphasis: #9a6700; --borderColor-danger-emphasis: #cf222e; --borderColor-done-emphasis: #8250df; - --color-prettylights-syntax-comment: #57606a; + --color-prettylights-syntax-comment: #59636e; --color-prettylights-syntax-constant: #0550ae; --color-prettylights-syntax-constant-other-reference-link: #0a3069; --color-prettylights-syntax-entity: #6639ba; - --color-prettylights-syntax-storage-modifier-import: #24292f; + --color-prettylights-syntax-storage-modifier-import: #1f2328; --color-prettylights-syntax-entity-tag: #0550ae; --color-prettylights-syntax-keyword: #cf222e; --color-prettylights-syntax-string: #0a3069; --color-prettylights-syntax-variable: #953800; --color-prettylights-syntax-brackethighlighter-unmatched: #82071e; - --color-prettylights-syntax-brackethighlighter-angle: #57606a; + --color-prettylights-syntax-brackethighlighter-angle: #59636e; --color-prettylights-syntax-invalid-illegal-text: #f6f8fa; --color-prettylights-syntax-invalid-illegal-bg: #82071e; --color-prettylights-syntax-carriage-return-text: #f6f8fa; @@ -109,18 +108,18 @@ --color-prettylights-syntax-string-regexp: #116329; --color-prettylights-syntax-markup-list: #3b2300; --color-prettylights-syntax-markup-heading: #0550ae; - --color-prettylights-syntax-markup-italic: #24292f; - --color-prettylights-syntax-markup-bold: #24292f; + --color-prettylights-syntax-markup-italic: #1f2328; + --color-prettylights-syntax-markup-bold: #1f2328; --color-prettylights-syntax-markup-deleted-text: #82071e; --color-prettylights-syntax-markup-deleted-bg: #ffebe9; --color-prettylights-syntax-markup-inserted-text: #116329; --color-prettylights-syntax-markup-inserted-bg: #dafbe1; --color-prettylights-syntax-markup-changed-text: #953800; --color-prettylights-syntax-markup-changed-bg: #ffd8b5; - --color-prettylights-syntax-markup-ignored-text: #eaeef2; + --color-prettylights-syntax-markup-ignored-text: #d1d9e0; --color-prettylights-syntax-markup-ignored-bg: #0550ae; --color-prettylights-syntax-meta-diff-range: #8250df; - --color-prettylights-syntax-sublimelinter-gutter-mark: #8c959f; + --color-prettylights-syntax-sublimelinter-gutter-mark: #818b98; } } @@ -134,7 +133,7 @@ font-size: 16px; line-height: 1.5; word-wrap: break-word; - scroll-behavior: auto; + scroll-behavior: auto !important; } .markdown-body .octicon { @@ -230,7 +229,6 @@ border-style: none; max-width: 100%; box-sizing: content-box; - background-color: var(--bgColor-default); } .markdown-body code, @@ -242,7 +240,7 @@ } .markdown-body figure { - margin: 1em 40px; + margin: 1em var(--base-size-40); } .markdown-body hr { @@ -252,7 +250,7 @@ border-bottom: 1px solid var(--borderColor-muted); height: .25em; padding: 0; - margin: 24px 0; + margin: var(--base-size-24) 0; background-color: var(--borderColor-default); border: 0; } @@ -339,10 +337,6 @@ cursor: pointer; } -.markdown-body details:not([open])>*:not(summary) { - display: none; -} - .markdown-body a:focus, .markdown-body [role=button]:focus, .markdown-body input[type=radio]:focus, @@ -379,7 +373,7 @@ .markdown-body kbd { display: inline-block; - padding: 3px 5px; + padding: var(--base-size-4); font: 11px var(--fontStack-monospace, ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace); line-height: 10px; color: var(--fgColor-default); @@ -397,8 +391,8 @@ .markdown-body h4, .markdown-body h5, .markdown-body h6 { - margin-top: 24px; - margin-bottom: 16px; + margin-top: var(--base-size-24); + margin-bottom: var(--base-size-16); font-weight: var(--base-text-weight-semibold, 600); line-height: 1.25; } @@ -529,7 +523,7 @@ .markdown-body .anchor { float: left; - padding-right: 4px; + padding-right: var(--base-size-4); margin-left: -20px; line-height: 1; } @@ -547,7 +541,7 @@ .markdown-body pre, .markdown-body details { margin-top: 0; - margin-bottom: 16px; + margin-bottom: var(--base-size-16); } .markdown-body blockquote>:first-child { @@ -666,7 +660,7 @@ } .markdown-body li>p { - margin-top: 16px; + margin-top: var(--base-size-16); } .markdown-body li+li { @@ -679,15 +673,15 @@ .markdown-body dl dt { padding: 0; - margin-top: 16px; + margin-top: var(--base-size-16); font-size: 1em; font-style: italic; font-weight: var(--base-text-weight-semibold, 600); } .markdown-body dl dd { - padding: 0 16px; - margin-bottom: 16px; + padding: 0 var(--base-size-16); + margin-bottom: var(--base-size-16); } .markdown-body table th { @@ -856,7 +850,7 @@ } .markdown-body .highlight { - margin-bottom: 16px; + margin-bottom: var(--base-size-16); } .markdown-body .highlight pre { @@ -866,7 +860,7 @@ .markdown-body .highlight pre, .markdown-body pre { - padding: 16px; + padding: var(--base-size-16); overflow: auto; font-size: 85%; line-height: 1.45; @@ -899,7 +893,7 @@ } .markdown-body .csv-data .blob-num { - padding: 10px 8px 9px; + padding: 10px var(--base-size-8) 9px; text-align: right; background: var(--bgColor-default); border: 0; @@ -930,13 +924,13 @@ } .markdown-body .footnotes ol { - padding-left: 16px; + padding-left: var(--base-size-16); } .markdown-body .footnotes ol ul { display: inline-block; - padding-left: 16px; - margin-top: 16px; + padding-left: var(--base-size-16); + margin-top: var(--base-size-16); } .markdown-body .footnotes li { @@ -945,10 +939,10 @@ .markdown-body .footnotes li:target::before { position: absolute; - top: -8px; - right: -8px; - bottom: -8px; - left: -24px; + top: calc(var(--base-size-8)*-1); + right: calc(var(--base-size-8)*-1); + bottom: calc(var(--base-size-8)*-1); + left: calc(var(--base-size-24)*-1); pointer-events: none; content: ""; border: 2px solid var(--borderColor-accent-emphasis); @@ -1138,12 +1132,12 @@ vertical-align: middle; } -.markdown-body .contains-task-list:dir(rtl) .task-list-item-checkbox { +.markdown-body ul:dir(rtl) .task-list-item-checkbox { margin: 0 -1.6em .25em .2em; } -.markdown-body .contains-task-list { - position: relative; +.markdown-body ol:dir(rtl) .task-list-item-checkbox { + margin: 0 -1.6em .25em .2em; } .markdown-body .contains-task-list:hover .task-list-item-convert-container, @@ -1224,3 +1218,4 @@ .markdown-body>*:first-child>.heading-element:first-child { margin-top: 0 !important; } + diff --git a/package.json b/package.json index b7bb0ba..7d6b388 100644 --- a/package.json +++ b/package.json @@ -35,6 +35,6 @@ "stylesheet" ], "devDependencies": { - "generate-github-markdown-css": "^6.3.0" + "generate-github-markdown-css": "^6.4.0" } } From 74e1bcc0522c478c3c83e04430784614795312a0 Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Thu, 26 Sep 2024 11:23:50 +0700 Subject: [PATCH 14/19] 5.7.0 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 7d6b388..f33f148 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "github-markdown-css", - "version": "5.6.1", + "version": "5.7.0", "description": "The minimal amount of CSS to replicate the GitHub Markdown style", "license": "MIT", "repository": "sindresorhus/github-markdown-css", From 0b0d6edc282b18e129bcceb94764525bb698ff16 Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Sat, 16 Nov 2024 00:30:07 +0700 Subject: [PATCH 15/19] Regenerate GitHub CSS --- github-markdown-dark.css | 43 ++++++++++++++++++++++++++++++++++----- github-markdown-light.css | 43 ++++++++++++++++++++++++++++++++++----- github-markdown.css | 43 ++++++++++++++++++++++++++++++++++----- package.json | 8 ++++---- 4 files changed, 118 insertions(+), 19 deletions(-) diff --git a/github-markdown-dark.css b/github-markdown-dark.css index df8f2c1..c65130d 100644 --- a/github-markdown-dark.css +++ b/github-markdown-dark.css @@ -3,14 +3,15 @@ color-scheme: dark; -ms-text-size-adjust: 100%; -webkit-text-size-adjust: 100%; - margin: 0; color: #f0f6fc; background-color: #0d1117; font-family: -apple-system,BlinkMacSystemFont,"Segoe UI","Noto Sans",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"; font-size: 16px; - line-height: 1.5; word-wrap: break-word; - scroll-behavior: auto !important; + margin: 0; + min-height: 100vh; + line-height: 1.5; + scroll-behavior: smooth; } .markdown-body .octicon { @@ -133,12 +134,12 @@ } .markdown-body input { - font: inherit; margin: 0; overflow: visible; font-family: inherit; font-size: inherit; line-height: inherit; + font: inherit; } .markdown-body [type=button], @@ -203,6 +204,7 @@ width: max-content; max-width: 100%; overflow: auto; + font-variant: tabular-nums; } .markdown-body td, @@ -362,7 +364,6 @@ .markdown-body input::-webkit-outer-spin-button, .markdown-body input::-webkit-inner-spin-button { margin: 0; - -webkit-appearance: none; appearance: none; } @@ -834,6 +835,10 @@ font-family: monospace; } +.markdown-body body:has(:modal) { + padding-right: var(--dialog-scrollgutter) !important; +} + .markdown-body .pl-c { color: #9198a1; } @@ -1096,3 +1101,31 @@ margin-top: 0 !important; } +.markdown-body ul[role='list'], +.markdown-body ol[role='list'] { + list-style: none; +} + +.markdown-body html[focus-within] { + scroll-behavior: smooth; +} + +.markdown-body html:focus-within { + scroll-behavior: smooth; +} + +.markdown-body a:not([class]) { + -webkit-text-decoration-skip: ink; + text-decoration-skip-ink: auto; +} + +.markdown-body img, +.markdown-body picture { + max-width: 100%; + display: block; +} + +.markdown-body [class^=Primer_Brand__Link-module__Link___]::after { + width: calc(100% - 20px); +} + diff --git a/github-markdown-light.css b/github-markdown-light.css index 6e7ddf3..80b6561 100644 --- a/github-markdown-light.css +++ b/github-markdown-light.css @@ -3,14 +3,15 @@ color-scheme: light; -ms-text-size-adjust: 100%; -webkit-text-size-adjust: 100%; - margin: 0; color: #1f2328; background-color: #ffffff; font-family: -apple-system,BlinkMacSystemFont,"Segoe UI","Noto Sans",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"; font-size: 16px; - line-height: 1.5; word-wrap: break-word; - scroll-behavior: auto !important; + margin: 0; + min-height: 100vh; + line-height: 1.5; + scroll-behavior: smooth; } .markdown-body .octicon { @@ -133,12 +134,12 @@ } .markdown-body input { - font: inherit; margin: 0; overflow: visible; font-family: inherit; font-size: inherit; line-height: inherit; + font: inherit; } .markdown-body [type=button], @@ -203,6 +204,7 @@ width: max-content; max-width: 100%; overflow: auto; + font-variant: tabular-nums; } .markdown-body td, @@ -362,7 +364,6 @@ .markdown-body input::-webkit-outer-spin-button, .markdown-body input::-webkit-inner-spin-button { margin: 0; - -webkit-appearance: none; appearance: none; } @@ -834,6 +835,10 @@ font-family: monospace; } +.markdown-body body:has(:modal) { + padding-right: var(--dialog-scrollgutter) !important; +} + .markdown-body .pl-c { color: #59636e; } @@ -1096,3 +1101,31 @@ margin-top: 0 !important; } +.markdown-body ul[role='list'], +.markdown-body ol[role='list'] { + list-style: none; +} + +.markdown-body html[focus-within] { + scroll-behavior: smooth; +} + +.markdown-body html:focus-within { + scroll-behavior: smooth; +} + +.markdown-body a:not([class]) { + -webkit-text-decoration-skip: ink; + text-decoration-skip-ink: auto; +} + +.markdown-body img, +.markdown-body picture { + max-width: 100%; + display: block; +} + +.markdown-body [class^=Primer_Brand__Link-module__Link___]::after { + width: calc(100% - 20px); +} + diff --git a/github-markdown.css b/github-markdown.css index b7afaa4..257b921 100644 --- a/github-markdown.css +++ b/github-markdown.css @@ -126,14 +126,15 @@ .markdown-body { -ms-text-size-adjust: 100%; -webkit-text-size-adjust: 100%; - margin: 0; color: var(--fgColor-default); background-color: var(--bgColor-default); font-family: -apple-system,BlinkMacSystemFont,"Segoe UI","Noto Sans",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"; font-size: 16px; - line-height: 1.5; word-wrap: break-word; - scroll-behavior: auto !important; + margin: 0; + min-height: 100vh; + line-height: 1.5; + scroll-behavior: smooth; } .markdown-body .octicon { @@ -256,12 +257,12 @@ } .markdown-body input { - font: inherit; margin: 0; overflow: visible; font-family: inherit; font-size: inherit; line-height: inherit; + font: inherit; } .markdown-body [type=button], @@ -326,6 +327,7 @@ width: max-content; max-width: 100%; overflow: auto; + font-variant: tabular-nums; } .markdown-body td, @@ -485,7 +487,6 @@ .markdown-body input::-webkit-outer-spin-button, .markdown-body input::-webkit-inner-spin-button { margin: 0; - -webkit-appearance: none; appearance: none; } @@ -957,6 +958,10 @@ font-family: monospace; } +.markdown-body body:has(:modal) { + padding-right: var(--dialog-scrollgutter) !important; +} + .markdown-body .pl-c { color: var(--color-prettylights-syntax-comment); } @@ -1219,3 +1224,31 @@ margin-top: 0 !important; } +.markdown-body ul[role='list'], +.markdown-body ol[role='list'] { + list-style: none; +} + +.markdown-body html[focus-within] { + scroll-behavior: smooth; +} + +.markdown-body html:focus-within { + scroll-behavior: smooth; +} + +.markdown-body a:not([class]) { + -webkit-text-decoration-skip: ink; + text-decoration-skip-ink: auto; +} + +.markdown-body img, +.markdown-body picture { + max-width: 100%; + display: block; +} + +.markdown-body [class^=Primer_Brand__Link-module__Link___]::after { + width: calc(100% - 20px); +} + diff --git a/package.json b/package.json index f33f148..fe31083 100644 --- a/package.json +++ b/package.json @@ -15,9 +15,9 @@ "node": ">=10" }, "scripts": { - "make:light": "github-markdown-css --type light > github-markdown-light.css", - "make:dark": "github-markdown-css --type dark > github-markdown-dark.css", - "make:auto": "github-markdown-css --type auto > github-markdown.css", + "make:light": "github-markdown-css --no-use-fixture --type light > github-markdown-light.css", + "make:dark": "github-markdown-css --no-use-fixture --type dark > github-markdown-dark.css", + "make:auto": "github-markdown-css --no-use-fixture --type auto > github-markdown.css", "make": "npm run make:light && npm run make:dark && npm run make:auto" }, "files": [ @@ -35,6 +35,6 @@ "stylesheet" ], "devDependencies": { - "generate-github-markdown-css": "^6.4.0" + "generate-github-markdown-css": "^6.5.0" } } From 9ab210a7b09f657d0b79321e8135017d9d64236a Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Sat, 16 Nov 2024 00:33:18 +0700 Subject: [PATCH 16/19] 5.8.0 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index fe31083..f91fa99 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "github-markdown-css", - "version": "5.7.0", + "version": "5.8.0", "description": "The minimal amount of CSS to replicate the GitHub Markdown style", "license": "MIT", "repository": "sindresorhus/github-markdown-css", From f2dc5d9c8cda13c47119aafbea649ef1307a2e9e Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Thu, 28 Nov 2024 15:40:20 +0700 Subject: [PATCH 17/19] Regenerate GitHub CSS --- github-markdown-dark.css | 36 +++++------------------------------- github-markdown-light.css | 36 +++++------------------------------- github-markdown.css | 36 +++++------------------------------- package.json | 2 +- 4 files changed, 16 insertions(+), 94 deletions(-) diff --git a/github-markdown-dark.css b/github-markdown-dark.css index c65130d..a5a7343 100644 --- a/github-markdown-dark.css +++ b/github-markdown-dark.css @@ -3,15 +3,13 @@ color-scheme: dark; -ms-text-size-adjust: 100%; -webkit-text-size-adjust: 100%; + margin: 0; color: #f0f6fc; background-color: #0d1117; font-family: -apple-system,BlinkMacSystemFont,"Segoe UI","Noto Sans",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"; font-size: 16px; - word-wrap: break-word; - margin: 0; - min-height: 100vh; line-height: 1.5; - scroll-behavior: smooth; + word-wrap: break-word; } .markdown-body .octicon { @@ -134,12 +132,12 @@ } .markdown-body input { + font: inherit; margin: 0; overflow: visible; font-family: inherit; font-size: inherit; line-height: inherit; - font: inherit; } .markdown-body [type=button], @@ -1101,31 +1099,7 @@ margin-top: 0 !important; } -.markdown-body ul[role='list'], -.markdown-body ol[role='list'] { - list-style: none; -} - -.markdown-body html[focus-within] { - scroll-behavior: smooth; -} - -.markdown-body html:focus-within { - scroll-behavior: smooth; -} - -.markdown-body a:not([class]) { - -webkit-text-decoration-skip: ink; - text-decoration-skip-ink: auto; -} - -.markdown-body img, -.markdown-body picture { - max-width: 100%; - display: block; -} - -.markdown-body [class^=Primer_Brand__Link-module__Link___]::after { - width: calc(100% - 20px); +.markdown-body .highlight pre:has(+.zeroclipboard-container) { + min-height: 52px; } diff --git a/github-markdown-light.css b/github-markdown-light.css index 80b6561..ce0861d 100644 --- a/github-markdown-light.css +++ b/github-markdown-light.css @@ -3,15 +3,13 @@ color-scheme: light; -ms-text-size-adjust: 100%; -webkit-text-size-adjust: 100%; + margin: 0; color: #1f2328; background-color: #ffffff; font-family: -apple-system,BlinkMacSystemFont,"Segoe UI","Noto Sans",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"; font-size: 16px; - word-wrap: break-word; - margin: 0; - min-height: 100vh; line-height: 1.5; - scroll-behavior: smooth; + word-wrap: break-word; } .markdown-body .octicon { @@ -134,12 +132,12 @@ } .markdown-body input { + font: inherit; margin: 0; overflow: visible; font-family: inherit; font-size: inherit; line-height: inherit; - font: inherit; } .markdown-body [type=button], @@ -1101,31 +1099,7 @@ margin-top: 0 !important; } -.markdown-body ul[role='list'], -.markdown-body ol[role='list'] { - list-style: none; -} - -.markdown-body html[focus-within] { - scroll-behavior: smooth; -} - -.markdown-body html:focus-within { - scroll-behavior: smooth; -} - -.markdown-body a:not([class]) { - -webkit-text-decoration-skip: ink; - text-decoration-skip-ink: auto; -} - -.markdown-body img, -.markdown-body picture { - max-width: 100%; - display: block; -} - -.markdown-body [class^=Primer_Brand__Link-module__Link___]::after { - width: calc(100% - 20px); +.markdown-body .highlight pre:has(+.zeroclipboard-container) { + min-height: 52px; } diff --git a/github-markdown.css b/github-markdown.css index 257b921..bc8e12b 100644 --- a/github-markdown.css +++ b/github-markdown.css @@ -126,15 +126,13 @@ .markdown-body { -ms-text-size-adjust: 100%; -webkit-text-size-adjust: 100%; + margin: 0; color: var(--fgColor-default); background-color: var(--bgColor-default); font-family: -apple-system,BlinkMacSystemFont,"Segoe UI","Noto Sans",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"; font-size: 16px; - word-wrap: break-word; - margin: 0; - min-height: 100vh; line-height: 1.5; - scroll-behavior: smooth; + word-wrap: break-word; } .markdown-body .octicon { @@ -257,12 +255,12 @@ } .markdown-body input { + font: inherit; margin: 0; overflow: visible; font-family: inherit; font-size: inherit; line-height: inherit; - font: inherit; } .markdown-body [type=button], @@ -1224,31 +1222,7 @@ margin-top: 0 !important; } -.markdown-body ul[role='list'], -.markdown-body ol[role='list'] { - list-style: none; -} - -.markdown-body html[focus-within] { - scroll-behavior: smooth; -} - -.markdown-body html:focus-within { - scroll-behavior: smooth; -} - -.markdown-body a:not([class]) { - -webkit-text-decoration-skip: ink; - text-decoration-skip-ink: auto; -} - -.markdown-body img, -.markdown-body picture { - max-width: 100%; - display: block; -} - -.markdown-body [class^=Primer_Brand__Link-module__Link___]::after { - width: calc(100% - 20px); +.markdown-body .highlight pre:has(+.zeroclipboard-container) { + min-height: 52px; } diff --git a/package.json b/package.json index f91fa99..3b207a1 100644 --- a/package.json +++ b/package.json @@ -35,6 +35,6 @@ "stylesheet" ], "devDependencies": { - "generate-github-markdown-css": "^6.5.0" + "generate-github-markdown-css": "^6.5.1" } } From e771b613e93f868afd7ce2cdba2a2c7b6c649416 Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Thu, 28 Nov 2024 15:43:27 +0700 Subject: [PATCH 18/19] 5.8.1 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 3b207a1..67150e3 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "github-markdown-css", - "version": "5.8.0", + "version": "5.8.1", "description": "The minimal amount of CSS to replicate the GitHub Markdown style", "license": "MIT", "repository": "sindresorhus/github-markdown-css", From bedb4b771f5fa1ae117df597c79993fd1eb4dff0 Mon Sep 17 00:00:00 2001 From: slydor Date: Fri, 20 Dec 2024 16:16:57 +0100 Subject: [PATCH 19/19] Add hint to avoid browser quirks mode (#117) --- readme.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/readme.md b/readme.md index 486d8d9..abff134 100644 --- a/readme.md +++ b/readme.md @@ -58,6 +58,17 @@ You may know that now GitHub supports more than 2 themes including `dark_dimmed` See [`generate-github-markdown-css`](https://github.com/sindresorhus/generate-github-markdown-css) for how it's generated and ability to generate your own. +## Troubleshooting + +If you encounter styling issues, like tables in dark mode rendering their fonts in black, the browser might uses [quirks mode](https://developer.mozilla.org/en-US/docs/Web/HTML/Quirks_Mode_and_Standards_Mode) by accident. + +To avoid quirks mode, always include a doctype at the top of your page. + +```html + + +``` + ## Dev Run `npm run make` to update the CSS.