From e249a465bb90556aae8a395b9bbe81f1bd7edae2 Mon Sep 17 00:00:00 2001 From: Antonette Caldwell <134739862+nebula-aac@users.noreply.github.com> Date: Fri, 26 Apr 2024 14:17:07 +0000 Subject: [PATCH] feat: move custom button to styled Signed-off-by: Antonette Caldwell <134739862+nebula-aac@users.noreply.github.com> --- src/base/Button/Button.tsx | 16 --- src/custom/Modal/index.tsx | 2 +- src/styled/button/index.tsx | 193 ++++++++++++++++++++++++++++++++++++ src/styled/index.ts | 1 + 4 files changed, 195 insertions(+), 17 deletions(-) create mode 100644 src/styled/button/index.tsx create mode 100644 src/styled/index.ts diff --git a/src/base/Button/Button.tsx b/src/base/Button/Button.tsx index 534ae2de..bc5a6fce 100644 --- a/src/base/Button/Button.tsx +++ b/src/base/Button/Button.tsx @@ -14,20 +14,4 @@ export function Button({ label, children, ...props }: ButtonProps): JSX.Element ); } -export const ContainedButton = (props: ButtonProps): JSX.Element => ( - -); -export const OutlinedButton = (props: ButtonProps): JSX.Element => ( - -); -export const TextButton = (props: ButtonProps): JSX.Element => ( - -); - export default Button; diff --git a/src/custom/Modal/index.tsx b/src/custom/Modal/index.tsx index feff3092..f563339d 100644 --- a/src/custom/Modal/index.tsx +++ b/src/custom/Modal/index.tsx @@ -1,9 +1,9 @@ import { DialogProps, styled } from '@mui/material'; import React, { useRef, useState } from 'react'; import { Dialog, IconButton, Paper, Typography } from '../../base'; -import { ContainedButton, OutlinedButton, TextButton } from '../../base/Button/Button'; import { iconLarge } from '../../constants/iconsSizes'; import { CloseIcon, InfoCircleIcon } from '../../icons'; +import { ContainedButton, OutlinedButton, TextButton } from '../../styled'; import { CustomTooltip } from '../CustomTooltip'; interface ModalProps extends DialogProps { diff --git a/src/styled/button/index.tsx b/src/styled/button/index.tsx new file mode 100644 index 00000000..c28ef6c6 --- /dev/null +++ b/src/styled/button/index.tsx @@ -0,0 +1,193 @@ +import { styled } from '@mui/material/styles'; +import React from 'react'; +import Button, { ButtonProps } from '../../base/Button/Button'; +import { darkTeal } from '../../theme/colors'; + +export function ContainedButton(props: ButtonProps): React.JSX.Element { + return