MDC Pug3.0.0-beta.3
codeforumbug_report

Examples

Basic card

codecode_off

Title

Visit ten places on our planet that are undergoing the biggest changes today.

+mdc-card
    +mdc-card__header('Title')
 
    // or
    // +mdc-card__header(title='Title')
 
    +mdc-card__section()(secondary)
        +mdc-typography('Visit ten places on our planet that are undergoing the biggest changes today.')(type='body2' noMargin)

Card with a primary action

codecode_off

Title

Visit ten places on our planet that are undergoing the biggest changes today.

+mdc-card
    +mdc-card__primary-action
        +mdc-card__header('Title')
 
        +mdc-card__section()(secondary)
            +mdc-typography('Visit ten places on our planet that are undergoing the biggest changes today.')(type='body2' noMargin)

Card with subtitle

codecode_off

Title

Subtitle

Visit ten places on our planet that are undergoing the biggest changes today.

+mdc-card
    +mdc-card__header('Title', 'Subtitle')
 
    // or
    // +mdc-card__header(title='Title' subtitle='Subtitle')
 
    +mdc-card__section()(secondary)
        +mdc-typography('Visit ten places on our planet that are undergoing the biggest changes today.')(type='body2' noMargin)

Card with overline

codecode_off
Overline

Title

Subtitle

Visit ten places on our planet that are undergoing the biggest changes today.

+mdc-card
    +mdc-card__header('Title', 'Subtitle', 'Overline')
 
    // or
    // +mdc-card__header(
    //     overline='Overline'
    //     title='Title'
    //     subtitle='Subtitle'
    // )
 
    +mdc-card__section()(secondary)
        +mdc-typography('Visit ten places on our planet that are undergoing the biggest changes today.')(type='body2' noMargin)

Card with a header graphic

codecode_off
star

Title

Visit ten places on our planet that are undergoing the biggest changes today.

+mdc-card
    +mdc-card__header(
        title='Title'
        icon='star'
    )
 
    +mdc-card__section()(secondary)
        +mdc-typography('Visit ten places on our planet that are undergoing the biggest changes today.')(type='body2' noMargin)

Card with a header action

codecode_off

Title

star

Visit ten places on our planet that are undergoing the biggest changes today.

+mdc-card
    +mdc-card__header('Title')(withActions)
        +mdc-card__header__actions
            +mdc-card__icon('star')
 
    +mdc-card__section()(secondary)
        +mdc-typography('Visit ten places on our planet that are undergoing the biggest changes today.')(type='body2' noMargin)

Card with buttons

codecode_off

Title

Visit ten places on our planet that are undergoing the biggest changes today.

+mdc-card
    +mdc-card__header('Title')
 
    +mdc-card__section()(secondary)
        +mdc-typography('Visit ten places on our planet that are undergoing the biggest changes today.')(type='body2' noMargin)
 
    +mdc-card__actions
        +mdc-card__button('Button')
        +mdc-card__button('Button')

Card with icons

codecode_off

Title

Visit ten places on our planet that are undergoing the biggest changes today.

starfavorite
+mdc-card
    +mdc-card__header('Title')
 
    +mdc-card__section()(secondary)
        +mdc-typography('Visit ten places on our planet that are undergoing the biggest changes today.')(type='body2' noMargin)
 
    +mdc-card__actions
        +mdc-card__icon('star')
        +mdc-card__icon('favorite')

Card with buttons and icons

codecode_off

Title

Visit ten places on our planet that are undergoing the biggest changes today.

starfavorite
+mdc-card
    +mdc-card__header('Title')
 
    +mdc-card__section()(secondary)
        +mdc-typography('Visit ten places on our planet that are undergoing the biggest changes today.')(type='body2' noMargin)
 
    +mdc-card__actions
        +mdc-card__action-buttons
            +mdc-card__button('Button')
            +mdc-card__button('Button')
 
        +mdc-card__action-icons
            +mdc-card__icon('star')
            +mdc-card__icon('favorite')