@geneui/components 3.0.0-next-fa529af-03102024 → 3.0.0-next-77c6918-09102024

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 (106) hide show
  1. package/ActionableList/index.js +5 -5
  2. package/AdvancedSearch/index.js +4 -4
  3. package/Alert/index.js +1 -1
  4. package/Avatar/index.js +1 -1
  5. package/Breadcrumb/index.js +3 -3
  6. package/Card/index.js +3 -3
  7. package/CardList/index.js +10 -10
  8. package/{CellMeasurerCache-0b14f9d9.js → CellMeasurerCache-f5f86ede.js} +1 -1
  9. package/Charts/index.js +3 -3
  10. package/Checkbox/index.js +2 -5
  11. package/CheckboxGroup/index.js +2 -5
  12. package/CheckboxGroupWithSearch/index.js +3 -3
  13. package/ComboBox/index.js +2 -5
  14. package/Copy/index.js +2 -5
  15. package/Counter/index.js +4 -4
  16. package/DateFilter/index.js +4 -4
  17. package/DatePickerInput/index.js +4 -4
  18. package/Drawer/index.js +2 -5
  19. package/Dropdown/index.js +7 -7
  20. package/Editor/index.js +1 -1
  21. package/ExtendedInput/index.js +3 -3
  22. package/Form/index.js +6 -6
  23. package/FormableCheckbox/index.js +3 -6
  24. package/FormableDatePicker/index.js +5 -5
  25. package/FormableDropdown/index.js +6 -6
  26. package/FormableEditor/index.js +2 -2
  27. package/{FormableHOC-a4ebfd24.js → FormableHOC-85f89a81.js} +1 -1
  28. package/FormableMultiSelectDropdown/index.js +6 -6
  29. package/FormableNumberInput/index.js +4 -4
  30. package/FormableRadio/index.js +2 -2
  31. package/FormableSwitcher/index.js +2 -2
  32. package/FormableTextInput/index.js +4 -4
  33. package/FormableUploader/index.js +4 -4
  34. package/GeneUIProvider/index.js +4 -1
  35. package/Grid/index.js +1 -1
  36. package/HelperText/index.js +5 -7
  37. package/Holder/index.js +2 -5
  38. package/Image/index.js +5 -8
  39. package/ImagePreview/index.js +3 -5
  40. package/InteractiveWidget/index.js +4 -6
  41. package/Label/index.js +4 -6
  42. package/Menu/index.js +3 -3
  43. package/MobilePopup/index.js +3 -3
  44. package/Modal/index.js +1 -1
  45. package/ModuleTitle/index.js +2 -5
  46. package/NavigationMenu/index.js +3 -3
  47. package/Notification/index.js +1 -1
  48. package/Option/index.js +3 -3
  49. package/Overlay/index.js +2 -5
  50. package/Overspread/index.js +5 -5
  51. package/Pagination/index.js +6 -6
  52. package/Pill/index.js +67 -0
  53. package/Popover/index.js +1 -1
  54. package/PopoverV2/index.js +2 -2
  55. package/Products/index.js +1 -1
  56. package/Profile/index.js +3 -3
  57. package/Radio/index.js +1 -1
  58. package/RadioGroup/index.js +1 -1
  59. package/Range/index.js +1 -1
  60. package/Scrollbar/index.js +1 -1
  61. package/Search/index.js +3 -3
  62. package/SearchWithDropdown/index.js +5 -5
  63. package/Section/index.js +1 -1
  64. package/Slider/index.js +3 -3
  65. package/Status/index.js +1 -7
  66. package/Steps/index.js +5 -5
  67. package/SuggestionList/index.js +1 -1
  68. package/Switcher/index.js +1 -1
  69. package/Table/index.js +12 -12
  70. package/TableCompositions/index.js +10 -10
  71. package/Tag/index.js +1 -1
  72. package/Textarea/index.js +3 -3
  73. package/TimePicker/index.js +4 -4
  74. package/Title/index.js +1 -1
  75. package/Toaster/index.js +1 -1
  76. package/Tooltip/index.js +1 -8
  77. package/TransferList/index.js +4 -4
  78. package/Uploader/index.js +3 -3
  79. package/ValidatableCheckbox/index.js +2 -5
  80. package/ValidatableDatePicker/index.js +4 -4
  81. package/ValidatableDropdown/index.js +5 -5
  82. package/ValidatableElements/index.js +5 -5
  83. package/ValidatableMultiSelectDropdown/index.js +5 -5
  84. package/ValidatableNumberInput/index.js +3 -3
  85. package/ValidatableRadio/index.js +1 -1
  86. package/ValidatableSwitcher/index.js +1 -1
  87. package/ValidatableTextInput/index.js +3 -3
  88. package/ValidatableTimeInput/index.js +3 -3
  89. package/ValidatableUploader/index.js +3 -3
  90. package/Widget/index.js +2 -5
  91. package/{configs-34847b77.js → configs-00612ce0.js} +1 -1
  92. package/hooks/useDeviceType.js +1 -1
  93. package/{index-5a08e021.js → index-3e0ca61d.js} +1 -1
  94. package/{index-24537904.js → index-79ed03c9.js} +4 -4
  95. package/{index-59637c99.js → index-abbcc5bb.js} +5 -5
  96. package/{index-0c18f902.js → index-c92894e2.js} +642 -39
  97. package/index.d.ts +1 -0
  98. package/index.js +10 -9
  99. package/lib/atoms/HelperText/HelperText.d.ts +5 -0
  100. package/lib/atoms/Pill/Pill.d.ts +50 -0
  101. package/lib/atoms/Pill/index.d.ts +1 -0
  102. package/lib/molecules/Tooltip/Tooltip.d.ts +30 -23
  103. package/lib/providers/GeneUIProvider/GeneUIProvider.d.ts +1 -0
  104. package/package.json +1 -1
  105. package/{react-beautiful-dnd.esm-1cdf39df.js → react-beautiful-dnd.esm-fa2b11a1.js} +1 -1
  106. package/{useEllipsisDetection-4d997d5d.js → useEllipsisDetection-c1c9ad94.js} +7 -3
