Skip to content

New color attribute is not working in header tag, .e.g <h1 color="primary"> when it is in some container, e.g Card #8330

Closed
@bimal72

Description

@bimal72

Hello,
I have used color attribute as follows.

<ion-card  >            
            <ion-card-content style="line-height:1" padding-horizontal text-left>
              <h1 text-center margin-bottom style="font-weight:bold" color="primary" >DEALS</h1>           

It should display DEALS in primary color but it don't.
Its rendered html is

<ion-card class="card-md">
            <ion-card-content padding-horizontal="" style="line-height:1" text-left="">
              <h1 color="primary"  class="text-md text-md-primary" ng-reflect-color="primary">DEALS</h1>

But it renders dark color.

When I inspect its css rules

.card-md h1 {
    margin: 0 0 2px;
    font-size: 2.4rem;
    font-weight: normal;
    color: #222; //this is dark color it renders
}

.text-md-primary {
   color: #1f9bcc; // this is primary color - strikeout

}

As a workaround if I put DEAL label in

 <h1 text-center margin-bottom style="font-weight:bold" ><span color="primary">DEAL</span></h1>, 

it is working as desired
Please help me to implement correctly.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions