diff options
| author | Adam Mathes <adam@adammathes.com> | 2026-02-14 18:24:22 -0800 |
|---|---|---|
| committer | Adam Mathes <adam@adammathes.com> | 2026-02-14 18:24:22 -0800 |
| commit | a7369274ba24298a0449865f147fc65253e992a2 (patch) | |
| tree | 365c748669990fca48052c6aa299e2e6da7afdb5 | |
| parent | f9b22750dced97a974005593909077d09b1129b9 (diff) | |
| download | neko-a7369274ba24298a0449865f147fc65253e992a2.tar.gz neko-a7369274ba24298a0449865f147fc65253e992a2.tar.bz2 neko-a7369274ba24298a0449865f147fc65253e992a2.zip | |
style: fix font theme application to body text
| -rw-r--r-- | .thicket/tickets.jsonl | 4 | ||||
| -rw-r--r-- | frontend/src/index.css | 4 | ||||
| -rw-r--r-- | frontend/tests/font.spec.ts | 31 |
3 files changed, 38 insertions, 1 deletions
diff --git a/.thicket/tickets.jsonl b/.thicket/tickets.jsonl index 6ef1606..f848457 100644 --- a/.thicket/tickets.jsonl +++ b/.thicket/tickets.jsonl @@ -11,7 +11,7 @@ {"id":"NK-2ypbgd","title":"Vanilla JS: Implement Search","description":"Add search bar to vanilla JS prototype and hook up to search API.","type":"feature","status":"closed","priority":2,"labels":null,"assignee":"","created":"2026-02-14T04:47:39.405003074Z","updated":"2026-02-14T04:49:07.592627269Z"} {"id":"NK-35kxxw","title":"v2 frontend move the star to the RIGHT of the title","description":"Look at the old implementation and make it look more like that! Big start, same size as the article title.","type":"bug","status":"closed","priority":0,"labels":null,"assignee":"","created":"2026-02-14T00:44:13.630511415Z","updated":"2026-02-14T01:07:04.861274618Z"} {"id":"NK-3e3dim","title":"go vet fails on github ci","description":"Looks like the newly enabled github ci runs go vet and got a bunch of errors including:\n\ngo vet ./...\n shell: /usr/bin/bash -e {0}\nError: config/config.go:6:2: missing go.sum entry for module providing package gopkg.in/yaml.v2 (imported by adammathes.com/neko/config); to add:\n go get adammathes.com/neko/config\nError: models/db.go:10:2: missing go.sum entry for module providing package github.com/mattn/go-sqlite3 (imported by adammathes.com/neko/models); to add:\n go get adammathes.com/neko/models\nError: models/feed/feed.go:10:2: missing go.sum entry for module providing package github.com/PuerkitoBio/goquery (imported by adammathes.com/neko/models/feed); to add:\n go get adammathes.com/neko/models/feed\nError: models/item/item.go:12:2: missing go.sum entry for module providing package github.com/advancedlogic/GoOse (imported by adammathes.com/neko/models/item); to add:\n go get adammathes.com/neko/models/item\nError: models/item/item.go:13:2: missing go.sum entry for module providing package github.com/microcosm-cc/bluemonday (imported by adammathes.com/neko/models/item); to add:\n go get adammathes.com/neko/models/item\nError: models/item/item.go:14:2: missing go.sum entry for module providing package github.com/russross/blackfriday (imported by adammathes.com/neko/models/item); to add:\n go get adammathes.com/neko/models/item\nError: crawler/crawler.go:7:2: missing go.sum entry for module providing package github.com/mmcdole/gofeed (imported by adammathes.com/neko/crawler); to add:\n go get adammathes.com/neko/crawler\nError: tui/tui.go:9:2: missing go.sum entry for module providing package github.com/charmbracelet/bubbles/list (imported by adammathes.com/neko/tui); to add:\n go get adammathes.com/neko/tui\nError: tui/tui.go:10:2: missing go.sum entry for module providing package github.com/charmbracelet/bubbles/viewport (imported by adammathes.com/neko/tui); to add:\n go get adammathes.com/neko/tui\nError: tui/tui.go:11:2: missing go.sum entry for module providing package github.com/charmbracelet/bubbletea (imported by adammathes.com/neko/tui); to add:\n go get adammathes.com/neko/tui\nError: tui/style.go:3:8: missing go.sum entry for module providing package github.com/charmbracelet/lipgloss (imported by adammathes.com/neko/tui); to add:\n go get adammathes.com/neko/tui\nError: web/web.go:19:2: missing go.sum entry for module providing package github.com/GeertJohan/go.rice (imported by adammathes.com/neko/web); to add:\n go get adammathes.com/neko/web\nError: web/rice-box.go:7:2: missing go.sum entry for module providing package github.com/GeertJohan/go.rice/embedded (imported by adammathes.com/neko/web); to add:\n go get adammathes.com/neko/web\nError: web/web.go:20:2: missing go.sum entry for module providing package golang.org/x/crypto/bcrypt (imported by adammathes.com/neko/web); to add:\n go get adammathes.com/neko/web\nError: main.go:16:2: missing go.sum entry for module providing package github.com/ogier/pflag (imported by adammathes.com/neko); to add:\n go get adammathes.com/neko\nError: Process completed with exit code 1.","type":"bug","status":"closed","priority":0,"labels":null,"assignee":"","created":"2026-02-14T03:33:16.174683053Z","updated":"2026-02-14T03:34:08.731025136Z"} -{"id":"NK-3g1ouf","title":"fix font theming","description":"The font selector should adjust more than just the titles/ui, the font stack should include the \"normal\" article text too, right now it's palatino in every stack, it should really just be the first one I think.","type":"bug","status":"open","priority":1,"labels":null,"assignee":"","created":"2026-02-15T00:53:53.986364009Z","updated":"2026-02-15T00:53:53.986364009Z"} +{"id":"NK-3g1ouf","title":"fix font theming","description":"The font selector should adjust more than just the titles/ui, the font stack should include the \"normal\" article text too, right now it's palatino in every stack, it should really just be the first one I think.","type":"bug","status":"closed","priority":1,"labels":null,"assignee":"","created":"2026-02-15T00:53:53.986364009Z","updated":"2026-02-15T02:23:57.431627206Z"} {"id":"NK-3om7x2","title":"Implement Feed Items View","description":"Create a component to display items for a selected feed. Fetch items from /api/stream?feed_id=...","type":"","status":"closed","priority":1,"labels":null,"assignee":"","created":"2026-02-13T05:59:46.161356437Z","updated":"2026-02-13T14:55:14.795643835Z"} {"id":"NK-4juza2","title":"v2 ui - collapsible feed list","description":"In the left side navigation list of feeds, the feeds should be hidden by default. The word \"feeds\" should be a toggle to show/hide the list, with a triangle that indicates state.","type":"feature","status":"closed","priority":0,"labels":null,"assignee":"","created":"2026-02-14T02:48:25.194856022Z","updated":"2026-02-14T03:16:19.259726648Z"} {"id":"NK-4yjicm","title":"Create api/reader package and middleware","description":"","type":"task","status":"closed","priority":2,"labels":null,"assignee":"","created":"2026-02-15T00:21:45.866133071Z","updated":"2026-02-15T00:44:41.290163192Z"} @@ -25,6 +25,7 @@ {"id":"NK-7tzbql","title":"Fix TUI Content View Navigation and Interaction","description":"The TUI content view (reading a single item) is currently non-functional or severely limited. Users cannot easily navigate back, scroll, or interact with the content. This task involves improving the 'viewContent' state in the TUI.","type":"bug","status":"closed","priority":1,"labels":null,"assignee":"","created":"2026-02-13T05:02:57.382793121Z","updated":"2026-02-13T05:06:15.144485446Z"} {"id":"NK-7xuajb","title":"[security] Add HTTP Security Headers","description":"Add middleware to set standard security headers: Content-Security-Policy (restrict sources), X-Content-Type-Options: nosniff, X-Frame-Options: DENY, Referrer-Policy: strict-origin-when-cross-origin.","type":"","status":"closed","priority":2,"labels":null,"assignee":"","created":"2026-02-14T16:35:59.320775688Z","updated":"2026-02-14T17:20:46.397582923Z"} {"id":"NK-897v23","title":"Enhance UI with better loading indicators and error states","description":"The application should have a consistent and premium feel for loading and error states. Currently, it uses simple text. We should implement skeleton screens or more polished animations.","type":"task","status":"open","priority":3,"labels":null,"assignee":"","created":"2026-02-14T22:49:05.942464799Z","updated":"2026-02-14T22:49:05.942464799Z"} +{"id":"NK-8d1uzw","title":"Clean up unused font CSS variables","description":"The font CSS variables might have duplicates or unused entries after the fix. Audit them.","type":"task","status":"open","priority":3,"labels":null,"assignee":"","created":"2026-02-15T02:24:06.398437323Z","updated":"2026-02-15T02:24:06.398437323Z"} {"id":"NK-8hu7z1","title":"scrape full text button","description":"add this feature back in to the v2 ui and verify it is still working (not sure if we have any tests)","type":"feature","status":"closed","priority":1,"labels":null,"assignee":"","created":"2026-02-14T17:27:49.815938946Z","updated":"2026-02-14T17:58:19.083695149Z"} {"id":"NK-8rhpp3","title":"v2 frontend: when selected, don't change style of feed items","description":"Just leave them the same when j/k \"selects\" an item. No blue side thing, no change in background, it's distracting. Just scroll it to the right place.","type":"bug","status":"closed","priority":0,"labels":null,"assignee":"","created":"2026-02-14T00:39:50.01934312Z","updated":"2026-02-14T01:02:54.204739756Z"} {"id":"NK-8s75ec","title":"page size and performance","description":"Do some analysis of page size (css/html/javascript) on the legacy version vs. new version and give me a report. We want it to be small and fast! If the new version is much worse file some tickets to investigate further.","type":"task","status":"closed","priority":0,"labels":null,"assignee":"","created":"2026-02-13T20:16:13.898081788Z","updated":"2026-02-13T21:50:12.004391671Z"} @@ -122,6 +123,7 @@ {"id":"NK-d3uzxij","from_ticket_id":"NK-g818qn","to_ticket_id":"NK-2tcnmq","type":"created_from","created":"2026-02-14T22:46:32.880451865Z"} {"id":"NK-d50pbhs","from_ticket_id":"NK-zt4e32","to_ticket_id":"NK-t0nmbj","type":"created_from","created":"2026-02-13T05:44:01.598803513Z"} {"id":"NK-d58l5y5","from_ticket_id":"NK-ojdcmq","to_ticket_id":"NK-5ocxgm","type":"created_from","created":"2026-02-13T19:45:07.395109046Z"} +{"id":"NK-d7tr9po","from_ticket_id":"NK-8d1uzw","to_ticket_id":"NK-3g1ouf","type":"created_from","created":"2026-02-15T02:24:06.423302632Z"} {"id":"NK-d7zgu6w","from_ticket_id":"NK-fm15vq","to_ticket_id":"NK-ymf1jb","type":"created_from","created":"2026-02-13T20:27:36.795511524Z"} {"id":"NK-d86tgcs","from_ticket_id":"NK-ed1iah","to_ticket_id":"NK-1phdpf","type":"created_from","created":"2026-02-13T04:26:55.917754798Z"} {"id":"NK-dda9zfr","from_ticket_id":"NK-lrew5z","to_ticket_id":"NK-mwf9q2","type":"created_from","created":"2026-02-13T18:04:57.273164732Z"} diff --git a/frontend/src/index.css b/frontend/src/index.css index 6396633..c60ddb6 100644 --- a/frontend/src/index.css +++ b/frontend/src/index.css @@ -24,21 +24,25 @@ h5, .font-default { --font-body: Palatino, 'Palatino Linotype', 'Palatino LT STD', 'Book Antiqua', Georgia, serif; --font-heading: 'Helvetica Neue', Helvetica, Arial, sans-serif; + font-family: var(--font-body); } .font-serif { --font-body: Georgia, 'Times New Roman', Times, serif; --font-heading: Georgia, 'Times New Roman', Times, serif; + font-family: var(--font-body); } .font-sans { --font-body: Inter, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif; --font-heading: Inter, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif; + font-family: var(--font-body); } .font-mono { --font-body: Menlo, Monaco, Consolas, 'Courier New', monospace; --font-heading: Menlo, Monaco, Consolas, 'Courier New', monospace; + font-family: var(--font-body); } :root { diff --git a/frontend/tests/font.spec.ts b/frontend/tests/font.spec.ts new file mode 100644 index 0000000..0723f38 --- /dev/null +++ b/frontend/tests/font.spec.ts @@ -0,0 +1,31 @@ +import { test, expect } from '@playwright/test'; + +test.describe('Font Theme Settings', () => { + test('should change font family when theme starts', async ({ page }) => { + // 1. Login + await page.goto('/v2/login'); + await page.click('button[type="submit"]'); + await expect(page).toHaveURL(/.*\/v2\/?$/); + + // 2. Go to Settings + await page.click('text=Settings'); + await expect(page).toHaveURL(/.*\/v2\/settings/); + + // 3. Verify Default Font (Palatino) + // We check the computed style of the dashboard container or a body element + const dashboard = page.locator('.dashboard'); + await expect(dashboard).toHaveCSS('font-family', /Palatino/); + + // 4. Change to Sans-Serif + await page.selectOption('select.font-select', 'sans'); + + // 5. Verify Sans Font (Inter) + await expect(dashboard).toHaveCSS('font-family', /Inter/); + + // 6. Change to Monospace + await page.selectOption('select.font-select', 'mono'); + + // 7. Verify Mono Font (Menlo or Monaco or Courier) + await expect(dashboard).toHaveCSS('font-family', /Menlo|Monaco|Courier/); + }); +}); |
