import { css } from 'styled-components/macro'

import type { Languages } from 'config/languages'

type ProcedureName = string
type RequestParameters = any
type StyledCss = ReturnType<typeof css>

export enum ClientIds {
  Facr = 'facr-ott-web',
  Instat = 'ott-web',
}

export enum ClientNames {
  Facr = 'facr',
  Instat = 'instat',
}

export type ClientConfig = {
  auth: {
    clientId: ClientIds,
    metaDataUrlParams?: string,
  },
  defaultLanguage?: Languages,
  description: string,
  disabledPreferences?: boolean,
  name: ClientNames,
  privacyLink: string,
  requests?: Record<ProcedureName, RequestParameters>,
  showSearch?: boolean,
  styles: {
    background?: string,
    homePageHeader?: StyledCss,
    logo: string,
    logoHeight?: number,
    logoLeft?: number,
    logoTop?: number,
    logoWidth?: number,
    matchLogoHeight?: number,
    matchLogoTopMargin?: number,
    matchLogoWidth?: number,
  },
  title: string,
}
