Skip to content
CAI
Software that uses CAICheck a score

BBarisKilic/Numbers

69.5

Adequate · 21 September 2026

1.8k

lines of production code

Dart

with C++, C

4

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

This is a Flutter application that allows users to search for specific numbers and generate random numbers via a remote API. It features a modular, feature-based architecture with dedicated layers for data, domain, and presentation, supporting both light and dark themes. The system includes a settings interface for theme management and localization, with native support for Android, iOS, Web, and Windows platforms.

How it got here

2022 — Architecture bootstrap and platform upgrades

18 changes.

The project transitioned from a default Flutter template to a structured architecture featuring dependency injection, centralized routing, and standardized core models for data handling and parameters. Concurrently, the Android and iOS build environments were upgraded to modern tooling versions, and custom UI components were introduced to support the new design system.

2023 — Feature-based architecture and number feature

20 changes.

The project restructured its codebase into a feature-based architecture, introducing dedicated modules for domain, data, and presentation layers. This period focused on implementing the 'number' feature, including its UI, state management, and data retrieval, while also adding Windows and web platform support and enhancing localization.

Features

Add BuildContext extension for convenient access to localization, theme, and screen metrics

A new BuildContext extension has been introduced to simplify access to common Flutter resources. Users can now directly access localization via the 'l10n' getter, retrieve theme data, text themes, and color schemes, and obtain screen height and width properties, reducing boilerplate code in UI components.

lib/src/core/extensions · high confidence

Added number domain use cases

The number feature now exposes domain use cases for retrieving a specific number and generating a random number. These new classes, GetNumberUseCase and GetRandomNumberUseCase, act as intermediaries that delegate requests to the NumberRepository, and are exported via a consolidated usecases barrel file for easier consumption by the application layer.

lib/src/features/number/domain/usecases · high confidence

Initial support for Windows desktop and web platforms

The application now includes the necessary scaffolding to run on Windows desktop and web browsers. For Windows, this adds the CMake build configuration, the Win32 window runner with high-DPI support, and the entry point to host the Flutter view. For web, this adds the HTML entry point and PWA manifest, enabling the app to be served and installed as a progressive web app.

web, windows · high confidence

Introduce Number feature page with numpad interface

The Number feature now includes a dedicated presentation page that provides a user interface for number input. This page displays a custom app bar, a text input field, an information container, and a grid-based numpad for entering digits. The view is wrapped in a BlocProvider to manage state via the NumberCubit, and it utilizes localized app titles and theme-aware styling for the app bar icon.

lib/src/features/number/presentation/pages · high confidence

Introduce NumberRepositoryImpl for number data operations

The application now includes a concrete implementation of the number repository, NumberRepositoryImpl, located in the data layer. This class handles fetching specific numbers and generating random numbers by delegating to the underlying NumbersService. It wraps the service responses in a DataState pattern, returning DataSuccess for valid results or DataFailure with detailed error information when exceptions occur, thereby centralizing error handling for number-related data retrieval.

lib/src/features/number/data/repositories · high confidence

Introduce centralized app routing configuration

Added a new \AppRoute\ class in the config layer that defines the application's navigation structure using GoRouter. This configuration establishes the route hierarchy, mapping the number page as the root and nesting the settings page within it, effectively centralizing the app's navigation logic.

lib/src/config/routes · high confidence

Introduce configurable light and dark theme support

The application now supports switching between light and dark visual themes. This change introduces a new theme configuration layer in \lib/src/config/themes\ containing an \AppTheme\ interface, an \AvailableTheme\ enum (with \light\ and \dark\ options), and concrete implementations (\LightAppTheme\ and \DarkAppTheme\). These implementations define specific \ThemeData\ settings, including colors, typography, and component styles, allowing the app to render distinct visual appearances based on the selected theme.

lib/src/config/themes · high confidence

Introduce core DataState and ErrorDetails resource models

The core layer now includes a new \DataState\ sealed class to represent operation outcomes, distinguishing between \DataSuccess\ (carrying the result data) and \DataFailure\ (carrying \ErrorDetails\). The \ErrorDetails\ class provides a structured container for error information, specifically storing the error type, message, and stack trace. These models, generated using Freezed, are exported via the \resources.dart\ barrel file to standardize how data and errors are handled throughout the application.

lib/src/core/resources · high confidence

Introduced NumberRepository interface for number data access

Added a new abstract interface class, NumberRepository, within the number feature's domain layer. This interface defines the contract for retrieving specific numbers via GetNumberParams and fetching random numbers, returning results wrapped in a DataState. A corresponding barrel file (repositories.dart) was created to export this interface, establishing the foundation for number data operations in the application.

