From 11b2e34ea29b6ac87737cd4799a6ef12c3cdac65 Mon Sep 17 00:00:00 2001 From: Nozomi Ichihara <31800566+nozomione@users.noreply.github.com> Date: Mon, 18 Sep 2023 10:15:23 -0400 Subject: [PATCH] (fix) adjust the Grommet button theme to prevent overwriting --- client/src/theme/button.js | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) diff --git a/client/src/theme/button.js b/client/src/theme/button.js index 45cac26a..523538b7 100644 --- a/client/src/theme/button.js +++ b/client/src/theme/button.js @@ -1,12 +1,10 @@ +const defaultBorder = { radius: '4px', width: '1px' } + export default { - border: { - radius: '4px', - width: '1px' - }, color: 'brand', default: { color: 'brand', - border: { color: 'brand', width: '1px' }, + border: { color: 'brand', ...defaultBorder }, padding: { horizontal: '24px', vertical: '7px' // 8px - 1px for border @@ -14,7 +12,7 @@ export default { }, primary: { background: { color: 'brand' }, - border: { color: 'brand', width: '1px' }, + border: { color: 'brand', ...defaultBorder }, color: 'white', padding: { horizontal: '24px', @@ -22,7 +20,7 @@ export default { } }, secondary: { - border: { color: 'brand', width: '1px' }, + border: { color: 'brand', ...defaultBorder }, color: 'text', padding: { horizontal: '24px', @@ -34,9 +32,7 @@ export default { color: 'text', secondary: { background: 'none', - border: { - color: 'brand-contrast' - } + border: { color: 'brand-contrast', ...defaultBorder } } }, disabled: { @@ -44,7 +40,7 @@ export default { shadow: undefined, color: 'text-weak', background: 'black-tint-90', - border: { color: 'black-tint-90' }, + border: { color: 'black-tint-90', ...defaultBorder }, primary: { color: 'black-tint-40', background: 'black-tint-70' } }, hover: {