Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .storybook/preview.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import type { Preview } from '@storybook/react-vite';
import '@kibalabs/ui-react/dist/index.css';
import '@kibalabs/ui-react/styles.css';
import '../src/styles.scss';

const preview: Preview = {
Expand Down
8 changes: 4 additions & 4 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
},
"devDependencies": {
"@kibalabs/build": "0.13.3-next.13",
"@kibalabs/ui-react": "0.11.3-next.18",
"@kibalabs/ui-react": "^0.11.3-next.22",
Copy link

Copilot AI Dec 4, 2025

Choose a reason for hiding this comment

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

The version specifier has been changed from a pinned version 0.11.3-next.18 to a caret range ^0.11.3-next.22. This changes the versioning strategy for this devDependency.

For pre-release versions (versions with -next), npm's caret behavior might not work as expected. The caret (^) allows updates that do not modify the left-most non-zero element, but with pre-release identifiers, the behavior can be unpredictable. Consider whether you want to:

  1. Keep it pinned (remove the ^) for consistent builds
  2. Use a tilde (~) to allow only patch-level changes
  3. Keep the caret if flexible pre-release updates are intentional

This change should also be reflected in the peerDependencies constraint on line 49, which currently specifies >=0.11.3-next.18.

Copilot uses AI. Check for mistakes.
"@storybook/addon-docs": "10.1.2",
"@storybook/react-vite": "10.1.2",
"@types/react": "19.2.7",
Expand Down
1 change: 1 addition & 0 deletions src/component.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ export function Dropzone(props: IDropzoneProps): React.ReactElement {
style={style}
>
<input
ref={(inputProps as React.InputHTMLAttributes<HTMLInputElement> & { ref?: React.Ref<HTMLInputElement> }).ref}
Copy link

Copilot AI Dec 4, 2025

Choose a reason for hiding this comment

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

The type assertion on line 53 is overly complex and could be simplified. Since getInputProps() from react-dropzone returns props that include a ref property, you can simply use inputProps.ref directly without the type assertion. The current casting to React.InputHTMLAttributes<HTMLInputElement> & { ref?: React.Ref<HTMLInputElement> } is unnecessarily verbose and may cause type safety issues.

Consider simplifying to:

ref={inputProps.ref}

This is the standard pattern for react-dropzone and will work correctly with TypeScript.

Suggested change
ref={(inputProps as React.InputHTMLAttributes<HTMLInputElement> & { ref?: React.Ref<HTMLInputElement> }).ref}
ref={inputProps.ref}

Copilot uses AI. Check for mistakes.
accept={inputProps.accept}
multiple={inputProps.multiple}
type={inputProps.type}
Expand Down
Loading