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.
Files changed (61) hide show
  1. package/dist/_virtual/index.js +5 -5
  2. package/dist/_virtual/index2.js +4 -4
  3. package/dist/_virtual/index3.js +4 -4
  4. package/dist/_virtual/index7.js +2 -3
  5. package/dist/_virtual/index8.js +3 -2
  6. package/dist/components/DropDownWithTable/Table/Table.js +35 -34
  7. package/dist/components/DropDownWithTable/Table/Table.types.d.ts +1 -0
  8. package/dist/components/PriceCard.d.ts +13 -0
  9. package/dist/components/PriceCard.js +170 -91
  10. package/dist/components/StatCard.js +8 -7
  11. package/dist/components/Table/Table.js +39 -38
  12. package/dist/components/Table/Table.types.d.ts +1 -0
  13. package/dist/components/Table/components/CellComponents.js +1 -1
  14. package/dist/node_modules/react-bootstrap/esm/Alert.js +1 -1
  15. package/dist/node_modules/react-bootstrap/esm/AlertHeading.js +1 -1
  16. package/dist/node_modules/react-bootstrap/esm/AlertLink.js +1 -1
  17. package/dist/node_modules/react-bootstrap/esm/Button.js +1 -1
  18. package/dist/node_modules/react-bootstrap/esm/CloseButton.js +1 -1
  19. package/dist/node_modules/react-bootstrap/esm/Col.js +1 -1
  20. package/dist/node_modules/react-bootstrap/esm/Collapse.js +1 -1
  21. package/dist/node_modules/react-bootstrap/esm/Dropdown.js +1 -1
  22. package/dist/node_modules/react-bootstrap/esm/DropdownDivider.js +1 -1
  23. package/dist/node_modules/react-bootstrap/esm/DropdownHeader.js +1 -1
  24. package/dist/node_modules/react-bootstrap/esm/DropdownItem.js +1 -1
  25. package/dist/node_modules/react-bootstrap/esm/DropdownItemText.js +1 -1
  26. package/dist/node_modules/react-bootstrap/esm/DropdownMenu.js +1 -1
  27. package/dist/node_modules/react-bootstrap/esm/DropdownToggle.js +1 -1
  28. package/dist/node_modules/react-bootstrap/esm/Fade.js +1 -1
  29. package/dist/node_modules/react-bootstrap/esm/Feedback.js +1 -1
  30. package/dist/node_modules/react-bootstrap/esm/FloatingLabel.js +1 -1
  31. package/dist/node_modules/react-bootstrap/esm/Form.js +1 -1
  32. package/dist/node_modules/react-bootstrap/esm/FormCheck.js +1 -1
  33. package/dist/node_modules/react-bootstrap/esm/FormCheckInput.js +1 -1
  34. package/dist/node_modules/react-bootstrap/esm/FormCheckLabel.js +1 -1
  35. package/dist/node_modules/react-bootstrap/esm/FormControl.js +1 -1
  36. package/dist/node_modules/react-bootstrap/esm/FormFloating.js +1 -1
  37. package/dist/node_modules/react-bootstrap/esm/FormLabel.js +1 -1
  38. package/dist/node_modules/react-bootstrap/esm/FormRange.js +1 -1
  39. package/dist/node_modules/react-bootstrap/esm/FormSelect.js +1 -1
  40. package/dist/node_modules/react-bootstrap/esm/FormText.js +1 -1
  41. package/dist/node_modules/react-bootstrap/esm/Image.js +1 -1
  42. package/dist/node_modules/react-bootstrap/esm/Nav.js +1 -1
  43. package/dist/node_modules/react-bootstrap/esm/NavItem.js +1 -1
  44. package/dist/node_modules/react-bootstrap/esm/NavLink.js +1 -1
  45. package/dist/node_modules/react-bootstrap/esm/Navbar.js +1 -1
  46. package/dist/node_modules/react-bootstrap/esm/NavbarBrand.js +1 -1
  47. package/dist/node_modules/react-bootstrap/esm/NavbarText.js +1 -1
  48. package/dist/node_modules/react-bootstrap/esm/NavbarToggle.js +1 -1
  49. package/dist/node_modules/react-bootstrap/esm/Offcanvas.js +1 -1
  50. package/dist/node_modules/react-bootstrap/esm/OffcanvasBody.js +1 -1
  51. package/dist/node_modules/react-bootstrap/esm/OffcanvasHeader.js +1 -1
  52. package/dist/node_modules/react-bootstrap/esm/OffcanvasTitle.js +1 -1
  53. package/dist/node_modules/react-bootstrap/esm/OffcanvasToggling.js +1 -1
  54. package/dist/node_modules/react-bootstrap/esm/Toast.js +1 -1
  55. package/dist/node_modules/react-bootstrap/esm/ToastBody.js +1 -1
  56. package/dist/node_modules/react-bootstrap/esm/ToastHeader.js +1 -1
  57. package/dist/node_modules/react-bootstrap/esm/divWithClassName.js +1 -1
  58. package/dist/node_modules/react-helmet-async/lib/index.esm.js +2 -2
  59. package/dist/node_modules/react-is/index.js +1 -1
  60. package/dist/node_modules/recharts/es6/util/ReactUtils.js +1 -1
  61. package/package.json +1 -1
@@ -1,149 +1,149 @@
1
- import { j as r } from "../_virtual/jsx-runtime.js";
1
+ import { j as i } from "../_virtual/jsx-runtime.js";
2
2
  import "react";
