UNPKG

storybook-addon-theme-provider

Version:

Storybook addon to manage global themes provided by Styled components, Emotion or any other solution based on React component. Compatible with Storybook versions 7 and 8

13 lines (12 loc) 426 B
import { jsx as r } from "react/jsx-runtime"; import { u as i } from "./useGlobalThemes-CslCgoSs.js"; const l = (t) => (m) => { const { themes: s = [], selectedTheme: o } = i(), e = s.find( ({ name: h }) => !!o && h === o ); return /* @__PURE__ */ r(t, { theme: e == null ? void 0 : e.themeObject, children: /* @__PURE__ */ r(m, {}) }); }; export { l as w }; //# sourceMappingURL=withThemeProvider-BzEFvOAD.js.map