diff --git a/src/components/Settings/index.tsx b/src/components/Settings/index.tsx index cd9b2f4880..ef6f462441 100644 --- a/src/components/Settings/index.tsx +++ b/src/components/Settings/index.tsx @@ -156,7 +156,7 @@ export default function SettingsTab() { return ( - setShowConfirmation(false)}> + setShowConfirmation(false)} maxHeight={100}> @@ -233,7 +233,10 @@ export default function SettingsTab() { toggleExpertMode() setShowConfirmation(false) } - : () => setShowConfirmation(true) + : () => { + toggle() + setShowConfirmation(true) + } } /> diff --git a/src/components/SlippageTabs/index.tsx b/src/components/SlippageTabs/index.tsx index 253c3ecb97..ec87509bb7 100644 --- a/src/components/SlippageTabs/index.tsx +++ b/src/components/SlippageTabs/index.tsx @@ -21,15 +21,15 @@ enum DeadlineError { const FancyButton = styled.button` color: ${({ theme }) => theme.text1}; align-items: center; - min-width: 40px; height: 2rem; border-radius: 36px; font-size: 12px; + width: auto; + min-width: 3rem; border: 1px solid ${({ theme }) => theme.bg3}; outline: none; background: ${({ theme }) => theme.bg1}; :hover { - cursor: inherit; border: 1px solid ${({ theme }) => theme.bg4}; } :focus { @@ -48,9 +48,8 @@ const Option = styled(FancyButton)<{ active: boolean }>` const Input = styled.input` background: ${({ theme }) => theme.bg1}; - flex-grow: 1; font-size: 16px; - min-width: 60px; + width: auto; outline: none; &::-webkit-outer-spin-button, &::-webkit-inner-spin-button { @@ -64,6 +63,7 @@ const OptionCustom = styled(FancyButton)<{ active?: boolean; warning?: boolean } height: 2rem; position: relative; padding: 0 0.75rem; + flex: 1; border: ${({ theme, active, warning }) => active && `1px solid ${warning ? theme.red1 : theme.primary1}`}; :hover { border: ${({ theme, active, warning }) => @@ -78,6 +78,13 @@ const OptionCustom = styled(FancyButton)<{ active?: boolean; warning?: boolean } } ` +const SlippageEmojiContainer = styled.span` + color: #f3841e; + ${({ theme }) => theme.mediaWidth.upToSmall` + display: none; + `} +` + export interface SlippageTabsProps { rawSlippage: number setRawSlippage: (rawSlippage: number) => void @@ -182,9 +189,11 @@ export default function SlippageTabs({ rawSlippage, setRawSlippage, deadline, se {!!slippageInput && (slippageError === SlippageError.RiskyLow || slippageError === SlippageError.RiskyHigh) ? ( - - ⚠️ - + + + ⚠️ + + ) : null}