theme_extensions_gen 1.2.0 copy "theme_extensions_gen: ^1.2.0" to clipboard
theme_extensions_gen: ^1.2.0 copied to clipboard

Generate Flutter ThemeExtensions from annotated templates with context accessors and no boilerplate.

Changelog #

1.2.0 #

feat: detect the library that provides ThemeExtension (package:flutter/material.dart or package:material_ui/material_ui.dart) from the annotated code and use it in the generated BuildContext extensions and theme lists feat: add the theme_import builder option to set that import explicitly feat: fields without a lerp (int, bool, String, enums, ...) now snap at t = 0.5 instead of producing code that does not compile feat: templates with a second constructor, a generative constructor or positional parameters fail the build with a message that names the class fix: debugFillProperties for bool fields used FlagProperty positionally and did not compile fix: hashCode is built with Object.hashAll instead of XOR, so swapped or equal field values no longer collide fix: the generated theme list carries the same ignore_for_file header as the context extensions and is formatted fix: Diagnosticable detection matched any package whose name starts with flutter fix: same-name templates whose paths nest no longer crash getter name resolution chore: allow analyzer 13 and 14 (>=8.0.0 <15.0.0) and source_gen 4.3 chore: very_good_analysis removed from the runtime dependencies chore: .theme_impl.json uses importUri like .theme_templates.json; the old import key is still read test: drop the analyzer-version-specific element mock in favor of noSuchMethod docs: document theme_import, field interpolation rules and template constraints; fix output_groups and builder names in the config examples

1.1.0 #

chore: widen analyzer constraint to >=8.0.0 <13.0.0 (support analyzer 10, 11, 12 for Dart 3.10–3.12); generator code unchanged

1.0.1 #

**Allow analyzer 9.0.0.

0.3.0 #

refactor: migrate to element2 API and remove legacy analyzer usage chore: update dependencies for Dart 3.8 and latest build/codegen packages refactor: drop manual builder config validation in favor of fromMap test: clean up outdated mocks and migrate to TestReaderWriter-based tests test: update golden files for new codegen output

0.2.1 #

chore: minor README updates and improved test coverage

0.2.0 #

feat: migrate to standalone repository from monorepo

0.1.5 #

chore(example): update structure and documentation

0.1.4 #

fix: resolve builder integration issues

0.1.3 #

chore: update CI config
test: improved test coverage and added internal validation tests

0.1.2 #

ci: added GitHub Actions
docs: improved README and formatting

0.1.1 #

feat: added library entrypoint to follow naming conventions
docs: improved documentation and score compliance
chore: minor cleanup and formatting

0.1.0 #

initial release:

  • Code generation for ThemeExtension templates and implementations
  • Support for context extensions and group-based splitting
  • Customizable output via build.yaml