@envive-ai/react-toolkit 0.1.12 → 0.2.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 (206) hide show
  1. package/dist/Accordion/index.cjs +3 -3
  2. package/dist/Accordion/index.d.cts +2 -2
  3. package/dist/Accordion/index.d.ts +2 -2
  4. package/dist/Accordion/index.js +3 -3
  5. package/dist/{Accordion-DBZpiQe7.cjs → Accordion-D9gO9_y3.cjs} +1 -1
  6. package/dist/{Accordion-Cp3Hx2zm.js → Accordion-ZEdp99Ph.js} +1 -1
  7. package/dist/AnimatedChevron/index.cjs +3 -0
  8. package/dist/AnimatedChevron/index.d.cts +11 -0
  9. package/dist/AnimatedChevron/index.d.ts +11 -0
  10. package/dist/AnimatedChevron/index.js +3 -0
  11. package/dist/AnimatedChevron-CwuXgR2r.js +29 -0
  12. package/dist/AnimatedChevron-e_UzWBl0.cjs +37 -0
  13. package/dist/AppliedFiltersScrollbar/index.cjs +25 -27
  14. package/dist/AppliedFiltersScrollbar/index.d.ts +2 -2
  15. package/dist/AppliedFiltersScrollbar/index.js +25 -27
  16. package/dist/ButtonBase/index.cjs +4 -4
  17. package/dist/ButtonBase/index.d.cts +3 -4
  18. package/dist/ButtonBase/index.d.ts +2 -3
  19. package/dist/ButtonBase/index.js +4 -4
  20. package/dist/{ButtonBase-BAf-nlCm.js → ButtonBase-BJ0qXMWD.js} +3 -3
  21. package/dist/{ButtonBase-Do88ndKa.cjs → ButtonBase-VIv-tn7H.cjs} +3 -3
  22. package/dist/DynamicFiltersScrollbar/index.cjs +23 -25
  23. package/dist/DynamicFiltersScrollbar/index.d.cts +2 -2
  24. package/dist/DynamicFiltersScrollbar/index.d.ts +2 -2
  25. package/dist/DynamicFiltersScrollbar/index.js +23 -25
  26. package/dist/DynamicFiltersScrollbar-HCYZjI14.cjs +81 -0
  27. package/dist/DynamicFiltersScrollbar-O0ai3cIG.js +66 -0
  28. package/dist/FilterScrollbar/index.cjs +3 -3
  29. package/dist/FilterScrollbar/index.d.cts +3 -3
  30. package/dist/FilterScrollbar/index.d.ts +3 -3
  31. package/dist/FilterScrollbar/index.js +3 -3
  32. package/dist/Headline/index.cjs +2 -2
  33. package/dist/Headline/index.d.cts +2 -2
  34. package/dist/Headline/index.d.ts +2 -2
  35. package/dist/Headline/index.js +2 -2
  36. package/dist/{Headline-DTT4RSv2.cjs → Headline-CKJmd2w4.cjs} +1 -1
  37. package/dist/{Headline-DNEWF8ly.js → Headline-DtjTB4xS.js} +1 -1
  38. package/dist/ImageWithFallback/index.cjs +1 -1
  39. package/dist/ImageWithFallback/index.d.cts +2 -2
  40. package/dist/ImageWithFallback/index.d.ts +2 -2
  41. package/dist/ImageWithFallback/index.js +1 -1
  42. package/dist/ModalSheet/index.cjs +2 -1
  43. package/dist/ModalSheet/index.d.cts +2 -2
  44. package/dist/ModalSheet/index.d.ts +2 -2
  45. package/dist/ModalSheet/index.js +2 -1
  46. package/dist/{ModalSheet-Csz8HIxs.cjs → ModalSheet-DwnbbFh7.cjs} +2 -26
  47. package/dist/{ModalSheet-01pxpy_K.js → ModalSheet-sMg44OLz.js} +2 -26
  48. package/dist/ProductCard/index.cjs +6 -6
  49. package/dist/ProductCard/index.d.cts +1 -1
  50. package/dist/ProductCard/index.d.ts +1 -1
  51. package/dist/ProductCard/index.js +6 -6
  52. package/dist/{ProductCard-FDyIMnZs.cjs → ProductCard-BDz80MCQ.cjs} +34 -34
  53. package/dist/{ProductCard-C3MjnfZJ.js → ProductCard-CqhNJShq.js} +34 -34
  54. package/dist/ProductGrid/index.cjs +7 -7
  55. package/dist/ProductGrid/index.d.cts +4 -8
  56. package/dist/ProductGrid/index.d.ts +4 -8
  57. package/dist/ProductGrid/index.js +7 -7
  58. package/dist/{ProductGrid-C9OKsyB2.js → ProductGrid-8n4XgcMr.js} +3 -7
  59. package/dist/{ProductGrid-TlntVJ6h.cjs → ProductGrid-RRcdkY5J.cjs} +3 -7
  60. package/dist/RadioButton/index.cjs +3 -3
  61. package/dist/RadioButton/index.d.cts +5 -3
  62. package/dist/RadioButton/index.d.ts +5 -3
  63. package/dist/RadioButton/index.js +3 -3
  64. package/dist/{RadioButton-DZ6QXkrN.cjs → RadioButton-BWnaUI8o.cjs} +17 -10
  65. package/dist/{RadioButton-Bf68dZl7.js → RadioButton-CG8_M0hY.js} +18 -11
  66. package/dist/RadioButtonGroup/index.cjs +4 -4
  67. package/dist/RadioButtonGroup/index.d.cts +2 -2
  68. package/dist/RadioButtonGroup/index.d.ts +2 -2
  69. package/dist/RadioButtonGroup/index.js +4 -4
  70. package/dist/{RadioButtonGroup-8k7hkJYB.js → RadioButtonGroup-B7EuiEP1.js} +2 -1
  71. package/dist/{RadioButtonGroup-Dc_n5amh.cjs → RadioButtonGroup-ReQqakpS.cjs} +2 -1
  72. package/dist/SearchAutocomplete/index.cjs +1 -1
  73. package/dist/SearchAutocomplete/index.js +1 -1
  74. package/dist/SearchFilter/index.cjs +15 -11
  75. package/dist/SearchFilter/index.d.cts +20 -6
  76. package/dist/SearchFilter/index.d.ts +20 -6
  77. package/dist/SearchFilter/index.js +12 -11
  78. package/dist/{SearchFilter-DvqBIXa1.js → SearchFilter-C8mgj84o.js} +28 -18
  79. package/dist/{SearchFilter-CTVBi5s3.cjs → SearchFilter-FrdHPM5O.cjs} +45 -17
  80. package/dist/SearchInput/index.cjs +4 -4
  81. package/dist/SearchInput/index.d.cts +3 -2
  82. package/dist/SearchInput/index.d.ts +4 -3
  83. package/dist/SearchInput/index.js +4 -4
  84. package/dist/{SearchInput-vJMWoLzS.cjs → SearchInput--x9NTMTb.cjs} +2 -2
  85. package/dist/{SearchInput-CVaCPWCE.js → SearchInput-IBq83nqF.js} +2 -2
  86. package/dist/SearchInputForm/index.cjs +5 -5
  87. package/dist/SearchInputForm/index.d.cts +34 -2
  88. package/dist/SearchInputForm/index.d.ts +34 -2
  89. package/dist/SearchInputForm/index.js +5 -5
  90. package/dist/SearchResultsContent/index.cjs +36 -39
  91. package/dist/SearchResultsContent/index.d.cts +4 -6
  92. package/dist/SearchResultsContent/index.d.ts +4 -6
  93. package/dist/SearchResultsContent/index.js +36 -39
  94. package/dist/SearchResultsFilterSidebar/index.cjs +13 -12
  95. package/dist/SearchResultsFilterSidebar/index.d.cts +1 -1
  96. package/dist/SearchResultsFilterSidebar/index.d.ts +1 -1
  97. package/dist/SearchResultsFilterSidebar/index.js +13 -12
  98. package/dist/SearchResultsStates/index.cjs +12 -12
  99. package/dist/SearchResultsStates/index.d.cts +6 -8
  100. package/dist/SearchResultsStates/index.d.ts +6 -8
  101. package/dist/SearchResultsStates/index.js +12 -12
  102. package/dist/{SearchResultsStates-iKz64Pd4.js → SearchResultsStates-D7dM35qq.js} +8 -10
  103. package/dist/{SearchResultsStates-CH4agenX.cjs → SearchResultsStates-nlaPbkj3.cjs} +8 -10
  104. package/dist/SparkleAnimation/index.cjs +1 -1
  105. package/dist/SparkleAnimation/index.d.cts +2 -2
  106. package/dist/SparkleAnimation/index.d.ts +2 -2
  107. package/dist/SparkleAnimation/index.js +1 -1
  108. package/dist/{SparkleAnimation-qi5WCJ9B.cjs → SparkleAnimation-D1aZE-7A.cjs} +0 -1
  109. package/dist/{SparkleAnimation-BLfNojLv.js → SparkleAnimation-DtWkXmkN.js} +0 -1
  110. package/dist/Spinner/index.cjs +1 -1
  111. package/dist/Spinner/index.d.cts +2 -2
  112. package/dist/Spinner/index.d.ts +2 -2
  113. package/dist/Spinner/index.js +1 -1
  114. package/dist/SuggestionButton/index.cjs +3 -3
  115. package/dist/SuggestionButton/index.d.ts +2 -2
  116. package/dist/SuggestionButton/index.js +3 -3
  117. package/dist/Text/index.cjs +2 -2
  118. package/dist/Text/index.d.cts +2 -2
  119. package/dist/Text/index.d.ts +3 -3
  120. package/dist/Text/index.js +2 -2
  121. package/dist/{Text-Bod4OMPk.js → Text-BLzNhX4H.js} +1 -1
  122. package/dist/{Text-MQjxqgZZ.cjs → Text-DllCE9_D.cjs} +1 -1
  123. package/dist/TextInput/index.cjs +2 -2
  124. package/dist/TextInput/index.d.ts +1 -1
  125. package/dist/TextInput/index.js +2 -2
  126. package/dist/{TextInput-DoM41M53.js → TextInput-BeHPlVHT.js} +1 -1
  127. package/dist/{TextInput-B3dTeD3q.cjs → TextInput-CGs4BY1q.cjs} +1 -1
  128. package/dist/ToggleButton/index.cjs +3 -3
  129. package/dist/ToggleButton/index.d.cts +2 -2
  130. package/dist/ToggleButton/index.d.ts +2 -2
  131. package/dist/ToggleButton/index.js +3 -3
  132. package/dist/{ToggleButton-GIVd2-Z4.js → ToggleButton-CRiPqTCb.js} +1 -1
  133. package/dist/{ToggleButton-CK_vkMvt.cjs → ToggleButton-DfJZ8POQ.cjs} +1 -1
  134. package/dist/{index-CFH3KUVw.d.cts → index-B9WeFNlO.d.cts} +5 -9
  135. package/dist/{index-B8l3muO3.d.ts → index-CLGe_Pam.d.cts} +2 -3
  136. package/dist/{index-Vck3pox6.d.ts → index-CeECGrFM.d.ts} +4 -8
  137. package/dist/{index-BMt66uqr.d.cts → index-PSzeHU2s.d.ts} +2 -3
  138. package/dist/{searchFilterSidebarVariants-CI782ylo.js → searchFilterSidebarVariants-B05f5SD5.js} +1 -1
  139. package/dist/{searchFilterSidebarVariants-DFfOTqjc.cjs → searchFilterSidebarVariants-NQhqq-NT.cjs} +1 -1
  140. package/dist/{textVariantClasses-Dgz7Zaql.cjs → textVariantClasses-CBre7vXv.cjs} +5 -7
  141. package/dist/{textVariantClasses-D77TGEy1.js → textVariantClasses-CRrTb43V.js} +5 -7
  142. package/dist/types-BhGjnuWx.d.cts +4 -0
  143. package/dist/types-CTOdb0G0.d.ts +4 -0
  144. package/package.json +7 -7
  145. package/src/atoms/search/types.ts +1 -5
  146. package/src/components/AnimatedChevron/index.ts +1 -0
  147. package/src/components/AppliedFiltersScrollbar/AppliedFiltersScrollbar.tsx +25 -27
  148. package/src/components/ButtonBase/ButtonBase.tsx +1 -2
  149. package/src/components/DynamicFiltersScrollbar/DynamicFiltersScrollbar.tsx +26 -28
  150. package/src/components/FilterScrollbar/AppliedFiltersScrollbar.tsx +25 -27
  151. package/src/components/FilterScrollbar/DynamicFiltersScrollbar.tsx +26 -28
  152. package/src/components/ModalSheet/ModalSheet.tsx +1 -1
  153. package/src/components/ModalSheet/common/closeIcon.tsx +2 -2
  154. package/src/components/ModalSheet/mobile/mobileHeader.tsx +1 -1
  155. package/src/components/ProductCard/ProductCard.tsx +5 -28
  156. package/src/components/ProductGrid/ProductGrid.tsx +3 -11
  157. package/src/components/RadioButton/RadioButton.tsx +15 -6
  158. package/src/components/RadioButtonGroup/RadioButtonGroup.tsx +1 -0
  159. package/src/components/SearchFilter/SearchFilter.tsx +2 -2
  160. package/src/components/SearchFilter/SearchFilterFooter.tsx +1 -1
  161. package/src/components/SearchFilter/SearchFilterHeader.tsx +6 -1
  162. package/src/components/SearchFilter/SearchFilterItem.tsx +17 -3
  163. package/src/components/SearchFilter/index.ts +4 -2
  164. package/src/components/SearchFilter/useHasFilterStateChanged.tsx +1 -0
  165. package/src/components/SearchFilter/utils.ts +4 -6
  166. package/src/components/SearchInput/SearchInput.tsx +2 -2
  167. package/src/components/SearchInput/searchInputVariants.ts +1 -1
  168. package/src/components/SearchInputForm/SearchInputForm.tsx +1 -1
  169. package/src/components/SearchInputForm/index.ts +0 -1
  170. package/src/components/SearchResultsContent/SearchResultsContent.tsx +33 -38
  171. package/src/components/SearchResultsFilterSidebar/SearchResultsFilter.tsx +2 -3
  172. package/src/components/SearchResultsFilterSidebar/searchFilterSidebarVariants.ts +1 -1
  173. package/src/components/SearchResultsStates/SearchResultsGrid.tsx +4 -8
  174. package/src/components/SearchResultsStates/SearchResultsLoadingGrid.tsx +3 -3
  175. package/src/components/SparkleAnimation/SparkleAnimation.tsx +0 -1
  176. package/src/components/Spinner/Spinner.tsx +29 -14
  177. package/src/components/SuggestionButton/SuggestionButton.tsx +1 -1
  178. package/src/components/SuggestionButton/types.ts +1 -1
  179. package/src/components/Text/textVariantClasses.ts +12 -10
  180. package/src/components/TextInput/TextInput.tsx +1 -0
  181. package/src/util/camelCasedPropertiesDeep.ts +22 -22
  182. package/src/util/internal.ts +4 -2
  183. package/src/util/splitWords.ts +35 -31
  184. package/dist/DynamicFiltersScrollbar-C4kdNSJ9.js +0 -70
  185. package/dist/DynamicFiltersScrollbar-CVw1PINp.cjs +0 -85
  186. package/dist/Styles/index.cjs +0 -274
  187. package/dist/Styles/index.d.cts +0 -258
  188. package/dist/Styles/index.d.ts +0 -258
  189. package/dist/Styles/index.js +0 -274
  190. package/dist/index-H_9LhS_1.d.cts +0 -36
  191. package/dist/index-h-QwQNnu.d.ts +0 -36
  192. package/src/components/SearchInputForm/types.ts +0 -1
  193. package/src/components/Styles/EnviveTailwindPreset.ts +0 -285
  194. package/src/components/Styles/index.ts +0 -2
  195. package/tailwind-preset.js +0 -3
  196. /package/dist/{ButtonBase-0NN6wmX-.js → ButtonBase-BktteD9c.js} +0 -0
  197. /package/dist/{ButtonBase-BIXx56hq.cjs → ButtonBase-Cb6Iec6f.cjs} +0 -0
  198. /package/dist/{ImageWithFallback-DqxjwO3i.js → ImageWithFallback-CbYsD1_a.js} +0 -0
  199. /package/dist/{ImageWithFallback-Cx-KNi-D.cjs → ImageWithFallback-Km9h16Vz.cjs} +0 -0
  200. /package/dist/{SearchAutocomplete-BlpII8Xs.js → SearchAutocomplete-BMNYZiJL.js} +0 -0
  201. /package/dist/{SearchAutocomplete-DIEhLT4C.cjs → SearchAutocomplete-BmHdijOv.cjs} +0 -0
  202. /package/dist/{Spinner-CjGLIRgs.js → Spinner-bg6jb_ks.js} +0 -0
  203. /package/dist/{Spinner-DFor2Szi.cjs → Spinner-rcWX566W.cjs} +0 -0
  204. /package/dist/{colorsConfig-DEfiLHH0.js → colorsConfig-Ck2jeqWe.js} +0 -0
  205. /package/dist/{colorsConfig-D-MZuBvt.cjs → colorsConfig-CqCKftuM.cjs} +0 -0
  206. /package/dist/{textVariantClasses-kyZtL8F5.d.ts → textVariantClasses-Bl8SAGwZ.d.ts} +0 -0
