Skip to content

feat: add more subtitle style and fix some api erro handling - #1671

Draft
Ckrvxr wants to merge 42 commits into
mengxi-ream:mainfrom
Ckrvxr:dummy-subs-20260610
Draft

feat: add more subtitle style and fix some api erro handling#1671
Ckrvxr wants to merge 42 commits into
mengxi-ream:mainfrom
Ckrvxr:dummy-subs-20260610

Conversation

@Ckrvxr

@Ckrvxr Ckrvxr commented Jun 10, 2026

Copy link
Copy Markdown

已经把简易和高级模式分开写了。现在就比较清新。

PixPin_2026-06-10_22-58-20
Pixpin.2026-06-10.22-03-32.mp4
PixPin_2026-06-10_22-58-50

Ckrvxr added 30 commits June 8, 2026 02:09
Ckrvxr added 12 commits June 10, 2026 19:46
- Split DEFAULT_TEXT_STYLE into main (fontScale 80) and translation (100)
- Fix Blur background opacity: remove *0.3 clamp, map 0-100 directly
- Fix Liquid Glass background: wire up opacity slider instead of hardcoded 0.08
- Unified preset labels with Background Style options (Glass→Blur, Liquid→Liquid Glass)
- Update preset default opacities: Glass 35, Liquid/Advanced 100
- Change DEFAULT_BACKGROUND_STYLE from none to blur
- Change DEFAULT_PRESET_STYLE from Advanced (4) to Blur (2)
- Change DEFAULT_LINE_GAP 2→4, DEFAULT_FONT_STROKE_WIDTH 2.5→3
- Fix reset handlers: add missing presetStyle/backgroundForceMerge, use correct defaults
- Remove SubtitleMode type and basic/advanced toggle (merged into presetStyle)
- Add Advanced preset snapshot for preserving custom values on mode switch
…shouldMerge threshold

- Export ADVANCED_INDEX from constants/subtitles, import in all consumers
- Save Advanced snapshot before reset in both style.tsx and general-settings.tsx
- Change shouldMerge threshold from lineGap <= 3 to lineGap <= 4
- Add presetStyle, backgroundStyle, lineGap, backgroundForceMerge to 8 locale files
- Rename en.yml presetStyle from Style to Preset
- Fix hardcoded 'Background Style' labels to use i18n key in style.tsx and general-settings.tsx
- Rename resetGeneralConfig to handleResetGeneral in general-settings.tsx
- Add presetStyle, backgroundForceMerge, lineGap to subtitle style
- Set backgroundStyle based on backgroundOpacity (0→none, otherwise→blur)
- Update shadow/stroke defaults to 3 for main and translation
- Add v076.ts example file and v075-to-v076.test.ts
- Replace async vi.mock factory with sync atoms at module scope
- Add missing @vitest-environment jsdom directive
- Add ResizeObserver mock for jsdom compatibility
@github-actions github-actions Bot added the feat label Jun 10, 2026
@changeset-bot

changeset-bot Bot commented Jun 10, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: aefc29a

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants