Refactor component imports for consistency and organization
- Updated import paths for various components to align with new directory structure. - Changed imports from 'row-actions', 'confirm-dialog', 'image-preview-button', and 'file-upload' to their respective new locations in 'data-display', 'dialogs', and 'inputs'. - Adjusted imports in multiple pages including purchase, restock, transaction, category, customer, product, raw-material, supplier, roles, and settings. - Ensured all relevant components are imported from their new locations to maintain functionality.
This commit is contained in:
parent
d648d48632
commit
166419134f
@ -1,7 +1,7 @@
|
||||
import { createInertiaApp } from '@inertiajs/react';
|
||||
import { registerSW } from 'virtual:pwa-register';
|
||||
import { FlashToast } from '@/components/flash-toast';
|
||||
import { PWAUpdateToast } from '@/components/pwa-update-toast';
|
||||
import { FlashToast } from '@/components/notifications';
|
||||
import { PWAUpdateToast } from '@/components/notifications';
|
||||
import { Toaster } from '@/components/ui/sonner';
|
||||
import { TooltipProvider } from '@/components/ui/tooltip';
|
||||
import { initializeTheme } from '@/hooks/use-appearance';
|
||||
|
||||
7
resources/js/components/auth/index.ts
Normal file
7
resources/js/components/auth/index.ts
Normal file
@ -0,0 +1,7 @@
|
||||
export { default as ManagePasskeys } from './manage-passkeys';
|
||||
export { default as ManageTwoFactor } from './manage-two-factor';
|
||||
export { default as PasskeyItem } from './passkey-item';
|
||||
export { default as PasskeyRegister } from './passkey-register';
|
||||
export { default as PasskeyVerify } from './passkey-verify';
|
||||
export { default as TwoFactorRecoveryCodes } from './two-factor-recovery-codes';
|
||||
export { default as TwoFactorSetupModal } from './two-factor-setup-modal';
|
||||
@ -1,9 +1,8 @@
|
||||
import { router } from '@inertiajs/react';
|
||||
import { KeyRound } from 'lucide-react';
|
||||
import { destroy } from '@/actions/Laravel/Passkeys/Http/Controllers/PasskeyRegistrationController';
|
||||
import Heading from '@/components/heading';
|
||||
import PasskeyItem from '@/components/passkey-item';
|
||||
import PasskeyRegistration from '@/components/passkey-register';
|
||||
import { Heading } from '@/components/layout';
|
||||
import { PasskeyItem, PasskeyRegister as PasskeyRegistration } from '@/components/auth';
|
||||
import type { Passkey } from '@/types/auth';
|
||||
|
||||
export type Props = {
|
||||
@ -2,9 +2,8 @@ import { Form } from '@inertiajs/react';
|
||||
import { ShieldCheck } from 'lucide-react';
|
||||
import { useEffect, useRef, useState } from 'react';
|
||||
import { toast } from 'sonner';
|
||||
import Heading from '@/components/heading';
|
||||
import TwoFactorRecoveryCodes from '@/components/two-factor-recovery-codes';
|
||||
import TwoFactorSetupModal from '@/components/two-factor-setup-modal';
|
||||
import { Heading } from '@/components/layout';
|
||||
import { TwoFactorRecoveryCodes, TwoFactorSetupModal } from '@/components/auth';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { useTwoFactorAuth } from '@/hooks/use-two-factor-auth';
|
||||
import { disable, enable } from '@/routes/two-factor';
|
||||
@ -1,6 +1,6 @@
|
||||
import { usePasskeyRegister } from '@laravel/passkeys/react';
|
||||
import { useState } from 'react';
|
||||
import InputError from '@/components/input-error';
|
||||
import { InputError } from '@/components/ui';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Input } from '@/components/ui/input';
|
||||
import { Label } from '@/components/ui/label';
|
||||
@ -2,7 +2,7 @@ import type { UrlMethodPair } from '@inertiajs/core';
|
||||
import { router } from '@inertiajs/react';
|
||||
import { usePasskeyVerify } from '@laravel/passkeys/react';
|
||||
import { KeyRound } from 'lucide-react';
|
||||
import InputError from '@/components/input-error';
|
||||
import { InputError } from '@/components/ui';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Separator } from '@/components/ui/separator';
|
||||
import { Spinner } from '@/components/ui/spinner';
|
||||
@ -2,7 +2,7 @@ import { Form } from '@inertiajs/react';
|
||||
import { Eye, EyeOff, LockKeyhole, RefreshCw } from 'lucide-react';
|
||||
import { useCallback, useEffect, useRef, useState } from 'react';
|
||||
import { toast } from 'sonner';
|
||||
import AlertError from '@/components/alert-error';
|
||||
import { AlertError } from '@/components/notifications';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import {
|
||||
Card,
|
||||
@ -3,8 +3,8 @@ import { REGEXP_ONLY_DIGITS } from 'input-otp';
|
||||
import { Check, Copy, ScanLine } from 'lucide-react';
|
||||
import { useCallback, useEffect, useMemo, useRef, useState } from 'react';
|
||||
import { toast } from 'sonner';
|
||||
import AlertError from '@/components/alert-error';
|
||||
import InputError from '@/components/input-error';
|
||||
import { AlertError } from '@/components/notifications';
|
||||
import { InputError } from '@/components/ui';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import {
|
||||
Dialog,
|
||||
@ -1,6 +1,6 @@
|
||||
import type { ImgHTMLAttributes } from 'react';
|
||||
|
||||
import logo from '../../../public/assets/logo.png';
|
||||
import logo from '../../../../public/assets/logo.png';
|
||||
|
||||
export default function AppLogoIcon(
|
||||
props: ImgHTMLAttributes<HTMLImageElement>,
|
||||
@ -1,6 +1,6 @@
|
||||
import { usePage } from '@inertiajs/react';
|
||||
|
||||
import AppLogoIcon from '@/components/app-logo-icon';
|
||||
import { AppLogoIcon } from '@/components/brand';
|
||||
|
||||
export default function AppLogo() {
|
||||
const { name } = usePage().props;
|
||||
2
resources/js/components/brand/index.ts
Normal file
2
resources/js/components/brand/index.ts
Normal file
@ -0,0 +1,2 @@
|
||||
export { default as AppLogo } from './app-logo';
|
||||
export { default as AppLogoIcon } from './app-logo-icon';
|
||||
6
resources/js/components/data-display/index.ts
Normal file
6
resources/js/components/data-display/index.ts
Normal file
@ -0,0 +1,6 @@
|
||||
export { CardTable } from './card-table';
|
||||
export { DataTable, type PaginationState } from './data-table';
|
||||
export { FilterPopover } from './filter-popover';
|
||||
export { RowActions, type RowAction } from './row-actions';
|
||||
export { StatusBadge } from './status-badge';
|
||||
export { ToggleStatus } from './toggle-status';
|
||||
@ -1,4 +1,4 @@
|
||||
import { ConfirmDialog } from '@/components/confirm-dialog';
|
||||
import { ConfirmDialog } from '@/components/dialogs';
|
||||
|
||||
type DeleteConfirmDialogProps<T> = {
|
||||
target: T | null;
|
||||
@ -1,5 +1,5 @@
|
||||
import { useState } from 'react';
|
||||
import { ImagePreviewModal } from '@/components/image-preview-modal';
|
||||
import { ImagePreviewModal } from '@/components/dialogs';
|
||||
|
||||
type ImagePreviewButtonProps = {
|
||||
srcs: string[];
|
||||
5
resources/js/components/dialogs/index.ts
Normal file
5
resources/js/components/dialogs/index.ts
Normal file
@ -0,0 +1,5 @@
|
||||
export { ConfirmDialog } from './confirm-dialog';
|
||||
export { DeleteConfirmDialog } from './delete-confirm-dialog';
|
||||
export { FormDialog } from './form-dialog';
|
||||
export { ImagePreviewButton } from './image-preview-button';
|
||||
export { ImagePreviewModal } from './image-preview-modal';
|
||||
9
resources/js/components/inputs/index.ts
Normal file
9
resources/js/components/inputs/index.ts
Normal file
@ -0,0 +1,9 @@
|
||||
export { default as PasswordInput } from './password-input';
|
||||
export { CameraCapture } from './camera-capture';
|
||||
export { DatePicker } from './date-picker';
|
||||
export { FileUpload } from './file-upload';
|
||||
export { FileUploadMultiple } from './file-upload-multiple';
|
||||
export { LocationMap } from './location-map';
|
||||
export { NumberInput } from './number-input';
|
||||
export { PhoneNumberInput } from './phone-number-input';
|
||||
export { RupiahInput } from './rupiah-input';
|
||||
@ -1,8 +1,7 @@
|
||||
import { Link, usePage } from '@inertiajs/react';
|
||||
import { BookOpen, Folder, LayoutGrid, Menu, Search } from 'lucide-react';
|
||||
import AppLogo from '@/components/app-logo';
|
||||
import AppLogoIcon from '@/components/app-logo-icon';
|
||||
import { Breadcrumbs } from '@/components/breadcrumbs';
|
||||
import { AppLogo, AppLogoIcon } from '@/components/brand';
|
||||
import { Breadcrumbs } from '@/components/layout';
|
||||
import { Avatar, AvatarFallback, AvatarImage } from '@/components/ui/avatar';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import {
|
||||
@ -28,7 +27,7 @@ import {
|
||||
TooltipContent,
|
||||
TooltipTrigger,
|
||||
} from '@/components/ui/tooltip';
|
||||
import { UserMenuContent } from '@/components/user-menu-content';
|
||||
import { UserMenuContent } from '@/components/user';
|
||||
import { useCurrentUrl } from '@/hooks/use-current-url';
|
||||
import { useInitials } from '@/hooks/use-initials';
|
||||
import { cn, toUrl } from '@/lib/utils';
|
||||
@ -1,6 +1,6 @@
|
||||
import { Breadcrumbs } from '@/components/breadcrumbs';
|
||||
import { NavUser } from '@/components/nav-user';
|
||||
import { NotificationBell } from '@/components/notification-bell';
|
||||
import { Breadcrumbs } from '@/components/layout';
|
||||
import { NavUser } from '@/components/user';
|
||||
import { NotificationBell } from '@/components/notifications';
|
||||
import { SidebarTrigger } from '@/components/ui/sidebar';
|
||||
import type { BreadcrumbItem as BreadcrumbItemType } from '@/types';
|
||||
|
||||
@ -24,7 +24,7 @@ import {
|
||||
Wallet,
|
||||
} from 'lucide-react';
|
||||
import React from 'react';
|
||||
import AppLogo from '@/components/app-logo';
|
||||
import { AppLogo } from '@/components/brand';
|
||||
import {
|
||||
Sidebar,
|
||||
SidebarContent,
|
||||
8
resources/js/components/layout/index.ts
Normal file
8
resources/js/components/layout/index.ts
Normal file
@ -0,0 +1,8 @@
|
||||
export { AppContent } from './app-content';
|
||||
export { AppHeader } from './app-header';
|
||||
export { AppShell } from './app-shell';
|
||||
export { AppSidebar } from './app-sidebar';
|
||||
export { AppSidebarHeader } from './app-sidebar-header';
|
||||
export { Breadcrumbs } from './breadcrumbs';
|
||||
export { default as Heading } from './heading';
|
||||
export { PageHeader } from './page-header';
|
||||
4
resources/js/components/notifications/index.ts
Normal file
4
resources/js/components/notifications/index.ts
Normal file
@ -0,0 +1,4 @@
|
||||
export { default as AlertError } from './alert-error';
|
||||
export { FlashToast } from './flash-toast';
|
||||
export { NotificationBell } from './notification-bell';
|
||||
export { PWAUpdateToast } from './pwa-update-toast';
|
||||
3
resources/js/components/ui/index.ts
Normal file
3
resources/js/components/ui/index.ts
Normal file
@ -0,0 +1,3 @@
|
||||
export { default as AppearanceTabs } from './appearance-tabs';
|
||||
export { default as InputError } from './input-error';
|
||||
export { default as TextLink } from './text-link';
|
||||
@ -2,9 +2,9 @@ import { Form } from '@inertiajs/react';
|
||||
import { useRef } from 'react';
|
||||
import { toast } from 'sonner';
|
||||
import ProfileController from '@/actions/App/Http/Controllers/Settings/ProfileController';
|
||||
import Heading from '@/components/heading';
|
||||
import InputError from '@/components/input-error';
|
||||
import PasswordInput from '@/components/password-input';
|
||||
import { Heading } from '@/components/layout';
|
||||
import { InputError } from '@/components/ui';
|
||||
import { PasswordInput } from '@/components/inputs';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import {
|
||||
Dialog,
|
||||
4
resources/js/components/user/index.ts
Normal file
4
resources/js/components/user/index.ts
Normal file
@ -0,0 +1,4 @@
|
||||
export { default as DeleteUser } from './delete-user';
|
||||
export { NavUser } from './nav-user';
|
||||
export { UserInfo } from './user-info';
|
||||
export { UserMenuContent } from './user-menu-content';
|
||||
@ -5,8 +5,8 @@ import {
|
||||
DropdownMenuContent,
|
||||
DropdownMenuTrigger,
|
||||
} from '@/components/ui/dropdown-menu';
|
||||
import { UserInfo } from '@/components/user-info';
|
||||
import { UserMenuContent } from '@/components/user-menu-content';
|
||||
import { UserInfo } from '@/components/user';
|
||||
import { UserMenuContent } from '@/components/user';
|
||||
|
||||
export function NavUser() {
|
||||
const { auth } = usePage().props;
|
||||
@ -6,7 +6,7 @@ import {
|
||||
DropdownMenuLabel,
|
||||
DropdownMenuSeparator,
|
||||
} from '@/components/ui/dropdown-menu';
|
||||
import { UserInfo } from '@/components/user-info';
|
||||
import { UserInfo } from '@/components/user';
|
||||
import { useMobileNavigation } from '@/hooks/use-mobile-navigation';
|
||||
import { logout } from '@/routes';
|
||||
import { edit } from '@/routes/profile';
|
||||
@ -1,6 +1,6 @@
|
||||
import { router } from '@inertiajs/react';
|
||||
import { useCallback, useEffect, useState } from 'react';
|
||||
import type { PaginationState } from '@/components/data-table';
|
||||
import type { PaginationState } from '@/components/data-display';
|
||||
|
||||
type UseServerTableOptions = {
|
||||
route: () => string;
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import { AppContent } from '@/components/app-content';
|
||||
import { AppHeader } from '@/components/app-header';
|
||||
import { AppShell } from '@/components/app-shell';
|
||||
import { AppContent } from '@/components/layout';
|
||||
import { AppHeader } from '@/components/layout';
|
||||
import { AppShell } from '@/components/layout';
|
||||
import type { AppLayoutProps } from '@/types';
|
||||
|
||||
export default function AppHeaderLayout({
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
import { AppContent } from '@/components/app-content';
|
||||
import { AppShell } from '@/components/app-shell';
|
||||
import { AppSidebar } from '@/components/app-sidebar';
|
||||
import { AppSidebarHeader } from '@/components/app-sidebar-header';
|
||||
import { AppContent } from '@/components/layout';
|
||||
import { AppShell } from '@/components/layout';
|
||||
import { AppSidebar } from '@/components/layout';
|
||||
import { AppSidebarHeader } from '@/components/layout';
|
||||
import type { AppLayoutProps } from '@/types';
|
||||
|
||||
export default function AppSidebarLayout({
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
import { Link } from '@inertiajs/react';
|
||||
import AppLogoIcon from '@/components/app-logo-icon';
|
||||
import { AppLogoIcon } from '@/components/brand';
|
||||
import { home } from '@/routes';
|
||||
import type { AuthLayoutProps } from '@/types';
|
||||
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
import { Link, usePage } from '@inertiajs/react';
|
||||
import AppLogoIcon from '@/components/app-logo-icon';
|
||||
import { AppLogoIcon } from '@/components/brand';
|
||||
import { home } from '@/routes';
|
||||
import type { AuthLayoutProps } from '@/types';
|
||||
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import { Link } from '@inertiajs/react';
|
||||
import type { PropsWithChildren } from 'react';
|
||||
import Heading from '@/components/heading';
|
||||
import { Heading } from '@/components/layout';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Separator } from '@/components/ui/separator';
|
||||
import { useCurrentUrl } from '@/hooks/use-current-url';
|
||||
|
||||
@ -20,7 +20,7 @@ import {
|
||||
YAxis,
|
||||
} from 'recharts';
|
||||
import { StatCard } from '@/components/card/stat-card';
|
||||
import { DatePicker } from '@/components/date-picker';
|
||||
import { DatePicker } from '@/components/inputs';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Card, CardContent, CardDescription, CardHeader, CardTitle } from '@/components/ui/card';
|
||||
import {
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import type { ColumnDef } from '@tanstack/react-table';
|
||||
import { Pencil, Trash2 } from 'lucide-react';
|
||||
import { RowActions } from '@/components/row-actions';
|
||||
import { RowActions } from '@/components/data-display';
|
||||
|
||||
export type CashAccount = {
|
||||
id: number;
|
||||
|
||||
@ -1,15 +1,15 @@
|
||||
import { Head, router } from '@inertiajs/react';
|
||||
import { ArrowDownToLine, ArrowUpFromLine, Wallet } from 'lucide-react';
|
||||
import { useState } from 'react';
|
||||
import type { PaginationState } from '@/components/data-table';
|
||||
import { DataTable } from '@/components/data-table';
|
||||
import { DeleteConfirmDialog } from '@/components/delete-confirm-dialog';
|
||||
import { FileUpload } from '@/components/file-upload';
|
||||
import { FilterPopover } from '@/components/filter-popover';
|
||||
import { FormDialog } from '@/components/form-dialog';
|
||||
import InputError from '@/components/input-error';
|
||||
import { PageHeader } from '@/components/page-header';
|
||||
import { RupiahInput } from '@/components/rupiah-input';
|
||||
import type { PaginationState } from '@/components/data-display';
|
||||
import { DataTable } from '@/components/data-display';
|
||||
import { DeleteConfirmDialog } from '@/components/dialogs';
|
||||
import { FileUpload } from '@/components/inputs';
|
||||
import { FilterPopover } from '@/components/data-display';
|
||||
import { FormDialog } from '@/components/dialogs';
|
||||
import { InputError } from '@/components/ui';
|
||||
import { PageHeader } from '@/components/layout';
|
||||
import { RupiahInput } from '@/components/inputs';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card';
|
||||
import { Input } from '@/components/ui/input';
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
import type { ColumnDef } from '@tanstack/react-table';
|
||||
import { Pencil, Trash2 } from 'lucide-react';
|
||||
import { ImagePreviewButton } from '@/components/image-preview-button';
|
||||
import { RowActions } from '@/components/row-actions';
|
||||
import { ImagePreviewButton } from '@/components/dialogs';
|
||||
import { RowActions } from '@/components/data-display';
|
||||
|
||||
export type CashTransaction = {
|
||||
id: number;
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import type { ColumnDef } from '@tanstack/react-table';
|
||||
import { CheckCircle, CircleDollarSign, History, Pencil, Trash2 } from 'lucide-react';
|
||||
import { RowActions } from '@/components/row-actions';
|
||||
import { RowActions } from '@/components/data-display';
|
||||
import { Badge } from '@/components/ui/badge';
|
||||
|
||||
export type EmployeeAdvancePayment = {
|
||||
|
||||
@ -1,15 +1,15 @@
|
||||
import { Head, router, usePage } from '@inertiajs/react';
|
||||
import { Plus } from 'lucide-react';
|
||||
import { useEffect, useState } from 'react';
|
||||
import type { PaginationState } from '@/components/data-table';
|
||||
import { DataTable } from '@/components/data-table';
|
||||
import { DatePicker } from '@/components/date-picker';
|
||||
import { DeleteConfirmDialog } from '@/components/delete-confirm-dialog';
|
||||
import { FilterPopover } from '@/components/filter-popover';
|
||||
import { FormDialog } from '@/components/form-dialog';
|
||||
import InputError from '@/components/input-error';
|
||||
import { PageHeader } from '@/components/page-header';
|
||||
import { RupiahInput } from '@/components/rupiah-input';
|
||||
import type { PaginationState } from '@/components/data-display';
|
||||
import { DataTable } from '@/components/data-display';
|
||||
import { DatePicker } from '@/components/inputs';
|
||||
import { DeleteConfirmDialog } from '@/components/dialogs';
|
||||
import { FilterPopover } from '@/components/data-display';
|
||||
import { FormDialog } from '@/components/dialogs';
|
||||
import { InputError } from '@/components/ui';
|
||||
import { PageHeader } from '@/components/layout';
|
||||
import { RupiahInput } from '@/components/inputs';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import {
|
||||
Dialog,
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
import type { ColumnDef } from '@tanstack/react-table';
|
||||
import { Pencil, Trash2 } from 'lucide-react';
|
||||
import { ImagePreviewButton } from '@/components/image-preview-button';
|
||||
import { RowActions } from '@/components/row-actions';
|
||||
import { ImagePreviewButton } from '@/components/dialogs';
|
||||
import { RowActions } from '@/components/data-display';
|
||||
|
||||
export type Expense = {
|
||||
id: number;
|
||||
|
||||
@ -1,14 +1,14 @@
|
||||
import { Head, router } from '@inertiajs/react';
|
||||
import { Plus } from 'lucide-react';
|
||||
import { useState } from 'react';
|
||||
import type { PaginationState } from '@/components/data-table';
|
||||
import { DataTable } from '@/components/data-table';
|
||||
import { DeleteConfirmDialog } from '@/components/delete-confirm-dialog';
|
||||
import { FileUpload } from '@/components/file-upload';
|
||||
import { FormDialog } from '@/components/form-dialog';
|
||||
import InputError from '@/components/input-error';
|
||||
import { PageHeader } from '@/components/page-header';
|
||||
import { RupiahInput } from '@/components/rupiah-input';
|
||||
import type { PaginationState } from '@/components/data-display';
|
||||
import { DataTable } from '@/components/data-display';
|
||||
import { DeleteConfirmDialog } from '@/components/dialogs';
|
||||
import { FileUpload } from '@/components/inputs';
|
||||
import { FormDialog } from '@/components/dialogs';
|
||||
import { InputError } from '@/components/ui';
|
||||
import { PageHeader } from '@/components/layout';
|
||||
import { RupiahInput } from '@/components/inputs';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Input } from '@/components/ui/input';
|
||||
import { Label } from '@/components/ui/label';
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import type { ColumnDef } from '@tanstack/react-table';
|
||||
import { Eye, Lock, Unlock } from 'lucide-react';
|
||||
import { RowActions } from '@/components/row-actions';
|
||||
import { RowActions } from '@/components/data-display';
|
||||
import { Badge } from '@/components/ui/badge';
|
||||
import { MONTH_NAMES } from '@/lib/constants';
|
||||
import { formatCurrency } from '@/lib/utils';
|
||||
|
||||
@ -1,9 +1,9 @@
|
||||
import { Head, router } from '@inertiajs/react';
|
||||
import { useState } from 'react';
|
||||
import type { PaginationState } from '@/components/data-table';
|
||||
import { DataTable } from '@/components/data-table';
|
||||
import { DeleteConfirmDialog } from '@/components/delete-confirm-dialog';
|
||||
import { PageHeader } from '@/components/page-header';
|
||||
import type { PaginationState } from '@/components/data-display';
|
||||
import { DataTable } from '@/components/data-display';
|
||||
import { DeleteConfirmDialog } from '@/components/dialogs';
|
||||
import { PageHeader } from '@/components/layout';
|
||||
import { useCan } from '@/hooks/use-can';
|
||||
import { useServerTable } from '@/hooks/use-server-table';
|
||||
import { MONTH_NAMES } from '@/lib/constants';
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import type { ColumnDef } from '@tanstack/react-table';
|
||||
import { CircleDollarSign, Pencil, Trash2, XCircle } from 'lucide-react';
|
||||
import { RowActions } from '@/components/row-actions';
|
||||
import { RowActions } from '@/components/data-display';
|
||||
import { Badge } from '@/components/ui/badge';
|
||||
import { formatCurrency } from '@/lib/utils';
|
||||
|
||||
|
||||
@ -2,10 +2,10 @@ import { Form, Head, Link, router } from '@inertiajs/react';
|
||||
import { ArrowLeft } from 'lucide-react';
|
||||
import { useState } from 'react';
|
||||
import { toast } from 'sonner';
|
||||
import { ConfirmDialog } from '@/components/confirm-dialog';
|
||||
import { DataTable } from '@/components/data-table';
|
||||
import InputError from '@/components/input-error';
|
||||
import { RupiahInput } from '@/components/rupiah-input';
|
||||
import { ConfirmDialog } from '@/components/dialogs';
|
||||
import { DataTable } from '@/components/data-display';
|
||||
import { InputError } from '@/components/ui';
|
||||
import { RupiahInput } from '@/components/inputs';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import {
|
||||
Dialog,
|
||||
|
||||
@ -14,8 +14,8 @@ import {
|
||||
} from 'lucide-react';
|
||||
import { useMemo, useState } from 'react';
|
||||
import { toast } from 'sonner';
|
||||
import { CameraCapture } from '@/components/camera-capture';
|
||||
import { LocationMap } from '@/components/location-map';
|
||||
import { CameraCapture } from '@/components/inputs';
|
||||
import { LocationMap } from '@/components/inputs';
|
||||
import { TodayAttendanceAlert } from '@/components/card/today-attendance-alert';
|
||||
import { Badge } from '@/components/ui/badge';
|
||||
import { Button } from '@/components/ui/button';
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
import type { ColumnDef } from '@tanstack/react-table';
|
||||
import { KeyRound, Pencil, Trash2 } from 'lucide-react';
|
||||
import { RowActions } from '@/components/row-actions';
|
||||
import { ToggleStatus } from '@/components/toggle-status';
|
||||
import { RowActions } from '@/components/data-display';
|
||||
import { ToggleStatus } from '@/components/data-display';
|
||||
import { formatCurrency } from '@/lib/utils';
|
||||
|
||||
export type Employee = {
|
||||
|
||||
@ -2,10 +2,10 @@ import { Form, Head, Link } from '@inertiajs/react';
|
||||
import { AlertCircle, ArrowLeft } from 'lucide-react';
|
||||
import { useState } from 'react';
|
||||
import { toast } from 'sonner';
|
||||
import { DatePicker } from '@/components/date-picker';
|
||||
import InputError from '@/components/input-error';
|
||||
import { PhoneNumberInput } from '@/components/phone-number-input';
|
||||
import { RupiahInput } from '@/components/rupiah-input';
|
||||
import { DatePicker } from '@/components/inputs';
|
||||
import { InputError } from '@/components/ui';
|
||||
import { PhoneNumberInput } from '@/components/inputs';
|
||||
import { RupiahInput } from '@/components/inputs';
|
||||
import { Alert, AlertDescription, AlertTitle } from '@/components/ui/alert';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card';
|
||||
|
||||
@ -2,10 +2,10 @@ import { Form, Head, Link } from '@inertiajs/react';
|
||||
import { ArrowLeft } from 'lucide-react';
|
||||
import { useMemo, useState } from 'react';
|
||||
import { toast } from 'sonner';
|
||||
import { DatePicker } from '@/components/date-picker';
|
||||
import InputError from '@/components/input-error';
|
||||
import { PhoneNumberInput } from '@/components/phone-number-input';
|
||||
import { RupiahInput } from '@/components/rupiah-input';
|
||||
import { DatePicker } from '@/components/inputs';
|
||||
import { InputError } from '@/components/ui';
|
||||
import { PhoneNumberInput } from '@/components/inputs';
|
||||
import { RupiahInput } from '@/components/inputs';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card';
|
||||
import {
|
||||
|
||||
@ -1,11 +1,11 @@
|
||||
import { Head, Link, router } from '@inertiajs/react';
|
||||
import { Plus } from 'lucide-react';
|
||||
import { useState } from 'react';
|
||||
import type { PaginationState } from '@/components/data-table';
|
||||
import { DataTable } from '@/components/data-table';
|
||||
import { DeleteConfirmDialog } from '@/components/delete-confirm-dialog';
|
||||
import { FilterPopover } from '@/components/filter-popover';
|
||||
import { PageHeader } from '@/components/page-header';
|
||||
import type { PaginationState } from '@/components/data-display';
|
||||
import { DataTable } from '@/components/data-display';
|
||||
import { DeleteConfirmDialog } from '@/components/dialogs';
|
||||
import { FilterPopover } from '@/components/data-display';
|
||||
import { PageHeader } from '@/components/layout';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import {
|
||||
Select,
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import type { ColumnDef } from '@tanstack/react-table';
|
||||
import { CheckCircle, Pencil, Trash2, XCircle } from 'lucide-react';
|
||||
import { RowActions } from '@/components/row-actions';
|
||||
import { RowActions } from '@/components/data-display';
|
||||
import { Badge } from '@/components/ui/badge';
|
||||
|
||||
export type LeaveRequest = {
|
||||
|
||||
@ -1,14 +1,14 @@
|
||||
import { Head, router } from '@inertiajs/react';
|
||||
import { Plus } from 'lucide-react';
|
||||
import { useEffect, useState } from 'react';
|
||||
import type { PaginationState } from '@/components/data-table';
|
||||
import { DataTable } from '@/components/data-table';
|
||||
import { DatePicker } from '@/components/date-picker';
|
||||
import { DeleteConfirmDialog } from '@/components/delete-confirm-dialog';
|
||||
import { FilterPopover } from '@/components/filter-popover';
|
||||
import { FormDialog } from '@/components/form-dialog';
|
||||
import InputError from '@/components/input-error';
|
||||
import { PageHeader } from '@/components/page-header';
|
||||
import type { PaginationState } from '@/components/data-display';
|
||||
import { DataTable } from '@/components/data-display';
|
||||
import { DatePicker } from '@/components/inputs';
|
||||
import { DeleteConfirmDialog } from '@/components/dialogs';
|
||||
import { FilterPopover } from '@/components/data-display';
|
||||
import { FormDialog } from '@/components/dialogs';
|
||||
import { InputError } from '@/components/ui';
|
||||
import { PageHeader } from '@/components/layout';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Label } from '@/components/ui/label';
|
||||
import {
|
||||
|
||||
@ -4,11 +4,11 @@ import { Form, Head, Link, usePage } from '@inertiajs/react';
|
||||
import { ArrowLeft, Check, Layers, Plus, ShoppingCart, Trash2 } from 'lucide-react';
|
||||
import { useCallback, useMemo, useRef, useState } from 'react';
|
||||
import { toast } from 'sonner';
|
||||
import { ConfirmDialog } from '@/components/confirm-dialog';
|
||||
import { FileUpload } from '@/components/file-upload';
|
||||
import { ImagePreviewModal } from '@/components/image-preview-modal';
|
||||
import InputError from '@/components/input-error';
|
||||
import { NumberInput } from '@/components/number-input';
|
||||
import { ConfirmDialog } from '@/components/dialogs';
|
||||
import { FileUpload } from '@/components/inputs';
|
||||
import { ImagePreviewModal } from '@/components/dialogs';
|
||||
import { InputError } from '@/components/ui';
|
||||
import { NumberInput } from '@/components/inputs';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card';
|
||||
import { Combobox, ComboboxContent, ComboboxEmpty, ComboboxInput, ComboboxItem, ComboboxList } from '@/components/ui/combobox';
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import { ChevronDown, Pencil, Trash2 } from 'lucide-react';
|
||||
import { ImagePreviewButton } from '@/components/image-preview-button';
|
||||
import { RowActions } from '@/components/row-actions';
|
||||
import { ImagePreviewButton } from '@/components/dialogs';
|
||||
import { RowActions } from '@/components/data-display';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Card, CardContent } from '@/components/ui/card';
|
||||
import { useCan } from '@/hooks/use-can';
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
import { Fragment } from 'react';
|
||||
import { ImagePreviewButton } from '@/components/image-preview-button';
|
||||
import { ImagePreviewButton } from '@/components/dialogs';
|
||||
import {
|
||||
Table,
|
||||
TableBody,
|
||||
|
||||
@ -4,11 +4,11 @@ import { Form, Head, Link, usePage } from '@inertiajs/react';
|
||||
import { ArrowLeft, Check, Layers, Plus, ShoppingCart, Trash2 } from 'lucide-react';
|
||||
import { useCallback, useMemo, useRef, useState } from 'react';
|
||||
import { toast } from 'sonner';
|
||||
import { ConfirmDialog } from '@/components/confirm-dialog';
|
||||
import { FileUpload } from '@/components/file-upload';
|
||||
import { ImagePreviewModal } from '@/components/image-preview-modal';
|
||||
import InputError from '@/components/input-error';
|
||||
import { NumberInput } from '@/components/number-input';
|
||||
import { ConfirmDialog } from '@/components/dialogs';
|
||||
import { FileUpload } from '@/components/inputs';
|
||||
import { ImagePreviewModal } from '@/components/dialogs';
|
||||
import { InputError } from '@/components/ui';
|
||||
import { NumberInput } from '@/components/inputs';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card';
|
||||
import { Combobox, ComboboxContent, ComboboxEmpty, ComboboxInput, ComboboxItem, ComboboxList } from '@/components/ui/combobox';
|
||||
|
||||
@ -1,10 +1,10 @@
|
||||
import { Head, Link, router } from '@inertiajs/react';
|
||||
import { Plus } from 'lucide-react';
|
||||
import { useState } from 'react';
|
||||
import { CardTable } from '@/components/card-table';
|
||||
import { DeleteConfirmDialog } from '@/components/delete-confirm-dialog';
|
||||
import { CardTable } from '@/components/data-display';
|
||||
import { DeleteConfirmDialog } from '@/components/dialogs';
|
||||
import { useCardTableExpand } from '@/components/hooks/use-card-table-expand';
|
||||
import { PageHeader } from '@/components/page-header';
|
||||
import { PageHeader } from '@/components/layout';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { useCan } from '@/hooks/use-can';
|
||||
import { useServerTable } from '@/hooks/use-server-table';
|
||||
|
||||
@ -13,12 +13,12 @@ import {
|
||||
} from 'lucide-react';
|
||||
import { useCallback, useMemo, useRef, useState } from 'react';
|
||||
import { toast } from 'sonner';
|
||||
import { ConfirmDialog } from '@/components/confirm-dialog';
|
||||
import { FileUpload } from '@/components/file-upload';
|
||||
import { ImagePreviewModal } from '@/components/image-preview-modal';
|
||||
import InputError from '@/components/input-error';
|
||||
import { NumberInput } from '@/components/number-input';
|
||||
import { RupiahInput } from '@/components/rupiah-input';
|
||||
import { ConfirmDialog } from '@/components/dialogs';
|
||||
import { FileUpload } from '@/components/inputs';
|
||||
import { ImagePreviewModal } from '@/components/dialogs';
|
||||
import { InputError } from '@/components/ui';
|
||||
import { NumberInput } from '@/components/inputs';
|
||||
import { RupiahInput } from '@/components/inputs';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card';
|
||||
import {
|
||||
|
||||
@ -10,12 +10,12 @@ import {
|
||||
} from 'lucide-react';
|
||||
import { useCallback, useMemo, useState } from 'react';
|
||||
import { toast } from 'sonner';
|
||||
import { ConfirmDialog } from '@/components/confirm-dialog';
|
||||
import { FileUpload } from '@/components/file-upload';
|
||||
import { ImagePreviewModal } from '@/components/image-preview-modal';
|
||||
import InputError from '@/components/input-error';
|
||||
import { NumberInput } from '@/components/number-input';
|
||||
import { RupiahInput } from '@/components/rupiah-input';
|
||||
import { ConfirmDialog } from '@/components/dialogs';
|
||||
import { FileUpload } from '@/components/inputs';
|
||||
import { ImagePreviewModal } from '@/components/dialogs';
|
||||
import { InputError } from '@/components/ui';
|
||||
import { NumberInput } from '@/components/inputs';
|
||||
import { RupiahInput } from '@/components/inputs';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card';
|
||||
import {
|
||||
|
||||
@ -1,11 +1,11 @@
|
||||
import { Head, Link, router } from '@inertiajs/react';
|
||||
import { Plus } from 'lucide-react';
|
||||
import { useMemo, useState } from 'react';
|
||||
import { CardTable } from '@/components/card-table';
|
||||
import { DeleteConfirmDialog } from '@/components/delete-confirm-dialog';
|
||||
import { FilterPopover } from '@/components/filter-popover';
|
||||
import { CardTable } from '@/components/data-display';
|
||||
import { DeleteConfirmDialog } from '@/components/dialogs';
|
||||
import { FilterPopover } from '@/components/data-display';
|
||||
import { useCardTableExpand } from '@/components/hooks/use-card-table-expand';
|
||||
import { PageHeader } from '@/components/page-header';
|
||||
import { PageHeader } from '@/components/layout';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import {
|
||||
Combobox,
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import { ChevronDown, Pencil, Trash2 } from 'lucide-react';
|
||||
import { ImagePreviewButton } from '@/components/image-preview-button';
|
||||
import { RowActions } from '@/components/row-actions';
|
||||
import { ImagePreviewButton } from '@/components/dialogs';
|
||||
import { RowActions } from '@/components/data-display';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Card, CardContent } from '@/components/ui/card';
|
||||
import { useCan } from '@/hooks/use-can';
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
import { ImagePreviewButton } from '@/components/image-preview-button';
|
||||
import { ImagePreviewButton } from '@/components/dialogs';
|
||||
import {
|
||||
Table,
|
||||
TableBody,
|
||||
|
||||
@ -4,11 +4,11 @@ import { Form, Head, Link, usePage } from '@inertiajs/react';
|
||||
import { ArrowLeft, Minus, Plus, ShoppingCart, Trash2 } from 'lucide-react';
|
||||
import { useCallback, useEffect, useMemo, useRef, useState } from 'react';
|
||||
import { toast } from 'sonner';
|
||||
import { ConfirmDialog } from '@/components/confirm-dialog';
|
||||
import { FileUpload } from '@/components/file-upload';
|
||||
import { ImagePreviewModal } from '@/components/image-preview-modal';
|
||||
import InputError from '@/components/input-error';
|
||||
import { NumberInput } from '@/components/number-input';
|
||||
import { ConfirmDialog } from '@/components/dialogs';
|
||||
import { FileUpload } from '@/components/inputs';
|
||||
import { ImagePreviewModal } from '@/components/dialogs';
|
||||
import { InputError } from '@/components/ui';
|
||||
import { NumberInput } from '@/components/inputs';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card';
|
||||
import {
|
||||
|
||||
@ -4,11 +4,11 @@ import { Form, Head, Link } from '@inertiajs/react';
|
||||
import { ArrowLeft, Minus, Plus, ShoppingCart, Trash2 } from 'lucide-react';
|
||||
import { useCallback, useEffect, useMemo, useRef, useState } from 'react';
|
||||
import { toast } from 'sonner';
|
||||
import { ConfirmDialog } from '@/components/confirm-dialog';
|
||||
import { FileUpload } from '@/components/file-upload';
|
||||
import { ImagePreviewModal } from '@/components/image-preview-modal';
|
||||
import InputError from '@/components/input-error';
|
||||
import { NumberInput } from '@/components/number-input';
|
||||
import { ConfirmDialog } from '@/components/dialogs';
|
||||
import { FileUpload } from '@/components/inputs';
|
||||
import { ImagePreviewModal } from '@/components/dialogs';
|
||||
import { InputError } from '@/components/ui';
|
||||
import { NumberInput } from '@/components/inputs';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card';
|
||||
import { Label } from '@/components/ui/label';
|
||||
|
||||
@ -1,10 +1,10 @@
|
||||
import { Head, Link, router } from '@inertiajs/react';
|
||||
import { Plus } from 'lucide-react';
|
||||
import { useState } from 'react';
|
||||
import { CardTable } from '@/components/card-table';
|
||||
import { DeleteConfirmDialog } from '@/components/delete-confirm-dialog';
|
||||
import { CardTable } from '@/components/data-display';
|
||||
import { DeleteConfirmDialog } from '@/components/dialogs';
|
||||
import { useCardTableExpand } from '@/components/hooks/use-card-table-expand';
|
||||
import { PageHeader } from '@/components/page-header';
|
||||
import { PageHeader } from '@/components/layout';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { useCan } from '@/hooks/use-can';
|
||||
import { useServerTable } from '@/hooks/use-server-table';
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
import { ChevronDown, Pencil, Trash2 } from 'lucide-react';
|
||||
import { RowActions } from '@/components/row-actions';
|
||||
import { RowActions } from '@/components/data-display';
|
||||
import { Badge } from '@/components/ui/badge';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Card, CardContent } from '@/components/ui/card';
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
import { Fragment } from 'react';
|
||||
import { ImagePreviewButton } from '@/components/image-preview-button';
|
||||
import { ImagePreviewButton } from '@/components/dialogs';
|
||||
import {
|
||||
Table,
|
||||
TableBody,
|
||||
|
||||
@ -4,12 +4,12 @@ import { Form, Head, Link, usePage } from '@inertiajs/react';
|
||||
import { ArrowLeft, Minus, Plus, ShoppingCart, Trash2 } from 'lucide-react';
|
||||
import { useCallback, useEffect, useMemo, useRef, useState } from 'react';
|
||||
import { toast } from 'sonner';
|
||||
import { ConfirmDialog } from '@/components/confirm-dialog';
|
||||
import { FileUpload } from '@/components/file-upload';
|
||||
import { ImagePreviewModal } from '@/components/image-preview-modal';
|
||||
import InputError from '@/components/input-error';
|
||||
import { NumberInput } from '@/components/number-input';
|
||||
import { RupiahInput } from '@/components/rupiah-input';
|
||||
import { ConfirmDialog } from '@/components/dialogs';
|
||||
import { FileUpload } from '@/components/inputs';
|
||||
import { ImagePreviewModal } from '@/components/dialogs';
|
||||
import { InputError } from '@/components/ui';
|
||||
import { NumberInput } from '@/components/inputs';
|
||||
import { RupiahInput } from '@/components/inputs';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card';
|
||||
import {
|
||||
|
||||
@ -4,12 +4,12 @@ import { Form, Head, Link } from '@inertiajs/react';
|
||||
import { ArrowLeft, Minus, Plus, ShoppingCart, Trash2 } from 'lucide-react';
|
||||
import { useCallback, useEffect, useMemo, useRef, useState } from 'react';
|
||||
import { toast } from 'sonner';
|
||||
import { ConfirmDialog } from '@/components/confirm-dialog';
|
||||
import { FileUpload } from '@/components/file-upload';
|
||||
import { ImagePreviewModal } from '@/components/image-preview-modal';
|
||||
import InputError from '@/components/input-error';
|
||||
import { NumberInput } from '@/components/number-input';
|
||||
import { RupiahInput } from '@/components/rupiah-input';
|
||||
import { ConfirmDialog } from '@/components/dialogs';
|
||||
import { FileUpload } from '@/components/inputs';
|
||||
import { ImagePreviewModal } from '@/components/dialogs';
|
||||
import { InputError } from '@/components/ui';
|
||||
import { NumberInput } from '@/components/inputs';
|
||||
import { RupiahInput } from '@/components/inputs';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card';
|
||||
import {
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user