Update large sizes
This commit is contained in:
+14
-10
@@ -430,10 +430,10 @@ export const Button = React.forwardRef<View, ButtonProps>(
|
|||||||
if (shape === 'default') {
|
if (shape === 'default') {
|
||||||
if (size === 'large') {
|
if (size === 'large') {
|
||||||
baseStyles.push({
|
baseStyles.push({
|
||||||
paddingVertical: 13,
|
paddingVertical: 14,
|
||||||
paddingHorizontal: 20,
|
paddingHorizontal: 24,
|
||||||
borderRadius: 8,
|
borderRadius: 10,
|
||||||
gap: 8,
|
gap: 5,
|
||||||
})
|
})
|
||||||
} else if (size === 'small') {
|
} else if (size === 'small') {
|
||||||
baseStyles.push({
|
baseStyles.push({
|
||||||
@@ -451,11 +451,15 @@ export const Button = React.forwardRef<View, ButtonProps>(
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
} else if (shape === 'round' || shape === 'square') {
|
} else if (shape === 'round' || shape === 'square') {
|
||||||
|
/*
|
||||||
|
* These sizes match the actual rendered size on screen, based on
|
||||||
|
* Chrome's web inspector
|
||||||
|
*/
|
||||||
if (size === 'large') {
|
if (size === 'large') {
|
||||||
if (shape === 'round') {
|
if (shape === 'round') {
|
||||||
baseStyles.push({height: 46, width: 46})
|
baseStyles.push({height: 45, width: 45})
|
||||||
} else {
|
} else {
|
||||||
baseStyles.push({height: 44, width: 44})
|
baseStyles.push({height: 45, width: 45})
|
||||||
}
|
}
|
||||||
} else if (size === 'small') {
|
} else if (size === 'small') {
|
||||||
if (shape === 'round') {
|
if (shape === 'round') {
|
||||||
@@ -745,7 +749,7 @@ export function ButtonIcon({
|
|||||||
const iconSizeShorthand =
|
const iconSizeShorthand =
|
||||||
size ??
|
size ??
|
||||||
(({
|
(({
|
||||||
large: 'sm',
|
large: 'md',
|
||||||
small: 'sm',
|
small: 'sm',
|
||||||
tiny: 'xs',
|
tiny: 'xs',
|
||||||
}[buttonSize || 'small'] || 'sm') as Exclude<
|
}[buttonSize || 'small'] || 'sm') as Exclude<
|
||||||
@@ -771,9 +775,9 @@ export function ButtonIcon({
|
|||||||
* don't increase button size
|
* don't increase button size
|
||||||
*/
|
*/
|
||||||
const iconContainerSize = {
|
const iconContainerSize = {
|
||||||
large: 18,
|
large: 17,
|
||||||
small: 16,
|
small: 17,
|
||||||
tiny: 12,
|
tiny: 13,
|
||||||
}[buttonSize || 'small']
|
}[buttonSize || 'small']
|
||||||
|
|
||||||
return {
|
return {
|
||||||
|
|||||||
Reference in New Issue
Block a user