Skip to content

Commit

Permalink
feat(Card): add link prop
Browse files Browse the repository at this point in the history
  • Loading branch information
BrainMaestro committed Feb 21, 2017
1 parent 3f83015 commit fa5bc4c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/views/Card/Card.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,9 @@ export default class Card extends Component {
/** A card can contain an Image component. */
image: customPropTypes.itemShorthand,

/** A card can be formatted to link to other content. */
link: PropTypes.bool,

/** Shorthand for CardMeta. */
meta: customPropTypes.itemShorthand,

Expand Down Expand Up @@ -100,6 +103,7 @@ export default class Card extends Component {
header,
href,
image,
link,
meta,
onClick,
raised,
Expand All @@ -110,6 +114,7 @@ export default class Card extends Component {
color,
useKeyOnly(centered, 'centered'),
useKeyOnly(fluid, 'fluid'),
useKeyOnly(link, 'link'),
useKeyOnly(raised, 'raised'),
'card',
className,
Expand Down
1 change: 1 addition & 0 deletions test/specs/views/Card/Card-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ describe('Card', () => {

common.propKeyOnlyToClassName(Card, 'centered')
common.propKeyOnlyToClassName(Card, 'fluid')
common.propKeyOnlyToClassName(Card, 'link')
common.propKeyOnlyToClassName(Card, 'raised')

common.propValueOnlyToClassName(Card, 'color', SUI.COLORS)
Expand Down

0 comments on commit fa5bc4c

Please sign in to comment.