Skip to content

Commit 3c1910b

Browse files
authored
hotfix(projects): responsive status pills for mobile (#1208)
* hotfix(projects): correct the image grid src * feat(projects): implement responsive status text with hide-mobile spans Add CSS-only solution for displaying longer status text on desktop and shorter text on mobile without JavaScript or additional YAML properties. Changes: - Add .hide-mobile CSS class that hides content on mobile (< 640px) - Update status pills to use hide-mobile spans for conditional text display - "Active advocacy underway" shows full text on desktop, "Active advocacy" on mobile - "Alpha stage, approaching v1 launch" shows full text on desktop, "Alpha stage" on mobile Projects affected: - Bitcoin Builder Kit: Alpha stage, approaching v1 launch - Adopting the ₿ symbol: Active advocacy underway - Human Bitcoin Addresses: Active advocacy underway - Making Privacy Permeate: Active advocacy underway * fix(projects): improve mobile spacing and status text rendering Adjust mobile spacing and fix HTML rendering for status pills. Changes: - Fix status text spacing: move space outside hide-mobile span for proper rendering ("Active advocacy <span>underway</span>" instead of "Active advocacy<span> underway</span>") - Reduce projects-grid bottom padding on mobile from 60px to 15px - Add spacing between Funding section and first split section using adjacent sibling selector (p + .split-section) - Ensures proper spacing hierarchy: projects → funding (tight) → split sections (spaced) Affected status pills: - Adopting the ₿ symbol - Human Bitcoin Addresses - Making Privacy Permeate * fix(projects): use non-breaking space entity in hide-mobile spans Replace regular space with &nbsp; in status pills to prevent whitespace collapsing. Ensures consistent spacing between 'Active advocacy' and 'underway' on desktop. Browser whitespace collapsing rules can remove spaces at the start of inline elements like <span>. Using &nbsp; entity forces the space to always render.
1 parent 5c939e7 commit 3c1910b

2 files changed

Lines changed: 14 additions & 5 deletions

File tree

_data/projects.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ projects:
4242
key_people:
4343
- handle: "@StephenDeLorme"
4444
url: https://x.com/StephenDeLorme
45-
status: Alpha stage, approaching v1 launch
45+
status: Alpha stage<span class="hide-mobile">, approaching v1 launch</span>
4646
connect:
4747
channel: "#bitcoin-builder-kit"
4848
url: https://discord.gg/km4pzgc5aG
@@ -92,7 +92,7 @@ projects:
9292
key_people:
9393
- handle: "@matbalez"
9494
url: https://x.com/matbalez
95-
status: Active advocacy underway
95+
status: Active advocacy<span class="hide-mobile">&nbsp;underway</span>
9696
connect:
9797
channel: "#bip-177"
9898
url: https://discord.gg/amVyhmzZ3s
@@ -110,7 +110,7 @@ projects:
110110
url: https://x.com/matbalez
111111
- handle: "@ConorOkus"
112112
url: https://x.com/ConorOkus
113-
status: Active advocacy underway
113+
status: Active advocacy<span class="hide-mobile">&nbsp;underway</span>
114114
connect:
115115
channel: "#bip-353"
116116
url: https://discord.gg/Ja8ke7Kg2G
@@ -286,7 +286,7 @@ projects:
286286
key_people:
287287
- handle: "@Yashraj__"
288288
url: https://x.com/Yashraj__
289-
status: Active advocacy underway
289+
status: Active advocacy<span class="hide-mobile">&nbsp;underway</span>
290290
connect:
291291
channel: "#privacy"
292292
url: https://discord.gg/AQefTMm5hK

_sass/minima/_projects-page.scss

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -351,9 +351,18 @@
351351

352352
// Responsive
353353
@include media-query(small) {
354+
.hide-mobile {
355+
display: none;
356+
}
357+
354358
.projects-grid {
355359
gap: $spacing-unit * 2;
356-
padding: $spacing-unit * 2 0;
360+
padding: $spacing-unit * 2 0 $spacing-unit / 2 0;
361+
}
362+
363+
// Add space between funding section and first split section
364+
p + .split-section {
365+
margin-top: $spacing-unit * 3;
357366
}
358367

359368
.project-category__list {

0 commit comments

Comments
 (0)