oolib 2.207.1 → 2.208.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.
Files changed (161) hide show
  1. package/dist/components/DateRangePicker/index.js +2 -2
  2. package/dist/components/GroupQuestionsInputSingle/index.js +2 -2
  3. package/dist/components/IFrameInput/index.js +1 -1
  4. package/dist/components/ImageInput/comps/Placeholder/index.js +1 -1
  5. package/dist/components/SimpleTable/index.js +2 -2
  6. package/dist/components/VideoInput/comps/EmbedLinkModal.js +1 -1
  7. package/dist/components/cards/ListProfile/index.js +1 -1
  8. package/dist/index.d.ts +8 -9
  9. package/dist/index.js +25 -33
  10. package/dist/stories/Oolib/components/Modal.stories.js +2 -2
  11. package/dist/stories/Oolib/components/TagsInput.stories.js +1 -1
  12. package/dist/stories/v2/components/visualization/HeatMapGrid.stories.d.ts +1 -0
  13. package/dist/stories/v2/components/visualization/HeatMapGrid.stories.js +83 -1
  14. package/dist/v2/components/DateRangePicker/index.js +1 -2
  15. package/dist/v2/components/TabBar/index.js +3 -3
  16. package/dist/v2/components/TextInputs/index.js +0 -7
  17. package/dist/v2/components/TextInputs/index.styled.js +1 -1
  18. package/dist/v2/components/dataviz/HeatMapGrid/index.js +23 -28
  19. package/dist/v2/components/dataviz/HeatMapGrid/utils/usePrepareHeatMapData.d.ts +33 -0
  20. package/dist/v2/components/dataviz/HeatMapGrid/utils/usePrepareHeatMapData.js +117 -0
  21. package/package.json +1 -1
  22. package/dist/components/BlockLabel/index.d.ts +0 -2
  23. package/dist/components/BlockLabel/index.js +0 -75
  24. package/dist/components/BlockLabel/index.styled.d.ts +0 -2
  25. package/dist/components/BlockLabel/index.styled.js +0 -14
  26. package/dist/components/Dropdowns/DropdownMulti/index.d.ts +0 -38
  27. package/dist/components/Dropdowns/DropdownMulti/index.js +0 -179
  28. package/dist/components/Dropdowns/DropdownSingle/index.d.ts +0 -40
  29. package/dist/components/Dropdowns/DropdownSingle/index.js +0 -163
  30. package/dist/components/Dropdowns/comps/Caret/index.d.ts +0 -6
  31. package/dist/components/Dropdowns/comps/Caret/index.js +0 -19
  32. package/dist/components/Dropdowns/comps/Caret/styled.d.ts +0 -2
  33. package/dist/components/Dropdowns/comps/Caret/styled.js +0 -14
  34. package/dist/components/Dropdowns/comps/DisplayCompSingle/index.d.ts +0 -7
  35. package/dist/components/Dropdowns/comps/DisplayCompSingle/index.js +0 -39
  36. package/dist/components/Dropdowns/comps/NoOptionResultsComp/index.d.ts +0 -4
  37. package/dist/components/Dropdowns/comps/NoOptionResultsComp/index.js +0 -15
  38. package/dist/components/Dropdowns/comps/OptionContent/index.d.ts +0 -8
  39. package/dist/components/Dropdowns/comps/OptionContent/index.js +0 -34
  40. package/dist/components/Dropdowns/comps/OptionsMulti/index.d.ts +0 -28
  41. package/dist/components/Dropdowns/comps/OptionsMulti/index.js +0 -159
  42. package/dist/components/Dropdowns/comps/OptionsShell/comps/OptionsAnimateWrapper/index.d.ts +0 -14
  43. package/dist/components/Dropdowns/comps/OptionsShell/comps/OptionsAnimateWrapper/index.js +0 -81
  44. package/dist/components/Dropdowns/comps/OptionsShell/comps/OptionsAnimateWrapper/styled.d.ts +0 -2
  45. package/dist/components/Dropdowns/comps/OptionsShell/comps/OptionsAnimateWrapper/styled.js +0 -25
  46. package/dist/components/Dropdowns/comps/OptionsShell/index.d.ts +0 -2
  47. package/dist/components/Dropdowns/comps/OptionsShell/index.js +0 -101
  48. package/dist/components/Dropdowns/comps/OptionsShell/styled.d.ts +0 -5
  49. package/dist/components/Dropdowns/comps/OptionsShell/styled.js +0 -45
  50. package/dist/components/Dropdowns/comps/OptionsSingle/index.d.ts +0 -28
  51. package/dist/components/Dropdowns/comps/OptionsSingle/index.js +0 -105
  52. package/dist/components/Dropdowns/comps/OptionsSingle/styled.d.ts +0 -1
  53. package/dist/components/Dropdowns/comps/OptionsSingle/styled.js +0 -61
  54. package/dist/components/Dropdowns/comps/SelectDropdown/index.d.ts +0 -13
  55. package/dist/components/Dropdowns/comps/SelectDropdown/index.js +0 -54
  56. package/dist/components/Dropdowns/comps/SelectDropdown/styled.d.ts +0 -1
  57. package/dist/components/Dropdowns/comps/SelectDropdown/styled.js +0 -71
  58. package/dist/components/Dropdowns/comps/SelectTagsInput/index.d.ts +0 -18
  59. package/dist/components/Dropdowns/comps/SelectTagsInput/index.js +0 -124
  60. package/dist/components/Dropdowns/comps/SelectTagsInput/styled.d.ts +0 -2
  61. package/dist/components/Dropdowns/comps/SelectTagsInput/styled.js +0 -54
  62. package/dist/components/Dropdowns/handlers/index.d.ts +0 -14
  63. package/dist/components/Dropdowns/handlers/index.js +0 -52
  64. package/dist/components/Dropdowns/styled.d.ts +0 -2
  65. package/dist/components/Dropdowns/styled.js +0 -49
  66. package/dist/components/Dropdowns/utils/genColor.d.ts +0 -4
  67. package/dist/components/Dropdowns/utils/genColor.js +0 -15
  68. package/dist/components/Dropdowns/utils/genIcon.d.ts +0 -6
  69. package/dist/components/Dropdowns/utils/genIcon.js +0 -18
  70. package/dist/components/Dropdowns/utils/genLinkOrText.d.ts +0 -1
  71. package/dist/components/Dropdowns/utils/genLinkOrText.js +0 -48
  72. package/dist/components/Dropdowns/utils/genProfileImg.d.ts +0 -6
  73. package/dist/components/Dropdowns/utils/genProfileImg.js +0 -14
  74. package/dist/components/Dropdowns/utils/genTagComp.d.ts +0 -2
  75. package/dist/components/Dropdowns/utils/genTagComp.js +0 -27
  76. package/dist/components/Dropdowns/utils/generateOptions.d.ts +0 -5
  77. package/dist/components/Dropdowns/utils/generateOptions.js +0 -20
  78. package/dist/components/Dropdowns/utils/getAllOptionsFns/genMonthsArray.d.ts +0 -1
  79. package/dist/components/Dropdowns/utils/getAllOptionsFns/genMonthsArray.js +0 -40
  80. package/dist/components/Dropdowns/utils/getAllOptionsFns/genYearsArray.d.ts +0 -4
  81. package/dist/components/Dropdowns/utils/getAllOptionsFns/genYearsArray.js +0 -11
  82. package/dist/components/Dropdowns/utils/getAllOptionsFns/getLanguagesArray.d.ts +0 -4
  83. package/dist/components/Dropdowns/utils/getAllOptionsFns/getLanguagesArray.js +0 -62
  84. package/dist/components/Dropdowns/utils/getAllOptionsFns/index.d.ts +0 -1
  85. package/dist/components/Dropdowns/utils/getAllOptionsFns/index.js +0 -19
  86. package/dist/components/Dropdowns/utils/getValue.d.ts +0 -14
  87. package/dist/components/Dropdowns/utils/getValue.js +0 -32
  88. package/dist/components/Dropdowns/utils/isDynamicOtherOption.d.ts +0 -0
  89. package/dist/components/Dropdowns/utils/isDynamicOtherOption.js +0 -0
  90. package/dist/components/Dropdowns/utils/keywordSearchOptions.d.ts +0 -6
  91. package/dist/components/Dropdowns/utils/keywordSearchOptions.js +0 -18
  92. package/dist/components/Dropdowns/utils/setDropdownSelectText.d.ts +0 -12
  93. package/dist/components/Dropdowns/utils/setDropdownSelectText.js +0 -19
  94. package/dist/components/Dropdowns/utils/useCreateDropdownRefs.d.ts +0 -5
  95. package/dist/components/Dropdowns/utils/useCreateDropdownRefs.js +0 -15
  96. package/dist/components/Dropdowns/utils/useHideShowOptions.d.ts +0 -5
  97. package/dist/components/Dropdowns/utils/useHideShowOptions.js +0 -20
  98. package/dist/components/Dropdowns/utils/useKeyboardControl.d.ts +0 -12
  99. package/dist/components/Dropdowns/utils/useKeyboardControl.js +0 -73
  100. package/dist/components/Dropdowns/utils/useSearchString.d.ts +0 -4
  101. package/dist/components/Dropdowns/utils/useSearchString.js +0 -20
  102. package/dist/components/Dropdowns/utils/useSetYOrientation.d.ts +0 -9
  103. package/dist/components/Dropdowns/utils/useSetYOrientation.js +0 -46
  104. package/dist/components/Hints/contextApi.d.ts +0 -6
  105. package/dist/components/Hints/contextApi.js +0 -48
  106. package/dist/components/Hints/index.d.ts +0 -9
  107. package/dist/components/Hints/index.js +0 -127
  108. package/dist/components/Hints/styled.d.ts +0 -6
  109. package/dist/components/Hints/styled.js +0 -54
  110. package/dist/components/RadioAndCheckbox/comps/CheckboxList/comps/CheckboxButton/index.d.ts +0 -11
  111. package/dist/components/RadioAndCheckbox/comps/CheckboxList/comps/CheckboxButton/index.js +0 -30
  112. package/dist/components/RadioAndCheckbox/comps/CheckboxList/comps/CheckboxButton/styled.d.ts +0 -1
  113. package/dist/components/RadioAndCheckbox/comps/CheckboxList/comps/CheckboxButton/styled.js +0 -70
  114. package/dist/components/RadioAndCheckbox/comps/CheckboxList/comps/CheckboxInput/index.d.ts +0 -11
  115. package/dist/components/RadioAndCheckbox/comps/CheckboxList/comps/CheckboxInput/index.js +0 -50
  116. package/dist/components/RadioAndCheckbox/comps/CheckboxList/index.d.ts +0 -20
  117. package/dist/components/RadioAndCheckbox/comps/CheckboxList/index.js +0 -124
  118. package/dist/components/RadioAndCheckbox/comps/CheckboxList/styled.d.ts +0 -2
  119. package/dist/components/RadioAndCheckbox/comps/CheckboxList/styled.js +0 -17
  120. package/dist/components/RadioAndCheckbox/comps/RadioList/comps/RadioInput/index.d.ts +0 -18
  121. package/dist/components/RadioAndCheckbox/comps/RadioList/comps/RadioInput/index.js +0 -53
  122. package/dist/components/RadioAndCheckbox/comps/RadioList/comps/RadioInput/styled.d.ts +0 -2
  123. package/dist/components/RadioAndCheckbox/comps/RadioList/comps/RadioInput/styled.js +0 -84
  124. package/dist/components/RadioAndCheckbox/comps/RadioList/comps/index.d.ts +0 -1
  125. package/dist/components/RadioAndCheckbox/comps/RadioList/comps/index.js +0 -6
  126. package/dist/components/RadioAndCheckbox/comps/RadioList/index.d.ts +0 -17
  127. package/dist/components/RadioAndCheckbox/comps/RadioList/index.js +0 -109
  128. package/dist/components/RadioAndCheckbox/index.d.ts +0 -5
  129. package/dist/components/RadioAndCheckbox/index.js +0 -14
  130. package/dist/components/RadioAndCheckbox/styled.d.ts +0 -5
  131. package/dist/components/RadioAndCheckbox/styled.js +0 -84
  132. package/dist/components/RadioAndCheckbox/utils.d.ts +0 -22
  133. package/dist/components/RadioAndCheckbox/utils.js +0 -49
  134. package/dist/components/Switches/index.d.ts +0 -21
  135. package/dist/components/Switches/index.js +0 -102
  136. package/dist/components/Switches/styled.d.ts +0 -5
  137. package/dist/components/Switches/styled.js +0 -63
  138. package/dist/components/TextInputs/index.d.ts +0 -24
  139. package/dist/components/TextInputs/index.js +0 -367
  140. package/dist/components/TextInputs/index.styled.d.ts +0 -3
  141. package/dist/components/TextInputs/index.styled.js +0 -77
  142. package/dist/components/cards/CardContent/index.d.ts +0 -11
  143. package/dist/components/cards/CardContent/index.js +0 -76
  144. package/dist/components/cards/CardContent/styled.d.ts +0 -7
  145. package/dist/components/cards/CardContent/styled.js +0 -63
  146. package/dist/components/cards/ListContent/index.d.ts +0 -12
  147. package/dist/components/cards/ListContent/index.js +0 -87
  148. package/dist/components/cards/ListContent/styled.d.ts +0 -7
  149. package/dist/components/cards/ListContent/styled.js +0 -26
  150. package/dist/stories/Oolib/components/BlockLabel.stories.d.ts +0 -71
  151. package/dist/stories/Oolib/components/BlockLabel.stories.js +0 -106
  152. package/dist/stories/Oolib/components/Checkbox.stories.d.ts +0 -248
  153. package/dist/stories/Oolib/components/Checkbox.stories.js +0 -249
  154. package/dist/stories/Oolib/components/Dropdowns.stories.d.ts +0 -127
  155. package/dist/stories/Oolib/components/Dropdowns.stories.js +0 -298
  156. package/dist/stories/Oolib/components/RadioButton.stories.d.ts +0 -260
  157. package/dist/stories/Oolib/components/RadioButton.stories.js +0 -264
  158. package/dist/stories/Oolib/components/Switches.stories.d.ts +0 -106
  159. package/dist/stories/Oolib/components/Switches.stories.js +0 -146
  160. package/dist/stories/Oolib/components/TextInputs.stories.d.ts +0 -124
  161. package/dist/stories/Oolib/components/TextInputs.stories.js +0 -188
