From 96e78c5fdfada73d37644083c7580a1d444ed748 Mon Sep 17 00:00:00 2001 From: Adam Mathes Date: Mon, 16 Feb 2026 09:37:04 -0800 Subject: Fix v3ui: neko button fixed position - Remove duplicate neko logo from v3 sidebar - Keep sidebar toggle button fixed at top-left even when sidebar is open - Add top padding to v3 sidebar to prevent overlap with the fixed toggle button - Update v3 tests to match UI changes --- .thicket/tickets.jsonl | 8 +- frontend-vanilla/src/main.test.ts | 9 --- frontend-vanilla/src/main.ts | 1 - frontend-vanilla/src/style.css | 10 +-- web/dist/v3/assets/index-BV2Ufoce.css | 1 + web/dist/v3/assets/index-BZ4E0pnc.css | 1 - web/dist/v3/assets/index-Bf6N2Bbo.js | 143 +++++++++++++++++++++++++++++++++ web/dist/v3/assets/index-DmGSlScV.js | 144 ---------------------------------- web/dist/v3/index.html | 4 +- 9 files changed, 153 insertions(+), 168 deletions(-) create mode 100644 web/dist/v3/assets/index-BV2Ufoce.css delete mode 100644 web/dist/v3/assets/index-BZ4E0pnc.css create mode 100644 web/dist/v3/assets/index-Bf6N2Bbo.js delete mode 100644 web/dist/v3/assets/index-DmGSlScV.js diff --git a/.thicket/tickets.jsonl b/.thicket/tickets.jsonl index 0b1116e..c19c16d 100644 --- a/.thicket/tickets.jsonl +++ b/.thicket/tickets.jsonl @@ -15,7 +15,7 @@ {"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-4jy0t2","title":"Implement Mocked-API UI Tests","description":"Configure Playwright to intercept /api/ requests and return mock JSON. This decouples UI testing from the backend, reducing VM crash risk and enabling fast UI iteration.","type":"task","status":"closed","priority":1,"labels":null,"assignee":"","created":"2026-02-15T16:23:32.209848684Z","updated":"2026-02-15T21:47:24.97680381Z"} -{"id":"NK-4p3s91","title":"Page title \"frontend-vanilla\" should be \"neko\"","description":"Frontend-vanilla is like, an internal thing. The app should just show up at \"neko\" in browser title bar.","type":"task","status":"open","priority":2,"labels":null,"assignee":"","created":"2026-02-16T16:18:00.411259747Z","updated":"2026-02-16T16:18:00.411259747Z"} +{"id":"NK-4p3s91","title":"v3 ui: Page title \"frontend-vanilla\" should be \"neko\"","description":"Frontend-vanilla is like, an internal thing. The app should just show up at \"neko\" in browser title bar.","type":"task","status":"open","priority":1,"labels":null,"assignee":"","created":"2026-02-16T16:18:00.411259747Z","updated":"2026-02-16T16:18:00.411259747Z"} {"id":"NK-4y484t","title":"last item behavior on mobile","description":"I think there's a bug where if the last item on screen on mobile isn't \"big\" enough it won't trigger loading more items, but not sure. please verify the behavior.","type":"bug","status":"closed","priority":1,"labels":null,"assignee":"","created":"2026-02-15T16:46:38.025288816Z","updated":"2026-02-15T16:50:36.390669216Z"} {"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"} {"id":"NK-59kbij","title":"Implement Frontend Logout","description":"Add logout button to dashboard header. Call /api/logout (need to create this potentially?). Redirect to /login","type":"","status":"closed","priority":1,"labels":null,"assignee":"","created":"2026-02-13T14:58:18.343464645Z","updated":"2026-02-13T15:01:33.783216589Z"} @@ -30,7 +30,7 @@ {"id":"NK-7u97bb","title":"Freeing up space by purging very old items","description":"I have been running neko for so long that my production database is 1.4GB. Come up with a tool (ok to run it from command line) that purges some super old feed items to save space. Probably needs some variables on age, etc. Think carefully about the algorithm! it should be accessible from the CLI to start, although maybe we should show \"db size\" in settings too with an option to clean up.","type":"feature","status":"closed","priority":2,"labels":null,"assignee":"","created":"2026-02-15T03:01:05.643515805Z","updated":"2026-02-15T18:51:26.631274215Z"} {"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":"closed","priority":3,"labels":null,"assignee":"","created":"2026-02-14T22:49:05.942464799Z","updated":"2026-02-14T22:49:05.942464799Z"} -{"id":"NK-89za3s","title":"v3ui: neko button fixed position","description":"the neko cat button keeps moving, I kind of just want it to stay in the same position at the top left like a logo. move the search box down a bit so it won't overlap","type":"task","status":"open","priority":2,"labels":null,"assignee":"","created":"2026-02-16T15:38:25.158968209Z","updated":"2026-02-16T15:38:25.158968209Z"} +{"id":"NK-89za3s","title":"v3ui: neko button fixed position","description":"the neko cat button keeps moving, I kind of just want it to stay in the same position at the top left like a logo. move the search box down a bit so it won't overlap. there should only be one neko on the page total in the top left!","type":"bug","status":"closed","priority":0,"labels":null,"assignee":"","created":"2026-02-16T15:38:25.158968209Z","updated":"2026-02-16T17:37:04.494608875Z"} {"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":"closed","priority":2,"labels":null,"assignee":"","created":"2026-02-15T02:24:06.398437323Z","updated":"2026-02-15T17:28:58.42125577Z"} {"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"} @@ -81,7 +81,7 @@ {"id":"NK-gjymiw","title":"FEEDS in sidebar needs to be more clearly a collapsible thing","description":"FEEDS in the sidebar needs a caret (\u003e that turns to V) or something similar to make it clear it's a toggle collapsible list thing","type":"feature","status":"closed","priority":1,"labels":null,"assignee":"","created":"2026-02-14T23:54:20.355824171Z","updated":"2026-02-15T00:06:02.456524674Z"} {"id":"NK-gnxc6e","title":"Feed list collapsed by default","description":"The list of feeds on the left side should be collapsed by default, with a little control to extend it.","type":"feature","status":"closed","priority":1,"labels":null,"assignee":"","created":"2026-02-14T00:58:15.661695308Z","updated":"2026-02-14T01:29:12.82081713Z"} {"id":"NK-gqkh96","title":"Remaining test coverage gaps","description":"Cross-package test coverage is at 81.2%. The remaining untested functions are: GetFullContent (goose HTTP extraction), indexHandler/serveBoxedFile (rice.MustFindBox), Serve (starts HTTP server), main, util.init. To reach 90%, consider: (1) refactoring GetFullContent to accept an interface for HTTP fetching, (2) refactoring Serve to extract route setup into a testable function, (3) mocking rice.MustFindBox, (4) using feeds from https://trenchant.org/feeds.txt as static test fixtures for integration tests.","type":"cleanup","status":"closed","priority":3,"labels":null,"assignee":"","created":"2026-02-13T03:54:30.298141982Z","updated":"2026-02-14T02:44:05.399097286Z"} -{"id":"NK-gxvegm","title":"Settings page toggle behavior for feeds and tags","description":"Currently only 'filters' and 'settings' link toggle away from settings page. We should probably implement similar behavior if clicking on a feed or tag while on the settings page (it currently might work by accident due to direct navigation, but we should verify).","type":"task","status":"open","priority":4,"labels":null,"assignee":"","created":"2026-02-16T16:17:21.4431998Z","updated":"2026-02-16T16:17:21.4431998Z"} +{"id":"NK-gxvegm","title":"Settings page toggle behavior for feeds and tags","description":"Currently only 'filters' and 'settings' link toggle away from settings page. We should probably implement similar behavior if clicking on a feed or tag while on the settings page (it currently might work by accident due to direct navigation, but we should verify).","type":"task","status":"open","priority":2,"labels":null,"assignee":"","created":"2026-02-16T16:17:21.4431998Z","updated":"2026-02-16T16:17:21.4431998Z"} {"id":"NK-hidz4w","title":"Add Local Git Hooks","description":"Create a script/make target to install a pre-push hook that runs 'make check'. This enforces quality gates locally, keeping the CI clean.","type":"task","status":"closed","priority":1,"labels":null,"assignee":"","created":"2026-02-15T16:23:36.906173277Z","updated":"2026-02-15T17:25:28.129358055Z"} {"id":"NK-hj6f9p","title":"Investigate E2E Tag View flakiness","description":"The E2E test for /v2/tag/Tech was temporarily disabled because it was timing out/failing. Investigate if it's a race condition or a routing issue.","type":"bug","status":"closed","priority":4,"labels":null,"assignee":"","created":"2026-02-15T01:04:54.404114014Z","updated":"2026-02-15T19:14:17.974207248Z"} {"id":"NK-hspao2","title":"Vanilla JS: Implement Test Infrastructure","description":"Setup testing infrastructure for vanilla JS prototype to ensure 80% coverage. Refactor app.js for testability and add unit tests.","type":"task","status":"closed","priority":1,"labels":null,"assignee":"","created":"2026-02-14T05:13:11.587767054Z","updated":"2026-02-14T05:13:11.587767054Z"} @@ -141,7 +141,7 @@ {"id":"NK-shpyxh","title":"add search to new ui","description":"","type":"epic","status":"closed","priority":1,"labels":null,"assignee":"","created":"2026-02-13T19:29:44.251257089Z","updated":"2026-02-14T01:02:58.547025683Z"} {"id":"NK-sk6pym","title":"fix docker-compose","description":"bug when trying to build in docker -- we may want to add an automated test for this later (though it may be hard since we're building in a vm to nest these)\n\n--\u003e 668e2e2c4b44\n[2/3] STEP 3/9: WORKDIR /app\n--\u003e b42c7c265b7f\n[2/3] STEP 4/9: COPY go.mod go.sum ./\n--\u003e 093e4d9b623e\n[2/3] STEP 5/9: RUN go mod download\n--\u003e 208c8aaac5eb\n[2/3] STEP 6/9: COPY . .\n--\u003e 7c44260c3ac0\n[2/3] STEP 7/9: COPY --from=frontend-builder /app/frontend/dist ./frontend/dist\n--\u003e 09749e6660e1\n[2/3] STEP 8/9: RUN rice -i ./web embed-go\n2026/02/14 17:34:13 no calls to rice.FindBox() found\n--\u003e cdc88c64da36\n[2/3] STEP 9/9: RUN go build -o neko .\nno Go files in /app\nError: building at STEP \"RUN go build -o neko .\": while running runtime: exit status 1","type":"bug","status":"closed","priority":1,"labels":null,"assignee":"","created":"2026-02-14T17:38:05.696339994Z","updated":"2026-02-14T18:06:42.659012133Z"} {"id":"NK-sne5ox","title":"Implement Export/Import UI","description":"Add UI in settings to download OPML export and upload OPML import. Use /export/ and /import/ (need to check if import exists).","type":"epic","status":"icebox","priority":3,"labels":null,"assignee":"","created":"2026-02-13T15:05:23.266731399Z","updated":"2026-02-13T15:05:23.266731399Z"} -{"id":"NK-sssn4a","title":"v3: themes are wrong","description":"the light and dark themes don't quite work right on v3 -- it has black text on black bg in settings for example.\n\nlook at the v2 ones and please more closely use those colors, that seems to have worked better. and copy the emoji and put it in the sidebar of v3 too please.","type":"task","status":"open","priority":1,"labels":null,"assignee":"","created":"2026-02-16T15:54:20.52804517Z","updated":"2026-02-16T15:54:20.52804517Z"} +{"id":"NK-sssn4a","title":"v3: themes are wrong","description":"the light and dark themes don't quite work right on v3 -- it has black text on black bg in settings for example.\n\nlook at the v2 ones and please more closely use those colors, that seems to have worked better. and copy the emoji and put it in the sidebar of v3 too please.","type":"task","status":"closed","priority":1,"labels":null,"assignee":"","created":"2026-02-16T15:54:20.52804517Z","updated":"2026-02-16T17:28:52.865767539Z"} {"id":"NK-sxcm7y","title":"Enable Gzip Compression in Go Backend","description":"Check if the Go backend is serving content with gzip compression. If not, implement it to reduce page size and improve performance. Add tests to verify.","type":"feature","status":"closed","priority":0,"labels":null,"assignee":"","created":"2026-02-13T21:57:24.578388732Z","updated":"2026-02-13T22:22:49.350223751Z"} {"id":"NK-t0nmbj","title":"new web frontend","description":"The current frontend uses an old version of backbone and jquery. Let's \"deprecate\" it -- keep it arouond so we can test against it and use it, but let's be able to also serve and use a nice shiny new frontend written in either simiple, highly efficient vanilla javascript, or put together something in react or similar. Needs to feel fast and low latency!\n\nIt's very important that this new frontend has all the functionality of the existing one AND looks similar (use same style, etc, but adjust a little if needed.)\n\nALSO make it highly testable and have high test coverage as you go. I don't want it to use the Chrome browser plugin thing, just test it on your own using things from the command line you can do.","type":"epic","status":"closed","priority":0,"labels":null,"assignee":"","created":"2026-02-13T02:01:37.2107893Z","updated":"2026-02-13T05:43:47.613995925Z"} {"id":"NK-t7m31s","title":"Wire Reader API into web.go","description":"","type":"task","status":"closed","priority":2,"labels":null,"assignee":"","created":"2026-02-15T00:21:55.393639254Z","updated":"2026-02-15T00:44:41.579714853Z"} diff --git a/frontend-vanilla/src/main.test.ts b/frontend-vanilla/src/main.test.ts index 3798f1b..c9d0e0c 100644 --- a/frontend-vanilla/src/main.test.ts +++ b/frontend-vanilla/src/main.test.ts @@ -65,19 +65,10 @@ describe('main application logic', () => { it('renderLayout should create sidebar and main content', () => { renderLayout(); expect(document.getElementById('sidebar')).not.toBeNull(); - expect(document.querySelector('.logo')).not.toBeNull(); expect(document.getElementById('content-area')).not.toBeNull(); expect(document.getElementById('sidebar-toggle-btn')).not.toBeNull(); }); - it('should navigate to home when clicking logo', () => { - renderLayout(); - const logo = document.querySelector('.logo') as HTMLElement; - const navigateSpy = vi.spyOn(router, 'navigate'); - logo.click(); - expect(navigateSpy).toHaveBeenCalledWith('/', expect.any(Object)); - }); - it('renderFeeds should populate feed list', () => { renderLayout(); store.setFeeds([{ _id: 1, title: 'Test Feed', url: 'test', web_url: 'test', category: 'tag' }]); diff --git a/frontend-vanilla/src/main.ts b/frontend-vanilla/src/main.ts index f4493b8..3f53fc2 100644 --- a/frontend-vanilla/src/main.ts +++ b/frontend-vanilla/src/main.ts @@ -30,7 +30,6 @@ export function renderLayout() {