Merge pull request 'fix: update import path for SingleDatePicker and add type annotation to component' (#2) from dev into main
Some checks failed
Publish to npm / publish (push) Failing after 22s
Some checks failed
Publish to npm / publish (push) Failing after 22s
Reviewed-on: #2
This commit is contained in:
commit
d2fb0ca732
|
@ -1,5 +1,5 @@
|
|||
import React from 'react'
|
||||
import { SingleDatePicker } from "../dist/index.es"
|
||||
import { SingleDatePicker } from "../src/index"
|
||||
import './app.scss'
|
||||
|
||||
export default () => {
|
||||
|
|
|
@ -80,7 +80,7 @@ export interface SingleDatePickerProps {
|
|||
*
|
||||
* @param {SingleDatePickerProps} props
|
||||
*/
|
||||
const SingleDatePicker: React.FC = ({ value, onSelect, localization, onClose, mainColor = '#000000', accentColor = '#000000', reversedColor = '#ffffff', hoverColor = '#00000017', borderColor = '#e0e0e0' }: SingleDatePickerProps) => {
|
||||
const SingleDatePicker: React.FC<SingleDatePickerProps> = ({ value, onSelect, localization, onClose, mainColor = '#000000', accentColor = '#000000', reversedColor = '#ffffff', hoverColor = '#00000017', borderColor = '#e0e0e0' }: SingleDatePickerProps) => {
|
||||
const [currentMonth, setCurrentMonth] = useState(new Date().getMonth())
|
||||
const [currentYear, setCurrentYear] = useState(new Date().getFullYear())
|
||||
const [selectedDate, setSelectedDate] = useState(new Date())
|
||||
|
|
Loading…
Reference in New Issue
Block a user