package/index.d.ts CHANGED
@@ -26,6 +26,7 @@ export { default as Avatar } from './lib/atoms/Avatar/index';
26
26
  export { default as LinkButton } from './lib/atoms/LinkButton/index';
27
27
  export { default as HelperText } from './lib/atoms/HelperText';
28
28
  export { default as Loader } from './lib/atoms/Loader';
29
+ export { default as Pill } from './lib/atoms/Pill';
29
30
  export { Row, Col } from './lib/molecules/Grid';
30
31
  export { Tab, Tabs } from './lib/molecules/Tabs';
31
32
  export { Step, Steps } from './lib/molecules/Steps';
package/index.js CHANGED
@@ -14,7 +14,7 @@ export { default as Scrollbar } from './Scrollbar/index.js';
14
14
  export { default as Time } from './Time/index.js';
15
15
  export { default as Empty } from './Empty/index.js';
16
16
  export { default as Popover } from './Popover/index.js';
17
- export { P as PopoverV2 } from './index-5a08e021.js';
17
+ export { P as PopoverV2 } from './index-3e0ca61d.js';
18
18
  export { default as Title } from './Title/index.js';
19
19
  export { default as Image } from './Image/index.js';
20
20
  export { default as KeyValue } from './KeyValue/index.js';
@@ -26,6 +26,7 @@ export { default as Avatar } from './Avatar/index.js';
26
26
  export { default as LinkButton } from './LinkButton/index.js';
27
27
  export { default as HelperText } from './HelperText/index.js';
28
28
  export { default as Loader } from './Loader/index.js';
29
+ export { default as Pill } from './Pill/index.js';
29
30
  export { Col, Row } from './Grid/index.js';
30
31
  export { Tab, Tabs } from './Tabs/index.js';
31
32
  export { Step, Steps } from './Steps/index.js';
@@ -35,7 +36,7 @@ export { default as Checkbox } from './Checkbox/index.js';
35
36
  export { default as Card } from './Card/index.js';
36
37
  export { default as Tag } from './Tag/index.js';
37
38
  export { default as Alert, alertTypes } from './Alert/index.js';
38
- export { T as Tooltip } from './index-0c18f902.js';
39
+ export { T as Tooltip } from './index-c92894e2.js';
39
40
  export { default as Range } from './Range/index.js';
40
41
  export { default as Slider } from './Slider/index.js';
41
42
  export { default as Pagination } from './Pagination/index.js';
@@ -88,7 +89,7 @@ export { default as FormableUploader } from './FormableUploader/index.js';
88
89
  export { default as FormableSwitcher } from './FormableSwitcher/index.js';
