@rio-cloud/rio-uikit 0.16.0-beta-3 → 0.16.1-beta-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/lib/components/filepicker/FilePicker.js +1 -1
- package/lib/components/table/TableSettingsColumnButtons.js +7 -6
- package/lib/components/table/TableSettingsColumnDetails.js +58 -103
- package/lib/components/table/TableSettingsDialog.js +26 -32
- package/lib/components/table/TableSettingsDialogFooter.js +15 -13
- package/lib/components/table/TableSettingsListContainer.js +55 -20
- package/lib/components/table/TableSettingsListItem.js +66 -27
- package/lib/components/table/TableViewToggles.js +98 -104
- package/lib/components/table/tableSettingsPropTypes.js +18 -0
- package/lib/style/css/_exports/rio-buyButton.less +1 -1
- package/lib/style/css/_exports/rio-uikit-core.less +5 -1
- package/lib/style/css/_exports/rio-website.less +1 -2
- package/lib/style/css/_exports/vw-uikit.less +1 -1
- package/lib/style/css/components/ApplicationHeader.less +1 -1
- package/lib/style/css/components/AssetTree.less +2 -2
- package/lib/style/css/components/Dialog.less +13 -11
- package/lib/style/css/components/Dropdown.less +0 -1
- package/lib/style/css/components/Select.less +1 -0
- package/lib/style/css/components/TableToolbar.less +1 -1
- package/lib/style/css/components/Tooltip.less +0 -39
- package/lib/style/css/design/list-group.less +7 -2
- package/lib/style/css/design/responsive/_imports.less +0 -1
- package/lib/style/css/design/responsive/flexgrid.less +14 -14
- package/lib/style/css/design/responsive/position.less +9 -8
- package/lib/style/css/design/responsive/sizing.less +0 -19
- package/lib/style/css/design/sizing.less +18 -0
- package/lib/style/css/design/visibility.less +186 -0
- package/lib/style/css/filter/_imports.less +1 -0
- package/lib/style/css/filter/blur.less +17 -0
- package/lib/style/fonts/rioglyph/rioglyph.less +11 -1
- package/lib/style/fonts/rioglyph/rioglyph.svg +120 -102
- package/lib/style/fonts/rioglyph/rioglyph.ttf +0 -0
- package/lib/style/fonts/rioglyph/rioglyph.woff +0 -0
- package/lib/types.ts +10 -6
- package/lib/version.json +1 -1
- package/package.json +8 -6
|
@@ -11,9 +11,15 @@ var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends")
|
|
|
11
11
|
|
|
12
12
|
var _react = _interopRequireDefault(require("react"));
|
|
13
13
|
|
|
14
|
+
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
15
|
+
|
|
14
16
|
var _classnames = _interopRequireDefault(require("classnames"));
|
|
15
17
|
|
|
16
|
-
var
|
|
18
|
+
var _sortable = require("@dnd-kit/sortable");
|
|
19
|
+
|
|
20
|
+
var _utilities = require("@dnd-kit/utilities");
|
|
21
|
+
|
|
22
|
+
var _isEmpty = _interopRequireDefault(require("lodash/fp/isEmpty"));
|
|
17
23
|
|
|
18
24
|
var _Checkbox = _interopRequireDefault(require("../checkbox/Checkbox"));
|
|
19
25
|
|
|
@@ -23,6 +29,8 @@ var _TableSettingsColumnDetails = require("./TableSettingsColumnDetails");
|
|
|
23
29
|
|
|
24
30
|
var _TableSettingsColumnButtons = require("./TableSettingsColumnButtons");
|
|
25
31
|
|
|
32
|
+
var _tableSettingsPropTypes = require("./tableSettingsPropTypes");
|
|
33
|
+
|
|
26
34
|
/* eslint-disable new-cap */
|
|
27
35
|
var MAX_COLUMN_WIDTH = 1000;
|
|
28
36
|
|
|
@@ -39,22 +47,14 @@ var filterColumns = function filterColumns(searchValue) {
|
|
|
39
47
|
};
|
|
40
48
|
|
|
41
49
|
exports.filterColumns = filterColumns;
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
_ref$className = _ref.className,
|
|
46
|
-
className = _ref$className === void 0 ? '' : _ref$className;
|
|
47
|
-
return /*#__PURE__*/_react.default.createElement("div", {
|
|
48
|
-
className: "table-settings-item-label ".concat(className),
|
|
49
|
-
"data-key": column
|
|
50
|
-
}, columnLabels[column]);
|
|
51
|
-
});
|
|
52
|
-
var TableSettingsListItem = (0, _reactSortableHoc.SortableElement)(function (props) {
|
|
53
|
-
var column = props.value,
|
|
50
|
+
|
|
51
|
+
var TableSettingsListItem = function TableSettingsListItem(props) {
|
|
52
|
+
var column = props.column,
|
|
54
53
|
orderIndex = props.orderIndex,
|
|
55
54
|
columnLabels = props.columnLabels,
|
|
56
55
|
autoLabel = props.autoLabel,
|
|
57
|
-
|
|
56
|
+
_props$disabledColumn = props.disabledColumns,
|
|
57
|
+
disabledColumns = _props$disabledColumn === void 0 ? [] : _props$disabledColumn,
|
|
58
58
|
columnOrder = props.columnOrder,
|
|
59
59
|
_props$hiddenColumns = props.hiddenColumns,
|
|
60
60
|
hiddenColumns = _props$hiddenColumns === void 0 ? [] : _props$hiddenColumns,
|
|
@@ -67,20 +67,39 @@ var TableSettingsListItem = (0, _reactSortableHoc.SortableElement)(function (pro
|
|
|
67
67
|
onResetColumnWidth = props.onResetColumnWidth,
|
|
68
68
|
onMoveColumn = props.onMoveColumn,
|
|
69
69
|
onOpenDetails = props.onOpenDetails,
|
|
70
|
-
onToggleHideColumn = props.onToggleHideColumn
|
|
70
|
+
onToggleHideColumn = props.onToggleHideColumn,
|
|
71
|
+
className = props.className;
|
|
72
|
+
var isSortingDisabled = !(0, _isEmpty.default)(columnSearchValue);
|
|
73
|
+
|
|
74
|
+
var _useSortable = (0, _sortable.useSortable)({
|
|
75
|
+
id: column,
|
|
76
|
+
disabled: isSortingDisabled
|
|
77
|
+
}),
|
|
78
|
+
attributes = _useSortable.attributes,
|
|
79
|
+
listeners = _useSortable.listeners,
|
|
80
|
+
setNodeRef = _useSortable.setNodeRef,
|
|
81
|
+
transform = _useSortable.transform,
|
|
82
|
+
transition = _useSortable.transition;
|
|
83
|
+
|
|
84
|
+
var style = {
|
|
85
|
+
transform: _utilities.CSS.Transform.toString(transform),
|
|
86
|
+
transition: transition
|
|
87
|
+
}; // Filter out items which don't match the search value.
|
|
71
88
|
// Note that we need to render all items at least once at the beginning in order to get their DOM lables
|
|
72
89
|
// otherwise the search won't work when initial search value is provided via props.
|
|
73
90
|
|
|
74
91
|
var isFiltered = filterColumns(columnSearchValue, column, columnLabelStrings) && !updateColumnLabelStrings;
|
|
75
|
-
var itemClassNames = (0, _classnames.default)('table-settings-item', updateColumnLabelStrings && 'opacity-0', isFiltered && 'position-offscreen');
|
|
92
|
+
var itemClassNames = (0, _classnames.default)('table-settings-item', updateColumnLabelStrings && 'opacity-0', isFiltered && 'position-offscreen', className);
|
|
76
93
|
var columnDetails = columnsDetails[column];
|
|
77
94
|
return /*#__PURE__*/_react.default.createElement("div", {
|
|
78
95
|
className: itemClassNames,
|
|
79
|
-
key: "table-settings-item-".concat(column)
|
|
96
|
+
key: "table-settings-item-".concat(column),
|
|
97
|
+
ref: setNodeRef,
|
|
98
|
+
style: style
|
|
80
99
|
}, /*#__PURE__*/_react.default.createElement("div", {
|
|
81
|
-
className:
|
|
100
|
+
className: "table-settings-item-header user-select-none"
|
|
82
101
|
}, /*#__PURE__*/_react.default.createElement("div", {
|
|
83
|
-
className:
|
|
102
|
+
className: "CheckboxWrapper display-flex align-items-center padding-left-2"
|
|
84
103
|
}, /*#__PURE__*/_react.default.createElement(_Checkbox.default, {
|
|
85
104
|
checked: !hiddenColumns.includes(column),
|
|
86
105
|
onClick: function onClick(event) {
|
|
@@ -88,19 +107,18 @@ var TableSettingsListItem = (0, _reactSortableHoc.SortableElement)(function (pro
|
|
|
88
107
|
event.stopPropagation();
|
|
89
108
|
},
|
|
90
109
|
disabled: disabledColumns.includes(column)
|
|
91
|
-
})), /*#__PURE__*/_react.default.createElement(
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
className: 'column-width-label'
|
|
110
|
+
})), /*#__PURE__*/_react.default.createElement("div", (0, _extends2.default)({
|
|
111
|
+
className: "table-settings-item-label ".concat(isSortingDisabled ? 'no-drag' : ''),
|
|
112
|
+
"data-key": column
|
|
113
|
+
}, attributes, listeners), columnLabels[column]), columnDetails && /*#__PURE__*/_react.default.createElement("div", {
|
|
114
|
+
className: "column-width-label"
|
|
97
115
|
}, columnDetails.width ? "".concat(columnDetails.width, "px") : autoLabel), /*#__PURE__*/_react.default.createElement(_TableSettingsColumnButtons.TableSettingsColumnButtons, {
|
|
98
116
|
column: column,
|
|
99
117
|
index: orderIndex,
|
|
100
118
|
columnDetails: columnDetails,
|
|
101
119
|
columnOrder: columnOrder,
|
|
102
120
|
openColumnsDetails: openColumnsDetails,
|
|
103
|
-
|
|
121
|
+
disabled: isSortingDisabled,
|
|
104
122
|
onMoveColumn: onMoveColumn,
|
|
105
123
|
onOpenDetails: onOpenDetails
|
|
106
124
|
})), columnDetails && /*#__PURE__*/_react.default.createElement(_Collapse.default, {
|
|
@@ -111,6 +129,27 @@ var TableSettingsListItem = (0, _reactSortableHoc.SortableElement)(function (pro
|
|
|
111
129
|
onColumnWidthChange: onColumnWidthChange,
|
|
112
130
|
onResetColumnWidth: onResetColumnWidth
|
|
113
131
|
})))));
|
|
114
|
-
}
|
|
132
|
+
};
|
|
133
|
+
|
|
134
|
+
TableSettingsListItem.propTypes = {
|
|
135
|
+
column: _propTypes.default.string,
|
|
136
|
+
orderIndex: _propTypes.default.number,
|
|
137
|
+
columnLabels: _propTypes.default.object,
|
|
138
|
+
autoLabel: _propTypes.default.string,
|
|
139
|
+
disabledColumns: _propTypes.default.arrayOf(_propTypes.default.string),
|
|
140
|
+
columnOrder: _propTypes.default.arrayOf(_propTypes.default.string),
|
|
141
|
+
hiddenColumns: _propTypes.default.arrayOf(_propTypes.default.string),
|
|
142
|
+
columnSearchValue: _propTypes.default.string,
|
|
143
|
+
columnsDetails: _tableSettingsPropTypes.columnsDetailsPropTypes,
|
|
144
|
+
columnLabelStrings: _propTypes.default.object,
|
|
145
|
+
openColumnsDetails: _propTypes.default.object,
|
|
146
|
+
updateColumnLabelStrings: _propTypes.default.bool,
|
|
147
|
+
onColumnWidthChange: _propTypes.default.func,
|
|
148
|
+
onResetColumnWidth: _propTypes.default.func,
|
|
149
|
+
onMoveColumn: _propTypes.default.func,
|
|
150
|
+
onOpenDetails: _propTypes.default.func,
|
|
151
|
+
onToggleHideColumn: _propTypes.default.func,
|
|
152
|
+
className: _propTypes.default.string
|
|
153
|
+
};
|
|
115
154
|
var _default = TableSettingsListItem;
|
|
116
155
|
exports.default = _default;
|
|
@@ -9,17 +9,11 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
9
9
|
});
|
|
10
10
|
exports.default = void 0;
|
|
11
11
|
|
|
12
|
-
var
|
|
12
|
+
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
13
13
|
|
|
14
|
-
var
|
|
14
|
+
var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
|
|
15
15
|
|
|
16
|
-
var
|
|
17
|
-
|
|
18
|
-
var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits"));
|
|
19
|
-
|
|
20
|
-
var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));
|
|
21
|
-
|
|
22
|
-
var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));
|
|
16
|
+
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
|
23
17
|
|
|
24
18
|
var _react = _interopRequireWildcard(require("react"));
|
|
25
19
|
|
|
@@ -27,106 +21,103 @@ var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
|
27
21
|
|
|
28
22
|
var _classnames = _interopRequireDefault(require("classnames"));
|
|
29
23
|
|
|
30
|
-
|
|
24
|
+
var _OverlayTrigger = _interopRequireDefault(require("../overlay/OverlayTrigger"));
|
|
31
25
|
|
|
32
|
-
|
|
26
|
+
var _Tooltip = _interopRequireDefault(require("../tooltip/Tooltip"));
|
|
27
|
+
|
|
28
|
+
var _excluded = ["viewType", "initialViewType", "onViewTypeChange", "className", "disabledViewTypes", "disabled", "tableViewTooltipContent", "singleCardViewTooltipContent", "multiCardsViewTooltipContent"];
|
|
33
29
|
|
|
34
|
-
function
|
|
30
|
+
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); }
|
|
35
31
|
|
|
36
|
-
function
|
|
32
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
37
33
|
|
|
38
34
|
// TODO: add responsive behaviour and trigger a change from table to list for small screen -> see DriverAdministration
|
|
39
|
-
var
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
value: function handleSetTableView() {
|
|
71
|
-
this.setState({
|
|
72
|
-
viewType: TableViewToggles.VIEW_TYPE_TABLE
|
|
73
|
-
});
|
|
74
|
-
this.props.onViewTypeChange(TableViewToggles.VIEW_TYPE_TABLE);
|
|
75
|
-
}
|
|
76
|
-
}, {
|
|
77
|
-
key: "handleSetSingleCardsView",
|
|
78
|
-
value: function handleSetSingleCardsView() {
|
|
79
|
-
this.setState({
|
|
80
|
-
viewType: TableViewToggles.VIEW_TYPE_SINGLE_CARD
|
|
81
|
-
});
|
|
82
|
-
this.props.onViewTypeChange(TableViewToggles.VIEW_TYPE_SINGLE_CARD);
|
|
83
|
-
}
|
|
84
|
-
}, {
|
|
85
|
-
key: "handleSetMultiCardsView",
|
|
86
|
-
value: function handleSetMultiCardsView() {
|
|
87
|
-
this.setState({
|
|
88
|
-
viewType: TableViewToggles.VIEW_TYPE_MULTI_CARDS
|
|
89
|
-
});
|
|
90
|
-
this.props.onViewTypeChange(TableViewToggles.VIEW_TYPE_MULTI_CARDS);
|
|
91
|
-
}
|
|
92
|
-
}, {
|
|
93
|
-
key: "render",
|
|
94
|
-
value: function render() {
|
|
95
|
-
var viewType = this.state.viewType;
|
|
96
|
-
var _this$props = this.props,
|
|
97
|
-
className = _this$props.className,
|
|
98
|
-
disabledViewTypes = _this$props.disabledViewTypes,
|
|
99
|
-
disabled = _this$props.disabled;
|
|
100
|
-
var wrapperClassNames = (0, _classnames.default)('TableViewToggles', 'btn-group', 'display-flex', 'flex-row', className && className);
|
|
101
|
-
var buttonClassNames = (0, _classnames.default)('btn btn-default btn-icon-only', disabled && 'disabled pointer-events-none');
|
|
102
|
-
var tableViewActiveClasses = (0, _classnames.default)(buttonClassNames, viewType === TableViewToggles.VIEW_TYPE_TABLE && 'active');
|
|
103
|
-
var cardViewActiveClasses = (0, _classnames.default)(buttonClassNames, viewType === TableViewToggles.VIEW_TYPE_SINGLE_CARD && 'active');
|
|
104
|
-
var multiCardsViewActiveClasses = (0, _classnames.default)(buttonClassNames, viewType === TableViewToggles.VIEW_TYPE_MULTI_CARDS && 'active');
|
|
105
|
-
return /*#__PURE__*/_react.default.createElement("div", {
|
|
106
|
-
className: wrapperClassNames
|
|
107
|
-
}, !disabledViewTypes.includes(TableViewToggles.VIEW_TYPE_TABLE) && /*#__PURE__*/_react.default.createElement("button", {
|
|
108
|
-
className: tableViewActiveClasses,
|
|
109
|
-
type: "button",
|
|
110
|
-
onClick: this.handleSetTableView
|
|
111
|
-
}, /*#__PURE__*/_react.default.createElement("span", {
|
|
112
|
-
className: "rioglyph rioglyph-table-view"
|
|
113
|
-
})), !disabledViewTypes.includes(TableViewToggles.VIEW_TYPE_SINGLE_CARD) && /*#__PURE__*/_react.default.createElement("button", {
|
|
114
|
-
className: cardViewActiveClasses,
|
|
115
|
-
type: "button",
|
|
116
|
-
onClick: this.handleSetSingleCardsView
|
|
117
|
-
}, /*#__PURE__*/_react.default.createElement("span", {
|
|
118
|
-
className: "rioglyph rioglyph-th-list"
|
|
119
|
-
})), !disabledViewTypes.includes(TableViewToggles.VIEW_TYPE_MULTI_CARDS) && /*#__PURE__*/_react.default.createElement("button", {
|
|
120
|
-
className: multiCardsViewActiveClasses,
|
|
121
|
-
type: "button",
|
|
122
|
-
onClick: this.handleSetMultiCardsView
|
|
123
|
-
}, /*#__PURE__*/_react.default.createElement("span", {
|
|
124
|
-
className: "rioglyph rioglyph-split-view"
|
|
125
|
-
})));
|
|
35
|
+
var wrapWithTooltip = function wrapWithTooltip(tooltipContent, element) {
|
|
36
|
+
return /*#__PURE__*/_react.default.createElement(_OverlayTrigger.default, {
|
|
37
|
+
placement: "bottom",
|
|
38
|
+
overlay: /*#__PURE__*/_react.default.createElement(_Tooltip.default, {
|
|
39
|
+
id: "tooltip",
|
|
40
|
+
allowOnTouch: true
|
|
41
|
+
}, tooltipContent)
|
|
42
|
+
}, element);
|
|
43
|
+
};
|
|
44
|
+
|
|
45
|
+
var TableViewToggles = function TableViewToggles(props) {
|
|
46
|
+
var viewType = props.viewType,
|
|
47
|
+
initialViewType = props.initialViewType,
|
|
48
|
+
onViewTypeChange = props.onViewTypeChange,
|
|
49
|
+
className = props.className,
|
|
50
|
+
disabledViewTypes = props.disabledViewTypes,
|
|
51
|
+
disabled = props.disabled,
|
|
52
|
+
tableViewTooltipContent = props.tableViewTooltipContent,
|
|
53
|
+
singleCardViewTooltipContent = props.singleCardViewTooltipContent,
|
|
54
|
+
multiCardsViewTooltipContent = props.multiCardsViewTooltipContent,
|
|
55
|
+
remainingProps = (0, _objectWithoutProperties2.default)(props, _excluded);
|
|
56
|
+
|
|
57
|
+
var _useState = (0, _react.useState)(initialViewType),
|
|
58
|
+
_useState2 = (0, _slicedToArray2.default)(_useState, 2),
|
|
59
|
+
internaViewType = _useState2[0],
|
|
60
|
+
setInternalViewType = _useState2[1]; // update internal state when external state changes - controlled component case
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
(0, _react.useEffect)(function () {
|
|
64
|
+
if (viewType) {
|
|
65
|
+
setInternalViewType(viewType);
|
|
126
66
|
}
|
|
127
|
-
}]);
|
|
128
|
-
|
|
129
|
-
|
|
67
|
+
}, [viewType]);
|
|
68
|
+
|
|
69
|
+
var handleSetTableView = function handleSetTableView() {
|
|
70
|
+
setInternalViewType(TableViewToggles.VIEW_TYPE_TABLE);
|
|
71
|
+
onViewTypeChange(TableViewToggles.VIEW_TYPE_TABLE);
|
|
72
|
+
};
|
|
73
|
+
|
|
74
|
+
var handleSetSingleCardsView = function handleSetSingleCardsView() {
|
|
75
|
+
setInternalViewType(TableViewToggles.VIEW_TYPE_SINGLE_CARD);
|
|
76
|
+
onViewTypeChange(TableViewToggles.VIEW_TYPE_SINGLE_CARD);
|
|
77
|
+
};
|
|
78
|
+
|
|
79
|
+
var handleSetMultiCardsView = function handleSetMultiCardsView() {
|
|
80
|
+
setInternalViewType(TableViewToggles.VIEW_TYPE_MULTI_CARDS);
|
|
81
|
+
onViewTypeChange(TableViewToggles.VIEW_TYPE_MULTI_CARDS);
|
|
82
|
+
};
|
|
83
|
+
|
|
84
|
+
var wrapperClassNames = (0, _classnames.default)('TableViewToggles', 'btn-group', 'display-flex', 'flex-row', className && className);
|
|
85
|
+
var buttonClassNames = (0, _classnames.default)('btn btn-default btn-icon-only', disabled && 'disabled pointer-events-none');
|
|
86
|
+
var tableViewActiveClasses = (0, _classnames.default)(buttonClassNames, internaViewType === TableViewToggles.VIEW_TYPE_TABLE && 'active');
|
|
87
|
+
var cardViewActiveClasses = (0, _classnames.default)(buttonClassNames, internaViewType === TableViewToggles.VIEW_TYPE_SINGLE_CARD && 'active');
|
|
88
|
+
var multiCardsViewActiveClasses = (0, _classnames.default)(buttonClassNames, internaViewType === TableViewToggles.VIEW_TYPE_MULTI_CARDS && 'active');
|
|
89
|
+
|
|
90
|
+
var tableViewButton = /*#__PURE__*/_react.default.createElement("button", {
|
|
91
|
+
className: tableViewActiveClasses,
|
|
92
|
+
type: "button",
|
|
93
|
+
onClick: handleSetTableView
|
|
94
|
+
}, /*#__PURE__*/_react.default.createElement("span", {
|
|
95
|
+
className: "rioglyph rioglyph-table-view"
|
|
96
|
+
}));
|
|
97
|
+
|
|
98
|
+
var singleCardViewButton = /*#__PURE__*/_react.default.createElement("button", {
|
|
99
|
+
className: cardViewActiveClasses,
|
|
100
|
+
type: "button",
|
|
101
|
+
onClick: handleSetSingleCardsView
|
|
102
|
+
}, /*#__PURE__*/_react.default.createElement("span", {
|
|
103
|
+
className: "rioglyph rioglyph-th-list"
|
|
104
|
+
}));
|
|
105
|
+
|
|
106
|
+
var multiCardViewButton = /*#__PURE__*/_react.default.createElement("button", {
|
|
107
|
+
className: multiCardsViewActiveClasses,
|
|
108
|
+
type: "button",
|
|
109
|
+
onClick: handleSetMultiCardsView
|
|
110
|
+
}, /*#__PURE__*/_react.default.createElement("span", {
|
|
111
|
+
className: "rioglyph rioglyph-split-view"
|
|
112
|
+
}));
|
|
113
|
+
|
|
114
|
+
var showTableViewButton = !disabledViewTypes.includes(TableViewToggles.VIEW_TYPE_TABLE);
|
|
115
|
+
var showSingleCardViewButton = !disabledViewTypes.includes(TableViewToggles.VIEW_TYPE_SINGLE_CARD);
|
|
116
|
+
var showMultiCardViewButton = !disabledViewTypes.includes(TableViewToggles.VIEW_TYPE_MULTI_CARDS);
|
|
117
|
+
return /*#__PURE__*/_react.default.createElement("div", (0, _extends2.default)({}, remainingProps, {
|
|
118
|
+
className: wrapperClassNames
|
|
119
|
+
}), showTableViewButton && (tableViewTooltipContent ? wrapWithTooltip(tableViewTooltipContent, tableViewButton) : tableViewButton), showSingleCardViewButton && (singleCardViewTooltipContent ? wrapWithTooltip(singleCardViewTooltipContent, singleCardViewButton) : singleCardViewButton), showMultiCardViewButton && (multiCardsViewTooltipContent ? wrapWithTooltip(multiCardsViewTooltipContent, multiCardViewButton) : multiCardViewButton));
|
|
120
|
+
};
|
|
130
121
|
|
|
131
122
|
TableViewToggles.VIEW_TYPE_TABLE = 'TABLE';
|
|
132
123
|
TableViewToggles.VIEW_TYPE_SINGLE_CARD = 'SINGLE_CARD';
|
|
@@ -143,7 +134,10 @@ TableViewToggles.propTypes = {
|
|
|
143
134
|
disabledViewTypes: _propTypes.default.arrayOf(_propTypes.default.oneOf([TableViewToggles.VIEW_TYPE_TABLE, TableViewToggles.VIEW_TYPE_SINGLE_CARD, TableViewToggles.VIEW_TYPE_MULTI_CARDS])),
|
|
144
135
|
onViewTypeChange: _propTypes.default.func,
|
|
145
136
|
disabled: _propTypes.default.bool,
|
|
146
|
-
className: _propTypes.default.string
|
|
137
|
+
className: _propTypes.default.string,
|
|
138
|
+
tableViewTooltipContent: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.node]),
|
|
139
|
+
singleCardViewTooltipContent: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.node]),
|
|
140
|
+
multiCardsViewTooltipContent: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.node])
|
|
147
141
|
};
|
|
148
142
|
var _default = TableViewToggles;
|
|
149
143
|
exports.default = _default;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports.columnsDetailsPropTypes = void 0;
|
|
9
|
+
|
|
10
|
+
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
11
|
+
|
|
12
|
+
var columnsDetailsPropTypes = _propTypes.default.objectOf(_propTypes.default.shape({
|
|
13
|
+
width: _propTypes.default.number,
|
|
14
|
+
defaultWidth: _propTypes.default.number,
|
|
15
|
+
maxWidth: _propTypes.default.number
|
|
16
|
+
}));
|
|
17
|
+
|
|
18
|
+
exports.columnsDetailsPropTypes = columnsDetailsPropTypes;
|
|
@@ -33,7 +33,6 @@
|
|
|
33
33
|
@import (less) '../design/type.less';
|
|
34
34
|
@import (less) '../design/popovers.less';
|
|
35
35
|
@import (less) '../design/utilities.less';
|
|
36
|
-
@import (less) '../design/visibilty.less';
|
|
37
36
|
@import (less) '../design/blockquote.less';
|
|
38
37
|
@import (less) '../design/callouts.less';
|
|
39
38
|
@import (less) '../design/container.less';
|
|
@@ -50,8 +49,10 @@
|
|
|
50
49
|
@import (less) '../design/overflow.less';
|
|
51
50
|
@import (less) '../design/position.less';
|
|
52
51
|
@import (less) '../design/rounded.less';
|
|
52
|
+
@import (less) '../design/sizing.less';
|
|
53
53
|
@import (less) '../design/shadows.less';
|
|
54
54
|
@import (less) '../design/text.less';
|
|
55
|
+
@import (less) '../design/visibility.less';
|
|
55
56
|
@import (less) '../design/z-index.less';
|
|
56
57
|
|
|
57
58
|
// Theme
|
|
@@ -64,6 +65,9 @@
|
|
|
64
65
|
// Animations
|
|
65
66
|
@import (less) '../animations/_imports.less';
|
|
66
67
|
|
|
68
|
+
// Filter
|
|
69
|
+
@import (less) '../filter/_imports.less';
|
|
70
|
+
|
|
67
71
|
// Print
|
|
68
72
|
@import (less) '../print/print.less';
|
|
69
73
|
|
|
@@ -2084,7 +2084,7 @@ form[id*="contactForm"] {
|
|
|
2084
2084
|
// Safari image fix
|
|
2085
2085
|
@media not all and (min-resolution:.001dpcm) {
|
|
2086
2086
|
@supports (-webkit-appearance:none) {
|
|
2087
|
-
img[src*="placeholder_transparent"] {
|
|
2087
|
+
img[src*="placeholder_transparent"]:not([style*="background-image"]) {
|
|
2088
2088
|
opacity: 0;
|
|
2089
2089
|
}
|
|
2090
2090
|
|
|
@@ -2097,7 +2097,6 @@ form[id*="contactForm"] {
|
|
|
2097
2097
|
}
|
|
2098
2098
|
|
|
2099
2099
|
// section clippig
|
|
2100
|
-
|
|
2101
2100
|
.section-wrapper {
|
|
2102
2101
|
&[class*="clip-"]:after {
|
|
2103
2102
|
content: "";
|
|
@@ -266,7 +266,7 @@
|
|
|
266
266
|
max-height: ~'calc(100vh - @{navbar-height} - 20px)'; // --vh fallback
|
|
267
267
|
max-height: ~'calc(var(--vh, 1vh) * 100 - @{navbar-height} - 20px)';
|
|
268
268
|
max-width: calc(~'100% - 3px');
|
|
269
|
-
|
|
269
|
+
width: 100%;
|
|
270
270
|
overflow-x: hidden;
|
|
271
271
|
overflow-y: auto;
|
|
272
272
|
|
|
@@ -167,12 +167,12 @@
|
|
|
167
167
|
top: 0;
|
|
168
168
|
|
|
169
169
|
.ApplicationLayoutSidebar:not(.right) & {
|
|
170
|
-
box-shadow: 5px 5px 5px asset-
|
|
170
|
+
box-shadow: 5px 5px 5px @asset-tree-shadow-color;
|
|
171
171
|
left: 0;
|
|
172
172
|
}
|
|
173
173
|
|
|
174
174
|
.ApplicationLayoutSidebar.right & {
|
|
175
|
-
box-shadow: -5px 5px 5px asset-
|
|
175
|
+
box-shadow: -5px 5px 5px @asset-tree-shadow-color;
|
|
176
176
|
right: 0;
|
|
177
177
|
}
|
|
178
178
|
}
|
|
@@ -344,18 +344,20 @@ body {
|
|
|
344
344
|
}
|
|
345
345
|
|
|
346
346
|
&.TableSettingsDialog {
|
|
347
|
-
.modal-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
347
|
+
.modal-dialog {
|
|
348
|
+
.modal-content {
|
|
349
|
+
.modal-body {
|
|
350
|
+
background: @gray-lightest;
|
|
351
|
+
padding-left: 0;
|
|
352
|
+
padding-right: 0;
|
|
353
|
+
|
|
354
|
+
@media (max-height: 450px) and (min-width: @screen-sm - 0.1) {
|
|
355
|
+
max-height: calc(~'100vh - 200px'); // --vh fallback
|
|
356
|
+
max-height: calc(~'var(--vh, 1vh) * 100 - 200px');
|
|
357
|
+
overflow-y: auto;
|
|
358
|
+
}
|
|
359
|
+
}
|
|
356
360
|
}
|
|
357
|
-
|
|
358
|
-
// TableSettings item styles are colocated with the components
|
|
359
361
|
}
|
|
360
362
|
}
|
|
361
363
|
}
|
|
@@ -219,43 +219,4 @@
|
|
|
219
219
|
margin-right: 10px;
|
|
220
220
|
}
|
|
221
221
|
}
|
|
222
|
-
}
|
|
223
|
-
|
|
224
|
-
// Tippy
|
|
225
|
-
.tippy-touch {
|
|
226
|
-
cursor: pointer !important
|
|
227
|
-
}
|
|
228
|
-
|
|
229
|
-
.tippy-popper {
|
|
230
|
-
-webkit-perspective: 800px;
|
|
231
|
-
max-width: 400px;
|
|
232
|
-
outline: 0;
|
|
233
|
-
perspective: 800px;
|
|
234
|
-
pointer-events: none;
|
|
235
|
-
transition-timing-function: cubic-bezier(.165, .84, .44, 1);
|
|
236
|
-
z-index: 9999;
|
|
237
|
-
}
|
|
238
|
-
|
|
239
|
-
.tippy-popper.html-template {
|
|
240
|
-
max-width: 96%;
|
|
241
|
-
max-width: calc(100% - 20px)
|
|
242
|
-
}
|
|
243
|
-
|
|
244
|
-
.tippy-tooltip {
|
|
245
|
-
position: relative;
|
|
246
|
-
color: #fff;
|
|
247
|
-
border-radius: 4px;
|
|
248
|
-
font-size: .95rem;
|
|
249
|
-
padding: .4rem .8rem;
|
|
250
|
-
text-align: center;
|
|
251
|
-
will-change: transform;
|
|
252
|
-
-webkit-font-smoothing: antialiased;
|
|
253
|
-
-moz-osx-font-smoothing: grayscale;
|
|
254
|
-
background-color: #333
|
|
255
|
-
}
|
|
256
|
-
|
|
257
|
-
.tippy-tooltip [x-arrow] {
|
|
258
|
-
position: absolute;
|
|
259
|
-
width: 0;
|
|
260
|
-
height: 0
|
|
261
222
|
}
|
|
@@ -13,11 +13,16 @@
|
|
|
13
13
|
transition: all 70ms ease-in-out;
|
|
14
14
|
|
|
15
15
|
&:first-child {
|
|
16
|
-
.
|
|
16
|
+
&:not(.rounded-none) {
|
|
17
|
+
.border-top-radius(@border-radius-default);
|
|
18
|
+
}
|
|
17
19
|
}
|
|
18
20
|
|
|
19
21
|
&:last-child {
|
|
20
|
-
.
|
|
22
|
+
&:not(.rounded-none) {
|
|
23
|
+
.border-bottom-radius(@border-radius-default);
|
|
24
|
+
}
|
|
25
|
+
|
|
21
26
|
margin-bottom: 0;
|
|
22
27
|
}
|
|
23
28
|
|