oa-componentbook 0.17.63 → 0.17.64
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/components/oa-component-accordion/Accordion.js +16 -9
- package/build/components/oa-component-accordion/styles.js +1 -1
- package/build/components/oa-component-drawer/styles.js +1 -1
- package/build/components/oa-component-input/CustomInput.js +69 -0
- package/build/components/oa-component-modal/CustomModal.js +15 -8
- package/build/components/oa-component-notification/CustomNotification.js +3 -3
- package/build/components/oa-component-notification/styles.js +1 -1
- package/build/components/oa-component-radio/CustomRadio.js +33 -14
- package/build/components/oa-component-radio/styles.js +4 -6
- package/build/components/oa-component-select/CustomSelect.js +129 -0
- package/build/components/oa-component-table/CustomTable.js +32 -18
- package/build/components/oa-component-tabs/styles.js +1 -1
- package/build/components/oa-component-timeline/styles.js +1 -1
- package/build/images/CautionSvg.js +20 -0
- package/build/images/DeleteSvg.js +37 -0
- package/build/index.js +23 -4
- package/build/widgets/oa-widget-close-claim/CloseClaimWidget.js +19 -21
- package/build/widgets/oa-widget-close-claim/styles.js +1 -1
- package/build/widgets/oa-widget-notes/NotesWidget.js +3 -5
- package/build/widgets/oa-widget-notes/styles.js +1 -1
- package/build/widgets/oa-widget-upload-download/UploadDownloadWidget.js +2 -5
- package/build/widgets/oa-widget-upload-download/styles.js +1 -1
- package/build/widgets/oa-widget-view-history/ViewHistoryWidget.js +6 -4
- package/build/widgets/oa-widget-view-history/styles.js +4 -6
- package/package.json +1 -1
- /package/build/components/{oa-component-spacingScales → oa-component-demo-spacing}/SpacingScales.js +0 -0
- /package/build/components/{oa-component-spacingScales → oa-component-demo-spacing}/styles.js +0 -0
|
@@ -15,16 +15,20 @@ function Accordion(_ref) {
|
|
|
15
15
|
'data-test': dataTest,
|
|
16
16
|
disabled,
|
|
17
17
|
headerText,
|
|
18
|
-
smallText
|
|
18
|
+
smallText,
|
|
19
|
+
hasContentPadding // New prop to determine whether to apply contentPadding
|
|
19
20
|
} = _ref;
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
}
|
|
21
|
+
const themeConfig = {
|
|
22
|
+
components: {
|
|
23
|
+
Collapse: {
|
|
24
|
+
headerBg: 'var(--color-secondary-background)',
|
|
25
|
+
contentPadding: hasContentPadding ? '20px 24px' : '0' // Adjust the value as needed
|
|
26
26
|
}
|
|
27
27
|
}
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
return /*#__PURE__*/_react.default.createElement(_antd.ConfigProvider, {
|
|
31
|
+
theme: themeConfig
|
|
28
32
|
}, /*#__PURE__*/_react.default.createElement(_styles.CollapseStyle, null, /*#__PURE__*/_react.default.createElement(_antd.Collapse, {
|
|
29
33
|
expandIconPosition: "end",
|
|
30
34
|
defaultActiveKey: disabled ? '-1' : '1'
|
|
@@ -45,13 +49,16 @@ Accordion.propTypes = {
|
|
|
45
49
|
'data-test': _propTypes.default.string,
|
|
46
50
|
disabled: _propTypes.default.bool,
|
|
47
51
|
headerText: _propTypes.default.string.isRequired,
|
|
48
|
-
smallText: _propTypes.default.string
|
|
52
|
+
smallText: _propTypes.default.string,
|
|
53
|
+
hasContentPadding: _propTypes.default.bool // New prop for controlling contentPadding
|
|
49
54
|
};
|
|
55
|
+
|
|
50
56
|
Accordion.defaultProps = {
|
|
51
57
|
body: '',
|
|
52
58
|
'data-test': null,
|
|
53
59
|
disabled: false,
|
|
54
|
-
smallText: ''
|
|
60
|
+
smallText: '',
|
|
61
|
+
hasContentPadding: true // Default value for contentPadding
|
|
55
62
|
};
|
|
56
63
|
var _default = Accordion;
|
|
57
64
|
exports.default = _default;
|
|
@@ -12,5 +12,5 @@ var _default = {};
|
|
|
12
12
|
exports.default = _default;
|
|
13
13
|
const SmallText = _styledComponents.default.small(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n font-size: 18px;\n color: #E21616;\n margin: 0 0 0 4px;\n"])));
|
|
14
14
|
exports.SmallText = SmallText;
|
|
15
|
-
const CollapseStyle = _styledComponents.default.div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n.ant-collapse .ant-collapse-item-disabled{\n background: var(--color-disabled-button);\n}\n .ant-collapse-item-active .ant-collapse-expand-icon{\n transform: rotate(180deg);\n }\n .ant-collapse-expand-icon{\n transform: rotate(90deg);\n padding-inline-start: 0 !important;\n }\n .ant-collapse-header-text{\n color: var(--color-primary-content);\n }\n .ant-collapse-arrow{\n color: var(--color-secondary-content) !important;\n }\n .ant-collapse>.ant-collapse-item:last-child,.ant-collapse>.ant-collapse-item:last-child>.ant-collapse-header,.ant-collapse .ant-collapse-item:last-child >.ant-collapse-content {\n border-radius: 0 0 4px 4px;\n }\n .ant-collapse>.ant-collapse-item {\n border: none;\n }\n .ant-collapse{\n border: 1px solid var(--color-divider);\n border-radius: 4px;\n }\n
|
|
15
|
+
const CollapseStyle = _styledComponents.default.div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n.ant-collapse .ant-collapse-item-disabled{\n background: var(--color-disabled-button);\n}\n .ant-collapse-item-active .ant-collapse-expand-icon{\n transform: rotate(180deg);\n }\n .ant-collapse-expand-icon{\n transform: rotate(90deg);\n padding-inline-start: 0 !important;\n }\n .ant-collapse-header-text{\n color: var(--color-primary-content);\n }\n .ant-collapse-arrow{\n color: var(--color-secondary-content) !important;\n }\n .ant-collapse>.ant-collapse-item:last-child,.ant-collapse>.ant-collapse-item:last-child>.ant-collapse-header,.ant-collapse .ant-collapse-item:last-child >.ant-collapse-content {\n border-radius: 0 0 4px 4px;\n }\n .ant-collapse>.ant-collapse-item {\n border: none;\n }\n .ant-collapse{\n border: 1px solid var(--color-divider);\n border-radius: 4px;\n }\n \n .ant-collapse>.ant-collapse-item >.ant-collapse-header{\n padding: 12px 24px;\n }\n"])));
|
|
16
16
|
exports.CollapseStyle = CollapseStyle;
|
|
@@ -11,7 +11,7 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
11
11
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
12
12
|
const DrawerFooter = _styledComponents.default.aside(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: flex;\n justify-content: flex-end;\n gap: 12px;\n"])));
|
|
13
13
|
exports.DrawerFooter = DrawerFooter;
|
|
14
|
-
const CustomStyledDrawer = (0, _styledComponents.default)(_antd.Drawer)(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n .ant-drawer-header {\n padding:
|
|
14
|
+
const CustomStyledDrawer = (0, _styledComponents.default)(_antd.Drawer)(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n .ant-drawer-header {\n padding: 16px 24px;\n background: var(--color-secondary-background);\n }\n"])));
|
|
15
15
|
exports.CustomStyledDrawer = CustomStyledDrawer;
|
|
16
16
|
const BaseDrawerTitle = _styledComponents.default.div(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n display: flex;\n justify-content: space-between;\n"])));
|
|
17
17
|
exports.BaseDrawerTitle = BaseDrawerTitle;
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
require("core-js/modules/es.object.assign.js");
|
|
4
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5
|
+
value: true
|
|
6
|
+
});
|
|
7
|
+
exports.default = CustomInput;
|
|
8
|
+
var _react = _interopRequireDefault(require("react"));
|
|
9
|
+
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
10
|
+
var _antd = require("antd");
|
|
11
|
+
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
12
|
+
var _Typography = _interopRequireDefault(require("../oa-component-typography/Typography"));
|
|
13
|
+
var _ColorVariablesMap = _interopRequireDefault(require("../../global-css/ColorVariablesMap"));
|
|
14
|
+
require("antd/dist/reset.css");
|
|
15
|
+
const _excluded = ["data-test", "disabled"];
|
|
16
|
+
var _templateObject;
|
|
17
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
18
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
19
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
20
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
21
|
+
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
22
|
+
const StyledInput = (0, _styledComponents.default)(_antd.Input)(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n .ant-input {\n display: flex;\n align-items: center;\n }\n"])));
|
|
23
|
+
function CustomInput(_ref) {
|
|
24
|
+
let {
|
|
25
|
+
'data-test': dataTest,
|
|
26
|
+
disabled: inputDisabled
|
|
27
|
+
} = _ref,
|
|
28
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
29
|
+
return /*#__PURE__*/_react.default.createElement(_antd.ConfigProvider, {
|
|
30
|
+
theme: {
|
|
31
|
+
components: {
|
|
32
|
+
Input: {
|
|
33
|
+
borderColor: inputDisabled ? _ColorVariablesMap.default['--color-divider'] : _ColorVariablesMap.default['--color-placeholder-text'],
|
|
34
|
+
borderRadius: '4px',
|
|
35
|
+
height: (props === null || props === void 0 ? void 0 : props.size) === 'small' ? '36px' : '52px',
|
|
36
|
+
padding: (props === null || props === void 0 ? void 0 : props.size) === 'small' ? '8px 12px' : '16px 16px'
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
token: {
|
|
40
|
+
colorTextPlaceholder: _ColorVariablesMap.default['--color-placeholder-text'],
|
|
41
|
+
lineHeight: '20px',
|
|
42
|
+
colorPrimary: _ColorVariablesMap.default['--color-primary'],
|
|
43
|
+
colorPrimaryHover: _ColorVariablesMap.default['--color-primary'],
|
|
44
|
+
borderRadius: '4px',
|
|
45
|
+
controlHeight: 48,
|
|
46
|
+
controlHeightSM: 32,
|
|
47
|
+
controlItemBgHover: _ColorVariablesMap.default['--color-background-info'],
|
|
48
|
+
colorBgElevated: _ColorVariablesMap.default['--color-primary-background'],
|
|
49
|
+
colorBorder: _ColorVariablesMap.default['--color-placeholder-text'],
|
|
50
|
+
colorFillSecondary: _ColorVariablesMap.default['--color-secondary-background'],
|
|
51
|
+
colorText: _ColorVariablesMap.default['--color-primary-content'],
|
|
52
|
+
colorIcon: _ColorVariablesMap.default['--color-primary-content']
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}, /*#__PURE__*/_react.default.createElement(StyledInput, _extends({
|
|
56
|
+
"data-test": dataTest ? "".concat(dataTest, "-input") : undefined,
|
|
57
|
+
disabled: inputDisabled
|
|
58
|
+
}, props)));
|
|
59
|
+
}
|
|
60
|
+
CustomInput.propTypes = {
|
|
61
|
+
'data-test': _propTypes.default.string,
|
|
62
|
+
disabled: _propTypes.default.bool,
|
|
63
|
+
size: _propTypes.default.oneOf(['small', 'middle'])
|
|
64
|
+
};
|
|
65
|
+
CustomInput.defaultProps = {
|
|
66
|
+
'data-test': null,
|
|
67
|
+
disabled: false,
|
|
68
|
+
size: 'middle'
|
|
69
|
+
};
|
|
@@ -23,6 +23,7 @@ function CustomModal(_ref) {
|
|
|
23
23
|
let {
|
|
24
24
|
buttonConfig,
|
|
25
25
|
children,
|
|
26
|
+
'data-test': dataTest,
|
|
26
27
|
imgSrc,
|
|
27
28
|
// This callback function provided by parent is called upon clicking on the cancel button
|
|
28
29
|
onCancel,
|
|
@@ -43,13 +44,8 @@ function CustomModal(_ref) {
|
|
|
43
44
|
};
|
|
44
45
|
|
|
45
46
|
return /*#__PURE__*/_react.default.createElement(_antd.Modal, {
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
src: imgSrc,
|
|
49
|
-
alt: ""
|
|
50
|
-
}), /*#__PURE__*/_react.default.isValidElement(title) && /*#__PURE__*/_react.default.createElement(_Typography.default, {
|
|
51
|
-
typography: typographies.title
|
|
52
|
-
}, title)),
|
|
47
|
+
centered: true,
|
|
48
|
+
"data-test": dataTest,
|
|
53
49
|
footer: (buttonConfig === null || buttonConfig === void 0 ? void 0 : buttonConfig.length) > 0 && /*#__PURE__*/_react.default.createElement(_styles.ButtonContainer, null, buttonConfig === null || buttonConfig === void 0 ? void 0 : buttonConfig.map(button => /*#__PURE__*/_react.default.createElement(_CustomButton.default, _extends({
|
|
54
50
|
key: (0, _nanoid.nanoid)()
|
|
55
51
|
}, button, {
|
|
@@ -57,9 +53,17 @@ function CustomModal(_ref) {
|
|
|
57
53
|
label: button.label,
|
|
58
54
|
onClick: button.callback,
|
|
59
55
|
size: "large",
|
|
60
|
-
type: button.type
|
|
56
|
+
type: button.type,
|
|
57
|
+
"data-test": button['data-test']
|
|
61
58
|
})))),
|
|
59
|
+
onCancel: handleCancel,
|
|
62
60
|
open: open,
|
|
61
|
+
title: (title || imgSrc) && /*#__PURE__*/_react.default.createElement(_styles.TitleContainer, null, imgSrc && /*#__PURE__*/_react.default.createElement("img", {
|
|
62
|
+
src: imgSrc,
|
|
63
|
+
alt: ""
|
|
64
|
+
}), /*#__PURE__*/_react.default.isValidElement(title) && /*#__PURE__*/_react.default.createElement(_Typography.default, {
|
|
65
|
+
typography: typographies.title
|
|
66
|
+
}, title)),
|
|
63
67
|
width: width
|
|
64
68
|
}, children && /*#__PURE__*/_react.default.createElement(_styles.DescriptionContainer, null,
|
|
65
69
|
// The label is a string or a number
|
|
@@ -72,6 +76,7 @@ CustomModal.propTypes = {
|
|
|
72
76
|
// Array of button configurations
|
|
73
77
|
buttonConfig: _propTypes.default.arrayOf(_propTypes.default.shape({
|
|
74
78
|
callback: _propTypes.default.func.isRequired,
|
|
79
|
+
'data-test': _propTypes.default.string,
|
|
75
80
|
label: _propTypes.default.string,
|
|
76
81
|
iconConfig: _propTypes.default.shape({
|
|
77
82
|
icon: _propTypes.default.node,
|
|
@@ -81,6 +86,7 @@ CustomModal.propTypes = {
|
|
|
81
86
|
type: _propTypes.default.oneOf(['primary', 'secondary', 'text-only', 'danger-primary', 'danger-secondary', 'danger-text-only']).isRequired
|
|
82
87
|
})),
|
|
83
88
|
children: _propTypes.default.node,
|
|
89
|
+
'data-test': _propTypes.default.string,
|
|
84
90
|
title: _propTypes.default.string,
|
|
85
91
|
typographies: _propTypes.default.shape({
|
|
86
92
|
title: _propTypes.default.oneOf(_Typography.typographyOptions),
|
|
@@ -94,6 +100,7 @@ CustomModal.propTypes = {
|
|
|
94
100
|
CustomModal.defaultProps = {
|
|
95
101
|
buttonConfig: [],
|
|
96
102
|
children: null,
|
|
103
|
+
'data-test': null,
|
|
97
104
|
imgSrc: null,
|
|
98
105
|
open: true,
|
|
99
106
|
title: null,
|
|
@@ -62,11 +62,11 @@ const Notification = /*#__PURE__*/(0, _react.forwardRef)((_ref, ref) => {
|
|
|
62
62
|
}, /*#__PURE__*/_react.default.createElement("div", null, title)), /*#__PURE__*/_react.default.createElement(_Typography.default, {
|
|
63
63
|
color: descriptionColor,
|
|
64
64
|
typography: typographies.description
|
|
65
|
-
}, description)));
|
|
65
|
+
}, /*#__PURE__*/_react.default.createElement("small", null, description))));
|
|
66
66
|
api.open({
|
|
67
67
|
message: customNotification,
|
|
68
68
|
style: {
|
|
69
|
-
padding: '8px 16px
|
|
69
|
+
padding: '8px 16px 0px 16px',
|
|
70
70
|
borderRadius: '4px',
|
|
71
71
|
borderLeft: "4px solid ".concat(borderColor),
|
|
72
72
|
boxShadow: '0px 2px 8px 0px rgba(0, 0, 0, 0.12)'
|
|
@@ -110,7 +110,7 @@ Notification.propTypes = {
|
|
|
110
110
|
})
|
|
111
111
|
};
|
|
112
112
|
Notification.defaultProps = {
|
|
113
|
-
duration:
|
|
113
|
+
duration: null,
|
|
114
114
|
onClick: () => {},
|
|
115
115
|
onClose: () => {},
|
|
116
116
|
placement: 'topRight',
|
|
@@ -10,5 +10,5 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
10
10
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
11
11
|
var _default = {};
|
|
12
12
|
exports.default = _default;
|
|
13
|
-
const StyledNotification = _styledComponents.default.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: flex;\n justify-content: space-between; \n"])));
|
|
13
|
+
const StyledNotification = _styledComponents.default.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: flex;\n justify-content: space-between; \n align-item: center;\n small{\n font-size: inherit;\n display: block;\n padding: 4px 0 0;\n }\n .anticon-close{\n color: var(--color-secondary-content);\n }\n \n"])));
|
|
14
14
|
exports.StyledNotification = StyledNotification;
|
|
@@ -4,18 +4,36 @@ require("core-js/modules/es.object.assign.js");
|
|
|
4
4
|
Object.defineProperty(exports, "__esModule", {
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
7
|
-
exports.default = void 0;
|
|
7
|
+
exports.getRadioTheme = exports.default = void 0;
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
|
9
9
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
10
10
|
var _antd = require("antd");
|
|
11
|
-
var _Typography = _interopRequireDefault(require("../oa-component-typography/Typography"));
|
|
12
11
|
var _utils = require("../../utils");
|
|
13
|
-
var
|
|
12
|
+
var _ColorVariablesMap = _interopRequireDefault(require("../../global-css/ColorVariablesMap"));
|
|
14
13
|
const _excluded = ["label", "data-test", "disabled", "onChange", "size", "value"];
|
|
15
14
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
16
15
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
17
16
|
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
18
17
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
18
|
+
const getRadioTheme = () => ({
|
|
19
|
+
token: {
|
|
20
|
+
colorPrimary: _ColorVariablesMap.default['--color-primary'],
|
|
21
|
+
// color-primary
|
|
22
|
+
// colorPrimaryHover: 'orange',
|
|
23
|
+
// colorPrimaryActive: 'red',
|
|
24
|
+
// colorPrimaryBorder: 'green',
|
|
25
|
+
colorTextDisabled: _ColorVariablesMap.default['--color-disabled-button'],
|
|
26
|
+
// color-disabled-button
|
|
27
|
+
colorText: _ColorVariablesMap.default['--color-primary-content'] // color-primary-content
|
|
28
|
+
},
|
|
29
|
+
|
|
30
|
+
components: {
|
|
31
|
+
Radio: {
|
|
32
|
+
wrapperMarginInlineEnd: 12
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
});
|
|
36
|
+
exports.getRadioTheme = getRadioTheme;
|
|
19
37
|
function CustomRadio(_ref) {
|
|
20
38
|
let {
|
|
21
39
|
label,
|
|
@@ -36,26 +54,27 @@ function CustomRadio(_ref) {
|
|
|
36
54
|
onChange(event);
|
|
37
55
|
};
|
|
38
56
|
return /*#__PURE__*/_react.default.createElement(_antd.ConfigProvider, {
|
|
39
|
-
theme:
|
|
40
|
-
|
|
41
|
-
Radio: {
|
|
42
|
-
dotSize: '8'
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
|
-
}, /*#__PURE__*/_react.default.createElement(_styles.RadioContainer, null, /*#__PURE__*/_react.default.createElement(_styles.StyledRadio, _extends({
|
|
57
|
+
theme: getRadioTheme()
|
|
58
|
+
}, /*#__PURE__*/_react.default.createElement(_antd.Radio, _extends({
|
|
47
59
|
disabled: disabled,
|
|
48
60
|
onChange: handleChange,
|
|
49
61
|
value: value,
|
|
50
62
|
"data-test": dataTest
|
|
51
63
|
}, antDesignProps), ((0, _utils.isString)(label) || (0, _utils.isNumber)(label)) && /*#__PURE__*/_react.default.createElement("p", {
|
|
52
64
|
className: size === 'large' ? 'type-b1-400' : 'type-b2-400',
|
|
53
|
-
|
|
54
|
-
|
|
65
|
+
style: {
|
|
66
|
+
// paddingLeft: '12px'
|
|
67
|
+
}
|
|
68
|
+
}, label) || /*#__PURE__*/_react.default.isValidElement(label) && label || undefined));
|
|
69
|
+
}
|
|
70
|
+
function CustomRadioGroup(props) {
|
|
71
|
+
return /*#__PURE__*/_react.default.createElement(_antd.ConfigProvider, {
|
|
72
|
+
theme: getRadioTheme()
|
|
73
|
+
}, /*#__PURE__*/_react.default.createElement(_antd.Radio.Group, props));
|
|
55
74
|
}
|
|
56
75
|
|
|
57
76
|
// This allows us referencing the Group container and Button component in our Checkbox component
|
|
58
|
-
CustomRadio.Group =
|
|
77
|
+
CustomRadio.Group = CustomRadioGroup;
|
|
59
78
|
CustomRadio.Button = CustomRadio;
|
|
60
79
|
CustomRadio.propTypes = {
|
|
61
80
|
'data-test': _propTypes.default.string,
|
|
@@ -3,15 +3,13 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.default = exports.
|
|
6
|
+
exports.default = exports.RadioContainer = void 0;
|
|
7
7
|
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
8
8
|
var _antd = require("antd");
|
|
9
|
-
var _templateObject
|
|
9
|
+
var _templateObject;
|
|
10
10
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
11
11
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
12
12
|
var _default = {};
|
|
13
13
|
exports.default = _default;
|
|
14
|
-
const RadioContainer = _styledComponents.default.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n
|
|
15
|
-
exports.RadioContainer = RadioContainer;
|
|
16
|
-
const StyledRadio = (0, _styledComponents.default)(_antd.Radio)(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n p{\n color: var(--color-primary-content);\n }\n .ant-radio-checked .ant-radio-inner {\n background: var(--color-primary-background);\n border:1px solid var(--color-primary);\n }\n\n .ant-radio-inner::after {\n background: var(--color-primary);\n }\n\n .ant-radio-inner:hover {\n color: var(--color-primary);\n } \n \n .ant-radio-inner {\n border-color: var(--color-secondary-content);\n }\n"])));
|
|
17
|
-
exports.StyledRadio = StyledRadio;
|
|
14
|
+
const RadioContainer = _styledComponents.default.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n/* .ant-radio-wrapper span.ant-radio+*{\n padding-inline-start: 12px;\n} */\n"])));
|
|
15
|
+
exports.RadioContainer = RadioContainer;
|
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
require("core-js/modules/es.symbol.description.js");
|
|
4
|
+
require("core-js/modules/es.object.assign.js");
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports.default = CustomSelect;
|
|
9
|
+
var _react = _interopRequireDefault(require("react"));
|
|
10
|
+
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
11
|
+
var _antd = require("antd");
|
|
12
|
+
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
13
|
+
var _utils = require("../../utils");
|
|
14
|
+
var _Typography = _interopRequireDefault(require("../oa-component-typography/Typography"));
|
|
15
|
+
var _ColorVariablesMap = _interopRequireDefault(require("../../global-css/ColorVariablesMap"));
|
|
16
|
+
require("antd/dist/reset.css");
|
|
17
|
+
const _excluded = ["data-test", "disabled", "options"],
|
|
18
|
+
_excluded2 = ["label", "disabled"];
|
|
19
|
+
var _templateObject;
|
|
20
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
21
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
22
|
+
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; }
|
|
23
|
+
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; }
|
|
24
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
25
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
|
|
26
|
+
function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
27
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
28
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
29
|
+
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
30
|
+
const StyledSelect = (0, _styledComponents.default)(_antd.Select)(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n .ant-select-selection-item {\n display: flex;\n align-items: center;\n }\n"])));
|
|
31
|
+
function CustomSelect(_ref) {
|
|
32
|
+
let {
|
|
33
|
+
'data-test': dataTest,
|
|
34
|
+
disabled: selectDisabled,
|
|
35
|
+
options
|
|
36
|
+
} = _ref,
|
|
37
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
38
|
+
const actualOptions = options.map(option => {
|
|
39
|
+
const {
|
|
40
|
+
label,
|
|
41
|
+
disabled
|
|
42
|
+
} = option,
|
|
43
|
+
otherProperties = _objectWithoutProperties(option, _excluded2);
|
|
44
|
+
if ((0, _utils.isString)(label) || (0, _utils.isNumber)(label)) {
|
|
45
|
+
return _objectSpread({
|
|
46
|
+
label: /*#__PURE__*/_react.default.createElement(_Typography.default, {
|
|
47
|
+
color: disabled || selectDisabled ? 'placeholder-text' : undefined,
|
|
48
|
+
typography: "type-b2-400",
|
|
49
|
+
"data-test": dataTest ? "".concat(dataTest, "-(").concat(label, ")") : undefined
|
|
50
|
+
}, label),
|
|
51
|
+
disabled
|
|
52
|
+
}, otherProperties);
|
|
53
|
+
}
|
|
54
|
+
if ( /*#__PURE__*/_react.default.isValidElement(label)) {
|
|
55
|
+
return _objectSpread({
|
|
56
|
+
label: /*#__PURE__*/_react.default.cloneElement(label, {
|
|
57
|
+
'data-test': dataTest ? "".concat(dataTest, "-(").concat(label, ")") : undefined
|
|
58
|
+
}),
|
|
59
|
+
disabled
|
|
60
|
+
}, otherProperties);
|
|
61
|
+
}
|
|
62
|
+
return option;
|
|
63
|
+
});
|
|
64
|
+
return /*#__PURE__*/_react.default.createElement(_antd.ConfigProvider, {
|
|
65
|
+
theme: {
|
|
66
|
+
components: {
|
|
67
|
+
Select: {
|
|
68
|
+
optionHeight: (props === null || props === void 0 ? void 0 : props.size) === 'small' ? '36px' : '52px',
|
|
69
|
+
optionSelectedBg: _ColorVariablesMap.default['--color-primary-background'],
|
|
70
|
+
optionSelectedColor: _ColorVariablesMap.default['--color-primary'],
|
|
71
|
+
optionPadding: (props === null || props === void 0 ? void 0 : props.size) === 'small' ? '8px 12px' : '16px 16px'
|
|
72
|
+
}
|
|
73
|
+
},
|
|
74
|
+
token: {
|
|
75
|
+
colorTextPlaceholder: _ColorVariablesMap.default['--color-placeholder-text'],
|
|
76
|
+
lineHeight: '20px',
|
|
77
|
+
// Same as type-b2-400
|
|
78
|
+
colorPrimary: _ColorVariablesMap.default['--color-primary'],
|
|
79
|
+
// for active color of select
|
|
80
|
+
colorPrimaryHover: _ColorVariablesMap.default['--color-primary'],
|
|
81
|
+
// for hover color of select
|
|
82
|
+
borderRadius: '4px',
|
|
83
|
+
// For border radius of select text field.
|
|
84
|
+
borderRadiusLG: '4px',
|
|
85
|
+
// For border radius of dropdown
|
|
86
|
+
controlHeight: 48,
|
|
87
|
+
// height of text field (tag height is half of this, i.e. 24px)
|
|
88
|
+
controlHeightSM: 32,
|
|
89
|
+
// height of small text field
|
|
90
|
+
controlItemBgHover: _ColorVariablesMap.default['--color-background-info'],
|
|
91
|
+
// hover color of items
|
|
92
|
+
colorBgElevated: _ColorVariablesMap.default['--color-primary-background'],
|
|
93
|
+
// multipleItemHeight: 100,
|
|
94
|
+
colorBgContainerDisabled: _ColorVariablesMap.default['--color-divider'],
|
|
95
|
+
// background color of disabled select
|
|
96
|
+
colorBorder: _ColorVariablesMap.default['--color-placeholder-text'],
|
|
97
|
+
colorFillSecondary: _ColorVariablesMap.default['--color-secondary-background'],
|
|
98
|
+
// background color for tags
|
|
99
|
+
colorText: _ColorVariablesMap.default['--color-primary-content'],
|
|
100
|
+
// Text color of unselected options in dropdown
|
|
101
|
+
colorIcon: _ColorVariablesMap.default['--color-primary-content'] // Color of cross icon
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
}, /*#__PURE__*/_react.default.createElement(StyledSelect, _extends({
|
|
105
|
+
"data-test": dataTest ? "".concat(dataTest, "-select") : undefined,
|
|
106
|
+
options: actualOptions,
|
|
107
|
+
dropdownStyle: {
|
|
108
|
+
padding: '0px'
|
|
109
|
+
},
|
|
110
|
+
maxTagCount: "responsive",
|
|
111
|
+
disabled: selectDisabled
|
|
112
|
+
}, props)));
|
|
113
|
+
}
|
|
114
|
+
CustomSelect.propTypes = {
|
|
115
|
+
'data-test': _propTypes.default.string,
|
|
116
|
+
disabled: _propTypes.default.bool,
|
|
117
|
+
size: _propTypes.default.oneOf(['small', 'middle']),
|
|
118
|
+
options: _propTypes.default.arrayOf(
|
|
119
|
+
// Checked from antd's github
|
|
120
|
+
_propTypes.default.shape({
|
|
121
|
+
label: _propTypes.default.node.isRequired,
|
|
122
|
+
value: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number]).isRequired
|
|
123
|
+
})).isRequired
|
|
124
|
+
};
|
|
125
|
+
CustomSelect.defaultProps = {
|
|
126
|
+
'data-test': null,
|
|
127
|
+
disabled: false,
|
|
128
|
+
size: 'middle'
|
|
129
|
+
};
|
|
@@ -13,7 +13,7 @@ var _Typography = _interopRequireDefault(require("../oa-component-typography/Typ
|
|
|
13
13
|
require("antd/dist/reset.css");
|
|
14
14
|
var _ColorVariablesMap = _interopRequireDefault(require("../../global-css/ColorVariablesMap"));
|
|
15
15
|
var _utils = require("../../utils");
|
|
16
|
-
const _excluded = ["columns", "dataSource", "pagination", "rowKey", "size"],
|
|
16
|
+
const _excluded = ["columns", "dataSource", "pagination", "rowKey", "size", "tableBorder"],
|
|
17
17
|
_excluded2 = ["title"];
|
|
18
18
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
19
19
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
@@ -30,7 +30,8 @@ function CustomTable(_ref) {
|
|
|
30
30
|
dataSource,
|
|
31
31
|
pagination,
|
|
32
32
|
rowKey,
|
|
33
|
-
size
|
|
33
|
+
size,
|
|
34
|
+
tableBorder
|
|
34
35
|
} = _ref,
|
|
35
36
|
antDesignProps = _objectWithoutProperties(_ref, _excluded);
|
|
36
37
|
const uppercaseColumns = columns.map(column => {
|
|
@@ -38,15 +39,28 @@ function CustomTable(_ref) {
|
|
|
38
39
|
title
|
|
39
40
|
} = column,
|
|
40
41
|
otherColumnProperties = _objectWithoutProperties(column, _excluded2);
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
42
|
+
const titleComponent = (0, _utils.isString)(title) || (0, _utils.isNumber)(title) ? /*#__PURE__*/_react.default.createElement(_Typography.default, {
|
|
43
|
+
typography: "type-sl1-700"
|
|
44
|
+
}, title) : title;
|
|
45
|
+
return _objectSpread({
|
|
46
|
+
title: titleComponent,
|
|
47
|
+
render: text => {
|
|
48
|
+
if ((0, _utils.isString)(text) || (0, _utils.isNumber)(text)) {
|
|
49
|
+
return /*#__PURE__*/_react.default.createElement(_Typography.default, {
|
|
50
|
+
typography: "type-b2-400"
|
|
51
|
+
}, text);
|
|
52
|
+
}
|
|
53
|
+
return text;
|
|
54
|
+
}
|
|
55
|
+
}, otherColumnProperties);
|
|
49
56
|
});
|
|
57
|
+
const tableStyle = {
|
|
58
|
+
borderTop: '1px solid var(--color-divider)',
|
|
59
|
+
borderRight: tableBorder ? '1px solid var(--color-divider)' : '0',
|
|
60
|
+
borderBottom: tableBorder ? '1px solid var(--color-divider)' : '0',
|
|
61
|
+
borderLeft: tableBorder ? '1px solid var(--color-divider)' : '0',
|
|
62
|
+
borderRadius: tableBorder ? '4px' : '0'
|
|
63
|
+
};
|
|
50
64
|
return /*#__PURE__*/_react.default.createElement(_antd.ConfigProvider, {
|
|
51
65
|
theme: {
|
|
52
66
|
components: {
|
|
@@ -54,6 +68,7 @@ function CustomTable(_ref) {
|
|
|
54
68
|
borderColor: _ColorVariablesMap.default['--color-divider'],
|
|
55
69
|
headerColor: _ColorVariablesMap.default['--color-secondary-content'],
|
|
56
70
|
headerBg: _ColorVariablesMap.default['--color-secondary-background'],
|
|
71
|
+
rowHoverBg: _ColorVariablesMap.default['--color-secondary-background'],
|
|
57
72
|
headerBorderRadius: '0',
|
|
58
73
|
headerSplitColor: _ColorVariablesMap.default['--color-secondary-background'],
|
|
59
74
|
footerColor: _ColorVariablesMap.default['--color-primary-content'],
|
|
@@ -66,21 +81,18 @@ function CustomTable(_ref) {
|
|
|
66
81
|
cellFontSize: '14px',
|
|
67
82
|
cellFontSizeMD: '14px',
|
|
68
83
|
cellFontSizeSM: '14px',
|
|
69
|
-
selectionColumnWidth: '54px'
|
|
84
|
+
selectionColumnWidth: '54px',
|
|
85
|
+
colorText: _ColorVariablesMap.default['--color-primary-content']
|
|
70
86
|
}
|
|
71
87
|
}
|
|
72
88
|
}
|
|
73
89
|
}, /*#__PURE__*/_react.default.createElement(_antd.Table, _extends({
|
|
74
|
-
style:
|
|
75
|
-
border: '1px solid var(--color-divider)',
|
|
76
|
-
borderRadius: '4px'
|
|
77
|
-
},
|
|
90
|
+
style: tableStyle,
|
|
78
91
|
columns: uppercaseColumns,
|
|
79
92
|
dataSource: dataSource,
|
|
80
93
|
pagination: pagination,
|
|
81
94
|
rowKey: rowKey,
|
|
82
95
|
size: size
|
|
83
|
-
// This allows for all ant design props to be supported.
|
|
84
96
|
}, antDesignProps)));
|
|
85
97
|
}
|
|
86
98
|
CustomTable.propTypes = {
|
|
@@ -88,14 +100,16 @@ CustomTable.propTypes = {
|
|
|
88
100
|
dataSource: _propTypes.default.array,
|
|
89
101
|
pagination: _propTypes.default.oneOfType([_propTypes.default.bool, _propTypes.default.object]),
|
|
90
102
|
rowKey: _propTypes.default.string,
|
|
91
|
-
size: _propTypes.default.oneOf(['small', 'middle', 'large'])
|
|
103
|
+
size: _propTypes.default.oneOf(['small', 'middle', 'large']),
|
|
104
|
+
tableBorder: _propTypes.default.bool
|
|
92
105
|
};
|
|
93
106
|
CustomTable.defaultProps = {
|
|
94
107
|
dataSource: [],
|
|
95
108
|
columns: [],
|
|
96
109
|
pagination: false,
|
|
97
110
|
rowKey: '',
|
|
98
|
-
size: 'middle'
|
|
111
|
+
size: 'middle',
|
|
112
|
+
tableBorder: true
|
|
99
113
|
};
|
|
100
114
|
var _default = CustomTable;
|
|
101
115
|
exports.default = _default;
|
|
@@ -11,5 +11,5 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
11
11
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
12
12
|
var _default = {};
|
|
13
13
|
exports.default = _default;
|
|
14
|
-
const StyledTabs = _styledComponents.default.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n.ant-tabs .ant-tabs-tab{\n color: var(--color-secondary-content);\n }\n .ant-tabs-top >.ant-tabs-nav::before{\n border-bottom: 1px solid var(--color-divider)\n }\n .ant-tabs .ant-tabs-tab.ant-tabs-tab-active .ant-tabs-tab-btn {\n color: var(--color-primary);\n font-size: 14px;\n font-weight: 600;\n line-height: 20px;\n }\n .ant-tabs .ant-tabs-tab:hover{\n color: var(--color-primary-hover);\n }\n .ant-tabs .ant-tabs-ink-bar{\n background: var(--color-primary);\n }\n"])));
|
|
14
|
+
const StyledTabs = _styledComponents.default.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n.ant-tabs .ant-tabs-tab{\n color: var(--color-secondary-content);\n padding: 12px;\n }\n .ant-tabs .ant-tabs-tab+.ant-tabs-tab{\n margin: 0;\n }\n .ant-tabs-top >.ant-tabs-nav::before{\n border-bottom: 1px solid var(--color-divider)\n }\n .ant-tabs .ant-tabs-tab.ant-tabs-tab-active .ant-tabs-tab-btn {\n color: var(--color-primary);\n font-size: 14px;\n font-weight: 600;\n line-height: 20px;\n }\n .ant-tabs .ant-tabs-tab:hover{\n color: var(--color-primary-hover);\n }\n .ant-tabs .ant-tabs-ink-bar{\n background: var(--color-primary);\n }\n"])));
|
|
15
15
|
exports.StyledTabs = StyledTabs;
|
|
@@ -13,6 +13,6 @@ var _default = {};
|
|
|
13
13
|
exports.default = _default;
|
|
14
14
|
const StyleTimeline = _styledComponents.default.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n.ant-steps .ant-steps-item-finish>.ant-steps-item-container>.ant-steps-item-content>.ant-steps-item-title,.ant-steps .ant-steps-item-process>.ant-steps-item-container>.ant-steps-item-content>.ant-steps-item-title{\n color: var(--color-primary-content);\n font-size: 14px;\n font-weight: 400;\n line-height: 20px; \n}\n.ant-steps .ant-steps-item-wait>.ant-steps-item-container>.ant-steps-item-content>.ant-steps-item-title{\n font-size: 14px;\n font-weight: 400;\n line-height: 20px;\n}\n.ant-steps .ant-steps-item-wait>.ant-steps-item-container>.ant-steps-item-content>.ant-steps-item-title {\n color: var(--color-disabled-button);\n}\n"])));
|
|
15
15
|
exports.StyleTimeline = StyleTimeline;
|
|
16
|
-
const CustomSteps = (0, _styledComponents.default)(_antd.Steps)(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n display: block;\n position: relative;\n padding: 20px 0 56px;\n .ant-steps-item-tail{\n left:
|
|
16
|
+
const CustomSteps = (0, _styledComponents.default)(_antd.Steps)(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n display: block;\n position: relative;\n padding: 20px 0 56px;\n .ant-steps-item-tail{\n left: 6px;\n }\n .ant-steps-item-content{\n width: auto !important;\n }\n .ant-steps-item:fist-child .ant-steps-item-content{\n\n }\n .ant-steps-item-icon {\n width: 16px !important;\n height: 16px !important;\n margin-inline-end: 68px;\n }\n \n .ant-steps-item-tail {\n top: 6px !important;\n }\n \n .ant-steps-icon-dot {\n background: #00875A !important;\n }\n \n .ant-steps-item-tail::after {\n height: 2px !important;\n width: 100% !important;\n margin-inline-start: -8px !important;\n }\n \n .ant-steps-item-finish .ant-steps-item-tail::after {\n background: #00875A !important;\n }\n \n .ant-steps-item-process .ant-steps-item-tail::after {\n background-color: rgba(5, 5, 5, 0.06) !important;\n }\n \n .ant-steps-item-wait .ant-steps-icon-dot {\n background-color: rgb(240 240 240)!important;\n }\n \n .ant-steps-item-content {\n margin-top: 8px !important;\n }\n .ant-steps-item-description {\n display: none;\n }\n"])));
|
|
17
17
|
exports.CustomSteps = CustomSteps;
|
|
18
18
|
CustomSteps.Step = _antd.Steps.Step;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = CautionSvg;
|
|
7
|
+
var _react = _interopRequireDefault(require("react"));
|
|
8
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
9
|
+
function CautionSvg() {
|
|
10
|
+
return /*#__PURE__*/_react.default.createElement("svg", {
|
|
11
|
+
width: "20",
|
|
12
|
+
height: "20",
|
|
13
|
+
viewBox: "0 0 20 20",
|
|
14
|
+
fill: "none",
|
|
15
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
16
|
+
}, /*#__PURE__*/_react.default.createElement("path", {
|
|
17
|
+
d: "M11.8723 4.0809C11.6825 3.75226 11.4096 3.47936 11.0809 3.28962C10.7523 3.09989 10.3795 3 10 3C9.62051 3 9.2477 3.09989 8.91905 3.28962C8.59039 3.47936 8.31747 3.75226 8.1277 4.0809L2.2896 14.1929C2.09987 14.5216 1.99999 14.8944 2 15.2739C2.00001 15.6534 2.09991 16.0262 2.28966 16.3548C2.4794 16.6835 2.75231 16.9564 3.08096 17.1461C3.4096 17.3359 3.7824 17.4358 4.16189 17.4358H15.8381C16.2176 17.4358 16.5904 17.3359 16.919 17.1461C17.2477 16.9564 17.5206 16.6835 17.7103 16.3548C17.9001 16.0262 18 15.6534 18 15.2739C18 14.8944 17.9001 14.5216 17.7104 14.1929L11.8723 4.0809ZM10 15.6848C9.83506 15.6848 9.67383 15.6359 9.5367 15.5443C9.39956 15.4526 9.29267 15.3224 9.22956 15.17C9.16644 15.0176 9.14993 14.8499 9.1821 14.6882C9.21428 14.5264 9.29371 14.3778 9.41033 14.2612C9.52696 14.1446 9.67555 14.0651 9.83732 14.033C9.99908 14.0008 10.1668 14.0173 10.3191 14.0804C10.4715 14.1435 10.6018 14.2504 10.6934 14.3876C10.785 14.5247 10.8339 14.6859 10.8339 14.8509C10.8339 14.9604 10.8124 15.0688 10.7704 15.17C10.7285 15.2712 10.6671 15.3631 10.5897 15.4405C10.5122 15.518 10.4203 15.5794 10.3191 15.6213C10.218 15.6632 10.1095 15.6848 10 15.6848ZM11.1774 7.31731L10.8829 12.3245C10.8696 12.5497 10.7708 12.7613 10.6067 12.916C10.4426 13.0708 10.2255 13.157 9.99997 13.157C9.77439 13.157 9.55734 13.0708 9.39322 12.916C9.2291 12.7613 9.13031 12.5497 9.11707 12.3245L8.82253 7.31731C8.81309 7.15686 8.83654 6.99618 8.89144 6.84513C8.94635 6.69407 9.03155 6.55583 9.14181 6.43889C9.25207 6.32196 9.38507 6.22879 9.53264 6.1651C9.68021 6.10142 9.83924 6.06858 9.99996 6.06858C10.1607 6.06858 10.3197 6.10142 10.4673 6.1651C10.6149 6.22879 10.7478 6.32196 10.8581 6.43889C10.9684 6.55583 11.0536 6.69407 11.1085 6.84513C11.1634 6.99618 11.1868 7.15686 11.1774 7.31731Z",
|
|
18
|
+
fill: "currentColor"
|
|
19
|
+
}));
|
|
20
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = DeleteSvg;
|
|
7
|
+
var _react = _interopRequireDefault(require("react"));
|
|
8
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
9
|
+
function DeleteSvg() {
|
|
10
|
+
return /*#__PURE__*/_react.default.createElement("svg", {
|
|
11
|
+
width: "24",
|
|
12
|
+
height: "24",
|
|
13
|
+
viewBox: "0 0 24 24",
|
|
14
|
+
fill: "none",
|
|
15
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
16
|
+
}, /*#__PURE__*/_react.default.createElement("mask", {
|
|
17
|
+
id: "mask0_2670_1928",
|
|
18
|
+
style: {
|
|
19
|
+
maskType: 'alpha'
|
|
20
|
+
},
|
|
21
|
+
maskUnits: "userSpaceOnUse",
|
|
22
|
+
x: "0",
|
|
23
|
+
y: "-1",
|
|
24
|
+
width: "24",
|
|
25
|
+
height: "25"
|
|
26
|
+
}, /*#__PURE__*/_react.default.createElement("rect", {
|
|
27
|
+
y: "-0.000274658",
|
|
28
|
+
width: "24",
|
|
29
|
+
height: "24",
|
|
30
|
+
fill: "#D9D9D9"
|
|
31
|
+
})), /*#__PURE__*/_react.default.createElement("g", {
|
|
32
|
+
mask: "url(#mask0_2670_1928)"
|
|
33
|
+
}, /*#__PURE__*/_react.default.createElement("path", {
|
|
34
|
+
d: "M6.9577 20.4997C6.56443 20.4997 6.22573 20.3576 5.9416 20.0735C5.65747 19.7893 5.5154 19.4506 5.5154 19.0574V5.45167H5.0673C4.90625 5.45167 4.77144 5.39694 4.66287 5.28749C4.55429 5.17804 4.5 5.04215 4.5 4.87982C4.5 4.71747 4.55429 4.58308 4.66287 4.47667C4.77144 4.37027 4.90625 4.31707 5.0673 4.31707H8.7769C8.7769 4.11963 8.84561 3.95329 8.98303 3.81804C9.12044 3.68278 9.28571 3.61514 9.47883 3.61514H14.5211C14.7142 3.61514 14.8795 3.68385 15.0169 3.82127C15.1543 3.9587 15.2231 4.12397 15.2231 4.31707H18.9327C19.0937 4.31707 19.2285 4.37179 19.3371 4.48124C19.4457 4.59068 19.5 4.72657 19.5 4.88892C19.5 5.05127 19.4457 5.18564 19.3371 5.29204C19.2285 5.39846 19.0937 5.45167 18.9327 5.45167H18.4846V19.0574C18.4846 19.4506 18.3425 19.7893 18.0584 20.0735C17.7742 20.3576 17.4355 20.4997 17.0423 20.4997H6.9577ZM17.35 5.45167H6.64998V19.0574C6.64998 19.1471 6.68042 19.2208 6.74132 19.2785C6.80224 19.3362 6.87437 19.3651 6.9577 19.3651H17.0423C17.1256 19.3651 17.1977 19.3362 17.2586 19.2785C17.3195 19.2208 17.35 19.1471 17.35 19.0574V5.45167ZM9.53078 17.2536H10.6654V7.53819H9.53078V17.2536ZM13.3346 17.2536H14.4692V7.53819H13.3346V17.2536Z",
|
|
35
|
+
fill: "currentColor"
|
|
36
|
+
})));
|
|
37
|
+
}
|
package/build/index.js
CHANGED
|
@@ -113,6 +113,12 @@ Object.defineProperty(exports, "CustomRadio", {
|
|
|
113
113
|
return _CustomRadio.default;
|
|
114
114
|
}
|
|
115
115
|
});
|
|
116
|
+
Object.defineProperty(exports, "CustomSelect", {
|
|
117
|
+
enumerable: true,
|
|
118
|
+
get: function get() {
|
|
119
|
+
return _CustomSelect.default;
|
|
120
|
+
}
|
|
121
|
+
});
|
|
116
122
|
Object.defineProperty(exports, "CustomTable", {
|
|
117
123
|
enumerable: true,
|
|
118
124
|
get: function get() {
|
|
@@ -191,7 +197,7 @@ Object.defineProperty(exports, "SendPaymentLinkWidget", {
|
|
|
191
197
|
return _SendPaymentLinkWidget.default;
|
|
192
198
|
}
|
|
193
199
|
});
|
|
194
|
-
Object.defineProperty(exports, "
|
|
200
|
+
Object.defineProperty(exports, "SpacingDemo", {
|
|
195
201
|
enumerable: true,
|
|
196
202
|
get: function get() {
|
|
197
203
|
return _SpacingScales.default;
|
|
@@ -269,6 +275,18 @@ Object.defineProperty(exports, "colorOptions", {
|
|
|
269
275
|
return _ColorVariablesDemo.colorOptions;
|
|
270
276
|
}
|
|
271
277
|
});
|
|
278
|
+
Object.defineProperty(exports, "getCheckboxTheme", {
|
|
279
|
+
enumerable: true,
|
|
280
|
+
get: function get() {
|
|
281
|
+
return _CustomCheckBox.getCheckboxTheme;
|
|
282
|
+
}
|
|
283
|
+
});
|
|
284
|
+
Object.defineProperty(exports, "getRadioTheme", {
|
|
285
|
+
enumerable: true,
|
|
286
|
+
get: function get() {
|
|
287
|
+
return _CustomRadio.getRadioTheme;
|
|
288
|
+
}
|
|
289
|
+
});
|
|
272
290
|
Object.defineProperty(exports, "typographyOptions", {
|
|
273
291
|
enumerable: true,
|
|
274
292
|
get: function get() {
|
|
@@ -279,15 +297,15 @@ var _Accordion = _interopRequireDefault(require("./components/oa-component-accor
|
|
|
279
297
|
var _ColorVariablesDemo = _interopRequireWildcard(require("./components/oa-component-demo-color-variables/ColorVariablesDemo"));
|
|
280
298
|
var _BorderRadiusDemo = _interopRequireDefault(require("./components/oa-component-demo-border-radius/BorderRadiusDemo"));
|
|
281
299
|
var _CustomButton = _interopRequireDefault(require("./components/oa-component-button/CustomButton"));
|
|
282
|
-
var _CustomCheckBox =
|
|
300
|
+
var _CustomCheckBox = _interopRequireWildcard(require("./components/oa-component-checkbox/CustomCheckBox"));
|
|
283
301
|
var _CustomDrawer = _interopRequireDefault(require("./components/oa-component-drawer/CustomDrawer"));
|
|
284
302
|
var _CustomIcon = _interopRequireWildcard(require("./components/oa-component-icons/CustomIcon"));
|
|
285
303
|
var _CustomInfo = _interopRequireDefault(require("./components/oa-component-info/CustomInfo"));
|
|
286
304
|
var _CustomLoader = _interopRequireDefault(require("./components/oa-component-loader/CustomLoader"));
|
|
287
305
|
var _CustomModal = _interopRequireDefault(require("./components/oa-component-modal/CustomModal"));
|
|
288
306
|
var _CustomNotification = _interopRequireDefault(require("./components/oa-component-notification/CustomNotification"));
|
|
289
|
-
var _CustomRadio =
|
|
290
|
-
var
|
|
307
|
+
var _CustomRadio = _interopRequireWildcard(require("./components/oa-component-radio/CustomRadio"));
|
|
308
|
+
var _CustomSelect = _interopRequireDefault(require("./components/oa-component-select/CustomSelect"));
|
|
291
309
|
var _CustomTable = _interopRequireDefault(require("./components/oa-component-table/CustomTable"));
|
|
292
310
|
var _CustomTabs = _interopRequireDefault(require("./components/oa-component-tabs/CustomTabs"));
|
|
293
311
|
var _CustomTag = _interopRequireDefault(require("./components/oa-component-tag/CustomTag"));
|
|
@@ -296,6 +314,7 @@ var _CustomToggle = _interopRequireDefault(require("./components/oa-component-to
|
|
|
296
314
|
var _ElevationDemo = _interopRequireDefault(require("./components/oa-component-demo-elevation/ElevationDemo"));
|
|
297
315
|
var _TextArea = _interopRequireDefault(require("./components/oa-component-textarea/TextArea"));
|
|
298
316
|
var _Typography = _interopRequireWildcard(require("./components/oa-component-typography/Typography"));
|
|
317
|
+
var _SpacingScales = _interopRequireDefault(require("./components/oa-component-demo-spacing/SpacingScales"));
|
|
299
318
|
var _BorderRadius = _interopRequireDefault(require("./global-css/BorderRadius"));
|
|
300
319
|
var _ColorVariables = _interopRequireDefault(require("./global-css/ColorVariables"));
|
|
301
320
|
var _Elevation = _interopRequireDefault(require("./global-css/Elevation"));
|
|
@@ -13,6 +13,7 @@ var _CustomRadio = _interopRequireDefault(require("../../components/oa-component
|
|
|
13
13
|
var _styles = require("./styles");
|
|
14
14
|
var _Typography = _interopRequireDefault(require("../../components/oa-component-typography/Typography"));
|
|
15
15
|
var _CustomDrawer = _interopRequireDefault(require("../../components/oa-component-drawer/CustomDrawer"));
|
|
16
|
+
var _CustomSelect = _interopRequireDefault(require("../../components/oa-component-select/CustomSelect"));
|
|
16
17
|
const _excluded = ["visible", "onCancel", "onConfirm", "fraudReasons", "closingClaimReasons", "serviceRequestData", "data-test"];
|
|
17
18
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
18
19
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
@@ -98,17 +99,14 @@ function CloseClaimWidget(_ref) {
|
|
|
98
99
|
labelCol: {
|
|
99
100
|
span: 24
|
|
100
101
|
}
|
|
101
|
-
}, /*#__PURE__*/_react.default.createElement(
|
|
102
|
+
}, /*#__PURE__*/_react.default.createElement(_CustomSelect.default, {
|
|
102
103
|
placeholder: "Select",
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
value: row.key,
|
|
110
|
-
"data-test": dataTest ? "".concat(dataTest, "--rejection-reason-(").concat(row.value, ")") : undefined
|
|
111
|
-
}, row.value)))), /*#__PURE__*/_react.default.createElement("div", null, /*#__PURE__*/_react.default.createElement(_antd.Form.Item, {
|
|
104
|
+
"data-test": dataTest ? "".concat(dataTest, "--rejection-reason") : undefined,
|
|
105
|
+
options: closingClaimReasons === null || closingClaimReasons === void 0 ? void 0 : closingClaimReasons.map(row => ({
|
|
106
|
+
value: row.key,
|
|
107
|
+
label: row.value
|
|
108
|
+
}))
|
|
109
|
+
})), /*#__PURE__*/_react.default.createElement("div", null, /*#__PURE__*/_react.default.createElement(_antd.Form.Item, {
|
|
112
110
|
name: "isCustomerFraudCase",
|
|
113
111
|
rules: [{
|
|
114
112
|
required: true,
|
|
@@ -147,19 +145,19 @@ function CloseClaimWidget(_ref) {
|
|
|
147
145
|
labelCol: {
|
|
148
146
|
span: 24
|
|
149
147
|
}
|
|
150
|
-
}, /*#__PURE__*/_react.default.createElement(
|
|
148
|
+
}, /*#__PURE__*/_react.default.createElement(_CustomSelect.default, {
|
|
151
149
|
mode: "multiple",
|
|
152
150
|
placeholder: "Select",
|
|
153
|
-
"data-test": dataTest ? "".concat(dataTest, "--fraud-reason
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
}
|
|
151
|
+
"data-test": dataTest ? "".concat(dataTest, "--fraud-reason") : undefined,
|
|
152
|
+
options: [{
|
|
153
|
+
value: 'placeholder',
|
|
154
|
+
label: 'Select one or more...',
|
|
155
|
+
disabled: true
|
|
156
|
+
}, ...fraudReasons.map(row => ({
|
|
157
|
+
value: row.key,
|
|
158
|
+
label: row.value
|
|
159
|
+
}))]
|
|
160
|
+
})), /*#__PURE__*/_react.default.createElement(_antd.Form.Item, {
|
|
163
161
|
label: "Remarks",
|
|
164
162
|
labelCol: {
|
|
165
163
|
span: 24
|
|
@@ -10,5 +10,5 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
10
10
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
11
11
|
var _default = {};
|
|
12
12
|
exports.default = _default;
|
|
13
|
-
const AsideContainer = _styledComponents.default.aside(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n h1 {\n padding: 0 0 10px;\n margin: 0;\n color: var(--color-primary-content);\n }\n\n small {\n padding: 0 0 32px;\n margin: 0;\n display: block;\n color: var(--color-primary-content);\n }\n\n .ant-radio-group {\n display: flex;\n }\n\n .ant-form-item .ant-form-item-label >label.ant-form-item-required:not(.ant-form-item-required-mark-optional)::before {\n position: absolute;\n right:0;\n color: var(--color-negative);\n padding: 0;\n }\n .ant-form-item {\n margin-bottom: 36px;\n }\n\n textarea {\n min-height: 108px;\n resize: none;\n border-radius: 4px;\n padding: 12px;\n border: 1px solid var(--color-placeholder-text);\n }\n ::-ms-input-placeholder { \n color: var(--color-placeholder-text);\n }\n .type-r1-400 {\n color: var(--color-negative);\n }\n
|
|
13
|
+
const AsideContainer = _styledComponents.default.aside(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n h1 {\n padding: 0 0 10px;\n margin: 0;\n color: var(--color-primary-content);\n }\n\n small {\n padding: 0 0 32px;\n margin: 0;\n display: block;\n color: var(--color-primary-content);\n }\n\n .ant-radio-group {\n display: flex;\n }\n\n .ant-form-item .ant-form-item-label >label.ant-form-item-required:not(.ant-form-item-required-mark-optional)::before {\n position: absolute;\n right:0;\n color: var(--color-negative);\n padding: 0;\n }\n .ant-form-item {\n margin-bottom: 36px;\n }\n\n textarea {\n min-height: 108px;\n resize: none;\n border-radius: 4px;\n padding: 12px;\n border: 1px solid var(--color-placeholder-text);\n }\n ::-ms-input-placeholder { \n color: var(--color-placeholder-text);\n }\n .type-r1-400 {\n color: var(--color-negative);\n }\n\n .ant-form-item .ant-form-item-label {\n padding: 0;\n }\n\n label {\n padding: 0 0 4px;\n height: auto !important;\n color: var(--color-primary-content) !important;\n }\n\n form .ant-radio-wrapper {\n width: 140px;\n }\n"])));
|
|
14
14
|
exports.AsideContainer = AsideContainer;
|
|
@@ -55,7 +55,7 @@ function NotesWidget(_ref) {
|
|
|
55
55
|
if (!disabled && index === 0) {
|
|
56
56
|
return /*#__PURE__*/_react.default.createElement(_antd.Input, {
|
|
57
57
|
"data-test": dataTest,
|
|
58
|
-
size: "
|
|
58
|
+
size: "medium",
|
|
59
59
|
value: noteInputValue,
|
|
60
60
|
onChange: event => setNoteInputValue(event.target.value),
|
|
61
61
|
onBlur: handleBlur,
|
|
@@ -79,10 +79,8 @@ function NotesWidget(_ref) {
|
|
|
79
79
|
dataSource: mutatedRecords,
|
|
80
80
|
pagination: false,
|
|
81
81
|
style: {
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
we show a message instead of a table
|
|
85
|
-
*/
|
|
82
|
+
border: '1px solid var(--color-divider)',
|
|
83
|
+
borderRadius: '4px',
|
|
86
84
|
display: !(records.length > 0) && disabled ? 'none' : undefined
|
|
87
85
|
},
|
|
88
86
|
size: "small"
|
|
@@ -10,5 +10,5 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
10
10
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
11
11
|
var _default = {};
|
|
12
12
|
exports.default = _default;
|
|
13
|
-
const NoNotesMessage = _styledComponents.default.section(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n position: absolute;\n top: 50%;\n left: 50%;\n transform: translateX(-50%) translateY(-50%);\n"])));
|
|
13
|
+
const NoNotesMessage = _styledComponents.default.section(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n position: absolute;\n top: 50%;\n left: 50%;\n transform: translateX(-50%) translateY(-50%);\n input{\n height: 30px;\n }\n"])));
|
|
14
14
|
exports.NoNotesMessage = NoNotesMessage;
|
|
@@ -10,7 +10,7 @@ var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
|
10
10
|
var _icons = require("@ant-design/icons");
|
|
11
11
|
var _antd = require("antd");
|
|
12
12
|
var _nanoid = require("nanoid");
|
|
13
|
-
var
|
|
13
|
+
var _CustomIcon = require("../../components/oa-component-icons/CustomIcon");
|
|
14
14
|
var _styles = require("./styles");
|
|
15
15
|
var _Typography = _interopRequireDefault(require("../../components/oa-component-typography/Typography"));
|
|
16
16
|
var _CustomButton = _interopRequireDefault(require("../../components/oa-component-button/CustomButton"));
|
|
@@ -106,10 +106,7 @@ function UploadDownloadWidget(_ref) {
|
|
|
106
106
|
"data-test": dataTest ? "".concat(dataTest, "--delete-button-").concat(index) : undefined,
|
|
107
107
|
iconConfig: {
|
|
108
108
|
position: 'left',
|
|
109
|
-
icon: /*#__PURE__*/_react.default.createElement(
|
|
110
|
-
src: _delete.default,
|
|
111
|
-
alt: "img"
|
|
112
|
-
})
|
|
109
|
+
icon: /*#__PURE__*/_react.default.createElement(_CustomIcon.DeleteIcon, null)
|
|
113
110
|
},
|
|
114
111
|
onClick: (_uploadedDocument$onD2 = uploadedDocument.onDelete) !== null && _uploadedDocument$onD2 !== void 0 ? _uploadedDocument$onD2 : () => {},
|
|
115
112
|
type: "danger-text-only"
|
|
@@ -9,7 +9,7 @@ var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
|
9
9
|
var _templateObject, _templateObject2, _templateObject3, _templateObject4;
|
|
10
10
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
11
11
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
12
|
-
const StyledSection = _styledComponents.default.section(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: flex;\n
|
|
12
|
+
const StyledSection = _styledComponents.default.section(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: flex;\n gap: 4px;\n\n .text-container img:hover{\n opacity: 0.4;\n }\n .ant-btn-link{\n display: flex;\n padding: 0!important;\n height: auto !important;\n align-items: center;\n }\n\n .ant-btn >.anticon+span {\n margin-inline-start: 4px;\n }\n"])));
|
|
13
13
|
exports.StyledSection = StyledSection;
|
|
14
14
|
const EllipsisLabel = _styledComponents.default.span(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n display: block;\n \n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n width: 102px;\n"])));
|
|
15
15
|
exports.EllipsisLabel = EllipsisLabel;
|
|
@@ -89,16 +89,18 @@ function ViewHistoryWidget(_ref) {
|
|
|
89
89
|
placement: "right",
|
|
90
90
|
title: "VIEW HISTORY",
|
|
91
91
|
width: "860"
|
|
92
|
-
}, props), /*#__PURE__*/_react.default.createElement(
|
|
93
|
-
|
|
92
|
+
}, props), /*#__PURE__*/_react.default.createElement(_Typography.default, {
|
|
93
|
+
color: "primary-content",
|
|
94
|
+
typography: "type-b1-400"
|
|
94
95
|
}, name ? "".concat(name, ": ") : null, "Current File"), /*#__PURE__*/_react.default.createElement(_styles.TableContainer, null, /*#__PURE__*/_react.default.createElement(_CustomTable.default, {
|
|
95
96
|
columns: columns,
|
|
96
97
|
dataSource: currentDocument !== null && currentDocument !== void 0 && (_currentDocument$docD = currentDocument.docDetails) !== null && _currentDocument$docD !== void 0 && (_currentDocument$docD = _currentDocument$docD.uploadedDocuments) !== null && _currentDocument$docD !== void 0 && (_currentDocument$docD = _currentDocument$docD[0]) !== null && _currentDocument$docD !== void 0 && _currentDocument$docD.name && currentDocument !== null && currentDocument !== void 0 && (_currentDocument$docD2 = currentDocument.docDetails) !== null && _currentDocument$docD2 !== void 0 && (_currentDocument$docD2 = _currentDocument$docD2.uploadedDocuments) !== null && _currentDocument$docD2 !== void 0 && (_currentDocument$docD2 = _currentDocument$docD2[0]) !== null && _currentDocument$docD2 !== void 0 && _currentDocument$docD2.onDownload ? [currentDocument] : [],
|
|
97
98
|
rowKey: "key",
|
|
98
99
|
size: "middle",
|
|
99
100
|
pagination: false
|
|
100
|
-
})), /*#__PURE__*/_react.default.createElement(
|
|
101
|
-
|
|
101
|
+
})), /*#__PURE__*/_react.default.createElement(_Typography.default, {
|
|
102
|
+
color: "primary-content",
|
|
103
|
+
typography: "type-b1-400"
|
|
102
104
|
}, "History"), /*#__PURE__*/_react.default.createElement(_styles.TableContainer, null, /*#__PURE__*/_react.default.createElement(_CustomTable.default, {
|
|
103
105
|
columns: columns,
|
|
104
106
|
dataSource: copyOfPreviousDocuments,
|
|
@@ -3,14 +3,12 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.default = exports.
|
|
6
|
+
exports.default = exports.TableContainer = void 0;
|
|
7
7
|
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
8
|
-
var _templateObject
|
|
8
|
+
var _templateObject;
|
|
9
9
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
10
10
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
11
11
|
var _default = {};
|
|
12
12
|
exports.default = _default;
|
|
13
|
-
const TableContainer = _styledComponents.default.section(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n padding: 16px 0
|
|
14
|
-
exports.TableContainer = TableContainer;
|
|
15
|
-
const ViewHistoryPara = _styledComponents.default.h3(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n color: var(--color-primary-content);\n"])));
|
|
16
|
-
exports.ViewHistoryPara = ViewHistoryPara;
|
|
13
|
+
const TableContainer = _styledComponents.default.section(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n padding: 16px 0 32px;\n"])));
|
|
14
|
+
exports.TableContainer = TableContainer;
|
package/package.json
CHANGED
/package/build/components/{oa-component-spacingScales → oa-component-demo-spacing}/SpacingScales.js
RENAMED
|
File without changes
|
/package/build/components/{oa-component-spacingScales → oa-component-demo-spacing}/styles.js
RENAMED
|
File without changes
|