Can we access your project?
Current Behavior
Hi Team!
Here is the detailed description of the error blocking my project:
-
The Exact Error Message:
Nav Bar references theme color "on_primary" that does not exist.
-
Description of the Bug:
This is a ghost/phantom reference issue. The "Show Nav Bar" toggle is completely disabled (turned off) in my global project settings. However, FlutterFlow’s background compiler is still trying to validate the Nav Bar's internal properties and flags a missing on_primary color token.
-
Why I cannot fix it from the UI:
If I turn the Nav Bar toggle ON to find the culprit, I am blocked by the requirement to have at least two pages set to "Show on Nav Bar".
Even when bypassed, the on_primary color reference does not appear anywhere in the style options.
I cannot create a fallback Custom Color named on_primary because the FlutterFlow UI strictly forbids underscores (_) in custom color variable names. (I tried creating onPrimary, but the compiler still looks for the snake_case version).
- Expected Resolution:
Since this reference is stuck in the project's metadata/backend JSON and hidden from the visual builder, I need your technical team to manually clear/flush my project's backend cache or remove the dead on_primary key from the Nav Bar configuration file (main.dart level).
Thank you very much for your assistance!
Expected Behavior
Since the "Show Nav Bar" toggle is disabled, the project should compile successfully without throwing validation errors for hidden Nav Bar styling properties. Deleting or renaming theme colors should not leave corrupted, uneditable background references in configuration files.
Steps to Reproduce
Go to Theme Settings -> Colors and use a theme design system that natively includes or previously referenced the color token on_primary.
Ensure that the global Nav Bar styling properties have initialized background metadata pointing to this on_primary color.
Delete, rename, or modify the color palette so that on_primary no longer exists in the active theme colors list.
Navigate to Settings -> Nav Bar & AppBar and toggle "Show Nav Bar" to OFF.
Click on the bug icon to run project validation or attempt to compile the application.
Actual Result:
The project validation fails and triggers a hard blocking error: "Nav Bar references theme color "on_primary" that does not exist.", despite the Nav Bar widget being completely disabled and its styling parameters hidden from the user interface.
Why it cannot be bypassed by the user:
Toggling "Show Nav Bar" back ON immediately triggers a secondary UI block requiring at least two pages to be added to the Nav Bar.
Creating a manual custom color named on_primary as a fallback is strictly impossible because the character validator for Custom Colors completely rejects underscores (_).
Reproducible from Blank
Bug Report Code (Required)
IT4gkvLq24lOxcdY7aX6bu9Vo2MsQmF6apc0sNobbxAjIoDoPJkUafTBblpvTu7jS29PKEWL/UMC0c3HhvLPMsIoAzKCUb5i+JN5Wxbhcz+/aoSkCpeSQX98DZ9RN2aF0qaNrwlSNfhvW3gg2Uz3H+i/fA/rNOL6Zwh9f6PHaOI=
Visual documentation
Environment
- FlutterFlow version:
- Platform:
- Browser name and version:
- Operating system and version affected:
Additional Information
No response
Can we access your project?
Current Behavior
Hi Team!
Here is the detailed description of the error blocking my project:
The Exact Error Message:
Nav Bar references theme color "on_primary" that does not exist.
Description of the Bug:
This is a ghost/phantom reference issue. The "Show Nav Bar" toggle is completely disabled (turned off) in my global project settings. However, FlutterFlow’s background compiler is still trying to validate the Nav Bar's internal properties and flags a missing on_primary color token.
Why I cannot fix it from the UI:
If I turn the Nav Bar toggle ON to find the culprit, I am blocked by the requirement to have at least two pages set to "Show on Nav Bar".
Even when bypassed, the on_primary color reference does not appear anywhere in the style options.
I cannot create a fallback Custom Color named on_primary because the FlutterFlow UI strictly forbids underscores (_) in custom color variable names. (I tried creating onPrimary, but the compiler still looks for the snake_case version).
Since this reference is stuck in the project's metadata/backend JSON and hidden from the visual builder, I need your technical team to manually clear/flush my project's backend cache or remove the dead on_primary key from the Nav Bar configuration file (main.dart level).
Thank you very much for your assistance!
Expected Behavior
Since the "Show Nav Bar" toggle is disabled, the project should compile successfully without throwing validation errors for hidden Nav Bar styling properties. Deleting or renaming theme colors should not leave corrupted, uneditable background references in configuration files.
Steps to Reproduce
Go to Theme Settings -> Colors and use a theme design system that natively includes or previously referenced the color token on_primary.
Ensure that the global Nav Bar styling properties have initialized background metadata pointing to this on_primary color.
Delete, rename, or modify the color palette so that on_primary no longer exists in the active theme colors list.
Navigate to Settings -> Nav Bar & AppBar and toggle "Show Nav Bar" to OFF.
Click on the bug icon to run project validation or attempt to compile the application.
Actual Result:
The project validation fails and triggers a hard blocking error: "Nav Bar references theme color "on_primary" that does not exist.", despite the Nav Bar widget being completely disabled and its styling parameters hidden from the user interface.
Why it cannot be bypassed by the user:
Toggling "Show Nav Bar" back ON immediately triggers a secondary UI block requiring at least two pages to be added to the Nav Bar.
Creating a manual custom color named on_primary as a fallback is strictly impossible because the character validator for Custom Colors completely rejects underscores (_).
Reproducible from Blank
Bug Report Code (Required)
IT4gkvLq24lOxcdY7aX6bu9Vo2MsQmF6apc0sNobbxAjIoDoPJkUafTBblpvTu7jS29PKEWL/UMC0c3HhvLPMsIoAzKCUb5i+JN5Wxbhcz+/aoSkCpeSQX98DZ9RN2aF0qaNrwlSNfhvW3gg2Uz3H+i/fA/rNOL6Zwh9f6PHaOI=
Visual documentation
Environment
Additional Information
No response