@@ -94,13 +94,15 @@ export const TextStyleVariantMap = {
94
94
  ...HeadlineVariantMap,
95
95
  };
96
96
 
97
- export const getVariantPlaceholderClassNames = (classes: Record<string, boolean>) => {
98
- return Object.keys(classes).reduce((acc, key) => {
99
- if(key.includes('spiffy-tw')){
100
- acc[`placeholder:${key}`] = classes[key];
101
- } else {
102
- acc[`${key}-placeholder`] = classes[key];
103
- }
104
- return acc;
105
- }, {} as Record<string, boolean>);
106
- }
97
+ export const getVariantPlaceholderClassNames = (classes: Record<string, boolean>) =>
98
+ Object.keys(classes).reduce(
99
+ (acc, key) => {
100
+ if (key.includes('spiffy-tw')) {
101
+ acc[`placeholder:${key}`] = classes[key];
102
+ } else {
103
+ acc[`${key}-placeholder`] = classes[key];
104
+ }
105
+ return acc;
106
+ },
107
+ {} as Record<string, boolean>,
108
+ );
@@ -1,3 +1,4 @@
1
+ /* eslint-disable react/jsx-props-no-spreading */
1
2
  // Disabling this prevents an otherwise simple wrapper around input
2
3
  // from becoming needlessly verbose while maintaining flexibility.
3
4
  // Keeping it enabled requires listing every possible prop.
@@ -1,4 +1,3 @@
1
- /* eslint-disable @typescript-eslint/no-unsafe-function-type */
2
1
  import type { CamelCase, CamelCaseOptions } from './camelCase';
3
2
  import type { UnknownArray } from './unknownArray';
4
3
 
@@ -49,33 +48,34 @@ import type { UnknownArray } from './unknownArray';
49
48
  export type CamelCasedPropertiesDeep<
50
49
  Value,
51
50
  Options extends CamelCaseOptions = { preserveConsecutiveUppercase: true },
51
+ // eslint-disable-next-line @typescript-eslint/ban-types
52
52
  > = Value extends Function
53
53
  ? Value
54
54
  : Value extends UnknownArray
55
- ? CamelCasedPropertiesArrayDeep<Value>
56
- : Value extends Set<infer U>
57
- ? Set<CamelCasedPropertiesDeep<U, Options>>
58
- : {
59
- [K in keyof Value as CamelCase<K, Options>]: CamelCasedPropertiesDeep<Value[K], Options>;
60
- };
55
+ ? CamelCasedPropertiesArrayDeep<Value>
56
+ : Value extends Set<infer U>
57
+ ? Set<CamelCasedPropertiesDeep<U, Options>>
58
+ : {
59
+ [K in keyof Value as CamelCase<K, Options>]: CamelCasedPropertiesDeep<Value[K], Options>;
60
+ };
61
61
 
