@pnkx-lib/ui 1.9.124 → 1.9.126

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.
Files changed (149) hide show
  1. package/dist/style.css +2 -2
  2. package/es/chunks/{AntdIcon-BzTwLyPk.js → AntdIcon-BS99Z6_t.js} +7172 -450
  3. package/es/chunks/{Card-z7w17sEa.js → ConfigProvider-Bsz3gTK1.js} +116 -91
  4. package/es/chunks/{Switch-DJsNQcly.js → Switch-vaUhKEAu.js} +1 -1
  5. package/es/fields/index.js +2 -2
  6. package/es/index.js +3 -3
  7. package/es/ui/index.js +2 -2
  8. package/package.json +1 -1
  9. package/types/App.d.ts +2 -0
  10. package/types/DemoInput/DemoInput.d.ts +1 -0
  11. package/types/DemoTable/FiltersCategoryDemo/components/RenderFilterFields.d.ts +12 -0
  12. package/types/DemoTable/FiltersCategoryDemo/components/TagsFilter.d.ts +12 -0
  13. package/types/DemoTable/FiltersCategoryDemo/index.d.ts +8 -0
  14. package/types/DemoTable/apiUser.d.ts +30 -0
  15. package/types/DemoTable/hooks/useConvertGroupButton.d.ts +13 -0
  16. package/types/DemoTable/index.d.ts +2 -0
  17. package/types/DemoTable/tabDemo.d.ts +2 -0
  18. package/types/assets/svg/404.d.ts +2 -0
  19. package/types/assets/svg/Flag.d.ts +2 -0
  20. package/types/assets/svg/Logout.d.ts +2 -0
  21. package/types/assets/svg/Search.d.ts +2 -0
  22. package/types/assets/svg/Setting.d.ts +2 -0
  23. package/types/components/icons/Dollar.d.ts +3 -0
  24. package/types/components/index.d.ts +3 -0
  25. package/types/{ui → components/ui}/BulkActions/BulkAction.d.ts +1 -1
  26. package/types/{ui → components/ui}/BulkActions/index.d.ts +1 -1
  27. package/types/components/ui/ConfigProvider.d.ts +4 -0
  28. package/types/{ui → components/ui}/Sidebar.d.ts +2 -1
  29. package/types/{ui → components/ui}/Table/ActionRowTable/index.d.ts +1 -1
  30. package/types/{ui → components/ui}/Table/HeadingTable/components/GroupHeadingButton.d.ts +1 -1
  31. package/types/{ui → components/ui}/Table/index.d.ts +1 -1
  32. package/types/{ui → components/ui}/index.d.ts +1 -0
  33. package/types/constants/common.d.ts +1 -0
  34. package/types/constants/index.d.ts +2 -0
  35. package/types/constants/table.d.ts +32 -0
  36. package/types/fields.d.ts +1 -1
  37. package/types/helpers/common.d.ts +1 -0
  38. package/types/hooks.d.ts +1 -1
  39. package/types/index.d.ts +2 -3
  40. package/types/interface/common.d.ts +8 -0
  41. package/types/interface/tab.d.ts +5 -0
  42. package/types/main.d.ts +0 -0
  43. package/types/stores/tabStore.d.ts +6 -0
  44. package/types/stories/Input.stories.d.ts +6 -0
  45. package/types/ui.d.ts +1 -1
  46. package/types/utils/router.d.ts +35 -0
  47. package/types/utils/timer.d.ts +7 -0
  48. package/types/vite-env.d.ts +1 -0
  49. /package/types/{fields → components/fields}/CascaderField.d.ts +0 -0
  50. /package/types/{fields → components/fields}/Checkbox.d.ts +0 -0
  51. /package/types/{fields → components/fields}/DatePicker.d.ts +0 -0
  52. /package/types/{fields → components/fields}/DateRangePicker.d.ts +0 -0
  53. /package/types/{fields → components/fields}/Input.d.ts +0 -0
  54. /package/types/{fields → components/fields}/PnkxField.d.ts +0 -0
  55. /package/types/{fields → components/fields}/Radio.d.ts +0 -0
  56. /package/types/{fields → components/fields}/Select.d.ts +0 -0
  57. /package/types/{fields → components/fields}/Switch.d.ts +0 -0
  58. /package/types/{fields → components/fields}/Textarea.d.ts +0 -0
  59. /package/types/{fields → components/fields}/TinyMCE.d.ts +0 -0
  60. /package/types/{fields → components/fields}/Upload.d.ts +0 -0
  61. /package/types/{fields → components/fields}/index.d.ts +0 -0
  62. /package/types/{hooks → components/hooks}/index.d.ts +0 -0
  63. /package/types/{hooks → components/hooks}/useDebounce.d.ts +0 -0
  64. /package/types/{hooks → components/hooks}/useMessage.d.ts +0 -0
  65. /package/types/{hooks → components/hooks}/useToast.d.ts +0 -0
  66. /package/types/{icons → components/icons}/ActivateIcon.d.ts +0 -0
  67. /package/types/{icons → components/icons}/AllowClearIcon.d.ts +0 -0
  68. /package/types/{icons → components/icons}/ApprovalIcon.d.ts +0 -0
  69. /package/types/{icons → components/icons}/CancelApprovalIcon.d.ts +0 -0
  70. /package/types/{icons → components/icons}/CancelSendApprovalIcon.d.ts +0 -0
  71. /package/types/{icons → components/icons}/DeleteIcon.d.ts +0 -0
  72. /package/types/{icons → components/icons}/DragIcon.d.ts +0 -0
  73. /package/types/{icons → components/icons}/EditIcon.d.ts +0 -0
  74. /package/types/{icons → components/icons}/ErrorConfirmIcon.d.ts +0 -0
  75. /package/types/{icons → components/icons}/InActivateIcon.d.ts +0 -0
  76. /package/types/{icons → components/icons}/InfoConfirmIcon.d.ts +0 -0
  77. /package/types/{icons → components/icons}/MoreIcon.d.ts +0 -0
  78. /package/types/{icons → components/icons}/PlusIcon.d.ts +0 -0
  79. /package/types/{icons → components/icons}/RefuseApprovalIcon.d.ts +0 -0
  80. /package/types/{icons → components/icons}/RestoreIcon.d.ts +0 -0
  81. /package/types/{icons → components/icons}/SearchAdvanceIcon.d.ts +0 -0
  82. /package/types/{icons → components/icons}/SearchIcon.d.ts +0 -0
  83. /package/types/{icons → components/icons}/SendApprovalIcon.d.ts +0 -0
  84. /package/types/{icons → components/icons}/SettingIcon.d.ts +0 -0
  85. /package/types/{icons → components/icons}/SuccessIcon.d.ts +0 -0
  86. /package/types/{icons → components/icons}/TrashCanIcon.d.ts +0 -0
  87. /package/types/{icons → components/icons}/WaitingApprovalIcon.d.ts +0 -0
  88. /package/types/{icons → components/icons}/WarningConfirmIcon.d.ts +0 -0
  89. /package/types/{icons → components/icons}/index.d.ts +0 -0
  90. /package/types/{ui → components/ui}/Alert.d.ts +0 -0
  91. /package/types/{ui → components/ui}/Anchor.d.ts +0 -0
  92. /package/types/{ui → components/ui}/Appfix.d.ts +0 -0
  93. /package/types/{ui → components/ui}/AutoComplete.d.ts +0 -0
  94. /package/types/{ui → components/ui}/Badge.d.ts +0 -0
  95. /package/types/{ui → components/ui}/Breadcrumb.d.ts +0 -0
  96. /package/types/{ui → components/ui}/BreadcrumbHeading.d.ts +0 -0
  97. /package/types/{ui → components/ui}/BulkActions/DropListActions.d.ts +0 -0
  98. /package/types/{ui → components/ui}/Button.d.ts +0 -0
  99. /package/types/{ui → components/ui}/Card.d.ts +0 -0
  100. /package/types/{ui → components/ui}/Cascader.d.ts +0 -0
  101. /package/types/{ui → components/ui}/CategoryStatus.d.ts +0 -0
  102. /package/types/{ui → components/ui}/Col.d.ts +0 -0
  103. /package/types/{ui → components/ui}/Collapse.d.ts +0 -0
  104. /package/types/{ui → components/ui}/ColorPicker.d.ts +0 -0
  105. /package/types/{ui → components/ui}/ConfirmModal.d.ts +0 -0
  106. /package/types/{ui → components/ui}/Container.d.ts +0 -0
  107. /package/types/{ui → components/ui}/Divider.d.ts +0 -0
  108. /package/types/{ui → components/ui}/Drawer.d.ts +0 -0
  109. /package/types/{ui → components/ui}/Dropdown.d.ts +0 -0
  110. /package/types/{ui → components/ui}/Empty.d.ts +0 -0
  111. /package/types/{ui → components/ui}/ErrorBoundary.d.ts +0 -0
  112. /package/types/{ui → components/ui}/ErrorMessage.d.ts +0 -0
  113. /package/types/{ui → components/ui}/Flex.d.ts +0 -0
  114. /package/types/{ui → components/ui}/Footer.d.ts +0 -0
  115. /package/types/{ui → components/ui}/Heading.d.ts +0 -0
  116. /package/types/{ui → components/ui}/Image.d.ts +0 -0
  117. /package/types/{ui → components/ui}/Label.d.ts +0 -0
  118. /package/types/{ui → components/ui}/Layout.d.ts +0 -0
  119. /package/types/{ui → components/ui}/Menu.d.ts +0 -0
  120. /package/types/{ui → components/ui}/Modal.d.ts +0 -0
  121. /package/types/{ui → components/ui}/Page404.d.ts +0 -0
  122. /package/types/{ui → components/ui}/Pagination.d.ts +0 -0
  123. /package/types/{ui → components/ui}/Popconfirm.d.ts +0 -0
  124. /package/types/{ui → components/ui}/Popover.d.ts +0 -0
  125. /package/types/{ui → components/ui}/QRCode.d.ts +0 -0
  126. /package/types/{ui → components/ui}/Rate.d.ts +0 -0
  127. /package/types/{ui → components/ui}/Result.d.ts +0 -0
  128. /package/types/{ui → components/ui}/Row.d.ts +0 -0
  129. /package/types/{ui → components/ui}/SearchFilterForm.d.ts +0 -0
  130. /package/types/{ui → components/ui}/Segmented.d.ts +0 -0
  131. /package/types/{ui → components/ui}/Skeleton.d.ts +0 -0
  132. /package/types/{ui → components/ui}/Space.d.ts +0 -0
  133. /package/types/{ui → components/ui}/Spin.d.ts +0 -0
  134. /package/types/{ui → components/ui}/Splitter.d.ts +0 -0
  135. /package/types/{ui → components/ui}/Statistic.d.ts +0 -0
  136. /package/types/{ui → components/ui}/Steps.d.ts +0 -0
  137. /package/types/{ui → components/ui}/Table/HeadingTable/index.d.ts +0 -0
  138. /package/types/{ui → components/ui}/Table/SettingTable/IconSettingTable.d.ts +0 -0
  139. /package/types/{ui → components/ui}/Table/SettingTable/SettingColumnItem.d.ts +0 -0
  140. /package/types/{ui → components/ui}/Table/SettingTable/SortableItem.d.ts +0 -0
  141. /package/types/{ui → components/ui}/Table/SettingTable/index.d.ts +0 -0
  142. /package/types/{ui → components/ui}/Tabs.d.ts +0 -0
  143. /package/types/{ui → components/ui}/Tag.d.ts +0 -0
  144. /package/types/{ui → components/ui}/Timeline.d.ts +0 -0
  145. /package/types/{ui → components/ui}/Tooltip.d.ts +0 -0
  146. /package/types/{ui → components/ui}/Tour.d.ts +0 -0
  147. /package/types/{ui → components/ui}/Tree.d.ts +0 -0
  148. /package/types/{ui → components/ui}/Typography.d.ts +0 -0
  149. /package/types/{ui → components/ui}/Watermark.d.ts +0 -0
