Skip to content

Commit a3bda47

Browse files
authored
feat(advent-of-code): port from catppucccin (#34)
* feat(advent-of-code): port from catppucccin * fix(advent-of-code): update colors and add optional custom font var * fix(advent-of-code): correct font var * docs(advent-of-code): add previews * docs: add link in main readme * style: deno fmt * style: format readme * fix: correct update url
1 parent cd226c6 commit a3bda47

4 files changed

Lines changed: 316 additions & 0 deletions

File tree

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@
6161
- [YouTube](https://github.com/rose-pine/userstyles/tree/main/styles/youtube)
6262
- [NixOS-Search](https://github.com/rose-pine/userstyles/tree/main/styles/nixos-search)
6363
- [status.cafe](https://github.com/rose-pine/userstyles/tree/main/styles/status.cafe)
64+
- [Advent of Code](https://github.com/rose-pine/userstyles/tree/main/styles/advent-of-code)
6465

6566
## Contributing
6667

styles/advent-of-code/license

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
This theme includes code from the original theme Catppuccin, which is licensed under the MIT License:
2+
3+
Catppuccin MIT License
4+
5+
Copyright (c) 2021 Catppuccin
6+
7+
Permission is hereby granted, free of charge, to any person obtaining a copy
8+
of this software and associated documentation files (the "Software"), to deal
9+
in the Software without restriction, including without limitation the rights
10+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
11+
copies of the Software, and to permit persons to whom the Software is
12+
furnished to do so, subject to the following conditions:
13+
14+
The above copyright notice and this permission notice shall be included in all
15+
copies or substantial portions of the Software.
16+
17+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
18+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
19+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
20+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
21+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
22+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
23+
SOFTWARE.
24+
25+
All modifications and additions to the original theme are licensed under the MIT License:
26+
27+
Rosé Pine MIT License
28+
29+
Copyright (c) 2024 Rosé Pine
30+
31+
Permission is hereby granted, free of charge, to any person obtaining a copy
32+
of this software and associated documentation files (the "Software"), to deal
33+
in the Software without restriction, including without limitation the rights
34+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
35+
copies of the Software, and to permit persons to whom the Software is
36+
furnished to do so, subject to the following conditions:
37+
38+
The above copyright notice and this permission notice shall be included in all
39+
copies or substantial portions of the Software.
40+
41+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
42+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
43+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
44+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
45+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
46+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
47+
SOFTWARE.

styles/advent-of-code/readme.md

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
<p align="center">
2+
<img src="https://github.com/rose-pine/rose-pine-theme/raw/main/assets/icon.png" width="80" />
3+
<h2 align="center">Rosé Pine for Advent of Code</h2>
4+
</p>
5+
6+
<p align="center">All natural pine, faux fur and a bit of soho vibes for the classy minimalist</p>
7+
8+
<p align="center">
9+
<a href="https://github.com/rose-pine/rose-pine-theme">
10+
<img src="https://img.shields.io/badge/community-rosé%20pine-26233a?labelColor=191724&logo=data:image/svg+xml;base64,PHN2ZyB3aWR0aD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I2IDYwLjk3ODlaIiBmaWxsPSIjRUJCQ0JBIi8+Cjwvc3ZnPgo=&style=for-the-badge" />
11+
</a>
12+
<a href="https://github.com/rose-pine/userstyles/raw/main/advent-of-code/rose-pine.user.less"><img src="https://img.shields.io/badge/stylus-install-cba6f7?colorA=363a4f&style=for-the-badge"></a>
13+
</p>
14+
15+
## Usage
16+
17+
1. Make sure you have the [Stylus](https://github.com/openstyles/stylus) browser
18+
extension installed, then visit
19+
[this link](https://github.com/rose-pine/userstyles/raw/main/styles/advent-of-code/rose-pine.user.less)
20+
2. Configure your preferred accent color and theme variant
21+
3. Click install on the top left
22+
23+
## Gallery
24+
25+
![Rosé Pine](https://imgur.com/736foDh.png)
26+
![Rosé Pine Moon](https://imgur.com/sRxZkYl.png)
27+
![Rosé Pine Dawn](https://imgur.com/Ep8MqEM.png)
28+
29+
## Thanks to
30+
31+
- [Catppuccin Org](https://github.com/catppuccin)
32+
- [adriankarlen](https://github.com/adriankarlen)
Lines changed: 236 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,236 @@
1+
/* ==UserStyle==
2+
@name Rosé Pine for Advent of Code
3+
@description Soho vibes for Advent of Code
4+
@version 1.0.0
5+
@license MIT
6+
@author Rosé Pine (https://github.com/rose-pine)
7+
@namespace https://github.com/rose-pine
8+
@homepageURL https://github.com/rose-pine/userstyles
9+
@updateURL https://github.com/rose-pine/userstyles/raw/main/styles/advent-of-code/rose-pine.user.less
10+
@preprocessor less
11+
12+
@var select lightVariant "Light Variant" ["main:Rosé Pine", "moon:Rosé Pine Moon", "dawn:Rosé Pine Dawn*"]
13+
@var select darkVariant "Dark Variant" ["main:Rosé Pine*", "moon:Rosé Pine Moon", "dawn:Rosé Pine Dawn"]
14+
@var text fontFamily "Font family" "'Source Code Pro'"
15+
==/UserStyle== */
16+
17+
@-moz-document domain("adventofcode.com") {
18+
:root {
19+
@media (prefers-color-scheme: light) {
20+
#rose-pine(@lightVariant);
21+
}
22+
@media (prefers-color-scheme: dark) {
23+
#rose-pine(@darkVariant);
24+
}
25+
}
26+
27+
:root[data-theme="dark"] {
28+
#rose-pine(@darkVariant);
29+
}
30+
:root[data-theme="light"] {
31+
#rose-pine(@lightVariant);
32+
}
33+
34+
#rose-pine(@variant) {
35+
@base: @rose-pine[@@variant][@base];
36+
@surface: @rose-pine[@@variant][@surface];
37+
@overlay: @rose-pine[@@variant][@overlay];
38+
@muted: @rose-pine[@@variant][@muted];
39+
@subtle: @rose-pine[@@variant][@subtle];
40+
@text: @rose-pine[@@variant][@text];
41+
@love: @rose-pine[@@variant][@love];
42+
@gold: @rose-pine[@@variant][@gold];
43+
@rose: @rose-pine[@@variant][@rose];
44+
@pine: @rose-pine[@@variant][@pine];
45+
@foam: @rose-pine[@@variant][@foam];
46+
@iris: @rose-pine[@@variant][@iris];
47+
@highlightLow: @rose-pine[@@variant][@highlightLow];
48+
@highlightMed: @rose-pine[@@variant][@highlightMed];
49+
@highlightHigh: @rose-pine[@@variant][@highlightHigh];
50+
color-scheme: if(@variant = dawn, light, dark);
51+
52+
body {
53+
background: @base;
54+
color: @text;
55+
font-family: @fontFamily, monospace;
56+
57+
header h1 a,
58+
header h1 span {
59+
color: @pine;
60+
text-shadow: 0 0 2px @pine, 0 0 5px @pine;
61+
}
62+
63+
a {
64+
color: @pine;
65+
}
66+
67+
.star-count,
68+
.privboard-star-both {
69+
color: @gold;
70+
}
71+
72+
.quiet {
73+
color: @muted;
74+
opacity: 1;
75+
}
76+
77+
.share,
78+
.share:hover,
79+
input[type="submit"] {
80+
color: @pine;
81+
}
82+
83+
main {
84+
article {
85+
em {
86+
color: @text;
87+
text-shadow: 0 0 5px @text;
88+
}
89+
90+
h2 {
91+
color: @text;
92+
}
93+
94+
input[type="radio"]:checked ~ span,
95+
input[type="checkbox"]:checked ~ span {
96+
color: @text;
97+
}
98+
99+
input[type="radio"] ~ span:hover,
100+
input[type="radio"] ~ span:focus,
101+
input[type="checkbox"]:hover ~ span,
102+
input[type="checkbox"]:focus ~ span {
103+
background-color: @base;
104+
}
105+
}
106+
.supporter-badge {
107+
color: @gold;
108+
}
109+
110+
.supporter-badge:hover {
111+
color: @gold;
112+
text-shadow: 0 0 5px @gold;
113+
}
114+
115+
.sponsor-badge {
116+
color: @foam;
117+
}
118+
119+
.sponsor-badge:hover,
120+
.sponsor-badge:focus {
121+
color: @foam;
122+
text-shadow: 0 0 5px @foam;
123+
}
124+
125+
.leaderboard-entry {
126+
.leaderboard-position {
127+
color: @subtle;
128+
}
129+
.leaderboard-totalscore {
130+
color: @text;
131+
}
132+
}
133+
134+
.leaderboard-daylinks-selected {
135+
color: @text;
136+
text-shadow: 0 0 5px @text;
137+
}
138+
139+
.leaderboard-daylinks-selected:hover {
140+
color: @pine;
141+
}
142+
143+
.leaderboard-anon {
144+
opacity: 1;
145+
color: @muted;
146+
}
147+
.calendar {
148+
.calendar-color-w {
149+
color: @text;
150+
}
151+
.calendar-color-s {
152+
color: @gold;
153+
}
154+
.calendar-color-c {
155+
color: @subtle;
156+
}
157+
.calendar-color-g3 {
158+
color: darken(@pine, 3%);
159+
}
160+
.calendar-color-g2 {
161+
color: @pine;
162+
}
163+
.calendar-color-g4 {
164+
color: darken(@pine, 3.5%);
165+
}
166+
.calendar-color-u {
167+
color: @foam;
168+
}
169+
.calendar-color-a {
170+
color: @muted;
171+
}
172+
.calendar-color-g1 {
173+
color: darken(@pine, 2.5%);
174+
}
175+
.calendar-color-g0 {
176+
color: darken(@pine, 2%);
177+
}
178+
.calendar-color-l {
179+
color: @love;
180+
}
181+
.calendar-mark-complete {
182+
color: @gold;
183+
}
184+
.calendar-mark-verycomplete {
185+
color: @gold;
186+
}
187+
.calendar-day {
188+
color: @subtle;
189+
}
190+
#calendar-countdown {
191+
color: @subtle;
192+
}
193+
194+
span {
195+
color: @surface;
196+
}
197+
198+
a {
199+
color: @surface;
200+
}
201+
}
202+
203+
.day-success {
204+
color: @gold;
205+
text-shadow: 0 0 5px @gold;
206+
}
207+
208+
.stats-both {
209+
color: @gold;
210+
}
211+
212+
.stats-firstonly {
213+
color: @overlay;
214+
}
215+
216+
a:hover {
217+
background-color: @overlay !important;
218+
}
219+
220+
input[type="text"],
221+
textarea,
222+
code::before {
223+
border-color: @highlightMed;
224+
background: @base;
225+
}
226+
}
227+
}
228+
}
229+
}
230+
231+
/* deno-fmt-ignore */
232+
@rose-pine: {
233+
@main: { @base: #191724; @surface: #1f1d2e; @overlay: #26233a; @muted: #6e6a86; @subtle: #908caa; @text: #e0def4; @love: #eb6f92; @gold: #f6c177; @rose: #ebbcba; @pine: #31748f; @foam: #9ccfd8; @iris: #c4a7e7; @highlightLow: #21202e; @highlightMed: #403d52; @highlightHigh: #524f67; };
234+
@moon: { @base: #232136; @surface: #2a273f; @overlay: #393552; @muted: #6e6a86; @subtle: #908caa; @text: #e0def4; @love: #eb6f92; @gold: #f6c177; @rose: #ea9a97; @pine: #3e8fb0; @foam: #9ccfd8; @iris: #c4a7e7; @highlightLow: #2a283e; @highlightMed: #44415a; @highlightHigh: #56526e; };
235+
@dawn: { @base: #faf4ed; @surface: #fffaf3; @overlay: #f2e9e1; @muted: #9893a5; @subtle: #797593; @text: #575279; @love: #b4637a; @gold: #ea9d34; @rose: #d7827e; @pine: #286983; @foam: #56949f; @iris: #907aa9; @highlightLow: #f4ede8; @highlightMed: #dfdad9; @highlightHigh: #cecacd; };
236+
};

0 commit comments

Comments
 (0)