warqadui 0.0.47 → 0.0.50

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -5,6 +5,7 @@ import * as react_hook_form from 'react-hook-form';
5
5
  import { FieldValues, Path, UseFormReturn } from 'react-hook-form';
6
6
  import { ColumnDef, SortingState, ColumnFiltersState, RowData } from '@tanstack/react-table';
7
7
  import * as react_to_print from 'react-to-print';
8
+ import { UploadFile } from 'antd';
8
9
 
9
10
  interface ButtonProps extends React__default.ButtonHTMLAttributes<HTMLButtonElement> {
10
11
  variant?: "primary" | "secondary" | "outline" | "ghost" | "danger" | "warning";
@@ -601,6 +602,36 @@ declare const useA4StatementView: ({ url, v, delay, params, startPage, }?: {
601
602
  reactToPrintFn: react_to_print.UseReactToPrintFn;
602
603
  };
603
604
 
605
+ declare const useA4CategoryView: ({ url, v, delay, params, startPage, }?: {
606
+ url?: string;
607
+ v?: 0 | 1 | 2;
608
+ delay?: number;
609
+ params?: Record<string, any>;
610
+ startPage?: number;
611
+ }) => {
612
+ A4CategoryView: ({ data, groups: incomingGroups, error, info, title, subtitle, printable, gridTitle, startPage: componentStartPage, isLoading: externalLoading, renderItem, gridColumns, }: {
613
+ gridTitle?: string;
614
+ data?: any[];
615
+ groups?: {
616
+ title: string;
617
+ items: any[];
618
+ }[];
619
+ error?: string | null;
620
+ info?: any[];
621
+ title?: string;
622
+ subtitle?: string;
623
+ printable?: boolean;
624
+ startPage?: number;
625
+ isLoading?: boolean;
626
+ renderItem: (item: any) => React.ReactNode;
627
+ gridColumns?: number;
628
+ }) => react_jsx_runtime.JSX.Element;
629
+ data: any;
630
+ isLoading: boolean;
631
+ get: FetchFunction;
632
+ reactToPrintFn: react_to_print.UseReactToPrintFn;
633
+ };
634
+
604
635
  declare const useTransaction: ({ url, v, delay, params, dateFilter, }: {
605
636
  url: string;
606
637
  v?: 0 | 1 | 2;
@@ -712,4 +743,35 @@ interface StorageManager {
712
743
  */
713
744
  declare const storage: StorageManager;
714
745
 
715
- export { Badge, type BadgeProps, Branding, type BrandingProps, Button, type ButtonProps, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, ClassicSpin, CodeBlock, DashboardLayout, DataTable, type DataTableColumn, DateInput, type DateInputProps, type DeleteFunction, type FetchFunction, type FetchProps, Fields, InfoGrid, Input, type InputProps, LoadingBox, LoadingSpin, Modal, type ModalProps, type NavItem, type NavItems, type Option, OverlaySpin, PageA4, PageHeader, type PdfOptions, PhoneInput, type PhoneInputProps, type PostFunction, PostTable, type PostTableActions, type PostTableChangeParams, type PutFunction, SearchApi, SearchApiContent, SearchApiInput, SearchApiItem, type SearchApiProps, SearchApiTrigger, Select, SelectContent, SelectItem, type SelectProps, SelectTrigger, SimpleTable, type SimpleTableColumn, type StorageManager, type StoreConfig, Textarea, type TextareaProps, type ThemeConfig, ThemeProvider, ThemeToggle, type UseModalReturn, type WarqadConfig, type WarqadConfigContextType, WarqadProvider, generatePdf, storage, useA4StatementView, useApi, useModal, useSearchApiContext, useSelectContext, useTheme, useTransaction, useWarqadConfig };
746
+ declare const useAntdImageUpload: ({ length }: {
747
+ length?: number | undefined;
748
+ }) => {
749
+ ImageBox: () => react_jsx_runtime.JSX.Element;
750
+ fileList: UploadFile<any>[];
751
+ setFileList: React$1.Dispatch<React$1.SetStateAction<UploadFile<any>[]>>;
752
+ };
753
+
754
+ interface CategoryItem {
755
+ id: string | number;
756
+ name: string;
757
+ price: string | number;
758
+ image: string;
759
+ }
760
+ interface CategoryViewProps {
761
+ categoryName: string;
762
+ items: CategoryItem[];
763
+ className?: string;
764
+ }
765
+ declare const CategoryCard: React__default.FC<{
766
+ item: CategoryItem;
767
+ }>;
768
+
769
+ declare const Views: {
770
+ Transaction: () => react_jsx_runtime.JSX.Element;
771
+ CategoryView: React$1.FC<CategoryViewProps>;
772
+ CategoryCard: React$1.FC<{
773
+ item: CategoryItem;
774
+ }>;
775
+ };
776
+
777
+ export { Badge, type BadgeProps, Branding, type BrandingProps, Button, type ButtonProps, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, CategoryCard, type CategoryItem, ClassicSpin, CodeBlock, DashboardLayout, DataTable, type DataTableColumn, DateInput, type DateInputProps, type DeleteFunction, type FetchFunction, type FetchProps, Fields, InfoGrid, Input, type InputProps, LoadingBox, LoadingSpin, Modal, type ModalProps, type NavItem, type NavItems, type Option, OverlaySpin, PageA4, PageHeader, type PdfOptions, PhoneInput, type PhoneInputProps, type PostFunction, PostTable, type PostTableActions, type PostTableChangeParams, type PutFunction, SearchApi, SearchApiContent, SearchApiInput, SearchApiItem, type SearchApiProps, SearchApiTrigger, Select, SelectContent, SelectItem, type SelectProps, SelectTrigger, SimpleTable, type SimpleTableColumn, type StorageManager, type StoreConfig, Textarea, type TextareaProps, type ThemeConfig, ThemeProvider, ThemeToggle, type UseModalReturn, Views, type WarqadConfig, type WarqadConfigContextType, WarqadProvider, generatePdf, storage, useA4CategoryView, useA4StatementView, useAntdImageUpload, useApi, useModal, useSearchApiContext, useSelectContext, useTheme, useTransaction, useWarqadConfig };
package/dist/index.d.ts CHANGED
@@ -5,6 +5,7 @@ import * as react_hook_form from 'react-hook-form';
5
5
  import { FieldValues, Path, UseFormReturn } from 'react-hook-form';
6
6
  import { ColumnDef, SortingState, ColumnFiltersState, RowData } from '@tanstack/react-table';
7
7
  import * as react_to_print from 'react-to-print';
8
+ import { UploadFile } from 'antd';
8
9
 
9
10
  interface ButtonProps extends React__default.ButtonHTMLAttributes<HTMLButtonElement> {
10
11
  variant?: "primary" | "secondary" | "outline" | "ghost" | "danger" | "warning";
@@ -601,6 +602,36 @@ declare const useA4StatementView: ({ url, v, delay, params, startPage, }?: {
601
602
  reactToPrintFn: react_to_print.UseReactToPrintFn;
602
603
  };
603
604
 
605
+ declare const useA4CategoryView: ({ url, v, delay, params, startPage, }?: {
606
+ url?: string;
607
+ v?: 0 | 1 | 2;
608
+ delay?: number;
609
+ params?: Record<string, any>;
610
+ startPage?: number;
611
+ }) => {
612
+ A4CategoryView: ({ data, groups: incomingGroups, error, info, title, subtitle, printable, gridTitle, startPage: componentStartPage, isLoading: externalLoading, renderItem, gridColumns, }: {
613
+ gridTitle?: string;
614
+ data?: any[];
615
+ groups?: {
616
+ title: string;
617
+ items: any[];
618
+ }[];
619
+ error?: string | null;
620
+ info?: any[];
621
+ title?: string;
622
+ subtitle?: string;
623
+ printable?: boolean;
624
+ startPage?: number;
625
+ isLoading?: boolean;
626
+ renderItem: (item: any) => React.ReactNode;
627
+ gridColumns?: number;
628
+ }) => react_jsx_runtime.JSX.Element;
629
+ data: any;
630
+ isLoading: boolean;
631
+ get: FetchFunction;
632
+ reactToPrintFn: react_to_print.UseReactToPrintFn;
633
+ };
634
+
604
635
  declare const useTransaction: ({ url, v, delay, params, dateFilter, }: {
605
636
  url: string;
606
637
  v?: 0 | 1 | 2;
@@ -712,4 +743,35 @@ interface StorageManager {
712
743
  */
713
744
  declare const storage: StorageManager;
714
745
 
715
- export { Badge, type BadgeProps, Branding, type BrandingProps, Button, type ButtonProps, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, ClassicSpin, CodeBlock, DashboardLayout, DataTable, type DataTableColumn, DateInput, type DateInputProps, type DeleteFunction, type FetchFunction, type FetchProps, Fields, InfoGrid, Input, type InputProps, LoadingBox, LoadingSpin, Modal, type ModalProps, type NavItem, type NavItems, type Option, OverlaySpin, PageA4, PageHeader, type PdfOptions, PhoneInput, type PhoneInputProps, type PostFunction, PostTable, type PostTableActions, type PostTableChangeParams, type PutFunction, SearchApi, SearchApiContent, SearchApiInput, SearchApiItem, type SearchApiProps, SearchApiTrigger, Select, SelectContent, SelectItem, type SelectProps, SelectTrigger, SimpleTable, type SimpleTableColumn, type StorageManager, type StoreConfig, Textarea, type TextareaProps, type ThemeConfig, ThemeProvider, ThemeToggle, type UseModalReturn, type WarqadConfig, type WarqadConfigContextType, WarqadProvider, generatePdf, storage, useA4StatementView, useApi, useModal, useSearchApiContext, useSelectContext, useTheme, useTransaction, useWarqadConfig };
746
+ declare const useAntdImageUpload: ({ length }: {
747
+ length?: number | undefined;
748
+ }) => {
749
+ ImageBox: () => react_jsx_runtime.JSX.Element;
750
+ fileList: UploadFile<any>[];
751
+ setFileList: React$1.Dispatch<React$1.SetStateAction<UploadFile<any>[]>>;
752
+ };
753
+
754
+ interface CategoryItem {
755
+ id: string | number;
756
+ name: string;
757
+ price: string | number;
758
+ image: string;
759
+ }
760
+ interface CategoryViewProps {
761
+ categoryName: string;
762
+ items: CategoryItem[];
763
+ className?: string;
764
+ }
765
+ declare const CategoryCard: React__default.FC<{
766
+ item: CategoryItem;
767
+ }>;
768
+
769
+ declare const Views: {
770
+ Transaction: () => react_jsx_runtime.JSX.Element;
771
+ CategoryView: React$1.FC<CategoryViewProps>;
772
+ CategoryCard: React$1.FC<{
773
+ item: CategoryItem;
774
+ }>;
775
+ };
776
+
777
+ export { Badge, type BadgeProps, Branding, type BrandingProps, Button, type ButtonProps, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, CategoryCard, type CategoryItem, ClassicSpin, CodeBlock, DashboardLayout, DataTable, type DataTableColumn, DateInput, type DateInputProps, type DeleteFunction, type FetchFunction, type FetchProps, Fields, InfoGrid, Input, type InputProps, LoadingBox, LoadingSpin, Modal, type ModalProps, type NavItem, type NavItems, type Option, OverlaySpin, PageA4, PageHeader, type PdfOptions, PhoneInput, type PhoneInputProps, type PostFunction, PostTable, type PostTableActions, type PostTableChangeParams, type PutFunction, SearchApi, SearchApiContent, SearchApiInput, SearchApiItem, type SearchApiProps, SearchApiTrigger, Select, SelectContent, SelectItem, type SelectProps, SelectTrigger, SimpleTable, type SimpleTableColumn, type StorageManager, type StoreConfig, Textarea, type TextareaProps, type ThemeConfig, ThemeProvider, ThemeToggle, type UseModalReturn, Views, type WarqadConfig, type WarqadConfigContextType, WarqadProvider, generatePdf, storage, useA4CategoryView, useA4StatementView, useAntdImageUpload, useApi, useModal, useSearchApiContext, useSelectContext, useTheme, useTransaction, useWarqadConfig };