Button Text Color


Topic: Button Text Color

Hi , I have a button and want to use any of the possible text colors ( https://mdbootstrap.com/docs/react/css/colors/#text-colors ) for all of the possible colors ( https://mdbootstrap.com/docs/react/css/colors ) to be used for button's color

for instance: How to set button's text color to black or red in this example:

MDBBtn className=" rounded text-dark blue lighten-5" > Test Button /MDBBtn>

As its showing white on light blue and I want to change it to text-dark.


Anna Morawska staff answered 3 years ago

Hi there,

it's a bug which is already fixed in the version we are currently working on - it will be available next Monday. For now, you can use a small hotfix :

import React from 'react';
import { MDBBtn } from 'mdbreact';

const ButtonPage = () => {

  return (
    <MDBBtn color=" red-text" className="rounded blue lighten-5">Test Button</ MDBBtn >
  );
}

export default ButtonPage;

Please insert min. 20 characters.

FREE CONSULTATION

Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.

Status

Answered

Specification of the issue
  • User: Free
  • Premium support: No
  • Technology: MDB React
  • MDB Version: 4.11.0
  • Device: Mac
  • Browser: Chrome
  • OS: MacOS
  • Provided sample code: No
  • Provided link: Yes
Tags