fix: toast width to fit-content (#8955)

* fix: toast width to fit-content

* Increase spacing between message and command

* Hide shadow

* Align toast to right
This commit is contained in:
Aswath K 2021-11-08 20:49:33 +05:30 committed by GitHub
parent 29f5962e4c
commit f17ce968e7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 1 deletions

View File

@ -59,7 +59,8 @@ const ToastBody = styled.div<{
dispatchableAction?: { type: ReduxActionType; payload: any };
width?: string;
}>`
width: ${(props) => props.width || "264px"};
width: ${(props) => props.width || "fit-content"};
margin-left: auto;
background: ${(props) => props.theme.colors.toast.bg};
padding: ${(props) => props.theme.spaces[4]}px
${(props) => props.theme.spaces[5]}px;
@ -130,6 +131,7 @@ const StyledDebugButton = styled(DebugButton)`
const StyledActionText = styled(Text)`
color: ${(props) => props.theme.colors.toast.undoRedoColor} !important;
cursor: pointer;
margin-left: ${(props) => props.theme.spaces[3]}px;
`;
export function ToastComponent(

View File

@ -46,6 +46,7 @@ div.bp3-popover-arrow {
.Toastify__toast {
padding: 0 !important;
border-radius: 4px !important;
box-shadow: none !important;
}
.Toastify__toast-body {
margin: 0 !important;