@adiba-banking-cloud/backoffice 0.0.106 → 0.2.1
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/build/index.cjs.js/{heatmap-BJmii0aO.js → heatmap-D-qDlLOI.js} +1 -1
- package/build/index.cjs.js/{index-BLpjQkzt.js → index-CWyl7EKZ.js} +318 -1
- package/build/index.cjs.js/index.js +14 -1
- package/build/index.esm.js/{heatmap-yNnNxsAY.js → heatmap-CtdCSRhG.js} +1 -1
- package/build/index.esm.js/{index-CWjYoFnK.js → index-D7Cza3cb.js} +591 -282
- package/build/index.esm.js/index.js +6 -1
- package/build/typings/index.d.ts +5 -0
- package/build/typings/shared/api/client.d.ts +24 -0
- package/build/typings/shared/api/constants.d.ts +12 -0
- package/build/typings/shared/api/index.d.ts +3 -0
- package/build/typings/shared/api/types.d.ts +26 -0
- package/build/typings/shared/components/ModalContentWrapper.d.ts +9 -0
- package/build/typings/shared/components/index.d.ts +1 -0
- package/build/typings/shared/hocs/index.d.ts +1 -0
- package/build/typings/shared/hocs/withProviders.d.ts +49 -0
- package/build/typings/shared/hooks/index.d.ts +1 -0
- package/build/typings/shared/hooks/useUrlFilters.d.ts +88 -0
- package/build/typings/shared/types/index.d.ts +1 -0
- package/build/typings/shared/types/pagination.d.ts +16 -0
- package/package.json +10 -2
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
import { modals } from '@mantine/modals';
|
|
2
|
-
import
|
|
3
|
-
import
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import React__default, { useRef, useMemo, useEffect, useState } from 'react';
|
|
4
|
+
import { Center, Image, Space, Popover, Button, Stack, Divider, Group, Text, Menu, Avatar, Badge, NavLink, Card, TextInput, ActionIcon, Box, Title, SegmentedControl, Breadcrumbs, Anchor, ColorSwatch, AspectRatio, Overlay, rem, SimpleGrid, Indicator, Table, createTheme, PinInput, Drawer as Drawer$1, ScrollArea, NumberInput, PasswordInput, Textarea, Grid, MantineProvider } from '@mantine/core';
|
|
4
5
|
import { DotLottieReact } from '@lottiefiles/dotlottie-react';
|
|
5
6
|
import _extends from '@babel/runtime/helpers/extends';
|
|
6
7
|
import HighchartsReact from 'highcharts-react-official';
|
|
7
8
|
import HighchartsRounded from 'highcharts-rounded-corners';
|
|
8
9
|
import * as IconSax from 'iconsax-react';
|
|
9
|
-
import { Link } from 'react-router-dom';
|
|
10
|
+
import { Link, useSearchParams } from 'react-router-dom';
|
|
10
11
|
import { useDisclosure, useToggle } from '@mantine/hooks';
|
|
11
12
|
import { useForm } from '@mantine/form';
|
|
12
13
|
import '@fontsource/poppins/100.css';
|
|
@@ -17,6 +18,11 @@ import '@fontsource/poppins/500.css';
|
|
|
17
18
|
import '@fontsource/poppins/600.css';
|
|
18
19
|
import '@fontsource/poppins/700.css';
|
|
19
20
|
import '@fontsource/poppins/800.css';
|
|
21
|
+
import axios from 'axios';
|
|
22
|
+
import { DatesProvider } from '@mantine/dates';
|
|
23
|
+
import '@mantine/dates/styles.css';
|
|
24
|
+
import { QueryClient, QueryClientProvider } from '@tanstack/react-query';
|
|
25
|
+
import { ReactQueryDevtools } from '@tanstack/react-query-devtools';
|
|
20
26
|
|
|
21
27
|
function _mergeNamespaces(n, m) {
|
|
22
28
|
m.forEach(function (e) {
|
|
@@ -11345,7 +11351,7 @@ const Column = props => {
|
|
|
11345
11351
|
chartRef.current.chart.update(chartOptions, true);
|
|
11346
11352
|
}
|
|
11347
11353
|
}, [chartOptions]);
|
|
11348
|
-
return /*#__PURE__*/
|
|
11354
|
+
return /*#__PURE__*/React__default.createElement(HighchartsReact, {
|
|
11349
11355
|
highcharts: Highcharts,
|
|
11350
11356
|
ref: chartRef,
|
|
11351
11357
|
options: chartOptions
|
|
@@ -11368,7 +11374,7 @@ const EqualizerColumn = props => {
|
|
|
11368
11374
|
showYLabel: props.showYLabel,
|
|
11369
11375
|
showAxisLabel: props.showAxisLabel
|
|
11370
11376
|
};
|
|
11371
|
-
return /*#__PURE__*/
|
|
11377
|
+
return /*#__PURE__*/React__default.createElement(Column, chartOptions);
|
|
11372
11378
|
};
|
|
11373
11379
|
const SimpleColumn = props => {
|
|
11374
11380
|
const chartOptions = {
|
|
@@ -11387,10 +11393,10 @@ const SimpleColumn = props => {
|
|
|
11387
11393
|
showYLabel: props.showYLabel,
|
|
11388
11394
|
showAxisLabel: props.showAxisLabel
|
|
11389
11395
|
};
|
|
11390
|
-
return /*#__PURE__*/
|
|
11396
|
+
return /*#__PURE__*/React__default.createElement(Column, chartOptions);
|
|
11391
11397
|
};
|
|
11392
11398
|
const StackedColumn = props => {
|
|
11393
|
-
return /*#__PURE__*/
|
|
11399
|
+
return /*#__PURE__*/React__default.createElement(Column, _extends({}, props, {
|
|
11394
11400
|
equalizer: false
|
|
11395
11401
|
}));
|
|
11396
11402
|
};
|
|
@@ -11688,7 +11694,7 @@ const Area = props => {
|
|
|
11688
11694
|
chartRef.current.chart.update(chartOptions, true);
|
|
11689
11695
|
}
|
|
11690
11696
|
}, [chartOptions]);
|
|
11691
|
-
return /*#__PURE__*/
|
|
11697
|
+
return /*#__PURE__*/React__default.createElement(HighchartsReact, {
|
|
11692
11698
|
highcharts: Highcharts,
|
|
11693
11699
|
ref: chartRef,
|
|
11694
11700
|
options: chartOptions
|
|
@@ -11709,7 +11715,7 @@ const SimpleArea = props => {
|
|
|
11709
11715
|
showYAxis: props.showYAxis,
|
|
11710
11716
|
step: props.step
|
|
11711
11717
|
};
|
|
11712
|
-
return /*#__PURE__*/
|
|
11718
|
+
return /*#__PURE__*/React__default.createElement(Area, chartOptions);
|
|
11713
11719
|
};
|
|
11714
11720
|
const MultiAxisArea = props => {
|
|
11715
11721
|
const chartRef = useRef(null);
|
|
@@ -11727,7 +11733,7 @@ const MultiAxisArea = props => {
|
|
|
11727
11733
|
chartRef.current.chart.update(chartOptions, true);
|
|
11728
11734
|
}
|
|
11729
11735
|
}, [chartOptions]);
|
|
11730
|
-
return /*#__PURE__*/
|
|
11736
|
+
return /*#__PURE__*/React__default.createElement(HighchartsReact, {
|
|
11731
11737
|
highcharts: Highcharts,
|
|
11732
11738
|
ref: chartRef,
|
|
11733
11739
|
options: chartOptions
|
|
@@ -11749,7 +11755,7 @@ const StackedArea = props => {
|
|
|
11749
11755
|
chartRef.current.chart.update(chartOptions, true);
|
|
11750
11756
|
}
|
|
11751
11757
|
}, [chartOptions]);
|
|
11752
|
-
return /*#__PURE__*/
|
|
11758
|
+
return /*#__PURE__*/React__default.createElement(HighchartsReact, {
|
|
11753
11759
|
highcharts: Highcharts,
|
|
11754
11760
|
ref: chartRef,
|
|
11755
11761
|
options: chartOptions
|
|
@@ -12145,7 +12151,7 @@ const initChart$1 = props => {
|
|
|
12145
12151
|
}
|
|
12146
12152
|
|
|
12147
12153
|
// Fallback: use dynamic import (async, but will work in Vite/Storybook)
|
|
12148
|
-
import('./heatmap-
|
|
12154
|
+
import('./heatmap-CtdCSRhG.js').then(function (n) { return n.h; }).then(heatmapModule => {
|
|
12149
12155
|
const moduleFn = typeof heatmapModule === "function" ? heatmapModule : heatmapModule?.default || heatmapModule;
|
|
12150
12156
|
if (typeof moduleFn === "function") {
|
|
12151
12157
|
moduleFn(Highcharts);
|
|
@@ -12170,7 +12176,7 @@ const Heatmap = props => {
|
|
|
12170
12176
|
chartRef.current.chart.update(chartOptions, true);
|
|
12171
12177
|
}
|
|
12172
12178
|
}, [chartOptions]);
|
|
12173
|
-
return /*#__PURE__*/
|
|
12179
|
+
return /*#__PURE__*/React__default.createElement(HighchartsReact, {
|
|
12174
12180
|
highcharts: Highcharts,
|
|
12175
12181
|
ref: chartRef,
|
|
12176
12182
|
options: chartOptions
|
|
@@ -12386,17 +12392,17 @@ const initCalendarSeries = props => {
|
|
|
12386
12392
|
};
|
|
12387
12393
|
};
|
|
12388
12394
|
const BasicHeatmap = props => {
|
|
12389
|
-
return /*#__PURE__*/
|
|
12395
|
+
return /*#__PURE__*/React__default.createElement(Heatmap, _extends({}, props, {
|
|
12390
12396
|
type: "basic"
|
|
12391
12397
|
}));
|
|
12392
12398
|
};
|
|
12393
12399
|
const InterpolatedHeatmap = props => {
|
|
12394
|
-
return /*#__PURE__*/
|
|
12400
|
+
return /*#__PURE__*/React__default.createElement(Heatmap, _extends({}, props, {
|
|
12395
12401
|
type: "interpolated"
|
|
12396
12402
|
}));
|
|
12397
12403
|
};
|
|
12398
12404
|
const CalendarHeatmap = props => {
|
|
12399
|
-
return /*#__PURE__*/
|
|
12405
|
+
return /*#__PURE__*/React__default.createElement(Heatmap, _extends({}, props, {
|
|
12400
12406
|
type: "calendar"
|
|
12401
12407
|
}));
|
|
12402
12408
|
};
|
|
@@ -12502,7 +12508,7 @@ const DonutChart = props => {
|
|
|
12502
12508
|
chartRef.current.chart.update(chartOptions, true);
|
|
12503
12509
|
}
|
|
12504
12510
|
}, [chartOptions]);
|
|
12505
|
-
return /*#__PURE__*/
|
|
12511
|
+
return /*#__PURE__*/React__default.createElement(HighchartsReact, {
|
|
12506
12512
|
highcharts: Highcharts$1,
|
|
12507
12513
|
ref: chartRef,
|
|
12508
12514
|
options: chartOptions
|
|
@@ -12539,7 +12545,7 @@ const Icons = _ref => {
|
|
|
12539
12545
|
color
|
|
12540
12546
|
} = _ref;
|
|
12541
12547
|
const Element = IconSax[name];
|
|
12542
|
-
return /*#__PURE__*/
|
|
12548
|
+
return /*#__PURE__*/React__default.createElement(Element, {
|
|
12543
12549
|
size,
|
|
12544
12550
|
color,
|
|
12545
12551
|
variant,
|
|
@@ -12561,15 +12567,15 @@ const Logo = _ref => {
|
|
|
12561
12567
|
fit,
|
|
12562
12568
|
...rest
|
|
12563
12569
|
} = _ref;
|
|
12564
|
-
return /*#__PURE__*/
|
|
12570
|
+
return /*#__PURE__*/React__default.createElement(Center, _extends({}, rest, {
|
|
12565
12571
|
component: Link,
|
|
12566
12572
|
display: "flex",
|
|
12567
12573
|
to: href
|
|
12568
|
-
}), /*#__PURE__*/
|
|
12574
|
+
}), /*#__PURE__*/React__default.createElement(Image, {
|
|
12569
12575
|
fallbackSrc: fallbackSrc,
|
|
12570
12576
|
src: src,
|
|
12571
12577
|
fit: fit
|
|
12572
|
-
}), /*#__PURE__*/
|
|
12578
|
+
}), /*#__PURE__*/React__default.createElement(Space, {
|
|
12573
12579
|
flex: 1,
|
|
12574
12580
|
hidden: true
|
|
12575
12581
|
}));
|
|
@@ -12582,7 +12588,7 @@ const DynamicLogo = _ref2 => {
|
|
|
12582
12588
|
w = 180,
|
|
12583
12589
|
...rest
|
|
12584
12590
|
} = _ref2;
|
|
12585
|
-
return /*#__PURE__*/
|
|
12591
|
+
return /*#__PURE__*/React__default.createElement(Logo, _extends({}, rest, {
|
|
12586
12592
|
href,
|
|
12587
12593
|
src,
|
|
12588
12594
|
fit,
|
|
@@ -12596,7 +12602,7 @@ const DynamicShigaLogo = _ref3 => {
|
|
|
12596
12602
|
fit = "contain",
|
|
12597
12603
|
...rest
|
|
12598
12604
|
} = _ref3;
|
|
12599
|
-
return /*#__PURE__*/
|
|
12605
|
+
return /*#__PURE__*/React__default.createElement(Logo, _extends({}, rest, {
|
|
12600
12606
|
href,
|
|
12601
12607
|
src,
|
|
12602
12608
|
fit,
|
|
@@ -12610,13 +12616,13 @@ const ApplicationMenuTarget = _ref => {
|
|
|
12610
12616
|
toggle,
|
|
12611
12617
|
...rest
|
|
12612
12618
|
} = _ref;
|
|
12613
|
-
return /*#__PURE__*/
|
|
12619
|
+
return /*#__PURE__*/React__default.createElement(Popover.Target, null, /*#__PURE__*/React__default.createElement(Button, {
|
|
12614
12620
|
variant: "transparent",
|
|
12615
12621
|
justify: "space-between",
|
|
12616
12622
|
h: 60,
|
|
12617
12623
|
fw: 300,
|
|
12618
12624
|
w: 200,
|
|
12619
|
-
rightSection: /*#__PURE__*/
|
|
12625
|
+
rightSection: /*#__PURE__*/React__default.createElement(Icons, {
|
|
12620
12626
|
name: "ArrowDown2",
|
|
12621
12627
|
size: 16
|
|
12622
12628
|
}),
|
|
@@ -12631,32 +12637,32 @@ const ApplicationMenuDropdown = _ref => {
|
|
|
12631
12637
|
moreLink,
|
|
12632
12638
|
toggle
|
|
12633
12639
|
} = _ref;
|
|
12634
|
-
return /*#__PURE__*/
|
|
12640
|
+
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(Popover.Dropdown, {
|
|
12635
12641
|
ml: "md",
|
|
12636
12642
|
p: 5
|
|
12637
|
-
}, /*#__PURE__*/
|
|
12643
|
+
}, /*#__PURE__*/React__default.createElement(Stack, {
|
|
12638
12644
|
gap: 5,
|
|
12639
12645
|
p: 0
|
|
12640
|
-
}, /*#__PURE__*/
|
|
12646
|
+
}, /*#__PURE__*/React__default.createElement(Stack, {
|
|
12641
12647
|
gap: 5,
|
|
12642
12648
|
align: "flex-start"
|
|
12643
|
-
}, items.map((item, index) => /*#__PURE__*/
|
|
12649
|
+
}, items.map((item, index) => /*#__PURE__*/React__default.createElement(DropdownItem, _extends({
|
|
12644
12650
|
key: `item-${index}`
|
|
12645
12651
|
}, item, {
|
|
12646
12652
|
onClick: e => {
|
|
12647
12653
|
toggle();
|
|
12648
12654
|
item.onClick(e);
|
|
12649
12655
|
}
|
|
12650
|
-
})))), /*#__PURE__*/
|
|
12656
|
+
})))), /*#__PURE__*/React__default.createElement(Divider, null), /*#__PURE__*/React__default.createElement(Group, {
|
|
12651
12657
|
grow: true,
|
|
12652
12658
|
justify: "center"
|
|
12653
|
-
}, /*#__PURE__*/
|
|
12659
|
+
}, /*#__PURE__*/React__default.createElement(Button, {
|
|
12654
12660
|
variant: "subtle",
|
|
12655
12661
|
p: 0,
|
|
12656
12662
|
component: Link,
|
|
12657
12663
|
to: moreLink,
|
|
12658
12664
|
onClick: toggle
|
|
12659
|
-
}, /*#__PURE__*/
|
|
12665
|
+
}, /*#__PURE__*/React__default.createElement(Text, {
|
|
12660
12666
|
size: "xs",
|
|
12661
12667
|
fw: 300,
|
|
12662
12668
|
w: 320
|
|
@@ -12674,7 +12680,7 @@ const DropdownItem = _ref2 => {
|
|
|
12674
12680
|
id,
|
|
12675
12681
|
onClick
|
|
12676
12682
|
} = _ref2;
|
|
12677
|
-
return /*#__PURE__*/
|
|
12683
|
+
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(Button, {
|
|
12678
12684
|
variant: "subtle",
|
|
12679
12685
|
fw: 300,
|
|
12680
12686
|
mih: 70,
|
|
@@ -12682,15 +12688,15 @@ const DropdownItem = _ref2 => {
|
|
|
12682
12688
|
c: active ? activeColor : inactiveColor,
|
|
12683
12689
|
onClick: onClick,
|
|
12684
12690
|
"data-index": id
|
|
12685
|
-
}, /*#__PURE__*/
|
|
12691
|
+
}, /*#__PURE__*/React__default.createElement(Group, {
|
|
12686
12692
|
w: 320
|
|
12687
|
-
}, /*#__PURE__*/
|
|
12693
|
+
}, /*#__PURE__*/React__default.createElement(Icons, icon), /*#__PURE__*/React__default.createElement(Stack, {
|
|
12688
12694
|
align: "flex-start",
|
|
12689
12695
|
gap: 5
|
|
12690
|
-
}, /*#__PURE__*/
|
|
12696
|
+
}, /*#__PURE__*/React__default.createElement(Text, {
|
|
12691
12697
|
size: "sm",
|
|
12692
12698
|
fw: 300
|
|
12693
|
-
}, title), /*#__PURE__*/
|
|
12699
|
+
}, title), /*#__PURE__*/React__default.createElement(Text, {
|
|
12694
12700
|
size: "xs",
|
|
12695
12701
|
fz: 11,
|
|
12696
12702
|
fw: 300
|
|
@@ -12708,7 +12714,7 @@ const ApplicationMenu = _ref => {
|
|
|
12708
12714
|
const [opened, {
|
|
12709
12715
|
toggle
|
|
12710
12716
|
}] = useDisclosure(false);
|
|
12711
|
-
return /*#__PURE__*/
|
|
12717
|
+
return /*#__PURE__*/React__default.createElement(Popover, {
|
|
12712
12718
|
transitionProps: {
|
|
12713
12719
|
transition
|
|
12714
12720
|
},
|
|
@@ -12722,9 +12728,9 @@ const ApplicationMenu = _ref => {
|
|
|
12722
12728
|
radius: "sm",
|
|
12723
12729
|
opened: opened,
|
|
12724
12730
|
onChange: toggle
|
|
12725
|
-
}, /*#__PURE__*/
|
|
12731
|
+
}, /*#__PURE__*/React__default.createElement(ApplicationMenuTarget, {
|
|
12726
12732
|
toggle
|
|
12727
|
-
}, label), /*#__PURE__*/
|
|
12733
|
+
}, label), /*#__PURE__*/React__default.createElement(ApplicationMenuDropdown, {
|
|
12728
12734
|
items,
|
|
12729
12735
|
moreLink,
|
|
12730
12736
|
moreText,
|
|
@@ -12738,32 +12744,32 @@ const UserMenuTarget = _ref => {
|
|
|
12738
12744
|
username,
|
|
12739
12745
|
avatar
|
|
12740
12746
|
} = _ref;
|
|
12741
|
-
return /*#__PURE__*/
|
|
12747
|
+
return /*#__PURE__*/React__default.createElement(Menu.Target, null, /*#__PURE__*/React__default.createElement(Button, {
|
|
12742
12748
|
variant: "subtle",
|
|
12743
12749
|
h: 50,
|
|
12744
12750
|
px: 10,
|
|
12745
12751
|
radius: "md"
|
|
12746
|
-
}, /*#__PURE__*/
|
|
12752
|
+
}, /*#__PURE__*/React__default.createElement(Group, {
|
|
12747
12753
|
gap: "sm"
|
|
12748
|
-
}, /*#__PURE__*/
|
|
12754
|
+
}, /*#__PURE__*/React__default.createElement(Avatar, {
|
|
12749
12755
|
src: avatar,
|
|
12750
12756
|
radius: "md",
|
|
12751
12757
|
key: name,
|
|
12752
12758
|
name: name,
|
|
12753
12759
|
color: "initials",
|
|
12754
12760
|
bd: "0.5px solid adiba.2"
|
|
12755
|
-
}), /*#__PURE__*/
|
|
12761
|
+
}), /*#__PURE__*/React__default.createElement(Stack, {
|
|
12756
12762
|
gap: 0,
|
|
12757
12763
|
align: "flex-start",
|
|
12758
12764
|
visibleFrom: "md",
|
|
12759
12765
|
fw: 300
|
|
12760
|
-
}, /*#__PURE__*/
|
|
12766
|
+
}, /*#__PURE__*/React__default.createElement(Text, {
|
|
12761
12767
|
fw: 300,
|
|
12762
12768
|
size: "sm"
|
|
12763
|
-
}, name), /*#__PURE__*/
|
|
12769
|
+
}, name), /*#__PURE__*/React__default.createElement(Text, {
|
|
12764
12770
|
c: "dimmed",
|
|
12765
12771
|
size: "xs"
|
|
12766
|
-
}, username)), /*#__PURE__*/
|
|
12772
|
+
}, username)), /*#__PURE__*/React__default.createElement(Icons, {
|
|
12767
12773
|
name: "ArrowDown2",
|
|
12768
12774
|
size: 12
|
|
12769
12775
|
}))));
|
|
@@ -12774,33 +12780,33 @@ const UserMenuDropdown = _ref => {
|
|
|
12774
12780
|
sections,
|
|
12775
12781
|
height = 40
|
|
12776
12782
|
} = _ref;
|
|
12777
|
-
return /*#__PURE__*/
|
|
12783
|
+
return /*#__PURE__*/React__default.createElement(Menu.Dropdown, null, sections.map((section, index) => {
|
|
12778
12784
|
const items = [];
|
|
12779
|
-
const sectionItems = section.items.map((item, key) => /*#__PURE__*/
|
|
12785
|
+
const sectionItems = section.items.map((item, key) => /*#__PURE__*/React__default.createElement(Menu.Item, {
|
|
12780
12786
|
c: section?.color,
|
|
12781
12787
|
key: `menu-item-${key}`,
|
|
12782
12788
|
h: height,
|
|
12783
|
-
leftSection: /*#__PURE__*/
|
|
12789
|
+
leftSection: /*#__PURE__*/React__default.createElement(Icons, _extends({}, item.icon, {
|
|
12784
12790
|
stroke: 0.5
|
|
12785
12791
|
})),
|
|
12786
|
-
rightSection: item?.disclosure ? /*#__PURE__*/
|
|
12792
|
+
rightSection: item?.disclosure ? /*#__PURE__*/React__default.createElement(Icons, {
|
|
12787
12793
|
name: "ArrowRight2",
|
|
12788
12794
|
size: 12,
|
|
12789
12795
|
stroke: 0.5
|
|
12790
|
-
}) : item.badge ? /*#__PURE__*/
|
|
12796
|
+
}) : item.badge ? /*#__PURE__*/React__default.createElement(Badge, {
|
|
12791
12797
|
color: item?.badge?.color,
|
|
12792
12798
|
size: "sm"
|
|
12793
12799
|
}, item?.badge?.text) : undefined,
|
|
12794
12800
|
onClick: () => item.callbackFn ? item.callbackFn() : void 0
|
|
12795
|
-
}, /*#__PURE__*/
|
|
12801
|
+
}, /*#__PURE__*/React__default.createElement(Text, {
|
|
12796
12802
|
size: "xs",
|
|
12797
12803
|
fw: 300
|
|
12798
12804
|
}, item.label)));
|
|
12799
|
-
if (index) items.push(/*#__PURE__*/
|
|
12805
|
+
if (index) items.push(/*#__PURE__*/React__default.createElement(Divider, {
|
|
12800
12806
|
key: `divider-${index}`,
|
|
12801
12807
|
my: 2
|
|
12802
12808
|
}));
|
|
12803
|
-
if (section?.title) items.push(/*#__PURE__*/
|
|
12809
|
+
if (section?.title) items.push(/*#__PURE__*/React__default.createElement(Menu.Label, {
|
|
12804
12810
|
fz: 10,
|
|
12805
12811
|
fw: 500,
|
|
12806
12812
|
c: "dimmed",
|
|
@@ -12820,7 +12826,7 @@ const UserMenu = _ref => {
|
|
|
12820
12826
|
avatar,
|
|
12821
12827
|
sections
|
|
12822
12828
|
} = _ref;
|
|
12823
|
-
return /*#__PURE__*/
|
|
12829
|
+
return /*#__PURE__*/React__default.createElement(Menu, {
|
|
12824
12830
|
width: width || 250,
|
|
12825
12831
|
transitionProps: {
|
|
12826
12832
|
transition: "pop"
|
|
@@ -12831,11 +12837,11 @@ const UserMenu = _ref => {
|
|
|
12831
12837
|
offset: 5,
|
|
12832
12838
|
arrowOffset: 20,
|
|
12833
12839
|
arrowSize: 10
|
|
12834
|
-
}, /*#__PURE__*/
|
|
12840
|
+
}, /*#__PURE__*/React__default.createElement(UserMenuTarget, {
|
|
12835
12841
|
name,
|
|
12836
12842
|
username,
|
|
12837
12843
|
avatar
|
|
12838
|
-
}), /*#__PURE__*/
|
|
12844
|
+
}), /*#__PURE__*/React__default.createElement(UserMenuDropdown, {
|
|
12839
12845
|
sections,
|
|
12840
12846
|
height
|
|
12841
12847
|
}));
|
|
@@ -12849,7 +12855,7 @@ const SideMenu = _ref => {
|
|
|
12849
12855
|
sidemenu,
|
|
12850
12856
|
onClick
|
|
12851
12857
|
} = _ref;
|
|
12852
|
-
return /*#__PURE__*/
|
|
12858
|
+
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, sidemenu.map(item => /*#__PURE__*/React__default.createElement(NavLink, {
|
|
12853
12859
|
className: "backoffice-sidemenu",
|
|
12854
12860
|
mt: "sm",
|
|
12855
12861
|
component: Link,
|
|
@@ -12861,10 +12867,10 @@ const SideMenu = _ref => {
|
|
|
12861
12867
|
active: item.active,
|
|
12862
12868
|
variant,
|
|
12863
12869
|
onClick,
|
|
12864
|
-
leftSection: item.icon ? /*#__PURE__*/
|
|
12870
|
+
leftSection: item.icon ? /*#__PURE__*/React__default.createElement(Icons, item.icon) : undefined,
|
|
12865
12871
|
label: item.label,
|
|
12866
12872
|
to: item.children?.length ? "#" : item?.href || "#"
|
|
12867
|
-
}, item.children?.length ? item.children.map(subitem => /*#__PURE__*/
|
|
12873
|
+
}, item.children?.length ? item.children.map(subitem => /*#__PURE__*/React__default.createElement(NavLink, {
|
|
12868
12874
|
mt: "xs",
|
|
12869
12875
|
component: Link,
|
|
12870
12876
|
to: subitem.href || "#",
|
|
@@ -12889,7 +12895,7 @@ const SimplePanel = _ref => {
|
|
|
12889
12895
|
children,
|
|
12890
12896
|
...rest
|
|
12891
12897
|
} = _ref;
|
|
12892
|
-
return /*#__PURE__*/
|
|
12898
|
+
return /*#__PURE__*/React__default.createElement(Card, _extends({
|
|
12893
12899
|
p: !withPadding ? 0 : "md",
|
|
12894
12900
|
radius: !withRadius ? 0 : "lg",
|
|
12895
12901
|
flex: autoHeight ? 1 : "none"
|
|
@@ -12902,34 +12908,34 @@ const TitledPanel = _ref2 => {
|
|
|
12902
12908
|
children,
|
|
12903
12909
|
...rest
|
|
12904
12910
|
} = _ref2;
|
|
12905
|
-
return /*#__PURE__*/
|
|
12911
|
+
return /*#__PURE__*/React__default.createElement(SimplePanel, _extends({}, rest, {
|
|
12906
12912
|
withPadding: withPadding
|
|
12907
|
-
}), /*#__PURE__*/
|
|
12913
|
+
}), /*#__PURE__*/React__default.createElement(Group, {
|
|
12908
12914
|
h: 48,
|
|
12909
12915
|
px: withPadding ? 0 : "md",
|
|
12910
12916
|
mt: !withPadding ? "md" : 0,
|
|
12911
12917
|
justify: "space-between"
|
|
12912
|
-
}, /*#__PURE__*/
|
|
12918
|
+
}, /*#__PURE__*/React__default.createElement(Group, null, /*#__PURE__*/React__default.createElement(Center, {
|
|
12913
12919
|
bg: "gray.1",
|
|
12914
12920
|
w: 32,
|
|
12915
12921
|
h: 32,
|
|
12916
12922
|
style: {
|
|
12917
12923
|
borderRadius: "50%"
|
|
12918
12924
|
}
|
|
12919
|
-
}, /*#__PURE__*/
|
|
12925
|
+
}, /*#__PURE__*/React__default.createElement(Icons, _extends({}, title.icon, {
|
|
12920
12926
|
size: 20,
|
|
12921
12927
|
variant: "Bulk"
|
|
12922
|
-
}))), /*#__PURE__*/
|
|
12928
|
+
}))), /*#__PURE__*/React__default.createElement(Text, {
|
|
12923
12929
|
fw: 300
|
|
12924
|
-
}, title.label)), /*#__PURE__*/
|
|
12930
|
+
}, title.label)), /*#__PURE__*/React__default.createElement(Space, {
|
|
12925
12931
|
flex: 1
|
|
12926
|
-
}), /*#__PURE__*/
|
|
12932
|
+
}), /*#__PURE__*/React__default.createElement(Group, {
|
|
12927
12933
|
hidden: !rest.middlesection
|
|
12928
|
-
}, rest.middlesection), /*#__PURE__*/
|
|
12934
|
+
}, rest.middlesection), /*#__PURE__*/React__default.createElement(Space, {
|
|
12929
12935
|
flex: 1
|
|
12930
|
-
}), /*#__PURE__*/
|
|
12936
|
+
}), /*#__PURE__*/React__default.createElement(Group, {
|
|
12931
12937
|
hidden: !rest.rightsection
|
|
12932
|
-
}, rest.rightsection)), /*#__PURE__*/
|
|
12938
|
+
}, rest.rightsection)), /*#__PURE__*/React__default.createElement(Box, {
|
|
12933
12939
|
pt: !withPadding ? 0 : "md"
|
|
12934
12940
|
}, children));
|
|
12935
12941
|
};
|
|
@@ -12955,13 +12961,13 @@ const SearchPanel = _ref3 => {
|
|
|
12955
12961
|
search: search
|
|
12956
12962
|
}
|
|
12957
12963
|
});
|
|
12958
|
-
return /*#__PURE__*/
|
|
12964
|
+
return /*#__PURE__*/React__default.createElement(SimplePanel, rest, /*#__PURE__*/React__default.createElement(Stack, null, /*#__PURE__*/React__default.createElement("form", {
|
|
12959
12965
|
onSubmit: form.onSubmit(values => {
|
|
12960
12966
|
searchFn ? searchFn(values) : void 0;
|
|
12961
12967
|
})
|
|
12962
|
-
}, /*#__PURE__*/
|
|
12968
|
+
}, /*#__PURE__*/React__default.createElement(Group, {
|
|
12963
12969
|
gap: "xs"
|
|
12964
|
-
}, /*#__PURE__*/
|
|
12970
|
+
}, /*#__PURE__*/React__default.createElement(TextInput, {
|
|
12965
12971
|
fw: 300,
|
|
12966
12972
|
name: "search",
|
|
12967
12973
|
size: "md",
|
|
@@ -12969,16 +12975,16 @@ const SearchPanel = _ref3 => {
|
|
|
12969
12975
|
flex: 1,
|
|
12970
12976
|
value: search,
|
|
12971
12977
|
placeholder: placeholder,
|
|
12972
|
-
leftSection: /*#__PURE__*/
|
|
12973
|
-
rightSection: typeof filterFn == "function" ? /*#__PURE__*/
|
|
12978
|
+
leftSection: /*#__PURE__*/React__default.createElement(Icons, searchIcon),
|
|
12979
|
+
rightSection: typeof filterFn == "function" ? /*#__PURE__*/React__default.createElement(ActionIcon, {
|
|
12974
12980
|
variant: "transparent",
|
|
12975
12981
|
onClick: filterFn
|
|
12976
|
-
}, /*#__PURE__*/
|
|
12982
|
+
}, /*#__PURE__*/React__default.createElement(Icons, filterIcon)) : /*#__PURE__*/React__default.createElement(React__default.Fragment, null),
|
|
12977
12983
|
onChange: e => {
|
|
12978
12984
|
setSearch(e.currentTarget.value);
|
|
12979
12985
|
form.setFieldValue("search", e.currentTarget.value);
|
|
12980
12986
|
}
|
|
12981
|
-
}), /*#__PURE__*/
|
|
12987
|
+
}), /*#__PURE__*/React__default.createElement(Button, {
|
|
12982
12988
|
variant: "light",
|
|
12983
12989
|
size: "md",
|
|
12984
12990
|
fw: 300,
|
|
@@ -12986,7 +12992,7 @@ const SearchPanel = _ref3 => {
|
|
|
12986
12992
|
miw: 100,
|
|
12987
12993
|
maw: 150,
|
|
12988
12994
|
type: "submit",
|
|
12989
|
-
leftSection: /*#__PURE__*/
|
|
12995
|
+
leftSection: /*#__PURE__*/React__default.createElement(Icons, searchIcon)
|
|
12990
12996
|
}, searchText))), children));
|
|
12991
12997
|
};
|
|
12992
12998
|
|
|
@@ -12996,13 +13002,13 @@ const LabelPanelItem = _ref => {
|
|
|
12996
13002
|
value,
|
|
12997
13003
|
labelWidth
|
|
12998
13004
|
} = _ref;
|
|
12999
|
-
return /*#__PURE__*/
|
|
13005
|
+
return /*#__PURE__*/React__default.createElement(Group, null, /*#__PURE__*/React__default.createElement(Text, {
|
|
13000
13006
|
fw: 300,
|
|
13001
13007
|
fz: "sm",
|
|
13002
13008
|
c: "dimmed",
|
|
13003
13009
|
w: labelWidth,
|
|
13004
13010
|
truncate: true
|
|
13005
|
-
}, label), /*#__PURE__*/
|
|
13011
|
+
}, label), /*#__PURE__*/React__default.createElement(Text, {
|
|
13006
13012
|
fw: 300,
|
|
13007
13013
|
fz: "sm",
|
|
13008
13014
|
truncate: true
|
|
@@ -13022,19 +13028,19 @@ const LabelPanel = _ref => {
|
|
|
13022
13028
|
p = "md",
|
|
13023
13029
|
...rest
|
|
13024
13030
|
} = _ref;
|
|
13025
|
-
return /*#__PURE__*/
|
|
13031
|
+
return /*#__PURE__*/React__default.createElement(Card, _extends({}, rest, {
|
|
13026
13032
|
withBorder,
|
|
13027
13033
|
radius,
|
|
13028
13034
|
p
|
|
13029
|
-
}), /*#__PURE__*/
|
|
13035
|
+
}), /*#__PURE__*/React__default.createElement(Stack, {
|
|
13030
13036
|
pb: "md"
|
|
13031
|
-
}, /*#__PURE__*/
|
|
13037
|
+
}, /*#__PURE__*/React__default.createElement(Group, {
|
|
13032
13038
|
justify: "space-between",
|
|
13033
13039
|
p: 0
|
|
13034
|
-
}, /*#__PURE__*/
|
|
13040
|
+
}, /*#__PURE__*/React__default.createElement(Title, {
|
|
13035
13041
|
order: 6,
|
|
13036
13042
|
py: "xs"
|
|
13037
|
-
}, title), /*#__PURE__*/
|
|
13043
|
+
}, title), /*#__PURE__*/React__default.createElement(Button, {
|
|
13038
13044
|
style: {
|
|
13039
13045
|
display: hasEdit ? "block" : "none"
|
|
13040
13046
|
},
|
|
@@ -13042,11 +13048,11 @@ const LabelPanel = _ref => {
|
|
|
13042
13048
|
variant: "outline",
|
|
13043
13049
|
onClick: editFn,
|
|
13044
13050
|
size: "xs",
|
|
13045
|
-
leftSection: /*#__PURE__*/
|
|
13051
|
+
leftSection: /*#__PURE__*/React__default.createElement(Icons, {
|
|
13046
13052
|
name: "Edit2"
|
|
13047
13053
|
})
|
|
13048
13054
|
}, editLabel)), items.map((item, index) => {
|
|
13049
|
-
return /*#__PURE__*/
|
|
13055
|
+
return /*#__PURE__*/React__default.createElement(LabelPanelItem, _extends({
|
|
13050
13056
|
key: `label-item-${index}`
|
|
13051
13057
|
}, item, {
|
|
13052
13058
|
labelWidth: labelWidth
|
|
@@ -13069,17 +13075,17 @@ const AvatarLabelPanel = _ref2 => {
|
|
|
13069
13075
|
editFn = void 0,
|
|
13070
13076
|
...rest
|
|
13071
13077
|
} = _ref2;
|
|
13072
|
-
return /*#__PURE__*/
|
|
13078
|
+
return /*#__PURE__*/React__default.createElement(Card, _extends({}, rest, {
|
|
13073
13079
|
withBorder,
|
|
13074
13080
|
radius,
|
|
13075
13081
|
p
|
|
13076
|
-
}), /*#__PURE__*/
|
|
13082
|
+
}), /*#__PURE__*/React__default.createElement(Group, {
|
|
13077
13083
|
align: "flex-start",
|
|
13078
13084
|
py: "sm"
|
|
13079
|
-
}, /*#__PURE__*/
|
|
13085
|
+
}, /*#__PURE__*/React__default.createElement(Box, {
|
|
13080
13086
|
w: labelWidth,
|
|
13081
13087
|
pl: "md"
|
|
13082
|
-
}, /*#__PURE__*/
|
|
13088
|
+
}, /*#__PURE__*/React__default.createElement(Avatar, {
|
|
13083
13089
|
size: avatarSize,
|
|
13084
13090
|
src: avatar,
|
|
13085
13091
|
radius: "md",
|
|
@@ -13087,29 +13093,29 @@ const AvatarLabelPanel = _ref2 => {
|
|
|
13087
13093
|
name: name,
|
|
13088
13094
|
color: "initials",
|
|
13089
13095
|
bd: "0.5px solid adiba.2"
|
|
13090
|
-
})), /*#__PURE__*/
|
|
13096
|
+
})), /*#__PURE__*/React__default.createElement(Stack, {
|
|
13091
13097
|
py: 10,
|
|
13092
13098
|
gap: "md",
|
|
13093
13099
|
h: "100%"
|
|
13094
|
-
}, /*#__PURE__*/
|
|
13100
|
+
}, /*#__PURE__*/React__default.createElement(Title, {
|
|
13095
13101
|
fw: 500,
|
|
13096
13102
|
order: 4
|
|
13097
|
-
}, name), /*#__PURE__*/
|
|
13103
|
+
}, name), /*#__PURE__*/React__default.createElement(Text, {
|
|
13098
13104
|
fw: 300,
|
|
13099
13105
|
fz: 14
|
|
13100
|
-
}, username), /*#__PURE__*/
|
|
13106
|
+
}, username), /*#__PURE__*/React__default.createElement(Text, {
|
|
13101
13107
|
fw: 300,
|
|
13102
13108
|
fz: 14
|
|
13103
|
-
}, "Internal / ", role), /*#__PURE__*/
|
|
13109
|
+
}, "Internal / ", role), /*#__PURE__*/React__default.createElement(Text, {
|
|
13104
13110
|
fw: 300,
|
|
13105
13111
|
fz: 14
|
|
13106
|
-
}, "Last login: ", lastActive)), /*#__PURE__*/
|
|
13112
|
+
}, "Last login: ", lastActive)), /*#__PURE__*/React__default.createElement(Space, {
|
|
13107
13113
|
flex: 1
|
|
13108
|
-
}), /*#__PURE__*/
|
|
13114
|
+
}), /*#__PURE__*/React__default.createElement(Button, {
|
|
13109
13115
|
fw: 300,
|
|
13110
13116
|
variant: "outline",
|
|
13111
13117
|
size: "xs",
|
|
13112
|
-
leftSection: /*#__PURE__*/
|
|
13118
|
+
leftSection: /*#__PURE__*/React__default.createElement(Icons, {
|
|
13113
13119
|
name: "Edit2"
|
|
13114
13120
|
}),
|
|
13115
13121
|
onClick: editFn
|
|
@@ -13122,7 +13128,7 @@ const SimpleText = _ref => {
|
|
|
13122
13128
|
smaller,
|
|
13123
13129
|
...rest
|
|
13124
13130
|
} = _ref;
|
|
13125
|
-
return /*#__PURE__*/
|
|
13131
|
+
return /*#__PURE__*/React__default.createElement(Text, _extends({
|
|
13126
13132
|
fw: 300,
|
|
13127
13133
|
fz: smaller ? "90%" : undefined
|
|
13128
13134
|
}, rest), label);
|
|
@@ -13145,18 +13151,18 @@ const PageTitle = _ref => {
|
|
|
13145
13151
|
label,
|
|
13146
13152
|
...rest
|
|
13147
13153
|
} = create;
|
|
13148
|
-
rightsection = /*#__PURE__*/
|
|
13154
|
+
rightsection = /*#__PURE__*/React__default.createElement(Button, _extends({
|
|
13149
13155
|
radius: "md",
|
|
13150
13156
|
size: "sm",
|
|
13151
|
-
leftSection: /*#__PURE__*/
|
|
13157
|
+
leftSection: /*#__PURE__*/React__default.createElement(Icons, icon),
|
|
13152
13158
|
onClick: createFn
|
|
13153
|
-
}, rest), /*#__PURE__*/
|
|
13159
|
+
}, rest), /*#__PURE__*/React__default.createElement(Text, {
|
|
13154
13160
|
fw: 300,
|
|
13155
13161
|
fz: 14
|
|
13156
13162
|
}, label));
|
|
13157
13163
|
}
|
|
13158
13164
|
if (withSwitcher && switcher?.items?.length) {
|
|
13159
|
-
rightsection = /*#__PURE__*/
|
|
13165
|
+
rightsection = /*#__PURE__*/React__default.createElement(SegmentedControl, {
|
|
13160
13166
|
size: "sm",
|
|
13161
13167
|
bg: "white",
|
|
13162
13168
|
color: "adiba",
|
|
@@ -13165,34 +13171,34 @@ const PageTitle = _ref => {
|
|
|
13165
13171
|
onChange: switcher.onChange
|
|
13166
13172
|
});
|
|
13167
13173
|
}
|
|
13168
|
-
return /*#__PURE__*/
|
|
13174
|
+
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(Group, {
|
|
13169
13175
|
justify: "space-between",
|
|
13170
13176
|
py: "lg"
|
|
13171
|
-
}, /*#__PURE__*/
|
|
13177
|
+
}, /*#__PURE__*/React__default.createElement(Stack, {
|
|
13172
13178
|
gap: 4
|
|
13173
|
-
}, /*#__PURE__*/
|
|
13179
|
+
}, /*#__PURE__*/React__default.createElement(Title, {
|
|
13174
13180
|
order: 2,
|
|
13175
13181
|
fw: 500
|
|
13176
|
-
}, title), typeof subtitle == "string" ? /*#__PURE__*/
|
|
13182
|
+
}, title), typeof subtitle == "string" ? /*#__PURE__*/React__default.createElement(Text, {
|
|
13177
13183
|
fz: 14,
|
|
13178
13184
|
fw: 300
|
|
13179
|
-
}, subtitle) : /*#__PURE__*/
|
|
13185
|
+
}, subtitle) : /*#__PURE__*/React__default.createElement(Breadcrumbs, {
|
|
13180
13186
|
separatorMargin: "xs",
|
|
13181
13187
|
separator: "\xB7"
|
|
13182
13188
|
}, subtitle?.map((item, index) => {
|
|
13183
|
-
return index < subtitle.length - 1 ? /*#__PURE__*/
|
|
13189
|
+
return index < subtitle.length - 1 ? /*#__PURE__*/React__default.createElement(Anchor, {
|
|
13184
13190
|
key: index,
|
|
13185
13191
|
fz: 14,
|
|
13186
13192
|
fw: 400,
|
|
13187
13193
|
component: Link,
|
|
13188
13194
|
to: item.link
|
|
13189
|
-
}, item.name) : /*#__PURE__*/
|
|
13195
|
+
}, item.name) : /*#__PURE__*/React__default.createElement(Text, {
|
|
13190
13196
|
fz: 14,
|
|
13191
13197
|
key: index,
|
|
13192
13198
|
fw: 300,
|
|
13193
13199
|
c: "dimmed"
|
|
13194
13200
|
}, item.name);
|
|
13195
|
-
}))), /*#__PURE__*/
|
|
13201
|
+
}))), /*#__PURE__*/React__default.createElement(React__default.Fragment, null, rightsection)));
|
|
13196
13202
|
};
|
|
13197
13203
|
|
|
13198
13204
|
const TitleWithIndex = _ref => {
|
|
@@ -13204,20 +13210,20 @@ const TitleWithIndex = _ref => {
|
|
|
13204
13210
|
errorLabel,
|
|
13205
13211
|
errorFn = () => void 0
|
|
13206
13212
|
} = _ref;
|
|
13207
|
-
return /*#__PURE__*/
|
|
13213
|
+
return /*#__PURE__*/React__default.createElement(Group, null, /*#__PURE__*/React__default.createElement(Group, {
|
|
13208
13214
|
gap: "xs"
|
|
13209
|
-
}, /*#__PURE__*/
|
|
13215
|
+
}, /*#__PURE__*/React__default.createElement(Title, {
|
|
13210
13216
|
order: 3,
|
|
13211
13217
|
fw: 500
|
|
13212
|
-
}, title), /*#__PURE__*/
|
|
13218
|
+
}, title), /*#__PURE__*/React__default.createElement(Growth, growth), /*#__PURE__*/React__default.createElement(Text, {
|
|
13213
13219
|
c: "dimmed",
|
|
13214
13220
|
size: "xs",
|
|
13215
13221
|
fw: 300
|
|
13216
|
-
}, subtitle)), /*#__PURE__*/
|
|
13222
|
+
}, subtitle)), /*#__PURE__*/React__default.createElement(Space, {
|
|
13217
13223
|
flex: 1
|
|
13218
|
-
}), /*#__PURE__*/
|
|
13224
|
+
}), /*#__PURE__*/React__default.createElement(Box, {
|
|
13219
13225
|
hidden: !hasError
|
|
13220
|
-
}, /*#__PURE__*/
|
|
13226
|
+
}, /*#__PURE__*/React__default.createElement(WidgetError, {
|
|
13221
13227
|
errorLabel: errorLabel,
|
|
13222
13228
|
errorFn: errorFn
|
|
13223
13229
|
})));
|
|
@@ -13229,16 +13235,16 @@ const Growth = _ref2 => {
|
|
|
13229
13235
|
} = _ref2;
|
|
13230
13236
|
const color = direction === "up" ? "rgb(64, 192, 87)" : "rgb(250,82,82)";
|
|
13231
13237
|
const name = direction === "up" ? "TrendUp" : "TrendDown";
|
|
13232
|
-
return /*#__PURE__*/
|
|
13238
|
+
return /*#__PURE__*/React__default.createElement(Group, {
|
|
13233
13239
|
c: color,
|
|
13234
13240
|
gap: 2
|
|
13235
|
-
}, /*#__PURE__*/
|
|
13241
|
+
}, /*#__PURE__*/React__default.createElement(Icons, {
|
|
13236
13242
|
name: name,
|
|
13237
13243
|
color: color,
|
|
13238
13244
|
size: 12,
|
|
13239
13245
|
stroke: 2.5,
|
|
13240
13246
|
variant: "Bold"
|
|
13241
|
-
}), /*#__PURE__*/
|
|
13247
|
+
}), /*#__PURE__*/React__default.createElement(Text, {
|
|
13242
13248
|
size: "xs",
|
|
13243
13249
|
fw: 500
|
|
13244
13250
|
}, text));
|
|
@@ -13248,10 +13254,10 @@ const WidgetError = _ref3 => {
|
|
|
13248
13254
|
errorLabel,
|
|
13249
13255
|
errorFn
|
|
13250
13256
|
} = _ref3;
|
|
13251
|
-
return /*#__PURE__*/
|
|
13257
|
+
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(Button, {
|
|
13252
13258
|
size: "sm",
|
|
13253
13259
|
variant: "transparent",
|
|
13254
|
-
leftSection: /*#__PURE__*/
|
|
13260
|
+
leftSection: /*#__PURE__*/React__default.createElement(Icons, {
|
|
13255
13261
|
name: "Danger",
|
|
13256
13262
|
color: "rgb(250,82,82",
|
|
13257
13263
|
stroke: 1.5
|
|
@@ -13268,11 +13274,11 @@ const ConnectionPanelDetail = _ref => {
|
|
|
13268
13274
|
value,
|
|
13269
13275
|
altColor
|
|
13270
13276
|
} = _ref;
|
|
13271
|
-
return /*#__PURE__*/
|
|
13277
|
+
return /*#__PURE__*/React__default.createElement(Group, null, /*#__PURE__*/React__default.createElement(Text, {
|
|
13272
13278
|
w: 100,
|
|
13273
13279
|
fw: 300,
|
|
13274
13280
|
fz: "xs"
|
|
13275
|
-
}, label), /*#__PURE__*/
|
|
13281
|
+
}, label), /*#__PURE__*/React__default.createElement(Text, {
|
|
13276
13282
|
fw: 300,
|
|
13277
13283
|
fz: "sm",
|
|
13278
13284
|
c: altColor
|
|
@@ -13292,35 +13298,35 @@ const ConnectionPanel = _ref => {
|
|
|
13292
13298
|
altColor,
|
|
13293
13299
|
...rest
|
|
13294
13300
|
} = _ref;
|
|
13295
|
-
return /*#__PURE__*/
|
|
13301
|
+
return /*#__PURE__*/React__default.createElement(Card, {
|
|
13296
13302
|
withBorder: true,
|
|
13297
13303
|
bg: "gray.0",
|
|
13298
13304
|
p: "lg",
|
|
13299
13305
|
radius: "md",
|
|
13300
13306
|
color: "red"
|
|
13301
|
-
}, /*#__PURE__*/
|
|
13307
|
+
}, /*#__PURE__*/React__default.createElement(Stack, null, /*#__PURE__*/React__default.createElement(Group, {
|
|
13302
13308
|
align: "flex-start"
|
|
13303
|
-
}, /*#__PURE__*/
|
|
13309
|
+
}, /*#__PURE__*/React__default.createElement(Icons, {
|
|
13304
13310
|
size: 48,
|
|
13305
13311
|
name: "Driver",
|
|
13306
13312
|
stroke: "0.5"
|
|
13307
|
-
}), /*#__PURE__*/
|
|
13313
|
+
}), /*#__PURE__*/React__default.createElement(Stack, {
|
|
13308
13314
|
gap: 5
|
|
13309
|
-
}, /*#__PURE__*/
|
|
13315
|
+
}, /*#__PURE__*/React__default.createElement(Title, {
|
|
13310
13316
|
fw: 400,
|
|
13311
13317
|
order: 6
|
|
13312
|
-
}, name), /*#__PURE__*/
|
|
13318
|
+
}, name), /*#__PURE__*/React__default.createElement(Group, {
|
|
13313
13319
|
justify: "flex-start",
|
|
13314
13320
|
gap: 5
|
|
13315
|
-
}, /*#__PURE__*/
|
|
13321
|
+
}, /*#__PURE__*/React__default.createElement(ColorSwatch, {
|
|
13316
13322
|
size: 12,
|
|
13317
13323
|
color: statusColor
|
|
13318
|
-
}), /*#__PURE__*/
|
|
13324
|
+
}), /*#__PURE__*/React__default.createElement(Text, {
|
|
13319
13325
|
fw: 300,
|
|
13320
13326
|
fz: "xs"
|
|
13321
|
-
}, status))), /*#__PURE__*/
|
|
13327
|
+
}, status))), /*#__PURE__*/React__default.createElement(Space, {
|
|
13322
13328
|
flex: 1
|
|
13323
|
-
}), /*#__PURE__*/
|
|
13329
|
+
}), /*#__PURE__*/React__default.createElement(Menu, {
|
|
13324
13330
|
width: 190,
|
|
13325
13331
|
transitionProps: {
|
|
13326
13332
|
transition: "pop"
|
|
@@ -13329,55 +13335,55 @@ const ConnectionPanel = _ref => {
|
|
|
13329
13335
|
withArrow: true,
|
|
13330
13336
|
withinPortal: true,
|
|
13331
13337
|
arrowSize: 20
|
|
13332
|
-
}, /*#__PURE__*/
|
|
13338
|
+
}, /*#__PURE__*/React__default.createElement(Menu.Target, null, /*#__PURE__*/React__default.createElement(ActionIcon, {
|
|
13333
13339
|
variant: "subtle",
|
|
13334
13340
|
m: 0
|
|
13335
|
-
}, /*#__PURE__*/
|
|
13341
|
+
}, /*#__PURE__*/React__default.createElement(Icons, {
|
|
13336
13342
|
name: "More"
|
|
13337
|
-
}))), /*#__PURE__*/
|
|
13343
|
+
}))), /*#__PURE__*/React__default.createElement(Menu.Dropdown, null, /*#__PURE__*/React__default.createElement(Menu.Item, {
|
|
13338
13344
|
h: 40,
|
|
13339
13345
|
onClick: edit.onClick,
|
|
13340
|
-
rightSection: /*#__PURE__*/
|
|
13346
|
+
rightSection: /*#__PURE__*/React__default.createElement(Icons, {
|
|
13341
13347
|
name: "ArrowRight2"
|
|
13342
13348
|
}),
|
|
13343
13349
|
"data-index": id
|
|
13344
|
-
}, /*#__PURE__*/
|
|
13350
|
+
}, /*#__PURE__*/React__default.createElement(Text, {
|
|
13345
13351
|
size: "xs",
|
|
13346
13352
|
fw: 300
|
|
13347
|
-
}, edit.label)), /*#__PURE__*/
|
|
13353
|
+
}, edit.label)), /*#__PURE__*/React__default.createElement(Menu.Item, {
|
|
13348
13354
|
h: 40,
|
|
13349
13355
|
onClick: test.onClick,
|
|
13350
|
-
rightSection: /*#__PURE__*/
|
|
13356
|
+
rightSection: /*#__PURE__*/React__default.createElement(Icons, {
|
|
13351
13357
|
name: "ArrowRight2"
|
|
13352
13358
|
}),
|
|
13353
13359
|
"data-index": id
|
|
13354
|
-
}, /*#__PURE__*/
|
|
13360
|
+
}, /*#__PURE__*/React__default.createElement(Text, {
|
|
13355
13361
|
size: "xs",
|
|
13356
13362
|
fw: 300
|
|
13357
|
-
}, test.label)), /*#__PURE__*/
|
|
13363
|
+
}, test.label)), /*#__PURE__*/React__default.createElement(Divider, null), /*#__PURE__*/React__default.createElement(Menu.Item, {
|
|
13358
13364
|
h: 40,
|
|
13359
13365
|
onClick: pause.onClick,
|
|
13360
13366
|
c: "red",
|
|
13361
|
-
leftSection: /*#__PURE__*/
|
|
13367
|
+
leftSection: /*#__PURE__*/React__default.createElement(Icons, {
|
|
13362
13368
|
name: "PauseCircle",
|
|
13363
13369
|
color: "red"
|
|
13364
13370
|
}),
|
|
13365
13371
|
"data-index": id
|
|
13366
|
-
}, /*#__PURE__*/
|
|
13372
|
+
}, /*#__PURE__*/React__default.createElement(Text, {
|
|
13367
13373
|
size: "xs",
|
|
13368
13374
|
fw: 300
|
|
13369
|
-
}, pause.label))))), /*#__PURE__*/
|
|
13375
|
+
}, pause.label))))), /*#__PURE__*/React__default.createElement(Card.Section, {
|
|
13370
13376
|
style: {
|
|
13371
13377
|
borderTop: "1px solid #ddd"
|
|
13372
13378
|
}
|
|
13373
|
-
}, /*#__PURE__*/
|
|
13379
|
+
}, /*#__PURE__*/React__default.createElement(Stack, {
|
|
13374
13380
|
mt: 0,
|
|
13375
13381
|
bg: "white",
|
|
13376
13382
|
p: "md",
|
|
13377
13383
|
gap: "lg",
|
|
13378
13384
|
py: "lg"
|
|
13379
13385
|
}, details.map((item, index) => {
|
|
13380
|
-
return /*#__PURE__*/
|
|
13386
|
+
return /*#__PURE__*/React__default.createElement(ConnectionPanelDetail, _extends({
|
|
13381
13387
|
key: `detail-${index}`
|
|
13382
13388
|
}, item, {
|
|
13383
13389
|
altColor: altColor
|
|
@@ -13392,13 +13398,13 @@ const ApplicationPanelFeatures = _ref => {
|
|
|
13392
13398
|
label,
|
|
13393
13399
|
icon
|
|
13394
13400
|
} = _ref;
|
|
13395
|
-
return /*#__PURE__*/
|
|
13401
|
+
return /*#__PURE__*/React__default.createElement(Group, {
|
|
13396
13402
|
gap: "xs"
|
|
13397
|
-
}, /*#__PURE__*/
|
|
13403
|
+
}, /*#__PURE__*/React__default.createElement(Icons, _extends({}, icon, {
|
|
13398
13404
|
color: "#aaa",
|
|
13399
13405
|
variant: "Bulk",
|
|
13400
13406
|
stroke: 1.5
|
|
13401
|
-
})), /*#__PURE__*/
|
|
13407
|
+
})), /*#__PURE__*/React__default.createElement(Text, {
|
|
13402
13408
|
fw: 300,
|
|
13403
13409
|
c: "altiba",
|
|
13404
13410
|
size: "12px",
|
|
@@ -13423,39 +13429,39 @@ const ApplicationPanel = _ref => {
|
|
|
13423
13429
|
onClick = () => void 0,
|
|
13424
13430
|
...rest
|
|
13425
13431
|
} = _ref;
|
|
13426
|
-
return /*#__PURE__*/
|
|
13432
|
+
return /*#__PURE__*/React__default.createElement(Card, _extends({
|
|
13427
13433
|
withBorder: true,
|
|
13428
13434
|
radius: "md"
|
|
13429
|
-
}, rest), /*#__PURE__*/
|
|
13435
|
+
}, rest), /*#__PURE__*/React__default.createElement(Card.Section, null, /*#__PURE__*/React__default.createElement(AspectRatio, {
|
|
13430
13436
|
ratio: 3 / 2
|
|
13431
|
-
}, /*#__PURE__*/
|
|
13437
|
+
}, /*#__PURE__*/React__default.createElement(Image, {
|
|
13432
13438
|
alt: name,
|
|
13433
13439
|
src: coverImage,
|
|
13434
13440
|
fallbackSrc: img$a
|
|
13435
|
-
}), /*#__PURE__*/
|
|
13441
|
+
}), /*#__PURE__*/React__default.createElement(Overlay, {
|
|
13436
13442
|
gradient: "linear-gradient(45deg, rgba(255,255,255,0.1) 0%,rgba(255,255,255,0.05) 100%)"
|
|
13437
|
-
}))), /*#__PURE__*/
|
|
13443
|
+
}))), /*#__PURE__*/React__default.createElement(Card.Section, {
|
|
13438
13444
|
p: "md"
|
|
13439
|
-
}, /*#__PURE__*/
|
|
13445
|
+
}, /*#__PURE__*/React__default.createElement(Stack, {
|
|
13440
13446
|
gap: "sm"
|
|
13441
|
-
}, /*#__PURE__*/
|
|
13447
|
+
}, /*#__PURE__*/React__default.createElement(Group, {
|
|
13442
13448
|
justify: "space-between"
|
|
13443
|
-
}, /*#__PURE__*/
|
|
13449
|
+
}, /*#__PURE__*/React__default.createElement(Text, {
|
|
13444
13450
|
fw: 400
|
|
13445
|
-
}, name), /*#__PURE__*/
|
|
13451
|
+
}, name), /*#__PURE__*/React__default.createElement(Badge, {
|
|
13446
13452
|
style: {
|
|
13447
13453
|
display: String(discount).length > 1 ? "block" : "none"
|
|
13448
13454
|
},
|
|
13449
13455
|
fw: 300,
|
|
13450
13456
|
variant: "outline"
|
|
13451
|
-
}, discount)), /*#__PURE__*/
|
|
13457
|
+
}, discount)), /*#__PURE__*/React__default.createElement(Text, {
|
|
13452
13458
|
fw: 300,
|
|
13453
13459
|
fz: "sm",
|
|
13454
13460
|
lineClamp: 3
|
|
13455
|
-
}, summary))), /*#__PURE__*/
|
|
13461
|
+
}, summary))), /*#__PURE__*/React__default.createElement(Card.Section, {
|
|
13456
13462
|
p: "md",
|
|
13457
13463
|
pt: 0
|
|
13458
|
-
}, /*#__PURE__*/
|
|
13464
|
+
}, /*#__PURE__*/React__default.createElement(Text, {
|
|
13459
13465
|
fz: "xs",
|
|
13460
13466
|
c: "gray.5",
|
|
13461
13467
|
mb: "xs",
|
|
@@ -13463,26 +13469,26 @@ const ApplicationPanel = _ref => {
|
|
|
13463
13469
|
fw: 500,
|
|
13464
13470
|
lts: rem("-0.25px"),
|
|
13465
13471
|
tt: "uppercase"
|
|
13466
|
-
}, featureLabel), /*#__PURE__*/
|
|
13472
|
+
}, featureLabel), /*#__PURE__*/React__default.createElement(SimpleGrid, {
|
|
13467
13473
|
cols: 1,
|
|
13468
13474
|
spacing: "xs",
|
|
13469
13475
|
verticalSpacing: "xs"
|
|
13470
13476
|
}, features.map((feature, index) => {
|
|
13471
|
-
return /*#__PURE__*/
|
|
13477
|
+
return /*#__PURE__*/React__default.createElement(ApplicationPanelFeatures, _extends({
|
|
13472
13478
|
key: index
|
|
13473
13479
|
}, feature));
|
|
13474
|
-
}))), /*#__PURE__*/
|
|
13480
|
+
}))), /*#__PURE__*/React__default.createElement(Card.Section, {
|
|
13475
13481
|
p: "md"
|
|
13476
|
-
}, /*#__PURE__*/
|
|
13482
|
+
}, /*#__PURE__*/React__default.createElement(Group, {
|
|
13477
13483
|
gap: 30,
|
|
13478
13484
|
justify: "space-between"
|
|
13479
|
-
}, /*#__PURE__*/
|
|
13485
|
+
}, /*#__PURE__*/React__default.createElement(Box, null, /*#__PURE__*/React__default.createElement(Text, {
|
|
13480
13486
|
fz: "lg",
|
|
13481
13487
|
fw: 500,
|
|
13482
13488
|
style: {
|
|
13483
13489
|
lineHeight: 1
|
|
13484
13490
|
}
|
|
13485
|
-
}, amount), /*#__PURE__*/
|
|
13491
|
+
}, amount), /*#__PURE__*/React__default.createElement(Text, {
|
|
13486
13492
|
fz: "xs",
|
|
13487
13493
|
c: "dimmed",
|
|
13488
13494
|
fw: 300,
|
|
@@ -13490,19 +13496,19 @@ const ApplicationPanel = _ref => {
|
|
|
13490
13496
|
lineHeight: 1
|
|
13491
13497
|
},
|
|
13492
13498
|
mt: 3
|
|
13493
|
-
}, `per ${frequency}`)), /*#__PURE__*/
|
|
13499
|
+
}, `per ${frequency}`)), /*#__PURE__*/React__default.createElement(Box, {
|
|
13494
13500
|
hidden: subscribed
|
|
13495
|
-
}, /*#__PURE__*/
|
|
13501
|
+
}, /*#__PURE__*/React__default.createElement(Button, {
|
|
13496
13502
|
fw: 300,
|
|
13497
|
-
leftSection: /*#__PURE__*/
|
|
13503
|
+
leftSection: /*#__PURE__*/React__default.createElement(Icons, {
|
|
13498
13504
|
name: "AddCircle"
|
|
13499
13505
|
}),
|
|
13500
13506
|
radius: "md",
|
|
13501
13507
|
onClick: onClick
|
|
13502
|
-
}, actionLabel)), /*#__PURE__*/
|
|
13508
|
+
}, actionLabel)), /*#__PURE__*/React__default.createElement(Box, {
|
|
13503
13509
|
hidden: !subscribed
|
|
13504
|
-
}, /*#__PURE__*/
|
|
13505
|
-
leftSection: /*#__PURE__*/
|
|
13510
|
+
}, /*#__PURE__*/React__default.createElement(Button, {
|
|
13511
|
+
leftSection: /*#__PURE__*/React__default.createElement(Icons, {
|
|
13506
13512
|
name: "TickCircle"
|
|
13507
13513
|
}),
|
|
13508
13514
|
fw: 300,
|
|
@@ -13524,40 +13530,40 @@ const SubscriptionPlans = _ref => {
|
|
|
13524
13530
|
onClick
|
|
13525
13531
|
} = _ref;
|
|
13526
13532
|
const price = planPrice.split("/");
|
|
13527
|
-
return /*#__PURE__*/
|
|
13533
|
+
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(Indicator, {
|
|
13528
13534
|
size: 20,
|
|
13529
|
-
label: /*#__PURE__*/
|
|
13535
|
+
label: /*#__PURE__*/React__default.createElement(Icons, {
|
|
13530
13536
|
name: "TickCircle",
|
|
13531
13537
|
size: 18,
|
|
13532
13538
|
stroke: 1
|
|
13533
13539
|
}),
|
|
13534
13540
|
disabled: !isActive,
|
|
13535
13541
|
className: "payment-plan"
|
|
13536
|
-
}, /*#__PURE__*/
|
|
13542
|
+
}, /*#__PURE__*/React__default.createElement(Card, {
|
|
13537
13543
|
bg: isActive ? "gray.1" : "white",
|
|
13538
13544
|
p: "md",
|
|
13539
13545
|
radius: "sm",
|
|
13540
13546
|
withBorder: true
|
|
13541
|
-
}, /*#__PURE__*/
|
|
13547
|
+
}, /*#__PURE__*/React__default.createElement(Stack, {
|
|
13542
13548
|
gap: "xl"
|
|
13543
|
-
}, /*#__PURE__*/
|
|
13549
|
+
}, /*#__PURE__*/React__default.createElement(Group, {
|
|
13544
13550
|
justify: "space-between",
|
|
13545
13551
|
align: "flex-start"
|
|
13546
|
-
}, /*#__PURE__*/
|
|
13552
|
+
}, /*#__PURE__*/React__default.createElement(Box, null, /*#__PURE__*/React__default.createElement(Title, {
|
|
13547
13553
|
order: 6,
|
|
13548
13554
|
fw: 500
|
|
13549
|
-
}, title), /*#__PURE__*/
|
|
13555
|
+
}, title), /*#__PURE__*/React__default.createElement(Text, {
|
|
13550
13556
|
fz: "xs",
|
|
13551
13557
|
c: altColor,
|
|
13552
13558
|
fw: 300
|
|
13553
|
-
}, durationDays, " ", isActive ? " days remaining" : " days")), /*#__PURE__*/
|
|
13559
|
+
}, durationDays, " ", isActive ? " days remaining" : " days")), /*#__PURE__*/React__default.createElement(Text, {
|
|
13554
13560
|
fz: "sm",
|
|
13555
13561
|
fw: 500
|
|
13556
|
-
}, price[0], /*#__PURE__*/
|
|
13562
|
+
}, price[0], /*#__PURE__*/React__default.createElement(Text, {
|
|
13557
13563
|
fz: "sm",
|
|
13558
13564
|
component: "span",
|
|
13559
13565
|
c: "dimmed"
|
|
13560
|
-
}, price[1] ? `/${price[1]}` : " /month"))), /*#__PURE__*/
|
|
13566
|
+
}, price[1] ? `/${price[1]}` : " /month"))), /*#__PURE__*/React__default.createElement(Button, {
|
|
13561
13567
|
w: 100,
|
|
13562
13568
|
size: "xs",
|
|
13563
13569
|
fw: 500,
|
|
@@ -13583,74 +13589,74 @@ const PaymentMethod = _ref => {
|
|
|
13583
13589
|
type,
|
|
13584
13590
|
exp
|
|
13585
13591
|
} = _ref;
|
|
13586
|
-
return /*#__PURE__*/
|
|
13592
|
+
return /*#__PURE__*/React__default.createElement(Card, {
|
|
13587
13593
|
withBorder: true,
|
|
13588
13594
|
radius: "md",
|
|
13589
13595
|
p: 0,
|
|
13590
13596
|
bg: isActive ? "gray.1" : "white",
|
|
13591
13597
|
w: 330
|
|
13592
|
-
}, /*#__PURE__*/
|
|
13598
|
+
}, /*#__PURE__*/React__default.createElement(Group, {
|
|
13593
13599
|
gap: "md",
|
|
13594
13600
|
px: "sm"
|
|
13595
|
-
}, /*#__PURE__*/
|
|
13601
|
+
}, /*#__PURE__*/React__default.createElement(Center, {
|
|
13596
13602
|
h: 88,
|
|
13597
13603
|
w: 80
|
|
13598
|
-
}, logo[type]), /*#__PURE__*/
|
|
13604
|
+
}, logo[type]), /*#__PURE__*/React__default.createElement(Stack, {
|
|
13599
13605
|
gap: 3
|
|
13600
|
-
}, /*#__PURE__*/
|
|
13606
|
+
}, /*#__PURE__*/React__default.createElement(Text, {
|
|
13601
13607
|
fz: 14,
|
|
13602
13608
|
tt: "uppercase",
|
|
13603
13609
|
fw: 500
|
|
13604
|
-
}, `**** **** **** ${pan}`), /*#__PURE__*/
|
|
13610
|
+
}, `**** **** **** ${pan}`), /*#__PURE__*/React__default.createElement(Group, {
|
|
13605
13611
|
c: "dimmed"
|
|
13606
|
-
}, /*#__PURE__*/
|
|
13612
|
+
}, /*#__PURE__*/React__default.createElement(Text, {
|
|
13607
13613
|
tt: "capitalize",
|
|
13608
13614
|
fw: 300,
|
|
13609
13615
|
size: "xs"
|
|
13610
|
-
}, type), /*#__PURE__*/
|
|
13616
|
+
}, type), /*#__PURE__*/React__default.createElement(Text, {
|
|
13611
13617
|
fw: 300,
|
|
13612
13618
|
size: "sm"
|
|
13613
|
-
}, exp))), /*#__PURE__*/
|
|
13619
|
+
}, exp))), /*#__PURE__*/React__default.createElement(Space, {
|
|
13614
13620
|
flex: 1
|
|
13615
|
-
}), /*#__PURE__*/
|
|
13621
|
+
}), /*#__PURE__*/React__default.createElement(ActionIcon, {
|
|
13616
13622
|
variant: "subtle",
|
|
13617
13623
|
disabled: isActive
|
|
13618
|
-
}, !isActive ? /*#__PURE__*/
|
|
13624
|
+
}, !isActive ? /*#__PURE__*/React__default.createElement(Icons, {
|
|
13619
13625
|
name: "Record"
|
|
13620
|
-
}) : /*#__PURE__*/
|
|
13626
|
+
}) : /*#__PURE__*/React__default.createElement(Icons, {
|
|
13621
13627
|
name: "TickCircle"
|
|
13622
13628
|
}))));
|
|
13623
13629
|
};
|
|
13624
13630
|
const logo = {
|
|
13625
|
-
mastercard: /*#__PURE__*/
|
|
13631
|
+
mastercard: /*#__PURE__*/React__default.createElement(Image, {
|
|
13626
13632
|
height: 60,
|
|
13627
13633
|
src: img$7
|
|
13628
13634
|
}),
|
|
13629
|
-
visa: /*#__PURE__*/
|
|
13635
|
+
visa: /*#__PURE__*/React__default.createElement(Image, {
|
|
13630
13636
|
height: 60,
|
|
13631
13637
|
src: img$8
|
|
13632
13638
|
}),
|
|
13633
|
-
amex: /*#__PURE__*/
|
|
13639
|
+
amex: /*#__PURE__*/React__default.createElement(Image, {
|
|
13634
13640
|
height: 60,
|
|
13635
13641
|
src: img$9
|
|
13636
13642
|
}),
|
|
13637
|
-
paypal: /*#__PURE__*/
|
|
13643
|
+
paypal: /*#__PURE__*/React__default.createElement(Image, {
|
|
13638
13644
|
height: 60,
|
|
13639
13645
|
src: img$6
|
|
13640
13646
|
}),
|
|
13641
|
-
verve: /*#__PURE__*/
|
|
13647
|
+
verve: /*#__PURE__*/React__default.createElement(Image, {
|
|
13642
13648
|
height: 60,
|
|
13643
13649
|
src: img$5
|
|
13644
13650
|
})
|
|
13645
13651
|
};
|
|
13646
13652
|
const PaymentMethodAdd = () => {
|
|
13647
|
-
return /*#__PURE__*/
|
|
13653
|
+
return /*#__PURE__*/React__default.createElement(Group, {
|
|
13648
13654
|
align: "center"
|
|
13649
|
-
}, /*#__PURE__*/
|
|
13655
|
+
}, /*#__PURE__*/React__default.createElement(Button, {
|
|
13650
13656
|
variant: "outline",
|
|
13651
13657
|
w: 60,
|
|
13652
13658
|
h: 60
|
|
13653
|
-
}, /*#__PURE__*/
|
|
13659
|
+
}, /*#__PURE__*/React__default.createElement(Icons, {
|
|
13654
13660
|
name: "Add",
|
|
13655
13661
|
size: 60,
|
|
13656
13662
|
stroke: 1
|
|
@@ -13662,7 +13668,7 @@ const SimpleHeader = _ref => {
|
|
|
13662
13668
|
id,
|
|
13663
13669
|
label
|
|
13664
13670
|
} = _ref;
|
|
13665
|
-
return /*#__PURE__*/
|
|
13671
|
+
return /*#__PURE__*/React__default.createElement(Table.Th, {
|
|
13666
13672
|
fw: 500,
|
|
13667
13673
|
id: id,
|
|
13668
13674
|
fz: "xs",
|
|
@@ -13687,13 +13693,13 @@ const SimpleBody = _ref => {
|
|
|
13687
13693
|
if (withIndex) {
|
|
13688
13694
|
row["index"] = `${index ? index + 1 : 1}`;
|
|
13689
13695
|
}
|
|
13690
|
-
return /*#__PURE__*/
|
|
13696
|
+
return /*#__PURE__*/React__default.createElement(Table.Tr, {
|
|
13691
13697
|
fw: 300,
|
|
13692
13698
|
fz: "sm",
|
|
13693
13699
|
h: 50
|
|
13694
13700
|
}, columns.map((column, idx) => {
|
|
13695
13701
|
const columnIndex = column.id;
|
|
13696
|
-
return /*#__PURE__*/
|
|
13702
|
+
return /*#__PURE__*/React__default.createElement(Table.Td, {
|
|
13697
13703
|
key: idx
|
|
13698
13704
|
}, typeof row[columnIndex] === "function" ? row[columnIndex](`${index}`) : row[columnIndex] || "");
|
|
13699
13705
|
}));
|
|
@@ -13727,14 +13733,14 @@ const SimpleTable = _ref => {
|
|
|
13727
13733
|
withRowBorders: false,
|
|
13728
13734
|
verticalSpacing: "md"
|
|
13729
13735
|
};
|
|
13730
|
-
return /*#__PURE__*/
|
|
13736
|
+
return /*#__PURE__*/React__default.createElement(Table, isStriped && isStripedProps, /*#__PURE__*/React__default.createElement(Table.Thead, null, /*#__PURE__*/React__default.createElement(Table.Tr, {
|
|
13731
13737
|
bg: isStriped ? "gray.1" : "transparent"
|
|
13732
13738
|
}, columns.map((column, index) => {
|
|
13733
|
-
return /*#__PURE__*/
|
|
13739
|
+
return /*#__PURE__*/React__default.createElement(SimpleHeader, _extends({
|
|
13734
13740
|
key: `column-${index}`
|
|
13735
13741
|
}, column));
|
|
13736
|
-
}))), /*#__PURE__*/
|
|
13737
|
-
return /*#__PURE__*/
|
|
13742
|
+
}))), /*#__PURE__*/React__default.createElement(Table.Tbody, null, rows.map((row, index) => {
|
|
13743
|
+
return /*#__PURE__*/React__default.createElement(SimpleBody, {
|
|
13738
13744
|
key: index,
|
|
13739
13745
|
row,
|
|
13740
13746
|
columns,
|
|
@@ -13779,29 +13785,29 @@ const File = _ref => {
|
|
|
13779
13785
|
} = _ref;
|
|
13780
13786
|
const isChip = shape == "chip";
|
|
13781
13787
|
const radius = isChip ? "md" : "sm";
|
|
13782
|
-
return /*#__PURE__*/
|
|
13788
|
+
return /*#__PURE__*/React__default.createElement(Card, _extends({}, rest, {
|
|
13783
13789
|
radius,
|
|
13784
13790
|
w,
|
|
13785
13791
|
bg,
|
|
13786
13792
|
bd
|
|
13787
|
-
}), /*#__PURE__*/
|
|
13793
|
+
}), /*#__PURE__*/React__default.createElement(Card.Section, {
|
|
13788
13794
|
p: isChip ? "xs" : undefined
|
|
13789
|
-
}, /*#__PURE__*/
|
|
13795
|
+
}, /*#__PURE__*/React__default.createElement(Group, {
|
|
13790
13796
|
justify: isChip ? "space-between" : undefined,
|
|
13791
13797
|
gap: "xs"
|
|
13792
|
-
}, /*#__PURE__*/
|
|
13798
|
+
}, /*#__PURE__*/React__default.createElement(Image, {
|
|
13793
13799
|
p: isChip ? undefined : "xs",
|
|
13794
13800
|
pr: 2,
|
|
13795
13801
|
h: isChip ? CHIP_HEIGHT : TILE_HEIGHT,
|
|
13796
13802
|
w: isChip ? CHIP_WIDTH : TILE_WIDTH,
|
|
13797
13803
|
alt: shape,
|
|
13798
13804
|
fallbackSrc: ICON[type]
|
|
13799
|
-
}), rest.children, /*#__PURE__*/
|
|
13805
|
+
}), rest.children, /*#__PURE__*/React__default.createElement(Space, {
|
|
13800
13806
|
flex: 1
|
|
13801
|
-
}), rightsection ? /*#__PURE__*/
|
|
13807
|
+
}), rightsection ? /*#__PURE__*/React__default.createElement(ActionIcon, {
|
|
13802
13808
|
variant: "transparent",
|
|
13803
13809
|
onClick: rightsection.onClick
|
|
13804
|
-
}, /*#__PURE__*/
|
|
13810
|
+
}, /*#__PURE__*/React__default.createElement(Icons, rightsection?.icon)) : undefined)));
|
|
13805
13811
|
};
|
|
13806
13812
|
|
|
13807
13813
|
const theme = createTheme({
|
|
@@ -13831,21 +13837,21 @@ const ErrorModal = _ref => {
|
|
|
13831
13837
|
id,
|
|
13832
13838
|
innerProps
|
|
13833
13839
|
} = _ref;
|
|
13834
|
-
return /*#__PURE__*/
|
|
13840
|
+
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(Stack, {
|
|
13835
13841
|
align: "center",
|
|
13836
13842
|
py: "md"
|
|
13837
|
-
}, /*#__PURE__*/
|
|
13843
|
+
}, /*#__PURE__*/React__default.createElement(Center, {
|
|
13838
13844
|
w: 170,
|
|
13839
13845
|
h: 170
|
|
13840
|
-
}, /*#__PURE__*/
|
|
13846
|
+
}, /*#__PURE__*/React__default.createElement(DotLottieReact, {
|
|
13841
13847
|
speed: 0.5,
|
|
13842
13848
|
src: ErrorAnimation,
|
|
13843
13849
|
loop: false,
|
|
13844
13850
|
autoplay: true
|
|
13845
|
-
})), /*#__PURE__*/
|
|
13851
|
+
})), /*#__PURE__*/React__default.createElement(Text, {
|
|
13846
13852
|
fw: 300,
|
|
13847
13853
|
ta: "center"
|
|
13848
|
-
}, innerProps.modalBody)), /*#__PURE__*/
|
|
13854
|
+
}, innerProps.modalBody)), /*#__PURE__*/React__default.createElement(Button, {
|
|
13849
13855
|
radius: "xl",
|
|
13850
13856
|
fw: 300,
|
|
13851
13857
|
size: "md",
|
|
@@ -13863,9 +13869,9 @@ const InfoModal = _ref => {
|
|
|
13863
13869
|
id,
|
|
13864
13870
|
innerProps
|
|
13865
13871
|
} = _ref;
|
|
13866
|
-
return /*#__PURE__*/
|
|
13872
|
+
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(Text, {
|
|
13867
13873
|
size: "sm"
|
|
13868
|
-
}, innerProps.modalBody), /*#__PURE__*/
|
|
13874
|
+
}, innerProps.modalBody), /*#__PURE__*/React__default.createElement(Button, {
|
|
13869
13875
|
fullWidth: true,
|
|
13870
13876
|
mt: "md",
|
|
13871
13877
|
onClick: () => context.closeModal(id)
|
|
@@ -13879,17 +13885,17 @@ const SimpleModal = _ref => {
|
|
|
13879
13885
|
innerProps,
|
|
13880
13886
|
...rest
|
|
13881
13887
|
} = _ref;
|
|
13882
|
-
return /*#__PURE__*/
|
|
13888
|
+
return /*#__PURE__*/React__default.createElement(Stack, {
|
|
13883
13889
|
pt: "lg",
|
|
13884
13890
|
gap: "xl"
|
|
13885
|
-
}, /*#__PURE__*/
|
|
13891
|
+
}, /*#__PURE__*/React__default.createElement(Stack, {
|
|
13886
13892
|
align: "center",
|
|
13887
13893
|
gap: "lg"
|
|
13888
|
-
}, /*#__PURE__*/
|
|
13894
|
+
}, /*#__PURE__*/React__default.createElement(Title, {
|
|
13889
13895
|
order: 3,
|
|
13890
13896
|
fw: 500,
|
|
13891
13897
|
lh: "40px"
|
|
13892
|
-
}, innerProps.title), /*#__PURE__*/
|
|
13898
|
+
}, innerProps.title), /*#__PURE__*/React__default.createElement(React__default.Fragment, null, innerProps.modalBody)));
|
|
13893
13899
|
};
|
|
13894
13900
|
|
|
13895
13901
|
var SuccessAnimation = "data:null;base64,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";
|
|
@@ -13900,21 +13906,21 @@ const SuccessModal = _ref => {
|
|
|
13900
13906
|
id,
|
|
13901
13907
|
innerProps
|
|
13902
13908
|
} = _ref;
|
|
13903
|
-
return /*#__PURE__*/
|
|
13909
|
+
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(Stack, {
|
|
13904
13910
|
align: "center",
|
|
13905
13911
|
py: "md"
|
|
13906
|
-
}, /*#__PURE__*/
|
|
13912
|
+
}, /*#__PURE__*/React__default.createElement(Center, {
|
|
13907
13913
|
w: 170,
|
|
13908
13914
|
h: 170
|
|
13909
|
-
}, /*#__PURE__*/
|
|
13915
|
+
}, /*#__PURE__*/React__default.createElement(DotLottieReact, {
|
|
13910
13916
|
speed: 0.8,
|
|
13911
13917
|
src: SuccessAnimation,
|
|
13912
13918
|
loop: false,
|
|
13913
13919
|
autoplay: true
|
|
13914
|
-
})), /*#__PURE__*/
|
|
13920
|
+
})), /*#__PURE__*/React__default.createElement(Text, {
|
|
13915
13921
|
fw: 300,
|
|
13916
13922
|
ta: "center"
|
|
13917
|
-
}, innerProps.modalBody)), /*#__PURE__*/
|
|
13923
|
+
}, innerProps.modalBody)), /*#__PURE__*/React__default.createElement(Button, {
|
|
13918
13924
|
radius: "xl",
|
|
13919
13925
|
fw: 300,
|
|
13920
13926
|
size: "md",
|
|
@@ -13932,22 +13938,22 @@ const TwoFactorModal = _ref => {
|
|
|
13932
13938
|
title = "Verify Your Identity",
|
|
13933
13939
|
pinLength = 6
|
|
13934
13940
|
} = _ref;
|
|
13935
|
-
return /*#__PURE__*/
|
|
13941
|
+
return /*#__PURE__*/React__default.createElement(Stack, {
|
|
13936
13942
|
align: "center",
|
|
13937
13943
|
py: 40,
|
|
13938
13944
|
gap: "lg"
|
|
13939
|
-
}, /*#__PURE__*/
|
|
13945
|
+
}, /*#__PURE__*/React__default.createElement(Title, {
|
|
13940
13946
|
order: 3,
|
|
13941
13947
|
fw: 500,
|
|
13942
13948
|
h: 40
|
|
13943
|
-
}, title), /*#__PURE__*/
|
|
13949
|
+
}, title), /*#__PURE__*/React__default.createElement(PinInput, {
|
|
13944
13950
|
length: pinLength,
|
|
13945
13951
|
placeholder: "",
|
|
13946
13952
|
type: "number",
|
|
13947
13953
|
inputType: "tel",
|
|
13948
13954
|
inputMode: "numeric",
|
|
13949
13955
|
autoFocus: true
|
|
13950
|
-
}), /*#__PURE__*/
|
|
13956
|
+
}), /*#__PURE__*/React__default.createElement(Text, {
|
|
13951
13957
|
ta: "center",
|
|
13952
13958
|
fw: 300
|
|
13953
13959
|
}, children));
|
|
@@ -13962,7 +13968,7 @@ const Drawer = _ref => {
|
|
|
13962
13968
|
title = "",
|
|
13963
13969
|
page = undefined
|
|
13964
13970
|
} = _ref;
|
|
13965
|
-
return /*#__PURE__*/
|
|
13971
|
+
return /*#__PURE__*/React__default.createElement(Drawer$1.Root, {
|
|
13966
13972
|
opened,
|
|
13967
13973
|
onClose,
|
|
13968
13974
|
position,
|
|
@@ -13975,17 +13981,17 @@ const Drawer = _ref => {
|
|
|
13975
13981
|
duration: 500,
|
|
13976
13982
|
transition: "slide-left"
|
|
13977
13983
|
}
|
|
13978
|
-
}, /*#__PURE__*/
|
|
13984
|
+
}, /*#__PURE__*/React__default.createElement(Drawer$1.Overlay, null), /*#__PURE__*/React__default.createElement(Drawer$1.Content, null, /*#__PURE__*/React__default.createElement(Drawer$1.Header, null, /*#__PURE__*/React__default.createElement(Drawer$1.Title, {
|
|
13979
13985
|
fz: "lg",
|
|
13980
13986
|
fw: "400"
|
|
13981
|
-
}, title), /*#__PURE__*/
|
|
13982
|
-
icon: /*#__PURE__*/
|
|
13987
|
+
}, title), /*#__PURE__*/React__default.createElement(Drawer$1.CloseButton, {
|
|
13988
|
+
icon: /*#__PURE__*/React__default.createElement(Icons, {
|
|
13983
13989
|
name: "Back",
|
|
13984
13990
|
size: 24
|
|
13985
13991
|
})
|
|
13986
|
-
})), /*#__PURE__*/
|
|
13992
|
+
})), /*#__PURE__*/React__default.createElement(Drawer$1.Body, {
|
|
13987
13993
|
p: "md"
|
|
13988
|
-
}, /*#__PURE__*/
|
|
13994
|
+
}, /*#__PURE__*/React__default.createElement(ScrollArea, {
|
|
13989
13995
|
scrollbars: "y"
|
|
13990
13996
|
}, page))));
|
|
13991
13997
|
};
|
|
@@ -14040,7 +14046,7 @@ const SimpleForm = _ref => {
|
|
|
14040
14046
|
variant: !isEditable ? "unstyled" : "default",
|
|
14041
14047
|
required: true
|
|
14042
14048
|
};
|
|
14043
|
-
return /*#__PURE__*/
|
|
14049
|
+
return /*#__PURE__*/React__default.createElement("form", {
|
|
14044
14050
|
onSubmit: form.onSubmit(values => hasSubmit ? rest.onSubmit?.(values) : void 0),
|
|
14045
14051
|
onReset: () => {
|
|
14046
14052
|
form.reset();
|
|
@@ -14049,18 +14055,18 @@ const SimpleForm = _ref => {
|
|
|
14049
14055
|
style: {
|
|
14050
14056
|
height: "100%"
|
|
14051
14057
|
}
|
|
14052
|
-
}, /*#__PURE__*/
|
|
14058
|
+
}, /*#__PURE__*/React__default.createElement(Stack, {
|
|
14053
14059
|
h: "100%"
|
|
14054
|
-
}, /*#__PURE__*/
|
|
14060
|
+
}, /*#__PURE__*/React__default.createElement(Grid, null, fields.map((field, index) => {
|
|
14055
14061
|
if (typeof field === "string") {
|
|
14056
14062
|
const sanitizedField = santize(field);
|
|
14057
|
-
return /*#__PURE__*/
|
|
14063
|
+
return /*#__PURE__*/React__default.createElement(Grid.Col, {
|
|
14058
14064
|
key: index,
|
|
14059
14065
|
span: layout[index]
|
|
14060
|
-
}, /*#__PURE__*/
|
|
14066
|
+
}, /*#__PURE__*/React__default.createElement(TextInput, _extends({}, inputProps, sanitizedField, form.getInputProps(sanitizedField.name))));
|
|
14061
14067
|
}
|
|
14062
14068
|
if (typeof field === "function") {
|
|
14063
|
-
return /*#__PURE__*/
|
|
14069
|
+
return /*#__PURE__*/React__default.createElement(Grid.Col, {
|
|
14064
14070
|
key: index,
|
|
14065
14071
|
span: layout[index]
|
|
14066
14072
|
}, field(form.getInputProps));
|
|
@@ -14068,15 +14074,15 @@ const SimpleForm = _ref => {
|
|
|
14068
14074
|
if (Object.keys(components).includes(field.component)) {
|
|
14069
14075
|
const Component = components[field.component];
|
|
14070
14076
|
const sanitizedField = santize(field.field ?? "");
|
|
14071
|
-
return /*#__PURE__*/
|
|
14077
|
+
return /*#__PURE__*/React__default.createElement(Grid.Col, {
|
|
14072
14078
|
key: index,
|
|
14073
14079
|
span: layout[index]
|
|
14074
|
-
}, /*#__PURE__*/
|
|
14080
|
+
}, /*#__PURE__*/React__default.createElement(Component, _extends({}, field.field, inputProps, sanitizedField, form.getInputProps(sanitizedField.name))));
|
|
14075
14081
|
}
|
|
14076
14082
|
return null;
|
|
14077
|
-
})), /*#__PURE__*/
|
|
14083
|
+
})), /*#__PURE__*/React__default.createElement(Space, {
|
|
14078
14084
|
flex: 1
|
|
14079
|
-
}), /*#__PURE__*/
|
|
14085
|
+
}), /*#__PURE__*/React__default.createElement(FormButtons, {
|
|
14080
14086
|
hasSubmit,
|
|
14081
14087
|
hasReset,
|
|
14082
14088
|
buttonSize
|
|
@@ -14103,15 +14109,15 @@ const FormButtons = _ref2 => {
|
|
|
14103
14109
|
hasReset = false,
|
|
14104
14110
|
buttonSize
|
|
14105
14111
|
} = _ref2;
|
|
14106
|
-
return /*#__PURE__*/
|
|
14112
|
+
return /*#__PURE__*/React__default.createElement(Group, {
|
|
14107
14113
|
mt: "lg",
|
|
14108
14114
|
justify: "flex-end",
|
|
14109
14115
|
grow: true,
|
|
14110
14116
|
gap: 10,
|
|
14111
14117
|
w: "100%",
|
|
14112
14118
|
display: hasSubmit || hasReset ? "flex" : "none"
|
|
14113
|
-
}, /*#__PURE__*/
|
|
14114
|
-
leftSection: /*#__PURE__*/
|
|
14119
|
+
}, /*#__PURE__*/React__default.createElement(Button, {
|
|
14120
|
+
leftSection: /*#__PURE__*/React__default.createElement(Icons, {
|
|
14115
14121
|
name: "CloseCircle",
|
|
14116
14122
|
size: 16
|
|
14117
14123
|
}),
|
|
@@ -14125,12 +14131,12 @@ const FormButtons = _ref2 => {
|
|
|
14125
14131
|
display: hasReset ? "block" : "none"
|
|
14126
14132
|
},
|
|
14127
14133
|
flex: 1
|
|
14128
|
-
}, /*#__PURE__*/
|
|
14134
|
+
}, /*#__PURE__*/React__default.createElement(Text, {
|
|
14129
14135
|
fw: 400,
|
|
14130
14136
|
fz: "sm",
|
|
14131
14137
|
c: "white"
|
|
14132
|
-
}, "Cancel")), /*#__PURE__*/
|
|
14133
|
-
leftSection: /*#__PURE__*/
|
|
14138
|
+
}, "Cancel")), /*#__PURE__*/React__default.createElement(Button, {
|
|
14139
|
+
leftSection: /*#__PURE__*/React__default.createElement(Icons, {
|
|
14134
14140
|
name: "TickCircle",
|
|
14135
14141
|
size: 16
|
|
14136
14142
|
}),
|
|
@@ -14144,7 +14150,7 @@ const FormButtons = _ref2 => {
|
|
|
14144
14150
|
display: hasSubmit ? "block" : "none"
|
|
14145
14151
|
},
|
|
14146
14152
|
flex: 1
|
|
14147
|
-
}, /*#__PURE__*/
|
|
14153
|
+
}, /*#__PURE__*/React__default.createElement(Text, {
|
|
14148
14154
|
fw: 300,
|
|
14149
14155
|
fz: "sm",
|
|
14150
14156
|
c: "white"
|
|
@@ -14160,24 +14166,24 @@ const MaskedTilePanel = _ref => {
|
|
|
14160
14166
|
} = _ref;
|
|
14161
14167
|
const [masked, toggle] = useToggle();
|
|
14162
14168
|
const name = masked ? "Eye" : "EyeSlash";
|
|
14163
|
-
return /*#__PURE__*/
|
|
14169
|
+
return /*#__PURE__*/React__default.createElement(Card, {
|
|
14164
14170
|
p: "md",
|
|
14165
14171
|
bg: "gray.0",
|
|
14166
14172
|
style: {
|
|
14167
14173
|
borderRadius: "10px"
|
|
14168
14174
|
}
|
|
14169
|
-
}, /*#__PURE__*/
|
|
14175
|
+
}, /*#__PURE__*/React__default.createElement(Group, {
|
|
14170
14176
|
justify: "space-between"
|
|
14171
|
-
}, /*#__PURE__*/
|
|
14177
|
+
}, /*#__PURE__*/React__default.createElement(Stack, {
|
|
14172
14178
|
gap: 0,
|
|
14173
14179
|
p: 0,
|
|
14174
14180
|
flex: 1
|
|
14175
|
-
}, /*#__PURE__*/
|
|
14181
|
+
}, /*#__PURE__*/React__default.createElement(Text, {
|
|
14176
14182
|
fz: "sm",
|
|
14177
14183
|
fw: 300,
|
|
14178
14184
|
p: 0,
|
|
14179
14185
|
c: "gray.7"
|
|
14180
|
-
}, label), /*#__PURE__*/
|
|
14186
|
+
}, label), /*#__PURE__*/React__default.createElement(TextInput, {
|
|
14181
14187
|
type: masked ? "password" : "text",
|
|
14182
14188
|
fw: 300,
|
|
14183
14189
|
p: 0,
|
|
@@ -14185,10 +14191,10 @@ const MaskedTilePanel = _ref => {
|
|
|
14185
14191
|
value: value,
|
|
14186
14192
|
variant: "unstyled",
|
|
14187
14193
|
readOnly: true
|
|
14188
|
-
})), /*#__PURE__*/
|
|
14194
|
+
})), /*#__PURE__*/React__default.createElement(ActionIcon, {
|
|
14189
14195
|
variant: "transparent",
|
|
14190
14196
|
onClick: () => onMasked() ? toggle() : void 0
|
|
14191
|
-
}, icon && /*#__PURE__*/
|
|
14197
|
+
}, icon && /*#__PURE__*/React__default.createElement(Icons, {
|
|
14192
14198
|
size: 24,
|
|
14193
14199
|
color: "gray",
|
|
14194
14200
|
name: name
|
|
@@ -14199,24 +14205,24 @@ const TilePanel = _ref2 => {
|
|
|
14199
14205
|
label,
|
|
14200
14206
|
value
|
|
14201
14207
|
} = _ref2;
|
|
14202
|
-
return /*#__PURE__*/
|
|
14208
|
+
return /*#__PURE__*/React__default.createElement(Card, {
|
|
14203
14209
|
p: "md",
|
|
14204
14210
|
bg: "gray.0",
|
|
14205
14211
|
style: {
|
|
14206
14212
|
borderRadius: "10px"
|
|
14207
14213
|
}
|
|
14208
|
-
}, /*#__PURE__*/
|
|
14214
|
+
}, /*#__PURE__*/React__default.createElement(Group, {
|
|
14209
14215
|
justify: "space-between"
|
|
14210
|
-
}, /*#__PURE__*/
|
|
14216
|
+
}, /*#__PURE__*/React__default.createElement(Stack, {
|
|
14211
14217
|
gap: 0,
|
|
14212
14218
|
p: 0,
|
|
14213
14219
|
flex: 1
|
|
14214
|
-
}, /*#__PURE__*/
|
|
14220
|
+
}, /*#__PURE__*/React__default.createElement(Text, {
|
|
14215
14221
|
fz: "sm",
|
|
14216
14222
|
fw: 300,
|
|
14217
14223
|
p: 0,
|
|
14218
14224
|
c: "gray.7"
|
|
14219
|
-
}, label), /*#__PURE__*/
|
|
14225
|
+
}, label), /*#__PURE__*/React__default.createElement(TextInput, {
|
|
14220
14226
|
fw: 300,
|
|
14221
14227
|
p: 0,
|
|
14222
14228
|
c: "adiba",
|
|
@@ -14231,18 +14237,18 @@ var ConfirmAnimation = "data:null;base64,UEsDBBQAAAAIAEoK11qAribJgAAAALUAAAANAAA
|
|
|
14231
14237
|
const ConfirmModal = _ref => {
|
|
14232
14238
|
let {
|
|
14233
14239
|
children} = _ref;
|
|
14234
|
-
return /*#__PURE__*/
|
|
14240
|
+
return /*#__PURE__*/React__default.createElement(Stack, {
|
|
14235
14241
|
align: "center",
|
|
14236
14242
|
py: "md"
|
|
14237
|
-
}, /*#__PURE__*/
|
|
14243
|
+
}, /*#__PURE__*/React__default.createElement(Center, {
|
|
14238
14244
|
w: 150,
|
|
14239
14245
|
h: 150,
|
|
14240
14246
|
pt: "md"
|
|
14241
|
-
}, /*#__PURE__*/
|
|
14247
|
+
}, /*#__PURE__*/React__default.createElement(DotLottieReact, {
|
|
14242
14248
|
speed: 1,
|
|
14243
14249
|
src: ConfirmAnimation,
|
|
14244
14250
|
autoplay: true
|
|
14245
|
-
})), /*#__PURE__*/
|
|
14251
|
+
})), /*#__PURE__*/React__default.createElement(Text, {
|
|
14246
14252
|
ta: "center",
|
|
14247
14253
|
fw: 300
|
|
14248
14254
|
}, children));
|
|
@@ -14405,4 +14411,307 @@ const useManagedModals = () => {
|
|
|
14405
14411
|
};
|
|
14406
14412
|
};
|
|
14407
14413
|
|
|
14408
|
-
|
|
14414
|
+
/**
|
|
14415
|
+
* Default pagination page size
|
|
14416
|
+
*/
|
|
14417
|
+
const DEFAULT_PAGE_SIZE = 10;
|
|
14418
|
+
|
|
14419
|
+
/**
|
|
14420
|
+
* Maximum allowed page size for pagination
|
|
14421
|
+
*/
|
|
14422
|
+
const MAX_PAGE_SIZE = 100;
|
|
14423
|
+
|
|
14424
|
+
/**
|
|
14425
|
+
* Default API request timeout in milliseconds
|
|
14426
|
+
*/
|
|
14427
|
+
const DEFAULT_API_TIMEOUT = 30000;
|
|
14428
|
+
|
|
14429
|
+
/**
|
|
14430
|
+
* Configuration for URL filter hook
|
|
14431
|
+
*/
|
|
14432
|
+
|
|
14433
|
+
/**
|
|
14434
|
+
* Return type for useUrlFilters hook
|
|
14435
|
+
*/
|
|
14436
|
+
|
|
14437
|
+
/**
|
|
14438
|
+
* Generic hook for managing URL-based filters with pagination
|
|
14439
|
+
*
|
|
14440
|
+
* @example
|
|
14441
|
+
* ```tsx
|
|
14442
|
+
* interface MyFilters {
|
|
14443
|
+
* page: number;
|
|
14444
|
+
* limit: number;
|
|
14445
|
+
* name?: string;
|
|
14446
|
+
* status?: string;
|
|
14447
|
+
* }
|
|
14448
|
+
*
|
|
14449
|
+
* const { filters, updateFilters, clearFilters } = useUrlFilters<MyFilters>({
|
|
14450
|
+
* parseFilters: (params) => ({
|
|
14451
|
+
* page: parseInt(params.get('page') || '1', 10),
|
|
14452
|
+
* limit: parseInt(params.get('limit') || '10', 10),
|
|
14453
|
+
* name: params.get('name') || undefined,
|
|
14454
|
+
* status: params.get('status') || undefined,
|
|
14455
|
+
* }),
|
|
14456
|
+
* serializeFilters: (filters, params) => {
|
|
14457
|
+
* if (filters.page) params.set('page', String(filters.page));
|
|
14458
|
+
* if (filters.limit) params.set('limit', String(filters.limit));
|
|
14459
|
+
* if (filters.name) params.set('name', filters.name);
|
|
14460
|
+
* if (filters.status) params.set('status', filters.status);
|
|
14461
|
+
* },
|
|
14462
|
+
* });
|
|
14463
|
+
* ```
|
|
14464
|
+
*/
|
|
14465
|
+
function useUrlFilters(options) {
|
|
14466
|
+
const {
|
|
14467
|
+
defaultPageSize = DEFAULT_PAGE_SIZE,
|
|
14468
|
+
parseFilters,
|
|
14469
|
+
serializeFilters,
|
|
14470
|
+
hasActiveFilters: checkActiveFilters,
|
|
14471
|
+
toApiParams
|
|
14472
|
+
} = options;
|
|
14473
|
+
const [searchParams, setSearchParams] = useSearchParams();
|
|
14474
|
+
const filters = useMemo(() => {
|
|
14475
|
+
const parsed = parseFilters(searchParams);
|
|
14476
|
+
|
|
14477
|
+
// Ensure page and limit are always present with valid defaults
|
|
14478
|
+
const page = typeof parsed.page === "number" && parsed.page > 0 ? parsed.page : 1;
|
|
14479
|
+
const limit = typeof parsed.limit === "number" && parsed.limit > 0 ? parsed.limit : defaultPageSize;
|
|
14480
|
+
return {
|
|
14481
|
+
...parsed,
|
|
14482
|
+
page,
|
|
14483
|
+
limit
|
|
14484
|
+
};
|
|
14485
|
+
}, [searchParams, parseFilters, defaultPageSize]);
|
|
14486
|
+
const updateFilters = newFilters => {
|
|
14487
|
+
const params = new URLSearchParams(searchParams);
|
|
14488
|
+
|
|
14489
|
+
// Merge new filters with existing filters
|
|
14490
|
+
const mergedFilters = {
|
|
14491
|
+
...filters,
|
|
14492
|
+
...newFilters
|
|
14493
|
+
};
|
|
14494
|
+
|
|
14495
|
+
// Determine if we should reset page to 1
|
|
14496
|
+
// Reset if: page is not explicitly set AND other filters are changing
|
|
14497
|
+
const hasNonPaginationChanges = Object.keys(newFilters).some(key => key !== "page" && key !== "limit");
|
|
14498
|
+
if (newFilters.page === undefined && hasNonPaginationChanges) {
|
|
14499
|
+
mergedFilters.page = 1; // Reset to page 1
|
|
14500
|
+
}
|
|
14501
|
+
|
|
14502
|
+
// Ensure page and limit are numbers
|
|
14503
|
+
if (typeof mergedFilters.page !== "number" || mergedFilters.page < 1) {
|
|
14504
|
+
mergedFilters.page = 1;
|
|
14505
|
+
}
|
|
14506
|
+
if (typeof mergedFilters.limit !== "number" || mergedFilters.limit < 1) {
|
|
14507
|
+
mergedFilters.limit = defaultPageSize;
|
|
14508
|
+
}
|
|
14509
|
+
|
|
14510
|
+
// Serialize all filters
|
|
14511
|
+
serializeFilters(mergedFilters, params);
|
|
14512
|
+
setSearchParams(params, {
|
|
14513
|
+
replace: true
|
|
14514
|
+
});
|
|
14515
|
+
};
|
|
14516
|
+
const clearFilters = () => {
|
|
14517
|
+
const params = new URLSearchParams();
|
|
14518
|
+
params.set("page", "1");
|
|
14519
|
+
params.set("limit", String(defaultPageSize));
|
|
14520
|
+
setSearchParams(params, {
|
|
14521
|
+
replace: true
|
|
14522
|
+
});
|
|
14523
|
+
};
|
|
14524
|
+
const hasActiveFilters = useMemo(() => {
|
|
14525
|
+
if (checkActiveFilters) {
|
|
14526
|
+
return checkActiveFilters(filters);
|
|
14527
|
+
}
|
|
14528
|
+
// Default: check if any non-pagination fields have values
|
|
14529
|
+
return Object.keys(filters).some(key => {
|
|
14530
|
+
if (key === "page" || key === "limit") return false;
|
|
14531
|
+
const value = filters[key];
|
|
14532
|
+
return value !== undefined && value !== null && value !== "";
|
|
14533
|
+
});
|
|
14534
|
+
}, [filters, checkActiveFilters]);
|
|
14535
|
+
const apiParams = useMemo(() => {
|
|
14536
|
+
if (toApiParams) {
|
|
14537
|
+
return toApiParams(filters);
|
|
14538
|
+
}
|
|
14539
|
+
return undefined;
|
|
14540
|
+
}, [filters, toApiParams]);
|
|
14541
|
+
return {
|
|
14542
|
+
filters,
|
|
14543
|
+
updateFilters,
|
|
14544
|
+
clearFilters,
|
|
14545
|
+
hasActiveFilters,
|
|
14546
|
+
apiParams
|
|
14547
|
+
};
|
|
14548
|
+
}
|
|
14549
|
+
|
|
14550
|
+
class ApiClient {
|
|
14551
|
+
constructor(config) {
|
|
14552
|
+
const {
|
|
14553
|
+
baseURL = "/",
|
|
14554
|
+
timeout = DEFAULT_API_TIMEOUT,
|
|
14555
|
+
headers = {
|
|
14556
|
+
"Content-Type": "application/json"
|
|
14557
|
+
}
|
|
14558
|
+
} = config;
|
|
14559
|
+
this.client = axios.create({
|
|
14560
|
+
baseURL,
|
|
14561
|
+
timeout,
|
|
14562
|
+
headers
|
|
14563
|
+
});
|
|
14564
|
+
this.setupInterceptors();
|
|
14565
|
+
}
|
|
14566
|
+
setupInterceptors() {
|
|
14567
|
+
// Request interceptor
|
|
14568
|
+
this.client.interceptors.request.use(config => {
|
|
14569
|
+
// Add auth token, logging, etc. if needed
|
|
14570
|
+
return config;
|
|
14571
|
+
}, error => Promise.reject(error));
|
|
14572
|
+
|
|
14573
|
+
// Response interceptor
|
|
14574
|
+
this.client.interceptors.response.use(response => {
|
|
14575
|
+
return response;
|
|
14576
|
+
}, error => {
|
|
14577
|
+
// Handle errors globally
|
|
14578
|
+
return Promise.reject(this.handleError(error));
|
|
14579
|
+
});
|
|
14580
|
+
}
|
|
14581
|
+
handleError(error) {
|
|
14582
|
+
if (error && typeof error === "object" && "response" in error) {
|
|
14583
|
+
const axiosError = error;
|
|
14584
|
+
if (axiosError.response) {
|
|
14585
|
+
return {
|
|
14586
|
+
status: "error",
|
|
14587
|
+
code: axiosError.response.status,
|
|
14588
|
+
message: axiosError.response.data?.message || "An error occurred",
|
|
14589
|
+
error: axiosError.response.data?.error || axiosError.message || "An unexpected error occurred"
|
|
14590
|
+
};
|
|
14591
|
+
}
|
|
14592
|
+
}
|
|
14593
|
+
const errorMessage = error instanceof Error ? error.message : "An unexpected error occurred";
|
|
14594
|
+
return {
|
|
14595
|
+
status: "error",
|
|
14596
|
+
code: 500,
|
|
14597
|
+
message: "Network error",
|
|
14598
|
+
error: errorMessage
|
|
14599
|
+
};
|
|
14600
|
+
}
|
|
14601
|
+
async get(url, config) {
|
|
14602
|
+
const response = await this.client.get(url, config);
|
|
14603
|
+
return response.data;
|
|
14604
|
+
}
|
|
14605
|
+
async post(url, data, config) {
|
|
14606
|
+
const response = await this.client.post(url, data, config);
|
|
14607
|
+
return response.data;
|
|
14608
|
+
}
|
|
14609
|
+
async put(url, data, config) {
|
|
14610
|
+
const response = await this.client.put(url, data, config);
|
|
14611
|
+
return response.data;
|
|
14612
|
+
}
|
|
14613
|
+
async delete(url, config) {
|
|
14614
|
+
const response = await this.client.delete(url, config);
|
|
14615
|
+
return response.data;
|
|
14616
|
+
}
|
|
14617
|
+
}
|
|
14618
|
+
|
|
14619
|
+
/**
|
|
14620
|
+
* Factory function to create a configured API client instance
|
|
14621
|
+
* @param config - Configuration options for the API client
|
|
14622
|
+
* @returns Configured ApiClient instance
|
|
14623
|
+
*/
|
|
14624
|
+
function createApiClient() {
|
|
14625
|
+
let config = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
14626
|
+
return new ApiClient(config);
|
|
14627
|
+
}
|
|
14628
|
+
|
|
14629
|
+
/**
|
|
14630
|
+
* Default API client instance with default configuration
|
|
14631
|
+
* For custom configuration, use createApiClient() instead
|
|
14632
|
+
*/
|
|
14633
|
+
const apiClient = createApiClient();
|
|
14634
|
+
|
|
14635
|
+
/**
|
|
14636
|
+
* Wrapper component for modal content to ensure MantineProvider context is available
|
|
14637
|
+
* This is needed because modals rendered by the appshell may not have access to the pilet's provider
|
|
14638
|
+
*/
|
|
14639
|
+
const ModalContentWrapper = _ref => {
|
|
14640
|
+
let {
|
|
14641
|
+
children
|
|
14642
|
+
} = _ref;
|
|
14643
|
+
return /*#__PURE__*/React.createElement(MantineProvider, {
|
|
14644
|
+
theme: theme
|
|
14645
|
+
}, /*#__PURE__*/React.createElement(DatesProvider, {
|
|
14646
|
+
settings: {
|
|
14647
|
+
locale: "en",
|
|
14648
|
+
timezone: "UTC"
|
|
14649
|
+
}
|
|
14650
|
+
}, children));
|
|
14651
|
+
};
|
|
14652
|
+
|
|
14653
|
+
/**
|
|
14654
|
+
* Default QueryClient configuration
|
|
14655
|
+
*/
|
|
14656
|
+
const defaultQueryClient = new QueryClient({
|
|
14657
|
+
defaultOptions: {
|
|
14658
|
+
queries: {
|
|
14659
|
+
retry: 1,
|
|
14660
|
+
refetchOnWindowFocus: false,
|
|
14661
|
+
staleTime: 30000,
|
|
14662
|
+
// 30 seconds
|
|
14663
|
+
gcTime: 5 * 60 * 1000 // 5 minutes
|
|
14664
|
+
},
|
|
14665
|
+
mutations: {
|
|
14666
|
+
retry: false
|
|
14667
|
+
}
|
|
14668
|
+
}
|
|
14669
|
+
});
|
|
14670
|
+
/**
|
|
14671
|
+
* Higher-order component that wraps a component with all necessary providers:
|
|
14672
|
+
* - QueryClientProvider (React Query)
|
|
14673
|
+
* - MantineProvider (Mantine UI)
|
|
14674
|
+
* - DatesProvider (Mantine Dates)
|
|
14675
|
+
*
|
|
14676
|
+
* @param Component - Component to wrap
|
|
14677
|
+
* @param options - Optional configuration
|
|
14678
|
+
* @returns Wrapped component with all providers
|
|
14679
|
+
*
|
|
14680
|
+
* @example
|
|
14681
|
+
* ```tsx
|
|
14682
|
+
* // Using default configuration
|
|
14683
|
+
* const WrappedComponent = withProviders(MyComponent);
|
|
14684
|
+
*
|
|
14685
|
+
* // Using custom QueryClient
|
|
14686
|
+
* const customQueryClient = new QueryClient({ ... });
|
|
14687
|
+
* const WrappedComponent = withProviders(MyComponent, {
|
|
14688
|
+
* queryClient: customQueryClient,
|
|
14689
|
+
* });
|
|
14690
|
+
* ```
|
|
14691
|
+
*/
|
|
14692
|
+
function withProviders(Component) {
|
|
14693
|
+
let options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
14694
|
+
const {
|
|
14695
|
+
queryClient = defaultQueryClient,
|
|
14696
|
+
enableDevtools = true,
|
|
14697
|
+
theme: customTheme = theme,
|
|
14698
|
+
datesSettings = {
|
|
14699
|
+
locale: "en",
|
|
14700
|
+
timezone: "UTC"
|
|
14701
|
+
}
|
|
14702
|
+
} = options;
|
|
14703
|
+
const WrappedComponent = props => {
|
|
14704
|
+
const showDevtools = enableDevtools && typeof process !== "undefined" && process.env?.NODE_ENV === "development";
|
|
14705
|
+
return /*#__PURE__*/React.createElement(QueryClientProvider, {
|
|
14706
|
+
client: queryClient
|
|
14707
|
+
}, /*#__PURE__*/React.createElement(MantineProvider, {
|
|
14708
|
+
theme: customTheme
|
|
14709
|
+
}, /*#__PURE__*/React.createElement(DatesProvider, {
|
|
14710
|
+
settings: datesSettings
|
|
14711
|
+
}, /*#__PURE__*/React.createElement(Component, props), showDevtools && /*#__PURE__*/React.createElement(ReactQueryDevtools, null))));
|
|
14712
|
+
};
|
|
14713
|
+
WrappedComponent.displayName = `withProviders(${Component.displayName || Component.name || "Component"})`;
|
|
14714
|
+
return WrappedComponent;
|
|
14715
|
+
}
|
|
14716
|
+
|
|
14717
|
+
export { ApplicationMenu as A, BasicHeatmap as B, CalendarHeatmap as C, DonutChart as D, EqualizerColumn as E, File as F, SimpleForm as G, MaskedTilePanel as H, InterpolatedHeatmap as I, TilePanel as J, useModal as K, LabelPanel as L, MultiAxisArea as M, useManagedModals as N, useUrlFilters as O, PageTitle as P, DEFAULT_PAGE_SIZE as Q, MAX_PAGE_SIZE as R, SimpleColumn as S, TitledPanel as T, UserMenu as U, DEFAULT_API_TIMEOUT as V, createApiClient as W, apiClient as X, ModalContentWrapper as Y, withProviders as Z, StackedColumn as a, SimpleArea as b, StackedArea as c, Icons as d, DynamicLogo as e, DynamicShigaLogo as f, getDefaultExportFromCjs as g, SideMenu as h, SimplePanel as i, SearchPanel as j, AvatarLabelPanel as k, SimpleText as l, TitleWithIndex as m, ConnectionPanel as n, ApplicationPanel as o, SubscriptionPlans as p, PaymentMethod as q, PaymentMethodAdd as r, SimpleTable as s, theme as t, ErrorModal as u, InfoModal as v, SimpleModal as w, SuccessModal as x, TwoFactorModal as y, Drawer as z };
|