闭社主体 forked from https://github.com/tootsuite/mastodon
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

18 lines
724 B

  1. import React from 'react';
  2. import { List } from 'immutable';
  3. import { storiesOf } from '@storybook/react';
  4. import { action } from '@storybook/addon-actions';
  5. import AutosuggestTextarea from 'mastodon/components/autosuggest_textarea';
  6. const props = {
  7. onChange: action('changed'),
  8. onPaste: action('pasted'),
  9. onSuggestionSelected: action('suggestionsSelected'),
  10. onSuggestionsClearRequested: action('suggestionsClearRequested'),
  11. onSuggestionsFetchRequested: action('suggestionsFetchRequested'),
  12. suggestions: List([]),
  13. };
  14. storiesOf('AutosuggestTextarea', module)
  15. .add('default state', () => <AutosuggestTextarea value='' {...props} />)
  16. .add('with text', () => <AutosuggestTextarea value='Hello' {...props} />);