Unofficial DateTimeInput component for react-admin.
Component was updated from aor-datetime-input and versioning now started from v1.9.0 New package https://www.npmjs.com/package/ra-datetime-input
Component will work in two steps:
- Select date
- Select time
Just try it!
npm install ra-datetime-input --save
import React from 'react';
import {
Edit,
TextInput,
LongTextInput,
TabbedForm,
FormTab,
} from 'react-admin'
import DateTimeInput from 'ra-datetime-input';
export const NewsEdit = (props) => (
<Edit title={<NewsTitle />} {...props}>
<TabbedForm>
<FormTab>
<LongTextInput source="title" validate={required} />
<DateTimeInput source="publish_date" validate={required} />
</FormTab>
</TabbedForm>
</Edit>
);
You can build sources:
npm run build
This library is licensed under the MIT Licence.
Copyright (c) 2019 iamsimakov.