This repository has been archived by the owner on Mar 4, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(button): adding disabled prop to Button (#14)
- Loading branch information
Alexandru Buliga
authored
Jul 31, 2018
1 parent
48d735a
commit c7b7621
Showing
9 changed files
with
131 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 17 additions & 0 deletions
17
docs/src/examples/components/Button/States/ButtonExampleDisabled.shorthand.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import React from 'react' | ||
import { Button } from '@stardust-ui/react' | ||
|
||
const ButtonExampleDisabled = () => ( | ||
<div> | ||
<Button disabled content="Default" /> | ||
<Button disabled type="primary" content="Primary" /> | ||
<Button disabled type="secondary" content="Secondary" /> | ||
<Button disabled type="primary" icon="book" content="Click me" iconPosition="before" /> | ||
<Button disabled circular icon="coffee" /> | ||
<br /> | ||
<br /> | ||
<Button disabled fluid content="Fluid" /> | ||
</div> | ||
) | ||
|
||
export default ButtonExampleDisabled |
28 changes: 28 additions & 0 deletions
28
docs/src/examples/components/Button/States/ButtonExampleDisabled.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
import React from 'react' | ||
import { Button, Icon, Text } from '@stardust-ui/react' | ||
|
||
const ButtonExampleDisabled = () => ( | ||
<div> | ||
<Button disabled>Default</Button> | ||
<Button disabled type="primary"> | ||
Primary | ||
</Button> | ||
<Button disabled type="secondary"> | ||
Secondary | ||
</Button> | ||
<Button disabled type="primary" icon iconPosition="before"> | ||
<Icon name="book" color="white" xSpacing="after" /> | ||
<Text content="Click me" /> | ||
</Button> | ||
<Button disabled circular> | ||
<Icon name="coffee" xSpacing="none" /> | ||
</Button> | ||
<br /> | ||
<br /> | ||
<Button disabled fluid> | ||
Fluid | ||
</Button> | ||
</div> | ||
) | ||
|
||
export default ButtonExampleDisabled |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import React from 'react' | ||
import ComponentExample from 'docs/src/components/ComponentDoc/ComponentExample' | ||
import ExampleSection from 'docs/src/components/ComponentDoc/ExampleSection' | ||
|
||
const States = () => ( | ||
<ExampleSection title="States"> | ||
<ComponentExample | ||
title="Disabled" | ||
description="A button can show it is currently unable to be interacted with." | ||
examplePath="components/Button/States/ButtonExampleDisabled" | ||
/> | ||
</ExampleSection> | ||
) | ||
|
||
export default States |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters