Skip to content

bug: Progress bar doesn't use theme colors #20098

@schontz

Description

@schontz

Bug Report

Ionic version:

[x] 4.x

Current behavior:

Using an ion-progress-bar with a dark theme results in a white progress bar.

Expected behavior:

Progress bar would pick up the theme colors.

Steps to reproduce:

  1. Create an app with a progress bar
  2. Use the dark theme
  3. Progress bar is a white strip

Related code:
I had to do the following to fix it:

ion-progress-bar {
  --buffer-background: var(--ion-background-color);
  --background: var(--ion-background-color);
  --progress-background: var(--ion-color-step-400);
}

It seems like that should be the default.

Ionic info:

Ionic:

   Ionic CLI       : 5.4.12 
   Ionic Framework : @ionic/react 4.11.6

Capacitor:

   Capacitor CLI   : 1.2.1
   @capacitor/core : 1.3.0

Utility:

   cordova-res : not installed
   native-run  : not installed

System:

   NodeJS : v12.11.0 
   npm    : 6.13.4
   OS     : macOS Mojave

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions