@elliemae/ds-utilities 2.3.0-alpha.9 → 2.3.0-next.0

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 (215) hide show
  1. package/cjs/capitalize.js +7 -0
  2. package/cjs/compose.js +38 -0
  3. package/cjs/getComponentFromProps.js +30 -0
  4. package/cjs/hooks/index.js +63 -0
  5. package/cjs/hooks/useCancellableDelayedCallback.js +26 -0
  6. package/cjs/hooks/useDerivedStateFromProps.js +56 -0
  7. package/cjs/hooks/useExecutionTimer.js +31 -0
  8. package/cjs/hooks/useExpandState.js +133 -0
  9. package/cjs/hooks/useHotkeys.js +25 -0
  10. package/cjs/hooks/useHoverHandlersDelay.js +28 -0
  11. package/cjs/hooks/useIsShowingEllipsis.js +36 -0
  12. package/cjs/hooks/useOnElementResize.js +38 -0
  13. package/cjs/hooks/useParentElement.js +16 -0
  14. package/cjs/hooks/usePrevious.js +13 -0
  15. package/cjs/hooks/useResizeObserver.js +33 -0
  16. package/cjs/hooks/useSetRef.js +15 -0
  17. package/cjs/hooks/useShouldRecalculate.js +17 -0
  18. package/cjs/hooks/useWindowScrollerList.js +65 -0
  19. package/cjs/hooks/useWindowSize.js +27 -0
  20. package/cjs/index.js +268 -0
  21. package/cjs/onClickHandlerForNonInteractiveElements.js +22 -0
  22. package/cjs/operators.js +63 -0
  23. package/cjs/platform.js +9 -0
  24. package/cjs/reactTypesUtility.js +35 -0
  25. package/cjs/scrollingTimer.js +24 -0
  26. package/cjs/system.js +43 -0
  27. package/cjs/timeUtils.js +25 -0
  28. package/cjs/utils.js +263 -0
  29. package/cjs/validations.js +44 -0
  30. package/esm/capitalize.js +3 -0
  31. package/esm/compose.js +34 -0
  32. package/esm/getComponentFromProps.js +23 -0
  33. package/esm/hooks/index.js +19 -0
  34. package/esm/hooks/useCancellableDelayedCallback.js +24 -0
  35. package/esm/hooks/useDerivedStateFromProps.js +54 -0
  36. package/esm/hooks/useExecutionTimer.js +29 -0
  37. package/esm/hooks/useExpandState.js +127 -0
  38. package/esm/hooks/useHotkeys.js +19 -0
  39. package/{dist/esm → esm}/hooks/useHoverHandlersDelay.js +12 -15
  40. package/{dist/esm → esm}/hooks/useIsShowingEllipsis.js +12 -9
  41. package/esm/hooks/useOnElementResize.js +34 -0
  42. package/esm/hooks/useParentElement.js +12 -0
  43. package/esm/hooks/usePrevious.js +11 -0
  44. package/esm/hooks/useResizeObserver.js +26 -0
  45. package/esm/hooks/useSetRef.js +11 -0
  46. package/esm/hooks/useShouldRecalculate.js +15 -0
  47. package/{dist/esm → esm}/hooks/useWindowScrollerList.js +29 -20
  48. package/esm/hooks/useWindowSize.js +25 -0
  49. package/esm/index.js +32 -0
  50. package/esm/onClickHandlerForNonInteractiveElements.js +20 -0
  51. package/esm/operators.js +46 -0
  52. package/esm/platform.js +4 -0
  53. package/esm/reactTypesUtility.js +22 -0
  54. package/esm/scrollingTimer.js +20 -0
  55. package/esm/system.js +37 -0
  56. package/esm/timeUtils.js +20 -0
  57. package/esm/utils.js +99 -0
  58. package/esm/validations.js +38 -0
  59. package/package.json +72 -74
  60. package/{dist/types → types}/capitalize.d.ts +0 -0
  61. package/{dist/types → types}/compose.d.ts +1 -2
  62. package/types/getComponentFromProps.d.ts +2 -0
  63. package/types/hooks/index.d.ts +19 -0
  64. package/types/hooks/useCancellableDelayedCallback.d.ts +1 -0
  65. package/types/hooks/useDerivedStateFromProps.d.ts +1 -0
  66. package/types/hooks/useExecutionTimer.d.ts +1 -0
  67. package/{dist/types → types}/hooks/useExpandState.d.ts +2 -3
  68. package/types/hooks/useHotkeys.d.ts +5 -0
  69. package/{dist/types → types}/hooks/useHoverHandlersDelay.d.ts +2 -3
  70. package/{dist/types → types}/hooks/useIsShowingEllipsis.d.ts +0 -0
  71. package/types/hooks/useOnElementResize.d.ts +2 -0
  72. package/{dist/types → types}/hooks/useParentElement.d.ts +0 -0
  73. package/types/hooks/usePrevious.d.ts +2 -0
  74. package/types/hooks/useResizeObserver.d.ts +2 -0
  75. package/{dist/types → types}/hooks/useSetRef.d.ts +0 -0
  76. package/types/hooks/useShouldRecalculate.d.ts +1 -0
  77. package/types/hooks/useWindowScrollerList.d.ts +4 -0
  78. package/types/hooks/useWindowSize.d.ts +1 -0
  79. package/types/index.d.ts +13 -0
  80. package/{dist/types → types}/onClickHandlerForNonInteractiveElements.d.ts +7 -7
  81. package/{dist/types → types}/operators.d.ts +0 -0
  82. package/{dist/types → types}/platform.d.ts +0 -0
  83. package/{dist/types → types}/reactTypesUtility.d.ts +0 -0
  84. package/types/scrollingTimer.d.ts +1 -0
  85. package/{dist/types → types}/system.d.ts +0 -0
  86. package/{dist/types → types}/timeUtils.d.ts +0 -0
  87. package/{dist/types → types}/utils.d.ts +0 -0
  88. package/{dist/types → types}/validations.d.ts +0 -0
  89. package/dist/cjs/capitalize.js +0 -35
  90. package/dist/cjs/capitalize.js.map +0 -7
  91. package/dist/cjs/compose.js +0 -45
  92. package/dist/cjs/compose.js.map +0 -7
  93. package/dist/cjs/getComponentFromProps.js +0 -48
  94. package/dist/cjs/getComponentFromProps.js.map +0 -7
  95. package/dist/cjs/hooks/index.js +0 -71
  96. package/dist/cjs/hooks/index.js.map +0 -7
  97. package/dist/cjs/hooks/useCancellableDelayedCallback.js +0 -51
  98. package/dist/cjs/hooks/useCancellableDelayedCallback.js.map +0 -7
  99. package/dist/cjs/hooks/useDerivedStateFromProps.js +0 -67
  100. package/dist/cjs/hooks/useDerivedStateFromProps.js.map +0 -7
  101. package/dist/cjs/hooks/useExecutionTimer.js +0 -50
  102. package/dist/cjs/hooks/useExecutionTimer.js.map +0 -7
  103. package/dist/cjs/hooks/useExpandState.js +0 -120
  104. package/dist/cjs/hooks/useExpandState.js.map +0 -7
  105. package/dist/cjs/hooks/useHotkeys.js +0 -45
  106. package/dist/cjs/hooks/useHotkeys.js.map +0 -7
  107. package/dist/cjs/hooks/useHoverHandlersDelay.js +0 -58
  108. package/dist/cjs/hooks/useHoverHandlersDelay.js.map +0 -7
  109. package/dist/cjs/hooks/useIsShowingEllipsis.js +0 -58
  110. package/dist/cjs/hooks/useIsShowingEllipsis.js.map +0 -7
  111. package/dist/cjs/hooks/useOnElementResize.js +0 -54
  112. package/dist/cjs/hooks/useOnElementResize.js.map +0 -7
  113. package/dist/cjs/hooks/useParentElement.js +0 -43
  114. package/dist/cjs/hooks/useParentElement.js.map +0 -7
  115. package/dist/cjs/hooks/usePrevious.js +0 -44
  116. package/dist/cjs/hooks/usePrevious.js.map +0 -7
  117. package/dist/cjs/hooks/useResizeObserver.js +0 -60
  118. package/dist/cjs/hooks/useResizeObserver.js.map +0 -7
  119. package/dist/cjs/hooks/useSetRef.js +0 -42
  120. package/dist/cjs/hooks/useSetRef.js.map +0 -7
  121. package/dist/cjs/hooks/useShouldRecalculate.js +0 -44
  122. package/dist/cjs/hooks/useShouldRecalculate.js.map +0 -7
  123. package/dist/cjs/hooks/useWindowScrollerList.js +0 -83
  124. package/dist/cjs/hooks/useWindowScrollerList.js.map +0 -7
  125. package/dist/cjs/hooks/useWindowSize.js +0 -57
  126. package/dist/cjs/hooks/useWindowSize.js.map +0 -7
  127. package/dist/cjs/index.js +0 -146
  128. package/dist/cjs/index.js.map +0 -7
  129. package/dist/cjs/onClickHandlerForNonInteractiveElements.js +0 -49
  130. package/dist/cjs/onClickHandlerForNonInteractiveElements.js.map +0 -7
  131. package/dist/cjs/operators.js +0 -68
  132. package/dist/cjs/operators.js.map +0 -7
  133. package/dist/cjs/platform.js +0 -37
  134. package/dist/cjs/platform.js.map +0 -7
  135. package/dist/cjs/reactTypesUtility.js +0 -58
  136. package/dist/cjs/reactTypesUtility.js.map +0 -7
  137. package/dist/cjs/scrollingTimer.js +0 -46
  138. package/dist/cjs/scrollingTimer.js.map +0 -7
  139. package/dist/cjs/system.js +0 -60
  140. package/dist/cjs/system.js.map +0 -7
  141. package/dist/cjs/timeUtils.js +0 -43
  142. package/dist/cjs/timeUtils.js.map +0 -7
  143. package/dist/cjs/utils.js +0 -127
  144. package/dist/cjs/utils.js.map +0 -7
  145. package/dist/cjs/validations.js +0 -57
  146. package/dist/cjs/validations.js.map +0 -7
  147. package/dist/esm/capitalize.js +0 -6
  148. package/dist/esm/capitalize.js.map +0 -7
  149. package/dist/esm/compose.js +0 -16
  150. package/dist/esm/compose.js.map +0 -7
  151. package/dist/esm/getComponentFromProps.js +0 -19
  152. package/dist/esm/getComponentFromProps.js.map +0 -7
  153. package/dist/esm/hooks/index.js +0 -42
  154. package/dist/esm/hooks/index.js.map +0 -7
  155. package/dist/esm/hooks/useCancellableDelayedCallback.js +0 -22
  156. package/dist/esm/hooks/useCancellableDelayedCallback.js.map +0 -7
  157. package/dist/esm/hooks/useDerivedStateFromProps.js +0 -38
  158. package/dist/esm/hooks/useDerivedStateFromProps.js.map +0 -7
  159. package/dist/esm/hooks/useExecutionTimer.js +0 -21
  160. package/dist/esm/hooks/useExecutionTimer.js.map +0 -7
  161. package/dist/esm/hooks/useExpandState.js +0 -91
  162. package/dist/esm/hooks/useExpandState.js.map +0 -7
  163. package/dist/esm/hooks/useHotkeys.js +0 -16
  164. package/dist/esm/hooks/useHotkeys.js.map +0 -7
  165. package/dist/esm/hooks/useHoverHandlersDelay.js.map +0 -7
  166. package/dist/esm/hooks/useIsShowingEllipsis.js.map +0 -7
  167. package/dist/esm/hooks/useOnElementResize.js +0 -25
  168. package/dist/esm/hooks/useOnElementResize.js.map +0 -7
  169. package/dist/esm/hooks/useParentElement.js +0 -14
  170. package/dist/esm/hooks/useParentElement.js.map +0 -7
  171. package/dist/esm/hooks/usePrevious.js +0 -15
  172. package/dist/esm/hooks/usePrevious.js.map +0 -7
  173. package/dist/esm/hooks/useResizeObserver.js +0 -31
  174. package/dist/esm/hooks/useResizeObserver.js.map +0 -7
  175. package/dist/esm/hooks/useSetRef.js +0 -13
  176. package/dist/esm/hooks/useSetRef.js.map +0 -7
  177. package/dist/esm/hooks/useShouldRecalculate.js +0 -15
  178. package/dist/esm/hooks/useShouldRecalculate.js.map +0 -7
  179. package/dist/esm/hooks/useWindowScrollerList.js.map +0 -7
  180. package/dist/esm/hooks/useWindowSize.js +0 -28
  181. package/dist/esm/hooks/useWindowSize.js.map +0 -7
  182. package/dist/esm/index.js +0 -206
  183. package/dist/esm/index.js.map +0 -7
  184. package/dist/esm/onClickHandlerForNonInteractiveElements.js +0 -20
  185. package/dist/esm/onClickHandlerForNonInteractiveElements.js.map +0 -7
  186. package/dist/esm/operators.js +0 -39
  187. package/dist/esm/operators.js.map +0 -7
  188. package/dist/esm/platform.js +0 -8
  189. package/dist/esm/platform.js.map +0 -7
  190. package/dist/esm/reactTypesUtility.js +0 -29
  191. package/dist/esm/reactTypesUtility.js.map +0 -7
  192. package/dist/esm/scrollingTimer.js +0 -17
  193. package/dist/esm/scrollingTimer.js.map +0 -7
  194. package/dist/esm/system.js +0 -31
  195. package/dist/esm/system.js.map +0 -7
  196. package/dist/esm/timeUtils.js +0 -14
  197. package/dist/esm/timeUtils.js.map +0 -7
  198. package/dist/esm/utils.js +0 -136
  199. package/dist/esm/utils.js.map +0 -7
  200. package/dist/esm/validations.js +0 -28
  201. package/dist/esm/validations.js.map +0 -7
  202. package/dist/types/getComponentFromProps.d.ts +0 -3
  203. package/dist/types/hooks/index.d.ts +0 -19
  204. package/dist/types/hooks/useCancellableDelayedCallback.d.ts +0 -2
  205. package/dist/types/hooks/useDerivedStateFromProps.d.ts +0 -2
  206. package/dist/types/hooks/useExecutionTimer.d.ts +0 -2
  207. package/dist/types/hooks/useHotkeys.d.ts +0 -6
  208. package/dist/types/hooks/useOnElementResize.d.ts +0 -2
  209. package/dist/types/hooks/usePrevious.d.ts +0 -2
  210. package/dist/types/hooks/useResizeObserver.d.ts +0 -3
  211. package/dist/types/hooks/useShouldRecalculate.d.ts +0 -2
  212. package/dist/types/hooks/useWindowScrollerList.d.ts +0 -5
  213. package/dist/types/hooks/useWindowSize.d.ts +0 -2
  214. package/dist/types/index.d.ts +0 -13
  215. package/dist/types/scrollingTimer.d.ts +0 -1
