oolib 2.30.3 → 2.30.5

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.
@@ -16,7 +16,6 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  exports.TabBarStyle2 = exports.TabBarStyle1 = void 0;
18
18
  var react_1 = __importDefault(require("react"));
19
- var Typo_1 = require("../Typo");
20
19
  var index_styled_1 = require("./index.styled");
21
20
  var Base = function (_a) {
22
21
  var id = _a.id, options = _a.options, valueProp = _a.value, onChange = _a.onChange, style = _a.style, errorTabs = _a.errorTabs, _b = _a.tabBarStyle, tabBarStyle = _b === void 0 ? '1' : _b, saveValueAsString = _a.saveValueAsString, M = _a.M, S = _a.S, _size = _a.size //use any one of these 3
@@ -33,7 +32,7 @@ var Base = function (_a) {
33
32
  var tabIsActive = value && op.value === value.value;
34
33
  return (react_1.default.createElement(index_styled_1.TabBarTabWrapper, { tabBarStyle: tabBarStyle, key: op.value, active: tabIsActive, error: tabHasError },
35
34
  react_1.default.createElement(index_styled_1.TabBarTabStyled, { size: size, active: tabIsActive, error: tabHasError, tabBarStyle: tabBarStyle, onClick: function () { return handleClick(op); } },
36
- react_1.default.createElement(Typo_1.SANS_2, { semibold: tabBarStyle === "1" }, op.display))));
35
+ react_1.default.createElement(index_styled_1.STYLED_SANS_2, { semibold: tabBarStyle === "1" }, op.display))));
37
36
  })))));
38
37
  };
39
38
  var TabBarStyle1 = function (props) { return react_1.default.createElement(Base, __assign({}, props, { tabBarStyle: "1" })); };
@@ -3,3 +3,4 @@ export const TabBarContainerStyled: any;
3
3
  export const TabBarRowStyled: any;
4
4
  export const TabBarTabWrapper: any;
5
5
  export const TabBarTabStyled: any;
6
+ export const STYLED_SANS_2: any;
@@ -27,11 +27,12 @@ var __importStar = (this && this.__importStar) || function (mod) {
27
27
  return result;
28
28
  };
29
29
  Object.defineProperty(exports, "__esModule", { value: true });
30
- exports.TabBarTabStyled = exports.TabBarTabWrapper = exports.TabBarRowStyled = exports.TabBarContainerStyled = exports.TabBarStyled = void 0;
30
+ exports.STYLED_SANS_2 = exports.TabBarTabStyled = exports.TabBarTabWrapper = exports.TabBarRowStyled = exports.TabBarContainerStyled = exports.TabBarStyled = void 0;
31
31
  var styled_components_1 = __importStar(require("styled-components"));
32
32
  var themes_1 = require("../../themes");
33
33
  var mixins_1 = require("../../themes/mixins");
34
34
  var utilsOolib_1 = require("../../utilsOolib");
35
+ var Typo_1 = require("../Typo");
35
36
  var greyColor100 = themes_1.colors.greyColor100, greyColor10 = themes_1.colors.greyColor10, red = themes_1.colors.red, lightRed = themes_1.colors.lightRed, invertRed = themes_1.colors.invertRed, greyColor5 = themes_1.colors.greyColor5, white = themes_1.colors.white, none = themes_1.colors.none;
36
37
  var tabBarWrapperStyle1 = (0, styled_components_1.css)(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n ", "\n :hover {\n background-color: ", ";\n }\n\n ", "\n\n ", "\n"], ["\n ", "\n :hover {\n background-color: ", ";\n }\n\n ", "\n\n ", "\n"])), (0, mixins_1.transition)("background-color"), function (_a) {
37
38
  var error = _a.error;
@@ -79,7 +80,7 @@ exports.TabBarStyled = styled_components_1.default.div(templateObject_11 || (tem
79
80
  });
80
81
  exports.TabBarContainerStyled = styled_components_1.default.div(templateObject_12 || (templateObject_12 = __makeTemplateObject(["\n width: fit-content;\n height: 100%;\n"], ["\n width: fit-content;\n height: 100%;\n"])));
81
82
  exports.TabBarRowStyled = styled_components_1.default.div(templateObject_13 || (templateObject_13 = __makeTemplateObject(["\n display: flex;\n height: 100%;\n"], ["\n display: flex;\n height: 100%;\n"])));
82
- exports.TabBarTabWrapper = styled_components_1.default.div(templateObject_14 || (templateObject_14 = __makeTemplateObject(["\n ", "\n display: flex;\n align-items: center;\n"], ["\n ", "\n display: flex;\n align-items: center;\n"])), function (_a) {
83
+ exports.TabBarTabWrapper = styled_components_1.default.div(templateObject_14 || (templateObject_14 = __makeTemplateObject(["\n ", "\n display: flex;\n align-items: center;\n min-width: 0; //so that ellipsis works on the text within\n"], ["\n ", "\n display: flex;\n align-items: center;\n min-width: 0; //so that ellipsis works on the text within\n"])), function (_a) {
83
84
  var tabBarStyle = _a.tabBarStyle;
84
85
  return tabBarStyle === "1"
85
86
  ? tabBarWrapperStyle1
@@ -91,4 +92,5 @@ exports.TabBarTabStyled = styled_components_1.default.button(templateObject_15 |
91
92
  ? tabBarTabStyle1
92
93
  : tabBarStyle === "2" && tabBarTabStyle2;
93
94
  });
94
- var templateObject_1, templateObject_2, templateObject_3, templateObject_4, templateObject_5, templateObject_6, templateObject_7, templateObject_8, templateObject_9, templateObject_10, templateObject_11, templateObject_12, templateObject_13, templateObject_14, templateObject_15;
95
+ exports.STYLED_SANS_2 = (0, styled_components_1.default)(Typo_1.SANS_2)(templateObject_16 || (templateObject_16 = __makeTemplateObject(["\n white-space: nowrap;\n text-overflow: ellipsis;\n overflow: hidden;\n"], ["\n white-space: nowrap;\n text-overflow: ellipsis;\n overflow: hidden;\n"])));
96
+ var templateObject_1, templateObject_2, templateObject_3, templateObject_4, templateObject_5, templateObject_6, templateObject_7, templateObject_8, templateObject_9, templateObject_10, templateObject_11, templateObject_12, templateObject_13, templateObject_14, templateObject_15, templateObject_16;
@@ -54,7 +54,18 @@ var set_deleteVal = function (action, data, valuePath, value) {
54
54
  return data;
55
55
  }
56
56
  else if (action === 'delete') {
57
- delete dataRef[keysArray[len - 1]];
57
+ /**
58
+ * very important that we handle Array situations by 'splicing'
59
+ * rather than deleting, cuz 'delete' leaves an 'empty slot' in the
60
+ * array rather than removing the item completely which causes all
61
+ * sorts of problems.
62
+ */
63
+ if (Array.isArray(dataRef)) {
64
+ dataRef.splice(parseInt(keysArray[len - 1]), 1);
65
+ }
66
+ else {
67
+ delete dataRef[keysArray[len - 1]];
68
+ }
58
69
  return data;
59
70
  }
60
71
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "oolib",
3
- "version": "2.30.3",
3
+ "version": "2.30.5",
4
4
  "description": " OKE Component Library",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",