|
| 1 | +## 2.1.0 |
| 2 | + |
| 3 | +### Added |
| 4 | + |
| 5 | +- `BottomBarLayout.maxWidth` and `BottomBarLayout.adaptive(maxWidth: ...)` for |
| 6 | + width-capped adaptive layouts, plus `copyWith(clearMaxWidth: true)` for |
| 7 | + returning a derived layout to an uncapped width. |
| 8 | +- `BottomBarBodyPadding` as the built-in way to reserve the live floating-bar |
| 9 | + footprint inside `BottomBar.body`. |
| 10 | +- `BottomBarScrollBehavior.showAtStart` and |
| 11 | + `BottomBarScrollBehavior.showOnScrollEnd` for settling-based visibility |
| 12 | + restoration. |
| 13 | + |
| 14 | +### Changed |
| 15 | + |
| 16 | +- `BottomBarScope.barHeight` now reflects the full rendered footprint reserved |
| 17 | + by the bar, including configured offset and bottom safe-area when enabled. |
| 18 | +- `BottomBarItem` accessible naming is now deterministic: |
| 19 | + `semanticLabel` wins, otherwise `tooltip`, otherwise descendant semantics. |
| 20 | + Explicit names exclude descendant semantics to avoid duplicate announcements; |
| 21 | + items also expose selected/enabled button state, keep a 48x48 minimum target, |
| 22 | + and place badges at the directional top-end in both LTR and RTL layouts. |
| 23 | +- Custom `BottomBarMotion.transitionBuilder` usage is documented as a |
| 24 | + paint-only contract that must preserve layout footprint. |
| 25 | +- The hidden action is direction-aware by default: glyph, tooltip, and |
| 26 | + semantics flip with `scrollOpposite`, the touch target stays at least 48x48 |
| 27 | + when active, and the default glyph color follows `ColorScheme.onPrimary`. |
| 28 | +- Hidden bar actions are non-interactive and excluded from semantics when the |
| 29 | + bar is visible. |
| 30 | +- Reduced-motion environments snap directly to the target shown/hidden state |
| 31 | + instead of animating. |
| 32 | +- `BottomBarController` ownership is strict: double-attach fails in debug and |
| 33 | + release, and visibility updates are accepted only from the owning bar. |
| 34 | +- `BottomBarController` boundary scrolling now documents and uses explicit |
| 35 | + start/end semantics independent of `scrollOpposite`. |
| 36 | + |
| 37 | +### Fixed |
| 38 | + |
| 39 | +- `BottomBarController.scrollToStart()` always targets |
| 40 | + `ScrollPosition.minScrollExtent`, and `scrollToEnd()` always targets |
| 41 | + `ScrollPosition.maxScrollExtent`. |
| 42 | +- `NestedScrollView` boundary scrolling now targets the correct coordinated |
| 43 | + controller so start/end actions reset both header and body as expected. |
| 44 | +- Large `iconOffset` values keep the hidden action tappable because hit testing |
| 45 | + now follows the translated visual position. |
| 46 | +- The hidden action's full 48x48 minimum target now accepts taps at its corners; |
| 47 | + circular clipping applies only to the animated visual. |
| 48 | +- The example web app now uses Flutter's current generated bootstrap and |
| 49 | + package-specific, orientation-neutral PWA metadata. |
| 50 | + |
1 | 51 | ## 2.0.2 |
2 | 52 |
|
3 | | -- Fix: `BottomBarController.scrollToStart()` (and the back-to-top icon) did not fully reset a `NestedScrollView` — the collapsed `SliverAppBar`/`FlexibleSpaceBar` stayed collapsed and the list landed below its true top. A `NestedScrollView` scrolls on two coordinated positions (an outer header and an inner body), but the bar only animated the most-recently-active one. The controller now detects an enclosing `NestedScrollView` and drives its shared scroll coordinator with a single call — animating the outer controller to the top (which pulls the inner body up with it) for `scrollToStart`, and the inner controller to the bottom (which collapses the header) for `scrollToEnd`. ([#21](https://github.com/codenameakshay/flutter-floating-bottom-bar/issues/21)) |
| 53 | +- Fix: `BottomBarController.scrollToStart()` (and the back-to-top icon) did not |
| 54 | + fully reset a `NestedScrollView` — the collapsed |
| 55 | + `SliverAppBar`/`FlexibleSpaceBar` stayed collapsed and the list landed below |
| 56 | + its true top. A `NestedScrollView` scrolls on two coordinated positions (an |
| 57 | + outer header and an inner body), but the bar only animated the |
| 58 | + most-recently-active one. The controller now detects an enclosing |
| 59 | + `NestedScrollView` and drives its shared scroll coordinator with a single |
| 60 | + call — animating the outer controller to the top (which pulls the inner body |
| 61 | + up with it) for `scrollToStart`, and the inner controller to the bottom |
| 62 | + (which collapses the header) for `scrollToEnd`. |
| 63 | + ([#21](https://github.com/codenameakshay/flutter-floating-bottom-bar/issues/21)) |
4 | 64 |
|
5 | 65 | ## 2.0.1 |
6 | 66 |
|
7 | | -- Fix: the back-to-top icon became unclickable when a large `iconOffset` was set. The icon was painted at the offset position but its `SafeArea` ancestor still hit-tested against the original (untranslated) rect, so a large offset moved the visible icon outside its tappable area. The offset now wraps the icon's `SafeArea` so hit-testing follows the painted position. ([#19](https://github.com/codenameakshay/flutter-floating-bottom-bar/issues/19)) |
| 67 | +- Fix: the back-to-top icon became unclickable when a large `iconOffset` was |
| 68 | + set. The icon was painted at the offset position but its `SafeArea` ancestor |
| 69 | + still hit-tested against the original (untranslated) rect, so a large offset |
| 70 | + moved the visible icon outside its tappable area. The offset now wraps the |
| 71 | + icon's `SafeArea` so hit-testing follows the painted position. |
| 72 | + ([#19](https://github.com/codenameakshay/flutter-floating-bottom-bar/issues/19)) |
8 | 73 |
|
9 | 74 | ## 2.0.0 |
10 | 75 |
|
11 | | -Major release. Breaking changes — see the migration table in README.md and EXAMPLES.md. |
| 76 | +Major release. Breaking changes — see the migration table in `README.md`. |
12 | 77 |
|
13 | 78 | Breaking: |
14 | | -- Dart SDK minimum is now `>=3.5.0` because the package uses Motor-backed motion. |
15 | | -- `BottomBar.body` is now `Widget` instead of `Widget Function(BuildContext, ScrollController)`. The bar listens to `ScrollNotification` from any descendant scrollable; you no longer wire a controller through the builder. |
16 | | -- The `barColor`, `width`, `offset`, `borderRadius`, `barAlignment`, `fit`, `clip`, `respectSafeArea` parameters have moved into `BottomBarLayout`. |
17 | | -- The `duration`, `curve`, `start`, `end` parameters have moved into `BottomBarMotion`. `BottomBarMotion()` now defaults to Cupertino spring motion; existing `BottomBarMotion(duration: ..., curve: ...)` calls remain curve-based. `start`/`end` (doubles) are now `slideStart`/`slideEnd` (`Offset`s). |
18 | | -- The `hideOnScroll`, `reverse`, `scrollOpposite`, `scrollDeltaThreshold` parameters have moved into `BottomBarScrollBehavior`. `scrollDeltaThreshold` is now `deltaThreshold`. |
19 | | -- The `iconWidth`, `iconHeight`, `iconDecoration`, `barDecoration` parameters move to `BottomBarThemeData` (per-instance overrides remain via the `theme:` argument). |
20 | | -- `BottomBarScrollControllerProvider` is replaced by `BottomBarScope`. The `scrollController` field is gone; new fields are `barHeight` and `isVisible`. |
21 | | -- The hardcoded `Colors.black` default is replaced with Material 3 `colorScheme.surfaceContainer` for the bar and `colorScheme.primary` for the icon. |
| 79 | + |
| 80 | +- Dart SDK minimum is now `>=3.5.0` because the package uses Motor-backed |
| 81 | + motion. |
| 82 | +- `BottomBar.body` is now `Widget` instead of |
| 83 | + `Widget Function(BuildContext, ScrollController)`. The bar listens to |
| 84 | + `ScrollNotification` from any descendant scrollable; you no longer wire a |
| 85 | + controller through the builder. |
| 86 | +- The `barColor`, `width`, `offset`, `borderRadius`, `barAlignment`, `fit`, |
| 87 | + `clip`, and `respectSafeArea` parameters moved into `BottomBarLayout`. |
| 88 | +- The `duration`, `curve`, `start`, and `end` parameters moved into |
| 89 | + `BottomBarMotion`. `BottomBarMotion()` now defaults to Cupertino spring |
| 90 | + motion; existing `BottomBarMotion(duration: ..., curve: ...)` calls remain |
| 91 | + curve-based. `start`/`end` (doubles) are now `slideStart`/`slideEnd` |
| 92 | + (`Offset`s). |
| 93 | +- The `hideOnScroll`, `reverse`, `scrollOpposite`, and |
| 94 | + `scrollDeltaThreshold` parameters moved into `BottomBarScrollBehavior`. |
| 95 | + `scrollDeltaThreshold` is now `deltaThreshold`. |
| 96 | +- The `iconWidth`, `iconHeight`, `iconDecoration`, and `barDecoration` |
| 97 | + parameters moved to `BottomBarThemeData` (per-instance overrides remain via |
| 98 | + the `theme:` argument). |
| 99 | +- `BottomBarScrollControllerProvider` is replaced by `BottomBarScope`. The |
| 100 | + `scrollController` field is gone; new fields are `barHeight` and `isVisible`. |
| 101 | +- The hardcoded `Colors.black` default is replaced with Material 3 |
| 102 | + `colorScheme.surfaceContainer` for the bar and `colorScheme.primary` for the |
| 103 | + icon. |
22 | 104 |
|
23 | 105 | New: |
24 | | -- Motor-backed Cupertino motion is the default show/hide engine, with velocity-preserving redirection when scroll direction changes mid-animation. |
25 | | -- `BottomBarMotion.cupertino(...)`, `BottomBarMotion.curved(...)`, and `BottomBarMotion.motor(...)` constructors. |
| 106 | + |
| 107 | +- Motor-backed Cupertino motion is the default show/hide engine, with |
| 108 | + velocity-preserving redirection when scroll direction changes mid-animation. |
| 109 | +- `BottomBarMotion.cupertino(...)`, `BottomBarMotion.curved(...)`, and |
| 110 | + `BottomBarMotion.motor(...)` constructors. |
26 | 111 | - `BottomBarThemeData` `ThemeExtension` for app-wide defaults. |
27 | | -- `BottomBarTransition` enum (`slide`, `fade`, `scale`, `slideAndFade`) plus `BottomBarMotion.transitionBuilder` escape hatch. |
| 112 | +- `BottomBarTransition` enum (`slide`, `fade`, `scale`, `slideAndFade`) plus |
| 113 | + `BottomBarMotion.transitionBuilder`. |
28 | 114 | - `BottomBarItem` and `BottomBarItems` helpers for the common nav-item case. |
29 | | -- `BottomBarScope.barHeight` exposes the live rendered bar height to descendants for content-padding purposes. |
30 | | -- `BottomBarScope.isVisible` exposes live visibility without owning a controller. |
31 | | -- Notification-based scroll detection works with `NestedScrollView`, `CustomScrollView`, multiple `TabBarView` children, and any user-supplied `ScrollController` with no wiring. |
| 115 | +- `BottomBarScope.barHeight` exposes the live rendered bar height to |
| 116 | + descendants for content-padding purposes. |
| 117 | +- `BottomBarScope.isVisible` exposes live visibility without owning a |
| 118 | + controller. |
| 119 | +- Notification-based scroll detection works with `NestedScrollView`, |
| 120 | + `CustomScrollView`, multiple `TabBarView` children, and any user-supplied |
| 121 | + `ScrollController` with no wiring. |
32 | 122 | - `BottomBarScrollBehavior.predicate` for filtering unwanted notifications. |
33 | 123 | - `BottomBarController` now asserts on double-attach in debug. |
34 | 124 |
|
35 | 125 | Repository: |
36 | | -- Package source moved from `packages/flutter_floating_bottom_bar/` to repo root. The example app moved to `example/`. The `packages/` directory is removed. |
| 126 | + |
| 127 | +- Package source moved from `packages/flutter_floating_bottom_bar/` to repo |
| 128 | + root. The example app moved to `example/`. The `packages/` directory is |
| 129 | + removed. |
37 | 130 |
|
38 | 131 | ## 1.4.0 |
39 | 132 |
|
40 | 133 | - Upgrade project/tooling for Flutter `3.41.4` development via FVM. |
41 | 134 | - Update SDK constraints and refresh dependencies. |
42 | | -- Add `BottomBarController` for programmatic `show`, `hide`, `toggle`, `scrollToStart`, and `scrollToEnd`. |
| 135 | +- Add `BottomBarController` for programmatic `show`, `hide`, `toggle`, |
| 136 | + `scrollToStart`, and `scrollToEnd`. |
43 | 137 | - Add `onVisibilityChanged` callback for visibility state transitions. |
44 | 138 | - Add `scrollDeltaThreshold` to reduce flicker from minor scroll movement. |
45 | 139 | - Add `iconSemanticLabel` and `iconTooltip` for better accessibility. |
46 | 140 | - Improve internal scroll/visibility handling and test coverage. |
47 | 141 |
|
48 | 142 | ## 1.3.0 |
49 | 143 |
|
50 | | -- Added `respectSafeArea` property to control whether the BottomBar should respect the SafeArea |
51 | | -- Removed deprecated `alignment` property (use `barAlignment` instead) |
52 | | -- Fixed ScrollController issues with multiple attachments |
53 | | -- Improved scroll listener management for better performance |
| 144 | +- Added `respectSafeArea` property to control whether the `BottomBar` should |
| 145 | + respect the safe area. |
| 146 | +- Removed deprecated `alignment` property (use `barAlignment` instead). |
| 147 | +- Fixed `ScrollController` issues with multiple attachments. |
| 148 | +- Improved scroll listener management for better performance. |
54 | 149 |
|
55 | 150 | ## 1.2.1+1 |
56 | 151 |
|
57 | | -- Fix code formatting |
| 152 | +- Fix code formatting. |
58 | 153 |
|
59 | 154 | ## 1.2.1 |
60 | 155 |
|
61 | | -- Update to Flutter v3.22.1 |
62 | | -- Fix divider error in example |
63 | | -- Update dependencies |
| 156 | +- Update to Flutter `3.22.1`. |
| 157 | +- Fix divider error in example. |
| 158 | +- Update dependencies. |
64 | 159 |
|
65 | 160 | ## 1.2.0 |
66 | 161 |
|
67 | | -- Add `offset`, `barAlignment`, `barDecoration`, `iconDecoration` properties. |
| 162 | +- Add `offset`, `barAlignment`, `barDecoration`, and `iconDecoration` |
| 163 | + properties. |
68 | 164 | - Remove `bottom` property. |
69 | | -- Deperecated `alignment` property, use `barAlignment` instead. `alignment` will be removed in a future release. |
70 | | -- Update all code examples, and fix errors. |
| 165 | +- Deprecate `alignment` in favor of `barAlignment`. |
| 166 | +- Update all code examples and fix errors. |
71 | 167 |
|
72 | 168 | ## 1.1.0 |
73 | 169 |
|
74 | | -- Add clip property to support clip behavior. |
75 | | -- Add an example for bar with a FAB. |
| 170 | +- Add `clip` property to support clip behavior. |
| 171 | +- Add an example for a bar with a FAB. |
76 | 172 |
|
77 | 173 | ## 1.0.1 |
78 | 174 |
|
79 | | -- Support for Flutter 3.10.5 |
80 | | -- Update dependencies |
| 175 | +- Support Flutter `3.10.5`. |
| 176 | +- Update dependencies. |
81 | 177 |
|
82 | 178 | ## 1.0.0+1 |
83 | 179 |
|
84 | | -- Add documentation |
| 180 | +- Add documentation. |
85 | 181 |
|
86 | 182 | ## 1.0.0 |
87 | 183 |
|
88 | | -- Initial release with basic functionality |
| 184 | +- Initial release with basic functionality. |
0 commit comments