package/package.json CHANGED
@@ -1,130 +1,127 @@
1
1
  {
2
2
  "name": "@elliemae/ds-utilities",
3
- "version": "2.3.0-alpha.9",
3
+ "version": "2.3.0-next.0",
4
4
  "license": "MIT",
5
5
  "description": "ICE MT - Dimsum - Utilities",
6
- "files": [
7
- "dist"
8
- ],
9
- "module": "./dist/esm/index.js",
10
- "main": "./dist/cjs/index.js",
11
- "types": "./dist/types/index.d.ts",
6
+ "module": "./esm/index.js",
7
+ "main": "./cjs/index.js",
8
+ "types": "./types/index.d.ts",
12
9
  "exports": {
13
10
  ".": {
14
- "import": "./dist/esm/index.js",
15
- "require": "./dist/cjs/index.js"
11
+ "import": "./esm/index.js",
12
+ "require": "./cjs/index.js"
16
13
  },
17
14
  "./validations": {
18
- "import": "./dist/esm/validations.js",
19
- "require": "./dist/cjs/validations.js"
15
+ "import": "./esm/validations.js",
16
+ "require": "./cjs/validations.js"
20
17
  },
21
18
  "./utils": {
22
- "import": "./dist/esm/utils.js",
23
- "require": "./dist/cjs/utils.js"
19
+ "import": "./esm/utils.js",
20
+ "require": "./cjs/utils.js"
24
21
  },
25
22
  "./timeUtils": {
26
- "import": "./dist/esm/timeUtils.js",
27
- "require": "./dist/cjs/timeUtils.js"
23
+ "import": "./esm/timeUtils.js",
24
+ "require": "./cjs/timeUtils.js"
28
25
  },
29
26
  "./system": {
30
- "import": "./dist/esm/system.js",
31
- "require": "./dist/cjs/system.js"
27
+ "import": "./esm/system.js",
28
+ "require": "./cjs/system.js"
32
29
  },
33
30
  "./scrollingTimer": {
34
- "import": "./dist/esm/scrollingTimer.js",
35
- "require": "./dist/cjs/scrollingTimer.js"
31
+ "import": "./esm/scrollingTimer.js",
32
+ "require": "./cjs/scrollingTimer.js"
36
33
  },
37
34
  "./reactTypesUtility": {
38
- "import": "./dist/esm/reactTypesUtility.js",
39
- "require": "./dist/cjs/reactTypesUtility.js"
35
+ "import": "./esm/reactTypesUtility.js",
36
+ "require": "./cjs/reactTypesUtility.js"
40
37
  },
41
38
  "./platform": {
42
- "import": "./dist/esm/platform.js",
43
- "require": "./dist/cjs/platform.js"
39
+ "import": "./esm/platform.js",
40
+ "require": "./cjs/platform.js"
44
41
  },
45
42
  "./operators": {
46
- "import": "./dist/esm/operators.js",
47
- "require": "./dist/cjs/operators.js"
43
+ "import": "./esm/operators.js",
44
+ "require": "./cjs/operators.js"
48
45
  },
49
46
  "./onClickHandlerForNonInteractiveElements": {
50
- "import": "./dist/esm/onClickHandlerForNonInteractiveElements.js",
51
- "require": "./dist/cjs/onClickHandlerForNonInteractiveElements.js"
47
+ "import": "./esm/onClickHandlerForNonInteractiveElements.js",
48
+ "require": "./cjs/onClickHandlerForNonInteractiveElements.js"
52
49
  },
53
50
  "./hooks/useWindowSize": {
54
- "import": "./dist/esm/hooks/useWindowSize.js",
55
- "require": "./dist/cjs/hooks/useWindowSize.js"
51
+ "import": "./esm/hooks/useWindowSize.js",
52
+ "require": "./cjs/hooks/useWindowSize.js"
56
53
  },
57
54
  "./hooks/useWindowScrollerList": {
58
- "import": "./dist/esm/hooks/useWindowScrollerList.js",
59
- "require": "./dist/cjs/hooks/useWindowScrollerList.js"
55
+ "import": "./esm/hooks/useWindowScrollerList.js",
56
+ "require": "./cjs/hooks/useWindowScrollerList.js"
60
57
  },
61
58
  "./hooks/useShouldRecalculate": {
62
- "import": "./dist/esm/hooks/useShouldRecalculate.js",
63
- "require": "./dist/cjs/hooks/useShouldRecalculate.js"
59
+ "import": "./esm/hooks/useShouldRecalculate.js",
60
+ "require": "./cjs/hooks/useShouldRecalculate.js"
64
61
  },
65
62
  "./hooks/useSetRef": {
66
- "import": "./dist/esm/hooks/useSetRef.js",
67
- "require": "./dist/cjs/hooks/useSetRef.js"
63
+ "import": "./esm/hooks/useSetRef.js",
64
+ "require": "./cjs/hooks/useSetRef.js"
68
65
  },
69
66
  "./hooks/useResizeObserver": {
70
- "import": "./dist/esm/hooks/useResizeObserver.js",
71
- "require": "./dist/cjs/hooks/useResizeObserver.js"
67
+ "import": "./esm/hooks/useResizeObserver.js",
68
+ "require": "./cjs/hooks/useResizeObserver.js"
72
69
  },
73
70
  "./hooks/usePrevious": {
74
- "import": "./dist/esm/hooks/usePrevious.js",
75
- "require": "./dist/cjs/hooks/usePrevious.js"
71
+ "import": "./esm/hooks/usePrevious.js",
72
+ "require": "./cjs/hooks/usePrevious.js"
76
73
  },
77
74
  "./hooks/useParentElement": {
78
- "import": "./dist/esm/hooks/useParentElement.js",
79
- "require": "./dist/cjs/hooks/useParentElement.js"
75
+ "import": "./esm/hooks/useParentElement.js",
76
+ "require": "./cjs/hooks/useParentElement.js"
80
77
  },
81
78
  "./hooks/useOnElementResize": {
82
- "import": "./dist/esm/hooks/useOnElementResize.js",
83
- "require": "./dist/cjs/hooks/useOnElementResize.js"
79
+ "import": "./esm/hooks/useOnElementResize.js",
80
+ "require": "./cjs/hooks/useOnElementResize.js"
84
81
  },
85
82
  "./hooks/useIsShowingEllipsis": {
86
- "import": "./dist/esm/hooks/useIsShowingEllipsis.js",
87
- "require": "./dist/cjs/hooks/useIsShowingEllipsis.js"
83
+ "import": "./esm/hooks/useIsShowingEllipsis.js",
84
+ "require": "./cjs/hooks/useIsShowingEllipsis.js"
88
85
  },
89
86
  "./hooks/useHoverHandlersDelay": {
90
- "import": "./dist/esm/hooks/useHoverHandlersDelay.js",
91
- "require": "./dist/cjs/hooks/useHoverHandlersDelay.js"
87
+ "import": "./esm/hooks/useHoverHandlersDelay.js",
88
+ "require": "./cjs/hooks/useHoverHandlersDelay.js"
92
89
  },
93
90
  "./hooks/useHotkeys": {
94
- "import": "./dist/esm/hooks/useHotkeys.js",
95
- "require": "./dist/cjs/hooks/useHotkeys.js"
91
+ "import": "./esm/hooks/useHotkeys.js",
92
+ "require": "./cjs/hooks/useHotkeys.js"
96
93
  },
97
94
  "./hooks/useExpandState": {
98
- "import": "./dist/esm/hooks/useExpandState.js",
99
- "require": "./dist/cjs/hooks/useExpandState.js"
95
+ "import": "./esm/hooks/useExpandState.js",
96
+ "require": "./cjs/hooks/useExpandState.js"
100
97
  },
101
98
  "./hooks/useExecutionTimer": {
102
- "import": "./dist/esm/hooks/useExecutionTimer.js",
103
- "require": "./dist/cjs/hooks/useExecutionTimer.js"
99
+ "import": "./esm/hooks/useExecutionTimer.js",
100
+ "require": "./cjs/hooks/useExecutionTimer.js"
104
101
  },
105
102
  "./hooks/useDerivedStateFromProps": {
106
- "import": "./dist/esm/hooks/useDerivedStateFromProps.js",
107
- "require": "./dist/cjs/hooks/useDerivedStateFromProps.js"
103
+ "import": "./esm/hooks/useDerivedStateFromProps.js",
104
+ "require": "./cjs/hooks/useDerivedStateFromProps.js"
108
105
  },
109
106
  "./hooks/useCancellableDelayedCallback": {
110
- "import": "./dist/esm/hooks/useCancellableDelayedCallback.js",
111
- "require": "./dist/cjs/hooks/useCancellableDelayedCallback.js"
107
+ "import": "./esm/hooks/useCancellableDelayedCallback.js",
108
+ "require": "./cjs/hooks/useCancellableDelayedCallback.js"
112
109
  },
113
110
  "./hooks": {
114
- "import": "./dist/esm/hooks/index.js",
115
- "require": "./dist/cjs/hooks/index.js"
111
+ "import": "./esm/hooks/index.js",
112
+ "require": "./cjs/hooks/index.js"
116
113
  },
117
114
  "./getComponentFromProps": {
118
- "import": "./dist/esm/getComponentFromProps.js",
119
- "require": "./dist/cjs/getComponentFromProps.js"
115
+ "import": "./esm/getComponentFromProps.js",
116
+ "require": "./cjs/getComponentFromProps.js"
120
117
  },
121
118
  "./compose": {
122
- "import": "./dist/esm/compose.js",
123
- "require": "./dist/cjs/compose.js"
119
+ "import": "./esm/compose.js",
120
+ "require": "./cjs/compose.js"
124
121
  },
125
122
  "./capitalize": {
126
- "import": "./dist/esm/capitalize.js",
127
- "require": "./dist/cjs/capitalize.js"
123
+ "import": "./esm/capitalize.js",
124
+ "require": "./cjs/capitalize.js"
128
125
  }
129
126
  },
130
127
  "sideEffects": [
@@ -136,13 +133,20 @@
136
133
  "url": "https://git.elliemae.io/platform-ui/dimsum.git"
137
134
  },
138
135
  "engines": {
139
- "pnpm": ">=6",
140
- "node": ">=16"
136
+ "npm": ">=7",
137
+ "node": ">=14"
141
138
  },
142
139
  "author": "ICE MT",
140
+ "scripts": {
141
+ "prebuild": "exit 0",
142
+ "predev": "exit 0",
143
+ "build": "node ../../scripts/build/build.js",
144
+ "dev": "cross-env NODE_ENV=development && node ../../scripts/build/build.js -w"
145
+ },
143
146
  "publishConfig": {
144
147
  "access": "public",
145
- "typeSafety": false
148
+ "directory": "dist",
149
+ "generateSubmodules": true
146
150
  },
147
151
  "dependencies": {
148
152
  "hotkeys-js": "~3.8.7",
@@ -157,11 +161,5 @@
157
161
  "lodash": "^4.17.21",
158
162
  "react": "~17.0.2",
159
163
  "react-dom": "^17.0.2"
160
- },
161
- "scripts": {
162
- "prebuild": "exit 0",
163
- "predev": "exit 0",
164
- "build": "node ../../scripts/build/build.js",
165
- "dev": "cross-env NODE_ENV=development && node ../../scripts/build/build.js -w"
166
164
  }
167
165
  }
