@vitrosoftware/common-ui-ts 1.1.250 → 1.1.252

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.
@@ -119,4 +119,8 @@
119
119
  top: 0;
120
120
  opacity: 0.5;
121
121
  cursor: initial;
122
+ }
123
+
124
+ .vitro-progress-container {
125
+ height: 88px;
122
126
  }
@@ -25,16 +25,17 @@
25
25
  color: #222D44 !important;
26
26
  }
27
27
 
28
- .TWMain .TWDateLeft,
29
- .TWMain .TWDatesLeft,
30
- .TWMain .TWDateRight,
28
+ .TWMain .TWDateLeft,
29
+ .TWMain .TWDatesLeft,
30
+ .TWMain .TWDateRight,
31
31
  .TWMain .TWDatesRight,
32
- .TWMain .TWDateTop,
33
- .TWMain .TWDatesTop,
34
- .TWMain .TWDateBottom,
32
+ .TWMain .TWDateTop,
33
+ .TWMain .TWDatesTop,
34
+ .TWMain .TWDateBottom,
35
35
  .TWMain .TWDatesBottom {
36
36
  background-image: url('@vitrosoftware/common-ui-ts/css/std/controls/table-view/img/date-picker.svg');
37
37
  background-size: 24px;
38
+ background-position: center;
38
39
  }
39
40
 
40
41
  .vitro-table-view-gantt .TWMain .TWDateLeft,
@@ -46,4 +47,5 @@
46
47
  .vitro-table-view-gantt .TWMain .TWDateBottom,
47
48
  .vitro-table-view-gantt .TWMain .TWDatesBottom {
48
49
  background-size: 20px;
50
+ background-position: center;
49
51
  }
@@ -79,7 +79,7 @@
79
79
  height: 24px;
80
80
  width: 24px;
81
81
  min-width: 24px;
82
- margin-left: -2px;
82
+ margin-left: -8px;
83
83
  display: none;
84
84
  cursor: default;
85
85
  }
@@ -1,7 +1,7 @@
1
1
  .TWCellHeader {
2
2
  font-family: "InterMedium" !important;
3
3
  background: #F7F9FC;
4
- padding: 4px 8px !important;
4
+ padding: 4px 0 4px 8px !important;
5
5
  }
6
6
 
