mirror of
https://gh.wpcy.net/https://github.com/elementor/one-click-accessibility.git
synced 2026-04-23 18:27:48 +08:00
* add: icon radius component * add: icon radius component * update: add support for widget radius * fix: minor ui fixes * fix: resolve comments * fix: alignment of the icon * update: add styled components * add: corner radius mixpanel event * fix: corner radius should have default values when no value is set based on icon * fix: icon radius input style * add: accessibility attributes * fix: active states color * add: logic to control invalid inputs * update: make aria attributes translatable * update: styled component names * add: spacing between the components
57 lines
1.3 KiB
JavaScript
57 lines
1.3 KiB
JavaScript
import Box from '@elementor/ui/Box';
|
|
import Grid from '@elementor/ui/Grid';
|
|
import Typography from '@elementor/ui/Typography';
|
|
import { styled } from '@elementor/ui/styles';
|
|
import {
|
|
ColorPicker,
|
|
IconRadius,
|
|
IconSelect,
|
|
IconSize,
|
|
} from '@ea11y/components';
|
|
import { __ } from '@wordpress/i18n';
|
|
|
|
const StyledGrid = styled(Grid)`
|
|
display: grid;
|
|
gap: ${({ theme }) => theme.spacing(5)};
|
|
padding: ${({ theme }) => theme.spacing(2)};
|
|
grid-template-columns: repeat(2, 1fr);
|
|
|
|
${({ theme }) => theme.breakpoints.down('lg')} {
|
|
grid-template-columns: repeat(1, 1fr);
|
|
}
|
|
`;
|
|
|
|
const IconDesignSettings = (props) => {
|
|
return (
|
|
<Grid padding={2} border={1} borderColor="divider" {...props}>
|
|
<Box marginBottom={2}>
|
|
<Typography variant="subtitle1">
|
|
{__('Style', 'pojo-accessibility')}
|
|
</Typography>
|
|
|
|
<Typography variant="body2">
|
|
{__(
|
|
"Customize your widget's color, icon, and size to match your brand.",
|
|
'pojo-accessibility',
|
|
)}
|
|
</Typography>
|
|
</Box>
|
|
|
|
<StyledGrid>
|
|
<Box display="flex" flexDirection="column" gap={5}>
|
|
<IconSelect />
|
|
<IconSize />
|
|
</Box>
|
|
|
|
<Box>
|
|
<ColorPicker />
|
|
</Box>
|
|
</StyledGrid>
|
|
<StyledGrid>
|
|
<IconRadius />
|
|
</StyledGrid>
|
|
</Grid>
|
|
);
|
|
};
|
|
|
|
export default IconDesignSettings;
|