@@ -1,25 +0,0 @@
1
- "use strict";
2
- var __makeTemplateObject = (this && this.__makeTemplateObject) || function (cooked, raw) {
3
- if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; }
4
- return cooked;
5
- };
6
- var __importDefault = (this && this.__importDefault) || function (mod) {
7
- return (mod && mod.__esModule) ? mod : { "default": mod };
8
- };
9
- Object.defineProperty(exports, "__esModule", { value: true });
10
- exports.StyledOptionsAnimateWrapper = void 0;
11
- var styled_components_1 = __importDefault(require("styled-components"));
12
- var globalVariables_1 = require("../../../../../../globalStyles/globalVariables");
13
- var mixins_1 = require("../../../../../../themes/mixins");
14
- /** for lightbox shell */
15
- exports.StyledOptionsAnimateWrapper = styled_components_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n height: ", ";\n /**\n 'else 100%' is very important. \n what this does is, on first render, it allows the optionsWrapper within to take whatever width \n its supposed to i.e max-content / 100% width of select / 36rem.\n Then on the next render (after the ref has already been attached to optionsWrapper), the proper width\n gets calculated and passed to this component.\n\n Without this 100%, this will not work > scenarios where there is enough space for the dropdown to \n stretch to the width of the select OR 36rem. Instead it will always stick to its min-width which is \n max-content\n */\n width: ", ";\n overflow: hidden;\n ", ";\n ", ";\n border-width: ", "; //hack, otherwsie this shit line shows when options are closed\n"], ["\n height: ", ";\n /**\n 'else 100%' is very important. \n what this does is, on first render, it allows the optionsWrapper within to take whatever width \n its supposed to i.e max-content / 100% width of select / 36rem.\n Then on the next render (after the ref has already been attached to optionsWrapper), the proper width\n gets calculated and passed to this component.\n\n Without this 100%, this will not work > scenarios where there is enough space for the dropdown to \n stretch to the width of the select OR 36rem. Instead it will always stick to its min-width which is \n max-content\n */\n width: ", ";\n overflow: hidden;\n ", ";\n ", ";\n border-width: ", "; //hack, otherwsie this shit line shows when options are closed\n"])), function (_a) {
16
- var isOpen = _a.isOpen, openHeight = _a.openHeight;
17
- return isOpen ? (openHeight ? openHeight + 'px' : 'auto') : 0;
18
- }, function (_a) {
19
- var width = _a.width;
20
- return width ? width + 'px' : '100%';
21
- }, (0, mixins_1.transition)('height', 'border-width'), globalVariables_1.globalLightboxStyle, function (_a) {
22
- var isOpen = _a.isOpen;
23
- return isOpen ? '1px' : 0;
24
- });
25
- var templateObject_1;
@@ -1,2 +0,0 @@
1
- export const OptionsShell: React.ForwardRefExoticComponent<React.RefAttributes<any>>;
2
- import React from "react";
@@ -1,101 +0,0 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
- Object.defineProperty(o, "default", { enumerable: true, value: v });
15
- }) : function(o, v) {
16
- o["default"] = v;
17
- });
18
- var __importStar = (this && this.__importStar) || (function () {
19
- var ownKeys = function(o) {
20
- ownKeys = Object.getOwnPropertyNames || function (o) {
21
- var ar = [];
22
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
- return ar;
24
- };
25
- return ownKeys(o);
26
- };
27
- return function (mod) {
28
- if (mod && mod.__esModule) return mod;
29
- var result = {};
30
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
- __setModuleDefault(result, mod);
32
- return result;
33
- };
34
- })();
35
- Object.defineProperty(exports, "__esModule", { value: true });
36
- exports.OptionsShell = void 0;
37
- var framer_motion_1 = require("framer-motion");
38
- var react_1 = __importStar(require("react"));
39
- var themes_1 = require("../../../../themes");
40
- var mixins_1 = require("../../../../themes/mixins");
41
- var useScreenWidth_1 = require("../../../../utils/customHooks/useScreenWidth");
42
- var usePopOutOfOverflowHiddenParent_1 = require("../../../../utils/usePopOutOfOverflowHiddenParent");
43
- var Buttons_1 = require("../../../Buttons");
44
- var Modal_1 = require("../../../Modals/Modal");
45
- var styled_1 = require("./styled");
46
- var OptionsAnimateWrapper_1 = require("./comps/OptionsAnimateWrapper");
47
- var styled_components_1 = require("styled-components");
48
- var DefaultMobileShell = function (_a) {
49
- var children = _a.children;
50
- return (react_1.default.createElement("div", { style: { top: 0, left: 0, height: '100dvh', width: '100dvw', position: 'fixed', zIndex: '100000000', background: 'rgba(0,0,0,0.5)', display: 'flex', flexDirection: 'column', justifyContent: 'flex-end' } }, children));
51
- };
52
- exports.OptionsShell = react_1.default.forwardRef(function (_a, ref) {
53
- var yOrientation = _a.yOrientation, lightboxHeight = _a.lightboxHeight, lightboxStyle = _a.lightboxStyle, options = _a.options, optionsAnchor = _a.optionsAnchor, showOptions = _a.showOptions, handleHideOptions = _a.handleHideOptions, children = _a.children, SelectComp = _a.SelectComp, label = _a.label, optionsModalLabel = _a.optionsModalLabel, invert = _a.invert, showDoneButton = _a.showDoneButton, _b = _a.popOutOfOverflowHiddenParent, popOutOfOverflowHiddenParent = _b === void 0 ? false : _b, relativeToRef = _a.relativeToRef, S = _a.S, alignDropdown = _a.alignDropdown;
54
- var screenWidth = (0, useScreenWidth_1.useScreenWidth)();
55
- var isDesktop = screenWidth >= (0, mixins_1.getBreakPoint)("sm");
56
- var currentTheme = (0, styled_components_1.useTheme)();
57
- var MobileShell = (currentTheme === null || currentTheme === void 0 ? void 0 : currentTheme.MobileShell) || DefaultMobileShell;
58
- var _c = (0, usePopOutOfOverflowHiddenParent_1.usePopOutOfOverflowHiddenParent)(popOutOfOverflowHiddenParent), fixPos = _c.fixPos, applyFixedPos = _c.applyFixedPos, removeFixedPos = _c.removeFixedPos, trackerRef = _c.trackerRef;
59
- (0, react_1.useEffect)(function () {
60
- if (popOutOfOverflowHiddenParent) {
61
- if (showOptions)
62
- applyFixedPos();
63
- else
64
- removeFixedPos();
65
- }
66
- }, [showOptions]);
67
- return isDesktop ? (react_1.default.createElement(react_1.Fragment, null,
68
- popOutOfOverflowHiddenParent && react_1.default.createElement("div", { ref: trackerRef }),
69
- react_1.default.createElement(OptionsAnimateWrapper_1.OptionsAnimateWrapper, { options: options, optionsRef: ref, relativeToRef: relativeToRef, showOptions: showOptions, invert: invert, yOrientation: yOrientation, fixPos: fixPos, optionsAnchor: optionsAnchor, children: children, lightboxStyle: lightboxStyle, alignDropdown: alignDropdown },
70
- react_1.default.createElement(styled_1.StyledOptionsWrapper, { id: "StyledOptionsWrapper", ref: ref, invert: invert, lightboxHeight: lightboxHeight,
71
- // className={className}
72
- style: {
73
- position: "absolute",
74
- bottom: yOrientation === "top" ? undefined : 0,
75
- top: yOrientation === "top" ? 0 : undefined,
76
- } }, children)))) : (
77
- // <AnimatePresence>
78
- // {showOptions ? (
79
- // <Modal
80
- // fitToContentHeight
81
- // title={optionsModalLabel || label}
82
- // onClose={handleHideOptions}
83
- // invert={invert}
84
- // S={S}
85
- // dynamicHeaderHeight
86
- // >
87
- react_1.default.createElement(react_1.Fragment, null, showOptions ? (react_1.default.createElement(MobileShell, { onClose: handleHideOptions, title: optionsModalLabel || label },
88
- SelectComp && SelectComp,
89
- react_1.default.createElement(styled_1.StyledModalOptionsWrapper, { invert: invert, ref: ref }, children),
90
- showDoneButton && (react_1.default.createElement("div", { style: {
91
- backgroundColor: invert ? themes_1.colors.greyColor90 : themes_1.colors.white,
92
- padding: "1rem 2rem",
93
- position: "sticky",
94
- bottom: "0",
95
- } },
96
- react_1.default.createElement(Buttons_1.ButtonPrimary, { children: "Done", width: "100%", onClick: handleHideOptions, S: S }))))) : null)
97
- // </Modal>
98
- // ) : null}
99
- // </AnimatePresence>
100
- );
101
- });
@@ -1,5 +0,0 @@
1
- /** for lightbox shell */
2
- export const StyledOptionsAnimateWrapper: import("styled-components").StyledComponent<"div", any, {}, never>;
3
- export const StyledOptionsWrapper: import("styled-components").StyledComponent<"ul", any, {}, never>;
4
- /** for modal shell */
5
- export const StyledModalOptionsWrapper: import("styled-components").StyledComponent<"div", any, {}, never>;
@@ -1,45 +0,0 @@
1
- "use strict";
2
- var __makeTemplateObject = (this && this.__makeTemplateObject) || function (cooked, raw) {
3
- if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; }
4
- return cooked;
5
- };
6
- var __importDefault = (this && this.__importDefault) || function (mod) {
7
- return (mod && mod.__esModule) ? mod : { "default": mod };
8
- };
9
- Object.defineProperty(exports, "__esModule", { value: true });
10
- exports.StyledModalOptionsWrapper = exports.StyledOptionsWrapper = exports.StyledOptionsAnimateWrapper = void 0;
11
- var styled_components_1 = __importDefault(require("styled-components"));
12
- var themes_1 = require("../../../../themes");
13
- var mixins_1 = require("../../../../themes/mixins");
14
- var globalVariables_1 = require("../../../../globalStyles/globalVariables");
15
- /** for lightbox shell */
16
- exports.StyledOptionsAnimateWrapper = styled_components_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n height: ", ";\n /**\n 'else 100%' is very important. \n what this does is, on first render, it allows the optionsWrapper within to take whatever width \n its supposed to i.e max-content / 100% width of select / 36rem.\n Then on the next render (after the ref has already been attached to optionsWrapper), the proper width\n gets calculated and passed to this component.\n\n Without this 100%, this will not work > scenarios where there is enough space for the dropdown to \n stretch to the width of the select OR 36rem. Instead it will always stick to its min-width which is \n max-content\n */\n width: ", ";\n overflow: hidden;\n ", ";\n ", ";\n border-width: ", "; //hack, otherwsie this shit line shows when options are closed\n"], ["\n height: ", ";\n /**\n 'else 100%' is very important. \n what this does is, on first render, it allows the optionsWrapper within to take whatever width \n its supposed to i.e max-content / 100% width of select / 36rem.\n Then on the next render (after the ref has already been attached to optionsWrapper), the proper width\n gets calculated and passed to this component.\n\n Without this 100%, this will not work > scenarios where there is enough space for the dropdown to \n stretch to the width of the select OR 36rem. Instead it will always stick to its min-width which is \n max-content\n */\n width: ", ";\n overflow: hidden;\n ", ";\n ", ";\n border-width: ", "; //hack, otherwsie this shit line shows when options are closed\n"])), function (_a) {
17
- var isOpen = _a.isOpen, openHeight = _a.openHeight;
18
- return isOpen ? (openHeight ? openHeight + 'px' : 'auto') : 0;
19
- }, function (_a) {
20
- var width = _a.width;
21
- return width ? width + 'px' : '100%';
22
- }, (0, mixins_1.transition)('height', 'border-width'), globalVariables_1.globalLightboxStyle, function (_a) {
23
- var isOpen = _a.isOpen;
24
- return isOpen ? '1px' : 0;
25
- });
26
- exports.StyledOptionsWrapper = styled_components_1.default.ul(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n z-index: 100000; //show remove if we do animation thing\n padding-left: 0; //cancel out the ul's padding left\n cursor: pointer;\n width: 100%;\n min-width: max-content;\n max-width: 36rem;\n overflow: auto;\n max-height: ", ";\n"], ["\n z-index: 100000; //show remove if we do animation thing\n padding-left: 0; //cancel out the ul's padding left\n cursor: pointer;\n width: 100%;\n min-width: max-content;\n max-width: 36rem;\n overflow: auto;\n max-height: ", ";\n"
27
- /** for modal shell */
28
- ])), function (_a) {
29
- var lightboxHeight = _a.lightboxHeight;
30
- switch (lightboxHeight) {
31
- case 'large':
32
- return '33rem';
33
- case 'small':
34
- return '20rem';
35
- case 'medium':
36
- default:
37
- return '24rem';
38
- }
39
- });
40
- /** for modal shell */
41
- exports.StyledModalOptionsWrapper = styled_components_1.default.div(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n position: relative;\n padding-left: 0;\n cursor: pointer;\n background-color: ", ";\n width: 100%;\n min-width: max-content;\n min-width: -moz-max-content;\n /* overflow: auto; */\n"], ["\n position: relative;\n padding-left: 0;\n cursor: pointer;\n background-color: ", ";\n width: 100%;\n min-width: max-content;\n min-width: -moz-max-content;\n /* overflow: auto; */\n"])), function (_a) {
42
- var invert = _a.invert;
43
- return invert ? themes_1.colors.greyColor90 : themes_1.colors.white;
44
- });
45
- var templateObject_1, templateObject_2, templateObject_3;
@@ -1,28 +0,0 @@
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, searchbarPlaceholder, alignDropdown }: {
2
- lightboxHeight: any;
3
- lightboxStyle: any;
4
- optionsAnchor: any;
5
- value: any;
6
- id: any;
7
- optionsClassName: any;
8
- relativeToRef: any;
9
- showOptions: any;
10
- handleHideOptions: any;
11
- handleSelect: any;
12
- options: any;
13
- isSearchable: any;
14
- label: any;
15
- optionsModalLabel: any;
16
- searchString: any;
17
- setSearchString: any;
18
- SelectComp: any;
19
- genCreateTagButton: any;
20
- invert: any;
21
- popOutOfOverflowHiddenParent: any;
22
- enableUseSetYOrientation?: boolean;
23
- S: any;
24
- observerRef: any;
25
- searchbarPlaceholder: any;
26
- alignDropdown: any;
27
- }): React.JSX.Element;
28
- import React from "react";
@@ -1,105 +0,0 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
- Object.defineProperty(o, "default", { enumerable: true, value: v });
15
- }) : function(o, v) {
16
- o["default"] = v;
17
- });
18
- var __importStar = (this && this.__importStar) || (function () {
19
- var ownKeys = function(o) {
20
- ownKeys = Object.getOwnPropertyNames || function (o) {
21
- var ar = [];
22
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
- return ar;
24
- };
25
- return ownKeys(o);
26
- };
27
- return function (mod) {
28
- if (mod && mod.__esModule) return mod;
29
- var result = {};
30
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
- __setModuleDefault(result, mod);
32
- return result;
33
- };
34
- })();
35
- Object.defineProperty(exports, "__esModule", { value: true });
36
- exports.OptionsSingle = void 0;
37
- var react_1 = __importStar(require("react"));
38
- var NoOptionResultsComp_1 = require("../NoOptionResultsComp");
39
- var OptionContent_1 = require("../OptionContent");
40
- var OptionsShell_1 = require("../OptionsShell");
41
- var styled_1 = require("./styled");
42
- var themes_1 = require("../../../../themes");
43
- var Divider_1 = require("../../../Divider");
44
- var TextInputs_1 = require("../../../TextInputs");
45
- var TextLoader_1 = require("../../../LoadersAndProgress/TextLoader");
46
- var useKeyboardControl_1 = require("../../utils/useKeyboardControl");
47
- var useSetYOrientation_1 = require("../../utils/useSetYOrientation");
48
- /**
49
- * if used independently, must be used inside a 'position: relative/absolute' div.
50
- */
51
- var OptionsSingle = function (_a) {
52
- var
53
- //from root
54
- lightboxHeight = _a.lightboxHeight, lightboxStyle = _a.lightboxStyle, optionsAnchor = _a.optionsAnchor, value = _a.value, id = _a.id, optionsClassName = _a.optionsClassName,
55
- //from Dropdown
56
- relativeToRef = _a.relativeToRef, //the element that this lightbox is being rendered against. i.e top or bottom
57
- 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
58
- 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)
59
- S = _a.S, observerRef = _a.observerRef, searchbarPlaceholder = _a.searchbarPlaceholder, alignDropdown = _a.alignDropdown
60
- //disabled only with this is being used for the RTEEmbedLightbox. Also this might be temp.
61
- //ensure this is set to false, if you are not passing a 'relativeToRef'
62
- ;
63
- //INIT ORIENTATION STATE AND CUSTOM HOOK
64
- var optionsRef = (0, react_1.useRef)(null);
65
- var yOrientation = (0, useSetYOrientation_1.useSetYOrientation)({
66
- showOptions: showOptions,
67
- optionsRef: optionsRef,
68
- relativeToRef: relativeToRef,
69
- enabled: enableUseSetYOrientation,
70
- }).yOrientation;
71
- var _c = (0, useKeyboardControl_1.useKeyboardControl)({
72
- showOptions: showOptions,
73
- optionsWrapperRef: optionsRef,
74
- handleHideOptions: handleHideOptions,
75
- handleSelect: handleSelect,
76
- options: options,
77
- searchString: searchString,
78
- id: id,
79
- }), scrollFocussedOpIntoView = _c.scrollFocussedOpIntoView, focussedOp = _c.focussedOp;
80
- var _d = (0, react_1.useState)(true), searchBarFocus = _d[0], setSearchBarFocus = _d[1];
81
- (0, react_1.useEffect)(function () {
82
- setSearchBarFocus(showOptions);
83
- }, [showOptions]);
84
- var genSearchBar = function () { return (react_1.default.createElement("div", { style: {
85
- position: "sticky",
86
- top: 0,
87
- zIndex: 1,
88
- background: invert ? themes_1.colors.greyColor90 : themes_1.colors.white,
89
- } },
90
- react_1.default.createElement("div", { style: { padding: "1rem" } },
91
- react_1.default.createElement(TextInputs_1.TextInput, { placeholder: searchbarPlaceholder, invert: invert, forceFocus: searchBarFocus, type: "text", icon: "MagnifyingGlass", value: searchString, onChange: function (k, v) { return setSearchString(v); }, S: S })),
92
- react_1.default.createElement(Divider_1.Divider, { invert: invert }))); };
93
- return (react_1.default.createElement(react_1.default.Fragment, null,
94
- react_1.default.createElement(OptionsShell_1.OptionsShell, { ref: optionsRef, yOrientation: yOrientation, lightboxHeight: lightboxHeight, lightboxStyle: lightboxStyle, options: options, optionsAnchor: optionsAnchor, showOptions: showOptions, SelectComp: SelectComp, handleHideOptions: handleHideOptions, label: label, optionsModalLabel: optionsModalLabel, invert: invert, relativeToRef: relativeToRef, popOutOfOverflowHiddenParent: popOutOfOverflowHiddenParent, alignDropdown: alignDropdown, S: S },
95
- isSearchable && genSearchBar(),
96
- options.length === 0 ? (react_1.default.createElement(NoOptionResultsComp_1.NoOptionResultsComp, { S: S })) : (react_1.default.createElement(react_1.Fragment, null, options.map(function (option, index) { return (react_1.default.createElement(styled_1.StyledOption, { key: option.value, invert: invert, isSelected: !option.loading && (value === null || value === void 0 ? void 0 : value.value) === option.value, isFocussed: focussedOp === index, className: "OKE-Dropdown__option", ref: function (el) {
97
- return focussedOp === index && el && scrollFocussedOpIntoView(el);
98
- }, onClick: function (e) {
99
- if (!option.loading)
100
- handleSelect(option);
101
- setSearchString && setSearchString("");
102
- }, S: S }, option.loading ? (react_1.default.createElement(TextLoader_1.TextLoader, { style: { width: "8rem", height: "1.5rem" } })) : (react_1.default.createElement(OptionContent_1.OptionContent, { option: option, optionsClassName: optionsClassName, invert: invert, S: S, observerRef: options.length === index + 1 ? observerRef : null })))); }))),
103
- genCreateTagButton && genCreateTagButton(options))));
104
- };
105
- exports.OptionsSingle = OptionsSingle;
@@ -1 +0,0 @@
1
- export const StyledOption: import("styled-components").StyledComponent<"li", any, {}, never>;
@@ -1,61 +0,0 @@
1
- "use strict";
2
- var __makeTemplateObject = (this && this.__makeTemplateObject) || function (cooked, raw) {
3
- if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; }
4
- return cooked;
5
- };
6
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
7
- if (k2 === undefined) k2 = k;
8
- var desc = Object.getOwnPropertyDescriptor(m, k);
9
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
10
- desc = { enumerable: true, get: function() { return m[k]; } };
11
- }
12
- Object.defineProperty(o, k2, desc);
13
- }) : (function(o, m, k, k2) {
14
- if (k2 === undefined) k2 = k;
15
- o[k2] = m[k];
16
- }));
17
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
18
- Object.defineProperty(o, "default", { enumerable: true, value: v });
19
- }) : function(o, v) {
20
- o["default"] = v;
21
- });
22
- var __importStar = (this && this.__importStar) || (function () {
23
- var ownKeys = function(o) {
24
- ownKeys = Object.getOwnPropertyNames || function (o) {
25
- var ar = [];
26
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
27
- return ar;
28
- };
29
- return ownKeys(o);
30
- };
31
- return function (mod) {
32
- if (mod && mod.__esModule) return mod;
33
- var result = {};
34
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
35
- __setModuleDefault(result, mod);
36
- return result;
37
- };
38
- })();
39
- Object.defineProperty(exports, "__esModule", { value: true });
40
- exports.StyledOption = void 0;
41
- var styled_components_1 = __importStar(require("styled-components"));
42
- var themes_1 = require("../../../../themes");
43
- var mixins_1 = require("../../../../themes/mixins");
44
- var utilsOolib_1 = require("../../../../utilsOolib");
45
- var globalVariables_1 = require("../../../../globalStyles/globalVariables");
46
- exports.StyledOption = styled_components_1.default.li(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n display: flex;\n align-items: center;\n padding: ", ";\n ", "\n ", ";\n\n background-color: ", ";\n\n ", "\n\n &:first-of-type {\n margin-top: 1rem;\n }\n\n &:last-of-type {\n margin-bottom: 1rem;\n }\n\n .OKE-Dropdown__optionDesc {\n @include kp-clamp-text(2);\n white-space: normal;\n }\n\n .OKE-Dropdown__optionImg {\n flex: 0 0 auto;\n }\n\n .OKE-Dropdown__checkboxClickArea {\n position: absolute;\n width: 2rem;\n height: 2rem;\n }\n .OKE-Dropdown__checkboxClickArea-box {\n margin-right: 1rem;\n flex-shrink: 0;\n }\n"], ["\n display: flex;\n align-items: center;\n padding: ", ";\n ", "\n ", ";\n\n background-color: ", ";\n\n ", "\n\n &:first-of-type {\n margin-top: 1rem;\n }\n\n &:last-of-type {\n margin-bottom: 1rem;\n }\n\n .OKE-Dropdown__optionDesc {\n @include kp-clamp-text(2);\n white-space: normal;\n }\n\n .OKE-Dropdown__optionImg {\n flex: 0 0 auto;\n }\n\n .OKE-Dropdown__checkboxClickArea {\n position: absolute;\n width: 2rem;\n height: 2rem;\n }\n .OKE-Dropdown__checkboxClickArea-box {\n margin-right: 1rem;\n flex-shrink: 0;\n }\n"])), function (_a) {
47
- var S = _a.S;
48
- return S ? '0.5rem 2rem' : ' 1rem 2rem';
49
- }, function (_a) {
50
- var S = _a.S;
51
- return !S
52
- ? (0, styled_components_1.css)(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n \n min-height: 4rem;\n "], ["\n \n min-height: 4rem;\n "]))) : (0, styled_components_1.css)(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n /* height: 3rem; */\n "], ["\n /* height: 3rem; */\n "])));
53
- }, (0, mixins_1.transition)('background-color'), function (_a) {
54
- var isFocussed = _a.isFocussed, isSelected = _a.isSelected, theme = _a.theme, invert = _a.invert;
55
- return isSelected
56
- ? (invert ? themes_1.colors.greyColor70 : (0, utilsOolib_1.getPrimaryColor10)(theme === null || theme === void 0 ? void 0 : theme.colors))
57
- : isFocussed
58
- ? (invert ? themes_1.colors.greyColor80 : themes_1.colors.greyColor5)
59
- : (invert ? themes_1.colors.greyColor90 : themes_1.colors.white);
60
- }, globalVariables_1.globalHoverOnWhiteBG);
61
- var templateObject_1, templateObject_2, templateObject_3;
@@ -1,13 +0,0 @@
1
- export function SelectDropdown({ invert, value, placeholder, genCustomSelectComp, selectClassName, showOptions, disableSelectTextUpdate, selectConfig, selectStyleOverride, S, disabled, }: {
2
- invert: any;
3
- value: any;
4
- placeholder: any;
5
- genCustomSelectComp: any;
6
- selectClassName: any;
7
- showOptions: any;
8
- disableSelectTextUpdate: any;
9
- selectConfig?: string;
10
- selectStyleOverride: any;
11
- S: any;
12
- disabled: any;
13
- }): any;
@@ -1,54 +0,0 @@
1
- "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
- Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.SelectDropdown = void 0;
7
- var react_1 = __importDefault(require("react"));
8
- var setDropdownSelectText_1 = require("../../utils/setDropdownSelectText");
9
- var Caret_1 = require("../Caret");
10
- var genIcon_1 = require("../../utils/genIcon");
11
- var Typo_1 = require("../../../Typo");
12
- var styled_1 = require("./styled");
13
- var genColor_1 = require("../../utils/genColor");
14
- var SelectDropdown = function (_a) {
15
- var
16
- //from root
17
- invert = _a.invert, value = _a.value, placeholder = _a.placeholder, genCustomSelectComp = _a.genCustomSelectComp, selectClassName = _a.selectClassName,
18
- //from Dropdown
19
- showOptions = _a.showOptions,
20
- //used only for filters, where we dont remove the placeholder even when an option is selected, instead we sustain the blue underline
21
- // && header where we dont update the menu title if one of its options is selected
22
- disableSelectTextUpdate = _a.disableSelectTextUpdate, _b = _a.selectConfig, selectConfig = _b === void 0 ? "all" : _b, selectStyleOverride = _a.selectStyleOverride, //used curr only in access control table & header dropdowns
23
- S = _a.S, disabled = _a.disabled;
24
- var dropdownSelectText = (0, setDropdownSelectText_1.setDropdownSelectText)({
25
- placeholder: placeholder,
26
- disableSelectTextUpdate: disableSelectTextUpdate,
27
- value: value,
28
- isTagsStyle: false,
29
- });
30
- var showElem = function (elem) {
31
- if (selectConfig === "all")
32
- return true;
33
- //else
34
- return selectConfig.indexOf(elem) !== -1 ? true : false;
35
- };
36
- var TypoComp = S ? Typo_1.SANS_2 : Typo_1.SANS_3;
37
- var genSelectComp = function () { return (react_1.default.createElement(styled_1.StyledSelectWrapper, { invert: invert, S: S, disabled: disabled, style: selectStyleOverride },
38
- react_1.default.createElement("div", null,
39
- react_1.default.createElement("div", { style: { display: "flex", gap: "1rem", alignItems: "center" } },
40
- showElem('color') && (0, genColor_1.genColor)({ color: value === null || value === void 0 ? void 0 : value.color }),
41
- showElem("icon") && (0, genIcon_1.genIcon)({ icon: value === null || value === void 0 ? void 0 : value.icon, invert: invert, S: S }),
42
- showElem("display") && (react_1.default.createElement(TypoComp
43
- // semibold={
44
- // dropdownSelectText.desc && showElem("desc") ? true : undefined
45
- // }
46
- , {
47
- // semibold={
48
- // dropdownSelectText.desc && showElem("desc") ? true : undefined
49
- // }
50
- className: "".concat(selectClassName || "", " ").concat(!value && placeholder) }, dropdownSelectText.display)))),
51
- react_1.default.createElement(Caret_1.Caret, { showOptions: showOptions, invert: invert, disabled: disabled }))); };
52
- return genCustomSelectComp ? genCustomSelectComp() : genSelectComp();
53
- };
54
- exports.SelectDropdown = SelectDropdown;
@@ -1 +0,0 @@
1
- export const StyledSelectWrapper: import("styled-components").StyledComponent<"div", any, {}, never>;
@@ -1,71 +0,0 @@
1
- "use strict";
2
- var __makeTemplateObject = (this && this.__makeTemplateObject) || function (cooked, raw) {
3
- if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; }
4
- return cooked;
5
- };
6
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
7
- if (k2 === undefined) k2 = k;
8
- var desc = Object.getOwnPropertyDescriptor(m, k);
9
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
10
- desc = { enumerable: true, get: function() { return m[k]; } };
11
- }
12
- Object.defineProperty(o, k2, desc);
13
- }) : (function(o, m, k, k2) {
14
- if (k2 === undefined) k2 = k;
15
- o[k2] = m[k];
16
- }));
17
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
18
- Object.defineProperty(o, "default", { enumerable: true, value: v });
19
- }) : function(o, v) {
20
- o["default"] = v;
21
- });
22
- var __importStar = (this && this.__importStar) || (function () {
23
- var ownKeys = function(o) {
24
- ownKeys = Object.getOwnPropertyNames || function (o) {
25
- var ar = [];
26
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
27
- return ar;
28
- };
29
- return ownKeys(o);
30
- };
31
- return function (mod) {
32
- if (mod && mod.__esModule) return mod;
33
- var result = {};
34
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
35
- __setModuleDefault(result, mod);
36
- return result;
37
- };
38
- })();
39
- Object.defineProperty(exports, "__esModule", { value: true });
40
- exports.StyledSelectWrapper = void 0;
41
- var styled_components_1 = __importStar(require("styled-components"));
42
- var themes_1 = require("../../../../themes");
43
- var utilsOolib_1 = require("../../../../utilsOolib");
44
- var mixins_1 = require("../../../../themes/mixins");
45
- exports.StyledSelectWrapper = styled_components_1.default.div(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n display: flex;\n align-items: center;\n justify-content: space-between;\n cursor: pointer;\n position: relative;\n border-radius: 2px;\n min-height: 4rem;\n padding: 0 2rem;\n background-color: ", ";\n color: ", "; \n ", "\n ", "\n ", "\n\n &::after{\n content: '';\n position: absolute;\n width: 0;\n height: 2px;\n bottom: 0;\n right: 0;\n background-color: ", ";\n ", "\n }\n \n\n &:hover {\n background-color: ", ";\n }\n\n &.focussed {\n background-color: ", ";\n &::after{\n width: 100%;\n }\n }\n"], ["\n display: flex;\n align-items: center;\n justify-content: space-between;\n cursor: pointer;\n position: relative;\n border-radius: 2px;\n min-height: 4rem;\n padding: 0 2rem;\n background-color: ", ";\n color: ", "; \n ", "\n ", "\n ", "\n\n &::after{\n content: '';\n position: absolute;\n width: 0;\n height: 2px;\n bottom: 0;\n right: 0;\n background-color: ", ";\n ", "\n }\n \n\n &:hover {\n background-color: ", ";\n }\n\n &.focussed {\n background-color: ", ";\n &::after{\n width: 100%;\n }\n }\n"])), function (_a) {
46
- var invert = _a.invert;
47
- return invert ? themes_1.colors.greyColor80 : themes_1.colors.greyColor5;
48
- }, function (_a) {
49
- var disabled = _a.disabled, invert = _a.invert;
50
- return disabled
51
- ? themes_1.colors.greyColor40
52
- : invert
53
- ? themes_1.colors.greyColor5
54
- : themes_1.colors.greyColor100;
55
- }, (0, mixins_1.transition)('background-color'), function (_a) {
56
- var S = _a.S;
57
- return S && (0, styled_components_1.css)(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n min-height: auto;\n height: 3rem;\n "], ["\n min-height: auto;\n height: 3rem;\n "])));
58
- }, function (_a) {
59
- var disabled = _a.disabled;
60
- return disabled && (0, styled_components_1.css)(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n pointer-events: none;\n "], ["\n pointer-events: none;\n "])));
61
- }, function (_a) {
62
- var invert = _a.invert, theme = _a.theme;
63
- return invert ? themes_1.colors.white : (0, utilsOolib_1.getPrimaryColor100)(theme === null || theme === void 0 ? void 0 : theme.colors);
64
- }, (0, mixins_1.transition)('width'), function (_a) {
65
- var invert = _a.invert;
66
- return invert ? themes_1.colors.greyColor70 : themes_1.colors.greyColor10;
67
- }, function (_a) {
68
- var invert = _a.invert;
69
- return invert ? themes_1.colors.greyColor70 : themes_1.colors.greyColor10;
70
- });
71
- var templateObject_1, templateObject_2, templateObject_3;
@@ -1,18 +0,0 @@
1
- export function SelectTagsInput({ invert, id, value, disabled, handleSelect, searchString, setSearchString, placeholder, setFocusSelectTagsInput, focusSelectTagsInput, single_multi, showOptions, S, tagColor, style }: {
2
- invert: any;
3
- id: any;
4
- value: any;
5
- disabled: any;
6
- handleSelect: any;
7
- searchString: any;
8
- setSearchString: any;
9
- placeholder: any;
10
- setFocusSelectTagsInput: any;
11
- focusSelectTagsInput: any;
12
- single_multi: any;
13
- showOptions: any;
14
- S: any;
15
- tagColor: any;
16
- style: any;
17
- }): React.JSX.Element;
18
- import React from "react";