Skip to content

Commit

Permalink
fix glitch
Browse files Browse the repository at this point in the history
  • Loading branch information
YieldRay committed Jan 26, 2024
1 parent 650bc1f commit 357fe6a
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 8 deletions.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "soda-material",
"version": "0.0.16",
"version": "0.0.17",
"keywords": [
"material design",
"material you"
Expand Down Expand Up @@ -28,7 +28,7 @@
"react-dom": ">=18"
},
"devDependencies": {
"@floating-ui/react": "^0.26.6",
"@floating-ui/react": "^0.26.7",
"@material/material-color-utilities": "^0.2.7",
"@mdi/js": "^7.4.47",
"@mdi/react": "^1.6.1",
Expand Down
2 changes: 1 addition & 1 deletion src/components/checkbox/Checkbox.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ export const Checkbox = forwardRef<
defaultChecked
)

const checkedIcon = children || <Icon size={1} path={mdiCheck} />
const checkedIcon = children || <Icon size={0.6} path={mdiCheck} />

return (
<div
Expand Down
6 changes: 3 additions & 3 deletions src/composition/NestedMenu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -190,14 +190,14 @@ const NestedMenuComponent = forwardRef<
useEffect(() => {
if (!tree) return

function handleTreeClick() {
const handleTreeClick = () => {
setIsOpen(false)
}

function onSubMenuOpen(event: {
const onSubMenuOpen = (event: {
nodeId: string
parentId: string
}) {
}) => {
if (event.nodeId !== nodeId && event.parentId === parentId) {
setIsOpen(false)
}
Expand Down
12 changes: 10 additions & 2 deletions src/composition/Select.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,11 @@ export const Select = forwardRef<

return (
<div {...props} ref={ref} className={clsx('sd-select', className)}>
<div ref={refs.setReference} {...getReferenceProps()}>
<div
ref={refs.setReference}
{...getReferenceProps()}
aria-haspopup
>
{isFunction(children)
? children(value!)
: children ?? (
Expand All @@ -276,7 +280,11 @@ export const Select = forwardRef<
options[selectedIndex]
)}
</span>
<Icon size={1} path={mdiMenuDown} />
<Icon
size={1}
path={mdiMenuDown}
rotate={open ? 180 : 0}
/>
</div>
</Ripple>
)}
Expand Down

0 comments on commit 357fe6a

Please sign in to comment.