Skip to content

Commit

Permalink
fix(customDatePicker): update component name
Browse files Browse the repository at this point in the history
  • Loading branch information
NSUWAL123 committed Jan 15, 2025
1 parent cf0cf89 commit 49fe0d6
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import windowDimention from '@/hooks/WindowDimension';
import Button from '@/components/common/Button';
import { Modal } from '@/components/common/Modal';
import { CustomSelect } from '@/components/common/Select.js';
import CustomDatePicker from '@/components/common/CustomDatePicker';
import DateRangePicker from '@/components/common/DateRangePicker';
import Table, { TableHeader } from '@/components/common/CustomTable';
import { DropdownMenu, DropdownMenuContent, DropdownMenuItem, DropdownMenuTrigger } from '@/components/common/Dropdown';
import { SubmissionsTableSkeletonLoader } from '@/components/ProjectSubmissions/ProjectSubmissionsSkeletonLoader.js';
Expand Down Expand Up @@ -318,7 +318,7 @@ const SubmissionsTable = ({ toggleView }) => {
/>
</div>
<div className={`${windowSize.width < 500 ? 'fmtm-w-full' : 'fmtm-w-[11.5rem]'}`}>
<CustomDatePicker
<DateRangePicker
title="Submitted Date"
startDate={dateRange?.start}
endDate={dateRange?.end}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import React from 'react';
import DatePicker from 'react-datepicker';
import 'react-datepicker/dist/react-datepicker.css';

type CustomDatePickerType = {
type DateRangePickerType = {
title: string;
className: string;
setStartDate: (date: Date | null) => void;
Expand All @@ -11,7 +11,7 @@ type CustomDatePickerType = {
endDate: Date | null;
};

const CustomDatePicker = ({ title, className, setStartDate, setEndDate, startDate, endDate }: CustomDatePickerType) => {
const DateRangePicker = ({ title, className, setStartDate, setEndDate, startDate, endDate }: DateRangePickerType) => {
const onChange = (dates: [Date | null, Date | null]) => {
const [start, end] = dates;
setStartDate(start);
Expand All @@ -36,4 +36,4 @@ const CustomDatePicker = ({ title, className, setStartDate, setEndDate, startDat
);
};

export default CustomDatePicker;
export default DateRangePicker;

0 comments on commit 49fe0d6

Please sign in to comment.