@sonic-equipment/ui 0.0.31 → 0.0.33
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/global-search/global-search-provider/global-search-container.d.ts +2 -0
- package/dist/global-search/global-search-provider/use-search-disclosure.d.ts +2 -0
- package/dist/index.d.ts +5 -1
- package/dist/index.js +4 -4
- package/dist/intl/translation-id.d.ts +1 -1
- package/dist/styles.css +10 -3
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -485,7 +485,7 @@ declare function FavoriteOutlinedIcon(props: React.SVGProps<SVGSVGElement>): rea
|
|
|
485
485
|
|
|
486
486
|
declare function HashedOutlinedIcon(props: React.SVGProps<SVGSVGElement>): react_jsx_runtime.JSX.Element;
|
|
487
487
|
|
|
488
|
-
type TranslationId = 'Chosen filters' | 'Clear' | 'Clear filters' | 'Excl. VAT' | 'Hide filters' | 'Incl. VAT' | 'Show' | 'Show all' | 'Show filters' | 'Show less' | 'Sort' | 'Submit' | 'articles' | 'article' | 'of' | 'sort.relevance' | 'sort.newest' | 'sort.price_asc' | 'sort.price_desc';
|
|
488
|
+
type TranslationId = 'Chosen filters' | 'Clear' | 'Clear filters' | 'Excl. VAT' | 'Hide filters' | 'Incl. VAT' | 'Show' | 'Show all' | 'Show filters' | 'Show less' | 'Sort by' | 'Submit' | 'articles' | 'article' | 'of' | 'sort.relevance' | 'sort.newest' | 'sort.price_asc' | 'sort.price_desc';
|
|
489
489
|
|
|
490
490
|
interface FormattedMessageProps {
|
|
491
491
|
fallbackValue?: string;
|
|
@@ -627,7 +627,9 @@ interface GlobalSearchProps {
|
|
|
627
627
|
declare function GlobalSearch({ children, searchClient }: GlobalSearchProps): react_jsx_runtime.JSX.Element;
|
|
628
628
|
|
|
629
629
|
declare const GlobalSearchDisclosureContext: React.Context<{
|
|
630
|
+
close: VoidFunction;
|
|
630
631
|
isOpen: boolean;
|
|
632
|
+
open: VoidFunction;
|
|
631
633
|
toggle: VoidFunction;
|
|
632
634
|
} | null>;
|
|
633
635
|
declare function GlobalSearchContainer({ children, }: {
|
|
@@ -769,7 +771,9 @@ declare function useAlgoliaSearch(): {
|
|
|
769
771
|
};
|
|
770
772
|
|
|
771
773
|
declare const useGlobalSearchDisclosure: () => {
|
|
774
|
+
close: VoidFunction;
|
|
772
775
|
isOpen: boolean;
|
|
776
|
+
open: VoidFunction;
|
|
773
777
|
toggle: VoidFunction;
|
|
774
778
|
};
|
|
775
779
|
|
package/dist/index.js
CHANGED
|
@@ -633,7 +633,7 @@ function ProductCard({ addToCartButton: AddToCartButton, favoriteButton: Favorit
|
|
|
633
633
|
var styles$n = {"category-card":"category-card-module-4NUjH","title":"category-card-module-LEhh3","is-selected":"category-card-module-vJ7vB","image-container":"category-card-module-oNTrK"};
|
|
634
634
|
|
|
635
635
|
function CategoryCard({ href, image, isSelected = false, title, }) {
|
|
636
|
-
return (jsxs(
|
|
636
|
+
return (jsxs(Link, { className: clsx({
|
|
637
637
|
[styles$n['is-selected']]: isSelected,
|
|
638
638
|
}, styles$n['category-card']), href: href, children: [jsx("div", { className: styles$n['image-container'], children: jsx(Image, { ...image }) }), jsx("p", { className: styles$n.title, children: title })] }));
|
|
639
639
|
}
|
|
@@ -6200,7 +6200,7 @@ function AlgoliaSortBy() {
|
|
|
6200
6200
|
acc[option.value] = option.label;
|
|
6201
6201
|
return acc;
|
|
6202
6202
|
}, {});
|
|
6203
|
-
return (jsx(Select, { label:
|
|
6203
|
+
return (jsx(Select, { label: t('Sort by'), onChange: value => refine(String(value)), options: options, selectedOption: currentRefinement, showLabel: false }));
|
|
6204
6204
|
}
|
|
6205
6205
|
|
|
6206
6206
|
function ConnectedFavoriteButton({ productId }) {
|
|
@@ -6769,8 +6769,8 @@ function useAlgoliaSearch() {
|
|
|
6769
6769
|
|
|
6770
6770
|
const GlobalSearchDisclosureContext = createContext(null);
|
|
6771
6771
|
function GlobalSearchContainer({ children, }) {
|
|
6772
|
-
const { isOpen, toggle } = useDisclosure(false);
|
|
6773
|
-
return (jsx(TransitionGroup, { children: jsxs(GlobalSearchDisclosureContext.Provider, { value: { isOpen, toggle }, children: [jsx(Transition, { in: isOpen, timeout: 300, children: state => jsx("div", { className: state, children: children }) }), jsx(OverlayBackground, { isOpen: isOpen, onClick: toggle })] }) }));
|
|
6772
|
+
const { close, isOpen, open, toggle } = useDisclosure(false);
|
|
6773
|
+
return (jsx(TransitionGroup, { children: jsxs(GlobalSearchDisclosureContext.Provider, { value: { close, isOpen, open, toggle }, children: [jsx(Transition, { in: isOpen, timeout: 300, children: state => jsx("div", { className: state, children: children }) }), jsx(OverlayBackground, { isOpen: isOpen, onClick: toggle })] }) }));
|
|
6774
6774
|
}
|
|
6775
6775
|
|
|
6776
6776
|
const useGlobalSearchDisclosure = () => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export type TranslationId = 'Chosen filters' | 'Clear' | 'Clear filters' | 'Excl. VAT' | 'Hide filters' | 'Incl. VAT' | 'Show' | 'Show all' | 'Show filters' | 'Show less' | 'Sort' | 'Submit' | 'articles' | 'article' | 'of' | 'sort.relevance' | 'sort.newest' | 'sort.price_asc' | 'sort.price_desc';
|
|
1
|
+
export type TranslationId = 'Chosen filters' | 'Clear' | 'Clear filters' | 'Excl. VAT' | 'Hide filters' | 'Incl. VAT' | 'Show' | 'Show all' | 'Show filters' | 'Show less' | 'Sort by' | 'Submit' | 'articles' | 'article' | 'of' | 'sort.relevance' | 'sort.newest' | 'sort.price_asc' | 'sort.price_desc';
|
package/dist/styles.css
CHANGED
|
@@ -844,8 +844,8 @@
|
|
|
844
844
|
}
|
|
845
845
|
|
|
846
846
|
.image-module-lg7Kj.image-module-LM93B {
|
|
847
|
-
width: var(--space-
|
|
848
|
-
height: var(--space-
|
|
847
|
+
width: var(--space-40);
|
|
848
|
+
height: var(--space-40);
|
|
849
849
|
}
|
|
850
850
|
|
|
851
851
|
.product-card-module-pLaiB {
|
|
@@ -1005,6 +1005,10 @@
|
|
|
1005
1005
|
word-break: break-all;
|
|
1006
1006
|
}
|
|
1007
1007
|
|
|
1008
|
+
.category-card-module-4NUjH[data-pressed] .category-card-module-LEhh3, .category-card-module-4NUjH[data-hovered] .category-card-module-LEhh3, .category-card-module-4NUjH[data-focused] .category-card-module-LEhh3 {
|
|
1009
|
+
color: var(--color-brand-red);
|
|
1010
|
+
}
|
|
1011
|
+
|
|
1008
1012
|
.category-card-module-4NUjH.category-card-module-vJ7vB .category-card-module-LEhh3 {
|
|
1009
1013
|
color: var(--color-brand-red);
|
|
1010
1014
|
}
|
|
@@ -2455,8 +2459,11 @@
|
|
|
2455
2459
|
}
|
|
2456
2460
|
|
|
2457
2461
|
.search-root-module-g9MP0 {
|
|
2458
|
-
position:
|
|
2462
|
+
position: absolute;
|
|
2459
2463
|
z-index: var(--search-layer);
|
|
2464
|
+
top: 0;
|
|
2465
|
+
right: 0;
|
|
2466
|
+
left: 0;
|
|
2460
2467
|
box-sizing: border-box;
|
|
2461
2468
|
transition: transform 0.3s ease-in-out;
|
|
2462
2469
|
}
|