mirror of
https://github.com/supabase/supabase.git
synced 2026-10-17 23:29:08 +03:00
Add a size map
This commit is contained in:
1 parent
33be4b8061
commit
f15df70144
1 file changed
+10
-2
@@ -7,12 +7,20 @@ interface Props {
|
||||
size?: 'tiny' | 'small' | 'medium' | 'large' | 'xlarge'
|
||||
}
|
||||
|
||||
export default function InputErrorIcon({ style, size }: Props) {
|
||||
const sizeMap = {
|
||||
tiny: 14,
|
||||
small: 16,
|
||||
medium: 20,
|
||||
large: 24,
|
||||
xlarge: 32,
|
||||
}
|
||||
|
||||
export default function InputErrorIcon({ style, size = 'medium' }: Props) {
|
||||
const __styles = styleHandler('inputErrorIcon')
|
||||
|
||||
return (
|
||||
<div className={__styles.base} style={style}>
|
||||
<AlertCircle size={size} strokeWidth={2} />
|
||||
<AlertCircle size={sizeMap[size]} strokeWidth={2} />
|
||||
</div>
|
||||
)
|
||||
}
|
||||
Reference in new issue
Block a user