3
- import { FiCheck as j, FiX as v } from "../node_modules/react-icons/fi/index.js";
4
- import i, { css as a } from "styled-components";
5
- import z from "../assets/icons/RiyalIcon.js";
6
- import { CurrencyContainer as k } from "../styles/Currency.styles.js";
7
- import C from "../assets/svg/Riyal.svg.js";
8
- import R from "./Badge.js";
3
+ import { FiCheck as B, FiX as T } from "../node_modules/react-icons/fi/index.js";
4
+ import o, { css as p } from "styled-components";
5
+ import m from "../assets/icons/RiyalIcon.js";
6
+ import { CurrencyContainer as H } from "../styles/Currency.styles.js";
7
+ import I from "../assets/svg/Riyal.svg.js";
8
+ import P from "./Badge.js";
9
9
  import d from "./Button.js";
10
- import n from "./Typography.js";
11
- const F = {
12
- transparent: a`
10
+ import a from "./Typography.js";
11
+ const W = {
12
+ transparent: p`
13
13
  background: rgba(255, 255, 255, 0.72);
14
14
  border: 1px solid ${({ theme: e }) => e.colors.grey.n200};
15
15
  box-shadow: 0 8px 24px rgba(16, 24, 40, 0.06);
16
16
  `,
17
- purple: a`
17
+ purple: p`
18
18
  background: linear-gradient(360deg, #ffffff 63.12%, #f1eeff 100%);
19
19
  border: 1px solid #e3deff;
20
20
  box-shadow:
21
21
  0px 4px 6px -2px #10182808,
22
22
  0px 12px 16px -4px #10182814;
23
23
  `
24
- }, S = i.div`
24
+ }, E = o.div`
25
25
  width: 100%;
26
26
  max-width: 28.458rem;
27
27
  border-radius: ${({ theme: e }) => e.borderRadius.xl};
28
28
  overflow: hidden;
29
29
  display: flex;
30
30
  flex-direction: column;
31
- ${({ $variant: e }) => F[e]};
32
- `, B = i.div`
31
+ ${({ $variant: e }) => W[e]};
32
+ `, L = o.div`
33
33
  padding: 2rem;
34
34
  display: flex;
35
35
  flex-direction: column;
36
36
  gap: ${({ theme: e }) => e.spacing.sm};
37
37
  border-bottom: 1px solid ${({ theme: e }) => e.colors.grey.n200};
38
- `, T = i.div`
38
+ `, D = o.div`
39
39
  display: flex;
40
40
  align-items: center;
41
41
  justify-content: space-between;
42
42
  gap: ${({ theme: e }) => e.spacing.m};
43
43
  flex-wrap: wrap;
44
- `, H = i(n)`
44
+ `, V = o(a)`
45
45
  font-family: ${({ theme: e }) => e.fonts.arabic};
46
46
  font-weight: 600;
47
47
  font-size: ${({ theme: e }) => {
48
- var o;
49
- return (o = e.typography.sizes) == null ? void 0 : o.s5;
48
+ var r;
49
+ return (r = e.typography.sizes) == null ? void 0 : r.s5;
50
50
  }};
51
51
  line-height: 1.75rem;
52
52
  color: ${({ theme: e }) => e.colors.grey.n400};
53
- `, P = i.div`
53
+ `, M = o.div`
54
54
  display: flex;
55
55
  flex-direction: column;
56
56
  gap: 0.85rem;
57
- `, E = i.div`
57
+ `, N = o.div`
58
58
  display: flex;
59
59
  align-items: center;
60
60
  gap: ${({ theme: e }) => e.spacing.xs};
61
61
  flex-wrap: wrap;
62
- `, I = i.div`
62
+ `, U = o.div`
63
63
  display: flex;
64
64
  align-items: baseline;
65
65
  gap: ${({ theme: e }) => e.spacing.xxs};
66
- `, D = i(z).attrs(({ theme: e }) => ({
66
+ `, X = o(m).attrs(({ theme: e }) => ({
67
67
  color: e.colors.grey.n350,
68
68
  width: "18",
69
69
  height: "20"
70
- }))``, L = i.span`
70
+ }))``, q = o.span`
71
71
  font-family: ${({ theme: e }) => e.fonts.english};
72
72
  font-weight: ${({ theme: e }) => e.typography.weights.semiBold};
73
73
  font-size: 2.706rem;
74
74
  line-height: 3.158rem;
75
- color: ${({ $color: e, theme: o }) => e ?? o.colors.grey.n800};
76
- `, V = i.span`
75
+ color: ${({ $color: e, theme: r }) => e ?? r.colors.grey.n800};
76
+ `, G = o.span`
77
77
  font-family: ${({ theme: e }) => e.fonts.arabic};
78
78
  font-weight: ${({ theme: e }) => e.typography.weights.regular};
79
79
  font-size: ${({ theme: e }) => {
80
- var o;
81
- return (o = e.typography.sizes) == null ? void 0 : o.s5;
80
+ var r;
81
+ return (r = e.typography.sizes) == null ? void 0 : r.s5;
82
82
  }};
83
83
  line-height: 1.804rem;
84
- color: ${({ $color: e, theme: o }) => e ?? o.colors.grey.n800};
85
- `, W = i(n)`
84
+ color: ${({ $color: e, theme: r }) => e ?? r.colors.grey.n800};
85
+ `, J = o(a)`
86
86
  font-family: ${({ theme: e }) => e.fonts.arabic};
87
87
  font-weight: ${({ theme: e }) => e.typography.weights.regular};
