Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion src/i18n/en.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ export const en: Copy = {
stats: [
{ label: 'Based in', value: 'Vienna, Austria' },
{ label: 'Working', value: 'Remote or hybrid', tone: 'now' },
{ label: 'Background', value: 'Web design & UI', tone: 'root' },
{ label: 'Languages', value: 'IT · EN · DE in progress' },
],
intro:
Expand Down
1 change: 0 additions & 1 deletion src/i18n/it.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ export const it: Copy = {
stats: [
{ label: 'Dove vivo', value: 'Vienna, Austria' },
{ label: 'Come lavoro', value: 'Remoto o ibrido', tone: 'now' },
{ label: 'Percorso', value: 'Web design e UI', tone: 'root' },
{ label: 'Lingue', value: 'IT · EN · DE in corso' },
],
intro:
Expand Down
9 changes: 5 additions & 4 deletions tests/e2e/homepage.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -79,8 +79,10 @@ for (const locale of ['en', 'it'] as const) {
expect(await img.evaluate((el: HTMLImageElement) => el.naturalWidth)).toBeGreaterThan(0);
});

test('lists the four facts', async ({ page }) => {
test('lists three practical facts without a design-background highlight', async ({ page }) => {
await page.goto(home);
await expect(page.locator('.hero .fact')).toHaveCount(3);
await expect(page.locator('.hero .facts .tone-root')).toHaveCount(0);
for (const stat of copy.hero.stats) {
await expect(page.locator('.hero .facts').getByText(stat.value)).toBeVisible();
}
Expand Down Expand Up @@ -259,9 +261,8 @@ for (const locale of ['en', 'it'] as const) {
await expect(page.locator('.work .years.live')).toHaveCount(1);
await expect(page.locator('.work .job').first().locator('.years.live')).toBeVisible();

// Lilac: the art foundation. The school, the block about drawing, the
// job where the drawing was the job.
await expect(page.locator('.hero .fact-v.tone-root')).toHaveCount(1);
// Lilac: design background remains in the detailed story, not the hero.
await expect(page.locator('.hero .fact-v.tone-root')).toHaveCount(0);
await expect(page.locator('.approach .block-title.tone-root')).toHaveCount(1);
await expect(page.locator('.work .chip.root')).toHaveCount(1);

Expand Down
3 changes: 2 additions & 1 deletion tests/unit/i18n.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,8 @@ describe('the colour system', () => {
for (const locale of LOCALES) {
const copy = getCopy(locale);
const facts = copy.hero.stats.filter((s) => s.tone);
expect(facts.map((s) => s.tone).sort()).toEqual(['now', 'root']);
expect(copy.hero.stats).toHaveLength(3);
expect(facts.map((s) => s.tone)).toEqual(['now']);

const toned = copy.approach.filter((b) => b.tone);
expect(toned.map((b) => b.tone)).toEqual(['root']);
Expand Down
Loading