Commit cdca8c4
Eric Bower
·
2024-04-25 09:31:36 -0400 EDT
parent 01c88ba
feat: better theme support
9 files changed,
+77,
-223
M
Makefile
+1,
-1
| ... | ... | @@ -28,7 +28,7 @@ static: build clean | |
| 28 | 28 | --desc "static site generator for git" \ | |
| 29 | 29 | --clone-url "https://github.com/picosh/pgit.git" \ | |
| 30 | 30 | --home-url "https://git.erock.io" \ | |
| 31 | - | --theme "algol" \ | |
| 31 | + | --theme "dracula" \ | |
| 32 | 32 | --revs main | |
| 33 | 33 | .PHONY: | |
| 34 | 34 |
+16,
-0
| ... | ... | @@ -23,6 +23,22 @@ To learn more about the options run: | |
| 23 | 23 | ./pgit --help | |
| 24 | 24 | ``` | |
| 25 | 25 | ||
| 26 | + | ## themes | |
| 27 | + | ||
| 28 | + | We support all [chroma](https://xyproto.github.io/splash/docs/all.html) themes. | |
| 29 | + | We do our best to adapt the theme of the entire site to match the chroma syntax | |
| 30 | + | highlighting theme. This is a "closet approximation" as we are not testing every | |
| 31 | + | single theme. | |
| 32 | + | ||
| 33 | + | ```bash | |
| 34 | + | ./pgit --revs main --label pico --out ./public --theme onedark | |
| 35 | + | ``` | |
| 36 | + | ||
| 37 | + | The default theme is `dracula`. If you want to change the colors for your site, | |
| 38 | + | we generate a `vars.css` file that you are welcome to overwrite before | |
| 39 | + | deploying, it will _not_ change the syntax highlighting colors, only the main | |
| 40 | + | site colors. | |
| 41 | + | ||
| 26 | 42 | # inspiration | |
| 27 | 43 | ||
| 28 | 44 | This project was heavily inspired by |
M
go.mod
+2,
-2
| ... | ... | @@ -3,13 +3,13 @@ module github.com/picosh/pgit | |
| 3 | 3 | go 1.18 | |
| 4 | 4 | ||
| 5 | 5 | require ( | |
| 6 | - | github.com/alecthomas/chroma v0.10.0 | |
| 6 | + | github.com/alecthomas/chroma/v2 v2.13.0 | |
| 7 | 7 | github.com/dustin/go-humanize v1.0.0 | |
| 8 | 8 | github.com/gogs/git-module v1.6.0 | |
| 9 | 9 | ) | |
| 10 | 10 | ||
| 11 | 11 | require ( | |
| 12 | - | github.com/dlclark/regexp2 v1.7.0 // indirect | |
| 12 | + | github.com/dlclark/regexp2 v1.11.0 // indirect | |
| 13 | 13 | github.com/mcuadros/go-version v0.0.0-20190308113854-92cdf37c5b75 // indirect | |
| 14 | 14 | github.com/stretchr/testify v1.8.1 // indirect | |
| 15 | 15 | golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4 // indirect |
M
go.sum
+7,
-6
| ... | ... | @@ -1,15 +1,17 @@ | |
| 1 | - | github.com/alecthomas/chroma v0.10.0 h1:7XDcGkCQopCNKjZHfYrNLraA+M7e0fMiJ/Mfikbfjek= | |
| 2 | - | github.com/alecthomas/chroma v0.10.0/go.mod h1:jtJATyUxlIORhUOFNA9NZDWGAQ8wpxQQqNSB4rjA/1s= | |
| 1 | + | github.com/alecthomas/assert/v2 v2.6.0 h1:o3WJwILtexrEUk3cUVal3oiQY2tfgr/FHWiz/v2n4FU= | |
| 2 | + | github.com/alecthomas/chroma/v2 v2.13.0 h1:VP72+99Fb2zEcYM0MeaWJmV+xQvz5v5cxRHd+ooU1lI= | |
| 3 | + | github.com/alecthomas/chroma/v2 v2.13.0/go.mod h1:BUGjjsD+ndS6eX37YgTchSEG+Jg9Jv1GiZs9sqPqztk= | |
| 4 | + | github.com/alecthomas/repr v0.4.0 h1:GhI2A8MACjfegCPVq9f1FLvIBS+DrQ2KQBFZP1iFzXc= | |
| 3 | 5 | github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= | |
| 4 | 6 | github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= | |
| 5 | 7 | github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= | |
| 6 | - | github.com/dlclark/regexp2 v1.4.0/go.mod h1:2pZnwuY/m+8K6iRw6wQdMtk+rH5tNGR1i55kozfMjCc= | |
| 7 | - | github.com/dlclark/regexp2 v1.7.0 h1:7lJfhqlPssTb1WQx4yvTHN0uElPEv52sbaECrAQxjAo= | |
| 8 | - | github.com/dlclark/regexp2 v1.7.0/go.mod h1:DHkYz0B9wPfa6wondMfaivmHpzrQ3v9q8cnmRbL6yW8= | |
| 8 | + | github.com/dlclark/regexp2 v1.11.0 h1:G/nrcoOa7ZXlpoa/91N3X7mM3r8eIlMBBJZvsz/mxKI= | |
| 9 | + | github.com/dlclark/regexp2 v1.11.0/go.mod h1:DHkYz0B9wPfa6wondMfaivmHpzrQ3v9q8cnmRbL6yW8= | |
| 9 | 10 | github.com/dustin/go-humanize v1.0.0 h1:VSnTsYCnlFHaM2/igO1h6X3HA71jcobQuxemgkq4zYo= | |
| 10 | 11 | github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= | |
| 11 | 12 | github.com/gogs/git-module v1.6.0 h1:71GdRM9/pFxGgSUz8t2DKmm3RYuHUnTjsOuFInJXnkM= | |
| 12 | 13 | github.com/gogs/git-module v1.6.0/go.mod h1:8jFYhDxLUwEOhM2709l2CJXmoIIslobU1xszpT0NcAI= | |
| 14 | + | github.com/hexops/gotextdiff v1.0.3 h1:gitA9+qJrrTCsiCl7+kh75nPqQt1cx4ZkudSTLoUqJM= | |
| 13 | 15 | github.com/mcuadros/go-version v0.0.0-20190308113854-92cdf37c5b75 h1:Pijfgr7ZuvX7QIQiEwLdRVr3RoMG+i0SbBO1Qu+7yVk= | |
| 14 | 16 | github.com/mcuadros/go-version v0.0.0-20190308113854-92cdf37c5b75/go.mod h1:76rfSfYPWj01Z85hUf/ituArm797mNKcvINh1OlsZKo= | |
| 15 | 17 | github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= |
| ... | ... | @@ -18,7 +20,6 @@ github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+ | |
| 18 | 20 | github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= | |
| 19 | 21 | github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= | |
| 20 | 22 | github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= | |
| 21 | - | github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= | |
| 22 | 23 | github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= | |
| 23 | 24 | github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= | |
| 24 | 25 | github.com/stretchr/testify v1.8.1 h1:w7B6lhMri9wdJUVmEZPGGhZzrYTPvgJArz7wNPgYKsk= |
+1,
-0
| ... | ... | @@ -10,6 +10,7 @@ | |
| 10 | 10 | ||
| 11 | 11 | {{template "meta" .}} | |
| 12 | 12 | ||
| 13 | + | <link rel="stylesheet" href="/vars.css" /> | |
| 13 | 14 | <link rel="stylesheet" href="/smol.css" /> | |
| 14 | 15 | <link rel="stylesheet" href="/main.css" /> | |
| 15 | 16 | </head> |
+1,
-1
| ... | ... | @@ -26,7 +26,7 @@ | |
| 26 | 26 | ||
| 27 | 27 | <div class="flex items-center gap-xs"> | |
| 28 | 28 | <span>{{.AuthorStr}}</span> | |
| 29 | - | <span>·</span> | |
| 29 | + | <span> · </span> | |
| 30 | 30 | <span>{{.WhenStr}}</span> | |
| 31 | 31 | </div> | |
| 32 | 32 |
M
main.go
+36,
-5
| ... | ... | @@ -16,10 +16,10 @@ import ( | |
| 16 | 16 | "sync" | |
| 17 | 17 | "unicode/utf8" | |
| 18 | 18 | ||
| 19 | - | "github.com/alecthomas/chroma" | |
| 20 | - | formatterHtml "github.com/alecthomas/chroma/formatters/html" | |
| 21 | - | "github.com/alecthomas/chroma/lexers" | |
| 22 | - | "github.com/alecthomas/chroma/styles" | |
| 19 | + | "github.com/alecthomas/chroma/v2" | |
| 20 | + | formatterHtml "github.com/alecthomas/chroma/v2/formatters/html" | |
| 21 | + | "github.com/alecthomas/chroma/v2/lexers" | |
| 22 | + | "github.com/alecthomas/chroma/v2/styles" | |
| 23 | 23 | "github.com/dustin/go-humanize" | |
| 24 | 24 | git "github.com/gogs/git-module" | |
| 25 | 25 | ) |
| ... | ... | @@ -1008,6 +1008,30 @@ func (c *Config) writeRevision(repo *git.Repository, pageData *PageData, refs [] | |
| 1008 | 1008 | return output | |
| 1009 | 1009 | } | |
| 1010 | 1010 | ||
| 1011 | + | func style(theme chroma.Style) string { | |
| 1012 | + | bg := theme.Get(chroma.Background) | |
| 1013 | + | txt := theme.Get(chroma.Text) | |
| 1014 | + | kw := theme.Get(chroma.Keyword) | |
| 1015 | + | nv := theme.Get(chroma.NameVariable) | |
| 1016 | + | cm := theme.Get(chroma.Comment) | |
| 1017 | + | ln := theme.Get(chroma.LiteralNumber) | |
| 1018 | + | return fmt.Sprintf(`:root { | |
| 1019 | + | --bg-color: %s; | |
| 1020 | + | --text-color: %s; | |
| 1021 | + | --border: %s; | |
| 1022 | + | --link-color: %s; | |
| 1023 | + | --hover: %s; | |
| 1024 | + | --visited: %s; | |
| 1025 | + | }`, | |
| 1026 | + | bg.Background.String(), | |
| 1027 | + | txt.Colour.String(), | |
| 1028 | + | cm.Colour.String(), | |
| 1029 | + | nv.Colour.String(), | |
| 1030 | + | kw.Colour.String(), | |
| 1031 | + | ln.Colour.String(), | |
| 1032 | + | ) | |
| 1033 | + | } | |
| 1034 | + | ||
| 1011 | 1035 | func main() { | |
| 1012 | 1036 | var outdir = flag.String("out", "./public", "output directory") | |
| 1013 | 1037 | var rpath = flag.String("repo", ".", "path to git repo") |
| ... | ... | @@ -1043,7 +1067,7 @@ func main() { | |
| 1043 | 1067 | ||
| 1044 | 1068 | formatter := formatterHtml.New( | |
| 1045 | 1069 | formatterHtml.WithLineNumbers(true), | |
| 1046 | - | formatterHtml.LinkableLineNumbers(true, ""), | |
| 1070 | + | formatterHtml.WithLinkableLineNumbers(true, ""), | |
| 1047 | 1071 | formatterHtml.WithClasses(true), | |
| 1048 | 1072 | ) | |
| 1049 | 1073 |
| ... | ... | @@ -1071,6 +1095,13 @@ func main() { | |
| 1071 | 1095 | config.writeRepo() | |
| 1072 | 1096 | config.copyStatic("static") | |
| 1073 | 1097 | ||
| 1098 | + | styles := style(*theme) | |
| 1099 | + | fmt.Println(styles) | |
| 1100 | + | err = os.WriteFile(filepath.Join(out, "vars.css"), []byte(styles), 0644) | |
| 1101 | + | if err != nil { | |
| 1102 | + | panic(err) | |
| 1103 | + | } | |
| 1104 | + | ||
| 1074 | 1105 | fp := filepath.Join(out, "syntax.css") | |
| 1075 | 1106 | w, err := os.OpenFile(fp, os.O_RDWR|os.O_CREATE|os.O_TRUNC, 0644) | |
| 1076 | 1107 | if err != nil { |
+10,
-6
| ... | ... | @@ -1,15 +1,19 @@ | |
| 1 | + | pre { | |
| 2 | + | border: 1px solid var(--border); | |
| 3 | + | } | |
| 4 | + | ||
| 5 | + | body { | |
| 6 | + | max-width: 900px; | |
| 7 | + | } | |
| 8 | + | ||
| 1 | 9 | .border-b { | |
| 2 | - | border-bottom: 1px solid var(--grey); | |
| 10 | + | border-bottom: 1px solid var(--border); | |
| 3 | 11 | } | |
| 4 | 12 | ||
| 5 | 13 | .border-b:last-child { | |
| 6 | 14 | border-bottom: 0; | |
| 7 | 15 | } | |
| 8 | 16 | ||
| 9 | - | body { | |
| 10 | - | max-width: 900px; | |
| 11 | - | } | |
| 12 | - | ||
| 13 | 17 | .box { | |
| 14 | 18 | margin: 1rem 0; | |
| 15 | 19 | } |
| ... | ... | @@ -24,7 +28,7 @@ body { | |
| 24 | 28 | } | |
| 25 | 29 | ||
| 26 | 30 | .tree-row:hover { | |
| 27 | - | background-color: var(--grey); | |
| 31 | + | background-color: var(--border); | |
| 28 | 32 | } | |
| 29 | 33 | ||
| 30 | 34 | @media only screen and (max-width: 900px) { |
+3,
-202
| ... | ... | @@ -15,50 +15,6 @@ | |
| 15 | 15 | box-shadow: none; | |
| 16 | 16 | } | |
| 17 | 17 | ||
| 18 | - | @media (prefers-color-scheme: light) { | |
| 19 | - | :root { | |
| 20 | - | --main-hue: 250; | |
| 21 | - | --white: #6a737d; | |
| 22 | - | --white-light: #cfe0f4; | |
| 23 | - | --white-dark: #9b9b9b; | |
| 24 | - | --code: #e3e5e8; | |
| 25 | - | --code-border: #e3e5e8; | |
| 26 | - | --pre: #f6f8fa; | |
| 27 | - | --bg-color: #fdfdfd; | |
| 28 | - | --text-color: #24292f; | |
| 29 | - | --link-color: #005cc5; | |
| 30 | - | --visited: #6f42c1; | |
| 31 | - | --blockquote: #005cc5; | |
| 32 | - | --blockquote-bg: #cfe0f4; | |
| 33 | - | --hover: #d73a49; | |
| 34 | - | --grey: #ccc; | |
| 35 | - | --grey-light: #6a708e; | |
| 36 | - | --shadow: #e8e8e8; | |
| 37 | - | } | |
| 38 | - | } | |
| 39 | - | ||
| 40 | - | @media (prefers-color-scheme: dark) { | |
| 41 | - | :root { | |
| 42 | - | --main-hue: 250; | |
| 43 | - | --white: #f2f2f2; | |
| 44 | - | --white-light: #f2f2f2; | |
| 45 | - | --white-dark: #c6c6c6; | |
| 46 | - | --code: #414558; | |
| 47 | - | --code-border: #252525; | |
| 48 | - | --pre: #252525; | |
| 49 | - | --bg-color: #282a36; | |
| 50 | - | --text-color: #f2f2f2; | |
| 51 | - | --link-color: #8be9fd; | |
| 52 | - | --visited: #bd93f9; | |
| 53 | - | --blockquote: #bd93f9; | |
| 54 | - | --blockquote-bg: #414558; | |
| 55 | - | --hover: #ff80bf; | |
| 56 | - | --grey: #414558; | |
| 57 | - | --grey-light: #6a708e; | |
| 58 | - | --shadow: #252525; | |
| 59 | - | } | |
| 60 | - | } | |
| 61 | - | ||
| 62 | 18 | html { | |
| 63 | 19 | background-color: var(--bg-color); | |
| 64 | 20 | color: var(--text-color); |
| ... | ... | @@ -106,7 +62,6 @@ pre > code { | |
| 106 | 62 | background-color: inherit; | |
| 107 | 63 | padding: 0; | |
| 108 | 64 | border: none; | |
| 109 | - | color: initial; | |
| 110 | 65 | } | |
| 111 | 66 | ||
| 112 | 67 | code { |
| ... | ... | @@ -163,7 +118,7 @@ hr { | |
| 163 | 118 | border: 0; | |
| 164 | 119 | margin: 0; | |
| 165 | 120 | height: 2px; | |
| 166 | - | background: var(--grey); | |
| 121 | + | background: var(--border); | |
| 167 | 122 | margin: 1rem auto; | |
| 168 | 123 | text-align: center; | |
| 169 | 124 | } |
| ... | ... | @@ -182,15 +137,6 @@ a:visited { | |
| 182 | 137 | color: var(--visited); | |
| 183 | 138 | } | |
| 184 | 139 | ||
| 185 | - | a.link-grey { | |
| 186 | - | text-decoration: underline; | |
| 187 | - | color: var(--white); | |
| 188 | - | } | |
| 189 | - | ||
| 190 | - | a.link-grey:visited { | |
| 191 | - | color: var(--white); | |
| 192 | - | } | |
| 193 | - | ||
| 194 | 140 | section { | |
| 195 | 141 | margin-bottom: 1.4rem; | |
| 196 | 142 | } |
| ... | ... | @@ -211,21 +157,6 @@ article { | |
| 211 | 157 | overflow-wrap: break-word; | |
| 212 | 158 | } | |
| 213 | 159 | ||
| 214 | - | blockquote { | |
| 215 | - | border-left: 5px solid var(--blockquote); | |
| 216 | - | background-color: var(--blockquote-bg); | |
| 217 | - | padding: 0.8rem; | |
| 218 | - | margin: 1rem 0; | |
| 219 | - | } | |
| 220 | - | ||
| 221 | - | blockquote > p { | |
| 222 | - | margin: 0; | |
| 223 | - | } | |
| 224 | - | ||
| 225 | - | blockquote code { | |
| 226 | - | border: 1px solid var(--blockquote); | |
| 227 | - | } | |
| 228 | - | ||
| 229 | 160 | ul, | |
| 230 | 161 | ol { | |
| 231 | 162 | padding: 0 0 0 2rem; |
| ... | ... | @@ -287,45 +218,6 @@ figure { | |
| 287 | 218 | monospace; | |
| 288 | 219 | } | |
| 289 | 220 | ||
| 290 | - | .link-alt-adj, | |
| 291 | - | .link-alt-adj:visited, | |
| 292 | - | .link-alt-adj:visited:hover, | |
| 293 | - | .link-alt-adj:hover { | |
| 294 | - | color: var(--link-color); | |
| 295 | - | text-decoration: none; | |
| 296 | - | } | |
| 297 | - | ||
| 298 | - | .link-alt-adj:visited:hover, | |
| 299 | - | .link-alt-adj:hover { | |
| 300 | - | text-decoration: underline; | |
| 301 | - | } | |
| 302 | - | ||
| 303 | - | .link-alt-hover, | |
| 304 | - | .link-alt-hover:visited, | |
| 305 | - | .link-alt-hover:visited:hover, | |
| 306 | - | .link-alt-hover:hover { | |
| 307 | - | color: var(--hover); | |
| 308 | - | text-decoration: none; | |
| 309 | - | } | |
| 310 | - | ||
| 311 | - | .link-alt-hover:visited:hover, | |
| 312 | - | .link-alt-hover:hover { | |
| 313 | - | text-decoration: underline; | |
| 314 | - | } | |
| 315 | - | ||
| 316 | - | .link-alt, | |
| 317 | - | .link-alt:visited, | |
| 318 | - | .link-alt:visited:hover, | |
| 319 | - | .link-alt:hover { | |
| 320 | - | color: var(--white); | |
| 321 | - | text-decoration: none; | |
| 322 | - | } | |
| 323 | - | ||
| 324 | - | .link-alt:visited:hover, | |
| 325 | - | .link-alt:hover { | |
| 326 | - | text-decoration: underline; | |
| 327 | - | } | |
| 328 | - | ||
| 329 | 221 | .text-3xl { | |
| 330 | 222 | font-size: 2.5rem; | |
| 331 | 223 | } |
| ... | ... | @@ -371,7 +263,7 @@ figure { | |
| 371 | 263 | } | |
| 372 | 264 | ||
| 373 | 265 | .border { | |
| 374 | - | border: 2px solid var(--grey-light); | |
| 266 | + | border: 2px solid var(--border); | |
| 375 | 267 | } | |
| 376 | 268 | ||
| 377 | 269 | .text-left { |
| ... | ... | @@ -594,10 +486,6 @@ figure { | |
| 594 | 486 | justify-content: end; | |
| 595 | 487 | } | |
| 596 | 488 | ||
| 597 | - | .font-grey-light { | |
| 598 | - | color: var(--grey-light); | |
| 599 | - | } | |
| 600 | - | ||
| 601 | 489 | .hidden { | |
| 602 | 490 | display: none; | |
| 603 | 491 | } |
| ... | ... | @@ -606,97 +494,10 @@ figure { | |
| 606 | 494 | text-align: right; | |
| 607 | 495 | } | |
| 608 | 496 | ||
| 609 | - | /* ==== MARKDOWN ==== */ | |
| 610 | - | ||
| 611 | - | .md h1, | |
| 612 | - | .md h2, | |
| 613 | - | .md h3, | |
| 614 | - | .md h4 { | |
| 615 | - | padding: 0; | |
| 616 | - | margin: 1.5rem 0 0.9rem 0; | |
| 617 | - | font-weight: bold; | |
| 618 | - | } | |
| 619 | - | ||
| 620 | - | .md h1 a, | |
| 621 | - | .md h2 a, | |
| 622 | - | .md h3 a, | |
| 623 | - | .md h4 a { | |
| 624 | - | color: var(--grey-light); | |
| 625 | - | text-decoration: none; | |
| 626 | - | } | |
| 627 | - | ||
| 628 | - | .md h1 { | |
| 629 | - | font-size: 1.6rem; | |
| 630 | - | line-height: 1.15; | |
| 631 | - | border-bottom: 2px solid var(--grey); | |
| 632 | - | padding-bottom: 1rem; | |
| 633 | - | } | |
| 634 | - | ||
| 635 | - | .md h2 { | |
| 636 | - | font-size: 1.3rem; | |
| 637 | - | line-height: 1.15; | |
| 638 | - | color: var(--white-dark); | |
| 639 | - | } | |
| 640 | - | ||
| 641 | - | .md h3 { | |
| 642 | - | font-size: 1.2rem; | |
| 643 | - | color: var(--white-dark); | |
| 644 | - | } | |
| 645 | - | ||
| 646 | - | .md h4 { | |
| 647 | - | font-size: 1rem; | |
| 648 | - | color: var(--white-dark); | |
| 649 | - | } | |
| 650 | - | ||
| 651 | 497 | /* ==== HELPERS ==== */ | |
| 652 | 498 | ||
| 653 | - | .logo-header { | |
| 654 | - | line-height: 1; | |
| 655 | - | display: inline-block; | |
| 656 | - | background-color: #FF79C6; | |
| 657 | - | background-image: linear-gradient(to right, #FF5555, #FF79C6, #F8F859); | |
| 658 | - | color: transparent; | |
| 659 | - | background-clip: text; | |
| 660 | - | border: 3px solid #FF79C6; | |
| 661 | - | padding: 8px 10px 10px 10px; | |
| 662 | - | border-radius: 10px; | |
| 663 | - | box-shadow: 0px 5px 0px 0px var(--shadow); | |
| 664 | - | background-size: 100%; | |
| 665 | - | -webkit-background-clip: text; | |
| 666 | - | -moz-background-clip: text; | |
| 667 | - | -webkit-text-fill-color: transparent; | |
| 668 | - | -moz-text-fill-color: transparent; | |
| 669 | - | } | |
| 670 | - | ||
| 671 | - | .btn { | |
| 672 | - | border: 2px solid var(--link-color); | |
| 673 | - | color: var(--link-color); | |
| 674 | - | padding: 0.4rem 1rem; | |
| 675 | - | font-weight: bold; | |
| 676 | - | display: inline-block; | |
| 677 | - | } | |
| 678 | - | ||
| 679 | - | .btn-link:hover { | |
| 680 | - | border: 2px solid var(--hover); | |
| 681 | - | } | |
| 682 | - | ||
| 683 | - | .btn-link, | |
| 684 | - | .btn-link:visited { | |
| 685 | - | border: 2px solid var(--link-color); | |
| 686 | - | color: var(--link-color); | |
| 687 | - | padding: 0.4rem 1rem; | |
| 688 | - | text-decoration: none; | |
| 689 | - | font-weight: bold; | |
| 690 | - | display: inline-block; | |
| 691 | - | } | |
| 692 | - | ||
| 693 | - | .btn-link:visited:hover, | |
| 694 | - | .btn-link:hover { | |
| 695 | - | border: 2px solid var(--hover); | |
| 696 | - | } | |
| 697 | - | ||
| 698 | 499 | .box { | |
| 699 | - | border: 2px solid var(--grey-light); | |
| 500 | + | border: 2px solid var(--border); | |
| 700 | 501 | padding: 0.5rem 0.75rem; | |
| 701 | 502 | } | |
| 702 | 503 |