vize 1.0.4
vize: ^1.0.4 copied to clipboard
A modern, developer-friendly Flutter package for effortless responsive UIs that match your Figma designs perfectly.
Changelog #
All notable changes to the Vize package are documented here.
The format follows Keep a Changelog, and this project uses Semantic Versioning.
1.0.4 - 2026-05-24 #
Fixed #
VizeLayoutsilent config reset: Now usesVize.getInfo(context, constraints)instead of callingVize.init(context)on every rebuild, so global config is never touched during local constraint changes.VizeWrapperno-op build: Was returningchildwithout surfacingVizeInfoto the tree. Replaced with a properInheritedWidget(VizeScope);VizeWrapperkept as a backward-compatible alias.adaptiveValue<T>missing implementation: Documented since 1.0.0 but never implemented. Now a typed generic helper.VizeInfomissing convenience getters:isPortrait,isLandscape,isMobile,isTablet, andisDesktopwere documented but absent from the model. All five added.VizeInfosize property aliases:vizeScreenSizeandvizeWidgetSizeadded as aliases forvizeScreenandvizeWidget(originals kept).
Added #
- Initialisation guard:
Vize.Inow throws a descriptiveAssertionErrorif accessed beforeVize.init()instead of a crypticLateInitializationError. Vize.isInitialized: StaticboolgettertrueonceVize.init()has been called. Useful in tests and splash screens.VizeInfoequality:==andhashCodeimplemented soVizeScope.updateShouldNotifyskips unnecessary rebuilds.VizeInfo.toString(): Readable debug output onVizeInfo(device: …, orientation: …, screen: …, widget: …).
Improved #
- Singleton structure:
_instanceis nowstatic Vize?guarded by an assertion rather thanlate static. sp()docs: Clarified thatsp()scales relative to Figma canvas width, so values grow proportionally on wider devices by design.
1.0.3 - 2026-03-24 #
Added #
textScalarparameter onVize.init: Adoublemultiplier (default1.0) applied on top of the responsive text scale returned byts(). Pass a user font-size preference (e.g.0.85,1.0,1.15) to scale all text app-wide without an extraMediaQuerywrapper.
1.0.2 - 2025-12-31 #
Added #
- Figma-based Scaling Extensions: Added
.fh,.fw,.fhs, and.fwsextensions for pixel-perfect Figma design implementation. - Figma-based Helper Functions: Added
fw(),fh(),fws(), andfhs()helper functions for Figma-faithful scaling. - Clear API Documentation: Enhanced documentation with clear usage examples and guidance on when to use percentage-based vs Figma-based scaling.
Improved #
- Backward Compatibility: All existing percentage-based extensions (
.h,.w,.hs,.ws) remain unchanged for backward compatibility. - Developer Experience: Developers can now choose between percentage-based responsive layouts and Figma-faithful designs with clear, distinct APIs.
- Code Organization: Separated percentage-based and Figma-based utilities with comments.
Documentation #
- Usage Guidelines: Added comprehensive comments explaining when to use each type of scaling:
- Use
.h,.w,.hs,.wsfor responsive percentage-based layouts - Use
.fh,.fw,.fhs,.fwsfor Figma-faithful, pixel-perfect designs
- Use
- Migration Path: Existing code continues to work unchanged; new Figma features are additive.
1.0.1 - 2025-12-21 #
Added #
- VizeLayout Widget: A new reactive wrapper that automatically rebuilds UI and refreshes
Vizelogic when screen constraints or orientation change. - Vize.getInfo: Added a dedicated static method for capturing local widget constraints without colliding with global state.
Fixed #
- Reactivity Issue: Fixed a bug where scaling extensions (
.w,.h, etc.) wouldn't update on window resize or orientation change without a hot reload. - Naming Collision: Resolved a conflict between the
Vize.infostatic method and theVize.I.infogetter. - Type Safety: Fixed a type mismatch in the
VizeInfomodel assignment.
Improved #
- Linting: Addressed internal field warnings for better code health.
1.0.0 - 2025-12-21 #
Added #
- Initial release
- Responsive device detection (Watch, Mobile, Tablet, Desktop)
- Figma-perfect scaling (
sw,sh,ts,r, etc.) - Percentage-based layouts (
w,h,ws,hs) - Responsive padding (
pa,ps,po) and standard spacing (sp) - Number extensions for clean syntax
- Adaptive helpers (
adaptiveColumns,adaptiveValue) - Widgets:
VizeBuilder,VizeLayout - Customizable breakpoints and Figma dimensions
- Full documentation and examples