How to change ion-card background color


#1

I want to change ion-card background color but i dont know how to change.please help me anyone.
Thanks


#2

Override your theme in : my_project/src/theme/variables.scss
Android

$card-md-background-color: #000;

ios

$card-ios-background-color: #000;

You can find all variables here: https://ionicframework.com/docs/theming/overriding-ionic-variables/


#3

i think this should be global

How Can i setup for a specific page…?


#4

In your .scss file of your page, use .card class like this

.card {
  background-color: #000; // black
}

#6

It works…

Thanks for your help

can i remove the shadow of ion card


#7

Yes you can

.card {
  background-color: #000; // black
  box-shadow: none;
}

#8

Thanks bro …it works out…

Thanks for your concern