// @flow
import type { ThemedCssFunction } from 'styled-components';
import type { ThemeSpecificStyles } from './themes.proptypes';
import type { ThemeProps } from '../../types';
import { themes } from '../../themes';

export const getThemeSpecificStyles = (styles: ThemeSpecificStyles) => ({
  theme,
}: ThemeProps): ?ThemedCssFunction => {
  if (theme.name === themes.wealthsimple.name) return styles.wealthsimple;
  if (theme.name === themes.trade.name) return styles.trade;
  if (theme.name === themes.crypto.name) return styles.crypto;
  if (theme.name === themes.empower.name) return styles.empower;
  if (theme.name === themes.atlas.name) return styles.atlas;
  if (theme.name === themes.whitelabelDefaults.name)
    return styles.whitelabelDefaults;
};
