Commit Graph

490 Commits

Author SHA1 Message Date
Lawrence Hook b433727754 Add email validation, IP rate limiting, and fix SES parsing bug
Add SES email validation with 2s timeout and fail-open behavior to
send-magic-link. Add per-IP rate limiting with decrement on verify.
Fix SES response parsing path (MailboxValidation.IsValid.ConfidenceVerdict).
Add dedicated unit tests for validateEmail.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-01 23:48:01 -05:00
Lawrence Hook 84b103e46b Migrate storage layer from flat files to SQLite
Replace file-per-record auth requests, file-per-hash rate limits, and
JSON blob subscription cache with a single SQLite database via
better-sqlite3. Consolidate duplicated email/IP rate limit code into
shared helpers. Add missing IP rate limit pruning to cleanup interval.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-01 23:47:51 -05:00
Lawrence Hook 84c2ea5586 update versions 2026-03-01 21:58:47 -05:00
Lawrence Hook a4d5a97664 Merge branch 'released' 2026-03-01 21:58:09 -05:00
Lawrence Hook 2fe77faf0f version 4.3.72
Squashed commit of the following:

commit 53a18e7987
Author: Lawrence Hook <lawrencehook@gmail.com>
Date:   Sun Mar 1 16:56:50 2026 -0500

    Hide donate link for premium users instead of showing dead label

    Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

commit e2732dee6f
Author: Lawrence Hook <lawrencehook@gmail.com>
Date:   Sun Mar 1 16:50:33 2026 -0500

    Fix fast-xml-parser vulnerability via npm override and update @aws-sdk/client-ses

    Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

commit 281c0f1103
Author: Lawrence Hook <lawrencehook@gmail.com>
Date:   Sun Mar 1 16:46:31 2026 -0500

    Add "Active" sidebar tab and soften selected sidebar styling

    Adds "all" and "active" tabs at the top of the sidebar. "Active" shows
    all currently-enabled options in one place; "all" explicitly resets to
    the default view. Also lightens the sidebar selected state from solid
    black to a subtle tint.

    Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

commit 56b119ed98
Author: Lawrence Hook <lawrencehook@gmail.com>
Date:   Sun Feb 22 05:01:00 2026 -0500

    Cache grandfathered emails in memory at startup

    Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

commit afed16a38a
Author: Lawrence Hook <lawrencehook@gmail.com>
Date:   Sun Feb 22 04:47:51 2026 -0500

    Add tests for cache TTL and webhook ordering race condition

    Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

commit 361a8caf84
Author: Lawrence Hook <lawrencehook@gmail.com>
Date:   Sun Feb 22 04:34:00 2026 -0500

    Harden license cache: 10s TTL and skip incomplete subscription.created

    Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

commit d857ae8c26
Author: Lawrence Hook <lawrencehook@gmail.com>
Date:   Sat Feb 21 18:24:33 2026 -0500

    Update README: replace donations blurb with premium link

    Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

