zudoku 0.52.2 → 0.53.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/app/demo.js +2 -2
- package/dist/app/demo.js.map +1 -1
- package/dist/app/main.js +4 -4
- package/dist/app/standalone.js +3 -3
- package/dist/app/standalone.js.map +1 -1
- package/dist/config/validators/validate.d.ts +2 -2
- package/dist/config/validators/validate.js +3 -3
- package/dist/config/validators/validate.js.map +1 -1
- package/dist/flat-config.d.ts +325 -0
- package/dist/lib/components/Banner.js +1 -1
- package/dist/lib/components/Banner.js.map +1 -1
- package/dist/lib/components/Footer.js +1 -1
- package/dist/lib/components/Footer.js.map +1 -1
- package/dist/lib/components/Header.js +10 -10
- package/dist/lib/components/Header.js.map +1 -1
- package/dist/lib/components/Main.js +1 -1
- package/dist/lib/components/MobileTopNavigation.js +1 -1
- package/dist/lib/components/navigation/NavigationWrapper.js +1 -1
- package/dist/lib/core/ZudokuContext.d.ts +4 -4
- package/dist/lib/core/ZudokuContext.js +2 -2
- package/dist/vite/build.js +1 -1
- package/dist/vite/dev-server.js +1 -1
- package/lib/{MdxPage-Glqk-5sb.js → MdxPage-swXPJ0gf.js} +2 -2
- package/lib/{MdxPage-Glqk-5sb.js.map → MdxPage-swXPJ0gf.js.map} +1 -1
- package/lib/{OasProvider-Cks7Ky_-.js → OasProvider-CDAM3TB1.js} +2 -2
- package/lib/{OasProvider-Cks7Ky_-.js.map → OasProvider-CDAM3TB1.js.map} +1 -1
- package/lib/{OperationList-BP3gUFCx.js → OperationList-C9Hb9ql8.js} +5 -5
- package/lib/{OperationList-BP3gUFCx.js.map → OperationList-C9Hb9ql8.js.map} +1 -1
- package/lib/{Pagination-D2xTtsFG.js → Pagination-VGlgeCmS.js} +2 -2
- package/lib/{Pagination-D2xTtsFG.js.map → Pagination-VGlgeCmS.js.map} +1 -1
- package/lib/{SchemaList-BQOuyEO7.js → SchemaList-BAbh1BXO.js} +3 -3
- package/lib/{SchemaList-BQOuyEO7.js.map → SchemaList-BAbh1BXO.js.map} +1 -1
- package/lib/{SchemaView-C6fqo8Th.js → SchemaView-C2Io712T.js} +3 -3
- package/lib/{SchemaView-C6fqo8Th.js.map → SchemaView-C2Io712T.js.map} +1 -1
- package/lib/{SignUp-M9Jz4SXJ.js → SignUp-5RUdVhnq.js} +2 -2
- package/lib/{SignUp-M9Jz4SXJ.js.map → SignUp-5RUdVhnq.js.map} +1 -1
- package/lib/{circular-BNp-4wdn.js → circular-B42RaanD.js} +2 -2
- package/lib/{circular-BNp-4wdn.js.map → circular-B42RaanD.js.map} +1 -1
- package/lib/{createServer-D7OPYwXA.js → createServer-BKFsRuuk.js} +3 -3
- package/lib/{createServer-D7OPYwXA.js.map → createServer-BKFsRuuk.js.map} +1 -1
- package/lib/{errors-C473PjdR.js → errors-CF2X_x5o.js} +3 -3
- package/lib/{errors-C473PjdR.js.map → errors-CF2X_x5o.js.map} +1 -1
- package/lib/{index-BLRAtPoq.js → index-B6Re5_cx.js} +7 -7
- package/lib/{index-BLRAtPoq.js.map → index-B6Re5_cx.js.map} +1 -1
- package/lib/{index-Chtnw-sn.js → index-CLy1XyH0.js} +13 -13
- package/lib/{index-Chtnw-sn.js.map → index-CLy1XyH0.js.map} +1 -1
- package/lib/zudoku.auth-azureb2c.js +1 -1
- package/lib/zudoku.auth-clerk.js +1 -1
- package/lib/zudoku.auth-openid.js +1 -1
- package/lib/zudoku.components.js +1 -1
- package/lib/zudoku.plugin-api-catalog.js +1 -1
- package/lib/zudoku.plugin-markdown.js +1 -1
- package/lib/zudoku.plugin-openapi.js +1 -1
- package/package.json +1 -1
- package/src/app/demo.tsx +2 -2
- package/src/app/main.tsx +4 -4
- package/src/app/standalone.tsx +3 -3
- package/src/lib/components/Banner.tsx +1 -1
- package/src/lib/components/Footer.tsx +1 -1
- package/src/lib/components/Header.tsx +15 -17
- package/src/lib/components/Main.tsx +1 -1
- package/src/lib/components/MobileTopNavigation.tsx +2 -2
- package/src/lib/components/navigation/NavigationWrapper.tsx +1 -1
- package/src/lib/core/ZudokuContext.ts +5 -5
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { j as yo } from "./jsx-runtime-C5mzlN2N.js";
|
|
2
2
|
import { C as aa } from "./ClientOnly-E7hGysn1.js";
|
|
3
3
|
import { j as sa, u as To } from "./hook-Bd0yS8M0.js";
|
|
4
|
-
import { C as ca, A as qt, a as la } from "./errors-
|
|
4
|
+
import { C as ca, A as qt, a as la } from "./errors-CF2X_x5o.js";
|
|
5
5
|
/*! @azure/msal-common v15.7.0 2025-05-30 */
|
|
6
6
|
const d = {
|
|
7
7
|
LIBRARY_NAME: "MSAL.JS",
|
package/lib/zudoku.auth-clerk.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { j as l } from "./jsx-runtime-C5mzlN2N.js";
|
|
2
2
|
import { LogOutIcon as g } from "lucide-react";
|
|
3
|
-
import { S as f, a as w, b as p } from "./SignUp-
|
|
3
|
+
import { S as f, a as w, b as p } from "./SignUp-5RUdVhnq.js";
|
|
4
4
|
import { u as n } from "./hook-Bd0yS8M0.js";
|
|
5
5
|
const y = ({
|
|
6
6
|
clerkPubKey: d,
|
|
@@ -2,7 +2,7 @@ import { j as ne } from "./jsx-runtime-C5mzlN2N.js";
|
|
|
2
2
|
import { g as Le } from "./invariant-DAFpPywt.js";
|
|
3
3
|
import { C as Ue } from "./ClientOnly-E7hGysn1.js";
|
|
4
4
|
import { j as xe, u as S } from "./hook-Bd0yS8M0.js";
|
|
5
|
-
import { C as Ce, O as re, A as R, a as Ie } from "./errors-
|
|
5
|
+
import { C as Ce, O as re, A as R, a as Ie } from "./errors-CF2X_x5o.js";
|
|
6
6
|
var O = { exports: {} }, je = O.exports, oe;
|
|
7
7
|
function De() {
|
|
8
8
|
return oe || (oe = 1, function(t) {
|
package/lib/zudoku.components.js
CHANGED
|
@@ -3,7 +3,7 @@ import "./index-ClhS5TxS.js";
|
|
|
3
3
|
import "./chunk-DQRVZFIR-DHK7_Ilc.js";
|
|
4
4
|
import "./hook-Bd0yS8M0.js";
|
|
5
5
|
import "./Slot-DwZlQ-vX.js";
|
|
6
|
-
import { e as C, f as d, j as h, B as k, m as l, C as S, i as B, H as c, c as y, L as E, M as g, g as H, R as L, d as M, S as R, h as T, T as Z, Z as f, b as A, l as b, k as j, n as v, u as w } from "./index-
|
|
6
|
+
import { e as C, f as d, j as h, B as k, m as l, C as S, i as B, H as c, c as y, L as E, M as g, g as H, R as L, d as M, S as R, h as T, T as Z, Z as f, b as A, l as b, k as j, n as v, u as w } from "./index-CLy1XyH0.js";
|
|
7
7
|
import "./ui/Button.js";
|
|
8
8
|
import "./ui/Callout.js";
|
|
9
9
|
import "./ClientOnly-E7hGysn1.js";
|
|
@@ -3,7 +3,7 @@ import { s as f } from "./index-CcV90rin.js";
|
|
|
3
3
|
import { d as b, m as j } from "./chunk-DQRVZFIR-DHK7_Ilc.js";
|
|
4
4
|
import { u as x, c as v, j as d } from "./hook-Bd0yS8M0.js";
|
|
5
5
|
import { H as y } from "./RouteGuard-CbKd7_9h.js";
|
|
6
|
-
import { L as N } from "./index-
|
|
6
|
+
import { L as N } from "./index-CLy1XyH0.js";
|
|
7
7
|
import { H as k, M as S } from "./Slot-DwZlQ-vX.js";
|
|
8
8
|
const w = ({
|
|
9
9
|
items: n,
|
|
@@ -4,7 +4,7 @@ const m = (t) => ({
|
|
|
4
4
|
([e, n]) => ({
|
|
5
5
|
path: e,
|
|
6
6
|
lazy: async () => {
|
|
7
|
-
const { MdxPage: o } = await import("./MdxPage-
|
|
7
|
+
const { MdxPage: o } = await import("./MdxPage-swXPJ0gf.js"), { default: a, ...r } = await n();
|
|
8
8
|
return {
|
|
9
9
|
element: /* @__PURE__ */ s.jsx(
|
|
10
10
|
o,
|
|
@@ -3,7 +3,7 @@ import "lucide-react";
|
|
|
3
3
|
import "./chunk-DQRVZFIR-DHK7_Ilc.js";
|
|
4
4
|
import "./hook-Bd0yS8M0.js";
|
|
5
5
|
import "./ui/Button.js";
|
|
6
|
-
import { E as e, U as n, F as s } from "./index-
|
|
6
|
+
import { E as e, U as n, F as s } from "./index-B6Re5_cx.js";
|
|
7
7
|
export {
|
|
8
8
|
e as GetNavigationOperationsQuery,
|
|
9
9
|
n as UNTAGGED_PATH,
|
package/package.json
CHANGED
package/src/app/demo.tsx
CHANGED
package/src/app/main.tsx
CHANGED
|
@@ -36,12 +36,12 @@ export const convertZudokuConfigToOptions = (
|
|
|
36
36
|
basePath: config.basePath,
|
|
37
37
|
canonicalUrlOrigin: config.canonicalUrlOrigin,
|
|
38
38
|
protectedRoutes: config.protectedRoutes,
|
|
39
|
-
|
|
40
|
-
...config.
|
|
39
|
+
site: {
|
|
40
|
+
...config.site,
|
|
41
41
|
showPoweredBy:
|
|
42
42
|
ZuploEnv.buildConfig?.entitlements.devPortalZuploBranding ??
|
|
43
|
-
config.
|
|
44
|
-
logo: config.
|
|
43
|
+
config.site?.showPoweredBy,
|
|
44
|
+
logo: config.site?.logo,
|
|
45
45
|
},
|
|
46
46
|
slots: config.slots,
|
|
47
47
|
metadata: {
|
package/src/app/standalone.tsx
CHANGED
|
@@ -13,14 +13,14 @@ if (!root) {
|
|
|
13
13
|
}
|
|
14
14
|
|
|
15
15
|
const apiUrl = root.getAttribute("data-api-url");
|
|
16
|
-
const
|
|
16
|
+
const title = document.getElementsByTagName("title")[0]!.innerText;
|
|
17
17
|
const logoUrl = root.getAttribute("data-logo-url");
|
|
18
18
|
|
|
19
19
|
// IMPORTANT: This component must not contain tailwind classes
|
|
20
20
|
// This directory is not processed by the tailwind plugin
|
|
21
21
|
|
|
22
22
|
const config = {
|
|
23
|
-
|
|
23
|
+
site: {
|
|
24
24
|
logo: logoUrl
|
|
25
25
|
? {
|
|
26
26
|
src: {
|
|
@@ -29,7 +29,7 @@ const config = {
|
|
|
29
29
|
},
|
|
30
30
|
}
|
|
31
31
|
: undefined,
|
|
32
|
-
|
|
32
|
+
title,
|
|
33
33
|
},
|
|
34
34
|
navigation: [
|
|
35
35
|
{
|
|
@@ -60,22 +60,22 @@ export const Header = memo(function HeaderInner() {
|
|
|
60
60
|
const auth = useAuth();
|
|
61
61
|
const { isAuthenticated, profile, isAuthEnabled } = useAuth();
|
|
62
62
|
const context = useZudoku();
|
|
63
|
-
const {
|
|
63
|
+
const { site, plugins, options } = context;
|
|
64
64
|
|
|
65
65
|
const accountItems = plugins
|
|
66
66
|
.filter((p) => isProfileMenuPlugin(p))
|
|
67
67
|
.flatMap((p) => p.getProfileMenuItems(context))
|
|
68
68
|
.sort((i) => i.weight ?? 0);
|
|
69
69
|
|
|
70
|
-
const logoLightSrc =
|
|
71
|
-
? /https?:\/\//.test(
|
|
72
|
-
?
|
|
73
|
-
: joinUrl(options.basePath,
|
|
70
|
+
const logoLightSrc = site?.logo
|
|
71
|
+
? /https?:\/\//.test(site.logo.src.light)
|
|
72
|
+
? site.logo.src.light
|
|
73
|
+
: joinUrl(options.basePath, site.logo.src.light)
|
|
74
74
|
: undefined;
|
|
75
|
-
const logoDarkSrc =
|
|
76
|
-
? /https?:\/\//.test(
|
|
77
|
-
?
|
|
78
|
-
: joinUrl(options.basePath,
|
|
75
|
+
const logoDarkSrc = site?.logo
|
|
76
|
+
? /https?:\/\//.test(site.logo.src.dark)
|
|
77
|
+
? site.logo.src.dark
|
|
78
|
+
: joinUrl(options.basePath, site.logo.src.dark)
|
|
79
79
|
: undefined;
|
|
80
80
|
|
|
81
81
|
const borderBottom = "inset-shadow-[0_-1px_0_0_var(--border)]";
|
|
@@ -89,27 +89,25 @@ export const Header = memo(function HeaderInner() {
|
|
|
89
89
|
<div className="flex">
|
|
90
90
|
<Link to="/">
|
|
91
91
|
<div className="flex items-center gap-3.5">
|
|
92
|
-
{
|
|
92
|
+
{site?.logo && (
|
|
93
93
|
<>
|
|
94
94
|
<img
|
|
95
95
|
src={logoLightSrc}
|
|
96
|
-
alt={
|
|
97
|
-
style={{ width:
|
|
96
|
+
alt={site.logo.alt ?? site.title}
|
|
97
|
+
style={{ width: site.logo.width }}
|
|
98
98
|
className="max-h-(--top-header-height) dark:hidden"
|
|
99
99
|
loading="lazy"
|
|
100
100
|
/>
|
|
101
101
|
<img
|
|
102
102
|
src={logoDarkSrc}
|
|
103
|
-
alt={
|
|
104
|
-
style={{ width:
|
|
103
|
+
alt={site.logo.alt ?? site.title}
|
|
104
|
+
style={{ width: site.logo.width }}
|
|
105
105
|
className="max-h-(--top-header-height) hidden dark:block"
|
|
106
106
|
loading="lazy"
|
|
107
107
|
/>
|
|
108
108
|
</>
|
|
109
109
|
)}
|
|
110
|
-
<span className="font-semibold text-2xl">
|
|
111
|
-
{page?.pageTitle}
|
|
112
|
-
</span>
|
|
110
|
+
<span className="font-semibold text-2xl">{site?.title}</span>
|
|
113
111
|
</div>
|
|
114
112
|
</Link>
|
|
115
113
|
</div>
|
|
@@ -16,7 +16,7 @@ export const Main = ({ children }: PropsWithChildren) => {
|
|
|
16
16
|
|
|
17
17
|
return (
|
|
18
18
|
<Drawer
|
|
19
|
-
direction={options.
|
|
19
|
+
direction={options.site?.dir === "rtl" ? "right" : "left"}
|
|
20
20
|
open={isDrawerOpen}
|
|
21
21
|
onOpenChange={(open) => setDrawerOpen(open)}
|
|
22
22
|
>
|
|
@@ -26,7 +26,7 @@ export const MobileTopNavigation = () => {
|
|
|
26
26
|
|
|
27
27
|
return (
|
|
28
28
|
<Drawer
|
|
29
|
-
direction={options.
|
|
29
|
+
direction={options.site?.dir === "rtl" ? "left" : "right"}
|
|
30
30
|
open={drawerOpen}
|
|
31
31
|
onOpenChange={(open) => setDrawerOpen(open)}
|
|
32
32
|
>
|
|
@@ -62,7 +62,7 @@ export const MobileTopNavigation = () => {
|
|
|
62
62
|
))}
|
|
63
63
|
</ul>
|
|
64
64
|
</div>
|
|
65
|
-
{options.
|
|
65
|
+
{options.site?.showPoweredBy !== false && (
|
|
66
66
|
<PoweredByZudoku className="grow-0 justify-center gap-1" />
|
|
67
67
|
)}
|
|
68
68
|
</div>
|
|
@@ -37,7 +37,7 @@ export const NavigationWrapper = ({
|
|
|
37
37
|
</nav>
|
|
38
38
|
|
|
39
39
|
<div className="bg-background border-t p-2 mx-5 gap-2 items-center mt-2 drop-shadow-[0_-3px_1px_rgba(0,0,0,0.015)] hidden lg:[&:has(>_:nth-child(1):last-child)]:flex">
|
|
40
|
-
{options.
|
|
40
|
+
{options.site?.showPoweredBy !== false && <PoweredByZudoku />}
|
|
41
41
|
</div>
|
|
42
42
|
</div>
|
|
43
43
|
);
|
|
@@ -54,10 +54,10 @@ type Metadata = Partial<{
|
|
|
54
54
|
publisher: string;
|
|
55
55
|
}>;
|
|
56
56
|
|
|
57
|
-
type
|
|
57
|
+
type Site = Partial<{
|
|
58
58
|
dir?: "ltr" | "rtl";
|
|
59
59
|
showPoweredBy?: boolean;
|
|
60
|
-
|
|
60
|
+
title?: string;
|
|
61
61
|
logo?: {
|
|
62
62
|
src: {
|
|
63
63
|
light: string;
|
|
@@ -78,7 +78,7 @@ export type ZudokuContextOptions = {
|
|
|
78
78
|
basePath?: string;
|
|
79
79
|
canonicalUrlOrigin?: string;
|
|
80
80
|
metadata?: Metadata;
|
|
81
|
-
|
|
81
|
+
site?: Site;
|
|
82
82
|
authentication?: AuthenticationPlugin;
|
|
83
83
|
navigation?: Navigation;
|
|
84
84
|
plugins?: ZudokuPlugin[];
|
|
@@ -102,7 +102,7 @@ export class ZudokuContext {
|
|
|
102
102
|
public plugins: NonNullable<ZudokuContextOptions["plugins"]>;
|
|
103
103
|
public navigation: Navigation;
|
|
104
104
|
public meta: ZudokuContextOptions["metadata"];
|
|
105
|
-
public
|
|
105
|
+
public site: ZudokuContextOptions["site"];
|
|
106
106
|
public readonly authentication?: ZudokuContextOptions["authentication"];
|
|
107
107
|
public readonly queryClient: QueryClient;
|
|
108
108
|
public readonly options: ZudokuContextOptions;
|
|
@@ -123,7 +123,7 @@ export class ZudokuContext {
|
|
|
123
123
|
this.navigationPlugins = this.plugins.filter(isNavigationPlugin);
|
|
124
124
|
this.authentication = this.plugins.find(isAuthenticationPlugin);
|
|
125
125
|
this.meta = options.metadata;
|
|
126
|
-
this.
|
|
126
|
+
this.site = options.site;
|
|
127
127
|
this.plugins.forEach((plugin) => {
|
|
128
128
|
if (!isEventConsumerPlugin(plugin)) return;
|
|
129
129
|
|