@vitrosoftware/common-ui-ts 1.1.244 → 1.1.246
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/dist/index.js +24 -9
- package/dist/index.js.map +1 -1
- package/dist/src/controls/LookupPicker/LookupPicker.d.ts +1 -0
- package/dist/src/controls/LookupPicker/SelectedValueList.d.ts +1 -0
- package/dist/src/controls/LookupPicker/SelectedValueListItem.d.ts +1 -0
- package/dist/src/index.d.ts +2 -0
- package/package.json +1 -1
- package/src/controls/BimViewer/js/bim-viewer.js +2 -2
- package/src/controls/DxfViewer/js/dxf-viewer.js +15 -15
- package/src/controls/PdfViewer/js/pdf-viewer.js +1 -1
package/dist/index.js
CHANGED
|
@@ -60939,6 +60939,10 @@ var ActionHandler = function ActionHandler(props) {
|
|
|
60939
60939
|
onClose();
|
|
60940
60940
|
};
|
|
60941
60941
|
var onError = function onError(error) {
|
|
60942
|
+
if (error instanceof AbortExceptionImpl) {
|
|
60943
|
+
onCancel();
|
|
60944
|
+
return null;
|
|
60945
|
+
}
|
|
60942
60946
|
if (props.onError) {
|
|
60943
60947
|
var res = props.onError(error);
|
|
60944
60948
|
if (res.abort) {
|
|
@@ -61727,7 +61731,7 @@ var TabButtonGroup = function TabButtonGroup(props) {
|
|
|
61727
61731
|
var _ref$current;
|
|
61728
61732
|
resizeTimeout.id = null;
|
|
61729
61733
|
setWidth(((_ref$current = ref.current) === null || _ref$current === void 0 ? void 0 : _ref$current.offsetWidth) || 0);
|
|
61730
|
-
},
|
|
61734
|
+
}, 10);
|
|
61731
61735
|
}
|
|
61732
61736
|
}
|
|
61733
61737
|
}
|
|
@@ -61740,7 +61744,7 @@ var TabButtonGroup = function TabButtonGroup(props) {
|
|
|
61740
61744
|
}
|
|
61741
61745
|
}, [width]);
|
|
61742
61746
|
var getOverflowIndex = function getOverflowIndex(width) {
|
|
61743
|
-
var scrollWidth = (activeItemTabBtn === null || activeItemTabBtn === void 0 ? void 0 : activeItemTabBtn.width) || 0;
|
|
61747
|
+
var scrollWidth = ((activeItemTabBtn === null || activeItemTabBtn === void 0 ? void 0 : activeItemTabBtn.width) || 0) + 32;
|
|
61744
61748
|
for (var _iterator2 = _createForOfIteratorHelperLoose(tabList.entries()), _step2; !(_step2 = _iterator2()).done;) {
|
|
61745
61749
|
var _step2$value = _step2.value,
|
|
61746
61750
|
index = _step2$value[0],
|
|
@@ -63239,6 +63243,9 @@ var styles$N = {"vitro-lookup-picker":"_lookup-picker_vitro-lookup-picker_1aXYQE
|
|
|
63239
63243
|
var htmlValueStyles = {"vitro-item-html-value":"_lookup-picker-html-value_vitro-item-html-value_2QBoTey"};
|
|
63240
63244
|
|
|
63241
63245
|
var SelectedValueListItem = function SelectedValueListItem(props) {
|
|
63246
|
+
var _useState = React.useState(),
|
|
63247
|
+
htmlValue = _useState[0],
|
|
63248
|
+
setHtmlValue = _useState[1];
|
|
63242
63249
|
var className = props.isMultiSelect ? styles$M['vitro-selected-item-multi'] : styles$M['vitro-selected-item'];
|
|
63243
63250
|
var title = props.selectedValueTemplate(props.item);
|
|
63244
63251
|
var ref = React.useRef(null);
|
|
@@ -63252,6 +63259,11 @@ var SelectedValueListItem = function SelectedValueListItem(props) {
|
|
|
63252
63259
|
}
|
|
63253
63260
|
}
|
|
63254
63261
|
}, [props.isValueListVisible]);
|
|
63262
|
+
React.useEffect(function () {
|
|
63263
|
+
if (props.getHtmlValue) {
|
|
63264
|
+
setHtmlValue(props.getHtmlValue(props.item));
|
|
63265
|
+
}
|
|
63266
|
+
}, [props.item]);
|
|
63255
63267
|
return React__default.createElement(ValueTooltip, {
|
|
63256
63268
|
ref: valueTooltipRef,
|
|
63257
63269
|
containerRef: ref,
|
|
@@ -63262,9 +63274,9 @@ var SelectedValueListItem = function SelectedValueListItem(props) {
|
|
|
63262
63274
|
}, React__default.createElement("div", {
|
|
63263
63275
|
ref: ref,
|
|
63264
63276
|
className: className
|
|
63265
|
-
},
|
|
63277
|
+
}, htmlValue ? React__default.createElement(FlexBox, {
|
|
63266
63278
|
className: htmlValueStyles['vitro-item-html-value']
|
|
63267
|
-
},
|
|
63279
|
+
}, htmlValue) : null, props.isTitleVisible && React__default.createElement("span", null, title), props.isMultiSelect && !props.isReadOnly && React__default.createElement(ImageButton, {
|
|
63268
63280
|
onClick: function onClick() {
|
|
63269
63281
|
return props.onOptionValueDelete(props.item.id);
|
|
63270
63282
|
},
|
|
@@ -63282,7 +63294,8 @@ var SelectedValueList = function SelectedValueList(props) {
|
|
|
63282
63294
|
isValueListVisible: props.isValueListVisible,
|
|
63283
63295
|
selectedValueTemplate: props.selectedValueTemplate,
|
|
63284
63296
|
onOptionValueDelete: props.onOptionValueDelete,
|
|
63285
|
-
getHtmlValue: props.getHtmlValue
|
|
63297
|
+
getHtmlValue: props.getHtmlValue,
|
|
63298
|
+
isTitleVisible: props.isValueTitleVisible !== false
|
|
63286
63299
|
});
|
|
63287
63300
|
}));
|
|
63288
63301
|
};
|
|
@@ -63530,7 +63543,7 @@ var LookupPicker = React.forwardRef(function (props, ref) {
|
|
|
63530
63543
|
updatePending(props.valueList);
|
|
63531
63544
|
}, [props.valueList]);
|
|
63532
63545
|
React.useEffect(function () {
|
|
63533
|
-
if (props.selectedValueList) {
|
|
63546
|
+
if (props.selectedValueList && checkIsValueChanged(selectedValueList, props.selectedValueList)) {
|
|
63534
63547
|
setSelectedValueList(props.selectedValueList);
|
|
63535
63548
|
}
|
|
63536
63549
|
}, [props.selectedValueList]);
|
|
@@ -63678,7 +63691,7 @@ var LookupPicker = React.forwardRef(function (props, ref) {
|
|
|
63678
63691
|
if (isValueChanged) {
|
|
63679
63692
|
setSelectedValueList(newValueList);
|
|
63680
63693
|
setInputValue(CTRL.EMPTY);
|
|
63681
|
-
props.onChange && props.onChange(props.isMultiSelect ?
|
|
63694
|
+
props.onChange && props.onChange(props.isMultiSelect ? newValueList : selectedValue, props.name);
|
|
63682
63695
|
}
|
|
63683
63696
|
if (props.isMultiSelect) {
|
|
63684
63697
|
inputRef && inputRef.current && inputRef.current.focus();
|
|
@@ -63818,7 +63831,8 @@ var LookupPicker = React.forwardRef(function (props, ref) {
|
|
|
63818
63831
|
isMultiSelect: props.isMultiSelect,
|
|
63819
63832
|
isReadOnly: props.isReadOnly,
|
|
63820
63833
|
isValueListVisible: valueListVisible,
|
|
63821
|
-
getHtmlValue: getHtmlValue
|
|
63834
|
+
getHtmlValue: getHtmlValue,
|
|
63835
|
+
isValueTitleVisible: props.isValueTitleVisible
|
|
63822
63836
|
}) : !valueListVisible && props.placeholder && React__default.createElement("div", {
|
|
63823
63837
|
className: styles$N['vitro-placeholder']
|
|
63824
63838
|
}, props.placeholder), isEditable && React__default.createElement("input", {
|
|
@@ -66977,7 +66991,7 @@ var Viewer = function Viewer(props) {
|
|
|
66977
66991
|
};
|
|
66978
66992
|
|
|
66979
66993
|
var name = "@vitrosoftware/common-ui-ts";
|
|
66980
|
-
var version$1 = "1.1.
|
|
66994
|
+
var version$1 = "1.1.246";
|
|
66981
66995
|
var description = "vitro software common ui ts";
|
|
66982
66996
|
var author = "";
|
|
66983
66997
|
var license = "MIT";
|
|
@@ -86175,6 +86189,7 @@ var Icon = function Icon(props) {
|
|
|
86175
86189
|
|
|
86176
86190
|
exports.ACTION_HANDLER = ActionHandlerConstants;
|
|
86177
86191
|
exports.ALERT = AlertConstants;
|
|
86192
|
+
exports.AbortExceptionImpl = AbortExceptionImpl;
|
|
86178
86193
|
exports.ActionHandler = ActionHandler;
|
|
86179
86194
|
exports.Activity = Activity;
|
|
86180
86195
|
exports.ActivityItem = ActivityItem;
|