Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Version History

« Previous Version 5 Next »

React Components

Currently, no official <Button> component is defined mattermost-webapp. Most buttons are defined using inline jsx in the render() method.

Known Class Names

Button styles are inherited from the Bootstrap 3.4.1 npm package as well as Jasny Boostrap 3.1.3. Top-level class names are outlined in https://github.com/mattermost/mattermost-webapp/blob/master/sass/components/_buttons.scss but derive from the Bootstrap 3.4.1 core CSS.

  • btn

    • btn-primary

    • btn-cancel

    • btn-link

Examples

Primary button inside of the <ConfirmModal> component (View code on GitHub)

<button type="button" class="btn btn-primary" id="confirmModalButton">
  <span>Yes, set my status to "Online"</span>
</button>

Link button inside of the <ConfirmModal> component

<button type="button" class="btn btn-link btn-cancel" id="cancelModalButton">
  <span>No, keep it as "Away"</span>
</button>
  • No labels

0 Comments

You are not logged in. Any changes you make will be marked as anonymous. You may want to Log In if you already have an account.