88
88
  font-size: ${({ theme: e }) => {
89
- var o;
90
- return (o = e.typography.sizes) == null ? void 0 : o.s4;
89
+ var r;
90
+ return (r = e.typography.sizes) == null ? void 0 : r.s4;
91
91
  }};
92
92
  line-height: ${({ theme: e }) => e.typography.lineHeights.m};
93
93
  color: ${({ theme: e }) => e.colors.grey.n400};
94
- `, M = i.div`
94
+ `, K = o.div`
95
95
  padding: 2rem 2rem 2.5rem 2rem;
96
96
  display: flex;
97
97
  flex-direction: column;
98
98
  gap: ${({ theme: e }) => e.spacing.m};
99
- `, N = i(n)`
99
+ `, Q = o(a)`
100
100
  font-family: ${({ theme: e }) => e.fonts.arabic};
101
101
  font-weight: ${({ theme: e }) => e.typography.weights.semiBold};
102
102
  font-size: ${({ theme: e }) => {
103
- var o;
104
- return (o = e.typography.sizes) == null ? void 0 : o.s4;
103
+ var r;
104
+ return (r = e.typography.sizes) == null ? void 0 : r.s4;
105
105
  }};
106
106
  line-height: 0.7rem;
107
107
  color: ${({ theme: e }) => e.colors.grey.n650};
108
108
  text-transform: uppercase;
109
- `, U = i(n)`
109
+ `, Y = o(a)`
110
110
  font-family: ${({ theme: e }) => e.fonts.arabic};
111
111
  font-weight: 500;
112
112
  font-size: ${({ theme: e }) => {
113
- var o;
114
- return (o = e.typography.sizes) == null ? void 0 : o.s4;
113
+ var r;
114
+ return (r = e.typography.sizes) == null ? void 0 : r.s4;
115
115
  }};
116
116
  line-height: ${({ theme: e }) => e.typography.lineHeights.m};
117
117
  color: ${({ theme: e }) => e.colors.grey.n400};
118
- `, X = i.div`
118
+ `, Z = o.div`
119
119
  display: flex;
120
120
  align-items: center;
121
121
  gap: ${({ theme: e }) => e.spacing.xs};
122
- `, q = i.span`
122
+ `, _ = o.span`
123
123
  font-family: ${({ theme: e }) => e.fonts.arabic};
124
124
  font-weight: ${({ theme: e }) => e.typography.weights.bold};
125
125
  font-size: ${({ theme: e }) => e.typography.sizes.s9};
126
126
  line-height: ${({ theme: e }) => e.typography.lineHeights.xl};
127
127
  letter-spacing: ${({ theme: e }) => e.typography.letterSpacings.balancedNarrow};
128
128
  color: ${({ theme: e }) => e.colors.grey.n350};
129
- `, G = i.span`
129
+ `, O = o.span`
130
130
  font-family: ${({ theme: e }) => e.fonts.arabic};
131
131
  font-weight: ${({ theme: e }) => e.typography.weights.regular};
132
132
  font-size: ${({ theme: e }) => e.typography.sizes.s4};
133
133
  line-height: ${({ theme: e }) => e.typography.lineHeights.m};
134
134
  color: ${({ theme: e }) => e.colors.grey.n350};
135
- `, J = i.ul`
135
+ `, A = o.ul`
136
136
  list-style: none;
137
137
  margin: 0;
138
138
  padding: 0;
139
139
  display: flex;
140
140
  flex-direction: column;
141
141
  gap: ${({ theme: e }) => e.spacing.s};
142
- `, K = i.li`
142
+ `, ee = o.li`
143
143
  display: flex;
144
144
  align-items: center;
145
145
  gap: ${({ theme: e }) => e.spacing.xs};
146
- `, O = i.span`
146
+ `, ie = o.span`
147
147
  width: 1rem;
148
148
  height: 1rem;
149
149
  border-radius: 50%;
@@ -157,23 +157,23 @@ const F = {
157
157
  height: 0.7rem;
158
158
  }
159
159
 