File without changes
@@ -8,5 +8,4 @@
8
8
  * from right to left. For example, compose(f, g, h) is identical to doing
9
9
  * (...args) => f(g(h(...args))).
10
10
  */
11
- export declare const compose: (...funcs: any[]) => any;
12
- export default compose;
11
+ export declare function compose(...funcs: any[]): any;
@@ -0,0 +1,2 @@
1
+ /// <reference types="react" />
2
+ export default function getComponentFromProps(Component: any, props: any, children?: never[]): JSX.Element | null;
@@ -0,0 +1,19 @@
1
+ export { default as useMeasure } from 'use-measure';
2
+ export { default as useExecutionTimer } from './useExecutionTimer';
3
+ export { default as useExpandState } from './useExpandState';
4
+ export { default as useHotkeys } from './useHotkeys';
5
+ export { default as useHoverHandlersDelay } from './useHoverHandlersDelay';
6
+ export { default as useResizeObserver } from './useResizeObserver';
7
+ export { default as useShouldRecalculate } from './useShouldRecalculate';
8
+ export { default as useWindowScrollerList } from './useWindowScrollerList';
9
+ export { default as useWindowSize } from './useWindowSize';
10
+ export { default as useForceUpdate } from 'use-force-update';
11
+ export { default as useOnClickOutside } from 'use-onclickoutside';
12
+ export { useUncontrolled } from 'uncontrollable';
13
+ export { default as usePrevious } from './usePrevious';
14
+ export { default as useCancellableDelayedCallback } from './useCancellableDelayedCallback';
15
+ export { default as useDerivedStateFromProps } from './useDerivedStateFromProps';
16
+ export * from './useSetRef';
17
+ export * from './useParentElement';
18
+ export * from './useOnElementResize';
19
+ export * from './useIsShowingEllipsis';
@@ -0,0 +1 @@
1
+ export default function useCancellableDelayedCallback(cb: any, delay: any): ((...args: any[]) => void)[];
@@ -0,0 +1 @@
1
+ export default function useDerivedStateFromProp(prop: any, options?: {}): any[];
@@ -0,0 +1 @@
1
+ export default function useExecutionDelay(startFn: any, cleanFn: any, delayTime: any): ((...args: any[]) => void)[];
@@ -1,4 +1,4 @@
1
- export declare const useExpandState: ({ items, itemKey, expanded: expandedProp, onExpand, onExpandChange, onExpandAll, onToggleExpand, onCollapse, }: {
1
+ export default function useExpandState({ items, itemKey, expanded: expandedProp, onExpand, onExpandChange, onExpandAll, onToggleExpand, onCollapse, }: {
2
2
  items?: never[] | undefined;
3
3
  itemKey?: string | undefined;
4
4
  expanded?: {} | undefined;
@@ -7,7 +7,7 @@ export declare const useExpandState: ({ items, itemKey, expanded: expandedProp,
7
7
  onExpandAll?: (() => null) | undefined;
8
8
  onToggleExpand: any;
9
9
  onCollapse: any;
10
- }) => {
10
+ }): {
11
11
  state: {
12
12
  expanded: any;
13
13
  isExpandedAll: boolean;
@@ -20,4 +20,3 @@ export declare const useExpandState: ({ items, itemKey, expanded: expandedProp,
20
20
  };
21
21
  setExpanded: any;
22
22
  };
23
- export default useExpandState;
@@ -0,0 +1,5 @@
1
+ export default function useHotkeys({ keys, handler, options }: {
2
+ keys: any;
3
+ handler: any;
4
+ options?: {} | undefined;
5
+ }, deps?: never[]): void;
@@ -1,10 +1,9 @@
1
- export declare const useHoverHandlersDelay: ({ onMouseOver, onMouseLeave, hideDelay, showDelay, }: {
1
+ export default function useHoverHandlersDelay({ onMouseOver, onMouseLeave, hideDelay, showDelay, }: {
2
2
  onMouseOver: any;
3
3
  onMouseLeave: any;
4
4
  hideDelay?: number | undefined;
5
5
  showDelay?: number | undefined;
6
- }) => {
6
+ }): {
7
7
  onMouseOver: () => void;
8
8
  onMouseLeave: () => void;
9
9
  };
10
- export default useHoverHandlersDelay;
@@ -0,0 +1,2 @@
1
+ import React from 'react';
2
+ export declare const useOnElementResize: <T extends HTMLElement>(targetRef: React.RefObject<T>) => Record<'width' | 'height', number>;
@@ -0,0 +1,2 @@
1
+ declare function usePrevious(value: any): undefined;
2
+ export default usePrevious;
@@ -0,0 +1,2 @@
1
+ /// <reference types="react" />
2
+ export default function useResizeObserver(handler: any, el: any): import("react").Dispatch<any>[];
File without changes
@@ -0,0 +1 @@
1
+ export default function useShouldRecalculate(bool: any): number;
@@ -0,0 +1,4 @@
1
+ export default function useWindowScrollerList({ listInstance, outerListRef }: {
2
+ listInstance: any;
3
+ outerListRef: any;
4
+ }): void;
@@ -0,0 +1 @@
1
+ export default function useWindowSize(): false | number[];
@@ -0,0 +1,13 @@
1
+ export { default as getComponentFromProps } from './getComponentFromProps';
2
+ export { default as onClickHandlerForNonInteractiveElements } from './onClickHandlerForNonInteractiveElements';
3
+ export * from './capitalize';
4
+ export * from './operators';
5
+ export * from './utils';
6
+ export * from './system';
7
+ export * from './hooks';
8
+ export * from './timeUtils';
9
+ export * from './compose';
10
+ export * from './platform';
11
+ export * from './reactTypesUtility';
12
+ export * from './scrollingTimer';
13
+ export * from './validations';
@@ -1,12 +1,12 @@
1
- /**
2
- * onClickHandler: callback
3
- *
4
- * @param onClickHandler
5
- */
6
- export declare const onClickHandlerForNonInteractiveElements: (onClickHandler: any) => {
1
+ declare const _default: (onClickHandler: any) => {
7
2
  role: string;
8
3
  tabIndex: string;
9
4
  onClick: any;
10
5
  onKeyPress: (event: any) => void;
11
6
  };
12
- export default onClickHandlerForNonInteractiveElements;
7
+ /**
8
+ * onClickHandler: callback
9
+ *
10
+ * @param onClickHandler
11
+ */
12
+ export default _default;
File without changes
File without changes
File without changes
@@ -0,0 +1 @@
1
+ export declare function resetTimer(func: any): (...args: any[]) => void;
File without changes
File without changes
File without changes
File without changes
@@ -1,35 +0,0 @@
1
- var __create = Object.create;
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __getProtoOf = Object.getPrototypeOf;
6
- var __hasOwnProp = Object.prototype.hasOwnProperty;
7
- var __markAsModule = (target) => __defProp(target, "__esModule", { value: true });
8
- var __export = (target, all) => {
9
- for (var name in all)
10
- __defProp(target, name, { get: all[name], enumerable: true });
11
- };
12
- var __reExport = (target, module2, copyDefault, desc) => {
13
- if (module2 && typeof module2 === "object" || typeof module2 === "function") {
14
- for (let key of __getOwnPropNames(module2))
15
- if (!__hasOwnProp.call(target, key) && (copyDefault || key !== "default"))
16
- __defProp(target, key, { get: () => module2[key], enumerable: !(desc = __getOwnPropDesc(module2, key)) || desc.enumerable });
17
- }
18
- return target;
19
- };
20
- var __toESM = (module2, isNodeMode) => {
21
- return __reExport(__markAsModule(__defProp(module2 != null ? __create(__getProtoOf(module2)) : {}, "default", !isNodeMode && module2 && module2.__esModule ? { get: () => module2.default, enumerable: true } : { value: module2, enumerable: true })), module2);
22
- };
23
- var __toCommonJS = /* @__PURE__ */ ((cache) => {
24
- return (module2, temp) => {
25
- return cache && cache.get(module2) || (temp = __reExport(__markAsModule({}), module2, 1), cache && cache.set(module2, temp), temp);
26
- };
27
- })(typeof WeakMap !== "undefined" ? /* @__PURE__ */ new WeakMap() : 0);
28
- var capitalize_exports = {};
29
- __export(capitalize_exports, {
30
- capitalize: () => capitalize
31
- });
32
- var React = __toESM(require("react"));
33
- const capitalize = (string) => string.charAt(0).toUpperCase() + string.slice(1);
34
- module.exports = __toCommonJS(capitalize_exports);
35
- //# sourceMappingURL=capitalize.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../src/capitalize.tsx", "../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["export const capitalize = (string: string): string => string.charAt(0).toUpperCase() + string.slice(1);\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAhB,MAAM,aAAa,CAAC,WAA2B,OAAO,OAAO,GAAG,gBAAgB,OAAO,MAAM;",
6
- "names": []
7
- }
@@ -1,45 +0,0 @@
1
- var __create = Object.create;
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __getProtoOf = Object.getPrototypeOf;
6
- var __hasOwnProp = Object.prototype.hasOwnProperty;
7
- var __markAsModule = (target) => __defProp(target, "__esModule", { value: true });
8
- var __export = (target, all) => {
9
- for (var name in all)
10
- __defProp(target, name, { get: all[name], enumerable: true });
11
- };
12
- var __reExport = (target, module2, copyDefault, desc) => {
13
- if (module2 && typeof module2 === "object" || typeof module2 === "function") {
14
- for (let key of __getOwnPropNames(module2))
15
- if (!__hasOwnProp.call(target, key) && (copyDefault || key !== "default"))
16
- __defProp(target, key, { get: () => module2[key], enumerable: !(desc = __getOwnPropDesc(module2, key)) || desc.enumerable });
17
- }
18
- return target;
19
- };
20
- var __toESM = (module2, isNodeMode) => {
21
- return __reExport(__markAsModule(__defProp(module2 != null ? __create(__getProtoOf(module2)) : {}, "default", !isNodeMode && module2 && module2.__esModule ? { get: () => module2.default, enumerable: true } : { value: module2, enumerable: true })), module2);
22
- };
23
- var __toCommonJS = /* @__PURE__ */ ((cache) => {
24
- return (module2, temp) => {
25
- return cache && cache.get(module2) || (temp = __reExport(__markAsModule({}), module2, 1), cache && cache.set(module2, temp), temp);
26
- };
27
- })(typeof WeakMap !== "undefined" ? /* @__PURE__ */ new WeakMap() : 0);
28
- var compose_exports = {};
29
- __export(compose_exports, {
30
- compose: () => compose,
31
- default: () => compose_default
32
- });
33
- var React = __toESM(require("react"));
34
- const compose = (...funcs) => {
35
- if (funcs.length === 0) {
36
- return (arg) => arg;
37
- }
38
- if (funcs.length === 1) {
39
- return funcs[0];
40
- }
41
- return funcs.reduce((a, b) => (...args) => a(b(...args)));
42
- };
43
- var compose_default = compose;
44
- module.exports = __toCommonJS(compose_exports);
45
- //# sourceMappingURL=compose.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../src/compose.tsx", "../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["/**\n * Composes single-argument functions from right to left. The rightmost\n * function can take multiple arguments as it provides the signature for\n * the resulting composite function. [From redux v4.0.5]\n *\n * @param {...Function} funcs The functions to compose.\n * @returns {Function} A function obtained by composing the argument functions\n * from right to left. For example, compose(f, g, h) is identical to doing\n * (...args) => f(g(h(...args))).\n */\n\nexport const compose = (...funcs) => {\n if (funcs.length === 0) {\n return (arg) => arg;\n }\n\n if (funcs.length === 1) {\n return funcs[0];\n }\n\n return funcs.reduce((a, b) => (...args) => a(b(...args)));\n};\n\nexport default compose;\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADWhB,MAAM,UAAU,IAAI,UAAU;AACnC,MAAI,MAAM,WAAW,GAAG;AACtB,WAAO,CAAC,QAAQ;AAAA;AAGlB,MAAI,MAAM,WAAW,GAAG;AACtB,WAAO,MAAM;AAAA;AAGf,SAAO,MAAM,OAAO,CAAC,GAAG,MAAM,IAAI,SAAS,EAAE,EAAE,GAAG;AAAA;AAGpD,IAAO,kBAAQ;",
6
- "names": []
7
- }
@@ -1,48 +0,0 @@
1
- var __create = Object.create;
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __getProtoOf = Object.getPrototypeOf;
6
- var __hasOwnProp = Object.prototype.hasOwnProperty;
7
- var __markAsModule = (target) => __defProp(target, "__esModule", { value: true });
8
- var __export = (target, all) => {
9
- for (var name in all)
10
- __defProp(target, name, { get: all[name], enumerable: true });
11
- };
12
- var __reExport = (target, module2, copyDefault, desc) => {
13
- if (module2 && typeof module2 === "object" || typeof module2 === "function") {
14
- for (let key of __getOwnPropNames(module2))
15
- if (!__hasOwnProp.call(target, key) && (copyDefault || key !== "default"))
16
- __defProp(target, key, { get: () => module2[key], enumerable: !(desc = __getOwnPropDesc(module2, key)) || desc.enumerable });
17
- }
18
- return target;
19
- };
20
- var __toESM = (module2, isNodeMode) => {
21
- return __reExport(__markAsModule(__defProp(module2 != null ? __create(__getProtoOf(module2)) : {}, "default", !isNodeMode && module2 && module2.__esModule ? { get: () => module2.default, enumerable: true } : { value: module2, enumerable: true })), module2);
22
- };
23
- var __toCommonJS = /* @__PURE__ */ ((cache) => {
24
- return (module2, temp) => {
25
- return cache && cache.get(module2) || (temp = __reExport(__markAsModule({}), module2, 1), cache && cache.set(module2, temp), temp);
26
- };
27
- })(typeof WeakMap !== "undefined" ? /* @__PURE__ */ new WeakMap() : 0);
28
- var getComponentFromProps_exports = {};
29
- __export(getComponentFromProps_exports, {
30
- default: () => getComponentFromProps_default,
31
- getComponentFromProps: () => getComponentFromProps
32
- });
33
- var React = __toESM(require("react"));
34
- var import_react = __toESM(require("react"));
35
- const getComponentFromProps = (Component, props, children = []) => {
36
- if (!Component)
37
- return null;
38
- const componentChildren = Component.props ? Array.isArray(Component.props.children) ? Component.props.children : [Component.props.children] : null;
39
- return typeof Component === "function" ? /* @__PURE__ */ import_react.default.createElement(Component, {
40
- ...props
41
- }, children) : import_react.default.cloneElement(Component, {
42
- ...Component.props,
43
- ...props
44
- }, componentChildren ? [...componentChildren, ...children] : [...children]);
45
- };
46
- var getComponentFromProps_default = getComponentFromProps;
47
- module.exports = __toCommonJS(getComponentFromProps_exports);
48
- //# sourceMappingURL=getComponentFromProps.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../src/getComponentFromProps.tsx", "../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["/* eslint-disable no-nested-ternary */\nimport React from 'react';\n\nexport const getComponentFromProps = (Component, props, children = []) => {\n if (!Component) return null;\n const componentChildren = Component.props\n ? Array.isArray(Component.props.children)\n ? Component.props.children\n : [Component.props.children]\n : null;\n return typeof Component === 'function' ? (\n <Component {...props}>{children}</Component>\n ) : (\n React.cloneElement(\n Component,\n {\n ...Component.props,\n ...props,\n },\n componentChildren ? [...componentChildren, ...children] : [...children],\n )\n );\n};\n\nexport default getComponentFromProps;\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADCvB,mBAAkB;AAEX,MAAM,wBAAwB,CAAC,WAAW,OAAO,WAAW,OAAO;AACxE,MAAI,CAAC;AAAW,WAAO;AACvB,QAAM,oBAAoB,UAAU,QAChC,MAAM,QAAQ,UAAU,MAAM,YAC5B,UAAU,MAAM,WAChB,CAAC,UAAU,MAAM,YACnB;AACJ,SAAO,OAAO,cAAc,aAC1B,mDAAC,WAAD;AAAA,OAAe;AAAA,KAAQ,YAEvB,qBAAM,aACJ,WACA;AAAA,OACK,UAAU;AAAA,OACV;AAAA,KAEL,oBAAoB,CAAC,GAAG,mBAAmB,GAAG,YAAY,CAAC,GAAG;AAAA;AAKpE,IAAO,gCAAQ;",
6
- "names": []
7
- }