Commit 79632fd
Changed files (18)
assets/blob.css
@@ -0,0 +1,53 @@
+[id] {
+ scroll-margin-top: var(--header-height);
+}
+
+pre {
+ border: 1px solid var(--c-border);
+ border-top: none;
+ border-bottom-left-radius: var(--border-radius);
+ border-bottom-right-radius: var(--border-radius);
+}
+
+pre {
+ margin: 0;
+ padding: 8px 16px;
+ overflow-x: auto;
+ white-space: pre;
+ word-spacing: normal;
+ word-break: normal;
+ word-wrap: normal;
+ tab-size: 4;
+ font-family: var(--font-family-mono), monospace;
+}
+
+pre > code {
+ display: block;
+ padding: 0 16px;
+ width: fit-content;
+ min-width: 100%;
+ line-height: var(--code-line-height);
+ font-size: var(--code-font-size);
+}
+
+.border {
+ border: 1px solid var(--c-border);
+ border-top: none;
+ border-bottom-left-radius: 6px;
+ border-bottom-right-radius: 6px;
+}
+
+.binary-file {
+ padding: 8px 16px;
+ font-style: italic;
+}
+
+.image {
+ padding: 8px 16px;
+ text-align: center;
+}
+
+.image img {
+ max-width: 100%;
+ height: auto;
+}
assets/branches.css
@@ -0,0 +1,36 @@
+.branches {
+ border: 1px solid var(--c-border);
+ border-radius: var(--border-radius);
+ overflow: hidden;
+}
+
+.branch-row {
+ display: flex;
+ align-items: center;
+ gap: 12px;
+ height: 44px;
+ padding-inline: 16px;
+ border-bottom: 1px solid var(--c-border);
+ background-color: var(--c-bg-elv);
+}
+
+.branch-row:last-child {
+ border-bottom: none;
+}
+
+.branch-row a {
+ color: var(--c-text-1);
+}
+
+.branch-row a:hover {
+ color: var(--c-brand-2);
+ text-decoration: none;
+}
+
+.badge {
+ font-size: 12px;
+ color: var(--c-text-2);
+ border: 1px solid var(--c-border);
+ padding: 2px 6px;
+ border-radius: 999px;
+}
assets/commit.css
@@ -0,0 +1,210 @@
+h1 code {
+ border-radius: var(--border-radius);
+ background: var(--c-bg-alt);
+ padding: 4px 8px;
+ font-family: var(--font-family-mono), monospace;
+ font-weight: 500;
+}
+
+.commit {
+ display: flex;
+ flex-direction: column;
+ gap: 16px;
+ margin-bottom: 16px;
+}
+
+.commit-info {
+ display: flex;
+ flex-direction: row;
+ gap: 8px;
+ align-items: flex-end;
+}
+
+.commit-author {
+ color: var(--c-text-1);
+ font-weight: 600;
+ min-width: 0;
+ overflow-wrap: break-word;
+}
+
+.commit-date {
+ color: var(--c-text-2);
+ font-size: 12px;
+ font-family: var(--font-family-mono), monospace;
+}
+
+.commit-message {
+ border: 1px solid var(--c-border);
+ border-radius: var(--border-radius);
+ padding: 16px;
+}
+
+.ref-badges {
+ display: inline-flex;
+ gap: 6px;
+ margin-left: 8px;
+}
+
+.badge {
+ font-size: 12px;
+ color: var(--c-text-2);
+ border: 1px solid var(--c-border);
+ padding: 2px 6px;
+ border-radius: 999px;
+ white-space: nowrap;
+}
+
+.commit-subject {
+ font-size: 16px;
+ font-weight: 600;
+ line-height: 1.3;
+ hyphens: auto;
+}
+
+.commit-body {
+ margin-top: 16px;
+ white-space: pre-wrap;
+ line-height: 1.5;
+ hyphens: auto;
+}
+
+.commit-subinfo {
+ display: flex;
+ flex-direction: row;
+ gap: 16px;
+ justify-content: space-between;
+}
+
+.commit-layout {
+ display: grid;
+ grid-template-columns: 1fr;
+ gap: 16px;
+}
+
+@media (min-width: 960px) {
+ .commit-layout {
+ grid-template-columns: 300px 1fr;
+ align-items: start;
+ }
+
+ .files-tree {
+ position: sticky;
+ top: 16px;
+ }
+
+ .files-tree-content {
+ max-height: calc(100vh - var(--header-height) - 40px);
+ overflow: auto;
+ }
+}
+
+.files-tree {
+ border: 1px solid var(--c-border);
+ border-radius: var(--border-radius);
+}
+
+.files-tree-header {
+ display: flex;
+ flex-direction: row;
+ align-items: center;
+ padding-inline: 16px;
+ height: var(--header-height);
+ border-bottom: 1px solid var(--c-border);
+ border-top-left-radius: var(--border-radius);
+ border-top-right-radius: var(--border-radius);
+ background: var(--c-bg-alt);
+ font-size: 14px;
+ font-weight: 600;
+}
+
+.files-tree-content {
+ display: block;
+ padding-block: 6px;
+}
+
+.tree .children {
+ margin-left: 16px;
+ border-left: 1px dashed var(--c-border);
+}
+
+.tree .node {
+ display: flex;
+ align-items: center;
+ gap: 8px;
+ padding: 10px 16px;
+}
+
+.tree .file-name {
+ flex: 1;
+ font-weight: 500;
+ color: var(--c-text-1);
+ cursor: pointer;
+}
+
+.tree .file-name:hover {
+ color: var(--c-brand-2);
+ text-decoration: underline;
+}
+
+.tree .dir {
+ color: var(--c-dir);
+}
+
+.tree .file-added {
+ color: var(--c-green);
+}
+
+.tree .file-deleted {
+ color: var(--c-red);
+}
+
+.tree .file-renamed {
+ color: var(--c-yellow);
+}
+
+/* Per-file sections */
+.files {
+ min-width: 0;
+}
+
+.file-section + .file-section {
+ margin-top: 16px;
+}
+
+pre {
+ border: 1px solid var(--c-border);
+ border-top: none;
+ border-bottom-left-radius: var(--border-radius);
+ border-bottom-right-radius: var(--border-radius);
+
+ margin: 0;
+ padding: 8px 16px;
+ overflow-x: auto;
+ white-space: pre;
+ word-spacing: normal;
+ word-break: normal;
+ word-wrap: normal;
+ tab-size: 4;
+ font-family: var(--font-family-mono), monospace;
+}
+
+pre > code {
+ display: block;
+ padding: 0 16px;
+ width: fit-content;
+ min-width: 100%;
+ line-height: var(--code-line-height);
+ font-size: var(--code-font-size);
+}
+
+.binary-file {
+ padding: 8px 16px;
+ font-style: italic;
+}
+
+.border {
+ border: 1px solid var(--c-border);
+ border-top: none;
+ border-bottom-left-radius: 6px;
+ border-bottom-right-radius: 6px;
+}
assets/commits_list.css
@@ -0,0 +1,142 @@
+.commits {
+ border: 1px solid var(--c-border);
+ border-top: none;
+ border-bottom-left-radius: var(--border-radius);
+ border-bottom-right-radius: var(--border-radius);
+ overflow-x: auto;
+}
+
+.row {
+ display: flex;
+ height: 40px;
+ border-bottom: 1px solid var(--c-border);
+ padding-inline: 16px;
+ gap: 16px;
+}
+
+.row:last-child {
+ border-bottom: none;
+}
+
+.row:hover {
+ background-color: var(--c-bg-alt);
+}
+
+.cell {
+ display: flex;
+ gap: 8px;
+ align-items: center;
+}
+
+.hash a {
+ font-family: var(--font-family-mono), monospace;
+ color: var(--c-text-2);
+}
+
+.commit-title {
+ flex: 1;
+}
+
+.commit-title a {
+ color: var(--c-text-1);
+ line-height: 1.5;
+}
+
+.commit-title a:hover {
+ color: var(--c-brand-2);
+}
+
+.ref-badges {
+ display: inline-flex;
+ gap: 6px;
+ margin-left: 8px;
+}
+
+.badge {
+ font-size: 12px;
+ color: var(--c-text-2);
+ border: 1px solid var(--c-border);
+ padding: 2px 6px;
+ border-radius: 999px;
+ white-space: nowrap;
+}
+
+.date {
+ font-family: var(--font-family-mono), monospace;
+ font-size: 12px;
+ color: var(--c-text-2);
+}
+
+.pagination {
+ display: flex;
+ gap: 8px;
+ align-items: center;
+ justify-content: center;
+ margin-top: 12px;
+ padding: 8px 0;
+ color: var(--c-text-2);
+}
+
+.pagination a,
+.pagination span.btn {
+ display: inline-flex;
+ align-items: center;
+ gap: 6px;
+ padding: 6px 10px;
+ border: 1px solid var(--c-border);
+ border-radius: 6px;
+ background: var(--c-bg-elv);
+ color: var(--c-text-1);
+ text-decoration: none;
+ font-size: 13px;
+}
+
+.pagination a:hover {
+ color: var(--c-brand-2);
+ border-color: var(--c-brand-2);
+}
+
+.pagination .disabled {
+ opacity: 0.5;
+ pointer-events: none;
+}
+
+.pagination .page-indicator {
+ margin: 0 4px;
+ font-size: 13px;
+ color: var(--c-text-2);
+}
+
+/* Mobile optimizations */
+@media (max-width: 767px) {
+ .row {
+ height: auto;
+ padding: 10px 12px;
+ gap: 12px;
+ flex-wrap: wrap;
+ align-items: flex-start;
+ }
+
+ .commit-title {
+ flex-basis: 100%;
+ order: 1;
+ }
+
+ .author, .date, .hash {
+ font-size: 12px;
+ }
+
+ .author {
+ color: var(--c-text-2);
+ order: 2;
+ }
+
+ .date {
+ order: 2;
+ }
+
+ .hash {
+ margin-left: auto;
+ order: 3;
+ }
+}
assets/layout.css
@@ -0,0 +1,287 @@
+:root {
+ color-scheme: light dark;
+ --c-indigo-1: light-dark(#3451b2, #a8b1ff);
+ --c-indigo-2: light-dark(#3a5ccc, #5c73e7);
+ --c-indigo-3: light-dark(#5672cd, #3e63dd);
+ --c-green: light-dark(#1a7f37, #57ab5a);
+ --c-red: light-dark(#c53030, #e5534b);
+ --c-yellow: light-dark(#9a6700, #c69026);
+ --c-dir: light-dark(#54aeff, #9198a1);
+ --c-gray-soft: light-dark(rgba(142, 150, 170, .14), rgba(101, 117, 133, .16));
+ --c-bg: light-dark(#ffffff, #1b1b1f);
+ --c-bg-alt: light-dark(#f6f6f7, #161618);
+ --c-bg-elv: light-dark(#ffffff, #202127);
+ --c-text-1: light-dark(rgba(60, 60, 67), rgba(255, 255, 245, .86));
+ --c-text-2: light-dark(rgba(60, 60, 67, .78), rgba(235, 235, 245, .6));
+ --c-text-3: light-dark(rgba(60, 60, 67, .56), rgba(235, 235, 245, .38));
+ --c-border: light-dark(#c2c2c4, #3c3f44);
+ --c-divider: light-dark(#e2e2e3, #2e2e32);
+
+ --c-brand-1: var(--c-indigo-1);
+ --c-brand-2: var(--c-indigo-2);
+ --c-brand-3: var(--c-indigo-3);
+ --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
+ --font-family-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
+ --code-line-height: 20px;
+ --code-font-size: 12px;
+ --code-color: var(--c-brand-1);
+ --code-bg: var(--c-gray-soft);
+ --code-block-bg: var(--c-bg-alt);
+ --code-block-color: var(--c-text-1);
+ --header-height: 46px;
+ --border-radius: 6px;
+ --max-content-width: 1470px;
+}
+
+* {
+ box-sizing: border-box;
+}
+
+body {
+ margin: 0;
+ padding: 0;
+ font-family: var(--font-family), sans-serif;
+ font-size: 14px;
+ line-height: 1;
+ color: var(--c-text-1);
+ background-color: var(--c-bg);
+ text-rendering: optimizeLegibility;
+ -webkit-font-smoothing: antialiased;
+ -moz-osx-font-smoothing: grayscale;
+ -moz-text-size-adjust: none;
+ -webkit-text-size-adjust: none;
+ text-size-adjust: none;
+ min-height: 100vh;
+ display: flex;
+ flex-direction: column;
+}
+
+.nowrap {
+ white-space: nowrap;
+}
+
+h1 {
+ margin-inline: 0;
+ margin-block: 16px;
+ font-size: 20px;
+ font-weight: 600;
+}
+
+a {
+ color: var(--c-brand-1);
+ font-weight: 500;
+ text-decoration: underline;
+ text-underline-offset: 2px;
+ text-decoration: inherit;
+ touch-action: manipulation;
+}
+
+a:hover {
+ color: var(--c-brand-2);
+ text-decoration: underline;
+}
+
+.menu {
+ background-color: var(--c-bg-alt);
+ border-bottom: 1px solid var(--c-divider);
+ overflow-x: auto;
+}
+
+.menu-content {
+ display: flex;
+ flex-direction: row;
+ align-items: center;
+ gap: 16px;
+ padding-inline: 16px;
+ max-width: var(--max-content-width);
+ margin-inline: auto;
+}
+
+.menu-item {
+ display: flex;
+ align-items: center;
+ border-bottom: 2px solid transparent;
+ height: 56px;
+ padding-inline: 8px;
+}
+
+.menu-item a {
+ display: flex;
+ flex-direction: row;
+ gap: 8px;
+ align-items: center;
+ color: var(--c-text-1);
+ padding: 8px 10px;
+ border-radius: 4px;
+}
+
+.menu-item a:hover {
+ background-color: var(--c-bg-elv);
+ text-decoration: none;
+}
+
+.menu-item.selected {
+ border-bottom-color: var(--c-brand-1);
+}
+
+.project-name {
+ font-weight: 600;
+ font-size: 16px;
+ margin-inline: 16px;
+ color: var(--c-text-1);
+ text-decoration: none;
+}
+
+main {
+ flex-grow: 1;
+ width: 100%;
+ max-width: var(--max-content-width);
+ margin: 16px auto;
+}
+
+.main-content {
+ padding-inline: 16px;
+}
+
+footer {
+ padding: 12px 16px;
+ background-color: var(--c-bg-alt);
+ border-top: 1px solid var(--c-divider);
+ color: var(--c-text-3);
+ font-size: 12px;
+ text-align: center;
+}
+
+.header-container {
+ container-type: scroll-state;
+ position: sticky;
+ top: 0;
+}
+
+.header-container {
+ @container scroll-state(stuck: top) {
+ header {
+ border-top: none;
+ border-top-left-radius: 0;
+ border-top-right-radius: 0;
+ }
+
+ .goto-top {
+ display: flex;
+ }
+ }
+}
+
+header {
+ display: flex;
+ flex-direction: row;
+ align-items: center;
+ min-height: var(--header-height);
+ padding-inline: 16px;
+ background: var(--c-bg-alt);
+ border: 1px solid var(--c-border);
+ border-top-left-radius: var(--border-radius);
+ border-top-right-radius: var(--border-radius);
+}
+
+header h1 {
+ word-break: break-all;
+ font-weight: 600;
+ font-size: 16px;
+ margin: 0;
+ padding: 0;
+}
+
+.header-ref {
+ color: var(--c-text-2);
+ border: 1px solid var(--c-border);
+ border-radius: 6px;
+ padding: 6px 10px;
+ margin-right: 10px;
+ margin-left: -6px;
+}
+
+header .path {
+ font-size: 16px;
+}
+
+.breadcrumbs {
+ display: flex;
+ flex-direction: row;
+ flex-wrap: wrap;
+ gap: 6px;
+ font-size: 16px;
+}
+
+.breadcrumbs a {
+ word-break: break-all;
+}
+
+.goto-top {
+ display: none;
+ margin-left: auto;
+ padding: 6px 10px;
+ background: none;
+ border: none;
+ border-radius: 6px;
+ gap: 4px;
+ align-items: center;
+ color: var(--c-text-1);
+ cursor: pointer;
+}
+
+.goto-top:hover {
+ background: var(--c-bg-elv);
+}
+
+.raw-actions {
+ display: flex;
+ margin-left: auto;
+ gap: 2px;
+ align-items: center;
+}
+
+.raw-btn {
+ display: flex;
+ padding: 6px 10px;
+ background: none;
+ border: none;
+ border-radius: 6px;
+ align-items: center;
+ color: var(--c-text-1);
+ cursor: pointer;
+ font-size: 14px;
+ font-family: inherit;
+ text-decoration: none;
+}
+
+.raw-btn:hover {
+ background: var(--c-bg-elv);
+ color: var(--c-text-1);
+ text-decoration: none;
+}
+
+.has-tooltip {
+ position: relative;
+}
+
+.tooltip {
+ display: none;
+ position: absolute;
+ bottom: calc(100% + 6px);
+ left: 50%;
+ transform: translateX(-50%);
+ padding: 4px 8px;
+ background: var(--c-bg-elv);
+ border: 1px solid var(--c-border);
+ border-radius: 4px;
+ font-size: 12px;
+ white-space: nowrap;
+ color: var(--c-text-1);
+ pointer-events: none;
+}
+
+.has-tooltip:hover .tooltip,
+.has-tooltip.copied .tooltip {
+ display: block;
+}
assets/list.css
@@ -0,0 +1,80 @@
+.files {
+ border: 1px solid var(--c-border);
+ border-top: none;
+ width: 100%;
+ border-bottom-left-radius: var(--border-radius);
+ border-bottom-right-radius: var(--border-radius);
+ overflow-x: auto;
+}
+
+.files .dir {
+ color: var(--c-dir);
+}
+
+.files a {
+ color: var(--c-text-1);
+}
+
+.files a:hover {
+ color: var(--c-brand-2);
+}
+
+.row {
+ display: flex;
+ height: 40px;
+ border-bottom: 1px solid var(--c-border);
+ padding-inline: 16px;
+ gap: 16px;
+}
+
+.row:last-child {
+ border-bottom: none;
+}
+
+.row:hover {
+ background-color: var(--c-bg-alt);
+}
+
+.cell {
+ flex: 1;
+ display: flex;
+ gap: 8px;
+ align-items: center;
+ white-space: nowrap;
+}
+
+.cell:not(:first-child) {
+ justify-content: flex-end;
+ max-width: 100px;
+}
+
+@media (max-width: 767px) {
+ .file-mode {
+ display: none;
+ }
+}
+
+.markdown-container.readme {
+ padding-inline: 16px;
+ border: 1px solid var(--c-divider);
+ border-radius: 8px;
+ overflow-x: auto;
+ margin-top: 16px;
+}
+
+.markdown-body.readme {
+ width: 100%;
+ min-width: 200px;
+ max-width: 980px;
+ margin: 0 auto;
+ padding: 32px;
+ word-wrap: break-word;
+ font-size: 16px;
+ line-height: 1.5;
+}
+
+@media (max-width: 767px) {
+ .markdown-body.readme {
+ padding: 16px;
+ }
+}
assets/markdown.css
@@ -1,935 +1,28 @@
-:root {
- color-scheme: light dark;
- --borderColor-default: light-dark(#d1d9e0, #3d444d);
- --borderColor-muted: light-dark(#d1d9e0b3, #3d444db3);
- --borderColor-neutral-muted: var(--borderColor-muted);
- --bgColor-attention-muted: light-dark(#fff8c5, #bb800926);
- --bgColor-default: light-dark(#ffffff, #0d1117);
- --bgColor-muted: light-dark(#f6f8fa, #151b23);
- --bgColor-neutral-muted: light-dark(#818b981f, #656c7633);
- --fgColor-danger: light-dark(#d1242f, #f85149);
- --fgColor-default: light-dark(#1f2328, #f0f6fc);
- --fgColor-muted: light-dark(#59636e, #9198a1);
- --focus-outlineColor: light-dark(#0969da, #1f6feb);
- --fgColor-accent: light-dark(#0969da, #4493f8);
- --fgColor-attention: light-dark(#9a6700, #d29922);
- --fgColor-done: light-dark(#8250df, #ab7df8);
- --fgColor-success: light-dark(#1a7f37, #3fb950);
- --borderColor-accent-emphasis: light-dark(#0969da, #1f6feb);
- --borderColor-attention-emphasis: light-dark(#9a6700, #9e6a03);
- --borderColor-danger-emphasis: light-dark(#cf222e, #da3633);
- --borderColor-done-emphasis: light-dark(#8250df, #8957e5);
- --borderColor-success-emphasis: light-dark(#1a7f37, #238636);
+[id] {
+ scroll-margin-top: var(--header-height);
}
-.markdown-body details,
-.markdown-body figcaption,
-.markdown-body figure {
- display: block;
+.markdown-container {
+ border: 1px solid var(--c-divider);
+ border-top: none;
+ border-bottom-left-radius: 8px;
+ border-bottom-right-radius: 8px;
+ overflow-x: auto;
}
-.markdown-body summary {
- display: list-item;
+.markdown-body {
+ width: 100%;
+ min-width: 200px;
+ max-width: 980px;
+ margin: 0 auto;
+ padding: 32px;
+ word-wrap: break-word;
+ font-size: 16px;
+ line-height: 1.5;
}
-.markdown-body [hidden] {
- display: none !important;
-}
-
-.markdown-body a {
- background-color: transparent;
- text-decoration: none;
-}
-
-.markdown-body abbr[title] {
- border-bottom: none;
- text-decoration: underline dotted;
-}
-
-.markdown-body b,
-.markdown-body strong {
- font-weight: 600;
-}
-
-.markdown-body dfn {
- font-style: italic;
-}
-
-.markdown-body h1 {
- margin: .67em 0;
- font-weight: 600;
- padding-bottom: .3em;
- font-size: 2em;
- border-bottom: 1px solid var(--borderColor-muted);
-}
-
-.markdown-body mark {
- background-color: var(--bgColor-attention-muted);
- color: var(--fgColor-default);
-}
-
-.markdown-body small {
- font-size: 90%;
-}
-
-.markdown-body sub,
-.markdown-body sup {
- font-size: 75%;
- line-height: 0;
- position: relative;
- vertical-align: baseline;
-}
-
-.markdown-body sub {
- bottom: -0.25em;
-}
-
-.markdown-body sup {
- top: -0.5em;
-}
-
-.markdown-body img {
- border-style: none;
- max-width: 100%;
- box-sizing: content-box;
-}
-
-.markdown-body code,
-.markdown-body kbd,
-.markdown-body pre,
-.markdown-body samp {
- font-family: monospace;
- font-size: 1em;
-}
-
-.markdown-body figure {
- margin: 1em 2.5rem;
-}
-
-.markdown-body hr {
- box-sizing: content-box;
- overflow: hidden;
- border-bottom: 1px solid var(--borderColor-muted);
- height: .25em;
- padding: 0;
- margin: 1.5rem 0;
- background-color: var(--borderColor-default);
-}
-
-.markdown-body input {
- font: inherit;
- margin: 0;
- overflow: visible;
- line-height: inherit;
-}
-
-.markdown-body [type=button],
-.markdown-body [type=reset],
-.markdown-body [type=submit] {
- -webkit-appearance: button;
- appearance: button;
-}
-
-.markdown-body [type=checkbox],
-.markdown-body [type=radio] {
- box-sizing: border-box;
- padding: 0;
-}
-
-.markdown-body [type=number]::-webkit-inner-spin-button,
-.markdown-body [type=number]::-webkit-outer-spin-button {
- height: auto;
-}
-
-.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 {
- color: inherit;
- opacity: .54;
-}
-
-.markdown-body ::-webkit-file-upload-button {
- -webkit-appearance: button;
- appearance: button;
- font: inherit;
-}
-
-.markdown-body a:hover {
- text-decoration: underline;
-}
-
-.markdown-body ::placeholder {
- color: var(--fgColor-muted);
- opacity: 1;
-}
-
-.markdown-body hr::before {
- display: table;
- content: "";
-}
-
-.markdown-body hr::after {
- display: table;
- clear: both;
- content: "";
-}
-
-.markdown-body table {
- border-spacing: 0;
- border-collapse: collapse;
- display: block;
- width: max-content;
- max-width: 100%;
- overflow: auto;
- font-variant: tabular-nums;
-}
-
-.markdown-body td,
-.markdown-body th {
- padding: 0;
-}
-
-.markdown-body details summary {
- cursor: pointer;
-}
-
-.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(--focus-outlineColor);
- outline-offset: -2px;
- box-shadow: none;
-}
-
-.markdown-body a:focus:not(:focus-visible),
-.markdown-body [role=button]:focus:not(:focus-visible),
-.markdown-body input[type=radio]:focus:not(:focus-visible),
-.markdown-body input[type=checkbox]:focus:not(:focus-visible) {
- outline: solid 1px transparent;
-}
-
-.markdown-body a:focus-visible,
-.markdown-body [role=button]:focus-visible,
-.markdown-body input[type=radio]:focus-visible,
-.markdown-body input[type=checkbox]:focus-visible {
- outline: 2px solid var(--focus-outlineColor);
- outline-offset: -2px;
- box-shadow: none;
-}
-
-.markdown-body a:not([class]):focus,
-.markdown-body a:not([class]):focus-visible,
-.markdown-body input[type=radio]:focus,
-.markdown-body input[type=radio]:focus-visible,
-.markdown-body input[type=checkbox]:focus,
-.markdown-body input[type=checkbox]:focus-visible {
- outline-offset: 0;
-}
-
-.markdown-body kbd {
- display: inline-block;
- padding: 0.25rem;
- font: 11px ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace;
- line-height: 10px;
- color: var(--fgColor-default);
- vertical-align: middle;
- 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(--borderColor-neutral-muted);
-}
-
-.markdown-body h1,
-.markdown-body h2,
-.markdown-body h3,
-.markdown-body h4,
-.markdown-body h5,
-.markdown-body h6 {
- margin-top: 1.5rem;
- margin-bottom: 1rem;
- font-weight: 600;
- line-height: 1.25;
-}
-
-.markdown-body h2 {
- font-weight: 600;
- padding-bottom: .3em;
- font-size: 1.5em;
- border-bottom: 1px solid var(--borderColor-muted);
-}
-
-.markdown-body h3 {
- font-weight: 600;
- font-size: 1.25em;
-}
-
-.markdown-body h4 {
- font-weight: 600;
- font-size: 1em;
-}
-
-.markdown-body h5 {
- font-weight: 600;
- font-size: .875em;
-}
-
-.markdown-body h6 {
- font-weight: 600;
- font-size: .85em;
- color: var(--fgColor-muted);
-}
-
-.markdown-body p {
- margin-top: 0;
- margin-bottom: 10px;
-}
-
-.markdown-body blockquote {
- margin: 0;
- padding: 0 1em;
- color: var(--fgColor-muted);
- border-left: .25em solid var(--borderColor-default);
-}
-
-.markdown-body ul,
-.markdown-body ol {
- margin-top: 0;
- margin-bottom: 0;
- padding-left: 2em;
-}
-
-.markdown-body ol ol,
-.markdown-body ul ol {
- list-style-type: lower-roman;
-}
-
-.markdown-body ul ul ol,
-.markdown-body ul ol ol,
-.markdown-body ol ul ol,
-.markdown-body ol ol ol {
- list-style-type: lower-alpha;
-}
-
-.markdown-body dd {
- margin-left: 0;
-}
-
-.markdown-body tt,
-.markdown-body code,
-.markdown-body samp {
- 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-size: 12px;
- word-wrap: normal;
-}
-
-.markdown-body input::-webkit-outer-spin-button,
-.markdown-body input::-webkit-inner-spin-button {
- margin: 0;
- appearance: none;
-}
-
-.markdown-body .mr-2 {
- margin-right: 0.5rem !important;
-}
-
-.markdown-body::before {
- display: table;
- content: "";
-}
-
-.markdown-body::after {
- display: table;
- clear: both;
- content: "";
-}
-
-.markdown-body > *:first-child {
- margin-top: 0 !important;
-}
-
-.markdown-body > *:last-child {
- margin-bottom: 0 !important;
-}
-
-.markdown-body a:not([href]) {
- color: inherit;
- text-decoration: none;
-}
-
-.markdown-body .absent {
- color: var(--fgColor-danger);
-}
-
-.markdown-body .anchor {
- float: left;
- padding-right: 0.25rem;
- margin-left: -20px;
- line-height: 1;
-}
-
-.markdown-body .anchor:focus {
- outline: none;
-}
-
-.markdown-body p,
-.markdown-body blockquote,
-.markdown-body ul,
-.markdown-body ol,
-.markdown-body dl,
-.markdown-body table,
-.markdown-body pre,
-.markdown-body details {
- margin-top: 0;
- margin-bottom: 1rem;
-}
-
-.markdown-body blockquote > :first-child {
- margin-top: 0;
-}
-
-.markdown-body blockquote > :last-child {
- margin-bottom: 0;
-}
-
-.markdown-body h1:hover .anchor,
-.markdown-body h2:hover .anchor,
-.markdown-body h3:hover .anchor,
-.markdown-body h4:hover .anchor,
-.markdown-body h5:hover .anchor,
-.markdown-body h6:hover .anchor {
- text-decoration: none;
-}
-
-.markdown-body h1 tt,
-.markdown-body h1 code,
-.markdown-body h2 tt,
-.markdown-body h2 code,
-.markdown-body h3 tt,
-.markdown-body h3 code,
-.markdown-body h4 tt,
-.markdown-body h4 code,
-.markdown-body h5 tt,
-.markdown-body h5 code,
-.markdown-body h6 tt,
-.markdown-body h6 code {
- padding: 0 .2em;
- font-size: inherit;
-}
-
-.markdown-body summary h1,
-.markdown-body summary h2,
-.markdown-body summary h3,
-.markdown-body summary h4,
-.markdown-body summary h5,
-.markdown-body summary h6 {
- display: inline-block;
-}
-
-.markdown-body summary h1 .anchor,
-.markdown-body summary h2 .anchor,
-.markdown-body summary h3 .anchor,
-.markdown-body summary h4 .anchor,
-.markdown-body summary h5 .anchor,
-.markdown-body summary h6 .anchor {
- margin-left: -40px;
-}
-
-.markdown-body summary h1,
-.markdown-body summary h2 {
- padding-bottom: 0;
- border-bottom: 0;
-}
-
-.markdown-body ul.no-list,
-.markdown-body ol.no-list {
- padding: 0;
- list-style-type: none;
-}
-
-.markdown-body ol[type="a s"] {
- list-style-type: lower-alpha;
-}
-
-.markdown-body ol[type="A s"] {
- list-style-type: upper-alpha;
-}
-
-.markdown-body ol[type="i s"] {
- list-style-type: lower-roman;
-}
-
-.markdown-body ol[type="I s"] {
- list-style-type: upper-roman;
-}
-
-.markdown-body ol[type="1"] {
- list-style-type: decimal;
-}
-
-.markdown-body div > ol:not([type]) {
- list-style-type: decimal;
-}
-
-.markdown-body ul ul,
-.markdown-body ul ol,
-.markdown-body ol ol,
-.markdown-body ol ul {
- margin-top: 0;
- margin-bottom: 0;
-}
-
-.markdown-body li > p {
- margin-top: 1rem;
-}
-
-.markdown-body li + li {
- margin-top: .25em;
-}
-
-.markdown-body dl {
- padding: 0;
-}
-
-.markdown-body dl dt {
- padding: 0;
- margin-top: 1rem;
- font-size: 1em;
- font-style: italic;
- font-weight: 600;
-}
-
-.markdown-body dl dd {
- padding: 0 1rem;
- margin-bottom: 1rem;
-}
-
-.markdown-body table th {
- font-weight: 600;
-}
-
-.markdown-body table th,
-.markdown-body table td {
- padding: 6px 13px;
- border: 1px solid var(--borderColor-default);
-}
-
-.markdown-body table td > :last-child {
- margin-bottom: 0;
-}
-
-.markdown-body table tr {
- background-color: var(--bgColor-default);
- border-top: 1px solid var(--borderColor-neutral-muted);
-}
-
-.markdown-body table tr:nth-child(2n) {
- background-color: var(--bgColor-muted);
-}
-
-.markdown-body table img {
- background-color: transparent;
-}
-
-.markdown-body img[align=right] {
- padding-left: 20px;
-}
-
-.markdown-body img[align=left] {
- padding-right: 20px;
-}
-
-.markdown-body .emoji {
- max-width: none;
- vertical-align: text-top;
- background-color: transparent;
-}
-
-.markdown-body span.frame {
- display: block;
- overflow: hidden;
-}
-
-.markdown-body span.frame > span {
- display: block;
- float: left;
- width: auto;
- padding: 7px;
- margin: 13px 0 0;
- overflow: hidden;
- border: 1px solid var(--borderColor-default);
-}
-
-.markdown-body span.frame span img {
- display: block;
- float: left;
-}
-
-.markdown-body span.frame span span {
- display: block;
- padding: 5px 0 0;
- clear: both;
- color: var(--fgColor-default);
-}
-
-.markdown-body span.align-center {
- display: block;
- overflow: hidden;
- clear: both;
-}
-
-.markdown-body span.align-center > span {
- display: block;
- margin: 13px auto 0;
- overflow: hidden;
- text-align: center;
-}
-
-.markdown-body span.align-center span img {
- margin: 0 auto;
- text-align: center;
-}
-
-.markdown-body span.align-right {
- display: block;
- overflow: hidden;
- clear: both;
-}
-
-.markdown-body span.align-right > span {
- display: block;
- margin: 13px 0 0;
- overflow: hidden;
- text-align: right;
-}
-
-.markdown-body span.align-right span img {
- margin: 0;
- text-align: right;
-}
-
-.markdown-body span.float-left {
- display: block;
- float: left;
- margin-right: 13px;
- overflow: hidden;
-}
-
-.markdown-body span.float-left span {
- margin: 13px 0 0;
-}
-
-.markdown-body span.float-right {
- display: block;
- float: right;
- margin-left: 13px;
- overflow: hidden;
-}
-
-.markdown-body span.float-right > span {
- display: block;
- margin: 13px auto 0;
- overflow: hidden;
- text-align: right;
-}
-
-.markdown-body code,
-.markdown-body tt {
- padding: .2em .4em;
- margin: 0;
- font-size: 85%;
- white-space: break-spaces;
- background-color: var(--bgColor-neutral-muted);
- border-radius: 6px;
-}
-
-.markdown-body code br,
-.markdown-body tt br {
- display: none;
-}
-
-.markdown-body del code {
- text-decoration: inherit;
-}
-
-.markdown-body samp {
- font-size: 85%;
-}
-
-.markdown-body pre code {
- font-size: 100%;
-}
-
-.markdown-body pre > code {
- padding: 0;
- margin: 0;
- word-break: normal;
- white-space: pre;
- background: transparent;
- border: 0;
-}
-
-.markdown-body .highlight {
- margin-bottom: 1rem;
-}
-
-.markdown-body .highlight pre {
- margin-bottom: 0;
- word-break: normal;
-}
-
-.markdown-body .highlight pre,
-.markdown-body pre {
- padding: 1rem;
- overflow: auto;
- font-size: 85%;
- line-height: 1.45;
- color: var(--fgColor-default);
- background-color: var(--bgColor-muted);
- border-radius: 6px;
-}
-
-.markdown-body pre code,
-.markdown-body pre tt {
- display: inline;
- padding: 0;
- margin: 0;
- overflow: visible;
- line-height: inherit;
- word-wrap: normal;
- background-color: transparent;
- border: 0;
-}
-
-.markdown-body .csv-data td,
-.markdown-body .csv-data th {
- padding: 5px;
- overflow: hidden;
- font-size: 12px;
- line-height: 1;
- text-align: left;
- white-space: nowrap;
-}
-
-.markdown-body .csv-data .blob-num {
- padding: 10px 0.5rem 9px;
- text-align: right;
- background: var(--bgColor-default);
- border: 0;
-}
-
-.markdown-body .csv-data tr {
- border-top: 0;
-}
-
-.markdown-body .csv-data th {
- font-weight: 600;
- background: var(--bgColor-muted);
- border-top: 0;
-}
-
-.markdown-body [data-footnote-ref]::before {
- content: "[";
-}
-
-.markdown-body [data-footnote-ref]::after {
- content: "]";
-}
-
-.markdown-body .footnotes {
- font-size: 12px;
- color: var(--fgColor-muted);
- border-top: 1px solid var(--borderColor-default);
-}
-
-.markdown-body .footnotes ol {
- padding-left: 1rem;
-}
-
-.markdown-body .footnotes ol ul {
- display: inline-block;
- padding-left: 1rem;
- margin-top: 1rem;
-}
-
-.markdown-body .footnotes li {
- position: relative;
-}
-
-.markdown-body .footnotes li:target::before {
- position: absolute;
- 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 var(--focus-outlineColor);
- border-radius: 6px;
-}
-
-.markdown-body .footnotes li:target {
- color: var(--fgColor-default);
-}
-
-.markdown-body .footnotes .data-footnote-backref g-emoji {
- font-family: monospace;
-}
-
-.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;
- font-family: "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
- font-size: 1em;
- font-style: normal !important;
- font-weight: 400;
- line-height: 1;
- vertical-align: -0.075em;
-}
-
-.markdown-body g-emoji img {
- width: 1em;
- height: 1em;
-}
-
-.markdown-body .task-list-item {
- list-style-type: none;
-}
-
-.markdown-body .task-list-item label {
- font-weight: 400;
-}
-
-.markdown-body .task-list-item.enabled label {
- cursor: pointer;
-}
-
-.markdown-body .task-list-item + .task-list-item {
- margin-top: 0.25rem;
-}
-
-.markdown-body .task-list-item .handle {
- display: none;
-}
-
-.markdown-body .task-list-item-checkbox {
- margin: 0 .2em .25em -1.4em;
- vertical-align: middle;
-}
-
-.markdown-body ul:dir(rtl) .task-list-item-checkbox {
- margin: 0 -1.6em .25em .2em;
-}
-
-.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,
-.markdown-body .contains-task-list:focus-within .task-list-item-convert-container {
- display: block;
- width: auto;
- height: 24px;
- overflow: visible;
- clip: auto;
-}
-
-.markdown-body ::-webkit-calendar-picker-indicator {
- filter: invert(50%);
-}
-
-.markdown-body .markdown-alert {
- padding: 0.5rem 1rem;
- margin-bottom: 1rem;
- color: inherit;
- border-left: .25em solid var(--borderColor-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-title {
- display: flex;
- font-weight: 500;
- align-items: center;
- line-height: 1;
-}
-
-.markdown-body .markdown-alert.markdown-alert-note {
- border-left-color: var(--borderColor-accent-emphasis);
-}
-
-.markdown-body .markdown-alert.markdown-alert-note .markdown-alert-title {
- color: var(--fgColor-accent);
-}
-
-.markdown-body .markdown-alert.markdown-alert-important {
- border-left-color: var(--borderColor-done-emphasis);
-}
-
-.markdown-body .markdown-alert.markdown-alert-important .markdown-alert-title {
- color: var(--fgColor-done);
-}
-
-.markdown-body .markdown-alert.markdown-alert-warning {
- border-left-color: var(--borderColor-attention-emphasis);
-}
-
-.markdown-body .markdown-alert.markdown-alert-warning .markdown-alert-title {
- color: var(--fgColor-attention);
-}
-
-.markdown-body .markdown-alert.markdown-alert-tip {
- border-left-color: var(--borderColor-success-emphasis);
-}
-
-.markdown-body .markdown-alert.markdown-alert-tip .markdown-alert-title {
- color: var(--fgColor-success);
-}
-
-.markdown-body .markdown-alert.markdown-alert-caution {
- border-left-color: var(--borderColor-danger-emphasis);
-}
-
-.markdown-body .markdown-alert.markdown-alert-caution .markdown-alert-title {
- color: var(--fgColor-danger);
-}
-
-.markdown-body > *:first-child > .heading-element:first-child {
- margin-top: 0 !important;
-}
-
-.markdown-body .highlight pre:has(+.zeroclipboard-container) {
- min-height: 52px;
+@media (max-width: 767px) {
+ .markdown-body {
+ padding: 16px;
+ }
}
assets/markdownBody.css
@@ -0,0 +1,935 @@
+:root {
+ color-scheme: light dark;
+ --borderColor-default: light-dark(#d1d9e0, #3d444d);
+ --borderColor-muted: light-dark(#d1d9e0b3, #3d444db3);
+ --borderColor-neutral-muted: var(--borderColor-muted);
+ --bgColor-attention-muted: light-dark(#fff8c5, #bb800926);
+ --bgColor-default: light-dark(#ffffff, #0d1117);
+ --bgColor-muted: light-dark(#f6f8fa, #151b23);
+ --bgColor-neutral-muted: light-dark(#818b981f, #656c7633);
+ --fgColor-danger: light-dark(#d1242f, #f85149);
+ --fgColor-default: light-dark(#1f2328, #f0f6fc);
+ --fgColor-muted: light-dark(#59636e, #9198a1);
+ --focus-outlineColor: light-dark(#0969da, #1f6feb);
+ --fgColor-accent: light-dark(#0969da, #4493f8);
+ --fgColor-attention: light-dark(#9a6700, #d29922);
+ --fgColor-done: light-dark(#8250df, #ab7df8);
+ --fgColor-success: light-dark(#1a7f37, #3fb950);
+ --borderColor-accent-emphasis: light-dark(#0969da, #1f6feb);
+ --borderColor-attention-emphasis: light-dark(#9a6700, #9e6a03);
+ --borderColor-danger-emphasis: light-dark(#cf222e, #da3633);
+ --borderColor-done-emphasis: light-dark(#8250df, #8957e5);
+ --borderColor-success-emphasis: light-dark(#1a7f37, #238636);
+}
+
+.markdown-body details,
+.markdown-body figcaption,
+.markdown-body figure {
+ display: block;
+}
+
+.markdown-body summary {
+ display: list-item;
+}
+
+.markdown-body [hidden] {
+ display: none !important;
+}
+
+.markdown-body a {
+ background-color: transparent;
+ text-decoration: none;
+}
+
+.markdown-body abbr[title] {
+ border-bottom: none;
+ text-decoration: underline dotted;
+}
+
+.markdown-body b,
+.markdown-body strong {
+ font-weight: 600;
+}
+
+.markdown-body dfn {
+ font-style: italic;
+}
+
+.markdown-body h1 {
+ margin: .67em 0;
+ font-weight: 600;
+ padding-bottom: .3em;
+ font-size: 2em;
+ border-bottom: 1px solid var(--borderColor-muted);
+}
+
+.markdown-body mark {
+ background-color: var(--bgColor-attention-muted);
+ color: var(--fgColor-default);
+}
+
+.markdown-body small {
+ font-size: 90%;
+}
+
+.markdown-body sub,
+.markdown-body sup {
+ font-size: 75%;
+ line-height: 0;
+ position: relative;
+ vertical-align: baseline;
+}
+
+.markdown-body sub {
+ bottom: -0.25em;
+}
+
+.markdown-body sup {
+ top: -0.5em;
+}
+
+.markdown-body img {
+ border-style: none;
+ max-width: 100%;
+ box-sizing: content-box;
+}
+
+.markdown-body code,
+.markdown-body kbd,
+.markdown-body pre,
+.markdown-body samp {
+ font-family: monospace;
+ font-size: 1em;
+}
+
+.markdown-body figure {
+ margin: 1em 2.5rem;
+}
+
+.markdown-body hr {
+ box-sizing: content-box;
+ overflow: hidden;
+ border-bottom: 1px solid var(--borderColor-muted);
+ height: .25em;
+ padding: 0;
+ margin: 1.5rem 0;
+ background-color: var(--borderColor-default);
+}
+
+.markdown-body input {
+ font: inherit;
+ margin: 0;
+ overflow: visible;
+ line-height: inherit;
+}
+
+.markdown-body [type=button],
+.markdown-body [type=reset],
+.markdown-body [type=submit] {
+ -webkit-appearance: button;
+ appearance: button;
+}
+
+.markdown-body [type=checkbox],
+.markdown-body [type=radio] {
+ box-sizing: border-box;
+ padding: 0;
+}
+
+.markdown-body [type=number]::-webkit-inner-spin-button,
+.markdown-body [type=number]::-webkit-outer-spin-button {
+ height: auto;
+}
+
+.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 {
+ color: inherit;
+ opacity: .54;
+}
+
+.markdown-body ::-webkit-file-upload-button {
+ -webkit-appearance: button;
+ appearance: button;
+ font: inherit;
+}
+
+.markdown-body a:hover {
+ text-decoration: underline;
+}
+
+.markdown-body ::placeholder {
+ color: var(--fgColor-muted);
+ opacity: 1;
+}
+
+.markdown-body hr::before {
+ display: table;
+ content: "";
+}
+
+.markdown-body hr::after {
+ display: table;
+ clear: both;
+ content: "";
+}
+
+.markdown-body table {
+ border-spacing: 0;
+ border-collapse: collapse;
+ display: block;
+ width: max-content;
+ max-width: 100%;
+ overflow: auto;
+ font-variant: tabular-nums;
+}
+
+.markdown-body td,
+.markdown-body th {
+ padding: 0;
+}
+
+.markdown-body details summary {
+ cursor: pointer;
+}
+
+.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(--focus-outlineColor);
+ outline-offset: -2px;
+ box-shadow: none;
+}
+
+.markdown-body a:focus:not(:focus-visible),
+.markdown-body [role=button]:focus:not(:focus-visible),
+.markdown-body input[type=radio]:focus:not(:focus-visible),
+.markdown-body input[type=checkbox]:focus:not(:focus-visible) {
+ outline: solid 1px transparent;
+}
+
+.markdown-body a:focus-visible,
+.markdown-body [role=button]:focus-visible,
+.markdown-body input[type=radio]:focus-visible,
+.markdown-body input[type=checkbox]:focus-visible {
+ outline: 2px solid var(--focus-outlineColor);
+ outline-offset: -2px;
+ box-shadow: none;
+}
+
+.markdown-body a:not([class]):focus,
+.markdown-body a:not([class]):focus-visible,
+.markdown-body input[type=radio]:focus,
+.markdown-body input[type=radio]:focus-visible,
+.markdown-body input[type=checkbox]:focus,
+.markdown-body input[type=checkbox]:focus-visible {
+ outline-offset: 0;
+}
+
+.markdown-body kbd {
+ display: inline-block;
+ padding: 0.25rem;
+ font: 11px ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace;
+ line-height: 10px;
+ color: var(--fgColor-default);
+ vertical-align: middle;
+ 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(--borderColor-neutral-muted);
+}
+
+.markdown-body h1,
+.markdown-body h2,
+.markdown-body h3,
+.markdown-body h4,
+.markdown-body h5,
+.markdown-body h6 {
+ margin-top: 1.5rem;
+ margin-bottom: 1rem;
+ font-weight: 600;
+ line-height: 1.25;
+}
+
+.markdown-body h2 {
+ font-weight: 600;
+ padding-bottom: .3em;
+ font-size: 1.5em;
+ border-bottom: 1px solid var(--borderColor-muted);
+}
+
+.markdown-body h3 {
+ font-weight: 600;
+ font-size: 1.25em;
+}
+
+.markdown-body h4 {
+ font-weight: 600;
+ font-size: 1em;
+}
+
+.markdown-body h5 {
+ font-weight: 600;
+ font-size: .875em;
+}
+
+.markdown-body h6 {
+ font-weight: 600;
+ font-size: .85em;
+ color: var(--fgColor-muted);
+}
+
+.markdown-body p {
+ margin-top: 0;
+ margin-bottom: 10px;
+}
+
+.markdown-body blockquote {
+ margin: 0;
+ padding: 0 1em;
+ color: var(--fgColor-muted);
+ border-left: .25em solid var(--borderColor-default);
+}
+
+.markdown-body ul,
+.markdown-body ol {
+ margin-top: 0;
+ margin-bottom: 0;
+ padding-left: 2em;
+}
+
+.markdown-body ol ol,
+.markdown-body ul ol {
+ list-style-type: lower-roman;
+}
+
+.markdown-body ul ul ol,
+.markdown-body ul ol ol,
+.markdown-body ol ul ol,
+.markdown-body ol ol ol {
+ list-style-type: lower-alpha;
+}
+
+.markdown-body dd {
+ margin-left: 0;
+}
+
+.markdown-body tt,
+.markdown-body code,
+.markdown-body samp {
+ 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-size: 12px;
+ word-wrap: normal;
+}
+
+.markdown-body input::-webkit-outer-spin-button,
+.markdown-body input::-webkit-inner-spin-button {
+ margin: 0;
+ appearance: none;
+}
+
+.markdown-body .mr-2 {
+ margin-right: 0.5rem !important;
+}
+
+.markdown-body::before {
+ display: table;
+ content: "";
+}
+
+.markdown-body::after {
+ display: table;
+ clear: both;
+ content: "";
+}
+
+.markdown-body > *:first-child {
+ margin-top: 0 !important;
+}
+
+.markdown-body > *:last-child {
+ margin-bottom: 0 !important;
+}
+
+.markdown-body a:not([href]) {
+ color: inherit;
+ text-decoration: none;
+}
+
+.markdown-body .absent {
+ color: var(--fgColor-danger);
+}
+
+.markdown-body .anchor {
+ float: left;
+ padding-right: 0.25rem;
+ margin-left: -20px;
+ line-height: 1;
+}
+
+.markdown-body .anchor:focus {
+ outline: none;
+}
+
+.markdown-body p,
+.markdown-body blockquote,
+.markdown-body ul,
+.markdown-body ol,
+.markdown-body dl,
+.markdown-body table,
+.markdown-body pre,
+.markdown-body details {
+ margin-top: 0;
+ margin-bottom: 1rem;
+}
+
+.markdown-body blockquote > :first-child {
+ margin-top: 0;
+}
+
+.markdown-body blockquote > :last-child {
+ margin-bottom: 0;
+}
+
+.markdown-body h1:hover .anchor,
+.markdown-body h2:hover .anchor,
+.markdown-body h3:hover .anchor,
+.markdown-body h4:hover .anchor,
+.markdown-body h5:hover .anchor,
+.markdown-body h6:hover .anchor {
+ text-decoration: none;
+}
+
+.markdown-body h1 tt,
+.markdown-body h1 code,
+.markdown-body h2 tt,
+.markdown-body h2 code,
+.markdown-body h3 tt,
+.markdown-body h3 code,
+.markdown-body h4 tt,
+.markdown-body h4 code,
+.markdown-body h5 tt,
+.markdown-body h5 code,
+.markdown-body h6 tt,
+.markdown-body h6 code {
+ padding: 0 .2em;
+ font-size: inherit;
+}
+
+.markdown-body summary h1,
+.markdown-body summary h2,
+.markdown-body summary h3,
+.markdown-body summary h4,
+.markdown-body summary h5,
+.markdown-body summary h6 {
+ display: inline-block;
+}
+
+.markdown-body summary h1 .anchor,
+.markdown-body summary h2 .anchor,
+.markdown-body summary h3 .anchor,
+.markdown-body summary h4 .anchor,
+.markdown-body summary h5 .anchor,
+.markdown-body summary h6 .anchor {
+ margin-left: -40px;
+}
+
+.markdown-body summary h1,
+.markdown-body summary h2 {
+ padding-bottom: 0;
+ border-bottom: 0;
+}
+
+.markdown-body ul.no-list,
+.markdown-body ol.no-list {
+ padding: 0;
+ list-style-type: none;
+}
+
+.markdown-body ol[type="a s"] {
+ list-style-type: lower-alpha;
+}
+
+.markdown-body ol[type="A s"] {
+ list-style-type: upper-alpha;
+}
+
+.markdown-body ol[type="i s"] {
+ list-style-type: lower-roman;
+}
+
+.markdown-body ol[type="I s"] {
+ list-style-type: upper-roman;
+}
+
+.markdown-body ol[type="1"] {
+ list-style-type: decimal;
+}
+
+.markdown-body div > ol:not([type]) {
+ list-style-type: decimal;
+}
+
+.markdown-body ul ul,
+.markdown-body ul ol,
+.markdown-body ol ol,
+.markdown-body ol ul {
+ margin-top: 0;
+ margin-bottom: 0;
+}
+
+.markdown-body li > p {
+ margin-top: 1rem;
+}
+
+.markdown-body li + li {
+ margin-top: .25em;
+}
+
+.markdown-body dl {
+ padding: 0;
+}
+
+.markdown-body dl dt {
+ padding: 0;
+ margin-top: 1rem;
+ font-size: 1em;
+ font-style: italic;
+ font-weight: 600;
+}
+
+.markdown-body dl dd {
+ padding: 0 1rem;
+ margin-bottom: 1rem;
+}
+
+.markdown-body table th {
+ font-weight: 600;
+}
+
+.markdown-body table th,
+.markdown-body table td {
+ padding: 6px 13px;
+ border: 1px solid var(--borderColor-default);
+}
+
+.markdown-body table td > :last-child {
+ margin-bottom: 0;
+}
+
+.markdown-body table tr {
+ background-color: var(--bgColor-default);
+ border-top: 1px solid var(--borderColor-neutral-muted);
+}
+
+.markdown-body table tr:nth-child(2n) {
+ background-color: var(--bgColor-muted);
+}
+
+.markdown-body table img {
+ background-color: transparent;
+}
+
+.markdown-body img[align=right] {
+ padding-left: 20px;
+}
+
+.markdown-body img[align=left] {
+ padding-right: 20px;
+}
+
+.markdown-body .emoji {
+ max-width: none;
+ vertical-align: text-top;
+ background-color: transparent;
+}
+
+.markdown-body span.frame {
+ display: block;
+ overflow: hidden;
+}
+
+.markdown-body span.frame > span {
+ display: block;
+ float: left;
+ width: auto;
+ padding: 7px;
+ margin: 13px 0 0;
+ overflow: hidden;
+ border: 1px solid var(--borderColor-default);
+}
+
+.markdown-body span.frame span img {
+ display: block;
+ float: left;
+}
+
+.markdown-body span.frame span span {
+ display: block;
+ padding: 5px 0 0;
+ clear: both;
+ color: var(--fgColor-default);
+}
+
+.markdown-body span.align-center {
+ display: block;
+ overflow: hidden;
+ clear: both;
+}
+
+.markdown-body span.align-center > span {
+ display: block;
+ margin: 13px auto 0;
+ overflow: hidden;
+ text-align: center;
+}
+
+.markdown-body span.align-center span img {
+ margin: 0 auto;
+ text-align: center;
+}
+
+.markdown-body span.align-right {
+ display: block;
+ overflow: hidden;
+ clear: both;
+}
+
+.markdown-body span.align-right > span {
+ display: block;
+ margin: 13px 0 0;
+ overflow: hidden;
+ text-align: right;
+}
+
+.markdown-body span.align-right span img {
+ margin: 0;
+ text-align: right;
+}
+
+.markdown-body span.float-left {
+ display: block;
+ float: left;
+ margin-right: 13px;
+ overflow: hidden;
+}
+
+.markdown-body span.float-left span {
+ margin: 13px 0 0;
+}
+
+.markdown-body span.float-right {
+ display: block;
+ float: right;
+ margin-left: 13px;
+ overflow: hidden;
+}
+
+.markdown-body span.float-right > span {
+ display: block;
+ margin: 13px auto 0;
+ overflow: hidden;
+ text-align: right;
+}
+
+.markdown-body code,
+.markdown-body tt {
+ padding: .2em .4em;
+ margin: 0;
+ font-size: 85%;
+ white-space: break-spaces;
+ background-color: var(--bgColor-neutral-muted);
+ border-radius: 6px;
+}
+
+.markdown-body code br,
+.markdown-body tt br {
+ display: none;
+}
+
+.markdown-body del code {
+ text-decoration: inherit;
+}
+
+.markdown-body samp {
+ font-size: 85%;
+}
+
+.markdown-body pre code {
+ font-size: 100%;
+}
+
+.markdown-body pre > code {
+ padding: 0;
+ margin: 0;
+ word-break: normal;
+ white-space: pre;
+ background: transparent;
+ border: 0;
+}
+
+.markdown-body .highlight {
+ margin-bottom: 1rem;
+}
+
+.markdown-body .highlight pre {
+ margin-bottom: 0;
+ word-break: normal;
+}
+
+.markdown-body .highlight pre,
+.markdown-body pre {
+ padding: 1rem;
+ overflow: auto;
+ font-size: 85%;
+ line-height: 1.45;
+ color: var(--fgColor-default);
+ background-color: var(--bgColor-muted);
+ border-radius: 6px;
+}
+
+.markdown-body pre code,
+.markdown-body pre tt {
+ display: inline;
+ padding: 0;
+ margin: 0;
+ overflow: visible;
+ line-height: inherit;
+ word-wrap: normal;
+ background-color: transparent;
+ border: 0;
+}
+
+.markdown-body .csv-data td,
+.markdown-body .csv-data th {
+ padding: 5px;
+ overflow: hidden;
+ font-size: 12px;
+ line-height: 1;
+ text-align: left;
+ white-space: nowrap;
+}
+
+.markdown-body .csv-data .blob-num {
+ padding: 10px 0.5rem 9px;
+ text-align: right;
+ background: var(--bgColor-default);
+ border: 0;
+}
+
+.markdown-body .csv-data tr {
+ border-top: 0;
+}
+
+.markdown-body .csv-data th {
+ font-weight: 600;
+ background: var(--bgColor-muted);
+ border-top: 0;
+}
+
+.markdown-body [data-footnote-ref]::before {
+ content: "[";
+}
+
+.markdown-body [data-footnote-ref]::after {
+ content: "]";
+}
+
+.markdown-body .footnotes {
+ font-size: 12px;
+ color: var(--fgColor-muted);
+ border-top: 1px solid var(--borderColor-default);
+}
+
+.markdown-body .footnotes ol {
+ padding-left: 1rem;
+}
+
+.markdown-body .footnotes ol ul {
+ display: inline-block;
+ padding-left: 1rem;
+ margin-top: 1rem;
+}
+
+.markdown-body .footnotes li {
+ position: relative;
+}
+
+.markdown-body .footnotes li:target::before {
+ position: absolute;
+ 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 var(--focus-outlineColor);
+ border-radius: 6px;
+}
+
+.markdown-body .footnotes li:target {
+ color: var(--fgColor-default);
+}
+
+.markdown-body .footnotes .data-footnote-backref g-emoji {
+ font-family: monospace;
+}
+
+.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;
+ font-family: "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
+ font-size: 1em;
+ font-style: normal !important;
+ font-weight: 400;
+ line-height: 1;
+ vertical-align: -0.075em;
+}
+
+.markdown-body g-emoji img {
+ width: 1em;
+ height: 1em;
+}
+
+.markdown-body .task-list-item {
+ list-style-type: none;
+}
+
+.markdown-body .task-list-item label {
+ font-weight: 400;
+}
+
+.markdown-body .task-list-item.enabled label {
+ cursor: pointer;
+}
+
+.markdown-body .task-list-item + .task-list-item {
+ margin-top: 0.25rem;
+}
+
+.markdown-body .task-list-item .handle {
+ display: none;
+}
+
+.markdown-body .task-list-item-checkbox {
+ margin: 0 .2em .25em -1.4em;
+ vertical-align: middle;
+}
+
+.markdown-body ul:dir(rtl) .task-list-item-checkbox {
+ margin: 0 -1.6em .25em .2em;
+}
+
+.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,
+.markdown-body .contains-task-list:focus-within .task-list-item-convert-container {
+ display: block;
+ width: auto;
+ height: 24px;
+ overflow: visible;
+ clip: auto;
+}
+
+.markdown-body ::-webkit-calendar-picker-indicator {
+ filter: invert(50%);
+}
+
+.markdown-body .markdown-alert {
+ padding: 0.5rem 1rem;
+ margin-bottom: 1rem;
+ color: inherit;
+ border-left: .25em solid var(--borderColor-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-title {
+ display: flex;
+ font-weight: 500;
+ align-items: center;
+ line-height: 1;
+}
+
+.markdown-body .markdown-alert.markdown-alert-note {
+ border-left-color: var(--borderColor-accent-emphasis);
+}
+
+.markdown-body .markdown-alert.markdown-alert-note .markdown-alert-title {
+ color: var(--fgColor-accent);
+}
+
+.markdown-body .markdown-alert.markdown-alert-important {
+ border-left-color: var(--borderColor-done-emphasis);
+}
+
+.markdown-body .markdown-alert.markdown-alert-important .markdown-alert-title {
+ color: var(--fgColor-done);
+}
+
+.markdown-body .markdown-alert.markdown-alert-warning {
+ border-left-color: var(--borderColor-attention-emphasis);
+}
+
+.markdown-body .markdown-alert.markdown-alert-warning .markdown-alert-title {
+ color: var(--fgColor-attention);
+}
+
+.markdown-body .markdown-alert.markdown-alert-tip {
+ border-left-color: var(--borderColor-success-emphasis);
+}
+
+.markdown-body .markdown-alert.markdown-alert-tip .markdown-alert-title {
+ color: var(--fgColor-success);
+}
+
+.markdown-body .markdown-alert.markdown-alert-caution {
+ border-left-color: var(--borderColor-danger-emphasis);
+}
+
+.markdown-body .markdown-alert.markdown-alert-caution .markdown-alert-title {
+ color: var(--fgColor-danger);
+}
+
+.markdown-body > *:first-child > .heading-element:first-child {
+ margin-top: 0 !important;
+}
+
+.markdown-body .highlight pre:has(+.zeroclipboard-container) {
+ min-height: 52px;
+}
pkg/templates/blob.gohtml
@@ -1,61 +1,7 @@
{{- /*gotype: github.com/antonmedv/gitmal/pkg/templates.BlobParams */ -}}
{{ define "head" }}
- <link rel="stylesheet" href="{{ .LayoutParams.RootHref }}assets/markdown.css">
- <style>
- [id] {
- scroll-margin-top: var(--header-height);
- }
-
- pre {
- border: 1px solid var(--c-border);
- border-top: none;
- border-bottom-left-radius: var(--border-radius);
- border-bottom-right-radius: var(--border-radius);
- }
-
- pre {
- margin: 0;
- padding: 8px 16px;
- overflow-x: auto;
- white-space: pre;
- word-spacing: normal;
- word-break: normal;
- word-wrap: normal;
- tab-size: 4;
- font-family: var(--font-family-mono), monospace;
- }
-
- pre > code {
- display: block;
- padding: 0 16px;
- width: fit-content;
- min-width: 100%;
- line-height: var(--code-line-height);
- font-size: var(--code-font-size);
- }
-
- .border {
- border: 1px solid var(--c-border);
- border-top: none;
- border-bottom-left-radius: 6px;
- border-bottom-right-radius: 6px;
- }
-
- .binary-file {
- padding: 8px 16px;
- font-style: italic;
- }
-
- .image {
- padding: 8px 16px;
- text-align: center;
- }
-
- .image img {
- max-width: 100%;
- height: auto;
- }
- </style>
+ <link rel="stylesheet" href="{{ .LayoutParams.RootHref }}assets/markdownBody.css">
+ <link rel="stylesheet" href="{{ .LayoutParams.RootHref }}assets/blob.css">
<link rel="stylesheet" href="{{ .LayoutParams.RootHref }}assets/code.css">
{{ end }}
pkg/templates/branches.gohtml
@@ -1,43 +1,6 @@
{{- /*gotype: github.com/antonmedv/gitmal/pkg/templates.BranchesParams*/ -}}
{{ define "head" }}
- <style>
- .branches {
- border: 1px solid var(--c-border);
- border-radius: var(--border-radius);
- overflow: hidden;
- }
-
- .branch-row {
- display: flex;
- align-items: center;
- gap: 12px;
- height: 44px;
- padding-inline: 16px;
- border-bottom: 1px solid var(--c-border);
- background-color: var(--c-bg-elv);
- }
-
- .branch-row:last-child {
- border-bottom: none;
- }
-
- .branch-row a {
- color: var(--c-text-1);
- }
-
- .branch-row a:hover {
- color: var(--c-brand-2);
- text-decoration: none;
- }
-
- .badge {
- font-size: 12px;
- color: var(--c-text-2);
- border: 1px solid var(--c-border);
- padding: 2px 6px;
- border-radius: 999px;
- }
- </style>
+ <link rel="stylesheet" href="{{ .LayoutParams.RootHref }}assets/branches.css">
{{ end }}
{{ define "body" }}
pkg/templates/commit.gohtml
@@ -1,220 +1,6 @@
{{- /*gotype: github.com/antonmedv/gitmal/pkg/templates.CommitParams*/ -}}
{{ define "head" }}
- <style>
- h1 code {
- border-radius: var(--border-radius);
- background: var(--c-bg-alt);
- padding: 4px 8px;
- font-family: var(--font-family-mono), monospace;
- font-weight: 500;
- }
-
- .commit {
- display: flex;
- flex-direction: column;
- gap: 16px;
- margin-bottom: 16px;
- }
-
- .commit-info {
- display: flex;
- flex-direction: row;
- gap: 8px;
- align-items: flex-end;
- }
-
- .commit-author {
- color: var(--c-text-1);
- font-weight: 600;
- min-width: 0;
- overflow-wrap: break-word;
- }
-
- .commit-date {
- color: var(--c-text-2);
- font-size: 12px;
- font-family: var(--font-family-mono), monospace;
- }
-
- .commit-message {
- border: 1px solid var(--c-border);
- border-radius: var(--border-radius);
- padding: 16px;
- }
-
- .ref-badges {
- display: inline-flex;
- gap: 6px;
- margin-left: 8px;
- }
-
- .badge {
- font-size: 12px;
- color: var(--c-text-2);
- border: 1px solid var(--c-border);
- padding: 2px 6px;
- border-radius: 999px;
- white-space: nowrap;
- }
-
- .commit-subject {
- font-size: 16px;
- font-weight: 600;
- line-height: 1.3;
- hyphens: auto;
- }
-
- .commit-body {
- margin-top: 16px;
- white-space: pre-wrap;
- line-height: 1.5;
- hyphens: auto;
- }
-
- .commit-subinfo {
- display: flex;
- flex-direction: row;
- gap: 16px;
- justify-content: space-between;
- }
-
- .commit-layout {
- display: grid;
- grid-template-columns: 1fr;
- gap: 16px;
- }
-
- @media (min-width: 960px) {
- .commit-layout {
- grid-template-columns: 300px 1fr;
- align-items: start;
- }
-
- .files-tree {
- position: sticky;
- top: 16px;
- }
-
- .files-tree-content {
- max-height: calc(100vh - var(--header-height) - 40px);
- overflow: auto;
- }
- }
-
- .files-tree {
- border: 1px solid var(--c-border);
- border-radius: var(--border-radius);
- }
-
- .files-tree-header {
- display: flex;
- flex-direction: row;
- align-items: center;
- padding-inline: 16px;
- height: var(--header-height);
- border-bottom: 1px solid var(--c-border);
- border-top-left-radius: var(--border-radius);
- border-top-right-radius: var(--border-radius);
- background: var(--c-bg-alt);
- font-size: 14px;
- font-weight: 600;
- }
-
- .files-tree-content {
- display: block;
- padding-block: 6px;
- }
-
- .tree .children {
- margin-left: 16px;
- border-left: 1px dashed var(--c-border);
- }
-
- .tree .node {
- display: flex;
- align-items: center;
- gap: 8px;
- padding: 10px 16px;
- }
-
- .tree .file-name {
- flex: 1;
- font-weight: 500;
- color: var(--c-text-1);
- cursor: pointer;
- }
-
- .tree .file-name:hover {
- color: var(--c-brand-2);
- text-decoration: underline;
- }
-
- .tree .dir {
- color: var(--c-dir);
- }
-
- .tree .file-added {
- color: var(--c-green);
- }
-
- .tree .file-deleted {
- color: var(--c-red);
- }
-
- .tree .file-renamed {
- color: var(--c-yellow);
- }
-
- /* Per-file sections */
-
- .files {
- min-width: 0;
- }
-
- .file-section + .file-section {
- margin-top: 16px;
- }
-
- pre {
- border: 1px solid var(--c-border);
- border-top: none;
- border-bottom-left-radius: var(--border-radius);
- border-bottom-right-radius: var(--border-radius);
- }
-
- pre {
- margin: 0;
- padding: 8px 16px;
- overflow-x: auto;
- white-space: pre;
- word-spacing: normal;
- word-break: normal;
- word-wrap: normal;
- tab-size: 4;
- font-family: var(--font-family-mono), monospace;
- }
-
- pre > code {
- display: block;
- padding: 0 16px;
- width: fit-content;
- min-width: 100%;
- line-height: var(--code-line-height);
- font-size: var(--code-font-size);
- }
-
- .binary-file {
- padding: 8px 16px;
- font-style: italic;
- }
-
- .border {
- border: 1px solid var(--c-border);
- border-top: none;
- border-bottom-left-radius: 6px;
- border-bottom-right-radius: 6px;
- }
- </style>
+ <link rel="stylesheet" href="{{ .LayoutParams.RootHref }}assets/commit.css">
<link rel="stylesheet" href="{{ .LayoutParams.RootHref }}assets/code.css">
{{ end }}
pkg/templates/commits_list.gohtml
@@ -1,149 +1,6 @@
{{- /*gotype: github.com/antonmedv/gitmal/pkg/templates.CommitsListParams*/ -}}
{{ define "head" }}
- <style>
- .commits {
- border: 1px solid var(--c-border);
- border-top: none;
- border-bottom-left-radius: var(--border-radius);
- border-bottom-right-radius: var(--border-radius);
- overflow-x: auto;
- }
-
- .row {
- display: flex;
- height: 40px;
- border-bottom: 1px solid var(--c-border);
- padding-inline: 16px;
- gap: 16px;
- }
-
- .row:last-child {
- border-bottom: none;
- }
-
- .row:hover {
- background-color: var(--c-bg-alt);
- }
-
- .cell {
- display: flex;
- gap: 8px;
- align-items: center;
- }
-
- .hash a {
- font-family: var(--font-family-mono), monospace;
- color: var(--c-text-2);
- }
-
- .commit-title {
- flex: 1;
- }
-
- .commit-title a {
- color: var(--c-text-1);
- line-height: 1.5;
- }
-
- .commit-title a:hover {
- color: var(--c-brand-2);
- }
-
- .ref-badges {
- display: inline-flex;
- gap: 6px;
- margin-left: 8px;
- }
-
- .badge {
- font-size: 12px;
- color: var(--c-text-2);
- border: 1px solid var(--c-border);
- padding: 2px 6px;
- border-radius: 999px;
- white-space: nowrap;
- }
-
- .date {
- font-family: var(--font-family-mono), monospace;
- font-size: 12px;
- color: var(--c-text-2);
- }
-
- .pagination {
- display: flex;
- gap: 8px;
- align-items: center;
- justify-content: center;
- margin-top: 12px;
- padding: 8px 0;
- color: var(--c-text-2);
- }
-
- .pagination a,
- .pagination span.btn {
- display: inline-flex;
- align-items: center;
- gap: 6px;
- padding: 6px 10px;
- border: 1px solid var(--c-border);
- border-radius: 6px;
- background: var(--c-bg-elv);
- color: var(--c-text-1);
- text-decoration: none;
- font-size: 13px;
- }
-
- .pagination a:hover {
- color: var(--c-brand-2);
- border-color: var(--c-brand-2);
- }
-
- .pagination .disabled {
- opacity: 0.5;
- pointer-events: none;
- }
-
- .pagination .page-indicator {
- margin: 0 4px;
- font-size: 13px;
- color: var(--c-text-2);
- }
-
- /* Mobile optimizations */
- @media (max-width: 767px) {
- .row {
- height: auto;
- padding: 10px 12px;
- gap: 12px;
- flex-wrap: wrap;
- align-items: flex-start;
- }
-
- .commit-title {
- flex-basis: 100%;
- order: 1;
- }
-
- .author, .date, .hash {
- font-size: 12px;
- }
-
- .author {
- color: var(--c-text-2);
- order: 2;
- }
-
- .date {
- order: 2;
- }
-
- .hash {
- margin-left: auto;
- order: 3;
- }
- }
- </style>
+ <link rel="stylesheet" href="{{ .LayoutParams.RootHref }}assets/commits_list.css">
{{ end }}
{{ define "body" }}
pkg/templates/layout.gohtml
@@ -5,295 +5,7 @@
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>{{ .Title }}</title>
- <style>
- :root {
- color-scheme: light dark;
- --c-indigo-1: light-dark(#3451b2, #a8b1ff);
- --c-indigo-2: light-dark(#3a5ccc, #5c73e7);
- --c-indigo-3: light-dark(#5672cd, #3e63dd);
- --c-green: light-dark(#1a7f37, #57ab5a);
- --c-red: light-dark(#c53030, #e5534b);
- --c-yellow: light-dark(#9a6700, #c69026);
- --c-dir: light-dark(#54aeff, #9198a1);
- --c-gray-soft: light-dark(rgba(142, 150, 170, .14), rgba(101, 117, 133, .16));
- --c-bg: light-dark(#ffffff, #1b1b1f);
- --c-bg-alt: light-dark(#f6f6f7, #161618);
- --c-bg-elv: light-dark(#ffffff, #202127);
- --c-text-1: light-dark(rgba(60, 60, 67), rgba(255, 255, 245, .86));
- --c-text-2: light-dark(rgba(60, 60, 67, .78), rgba(235, 235, 245, .6));
- --c-text-3: light-dark(rgba(60, 60, 67, .56), rgba(235, 235, 245, .38));
- --c-border: light-dark(#c2c2c4, #3c3f44);
- --c-divider: light-dark(#e2e2e3, #2e2e32);
-
- --c-brand-1: var(--c-indigo-1);
- --c-brand-2: var(--c-indigo-2);
- --c-brand-3: var(--c-indigo-3);
- --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
- --font-family-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
- --code-line-height: 20px;
- --code-font-size: 12px;
- --code-color: var(--c-brand-1);
- --code-bg: var(--c-gray-soft);
- --code-block-bg: var(--c-bg-alt);
- --code-block-color: var(--c-text-1);
- --header-height: 46px;
- --border-radius: 6px;
- --max-content-width: 1470px;
- }
-
- * {
- box-sizing: border-box;
- }
-
- body {
- margin: 0;
- padding: 0;
- font-family: var(--font-family), sans-serif;
- font-size: 14px;
- line-height: 1;
- color: var(--c-text-1);
- background-color: var(--c-bg);
- text-rendering: optimizeLegibility;
- -webkit-font-smoothing: antialiased;
- -moz-osx-font-smoothing: grayscale;
- -moz-text-size-adjust: none;
- -webkit-text-size-adjust: none;
- text-size-adjust: none;
- min-height: 100vh;
- display: flex;
- flex-direction: column;
- }
-
- .nowrap {
- white-space: nowrap;
- }
-
- h1 {
- margin-inline: 0;
- margin-block: 16px;
- font-size: 20px;
- font-weight: 600;
- }
-
- a {
- color: var(--c-brand-1);
- font-weight: 500;
- text-decoration: underline;
- text-underline-offset: 2px;
- text-decoration: inherit;
- touch-action: manipulation;
- }
-
- a:hover {
- color: var(--c-brand-2);
- text-decoration: underline;
- }
-
- .menu {
- background-color: var(--c-bg-alt);
- border-bottom: 1px solid var(--c-divider);
- overflow-x: auto;
- }
-
- .menu-content {
- display: flex;
- flex-direction: row;
- align-items: center;
- gap: 16px;
- padding-inline: 16px;
- max-width: var(--max-content-width);
- margin-inline: auto;
- }
-
- .menu-item {
- display: flex;
- align-items: center;
- border-bottom: 2px solid transparent;
- height: 56px;
- padding-inline: 8px;
- }
-
- .menu-item a {
- display: flex;
- flex-direction: row;
- gap: 8px;
- align-items: center;
- color: var(--c-text-1);
- padding: 8px 10px;
- border-radius: 4px;
- }
-
- .menu-item a:hover {
- background-color: var(--c-bg-elv);
- text-decoration: none;
- }
-
- .menu-item.selected {
- border-bottom-color: var(--c-brand-1);
- }
-
- .project-name {
- font-weight: 600;
- font-size: 16px;
- margin-inline: 16px;
- color: var(--c-text-1);
- text-decoration: none;
- }
-
- main {
- flex-grow: 1;
- width: 100%;
- max-width: var(--max-content-width);
- margin: 16px auto;
- }
-
- .main-content {
- padding-inline: 16px;
- }
-
- footer {
- padding: 12px 16px;
- background-color: var(--c-bg-alt);
- border-top: 1px solid var(--c-divider);
- color: var(--c-text-3);
- font-size: 12px;
- text-align: center;
- }
-
- .header-container {
- container-type: scroll-state;
- position: sticky;
- top: 0;
- }
-
- .header-container {
- @container scroll-state(stuck: top) {
- header {
- border-top: none;
- border-top-left-radius: 0;
- border-top-right-radius: 0;
- }
-
- .goto-top {
- display: flex;
- }
- }
- }
-
- header {
- display: flex;
- flex-direction: row;
- align-items: center;
- min-height: var(--header-height);
- padding-inline: 16px;
- background: var(--c-bg-alt);
- border: 1px solid var(--c-border);
- border-top-left-radius: var(--border-radius);
- border-top-right-radius: var(--border-radius);
- }
-
- header h1 {
- word-break: break-all;
- font-weight: 600;
- font-size: 16px;
- margin: 0;
- padding: 0;
- }
-
- .header-ref {
- color: var(--c-text-2);
- border: 1px solid var(--c-border);
- border-radius: 6px;
- padding: 6px 10px;
- margin-right: 10px;
- margin-left: -6px;
- }
-
- header .path {
- font-size: 16px;
- }
-
- .breadcrumbs {
- display: flex;
- flex-direction: row;
- flex-wrap: wrap;
- gap: 6px;
- font-size: 16px;
- }
-
- .breadcrumbs a {
- word-break: break-all;
- }
-
- .goto-top {
- display: none;
- margin-left: auto;
- padding: 6px 10px;
- background: none;
- border: none;
- border-radius: 6px;
- gap: 4px;
- align-items: center;
- color: var(--c-text-1);
- cursor: pointer;
- }
-
- .goto-top:hover {
- background: var(--c-bg-elv);
- }
-
- .raw-actions {
- display: flex;
- margin-left: auto;
- gap: 2px;
- align-items: center;
- }
-
- .raw-btn {
- display: flex;
- padding: 6px 10px;
- background: none;
- border: none;
- border-radius: 6px;
- align-items: center;
- color: var(--c-text-1);
- cursor: pointer;
- font-size: 14px;
- font-family: inherit;
- text-decoration: none;
- }
-
- .raw-btn:hover {
- background: var(--c-bg-elv);
- color: var(--c-text-1);
- text-decoration: none;
- }
-
- .has-tooltip {
- position: relative;
- }
-
- .tooltip {
- display: none;
- position: absolute;
- bottom: calc(100% + 6px);
- left: 50%;
- transform: translateX(-50%);
- padding: 4px 8px;
- background: var(--c-bg-elv);
- border: 1px solid var(--c-border);
- border-radius: 4px;
- font-size: 12px;
- white-space: nowrap;
- color: var(--c-text-1);
- pointer-events: none;
- }
-
- .has-tooltip:hover .tooltip,
- .has-tooltip.copied .tooltip {
- display: block;
- }
- </style>
+ <link rel="stylesheet" href="{{ .RootHref }}assets/layout.css">
{{ template "head" . }}
</head>
<body>
pkg/templates/list.gohtml
@@ -1,90 +1,7 @@
{{- /*gotype: github.com/antonmedv/gitmal/pkg/templates.ListParams*/ -}}
{{ define "head" }}
- <link rel="stylesheet" href="{{ .LayoutParams.RootHref }}assets/markdown.css">
- <style>
- .files {
- border: 1px solid var(--c-border);
- border-top: none;
- width: 100%;
- border-bottom-left-radius: var(--border-radius);
- border-bottom-right-radius: var(--border-radius);
- overflow-x: auto;
- }
-
- .files .dir {
- color: var(--c-dir);
- }
-
- .files a {
- color: var(--c-text-1);
- }
-
- .files a:hover {
- color: var(--c-brand-2);
- }
-
- .row {
- display: flex;
- height: 40px;
- border-bottom: 1px solid var(--c-border);
- padding-inline: 16px;
- gap: 16px;
- }
-
- .row:last-child {
- border-bottom: none;
- }
-
- .row:hover {
- background-color: var(--c-bg-alt);
- }
-
- .cell {
- flex: 1;
- display: flex;
- gap: 8px;
- align-items: center;
- white-space: nowrap;
- }
-
- .cell:not(:first-child) {
- justify-content: flex-end;
- max-width: 100px;
- }
-
- @media (max-width: 767px) {
- .file-mode {
- display: none;
- }
- }
-
- {{ if .Readme }}
- .markdown-container {
- padding-inline: 16px;
- border: 1px solid var(--c-divider);
- border-radius: 8px;
- overflow-x: auto;
- margin-top: 16px;
- }
-
- .markdown-body {
- width: 100%;
- min-width: 200px;
- max-width: 980px;
- margin: 0 auto;
- padding: 32px;
- word-wrap: break-word;
- font-size: 16px;
- line-height: 1.5;
- }
-
- @media (max-width: 767px) {
- .markdown-body {
- padding: 16px;
- }
- }
- {{ end }}
- </style>
+ <link rel="stylesheet" href="{{ .LayoutParams.RootHref }}assets/list.css">
+ <link rel="stylesheet" href="{{ .LayoutParams.RootHref }}assets/markdownBody.css">
{{ end }}
{{ define "body" }}
@@ -134,8 +51,8 @@
</div>
{{ if .Readme }}
- <div class="markdown-container">
- <div class="markdown-body">
+ <div class="markdown-container readme">
+ <div class="markdown-body readme">
{{ .Readme }}
</div>
</div>
pkg/templates/markdown.gohtml
@@ -1,36 +1,7 @@
{{- /*gotype: github.com/antonmedv/gitmal/pkg/templates.MarkdownParams*/ -}}
{{ define "head" }}
<link rel="stylesheet" href="{{ .LayoutParams.RootHref }}assets/markdown.css">
- <style>
- [id] {
- scroll-margin-top: var(--header-height);
- }
-
- .markdown-container {
- border: 1px solid var(--c-divider);
- border-top: none;
- border-bottom-left-radius: 8px;
- border-bottom-right-radius: 8px;
- overflow-x: auto;
- }
-
- .markdown-body {
- width: 100%;
- min-width: 200px;
- max-width: 980px;
- margin: 0 auto;
- padding: 32px;
- word-wrap: break-word;
- font-size: 16px;
- line-height: 1.5;
- }
-
- @media (max-width: 767px) {
- .markdown-body {
- padding: 16px;
- }
- }
- </style>
+ <link rel="stylesheet" href="{{ .LayoutParams.RootHref }}assets/markdownBody.css">
{{ end }}
{{ define "body" }}
assets.go
@@ -6,26 +6,60 @@ import (
"path/filepath"
)
-//go:embed assets/markdown.css
-var MarkdownCSS []byte
+//go:embed assets/markdownBody.css
+var MarkdownBodyCSS []byte
//go:embed assets/code.css
var CodeCSS []byte
+//go:embed assets/blob.css
+var BlobCSS []byte
+
+//go:embed assets/branches.css
+var BranchesCSS []byte
+
+//go:embed assets/commit.css
+var CommitCSS []byte
+
+//go:embed assets/commits_list.css
+var CommitsListCss []byte
+
+//go:embed assets/layout.css
+var LayoutCSS []byte
+
+//go:embed assets/list.css
+var ListCSS []byte
+
+//go:embed assets/markdown.css
+var MarkdownCSS []byte
+
+//go:embed assets/tags.css
+var TagsCSS []byte
+
+var Assets = map[string][]byte{
+ "markdownBody.css": MarkdownBodyCSS,
+ "code.css": CodeCSS,
+ "blob.css": BlobCSS,
+ "branches.css": BranchesCSS,
+ "commit.css": CommitCSS,
+ "commits_list.css": CommitsListCss,
+ "layout.css": LayoutCSS,
+ "list.css": ListCSS,
+ "markdown.css": MarkdownCSS,
+ "tags.css": TagsCSS,
+}
+
func copyAssets(params Params) error {
outDir := filepath.Join(params.OutputDir, "assets")
if err := os.MkdirAll(outDir, 0o755); err != nil {
return err
}
- markdownCSSpath := filepath.Join(outDir, "markdown.css")
- if e := os.WriteFile(markdownCSSpath, MarkdownCSS, 0o644); e != nil {
- return e
- }
-
- codeCSSpath := filepath.Join(outDir, "code.css")
- if e := os.WriteFile(codeCSSpath, CodeCSS, 0o644); e != nil {
- return e
+ for name, data := range Assets {
+ path := filepath.Join(outDir, name)
+ if e := os.WriteFile(path, data, 0o644); e != nil {
+ return e
+ }
}
return nil