Skip to content

Commit

Permalink
fix(TypeAheadSelect): add a storybook example for controlled input value
Browse files Browse the repository at this point in the history
affects: patternfly-react
  • Loading branch information
Ron-Lavi committed Jun 19, 2018
1 parent 0115d53 commit 64e2ca4
Showing 1 changed file with 20 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -215,3 +215,23 @@ TypeAheadSelectStories.addWithInfo('Using Async Calls', () => {
</div>
);
});

TypeAheadSelectStories.addWithInfo('Controlled input value', () => (
<div className="container">
<br />
<br />
<br />
<h2>Controlled input value</h2>
<p>
<strong>
A default value will be shown when the component is rendered.
</strong>
</p>
<TypeAheadSelect
defaultInputValue="Denmark"
options={Mocks.countries}
labelKey="name"
placeholder="Choose a state..."
/>
</div>
));

0 comments on commit 64e2ca4

Please sign in to comment.