89
90
  export { default as FormableEditor } from './FormableEditor/index.js';
90
91
  export { default as FormableRadio } from './FormableRadio/index.js';
91
- export { F as FormableHOC } from './FormableHOC-a4ebfd24.js';
92
+ export { F as FormableHOC } from './FormableHOC-85f89a81.js';
92
93
  export { default as Toaster, toasterPositions } from './Toaster/index.js';
93
94
  export { default as SearchWithDropdown } from './SearchWithDropdown/index.js';
94
95
  export { default as CheckboxGroupWithSearch } from './CheckboxGroupWithSearch/index.js';
@@ -97,8 +98,8 @@ export { default as Overspread } from './Overspread/index.js';
97
98
  export { default as DatePicker } from './DatePicker/index.js';
98
99
  export { default as DateFilter } from './DateFilter/index.js';
99
100
  export { ComboTable, PaginationSelector, PaperWrapper, TableContainer, TableHeader, TablePagination, TableTitle, WithHeader, WithTitle } from './TableCompositions/index.js';
100
- export { D as Dropdown } from './index-24537904.js';
101
- export { T as Table } from './index-59637c99.js';
101
+ export { D as Dropdown } from './index-79ed03c9.js';
102
+ export { T as Table } from './index-abbcc5bb.js';
102
103
  export { CardList, WrappedCardList } from './CardList/index.js';
103
104
  import 'react';
104
105
  import 'prop-types';
@@ -126,7 +127,7 @@ export { default as useUpdatableRef } from './hooks/useUpdatableRef.js';
126
127
  export { default as useDidMount } from './hooks/useDidMount.js';
127
128
  export { default as useBodyScroll } from './hooks/useBodyScroll.js';
128
129
  export { default as useImgDownload } from './hooks/useImgDownload.js';
129
- export { u as useEllipsisDetection } from './useEllipsisDetection-4d997d5d.js';
130
+ export { u as useEllipsisDetection } from './useEllipsisDetection-c1c9ad94.js';
130
131
  import './tslib.es6-f211516f.js';
131
132
  import './index-031ff73c.js';
132
133
  import './style-inject.es-746bb8ed.js';
@@ -134,7 +135,7 @@ import './ArrowLeft-b88e2ba8.js';
134
135
  import './dateValidation-67caec66.js';
135
136
  import './_commonjsHelpers-24198af3.js';
136
137
  import 'react-dom';
137
- import './configs-34847b77.js';
138
+ import './configs-00612ce0.js';
138
139
  import './_rollupPluginBabelHelpers-a83240e1.js';
139
140
  import './index-5f37f281.js';
140
141
  import './checkboxRadioSwitcher-5b69d7bd.js';
@@ -154,6 +155,6 @@ import './index-262edd7a.js';
154
155
  import './index-b3a30cb9.js';
155
156
  import './objectWithoutPropertiesLoose-e1596bdb.js';
156
157
  import './clsx.m-2bb6df4b.js';
157
- import './CellMeasurerCache-0b14f9d9.js';
158
+ import './CellMeasurerCache-f5f86ede.js';
158
159
  import './redux-e591c1b8.js';
159
- import './react-beautiful-dnd.esm-1cdf39df.js';
160
+ import './react-beautiful-dnd.esm-fa2b11a1.js';
@@ -34,6 +34,11 @@ interface IHelperTextProps {
34
34
  * When `true`, a loading skeleton is displayed instead of the actual helper text.
35
35
  */
36
36
  isLoading?: boolean;
37
+ /**
38
+ * Additional class for the parent element.
39
+ * This prop should be used to set placement properties for the element relative to its parent using BEM conventions.
40
+ */
41
+ className?: string;
37
42
  }
