@cashub/ui 0.47.0 → 0.48.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/Tab/TabList.js +38 -26
- package/Tab/TabPanel.js +13 -20
- package/Tab/TabTab.js +36 -24
- package/Tab/index.js +15 -1
- package/Tab/subComponent/TabListV2.js +25 -0
- package/Tab/subComponent/TabPanelV2.js +52 -0
- package/Tab/subComponent/TabTabV2.js +63 -0
- package/VerticalTab/TabList.js +13 -18
- package/VerticalTab/TabPanel.js +16 -20
- package/VerticalTab/TabTab.js +40 -21
- package/VerticalTab/VerticalTab.js +8 -4
- package/alert/Alert.js +12 -5
- package/animate/Collapse.js +5 -7
- package/animate/Loader.js +18 -7
- package/animate/PulseRing.js +18 -5
- package/animate/Spinner.js +8 -3
- package/backdrop/BaseBackdrop.js +9 -3
- package/backdrop/LoadingBackdrop.js +7 -3
- package/backdrop/ModalBackdrop.js +5 -3
- package/badge/Badge.js +15 -3
- package/badge/BadgeDot.js +8 -3
- package/badge/BadgeFill.js +24 -6
- package/badge/BadgeWithText.js +13 -3
- package/billing/BarChart.js +1 -1
- package/breadcrumb/Breadcrumb.js +42 -3
- package/button/Button.js +88 -20
- package/button/ButtonGroup.js +33 -9
- package/button/IconButton.js +37 -10
- package/button/ScrollToTopButton.js +12 -4
- package/callout/Callout.js +37 -8
- package/chart/BarChart.js +10 -17
- package/chart/DoughnutChart.js +34 -20
- package/chart/LineChart.js +11 -18
- package/chart/SingleBarChart.js +22 -5
- package/chart/utils/centerTextPlugin.js +2 -2
- package/chart/utils/customTooltip.js +7 -7
- package/chart/utils/htmlLegendPlugin.js +1 -1
- package/container/FlexContainer.js +15 -7
- package/cropper/Cropper.js +1 -2
- package/datetimePicker/DatePicker.js +80 -26
- package/datetimePicker/DatePickerV2.js +95 -36
- package/datetimePicker/DatetimePicker.js +174 -11
- package/datetimePicker/DatetimePickerV2.js +87 -33
- package/datetimePicker/DatetimePickerV3.js +174 -11
- package/datetimePicker/TimeInput.js +35 -10
- package/datetimePicker/TimePicker.js +77 -22
- package/datetimePicker/TimePickerStyle.js +53 -3
- package/datetimePicker/TimePickerV2.js +54 -21
- package/datetimePicker/accordion/Month.js +93 -16
- package/datetimePicker/accordion/Year.js +96 -18
- package/datetimePicker/hooks/useChangeNumber.js +3 -6
- package/datetimePicker/hooks/useDecrease.js +3 -6
- package/datetimePicker/hooks/useIncrease.js +3 -6
- package/datetimePicker/subComponent/Accordion.js +101 -20
- package/descriptionList/DescriptionDetail.js +15 -4
- package/descriptionList/DescriptionList.js +12 -4
- package/descriptionList/DescriptionTerm.js +5 -3
- package/divider/Divider.js +15 -6
- package/dropdown/DropdownButtonOption.js +22 -6
- package/dropdown/DropdownContent.js +29 -15
- package/dropdown/DropdownDivOption.js +17 -3
- package/dropdown/DropdownLinkOption.js +14 -3
- package/dropdown/DropdownToggle.js +7 -15
- package/dropzone/FileDropzone.js +121 -22
- package/dropzone/ImageDropzone.js +83 -14
- package/dropzone/subComponent/Message.js +11 -4
- package/figure/IconFigure.js +16 -7
- package/figure/ImageFigure.js +19 -6
- package/file/HiddenFileInput.js +3 -3
- package/form/Checkbox.js +74 -13
- package/form/Fieldset.js +9 -3
- package/form/FormItem.js +10 -5
- package/form/Input.js +40 -7
- package/form/Label.js +34 -10
- package/form/MutedText.js +8 -4
- package/form/PasswordInput.js +20 -13
- package/form/RadioButton.js +55 -8
- package/form/SearchSelect.js +64 -12
- package/form/Searchbox.js +45 -19
- package/form/Slider.js +28 -10
- package/form/SwitchButton.js +48 -14
- package/form/Textarea.js +30 -3
- package/form/TreeView.js +13 -6
- package/grid/Column.js +23 -10
- package/grid/Grid.js +14 -6
- package/heading/Heading1.js +8 -4
- package/heading/Heading2.js +11 -5
- package/heading/Heading3.js +20 -8
- package/iconbox/ApplicationIconBox.js +48 -12
- package/iconbox/IconBox.js +31 -7
- package/iconbox/IconBoxV2.js +33 -8
- package/iconbox/subComponent/IconBoxFigure.js +17 -9
- package/iconbox/subComponent/IconBoxImage.js +21 -8
- package/image/ImageFluid.js +7 -3
- package/image/UploadImage.js +66 -18
- package/index.js +8 -1
- package/jsoneditor/JsonEditor.js +121 -15
- package/keyframe/Pulse.js +13 -3
- package/keyframe/Spin.js +5 -3
- package/layout/Aside.js +30 -5
- package/layout/Backdrop.js +8 -4
- package/layout/Container.js +21 -5
- package/layout/Footer.js +26 -7
- package/link/LinkSpan.js +37 -19
- package/map/GoogleMap.js +3 -7
- package/map/GoogleReverseGeolocation.js +6 -3
- package/map/LeafletMap.js +2 -2
- package/map/subComponent/GoogleMapContainer.js +16 -4
- package/map/subComponent/GoogleMapPopup.js +7 -10
- package/map/subComponent/GoogleMapWrapper.js +8 -15
- package/map/subComponent/LeafletDrawControl.js +9 -7
- package/map/subComponent/LeafletMapContainer.js +159 -4
- package/modal/StateModal.js +49 -28
- package/modal/TitleModal.js +70 -29
- package/package.json +1 -1
- package/page/Disclaimer.js +119 -3
- package/paginate/Paginate.js +54 -12
- package/popover/Popover.js +30 -25
- package/qrcode/QRCode.js +20 -6
- package/qrcode/QRCodeContainter.js +12 -4
- package/ribbon/Ribbon.js +29 -4
- package/section/Section.js +68 -20
- package/section/SectionBody.js +29 -8
- package/section/SectionHeader.js +36 -11
- package/section/SectionToolbar.js +9 -3
- package/section/SectionToolbarItem.js +8 -3
- package/select/InputSelect.js +16 -23
- package/select/Select.js +112 -43
- package/select/subComponent/Checkbox.js +24 -5
- package/select/subComponent/Footer.js +4 -3
- package/select/subComponent/ListBox.js +12 -5
- package/select/subComponent/Option.js +27 -7
- package/select/subComponent/OptionGroup.js +13 -3
- package/select/subComponent/Options.js +18 -5
- package/select/subComponent/SearchBox.js +34 -12
- package/select/subComponent/SelectedMultipleTags.js +21 -3
- package/select/subComponent/SelectedMultipleText.js +20 -4
- package/select/subComponent/SelectedSingle.js +7 -3
- package/styles/GlobalStyle.js +156 -45
- package/styles/mixin/backgroundColor.js +16 -8
- package/styles/mixin/borderColor.js +13 -7
- package/styles/mixin/color.js +13 -7
- package/styles/mixin/colorOnBackground.js +13 -7
- package/styles/mixin/inputPlaceholder.js +20 -3
- package/styles/mixin/media.js +5 -3
- package/styles/mixin/rounded.js +10 -6
- package/styles/mixin/scrollbar.js +13 -3
- package/styles/theme/dark.theme.js +15 -14
- package/styles/theme/light.theme.js +15 -14
- package/styles/theme/white.theme.js +15 -14
- package/table/GridTable.js +71 -33
- package/table/ImageBox.js +15 -5
- package/table/InfiniteGridTable.js +92 -46
- package/table/PermissionTable.js +32 -10
- package/table/SimpleGridTable.js +143 -0
- package/table/Table.js +198 -48
- package/table/__mock__/columns.js +1 -1
- package/table/index.js +7 -0
- package/table/subComponent/BaseTableHeadCell.js +37 -8
- package/table/subComponent/GridTableFooter.js +10 -4
- package/table/subComponent/GridTableHeadCell.js +6 -4
- package/table/subComponent/Resizer.js +19 -4
- package/table/subComponent/TableFooter.js +15 -6
- package/table/subComponent/TableFooterInfo.js +4 -3
- package/table/subComponent/TableFooterPager.js +19 -6
- package/table/subComponent/TableHeadCell.js +9 -3
- package/table/subComponent/TableSort.js +17 -7
- package/tagify/TagifyStyle.js +49 -3
- package/tagify/Tags.js +37 -21
- package/tagify/templates/getCreateButtonTemplate.js +5 -2
- package/text/Paragraph.js +50 -12
- package/timeline/Timeline.js +94 -17
- package/toast/CustomToastContainer.js +35 -3
- package/toast/MessageContainer.js +22 -4
- package/tooltip/Tooltip.js +47 -19
- package/treeView/TreeViewV2.js +1 -1
- package/treeView/TreeflexStyle.js +38 -3
- package/wizard/Wizard.js +115 -6
package/page/Disclaimer.js
CHANGED
|
@@ -5,8 +5,124 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.default = void 0;
|
|
7
7
|
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
8
|
-
var _templateObject;
|
|
9
8
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
const Disclaimer = _styledComponents.default.div`
|
|
10
|
+
border: var(--border-width) solid var(--border-color);
|
|
11
|
+
border-radius: var(--border-radius);
|
|
12
|
+
color: var(--font-on-background);
|
|
13
|
+
padding: var(--spacing);
|
|
14
|
+
|
|
15
|
+
> article {
|
|
16
|
+
line-height: 1.5;
|
|
17
|
+
|
|
18
|
+
&:not(:last-child) {
|
|
19
|
+
padding-bottom: var(--spacing-l);
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
> h2 {
|
|
23
|
+
text-align: center;
|
|
24
|
+
margin-bottom: var(--spacing-l);
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
> em {
|
|
28
|
+
display: block;
|
|
29
|
+
margin-bottom: var(--spacing-s);
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
> section {
|
|
33
|
+
margin-bottom: var(--spacing);
|
|
34
|
+
|
|
35
|
+
> h3 {
|
|
36
|
+
margin-bottom: var(--spacing-xs);
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
> p {
|
|
40
|
+
margin-bottom: var(--spacing-xs);
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
ul {
|
|
44
|
+
margin: var(--spacing-s) 0;
|
|
45
|
+
|
|
46
|
+
li {
|
|
47
|
+
margin: var(--spacing-xs) 0 var(--spacing-xs) var(--spacing-s);
|
|
48
|
+
|
|
49
|
+
&.disc {
|
|
50
|
+
list-style: disc;
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
ol {
|
|
56
|
+
padding: 0;
|
|
57
|
+
margin: var(--spacing-xs) 0 var(--spacing-xs) var(--spacing-s);
|
|
58
|
+
|
|
59
|
+
&.counter-number {
|
|
60
|
+
counter-reset: number;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
&.counter-number-alpha {
|
|
64
|
+
counter-reset: number alpha;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
&.nested-counter-number {
|
|
68
|
+
counter-reset: nested-number;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
&.ml-0 {
|
|
72
|
+
margin-left: 0;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
li {
|
|
76
|
+
margin: var(--spacing-s) 0;
|
|
77
|
+
|
|
78
|
+
&.decimal {
|
|
79
|
+
list-style: decimal;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
&.counter-number-increment {
|
|
83
|
+
counter-increment: number;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
&.counter-alpha-increment {
|
|
87
|
+
counter-increment: alpha;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
&.counter-number {
|
|
91
|
+
display: flex;
|
|
92
|
+
margin: var(--spacing-xs) 0;
|
|
93
|
+
|
|
94
|
+
&::before {
|
|
95
|
+
margin-right: var(--spacing-xs);
|
|
96
|
+
content: counters(number, '.') ' ';
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
&.counter-alpha {
|
|
101
|
+
display: flex;
|
|
102
|
+
margin: var(--spacing-xs) 0;
|
|
103
|
+
|
|
104
|
+
&::before {
|
|
105
|
+
margin-right: var(--spacing-xs);
|
|
106
|
+
content: '(' counter(alpha, upper-alpha) ')';
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
&.nested-counter-number-increment {
|
|
111
|
+
counter-increment: nested-number;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
&.nested-counter-number {
|
|
115
|
+
display: flex;
|
|
116
|
+
margin: var(--spacing-xs) 0;
|
|
117
|
+
|
|
118
|
+
&::before {
|
|
119
|
+
margin-right: var(--spacing-xs);
|
|
120
|
+
content: counters(number, '.') '.' counters(nested-number, '.');
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
`;
|
|
12
128
|
var _default = exports.default = Disclaimer;
|
package/paginate/Paginate.js
CHANGED
|
@@ -8,10 +8,8 @@ var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
|
8
8
|
var _fa = require("react-icons/fa");
|
|
9
9
|
var _hooks = require("@cashub/hooks");
|
|
10
10
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
11
|
-
var _templateObject, _templateObject2, _templateObject3, _templateObject4;
|
|
12
11
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
13
12
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
14
|
-
function _taggedTemplateLiteral(e, t) { return t || (t = e.slice(0)), Object.freeze(Object.defineProperties(e, { raw: { value: Object.freeze(t) } })); }
|
|
15
13
|
const Paginate = props => {
|
|
16
14
|
const {
|
|
17
15
|
currentPage,
|
|
@@ -68,28 +66,72 @@ const Paginate = props => {
|
|
|
68
66
|
})]
|
|
69
67
|
});
|
|
70
68
|
};
|
|
71
|
-
const Container = _styledComponents.default.ul
|
|
69
|
+
const Container = _styledComponents.default.ul`
|
|
70
|
+
display: flex;
|
|
71
|
+
text-align: center;
|
|
72
|
+
|
|
73
|
+
${_ref => {
|
|
72
74
|
let {
|
|
73
75
|
alignRight
|
|
74
76
|
} = _ref;
|
|
75
77
|
return alignRight && 'justify-content: flex-end';
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
+
}};
|
|
79
|
+
`;
|
|
80
|
+
const Link = _styledComponents.default.li`
|
|
81
|
+
width: 36px;
|
|
82
|
+
line-height: 37px;
|
|
83
|
+
font-size: var(--font-body1);
|
|
84
|
+
color: var(--font-on-background);
|
|
85
|
+
border-radius: var(--border-radius-round);
|
|
86
|
+
cursor: pointer;
|
|
87
|
+
transition: 0.3s;
|
|
88
|
+
|
|
89
|
+
&:not(:last-child) {
|
|
90
|
+
margin-right: var(--spacing-xs);
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
${_ref2 => {
|
|
78
94
|
let {
|
|
79
95
|
disabled
|
|
80
96
|
} = _ref2;
|
|
81
|
-
return disabled && (0, _styledComponents.css)
|
|
82
|
-
|
|
97
|
+
return disabled && (0, _styledComponents.css)`
|
|
98
|
+
opacity: 0.5;
|
|
99
|
+
cursor: no-drop;
|
|
100
|
+
`;
|
|
101
|
+
}};
|
|
102
|
+
|
|
103
|
+
${_ref3 => {
|
|
83
104
|
let {
|
|
84
105
|
active
|
|
85
106
|
} = _ref3;
|
|
86
|
-
return active &&
|
|
87
|
-
|
|
107
|
+
return active && `
|
|
108
|
+
background-color: var(--color-primary);
|
|
109
|
+
color: var(--font-on-primary);
|
|
110
|
+
`;
|
|
111
|
+
}}
|
|
112
|
+
|
|
113
|
+
&:hover {
|
|
114
|
+
${_ref4 => {
|
|
88
115
|
let {
|
|
89
116
|
disabled,
|
|
90
117
|
className
|
|
91
118
|
} = _ref4;
|
|
92
|
-
return !disabled && !className &&
|
|
93
|
-
|
|
94
|
-
|
|
119
|
+
return !disabled && !className && `
|
|
120
|
+
background-color: var(--color-primary);
|
|
121
|
+
color: var(--font-on-primary);
|
|
122
|
+
`;
|
|
123
|
+
}}
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
&.paginationDots {
|
|
127
|
+
cursor: default;
|
|
128
|
+
}
|
|
129
|
+
`;
|
|
130
|
+
const Icon = _styledComponents.default.span`
|
|
131
|
+
font-size: var(--font-body1);
|
|
132
|
+
display: flex;
|
|
133
|
+
justify-content: center;
|
|
134
|
+
align-items: center;
|
|
135
|
+
height: 100%;
|
|
136
|
+
`;
|
|
95
137
|
var _default = exports.default = Paginate;
|
package/popover/Popover.js
CHANGED
|
@@ -11,41 +11,32 @@ var _reactOutsideClickHandler = _interopRequireDefault(require("react-outside-cl
|
|
|
11
11
|
var _hooks = require("@cashub/hooks");
|
|
12
12
|
var _utils = require("@cashub/utils");
|
|
13
13
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
14
|
-
var _templateObject, _templateObject2;
|
|
15
|
-
const _excluded = ["container", "id"];
|
|
16
14
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
17
15
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
18
16
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
19
|
-
function _taggedTemplateLiteral(e, t) { return t || (t = e.slice(0)), Object.freeze(Object.defineProperties(e, { raw: { value: Object.freeze(t) } })); }
|
|
20
|
-
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
21
|
-
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
22
|
-
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
23
|
-
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
|
|
24
|
-
function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
25
|
-
function _objectWithoutProperties(e, t) { if (null == e) return {}; var o, r, i = _objectWithoutPropertiesLoose(e, t); if (Object.getOwnPropertySymbols) { var s = Object.getOwnPropertySymbols(e); for (r = 0; r < s.length; r++) o = s[r], t.includes(o) || {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]); } return i; }
|
|
26
|
-
function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t = {}; for (var n in r) if ({}.hasOwnProperty.call(r, n)) { if (e.includes(n)) continue; t[n] = r[n]; } return t; }
|
|
27
17
|
const Popover = _ref => {
|
|
28
18
|
let {
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
19
|
+
container,
|
|
20
|
+
id,
|
|
21
|
+
...props
|
|
22
|
+
} = _ref;
|
|
33
23
|
const rootElement = (0, _utils.appendElementTo)('PopoverContainer', 'div', container);
|
|
34
24
|
const handleClose = () => {
|
|
35
25
|
// unmount component and clear event handler and state before remove container
|
|
36
26
|
(0, _reactDom.unmountComponentAtNode)(rootElement);
|
|
37
27
|
rootElement.remove();
|
|
38
28
|
};
|
|
39
|
-
const result = document.getElementById(
|
|
29
|
+
const result = document.getElementById(`popover${id}`);
|
|
40
30
|
// found previous element mean want to close popover now, so remove it
|
|
41
31
|
if (result) {
|
|
42
32
|
handleClose();
|
|
43
33
|
return;
|
|
44
34
|
}
|
|
45
|
-
_reactDom.default.render(/*#__PURE__*/(0, _jsxRuntime.jsx)(Box,
|
|
46
|
-
|
|
35
|
+
_reactDom.default.render(/*#__PURE__*/(0, _jsxRuntime.jsx)(Box, {
|
|
36
|
+
...props,
|
|
37
|
+
id: `popover${id}`,
|
|
47
38
|
handleClose: handleClose
|
|
48
|
-
})
|
|
39
|
+
}), rootElement);
|
|
49
40
|
};
|
|
50
41
|
const Box = _ref2 => {
|
|
51
42
|
let {
|
|
@@ -65,22 +56,36 @@ const Box = _ref2 => {
|
|
|
65
56
|
});
|
|
66
57
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactOutsideClickHandler.default, {
|
|
67
58
|
onOutsideClick: event => {
|
|
68
|
-
if (
|
|
59
|
+
if (`popover${event.target.id}` !== id) {
|
|
69
60
|
handleClose();
|
|
70
61
|
}
|
|
71
62
|
},
|
|
72
63
|
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(Wrapper, {
|
|
73
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(PopoverBox,
|
|
64
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(PopoverBox, {
|
|
74
65
|
id: id,
|
|
75
66
|
ref: setTooltipElement,
|
|
76
|
-
style: styles.popper
|
|
77
|
-
|
|
67
|
+
style: styles.popper,
|
|
68
|
+
...attributes.popper,
|
|
78
69
|
placement: state && state.placement,
|
|
79
70
|
children: content
|
|
80
|
-
})
|
|
71
|
+
})
|
|
81
72
|
})
|
|
82
73
|
});
|
|
83
74
|
};
|
|
84
|
-
const Wrapper = _styledComponents.default.div
|
|
85
|
-
|
|
75
|
+
const Wrapper = _styledComponents.default.div`
|
|
76
|
+
position: relative;
|
|
77
|
+
`;
|
|
78
|
+
const PopoverBox = _styledComponents.default.div`
|
|
79
|
+
border: 1px solid var(--border-color);
|
|
80
|
+
color: var(--font-on-background);
|
|
81
|
+
background: var(--color-background2);
|
|
82
|
+
box-shadow: var(--box-shadow);
|
|
83
|
+
border-radius: calc(var(--border-radius) / 2);
|
|
84
|
+
padding: var(--spacing-xs);
|
|
85
|
+
z-index: 80;
|
|
86
|
+
font-size: var(--font-body1);
|
|
87
|
+
font-weight: var(--font-normal);
|
|
88
|
+
max-width: 50vw;
|
|
89
|
+
word-break: break-all;
|
|
90
|
+
`;
|
|
86
91
|
var _default = exports.default = Popover;
|
package/qrcode/QRCode.js
CHANGED
|
@@ -8,9 +8,7 @@ var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
|
8
8
|
var _qrcode = _interopRequireDefault(require("qrcode.react"));
|
|
9
9
|
var _cashubLogoOnly = _interopRequireDefault(require("../assets/images/cashub-logo-only.png"));
|
|
10
10
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
11
|
-
var _templateObject, _templateObject2, _templateObject3, _templateObject4;
|
|
12
11
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
13
|
-
function _taggedTemplateLiteral(e, t) { return t || (t = e.slice(0)), Object.freeze(Object.defineProperties(e, { raw: { value: Object.freeze(t) } })); }
|
|
14
12
|
const QRCodeBox = _ref => {
|
|
15
13
|
let {
|
|
16
14
|
content,
|
|
@@ -37,8 +35,24 @@ const QRCodeBox = _ref => {
|
|
|
37
35
|
})]
|
|
38
36
|
});
|
|
39
37
|
};
|
|
40
|
-
const Wrapper = _styledComponents.default.div
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
38
|
+
const Wrapper = _styledComponents.default.div`
|
|
39
|
+
color: var(--font-on-background);
|
|
40
|
+
text-align: center;
|
|
41
|
+
font-weight: var(--font-bold);
|
|
42
|
+
`;
|
|
43
|
+
const Container = _styledComponents.default.div`
|
|
44
|
+
display: inline-block;
|
|
45
|
+
padding: var(--spacing);
|
|
46
|
+
background: #fff;
|
|
47
|
+
border-radius: var(--border-radius);
|
|
48
|
+
`;
|
|
49
|
+
const Text = _styledComponents.default.p`
|
|
50
|
+
margin-top: var(--spacing-s);
|
|
51
|
+
font-size: var(--font-h3);
|
|
52
|
+
color: #000;
|
|
53
|
+
`;
|
|
54
|
+
const Message = _styledComponents.default.p`
|
|
55
|
+
margin-top: var(--spacing);
|
|
56
|
+
font-size: var(--font-h2);
|
|
57
|
+
`;
|
|
44
58
|
var _default = exports.default = QRCodeBox;
|
|
@@ -6,9 +6,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.default = void 0;
|
|
7
7
|
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
8
8
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
9
|
-
var _templateObject, _templateObject2;
|
|
10
9
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
11
|
-
function _taggedTemplateLiteral(e, t) { return t || (t = e.slice(0)), Object.freeze(Object.defineProperties(e, { raw: { value: Object.freeze(t) } })); }
|
|
12
10
|
const QRCodeContainter = _ref => {
|
|
13
11
|
let {
|
|
14
12
|
src,
|
|
@@ -21,6 +19,16 @@ const QRCodeContainter = _ref => {
|
|
|
21
19
|
})
|
|
22
20
|
});
|
|
23
21
|
};
|
|
24
|
-
const Figure = _styledComponents.default.figure
|
|
25
|
-
|
|
22
|
+
const Figure = _styledComponents.default.figure`
|
|
23
|
+
height: 240px;
|
|
24
|
+
padding: var(--spacing-s);
|
|
25
|
+
text-align: center;
|
|
26
|
+
border: var(--border-width) solid var(--border-color);
|
|
27
|
+
border-radius: var(--border-radius);
|
|
28
|
+
`;
|
|
29
|
+
const Image = _styledComponents.default.img`
|
|
30
|
+
height: 100%;
|
|
31
|
+
object-fit: contain;
|
|
32
|
+
border-radius: var(--border-radius);
|
|
33
|
+
`;
|
|
26
34
|
var _default = exports.default = QRCodeContainter;
|
package/ribbon/Ribbon.js
CHANGED
|
@@ -7,11 +7,36 @@ exports.default = void 0;
|
|
|
7
7
|
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
8
8
|
var _backgroundColor = _interopRequireDefault(require("../styles/mixin/backgroundColor"));
|
|
9
9
|
var _colorOnBackground = _interopRequireDefault(require("../styles/mixin/colorOnBackground"));
|
|
10
|
-
var _templateObject, _templateObject2;
|
|
11
10
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
11
|
+
const Ribbon = _styledComponents.default.div`
|
|
12
|
+
width: 120px;
|
|
13
|
+
height: 120px;
|
|
14
|
+
position: absolute;
|
|
15
|
+
overflow: hidden;
|
|
16
|
+
top: -3px;
|
|
17
|
+
left: -3px;
|
|
18
|
+
`;
|
|
19
|
+
const RibbonContent = _styledComponents.default.span`
|
|
20
|
+
position: absolute;
|
|
21
|
+
text-transform: uppercase;
|
|
22
|
+
text-align: center;
|
|
23
|
+
display: block;
|
|
24
|
+
width: 200px;
|
|
25
|
+
transform: rotate(-45deg);
|
|
26
|
+
top: 25px;
|
|
27
|
+
right: -25px;
|
|
28
|
+
padding: 5px 0;
|
|
29
|
+
|
|
30
|
+
&::before,
|
|
31
|
+
&::after {
|
|
32
|
+
display: block;
|
|
33
|
+
content: '';
|
|
34
|
+
border: 1px solid rgba(255, 255, 255, 0.4);
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
${_backgroundColor.default}
|
|
38
|
+
${_colorOnBackground.default}
|
|
39
|
+
`;
|
|
15
40
|
var _default = exports.default = Object.assign(Ribbon, {
|
|
16
41
|
Content: RibbonContent
|
|
17
42
|
});
|
package/section/Section.js
CHANGED
|
@@ -8,78 +8,126 @@ var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
|
8
8
|
var _bgChartTriangle = _interopRequireDefault(require("../assets/images/bg-chart-triangle.png"));
|
|
9
9
|
var _bgChartCircle = _interopRequireDefault(require("../assets/images/bg-chart-circle.png"));
|
|
10
10
|
var _map = _interopRequireDefault(require("../assets/images/map.png"));
|
|
11
|
-
var _templateObject;
|
|
12
11
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
13
|
-
|
|
14
|
-
|
|
12
|
+
const Section = _styledComponents.default.div`
|
|
13
|
+
background: var(--color-background1);
|
|
14
|
+
border-radius: var(--border-radius);
|
|
15
|
+
color: var(--font-on-background);
|
|
16
|
+
padding: var(--spacing);
|
|
17
|
+
margin-bottom: var(--spacing);
|
|
18
|
+
|
|
19
|
+
${_ref => {
|
|
15
20
|
let {
|
|
16
21
|
backgroundReverse
|
|
17
22
|
} = _ref;
|
|
18
23
|
return backgroundReverse && 'background: var(--color-background2);';
|
|
19
|
-
}
|
|
24
|
+
}}
|
|
25
|
+
|
|
26
|
+
${_ref2 => {
|
|
20
27
|
let {
|
|
21
28
|
paddingS
|
|
22
29
|
} = _ref2;
|
|
23
30
|
return paddingS && 'padding: var(--spacing-s);';
|
|
24
|
-
}
|
|
31
|
+
}}
|
|
32
|
+
|
|
33
|
+
${_ref3 => {
|
|
25
34
|
let {
|
|
26
35
|
paddingXS
|
|
27
36
|
} = _ref3;
|
|
28
37
|
return paddingXS && 'padding: var(--spacing-xs);';
|
|
29
|
-
}
|
|
38
|
+
}}
|
|
39
|
+
|
|
40
|
+
${_ref4 => {
|
|
30
41
|
let {
|
|
31
42
|
noPadding
|
|
32
43
|
} = _ref4;
|
|
33
44
|
return noPadding && 'padding: 0;';
|
|
34
|
-
}
|
|
45
|
+
}}
|
|
46
|
+
|
|
47
|
+
${_ref5 => {
|
|
35
48
|
let {
|
|
36
49
|
noPaddingX
|
|
37
50
|
} = _ref5;
|
|
38
51
|
return noPaddingX && 'padding-left: 0; padding-right: 0;';
|
|
39
|
-
}
|
|
52
|
+
}}
|
|
53
|
+
|
|
54
|
+
${_ref6 => {
|
|
40
55
|
let {
|
|
41
56
|
noPaddingTop
|
|
42
57
|
} = _ref6;
|
|
43
58
|
return noPaddingTop && 'padding-top: 0;';
|
|
44
|
-
}
|
|
59
|
+
}}
|
|
60
|
+
|
|
61
|
+
${_ref7 => {
|
|
45
62
|
let {
|
|
46
63
|
noPaddingBottom
|
|
47
64
|
} = _ref7;
|
|
48
65
|
return noPaddingBottom && 'padding-bottom: 0;';
|
|
49
|
-
}
|
|
66
|
+
}}
|
|
67
|
+
|
|
68
|
+
${_ref8 => {
|
|
50
69
|
let {
|
|
51
70
|
marginBottomS
|
|
52
71
|
} = _ref8;
|
|
53
72
|
return marginBottomS && 'margin-bottom: var(--spacing-s);';
|
|
54
|
-
}
|
|
73
|
+
}}
|
|
74
|
+
|
|
75
|
+
${_ref9 => {
|
|
55
76
|
let {
|
|
56
77
|
noMarginBottom
|
|
57
78
|
} = _ref9;
|
|
58
79
|
return noMarginBottom && 'margin-bottom: 0;';
|
|
59
|
-
}
|
|
80
|
+
}}
|
|
81
|
+
|
|
82
|
+
${_ref10 => {
|
|
60
83
|
let {
|
|
61
84
|
fullHeight
|
|
62
85
|
} = _ref10;
|
|
63
86
|
return fullHeight && 'height: calc(100% - var(--spacing));';
|
|
64
|
-
}
|
|
87
|
+
}}
|
|
88
|
+
|
|
89
|
+
${_ref11 => {
|
|
65
90
|
let {
|
|
66
91
|
backgroundMarker
|
|
67
92
|
} = _ref11;
|
|
68
|
-
return backgroundMarker &&
|
|
69
|
-
|
|
93
|
+
return backgroundMarker && `
|
|
94
|
+
background: var(--color-background2);
|
|
95
|
+
background-image: url(${_bgChartCircle.default}), url(${_bgChartTriangle.default});
|
|
96
|
+
background-repeat: no-repeat;
|
|
97
|
+
background-position: left top, right bottom;
|
|
98
|
+
background-size: 337px 312px, 166px 225px;
|
|
99
|
+
`;
|
|
100
|
+
}}
|
|
101
|
+
|
|
102
|
+
${_ref12 => {
|
|
70
103
|
let {
|
|
71
104
|
backgroundMap
|
|
72
105
|
} = _ref12;
|
|
73
|
-
return backgroundMap &&
|
|
74
|
-
|
|
106
|
+
return backgroundMap && `
|
|
107
|
+
background: var(--color-background2);
|
|
108
|
+
background-image: url(${_map.default});
|
|
109
|
+
background-repeat: no-repeat;
|
|
110
|
+
background-size: cover;
|
|
111
|
+
`;
|
|
112
|
+
}}
|
|
113
|
+
|
|
114
|
+
${_ref13 => {
|
|
75
115
|
let {
|
|
76
116
|
border
|
|
77
117
|
} = _ref13;
|
|
78
118
|
return border && 'border: var(--border-width) solid var(--border-color);';
|
|
79
|
-
}
|
|
119
|
+
}}
|
|
120
|
+
|
|
121
|
+
${_ref14 => {
|
|
80
122
|
let {
|
|
81
123
|
checkboxGroup
|
|
82
124
|
} = _ref14;
|
|
83
|
-
return checkboxGroup &&
|
|
84
|
-
|
|
125
|
+
return checkboxGroup && `
|
|
126
|
+
background: transparent;
|
|
127
|
+
width: 50%;
|
|
128
|
+
margin-left: auto;
|
|
129
|
+
margin-right: auto;
|
|
130
|
+
`;
|
|
131
|
+
}}
|
|
132
|
+
`;
|
|
85
133
|
var _default = exports.default = Section;
|
package/section/SectionBody.js
CHANGED
|
@@ -7,25 +7,46 @@ exports.default = void 0;
|
|
|
7
7
|
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
8
8
|
var _scrollbar = _interopRequireDefault(require("../styles/mixin/scrollbar"));
|
|
9
9
|
var _media = _interopRequireDefault(require("../styles/mixin/media"));
|
|
10
|
-
var _templateObject, _templateObject2, _templateObject3, _templateObject4;
|
|
11
10
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
12
11
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
13
12
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
const SectionBody = _styledComponents.default.div`
|
|
14
|
+
// fix: overflow element(relate to z-index problem)
|
|
15
|
+
// position: relative;
|
|
16
|
+
background: transparent;
|
|
17
|
+
padding: var(--spacing) 0 0 0;
|
|
18
|
+
|
|
19
|
+
${_ref => {
|
|
16
20
|
let {
|
|
17
21
|
noPadding
|
|
18
22
|
} = _ref;
|
|
19
23
|
return noPadding && 'padding: 0;';
|
|
20
|
-
}
|
|
24
|
+
}}
|
|
25
|
+
|
|
26
|
+
${_ref2 => {
|
|
21
27
|
let {
|
|
22
28
|
maxHeight
|
|
23
29
|
} = _ref2;
|
|
24
|
-
return maxHeight && (0, _styledComponents.css)
|
|
25
|
-
|
|
30
|
+
return maxHeight && (0, _styledComponents.css)`
|
|
31
|
+
max-height: ${maxHeight}px;
|
|
32
|
+
overflow-y: auto;
|
|
33
|
+
overflow-x: hidden;
|
|
34
|
+
${_scrollbar.default}
|
|
35
|
+
`;
|
|
36
|
+
}}
|
|
37
|
+
|
|
38
|
+
${_ref3 => {
|
|
26
39
|
let {
|
|
27
40
|
maxHeightLaptop
|
|
28
41
|
} = _ref3;
|
|
29
|
-
return maxHeightLaptop && (0, _styledComponents.css)
|
|
30
|
-
|
|
42
|
+
return maxHeightLaptop && (0, _styledComponents.css)`
|
|
43
|
+
${_media.default.laptop`
|
|
44
|
+
max-height: ${maxHeightLaptop}px;
|
|
45
|
+
overflow-y: auto;
|
|
46
|
+
overflow-x: hidden;
|
|
47
|
+
${_scrollbar.default}
|
|
48
|
+
`}
|
|
49
|
+
`;
|
|
50
|
+
}}
|
|
51
|
+
`;
|
|
31
52
|
var _default = exports.default = SectionBody;
|