mirror of https://github.com/acid-info/lsd.git
fix: rebase and update icon names
This commit is contained in:
parent
6fb89110b7
commit
c6d66876ad
|
@ -1,5 +1,4 @@
|
|||
import { FirstDayOfWeek, useMonth } from '@datepicker-react/hooks'
|
||||
import { useState } from 'react'
|
||||
import { useCalendarContext } from './Calendar.context'
|
||||
import { Days, MonthHeader, WeekdayHeader } from './MonthHelpers'
|
||||
import { calendarClasses } from './Calendar.classes'
|
||||
|
|
|
@ -1,13 +1,13 @@
|
|||
import clsx from 'clsx'
|
||||
import { Day } from './Day'
|
||||
import { FC } from 'react'
|
||||
import { NavigateBeforeIcon, NavigateNextIcon } from '../Icons'
|
||||
import { calendarClasses } from './Calendar.classes'
|
||||
import { Typography } from '../Typography'
|
||||
import { UseMonthResult } from '@datepicker-react/hooks'
|
||||
import { generateFullMonthDays } from '../../utils/date.utils'
|
||||
import { useCalendarContext } from './Calendar.context'
|
||||
import { YearControl } from './YearControl'
|
||||
import { ChevronLeftIcon, ChevronRightIcon } from '../Icons'
|
||||
|
||||
type CalendarNavigationButtonProps = {
|
||||
direction: 'previous' | 'next'
|
||||
|
@ -20,7 +20,7 @@ export const CalendarNavigationButton: FC<CalendarNavigationButtonProps> = ({
|
|||
onClick,
|
||||
className,
|
||||
}) => {
|
||||
const Icon = direction === 'previous' ? NavigateBeforeIcon : NavigateNextIcon
|
||||
const Icon = direction === 'previous' ? ChevronLeftIcon : ChevronRightIcon
|
||||
return (
|
||||
<button
|
||||
className={clsx(calendarClasses.button, className)}
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
import clsx from 'clsx'
|
||||
import { FC, useEffect, useRef, useState } from 'react'
|
||||
import { ArrowDownIcon, ArrowUpIcon } from '../Icons'
|
||||
import { calendarClasses } from './Calendar.classes'
|
||||
import { Typography } from '../Typography'
|
||||
import { useClickAway, useScroll } from 'react-use'
|
||||
import { useCalendarContext } from './Calendar.context'
|
||||
import { CALENDAR_MAX_YEAR, CALENDAR_MIN_YEAR } from '.'
|
||||
import { ChevronDownIcon, ChevronUpIcon } from '../Icons'
|
||||
|
||||
type YearControlProps = {
|
||||
year: string
|
||||
|
@ -102,9 +102,9 @@ export const YearControl: FC<YearControlProps> = ({
|
|||
|
||||
<div className={calendarClasses.changeYearIconContainer}>
|
||||
{changeYearMode ? (
|
||||
<ArrowUpIcon color="primary" />
|
||||
<ChevronUpIcon color="primary" />
|
||||
) : (
|
||||
<ArrowDownIcon color="primary" />
|
||||
<ChevronDownIcon color="primary" />
|
||||
)}
|
||||
</div>
|
||||
</div>
|
||||
|
|
Loading…
Reference in New Issue