38
43
  /**
39
44
  * The Helper Text provides users with additional information or guidance related to a specific input field in a form. This text helps users understand the expected format, requirements, or purpose of the input, thereby improving form completion accuracy and user confidence.
@@ -0,0 +1,50 @@
1
+ import { FC, JSX } from 'react';
2
+ import './Pill.scss';
3
+ interface IPillProps {
4
+ /**
5
+ * The actual text content to be displayed as pill text.
6
+ */
7
+ text?: string;
8
+ /**
9
+ * Determines the position of the `Icon` relative to the `text`. <br/>
10
+ * **Note:** If `withDot` is `true` and no custom `Icon` is provided, the dot icon will always be displayed before the text, regardless of the `iconAlignment` value.<br/>
11
+ * Possible values: `before` or `after`.
12
+ */
13
+ iconAlignment?: 'before' | 'after';
14
+ /**
15
+ * Pill visual appearance
16
+ * When `isFill` prop set to `true`, the `pill` will have a solid fill, providing a more prominent visual appearance. If `false`, the `pill` will be displayed with an outlined style.
17
+ */
18
+ isFill?: boolean;
19
+ /**
20
+ * Pill size
21
+ * Possible values: `smallNudge | small | medium`
22
+ */
23
+ size?: 'smallNudge' | 'small' | 'medium';
24
+ /**
25
+ * Pill icon <br/>
26
+ * The `Icon` prop accepts a JSX element that will be displayed alongside the `text`
27
+ */
28
+ Icon?: JSX.Element;
29
+ /**
30
+ * Displays a dot `Icon` when no custom `Icon` is provided. <br/>
31
+ * If `true`, a dot icon will be shown unless a custom `Icon` is specified. <br/>
32
+ * If `false`, the dot will be hidden, even if no custom `Icon` is provided.
33
+ */
34
+ withDot?: boolean;
35
+ /**
36
+ * Pill color <br/>
37
+ * Possible values: `informative | neutral | error | success | warning | purple | lagoon | magenta | slate | inverse`
38
+ */
39
+ color?: 'informative' | 'neutral' | 'error' | 'success' | 'warning' | 'purple' | 'lagoon' | 'magenta' | 'slate' | 'inverse';
40
+ /**
41
+ * Additional class for the parent element.
42
+ * This prop should be used to set placement properties for the element relative to its parent using BEM conventions.
43
+ */
44
+ className?: string;
45
+ }
46
+ /**
47
+ * A Pill component used to display concise information or categorize content. Often used for labels or status indicators, Pill components are visually distinct and can convey different meanings through text and color coding.
48
+ */
49
+ declare const Pill: FC<IPillProps>;
50
+ export { IPillProps, Pill as default };
@@ -0,0 +1 @@
1
+ export { IPillProps, default as default } from './Pill';
@@ -1,26 +1,24 @@
1
- import { CSSProperties, JSX, FC } from 'react';
1
+ import { JSX, FC, ReactNode } from 'react';
2
2
  import './Tooltip.scss';