commit c473314ca5
Author: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Date:   Sat Feb 21 18:22:39 2026 -0500

    Bump fast-xml-parser and @aws-sdk/xml-builder in /server (#201)

    Bumps [fast-xml-parser](https://github.com/NaturalIntelligence/fast-xml-parser) and [@aws-sdk/xml-builder](https://github.com/aws/aws-sdk-js-v3/tree/HEAD/packages-internal/xml-builder). These dependencies needed to be updated together.

    Updates `fast-xml-parser` from 5.3.4 to 5.3.6
    - [Release notes](https://github.com/NaturalIntelligence/fast-xml-parser/releases)
    - [Changelog](https://github.com/NaturalIntelligence/fast-xml-parser/blob/master/CHANGELOG.md)
    - [Commits](https://github.com/NaturalIntelligence/fast-xml-parser/compare/v5.3.4...v5.3.6)

    Updates `@aws-sdk/xml-builder` from 3.972.4 to 3.972.5
    - [Release notes](https://github.com/aws/aws-sdk-js-v3/releases)
    - [Changelog](https://github.com/aws/aws-sdk-js-v3/blob/main/packages-internal/xml-builder/CHANGELOG.md)
    - [Commits](https://github.com/aws/aws-sdk-js-v3/commits/HEAD/packages-internal/xml-builder)

    ---
    updated-dependencies:
    - dependency-name: fast-xml-parser
      dependency-version: 5.3.6
      dependency-type: indirect
    - dependency-name: "@aws-sdk/xml-builder"
      dependency-version: 3.972.5
      dependency-type: indirect
    ...

    Signed-off-by: dependabot[bot] <support@github.com>
    Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

commit 49e1a5d9ba
Author: Lawrence Hook <lawrencehook@gmail.com>
Date:   Sat Feb 21 17:30:29 2026 -0500

    Fix license cache not updating after checkout

    The checkout.session.completed webhook only sent a welcome email but
    did not update the subscription cache, so users kept getting cached
    free status after paying.

    Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

commit c5734518c4
Author: Lawrence Hook <lawrencehook@gmail.com>
Date:   Sun Feb 15 19:10:05 2026 -0500

    Remove TESTING.md and DEPLOYMENT.md

    Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

commit 6ed3ad0291
Author: Lawrence Hook <lawrencehook@gmail.com>
Date:   Sun Feb 15 19:08:03 2026 -0500

    Remove obsolete docs and update TODO for YouTube DOM change

    Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

commit 83693504e3
Author: Lawrence Hook <lawrencehook@gmail.com>
Date:   Sun Feb 15 18:54:29 2026 -0500

    update versions

commit 27a6ae6f18
Merge: 3f4b42b d6e642b
Author: Lawrence Hook <lawrencehook@gmail.com>
Date:   Sun Feb 15 18:53:37 2026 -0500

    Merge branch 'released'

commit 3f4b42b2de
Author: Lawrence Hook <lawrencehook@gmail.com>
Date:   Sun Feb 15 18:49:28 2026 -0500

    Update qs to 6.14.2 to fix low-severity DoS vulnerability

    Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

commit 8825666512
Author: Lawrence Hook <lawrencehook@gmail.com>
Date:   Sun Feb 15 18:45:37 2026 -0500

    Merge the monetization feature branch.

    Add RYS Premium subscription system

    Introduce optional paid tier with sign-in, Stripe billing, and premium
    feature gating. Core features remain free. Includes Node.js server for
    auth, payments, and license management.

    Extension changes:
    - Sign-in flow with magic link email
    - Premium/upgrade/account modals with branded UI
    - Premium feature gating (60+ advanced settings)
    - Password lock and scheduling (premium)
    - Fix "hide all but first row" for YouTube's new flat homepage DOM
    - Hide sidebar ad panels by default
    - Enable "Hide all Shorts" by default

    Server:
    - Magic link auth with rate limiting
    - Stripe checkout, webhooks, and billing portal
    - JWT-based license tokens
    - AWS SES transactional emails (welcome, sign-in, cancellation)
    - Grandfathered donor support

    Also adds CI workflow, server test suite, and extension unit tests.

commit a76f69804b
Author: Lawrence Hook <lawrencehook@gmail.com>
Date:   Sun Feb 8 20:45:35 2026 -0500

    update description in README

    Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

commit b5d1384ca8
Author: Lawrence Hook <lawrencehook@gmail.com>
Date:   Sun Feb 8 20:44:26 2026 -0500

    update "Why I made it" section in README

    Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

commit 18b64708b6
Author: Lawrence Hook <lawrencehook@gmail.com>
Date:   Sun Feb 8 20:14:23 2026 -0500

    update version to 4.3.71
2026-03-01 21:57:22 -05:00
Lawrence Hook 53a18e7987 Hide donate link for premium users instead of showing dead label
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-01 16:56:50 -05:00
Lawrence Hook e2732dee6f Fix fast-xml-parser vulnerability via npm override and update @aws-sdk/client-ses
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-01 16:50:33 -05:00
Lawrence Hook 281c0f1103 Add "Active" sidebar tab and soften selected sidebar styling
Adds "all" and "active" tabs at the top of the sidebar. "Active" shows
all currently-enabled options in one place; "all" explicitly resets to
the default view. Also lightens the sidebar selected state from solid
black to a subtle tint.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-01 16:46:31 -05:00
Lawrence Hook 56b119ed98 Cache grandfathered emails in memory at startup
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-22 05:01:00 -05:00
Lawrence Hook afed16a38a Add tests for cache TTL and webhook ordering race condition
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-22 04:47:51 -05:00
Lawrence Hook 361a8caf84 Harden license cache: 10s TTL and skip incomplete subscription.created
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-22 04:34:00 -05:00
Lawrence Hook d857ae8c26 Update README: replace donations blurb with premium link
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-21 18:24:33 -05:00
dependabot[bot] c473314ca5 Bump fast-xml-parser and @aws-sdk/xml-builder in /server (#201)
Bumps [fast-xml-parser](https://github.com/NaturalIntelligence/fast-xml-parser) and [@aws-sdk/xml-builder](https://github.com/aws/aws-sdk-js-v3/tree/HEAD/packages-internal/xml-builder). These dependencies needed to be updated together.

Updates `fast-xml-parser` from 5.3.4 to 5.3.6
- [Release notes](https://github.com/NaturalIntelligence/fast-xml-parser/releases)
- [Changelog](https://github.com/NaturalIntelligence/fast-xml-parser/blob/master/CHANGELOG.md)
- [Commits](https://github.com/NaturalIntelligence/fast-xml-parser/compare/v5.3.4...v5.3.6)

Updates `@aws-sdk/xml-builder` from 3.972.4 to 3.972.5
- [Release notes](https://github.com/aws/aws-sdk-js-v3/releases)
- [Changelog](https://github.com/aws/aws-sdk-js-v3/blob/main/packages-internal/xml-builder/CHANGELOG.md)
- [Commits](https://github.com/aws/aws-sdk-js-v3/commits/HEAD/packages-internal/xml-builder)

---
updated-dependencies:
- dependency-name: fast-xml-parser
  dependency-version: 5.3.6
  dependency-type: indirect
- dependency-name: "@aws-sdk/xml-builder"
  dependency-version: 3.972.5
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-21 18:22:39 -05:00
Lawrence Hook 49e1a5d9ba Fix license cache not updating after checkout
The checkout.session.completed webhook only sent a welcome email but
did not update the subscription cache, so users kept getting cached
free status after paying.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-21 17:30:29 -05:00
Lawrence Hook c5734518c4 Remove TESTING.md and DEPLOYMENT.md
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 19:10:05 -05:00
Lawrence Hook 6ed3ad0291 Remove obsolete docs and update TODO for YouTube DOM change
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 19:08:03 -05:00
Lawrence Hook 83693504e3 update versions 2026-02-15 18:54:29 -05:00
Lawrence Hook 27a6ae6f18 Merge branch 'released' 2026-02-15 18:53:37 -05:00
Lawrence Hook d6e642b962 version 4.3.71 2026-02-15 18:52:44 -05:00
Lawrence Hook 3f4b42b2de Update qs to 6.14.2 to fix low-severity DoS vulnerability
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 18:49:28 -05:00
Lawrence Hook 8825666512 Merge the monetization feature branch.
Add RYS Premium subscription system

Introduce optional paid tier with sign-in, Stripe billing, and premium
feature gating. Core features remain free. Includes Node.js server for
auth, payments, and license management.

Extension changes:
- Sign-in flow with magic link email
- Premium/upgrade/account modals with branded UI
- Premium feature gating (60+ advanced settings)
- Password lock and scheduling (premium)
- Fix "hide all but first row" for YouTube's new flat homepage DOM
- Hide sidebar ad panels by default
- Enable "Hide all Shorts" by default

Server:
- Magic link auth with rate limiting
- Stripe checkout, webhooks, and billing portal
- JWT-based license tokens
- AWS SES transactional emails (welcome, sign-in, cancellation)
- Grandfathered donor support

Also adds CI workflow, server test suite, and extension unit tests.
2026-02-15 18:45:37 -05:00
Lawrence Hook a76f69804b update description in README
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-08 20:45:35 -05:00
Lawrence Hook b5d1384ca8 update "Why I made it" section in README
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-08 20:44:26 -05:00
Lawrence Hook 18b64708b6 update version to 4.3.71 2026-02-08 20:14:23 -05:00
Lawrence Hook 6fd112f8da Merge branch 'main' into released 2026-02-08 20:13:22 -05:00
Lawrence Hook 299bd68b73 fix: scope yt-thumbnail-view-model shrink to grid cards only
Prevents sidebar thumbnails from being enlarged by the min-width rule.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-08 20:07:55 -05:00
Lawrence Hook a6924318e0 fix: shrink thumbnails for new YouTube homepage thumbnail element
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-08 20:04:44 -05:00
Lawrence Hook 980ebd3c90 fix: update extra rows selector for new YouTube homepage structure
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-08 19:56:16 -05:00
Lawrence Hook ef85e9ef02 feat: add option to hide YouTube Playables (closes #158, closes #175)
Also auto-select Homepage section in options when on YouTube homepage.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-08 19:50:37 -05:00
Sidhant a3542e42da fix: disable extension on YouTube Music (closes #152) (#168) 2026-02-07 17:52:29 -05:00
prinixoz edbadf2e54 added feature to always be in theater mode (#195)
Co-authored-by: prinixoz <prinixoz@gmail.com>
2026-02-07 17:40:08 -05:00
prinixoz f8379f3e88 fixed shrinking issue in channel tab (#196)
* fixed shrinking issue in channel tab

* fixed playlist video shirinking and overlapping in channel pages

* fixed post shirinking

* style: fix whitespace in shrink thumbnails CSS

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

---------

Co-authored-by: prinixoz <prinixoz@gmail.com>
Co-authored-by: Lawrence Hook <lawrencehook@gmail.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-07 17:36:07 -05:00
GeleArthur 3ef38334e9 Hide bell notifcations number in page titlle (#199)
* Added removing the bell in the title

* add comment on what it does

* Start of title

* style: fix spacing in if statement

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Lawrence Hook <lawrencehook@gmail.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-07 17:29:11 -05:00
prinixoz 4b4fb7722d hide result description (#197)
* hide description #188

* add idToShortId entry and fix extra whitespace

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

---------

Co-authored-by: prinixoz <prinixoz@gmail.com>
Co-authored-by: Lawrence Hook <lawrencehook@gmail.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-07 17:27:27 -05:00
Lawrence Hook 182f6489ef add deprecation comment for disable_playlist_autoplay
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-07 16:55:17 -05:00
Lawrence Hook a69b92a6b8 deprecate disable_playlist_autoplay setting
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-07 16:44:17 -05:00
Lawrence Hook f641d0f039 fix: remove duplicate function from bad merge 2026-02-04 20:17:35 -05:00
Lawrence Hook 0e21939821 fix: remove duplicate function from bad merge 2026-02-04 20:16:53 -05:00
Lawrence Hook 881514d71c update versions 2026-02-04 20:14:13 -05:00
Lawrence Hook 13d610181e Merge main into released 2026-02-04 20:11:53 -05:00
Lawrence Hook c3c7db3315 perf: optimize polling and reduce CPU usage
Options page:
- Pause timeLoop when popup is hidden (Page Visibility API)
- Use { once: true } for log prompt button listeners
- Remove stray console.log in settings import

Content script:
- Slow polling from 100ms to 500ms after page settles (was stuck at 100ms)
- Stop playlist autoplay interval once manager is found
- Only check dismiss buttons every 5th iteration
- Only check reveal boxes for first 30 iterations
- Only query clip button DOM if setting is enabled
- Skip subscriptions page queries if no sub-settings enabled
- Fix ad skip button selector for current YouTube UI

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-04 20:06:14 -05:00
Lawrence Hook 77d36b1360 chore: complete remaining quick wins from TODO
- Move duplicated YouTube URL regexes to shared/utils.js
- Delete commented-out code blocks (theater mode, playback speed, cookie manipulation, debug vars)
- Add Page Visibility API to pause polling when tab is hidden
- Update TODO.md to reflect completed items

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-04 19:28:12 -05:00
Lawrence Hook 1dbea5ab66 chore: clean up dead code and fix naming
- Remove debug console.log statements in options/main.js
- Remove unused TEMPLATE_FIELDSET variable
- Fix SEC_IN_WEEK → MIN_IN_WEEK (it was actually minutes)
- Remove dead setCookie/getCookie functions

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-04 19:22:30 -05:00
Lawrence Hook ab97952e84 feat: change analytics from opt-out to opt-in
- Add non-blocking bottom banner prompting users to enable logging
- Default log_enabled to false, track user response with log_prompt_answered
- Banner shows until user clicks Sure/No thanks, dismiss hides for session only
- Update settings menu icon from dots to gear
- Widen sidebar to prevent "Video Player" text wrapping

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-04 19:20:59 -05:00
Lawrence Hook 6f23fbc369 update git ignore 2026-01-31 16:22:39 -05:00
Lawrence Hook 93e2ea492d update versions 2026-01-28 21:35:57 -05:00
Lawrence Hook f894715b62 version 4.3.68 2026-01-28 21:31:06 -05:00
Lawrence Hook e8af6f0b7b feat: add announcement banner to YouTube homepage and revamp reveal boxes
- Add shared banner system (src/shared/banners.js) for extensible banner config
- Display RYS-branded announcement banner on YouTube homepage and options page
- Banner pushes down YouTube page content with CSS variable for height
- Revamp reveal suggestion boxes with polished two-row layout and RYS branding
- Add per-surface reveal settings (homepage/sidebar/end-of-video) with migration
- Consolidate colors and dimensions into CSS variables
- Cache reveal box config at module level for performance

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 21:23:51 -05:00
Lawrence Hook 769d7a150f update versions 2026-01-27 21:39:36 -05:00
Lawrence Hook 2e524c0d6c Merge branch 'released' 2026-01-27 21:38:58 -05:00