Releases: cevheri/flutter-bloc-advanced
v0.20.0
What's New in v0.20.0
Features
- Breadcrumb Navigation — Implemented breadcrumb navigation with resolver and widget
- Connectivity Monitoring & Analytics — Enhanced app functionality with connectivity monitoring and analytics integration
- Dynamic Versioning — Integrated
package_info_plusfor dynamic versioning - System Theme Detection — Enhanced theme management to support system brightness detection
- Community Section — Added community section with links and localization support
- Documentation Links — Added website link to sidebar and settings for documentation access
- Dynamic Documentation URLs — Integrated TemplateConfig for dynamic documentation URLs
- Responsive User List — Enhanced user list page with responsive design and new components
- AppShell State Management — Refactored AppShell to manage menu loading and enhance state management
- GitHub Community Standards — Added issue templates (bug report, feature request) and pull request template
Bug Fixes
- Improved security utility and cache interceptor error handling
- Fixed
docsUrlin TemplateConfig to point to the official documentation site - Fixed
translate_menu_titleparameter type for consistency
Refactoring
- Clean, modernize, and strengthen template architecture
- Simplified theme management in AppView and ThemeBloc
- Updated ChangePasswordScreen and ForgotPasswordScreen for improved UI and state management
- Improved overall code readability and formatting
- Removed Poppins font assets and related download script
- Removed
returnToSettingsparameter from account and auth screens
CI/CD & Infrastructure
- Updated GitHub Actions workflows to use latest action versions
- Updated CI workflows for improved structure and functionality
- Enhanced web build configuration and added SEO assets
- Updated favicon and added new icon assets
- Added Yandex verification and updated sitemap for SEO
Localization
- Enhanced localization files for English and Turkish
Full Changelog: v0.19.3...v0.20.0
v0.19.3
Feature-First Clean Architecture Migration
Type: BREAKING CHANGE
Summary
Complete architectural migration from Layered (Horizontal) Architecture to Feature-First Clean Boundaries Architecture. This release restructures the entire codebase into self-contained feature modules, introduces the Use Case pattern, replaces mockito with mocktail, removes code generation dependencies, and aligns the test structure with the new architecture.
Highlights
- Layered architecture -> Feature-first clean boundaries
- 6 isolated feature modules:
account,auth,catalog,dashboard,settings,users - Use Case pattern: BLoC -> UseCase -> Repository Interface
- mockito -> mocktail migration (57 generated
.mocks.dartfiles removed) - build_runner, json_serializable, auto_route removed
- 44 dead code files eliminated (city, district, customer modules)
- Test folder restructured to mirror
lib/feature-first layout - 472 tests passing, 0 failures, 0 analyzer issues
Architecture: Before vs After
Before (Layered)
lib/
├── configuration/ # All config in one place
├── data/
│ ├── models/ # ALL models together
│ └── repository/ # ALL repositories together
├── presentation/
│ ├── common_blocs/ # ALL BLoCs together
│ ├── common_widgets/
│ ├── design_system/
│ ├── screen/ # Screens grouped by feature but BLoCs separate
│ └── shell/
├── routes/ # All routing config
└── utils/ # All utilities
After (Feature-First)
lib/
├── app/ # Composition root
│ ├── bootstrap/ # App startup
│ ├── di/ # Dependency injection
│ ├── localization/ # Language management
│ ├── router/ # Centralized routing (composes feature routes)
│ ├── session/ # Auth session cubit
│ ├── shell/ # App shell (sidebar, top bar, bottom nav, drawer, command palette)
│ └── theme/ # Theme BLoC
├── core/ # Cross-cutting primitives (zero dependencies)
│ ├── errors/
│ ├── logging/
│ ├── security/
│ └── testing/
├── features/ # 6 self-contained business modules
│ ├── account/
│ ├── auth/
│ ├── catalog/
│ ├── dashboard/
│ ├── settings/
│ └── users/
├── infrastructure/ # External adapters
│ ├── config/ # Environment, constants
│ ├── http/ # HTTP client
│ └── storage/ # Local storage
├── shared/ # Business-free reusable components
│ ├── design_system/ # 14 components, tokens, theme
│ ├── models/ # Cross-feature entities (UserEntity)
│ ├── utils/ # Generic utilities
│ └── widgets/ # Reusable form widgets
├── generated/ # Auto-generated localization
├── l10n/ # ARB translation files (en, tr)
└── main/ # Entry points
Feature Module Structure
Each feature follows a standardized 5-layer internal structure:
features/<feature>/
├── application/ # BLoCs + Use Cases
│ ├── <feature>_bloc.dart
│ ├── <feature>_event.dart
│ ├── <feature>_state.dart
│ └── usecases/
├── data/ # Models, Mappers, Repository implementations
│ ├── models/
│ ├── mappers/
│ └── repositories/
├── domain/ # Interfaces (Flutter-free)
│ ├── entities/
│ └── repositories/
├── navigation/ # Feature-specific routes
└── presentation/ # Pages and feature-local widgets
├── pages/
└── widgets/
Dependency Rules
app --> features, shared, infrastructure, core
features --> shared, infrastructure, core
shared --> core only
infrastructure --> core only
core --> nothing
- Features CANNOT import from other features' internal directories.
- Cross-feature models/widgets MUST live in
shared/. - 0 boundary violations detected.
Breaking Changes
Removed Packages
| Package | Reason |
|---|---|
build_runner |
No code generation needed (manual fromJson/toJson) |
json_serializable |
Replaced with manual serialization + Equatable |
mockito |
Replaced with mocktail |
auto_route |
Fully migrated to go_router |
New Dev Dependencies
| Package | Version | Purpose |
|---|---|---|
mocktail |
^1.0.4 | Simplified mock management without code generation |
Removed Modules (Dead Code)
| Module | Files Removed | Reason |
|---|---|---|
| City (BLoC + Model + Repository) | 6 | Unused |
| District (BLoC + Model + Repository) | 6 | Unused |
| Customer (Screen + BLoC + Model + Repository) | 11 | Empty BLoC, unused screens |
| Home Screen (legacy) | 1 | 0 imports |
| utils/message.dart | 1 | 0 imports |
| utils/storage.dart | 1 | Entirely commented-out code |
| top_actions_widget.dart | 1 | 0 imports |
| drawer_widget.dart (legacy) | 1 | 0 imports |
| Mock JSON files | 5 | Belonged to removed modules |
| Related test files | 11 | Belonged to removed modules |
| Total | ~44 files |
Import Path Changes
All imports changed from layered paths to feature-first paths:
// Before
import 'package:flutter_bloc_advance/data/models/user.dart';
import 'package:flutter_bloc_advance/data/repository/user_repository.dart';
import 'package:flutter_bloc_advance/presentation/screen/user/bloc/user_bloc.dart';
// After
import 'package:flutter_bloc_advance/features/users/data/models/user.dart';
import 'package:flutter_bloc_advance/features/users/data/repositories/user_repository.dart';
import 'package:flutter_bloc_advance/features/users/application/user_bloc.dart';Added
Use Case Pattern
BLoCs now depend on use cases instead of directly on repositories:
// Before
class LoginBloc extends Bloc<LoginEvent, LoginState> {
final LoginRepository repository;
LoginBloc({required this.repository});
}
// After
class LoginBloc extends Bloc<LoginEvent, LoginState> {
LoginBloc({
required AuthenticateUserUseCase authenticateUserUseCase,
required SendOtpUseCase sendOtpUseCase,
required VerifyOtpUseCase verifyOtpUseCase,
required GetAccountUseCase getAccountUseCase,
});
}17 use cases implemented across all features.
Centralized Dependency Injection
// lib/app/di/app_dependencies.dart - Repository factories
class AppDependencies {
IAccountRepository createAccountRepository() => AccountRepository();
IAuthRepository createAuthRepository() => LoginRepository();
IUserRepository createUserRepository() => UserRepository();
// ...
}
// lib/app/di/app_scope.dart - BLoC providers composition rootFeature Route Composition
// lib/app/router/app_router.dart
ShellRoute(
builder: (context, state, child) => AppShell(state: state, child: child),
routes: [
...DashboardFeatureRoutes.routes,
...AccountFeatureRoutes.routes,
...UsersFeatureRoutes.routes,
...SettingsFeatureRoutes.routes,
...CatalogFeatureRoutes.routes,
],
),
...AuthFeatureRoutes.routes, // Outside shell (no auth required)Changed
Test Infrastructure: mockito -> mocktail
Commit: 09b4ea8
| Metric | Before | After |
|---|---|---|
| Mock framework | mockito + build_runner | mocktail |
Generated .mocks.dart files |
57 | 0 |
| Mock definition | @GenerateMocks([...]) annotation |
Manual class MockX extends Mock implements X |
| Stub syntax | when(mock.method()).thenReturn(...) |
when(() => mock.method()).thenReturn(...) |
| Central mock file | None (scattered) | test/mocks/mock_classes.dart |
Test Folder Structure
Test directory restructured to mirror lib/ feature-first layout:
test/
├── app/ # app/ tests
│ ├── di/ # DI contract tests
│ ├── localization/ # Localization tests
│ ├── router/ # Router tests
│ └── shell/ # Shell & drawer bloc tests
│ └── models/
├── core/ # core/ tests
│ ├── constants/
│ ├── logging/
│ └── security/
├── features/ # Feature tests (mirrors lib/features/)
│ ├── account/
│ │ ├── application/ # AccountBloc tests
│ │ ├── data/ # Repository & model tests
│ │ └── presentation/ # Page widget tests
│ ├── auth/
│ │ ├── application/ # Login, Register, ForgotPassword, ChangePassword bloc tests
│ │ ├── data/ # JWT, OTP model tests, LoginRepository tests
│ │ └── presentation/ # Login, Register, ForgotPassword page tests
│ ├── dashboard/
│ │ ├── application/ # DashboardCubit tests
│ │ ├── navigation/ # Route tests
│ │ └── presentation/ # Dashboard & home page tests
│ ├── settings/
│ │ ├── application/ # SettingsBloc tests
│ │ ├── navigation/ # Route tests
│ │ └── presentation/ # Settings page tests
│ └── users/
│ ├── application/ # UserBloc, AuthorityBloc tests
│ ├── data/ # User, Authority model & repository tests
│ ├── navigation/ # Route tests
│ └── presentation/ # UserList, UserEditor page tests
├── infrastructure/ # infrastructure/ tests
│ ├── config/ # Environment tests
│ ├── http/ # HTTP utils tests
│ └── storage/ # LocalStorage tests
├── shared/ # shared/ tests
│ ├── design_system/
│ │ └── tokens/ # Spacing token tests
│ └── widgets/ # Shared widget tests
├── mocks/ # Centralized test infrastructure
│ ├── m...
v0.18.5
Release Notes - v0.18.5 (Modern UI/UX Enhancement)
New Features
- Design System Components: 14+ new composable UI components added
- AppAvatar, AppBadge, AppButton, AppCard, AppDivider, AppInput
- AppEmptyState, AppErrorState, AppLoadingOverlay, AppSkeleton
- AppSheet, AppToast, AppPageTransition, AppResponsiveBuilder
- AppForm Components: AppFormCard, AppFormField, AppFormSection, AppFormActions for streamlined form handling
- Responsive App Shell: Sidebar navigation, top bar, breadcrumb, bottom nav, and command palette (Ctrl+K/Cmd+K) support
- SidebarBloc: New BLoC for sidebar state management (collapse/expand, active route, sub-menus)
- Component Catalog: Dev/test component catalog available at /catalog route
- AuthoritiesDropdown: Required field validation and improved UI with selection feedback
Improvements
- Login Screen: Converted to StatefulWidget with animations, responsive desktop/mobile layout, dynamic dark/light theme support
- Dashboard: Chart support via fl_chart, skeleton loading, cubit-based data management
- Settings Screen: Redesigned with grouped sections
- Account Screen: Modernized with avatar and AppCard integration
- User Management: UserEditorScreen and ListUserScreen made responsive, improved search functionality
- Theme System: Enhanced Material 3 configuration, added SemanticColors ThemeExtension, aligned with shadcn/ui standards
- Design Tokens: Consolidated AppSpacing, AppBreakpoints, AppDurations, AppSizes, AppRadius tokens
- Page Transitions: Added fade/slide animations and AppCard hover effects
Routing
- Consolidated go_router as the primary router with ShellRoute wrapping authenticated routes
- Removed legacy auto_route and GetX routing code
- Updated catalog, account, settings, and user routes
Dependency Changes
- Added: cached_network_image, fl_chart (v1.1.1), shimmer, sqflite
- Removed: adaptive_theme, auto_route, getwidget and 8 other unused packages
- Updated: fl_chart v0.70.0 → v1.1.1
- Moved: device_preview to dev dependencies
Documentation
- Added Flutter Modern UI Design Guide (Tailwind CSS / shadcn/ui approach)
- Added high-level architecture diagram (SVG)
- Comprehensive README.md update (project description, features, installation, screenshots)
- Added mobile and web UI screenshots (login, edit user, list user)
Code Cleanup
- Removed padding_spacing.dart, migrated to token system
- Reorganized theme_colors.dart
- Updated test files to align with new component structure
Change Summary: 85 files changed | ~6,200+ additions | ~2,700+ deletions
Full Changelog: v0.18.0...v0.18.5
v0.17.0
Overview
A polished release focusing on a comprehensive Material 3 theme rollout with the Poppins font, web enhancements, UI refinements, quality improvements, and build configuration updates.
Highlights
- Material 3 theme applied across the app with Poppins typography
- Web-specific components and automated font download support
- UI/UX refinements on settings and global components
- Quality pass addressing deprecated APIs and boosting test coverage
- Updated Android NDK and build configs
Added
- Implement comprehensive Material 3 theme system with Poppins font and apply to all screens (08e153b)
- Web: add web-specific components and font download script (3dc76c6)
- UI: add Poppins font family and typography configuration (deb865e)
Changed
- Update state management and UI components with new font integration (624f14e)
- Settings screen: adjust spacing and update icons for better clarity (3a0f67e)
Fixed / Quality
- Complete code analysis including formatting, deprecated API fixes, and enhanced test coverage (01ad77b)
Removed
- Remove font test widget and related code from drawer (5e03ac2)
Build / CI / Chore
- Update ndkVersion, add pubspec.lock, and Flutter run configuration (ccd9801)
- Update .gitignore to exclude Oracle JDK files (257f693)
- Revert style formatting change (cf2072a)
- Merge PR #52 by yusuf-gundogdu (3cd6b3b)
Breaking Changes
- None
Upgrade Notes
- Requires Flutter 3.32.8 and Dart SDK 3.8.1 (see
pubspec.yaml) - Recommended: run
flutter clean && flutter pub getafter upgrading - No manual migrations expected; verify theme and typography on custom widgets
- For web targets, ensure assets are served correctly and fonts are fetched on first load
Contributors
- Thanks to @yusuf-gundogdu for contributions via PR #52
v0.16.0
What's Changed
Full Changelog: v0.15.0...v0.16.0
Dashboard (Mock) overhaul, Drawer refactor, theme fix, and web build updates
Web URL: https://cevheri.github.io/flutter-bloc-advanced/
Highlights
- Mock-driven Dashboard foundation with basic UI wiring
- Quick actions redesigned as chip-like buttons with a “More” bottom-sheet
- Drawer state management and initialization refactor
- Theme switching race-condition fix
- Web build/deploy reliability improvements and formatting updates
Added
- Dashboard: model, mock repository, cubit, and basic UI wiring
- Dashboard: provide
DashboardCubitwith mock repository inHomeScreen - Dashboard: quick actions redesigned as chip-like buttons with a “More” bottom-sheet
- Web build: add build web actions
Changed
- Drawer: refactor state management and initialization
- Icon utilities: replace
string_2_iconwithicon_utilsand update drawer widget - Formatting: set Dart formatter
page_widthto 125 inanalysis_options.yaml; remove trailing newlines and apply consistent formatting - Dependencies: update Flutter and package versions
- Dashboard: initial design/wireframe; repo scan and baseline tests
Fixed
- Theme: resolve race-condition during theme switching
- Dashboard: remove direct
partimport fromHomeScreen - Web: fix web build and deploy to target
Breaking Changes
- None
How to Test
flutter clean && flutter pub getflutter analyze && flutter testflutter run -d chrome- Navigate to Dashboard and verify:
- Quick actions appear as chips; “More” opens a bottom-sheet
- Drawer transitions are consistent
- Theme toggling is stable (no flicker)
Notes
- This is a minor release (no breaking changes); suitable for tagging as
v0.8.0. - Full changelog is reflected under Unreleased in
CHANGELOG.md.
v0.15.0
v0.14.0
What is changed
feat: Add OTP support(local and API). Add new two widget : login with email. otp-send email widget and otp-verfiy widget.
test: Add OTP unit tests.
Full Changelog: v0.13.2...v0.14.0
v0.13.2
What is changed
- Add new common widgets for responsive usage(web or mobile) form and submit button.
- Fix unit-test sonar coverage.
Full Changelog: v0.13.1...v0.13.2
v0.13.1
What is changed
Fix
- Fixed flutter upgrade issues
- Fixed register screen route
- Fixed logout issue
- Fixed some unittests
Add
- Security enhancements
- Performance enhancements
Full Changelog: v0.13.0...v0.13.1
Sonarcloud latest status:
v0.13.0
What's Changed
-
Router, Screen state management enhancement and performance improvement by @cevheri in #38
-
feat: add go_router implementation
-
fix: flutter analyze issues
-
feat: implement Custom app router
-
chore: menu root,leaf and authorities
-
security: add hasAuthority check for user.roles and menu.roles check
-
test: fix drawer menu tests
-
fix: go_router redirect to login when account is failure(invalid TOKEN)
-
fix: go_router redirect problem in production(API call waiting)
-
fix: check jwt token for production and mock data
-
logs: add log tracer
-
feat: change languageSWitch button to stateless
-
fix: theme-mode button fixed
-
docs: add flutter stream guide
-
docs: update flutter stream guide, more use-case
-
feat: account screen structure changed. formBuilder state management fixed. handle bloc state changes
-
feat: user-screen structure changed(create, update, view screen removed and move to the UserEditorScreen)
-
chore: user and account state main data renamed
-
fix: user-list action buttons size and routing fixed
-
feat: user list screen refactored
-
refactor: change http utils get methods and mock json structure with pathParams and queryParams
-
refactor: add new authority dropdown widget
-
refactor: new user structure completed. user_list, user_editor(create, view, edit modes)
-
refactor: reformat code, organize import
-
feat: add back button in list-screen
-
fix: Add common confirmation_dialog and go_router and bloc provider enhancement. lazy loading blocProvider.
-
refactor: user-routes can work default bloc and repository or initialize exist bloc and repository
-
bump: flutter version upgrade to 3.27.1
Full Changelog: v0.12.0...v0.13.0