3
- interface ICustomPosition {
4
- left?: number;
5
- top?: number;
6
- }
3
+ export declare const correctPosition: {
4
+ 'bottom-center': string;
5
+ 'bottom-left': string;
6
+ 'bottom-right': string;
7
+ 'left-bottom': string;
8
+ 'left-center': string;
9
+ 'left-top': string;
10
+ 'right-bottom': string;
11
+ 'right-center': string;
12
+ 'right-top': string;
13
+ 'top-center': string;
14
+ 'top-left': string;
15
+ 'top-right': string;
16
+ };
7
17
  export interface ITooltipProps {
8
- /**
9
- * The Tooltip component size<br> Possible values: `default | small`
10
- */
11
- size?: 'default' | 'small';
12
18
  /**
13
19
  * Main content for the component.
14
20
  */
15
21
  text?: string;
16
- /**
17
- * Title for the component.
18
- */
19
- title?: string;
20
- /**
21
- * Style object, to have extra styles.
22
- */
23
- style?: CSSProperties;
24
22
  /**
25
23
  * If `true` the component will be visible without any action.
26
24
  */
@@ -28,7 +26,10 @@ export interface ITooltipProps {
28
26
  /**
29
27
  * Will display the component in the specified location.
30
28
  */
31
- customPosition?: ICustomPosition;
29
+ customPosition?: {
30
+ left?: number;
31
+ top?: number;
32
+ };
32
33
  /**
33
34
  * Any valid React node.
34
35
  */
@@ -36,19 +37,25 @@ export interface ITooltipProps {
36
37
  /**
37
38
  * Positions where will be displayed the Tooltip relates the child component.<br> Possible values: `top | right | bottom | left`
38
39
  */
39
- position?: 'top' | 'right' | 'bottom' | 'left';
40
+ position?: 'top-center' | 'top-left' | 'top-right' | 'right-center' | 'right-bottom' | 'right-top' | 'bottom-center' | 'bottom-left' | 'bottom-right' | 'left-center' | 'left-bottom' | 'left-top' | 'left-bottom';
40
41
  /**
41
42
  * Tooltip padding related to the target element
42
43
  */
43
44
  padding?: number;
44
- /**
45
- * Control with screenType appearance of component
46
- */
47
- screenType?: 'desktop' | 'mobile';
48
45
  /**
49
46
  * In case of `false` value, the children component will rendered without Tooltip.
50
47
  */
51
48
  isVisible?: boolean;
49
+ /**
50
+ * Available style varieties of Empty atom to display <br/>
51
+ * Possible values: `inverse | default`
52
+ */
53
+ appearance?: 'inverse' | 'default';
54
+ Icon?: ReactNode;
52
55
  }
56
+ /**
57
+ A tooltip is a small, elevated surface that appears to provide contextual information when a user hovers over or focuses on a UI element.
58
+ Tooltips should be used to offer helpful plaintext information, not to communicate system feedback. Use a popover instead if you need to deliver structured information or enable interactions.
59
+ */
53
60
  declare const Tooltip: FC<ITooltipProps>;
54
61
  export default Tooltip;
@@ -1,5 +1,6 @@
1
1
  import React, { JSX } from 'react';
2
2
  import 'src/assets/styles/globalStyling.scss';
3
+ import 'src/assets/styles/utils.scss';
3
4
  type ThemesTypes = 'light' | 'dark';
4
5
  type TokensType = {
5
6
  [key: string]: string | number;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@geneui/components",
3
3
  "description": "The Gene UI components library designed for BI tools",
4
- "version": "3.0.0-next-fa529af-03102024",
4
+ "version": "3.0.0-next-77c6918-09102024",
5
5
  "author": "SoftConstruct",
6
6
  "homepage": "https://github.com/softconstruct/gene-ui-components#readme",
7
7
  "repository": {
@@ -2,7 +2,7 @@ import React__default, { useLayoutEffect, useEffect, useMemo as useMemo$1, useCo
2
2
  import { a as _setPrototypeOf, b as _objectWithoutPropertiesLoose, c as _extends } from './objectWithoutPropertiesLoose-e1596bdb.js';
3
3
  import { c as compose, b as bindActionCreators$1, a as createStore$1, d as applyMiddleware } from './redux-e591c1b8.js';
4
4
  import PropTypes from 'prop-types';
5
- import { r as reactIsExports$1 } from './index-0c18f902.js';
5
+ import { r as reactIsExports$1 } from './index-c92894e2.js';
6
6
  import ReactDOM__default, { unstable_batchedUpdates } from 'react-dom';
7
7
 
8
8
  function _inheritsLoose(t, o) {
@@ -12,7 +12,12 @@ const useEllipsisDetection = (ref, externalDependencies = []) => {
12
12
  const { scrollWidth, clientWidth, scrollHeight, clientHeight } = ref.current;
13
13
  setIsTruncated(scrollWidth > clientWidth || scrollHeight > clientHeight + EQUAL_HEIGHT_DIFF);
14
14
  };
15
- useEffect(() => handleResize(), []);
15
+ useEffect(() => {
16
+ if (!ref.current || !('classList' in ref.current) || ref.current.classList.contains('ellipsis-text'))
17
+ return;
18
+ ref.current.classList.add('ellipsis-text');
19
+ }, [ref]);
20
+ useEffect(() => handleResize(), [...externalDependencies]);
16
21
  useEffect(() => {
17
22
  const debounce = () => debounceCallback(handleResize, 100);
18
23
  window.addEventListener('resize', debounce);
@@ -25,8 +30,7 @@ const useEllipsisDetection = (ref, externalDependencies = []) => {
25
30
  (_a = ref === null || ref === void 0 ? void 0 : ref.current) === null || _a === void 0 ? void 0 : _a.scrollWidth,
26
31
  (_b = ref === null || ref === void 0 ? void 0 : ref.current) === null || _b === void 0 ? void 0 : _b.clientWidth,
27
32
  (_c = ref === null || ref === void 0 ? void 0 : ref.current) === null || _c === void 0 ? void 0 : _c.scrollHeight,
28
- (_d = ref === null || ref === void 0 ? void 0 : ref.current) === null || _d === void 0 ? void 0 : _d.clientHeight,
29
- ...externalDependencies
33
+ (_d = ref === null || ref === void 0 ? void 0 : ref.current) === null || _d === void 0 ? void 0 : _d.clientHeight
30
34
  ]);
31
35
  return isTruncated;
32
36
  };