160
- ${({ theme: e, $variant: o }) => o === "included" ? a`
160
+ ${({ theme: e, $variant: r }) => r === "included" ? p`
161
161
  border: 1px solid ${e.colors.secondary.green.n450};
162
162
  color: ${e.colors.secondary.green.n450};
163
- ` : a`
163
+ ` : p`
164
164
  border: 1px solid ${e.colors.secondary.pink.n450};
165
165
  color: ${e.colors.secondary.pink.n450};
166
166
  `}
167
- `, Q = i(n)`
167
+ `, re = o(a)`
168
168
  font-family: ${({ theme: e }) => e.fonts.arabic};
169
169
  font-weight: 400;
170
170
  font-size: ${({ theme: e }) => {
171
- var o;
172
- return (o = e.typography.sizes) == null ? void 0 : o.s3;
171
+ var r;
172
+ return (r = e.typography.sizes) == null ? void 0 : r.s3;
173
173
  }};
174
174
  line-height: ${({ theme: e }) => e.typography.lineHeights.m};
175
175
  color: ${({ theme: e }) => e.colors.grey.n400};
176
- `, Y = i.div`
176
+ `, oe = o.div`
177
177
  width: 100%;
178
178
  margin-top: 1rem;
179
179
  display: flex;
@@ -183,57 +183,136 @@ const F = {
183
183
  button {
184
184
  width: 100%;
185
185
  }
186
- `, ne = ({
186
+ `, xe = ({
187
187
  title: e,
188
- price: o,
189
- description: f,
190
- secondaryPrice: p,
191
- features: x,
192
- variant: y = "transparent",
193
- badges: c = [],
194
- showPrimaryAction: m = !1,
188
+ price: r,
189
+ description: y,
190
+ secondaryPrice: c,
191
+ features: $,
192
+ variant: u = "transparent",
193
+ badges: h = [],
194
+ showPrimaryAction: b = !1,
195
195
  primaryAction: s,
196
- showSecondaryAction: $ = !1,
197
- secondaryAction: t,
198
- showFeatures: u = !0,
199
- featuresTitle: b = "FEATURES",
200
- featuresDescription: w = "Everything in our free plan plus....."
201
- }) => /* @__PURE__ */ r.jsxs(S, { $variant: y, children: [
202
- /* @__PURE__ */ r.jsxs(B, { children: [
203
- /* @__PURE__ */ r.jsxs(T, { children: [
204
- /* @__PURE__ */ r.jsx(H, { children: e }),
205
- c.length > 0 && /* @__PURE__ */ r.jsx(E, { children: c.map((l, g) => /* @__PURE__ */ r.jsx(R, { label: l.label, bgColor: l.bgColor, color: l.color }, `${l.label}-${g}`)) })
196
+ showSecondaryAction: j = !1,
197
+ secondaryAction: l,
198
+ showFeatures: w = !0,
199
+ featuresTitle: v = "FEATURES",
200
+ featuresDescription: z = "Everything in our free plan plus.....",
201
+ showAddons: C = !1,
202
+ selectedAddon: k = "Without",
203
+ setSelectedAddon: g,
204
+ addOnsData: f = [],
205
+ addonsTitle: F = "Personal Accountant",
206
+ addonsOptionalLabel: R = "optional",
207
+ addonsMonthlyLabel: S = "monthly"
208
+ }) => /* @__PURE__ */ i.jsxs(E, { $variant: u, children: [
209
+ /* @__PURE__ */ i.jsxs(L, { children: [
210
+ /* @__PURE__ */ i.jsxs(D, { children: [
211
+ /* @__PURE__ */ i.jsx(V, { children: e }),
212
+ h.length > 0 && /* @__PURE__ */ i.jsx(N, { children: h.map((t, n) => /* @__PURE__ */ i.jsx(P, { label: t.label, bgColor: t.bgColor, color: t.color }, `${t.label}-${n}`)) })
206
213
  ] }),
207
- /* @__PURE__ */ r.jsxs(I, { children: [
208
- /* @__PURE__ */ r.jsx(k, { src: C, alt: "Riyal" }),
209
- /* @__PURE__ */ r.jsx(L, { $color: o.color, children: o.amount }),
210
- /* @__PURE__ */ r.jsx(V, { $color: o.periodColor, children: o.period ?? "/ Month" })
214
+ /* @__PURE__ */ i.jsxs(U, { children: [
215
+ /* @__PURE__ */ i.jsx(H, { src: I, alt: "Riyal" }),
216
+ /* @__PURE__ */ i.jsx(q, { $color: r.color, children: r.amount }),
217
+ /* @__PURE__ */ i.jsx(G, { $color: r.periodColor, children: r.period ?? "/ Month" })
211
218
  ] }),
212
- p && /* @__PURE__ */ r.jsxs(X, { children: [
213
- /* @__PURE__ */ r.jsx(D, {}),
214
- /* @__PURE__ */ r.jsx(q, { children: p.amount }),
215
- /* @__PURE__ */ r.jsx(G, { children: p.label })
219
+ c && /* @__PURE__ */ i.jsxs(Z, { children: [
220
+ /* @__PURE__ */ i.jsx(X, {}),
221
+ /* @__PURE__ */ i.jsx(_, { children: c.amount }),
222
+ /* @__PURE__ */ i.jsx(O, { children: c.label })
216
223
  ] }),
217
- /* @__PURE__ */ r.jsx(W, { children: f }),
218
- /* @__PURE__ */ r.jsxs(Y, { children: [
219
- m && /* @__PURE__ */ r.jsx(d, { variant: (s == null ? void 0 : s.variant) ?? "primary", onClick: s == null ? void 0 : s.onPrimaryActionClick, children: s == null ? void 0 : s.label }),
220
- $ && /* @__PURE__ */ r.jsx(d, { variant: (t == null ? void 0 : t.variant) ?? "light-primary", onClick: t == null ? void 0 : t.onSecondaryActionClick, children: t == null ? void 0 : t.label })
224
+ /* @__PURE__ */ i.jsx(J, { children: y }),
225
+ /* @__PURE__ */ i.jsxs(oe, { children: [
226
+ b && /* @__PURE__ */ i.jsx(d, { variant: (s == null ? void 0 : s.variant) ?? "primary", onClick: s == null ? void 0 : s.onPrimaryActionClick, children: s == null ? void 0 : s.label }),
227
+ j && /* @__PURE__ */ i.jsx(d, { variant: (l == null ? void 0 : l.variant) ?? "light-primary", onClick: l == null ? void 0 : l.onSecondaryActionClick, children: l == null ? void 0 : l.label })
228
+ ] }),
229
+ C && f.length > 0 && /* @__PURE__ */ i.jsxs("div", { children: [
230
+ /* @__PURE__ */ i.jsx("div", { style: { display: "flex", justifyContent: "space-between", alignItems: "center", marginBottom: "10px" }, children: /* @__PURE__ */ i.jsxs("div", { children: [
231
+ /* @__PURE__ */ i.jsx("span", { style: { fontSize: "13px", fontWeight: 600, color: "#111827" }, children: F }),
232
+ /* @__PURE__ */ i.jsx("span", { style: { fontSize: "11px", color: "#9ca3af", marginLeft: "6px" }, children: R })
233
+ ] }) }),
234
+ /* @__PURE__ */ i.jsx(
235
+ "div",
236
+ {
237
+ style: {
238
+ backgroundColor: "#f2f4f7",
239
+ borderRadius: "9px",
240
+ padding: "4px",
241
+ display: "grid",
242
+ gridTemplateColumns: "repeat(3, minmax(0, 1fr))",
243
+ gap: "4px"
244
+ },
245
+ children: f.map((t) => {
246
+ const n = k === t.id;
247
+ return /* @__PURE__ */ i.jsxs(
248
+ "button",
249
+ {
250
+ type: "button",
251
+ onClick: () => g == null ? void 0 : g(t.id),
252
+ style: {
253
+ padding: "8px 6px 7px",
254
+ border: n ? "1px solid #d0d5dd" : "1px solid transparent",
255
+ backgroundColor: n ? "#ffffff" : "transparent",
256
+ color: n ? "#1d2939" : "#98a2b3",
257
+ borderRadius: "6px",
258
+ cursor: "pointer",
259
+ fontWeight: n ? 700 : 600,
260
+ fontSize: "12px",
261
+ lineHeight: 1.1,
262
+ transition: "all 0.18s ease",
263
+ display: "flex",
264
+ flexDirection: "column",
265
+ alignItems: "center",
266
+ justifyContent: "center",
267
+ gap: t.baseFare > 0 ? "2px" : "0",
268
+ minHeight: "42px",
269
+ boxShadow: n ? "0 1px 2px rgba(16, 24, 40, 0.08)" : "none"
270
+ },
271
+ children: [
272
+ /* @__PURE__ */ i.jsx("span", { children: t.titleEn }),
273
+ t.baseFare > 0 && /* @__PURE__ */ i.jsxs(
274
+ "span",
275
+ {
276
+ style: {
277
+ fontSize: "10px",
278
+ marginTop: "2px",
279
+ color: n ? "#101828" : "#667085",
280
+ fontWeight: 700,
281
+ display: "inline-flex",
282
+ alignItems: "center",
283
+ gap: "2px"
284
+ },
285
+ children: [
286
+ /* @__PURE__ */ i.jsx(m, { width: "9", height: "9", color: n ? "#101828" : "#667085" }),
287
+ t.baseFare,
288
+ " ",
289
+ S
290
+ ]
291
+ }
292
+ )
293
+ ]
294
+ },
295
+ t.id
296
+ );
297
+ })
298
+ }
299
+ )
221
300
  ] })
222
301
  ] }),
223
- u && /* @__PURE__ */ r.jsxs(M, { children: [
224
- /* @__PURE__ */ r.jsxs(P, { children: [
225
- /* @__PURE__ */ r.jsx(N, { children: b }),
226
- /* @__PURE__ */ r.jsx(U, { children: w })
302
+ w && /* @__PURE__ */ i.jsxs(K, { children: [
303
+ /* @__PURE__ */ i.jsxs(M, { children: [
304
+ /* @__PURE__ */ i.jsx(Q, { children: v }),
305
+ /* @__PURE__ */ i.jsx(Y, { children: z })
227
306
  ] }),
228
- /* @__PURE__ */ r.jsx(J, { children: x.map((l, g) => {
229
- const h = l.variant ?? "included";
230
- return /* @__PURE__ */ r.jsxs(K, { children: [
231
- /* @__PURE__ */ r.jsx(O, { $variant: h, children: h === "included" ? /* @__PURE__ */ r.jsx(j, {}) : /* @__PURE__ */ r.jsx(v, {}) }),
232
- /* @__PURE__ */ r.jsx(Q, { children: l.label })
233
- ] }, `${l.label}-${g}`);
307
+ /* @__PURE__ */ i.jsx(A, { children: $.map((t, n) => {
308
+ const x = t.variant ?? "included";
309
+ return /* @__PURE__ */ i.jsxs(ee, { children: [
310
+ /* @__PURE__ */ i.jsx(ie, { $variant: x, children: x === "included" ? /* @__PURE__ */ i.jsx(B, {}) : /* @__PURE__ */ i.jsx(T, {}) }),
311
+ /* @__PURE__ */ i.jsx(re, { children: t.label })
312
+ ] }, `${t.label}-${n}`);
234
313
  }) })
235
314
  ] })
236
315
  ] });
237
316
  export {
238
- ne as default
317
+ xe as default
239
318
  };
@@ -7,10 +7,11 @@ import j from "../assets/svg/Riyal.svg.js";
7
7
  const w = s.div`
8
8
  display: flex;
9
9
  width: 100%;
10
- height: 4rem;
10
+ height: 5rem;
11
11
  border-radius: ${({ theme: r }) => r.borderRadius.md};
12
12
  border: 1px solid ${({ theme: r }) => r.colors.grey.n100};
13
- overflow: hidden;
13
+ overflow-x: auto;
14
+ overflow-y: hidden;
14
15
  background-color: ${({ theme: r }) => r.colors.grey.n50};
15
16
  `, b = s.div`
16
17
  /* border: 1px solid ${({ theme: r }) => r.colors.grey.n150}; */
@@ -19,7 +20,7 @@ const w = s.div`
19
20
  flex-direction: column;
20
21
  justify-content: center;
21
22
  padding: 0.625rem ${({ theme: r }) => r.spacing.s};
22
- gap: ${({ theme: r }) => r.spacing.xxs};
23
+
23
24
  background-color: ${({ theme: r }) => r.colors.grey.n50};
24
25
  @media ${t.tablet} {
25
26
  padding: ${({ theme: r }) => r.spacing.xxs} ${({ theme: r }) => r.spacing.xs};
@@ -108,11 +109,11 @@ const w = s.div`
108
109
  state: n,
109
110
  indicators: h,
110
111
  variant: g = "currency",
111
- icon: x,
112
- $isLast: y
112
+ icon: y,
113
+ $isLast: x
113
114
  }) => {
114
115
  const { arrow: c = !0, sign: l = !0, percentage: d = !0 } = h || {};
115
- return /* @__PURE__ */ o.jsxs(b, { $isLast: y, children: [
116
+ return /* @__PURE__ */ o.jsxs(b, { $isLast: x, children: [
116
117
  /* @__PURE__ */ o.jsxs(v, { children: [
117
118
  /* @__PURE__ */ o.jsx("span", { children: r }),
118
119
  (c || l || d) && /* @__PURE__ */ o.jsx(z, { state: n, children: n === "positive" ? /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
@@ -126,7 +127,7 @@ const w = s.div`
126
127
  ] }) })
127
128
  ] }),
128
129
  /* @__PURE__ */ o.jsxs(I, { children: [
129
- g === "icon" ? /* @__PURE__ */ o.jsx(C, { children: x }) : /* @__PURE__ */ o.jsx(k, { src: j, alt: "Riyal" }),
130
+ g === "icon" ? /* @__PURE__ */ o.jsx(C, { children: y }) : /* @__PURE__ */ o.jsx(k, { src: j, alt: "Riyal" }),
130
131
  /* @__PURE__ */ o.jsxs(A, { children: [
131
132
  e,
132
133
  g !== "icon" && i && /* @__PURE__ */ o.jsxs(R, { children: [
@@ -1,7 +1,7 @@
1
1
  import { j as t } from "../../_virtual/jsx-runtime.js";
2
- import { useState as v, useEffect as E, useMemo as G } from "react";
3
- import { useTranslation as J } from "react-i18next";
4
- import N from "../Spinner.js";
2
+ import { useState as v, useEffect as E, useMemo as q } from "react";
3
+ import { useTranslation as G } from "react-i18next";
4
+ import J from "../Spinner.js";
5
5
  import Q from "../Pagination.js";
6
6
  import U from "../Typography.js";
7
7
  import L, { CheckboxCell as X } from "./components/CellComponents.js";
@@ -9,22 +9,22 @@ import O from "./components/TableHead.js";
9
9
  import { TableContainer as Y, LoadingOverlay as Z, TablesWrapper as H, DataScrollBox as D, StyledTable as k, TableBody as z, EmptyState as F, TableRow as W, TableCellContainer as b, ActionsTable as R, TableFooter as w } from "./Table.styles.js";
10
10
  function de({
11
11
  columns: T,
12
- data: i,
12
+ data: c,
13
13
  keyField: r,
14
- selectable: u = !1,
15
- onRowSelect: x,
16
- rowActions: m,
14
+ selectable: j = !1,
15
+ onRowSelect: m,
16
+ rowActions: x,
17
17
  stickyHeader: $ = !1,
18
18
  loading: a = !1,
19
19
  emptyStateMessage: y,
20
20
  pagination: n,
21
21
  onRowClick: f,
22
- rowClassName: j,
22
+ rowClassName: u,
23
23
  isRowDisabled: d,
24
24
  breakpoint: I = "md",
25
25
  alignHeader: C = "start"
26
26
  }) {
27
- const [h, p] = v([]), [S, g] = v(I), [_, B] = v(null), { t: K } = J();
27
+ const [h, p] = v([]), [S, g] = v(I), [N, B] = v(null), { t: _ } = G();
28
28
  E(() => {
29
29
  const e = () => {
30
30
  B(null);
@@ -39,36 +39,36 @@ function de({
39
39
  };
40
40
  return e(), window.addEventListener("resize", e), () => window.removeEventListener("resize", e);
41
41
  }, []);
42
- const P = G(() => T.filter((e) => typeof e.hidden == "function" ? !e.hidden(S) : !e.hidden), [T, S]), M = () => {
43
- h.length === i.length ? p([]) : p([...i]), x && x(h.length === i.length ? [] : [...i]);
44
- }, V = (e) => {
42
+ const P = q(() => T.filter((e) => typeof e.hidden == "function" ? !e.hidden(S) : !e.hidden), [T, S]), K = () => {
43
+ h.length === c.length ? p([]) : p([...c]), m && m(h.length === c.length ? [] : [...c]);
44
+ }, M = (e) => {
45
45
  const l = h.filter((s) => e[r] === s[r]);
46
46
  return l && l.length > 0;
47
- }, q = (e) => {
47
+ }, V = (e) => {
48
48
  const l = h.some((o) => o[r] === e[r]);
49
49
  let s;
50
- l ? s = h.filter((o) => o[r] !== e[r]) : s = [...h, e], p(s), x && x(s);
50
+ l ? s = h.filter((o) => o[r] !== e[r]) : s = [...h, e], p(s), m && m(s);
51
51
  };
52
52
  return /* @__PURE__ */ t.jsxs(Y, { children: [
53
- a && /* @__PURE__ */ t.jsx(Z, { children: /* @__PURE__ */ t.jsx(N, { size: "3rem" }) }),
53
+ a && /* @__PURE__ */ t.jsx(Z, { children: /* @__PURE__ */ t.jsx(J, { size: "3rem" }) }),
54
54
  /* @__PURE__ */ t.jsxs(H, { children: [
55
55
  /* @__PURE__ */ t.jsx(D, { children: /* @__PURE__ */ t.jsxs(k, { children: [
56
56
  /* @__PURE__ */ t.jsx(
57
57
  O,
58
58
  {
59
- data: i,
60
- handleSelectAll: M,
59
+ data: c,
60
+ handleSelectAll: K,
61
61
  selectedRows: h,
62
62
  visibleColumns: P,
63
63
  alignHeader: C,
64
64
  rowActions: void 0,
65
65
  stickyHeader: $,
66
- selectable: u,
66
+ selectable: j,
67
67
  loading: a
68
68
  }
69
69
  ),
70
- /* @__PURE__ */ t.jsx(z, { children: i.length === 0 ? /* @__PURE__ */ t.jsx("tr", { children: /* @__PURE__ */ t.jsx("td", { colSpan: (u ? 1 : 0) + P.length, children: /* @__PURE__ */ t.jsx(F, { children: /* @__PURE__ */ t.jsx(U, { variant: "mdText", children: y ?? K("NO_DATA_AVAILABLE") }) }) }) }) : i.map((e, l) => {
71
- const s = (d == null ? void 0 : d(e)) ?? !1, o = h.some((c) => c[r] === e[r]), A = e[r];
70
+ /* @__PURE__ */ t.jsx(z, { children: c.length === 0 ? /* @__PURE__ */ t.jsx("tr", { children: /* @__PURE__ */ t.jsx("td", { colSpan: (j ? 1 : 0) + P.length, children: /* @__PURE__ */ t.jsx(F, { children: /* @__PURE__ */ t.jsx(U, { variant: "mdText", children: y ?? _("NO_DATA_AVAILABLE") }) }) }) }) : c.map((e, l) => {
71
+ const s = (d == null ? void 0 : d(e)) ?? !1, o = h.some((i) => i[r] === e[r]), A = e[r];
72
72
  return /* @__PURE__ */ t.jsxs(
73
73
  W,
74
74
  {
@@ -76,55 +76,56 @@ function de({
76
76
  $disabled: s,
77
77
  $clickable: !!f && !s,
78
78
  onClick: () => !s && (f == null ? void 0 : f(e)),
79
- className: (j == null ? void 0 : j(e, l)) ?? "",
79
+ className: (u == null ? void 0 : u(e, l)) ?? "",
80
80
  children: [
81
- u && /* @__PURE__ */ t.jsx(b, { $align: "center", $isFirstColumn: !0, children: /* @__PURE__ */ t.jsx(
81
+ j && /* @__PURE__ */ t.jsx(b, { $align: "center", $isFirstColumn: !0, children: /* @__PURE__ */ t.jsx(
82
82
  X,
83
83
  {
84
84
  checkBoxOptions: {
85
- checked: V(e),
85
+ checked: M(e),
86
86
  $variant: "primary",
87
87
  $disabled: s,
88
88
  $size: "sm",
89
- onChange: () => !s && q(e)
89
+ onChange: () => !s && V(e)
90
90
  }
91
91
  }
92
92
  ) }),
93
- P.map((c) => /* @__PURE__ */ t.jsx(b, { $align: c.align, children: /* @__PURE__ */ t.jsx(
93
+ P.map((i) => /* @__PURE__ */ t.jsx(b, { $align: i.align, children: /* @__PURE__ */ t.jsx(
94
94
  L,
95
95
  {
96
- column: c,
96
+ column: i,
97
97
  row: e,
98
- type: c.cellType ?? "text",
99
- align: c.align,
100
- width: c.width ?? "",
101
- minWidth: c.minWidth ?? "",
102
- maxWidth: c.maxWidth ?? ""
98
+ type: i.cellType ?? "text",
99
+ align: i.align,
100
+ className: i.className,
101
+ width: i.width ?? "",
102
+ minWidth: i.minWidth ?? "",
103
+ maxWidth: i.maxWidth ?? ""
103
104
  }
104
- ) }, `${A}-${c.id}`))
105
+ ) }, `${A}-${i.id}`))
105
106
  ]
106
107
  },
107
108
  A
108
109
  );
109
110
  }) })
110
111
  ] }) }),
111
- m && m.length > 0 && /* @__PURE__ */ t.jsxs(R, { children: [
112
+ x && x.length > 0 && /* @__PURE__ */ t.jsxs(R, { children: [
112
113
  /* @__PURE__ */ t.jsx(
113
114
  O,
114
115
  {
115
- data: i,
116
+ data: c,
116
117
  handleSelectAll: () => {
117
118
  },
118
119
  selectedRows: h,
119
120
  visibleColumns: [],
120
121
  alignHeader: C,
121
- rowActions: m,
122
+ rowActions: x,
122
123
  stickyHeader: $,
123
124
  selectable: !1,
124
125
  loading: a
125
126
  }
126
127
  ),
127
- /* @__PURE__ */ t.jsx(z, { children: i.length === 0 ? /* @__PURE__ */ t.jsx("tr", { children: /* @__PURE__ */ t.jsx("td", { children: /* @__PURE__ */ t.jsx("div", { style: { height: "3.5rem" } }) }) }) : i.map((e) => {
128
+ /* @__PURE__ */ t.jsx(z, { children: c.length === 0 ? /* @__PURE__ */ t.jsx("tr", { children: /* @__PURE__ */ t.jsx("td", { children: /* @__PURE__ */ t.jsx("div", { style: { height: "3.5rem" } }) }) }) : c.map((e) => {
128
129
  const l = (d == null ? void 0 : d(e)) ?? !1;
129
130
  return /* @__PURE__ */ t.jsx(W, { $disabled: l, children: /* @__PURE__ */ t.jsx(b, { $align: "center", $isActionCell: !0, children: /* @__PURE__ */ t.jsx(
130
131
  L,
@@ -133,8 +134,8 @@ function de({
133
134
  type: "icon",
134
135
  iconOptions: {
135
136
  keyField: r,
136
- rowActions: m,
137
- activeDropdown: _,
137
+ rowActions: x,
138
+ activeDropdown: N,
138
139
  setActiveDropdown: B
139
140
  }
140
141
  }
@@ -4,6 +4,7 @@ export type TableColumn<T> = {
4
4
  id: string;
5
5
  header: string | React.ReactNode;
6
6
  accessor: keyof T | ((row: T) => React.ReactNode);
7
+ className?: string;
7
8
  width?: string;
8
9
  minWidth?: string;
9
10
  maxWidth?: string;
@@ -25,7 +25,7 @@ const i = g.div`
25
25
  duplicate: /* @__PURE__ */ r.jsx(j, {}),
26
26
  approve: /* @__PURE__ */ r.jsx(u, {}),
27
27
  print: /* @__PURE__ */ r.jsx(u, {})
28
- }, R = (e) => E[e.toLowerCase()] ?? null, D = ({ data: e, type: t, width: s, maxWidth: n, minWidth: o }) => /* @__PURE__ */ r.jsx(i, { width: s, maxWidth: n, minWidth: o, children: e && /* @__PURE__ */ r.jsx(d, { data: e, type: t, width: s }) }), L = ({ data: e, type: t, width: s, maxWidth: n, minWidth: o }) => /* @__PURE__ */ r.jsx(i, { width: s, maxWidth: n, minWidth: o, children: e && /* @__PURE__ */ r.jsx(d, { data: e, type: t, width: s }) }), M = ({ data: e, type: t, width: s, maxWidth: n, minWidth: o }) => /* @__PURE__ */ r.jsx(i, { width: s, maxWidth: n, minWidth: o, children: e && /* @__PURE__ */ r.jsx(d, { data: e, type: t, width: s }) }), S = ({ data: e, type: t, width: s, maxWidth: n, minWidth: o }) => /* @__PURE__ */ r.jsx(i, { width: s, maxWidth: n, minWidth: o, children: e && /* @__PURE__ */ r.jsx(d, { data: e, type: t, width: s }) }), V = ({ data: e, type: t, width: s, maxWidth: n, minWidth: o }) => /* @__PURE__ */ r.jsx(i, { width: s, maxWidth: n, minWidth: o, children: e && /* @__PURE__ */ r.jsx(b, { data: e, type: t, width: s }) }), H = ({ data: e, width: t, maxWidth: s, minWidth: n }) => /* @__PURE__ */ r.jsx(i, { width: t, maxWidth: s, minWidth: n, children: /* @__PURE__ */ r.jsx($, { value: e.value, direction: e.transactionType }) }), K = ({ checkBoxOptions: e, width: t, maxWidth: s, minWidth: n }) => {
28
+ }, R = (e) => E[e.toLowerCase()] ?? null, D = ({ data: e, type: t, width: s, maxWidth: n, minWidth: o }) => /* @__PURE__ */ r.jsx(i, { width: s, maxWidth: n, minWidth: o, children: e && /* @__PURE__ */ r.jsx(d, { data: e, type: t, width: s }) }), L = ({ data: e, type: t, width: s, maxWidth: n, minWidth: o }) => /* @__PURE__ */ r.jsx(i, { width: s, maxWidth: n, minWidth: o, children: e && /* @__PURE__ */ r.jsx(d, { data: e, type: t, width: s }) }), M = ({ data: e, type: t, width: s, maxWidth: n, minWidth: o }) => /* @__PURE__ */ r.jsx(i, { width: s, maxWidth: n, minWidth: o, children: e && /* @__PURE__ */ r.jsx(d, { data: e, type: t, width: s }) }), S = ({ data: e, type: t, width: s, maxWidth: n, minWidth: o, className: c }) => /* @__PURE__ */ r.jsx(i, { className: c, width: s, maxWidth: n, minWidth: o, children: e && /* @__PURE__ */ r.jsx(d, { data: e, type: t, width: s }) }), V = ({ data: e, type: t, width: s, maxWidth: n, minWidth: o }) => /* @__PURE__ */ r.jsx(i, { width: s, maxWidth: n, minWidth: o, children: e && /* @__PURE__ */ r.jsx(b, { data: e, type: t, width: s }) }), H = ({ data: e, width: t, maxWidth: s, minWidth: n }) => /* @__PURE__ */ r.jsx(i, { width: t, maxWidth: s, minWidth: n, children: /* @__PURE__ */ r.jsx($, { value: e.value, direction: e.transactionType }) }), K = ({ checkBoxOptions: e, width: t, maxWidth: s, minWidth: n }) => {
29
29
  const o = e ? { ...e, name: e.name ?? "" } : void 0;
30
30
  return /* @__PURE__ */ r.jsx(i, { width: t, maxWidth: s, minWidth: n, children: /* @__PURE__ */ r.jsx(F, { ...o }) });
31
31
  }, P = ({ radioButtonOptions: e, width: t, maxWidth: s, minWidth: n }) => {
@@ -1,4 +1,4 @@
1
- import k from "../../../_virtual/index.js";
1
+ import k from "../../../_virtual/index3.js";
2
2
  import * as v from "react";
3
3
  import N from "../../uncontrollable/lib/esm/hook.js";
4
4
  import "../../../_virtual/browser.js";