erp-pos-ecommerce-shared 0.2.13 → 0.2.14
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/components.js +10 -5
- package/dist/components.js.map +1 -1
- package/dist/hooks.d.ts +7 -1
- package/dist/hooks.js +8 -1
- package/dist/hooks.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +11 -6
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/components.js
CHANGED
|
@@ -9,7 +9,7 @@ import { modals } from '@mantine/modals';
|
|
|
9
9
|
import { notifications } from '@mantine/notifications';
|
|
10
10
|
import { jsxs, Fragment, jsx } from 'react/jsx-runtime';
|
|
11
11
|
import * as z from 'zod';
|
|
12
|
-
import { useMediaQuery } from '@mantine/hooks';
|
|
12
|
+
import { useMediaQuery as useMediaQuery$1 } from '@mantine/hooks';
|
|
13
13
|
import { flexRender, useReactTable, getSortedRowModel, getPaginationRowModel, getCoreRowModel } from '@tanstack/react-table';
|
|
14
14
|
import { ArrowDown, ArrowUp, ArrowUpDown, FileX, X, Search, ChevronUp, ChevronDown, ListFilter, Check, CalendarDays, MoreVertical } from 'lucide-react';
|
|
15
15
|
|
|
@@ -1108,6 +1108,12 @@ var barTextActive = "light-dark(#111827, var(--mantine-color-dark-0))";
|
|
|
1108
1108
|
var defaultHeaderBgColor = "light-dark(var(--mantine-color-gray-0), var(--mantine-color-dark-6))";
|
|
1109
1109
|
var paginationBorder = "light-dark(#e5e5e5, var(--mantine-color-dark-4))";
|
|
1110
1110
|
var paginationSurface = "light-dark(var(--mantine-color-white), var(--mantine-color-dark-6))";
|
|
1111
|
+
var useMediaQuery = () => {
|
|
1112
|
+
const isMobile = useMediaQuery$1("(max-width: 767px)");
|
|
1113
|
+
const isDesktop = useMediaQuery$1("(min-width: 992px)");
|
|
1114
|
+
const isTablet = useMediaQuery$1("(min-width: 768px) and (max-width: 991px)");
|
|
1115
|
+
return { isMobile, isDesktop, isTablet };
|
|
1116
|
+
};
|
|
1111
1117
|
var BottomPagination = ({
|
|
1112
1118
|
total,
|
|
1113
1119
|
pageSize,
|
|
@@ -1115,8 +1121,7 @@ var BottomPagination = ({
|
|
|
1115
1121
|
onPageSizeChange,
|
|
1116
1122
|
onPageIndexChange
|
|
1117
1123
|
}) => {
|
|
1118
|
-
const isMobile = useMediaQuery(
|
|
1119
|
-
const isDesktop = useMediaQuery("(min-width: 992px)");
|
|
1124
|
+
const { isMobile, isDesktop } = useMediaQuery();
|
|
1120
1125
|
const totalPages = Math.ceil(total / pageSize);
|
|
1121
1126
|
const currentPage = pageIndex + 1;
|
|
1122
1127
|
const handlePageChange = (page) => {
|
|
@@ -1824,7 +1829,7 @@ var FilterSelect = ({
|
|
|
1824
1829
|
children: selectedOption ? selectedOption.label : placeholder
|
|
1825
1830
|
}
|
|
1826
1831
|
) }),
|
|
1827
|
-
/* @__PURE__ */ jsxs(Menu.Dropdown, { style: { boxShadow: "0 0 10px 0 rgba(0, 0, 0, 0.1)" }, children: [
|
|
1832
|
+
/* @__PURE__ */ jsxs(Menu.Dropdown, { style: { boxShadow: "0 0 10px 0 rgba(0, 0, 0, 0.1)", borderRadius: "8px" }, children: [
|
|
1828
1833
|
searchable && /* @__PURE__ */ jsx(
|
|
1829
1834
|
TextInput,
|
|
1830
1835
|
{
|
|
@@ -1836,7 +1841,7 @@ var FilterSelect = ({
|
|
|
1836
1841
|
onChange: (e) => setSearch(e.currentTarget.value)
|
|
1837
1842
|
}
|
|
1838
1843
|
),
|
|
1839
|
-
/* @__PURE__ */ jsx(ScrollArea, {
|
|
1844
|
+
/* @__PURE__ */ jsx(ScrollArea, { mah: 240, scrollbars: "y", type: "always", children: filteredOptions.map((option) => /* @__PURE__ */ jsx(
|
|
1840
1845
|
Menu.Item,
|
|
1841
1846
|
{
|
|
1842
1847
|
leftSection: selectedOption?.value === option.value ? /* @__PURE__ */ jsx(Check, { size: 12 }) : null,
|