feat(native): the TREK Cloud screens show the app and make the choice of a plan easy

The cloud screen shows real screens of the app. The plans are a choice now: one tap marks a plan, the recommended one is marked, what every plan has is said once above them, storage says how many photos it holds, and the yearly switch shows what a year saves; one button at the foot carries the chosen plan on. The claim screen names the plan with a way to change it, shows the address as it will be once it is free, ticks off the password rules while typing, says in three words where the servers are, that it can be cancelled and that there are no ads, and puts the photo behind the form away.
This commit is contained in:
Maurice
2026-11-12 10:04:31 +01:00
parent 3c0c3b3f6e
commit 46b9df54bf
33 changed files with 797 additions and 101 deletions
Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

+201 -33
View File
@@ -6,9 +6,11 @@ import { StatusBar, Style } from '@capacitor/status-bar';
import logoUrl from '../public/icons/icon-white.svg';
import logoBlack from '../public/logo-dark.svg'; // #000 wordmark, for light backgrounds
import logoWhite from '../public/logo-light.svg'; // #fff wordmark, for dark backgrounds
import previewImage from './img/preview.webp'; // real app screens, from docs/screenshots/showcase-mobile.webp
import { AUTH_GATE_NAMES, canSignInInApp, type AuthGate } from '../src/native/authGate';
import { opensSoon, refundedBeforeOpening } from '../src/native/cloudOrders';
import { fakeIapClient, getIapClient, productIdFor, type Purchase } from '../src/native/iap';
import { priceValue } from '../src/native/priceValue';
import {
AUTH_PROXY_DOCS_URL,
CLIENT_CERT_DOCS_URL,
@@ -27,7 +29,7 @@ import {
type ProbeFailure,
type ProbeGet,
} from '../src/native/serverAddress';
import { passwordProblem } from '../../shared/src/auth/password-policy';
import { PASSWORD_MIN_LENGTH, passwordProblem, passwordRuleStates } from '../../shared/src/auth/password-policy';
import { TrekShell, type ClientCertificateFailure } from '../src/native/trekShell';
import { directionOf, pickLocale, translator } from './i18n';
import './shell.css';
@@ -150,6 +152,7 @@ const I = {
bolt: 'M13 2 4 14h7l-1 8 9-12h-7z',
shield: 'M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10',
check: 'M20 6 9 17l-5-5',
camera: 'M14.5 4h-5L7 7H4a2 2 0 0 0-2 2v9a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V9a2 2 0 0 0-2-2h-3l-2.5-3zM12 17a4 4 0 1 0 0-8 4 4 0 0 0 0 8z',
};
async function tap(style: ImpactStyle = ImpactStyle.Light): Promise<void> {
@@ -188,6 +191,8 @@ function show(screen: HTMLElement, opts: { back?: boolean } = {}): void {
}
root.append(screen);
current = screen;
// A form reads on a calm page: the photo steps back while it is on screen.
document.body.classList.toggle('quiet', screen.classList.contains('screen-quiet'));
}
function externalLink(text: string, href: string): HTMLAnchorElement {
@@ -533,7 +538,8 @@ function showCloud(opts: { back?: boolean } = {}): void {
showPlans();
});
const have = el('button', { type: 'button', className: 'linkbtn' }, t('native.cloud.haveServer'));
// The way out for someone who already runs TREK: there, but quieter than the way in.
const have = el('button', { type: 'button', className: 'linkbtn linkbtn-quiet' }, t('native.cloud.haveServer'));
have.addEventListener('click', () => {
void tap();
showConnect();
@@ -557,6 +563,12 @@ function showCloud(opts: { back?: boolean } = {}): void {
el('p', { className: 'sub' }, t('native.cloud.sub')),
],
[
// The app itself, as it runs on TREK Cloud: real screens, nothing drawn for the purpose.
el(
'div',
{ className: 'cloud-preview' },
el('img', { src: previewImage, alt: '', loading: 'lazy', decoding: 'async' })
),
el(
'div',
{ className: 'features' },
@@ -652,34 +664,58 @@ async function loadOffer(list: CloudPlans): Promise<Offer> {
return { canBuy, storePrices: await iap.prices(ids), opensSoon: soon };
}
function planCard(plan: CloudPlan, interval: 'month' | 'year', offer: Offer): HTMLElement {
const { label, buyable } = offerFor(offer, plan, interval);
/** The plan the picker starts on and marks: the smallest one with AI documents, the one most trips want. */
function recommendedPlan(plans: CloudPlan[]): CloudPlan | undefined {
return plans.find((p) => p.aiDocuments > 0) ?? plans[0];
}
/**
* What a year saves against twelve months, in whole percent, rounded down so
* the badge never promises more than the price gives. From the store's own price
* strings where both parse (the buyer's currency), else from the plan list.
*/
function yearlySaving(plans: CloudPlan[], offer: Offer): number | null {
const savings = plans.map((plan) => {
const month = priceValue(offer.storePrices?.get(productIdFor(plan.id, 'month'))) ?? plan.monthlyCents;
const year = priceValue(offer.storePrices?.get(productIdFor(plan.id, 'year'))) ?? plan.yearlyCents;
if (!month || !year) return null;
return Math.floor((1 - year / (month * 12)) * 100);
});
if (savings.some((v) => v === null)) return null;
const least = Math.min(...(savings as number[]));
return least >= 5 ? least : null;
}
function planCard(
plan: CloudPlan,
interval: 'month' | 'year',
offer: Offer,
opts: { recommended: boolean; selected: boolean; onSelect?: () => void }
): HTMLElement {
const { label } = offerFor(offer, plan, interval);
const per = interval === 'year' ? t('native.plans.perYear') : t('native.plans.perMonth');
const feat = (text: string) => el('span', {}, icon(I.check, 16), text);
const feat = (text: string, extra?: Node) => el('span', {}, icon(I.check, 16), text, ...(extra ? [extra] : []));
// An absent feature (e.g. a plan with no AI documents): a muted dash, not a
// green tick, so "none" never reads as a perk.
const featOff = (text: string) => el('span', { className: 'off' }, icon('M5 12h14', 16), text);
let sub: HTMLElement | null = null;
if (buyable) {
const button = el('button', { type: 'button', className: 'btn' }, t('native.plans.subscribe'));
sub = button;
button.addEventListener('click', async () => {
void tap(ImpactStyle.Medium);
// A store account with a running subscription buys nothing more: say so before the form.
button.disabled = true;
const held = await iap.held();
button.disabled = false;
if (held) showSubscribed();
else showClaim(plan, interval, `${label} ${per}`);
});
}
return el(
'div',
{ className: 'plan' },
// About 3 MB a photo, as a phone takes them: a size people can picture, as a
// camera and a number, which needs no words in any language.
const photos = el(
'small',
{ className: 'plan-photos' },
icon(I.camera, 13),
`≈ ${new Intl.NumberFormat(locale).format(plan.storageGb * 300)}`
);
const body = [
el(
'div',
{ className: 'plan-top' },
el('span', { className: 'plan-name' }, plan.name),
el(
'span',
{ className: 'plan-name' },
plan.name,
...(opts.recommended ? [el('span', { className: 'plan-badge' }, t('native.plans.recommended'))] : [])
),
// No price yet (orders not open): the plan shows without one rather than with an empty one.
// The price is figures and a currency sign: one left-to-right run, so Arabic
// keeps "5,99 €" whole, with the period standing apart beside it.
@@ -688,14 +724,24 @@ function planCard(plan: CloudPlan, interval: 'month' | 'year', offer: Offer): HT
el(
'div',
{ className: 'plan-feats' },
feat(t('native.plans.unlimited')),
feat(t('native.plans.storage', { n: String(plan.storageGb) })),
feat(t('native.plans.storage', { n: String(plan.storageGb) }), photos),
plan.aiDocuments > 0
? feat(t('native.plans.aiDocs', { n: String(plan.aiDocuments) }))
: featOff(t('native.plans.noAi'))
),
...(sub ? [sub] : [])
);
];
const className = `plan${opts.recommended ? ' featured' : ''}${opts.selected ? ' selected' : ''}`;
if (!opts.onSelect) return el('div', { className }, ...body);
// A choice among the plans, as radio buttons are: the one button below acts on it.
const card = el('button', { type: 'button', className }, el('span', { className: 'plan-radio' }), ...body);
card.setAttribute('role', 'radio');
card.setAttribute('aria-checked', String(opts.selected));
const select = opts.onSelect;
card.addEventListener('click', () => {
void tap();
select();
});
return card;
}
/**
@@ -784,23 +830,62 @@ function showPlans(opts: { back?: boolean } = {}): void {
let interval: 'month' | 'year' = 'month';
let plans: CloudPlan[] | null = null;
let offer: Offer = { canBuy: false, storePrices: null, opensSoon: false };
let selectedId: string | null = null;
const content = el('div', { className: 'loading' }, el('span', { className: 'spinner' }));
const footer = el('div', { className: 'plans-foot' });
// What every plan has, said once above them, so the cards show only what differs.
const everyPlan = el('p', { className: 'plans-every', hidden: true }, icon(I.check, 16), t('native.plans.everyPlan'));
const monthBtn = el('button', { type: 'button' }, t('native.plans.monthly'));
const yearBtn = el('button', { type: 'button' }, t('native.plans.yearly'));
const saveBadge = el('span', { className: 'save', hidden: true });
const yearBtn = el('button', { type: 'button' }, t('native.plans.yearly'), saveBadge);
const seg = el('div', { className: 'segmented' }, monthBtn, yearBtn);
// The one way on, kept in reach at the foot of the screen while the plans scroll.
const ctaName = el('span', { className: 'btn-label' });
const ctaPrice = el('small', {});
const cta = el('button', { type: 'button', className: 'btn plans-go' }, el('span', { className: 'btn-row' }, el('b', {}, ctaName), ctaPrice), icon(I.chevron, 20, 'chev'));
const ctaBar = el('div', { className: 'plans-cta', hidden: true }, cta);
const selected = (): CloudPlan | undefined => plans?.find((p) => p.id === selectedId);
const paintSeg = () => {
monthBtn.setAttribute('aria-pressed', String(interval === 'month'));
yearBtn.setAttribute('aria-pressed', String(interval === 'year'));
};
const paintCta = () => {
const plan = selected();
const buyable = plan ? offerFor(offer, plan, interval).buyable : false;
ctaBar.hidden = !buyable;
if (!plan || !buyable) return;
const { label } = offerFor(offer, plan, interval);
const per = interval === 'year' ? t('native.plans.perYear') : t('native.plans.perMonth');
ctaName.textContent = t('native.plans.continueWith', { plan: plan.name });
ctaPrice.textContent = `${label} ${per}`;
};
const renderList = () => {
const list = plans;
if (!list) return;
const recommended = recommendedPlan(list);
content.className = 'plans';
content.replaceChildren(...list.map((p) => planCard(p, interval, offer)));
content.setAttribute('role', 'radiogroup');
content.setAttribute('aria-label', t('native.plans.title'));
content.replaceChildren(
...list.map((p) =>
planCard(p, interval, offer, {
recommended: p.id === recommended?.id,
selected: p.id === selectedId,
// Only a plan that can be bought here is a choice; a closed shop shows them as they are.
onSelect: offerFor(offer, p, interval).buyable
? () => {
selectedId = p.id;
renderList();
}
: undefined,
})
)
);
paintCta();
};
const choose = (next: 'month' | 'year') => {
if (interval === next) return;
@@ -813,11 +898,35 @@ function showPlans(opts: { back?: boolean } = {}): void {
yearBtn.addEventListener('click', () => choose('year'));
paintSeg();
cta.addEventListener('click', async () => {
const plan = selected();
if (!plan) return;
void tap(ImpactStyle.Medium);
// A store account with a running subscription buys nothing more: say so before the form.
cta.disabled = true;
const held = await iap.held();
cta.disabled = false;
if (held) {
showSubscribed();
return;
}
const { label } = offerFor(offer, plan, interval);
const per = interval === 'year' ? t('native.plans.perYear') : t('native.plans.perMonth');
showClaim(plan, interval, `${label} ${per}`);
});
const load = async () => {
const list = await fetchPlans();
if (list) {
offer = await loadOffer(list);
plans = list.plans;
selectedId = recommendedPlan(list.plans)?.id ?? null;
const saving = yearlySaving(list.plans, offer);
if (saving !== null) {
saveBadge.textContent = `−${new Intl.NumberFormat(locale, { style: 'percent' }).format(saving / 100)}`;
saveBadge.hidden = false;
}
everyPlan.hidden = false;
renderList();
footer.replaceChildren(...planFooter(offer, list.plans));
return;
@@ -844,7 +953,7 @@ function showPlans(opts: { back?: boolean } = {}): void {
el('p', { className: 'sub' }, t('native.plans.sub')),
seg,
],
[content, footer]
[everyPlan, content, ctaBar, footer]
)
),
opts
@@ -1002,7 +1111,31 @@ function showClaim(
passwordInput.dir = 'ltr';
passwordInput.classList.add('ltr-value');
const passwordField = el('div', { className: 'field' }, passwordInput);
const passwordHint = el('p', { className: 'hint' }, t('native.claim.passwordHint'));
// Shown when the server's list knows the password, or on a send with a rule unmet.
const passwordHint = el('p', { className: 'hint', hidden: true }, t('native.claim.passwordHint'));
// The rules, each ticked off as it is met, rather than a paragraph to read.
const ruleLabels = {
// The number outside the words: it is always the same, and the word reads after it in every language.
length: `${PASSWORD_MIN_LENGTH}+ ${t('native.claim.ruleLength')}`,
upper: t('native.claim.ruleUpper'),
lower: t('native.claim.ruleLower'),
digit: t('native.claim.ruleDigit'),
special: t('native.claim.ruleSpecial'),
} as const;
const ruleItems = (Object.keys(ruleLabels) as (keyof typeof ruleLabels)[]).map((rule) => ({
rule,
node: el('span', {}, icon(I.check, 13), ruleLabels[rule]),
}));
const passwordRules = el('div', { className: 'pw-rules' }, ...ruleItems.map((r) => r.node));
const paintRules = () => {
const states = passwordRuleStates(passwordInput.value);
for (const { rule, node } of ruleItems) node.classList.toggle('met', states[rule]);
};
passwordInput.addEventListener('input', () => {
paintRules();
passwordHint.hidden = true;
passwordHint.className = 'hint';
});
// The § 327h agreement, asked on its own before anything is bought.
let consent: DeviationsConsent | null = null;
@@ -1026,6 +1159,19 @@ function showClaim(
void loadConsent();
const submit = el('button', { type: 'submit', className: 'btn' }, t('native.claim.subscribe', { price }));
// What is about to be bought, so nobody pays for a plan they did not mean.
const change = el('button', { type: 'button', className: 'linkbtn' }, t('native.claim.change'));
change.addEventListener('click', () => {
void tap();
showPlans({ back: true });
});
const planSummary = el(
'div',
{ className: 'claim-plan' },
el('span', {}, el('b', {}, `TREK Cloud ${plan.name}`), el('bdi', { dir: 'ltr' }, price)),
// A purchase already made is not a choice any more.
...(bought ? [] : [change])
);
const error = el('p', { className: 'error', role: 'alert' });
const form = el(
'form',
@@ -1035,6 +1181,7 @@ function showClaim(
emailField,
el('p', { className: 'hint' }, t('native.claim.emailHint')),
passwordField,
passwordRules,
passwordHint,
// Our terms govern the instance (terms § 5a): named before the purchase, not only in the confirmation mail.
el(
@@ -1045,6 +1192,13 @@ function showClaim(
externalLink(t('native.plans.ourTerms'), CLOUD_TERMS_URL)
),
consentField,
el(
'div',
{ className: 'trust' },
el('span', {}, icon(I.globe, 15), t('native.claim.trustServers')),
el('span', {}, icon(I.check, 15), t('native.claim.trustCancel')),
el('span', {}, icon(I.shield, 15), t('native.claim.trustNoAds'))
),
submit,
error
);
@@ -1080,8 +1234,18 @@ function showClaim(
const result = await slugStatus(value);
if (slugInput.value.trim().toLowerCase() !== value) return;
status = result;
slugNote.textContent = noteFor[result] ?? '';
slugNote.className = `hint ${result === 'available' ? 'ok' : result === 'error' ? '' : 'bad'}`;
if (result === 'available') {
// The address as it will be, the moment it is theirs to take.
slugNote.className = 'hint ok slug-free';
slugNote.replaceChildren(
icon(I.check, 16),
el('bdi', { dir: 'ltr' }, `${value}${cloudSuffix()}`),
el('small', {}, noteFor.available ?? '')
);
return;
}
slugNote.textContent = noteFor[result] ?? '';
}, 350);
});
@@ -1110,10 +1274,12 @@ function showClaim(
const password = passwordInput.value;
if (passwordProblem(password) || password.length > 128) {
shake(passwordField);
passwordHint.hidden = false;
passwordHint.className = 'hint bad';
passwordInput.focus();
return;
}
passwordHint.hidden = true;
passwordHint.className = 'hint';
// Nothing is bought without the agreement on the text the server holds today.
if (!consent && !(await loadConsent())) {
@@ -1191,6 +1357,7 @@ function showClaim(
} else if (redeemed.code === 'password-weak') {
// A common password the list on the server knows: the purchase waits, unredeemed, for a better one.
shake(passwordField);
passwordHint.hidden = false;
passwordHint.className = 'hint bad';
} else {
error.textContent = refundedBeforeOpening(redeemed.code, onPlay)
@@ -1202,12 +1369,13 @@ function showClaim(
show(
el(
'div',
{},
{ className: 'screen-quiet' },
...columns(
[
topbar(() => showPlans({ back: true })),
el('h1', { className: 'title-sm' }, t('native.claim.title')),
el('p', { className: 'sub' }, t('native.claim.sub')),
planSummary,
],
[form]
)
+226 -12
View File
@@ -236,8 +236,9 @@ body::after {
background:
linear-gradient(180deg, var(--veil-top) 0%, var(--veil-mid) 62%, var(--bg) 100%),
url('./img/kyoto.webp') left 28% / cover no-repeat;
-webkit-mask-image: linear-gradient(90deg, #000 0%, #000 40%, transparent 80%);
mask-image: linear-gradient(90deg, #000 0%, #000 40%, transparent 80%);
/* A long, soft hand-over to the grid: a short one read as an edge. */
-webkit-mask-image: linear-gradient(90deg, #000 0%, #000 22%, transparent 96%);
mask-image: linear-gradient(90deg, #000 0%, #000 22%, transparent 96%);
pointer-events: none;
z-index: 0;
}
@@ -246,8 +247,8 @@ body::after {
background-position:
0 0,
right 28%;
-webkit-mask-image: linear-gradient(270deg, #000 0%, #000 40%, transparent 80%);
mask-image: linear-gradient(270deg, #000 0%, #000 40%, transparent 80%);
-webkit-mask-image: linear-gradient(270deg, #000 0%, #000 22%, transparent 96%);
mask-image: linear-gradient(270deg, #000 0%, #000 22%, transparent 96%);
}
:root[dir='rtl'] body::before {
-webkit-mask-image: radial-gradient(135% 95% at 0% 0%, #000 34%, transparent 80%);
@@ -967,7 +968,9 @@ a.linkbtn {
.plans {
display: flex;
flex-direction: column;
gap: 12px;
gap: 14px;
/* Room for the badge that sits on the first card's top edge. */
padding-top: 4px;
}
.plan {
border: 1px solid var(--edge);
@@ -1036,15 +1039,94 @@ a.linkbtn {
.plan-feats .off svg {
color: var(--faint);
}
.plan .btn {
/* A plan is a choice, as a radio button is: the whole card takes the tap. */
button.plan {
font: inherit;
color: inherit;
text-align: start;
width: 100%;
min-height: 48px;
padding: 13px;
cursor: pointer;
position: relative;
padding-inline-start: 48px;
}
.plan:not(.featured) .btn {
background: var(--surface-2);
color: var(--ink);
border-color: var(--edge);
.plan-radio {
position: absolute;
inset-inline-start: 16px;
top: 19px;
width: 20px;
height: 20px;
border-radius: 50%;
border: 1.5px solid var(--edge-strong);
transition:
border-color 0.2s,
border-width 0.2s var(--ease);
}
.plan.selected {
border-color: var(--ink);
box-shadow:
0 0 0 1px var(--ink),
0 14px 34px -14px var(--wash-1-a85),
0 2px 8px -3px rgba(0, 0, 0, 0.35);
}
.plan.selected .plan-radio {
border: 6px solid var(--ink);
}
/* Pinned to the card's top edge, so the name and the price keep their line. */
.plan {
position: relative;
}
.plan-badge {
position: absolute;
top: -9px;
inset-inline-end: 16px;
padding: 2px 9px;
border-radius: 999px;
background: var(--accent);
color: var(--accent-ink);
font-size: 0.68rem;
font-weight: 600;
letter-spacing: 0.02em;
}
.plan-feats small {
color: var(--faint);
font-size: 0.8rem;
margin-inline-start: 2px;
}
.plan-feats {
margin-bottom: 0;
}
/* What every plan has, once above the cards. */
.plans-every {
display: flex;
align-items: center;
gap: 8px;
margin: 0 2px;
color: var(--muted);
font-size: 0.88rem;
}
.plans-every svg {
flex: none;
color: var(--ok);
}
/* The one button on, held at the foot of the screen over a fade while the plans scroll. */
.plans-cta {
position: sticky;
bottom: 0;
z-index: 2;
margin: 0 -2px;
padding: 18px 2px calc(env(safe-area-inset-bottom, 0px) + 10px);
background: linear-gradient(to bottom, transparent, var(--bg) 38%);
}
.plans-cta .btn {
width: 100%;
justify-content: space-between;
border-radius: 22px;
padding-inline: 22px 18px;
}
.plans-cta .btn-row small {
opacity: 0.72;
}
.loading {
@@ -1342,3 +1424,135 @@ a.linkbtn {
border-color: var(--danger);
animation: shake 0.35s;
}
/* ── Claim: what is bought, the address as it will be, the password rules ── */
/* A form reads on a calm page: the photo steps back while one is on screen. */
body::after {
transition: opacity 0.4s var(--ease);
}
body.quiet::after {
opacity: 0;
}
.claim-plan {
display: flex;
align-items: center;
justify-content: space-between;
gap: 12px;
margin-top: 4px;
padding: 12px 14px 12px 16px;
border: 1px solid var(--edge);
border-radius: var(--radius);
background: var(--surface);
}
.claim-plan > span {
display: flex;
flex-direction: column;
gap: 1px;
min-width: 0;
}
.claim-plan b {
font-weight: 650;
}
.claim-plan bdi {
color: var(--muted);
font-size: 0.88rem;
}
.claim-plan .linkbtn {
flex: none;
}
.slug-free {
display: flex;
align-items: center;
gap: 7px;
flex-wrap: wrap;
}
.slug-free bdi {
color: var(--ink);
font-weight: 600;
}
.slug-free small {
font-size: inherit;
}
.pw-rules {
display: flex;
flex-wrap: wrap;
gap: 6px;
margin: -4px 0 0;
}
.pw-rules span {
display: inline-flex;
align-items: center;
gap: 5px;
padding: 4px 10px 4px 8px;
border-radius: 999px;
background: var(--surface);
border: 1px solid var(--edge);
color: var(--faint);
font-size: 0.78rem;
transition:
color 0.2s,
background 0.2s,
border-color 0.2s;
}
.pw-rules svg {
opacity: 0.35;
transition: opacity 0.2s;
}
.pw-rules .met {
color: var(--ok);
background: var(--ok-a16);
border-color: transparent;
}
.pw-rules .met svg {
opacity: 1;
}
/* Three short facts right above the purchase. */
.trust {
display: flex;
flex-wrap: wrap;
justify-content: center;
gap: 6px 16px;
color: var(--muted);
font-size: 0.8rem;
}
.trust span {
display: inline-flex;
align-items: center;
gap: 6px;
}
.trust svg {
flex: none;
color: var(--ok);
}
/* ── Cloud: the app itself, and a quieter way out ── */
.cloud-preview {
margin: 2px -8px 4px;
border-radius: 22px;
overflow: hidden;
aspect-ratio: 720 / 562;
background: var(--surface);
box-shadow:
0 24px 50px -24px var(--wash-1-a85),
0 2px 10px -4px rgba(0, 0, 0, 0.35),
inset 0 0 0 1px var(--ink-a4);
}
.cloud-preview img {
display: block;
width: 100%;
height: 100%;
object-fit: cover;
}
.linkbtn-quiet {
font-size: 0.86rem;
color: var(--faint);
padding-top: 4px;
}
.plan-photos {
display: inline-flex;
align-items: center;
gap: 4px;
}
.plan-feats .plan-photos svg {
color: var(--faint);
}