[UI] Remove theme constants from twenty-front and use the ones exported from twenty-ui. (#5558)

Some parts of the Frontend used theme constants exported from
`modules/ui` while other parts used theme constants exported from
`twenty-ui`.

This PR centralizes theme constants by removing them from `modules/ui`
completely.
This commit is contained in:
Abdullah
2024-05-25 19:09:25 +05:00
committed by GitHub
parent 9c325eb0ef
commit cfd83d6b8e
81 changed files with 84 additions and 633 deletions

View File

@ -1,9 +1,8 @@
import styled from '@emotion/styled';
import { IconComponent, Tag } from 'twenty-ui';
import { IconComponent, Tag, ThemeColor } from 'twenty-ui';
import { Checkbox } from '@/ui/input/components/Checkbox';
import { MenuItemLeftContent } from '@/ui/navigation/menu-item/internals/components/MenuItemLeftContent';
import { ThemeColor } from '@/ui/theme/constants/MainColorNames';
import { StyledMenuItemBase } from '../internals/components/StyledMenuItemBase';

View File

@ -1,11 +1,10 @@
import { Tag } from 'twenty-ui';
import { Tag, ThemeColor } from 'twenty-ui';
import {
Checkbox,
CheckboxShape,
CheckboxSize,
} from '@/ui/input/components/Checkbox';
import { ThemeColor } from '@/ui/theme/constants/MainColorNames';
import {
StyledMenuItemBase,

View File

@ -1,7 +1,10 @@
import { useTheme } from '@emotion/react';
import { ColorSample, ColorSampleVariant, IconCheck } from 'twenty-ui';
import { ThemeColor } from '@/ui/theme/constants/MainColorNames';
import {
ColorSample,
ColorSampleVariant,
IconCheck,
ThemeColor,
} from 'twenty-ui';
import {
StyledMenuItemLabel,

View File

@ -1,7 +1,5 @@
import { useTheme } from '@emotion/react';
import { IconCheck, Tag } from 'twenty-ui';
import { ThemeColor } from '@/ui/theme/constants/MainColorNames';
import { IconCheck, Tag, ThemeColor } from 'twenty-ui';
import { StyledMenuItemLeftContent } from '../internals/components/StyledMenuItemBase';

View File

@ -1,8 +1,6 @@
import { MouseEvent } from 'react';
import styled from '@emotion/styled';
import { IconComponent } from 'twenty-ui';
import { HOVER_BACKGROUND } from '@/ui/theme/constants/HoverBackground';
import { HOVER_BACKGROUND, IconComponent } from 'twenty-ui';
import { MenuItemLeftContent } from '../internals/components/MenuItemLeftContent';
import { StyledMenuItemLeftContent } from '../internals/components/StyledMenuItemBase';

View File

@ -6,12 +6,9 @@ import {
CatalogStory,
ColorSampleVariant,
ComponentDecorator,
} from 'twenty-ui';
import {
MAIN_COLOR_NAMES,
ThemeColor,
} from '@/ui/theme/constants/MainColorNames';
} from 'twenty-ui';
import { MenuItemSelectColor } from '../MenuItemSelectColor';

View File

@ -1,7 +1,6 @@
import { css } from '@emotion/react';
import styled from '@emotion/styled';
import { HOVER_BACKGROUND } from '@/ui/theme/constants/HoverBackground';
import { HOVER_BACKGROUND } from 'twenty-ui';
import { MenuItemAccent } from '../../types/MenuItemAccent';