mirror of
https://github.com/oxen-io/session-desktop.git
synced 2023-12-14 02:12:57 +01:00
feat: moved constants into a constants folder
This commit is contained in:
parent
13efc85d5a
commit
2f0e993af3
|
@ -1,5 +1,5 @@
|
|||
import React, { useEffect, useState } from 'react';
|
||||
import { COLORS } from '../../../themes/colors';
|
||||
import { COLORS } from '../../../themes/constants/colors';
|
||||
import { getInitials } from '../../../util/getInitials';
|
||||
|
||||
type Props = {
|
||||
|
|
|
@ -6,7 +6,12 @@ import Picker from '@emoji-mart/react';
|
|||
import { useSelector } from 'react-redux';
|
||||
import { getTheme } from '../../state/selectors/theme';
|
||||
import { FixedBaseEmoji, FixedPickerProps } from '../../types/Reaction';
|
||||
import { COLORS, PrimaryColorStateType, THEMES, ThemeStateType } from '../../themes/colors.js';
|
||||
import {
|
||||
COLORS,
|
||||
PrimaryColorStateType,
|
||||
THEMES,
|
||||
ThemeStateType,
|
||||
} from '../../themes/constants/colors.js';
|
||||
import { hexColorToRGB } from '../../util/hexColorToRGB';
|
||||
import { getPrimaryColor } from '../../state/selectors/primaryColor';
|
||||
import { i18nEmojiData } from '../../util/emoji';
|
||||
|
|
|
@ -50,7 +50,7 @@ import { UserUtils } from '../../session/utils';
|
|||
|
||||
import { getLatestReleaseFromFileServer } from '../../session/apis/file_server_api/FileServerApi';
|
||||
import { switchThemeTo } from '../../session/utils/Theme';
|
||||
import { ThemeStateType } from '../../themes/colors';
|
||||
import { ThemeStateType } from '../../themes/constants/colors';
|
||||
import { getTheme } from '../../state/selectors/theme';
|
||||
import { switchPrimaryColor } from '../../themes/switchPrimaryColor';
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@ import { getTheme } from '../../state/selectors/theme';
|
|||
import { SessionRadio, SessionRadioPrimaryColors } from '../basic/SessionRadio';
|
||||
import { SpacerLG, SpacerMD } from '../basic/Text';
|
||||
import { StyledDescriptionSettingsItem, StyledTitleSettingsItem } from './SessionSettingListItem';
|
||||
import { getPrimaryColors, THEMES, ThemeStateType } from '../../themes/colors';
|
||||
import { getPrimaryColors, THEMES, ThemeStateType } from '../../themes/constants/colors';
|
||||
import { switchPrimaryColor } from '../../themes/switchPrimaryColor';
|
||||
import { getPrimaryColor } from '../../state/selectors/primaryColor';
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
import { Dispatch } from 'redux';
|
||||
import { applyTheme } from '../../state/ducks/theme';
|
||||
import { ThemeStateType } from '../../themes/colors';
|
||||
import { ThemeStateType } from '../../themes/constants/colors';
|
||||
import { switchHtmlToDarkTheme, switchHtmlToLightTheme } from '../../themes/SessionTheme';
|
||||
import { switchTheme } from '../../themes/switchTheme';
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import { PrimaryColorStateType } from '../../themes/colors';
|
||||
import { PrimaryColorStateType } from '../../themes/constants/colors';
|
||||
|
||||
export const APPLY_PRIMARY_COLOR = 'APPLY_PRIMARY_COLOR';
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import { ThemeStateType } from '../../themes/colors';
|
||||
import { ThemeStateType } from '../../themes/constants/colors';
|
||||
|
||||
export const APPLY_THEME = 'APPLY_THEME';
|
||||
|
||||
|
|
|
@ -17,7 +17,7 @@ import {
|
|||
reducer as stagedAttachments,
|
||||
StagedAttachmentsStateType,
|
||||
} from './ducks/stagedAttachments';
|
||||
import { PrimaryColorStateType, ThemeStateType } from '../themes/colors';
|
||||
import { PrimaryColorStateType, ThemeStateType } from '../themes/constants/colors';
|
||||
|
||||
export type StateType = {
|
||||
search: SearchStateType;
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import { PrimaryColorStateType } from '../../themes/colors';
|
||||
import { PrimaryColorStateType } from '../../themes/constants/colors';
|
||||
import { StateType } from '../reducer';
|
||||
|
||||
export const getPrimaryColor = (state: StateType): PrimaryColorStateType => state.primaryColor;
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import { ThemeStateType } from '../../themes/colors';
|
||||
import { ThemeStateType } from '../../themes/constants/colors';
|
||||
import { StateType } from '../reducer';
|
||||
|
||||
export const getTheme = (state: StateType): ThemeStateType => state.theme;
|
||||
|
|
Loading…
Reference in a new issue