62
62
  // This is a copy of DelimiterCasedPropertiesArrayDeep (see: delimiter-cased-properties-deep.d.ts).
63
63
  // These types should be kept in sync.
64
64
  type CamelCasedPropertiesArrayDeep<Value extends UnknownArray> = Value extends []
65
65
  ? []
66
66
  : // Tailing spread array
67
- Value extends [infer U, ...infer V]
68
- ? [CamelCasedPropertiesDeep<U>, ...CamelCasedPropertiesDeep<V>]
69
- : Value extends readonly [infer U, ...infer V]
70
- ? readonly [CamelCasedPropertiesDeep<U>, ...CamelCasedPropertiesDeep<V>]
71
- : // Leading spread array
72
- Value extends readonly [...infer U, infer V]
73
- ? [...CamelCasedPropertiesDeep<U>, CamelCasedPropertiesDeep<V>]
74
- : Value extends readonly [...infer U, infer V]
75
- ? readonly [...CamelCasedPropertiesDeep<U>, CamelCasedPropertiesDeep<V>]
76
- : // Array
77
- Value extends Array<infer U>
78
- ? Array<CamelCasedPropertiesDeep<U>>
79
- : Value extends ReadonlyArray<infer U>
80
- ? ReadonlyArray<CamelCasedPropertiesDeep<U>>
81
- : never;
67
+ Value extends [infer U, ...infer V]
68
+ ? [CamelCasedPropertiesDeep<U>, ...CamelCasedPropertiesDeep<V>]
69
+ : Value extends readonly [infer U, ...infer V]
70
+ ? readonly [CamelCasedPropertiesDeep<U>, ...CamelCasedPropertiesDeep<V>]
71
+ : // Leading spread array
72
+ Value extends readonly [...infer U, infer V]
73
+ ? [...CamelCasedPropertiesDeep<U>, CamelCasedPropertiesDeep<V>]
74
+ : Value extends readonly [...infer U, infer V]
75
+ ? readonly [...CamelCasedPropertiesDeep<U>, CamelCasedPropertiesDeep<V>]
76
+ : // Array
77
+ Value extends Array<infer U>
78
+ ? Array<CamelCasedPropertiesDeep<U>>
79
+ : Value extends ReadonlyArray<infer U>
80
+ ? ReadonlyArray<CamelCasedPropertiesDeep<U>>
81
+ : never;
@@ -1,5 +1,4 @@
1
1
  /* eslint-disable @typescript-eslint/no-explicit-any */
2
- /* eslint-disable @typescript-eslint/no-unsafe-function-type */
3
2
  // these types come from https://github.com/sindresorhus/type-fest/blob/main/source/internal.d.ts
4
3
 
5
4
  import type { Primitive } from './primitive';
@@ -13,7 +12,10 @@ export type BuiltIns = Primitive | void | Date | RegExp;
13
12
  /**
14
13
  * Matches non-recursive types.
15
14
  */
16
- export type NonRecursiveType = BuiltIns | Function | (new (...arguments_: any[]) => unknown);
15
+ export type NonRecursiveType =
16
+ | BuiltIns
17
+ | ((...arguments_: any[]) => unknown)
18
+ | (new (...arguments_: any[]) => unknown);
17
19
 
