Skip to content

feat(config): add show_animations option to disable canvas animations - #95

Merged
teuchezh merged 2 commits into
teuchezh:devfrom
r35krag0th:feature/show-animations-config
Jul 9, 2026
Merged

feat(config): add show_animations option to disable canvas animations#95
teuchezh merged 2 commits into
teuchezh:devfrom
r35krag0th:feature/show-animations-config

Conversation

@r35krag0th

Copy link
Copy Markdown

Summary

  • Adds show_animations: false config flag to completely disable the canvas animation layer
  • When disabled: no .canvas-container DOM node is created, the requestAnimationFrame loop never starts, and calling destroy() is triggered on live config change back to false
  • Surfaces the toggle in the visual card editor as a boolean switch
  • Adds show_animations translation key to all 9 supported locales (en, de, fr, es, it, nl, ru, sk, hu)

Motivation: Canvas weather animations (clouds, sun rays) render light-colored elements over white card text, making it unreadable in certain conditions. Users can now set show_animations: false to get a clean gradient background with no canvas overlay.

card_mod users can also hide animations without this flag:

card_mod:
  style: |
    .canvas-container { display: none; }

Test plan

  • Verify show_animations: false hides the canvas and gradient background renders cleanly
  • Verify show_animations: true (default/omitted) still shows animations as before
  • Verify toggling the option live in the editor destroys/restarts the animation loop correctly
  • Verify the toggle appears in the visual editor UI

@r35krag0th

Copy link
Copy Markdown
Author

-.- rebasing to dev; accidentally defaulted to main out of habit.

Canvas weather animations can render light-colored elements (white
clouds, sun rays) over white card text, making it unreadable. Add a
show_animations config flag (default: true) that completely disables
the canvas when set to false — no DOM node is created, the RAF loop
never starts, and the animation manager is destroyed on live config
change. Also surfaces the toggle in the visual card editor and adds
translations for all 9 supported locales.
@r35krag0th
r35krag0th force-pushed the feature/show-animations-config branch from 0fe4bfb to 00f41ab Compare May 17, 2026 14:55
- resolve locale/bundle conflicts, rebuild bundle from merged sources
- make editor.show_animations optional in EditorTranslations: locales may
  be partial (en fallback applies), required keys would break the
  generated locale index for pt/da/sr/pl
- document show_animations in README config tables (en/ru)

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@teuchezh
teuchezh merged commit db28f8f into teuchezh:dev Jul 9, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants