Skip to content

Commit ac19566

Browse files
committed
Publish 2024-09-27
1 parent 2baefce commit ac19566

File tree

6 files changed

+9
-130
lines changed

6 files changed

+9
-130
lines changed

images/plus-screen-1.png

222 KB
Loading

images/plus-screen-2.png

185 KB
Loading

images/plus-screen-3.png

193 KB
Loading

images/plus-screen-4.png

187 KB
Loading

plus/index.html

Lines changed: 5 additions & 61 deletions
Original file line numberDiff line numberDiff line change
@@ -42,66 +42,10 @@ <h3 class="slogan">
4242

4343
<div class="carousel">
4444
<div class="carousel-wrapper">
45-
<template id="carousel-card-template">
46-
<div class="carousel-card__name">
47-
Dark Reader Times
48-
</div>
49-
<div class="carousel-card__date">
50-
September 25, 2024
51-
</div>
52-
<div class="carousel-card__heading">
53-
Incredible Dark Mode
54-
</div>
55-
<div class="carousel-card__article">
56-
Trusted by <strong>9,000,000 users</strong>.
57-
Rating 4.7 ★★★★★.
58-
Developed since 2014.
59-
</div>
60-
<div class="carousel-card__heading">
61-
Custom Colors
62-
</div>
63-
<div class="carousel-card__article">
64-
Set background and text color <strong>comfortable</strong> for your eyes.
65-
</div>
66-
<div class="carousel-card__heading">
67-
Premium Themes
68-
</div>
69-
<div class="carousel-card__article">
70-
Choose from professionally configured <strong>theme presets</strong>.
71-
</div>
72-
</template>
73-
<script>
74-
function insertCarouselCard() {
75-
/** @type {HTMLTemplateElement} */
76-
const template = document.getElementById('carousel-card-template');
77-
const clone = template.content.cloneNode(true);
78-
const script = document.currentScript;
79-
script.parentElement.insertBefore(clone, script.nextElementSibling);
80-
}
81-
</script>
82-
<div class="carousel-card" style="--bg: hsl(260, 30%, 10%); --text: hsl(255, 25%, 60%);">
83-
<script>
84-
insertCarouselCard();
85-
</script>
86-
</div>
87-
<div class="carousel-card" style="--bg: hsl(210, 25%, 10%); --text: hsl(80, 25%, 50%);">
88-
<script>
89-
insertCarouselCard();
90-
</script>
91-
<div class="carousel-card__app">
92-
<img src="/images/plus-palette.png">
93-
</div>
94-
</div>
95-
<div class="carousel-card" style="--bg: hsl(31, 15%, 54%); --text: hsl(0, 0%, 0%);">
96-
<script>
97-
insertCarouselCard();
98-
</script>
99-
</div>
100-
<div class="carousel-card" style="--bg: hsl(0, 0%, 0%); --text: hsl(200, 5%, 55%);">
101-
<script>
102-
insertCarouselCard();
103-
</script>
104-
</div>
45+
<img class="carousel-screenshot" src="/images/plus-screen-1.png">
46+
<img class="carousel-screenshot" src="/images/plus-screen-3.png">
47+
<img class="carousel-screenshot" src="/images/plus-screen-2.png">
48+
<img class="carousel-screenshot" src="/images/plus-screen-4.png">
10549
</div>
10650
</div>
10751

@@ -121,4 +65,4 @@ <h3 class="slogan">
12165

12266
</body>
12367

124-
</html>
68+
</html>

plus/style.css

Lines changed: 4 additions & 69 deletions
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,7 @@ footer {
143143
overflow: auto;
144144
padding-bottom: 1rem;
145145
scroll-snap-type: x mandatory;
146+
touch-action: pan-x;
146147
width: 20rem;
147148
}
148149

@@ -151,80 +152,14 @@ footer {
151152
flex-direction: row;
152153
flex-wrap: nowrap;
153154
gap: 1rem;
155+
touch-action: pan-x;
154156
}
155157

156-
.carousel-card {
157-
background-color: var(--bg);
158+
.carousel-screenshot {
158159
border: 1px solid rgb(49, 46, 58);
159160
border-radius: 1rem;
160161
box-shadow: inset 0 0 0 0.25rem black;
161-
color: var(--text);
162+
display: inline-block;
162163
flex: none;
163-
height: 20rem;
164-
overflow: hidden;
165-
position: relative;
166-
scroll-snap-align: start;
167164
width: 12rem;
168165
}
169-
170-
.carousel-card__name {
171-
font-family: serif;
172-
font-weight: 900;
173-
font-size: 1rem;
174-
font-style: italic;
175-
margin-top: 1rem;
176-
text-align: center;
177-
}
178-
179-
.carousel-card__date {
180-
background-color: color-mix(in srgb, var(--bg), var(--text) 10%);
181-
font-family: system-ui;
182-
font-weight: bold;
183-
font-size: 0.5rem;
184-
line-height: 0.5rem;
185-
margin: 0.5rem 0.25rem;
186-
padding: 0.5rem 0.75rem;
187-
position: relative;
188-
text-align: left;
189-
190-
&::after {
191-
content: "☰";
192-
display: inline-block;
193-
font-size: 0.75rem;
194-
line-height: 0.5rem;
195-
position: absolute;
196-
right: 1rem;
197-
}
198-
}
199-
200-
.carousel-card__heading {
201-
font-family: system-ui;
202-
font-weight: bold;
203-
font-size: 1rem;
204-
margin: 0.5rem 1rem;
205-
text-align: left;
206-
}
207-
208-
.carousel-card__article {
209-
color: color-mix(in srgb, var(--text), var(--bg) 20%);
210-
font-family: system-ui;
211-
font-weight: normal;
212-
font-size: 0.75rem;
213-
margin: 0 1rem;
214-
text-align: left;
215-
}
216-
217-
.carousel-card__app {
218-
background-color: black;
219-
bottom: 0;
220-
left: 0;
221-
position: absolute;
222-
text-align: center;
223-
width: 100%;
224-
225-
img {
226-
border-top: 1px solid rgb(49, 46, 58);
227-
display: inline-block;
228-
width: 95%;
229-
}
230-
}

0 commit comments

Comments
 (0)