18
20
  /**
19
21
  * Returns a boolean for whether the string is numeric.
@@ -38,35 +38,39 @@ export type SplitWords<
38
38
  ? // Skip word separator
39
39
  [...SkipEmptyWord<CurrentWord>, ...SplitWords<RemainingCharacters>]
40
40
  : LastCharacter extends ''
41
- ? // Fist char of word
42
- SplitWords<RemainingCharacters, FirstCharacter, FirstCharacter>
43
- : // Case change: non-numeric to numeric, push word
44
- [false, true] extends [IsNumeric<LastCharacter>, IsNumeric<FirstCharacter>]
45
- ? [
46
- ...SkipEmptyWord<CurrentWord>,
47
- ...SplitWords<RemainingCharacters, FirstCharacter, FirstCharacter>,
48
- ]
49
- : // Case change: numeric to non-numeric, push word
50
- [true, false] extends [IsNumeric<LastCharacter>, IsNumeric<FirstCharacter>]
51
- ? [
52
- ...SkipEmptyWord<CurrentWord>,
53
- ...SplitWords<RemainingCharacters, FirstCharacter, FirstCharacter>,
54
- ]
55
- : // No case change: concat word
56
- [true, true] extends [IsNumeric<LastCharacter>, IsNumeric<FirstCharacter>]
57
- ? SplitWords<RemainingCharacters, FirstCharacter, `${CurrentWord}${FirstCharacter}`>
58
- : // Case change: lower to upper, push word
59
- [true, true] extends [IsLowerCase<LastCharacter>, IsUpperCase<FirstCharacter>]
60
- ? [
61
- ...SkipEmptyWord<CurrentWord>,
62
- ...SplitWords<RemainingCharacters, FirstCharacter, FirstCharacter>,
63
- ]
64
- : // Case change: upper to lower, brings back the last character, push word
65
- [true, true] extends [IsUpperCase<LastCharacter>, IsLowerCase<FirstCharacter>]
66
- ? [
67
- ...RemoveLastCharacter<CurrentWord, LastCharacter>,
68
- ...SplitWords<RemainingCharacters, FirstCharacter, `${LastCharacter}${FirstCharacter}`>,
69
- ]
70
- : // No case change: concat word
71
- SplitWords<RemainingCharacters, FirstCharacter, `${CurrentWord}${FirstCharacter}`>
41
+ ? // Fist char of word
42
+ SplitWords<RemainingCharacters, FirstCharacter, FirstCharacter>
43
+ : // Case change: non-numeric to numeric, push word
44
+ [false, true] extends [IsNumeric<LastCharacter>, IsNumeric<FirstCharacter>]
45
+ ? [
46
+ ...SkipEmptyWord<CurrentWord>,
47
+ ...SplitWords<RemainingCharacters, FirstCharacter, FirstCharacter>,
48
+ ]
49
+ : // Case change: numeric to non-numeric, push word
50
+ [true, false] extends [IsNumeric<LastCharacter>, IsNumeric<FirstCharacter>]
51
+ ? [
52
+ ...SkipEmptyWord<CurrentWord>,
53
+ ...SplitWords<RemainingCharacters, FirstCharacter, FirstCharacter>,
54
+ ]
55
+ : // No case change: concat word
56
+ [true, true] extends [IsNumeric<LastCharacter>, IsNumeric<FirstCharacter>]
57
+ ? SplitWords<RemainingCharacters, FirstCharacter, `${CurrentWord}${FirstCharacter}`>
58
+ : // Case change: lower to upper, push word
59
+ [true, true] extends [IsLowerCase<LastCharacter>, IsUpperCase<FirstCharacter>]
60
+ ? [
61
+ ...SkipEmptyWord<CurrentWord>,
62
+ ...SplitWords<RemainingCharacters, FirstCharacter, FirstCharacter>,
63
+ ]
64
+ : // Case change: upper to lower, brings back the last character, push word
65
+ [true, true] extends [IsUpperCase<LastCharacter>, IsLowerCase<FirstCharacter>]
66
+ ? [
67
+ ...RemoveLastCharacter<CurrentWord, LastCharacter>,
68
+ ...SplitWords<
69
+ RemainingCharacters,
70
+ FirstCharacter,
71
+ `${LastCharacter}${FirstCharacter}`
72
+ >,
73
+ ]
74
+ : // No case change: concat word
75
+ SplitWords<RemainingCharacters, FirstCharacter, `${CurrentWord}${FirstCharacter}`>
72
76
  : [...SkipEmptyWord<CurrentWord>];
@@ -1,70 +0,0 @@
1
- import { Text } from "./Text-Bod4OMPk.js";
2
- import classNames from "classnames";
3
- import { jsx, jsxs } from "react/jsx-runtime";
4
- import ScrollContainer from "react-indiana-drag-scroll";
5
-
6
- //#region src/components/FilterScrollbar/AppliedFiltersScrollbar.tsx
7
- const AppliedFiltersScrollbar = ({ selectedFilterOptions, filterBarClassNames, filterDefaultClasses, filterHoverClasses, appliedFilterBackgroundClasses, onRemoveFilter }) => {
8
- if (selectedFilterOptions.length === 0) return null;
9
- const filterDefaultWithoutBg = filterDefaultClasses.replace(/spiffy-tw-bg-\[--spiffy-colors-[^\]]+\]/g, "").trim();
10
- const buttonClasses = classNames(" spiffy-tw-flex spiffy-tw-items-center spiffy-tw-rounded-full spiffy-tw-px-[8px] spiffy-tw-py-[4px] spiffy-tw-whitespace-nowrap", filterHoverClasses, filterDefaultWithoutBg, appliedFilterBackgroundClasses);
11
- const iconColor = "currentColor";
12
- return /* @__PURE__ */ jsx(ScrollContainer, {
13
- className: filterBarClassNames,
14
- hideScrollbars: true,
15
- children: selectedFilterOptions.map((filter) => {
16
- return /* @__PURE__ */ jsx("button", {
17
- className: buttonClasses,
18
- type: "button",
19
- onClick: () => onRemoveFilter(filter),
20
- "aria-label": `Remove filter: ${filter.displayName}`,
21
- children: /* @__PURE__ */ jsxs("div", {
22
- className: "spiffy-tw-flex spiffy-tw-items-center spiffy-tw-gap-[8px]",
23
- children: [/* @__PURE__ */ jsx(Text, {
24
- variant: "body3",
25
- children: filter.displayName
26
- }), /* @__PURE__ */ jsx("svg", {
27
- xmlns: "http://www.w3.org/2000/svg",
28
- width: "10",
29
- height: "10",
30
- viewBox: "0 0 10 10",
31
- fill: "none",
32
- children: /* @__PURE__ */ jsx("path", {
33
- d: "M4.59766 4.29297L8.48535 0.405273L9.19238 1.1123L5.30469 5L9.19238 8.8877L8.48535 9.59473L4.59766 5.70703L0.707031 9.59766L0 8.89062L3.89062 5L0 1.10938L0.707031 0.402344L4.59766 4.29297Z",
34
- fill: iconColor
35
- })
36
- })]
37
- })
38
- }, filter.id);
39
- })
40
- });
41
- };
42
-
43
- //#endregion
44
- //#region src/components/FilterScrollbar/DynamicFiltersScrollbar.tsx
45
- const DynamicFiltersScrollbar = ({ availableDynamicFilters, filterBarClassNames, filterDefaultClasses, filterHoverClasses, onToggleDynamicFilter }) => {
46
- return /* @__PURE__ */ jsx(ScrollContainer, {
47
- className: filterBarClassNames,
48
- hideScrollbars: true,
49
- children: availableDynamicFilters.map(({ name, displayName }) => {
50
- const buttonClasses = classNames("spiffy-tw-px-[12px] spiffy-tw-py-2 spiffy-tw-rounded-full spiffy-tw-border spiffy-tw-whitespace-nowrap ", filterHoverClasses, filterDefaultClasses);
51
- return /* @__PURE__ */ jsx("button", {
52
- type: "button",
53
- className: buttonClasses,
54
- onClick: () => {
55
- onToggleDynamicFilter({
56
- filter: name,
57
- dynamicFilterDisplayName: displayName
58
- });
59
- },
60
- children: /* @__PURE__ */ jsx(Text, {
61
- variant: "body3",
62
- children: displayName
63
- })
64
- }, name);
65
- })
66
- });
67
- };
68
-
69
- //#endregion
70
- export { AppliedFiltersScrollbar, DynamicFiltersScrollbar };
@@ -1,85 +0,0 @@
1
- const require_chunk = require('./chunk-CUT6urMc.cjs');
2
- const require_Text = require('./Text-MQjxqgZZ.cjs');
3
- let classnames = require("classnames");
4
- classnames = require_chunk.__toESM(classnames);
5
- let react_jsx_runtime = require("react/jsx-runtime");
6
- react_jsx_runtime = require_chunk.__toESM(react_jsx_runtime);
7
- let react_indiana_drag_scroll = require("react-indiana-drag-scroll");
8
- react_indiana_drag_scroll = require_chunk.__toESM(react_indiana_drag_scroll);
9
-
10
- //#region src/components/FilterScrollbar/AppliedFiltersScrollbar.tsx
11
- const AppliedFiltersScrollbar = ({ selectedFilterOptions, filterBarClassNames, filterDefaultClasses, filterHoverClasses, appliedFilterBackgroundClasses, onRemoveFilter }) => {
12
- if (selectedFilterOptions.length === 0) return null;
13
- const filterDefaultWithoutBg = filterDefaultClasses.replace(/spiffy-tw-bg-\[--spiffy-colors-[^\]]+\]/g, "").trim();
14
- const buttonClasses = (0, classnames.default)(" spiffy-tw-flex spiffy-tw-items-center spiffy-tw-rounded-full spiffy-tw-px-[8px] spiffy-tw-py-[4px] spiffy-tw-whitespace-nowrap", filterHoverClasses, filterDefaultWithoutBg, appliedFilterBackgroundClasses);
15
- const iconColor = "currentColor";
16
- return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_indiana_drag_scroll.default, {
17
- className: filterBarClassNames,
18
- hideScrollbars: true,
19
- children: selectedFilterOptions.map((filter) => {
20
- return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
21
- className: buttonClasses,
22
- type: "button",
23
- onClick: () => onRemoveFilter(filter),
24
- "aria-label": `Remove filter: ${filter.displayName}`,
25
- children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
26
- className: "spiffy-tw-flex spiffy-tw-items-center spiffy-tw-gap-[8px]",
27
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_Text.Text, {
28
- variant: "body3",
29
- children: filter.displayName
30
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("svg", {
31
- xmlns: "http://www.w3.org/2000/svg",
32
- width: "10",
33
- height: "10",
34
- viewBox: "0 0 10 10",
35
- fill: "none",
36
- children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
37
- d: "M4.59766 4.29297L8.48535 0.405273L9.19238 1.1123L5.30469 5L9.19238 8.8877L8.48535 9.59473L4.59766 5.70703L0.707031 9.59766L0 8.89062L3.89062 5L0 1.10938L0.707031 0.402344L4.59766 4.29297Z",
38
- fill: iconColor
39
- })
40
- })]
41
- })
42
- }, filter.id);
43
- })
44
- });
45
- };
46
-
47
- //#endregion
48
- //#region src/components/FilterScrollbar/DynamicFiltersScrollbar.tsx
49
- const DynamicFiltersScrollbar = ({ availableDynamicFilters, filterBarClassNames, filterDefaultClasses, filterHoverClasses, onToggleDynamicFilter }) => {
50
- return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_indiana_drag_scroll.default, {
51
- className: filterBarClassNames,
52
- hideScrollbars: true,
53
- children: availableDynamicFilters.map(({ name, displayName }) => {
54
- const buttonClasses = (0, classnames.default)("spiffy-tw-px-[12px] spiffy-tw-py-2 spiffy-tw-rounded-full spiffy-tw-border spiffy-tw-whitespace-nowrap ", filterHoverClasses, filterDefaultClasses);
55
- return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
56
- type: "button",
57
- className: buttonClasses,
58
- onClick: () => {
59
- onToggleDynamicFilter({
60
- filter: name,
61
- dynamicFilterDisplayName: displayName
62
- });
63
- },
64
- children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_Text.Text, {
65
- variant: "body3",
66
- children: displayName
67
- })
68
- }, name);
69
- })
70
- });
71
- };
72
-
73
- //#endregion
74
- Object.defineProperty(exports, 'AppliedFiltersScrollbar', {
75
- enumerable: true,
76
- get: function () {
77
- return AppliedFiltersScrollbar;
78
- }
79
- });
80
- Object.defineProperty(exports, 'DynamicFiltersScrollbar', {
81
- enumerable: true,
82
- get: function () {
83
- return DynamicFiltersScrollbar;
84
- }
85
- });
@@ -1,274 +0,0 @@
1
- Object.defineProperty(exports, '__esModule', { value: true });
2
- const require_chunk = require('../chunk-CUT6urMc.cjs');
3
- let __tailwindcss_typography = require("@tailwindcss/typography");
4
- __tailwindcss_typography = require_chunk.__toESM(__tailwindcss_typography);
5
-
6
- //#region src/components/Styles/EnviveTailwindPreset.ts
7
- /**
8
- * Helper function to create content paths for the Envive React Toolkit
9
- * This should be used in the consuming application's tailwind.config.js
10
- *
11
- * @param additionalPaths - Additional content paths to include
12
- * @returns Array of content paths including the toolkit components
13
- */
14
- const createEnviveContentPaths = (additionalPaths = []) => {
15
- let toolkitPath;
16
- try {
17
- if (typeof require !== "undefined" && typeof require.resolve === "function") {
18
- const path = require("path");
19
- toolkitPath = path.join(path.dirname(require.resolve("@envive-ai/react-toolkit/package.json")), "dist/**/*.{js,cjs}");
20
- } else toolkitPath = "./node_modules/@envive-ai/react-toolkit/dist/**/*.{js,cjs}";
21
- } catch {
22
- toolkitPath = "./node_modules/@envive-ai/react-toolkit/dist/**/*.{js,cjs}";
23
- }
24
- return [toolkitPath, ...additionalPaths];
25
- };
26
- /** @type {import('tailwindcss').Config} */
27
- const EnviveTailwindPreset = {
28
- future: { hoverOnlyWhenSupported: true },
29
- prefix: "spiffy-tw-",
30
- theme: {
31
- screens: {
32
- sm: "480px",
33
- md: "768px",
34
- lg: "976px",
35
- xl: "1440px"
36
- },
37
- fontFamily: { sans: [
38
- "Inter Variable",
39
- "Poppins",
40
- "sans-serif"
41
- ] },
42
- fontSize: {
43
- xs: "12px",
44
- sm: "14px",
45
- md: "16px",
46
- lg: "18px",
47
- xl: "20px"
48
- },
49
- fontWeight: {
50
- normal: 400,
51
- medium: 500,
52
- semibold: 600,
53
- bold: 700
54
- },
55
- spacing: {
56
- px: "1px",
57
- .5: "2px",
58
- 1: "4px",
59
- 1.5: "6px",
60
- 2: "8px",
61
- 2.5: "10px",
62
- 3: "12px",
63
- 3.5: "14px",
64
- 4: "16px",
65
- 5: "20px",
66
- 6: "24px",
67
- 7: "28px",
68
- 8: "32px",
69
- 9: "36px",
70
- 10: "40px",
71
- 12: "48px",
72
- 14: "56px",
73
- 16: "64px",
74
- 20: "80px",
75
- 24: "96px",
76
- 28: "112px",
77
- 32: "128px",
78
- 36: "144px",
79
- 40: "160px",
80
- 44: "176px",
81
- 48: "192px",
82
- 52: "208px",
83
- 56: "224px",
84
- 60: "240px",
85
- 64: "256px",
86
- 72: "288px",
87
- 80: "320px",
88
- 96: "384px"
89
- },
90
- borderRadius: {
91
- none: "0",
92
- sm: "2px",
93
- base: "4px",
94
- md: "6px",
95
- lg: "8px",
96
- xl: "12px",
97
- "2xl": "16px",
98
- "3xl": "24px",
99
- full: "9999px"
100
- },
101
- extend: {
102
- keyframes: {
103
- pulse: {
104
- "0%": {
105
- borderColor: "#EDF2F7",
106
- background: "#EDF2F7"
107
- },
108
- "50%": {},
109
- "100%": {
110
- borderColor: "#A0AEC0",
111
- background: "#A0AEC0"
112
- }
113
- },
114
- ellipse_162_1_flow_1: {
115
- from: {
116
- transform: "translate(0px, 0px) rotate(0deg)",
117
- transformOrigin: "8.5px 9.5px",
118
- cy: "9.5px"
119
- },
120
- to: {
121
- transform: "translate(0px, 0px) rotate(0deg)",
122
- transformOrigin: "8.5px 7.5px",
123
- cy: "7.5px"
124
- }
125
- },
126
- ellipse_162_1_flow_2: {
127
- from: {
128
- transform: "translate(0px, 0px) rotate(0deg)",
129
- transformOrigin: "8.5px 7.5px",
130
- cy: "7.5px"
131
- },
132
- to: {
133
- transform: "translate(0px, 0px) rotate(0deg)",
134
- transformOrigin: "8.5px 9.5px",
135
- cy: "9.5px"
136
- }
137
- },
138
- ellipse_162_1_flow_5: {
139
- from: {
140
- transform: "translate(0px, 0px) rotate(0deg)",
141
- transformOrigin: "8.5px 9.5px",
142
- cy: "9.5px"
143
- },
144
- to: {
145
- transform: "translate(0px, 0px) rotate(0deg)",
146
- transformOrigin: "8.5px 7.5px",
147
- cy: "7.5px"
148
- }
149
- },
150
- ellipse_162_1_flow_6: {
151
- from: {
152
- transform: "translate(0px, 0px) rotate(0deg)",
153
- transformOrigin: "8.5px 7.5px",
154
- cy: "7.5px"
155
- },
156
- to: {
157
- transform: "translate(0px, 0px) rotate(0deg)",
158
- transformOrigin: "8.5px 9.5px",
159
- cy: "9.5px"
160
- }
161
- },
162
- ellipse_163_2_flow_2: {
163
- from: {
164
- transform: "translate(0px, 0px) rotate(0deg)",
165
- transformOrigin: "16.5px 9.5px",
166
- cy: "9.5px"
167
- },
168
- to: {
169
- transform: "translate(0px, 0px) rotate(0deg)",
170
- transformOrigin: "16.5px 7.5px",
171
- cy: "7.5px"
172
- }
173
- },
174
- ellipse_163_2_flow_3: {
175
- from: {
176
- transform: "translate(0px, 0px) rotate(0deg)",
177
- transformOrigin: "16.5px 7.5px",
178
- cy: "7.5px"
179
- },
180
- to: {
181
- transform: "translate(0px, 0px) rotate(0deg)",
182
- transformOrigin: "16.5px 9.5px",
183
- cy: "9.5px"
184
- }
185
- },
186
- ellipse_163_2_flow_6: {
187
- from: {
188
- transform: "translate(0px, 0px) rotate(0deg)",
189
- transformOrigin: "16.5px 9.5px",
190
- cy: "9.5px"
191
- },
192
- to: {
193
- transform: "translate(0px, 0px) rotate(0deg)",
194
- transformOrigin: "16.5px 7.5px",
195
- cy: "7.5px"
196
- }
197
- },
198
- ellipse_163_2_flow_7: {
199
- from: {
200
- transform: "translate(0px, 0px) rotate(0deg)",
201
- transformOrigin: "16.5px 7.5px",
202
- cy: "7.5px"
203
- },
204
- to: {
205
- transform: "translate(0px, 0px) rotate(0deg)",
206
- transformOrigin: "16.5px 9.5px",
207
- cy: "9.5px"
208
- }
209
- },
210
- ellipse_164_3_flow_3: {
211
- from: {
212
- transform: "translate(0px, 0px) rotate(0deg)",
213
- transformOrigin: "24.5px 9.5px",
214
- cy: "9.5px"
215
- },
216
- to: {
217
- transform: "translate(0px, 0px) rotate(0deg)",
218
- transformOrigin: "24.5px 7.5px",
219
- cy: "7.5px"
220
- }
221
- },
222
- ellipse_164_3_flow_4: {
223
- from: {
224
- transform: "translate(0px, 0px) rotate(0deg)",
225
- transformOrigin: "24.5px 7.5px",
226
- cy: "7.5px"
227
- },
228
- to: {
229
- transform: "translate(0px, 0px) rotate(0deg)",
230
- transformOrigin: "24.5px 9.5px",
231
- cy: "9.5px"
232
- }
233
- },
234
- ellipse_164_3_flow_7: {
235
- from: {
236
- transform: "translate(0px, 0px) rotate(0deg)",
237
- transformOrigin: "24.5px 9.5px",
238
- cy: "9.5px"
239
- },
240
- to: {
241
- transform: "translate(0px, 0px) rotate(0deg)",
242
- transformOrigin: "24.5px 7.5px",
243
- cy: "7.5px"
244
- }
245
- },
246
- ellipse_164_3_flow_8: {
247
- from: {
248
- transform: "translate(0px, 0px) rotate(0deg)",
249
- transformOrigin: "24.5px 7.5px",
250
- cy: "7.5px"
251
- },
252
- to: {
253
- transform: "translate(0px, 0px) rotate(0deg)",
254
- transformOrigin: "24.5px 9.5px",
255
- cy: "9.5px"
256
- }
257
- }
258
- },
259
- animation: {
260
- pulse: "pulse 0.8s linear infinite alternate",
261
- "ellipse-1-complete": "ellipse_162_1_flow_1 0.3s ease-out 0s forwards, ellipse_162_1_flow_2 0.2s ease-out 0.3s forwards, ellipse_162_1_flow_5 0.2s ease-out 0.91s forwards, ellipse_162_1_flow_6 0.2s ease-out 1.11s forwards",
262
- "ellipse-2-complete": "ellipse_163_2_flow_2 0.2s ease-out 0.3s forwards, ellipse_163_2_flow_3 0.2s ease-out 0.5s forwards, ellipse_163_2_flow_6 0.2s ease-out 1.11s forwards, ellipse_163_2_flow_7 0.2s ease-out 1.31s forwards",
263
- "ellipse-3-complete": "ellipse_164_3_flow_3 0.2s ease-out 0.5s forwards, ellipse_164_3_flow_4 0.2s ease-out 0.7s forwards, ellipse_164_3_flow_7 0.2s ease-out 1.31s forwards, ellipse_164_3_flow_8 0.2s ease-out 1.51s forwards"
264
- }
265
- }
266
- },
267
- content: [createEnviveContentPaths(["./index.html", "./src/**/*.{js,ts,jsx,tsx}"])],
268
- plugins: [__tailwindcss_typography.default]
269
- };
270
-
271
- //#endregion
272
- exports.EnviveTailwindPreset = EnviveTailwindPreset;
273
- exports.createEnviveContentPaths = createEnviveContentPaths;
274
- exports.default = EnviveTailwindPreset;