lib/src/features/number/domain/repositories · high confidence

Introduces HTTP-based number retrieval service

The application now includes a concrete implementation for fetching number data via HTTP using the Dio client. This change adds a new \DioNumbersService\ that communicates with a remote API to retrieve specific numbers and random numbers, replacing or supplementing previous data sources. It also introduces a dedicated \NumbersService\ interface and associated exception classes (\GetNumberException\, \GetRandomNumberException\) to handle API errors and network failures gracefully within the number feature.

lib/src/features/number/data/datasources · high confidence

Introduces centralized design constants and generated asset references

The application now provides a unified constants layer for core design tokens and resource paths. This includes the new AppPadding class, which offers a comprehensive set of predefined padding values (from 4.0 to 52.0) and helper methods for EdgeInsets, as well as the IconSize class defining standard icon dimensions. Additionally, generated files for assets (images) and fonts are introduced via FlutterGen, providing type-safe access to SVG icons and font families, while dedicated classes for URL endpoints and navigation paths are established.

lib/src/core/constants · high confidence

Introduction of AppCubit for theme management

The application now uses a dedicated AppCubit to manage the app's theme state. This component initializes the theme from shared preferences on startup and allows users to update the theme (light or dark) via the UI, persisting the selection immediately. The state is handled by a new AppState class using the Freezed package for immutable state management.

lib/src/app/presentation/cubit · high confidence

Introduction of CustomAppBar widget package

A new Flutter package has been added to provide a reusable CustomAppBar widget. This component displays a custom SVG icon on the left and a text title, both of which are configurable via parameters for color, size, and spacing. The app bar includes a bottom divider and does not imply a leading navigation button, allowing for a tailored header appearance in the application.

_packages/custom\_app\bar · high confidence

Introduction of a structured params layer for theme and number operations

A new core params layer has been introduced to standardize how data is passed between layers. This includes a base \Params\ class and specific implementations: \GetThemeParams\ and \SaveThemeParams\ for managing theme keys and values, and \GetNumberParams\ for handling number requests. These classes replace ad-hoc parameter passing with a consistent, immutable structure, improving type safety and clarity for theme and number-related use cases.

lib/src/core/params · high confidence

Introduction of the app layer barrel file

A new app layer entry point (lib/src/app/app.dart) has been added to the project. This file acts as a barrel file, re-exporting the data, domain, and presentation modules to simplify imports for consumers of the application layer.

lib/src/app · high confidence

Introduction of the core UseCase interface

A new abstract interface class \UseCase\<T, P\>\ has been added to the core layer, defining a standard contract for use cases with a generic return type and parameters. This establishes the foundational structure for business logic execution within the application's architecture.

lib/src/core/usecases · high confidence

New NumberCubit for number information retrieval

The number feature now includes a dedicated presentation layer with a NumberCubit and its associated state model (NumberState). This component manages the lifecycle for fetching details about a specific number or generating a random number, exposing states for initial, loading, loaded (with info), and error conditions. It relies on injected use cases (GetNumberUseCase and GetRandomNumberUseCase) to handle the business logic, and the presentation module now exports this cubit alongside the number page.

lib/src/features/number/presentation/cubit · high confidence

New SharpToggleSwitch component with configurable styling

The sharp\_toggle\_switch package now includes a new SharpToggleSwitch widget that renders a toggle switch with sharp (non-rounded) edges. Users can configure the switch's appearance using primary and secondary colors, set the height and width, define the initial position (left or right), and provide custom labels for the left and right states. The component triggers a callback when the toggle position changes.

_packages/sharp\_toggle\switch · high confidence

New core module exports consolidated

A new core library entry point (lib/src/core/core.dart) has been introduced to centralize and export key sub-modules, including constants, extensions, localization (l10n), parameters, resources, and usecases. This change provides a single import path for accessing these foundational components, simplifying dependency management for other parts of the application.

lib/src/core · high confidence

Architecture

Introduce feature-based data layer for theme persistence

The application's data access logic has been restructured into a feature-oriented architecture under \lib/src/app/data\. This change introduces a dedicated theme data layer that separates concerns into a \ThemeService\ interface (implemented via \SharedPrefThemeService\ for local storage using \shared\_preferences\) and a \ThemeRepositoryImpl\. The repository wraps the service calls, translating service-level exceptions into a standardized \DataState\ result (success or failure with error details), providing a consistent contract for consuming code to handle theme retrieval and saving operations.

lib/src/app/data · high confidence

