Fix advanced settings tool icon alignment (#8935)
Followup of @bosiraphael's design <img width="333" alt="Screenshot 2024-12-06 at 17 25 45" src="https://github.com/user-attachments/assets/b744a7a6-99cb-4d4c-b9da-df0661536208"> <img width="614" alt="Screenshot 2024-12-06 at 17 26 19" src="https://github.com/user-attachments/assets/e9f31fed-66b2-4ed7-a5cd-97a9bc526752"> --------- Co-authored-by: bosiraphael <raphael.bosi@gmail.com>
This commit is contained in:
@ -188,6 +188,7 @@ export {
|
||||
IconNumber9,
|
||||
IconNumbers,
|
||||
IconPaperclip,
|
||||
IconPassword,
|
||||
IconPencil,
|
||||
IconPercentage,
|
||||
IconPhone,
|
||||
@ -201,6 +202,7 @@ export {
|
||||
IconPlaystationSquare,
|
||||
IconPlug,
|
||||
IconPlus,
|
||||
IconPoint,
|
||||
IconPower,
|
||||
IconPresentation,
|
||||
IconPrinter,
|
||||
@ -241,7 +243,6 @@ export {
|
||||
IconTextSize,
|
||||
IconTextWrap,
|
||||
IconTimelineEvent,
|
||||
IconTool,
|
||||
IconTrash,
|
||||
IconUnlink,
|
||||
IconUpload,
|
||||
@ -253,8 +254,7 @@ export {
|
||||
IconVideo,
|
||||
IconWand,
|
||||
IconWorld,
|
||||
IconX,
|
||||
IconPassword,
|
||||
IconX
|
||||
} from '@tabler/icons-react';
|
||||
|
||||
export type { TablerIconsProps } from '@tabler/icons-react';
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
import styled from '@emotion/styled';
|
||||
import { IconTool } from '@ui/display';
|
||||
import { IconPoint } from '@ui/display';
|
||||
import { Toggle } from '@ui/input';
|
||||
import { MAIN_COLORS } from '@ui/theme';
|
||||
import { useId } from 'react';
|
||||
@ -20,10 +20,9 @@ const StyledLabel = styled.label`
|
||||
`;
|
||||
|
||||
const StyledIconContainer = styled.div`
|
||||
border-right: 1px solid ${MAIN_COLORS.yellow};
|
||||
height: 16px;
|
||||
position: absolute;
|
||||
left: ${({ theme }) => theme.spacing(-5)};
|
||||
left: ${({ theme }) => theme.spacing(-3)};
|
||||
`;
|
||||
|
||||
const StyledToggleContainer = styled.div`
|
||||
@ -33,8 +32,8 @@ const StyledToggleContainer = styled.div`
|
||||
width: 100%;
|
||||
`;
|
||||
|
||||
const StyledIconTool = styled(IconTool)`
|
||||
margin-right: ${({ theme }) => theme.spacing(0.5)};
|
||||
const StyledIconPoint = styled(IconPoint)`
|
||||
margin-right: 0;
|
||||
`;
|
||||
|
||||
type AdvancedSettingsToggleProps = {
|
||||
@ -54,7 +53,11 @@ export const AdvancedSettingsToggle = ({
|
||||
return (
|
||||
<StyledContainer>
|
||||
<StyledIconContainer>
|
||||
<StyledIconTool size={12} color={MAIN_COLORS.yellow} />
|
||||
<StyledIconPoint
|
||||
size={12}
|
||||
color={MAIN_COLORS.yellow}
|
||||
fill={MAIN_COLORS.yellow}
|
||||
/>
|
||||
</StyledIconContainer>
|
||||
<StyledToggleContainer>
|
||||
<StyledLabel htmlFor={inputId}>Advanced:</StyledLabel>
|
||||
|
||||
Reference in New Issue
Block a user