react-conventions
Version:
An open source set of React components that implement Ambassador's Design and UX patterns.
62 lines (58 loc) • 2.83 kB
JavaScript
import React from 'react'
import CodeExample from 'private/modules/CodeExample'
import ExampleDatePickerDefault from './ExampleDatePickerDefault'
import exampleDatePickerDefaultCode from '!raw!./ExampleDatePickerDefault'
import ExampleDatePickerDefaultCustomMinMax from './ExampleDatePickerDefaultCustomMinMax'
import exampleDatePickerDefaultCustomMinMaxCode from '!raw!./ExampleDatePickerDefaultCustomMinMax'
import ExampleDatePickerSelectedCustomMinMax from './ExampleDatePickerSelectedCustomMinMax'
import exampleDatePickerSelectedCustomMinMaxCode from '!raw!./ExampleDatePickerSelectedCustomMinMax'
import ExampleDatePickerSelected from './ExampleDatePickerSelected'
import exampleDatePickerSelectedCode from '!raw!./ExampleDatePickerSelected'
import ExampleDatePickerCallback from './ExampleDatePickerCallback'
import exampleDatePickerCallbackCode from '!raw!./ExampleDatePickerCallback'
import PropsList from 'private/modules/PropsList'
import docs from '!!docgen!react-conventions/lib/DatePicker/DatePicker'
import styles from 'private/css/content'
const DatePickerPage = () => (
<div>
<div className={styles.content}>
<div className={styles.block}>
<CodeExample
title='Default Date Picker'
description='This is the `DatePicker component` with default current date and min date: -10 years & max date: +10 years.'
markup={exampleDatePickerDefaultCode}>
<ExampleDatePickerDefault />
</CodeExample>
<CodeExample
title='Date Picker with custom min & max dates'
description='This is the `DatePicker component` with custom min & max dates.'
markup={exampleDatePickerDefaultCustomMinMaxCode}>
<ExampleDatePickerDefaultCustomMinMax />
</CodeExample>
<CodeExample
title='Date Picker with Selected Date'
description='This is the `DatePicker component` with Selected Date.'
markup={exampleDatePickerSelectedCode}>
<ExampleDatePickerSelected />
</CodeExample>
<CodeExample
title='Date Picker with Selected Date and custom min & max dates'
description='This is the `DatePicker component` with Selected Date and custom min & max dates.'
markup={exampleDatePickerSelectedCustomMinMaxCode}>
<ExampleDatePickerSelectedCustomMinMax />
</CodeExample>
<CodeExample
title='Example Date Picker with Callback'
description='This is the `DatePicker component`with Callback.'
markup={exampleDatePickerCallbackCode}>
<ExampleDatePickerCallback />
</CodeExample>
<div className={styles.block}>
<h3>Props</h3>
<PropsList list={docs[0].props} />
</div>
</div>
</div>
</div>
)
export default DatePickerPage