qaema-ui 0.0.59 → 0.0.61
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/index.js +5 -5
- package/dist/_virtual/index2.js +4 -4
- package/dist/_virtual/index3.js +4 -4
- package/dist/_virtual/index7.js +2 -3
- package/dist/_virtual/index8.js +3 -2
- package/dist/components/DropDownWithTable/Table/Table.js +35 -34
- package/dist/components/DropDownWithTable/Table/Table.types.d.ts +1 -0
- package/dist/components/PriceCard.d.ts +13 -0
- package/dist/components/PriceCard.js +170 -91
- package/dist/components/StatCard.js +8 -7
- package/dist/components/Table/Table.js +39 -38
- package/dist/components/Table/Table.types.d.ts +1 -0
- package/dist/components/Table/components/CellComponents.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/Alert.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/AlertHeading.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/AlertLink.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/Button.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/CloseButton.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/Col.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/Collapse.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/Dropdown.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/DropdownDivider.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/DropdownHeader.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/DropdownItem.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/DropdownItemText.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/DropdownMenu.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/DropdownToggle.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/Fade.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/Feedback.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/FloatingLabel.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/Form.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/FormCheck.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/FormCheckInput.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/FormCheckLabel.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/FormControl.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/FormFloating.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/FormLabel.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/FormRange.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/FormSelect.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/FormText.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/Image.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/Nav.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/NavItem.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/NavLink.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/Navbar.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/NavbarBrand.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/NavbarText.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/NavbarToggle.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/Offcanvas.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/OffcanvasBody.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/OffcanvasHeader.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/OffcanvasTitle.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/OffcanvasToggling.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/Toast.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/ToastBody.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/ToastHeader.js +1 -1
- package/dist/node_modules/react-bootstrap/esm/divWithClassName.js +1 -1
- package/dist/node_modules/react-helmet-async/lib/index.esm.js +2 -2
- package/dist/node_modules/react-is/index.js +1 -1
- package/dist/node_modules/recharts/es6/util/ReactUtils.js +1 -1
- package/package.json +1 -1
package/dist/_virtual/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { getDefaultExportFromCjs as
|
|
2
|
-
import { __require as
|
|
3
|
-
var a =
|
|
4
|
-
const
|
|
1
|
+
import { getDefaultExportFromCjs as r } from "./_commonjsHelpers.js";
|
|
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/index2.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/index3.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { getDefaultExportFromCjs as
|
|
2
|
-
import { __require as
|
|
3
|
-
var a =
|
|
4
|
-
const t = /* @__PURE__ */
|
|
1
|
+
import { getDefaultExportFromCjs as s } from "./_commonjsHelpers.js";
|
|
2
|
+
import { __require as r } from "../node_modules/classnames/index.js";
|
|
3
|
+
var a = r();
|
|
4
|
+
const t = /* @__PURE__ */ s(a);
|
|
5
5
|
export {
|
|
6
6
|
t as default
|
|
7
7
|
};
|
package/dist/_virtual/index7.js
CHANGED
package/dist/_virtual/index8.js
CHANGED
|
@@ -6,28 +6,28 @@ import Y from "../../Pagination.js";
|
|
|
6
6
|
import Z from "../../Typography.js";
|
|
7
7
|
import O, { CheckboxCell as H } from "./components/CellComponents.js";
|
|
8
8
|
import z from "./components/TableHead.js";
|
|
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
|
|
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 se } from "./Table.styles.js";
|
|
10
10
|
function xe({
|
|
11
11
|
columns: T,
|
|
12
|
-
data:
|
|
12
|
+
data: s,
|
|
13
13
|
keyField: l,
|
|
14
14
|
selectable: j = !1,
|
|
15
|
-
onRowSelect:
|
|
15
|
+
onRowSelect: o,
|
|
16
16
|
rowActions: x,
|
|
17
17
|
stickyHeader: $ = !1,
|
|
18
18
|
loading: f = !1,
|
|
19
19
|
emptyStateMessage: I,
|
|
20
|
-
pagination:
|
|
20
|
+
pagination: n,
|
|
21
21
|
onRowClick: u,
|
|
22
22
|
rowClassName: p,
|
|
23
23
|
isRowDisabled: d,
|
|
24
|
-
breakpoint:
|
|
24
|
+
breakpoint: N = "md",
|
|
25
25
|
alignHeader: C = "start",
|
|
26
26
|
// Dropdown related props
|
|
27
|
-
isTableHeadVisible:
|
|
27
|
+
isTableHeadVisible: _ = !1,
|
|
28
28
|
isRowSelected: S
|
|
29
29
|
}) {
|
|
30
|
-
const [h, g] = v([]), [B,
|
|
30
|
+
const [h, g] = v([]), [B, a] = v(N), [K, A] = v(null), { t: M } = U();
|
|
31
31
|
L(() => {
|
|
32
32
|
const e = () => {
|
|
33
33
|
A(null);
|
|
@@ -38,31 +38,31 @@ function xe({
|
|
|
38
38
|
}, []), L(() => {
|
|
39
39
|
const e = () => {
|
|
40
40
|
const i = window.innerWidth;
|
|
41
|
-
i < 576 ?
|
|
41
|
+
i < 576 ? a("sm") : i < 992 ? a("md") : a("lg");
|
|
42
42
|
};
|
|
43
43
|
return e(), window.addEventListener("resize", e), () => window.removeEventListener("resize", e);
|
|
44
44
|
}, []);
|
|
45
|
-
const
|
|
46
|
-
h.length ===
|
|
45
|
+
const P = Q(() => T.filter((e) => typeof e.hidden == "function" ? !e.hidden(B) : !e.hidden), [T, B]), V = () => {
|
|
46
|
+
h.length === s.length ? g([]) : g([...s]), o && o(h.length === s.length ? [] : [...s]);
|
|
47
47
|
}, q = (e) => {
|
|
48
48
|
const i = h.filter((r) => e[l] === r[l]);
|
|
49
49
|
return i && i.length > 0;
|
|
50
50
|
}, G = (e) => {
|
|
51
|
-
const i = h.some((
|
|
51
|
+
const i = h.some((m) => m[l] === e[l]);
|
|
52
52
|
let r;
|
|
53
|
-
i ? r = h.filter((
|
|
53
|
+
i ? r = h.filter((m) => m[l] !== e[l]) : r = [...h, e], g(r), o && o(r);
|
|
54
54
|
};
|
|
55
55
|
return /* @__PURE__ */ t.jsxs(D, { children: [
|
|
56
56
|
f && /* @__PURE__ */ t.jsx(k, { children: /* @__PURE__ */ t.jsx(X, { size: "3rem" }) }),
|
|
57
57
|
/* @__PURE__ */ t.jsxs(F, { children: [
|
|
58
58
|
/* @__PURE__ */ t.jsx(R, { children: /* @__PURE__ */ t.jsxs(w, { children: [
|
|
59
|
-
|
|
59
|
+
_ && /* @__PURE__ */ t.jsx(
|
|
60
60
|
z,
|
|
61
61
|
{
|
|
62
|
-
data:
|
|
62
|
+
data: s,
|
|
63
63
|
handleSelectAll: V,
|
|
64
64
|
selectedRows: h,
|
|
65
|
-
visibleColumns:
|
|
65
|
+
visibleColumns: P,
|
|
66
66
|
alignHeader: C,
|
|
67
67
|
rowActions: void 0,
|
|
68
68
|
stickyHeader: $,
|
|
@@ -70,12 +70,12 @@ function xe({
|
|
|
70
70
|
loading: f
|
|
71
71
|
}
|
|
72
72
|
),
|
|
73
|
-
/* @__PURE__ */ t.jsx(W, { children:
|
|
74
|
-
const r = (d == null ? void 0 : d(e)) ?? !1,
|
|
73
|
+
/* @__PURE__ */ t.jsx(W, { children: s.length === 0 ? /* @__PURE__ */ t.jsx("tr", { children: /* @__PURE__ */ t.jsx("td", { colSpan: (j ? 1 : 0) + P.length, children: /* @__PURE__ */ t.jsx(ee, { children: /* @__PURE__ */ t.jsx(Z, { variant: "mdText", children: I ?? M("NO_DATA_AVAILABLE") }) }) }) }) : s == null ? void 0 : s.map((e, i) => {
|
|
74
|
+
const r = (d == null ? void 0 : d(e)) ?? !1, m = 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
|
-
$selected:
|
|
78
|
+
$selected: m,
|
|
79
79
|
$disabled: r,
|
|
80
80
|
$clickable: !!u && !r,
|
|
81
81
|
onClick: () => !r && (u == null ? void 0 : u(e)),
|
|
@@ -93,13 +93,14 @@ function xe({
|
|
|
93
93
|
}
|
|
94
94
|
}
|
|
95
95
|
) }),
|
|
96
|
-
|
|
96
|
+
P.map((c) => /* @__PURE__ */ t.jsx(b, { $align: c.align, children: /* @__PURE__ */ t.jsx(
|
|
97
97
|
O,
|
|
98
98
|
{
|
|
99
99
|
column: c,
|
|
100
100
|
row: e,
|
|
101
101
|
type: c.cellType ?? "text",
|
|
102
102
|
align: c.align,
|
|
103
|
+
className: c.className,
|
|
103
104
|
width: c.width ?? "",
|
|
104
105
|
minWidth: c.minWidth ?? "",
|
|
105
106
|
maxWidth: c.maxWidth ?? ""
|
|
@@ -115,7 +116,7 @@ function xe({
|
|
|
115
116
|
/* @__PURE__ */ t.jsx(
|
|
116
117
|
z,
|
|
117
118
|
{
|
|
118
|
-
data:
|
|
119
|
+
data: s,
|
|
119
120
|
handleSelectAll: () => {
|
|
120
121
|
},
|
|
121
122
|
selectedRows: h,
|
|
@@ -127,7 +128,7 @@ function xe({
|
|
|
127
128
|
loading: f
|
|
128
129
|
}
|
|
129
130
|
),
|
|
130
|
-
/* @__PURE__ */ t.jsx(W, { children:
|
|
131
|
+
/* @__PURE__ */ t.jsx(W, { children: s.length === 0 ? /* @__PURE__ */ t.jsx("tr", { children: /* @__PURE__ */ t.jsx("td", { children: /* @__PURE__ */ t.jsx("div", { style: { height: "3.5rem" } }) }) }) : s == null ? void 0 : s.map((e) => {
|
|
131
132
|
const i = (d == null ? void 0 : d(e)) ?? !1;
|
|
132
133
|
return /* @__PURE__ */ t.jsx(y, { $disabled: i, children: /* @__PURE__ */ t.jsx(b, { $align: "center", $isActionCell: !0, children: /* @__PURE__ */ t.jsx(
|
|
133
134
|
O,
|
|
@@ -137,7 +138,7 @@ function xe({
|
|
|
137
138
|
iconOptions: {
|
|
138
139
|
keyField: l,
|
|
139
140
|
rowActions: x,
|
|
140
|
-
activeDropdown:
|
|
141
|
+
activeDropdown: K,
|
|
141
142
|
setActiveDropdown: A
|
|
142
143
|
}
|
|
143
144
|
}
|
|
@@ -145,21 +146,21 @@ function xe({
|
|
|
145
146
|
}) })
|
|
146
147
|
] })
|
|
147
148
|
] }),
|
|
148
|
-
|
|
149
|
+
n && n.enabled && /* @__PURE__ */ t.jsx(se, { children: /* @__PURE__ */ t.jsx(
|
|
149
150
|
Y,
|
|
150
151
|
{
|
|
151
|
-
currentPage:
|
|
152
|
-
totalPages:
|
|
153
|
-
onChange:
|
|
152
|
+
currentPage: n.currentPage,
|
|
153
|
+
totalPages: n.totalPages,
|
|
154
|
+
onChange: n.onPageChange,
|
|
154
155
|
disabled: f,
|
|
155
|
-
hidePrevButton:
|
|
156
|
-
hideNextButton:
|
|
157
|
-
siblingCount:
|
|
158
|
-
boundaryCount:
|
|
159
|
-
itemsPerPage:
|
|
160
|
-
totalItems:
|
|
161
|
-
itemsPerPageOptions:
|
|
162
|
-
onItemsPerPageChange:
|
|
156
|
+
hidePrevButton: n.hidePrevButton,
|
|
157
|
+
hideNextButton: n.hideNextButton,
|
|
158
|
+
siblingCount: n.siblingCount,
|
|
159
|
+
boundaryCount: n.boundaryCount,
|
|
160
|
+
itemsPerPage: n.pageSize,
|
|
161
|
+
totalItems: n.totalItems,
|
|
162
|
+
itemsPerPageOptions: n.itemsPerPageOptions,
|
|
163
|
+
onItemsPerPageChange: n.onItemsPerPageChange
|
|
163
164
|
}
|
|
164
165
|
) })
|
|
165
166
|
] });
|
|
@@ -20,6 +20,12 @@ export type PriceCardPrice = {
|
|
|
20
20
|
color?: string;
|
|
21
21
|
periodColor?: string;
|
|
22
22
|
};
|
|
23
|
+
export type PriceCardAddon = {
|
|
24
|
+
id: string;
|
|
25
|
+
titleEn: string;
|
|
26
|
+
baseFare: number;
|
|
27
|
+
color?: string;
|
|
28
|
+
};
|
|
23
29
|
export type PriceCardProps = {
|
|
24
30
|
title: string;
|
|
25
31
|
price: PriceCardPrice;
|
|
@@ -43,6 +49,13 @@ export type PriceCardProps = {
|
|
|
43
49
|
showFeatures?: boolean;
|
|
44
50
|
featuresTitle?: string;
|
|
45
51
|
featuresDescription?: string;
|
|
52
|
+
showAddons?: boolean;
|
|
53
|
+
selectedAddon?: string;
|
|
54
|
+
setSelectedAddon?: (addonId: string) => void;
|
|
55
|
+
addOnsData?: PriceCardAddon[];
|
|
56
|
+
addonsTitle?: string;
|
|
57
|
+
addonsOptionalLabel?: string;
|
|
58
|
+
addonsMonthlyLabel?: string;
|
|
46
59
|
};
|
|
47
60
|
declare const PriceCard: React.FC<PriceCardProps>;
|
|
48
61
|
export default PriceCard;
|