Added Proper theme color for Favorite Input box (#11434)
#11418 The background color changes based on the theme. - If the theme is 'light', the background color will be white. - Otherwise, it will use the theme's background transparent lighter color. --------- Co-authored-by: ehconitin <nitinkoche03@gmail.com> Co-authored-by: nitin <142569587+ehconitin@users.noreply.github.com>
This commit is contained in:
@ -1,12 +1,11 @@
|
|||||||
import { TextInputV2 } from '@/ui/input/components/TextInputV2';
|
import { TextInputV2 } from '@/ui/input/components/TextInputV2';
|
||||||
import { useScopedHotkeys } from '@/ui/utilities/hotkey/hooks/useScopedHotkeys';
|
import { useScopedHotkeys } from '@/ui/utilities/hotkey/hooks/useScopedHotkeys';
|
||||||
import { useListenClickOutside } from '@/ui/utilities/pointer-event/hooks/useListenClickOutside';
|
import { useListenClickOutside } from '@/ui/utilities/pointer-event/hooks/useListenClickOutside';
|
||||||
import styled from '@emotion/styled';
|
|
||||||
import { FocusEvent, useRef } from 'react';
|
import { FocusEvent, useRef } from 'react';
|
||||||
import { Key } from 'ts-key-enum';
|
import { Key } from 'ts-key-enum';
|
||||||
import { useHotkeyScopeOnMount } from '~/hooks/useHotkeyScopeOnMount';
|
|
||||||
import { isDefined } from 'twenty-shared/utils';
|
import { isDefined } from 'twenty-shared/utils';
|
||||||
import { IconComponent, TablerIconsProps } from 'twenty-ui/display';
|
import { IconComponent, TablerIconsProps } from 'twenty-ui/display';
|
||||||
|
import { useHotkeyScopeOnMount } from '~/hooks/useHotkeyScopeOnMount';
|
||||||
|
|
||||||
type NavigationDrawerInputProps = {
|
type NavigationDrawerInputProps = {
|
||||||
className?: string;
|
className?: string;
|
||||||
@ -20,10 +19,6 @@ type NavigationDrawerInputProps = {
|
|||||||
hotkeyScope: string;
|
hotkeyScope: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
const StyledInput = styled(TextInputV2)`
|
|
||||||
background-color: white;
|
|
||||||
`;
|
|
||||||
|
|
||||||
export const NavigationDrawerInput = ({
|
export const NavigationDrawerInput = ({
|
||||||
className,
|
className,
|
||||||
placeholder,
|
placeholder,
|
||||||
@ -71,7 +66,7 @@ export const NavigationDrawerInput = ({
|
|||||||
};
|
};
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<StyledInput
|
<TextInputV2
|
||||||
className={className}
|
className={className}
|
||||||
LeftIcon={Icon}
|
LeftIcon={Icon}
|
||||||
ref={inputRef}
|
ref={inputRef}
|
||||||
|
|||||||
Reference in New Issue
Block a user