oolib 2.108.0 → 2.108.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.
@@ -1,4 +1,4 @@
1
- export function DropdownSingle({ optionsAnchor, lightboxHeight, lightboxStyle, selectClassName, optionsClassName, disableSelectTextUpdate, selectStyleOverride, value: valueProp, id, onChange: parentOnChange, className, style, readOnly, invert, optionsFn, options: optionsProp, saveValueAsString, isTagsStyle, selectConfig, label, optionsModalLabel, broadcastShowOptions, isSearchable, searchFieldsConfig, setFilteredOptions: setFilteredOptionsInParent, setSearchString: setSearchStringInParent, searchString: searchStringInParent, genCustomSelectComp, placeholder, genCreateTagButton, popOutOfOverflowHiddenParent, S, disabled, tagColor }: {
1
+ export function DropdownSingle({ optionsAnchor, lightboxHeight, lightboxStyle, selectClassName, optionsClassName, disableSelectTextUpdate, selectStyleOverride, value: valueProp, id, onChange: parentOnChange, className, style, readOnly, invert, optionsFn, options: optionsProp, saveValueAsString, isTagsStyle, selectConfig, label, optionsModalLabel, broadcastShowOptions, isSearchable, searchFieldsConfig, setFilteredOptions: setFilteredOptionsInParent, setSearchString: setSearchStringInParent, searchString: searchStringInParent, genCustomSelectComp, placeholder, genCreateTagButton, popOutOfOverflowHiddenParent, S, disabled, tagColor, observerRef }: {
2
2
  optionsAnchor: any;
3
3
  lightboxHeight: any;
4
4
  lightboxStyle: any;
@@ -33,5 +33,6 @@ export function DropdownSingle({ optionsAnchor, lightboxHeight, lightboxStyle, s
33
33
  S: any;
34
34
  disabled: any;
35
35
  tagColor: any;
36
+ observerRef: any;
36
37
  }, ...args: any[]): React.JSX.Element;
37
38
  import React from "react";
@@ -72,7 +72,7 @@ function DropdownSingle(_a) {
72
72
  searchFieldsConfig = _a.searchFieldsConfig, setFilteredOptionsInParent = _a.setFilteredOptions, setSearchStringInParent = _a.setSearchString, searchStringInParent = _a.searchString, genCustomSelectComp = _a.genCustomSelectComp, placeholder = _a.placeholder, //
73
73
  genCreateTagButton = _a.genCreateTagButton, popOutOfOverflowHiddenParent = _a.popOutOfOverflowHiddenParent, S = _a.S, //
74
74
  disabled = _a.disabled, //
75
- tagColor = _a.tagColor;
75
+ tagColor = _a.tagColor, observerRef = _a.observerRef;
76
76
  var theme = (0, styled_components_1.useTheme)();
77
77
  var props = arguments[0];
78
78
  var value = (0, getValue_1.getValue_SINGLE)({ valueProp: valueProp, optionsFn: optionsFn, options: optionsProp, theme: theme, saveValueAsString: saveValueAsString });
@@ -152,7 +152,7 @@ function DropdownSingle(_a) {
152
152
  S: S,
153
153
  disabled: disabled
154
154
  })))),
155
- react_1.default.createElement(OptionsSingle_1.OptionsSingle, { lightboxHeight: lightboxHeight, lightboxStyle: lightboxStyle, optionsAnchor: optionsAnchor, searchString: searchString, setSearchString: setSearchString, id: id, optionsClassName: optionsClassName, label: label, value: value, relativeToRef: selectRef, invert: invert, showOptions: showOptions, handleHideOptions: handleHideOptions, handleSelect: handleSelect, options: options, optionsFn: optionsFn, optionsModalLabel: optionsModalLabel,
155
+ react_1.default.createElement(OptionsSingle_1.OptionsSingle, { observerRef: observerRef, lightboxHeight: lightboxHeight, lightboxStyle: lightboxStyle, optionsAnchor: optionsAnchor, searchString: searchString, setSearchString: setSearchString, id: id, optionsClassName: optionsClassName, label: label, value: value, relativeToRef: selectRef, invert: invert, showOptions: showOptions, handleHideOptions: handleHideOptions, handleSelect: handleSelect, options: options, optionsFn: optionsFn, optionsModalLabel: optionsModalLabel,
156
156
  //combobox specific
157
157
  isSearchable: isTagsStyle ? false : isSearchable, genCreateTagButton: genCreateTagButton, SelectComp: isTagsStyle && genSelectTagsInput(), S: S, popOutOfOverflowHiddenParent: popOutOfOverflowHiddenParent })));
158
158
  };
@@ -1,7 +1,8 @@
1
- export function OptionContent({ option, optionsClassName, invert, S }: {
1
+ export function OptionContent({ option, optionsClassName, invert, S, observerRef }: {
2
2
  option: any;
3
3
  optionsClassName: any;
4
4
  invert: any;
5
5
  S: any;
6
+ observerRef: any;
6
7
  }): React.JSX.Element;
7
8
  import React from "react";
@@ -12,11 +12,11 @@ var Typo_1 = require("../../../Typo");
12
12
  var styled_components_1 = require("styled-components");
13
13
  var genColor_1 = require("../../utils/genColor");
14
14
  var OptionContent = function (_a) {
15
- var option = _a.option, optionsClassName = _a.optionsClassName, invert = _a.invert, S = _a.S;
15
+ var option = _a.option, optionsClassName = _a.optionsClassName, invert = _a.invert, S = _a.S, observerRef = _a.observerRef;
16
16
  var theme = (0, styled_components_1.useTheme)();
17
17
  var TypoComp = S ? Typo_1.SANS_2 : Typo_1.SANS_3;
18
18
  var image = option.image, display = option.display, icon = option.icon, desc = option.desc, color = option.color;
19
- return (react_1.default.createElement("div", { style: {
19
+ return (react_1.default.createElement("div", { ref: observerRef, style: {
20
20
  display: "flex",
21
21
  alignItems: "flex-start",
22
22
  gap: "1rem",
@@ -1,4 +1,4 @@
1
- export function OptionsSingle({ lightboxHeight, lightboxStyle, optionsAnchor, value, id, optionsClassName, relativeToRef, showOptions, handleHideOptions, handleSelect, options, isSearchable, label, optionsModalLabel, searchString, setSearchString, SelectComp, genCreateTagButton, invert, popOutOfOverflowHiddenParent, enableUseSetYOrientation, S }: {
1
+ export function OptionsSingle({ lightboxHeight, lightboxStyle, optionsAnchor, value, id, optionsClassName, relativeToRef, showOptions, handleHideOptions, handleSelect, options, isSearchable, label, optionsModalLabel, searchString, setSearchString, SelectComp, genCreateTagButton, invert, popOutOfOverflowHiddenParent, enableUseSetYOrientation, S, observerRef }: {
2
2
  lightboxHeight: any;
3
3
  lightboxStyle: any;
4
4
  optionsAnchor: any;
@@ -21,5 +21,6 @@ export function OptionsSingle({ lightboxHeight, lightboxStyle, optionsAnchor, va
21
21
  popOutOfOverflowHiddenParent: any;
22
22
  enableUseSetYOrientation?: boolean;
23
23
  S: any;
24
+ observerRef: any;
24
25
  }): React.JSX.Element;
25
26
  import React from "react";
@@ -58,7 +58,7 @@ var OptionsSingle = function (_a) {
58
58
  relativeToRef = _a.relativeToRef, //the element that this lightbox is being rendered against. i.e top or bottom
59
59
  showOptions = _a.showOptions, handleHideOptions = _a.handleHideOptions, handleSelect = _a.handleSelect, options = _a.options, isSearchable = _a.isSearchable, label = _a.label, optionsModalLabel = _a.optionsModalLabel, //label is just a fallback for optionsModalLabel. Don't know why both are needed
60
60
  searchString = _a.searchString, setSearchString = _a.setSearchString, SelectComp = _a.SelectComp, genCreateTagButton = _a.genCreateTagButton, invert = _a.invert, popOutOfOverflowHiddenParent = _a.popOutOfOverflowHiddenParent, _b = _a.enableUseSetYOrientation, enableUseSetYOrientation = _b === void 0 ? true : _b, // if using this component standalone, this should be set to false ( if relativeToRef is not being passed thru)
61
- S = _a.S
61
+ S = _a.S, observerRef = _a.observerRef
62
62
  //disabled only with this is being used for the RTEEmbedLightbox. Also this might be temp.
63
63
  //ensure this is set to false, if you are not passing a 'relativeToRef'
64
64
  ;
@@ -113,7 +113,7 @@ var OptionsSingle = function (_a) {
113
113
  if (!option.loading)
114
114
  handleSelect(option);
115
115
  setSearchString && setSearchString('');
116
- }, S: S, style: style && style }, option.loading ? (react_1.default.createElement(TextLoader_1.TextLoader, { style: { width: "8rem", height: "1.5rem" } })) : (react_1.default.createElement(OptionContent_1.OptionContent, __assign({}, { option: option, optionsClassName: optionsClassName, invert: invert, S: S }))));
116
+ }, S: S, style: style && style }, option.loading ? (react_1.default.createElement(TextLoader_1.TextLoader, { style: { width: "8rem", height: "1.5rem" } })) : (react_1.default.createElement(OptionContent_1.OptionContent, __assign({}, { option: option, optionsClassName: optionsClassName, invert: invert, S: S, observerRef: observerRef }))));
117
117
  }),
118
118
  genCreateTagButton && genCreateTagButton(options))));
119
119
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "oolib",
3
- "version": "2.108.0",
3
+ "version": "2.108.1",
4
4
  "description": " OKE Component Library",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",