Style updates
This commit is contained in:
@@ -152,6 +152,7 @@ function SettingsButton() {
|
|||||||
}) || []
|
}) || []
|
||||||
}
|
}
|
||||||
classNames={selectClasses}
|
classNames={selectClasses}
|
||||||
|
className={selectClasses.default}
|
||||||
comboboxProps={{ withinPortal: false }}
|
comboboxProps={{ withinPortal: false }}
|
||||||
onChange={(_value, option: any) => setSelectedClient(option)}
|
onChange={(_value, option: any) => setSelectedClient(option)}
|
||||||
onLoad={(option: any) => setSelectedClient(option)}
|
onLoad={(option: any) => setSelectedClient(option)}
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ import {
|
|||||||
} from '@mantine/core';
|
} from '@mantine/core';
|
||||||
import { useCommonHooks } from 'hooks';
|
import { useCommonHooks } from 'hooks';
|
||||||
import { FiSave, FiX } from 'react-icons/fi';
|
import { FiSave, FiX } from 'react-icons/fi';
|
||||||
import { modalClasses, selectClasses, textClasses } from 'styles';
|
import { modalClasses, selectClasses, textClasses, textInputClasses } from 'styles';
|
||||||
import ThemeModalContent from './ThemeModalContent';
|
import ThemeModalContent from './ThemeModalContent';
|
||||||
|
|
||||||
function ThemeModal({
|
function ThemeModal({
|
||||||
@@ -33,7 +33,6 @@ function ThemeModal({
|
|||||||
handleSaveTheme,
|
handleSaveTheme,
|
||||||
}: any) {
|
}: any) {
|
||||||
const { theme } = useCommonHooks();
|
const { theme } = useCommonHooks();
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Modal.Root
|
<Modal.Root
|
||||||
size={'50%'}
|
size={'50%'}
|
||||||
@@ -44,7 +43,7 @@ function ThemeModal({
|
|||||||
style={{
|
style={{
|
||||||
'--color-text-pri': theme.primaryColor,
|
'--color-text-pri': theme.primaryColor,
|
||||||
'--color-text-acc': theme.accentColor,
|
'--color-text-acc': theme.accentColor,
|
||||||
'--color-background': theme.backgroundImage ? 'gray' : theme.backgroundColor,
|
'--color-background': theme.backgroundColor,
|
||||||
'--color-border': theme.borderColor,
|
'--color-border': theme.borderColor,
|
||||||
'--color-search-background': theme.searchColor,
|
'--color-search-background': theme.searchColor,
|
||||||
'--image-background': `url("${theme.backgroundImage}")`,
|
'--image-background': `url("${theme.backgroundImage}")`,
|
||||||
@@ -60,6 +59,8 @@ function ThemeModal({
|
|||||||
<ThemeModalContent selectedTheme={selectedTheme} />
|
<ThemeModalContent selectedTheme={selectedTheme} />
|
||||||
<Divider color='black' my='sm' />
|
<Divider color='black' my='sm' />
|
||||||
<TextInput
|
<TextInput
|
||||||
|
className={textInputClasses.default}
|
||||||
|
classNames={textInputClasses}
|
||||||
label='Theme Name'
|
label='Theme Name'
|
||||||
value={selectedTheme.name}
|
value={selectedTheme.name}
|
||||||
onChange={(e) => setSelectedTheme({ ...selectedTheme, name: e.target.value })}
|
onChange={(e) => setSelectedTheme({ ...selectedTheme, name: e.target.value })}
|
||||||
@@ -67,6 +68,10 @@ function ThemeModal({
|
|||||||
label: {
|
label: {
|
||||||
color: theme.primaryColor,
|
color: theme.primaryColor,
|
||||||
},
|
},
|
||||||
|
input: {
|
||||||
|
color: theme.primaryColor,
|
||||||
|
border: 'none',
|
||||||
|
},
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
<Divider color='black' my='sm' />
|
<Divider color='black' my='sm' />
|
||||||
@@ -85,7 +90,10 @@ function ThemeModal({
|
|||||||
radius={'sm'}
|
radius={'sm'}
|
||||||
w={'100px'}
|
w={'100px'}
|
||||||
color={selectedTheme.primaryColor}
|
color={selectedTheme.primaryColor}
|
||||||
style={{ cursor: 'pointer' }}
|
style={{
|
||||||
|
cursor: 'pointer',
|
||||||
|
border: `2px dashed ${theme.primaryColor}`,
|
||||||
|
}}
|
||||||
/>
|
/>
|
||||||
</Group>
|
</Group>
|
||||||
<Group justify='space-between'>
|
<Group justify='space-between'>
|
||||||
@@ -101,7 +109,10 @@ function ThemeModal({
|
|||||||
radius={'sm'}
|
radius={'sm'}
|
||||||
w={'100px'}
|
w={'100px'}
|
||||||
color={selectedTheme.accentColor}
|
color={selectedTheme.accentColor}
|
||||||
style={{ cursor: 'pointer' }}
|
style={{
|
||||||
|
cursor: 'pointer',
|
||||||
|
border: `2px dashed ${theme.primaryColor}`,
|
||||||
|
}}
|
||||||
/>
|
/>
|
||||||
</Group>
|
</Group>
|
||||||
<Group justify='space-between'>
|
<Group justify='space-between'>
|
||||||
@@ -117,7 +128,10 @@ function ThemeModal({
|
|||||||
radius={'sm'}
|
radius={'sm'}
|
||||||
w={'100px'}
|
w={'100px'}
|
||||||
color={selectedTheme.backgroundColor}
|
color={selectedTheme.backgroundColor}
|
||||||
style={{ cursor: 'pointer' }}
|
style={{
|
||||||
|
cursor: 'pointer',
|
||||||
|
border: `2px dashed ${theme.primaryColor}`,
|
||||||
|
}}
|
||||||
/>
|
/>
|
||||||
</Group>
|
</Group>
|
||||||
<Group justify='space-between'>
|
<Group justify='space-between'>
|
||||||
@@ -133,7 +147,10 @@ function ThemeModal({
|
|||||||
radius={'sm'}
|
radius={'sm'}
|
||||||
w={'100px'}
|
w={'100px'}
|
||||||
color={selectedTheme.borderColor}
|
color={selectedTheme.borderColor}
|
||||||
style={{ cursor: 'pointer' }}
|
style={{
|
||||||
|
cursor: 'pointer',
|
||||||
|
border: `2px dashed ${theme.primaryColor}`,
|
||||||
|
}}
|
||||||
/>
|
/>
|
||||||
</Group>
|
</Group>
|
||||||
<Group justify='space-between'>
|
<Group justify='space-between'>
|
||||||
@@ -149,23 +166,40 @@ function ThemeModal({
|
|||||||
radius={'sm'}
|
radius={'sm'}
|
||||||
w={'100px'}
|
w={'100px'}
|
||||||
color={selectedTheme.searchColor}
|
color={selectedTheme.searchColor}
|
||||||
style={{ cursor: 'pointer' }}
|
style={{
|
||||||
|
cursor: 'pointer',
|
||||||
|
border: `2px dashed ${theme.primaryColor}`,
|
||||||
|
}}
|
||||||
/>
|
/>
|
||||||
</Group>
|
</Group>
|
||||||
<Group justify='space-between'>
|
<Group justify='space-between'>
|
||||||
<Select
|
<Select
|
||||||
|
w={'100%'}
|
||||||
data={backgroundList}
|
data={backgroundList}
|
||||||
classNames={selectClasses}
|
classNames={selectClasses}
|
||||||
label='Background Image'
|
label='Background Image'
|
||||||
value={selectedTheme.backgroundImage}
|
value={
|
||||||
|
selectedTheme.backgroundImage === 'none'
|
||||||
|
? 'None'
|
||||||
|
: selectedTheme.backgroundImage
|
||||||
|
}
|
||||||
renderOption={(value) => {
|
renderOption={(value) => {
|
||||||
return (
|
return (
|
||||||
<Group h={'100%'} w={'100%'} justify='space-between'>
|
<Group
|
||||||
|
h={'50px'}
|
||||||
|
w={'100%'}
|
||||||
|
justify='space-between'
|
||||||
|
style={{
|
||||||
|
color: theme.primaryColor,
|
||||||
|
backgroundColor: theme.backgroundColor,
|
||||||
|
fontSize: '18px',
|
||||||
|
}}
|
||||||
|
>
|
||||||
{value.option.value}
|
{value.option.value}
|
||||||
{value.option.value && value.option.value !== 'None' && (
|
{value.option.value && value.option.value !== 'None' && (
|
||||||
<Image
|
<Image
|
||||||
h={'28px'}
|
h={'50px'}
|
||||||
w={'50px'}
|
w={'90px'}
|
||||||
src={`/backgrounds/${value.option.value}`}
|
src={`/backgrounds/${value.option.value}`}
|
||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
@@ -187,11 +221,13 @@ function ThemeModal({
|
|||||||
<ColorPicker value={colorValue} onChange={setColorValue} />
|
<ColorPicker value={colorValue} onChange={setColorValue} />
|
||||||
<Group w={'75%'} justify='space-between'>
|
<Group w={'75%'} justify='space-between'>
|
||||||
<TextInput
|
<TextInput
|
||||||
w={'50%'}
|
className={textInputClasses.default}
|
||||||
|
classNames={textInputClasses}
|
||||||
|
w={'100%'}
|
||||||
value={colorValue}
|
value={colorValue}
|
||||||
onChange={(e) => setColorValue(e.target.value)}
|
onChange={(e) => setColorValue(e.target.value)}
|
||||||
/>
|
/>
|
||||||
<Group>
|
<Group w={'100%'} align='center' justify='center'>
|
||||||
<Button
|
<Button
|
||||||
color={'green'}
|
color={'green'}
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
@@ -248,7 +284,7 @@ function ThemeModal({
|
|||||||
</Stack>
|
</Stack>
|
||||||
</Group>
|
</Group>
|
||||||
<Divider color='black' my='sm' />
|
<Divider color='black' my='sm' />
|
||||||
<Group>
|
<Group mt={'2rem'}>
|
||||||
<Button color={'green'} onClick={handleSaveTheme}>
|
<Button color={'green'} onClick={handleSaveTheme}>
|
||||||
Save
|
Save
|
||||||
</Button>
|
</Button>
|
||||||
|
|||||||
@@ -16,6 +16,7 @@
|
|||||||
&::placeholder {
|
&::placeholder {
|
||||||
color: var(--color-text-acc) !important;
|
color: var(--color-text-acc) !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.options {
|
.options {
|
||||||
@@ -46,5 +47,5 @@
|
|||||||
|
|
||||||
.root {
|
.root {
|
||||||
|
|
||||||
width: 180px !important;
|
width: 180px;
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user