@devgateway/dvz-ui-react
Version:
A modular, embeddable React component library for data visualization and UI, built with TypeScript. Provides reusable components for charts, maps, dashboards, and more, with built-in support for internationalization and Redux integration.
24 lines (23 loc) • 826 B
JavaScript
import { jsx as r } from "react/jsx-runtime";
import m from "../ResponsiveContainer.js";
import { PostProvider as w, PostConsumer as v, Post as P } from "@devgateway/wp-react-lib";
import { useLocation as d, useParams as h } from "react-router";
const g = (t) => {
const { header: s, footer: n } = t, i = d(), e = h(), o = new URLSearchParams(i.search), a = o.get("preview"), p = e.type == "post" ? "posts" : e.type, c = o.get("_wpnonce");
return /* @__PURE__ */ r(m, { header: s, footer: n, children: /* @__PURE__ */ r(
w,
{
type: p,
store: "preview",
perPage: 1,
view: a,
locale: e.lan,
previewNonce: c,
previewId: e.id,
children: /* @__PURE__ */ r(v, { children: /* @__PURE__ */ r(P, { preview: !0, showIntro: !0 }) })
}
) });
};
export {
g as default
};