Restructured domain layer with feature-based organization

The domain layer has been reorganized into a feature-based structure, introducing dedicated export files for repositories and use cases. This change establishes a clear separation of concerns by defining the ThemeRepository interface and its corresponding GetThemeUseCase and SaveThemeUseCase implementations, making it easier to locate and manage domain logic related to theme management.

lib/src/app/domain · high confidence

Restructured project into feature-based modules

The project has been reorganized to follow a feature-based architecture, introducing a new 'number' feature module. This module encapsulates its data sources, models, repositories, entities, use cases, and presentation widgets, exposing them through a single entry point. Additionally, a new presentation layer module has been created to export the application cubit and main app widget, improving code modularity and separation of concerns.

(repo-wide) · high confidence

Behavioural changes

Android build environment upgraded and app branding configured

The Android build system has been upgraded to Gradle 8.4, requiring a compatible Java development environment for building the app. Additionally, the app's visual identity has been established by adding adaptive launcher icons and a branded splash screen image (ic\_launch\_image) for the main, development, staging, and release builds, while the app label is now dynamically configured via a build variable.

android · high confidence

App widget now provides AppCubit and configures localization

The root App widget has been updated to wrap the application in a BlocProvider for AppCubit, ensuring the app state is available throughout the widget tree. Additionally, the MaterialApp configuration now explicitly includes AppLocalizations delegates and supported locales, enabling proper internationalization support for the user interface.

lib/src/app/presentation/widgets · high confidence

Config layer exposes routes and themes

The configuration module now explicitly exports the application route definitions and the theme definitions, making these resources available to other parts of the application through the central config entry point.

lib/src/config · high confidence

Introduce NumberDto data model with Freezed serialization

The Number feature's data layer now includes a structured data transfer object (NumberDto) for handling number-related data. This model uses the Freezed package to provide immutable data structures, automatic copy-with functionality, and JSON serialization/deserialization via the 'info' string field. This change replaces previous ad-hoc data handling with a standardized, type-safe model for the Number feature.

lib/src/features/number/data/models · high confidence

Introduce immutable Number entity with Freezed

The Number domain entity is now implemented as an immutable class using the Freezed code-generation library. This change replaces the previous implementation with a value-type that provides automatic equality checks, hashing, and a copy-with pattern, ensuring that instances of Number (containing an info string) are safe to use in reactive UIs and state management without accidental mutation.

lib/src/features/number/domain/entities · high confidence

Refactored number feature UI into modular widgets with localization support

The number feature's presentation layer has been restructured into distinct, reusable widgets (InfoContainer, NumberTextFormField, NumpadGridView, NumpadNumberButton, and NumpadActionButton) that are now part of the main NumberPage. This change introduces support for localized strings via \context.l10n\ (e.g., 'searchANumber', 'numpadClear') instead of static constants, and updates the UI to use the app's theme for colors and text styles. The numpad grid layout is now explicitly defined with staggered grid tiles, and the input field is configured for right-to-left (RTL) text direction.

lib/src/features/number/presentation/widgets · high confidence

Relocated and regenerated localization layer

The localization infrastructure has been moved to lib/src/core/l10n and regenerated to use current Flutter internationalization standards. This update introduces the AppLocalizations delegate and English translations (app\_en.arb) for core UI strings, including the app title, settings options, theme choices, and numpad controls, ensuring consistent text display across the application.

lib/src/core/l10n · high confidence

Replaced Flutter starter template with structured app bootstrap and dependency injection

The application has moved from the default Flutter counter template to a structured architecture featuring a dedicated bootstrap process. This new entry point initializes the app with a BLoC observer, enforces portrait orientation, and configures a service locator (GetIt) to inject dependencies such as theme services, repositories, and use cases. This change establishes the foundational wiring for the app's features, replacing the previous single-file implementation with a modular setup.

lib · high confidence

Settings screen now uses localized strings and a theme toggle

The Settings feature has been refactored to replace static text constants with localized strings via AppLocalizations, ensuring the UI respects the user's language preference. The settings page now displays a list of options (Theme, Rate Us, Contact Us, Terms, Privacy) and includes a new Theme selector that allows users to switch between Light and Dark modes using a toggle switch, which updates the AppCubit state.

lib/src/features/settings · high confidence

Updated Dart analysis configuration and project metadata

The project's static analysis rules have been switched from the default Flutter lints to the Very Good Analysis package, with specific exclusions added for generated code files (such as \.freezed.dart\ and \.g.dart\) and disabled lints for \public\_member\_api\_docs\ and \avoid\_catches\_without\_on\_clauses\. Additionally, the \.gitignore\ has been expanded to cover more Android, iOS, and VS Code artifacts, and the \.metadata\ file has been updated to reflect a new Flutter stable revision.

(repo-wide) · high confidence

iOS project upgraded to Xcode 14.3 with CocoaPods integration and multi-environment support

The iOS project has been upgraded to Xcode 14.3 (objectVersion 54), raising the minimum supported iOS version to 11.0. CocoaPods integration is now fully configured, including the Pods workspace reference, framework embedding build phases, and xcconfig files for development, staging, and production environments. The app bundle now supports dynamic naming via the $(FLAVOR\_APP\_NAME) variable and includes localization for English and Spanish, along with support for indirect input events.

ios · high confidence

Test coverage

Added test helper for localized app pumping; Added unit tests for NumberRepositoryImpl; Added unit tests for domain use cases; Removed default Flutter widget smoke test.

Dependencies

Major dependency upgrades and Android build system migration

The project has upgraded core dependencies to newer major versions, including go\_router to 17.5.0, bloc to 9.2.1, dio to 5.11.0, and freezed to 4.0.0-dev.3, alongside updates to build\_runner, json\_serializable, and very\_good\_analysis. The Android build configuration has been migrated to the new Gradle plugin management DSL (settings.gradle and app/build.gradle), introducing application namespaces, product flavors (production, staging, development), and release signing configurations. Additionally, the iOS build environment was initialized with a new Podfile and lockfile, and the app now includes custom fonts and assets managed by flutter\_gen.

(dependencies) · high confidence

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

This is the PUBLIC form of this artifact. Findings are listed in full, but the details of SECURITY findings — which rule fired, in which file, on which line, and how to fix it — are deliberately withheld, and any secret-scanner results are excluded entirely. Where detail is absent here it was REMOVED FOR PUBLICATION; it is not missing from the analysis. The complete artifact is available from the repository owner.

Score

  • CAI 68 → 70 (+1.9)
  • Rubric changed (rubric-2026.08.19 → rubric-2026.09.15) — scores are not directly comparable.

Lenses

  • Code Health 93 → 100 (+6.3)
  • Architecture 99 → 92 (-7.5)
  • Maturity 57 → 57 (+0.0)
  • Readiness 65 → 70 (+5.4)
  • Security 77 → 82 (+4.5)
  • Domain Modelling 100 → 100 (+0.0)

Resolved (7)

  • Coverage not included — suite not readable by the collector
  • Dependency hygiene not measured — dependency manifest found but not parsed for hygiene
  • No exposed public API
  • Test reliability not included
  • TooManyMethods: AppPadding (lib/src/core/constants/app_padding.dart)
  • complexity unreadable for .dart, .kt, .swift — churn × complexity hotspots could not be measured
  • dormant codebase — no living knowledge left to concentrate

New (9)

  • Dependency hygiene PARTLY measured — Maven/Gradle declarations read, no dependency graph resolved
  • Documentation: no contributor guidance (README.md)
  • Documentation: no installation or build instructions (README.md)
  • Documentation: no usage examples (README.md)
  • Duplicated block (13 lines × 2) (lib/src/features/number/presentation/widgets/numpad_action_button.dart)
  • High: security finding (details withheld)
  • High: security finding (details withheld)
  • High: security finding (details withheld)
  • No ADRs found

Changes since last survey

  • 10 commits — 10 feature/other, 0 fixes

By area

  • (repo) — 6 commits
  • (root) — 4 commits

Notable commits

  • change: build(deps): bump build_runner and freezed
  • change: build(deps): bump build_runner and freezed (#255)
  • change: build(deps): bump build_runner from 2.15.0 to 2.15.1 (#251)
  • change: build(deps): bump dio from 5.10.0 to 5.11.0
  • change: build(deps): bump dio from 5.10.0 to 5.11.0 (#253)
  • change: build(deps): bump equatable from 2.0.7 to 2.1.0 (#250)
  • change: build(deps): bump go_router from 17.3.0 to 17.5.0
  • change: build(deps): bump go_router from 17.3.0 to 17.5.0 (#256)
  • change: build(deps): bump json_serializable from 6.14.0 to 6.14.1
  • change: build(deps): bump json_serializable from 6.14.0 to 6.14.1 (#254)

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

BBarisKilic/Numbers was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 21 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit 4d3194dca9a0994c89d72aba650ac3a896edbe19 — the exact code this score is about.
  • Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
  • Measured by watchdog.canine.dev using codehealth-analyzer preprod-fa71c66cabd8.