@@ -0,0 +1,30 @@
1
+ export interface ReqResUser {
2
+ id: number;
3
+ title: string;
4
+ slug: string;
5
+ price: string;
6
+ }
7
+ export interface ReqResResponse {
8
+ data: ReqResUser[];
9
+ page: number;
10
+ per_page: number;
11
+ total: number;
12
+ }
13
+ export declare const fetchUsers: (page: number, perPage: number) => Promise<{
14
+ data: ReqResUser[];
15
+ pagination: {
16
+ total: number;
17
+ page: number;
18
+ limit: number;
19
+ totalPages: number;
20
+ };
21
+ }>;
22
+ export declare const fetchUsersNew: (page: number, perPage: number) => Promise<{
23
+ data: ReqResUser[];
24
+ pagination: {
25
+ total: number;
26
+ page: number;
27
+ limit: number;
28
+ totalPages: number;
29
+ };
30
+ }>;
@@ -0,0 +1,13 @@
1
+ import { GroupHeadingButtonItem } from '../../../../../../../../../../src/components/ui/Table/HeadingTable/components/GroupHeadingButton';
2
+ export interface LabelGroupHeadingButtonItem {
3
+ label: string;
4
+ is_status: number;
5
+ }
6
+ export interface QuantityGroupHeadingButtonItem {
7
+ quantity: number;
8
+ is_status: number;
9
+ }
10
+ declare const useConvertGroupButton: (labelGroupHeadingButtonItems: LabelGroupHeadingButtonItem[]) => {
11
+ data: GroupHeadingButtonItem[];
12
+ };
13
+ export default useConvertGroupButton;
@@ -0,0 +1,2 @@
1
+ declare const DemoTable: () => import("react/jsx-runtime").JSX.Element;
2
+ export default DemoTable;
@@ -0,0 +1,2 @@
1
+ declare const TabDemo: () => import("react/jsx-runtime").JSX.Element;
2
+ export default TabDemo;
@@ -0,0 +1,2 @@
1
+ declare const Svg404Notfound: () => import("react/jsx-runtime").JSX.Element;
2
+ export default Svg404Notfound;
@@ -0,0 +1,2 @@
1
+ declare const SvgFlag: () => import("react/jsx-runtime").JSX.Element;
2
+ export default SvgFlag;
@@ -0,0 +1,2 @@
1
+ declare const SvgLogout: () => import("react/jsx-runtime").JSX.Element;
2
+ export default SvgLogout;
@@ -0,0 +1,2 @@
1
+ declare const SvgIconSearch: () => import("react/jsx-runtime").JSX.Element;
2
+ export default SvgIconSearch;
@@ -0,0 +1,2 @@
1
+ declare const SvgSetting: () => import("react/jsx-runtime").JSX.Element;
2
+ export default SvgSetting;
@@ -0,0 +1,3 @@
1
+ import { SVGProps } from 'react';
2
+ declare const SvgDollar: (props: SVGProps<SVGSVGElement>) => import("react/jsx-runtime").JSX.Element;
3
+ export default SvgDollar;
@@ -0,0 +1,3 @@
1
+ export * from './ui';
2
+ export * from './fields';
3
+ export * from './hooks';
@@ -1,6 +1,6 @@
1
1
  import { ConfirmModalProps } from '../ConfirmModal';
