UNPKG

@kiwicom/orbit-components

Version:

Orbit-components is a React component library which provides developers with the easiest possible way of building Kiwi.com’s products.

19 lines (17 loc) 755 B
import * as React from "react"; import { ThemeProvider as StyledThemeProvider } from "styled-components"; import { UIDReset, UIDFork } from "react-uid"; import Dictionary from "../Dictionary"; import QueryContextProvider from "./QueryContext/Provider"; const ThemeProvider = ({ theme, dictionary, children }) => { return /*#__PURE__*/React.createElement(UIDReset, null, /*#__PURE__*/React.createElement(UIDFork, null, /*#__PURE__*/React.createElement(StyledThemeProvider, { theme: theme }, /*#__PURE__*/React.createElement(QueryContextProvider, null, dictionary ? /*#__PURE__*/React.createElement(Dictionary, { values: dictionary }, React.Children.only(children)) : React.Children.only(children))))); }; export default ThemeProvider;