aq-fe-framework 0.1.333 → 0.1.335

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.
@@ -1,4 +1,4 @@
1
- import { I as IBaseEntity } from './IBaseEntity-CD6G-bQD.mjs';
1
+ import { I as IBaseEntity } from './IBaseEntity-BprRafT5.mjs';
2
2
 
3
3
  interface IEmailConfig extends IBaseEntity {
4
4
  emailModule?: number;
@@ -1,4 +1,4 @@
1
- import { I as IBaseEntity } from './IBaseEntity-CD6G-bQD.mjs';
1
+ import { I as IBaseEntity } from './IBaseEntity-BprRafT5.mjs';
2
2
 
3
3
  interface IAQModule extends IBaseEntity {
4
4
  officelName?: string;
@@ -1,5 +1,5 @@
1
1
  interface IBaseEntity {
2
- id: number;
2
+ id?: number;
3
3
  code?: string;
4
4
  name?: string;
5
5
  concurrencyStamp?: string;
@@ -411,12 +411,30 @@ function MyDayOfWeekPicker({ value = [], onChange }) {
411
411
  )) }) });
412
412
  }
413
413
 
414
+ // src/core/input/MySelect.tsx
415
+ import { Loader, Select } from "@mantine/core";
416
+ import { jsx as jsx9 } from "react/jsx-runtime";
417
+ function MySelect(_a) {
418
+ var _b = _a, { label, data } = _b, rest = __objRest(_b, ["label", "data"]);
419
+ const isLoading = data === void 0;
420
+ return /* @__PURE__ */ jsx9(
421
+ Select,
422
+ __spreadValues({
423
+ label,
424
+ placeholder: isLoading ? "\u0110ang t\u1EA3i..." : label ? `Ch\u1ECDn ${label.toLowerCase()}` : "",
425
+ data: data != null ? data : [],
426
+ rightSection: isLoading ? /* @__PURE__ */ jsx9(Loader, { size: "xs" }) : void 0,
427
+ disabled: isLoading
428
+ }, rest)
429
+ );
430
+ }
431
+
414
432
  // src/core/input/MyTextInput.tsx
415
433
  import { TextInput } from "@mantine/core";
