@envive-ai/react-toolkit 0.1.1 → 0.1.2
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.
- package/dist/AppliedFiltersScrollbar-BlcyhZkZ.cjs +53 -0
- package/dist/AppliedFiltersScrollbar-DFGzRemu.js +44 -0
- package/dist/ButtonBase-C1rsL9gO.js +60 -0
- package/dist/ButtonBase-a8uj6c2f.cjs +69 -0
- package/dist/DynamicFiltersScrollbar-B2Rr1KnJ.cjs +41 -0
- package/dist/DynamicFiltersScrollbar-Dys6geP0.js +32 -0
- package/dist/Headline-L7w3BsBF.cjs +72 -0
- package/dist/Headline-ro_Nigw5.js +64 -0
- package/dist/ImageWithFallback-CfmkC58B.js +42 -0
- package/dist/ImageWithFallback-P3AjyL2Y.cjs +51 -0
- package/dist/ProductCard-Btg8tHGc.js +172 -0
- package/dist/ProductCard-CS6DZAwO.cjs +193 -0
- package/dist/ProductCardSkeleton-BPfp6IOp.js +38 -0
- package/dist/ProductCardSkeleton-BgvDlaty.cjs +46 -0
- package/dist/ProductGrid-B7QZfW-v.cjs +77 -0
- package/dist/ProductGrid-DB_Uq5F-.js +69 -0
- package/dist/SearchAutocomplete-C5FL82xC.js +51 -0
- package/dist/SearchAutocomplete-wr18dJ8L.cjs +62 -0
- package/dist/SearchFilter-D-2IdBKS.js +62 -0
- package/dist/SearchFilter-D0IzBlG5.cjs +70 -0
- package/dist/SearchFilterHeader-BQT0-ssS.js +37 -0
- package/dist/SearchFilterHeader-C3EklfoO.cjs +45 -0
- package/dist/SearchFilterItem-BodtWLoP.js +26 -0
- package/dist/SearchFilterItem-DmMkiqNC.cjs +34 -0
- package/dist/SearchInput-BrcAgcvI.js +89 -0
- package/dist/SearchInput-DSB9CwIq.cjs +106 -0
- package/dist/SparkleAnimation-BpLwrEqM.cjs +96 -0
- package/dist/SparkleAnimation-CXs58sFd.js +85 -0
- package/dist/Spinner-BZ-kTOpm.js +38 -0
- package/dist/Spinner-CfQ85Ajl.cjs +46 -0
- package/dist/Text-Bdv7F5-u.js +42 -0
- package/dist/Text-C04c4Z93.cjs +50 -0
- package/dist/TextInput-BO80ixsV.cjs +40 -0
- package/dist/TextInput-CEGWfdPC.js +31 -0
- package/dist/chunk-CUT6urMc.cjs +30 -0
- package/dist/colorsConfig-TCONYTQ7.cjs +38 -0
- package/dist/colorsConfig-l0ODUVhu.js +26 -0
- package/dist/common/ButtonBase/ButtonBase.cjs +5 -0
- package/dist/common/ButtonBase/ButtonBase.d.cts +35 -0
- package/dist/common/ButtonBase/ButtonBase.d.ts +35 -0
- package/dist/common/ButtonBase/ButtonBase.js +5 -0
- package/dist/common/Headline/Headline.cjs +4 -0
- package/dist/common/Headline/Headline.d.cts +21 -0
- package/dist/common/Headline/Headline.d.ts +21 -0
- package/dist/common/Headline/Headline.js +4 -0
- package/dist/common/ImageWithFallback/ImageWithFallback.cjs +3 -0
- package/dist/common/ImageWithFallback/ImageWithFallback.d.cts +26 -0
- package/dist/common/ImageWithFallback/ImageWithFallback.d.ts +26 -0
- package/dist/common/ImageWithFallback/ImageWithFallback.js +3 -0
- package/dist/common/ProductCard/ProductCard.cjs +11 -0
- package/dist/common/ProductCard/ProductCard.d.cts +91 -0
- package/dist/common/ProductCard/ProductCard.d.ts +91 -0
- package/dist/common/ProductCard/ProductCard.js +9 -0
- package/dist/common/ProductCard/ProductCardSkeleton.cjs +4 -0
- package/dist/common/ProductCard/ProductCardSkeleton.d.cts +12 -0
- package/dist/common/ProductCard/ProductCardSkeleton.d.ts +12 -0
- package/dist/common/ProductCard/ProductCardSkeleton.js +4 -0
- package/dist/common/ProductGrid/ProductGrid.cjs +11 -0
- package/dist/common/ProductGrid/ProductGrid.d.cts +26 -0
- package/dist/common/ProductGrid/ProductGrid.d.ts +26 -0
- package/dist/common/ProductGrid/ProductGrid.js +11 -0
- package/dist/common/SparkleAnimation/SparkleAnimation.cjs +3 -0
- package/dist/common/SparkleAnimation/SparkleAnimation.d.cts +15 -0
- package/dist/common/SparkleAnimation/SparkleAnimation.d.ts +15 -0
- package/dist/common/SparkleAnimation/SparkleAnimation.js +3 -0
- package/dist/common/Spinner/Spinner.cjs +3 -0
- package/dist/common/Spinner/Spinner.d.cts +11 -0
- package/dist/common/Spinner/Spinner.d.ts +11 -0
- package/dist/common/Spinner/Spinner.js +3 -0
- package/dist/common/SuggestionButton/SuggestionButton.cjs +188 -0
- package/dist/common/SuggestionButton/SuggestionButton.d.cts +35 -0
- package/dist/common/SuggestionButton/SuggestionButton.d.ts +35 -0
- package/dist/common/SuggestionButton/SuggestionButton.js +180 -0
- package/dist/common/Text/Text.cjs +4 -0
- package/dist/common/Text/Text.d.cts +28 -0
- package/dist/common/Text/Text.d.ts +28 -0
- package/dist/common/Text/Text.js +4 -0
- package/dist/common/TextInput/TextInput.cjs +4 -0
- package/dist/common/TextInput/TextInput.d.cts +98 -0
- package/dist/common/TextInput/TextInput.d.ts +98 -0
- package/dist/common/TextInput/TextInput.js +4 -0
- package/dist/productCardVariants-C_QIZ-KF.js +45 -0
- package/dist/productCardVariants-Dd-wrJKP.cjs +69 -0
- package/dist/productGridVariants-CxCKx5Fq.js +20 -0
- package/dist/productGridVariants-DVzvjK9i.cjs +26 -0
- package/dist/search/FilterScrollbar/AppliedFiltersScrollbar.cjs +5 -0
- package/dist/search/FilterScrollbar/AppliedFiltersScrollbar.d.cts +22 -0
- package/dist/search/FilterScrollbar/AppliedFiltersScrollbar.d.ts +22 -0
- package/dist/search/FilterScrollbar/AppliedFiltersScrollbar.js +5 -0
- package/dist/search/FilterScrollbar/DynamicFiltersScrollbar.cjs +5 -0
- package/dist/search/FilterScrollbar/DynamicFiltersScrollbar.d.cts +28 -0
- package/dist/search/FilterScrollbar/DynamicFiltersScrollbar.d.ts +28 -0
- package/dist/search/FilterScrollbar/DynamicFiltersScrollbar.js +5 -0
- package/dist/search/SearchFilter/SearchFilter.cjs +7 -0
- package/dist/search/SearchFilter/SearchFilter.d.cts +18 -0
- package/dist/search/SearchFilter/SearchFilter.d.ts +18 -0
- package/dist/search/SearchFilter/SearchFilter.js +7 -0
- package/dist/search/SearchFilter/SearchFilterHeader.cjs +5 -0
- package/dist/search/SearchFilter/SearchFilterHeader.d.cts +12 -0
- package/dist/search/SearchFilter/SearchFilterHeader.d.ts +12 -0
- package/dist/search/SearchFilter/SearchFilterHeader.js +5 -0
- package/dist/search/SearchFilter/SearchFilterItem.cjs +5 -0
- package/dist/search/SearchFilter/SearchFilterItem.d.cts +13 -0
- package/dist/search/SearchFilter/SearchFilterItem.d.ts +13 -0
- package/dist/search/SearchFilter/SearchFilterItem.js +5 -0
- package/dist/search/SearchInput/SearchInput.cjs +6 -0
- package/dist/search/SearchInput/SearchInput.d.cts +20 -0
- package/dist/search/SearchInput/SearchInput.d.ts +20 -0
- package/dist/search/SearchInput/SearchInput.js +6 -0
- package/dist/search/SearchInputAutocomplete/SearchAutocomplete.cjs +3 -0
- package/dist/search/SearchInputAutocomplete/SearchAutocomplete.d.cts +13 -0
- package/dist/search/SearchInputAutocomplete/SearchAutocomplete.d.ts +13 -0
- package/dist/search/SearchInputAutocomplete/SearchAutocomplete.js +3 -0
- package/dist/search/SearchInputForm/SearchInputForm.cjs +38 -0
- package/dist/search/SearchInputForm/SearchInputForm.d.cts +32 -0
- package/dist/search/SearchInputForm/SearchInputForm.d.ts +32 -0
- package/dist/search/SearchInputForm/SearchInputForm.js +36 -0
- package/dist/search/SearchResultsFilterSidebar/SearchResultsFilter.cjs +52 -0
- package/dist/search/SearchResultsFilterSidebar/SearchResultsFilter.d.cts +28 -0
- package/dist/search/SearchResultsFilterSidebar/SearchResultsFilter.d.ts +28 -0
- package/dist/search/SearchResultsFilterSidebar/SearchResultsFilter.js +49 -0
- package/dist/search/SearchResultsStates/NoSearchResultsFound.cjs +30 -0
- package/dist/search/SearchResultsStates/NoSearchResultsFound.d.cts +17 -0
- package/dist/search/SearchResultsStates/NoSearchResultsFound.d.ts +17 -0
- package/dist/search/SearchResultsStates/NoSearchResultsFound.js +26 -0
- package/dist/search/SearchResultsStates/SearchResultsGrid.cjs +66 -0
- package/dist/search/SearchResultsStates/SearchResultsGrid.d.cts +41 -0
- package/dist/search/SearchResultsStates/SearchResultsGrid.d.ts +41 -0
- package/dist/search/SearchResultsStates/SearchResultsGrid.js +62 -0
- package/dist/search/SearchResultsStates/SearchResultsLoadingGrid.cjs +52 -0
- package/dist/search/SearchResultsStates/SearchResultsLoadingGrid.d.cts +15 -0
- package/dist/search/SearchResultsStates/SearchResultsLoadingGrid.d.ts +15 -0
- package/dist/search/SearchResultsStates/SearchResultsLoadingGrid.js +49 -0
- package/dist/searchFilterSidebarVariants-GfFbQzGf.cjs +39 -0
- package/dist/searchFilterSidebarVariants-lJVVZT_2.js +34 -0
- package/dist/textVariantClasses-5t3OricK.js +101 -0
- package/dist/textVariantClasses-Bhf4VY5z.cjs +125 -0
- package/dist/types-53zIialA.d.ts +35 -0
- package/dist/types-B4BGZSlV.d.cts +4 -0
- package/dist/types-BQNqA5xL.d.ts +46 -0
- package/dist/types-BRLWwGMI.d.ts +4 -0
- package/dist/types-CImLkcNh.d.cts +46 -0
- package/dist/types-Cph97xkm.d.ts +6 -0
- package/dist/types-CpiJO5UH.d.ts +4 -0
- package/dist/types-DFetqNL2.d.ts +8 -0
- package/dist/types-DaSkJnT_.d.cts +8 -0
- package/dist/types-Dy4_w6Cf.d.cts +4 -0
- package/dist/types-TYhhwWZw.d.cts +6 -0
- package/dist/types-aa4flfRE.d.cts +35 -0
- package/package.json +8 -8
- package/src/components/common/ButtonBase/ButtonBase.tsx +2 -2
- package/src/components/common/ButtonBase/types.ts +2 -3
- package/dist/src/atoms/search/types.d.ts +0 -5
- package/dist/src/atoms/search/types.js +0 -1
- package/dist/src/components/common/ButtonBase/ButtonBase.d.ts +0 -2
- package/dist/src/components/common/ButtonBase/ButtonBase.js +0 -41
- package/dist/src/components/common/ButtonBase/types.d.ts +0 -24
- package/dist/src/components/common/ButtonBase/types.js +0 -6
- package/dist/src/components/common/Headline/Headline.d.ts +0 -10
- package/dist/src/components/common/Headline/Headline.js +0 -34
- package/dist/src/components/common/ImageWithFallback/ImageWithFallback.d.ts +0 -12
- package/dist/src/components/common/ImageWithFallback/ImageWithFallback.js +0 -26
- package/dist/src/components/common/ProductCard/ProductCard.d.ts +0 -39
- package/dist/src/components/common/ProductCard/ProductCard.js +0 -84
- package/dist/src/components/common/ProductCard/ProductCardSkeleton.d.ts +0 -9
- package/dist/src/components/common/ProductCard/ProductCardSkeleton.js +0 -15
- package/dist/src/components/common/ProductCard/productCardVariants.d.ts +0 -8
- package/dist/src/components/common/ProductCard/productCardVariants.js +0 -50
- package/dist/src/components/common/ProductCard/types.d.ts +0 -39
- package/dist/src/components/common/ProductCard/types.js +0 -10
- package/dist/src/components/common/ProductGrid/ProductGrid.d.ts +0 -14
- package/dist/src/components/common/ProductGrid/ProductGrid.js +0 -13
- package/dist/src/components/common/ProductGrid/productGridVariants.d.ts +0 -10
- package/dist/src/components/common/ProductGrid/productGridVariants.js +0 -16
- package/dist/src/components/common/SparkleAnimation/SparkleAnimation.d.ts +0 -7
- package/dist/src/components/common/SparkleAnimation/SparkleAnimation.js +0 -40
- package/dist/src/components/common/SparkleAnimation/types.d.ts +0 -6
- package/dist/src/components/common/SparkleAnimation/types.js +0 -7
- package/dist/src/components/common/Spinner/Spinner.d.ts +0 -5
- package/dist/src/components/common/Spinner/Spinner.js +0 -16
- package/dist/src/components/common/SuggestionButton/SuggestionButton.d.ts +0 -18
- package/dist/src/components/common/SuggestionButton/SuggestionButton.js +0 -210
- package/dist/src/components/common/SuggestionButton/types.d.ts +0 -1
- package/dist/src/components/common/SuggestionButton/types.js +0 -1
- package/dist/src/components/common/Text/Text.d.ts +0 -12
- package/dist/src/components/common/Text/Text.js +0 -26
- package/dist/src/components/common/Text/textVariantClasses.d.ts +0 -171
- package/dist/src/components/common/Text/textVariantClasses.js +0 -103
- package/dist/src/components/common/Text/types.d.ts +0 -16
- package/dist/src/components/common/Text/types.js +0 -6
- package/dist/src/components/common/TextInput/TextInput.d.ts +0 -8
- package/dist/src/components/common/TextInput/TextInput.js +0 -25
- package/dist/src/components/models/colorsConfig.d.ts +0 -26
- package/dist/src/components/models/colorsConfig.js +0 -23
- package/dist/src/components/search/FilterScrollbar/AppliedFiltersScrollbar.d.ts +0 -11
- package/dist/src/components/search/FilterScrollbar/AppliedFiltersScrollbar.js +0 -18
- package/dist/src/components/search/FilterScrollbar/DynamicFiltersScrollbar.d.ts +0 -15
- package/dist/src/components/search/FilterScrollbar/DynamicFiltersScrollbar.js +0 -15
- package/dist/src/components/search/SearchFilter/SearchFilter.d.ts +0 -2
- package/dist/src/components/search/SearchFilter/SearchFilter.js +0 -24
- package/dist/src/components/search/SearchFilter/SearchFilterHeader.d.ts +0 -2
- package/dist/src/components/search/SearchFilter/SearchFilterHeader.js +0 -9
- package/dist/src/components/search/SearchFilter/SearchFilterItem.d.ts +0 -2
- package/dist/src/components/search/SearchFilter/SearchFilterItem.js +0 -13
- package/dist/src/components/search/SearchFilter/types.d.ts +0 -42
- package/dist/src/components/search/SearchFilter/types.js +0 -1
- package/dist/src/components/search/SearchInput/SearchInput.d.ts +0 -16
- package/dist/src/components/search/SearchInput/SearchInput.js +0 -38
- package/dist/src/components/search/SearchInput/searchInputVariants.d.ts +0 -13
- package/dist/src/components/search/SearchInput/searchInputVariants.js +0 -12
- package/dist/src/components/search/SearchInputAutocomplete/SearchAutocomplete.d.ts +0 -10
- package/dist/src/components/search/SearchInputAutocomplete/SearchAutocomplete.js +0 -14
- package/dist/src/components/search/SearchInputForm/SearchInputForm.d.ts +0 -16
- package/dist/src/components/search/SearchInputForm/SearchInputForm.js +0 -13
- package/dist/src/components/search/SearchInputForm/types.d.ts +0 -1
- package/dist/src/components/search/SearchInputForm/types.js +0 -1
- package/dist/src/components/search/SearchResultsFilterSidebar/SearchResultsFilter.d.ts +0 -14
- package/dist/src/components/search/SearchResultsFilterSidebar/SearchResultsFilter.js +0 -15
- package/dist/src/components/search/SearchResultsFilterSidebar/searchFilterSidebarVariants.d.ts +0 -16
- package/dist/src/components/search/SearchResultsFilterSidebar/searchFilterSidebarVariants.js +0 -29
- package/dist/src/components/search/SearchResultsFilterSidebar/types.d.ts +0 -2
- package/dist/src/components/search/SearchResultsFilterSidebar/types.js +0 -1
- package/dist/src/components/search/SearchResultsStates/NoSearchResultsFound.d.ts +0 -8
- package/dist/src/components/search/SearchResultsStates/NoSearchResultsFound.js +0 -10
- package/dist/src/components/search/SearchResultsStates/SearchResultsGrid.d.ts +0 -24
- package/dist/src/components/search/SearchResultsStates/SearchResultsGrid.js +0 -19
- package/dist/src/components/search/SearchResultsStates/SearchResultsLoadingGrid.d.ts +0 -6
- package/dist/src/components/search/SearchResultsStates/SearchResultsLoadingGrid.js +0 -10
- package/dist/src/components/search/types.d.ts +0 -5
- package/dist/src/components/search/types.js +0 -6
- package/dist/src/components/test/types.d.ts +0 -3
- package/dist/src/components/test/types.js +0 -1
- package/dist/src/config/chatElementDisplayLocation.d.ts +0 -21
- package/dist/src/config/chatElementDisplayLocation.js +0 -23
- package/dist/src/index.d.ts +0 -45
- package/dist/src/index.js +0 -49
- package/dist/src/logging/logger.d.ts +0 -7
- package/dist/src/logging/logger.js +0 -16
- package/dist/src/types/external.d.ts +0 -21
- package/dist/src/types/external.js +0 -5
- package/dist/src/util/camelCase.d.ts +0 -65
- package/dist/src/util/camelCase.js +0 -2
- package/dist/src/util/camelCasedPropertiesDeep.d.ts +0 -53
- package/dist/src/util/camelCasedPropertiesDeep.js +0 -1
- package/dist/src/util/formatPrice.d.ts +0 -1
- package/dist/src/util/formatPrice.js +0 -11
- package/dist/src/util/internal.d.ts +0 -27
- package/dist/src/util/internal.js +0 -4
- package/dist/src/util/primitive.d.ts +0 -6
- package/dist/src/util/primitive.js +0 -2
- package/dist/src/util/splitWords.d.ts +0 -55
- package/dist/src/util/splitWords.js +0 -2
- package/dist/src/util/trim.d.ts +0 -24
- package/dist/src/util/trim.js +0 -2
- package/dist/src/util/unknownArray.d.ts +0 -25
- package/dist/src/util/unknownArray.js +0 -1
- package/src/index.ts +0 -59
|
@@ -0,0 +1,180 @@
|
|
|
1
|
+
import { ButtonBase } from "../../ButtonBase-C1rsL9gO.js";
|
|
2
|
+
import "../../textVariantClasses-5t3OricK.js";
|
|
3
|
+
import "../../Text-Bdv7F5-u.js";
|
|
4
|
+
import classNames from "classnames";
|
|
5
|
+
import { jsx } from "react/jsx-runtime";
|
|
6
|
+
import FourPointStar from "@envive-ai/react-icons/src/FourPointStar";
|
|
7
|
+
import OutlinedStar from "@envive-ai/react-icons/src/OutlinedStar";
|
|
8
|
+
|
|
9
|
+
//#region src/components/common/SuggestionButton/SuggestionButton.tsx
|
|
10
|
+
const SPIFFY_SUGGESTION_BUTTON_QUESTION_CLASS = "spiffy-suggestion-button-question-class";
|
|
11
|
+
const SPIFFY_SUGGESTION_BUTTON_ANSWER_CLASS = "spiffy-suggestion-button-answer-class";
|
|
12
|
+
const SPIFFY_SUGGESTION_BUTTON_TEXT_CLASS = "spiffy-suggestion-button-text-class";
|
|
13
|
+
const BORDER_CLASS = "spiffy-tw-border";
|
|
14
|
+
const TEXT_LINK_CLASSES = [
|
|
15
|
+
"spiffy-tw-text-[--spiffy-colors-text-link]",
|
|
16
|
+
"spiffy-tw-fill-[--spiffy-colors-text-link]",
|
|
17
|
+
"spiffy-tw-stroke-[--spiffy-colors-text-link]"
|
|
18
|
+
];
|
|
19
|
+
const TEXT_LIGHT_CLASSES = [
|
|
20
|
+
"spiffy-tw-text-[--spiffy-colors-text-light]",
|
|
21
|
+
"spiffy-tw-fill-[--spiffy-colors-text-light]",
|
|
22
|
+
"spiffy-tw-stroke-[--spiffy-colors-text-light]"
|
|
23
|
+
];
|
|
24
|
+
const TEXT_PRIMARY_CLASSES = [
|
|
25
|
+
"spiffy-tw-text-[--spiffy-colors-text-primary]",
|
|
26
|
+
"spiffy-tw-fill-[--spiffy-colors-text-primary]",
|
|
27
|
+
"spiffy-tw-stroke-[--spiffy-colors-text-primary]"
|
|
28
|
+
];
|
|
29
|
+
const ACCENT_PRIMARY_CLASSES = ["spiffy-tw-fill-[--spiffy-colors-accent-primary]", "spiffy-tw-stroke-[--spiffy-colors-accent-primary]"];
|
|
30
|
+
const DARK_BACKGROUND_CLASSES = ["spiffy-tw-bg-[--spiffy-colors-background-dark]", "spiffy-tw-border-[--spiffy-colors-background-dark]"];
|
|
31
|
+
const SECONDARY_DARK_BACKGROUND_CLASSES = ["spiffy-tw-bg-[--spiffy-colors-background-secondary-dark]", "spiffy-tw-border-[--spiffy-colors-background-secondary-dark]"];
|
|
32
|
+
const variantClassMap = new Map([
|
|
33
|
+
["outlined", ["spiffy-tw-border-[--spiffy-colors-border-outline]", ...TEXT_LINK_CLASSES]],
|
|
34
|
+
["outlinedLight", [
|
|
35
|
+
"spiffy-tw-border-[--spiffy-colors-border-outline]",
|
|
36
|
+
"spiffy-tw-bg-[--spiffy-colors-background-light]",
|
|
37
|
+
...TEXT_LINK_CLASSES,
|
|
38
|
+
BORDER_CLASS
|
|
39
|
+
]],
|
|
40
|
+
["primary", [
|
|
41
|
+
"spiffy-tw-bg-[--spiffy-colors-background-primary]",
|
|
42
|
+
"spiffy-tw-border-[--spiffy-colors-background-primary]",
|
|
43
|
+
...TEXT_LIGHT_CLASSES,
|
|
44
|
+
BORDER_CLASS
|
|
45
|
+
]],
|
|
46
|
+
["secondary", [
|
|
47
|
+
"spiffy-tw-bg-[--spiffy-colors-background-secondary]",
|
|
48
|
+
"spiffy-tw-text-[--spiffy-colors-text-link]",
|
|
49
|
+
"spiffy-tw-border-[--spiffy-colors-background-secondary]",
|
|
50
|
+
...ACCENT_PRIMARY_CLASSES,
|
|
51
|
+
BORDER_CLASS
|
|
52
|
+
]],
|
|
53
|
+
["tertiary", [
|
|
54
|
+
"spiffy-tw-bg-[--spiffy-colors-background-tertiary]",
|
|
55
|
+
"spiffy-tw-border-[--spiffy-colors-background-tertiary]",
|
|
56
|
+
...TEXT_LINK_CLASSES,
|
|
57
|
+
BORDER_CLASS
|
|
58
|
+
]],
|
|
59
|
+
["dark", [
|
|
60
|
+
...DARK_BACKGROUND_CLASSES,
|
|
61
|
+
...TEXT_LIGHT_CLASSES,
|
|
62
|
+
BORDER_CLASS
|
|
63
|
+
]],
|
|
64
|
+
["darkPrimary", [
|
|
65
|
+
...DARK_BACKGROUND_CLASSES,
|
|
66
|
+
"spiffy-tw-text-[--spiffy-colors-text-light]",
|
|
67
|
+
...ACCENT_PRIMARY_CLASSES,
|
|
68
|
+
BORDER_CLASS
|
|
69
|
+
]],
|
|
70
|
+
["darkAccent", [
|
|
71
|
+
...DARK_BACKGROUND_CLASSES,
|
|
72
|
+
"spiffy-tw-text-[--spiffy-colors-text-light]",
|
|
73
|
+
"spiffy-tw-fill-[--spiffy-colors-text-accent]",
|
|
74
|
+
"spiffy-tw-stroke-[--spiffy-colors-text-accent]",
|
|
75
|
+
BORDER_CLASS
|
|
76
|
+
]],
|
|
77
|
+
["transparent", [
|
|
78
|
+
"spiffy-tw-bg-transparent",
|
|
79
|
+
"spiffy-tw-border-[--spiffy-colors-background-light]",
|
|
80
|
+
"spiffy-tw-text-[--spiffy-colors-text-light]",
|
|
81
|
+
"spiffy-tw-fill-transparent",
|
|
82
|
+
"spiffy-tw-stroke-[--spiffy-colors-text-light]",
|
|
83
|
+
BORDER_CLASS
|
|
84
|
+
]],
|
|
85
|
+
["transparentDark", [
|
|
86
|
+
"spiffy-tw-bg-transparent",
|
|
87
|
+
"spiffy-tw-border-[--spiffy-colors-border-light]",
|
|
88
|
+
"spiffy-tw-text-[--spiffy-colors-text-primary]",
|
|
89
|
+
"spiffy-tw-fill-transparent",
|
|
90
|
+
"spiffy-tw-stroke-[--spiffy-colors-text-primary]",
|
|
91
|
+
BORDER_CLASS
|
|
92
|
+
]],
|
|
93
|
+
["secondaryDark", [
|
|
94
|
+
...SECONDARY_DARK_BACKGROUND_CLASSES,
|
|
95
|
+
...TEXT_LINK_CLASSES,
|
|
96
|
+
BORDER_CLASS
|
|
97
|
+
]],
|
|
98
|
+
["secondaryAccent", [
|
|
99
|
+
...SECONDARY_DARK_BACKGROUND_CLASSES,
|
|
100
|
+
"spiffy-tw-text-[--spiffy-colors-text-link]",
|
|
101
|
+
...ACCENT_PRIMARY_CLASSES,
|
|
102
|
+
BORDER_CLASS
|
|
103
|
+
]],
|
|
104
|
+
["lightDark", [
|
|
105
|
+
"spiffy-tw-bg-[--spiffy-colors-background-light]",
|
|
106
|
+
"spiffy-tw-border-[--spiffy-colors-background-dark]",
|
|
107
|
+
...TEXT_PRIMARY_CLASSES,
|
|
108
|
+
BORDER_CLASS
|
|
109
|
+
]]
|
|
110
|
+
]);
|
|
111
|
+
const borderedVariants = [
|
|
112
|
+
"outlined",
|
|
113
|
+
"outlinedLight",
|
|
114
|
+
"primary",
|
|
115
|
+
"secondary",
|
|
116
|
+
"tertiary",
|
|
117
|
+
"dark",
|
|
118
|
+
"darkAccent",
|
|
119
|
+
"darkPrimary",
|
|
120
|
+
"transparent",
|
|
121
|
+
"transparentDark",
|
|
122
|
+
"secondaryDark",
|
|
123
|
+
"secondaryAccent",
|
|
124
|
+
"lightDark"
|
|
125
|
+
];
|
|
126
|
+
const hoverTransform = (variantClass) => variantClass?.map((className) => `hover:${className}`);
|
|
127
|
+
const SuggestionButton = ({ variant, hoverVariant, isDisabled, content, boldText, borderRadius = "lg", isAnswer = false, dataAttributes, dataTestId, onClick }) => {
|
|
128
|
+
const buttonClassName = classNames({
|
|
129
|
+
[SPIFFY_SUGGESTION_BUTTON_QUESTION_CLASS]: !isAnswer,
|
|
130
|
+
[SPIFFY_SUGGESTION_BUTTON_ANSWER_CLASS]: isAnswer,
|
|
131
|
+
"!spiffy-tw-rounded-[20px]": borderRadius === "lg",
|
|
132
|
+
"!spiffy-tw-rounded-[8px]": borderRadius === "md",
|
|
133
|
+
"!spiffy-tw-rounded-[0px]": borderRadius === "sm",
|
|
134
|
+
"spiffy-tw-border-[1px]": borderedVariants.includes(variant),
|
|
135
|
+
"spiffy-tw-border-solid": borderedVariants.includes(variant)
|
|
136
|
+
});
|
|
137
|
+
const textClassName = classNames({
|
|
138
|
+
"spiffy-tw-text-[14px]": true,
|
|
139
|
+
"spiffy-tw-leading-[100%]": true,
|
|
140
|
+
"!spiffy-tw-font-bold": boldText
|
|
141
|
+
});
|
|
142
|
+
const iconClass = classNames({
|
|
143
|
+
"spiffy-tw-w-[11px]": true,
|
|
144
|
+
"spiffy-tw-h-[11px]": true,
|
|
145
|
+
"spiffy-tw-stroke-inherit": true,
|
|
146
|
+
"spiffy-tw-fill-inherit": true
|
|
147
|
+
});
|
|
148
|
+
const baseClasses = variantClassMap.get(variant) ?? [];
|
|
149
|
+
const hoverClasses = variantClassMap.get(hoverVariant) ?? [];
|
|
150
|
+
const baseBorderClasses = baseClasses.filter((cls) => cls.includes("border"));
|
|
151
|
+
const baseNonBorderClasses = baseClasses.filter((cls) => !cls.includes("border"));
|
|
152
|
+
const hoverBorderClasses = hoverClasses.filter((cls) => cls.includes("border"));
|
|
153
|
+
const hoverNonBorderClasses = hoverClasses.filter((cls) => !cls.includes("border"));
|
|
154
|
+
const variantClasses = [
|
|
155
|
+
...baseNonBorderClasses,
|
|
156
|
+
...hoverTransform(hoverNonBorderClasses),
|
|
157
|
+
...baseBorderClasses,
|
|
158
|
+
...hoverTransform(hoverBorderClasses)
|
|
159
|
+
];
|
|
160
|
+
const buttonClass = `${buttonClassName} ${variantClasses.join(" ")}`;
|
|
161
|
+
const getIcon = () => {
|
|
162
|
+
if (isAnswer) return void 0;
|
|
163
|
+
if (variant === "transparentDark") return OutlinedStar;
|
|
164
|
+
return FourPointStar;
|
|
165
|
+
};
|
|
166
|
+
return /* @__PURE__ */ jsx(ButtonBase, {
|
|
167
|
+
text: content,
|
|
168
|
+
dataAttributes,
|
|
169
|
+
dataTestId,
|
|
170
|
+
isDisabled,
|
|
171
|
+
icon: getIcon(),
|
|
172
|
+
iconClass: isAnswer ? void 0 : iconClass,
|
|
173
|
+
textClass: `${SPIFFY_SUGGESTION_BUTTON_TEXT_CLASS} ${textClassName}`,
|
|
174
|
+
buttonClass,
|
|
175
|
+
onClick
|
|
176
|
+
});
|
|
177
|
+
};
|
|
178
|
+
|
|
179
|
+
//#endregion
|
|
180
|
+
export { SPIFFY_SUGGESTION_BUTTON_ANSWER_CLASS, SPIFFY_SUGGESTION_BUTTON_QUESTION_CLASS, SPIFFY_SUGGESTION_BUTTON_TEXT_CLASS, SuggestionButton };
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import * as react_jsx_runtime7 from "react/jsx-runtime";
|
|
2
|
+
|
|
3
|
+
//#region src/components/common/Text/types.d.ts
|
|
4
|
+
|
|
5
|
+
type TextVariant = 'body1' | 'body2' | 'body3' | 'body4' | 'body5';
|
|
6
|
+
type TextType = 'p' | 'span' | 'sub';
|
|
7
|
+
//#endregion
|
|
8
|
+
//#region src/components/common/Text/Text.d.ts
|
|
9
|
+
type TextProps = {
|
|
10
|
+
children: React.ReactNode;
|
|
11
|
+
noOfLines?: number;
|
|
12
|
+
className?: string;
|
|
13
|
+
style?: React.CSSProperties;
|
|
14
|
+
variant?: TextVariant;
|
|
15
|
+
type?: TextType;
|
|
16
|
+
testId?: string;
|
|
17
|
+
};
|
|
18
|
+
declare const Text: ({
|
|
19
|
+
children,
|
|
20
|
+
className,
|
|
21
|
+
style,
|
|
22
|
+
noOfLines,
|
|
23
|
+
testId,
|
|
24
|
+
type,
|
|
25
|
+
variant
|
|
26
|
+
}: TextProps) => react_jsx_runtime7.JSX.Element;
|
|
27
|
+
//#endregion
|
|
28
|
+
export { Text };
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import * as react_jsx_runtime17 from "react/jsx-runtime";
|
|
2
|
+
|
|
3
|
+
//#region src/components/common/Text/types.d.ts
|
|
4
|
+
|
|
5
|
+
type TextVariant = 'body1' | 'body2' | 'body3' | 'body4' | 'body5';
|
|
6
|
+
type TextType = 'p' | 'span' | 'sub';
|
|
7
|
+
//#endregion
|
|
8
|
+
//#region src/components/common/Text/Text.d.ts
|
|
9
|
+
type TextProps = {
|
|
10
|
+
children: React.ReactNode;
|
|
11
|
+
noOfLines?: number;
|
|
12
|
+
className?: string;
|
|
13
|
+
style?: React.CSSProperties;
|
|
14
|
+
variant?: TextVariant;
|
|
15
|
+
type?: TextType;
|
|
16
|
+
testId?: string;
|
|
17
|
+
};
|
|
18
|
+
declare const Text: ({
|
|
19
|
+
children,
|
|
20
|
+
className,
|
|
21
|
+
style,
|
|
22
|
+
noOfLines,
|
|
23
|
+
testId,
|
|
24
|
+
type,
|
|
25
|
+
variant
|
|
26
|
+
}: TextProps) => react_jsx_runtime17.JSX.Element;
|
|
27
|
+
//#endregion
|
|
28
|
+
export { Text };
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
//#region src/components/common/Text/textVariantClasses.d.ts
|
|
4
|
+
|
|
5
|
+
declare const TextStyleVariantMap: {
|
|
6
|
+
t1: {
|
|
7
|
+
'spiffy-headline': boolean;
|
|
8
|
+
'spiffy-headline-1': boolean;
|
|
9
|
+
'spiffy-tw-text-[32px]': boolean;
|
|
10
|
+
'spiffy-tw-font-medium': boolean;
|
|
11
|
+
'spiffy-tw-leading-[124%]': boolean;
|
|
12
|
+
};
|
|
13
|
+
t2: {
|
|
14
|
+
'spiffy-headline': boolean;
|
|
15
|
+
'spiffy-headline-1': boolean;
|
|
16
|
+
'spiffy-tw-text-[16px]': boolean;
|
|
17
|
+
'spiffy-tw-font-medium': boolean;
|
|
18
|
+
'spiffy-tw-leading-[124%]': boolean;
|
|
19
|
+
};
|
|
20
|
+
t3: {
|
|
21
|
+
'spiffy-headline': boolean;
|
|
22
|
+
'spiffy-headline-1': boolean;
|
|
23
|
+
'spiffy-tw-text-[24px]': boolean;
|
|
24
|
+
'spiffy-tw-leading-[120%]': boolean;
|
|
25
|
+
};
|
|
26
|
+
h1: {
|
|
27
|
+
'spiffy-headline': boolean;
|
|
28
|
+
'spiffy-headline-1': boolean;
|
|
29
|
+
'spiffy-tw-text-[20px]': boolean;
|
|
30
|
+
'spiffy-tw-font-normal': boolean;
|
|
31
|
+
'spiffy-tw-leading-[120%]': boolean;
|
|
32
|
+
};
|
|
33
|
+
h2: {
|
|
34
|
+
'spiffy-headline': boolean;
|
|
35
|
+
'spiffy-headline-2': boolean;
|
|
36
|
+
'spiffy-tw-text-[16px]': boolean;
|
|
37
|
+
'spiffy-tw-font-normal': boolean;
|
|
38
|
+
'spiffy-tw-leading-[124%]': boolean;
|
|
39
|
+
};
|
|
40
|
+
h3: {
|
|
41
|
+
'spiffy-headline': boolean;
|
|
42
|
+
'spiffy-headline-3': boolean;
|
|
43
|
+
'spiffy-tw-text-[15px]': boolean;
|
|
44
|
+
'spiffy-tw-font-medium': boolean;
|
|
45
|
+
'spiffy-tw-leading-[124%]': boolean;
|
|
46
|
+
};
|
|
47
|
+
h4: {
|
|
48
|
+
'spiffy-headline': boolean;
|
|
49
|
+
'spiffy-headline-4': boolean;
|
|
50
|
+
'spiffy-tw-text-[14px]': boolean;
|
|
51
|
+
'spiffy-tw-font-medium': boolean;
|
|
52
|
+
'spiffy-tw-leading-[124%]': boolean;
|
|
53
|
+
};
|
|
54
|
+
body1: {
|
|
55
|
+
'spiffy-body-text': boolean;
|
|
56
|
+
'spiffy-body-1': boolean;
|
|
57
|
+
'spiffy-tw-text-[20px]': boolean;
|
|
58
|
+
'spiffy-tw-font-normal': boolean;
|
|
59
|
+
'spiffy-tw-line-height-[120%]': boolean;
|
|
60
|
+
};
|
|
61
|
+
body2: {
|
|
62
|
+
'spiffy-body-text': boolean;
|
|
63
|
+
'spiffy-body-2': boolean;
|
|
64
|
+
'spiffy-tw-text-[16px]': boolean;
|
|
65
|
+
'spiffy-tw-font-normal': boolean;
|
|
66
|
+
'spiffy-tw-line-height-[148%]': boolean;
|
|
67
|
+
};
|
|
68
|
+
body3: {
|
|
69
|
+
'spiffy-body-text': boolean;
|
|
70
|
+
'spiffy-body-3': boolean;
|
|
71
|
+
'spiffy-tw-text-sm': boolean;
|
|
72
|
+
'spiffy-tw-font-normal': boolean;
|
|
73
|
+
'spiffy-tw-leading-[140%]': boolean;
|
|
74
|
+
};
|
|
75
|
+
body4: {
|
|
76
|
+
'spiffy-body-text': boolean;
|
|
77
|
+
'spiffy-body-4': boolean;
|
|
78
|
+
'spiffy-tw-text-xs': boolean;
|
|
79
|
+
'spiffy-tw-font-medium': boolean;
|
|
80
|
+
'spiffy-tw-leading-[130%]': boolean;
|
|
81
|
+
};
|
|
82
|
+
body5: {
|
|
83
|
+
'spiffy-body-text': boolean;
|
|
84
|
+
'spiffy-body-5': boolean;
|
|
85
|
+
'spiffy-tw-text-[10px]': boolean;
|
|
86
|
+
'spiffy-tw-font-normal': boolean;
|
|
87
|
+
};
|
|
88
|
+
};
|
|
89
|
+
//#endregion
|
|
90
|
+
//#region src/components/common/TextInput/TextInput.d.ts
|
|
91
|
+
interface TextInputProps extends React.InputHTMLAttributes<HTMLInputElement> {
|
|
92
|
+
borderRadius: 'sm' | 'md' | 'lg' | 'xl';
|
|
93
|
+
borderColorClass?: string;
|
|
94
|
+
placeholderVariant?: keyof typeof TextStyleVariantMap;
|
|
95
|
+
}
|
|
96
|
+
declare const TextInput: React.ForwardRefExoticComponent<TextInputProps & React.RefAttributes<HTMLInputElement>>;
|
|
97
|
+
//#endregion
|
|
98
|
+
export { TextInput, TextInputProps };
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
//#region src/components/common/Text/textVariantClasses.d.ts
|
|
4
|
+
|
|
5
|
+
declare const TextStyleVariantMap: {
|
|
6
|
+
t1: {
|
|
7
|
+
'spiffy-headline': boolean;
|
|
8
|
+
'spiffy-headline-1': boolean;
|
|
9
|
+
'spiffy-tw-text-[32px]': boolean;
|
|
10
|
+
'spiffy-tw-font-medium': boolean;
|
|
11
|
+
'spiffy-tw-leading-[124%]': boolean;
|
|
12
|
+
};
|
|
13
|
+
t2: {
|
|
14
|
+
'spiffy-headline': boolean;
|
|
15
|
+
'spiffy-headline-1': boolean;
|
|
16
|
+
'spiffy-tw-text-[16px]': boolean;
|
|
17
|
+
'spiffy-tw-font-medium': boolean;
|
|
18
|
+
'spiffy-tw-leading-[124%]': boolean;
|
|
19
|
+
};
|
|
20
|
+
t3: {
|
|
21
|
+
'spiffy-headline': boolean;
|
|
22
|
+
'spiffy-headline-1': boolean;
|
|
23
|
+
'spiffy-tw-text-[24px]': boolean;
|
|
24
|
+
'spiffy-tw-leading-[120%]': boolean;
|
|
25
|
+
};
|
|
26
|
+
h1: {
|
|
27
|
+
'spiffy-headline': boolean;
|
|
28
|
+
'spiffy-headline-1': boolean;
|
|
29
|
+
'spiffy-tw-text-[20px]': boolean;
|
|
30
|
+
'spiffy-tw-font-normal': boolean;
|
|
31
|
+
'spiffy-tw-leading-[120%]': boolean;
|
|
32
|
+
};
|
|
33
|
+
h2: {
|
|
34
|
+
'spiffy-headline': boolean;
|
|
35
|
+
'spiffy-headline-2': boolean;
|
|
36
|
+
'spiffy-tw-text-[16px]': boolean;
|
|
37
|
+
'spiffy-tw-font-normal': boolean;
|
|
38
|
+
'spiffy-tw-leading-[124%]': boolean;
|
|
39
|
+
};
|
|
40
|
+
h3: {
|
|
41
|
+
'spiffy-headline': boolean;
|
|
42
|
+
'spiffy-headline-3': boolean;
|
|
43
|
+
'spiffy-tw-text-[15px]': boolean;
|
|
44
|
+
'spiffy-tw-font-medium': boolean;
|
|
45
|
+
'spiffy-tw-leading-[124%]': boolean;
|
|
46
|
+
};
|
|
47
|
+
h4: {
|
|
48
|
+
'spiffy-headline': boolean;
|
|
49
|
+
'spiffy-headline-4': boolean;
|
|
50
|
+
'spiffy-tw-text-[14px]': boolean;
|
|
51
|
+
'spiffy-tw-font-medium': boolean;
|
|
52
|
+
'spiffy-tw-leading-[124%]': boolean;
|
|
53
|
+
};
|
|
54
|
+
body1: {
|
|
55
|
+
'spiffy-body-text': boolean;
|
|
56
|
+
'spiffy-body-1': boolean;
|
|
57
|
+
'spiffy-tw-text-[20px]': boolean;
|
|
58
|
+
'spiffy-tw-font-normal': boolean;
|
|
59
|
+
'spiffy-tw-line-height-[120%]': boolean;
|
|
60
|
+
};
|
|
61
|
+
body2: {
|
|
62
|
+
'spiffy-body-text': boolean;
|
|
63
|
+
'spiffy-body-2': boolean;
|
|
64
|
+
'spiffy-tw-text-[16px]': boolean;
|
|
65
|
+
'spiffy-tw-font-normal': boolean;
|
|
66
|
+
'spiffy-tw-line-height-[148%]': boolean;
|
|
67
|
+
};
|
|
68
|
+
body3: {
|
|
69
|
+
'spiffy-body-text': boolean;
|
|
70
|
+
'spiffy-body-3': boolean;
|
|
71
|
+
'spiffy-tw-text-sm': boolean;
|
|
72
|
+
'spiffy-tw-font-normal': boolean;
|
|
73
|
+
'spiffy-tw-leading-[140%]': boolean;
|
|
74
|
+
};
|
|
75
|
+
body4: {
|
|
76
|
+
'spiffy-body-text': boolean;
|
|
77
|
+
'spiffy-body-4': boolean;
|
|
78
|
+
'spiffy-tw-text-xs': boolean;
|
|
79
|
+
'spiffy-tw-font-medium': boolean;
|
|
80
|
+
'spiffy-tw-leading-[130%]': boolean;
|
|
81
|
+
};
|
|
82
|
+
body5: {
|
|
83
|
+
'spiffy-body-text': boolean;
|
|
84
|
+
'spiffy-body-5': boolean;
|
|
85
|
+
'spiffy-tw-text-[10px]': boolean;
|
|
86
|
+
'spiffy-tw-font-normal': boolean;
|
|
87
|
+
};
|
|
88
|
+
};
|
|
89
|
+
//#endregion
|
|
90
|
+
//#region src/components/common/TextInput/TextInput.d.ts
|
|
91
|
+
interface TextInputProps extends React.InputHTMLAttributes<HTMLInputElement> {
|
|
92
|
+
borderRadius: 'sm' | 'md' | 'lg' | 'xl';
|
|
93
|
+
borderColorClass?: string;
|
|
94
|
+
placeholderVariant?: keyof typeof TextStyleVariantMap;
|
|
95
|
+
}
|
|
96
|
+
declare const TextInput: React.ForwardRefExoticComponent<TextInputProps & React.RefAttributes<HTMLInputElement>>;
|
|
97
|
+
//#endregion
|
|
98
|
+
export { TextInput, TextInputProps };
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
//#region src/components/common/ProductCard/productCardVariants.ts
|
|
2
|
+
/**
|
|
3
|
+
* Shared variant mapping configurations for ProductCard components
|
|
4
|
+
*/
|
|
5
|
+
const variantClassMap = new Map([
|
|
6
|
+
["filled", ["spiffy-tw-bg-[--spiffy-colors-background-secondary]", "spiffy-tw-shadow-md"]],
|
|
7
|
+
["bordered", [
|
|
8
|
+
"spiffy-tw-bg-[--spiffy-colors-background-secondary]",
|
|
9
|
+
"spiffy-tw-border",
|
|
10
|
+
"spiffy-tw-border-[--spiffy-colors-border-light]"
|
|
11
|
+
]],
|
|
12
|
+
["minimal", ["spiffy-tw-bg-transparent"]],
|
|
13
|
+
["transparentBordered", [
|
|
14
|
+
"spiffy-tw-bg-transparent",
|
|
15
|
+
"spiffy-tw-border",
|
|
16
|
+
"spiffy-tw-border-[--spiffy-colors-border-light]"
|
|
17
|
+
]]
|
|
18
|
+
]);
|
|
19
|
+
const variantHoverClassMap = new Map([["backgroundDark", ["hover:spiffy-tw-bg-[--spiffy-colors-background-secondary-dark]"]], ["none", []]]);
|
|
20
|
+
const variantTitleColorMap = new Map([
|
|
21
|
+
["filled", "spiffy-tw-text-[--spiffy-colors-text-link]"],
|
|
22
|
+
["bordered", "spiffy-tw-text-[--spiffy-colors-text-primary]"],
|
|
23
|
+
["minimal", "spiffy-tw-text-[--spiffy-colors-text-primary]"],
|
|
24
|
+
["transparentBordered", "spiffy-tw-text-[--spiffy-colors-text-primary]"]
|
|
25
|
+
]);
|
|
26
|
+
const productCardLayoutVariantClasses = {
|
|
27
|
+
normal: {
|
|
28
|
+
productTitle: ["spiffy-product-card-title"],
|
|
29
|
+
container: ["spiffy-tw-w-[208px]"],
|
|
30
|
+
verticalContainer: ["spiffy-tw-rounded-[8px]", "spiffy-tw-h-[268px]"]
|
|
31
|
+
},
|
|
32
|
+
tall: {
|
|
33
|
+
productTitle: ["spiffy-product-card-title-tall", "spiffy-tw-pt-[8px]"],
|
|
34
|
+
container: ["spiffy-tw-w-[160px] lg:spiffy-tw-w-[300px]"],
|
|
35
|
+
verticalContainer: ["lg:spiffy-tw-h-[496px]"]
|
|
36
|
+
},
|
|
37
|
+
square: {
|
|
38
|
+
productTitle: ["spiffy-product-card-title-tall", "spiffy-tw-pt-[8px]"],
|
|
39
|
+
container: ["spiffy-tw-w-[160px] lg:spiffy-tw-w-[280px]"],
|
|
40
|
+
verticalContainer: ["lg:spiffy-tw-h-[400px]"]
|
|
41
|
+
}
|
|
42
|
+
};
|
|
43
|
+
|
|
44
|
+
//#endregion
|
|
45
|
+
export { productCardLayoutVariantClasses, variantClassMap, variantHoverClassMap, variantTitleColorMap };
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
|
|
2
|
+
//#region src/components/common/ProductCard/productCardVariants.ts
|
|
3
|
+
/**
|
|
4
|
+
* Shared variant mapping configurations for ProductCard components
|
|
5
|
+
*/
|
|
6
|
+
const variantClassMap = new Map([
|
|
7
|
+
["filled", ["spiffy-tw-bg-[--spiffy-colors-background-secondary]", "spiffy-tw-shadow-md"]],
|
|
8
|
+
["bordered", [
|
|
9
|
+
"spiffy-tw-bg-[--spiffy-colors-background-secondary]",
|
|
10
|
+
"spiffy-tw-border",
|
|
11
|
+
"spiffy-tw-border-[--spiffy-colors-border-light]"
|
|
12
|
+
]],
|
|
13
|
+
["minimal", ["spiffy-tw-bg-transparent"]],
|
|
14
|
+
["transparentBordered", [
|
|
15
|
+
"spiffy-tw-bg-transparent",
|
|
16
|
+
"spiffy-tw-border",
|
|
17
|
+
"spiffy-tw-border-[--spiffy-colors-border-light]"
|
|
18
|
+
]]
|
|
19
|
+
]);
|
|
20
|
+
const variantHoverClassMap = new Map([["backgroundDark", ["hover:spiffy-tw-bg-[--spiffy-colors-background-secondary-dark]"]], ["none", []]]);
|
|
21
|
+
const variantTitleColorMap = new Map([
|
|
22
|
+
["filled", "spiffy-tw-text-[--spiffy-colors-text-link]"],
|
|
23
|
+
["bordered", "spiffy-tw-text-[--spiffy-colors-text-primary]"],
|
|
24
|
+
["minimal", "spiffy-tw-text-[--spiffy-colors-text-primary]"],
|
|
25
|
+
["transparentBordered", "spiffy-tw-text-[--spiffy-colors-text-primary]"]
|
|
26
|
+
]);
|
|
27
|
+
const productCardLayoutVariantClasses = {
|
|
28
|
+
normal: {
|
|
29
|
+
productTitle: ["spiffy-product-card-title"],
|
|
30
|
+
container: ["spiffy-tw-w-[208px]"],
|
|
31
|
+
verticalContainer: ["spiffy-tw-rounded-[8px]", "spiffy-tw-h-[268px]"]
|
|
32
|
+
},
|
|
33
|
+
tall: {
|
|
34
|
+
productTitle: ["spiffy-product-card-title-tall", "spiffy-tw-pt-[8px]"],
|
|
35
|
+
container: ["spiffy-tw-w-[160px] lg:spiffy-tw-w-[300px]"],
|
|
36
|
+
verticalContainer: ["lg:spiffy-tw-h-[496px]"]
|
|
37
|
+
},
|
|
38
|
+
square: {
|
|
39
|
+
productTitle: ["spiffy-product-card-title-tall", "spiffy-tw-pt-[8px]"],
|
|
40
|
+
container: ["spiffy-tw-w-[160px] lg:spiffy-tw-w-[280px]"],
|
|
41
|
+
verticalContainer: ["lg:spiffy-tw-h-[400px]"]
|
|
42
|
+
}
|
|
43
|
+
};
|
|
44
|
+
|
|
45
|
+
//#endregion
|
|
46
|
+
Object.defineProperty(exports, 'productCardLayoutVariantClasses', {
|
|
47
|
+
enumerable: true,
|
|
48
|
+
get: function () {
|
|
49
|
+
return productCardLayoutVariantClasses;
|
|
50
|
+
}
|
|
51
|
+
});
|
|
52
|
+
Object.defineProperty(exports, 'variantClassMap', {
|
|
53
|
+
enumerable: true,
|
|
54
|
+
get: function () {
|
|
55
|
+
return variantClassMap;
|
|
56
|
+
}
|
|
57
|
+
});
|
|
58
|
+
Object.defineProperty(exports, 'variantHoverClassMap', {
|
|
59
|
+
enumerable: true,
|
|
60
|
+
get: function () {
|
|
61
|
+
return variantHoverClassMap;
|
|
62
|
+
}
|
|
63
|
+
});
|
|
64
|
+
Object.defineProperty(exports, 'variantTitleColorMap', {
|
|
65
|
+
enumerable: true,
|
|
66
|
+
get: function () {
|
|
67
|
+
return variantTitleColorMap;
|
|
68
|
+
}
|
|
69
|
+
});
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
//#region src/components/common/ProductGrid/productGridVariants.ts
|
|
2
|
+
const productGridVariantClasses = {
|
|
3
|
+
standard: {
|
|
4
|
+
productCardVariant: "minimal",
|
|
5
|
+
productCardHoverVariant: "backgroundDark",
|
|
6
|
+
productCardLayoutVariant: "tall",
|
|
7
|
+
productCardImageAspectRatio: "3:4",
|
|
8
|
+
zoomOnHover: true
|
|
9
|
+
},
|
|
10
|
+
square: {
|
|
11
|
+
productCardVariant: "minimal",
|
|
12
|
+
productCardHoverVariant: "backgroundDark",
|
|
13
|
+
productCardLayoutVariant: "square",
|
|
14
|
+
productCardImageAspectRatio: "square",
|
|
15
|
+
zoomOnHover: true
|
|
16
|
+
}
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
//#endregion
|
|
20
|
+
export { productGridVariantClasses };
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
|
|
2
|
+
//#region src/components/common/ProductGrid/productGridVariants.ts
|
|
3
|
+
const productGridVariantClasses = {
|
|
4
|
+
standard: {
|
|
5
|
+
productCardVariant: "minimal",
|
|
6
|
+
productCardHoverVariant: "backgroundDark",
|
|
7
|
+
productCardLayoutVariant: "tall",
|
|
8
|
+
productCardImageAspectRatio: "3:4",
|
|
9
|
+
zoomOnHover: true
|
|
10
|
+
},
|
|
11
|
+
square: {
|
|
12
|
+
productCardVariant: "minimal",
|
|
13
|
+
productCardHoverVariant: "backgroundDark",
|
|
14
|
+
productCardLayoutVariant: "square",
|
|
15
|
+
productCardImageAspectRatio: "square",
|
|
16
|
+
zoomOnHover: true
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
//#endregion
|
|
21
|
+
Object.defineProperty(exports, 'productGridVariantClasses', {
|
|
22
|
+
enumerable: true,
|
|
23
|
+
get: function () {
|
|
24
|
+
return productGridVariantClasses;
|
|
25
|
+
}
|
|
26
|
+
});
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
require('../../textVariantClasses-Bhf4VY5z.cjs');
|
|
2
|
+
require('../../Text-C04c4Z93.cjs');
|
|
3
|
+
const require_AppliedFiltersScrollbar = require('../../AppliedFiltersScrollbar-BlcyhZkZ.cjs');
|
|
4
|
+
|
|
5
|
+
exports.AppliedFiltersScrollbar = require_AppliedFiltersScrollbar.AppliedFiltersScrollbar;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { SelectedFilterOption } from "../../types-DaSkJnT_.cjs";
|
|
2
|
+
import * as react_jsx_runtime11 from "react/jsx-runtime";
|
|
3
|
+
|
|
4
|
+
//#region src/components/search/FilterScrollbar/AppliedFiltersScrollbar.d.ts
|
|
5
|
+
interface AppliedFiltersScrollbarProps {
|
|
6
|
+
selectedFilterOptions: SelectedFilterOption[];
|
|
7
|
+
filterBarClassNames: string;
|
|
8
|
+
filterDefaultClasses: string;
|
|
9
|
+
filterHoverClasses: string;
|
|
10
|
+
appliedFilterBackgroundClasses: string;
|
|
11
|
+
onRemoveFilter: (filter: SelectedFilterOption) => void;
|
|
12
|
+
}
|
|
13
|
+
declare const AppliedFiltersScrollbar: ({
|
|
14
|
+
selectedFilterOptions,
|
|
15
|
+
filterBarClassNames,
|
|
16
|
+
filterDefaultClasses,
|
|
17
|
+
filterHoverClasses,
|
|
18
|
+
appliedFilterBackgroundClasses,
|
|
19
|
+
onRemoveFilter
|
|
20
|
+
}: AppliedFiltersScrollbarProps) => react_jsx_runtime11.JSX.Element;
|
|
21
|
+
//#endregion
|
|
22
|
+
export { AppliedFiltersScrollbar };
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { SelectedFilterOption } from "../../types-DFetqNL2.js";
|
|
2
|
+
import * as react_jsx_runtime15 from "react/jsx-runtime";
|
|
3
|
+
|
|
4
|
+
//#region src/components/search/FilterScrollbar/AppliedFiltersScrollbar.d.ts
|
|
5
|
+
interface AppliedFiltersScrollbarProps {
|
|
6
|
+
selectedFilterOptions: SelectedFilterOption[];
|
|
7
|
+
filterBarClassNames: string;
|
|
8
|
+
filterDefaultClasses: string;
|
|
9
|
+
filterHoverClasses: string;
|
|
10
|
+
appliedFilterBackgroundClasses: string;
|
|
11
|
+
onRemoveFilter: (filter: SelectedFilterOption) => void;
|
|
12
|
+
}
|
|
13
|
+
declare const AppliedFiltersScrollbar: ({
|
|
14
|
+
selectedFilterOptions,
|
|
15
|
+
filterBarClassNames,
|
|
16
|
+
filterDefaultClasses,
|
|
17
|
+
filterHoverClasses,
|
|
18
|
+
appliedFilterBackgroundClasses,
|
|
19
|
+
onRemoveFilter
|
|
20
|
+
}: AppliedFiltersScrollbarProps) => react_jsx_runtime15.JSX.Element;
|
|
21
|
+
//#endregion
|
|
22
|
+
export { AppliedFiltersScrollbar };
|