Skip to content

Ion-icon with slot attribute wrong color in ion-item with color attribute on android #17557

Closed

Description

@Spinnenzunge

Bug Report

Slotted ion-icon does not apply the contrast color of the color variable that is set on ion-item on Android.

Ionic version:

[x] 4.x

Current behavior:
If I set the color attribute on an ion-item, the ion-icon with slot="start" does not apply the contrast color of my set color on Android.

Expected behavior:
Contrast color of my color variable is set to slotted ion-icon on Android the same it is on iOS.

Steps to reproduce:

<ion-item color="primary" lines="none">
   <ion-icon src="assets/icon/icon.svg" slot="start"></ion-icon>
   <ion-label>Label</ion-label>
</ion-item>

Related code:
Following CSS is probably interfering.

::slotted(ion-icon) {
    color: rgba(var(--ion-text-color-rgb,0,0,0),.54);
    font-size: 24px;
}

Ionic info:

Ionic:

   ionic (Ionic CLI)             : 4.10.3 (/usr/local/lib/node_modules/ionic)
   Ionic Framework               : @ionic/angular 4.0.1
   @angular-devkit/build-angular : 0.12.4
   @angular-devkit/schematics    : 7.2.4
   @angular/cli                  : 7.2.4
   @ionic/angular-toolkit        : 1.4.0

System:

   NodeJS : v10.14.1 (/usr/local/bin/node)
   npm    : 6.7.0
   OS     : macOS Mojave

Activity

  1. added
    package: core
    type: bug
    on Feb 22, 2019
  2. self-assigned this
    on Feb 22, 2019
  3. liamdebeasi commented on Mar 1, 2019

    @liamdebeasi
    Contributor

    Hi there,

    Thanks for the issue! This has been merged (via #17585) and will be in the next release of Ionic.

  4. ionitron-bot commented on Mar 31, 2019

    @ionitron-bot

    Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out.

  5. locked and limited conversation to collaborators on Mar 31, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

package: coretype: bug

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions