Skip to content

Commit

Permalink
[Docs] Fix the wrong spelling of ExampleExpandable
Browse files Browse the repository at this point in the history
I have also changed the example to illustrate two features
- The padding button adding with (#4820)
- Move the CardActions at the top with `expandable={false}` as we can see in the [spec](
https://material.google.com/components/cards.html#cards-behavior)
  • Loading branch information
oliviertassinari committed Jul 26, 2016
1 parent 534e3fb commit abc85d8
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,25 +2,25 @@ import React from 'react';
import {Card, CardActions, CardHeader, CardText} from 'material-ui/Card';
import FlatButton from 'material-ui/FlatButton';

const CardExampleWithoutAvatar = () => (
const CardExampleExpandable = () => (
<Card>
<CardHeader
title="Without Avatar"
subtitle="Subtitle"
actAsExpander={true}
showExpandableButton={true}
/>
<CardActions>
<FlatButton label="Action1" />
<FlatButton label="Action2" />
</CardActions>
<CardText expandable={true}>
Lorem ipsum dolor sit amet, consectetur adipiscing elit.
Donec mattis pretium massa. Aliquam erat volutpat. Nulla facilisi.
Donec vulputate interdum sollicitudin. Nunc lacinia auctor quam sed pellentesque.
Aliquam dui mauris, mattis quis lacus id, pellentesque lobortis odio.
</CardText>
<CardActions expandable={true}>
<FlatButton label="Action1" />
<FlatButton label="Action2" />
</CardActions>
</Card>
);

export default CardExampleWithoutAvatar;
export default CardExampleExpandable;
8 changes: 4 additions & 4 deletions docs/src/app/components/pages/components/Card/Page.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ import MarkdownElement from '../../../MarkdownElement';
import cardReadmeText from './README';
import cardExampleWithAvatarCode from '!raw!./ExampleWithAvatar';
import CardExampleWithAvatar from './ExampleWithAvatar';
import cardExampleWithoutAvatarCode from '!raw!./ExampleWithoutAvatar';
import CardExampleWithoutAvatar from './ExampleWithoutAvatar';
import cardExampleExpandableCode from '!raw!./ExampleExpandable';
import CardExampleExpandable from './ExampleExpandable';
import cardExampleControlledCode from '!raw!./ExampleControlled';
import CardExampleControlled from './ExampleControlled';

Expand Down Expand Up @@ -43,9 +43,9 @@ const CardPage = () => (
<CodeExample
title="Expandable example"
description={descriptions.simple}
code={cardExampleWithoutAvatarCode}
code={cardExampleExpandableCode}
>
<CardExampleWithoutAvatar />
<CardExampleExpandable />
</CodeExample>
<CodeExample
title="Controlled example"
Expand Down

0 comments on commit abc85d8

Please sign in to comment.