qaema-ui 0.0.27 → 0.0.29
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/_virtual/index2.js +4 -4
- package/dist/_virtual/index3.js +4 -4
- package/dist/_virtual/index4.js +4 -4
- package/dist/assets/icons/RiyalIcon.d.ts +1 -1
- package/dist/components/AccordionCard.d.ts +1 -1
- package/dist/components/ActionInput.d.ts +2 -2
- package/dist/components/AddOnCardInput.d.ts +2 -2
- package/dist/components/Alert.d.ts +1 -1
- package/dist/components/AmountItem.d.ts +2 -2
- package/dist/components/Badge.d.ts +3 -3
- package/dist/components/Button.d.ts +3 -2
- package/dist/components/Card.d.ts +1 -1
- package/dist/components/CardsList.d.ts +2 -2
- package/dist/components/Chart.d.ts +1 -1
- package/dist/components/ChartLegend/ChartLegend.d.ts +2 -2
- package/dist/components/ChartLegend/ChartLegend.js +8 -7
- package/dist/components/ChartLegend/PieChartLegend.d.ts +1 -1
- package/dist/components/ChartLegend/styles.d.ts +5 -5
- package/dist/components/CollapsableCard.d.ts +1 -1
- package/dist/components/ConfigList.d.ts +1 -1
- package/dist/components/ConfirmationPopup.d.ts +1 -1
- package/dist/components/DatePicker.d.ts +1 -1
- package/dist/components/DatePicker.js +1 -1
- package/dist/components/Divider.d.ts +2 -2
- package/dist/components/Draggable.d.ts +1 -1
- package/dist/components/DropDown.d.ts +1 -1
- package/dist/components/DropDownWithTable/DropDownWithTable.d.ts +1 -1
- package/dist/components/DropDownWithTable/DropDownWithTable.types.d.ts +1 -1
- package/dist/components/DropDownWithTable/Table/Table.d.ts +1 -1
- package/dist/components/DropDownWithTable/Table/Table.js +66 -66
- package/dist/components/DropDownWithTable/Table/Table.styles.d.ts +27 -27
- package/dist/components/DropDownWithTable/Table/components/CellComponents.d.ts +6 -6
- package/dist/components/DropDownWithTable/Table/components/CellComponents.js +82 -82
- package/dist/components/DropDownWithTable/Table/components/TableHead.d.ts +1 -1
- package/dist/components/FileDownloadCard.d.ts +1 -1
- package/dist/components/Filter.d.ts +14 -14
- package/dist/components/FilterActiveBar.d.ts +1 -1
- package/dist/components/Header.d.ts +3 -2
- package/dist/components/HelpCard.d.ts +2 -2
- package/dist/components/Hint.d.ts +2 -2
- package/dist/components/HorizontalChart.d.ts +2 -2
- package/dist/components/Image.d.ts +2 -2
- package/dist/components/InfoCard.d.ts +1 -1
- package/dist/components/InfoItem.d.ts +1 -1
- package/dist/components/InputField.d.ts +2 -2
- package/dist/components/Layout.d.ts +4 -3
- package/dist/components/Legend.d.ts +1 -1
- package/dist/components/Link.d.ts +1 -1
- package/dist/components/ListToolbar.d.ts +5 -5
- package/dist/components/MethodCard.d.ts +1 -1
- package/dist/components/Modal.d.ts +2 -2
- package/dist/components/ModalWithRequestCard.d.ts +2 -2
- package/dist/components/NavItem.d.ts +2 -2
- package/dist/components/NavigationPanel.d.ts +2 -2
- package/dist/components/NextActionBox.d.ts +1 -1
- package/dist/components/NextActionBox.js +104 -0
- package/dist/components/NumberInput.d.ts +1 -1
- package/dist/components/OTP.d.ts +1 -1
- package/dist/components/OptionCardGroup.d.ts +2 -2
- package/dist/components/OptionCardGroup.js +16 -15
- package/dist/components/Pagination.d.ts +1 -1
- package/dist/components/PasswordInputField.d.ts +2 -2
- package/dist/components/PaymentLinkDetails.d.ts +1 -1
- package/dist/components/PaymentTooltip.d.ts +2 -2
- package/dist/components/PhoneInputField.d.ts +2 -2
- package/dist/components/QuickActionItem.d.ts +2 -2
- package/dist/components/QuickStartCard.d.ts +4 -4
- package/dist/components/RadioInput.d.ts +1 -1
- package/dist/components/ReconciliationGroups.d.ts +1 -1
- package/dist/components/RequestCard.d.ts +7 -7
- package/dist/components/RequestSummaryCard.d.ts +6 -6
- package/dist/components/SectionHeader.d.ts +1 -1
- package/dist/components/SideMenuLinks.d.ts +1 -1
- package/dist/components/Sidemenu.d.ts +2 -2
- package/dist/components/Spinner.d.ts +1 -1
- package/dist/components/StatCard.d.ts +1 -1
- package/dist/components/StatIndicator.d.ts +1 -1
- package/dist/components/StatusFeedback.d.ts +2 -2
- package/dist/components/StepperProcess.d.ts +391 -571
- package/dist/components/SummaryCard.d.ts +1 -1
- package/dist/components/Table/Table.d.ts +1 -1
- package/dist/components/Table/Table.styles.d.ts +27 -27
- package/dist/components/Table/components/CellComponents.d.ts +6 -6
- package/dist/components/Table/components/TableHead.d.ts +1 -1
- package/dist/components/Tabs.d.ts +1 -1
- package/dist/components/TextArea.d.ts +1 -1
- package/dist/components/ThemeProvider.d.ts +2 -2
- package/dist/components/ToastNotification.d.ts +2 -2
- package/dist/components/Toggle.d.ts +2 -2
- package/dist/components/ToggleForm.d.ts +2 -2
- package/dist/components/Typography.d.ts +3 -3
- package/dist/components/index.d.ts +1 -1
- package/dist/hooks/useFormikInput.d.ts +11 -11
- package/dist/hooks/useTypographyVariant.d.ts +1 -1
- package/dist/i18n/i18n.d.ts +3 -3
- package/dist/index.js +173 -171
- package/dist/node_modules/@react-spring/core/dist/react-spring_core.modern.js +1 -1
- package/dist/node_modules/@restart/ui/esm/ImperativeTransition.js +1 -0
- package/dist/node_modules/d3-format/src/defaultLocale.js +4 -3
- package/dist/node_modules/d3-format/src/formatDecimal.js +4 -4
- package/dist/node_modules/d3-format/src/formatPrefixAuto.js +5 -5
- package/dist/node_modules/d3-format/src/locale.js +37 -37
- package/dist/node_modules/d3-shape/src/symbol/circle.js +3 -3
- package/dist/node_modules/d3-time-format/src/defaultLocale.js +6 -5
- package/dist/node_modules/d3-time-format/src/locale.js +14 -14
- package/dist/node_modules/date-fns/addDays.js +3 -2
- package/dist/node_modules/date-fns/addMonths.js +9 -8
- package/dist/node_modules/date-fns/constructFrom.js +2 -1
- package/dist/node_modules/date-fns/differenceInCalendarDays.js +3 -2
- package/dist/node_modules/date-fns/endOfMonth.js +4 -3
- package/dist/node_modules/date-fns/endOfWeek.js +5 -4
- package/dist/node_modules/date-fns/format.js +1 -0
- package/dist/node_modules/date-fns/getDayOfYear.js +4 -3
- package/dist/node_modules/date-fns/getDaysInMonth.js +6 -5
- package/dist/node_modules/date-fns/getDefaultOptions.js +3 -2
- package/dist/node_modules/date-fns/getISODay.js +6 -5
- package/dist/node_modules/date-fns/getISOWeek.js +5 -4
- package/dist/node_modules/date-fns/getISOWeekYear.js +1 -0
- package/dist/node_modules/date-fns/getWeek.js +6 -5
- package/dist/node_modules/date-fns/getWeekYear.js +1 -0
- package/dist/node_modules/date-fns/getYear.js +3 -2
- package/dist/node_modules/date-fns/isAfter.js +3 -2
- package/dist/node_modules/date-fns/isBefore.js +4 -3
- package/dist/node_modules/date-fns/isDate.js +1 -0
- package/dist/node_modules/date-fns/isSameDay.js +9 -8
- package/dist/node_modules/date-fns/isSameMonth.js +6 -5
- package/dist/node_modules/date-fns/isValid.js +5 -4
- package/dist/node_modules/date-fns/locale/ar-SA.js +7 -6
- package/dist/node_modules/date-fns/locale/en-US.js +9 -8
- package/dist/node_modules/date-fns/parse.js +11 -10
- package/dist/node_modules/date-fns/setDay.js +7 -6
- package/dist/node_modules/date-fns/setISODay.js +4 -3
- package/dist/node_modules/date-fns/setISOWeek.js +5 -4
- package/dist/node_modules/date-fns/setMonth.js +6 -5
- package/dist/node_modules/date-fns/setWeek.js +4 -3
- package/dist/node_modules/date-fns/setYear.js +5 -4
- package/dist/node_modules/date-fns/startOfDay.js +5 -4
- package/dist/node_modules/date-fns/startOfISOWeek.js +3 -2
- package/dist/node_modules/date-fns/startOfISOWeekYear.js +6 -5
- package/dist/node_modules/date-fns/startOfMonth.js +1 -0
- package/dist/node_modules/date-fns/startOfWeek.js +8 -7
- package/dist/node_modules/date-fns/startOfWeekYear.js +5 -4
- package/dist/node_modules/date-fns/startOfYear.js +1 -0
- package/dist/node_modules/date-fns/subMonths.js +4 -3
- package/dist/node_modules/date-fns/toDate.js +4 -3
- package/dist/node_modules/date-fns/transpose.js +3 -2
- package/dist/node_modules/fast-equals/dist/esm/index.js +298 -0
- package/dist/node_modules/react-bootstrap/esm/CloseButton.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/Feedback.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/Form.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/Image.js +1 -1
- package/dist/node_modules/react-helmet-async/lib/index.esm.js +2 -2
- package/dist/node_modules/react-smooth/es6/Animate.js +2 -2
- package/dist/node_modules/react-transition-group/esm/Transition.js +1 -1
- package/dist/node_modules/react-transition-group/esm/utils/PropTypes.js +1 -1
- package/dist/node_modules/recharts/es6/component/Cursor.js +2 -2
- package/dist/node_modules/recharts/es6/util/ChartUtils.js +2 -2
- package/dist/node_modules/recharts-scale/es6/getNiceTickValues.js +7 -7
- package/dist/node_modules/victory-vendor/es/d3-scale.js +40 -40
- package/dist/styles/Currency.styles.d.ts +1 -1
- package/dist/styles/Dropdown.styles.d.ts +30 -30
- package/dist/styles/Input.styles.d.ts +1 -1
- package/dist/styles/Scrollbar.styles.d.ts +1 -1
- package/dist/styles/StatusFeedback.styles.d.ts +7 -7
- package/dist/theme/theme.d.ts +1 -1
- package/package.json +2 -3
- package/dist/i18n/locales/ar.json.d.ts +0 -55
- package/dist/i18n/locales/en.json.d.ts +0 -55
- package/dist/node_modules/fast-equals/dist/es/index.js +0 -324
- package/dist/theme/styled-components.d.ts +0 -5
package/dist/_virtual/index2.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { getDefaultExportFromCjs as r } from "./_commonjsHelpers.js";
|
|
2
|
-
import { __require as
|
|
3
|
-
var
|
|
4
|
-
const
|
|
2
|
+
import { __require as t } from "../node_modules/react-helmet-async/node_modules/react-fast-compare/index.js";
|
|
3
|
+
var a = t();
|
|
4
|
+
const m = /* @__PURE__ */ r(a);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
m as default
|
|
7
7
|
};
|
package/dist/_virtual/index3.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { getDefaultExportFromCjs as r } from "./_commonjsHelpers.js";
|
|
2
|
-
import { __require as
|
|
3
|
-
var a =
|
|
4
|
-
const
|
|
2
|
+
import { __require as o } from "../node_modules/shallowequal/index.js";
|
|
3
|
+
var a = o();
|
|
4
|
+
const t = /* @__PURE__ */ r(a);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
t as default
|
|
7
7
|
};
|
package/dist/_virtual/index4.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { getDefaultExportFromCjs as r } from "./_commonjsHelpers.js";
|
|
2
|
-
import { __require as o } from "../node_modules/
|
|
3
|
-
var
|
|
4
|
-
const
|
|
2
|
+
import { __require as o } from "../node_modules/prop-types/index.js";
|
|
3
|
+
var p = /* @__PURE__ */ o();
|
|
4
|
+
const s = /* @__PURE__ */ r(p);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
s as default
|
|
7
7
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { AmountCellData, CellType } from './Table/Table.types';
|
|
2
|
-
import { TypographyProps } from './Typography';
|
|
1
|
+
import type { AmountCellData, CellType } from './Table/Table.types';
|
|
2
|
+
import { type TypographyProps } from './Typography';
|
|
3
3
|
type AmountItemProps = {
|
|
4
4
|
data: AmountCellData;
|
|
5
5
|
type?: CellType;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { ReactNode } from 'react';
|
|
2
|
-
import { BadgeVariant } from '
|
|
3
|
-
import { FontWeight } from '
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import { type BadgeVariant } from '@hooks/useBadgeVariant';
|
|
3
|
+
import type { FontWeight } from '@theme/theme';
|
|
4
4
|
export type BadgeProps = {
|
|
5
5
|
bgColor?: string;
|
|
6
6
|
color?: string;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { ReactNode } from 'react';
|
|
3
|
+
import { type ButtonVariant } from '@hooks/useButtonVariant';
|
|
3
4
|
type ButtonSize = 'xxs' | 'xs' | 'sm' | 'md' | 'lg';
|
|
4
5
|
type ButtonType = 'button' | 'submit' | 'reset';
|
|
5
6
|
export type ButtonProps = {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { ButtonVariant } from 'react-bootstrap/esm/types';
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { ButtonVariant } from 'react-bootstrap/esm/types';
|
|
3
3
|
type cardListItem = {
|
|
4
4
|
primaryButtonTitle: string;
|
|
5
5
|
primaryButtonOnClick?: (item: cardListItem) => void;
|
|
@@ -1,27 +1,28 @@
|
|
|
1
1
|
import { j as e } from "../../_virtual/jsx-runtime.js";
|
|
2
2
|
import "react";
|
|
3
|
-
import { useTheme as
|
|
3
|
+
import { useTheme as c } from "styled-components";
|
|
4
4
|
import h from "../../assets/svg/Riyal.svg.js";
|
|
5
5
|
import g from "../Image.js";
|
|
6
6
|
import i from "../Typography.js";
|
|
7
7
|
import { StyledLegendContainer as p, LegendRow as x, LegendName as j, LegendValue as u } from "./styles.js";
|
|
8
|
-
const C = ({ yColor:
|
|
9
|
-
const
|
|
8
|
+
const C = ({ yColor: s, yyColor: m, legendItems: n }) => {
|
|
9
|
+
const o = c();
|
|
10
10
|
if (n && n.length)
|
|
11
11
|
return /* @__PURE__ */ e.jsx(p, { children: n.map((r, t) => {
|
|
12
|
-
const l = r.showRiyal ?? !0, a = r.value,
|
|
12
|
+
const l = r.showRiyal ?? !0, a = r.value, d = r.color ?? (t === 1 ? m ?? s : s);
|
|
13
13
|
return /* @__PURE__ */ e.jsxs(x, { children: [
|
|
14
14
|
/* @__PURE__ */ e.jsxs(j, { children: [
|
|
15
|
-
/* @__PURE__ */ e.jsx("span", { className: "legend-dot", style: { background:
|
|
15
|
+
/* @__PURE__ */ e.jsx("span", { className: "legend-dot", style: { background: d } }),
|
|
16
16
|
/* @__PURE__ */ e.jsx(i, { variant: "mdText", weight: "semiBold", children: r.name })
|
|
17
17
|
] }),
|
|
18
18
|
/* @__PURE__ */ e.jsx(u, { children: a && /* @__PURE__ */ e.jsxs(e.Fragment, { children: [
|
|
19
|
-
l && /* @__PURE__ */ e.jsx(g, { src: h, style: { verticalAlign: "middle" }, width:
|
|
19
|
+
l && /* @__PURE__ */ e.jsx(g, { src: h, style: { verticalAlign: "middle" }, width: o.spacing.sm, height: o.spacing.sm }),
|
|
20
20
|
/* @__PURE__ */ e.jsx(i, { variant: "mdText", children: a })
|
|
21
21
|
] }) })
|
|
22
22
|
] }, `${r.name}-${t}`);
|
|
23
23
|
}) });
|
|
24
24
|
};
|
|
25
25
|
export {
|
|
26
|
-
C as ChartLegend
|
|
26
|
+
C as ChartLegend,
|
|
27
|
+
C as default
|
|
27
28
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export declare const StyledLegendContainer: import(
|
|
2
|
-
export declare const PieLegendContainer: import(
|
|
3
|
-
export declare const LegendRow: import(
|
|
4
|
-
export declare const LegendName: import(
|
|
5
|
-
export declare const LegendValue: import(
|
|
1
|
+
export declare const StyledLegendContainer: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
2
|
+
export declare const PieLegendContainer: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
3
|
+
export declare const LegendRow: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
4
|
+
export declare const LegendName: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, never>> & string;
|
|
5
|
+
export declare const LegendValue: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
@@ -4,7 +4,7 @@ import { useTranslation as te } from "react-i18next";
|
|
|
4
4
|
import { FaRegCalendarAlt as oe, FaAngleDown as ne, FaAngleLeft as se } from "../node_modules/react-icons/fa/index.js";
|
|
5
5
|
import i, { useTheme as ie } from "styled-components";
|
|
6
6
|
import ae from "./Hint.js";
|
|
7
|
-
import {
|
|
7
|
+
import { formatDate as b } from "../node_modules/date-fns/format.js";
|
|
8
8
|
import { parse as le } from "../node_modules/date-fns/parse.js";
|
|
9
9
|
import { isBefore as L } from "../node_modules/date-fns/isBefore.js";
|
|
10
10
|
import { isAfter as z } from "../node_modules/date-fns/isAfter.js";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export type DividerProps = {
|
|
2
2
|
marginVertical?: string;
|
|
3
3
|
};
|
|
4
|
-
declare const Divider: import(
|
|
5
|
-
ref?: ((instance: HTMLDivElement | null) => void | import(
|
|
4
|
+
declare const Divider: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("styled-components/dist/types").Substitute<import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
|
|
5
|
+
ref?: ((instance: HTMLDivElement | null) => void | import("react").DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof import("react").DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | import("react").RefObject<HTMLDivElement> | null | undefined;
|
|
6
6
|
}>, DividerProps>, DividerProps>> & string;
|
|
7
7
|
export default Divider;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { DropDownWithTableProps } from './DropDownWithTable.types';
|
|
1
|
+
import type { DropDownWithTableProps } from './DropDownWithTable.types';
|
|
2
2
|
declare const DropDownWithTable: <T extends Record<string, unknown>>(props: DropDownWithTableProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
3
3
|
export default DropDownWithTable;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { TableProps } from './Table.types';
|
|
1
|
+
import type { TableProps } from './Table.types';
|
|
2
2
|
declare function Table<T extends Record<string, unknown>>({ columns, data, keyField, selectable, onRowSelect, rowActions, stickyHeader, loading, emptyStateMessage, pagination, onRowClick, rowClassName, isRowDisabled, breakpoint, alignHeader, isTableHeadVisible, isRowSelected: externalIsRowSelected, }: Readonly<TableProps<T>>): import("react/jsx-runtime").JSX.Element;
|
|
3
3
|
export default Table;
|
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
import { j as t } from "../../../_virtual/jsx-runtime.js";
|
|
2
|
-
import { useState as v, useEffect as L, useMemo as
|
|
3
|
-
import { useTranslation as
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import O, { CheckboxCell as
|
|
2
|
+
import { useState as v, useEffect as L, useMemo as Q } from "react";
|
|
3
|
+
import { useTranslation as U } from "react-i18next";
|
|
4
|
+
import X from "../../Spinner.js";
|
|
5
|
+
import Y from "../../Pagination.js";
|
|
6
|
+
import Z from "../../Typography.js";
|
|
7
|
+
import O, { CheckboxCell as H } from "./components/CellComponents.js";
|
|
8
8
|
import z from "./components/TableHead.js";
|
|
9
|
-
import { TableContainer as
|
|
10
|
-
function
|
|
9
|
+
import { TableContainer as D, LoadingOverlay as k, TablesWrapper as F, DataScrollBox as R, StyledTable as w, TableBody as W, EmptyState as ee, TableRow as y, TableCellContainer as b, ActionsTable as te, TableFooter as ne } from "./Table.styles.js";
|
|
10
|
+
function xe({
|
|
11
11
|
columns: T,
|
|
12
|
-
data:
|
|
13
|
-
keyField:
|
|
14
|
-
selectable:
|
|
12
|
+
data: n,
|
|
13
|
+
keyField: l,
|
|
14
|
+
selectable: j = !1,
|
|
15
15
|
onRowSelect: m,
|
|
16
16
|
rowActions: x,
|
|
17
17
|
stickyHeader: $ = !1,
|
|
18
18
|
loading: f = !1,
|
|
19
19
|
emptyStateMessage: I,
|
|
20
|
-
pagination:
|
|
21
|
-
onRowClick:
|
|
22
|
-
rowClassName:
|
|
20
|
+
pagination: s,
|
|
21
|
+
onRowClick: u,
|
|
22
|
+
rowClassName: p,
|
|
23
23
|
isRowDisabled: d,
|
|
24
24
|
breakpoint: _ = "md",
|
|
25
25
|
alignHeader: C = "start",
|
|
@@ -27,7 +27,7 @@ function me({
|
|
|
27
27
|
isTableHeadVisible: K = !1,
|
|
28
28
|
isRowSelected: S
|
|
29
29
|
}) {
|
|
30
|
-
const [h,
|
|
30
|
+
const [h, g] = v([]), [B, P] = v(_), [M, A] = v(null), { t: N } = U();
|
|
31
31
|
L(() => {
|
|
32
32
|
const e = () => {
|
|
33
33
|
A(null);
|
|
@@ -37,63 +37,63 @@ function me({
|
|
|
37
37
|
};
|
|
38
38
|
}, []), L(() => {
|
|
39
39
|
const e = () => {
|
|
40
|
-
const
|
|
41
|
-
|
|
40
|
+
const i = window.innerWidth;
|
|
41
|
+
i < 576 ? P("sm") : i < 992 ? P("md") : P("lg");
|
|
42
42
|
};
|
|
43
43
|
return e(), window.addEventListener("resize", e), () => window.removeEventListener("resize", e);
|
|
44
44
|
}, []);
|
|
45
|
-
const
|
|
46
|
-
h.length ===
|
|
45
|
+
const a = Q(() => T.filter((e) => typeof e.hidden == "function" ? !e.hidden(B) : !e.hidden), [T, B]), V = () => {
|
|
46
|
+
h.length === n.length ? g([]) : g([...n]), m && m(h.length === n.length ? [] : [...n]);
|
|
47
|
+
}, q = (e) => {
|
|
48
|
+
const i = h.filter((r) => e[l] === r[l]);
|
|
49
|
+
return i && i.length > 0;
|
|
47
50
|
}, G = (e) => {
|
|
48
|
-
const
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
const l = h.some((o) => o[r] === e[r]);
|
|
52
|
-
let s;
|
|
53
|
-
l ? s = h.filter((o) => o[r] !== e[r]) : s = [...h, e], p(s), m && m(s);
|
|
51
|
+
const i = h.some((o) => o[l] === e[l]);
|
|
52
|
+
let r;
|
|
53
|
+
i ? r = h.filter((o) => o[l] !== e[l]) : r = [...h, e], g(r), m && m(r);
|
|
54
54
|
};
|
|
55
|
-
return /* @__PURE__ */ t.jsxs(
|
|
56
|
-
f && /* @__PURE__ */ t.jsx(
|
|
57
|
-
/* @__PURE__ */ t.jsxs(
|
|
58
|
-
/* @__PURE__ */ t.jsx(
|
|
55
|
+
return /* @__PURE__ */ t.jsxs(D, { children: [
|
|
56
|
+
f && /* @__PURE__ */ t.jsx(k, { children: /* @__PURE__ */ t.jsx(X, { size: "3rem" }) }),
|
|
57
|
+
/* @__PURE__ */ t.jsxs(F, { children: [
|
|
58
|
+
/* @__PURE__ */ t.jsx(R, { children: /* @__PURE__ */ t.jsxs(w, { children: [
|
|
59
59
|
K && /* @__PURE__ */ t.jsx(
|
|
60
60
|
z,
|
|
61
61
|
{
|
|
62
|
-
data:
|
|
63
|
-
handleSelectAll:
|
|
62
|
+
data: n,
|
|
63
|
+
handleSelectAll: V,
|
|
64
64
|
selectedRows: h,
|
|
65
|
-
visibleColumns:
|
|
65
|
+
visibleColumns: a,
|
|
66
66
|
alignHeader: C,
|
|
67
67
|
rowActions: void 0,
|
|
68
68
|
stickyHeader: $,
|
|
69
|
-
selectable:
|
|
69
|
+
selectable: j,
|
|
70
70
|
loading: f
|
|
71
71
|
}
|
|
72
72
|
),
|
|
73
|
-
/* @__PURE__ */ t.jsx(W, { children:
|
|
74
|
-
const
|
|
73
|
+
/* @__PURE__ */ t.jsx(W, { children: n.length === 0 ? /* @__PURE__ */ t.jsx("tr", { children: /* @__PURE__ */ t.jsx("td", { colSpan: (j ? 1 : 0) + a.length, children: /* @__PURE__ */ t.jsx(ee, { children: /* @__PURE__ */ t.jsx(Z, { variant: "mdText", children: I ?? N("NO_DATA_AVAILABLE") }) }) }) }) : n == null ? void 0 : n.map((e, i) => {
|
|
74
|
+
const r = (d == null ? void 0 : d(e)) ?? !1, o = S ? S(e) : h.some((c) => c[l] === e[l]), E = e[l], J = (p == null ? void 0 : p(e, i)) ?? "";
|
|
75
75
|
return /* @__PURE__ */ t.jsxs(
|
|
76
76
|
y,
|
|
77
77
|
{
|
|
78
78
|
$selected: o,
|
|
79
|
-
$disabled:
|
|
80
|
-
$clickable: !!
|
|
81
|
-
onClick: () => !
|
|
82
|
-
className:
|
|
79
|
+
$disabled: r,
|
|
80
|
+
$clickable: !!u && !r,
|
|
81
|
+
onClick: () => !r && (u == null ? void 0 : u(e)),
|
|
82
|
+
className: J,
|
|
83
83
|
children: [
|
|
84
|
-
|
|
85
|
-
|
|
84
|
+
j && /* @__PURE__ */ t.jsx(b, { $align: "center", $isFirstColumn: !0, children: /* @__PURE__ */ t.jsx(
|
|
85
|
+
H,
|
|
86
86
|
{
|
|
87
87
|
checkBoxOptions: {
|
|
88
|
-
checked:
|
|
88
|
+
checked: q(e),
|
|
89
89
|
$variant: "primary",
|
|
90
|
-
$disabled:
|
|
90
|
+
$disabled: r,
|
|
91
91
|
$size: "sm",
|
|
92
|
-
onChange: () => !
|
|
92
|
+
onChange: () => !r && G(e)
|
|
93
93
|
}
|
|
94
94
|
}
|
|
95
95
|
) }),
|
|
96
|
-
|
|
96
|
+
a.map((c) => /* @__PURE__ */ t.jsx(b, { $align: c.align, children: /* @__PURE__ */ t.jsx(
|
|
97
97
|
O,
|
|
98
98
|
{
|
|
99
99
|
column: c,
|
|
@@ -111,11 +111,11 @@ function me({
|
|
|
111
111
|
);
|
|
112
112
|
}) })
|
|
113
113
|
] }) }),
|
|
114
|
-
x && x.length > 0 && /* @__PURE__ */ t.jsxs(
|
|
114
|
+
x && x.length > 0 && /* @__PURE__ */ t.jsxs(te, { children: [
|
|
115
115
|
/* @__PURE__ */ t.jsx(
|
|
116
116
|
z,
|
|
117
117
|
{
|
|
118
|
-
data:
|
|
118
|
+
data: n,
|
|
119
119
|
handleSelectAll: () => {
|
|
120
120
|
},
|
|
121
121
|
selectedRows: h,
|
|
@@ -127,43 +127,43 @@ function me({
|
|
|
127
127
|
loading: f
|
|
128
128
|
}
|
|
129
129
|
),
|
|
130
|
-
/* @__PURE__ */ t.jsx(W, { children:
|
|
131
|
-
const
|
|
132
|
-
return /* @__PURE__ */ t.jsx(y, { $disabled:
|
|
130
|
+
/* @__PURE__ */ t.jsx(W, { children: n.length === 0 ? /* @__PURE__ */ t.jsx("tr", { children: /* @__PURE__ */ t.jsx("td", { children: /* @__PURE__ */ t.jsx("div", { style: { height: "3.5rem" } }) }) }) : n == null ? void 0 : n.map((e) => {
|
|
131
|
+
const i = (d == null ? void 0 : d(e)) ?? !1;
|
|
132
|
+
return /* @__PURE__ */ t.jsx(y, { $disabled: i, children: /* @__PURE__ */ t.jsx(b, { $align: "center", $isActionCell: !0, children: /* @__PURE__ */ t.jsx(
|
|
133
133
|
O,
|
|
134
134
|
{
|
|
135
135
|
row: e,
|
|
136
136
|
type: "icon",
|
|
137
137
|
iconOptions: {
|
|
138
|
-
keyField:
|
|
138
|
+
keyField: l,
|
|
139
139
|
rowActions: x,
|
|
140
140
|
activeDropdown: M,
|
|
141
141
|
setActiveDropdown: A
|
|
142
142
|
}
|
|
143
143
|
}
|
|
144
|
-
) }) }, `action-${e[
|
|
144
|
+
) }) }, `action-${e[l]}`);
|
|
145
145
|
}) })
|
|
146
146
|
] })
|
|
147
147
|
] }),
|
|
148
|
-
|
|
149
|
-
|
|
148
|
+
s && s.enabled && /* @__PURE__ */ t.jsx(ne, { children: /* @__PURE__ */ t.jsx(
|
|
149
|
+
Y,
|
|
150
150
|
{
|
|
151
|
-
currentPage:
|
|
152
|
-
totalPages:
|
|
153
|
-
onChange:
|
|
151
|
+
currentPage: s.currentPage,
|
|
152
|
+
totalPages: s.totalPages,
|
|
153
|
+
onChange: s.onPageChange,
|
|
154
154
|
disabled: f,
|
|
155
|
-
hidePrevButton:
|
|
156
|
-
hideNextButton:
|
|
157
|
-
siblingCount:
|
|
158
|
-
boundaryCount:
|
|
159
|
-
itemsPerPage:
|
|
160
|
-
totalItems:
|
|
161
|
-
itemsPerPageOptions:
|
|
162
|
-
onItemsPerPageChange:
|
|
155
|
+
hidePrevButton: s.hidePrevButton,
|
|
156
|
+
hideNextButton: s.hideNextButton,
|
|
157
|
+
siblingCount: s.siblingCount,
|
|
158
|
+
boundaryCount: s.boundaryCount,
|
|
159
|
+
itemsPerPage: s.pageSize,
|
|
160
|
+
totalItems: s.totalItems,
|
|
161
|
+
itemsPerPageOptions: s.itemsPerPageOptions,
|
|
162
|
+
onItemsPerPageChange: s.onItemsPerPageChange
|
|
163
163
|
}
|
|
164
164
|
) })
|
|
165
165
|
] });
|
|
166
166
|
}
|
|
167
167
|
export {
|
|
168
|
-
|
|
168
|
+
xe as default
|
|
169
169
|
};
|