- Set background color of the main list to transparent by applying the class and adding CSS as shown.
- Add the color="none" attribute to each of the ion-item.
- lines="none" remove the lines under each of the ion-item.
Similarly one may ask, how do I change the color of my ion background?
Steps to reproduce the behavior:
- Go to any page.
- Add css class with background property to ion-content.
- Still displaying white background.
- set --background as property in css class instead of background.
- background color is working.
Also, how do you change the color of an ionic button? A color can be applied to an Ionic component in order to change the default colors using the color attribute. Notice in the buttons below that the text and background changes based on the color set. When there is no color set on the button it uses the primary color by default.
Also know, how do I change the button background color in ionic 4?
I want more colors :)
- Step 1: Create your color. I recommend you to use the Ionic Color Generator (color-generator).
- Step 2: Add this to your scss file. Now it's up to you where you add the new color.
- Step 3: Define the color for your components.
How do you add a background image in ionic 4?
You can use the CSS-Variable --background to change the background of ion-content. Put this into your components, pages or global scss. This will disabled background and then set the correct one.