Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
Prev Previous commit
Feedback and simplify
  • Loading branch information
Mamaduka committed May 28, 2025
commit a85bd117f74b8abe151fc63297f27b67ec5d1456
4 changes: 2 additions & 2 deletions packages/components/src/drop-zone/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ import type { WordPressComponentProps } from '../context';
*/
export function DropZoneComponent( {
className,
icon,
icon = upload,
label,
onFilesDrop,
onHTMLDrop,
Expand Down Expand Up @@ -125,7 +125,7 @@ export function DropZoneComponent( {
<div className="components-drop-zone__content">
<div className="components-drop-zone__content-inner">
<Icon
icon={ icon ? icon : upload }
icon={ icon }
className="components-drop-zone__content-icon"
/>
<span className="components-drop-zone__content-text">
Expand Down
2 changes: 2 additions & 0 deletions packages/components/src/drop-zone/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ export type DropZoneProps = {
className?: string;
/**
* An icon to be shown within the drop zone area.
*
* @default "upload"
*/
icon?: JSX.Element;
/**
Expand Down
Loading