7
7
  .TWClassHoveredCellHeader {
@@ -2,10 +2,8 @@
2
2
  .TWSort2Left, .TWSort2Right,
3
3
  .TWSort3Left, .TWSort3Right {
4
4
  background-repeat: no-repeat !important;
5
- height: 24px !important;
6
- width: 24px !important;
7
- background-size: 100% !important;
8
- background-position: center !important;
5
+ background-size: 24px !important;
6
+ background-position: -8px 0 !important;
9
7
  background-image: url('@vitrosoftware/common-ui-ts/css/std/controls/table-view/img/sort-top.svg');
10
8
  }
11
9
 
@@ -13,10 +11,8 @@
13
11
  .TWSort5Left, .TWSort5Right,
14
12
  .TWSort6Left, .TWSort6Right {
15
13
  background-repeat: no-repeat !important;
16
- height: 24px !important;
17
- width: 24px !important;
18
- background-size: 100% !important;
19
- background-position: center !important;
14
+ background-size: 24px !important;
15
+ background-position: -8px 0 !important;
20
16
  background-image: url('@vitrosoftware/common-ui-ts/css/std/controls/table-view/img/sort-bottom.svg');
21
17
  }
22
18
 
package/dist/index.css CHANGED
@@ -771,7 +771,7 @@ body em {
771
771
  height: 24px;
772
772
  width: 24px;
773
773
  min-width: 24px;
774
- margin-left: -2px;
774
+ margin-left: -8px;
775
775
  display: none;
776
776
  cursor: default;
777
777
  }
@@ -4474,6 +4474,10 @@ div._component-loader_vitro-component-loader_3J3a2or {
4474
4474
  top: 0;
4475
4475
  opacity: 0.5;
4476
4476
  cursor: initial;
4477
+ }
4478
+
4479
+ ._lookup-picker-value-list_vitro-progress-container_1wyhOOF {
4480
+ height: 88px;
4477
4481
  }
4478
4482
  ._error-message_vitro-error-message_2lHJjgO {
4479
4483
  display: inline-block;
package/dist/index.js CHANGED
@@ -21908,6 +21908,9 @@ var TableViewServiceImpl = /*#__PURE__*/function () {
21908
21908
  }
21909
21909
  return lastCol;
21910
21910
  };
21911
+ _proto.calcWidth = function calcWidth(col) {
21912
+ this.grid.CalcWidth(col);
21913
+ };
21911
21914
  return _createClass(TableViewServiceImpl, [{
21912
21915
  key: "columnList",
21913
21916
  get: function get() {
@@ -63570,7 +63573,7 @@ var SelectedValueList = function SelectedValueList(props) {
63570
63573
  }));
63571
63574
  };
63572
63575
 
63573
- var valueListStyles = {"vitro-value-list":"_lookup-picker-value-list_vitro-value-list_LSdCMjq","vitro-item":"_lookup-picker-value-list_vitro-item_7yZBz5u","vitro-item-html-value":"_lookup-picker-value-list_vitro-item-html-value_1yl9tXx","vitro-placeholder-empty":"_lookup-picker-value-list_vitro-placeholder-empty_fTVHWwc","vitro-keyword-highlight":"_lookup-picker-value-list_vitro-keyword-highlight_1uESHan","vitro-display-none":"_lookup-picker-value-list_vitro-display-none_2kDzC6K","vitro-flex":"_lookup-picker-value-list_vitro-flex_2ClzE5b","vitro-button":"_lookup-picker-value-list_vitro-button_3MejXb_","vitro-disabled":"_lookup-picker-value-list_vitro-disabled_11rNtMo"};
63576
+ var valueListStyles = {"vitro-value-list":"_lookup-picker-value-list_vitro-value-list_LSdCMjq","vitro-item":"_lookup-picker-value-list_vitro-item_7yZBz5u","vitro-item-html-value":"_lookup-picker-value-list_vitro-item-html-value_1yl9tXx","vitro-placeholder-empty":"_lookup-picker-value-list_vitro-placeholder-empty_fTVHWwc","vitro-keyword-highlight":"_lookup-picker-value-list_vitro-keyword-highlight_1uESHan","vitro-display-none":"_lookup-picker-value-list_vitro-display-none_2kDzC6K","vitro-flex":"_lookup-picker-value-list_vitro-flex_2ClzE5b","vitro-button":"_lookup-picker-value-list_vitro-button_3MejXb_","vitro-disabled":"_lookup-picker-value-list_vitro-disabled_11rNtMo","vitro-progress-container":"_lookup-picker-value-list_vitro-progress-container_1wyhOOF"};
63574
63577
 
63575
63578
  var ValueListItem = function ValueListItem(props) {
63576
63579
  var isDisabled = props.item.isEnabled === false;
@@ -63610,7 +63613,23 @@ var ValueList = function ValueList(props) {
63610
63613
  var _useState2 = React.useState(null),
63611
63614
  style = _useState2[0],
63612
63615
  setStyle = _useState2[1];
63616
+ var _useState3 = React.useState(false),
63617
+ isProgressVisible = _useState3[0],
63618
+ setIsProgressVisible = _useState3[1];
63613
63619
  var reg = new RegExp(props.inputValue.replace(PATTERN, REPLACEMENT), FLAG);
63620
+ React.useEffect(function () {
63621
+ var timer;
63622
+ if (props.isPending) {
63623
+ timer = setTimeout(function () {
63624
+ return setIsProgressVisible(true);
63625
+ }, 400);
63626
+ } else {
63627
+ setIsProgressVisible(false);
63628
+ }
63629
+ return function () {
63630
+ return clearTimeout(timer);
63631
+ };
63632
+ }, [props.isPending]);
63614
63633
  React.useEffect(function () {
63615
63634
  if (scrollableElement && scrollableElement.scrollTop === 0) {
63616
63635
  scrollableElement.scrollTop = 1;
@@ -63666,7 +63685,9 @@ var ValueList = function ValueList(props) {
63666
63685
  }, React__default.createElement(ScrollBar, {
63667
63686
  onInit: setScrollableElement,
63668
63687
  isPreventParentScroll: true
63669
- }, props.isPending && React__default.createElement(Progress, null), !props.isPending && React__default.createElement(React__default.Fragment, null, props.list.length > 0 ? props.list.sort(sortValueList).map(function (x) {
63688
+ }, isProgressVisible && React__default.createElement(FlexBox, {
63689
+ className: valueListStyles['vitro-progress-container']
63690
+ }, React__default.createElement(Progress, null)), !isProgressVisible && React__default.createElement(React__default.Fragment, null, props.list.length > 0 ? props.list.sort(sortValueList).map(function (x) {
63670
63691
  return React__default.createElement(ValueListItem, {
63671
63692
  item: x,
63672
63693
  onSelect: props.onOptionValueSelect,
@@ -63801,16 +63822,9 @@ var LookupPicker = React.forwardRef(function (props, ref) {
63801
63822
  var isShowTooltipRef = React.useRef(true);
63802
63823
  var scrollBarRef = React.useRef(null);
63803
63824
  var rightButtonGroupRef = React.useRef(null);
63804
- var updatePending = function updatePending(valueList) {
63805
- return setPending(valueList ? false : true);
63806
- };
63807
- React.useEffect(function () {
63808
- updatePending(props.valueList);
63809
- }, []);
63810
63825
  React.useEffect(function () {
63811
63826
  updateFilteredValueList(props.valueList || []);
63812
63827
  setSelectedValueList(createDefaultSelectedValueList);
63813
- updatePending(props.valueList);
63814
63828
  }, [props.valueList]);
63815
63829
  React.useEffect(function () {
63816
63830
  if (props.selectedValueList && checkIsValueChanged(selectedValueList, props.selectedValueList)) {
@@ -63898,6 +63912,8 @@ var LookupPicker = React.forwardRef(function (props, ref) {
63898
63912
  }
63899
63913
  }, [state]);
63900
63914
  var updateFilteredValueList = function updateFilteredValueList(valueList) {
63915
+ var _inputRef$current;
63916
+ var inputValue = ((_inputRef$current = inputRef.current) === null || _inputRef$current === void 0 ? void 0 : _inputRef$current.value) || CTRL.EMPTY;
63901
63917
  var availableValueList = inputValue ? filteredValueList : valueList;
63902
63918
  if (inputValue && inputValue.length >= (props.charCount || 0)) {
63903
63919
  availableValueList = valueList.filter(function (x) {
@@ -63937,6 +63953,8 @@ var LookupPicker = React.forwardRef(function (props, ref) {
63937
63953
  }
63938
63954
  };
63939
63955
  var filterByText = function filterByText(value) {
63956
+ var _inputRef$current2;
63957
+ var inputValue = ((_inputRef$current2 = inputRef.current) === null || _inputRef$current2 === void 0 ? void 0 : _inputRef$current2.value) || CTRL.EMPTY;
63940
63958
  var isValueContainsInputValue = filterValueTemplate(value).toLowerCase().indexOf(inputValue.toLowerCase()) >= 0;
63941
63959
  var isValueIsNotYetSelected = !selectedValueList.map(function (f) {
63942
63960
  return f.id;
@@ -63996,8 +64014,8 @@ var LookupPicker = React.forwardRef(function (props, ref) {
63996
64014
  };
63997
64015
  var onOptionValueDelete = function onOptionValueDelete(id) {
63998
64016
  if (!props.isDisabled) {
63999
- var _inputRef$current;
64000
- (_inputRef$current = inputRef.current) === null || _inputRef$current === void 0 ? void 0 : _inputRef$current.focus();
64017
+ var _inputRef$current3;
64018
+ (_inputRef$current3 = inputRef.current) === null || _inputRef$current3 === void 0 ? void 0 : _inputRef$current3.focus();
64001
64019
  var newSelectedValueList = id ? selectedValueList.filter(function (x) {
64002
64020
  return x.id !== id;
64003
64021
  }) : [];
@@ -64026,7 +64044,7 @@ var LookupPicker = React.forwardRef(function (props, ref) {
64026
64044
  }
64027
64045
  };
64028
64046
  var onFocus = function onFocus(e) {
64029
- var _inputRef$current2;
64047
+ var _inputRef$current4;
64030
64048
  if (scrollBarRef.current) {
64031
64049
  scrollBarRef.current.scrollTop = scrollBarRef.current.scrollHeight;
64032
64050
  }
@@ -64037,7 +64055,7 @@ var LookupPicker = React.forwardRef(function (props, ref) {
64037
64055
  isShowTooltipRef.current = false;
64038
64056
  setState(styles$O['vitro-focus']);
64039
64057
  expandValueList();
64040
- (_inputRef$current2 = inputRef.current) === null || _inputRef$current2 === void 0 ? void 0 : _inputRef$current2.focus();
64058
+ (_inputRef$current4 = inputRef.current) === null || _inputRef$current4 === void 0 ? void 0 : _inputRef$current4.focus();
64041
64059
  if (props.onFocus) {
64042
64060
  props.onFocus(e);
64043
64061
  }
@@ -67265,7 +67283,7 @@ var Viewer = function Viewer(props) {
67265
67283
  };
67266
67284
 
67267
67285
  var name = "@vitrosoftware/common-ui-ts";
67268
- var version$1 = "1.1.250";
67286
+ var version$1 = "1.1.252";
67269
67287
  var description = "vitro software common ui ts";
67270
67288
  var author = "";
67271
67289
  var license = "MIT";