// Copyright 2021 Signal Messenger, LLC // SPDX-License-Identifier: AGPL-3.0-only import React from 'react'; import { text } from '@storybook/addon-knobs'; import type { PropsType } from './GroupDescription'; import { GroupDescription } from './GroupDescription'; import { setupI18n } from '../../util/setupI18n'; import enMessages from '../../../_locales/en/messages.json'; const i18n = setupI18n('en', enMessages); export default { title: 'Components/Conversation/GroupDescription', }; const createProps = (overrideProps: Partial = {}): PropsType => ({ i18n, title: text('title', overrideProps.title || 'Sample Title'), text: text('text', overrideProps.text || 'Default group description'), }); export function Default(): JSX.Element { return ; } export function Long(): JSX.Element { return ( ); } export function WithNewlines(): JSX.Element { return ( ); } WithNewlines.story = { name: 'With newlines', }; export function WithEmoji(): JSX.Element { return ( ); } WithEmoji.story = { name: 'With emoji', }; export function WithLink(): JSX.Element { return ( ); } WithLink.story = { name: 'With link', }; export function KitchenSink(): JSX.Element { return ( ); } KitchenSink.story = { name: 'Kitchen sink', };