{
  "mappings": "AAEA,OAAO,cAAM;AAGb,OAAO,cAAM,WAAY,aAAa;AAWtC,OAAO,cAAM,iBAAkB,IAAI,mBAAiB,SAAS",
  "names": [],
  "sources": [
    "src/helpers.tsx"
  ],
  "version": 3,
  "sourcesContent": [
    "import { MEDIA } from './constants'\n\nexport const helpers = {}\n// Helpers\n\nexport const getTheme = (key: string, fallback?: string): any => {\n  if (typeof window === 'undefined') return undefined\n  let theme\n  try {\n    theme = localStorage.getItem(key) || undefined\n  } catch (e) {\n    // Unsupported\n  }\n  return theme || fallback\n}\n\nexport const getSystemTheme = (e?: MediaQueryList): 'dark' | 'light' => {\n  if (!e) {\n    e = window.matchMedia(MEDIA)\n  }\n\n  const isDark = e.matches\n  const systemTheme = isDark ? 'dark' : 'light'\n  return systemTheme\n}\n"
  ]
}