TWNTY-3825 - ESLint rule: const naming (#4171)

* ESLint rule: const naming

Co-authored-by: v1b3m <vibenjamin6@gmail.com>
Co-authored-by: KlingerMatheus <klinger.matheus@gitstart.dev>

* Refactor according to review

Co-authored-by: v1b3m <vibenjamin6@gmail.com>
Co-authored-by: KlingerMatheus <klinger.matheus@gitstart.dev>

* refactor: Reverts changes on `twenty-server`

Co-authored-by: KlingerMatheus <klinger.matheus@gitstart.dev>
Co-authored-by: v1b3m <vibenjamin6@gmail.com>

---------

Co-authored-by: gitstart-twenty <gitstart-twenty@users.noreply.github.com>
Co-authored-by: v1b3m <vibenjamin6@gmail.com>
Co-authored-by: KlingerMatheus <klinger.matheus@gitstart.dev>
This commit is contained in:
gitstart-app[bot]
2024-02-25 13:52:48 +01:00
committed by GitHub
parent a108d36040
commit f543191552
184 changed files with 1121 additions and 828 deletions

View File

@ -1,7 +1,7 @@
import { useTheme } from '@emotion/react';
import { motion } from 'framer-motion';
import { AnimationDuration } from '@/ui/theme/constants/animation';
import { AnimationDuration } from '@/ui/theme/constants/Animation';
type AnimatedEaseInProps = Omit<
React.ComponentProps<typeof motion.div>,

View File

@ -1,7 +1,7 @@
import { useTheme } from '@emotion/react';
import { AnimatePresence, motion } from 'framer-motion';
import { AnimationDuration } from '@/ui/theme/constants/animation';
import { AnimationDuration } from '@/ui/theme/constants/Animation';
type AnimatedEaseInOutProps = {
isOpen: boolean;

View File

@ -1,7 +1,7 @@
import { useTheme } from '@emotion/react';
import { AnimatePresence, motion } from 'framer-motion';
import { AnimationDuration } from '@/ui/theme/constants/animation';
import { AnimationDuration } from '@/ui/theme/constants/Animation';
type AnimatedFadeOutProps = {
isOpen: boolean;

View File

@ -5,7 +5,7 @@ import {
} from '@air/react-drag-to-select';
import { useTheme } from '@emotion/react';
import { rgba } from '@/ui/theme/constants/colors';
import { RGBA } from '@/ui/theme/constants/Rgba';
import { useDragSelect } from '../hooks/useDragSelect';
@ -61,7 +61,7 @@ export const DragSelect = ({
selectionProps: {
style: {
border: `1px solid ${theme.color.blue10}`,
background: rgba(theme.color.blue30, 0.4),
background: RGBA(theme.color.blue30, 0.4),
position: `absolute`,
zIndex: 99,
},

View File

@ -0,0 +1,7 @@
import { CustomHotkeyScopes } from '@/ui/utilities/hotkey/types/CustomHotkeyScope';
export const DEFAULT_HOTKEYS_SCOPE_CUSTOM_SCOPES: CustomHotkeyScopes = {
commandMenu: true,
goto: false,
keyboardShortcutMenu: false,
};

View File

@ -1,13 +1,6 @@
import { AppHotkeyScope } from '../types/AppHotkeyScope';
import { CustomHotkeyScopes } from '../types/CustomHotkeyScope';
import { HotkeyScope } from '../types/HotkeyScope';
export const DEFAULT_HOTKEYS_SCOPE_CUSTOM_SCOPES: CustomHotkeyScopes = {
commandMenu: true,
goto: false,
keyboardShortcutMenu: false,
};
export const INITIAL_HOTKEYS_SCOPE: HotkeyScope = {
scope: AppHotkeyScope.App,
customScopes: {

View File

@ -2,7 +2,7 @@ import { useRecoilCallback } from 'recoil';
import { isDefined } from '~/utils/isDefined';
import { DEFAULT_HOTKEYS_SCOPE_CUSTOM_SCOPES } from '../constants';
import { DEFAULT_HOTKEYS_SCOPE_CUSTOM_SCOPES } from '../constants/DefaultHotkeysScopeCustomScopes';
import { currentHotkeyScopeState } from '../states/internal/currentHotkeyScopeState';
import { internalHotkeysEnabledScopesState } from '../states/internal/internalHotkeysEnabledScopesState';
import { AppHotkeyScope } from '../types/AppHotkeyScope';

View File

@ -1,6 +1,6 @@
import { atom } from 'recoil';
import { INITIAL_HOTKEYS_SCOPE } from '../../constants';
import { INITIAL_HOTKEYS_SCOPE } from '../../constants/InitialHotkeysScope';
import { HotkeyScope } from '../../types/HotkeyScope';
export const currentHotkeyScopeState = atom<HotkeyScope>({

View File

@ -1,6 +1,6 @@
import { useMediaQuery } from 'react-responsive';
import { MOBILE_VIEWPORT } from '@/ui/theme/constants/theme';
import { MOBILE_VIEWPORT } from '@/ui/theme/constants/MobileViewport';
export const useIsMobile = () =>
useMediaQuery({ query: `(max-width: ${MOBILE_VIEWPORT}px)` });