2
2
  import { TListIcon } from '.';
3
- import { TypeStatusTable } from '../../../../../../../../../../src/constants';
3
+ import { TypeStatusTable } from '../../../../../../../../../../../src/constants';
4
4
  export interface BulkActionProps {
5
5
  quantity?: number;
6
6
  listIcon?: TListIcon[];
@@ -1,6 +1,6 @@
1
1
  import { CATEGORY_LIST_ENUM } from '../../../../../core/src/constants/enum';
2
2
  import { ConfirmModalProps } from '../ConfirmModal';
3
- import { TypeBulkActions, TypeStatusTable } from '../../../../../../../../../../src/constants';
3
+ import { TypeBulkActions, TypeStatusTable } from '../../../../../../../../../../../src/constants';
4
4
  interface IBulkActionsProps {
5
5
  quantity?: number;
6
6
  handleRestore?: () => void;
@@ -0,0 +1,4 @@
1
+ import { default as React } from 'react';
2
+ import { ConfigProviderProps as AntdConfigProviderProps } from 'antd';
3
+ export type ConfigProviderProps = AntdConfigProviderProps;
4
+ export declare const ConfigProvider: React.FC<ConfigProviderProps>;
@@ -2,13 +2,14 @@ import { ReactNode, default as React } from 'react';
2
2
  export type MenuType = {
3
3
  name: string;
4
4
  path: string;
5
- isShow: boolean;
5
+ isShowModules: boolean;
6
6
  isPrivateRoute?: boolean;
7
7
  layout?: React.LazyExoticComponent<React.MemoExoticComponent<any>> | React.ExoticComponent<any> | typeof React.Component;
8
8
  children: {
9
9
  name: string;
10
10
  path: string;
11
11
  icon?: ReactNode;
12
+ isShowChildren?: boolean;
12
13
  component: typeof React.Component | React.FC;
13
14
  children?: Array<{
14
15
  name: string;
@@ -1,5 +1,5 @@
1
1
  import { default as React } from 'react';
2
- import { TypeActionRowTable } from '../../../../../../../../../../../src/constants/table';
2
+ import { TypeActionRowTable } from '../../../../../../../../../../../../src/constants/table';
3
3
  export interface ActionRowTableProps {
4
4
  type: TypeActionRowTable;
5
5
  handleClick?: () => void;
@@ -1,5 +1,5 @@
1
1
  import { InitialFiltersSearch } from '@pnkx-lib/core';
2
- import { TFilters, TypeStatusTable } from '../../../../../../../../../../../../src/components/ui';
2
+ import { TFilters, TypeStatusTable } from '../../../../../../../../../../../../../src/components/ui';
3
3
  export interface GroupHeadingButtonItem {
4
4
  label: string;
5
5
  quantity: number;
@@ -4,7 +4,7 @@ import { TableProps } from 'antd/lib/table';
4
4
  import { InitialFiltersSearch } from '@pnkx-lib/core';
5
5
  import { MenuType } from '../Sidebar';
6
6
  import { GroupHeadingButtonItem } from './HeadingTable/components/GroupHeadingButton';
7
- import { TypeStatusTable } from '../../../../../../../../../../src/constants';
7
+ import { TypeStatusTable } from '../../../../../../../../../../../src/constants';
8
8
  interface RowCommon {
9
9
  [x: string]: any;
10
10
  }
@@ -56,3 +56,4 @@ export * from '../../constants/index';
56
56
  export * from './BulkActions';
57
57
  export * from './BreadcrumbHeading';
58
58
  export * from './Card';
59
+ export * from './ConfigProvider';
@@ -0,0 +1 @@
1
+ export declare const TINY_API = "miai0qn3c79adm555yoxd9kz6j6a323ek760nf7qd81nv1p5";
@@ -0,0 +1,2 @@
1
+ export * from './common';
2
+ export * from './table';
@@ -0,0 +1,32 @@
1
+ export declare const START_PAGE = 1;
2
+ export declare const START_PAGE_SIZE = 10;
3
+ export declare const PAGE_NUMBER = "page";
4
+ export declare const PAGE_SIZE = "size";
5
+ export declare const SORT_BY = "SortBy";
6
+ export declare const SORT_DESC = "SortDesc";
7
+ export declare enum TypeActionRowTable {
8
+ DELETE = "DELETE",
9
+ EDIT = "EDIT",
10
+ UNDO = "UNDO",
11
+ CANCELUNDO = "CANCELUNDO",
12
+ CHECKIN = "CHECKIN",
13
+ PRINT = "PRINT",
14
+ PAYMENT = "PAYMENT",
15
+ PLAY = "PLAY",
16
+ PAUSE = "PAUSE",
17
+ DOWNLOAD = "DOWNLOAD",
18
+ VIEW = "VIEW"
19
+ }
20
+ export declare enum TypeBulkActions {
21
+ BULKACTION = "bulkaction",
22
+ DROPLIST = "droplist"
23
+ }
24
+ export declare enum TypeStatusTable {
25
+ ALL = "ALL",// Tất cả
26
+ DRAFT = 0,// Tạo mới
27
+ WAITING_APPROVAL = 1,// Chờ duyệt
28
+ ACTIVE = 2,// Hoạt động
29
+ INACTIVE = 3,// Ngưng hoạt động
30
+ REJECTED = 4,// Từ chối duyệt
31
+ DELETED = 5
32
+ }
package/types/fields.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export * from './fields/index'
1
+ export * from './components/fields/index'
2
2
  export {}
@@ -0,0 +1 @@
1
+ export declare function hasFalsyFieldsObject<T extends object>(obj: T): boolean;
package/types/hooks.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export * from './hooks/index'
1
+ export * from './components/hooks/index'
2
2
  export {}
package/types/index.d.ts CHANGED
@@ -1,3 +1,2 @@
1
- export * from './ui';
2
- export * from './fields';
3
- export * from './hooks';
1
+ export * from './components/index'
2
+ export {}
@@ -0,0 +1,8 @@
1
+ export interface SelectOption {
2
+ label: string;
3
+ value: any;
4
+ }
5
+ export interface PaginationFilters {
6
+ size: number;
7
+ page: number;
8
+ }
@@ -0,0 +1,5 @@
1
+ export interface TabItem {
2
+ key: string;
3
+ label: string;
4
+ children: React.ReactNode;
5
+ }
File without changes
@@ -0,0 +1,6 @@
1
+ type TabState = {
2
+ activeTabKey?: string;
3
+ setActiveTabKey: (key: string) => void;
4
+ };
5
+ export declare const useTabStore: import('zustand').UseBoundStore<import('zustand').StoreApi<TabState>>;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { Meta, StoryObj } from '@storybook/react';
2
+ import { Input } from '../components/fields/Input';
3
+ declare const meta: Meta<typeof Input>;
4
+ export default meta;
5
+ type Story = StoryObj<typeof Input>;
6
+ export declare const Default: Story;
package/types/ui.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export * from './ui/index'
1
+ export * from './components/ui/index'
2
2
  export {}
@@ -0,0 +1,35 @@
1
+ export declare const PUBLIC_ROUTER: {
2
+ HOME: string;
3
+ SIGN_IN: string;
4
+ PAGE_404: string;
5
+ CATEGORY_LIST: {
6
+ LIST: string;
7
+ };
8
+ CATEGORY_DEMO: {
9
+ LIST: string;
10
+ DETAIL: string;
11
+ };
12
+ CATEGORY_MEDICAL_RECORD: {
13
+ LIST: string;
14
+ };
15
+ CATEGORY_CITY: {
16
+ LIST: string;
17
+ DETAIL: string;
18
+ };
19
+ CATEGORY_NATION: {
20
+ LIST: string;
21
+ DETAIL: string;
22
+ };
23
+ CATEGORY_ETHNIC: {
24
+ LIST: string;
25
+ };
26
+ CATEGORY_RELATIONSHIP: {
27
+ LIST: string;
28
+ };
29
+ CATEGORY_ATTRIBUTE: {
30
+ LIST: string;
31
+ };
32
+ CATEGORY_LOCATION: {
33
+ LIST: string;
34
+ };
35
+ };
@@ -0,0 +1,7 @@
1
+ declare class Timer {
2
+ timer: ReturnType<typeof setTimeout> | number | null;
3
+ constructor();
4
+ debounce(func: (arg: any) => void, time: number): void;
5
+ }
6
+ export declare const delay: (ms: number) => Promise<unknown>;
7
+ export default Timer;
@@ -0,0 +1 @@
1
+ /// <reference types="vite/client" />
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes