Skip to content

Commit

Permalink
Update DatePicker imports and component names
Browse files Browse the repository at this point in the history
  • Loading branch information
halimkun committed Mar 19, 2024
1 parent 7744b69 commit 261b70d
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 11 deletions.
4 changes: 2 additions & 2 deletions src/components/custom/forms/add-memo-internal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { Button } from '@/components/ui/button';
import { Combobox } from '../inputs/combo-box';
import { IconLoader } from '@tabler/icons-react';
import { Checkbox } from '@/components/ui/checkbox';
import { DatePickerDemo } from '../inputs/date-picker';
import { DatePicker } from '../inputs/date-picker';
import {
Card,
CardContent,
Expand Down Expand Up @@ -285,7 +285,7 @@ const FormAddMemoInternal = (props: FormAddMemoInternalProps) => {
>
Tanggal Terbit
</Label>
<DatePickerDemo
<DatePicker
date={tglTerbit}
setDate={setTglTerbit}
placeholder='pilih tanggal'
Expand Down
4 changes: 2 additions & 2 deletions src/components/custom/forms/add-ppi.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { Label } from '@/components/ui/label';
import { Textarea } from '@/components/ui/textarea';
import { useState } from 'react';
import { DatePickerDemo } from '../inputs/date-picker';
import { DatePicker } from '../inputs/date-picker';
import { Combobox } from '../inputs/combo-box';
import { IconLoader } from '@tabler/icons-react';
import { getSession } from 'next-auth/react';
Expand Down Expand Up @@ -72,7 +72,7 @@ const FormAddPPI = (props: formAddPpiProps) => {
<Label className='font-semibold text-primary' htmlFor='tgl_terbit'>
Tanggal Terbit
</Label>
<DatePickerDemo
<DatePicker
date={tglTerbit}
setDate={setTglTerbit}
placeholder='pilih tanggal'
Expand Down
4 changes: 2 additions & 2 deletions src/components/custom/forms/add-sk.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { Input } from '@/components/ui/input';
import { Label } from '@/components/ui/label';
import { Button } from '@/components/ui/button';
import { Combobox } from '../inputs/combo-box';
import { DatePickerDemo } from '../inputs/date-picker';
import { DatePicker } from '../inputs/date-picker';
import { IconDeviceSdCard, IconLoader } from '@tabler/icons-react';
import { getSession } from 'next-auth/react';

Expand Down Expand Up @@ -255,7 +255,7 @@ const FormAddSK = ({
.reverse()
.join('-')}
/>
<DatePickerDemo
<DatePicker
date={data ? d : date}
setDate={setDate}
placeholder='pilih tanggal terbit'
Expand Down
8 changes: 4 additions & 4 deletions src/components/custom/forms/add-surat-masuk.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Label } from '@/components/ui/label';
import { DatePickerDemo } from '../inputs/date-picker';
import { DatePicker } from '../inputs/date-picker';
import { Input } from '@/components/ui/input';
import { useEffect, useState } from 'react';
import { Combobox } from '../inputs/combo-box';
Expand Down Expand Up @@ -167,7 +167,7 @@ const FormAddSuratMasuk = (props: formAddSuratMasukProps) => {
.reverse()
.join('-')}
/>
<DatePickerDemo
<DatePicker
date={no_simrs}
setDate={setNoSimrs}
placeholder='pilih tanggal'
Expand Down Expand Up @@ -231,7 +231,7 @@ const FormAddSuratMasuk = (props: formAddSuratMasukProps) => {
.reverse()
.join('-')}
/>
<DatePickerDemo
<DatePicker
date={tgl_surat}
setDate={setTglSurat}
placeholder='pilih tanggal'
Expand All @@ -255,7 +255,7 @@ const FormAddSuratMasuk = (props: formAddSuratMasukProps) => {
.reverse()
.join('-')}
/>
<DatePickerDemo
<DatePicker
date={tgl_pelaksanaan}
setDate={setTglPelaksanaan}
placeholder='pilih tanggal'
Expand Down
2 changes: 1 addition & 1 deletion src/components/custom/inputs/date-picker.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import {
PopoverTrigger,
} from '@/components/ui/popover';

export function DatePickerDemo({ date, setDate, placeholder }: any) {
export function DatePicker({ date, setDate, placeholder }: any) {
return (
<Popover>
<PopoverTrigger asChild>
Expand Down

0 comments on commit 261b70d

Please sign in to comment.