416
- import { jsx as jsx9 } from "react/jsx-runtime";
434
+ import { jsx as jsx10 } from "react/jsx-runtime";
417
435
  function MyTextInput(_a) {
418
436
  var _b = _a, { label, isPhoneNumber } = _b, rest = __objRest(_b, ["label", "isPhoneNumber"]);
419
- return /* @__PURE__ */ jsx9(
437
+ return /* @__PURE__ */ jsx10(
420
438
  TextInput,
421
439
  __spreadValues({
422
440
  onKeyDown: (e) => {
@@ -457,7 +475,7 @@ import {
457
475
  } from "@mantine/core";
458
476
  import { IconPlus as IconPlus4, IconTrash as IconTrash3 } from "@tabler/icons-react";
459
477
  import { useState as useState2 } from "react";
460
- import { jsx as jsx10, jsxs as jsxs5 } from "react/jsx-runtime";
478
+ import { jsx as jsx11, jsxs as jsxs5 } from "react/jsx-runtime";
461
479
  function MyWeeklySessionSchedulerPicker({
462
480
  value = [],
463
481
  onChange
@@ -488,8 +506,8 @@ function MyWeeklySessionSchedulerPicker({
488
506
  return acc;
489
507
  }, {});
490
508
  const getLabel = (day) => enum_daysOfWeek[day] || `Day ${day}`;
491
- return /* @__PURE__ */ jsx10(Paper, { w: "100%", p: "md", children: /* @__PURE__ */ jsxs5(MyFlexColumn, { children: [
492
- /* @__PURE__ */ jsx10(Center, { children: /* @__PURE__ */ jsx10(
509
+ return /* @__PURE__ */ jsx11(Paper, { w: "100%", p: "md", children: /* @__PURE__ */ jsxs5(MyFlexColumn, { children: [
510
+ /* @__PURE__ */ jsx11(Center, { children: /* @__PURE__ */ jsx11(
493
511
  MyDayOfWeekPicker,
494
512
  {
495
513
  value: selectedDays,
@@ -499,8 +517,8 @@ function MyWeeklySessionSchedulerPicker({
499
517
  }
500
518
  }
501
519
  ) }),
502
- /* @__PURE__ */ jsx10(Divider, { my: "xs" }),
503
- /* @__PURE__ */ jsx10(Center, { children: /* @__PURE__ */ jsx10(ScrollArea.Autosize, { h: "40vh", children: /* @__PURE__ */ jsx10(MyFlexColumn, { w: { base: "100%", sm: "70%" }, children: selectedDays.map((dayOfWeek) => {
520
+ /* @__PURE__ */ jsx11(Divider, { my: "xs" }),
521
+ /* @__PURE__ */ jsx11(Center, { children: /* @__PURE__ */ jsx11(ScrollArea.Autosize, { h: "40vh", children: /* @__PURE__ */ jsx11(MyFlexColumn, { w: { base: "100%", sm: "70%" }, children: selectedDays.map((dayOfWeek) => {
504
522
  var _a;
505
523
  return /* @__PURE__ */ jsxs5(
506
524
  Paper,
@@ -510,18 +528,18 @@ function MyWeeklySessionSchedulerPicker({
510
528
  bg: const_object_colors.mantineBackgroundBlueLight,
511
529
  children: [
512
530
  /* @__PURE__ */ jsxs5(Group3, { gap: "apart", children: [
513
- /* @__PURE__ */ jsx10(Text3, { w: "70px", fw: 500, children: getLabel(dayOfWeek) }),
514
- /* @__PURE__ */ jsx10(
531
+ /* @__PURE__ */ jsx11(Text3, { w: "70px", fw: 500, children: getLabel(dayOfWeek) }),
532
+ /* @__PURE__ */ jsx11(
515
533
  Button5,
516
534
  {
517
535
  color: "teal.5",
518
- leftSection: /* @__PURE__ */ jsx10(IconPlus4, { size: 14 }),
536
+ leftSection: /* @__PURE__ */ jsx11(IconPlus4, { size: 14 }),
519
537
  onClick: () => handleAddSession(dayOfWeek),
520
538
  children: "Th\xEAm bu\u1ED5i"
521
539
  }
522
540
  )
523
541
  ] }),
524
- /* @__PURE__ */ jsx10(Divider, { my: "sm" }),
542
+ /* @__PURE__ */ jsx11(Divider, { my: "sm" }),
525
543
  (_a = grouped[dayOfWeek]) == null ? void 0 : _a.map((item, indexInDay) => {
526
544
  const globalIndex = value.findIndex(
527
545
  (v) => v === item
@@ -533,7 +551,7 @@ function MyWeeklySessionSchedulerPicker({
533
551
  gap: "xs",
534
552
  align: "flex-end",
535
553
  children: [
536
- /* @__PURE__ */ jsx10(
554
+ /* @__PURE__ */ jsx11(
537
555
  NumberInput,
538
556
  {
539
557
  label: "Ti\u1EBFt b\u1EAFt \u0111\u1EA7u",
@@ -545,7 +563,7 @@ function MyWeeklySessionSchedulerPicker({
545
563
  )
546
564
  }
547
565
  ),
548
- /* @__PURE__ */ jsx10(
566
+ /* @__PURE__ */ jsx11(
549
567
  NumberInput,
550
568
  {
551
569
  label: "S\u1ED1 ti\u1EBFt",
@@ -557,7 +575,7 @@ function MyWeeklySessionSchedulerPicker({
557
575
  )
558
576
  }
559
577
  ),
560
- /* @__PURE__ */ jsx10(
578
+ /* @__PURE__ */ jsx11(
561
579
  NumberInput,
562
580
  {
563
581
  label: "S\u1ED1 ph\xFAt ",
@@ -566,13 +584,13 @@ function MyWeeklySessionSchedulerPicker({
566
584
  value: item.durationMinutes
567
585
  }
568
586
  ),
569
- /* @__PURE__ */ jsx10(
587
+ /* @__PURE__ */ jsx11(
570
588
  Button5,
571
589
  {
572
590
  variant: "light",
573
591
  color: "red",
574
592
  onClick: () => handleRemove(globalIndex),
575
- leftSection: /* @__PURE__ */ jsx10(IconTrash3, { size: 14 }),
593
+ leftSection: /* @__PURE__ */ jsx11(IconTrash3, { size: 14 }),
576
594
  children: "X\xF3a bu\u1ED5i"
577
595
  }
578
596
  )
@@ -591,10 +609,10 @@ function MyWeeklySessionSchedulerPicker({
591
609
 
592
610
  // src/core/layout/MyFlexColumn.tsx
593
611
  import { Flex } from "@mantine/core";
594
- import { jsx as jsx11 } from "react/jsx-runtime";
612
+ import { jsx as jsx12 } from "react/jsx-runtime";
595
613
  function MyFlexColumn2(_a) {
596
614
  var _b = _a, { children } = _b, rest = __objRest(_b, ["children"]);
597
- return /* @__PURE__ */ jsx11(Flex, __spreadProps(__spreadValues({ direction: "column", gap: "md" }, rest), { children }));
615
+ return /* @__PURE__ */ jsx12(Flex, __spreadProps(__spreadValues({ direction: "column", gap: "md" }, rest), { children }));
598
616
  }
599
617
 
600
618
  export {
@@ -606,6 +624,7 @@ export {
606
624
  MyLabelValueRow,
607
625
  MyStatsCard,
608
626
  MyDayOfWeekPicker,
627
+ MySelect,
609
628
  MyTextInput,
610
629
  MyWeeklySessionSchedulerPicker,
611
630
  MyFlexColumn2 as MyFlexColumn
@@ -1,4 +1,4 @@
1
- import { I as IBaseEntity } from '../IBaseEntity-CD6G-bQD.mjs';
1
+ import { I as IBaseEntity } from '../IBaseEntity-BprRafT5.mjs';
2
2
  import { MRT_ColumnDef } from 'mantine-react-table';
3
3
 
4
4
  declare const baseColumns: MRT_ColumnDef<IBaseEntity>[];
@@ -2,7 +2,7 @@ import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
  import React$1, { ReactNode, ComponentProps } from 'react';
3
3
  import { t as type_action, T as TYPES_MANTINE_SIZE } from '../types-B5rmBuXz.mjs';
4
4
  import { ActionIconProps, ButtonProps, useModalsStack, CheckboxProps, SelectProps, NumberFormatterProps, FieldsetProps, FileInputProps, NumberInputProps, TextareaProps, MantineSize, InputWrapperProps, TextInputProps, ContainerProps, FlexProps, GroupProps, TypographyStylesProviderProps, TabsProps, SkeletonProps } from '@mantine/core';
5
- import { M as MyApiResponse } from '../createBaseApi-Bdh5kQ7-.mjs';
5
+ import { M as MyApiResponse } from '../createBaseApi-D9OK2lA_.mjs';
6
6
  import { AxiosResponse } from 'axios';
7
7
  import { useDisclosure, useListState } from '@mantine/hooks';
8
8
  import { UseFormReturnType, useForm } from '@mantine/form';
@@ -16,7 +16,7 @@ import { RichTextEditorProps } from '@mantine/tiptap';
16
16
  import { EditorOptions } from '@tiptap/react';
17
17
  import { IconProps, Icon } from '@tabler/icons-react';
18
18
  import { CalendarEventExternal } from '@schedule-x/calendar';
19
- import '../IBaseEntity-CD6G-bQD.mjs';
19
+ import '../IBaseEntity-BprRafT5.mjs';
20
20
  import 'exceljs';
21
21
 
22
22
  declare const MyBoxesCore: ({ className, ...rest }: {
@@ -1,14 +1,14 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
  import { t as type_action } from '../types-B5rmBuXz.mjs';
3
- import { ActionIconProps, ButtonProps, ModalProps, TextProps, GroupProps, ThemeIconProps, TextInputProps, FlexProps } from '@mantine/core';
3
+ import { ActionIconProps, ButtonProps, ModalProps, TextProps, GroupProps, ThemeIconProps, SelectProps, TextInputProps, FlexProps } from '@mantine/core';
4
4
  import { ReactNode } from 'react';
5
- import { M as MyApiResponse } from '../createBaseApi-Bdh5kQ7-.mjs';
5
+ import { M as MyApiResponse } from '../createBaseApi-D9OK2lA_.mjs';
6
6
  import { AxiosResponse } from 'axios';
7
7
  import { UseFormReturnType } from '@mantine/form';
8
8
  import { useDisclosure } from '@mantine/hooks';
9
9
  import { UseQueryResult } from '@tanstack/react-query';
10
10
  import { MRT_RowData, MRT_ColumnDef } from 'mantine-react-table';
11
- import '../IBaseEntity-CD6G-bQD.mjs';
11
+ import '../IBaseEntity-BprRafT5.mjs';
12
12
 
13
13
  interface CoreActionIconProps extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, "color" | "style">, ActionIconProps {
14
14
  actionType?: type_action;
@@ -77,6 +77,15 @@ interface CoreDayOfWeekPickerProps {
77
77
  }
78
78
  declare function MyDayOfWeekPicker({ value, onChange }: CoreDayOfWeekPickerProps): react_jsx_runtime.JSX.Element;
79
79
 
80
+ interface MySelectProps extends SelectProps {
81
+ label?: string;
82
+ data?: Array<string | {
83
+ value: string;
84
+ label: string;
85
+ }>;
86
+ }
87
+ declare function MySelect({ label, data, ...rest }: MySelectProps): react_jsx_runtime.JSX.Element;
88
+
80
89
  interface CoreTextInputProps extends TextInputProps {
81
90
  label?: string;
82
91
  defaultValue?: string;
@@ -101,4 +110,4 @@ interface IMyFlexColumn extends FlexProps {
101
110
  }
102
111
  declare function MyFlexColumn({ children, ...rest }: IMyFlexColumn): react_jsx_runtime.JSX.Element;
103
112
 
104
- export { type IWeeklySession, MyActionIcon, MyButton, MyButtonCreateUpdate, MyButtonModal, MyDataTableSelectOne, MyDayOfWeekPicker, MyFlexColumn, MyLabelValueRow, MyStatsCard, MyTextInput, MyWeeklySessionSchedulerPicker, type WeeklySessionSchedulerProps };
113
+ export { type IWeeklySession, MyActionIcon, MyButton, MyButtonCreateUpdate, MyButtonModal, MyDataTableSelectOne, MyDayOfWeekPicker, MyFlexColumn, MyLabelValueRow, MySelect, MyStatsCard, MyTextInput, MyWeeklySessionSchedulerPicker, type WeeklySessionSchedulerProps };
@@ -7,10 +7,11 @@ import {
7
7
  MyDayOfWeekPicker,
8
8
  MyFlexColumn,
9
9
  MyLabelValueRow,
10
+ MySelect,
10
11
  MyStatsCard,
11
12
  MyTextInput,
12
13
  MyWeeklySessionSchedulerPicker
13
- } from "../chunk-WXLN7SEF.mjs";
14
+ } from "../chunk-SIHFFLRO.mjs";
14
15
  import "../chunk-GEYCGM75.mjs";
15
16
  import "../chunk-NWBLJ3W3.mjs";
16
17
  import "../chunk-K6S7R6LU.mjs";
@@ -26,6 +27,7 @@ export {
26
27
  MyDayOfWeekPicker,
27
28
  MyFlexColumn,
28
29
  MyLabelValueRow,
30
+ MySelect,
29
31
  MyStatsCard,
30
32
  MyTextInput,
31
33
  MyWeeklySessionSchedulerPicker
@@ -1,6 +1,6 @@
1
1
  import * as axios from 'axios';
2
2
  import { AxiosInstance } from 'axios';
3
- import { I as IBaseEntity } from './IBaseEntity-CD6G-bQD.mjs';
3
+ import { I as IBaseEntity } from './IBaseEntity-BprRafT5.mjs';
4
4
 
5
5
  interface IPagingParams {
6
6
  pageNumber?: number;
@@ -1,11 +1,11 @@
1
1
  import * as next_dist_shared_lib_app_router_context_shared_runtime from 'next/dist/shared/lib/app-router-context.shared-runtime';
2
- import { M as MyApiResponse } from '../createBaseApi-Bdh5kQ7-.mjs';
3
- export { I as IPagingParams, c as createBaseApi } from '../createBaseApi-Bdh5kQ7-.mjs';
2
+ import { M as MyApiResponse } from '../createBaseApi-D9OK2lA_.mjs';
3
+ export { I as IPagingParams, c as createBaseApi } from '../createBaseApi-D9OK2lA_.mjs';
4
4
  import { AxiosInstance, AxiosResponse } from 'axios';
5
5
  import * as _tanstack_react_query from '@tanstack/react-query';
6
6
  import { UseMutationOptions, QueryKey, UseQueryOptions } from '@tanstack/react-query';
7
- import { I as IAQModule } from '../IAQModule-kmLY5UWG.mjs';
8
- import '../IBaseEntity-CD6G-bQD.mjs';
7
+ import { I as IAQModule } from '../IAQModule-DfONsRwE.mjs';
8
+ import '../IBaseEntity-BprRafT5.mjs';
9
9
 
10
10
  declare function useMyDevice(): {
11
11
  isMobile: boolean | undefined;
@@ -1,6 +1,10 @@
1
- export { I as IEmailConfig } from '../EmailConfig-CVG1cFdX.mjs';
2
- export { I as IAQModule } from '../IAQModule-kmLY5UWG.mjs';
3
- import { I as IBaseEntity } from '../IBaseEntity-CD6G-bQD.mjs';
1
+ export { I as IEmailConfig } from '../EmailConfig-Bza2PzTi.mjs';
2
+ export { I as IAQModule } from '../IAQModule-DfONsRwE.mjs';
3
+ import { I as IBaseEntity } from '../IBaseEntity-BprRafT5.mjs';
4
+
5
+ interface IPageContent extends IBaseEntity {
6
+ description?: string;
7
+ }
4
8
 
5
9
  interface IFile {
6
10
  fileName?: string | undefined;
@@ -51,8 +55,4 @@ interface IUser extends IBaseEntity {
51
55
  email?: string;
52
56
  }
53
57
 
54
- interface IPageContent extends IBaseEntity {
55
- description?: string;
56
- }
57
-
58
58
  export { IBaseEntity, type IDocument, type IFile, type IPageContent, type IPagePermission, type IRole, type IUser };
@@ -1,9 +1,9 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
  import { I as I_BasicAppShell_LinkItem } from '../BasicAppShell-CGKvZ5wV.mjs';
3
- import { I as IBaseEntity } from '../IBaseEntity-CD6G-bQD.mjs';
3
+ import { I as IBaseEntity } from '../IBaseEntity-BprRafT5.mjs';
4
4
  import { SelectProps, ButtonProps } from '@mantine/core';
5
- import { I as IEmailConfig } from '../EmailConfig-CVG1cFdX.mjs';
6
- import { I as IAQModule } from '../IAQModule-kmLY5UWG.mjs';
5
+ import { I as IEmailConfig } from '../EmailConfig-Bza2PzTi.mjs';
6
+ import { I as IAQModule } from '../IAQModule-DfONsRwE.mjs';
7
7
  import { ReactNode } from 'react';
8
8
 
9
9
  declare function F_accessControl({ menuData }: {
@@ -41,11 +41,14 @@ import "../chunk-5U2JSHSJ.mjs";
41
41
  import {
42
42
  const_object_documentTypes
43
43
  } from "../chunk-BZMQOGL6.mjs";
44
+ import {
45
+ enum_emailConfigModule
46
+ } from "../chunk-VH4ZAD6M.mjs";
44
47
  import {
45
48
  MyButton as MyButton2,
46
49
  MyDataTableSelectOne,
47
50
  MyTextInput as MyTextInput2
48
- } from "../chunk-WXLN7SEF.mjs";
51
+ } from "../chunk-SIHFFLRO.mjs";
49
52
  import {
50
53
  MyDataTable,
51
54
  MyFlexColumn,
@@ -54,9 +57,6 @@ import {
54
57
  import {
55
58
  const_object_colors
56
59
  } from "../chunk-NWBLJ3W3.mjs";
57
- import {
58
- enum_emailConfigModule
59
- } from "../chunk-VH4ZAD6M.mjs";
60
60
  import "../chunk-K6S7R6LU.mjs";
61
61
  import {
62
62
  baseAxios_default,
package/package.json CHANGED
@@ -42,7 +42,7 @@
42
42
  "types": "./dist/columns/index.d.mts"
43
43
  }
44
44
  },
45
- "version": "0.1.333",
45
+ "version": "0.1.335",
46
46
  "private": false,
47
47
  "files": [
48
48
  "dist"