Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix/SKU selector classname #165

Merged
3 changes: 2 additions & 1 deletion react/AutocompleteBlock.tsx
Original file line number Diff line number Diff line change
@@ -278,6 +278,7 @@ const AutocompleteBlock: FunctionComponent<any & WrappedComponentProps> = ({
'productThumb',
'productTitle',
'productSku',
'skuSelectionSelected',
EmanuelRamos115 marked this conversation as resolved.
Show resolved Hide resolved
'productLabel',
'inputQuantity',
'buttonAdd',
@@ -341,7 +342,7 @@ const AutocompleteBlock: FunctionComponent<any & WrappedComponentProps> = ({
return (
<span
key={item.itemId}
className={`mr4 ${handles.skuSelection}`}
className={`mr4 ${handles.skuSelection} ${item.itemId === selectedItem.value && handles.skuSelectionSelected}`}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The goal here is to just add a true or false to the className?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes! Only to get when is selected

>
<Tag
size="small"
2 changes: 1 addition & 1 deletion react/UploadBlock.tsx
Original file line number Diff line number Diff line change
@@ -348,7 +348,7 @@ const UploadBlock: FunctionComponent<
] as const

const handles = useCssHandles(CSS_HANDLES)

return (
<div className={`${handles.uploadBlock}`}>
{!componentOnly && (