dtable-ui-component 6.0.117-beta.9 → 6.0.117-xms.7
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/lib/DTableDropdownMenu/index.js +1 -3
- package/lib/DTableSubDropdownMenu/index.js +1 -8
- package/lib/DTableToolTip/index.css +45 -0
- package/lib/DTableToolTip/index.js +67 -0
- package/lib/ImagePreviewerLightbox/index.js +4 -1
- package/lib/index.js +7 -0
- package/lib/locales/de.json +2 -0
- package/lib/locales/en.json +2 -0
- package/lib/locales/es.json +2 -0
- package/lib/locales/fr.json +2 -0
- package/lib/locales/pt.json +2 -0
- package/lib/locales/ru.json +2 -0
- package/lib/locales/zh-CN.json +2 -0
- package/package.json +1 -1
|
@@ -20,9 +20,7 @@ const DTableDropdownMenu = _ref => {
|
|
|
20
20
|
menuProps,
|
|
21
21
|
children
|
|
22
22
|
} = _ref;
|
|
23
|
-
let customMenuProps = (0, _objectSpread2.default)(
|
|
24
|
-
flip: false
|
|
25
|
-
});
|
|
23
|
+
let customMenuProps = (0, _objectSpread2.default)({}, menuProps);
|
|
26
24
|
customMenuProps.modifiers = [{
|
|
27
25
|
name: 'preventOverflow',
|
|
28
26
|
options: {
|
|
@@ -20,9 +20,7 @@ const DTableSubDropdownMenu = _ref => {
|
|
|
20
20
|
menuProps,
|
|
21
21
|
children
|
|
22
22
|
} = _ref;
|
|
23
|
-
let customMenuProps = (0, _objectSpread2.default)(
|
|
24
|
-
flip: false
|
|
25
|
-
});
|
|
23
|
+
let customMenuProps = (0, _objectSpread2.default)({}, menuProps);
|
|
26
24
|
if (container) {
|
|
27
25
|
customMenuProps.container = container;
|
|
28
26
|
}
|
|
@@ -40,11 +38,6 @@ const DTableSubDropdownMenu = _ref => {
|
|
|
40
38
|
className: (0, _classnames.default)('dtable-sub-dropdown-menu', className),
|
|
41
39
|
menuProps: (0, _objectSpread2.default)((0, _objectSpread2.default)({}, customMenuProps), {}, {
|
|
42
40
|
modifiers: [{
|
|
43
|
-
name: 'preventOverflow',
|
|
44
|
-
options: {
|
|
45
|
-
boundary: document.body
|
|
46
|
-
}
|
|
47
|
-
}, {
|
|
48
41
|
name: 'offset',
|
|
49
42
|
options: {
|
|
50
43
|
offset: [-8, -1]
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
.dtable-tooltip {
|
|
2
|
+
position: absolute;
|
|
3
|
+
z-index: 99999;
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
.dtable-tooltip .tooltip {
|
|
7
|
+
max-width: 242px;
|
|
8
|
+
min-width: max-content;
|
|
9
|
+
opacity: 1;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.dtable-tooltip .tooltip .tooltip-inner {
|
|
13
|
+
font-size: 14px;
|
|
14
|
+
text-align: start;
|
|
15
|
+
background-color: var(--bs-body-color);
|
|
16
|
+
color: var(--bs-body-bg);
|
|
17
|
+
border-radius: 4px;
|
|
18
|
+
padding: 4px 8px;
|
|
19
|
+
line-height: 20px;
|
|
20
|
+
font-weight: normal;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.dtable-tooltip-shortcut-inner {
|
|
24
|
+
display: flex;
|
|
25
|
+
align-items: center;
|
|
26
|
+
justify-content: space-between;
|
|
27
|
+
gap: 4px;
|
|
28
|
+
line-height: 20px;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.dtable-tooltip-shortcut-keys {
|
|
32
|
+
display: inline-flex;
|
|
33
|
+
align-items: center;
|
|
34
|
+
gap: 4px;
|
|
35
|
+
flex-shrink: 0;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.dtable-tooltip-shortcut-key {
|
|
39
|
+
display: inline-block;
|
|
40
|
+
padding: 2px 8px;
|
|
41
|
+
border: 1px solid #999;
|
|
42
|
+
border-radius: 4px;
|
|
43
|
+
white-space: nowrap;
|
|
44
|
+
line-height: 14px;
|
|
45
|
+
}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
|
|
4
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5
|
+
value: true
|
|
6
|
+
});
|
|
7
|
+
exports.default = void 0;
|
|
8
|
+
var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectSpread2"));
|
|
9
|
+
var _react = _interopRequireDefault(require("react"));
|
|
10
|
+
var _reactstrap = require("reactstrap");
|
|
11
|
+
require("./index.css");
|
|
12
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
13
|
+
const DTableToolTip = _ref => {
|
|
14
|
+
let {
|
|
15
|
+
target,
|
|
16
|
+
placement = 'bottom',
|
|
17
|
+
className,
|
|
18
|
+
children,
|
|
19
|
+
shortcut
|
|
20
|
+
} = _ref;
|
|
21
|
+
const hasShortcut = Boolean(shortcut);
|
|
22
|
+
const renderContent = () => {
|
|
23
|
+
if (hasShortcut) {
|
|
24
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
25
|
+
className: "dtable-tooltip-shortcut-inner",
|
|
26
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
27
|
+
className: "dtable-tooltip-text",
|
|
28
|
+
children: children
|
|
29
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
30
|
+
className: "dtable-tooltip-shortcut-keys",
|
|
31
|
+
children: shortcut.map((key, index) => /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
32
|
+
className: "dtable-tooltip-shortcut-key",
|
|
33
|
+
children: key
|
|
34
|
+
}, index))
|
|
35
|
+
})]
|
|
36
|
+
});
|
|
37
|
+
}
|
|
38
|
+
return children;
|
|
39
|
+
};
|
|
40
|
+
const tooltipProps = {
|
|
41
|
+
target,
|
|
42
|
+
placement,
|
|
43
|
+
className: "dtable-tooltip ".concat(className ? className : ''),
|
|
44
|
+
innerClassName: hasShortcut ? 'dtable-tooltip-shortcut-inner' : '',
|
|
45
|
+
delay: {
|
|
46
|
+
show: 0,
|
|
47
|
+
hide: 0
|
|
48
|
+
},
|
|
49
|
+
hideArrow: true,
|
|
50
|
+
autohide: false,
|
|
51
|
+
modifiers: [{
|
|
52
|
+
name: 'offset',
|
|
53
|
+
options: {
|
|
54
|
+
offset: [0, -2.5]
|
|
55
|
+
}
|
|
56
|
+
}, {
|
|
57
|
+
name: 'preventOverflow',
|
|
58
|
+
options: {
|
|
59
|
+
boundariesElement: 'window'
|
|
60
|
+
}
|
|
61
|
+
}]
|
|
62
|
+
};
|
|
63
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactstrap.UncontrolledTooltip, (0, _objectSpread2.default)((0, _objectSpread2.default)({}, tooltipProps), {}, {
|
|
64
|
+
children: renderContent()
|
|
65
|
+
}));
|
|
66
|
+
};
|
|
67
|
+
var _default = exports.default = DTableToolTip;
|
|
@@ -124,7 +124,10 @@ function ImagePreviewerLightbox(props) {
|
|
|
124
124
|
zoomOutTip: (0, _lang.getLocale)('Zoom_out'),
|
|
125
125
|
rotateTip: (0, _lang.getLocale)('Rotate_image'),
|
|
126
126
|
deleteTip: (0, _lang.getLocale)('Delete_image'),
|
|
127
|
-
downloadImageTip: (0, _lang.getLocale)('Download_image')
|
|
127
|
+
downloadImageTip: (0, _lang.getLocale)('Download_image'),
|
|
128
|
+
preLineMetadaTip: (0, _lang.getLocale)('Pre_Line'),
|
|
129
|
+
nextLineMetadaTip: (0, _lang.getLocale)('Next_Line'),
|
|
130
|
+
closeMetadataTip: (0, _lang.getLocale)('Close')
|
|
128
131
|
});
|
|
129
132
|
}
|
|
130
133
|
var _default = exports.default = ImagePreviewerLightbox;
|
package/lib/index.js
CHANGED
|
@@ -226,6 +226,12 @@ Object.defineProperty(exports, "DTableSwitch", {
|
|
|
226
226
|
return _DTableSwitch.default;
|
|
227
227
|
}
|
|
228
228
|
});
|
|
229
|
+
Object.defineProperty(exports, "DTableToolTip", {
|
|
230
|
+
enumerable: true,
|
|
231
|
+
get: function () {
|
|
232
|
+
return _DTableToolTip.default;
|
|
233
|
+
}
|
|
234
|
+
});
|
|
229
235
|
Object.defineProperty(exports, "DateEditor", {
|
|
230
236
|
enumerable: true,
|
|
231
237
|
get: function () {
|
|
@@ -685,6 +691,7 @@ var _FileItemFormatter = _interopRequireDefault(require("./FileItemFormatter"));
|
|
|
685
691
|
var _DigitalSignFormatter = _interopRequireDefault(require("./DigitalSignFormatter"));
|
|
686
692
|
var _DepartmentSingleSelectFormatter = _interopRequireDefault(require("./DepartmentSingleSelectFormatter"));
|
|
687
693
|
var _SimpleLongTextFormatter = _interopRequireDefault(require("./SimpleLongTextFormatter"));
|
|
694
|
+
var _DTableToolTip = _interopRequireDefault(require("./DTableToolTip"));
|
|
688
695
|
var _RowExpandFormatter = _interopRequireDefault(require("./RowExpandFormatter"));
|
|
689
696
|
var _RowExpandEditor = _interopRequireDefault(require("./RowExpandEditor"));
|
|
690
697
|
var _RowExpand = _interopRequireDefault(require("./RowExpand"));
|
package/lib/locales/de.json
CHANGED
|
@@ -12,6 +12,8 @@
|
|
|
12
12
|
"Rotate_image": "Rotate image",
|
|
13
13
|
"Delete_image": "delete image",
|
|
14
14
|
"Download_image": "Download image",
|
|
15
|
+
"Pre_Line": "previous Line",
|
|
16
|
+
"Next_Line": "next Line",
|
|
15
17
|
"Zoom_in": "Zoom in",
|
|
16
18
|
"Zoom_out": "Zoom out",
|
|
17
19
|
"Choose_a_collaborator": "Wählen Sie einen Mitarbeiter",
|
package/lib/locales/en.json
CHANGED
|
@@ -12,6 +12,8 @@
|
|
|
12
12
|
"Rotate_image": "Rotate image",
|
|
13
13
|
"Delete_image": "delete image",
|
|
14
14
|
"Download_image": "Download image",
|
|
15
|
+
"Pre_Line": "previous Line",
|
|
16
|
+
"Next_Line": "next Line",
|
|
15
17
|
"Zoom_in": "Zoom in",
|
|
16
18
|
"Zoom_out": "Zoom out",
|
|
17
19
|
"Choose_a_collaborator": "Choose a collaborator",
|
package/lib/locales/es.json
CHANGED
|
@@ -12,6 +12,8 @@
|
|
|
12
12
|
"Rotate_image": "Rotate image",
|
|
13
13
|
"Delete_image": "delete image",
|
|
14
14
|
"Download_image": "Download image",
|
|
15
|
+
"Pre_Line": "previous Line",
|
|
16
|
+
"Next_Line": "next Line",
|
|
15
17
|
"Zoom_in": "Zoom in",
|
|
16
18
|
"Zoom_out": "Zoom out",
|
|
17
19
|
"Choose_a_collaborator": "Choose a collaborator",
|
package/lib/locales/fr.json
CHANGED
|
@@ -12,6 +12,8 @@
|
|
|
12
12
|
"Rotate_image": "Rotate image",
|
|
13
13
|
"Delete_image": "delete image",
|
|
14
14
|
"Download_image": "Download image",
|
|
15
|
+
"Pre_Line": "previous Line",
|
|
16
|
+
"Next_Line": "next Line",
|
|
15
17
|
"Zoom_in": "Zoom in",
|
|
16
18
|
"Zoom_out": "Zoom out",
|
|
17
19
|
"Choose_a_collaborator": "Choisissez un collaborateur",
|
package/lib/locales/pt.json
CHANGED
|
@@ -12,6 +12,8 @@
|
|
|
12
12
|
"Rotate_image": "Rotate image",
|
|
13
13
|
"Delete_image": "delete image",
|
|
14
14
|
"Download_image": "Download image",
|
|
15
|
+
"Pre_Line": "previous Line",
|
|
16
|
+
"Next_Line": "next Line",
|
|
15
17
|
"Zoom_in": "Zoom in",
|
|
16
18
|
"Zoom_out": "Zoom out",
|
|
17
19
|
"Choose_a_collaborator": "Choose a collaborator",
|
package/lib/locales/ru.json
CHANGED
|
@@ -12,6 +12,8 @@
|
|
|
12
12
|
"Rotate_image": "Rotate image",
|
|
13
13
|
"Delete_image": "delete image",
|
|
14
14
|
"Download_image": "Download image",
|
|
15
|
+
"Pre_Line": "previous Line",
|
|
16
|
+
"Next_Line": "next Line",
|
|
15
17
|
"Zoom_in": "Zoom in",
|
|
16
18
|
"Zoom_out": "Zoom out",
|
|
17
19
|
"Choose_a_collaborator": "Choose a collaborator",
|
package/lib/locales/zh-CN.json
CHANGED