Skip to content

v1.1.1 - Enhanced ThemeRuntime API, Vue Export Fixes, and Angular Package

Choose a tag to compare

@toozuuu toozuuu released this 11 Nov 21:35
· 33 commits to main since this release

πŸŽ‰ What's New

✨ Enhanced ThemeRuntime API

We've significantly expanded the ThemeRuntime class with new methods:

  • getThemeTokens(themeName) - Retrieve tokens for any theme by name
  • getAvailableThemes() - Get a list of all available theme names
  • nextTheme() - Cycle through themes programmatically
  • destroy() - Clean up runtime resources and remove injected CSS
  • watchSystemTheme(callback) - Watch for system theme changes (light/dark mode)
  • detectSystemTheme() - Static method to detect current system theme preference

πŸ†• Angular Package

Complete Angular adapter (@tokiforge/angular) with:

  • ThemeService - Injectable service using Angular Signals
  • Full SSR support with @angular/ssr
  • Static and dynamic theme modes
  • localStorage persistence
  • System theme detection

πŸ”§ Vue Package Export Fixes

Fixed critical export resolution issues:

  • Added default export to package.json exports field
  • Fixed ESM/CJS module resolution
  • Resolved "Failed to resolve entry" errors

πŸ› Bug Fixes

  • Vue Package: Fixed package.json exports to match build outputs
  • Core Package: Fixed Vitest configuration timeout issues on Windows
  • Angular Package: Created missing src/index.ts file
  • Build System: Improved build reliability across all packages

πŸ“š Documentation & Testing

  • Updated ThemeRuntime API documentation with all new methods
  • Added comprehensive Angular API documentation
  • Added 37 new tests for ThemeRuntime
  • Improved test coverage across all packages

πŸ“¦ Packages Updated

All packages updated to v1.1.1:

  • @tokiforge/core@1.1.1
  • @tokiforge/react@1.1.1
  • @tokiforge/vue@1.1.1
  • @tokiforge/angular@1.1.1 ✨ NEW
  • @tokiforge/svelte@1.1.1
  • @tokiforge/tailwind@1.1.1
  • @tokiforge/figma@1.1.1
  • tokiforge-cli@1.1.1

πŸš€ Quick Start

Vue Users (Fixed!)

npm install @tokiforge/vue@^1.1.1 @tokiforge/core@^1.1.1### Angular Users (New!)
npm install @tokiforge/angular@^1.1.1 @tokiforge/core@^1.1.1### Enhanced ThemeRuntimecript
import { ThemeRuntime } from '@tokiforge/core';

const runtime = new ThemeRuntime(config);

// Get available themes
const themes = runtime.getAvailableThemes();

// Watch system theme
runtime.watchSystemTheme((theme) => {
runtime.applyTheme(theme);
});## πŸ“– Documentation


Full Changelog: v1.1.0...v1.1.1