mirror of
https://github.com/jeffvli/feishin.git
synced 2026-06-12 15:22:35 +02:00
optimize various base components
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
import { useMemo } from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
import { QueryBuilderOption } from '/@/renderer/components/query-builder/query-builder-option';
|
||||
@@ -107,15 +108,17 @@ export const QueryBuilder = ({
|
||||
onChangeType({ groupIndex, level, value });
|
||||
};
|
||||
|
||||
const boxStyle = useMemo(
|
||||
() => ({
|
||||
border: '1px solid var(--theme-colors-border)',
|
||||
borderRadius: 'var(--theme-radius-md)',
|
||||
marginLeft: level > 0 ? '20px' : '0px',
|
||||
}),
|
||||
[level],
|
||||
);
|
||||
|
||||
return (
|
||||
<Box
|
||||
p="md"
|
||||
style={{
|
||||
border: '1px solid var(--theme-colors-border)',
|
||||
borderRadius: 'var(--theme-radius-md)',
|
||||
marginLeft: level > 0 ? '20px' : '0px',
|
||||
}}
|
||||
>
|
||||
<Box p="md" style={boxStyle}>
|
||||
<Stack gap="sm">
|
||||
<Group gap="sm" justify="space-between" wrap="nowrap">
|
||||
<Group gap="sm" wrap="nowrap">
|
||||
|
||||
Reference in New Issue
Block a user