Skip to content

Commit 8630154

Browse files
committed
feat: add forge streak symbol to widgets
1 parent 905ba07 commit 8630154

4 files changed

Lines changed: 30 additions & 4 deletions

File tree

app-demo.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -246,6 +246,12 @@ document.querySelectorAll("[data-demo-tab]").forEach((button) => {
246246
button.addEventListener("click", () => setTab(button.dataset.demoTab));
247247
});
248248

249+
if (window.location.hash) {
250+
window.setTimeout(() => {
251+
document.querySelector(window.location.hash)?.scrollIntoView();
252+
}, 80);
253+
}
254+
249255
document.querySelectorAll("[data-quick-action]").forEach((button) => {
250256
button.addEventListener("click", () => {
251257
const action = button.dataset.quickAction;
196 KB
Loading

index.html

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -214,17 +214,26 @@ <h2 id="widgets-title">Forge Fox keeps the streak visible.</h2>
214214
</div>
215215
<div class="widget-grid">
216216
<article class="fox-widget widget-hot reveal">
217-
<span class="widget-score">7</span>
217+
<span class="widget-score">
218+
<img src="assets/site/forge_streak_dumbbell.png" alt="" />
219+
<span>7</span>
220+
</span>
218221
<p>Keep it going.</p>
219222
<img src="assets/site/forgefox_streak.png" alt="Forge Fox streak widget pose" />
220223
</article>
221224
<article class="fox-widget widget-calm reveal">
222-
<span class="widget-score">92</span>
225+
<span class="widget-score">
226+
<img src="assets/site/forge_streak_dumbbell.png" alt="" />
227+
<span>92</span>
228+
</span>
223229
<p>Train today.</p>
224230
<img src="assets/site/forgefox_dumbbell.png" alt="Forge Fox dumbbell widget pose" />
225231
</article>
226232
<article class="fox-widget widget-alert reveal">
227-
<span class="widget-score">1h</span>
233+
<span class="widget-score">
234+
<img src="assets/site/forge_streak_dumbbell.png" alt="" />
235+
<span>1h</span>
236+
</span>
228237
<p>Proof window closing.</p>
229238
<img src="assets/site/forgefox_watch.png" alt="Forge Fox watch widget pose" />
230239
</article>

styles.css

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -844,11 +844,22 @@ input[type="range"] {
844844
}
845845

846846
.widget-score {
847-
display: block;
847+
display: inline-flex;
848+
align-items: center;
849+
gap: 10px;
848850
color: rgba(255, 255, 255, 0.86);
849851
font-size: 52px;
850852
line-height: 0.95;
851853
font-weight: 950;
854+
min-height: 58px;
855+
}
856+
857+
.widget-score img {
858+
width: 42px;
859+
height: 42px;
860+
object-fit: contain;
861+
flex: 0 0 42px;
862+
filter: drop-shadow(0 5px 10px rgba(0, 0, 0, 0.18));
852863
}
853864

854865
.fox-widget p {

0 commit comments

Comments
 (0)