Introduce a new design for the left pane
This commit is contained in:
parent
d60600d6fb
commit
35a54cdc02
63 changed files with 1205 additions and 576 deletions
|
@ -15,6 +15,8 @@ import {
|
|||
} from '../../types/Colors';
|
||||
import { getPreferredReactionEmoji as getPreferredReactionEmojiFromStoredValue } from '../../reactions/preferredReactionEmoji';
|
||||
|
||||
const DEFAULT_PREFERRED_LEFT_PANE_WIDTH = 320;
|
||||
|
||||
export const getItems = (state: StateType): ItemsStateType => state.items;
|
||||
|
||||
export const getUserAgent = createSelector(
|
||||
|
@ -63,6 +65,15 @@ export const getEmojiSkinTone = createSelector(
|
|||
: 0
|
||||
);
|
||||
|
||||
export const getPreferredLeftPaneWidth = createSelector(
|
||||
getItems,
|
||||
({ preferredLeftPaneWidth }: Readonly<ItemsStateType>): number =>
|
||||
typeof preferredLeftPaneWidth === 'number' &&
|
||||
Number.isInteger(preferredLeftPaneWidth)
|
||||
? preferredLeftPaneWidth
|
||||
: DEFAULT_PREFERRED_LEFT_PANE_WIDTH
|
||||
);
|
||||
|
||||
export const getPreferredReactionEmoji = createSelector(
|
||||
getItems,
|
||||
getEmojiSkinTone,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue