Skip to content

Commit

Permalink
Document Badge props
Browse files Browse the repository at this point in the history
  • Loading branch information
MitchLillie committed Oct 13, 2023
1 parent cc4150e commit 9a8dda8
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
6 changes: 6 additions & 0 deletions .changeset/giant-chairs-hunt.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
'@shopify/ui-extensions': patch
'@shopify/ui-extensions-react': patch
---

Add Badge component to admin
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,26 @@ import type {AccessibilityLabelProps, SizeScale, Tone} from '../shared';
import {IconName} from '../Icon/IconName';

interface BadgeBaseProps extends AccessibilityLabelProps {
/**
* Adjusts the color of the badge.
*/
tone?: Tone;
/**
* Adjusts the size of the badge.
*/
size?: Extract<SizeScale, 'small-100' | 'base'>;
}

interface BadgeIconProps {
/**
* Adds an icon to the badge.
*/
icon: IconName;
/**
* Adjusts the position of the icon within the badge. Requires `icon` to be set.
*
* @defaultValue 'start'
*/
iconPosition?: 'start' | 'end';
}

Expand Down

0 comments on commit 9a8dda8

Please sign in to comment.