@ekanos/harness 0.27.0 → 0.29.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/README.md +6 -4
- package/dist/internal/components/approvals-tray.d.ts +44 -6
- package/dist/internal/components/approvals-tray.js +252 -30
- package/dist/internal/components/ask-assistant-bridge.js +7 -1
- package/dist/internal/components/connect-controls.js +4 -2
- package/dist/internal/components/connect-dialog.d.ts +8 -1
- package/dist/internal/components/connect-dialog.js +23 -10
- package/dist/internal/components/connect-panel.d.ts +3 -2
- package/dist/internal/components/connect-panel.js +680 -340
- package/dist/internal/components/connect-steps.d.ts +72 -0
- package/dist/internal/components/connect-steps.js +341 -0
- package/dist/internal/components/console-not-found.d.ts +14 -0
- package/dist/internal/components/console-not-found.js +57 -0
- package/dist/internal/components/dashboard-grid.d.ts +10 -5
- package/dist/internal/components/dashboard-grid.js +8 -9
- package/dist/internal/components/dev-toolbar.d.ts +27 -5
- package/dist/internal/components/dev-toolbar.js +214 -176
- package/dist/internal/components/ekanos-logo.d.ts +18 -0
- package/dist/internal/components/ekanos-logo.js +74 -0
- package/dist/internal/components/events-panel.d.ts +13 -4
- package/dist/internal/components/events-panel.js +478 -81
- package/dist/internal/components/harness-widget-provider.d.ts +6 -8
- package/dist/internal/components/harness-widget-provider.js +5 -19
- package/dist/internal/components/health-panel.d.ts +8 -1
- package/dist/internal/components/health-panel.js +328 -31
- package/dist/internal/components/integration-badge.js +4 -2
- package/dist/internal/components/integration-tab-skeletons.d.ts +8 -0
- package/dist/internal/components/integration-tab-skeletons.js +76 -0
- package/dist/internal/components/not-found-state.d.ts +39 -0
- package/dist/internal/components/not-found-state.js +127 -0
- package/dist/internal/components/operation-runner-panel.d.ts +1 -1
- package/dist/internal/components/operation-runner-panel.js +624 -189
- package/dist/internal/components/operation-scope.d.ts +13 -0
- package/dist/internal/components/operation-scope.js +79 -0
- package/dist/internal/components/page-skeletons.d.ts +11 -0
- package/dist/internal/components/page-skeletons.js +61 -0
- package/dist/internal/components/provenance-banner.d.ts +13 -4
- package/dist/internal/components/provenance-banner.js +35 -10
- package/dist/internal/components/run-log-copy.d.ts +17 -0
- package/dist/internal/components/run-log-copy.js +67 -0
- package/dist/internal/components/run-log-detail.d.ts +22 -0
- package/dist/internal/components/run-log-detail.js +295 -0
- package/dist/internal/components/run-log-empty.d.ts +13 -0
- package/dist/internal/components/run-log-empty.js +46 -0
- package/dist/internal/components/run-log.d.ts +23 -3
- package/dist/internal/components/run-log.js +384 -130
- package/dist/internal/components/runtime-strip.d.ts +5 -1
- package/dist/internal/components/runtime-strip.js +82 -5
- package/dist/internal/components/schema-form.d.ts +2 -1
- package/dist/internal/components/schema-form.js +212 -79
- package/dist/internal/components/scrollable-nav.js +14 -2
- package/dist/internal/components/segmented-control.d.ts +19 -0
- package/dist/internal/components/segmented-control.js +46 -0
- package/dist/internal/components/shell-header.d.ts +25 -0
- package/dist/internal/components/shell-header.js +126 -0
- package/dist/internal/components/surface-nav.d.ts +12 -4
- package/dist/internal/components/surface-nav.js +79 -80
- package/dist/internal/components/widget-surface.d.ts +5 -1
- package/dist/internal/components/widget-surface.js +86 -14
- package/dist/internal/components/workflow-runner.d.ts +23 -10
- package/dist/internal/components/workflow-runner.js +451 -69
- package/dist/internal/lib/connect-model.d.ts +134 -0
- package/dist/internal/lib/connect-model.js +282 -0
- package/dist/internal/lib/connection-facts.js +2 -1
- package/dist/internal/lib/console-client.js +5 -2
- package/dist/internal/lib/console-hooks.d.ts +4 -1
- package/dist/internal/lib/console-hooks.js +3 -2
- package/dist/internal/lib/console-types.d.ts +6 -0
- package/dist/internal/lib/docs-links.d.ts +27 -0
- package/dist/internal/lib/docs-links.js +55 -1
- package/dist/internal/lib/event-delivery.d.ts +33 -0
- package/dist/internal/lib/event-delivery.js +66 -0
- package/dist/internal/lib/font-files/OFL-BricolageGrotesque.txt +93 -0
- package/dist/internal/lib/font-files/OFL-Figtree.txt +93 -0
- package/dist/internal/lib/font-files/bricolage-grotesque-latin-variable.woff2 +0 -0
- package/dist/internal/lib/font-files/figtree-latin-variable.woff2 +0 -0
- package/dist/internal/lib/fonts.js +13 -12
- package/dist/internal/lib/health-model.d.ts +58 -0
- package/dist/internal/lib/health-model.js +140 -0
- package/dist/internal/lib/integration-console-href.d.ts +5 -0
- package/dist/internal/lib/integration-console-href.js +7 -1
- package/dist/internal/lib/oauth-setup-guide.d.ts +28 -0
- package/dist/internal/lib/oauth-setup-guide.js +35 -1
- package/dist/internal/lib/operation-catalog.d.ts +70 -0
- package/dist/internal/lib/operation-catalog.js +261 -0
- package/dist/internal/lib/overview-model.d.ts +34 -0
- package/dist/internal/lib/overview-model.js +91 -0
- package/dist/internal/lib/registry-entry.d.ts +8 -0
- package/dist/internal/lib/registry-entry.js +11 -0
- package/dist/internal/lib/repo-name.d.ts +9 -0
- package/dist/internal/lib/repo-name.js +21 -0
- package/dist/internal/lib/run-log-view.d.ts +66 -1
- package/dist/internal/lib/run-log-view.js +183 -4
- package/dist/internal/lib/runner-view.d.ts +15 -0
- package/dist/internal/lib/runner-view.js +18 -0
- package/dist/internal/lib/schema-form-model.d.ts +17 -0
- package/dist/internal/lib/schema-form-model.js +50 -0
- package/dist/internal/lib/setup-checklist.d.ts +34 -0
- package/dist/internal/lib/setup-checklist.js +79 -0
- package/dist/internal/lib/toolbar-context.d.ts +0 -1
- package/dist/internal/lib/toolbar-context.js +0 -2
- package/dist/internal/lib/toolbar-visibility.d.ts +9 -2
- package/dist/internal/lib/toolbar-visibility.js +5 -0
- package/dist/internal/lib/use-operation-effects.d.ts +7 -0
- package/dist/internal/lib/use-operation-effects.js +28 -0
- package/dist/internal/lib/use-run-log-query.d.ts +9 -0
- package/dist/internal/lib/use-run-log-query.js +35 -0
- package/dist/internal/lib/widget-grid-gaps.d.ts +18 -0
- package/dist/internal/lib/widget-grid-gaps.js +41 -0
- package/dist/internal/lib/workflow-summary.d.ts +54 -0
- package/dist/internal/lib/workflow-summary.js +147 -0
- package/dist/internal/routes/console-home-page.js +2 -1
- package/dist/internal/routes/experience-connect-page.js +46 -17
- package/dist/internal/routes/experience-layout-page.d.ts +6 -6
- package/dist/internal/routes/experience-layout-page.js +3 -119
- package/dist/internal/routes/experience-page-host.js +61 -5
- package/dist/internal/routes/experience-pages-page.d.ts +5 -0
- package/dist/internal/routes/experience-pages-page.js +118 -0
- package/dist/internal/routes/experience-review-queue-page.d.ts +4 -1
- package/dist/internal/routes/experience-review-queue-page.js +108 -12
- package/dist/internal/routes/experience-runs-page.js +57 -4
- package/dist/internal/routes/experience-summary-page.d.ts +19 -0
- package/dist/internal/routes/experience-summary-page.js +212 -52
- package/dist/internal/routes/experience-widget-page.js +58 -7
- package/dist/internal/routes/experience-widgets-page.d.ts +2 -3
- package/dist/internal/routes/experience-widgets-page.js +29 -4
- package/dist/internal/routes/experience-workflow-page.js +81 -9
- package/dist/internal/routes/experience-workflows-page.js +85 -21
- package/dist/internal/routes/integration-layout.js +28 -3
- package/dist/internal/routes/integrations-connect-page.js +16 -6
- package/dist/internal/routes/integrations-events-page.js +22 -1
- package/dist/internal/routes/integrations-health-page.js +16 -1
- package/dist/internal/routes/integrations-layout.js +28 -4
- package/dist/internal/routes/integrations-list-page.d.ts +0 -1
- package/dist/internal/routes/integrations-list-page.js +11 -9
- package/dist/internal/routes/integrations-operation-page.js +53 -17
- package/dist/internal/routes/integrations-operations-page.js +539 -49
- package/dist/internal/routes/integrations-overview-page.js +332 -69
- package/dist/internal/routes/integrations-runs-page.js +53 -3
- package/dist/internal/routes/integrations-scope.d.ts +15 -2
- package/dist/internal/routes/integrations-scope.js +66 -18
- package/dist/internal/routes/preview-index-page.js +2 -2
- package/dist/internal/routes/repo-home-page.d.ts +2 -2
- package/dist/internal/routes/repo-home-page.js +429 -236
- package/dist/internal/routes/repo-layout.d.ts +12 -0
- package/dist/internal/routes/repo-layout.js +50 -38
- package/dist/internal/routes/repo-package-layouts.js +22 -8
- package/dist/internal/routes/single-widget-page.d.ts +1 -1
- package/dist/internal/routes/single-widget-page.js +28 -5
- package/dist/internal/routes/tile-page.d.ts +1 -1
- package/dist/internal/routes/tile-page.js +1 -2
- package/dist/internal/routes/widgets-page.d.ts +1 -1
- package/dist/internal/routes/widgets-page.js +5 -3
- package/dist/registry.d.ts +4 -5
- package/dist/registry.js +0 -1
- package/dist/routes.d.ts +8 -1
- package/dist/routes.js +4 -0
- package/package.json +14 -14
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
import type { ReactNode } from 'react';
|
|
2
2
|
import { type RepoClient } from '../lib/console-client.js';
|
|
3
|
+
/** The repo home's header and content column. Mount under `RepoProviders`. */
|
|
4
|
+
export declare function RepoFrame({ children }: {
|
|
5
|
+
children: ReactNode;
|
|
6
|
+
}): import("react").JSX.Element;
|
|
7
|
+
/**
|
|
8
|
+
* An `/integrations/<name>` or `/experiences/<name>` this repo has no package
|
|
9
|
+
* for, in the repo's own frame, listing the packages it does have.
|
|
10
|
+
*/
|
|
11
|
+
export declare function RepoNotFound({ kind, name, }: {
|
|
12
|
+
kind: 'integration' | 'experience';
|
|
13
|
+
name: string;
|
|
14
|
+
}): import("react").JSX.Element | null;
|
|
3
15
|
/** The layout of the repo home: `ekanos dev` at a repo root. */
|
|
4
16
|
export declare function RepoLayout({ children, client, }: {
|
|
5
17
|
children: ReactNode;
|
|
@@ -1,46 +1,23 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
-
import Link from "next/link";
|
|
4
|
-
import { usePathname } from "next/navigation";
|
|
5
3
|
import { Alert, AlertDescription } from "@ekanos/ui/alert";
|
|
6
|
-
import {
|
|
7
|
-
|
|
8
|
-
|
|
4
|
+
import {
|
|
5
|
+
NotFoundState
|
|
6
|
+
} from "../components/not-found-state.js";
|
|
7
|
+
import { PageSkeleton } from "../components/page-skeletons.js";
|
|
8
|
+
import { ShellHeader } from "../components/shell-header.js";
|
|
9
9
|
import { RepoProviders, useRepo } from "../lib/repo-context.js";
|
|
10
|
-
|
|
11
|
-
function repoName(root) {
|
|
12
|
-
return root.split(/[\\/]/).filter(Boolean).pop() ?? root;
|
|
13
|
-
}
|
|
10
|
+
import { repoName } from "../lib/repo-name.js";
|
|
14
11
|
function RepoFrame({ children }) {
|
|
15
12
|
const repo = useRepo();
|
|
16
|
-
const pathname = usePathname();
|
|
17
13
|
return /* @__PURE__ */ jsxs("div", { className: "flex min-h-screen flex-col", "data-test": "repo-frame", children: [
|
|
18
|
-
/* @__PURE__ */
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
return /* @__PURE__ */ jsxs(
|
|
26
|
-
Link,
|
|
27
|
-
{
|
|
28
|
-
href: tab.href,
|
|
29
|
-
"aria-current": active ? "page" : void 0,
|
|
30
|
-
className: cn(
|
|
31
|
-
"flex items-center gap-2 rounded-md px-3 py-2 whitespace-nowrap transition-colors",
|
|
32
|
-
FOCUS_RING,
|
|
33
|
-
active ? "bg-accent text-accent-foreground text-sm font-medium" : "text-muted-foreground hover:bg-accent text-sm"
|
|
34
|
-
),
|
|
35
|
-
children: [
|
|
36
|
-
/* @__PURE__ */ jsx(Icon, { name: tab.icon, className: "h-4 w-4" }),
|
|
37
|
-
tab.label
|
|
38
|
-
]
|
|
39
|
-
},
|
|
40
|
-
tab.href
|
|
41
|
-
);
|
|
42
|
-
}) })
|
|
43
|
-
] }),
|
|
14
|
+
/* @__PURE__ */ jsx(
|
|
15
|
+
ShellHeader,
|
|
16
|
+
{
|
|
17
|
+
title: repo.data ? repoName(repo.data.root) : "This repo",
|
|
18
|
+
kind: "repo"
|
|
19
|
+
}
|
|
20
|
+
),
|
|
44
21
|
/* @__PURE__ */ jsxs(
|
|
45
22
|
"main",
|
|
46
23
|
{
|
|
@@ -50,7 +27,10 @@ function RepoFrame({ children }) {
|
|
|
50
27
|
children: [
|
|
51
28
|
repo.isError ? /* @__PURE__ */ jsx(Alert, { variant: "destructive", "data-test": "repo-error", children: /* @__PURE__ */ jsxs(AlertDescription, { children: [
|
|
52
29
|
"Could not reach the harness server: ",
|
|
53
|
-
repo.error.message
|
|
30
|
+
repo.error.message,
|
|
31
|
+
". Check that ",
|
|
32
|
+
/* @__PURE__ */ jsx("code", { children: "ekanos dev" }),
|
|
33
|
+
" is still running, then reload."
|
|
54
34
|
] }) }) : null,
|
|
55
35
|
repo.data && repo.data.problems.length > 0 ? /* @__PURE__ */ jsx(Alert, { variant: "warning", "data-test": "repo-problems", children: /* @__PURE__ */ jsx(AlertDescription, { children: /* @__PURE__ */ jsx("ul", { className: "flex flex-col gap-1", children: repo.data.problems.map((problem) => /* @__PURE__ */ jsxs("li", { children: [
|
|
56
36
|
/* @__PURE__ */ jsx("code", { children: problem.where }),
|
|
@@ -63,6 +43,36 @@ function RepoFrame({ children }) {
|
|
|
63
43
|
)
|
|
64
44
|
] });
|
|
65
45
|
}
|
|
46
|
+
function RepoNotFound({
|
|
47
|
+
kind,
|
|
48
|
+
name
|
|
49
|
+
}) {
|
|
50
|
+
const repo = useRepo();
|
|
51
|
+
if (!repo.data) {
|
|
52
|
+
return repo.isError ? null : /* @__PURE__ */ jsx(PageSkeleton, { label: "Loading the repo" });
|
|
53
|
+
}
|
|
54
|
+
const options = kind === "integration" ? repo.data.integrations.map((row) => ({
|
|
55
|
+
label: row.name,
|
|
56
|
+
href: row.consoleHref,
|
|
57
|
+
hint: `v${row.version}`
|
|
58
|
+
})) : repo.data.experiences.map((row) => ({
|
|
59
|
+
label: row.name,
|
|
60
|
+
href: row.viewHref,
|
|
61
|
+
hint: `v${row.version}`
|
|
62
|
+
}));
|
|
63
|
+
const plural = kind === "integration" ? "integrations" : "experiences";
|
|
64
|
+
return /* @__PURE__ */ jsx(
|
|
65
|
+
NotFoundState,
|
|
66
|
+
{
|
|
67
|
+
testId: `${kind}-not-found`,
|
|
68
|
+
title: `No ${kind} called \u201C${name}\u201D`,
|
|
69
|
+
description: options.length > 0 ? `This repo has no ${kind} package named ${name}. Pick one of its ${plural}, or check the name in the address.` : `This repo has no ${plural} yet, so there is nothing at this address.`,
|
|
70
|
+
options,
|
|
71
|
+
...options.length > 0 ? { optionsLabel: `The ${plural} in this repo` } : {},
|
|
72
|
+
action: { label: "Back to the repo home", href: "/" }
|
|
73
|
+
}
|
|
74
|
+
);
|
|
75
|
+
}
|
|
66
76
|
function RepoLayout({
|
|
67
77
|
children,
|
|
68
78
|
client
|
|
@@ -70,5 +80,7 @@ function RepoLayout({
|
|
|
70
80
|
return /* @__PURE__ */ jsx(RepoProviders, { ...client ? { client } : {}, children: /* @__PURE__ */ jsx(RepoFrame, { children }) });
|
|
71
81
|
}
|
|
72
82
|
export {
|
|
73
|
-
|
|
83
|
+
RepoFrame,
|
|
84
|
+
RepoLayout,
|
|
85
|
+
RepoNotFound
|
|
74
86
|
};
|
|
@@ -1,10 +1,13 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
3
|
import { useMemo } from "react";
|
|
4
|
-
import {
|
|
4
|
+
import { useParams } from "next/navigation";
|
|
5
|
+
import { HeaderSkeleton, PageSkeleton } from "../components/page-skeletons.js";
|
|
5
6
|
import { createHttpConsoleClient, packageApiBase } from "../lib/console-client.js";
|
|
6
7
|
import { RepoProviders, useRepo } from "../lib/repo-context.js";
|
|
8
|
+
import { RepoNameProvider, repoName } from "../lib/repo-name.js";
|
|
7
9
|
import { ConsoleLayout } from "./integrations-layout.js";
|
|
10
|
+
import { RepoFrame, RepoNotFound } from "./repo-layout.js";
|
|
8
11
|
const REPO_HOME = "/";
|
|
9
12
|
function RepoExperienceLayout({
|
|
10
13
|
children,
|
|
@@ -22,8 +25,10 @@ function RepoExperienceLayout({
|
|
|
22
25
|
() => ({ experience: `/experiences/${name}`, repoHome: REPO_HOME }),
|
|
23
26
|
[name]
|
|
24
27
|
);
|
|
25
|
-
if (!surfaces)
|
|
26
|
-
|
|
28
|
+
if (!surfaces) {
|
|
29
|
+
return /* @__PURE__ */ jsx(RepoProviders, { children: /* @__PURE__ */ jsx(RepoFrame, { children: /* @__PURE__ */ jsx(RepoNotFound, { kind: "experience", name: decodeURIComponent(name) }) }) });
|
|
30
|
+
}
|
|
31
|
+
return /* @__PURE__ */ jsx(RepoProviders, { children: /* @__PURE__ */ jsx(WithRepoName, { children: /* @__PURE__ */ jsx(
|
|
27
32
|
ConsoleLayout,
|
|
28
33
|
{
|
|
29
34
|
client: resolved,
|
|
@@ -32,7 +37,11 @@ function RepoExperienceLayout({
|
|
|
32
37
|
apiBase: base,
|
|
33
38
|
children
|
|
34
39
|
}
|
|
35
|
-
);
|
|
40
|
+
) }) });
|
|
41
|
+
}
|
|
42
|
+
function WithRepoName({ children }) {
|
|
43
|
+
const repo = useRepo();
|
|
44
|
+
return /* @__PURE__ */ jsx(RepoNameProvider, { name: repo.data ? repoName(repo.data.root) : null, children });
|
|
36
45
|
}
|
|
37
46
|
function IntegrationScopeLayout({
|
|
38
47
|
children,
|
|
@@ -47,14 +56,19 @@ function IntegrationScopeLayout({
|
|
|
47
56
|
] });
|
|
48
57
|
}
|
|
49
58
|
if (!repo.data) {
|
|
50
|
-
return /* @__PURE__ */
|
|
59
|
+
return /* @__PURE__ */ jsxs("div", { className: "flex min-h-screen flex-col", children: [
|
|
60
|
+
/* @__PURE__ */ jsx(HeaderSkeleton, {}),
|
|
61
|
+
/* @__PURE__ */ jsx("main", { className: "mx-auto w-full max-w-5xl px-4 py-8 sm:px-6", children: /* @__PURE__ */ jsx(PageSkeleton, { label: "Loading the integration" }) })
|
|
62
|
+
] });
|
|
51
63
|
}
|
|
52
64
|
const own = repo.data.integrations.some((row) => row.name === slug);
|
|
53
65
|
const host = own ? null : repo.data.experiences.find(
|
|
54
66
|
(experience) => experience.integrations.some((used) => used.name === slug)
|
|
55
67
|
);
|
|
56
|
-
if (!own && !host)
|
|
57
|
-
|
|
68
|
+
if (!own && !host) {
|
|
69
|
+
return /* @__PURE__ */ jsx(RepoFrame, { children: /* @__PURE__ */ jsx(RepoNotFound, { kind: "integration", name: decodeURIComponent(slug) }) });
|
|
70
|
+
}
|
|
71
|
+
return /* @__PURE__ */ jsx(RepoNameProvider, { name: repoName(repo.data.root), children: /* @__PURE__ */ jsx(
|
|
58
72
|
ScopedConsole,
|
|
59
73
|
{
|
|
60
74
|
base: packageApiBase(
|
|
@@ -65,7 +79,7 @@ function IntegrationScopeLayout({
|
|
|
65
79
|
...client ? { client } : {},
|
|
66
80
|
children
|
|
67
81
|
}
|
|
68
|
-
);
|
|
82
|
+
) });
|
|
69
83
|
}
|
|
70
84
|
function ScopedConsole({
|
|
71
85
|
base,
|
|
@@ -1,23 +1,46 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx } from "react/jsx-runtime";
|
|
3
|
-
import { notFound } from "next/navigation";
|
|
4
3
|
import { findWidget } from "../../registry.js";
|
|
4
|
+
import { NotFoundState } from "../components/not-found-state.js";
|
|
5
5
|
import {
|
|
6
6
|
WidgetSurface,
|
|
7
7
|
withFocusedDefault
|
|
8
8
|
} from "../components/widget-surface.js";
|
|
9
|
+
import { previewHref } from "../lib/preview-sections.js";
|
|
9
10
|
import { useHarnessIntegration, useHarnessWidgetId } from "../registry-context.js";
|
|
10
11
|
function SingleWidgetPage() {
|
|
11
12
|
const integration = useHarnessIntegration();
|
|
12
13
|
const widgetId = useHarnessWidgetId();
|
|
13
|
-
if (!integration)
|
|
14
|
-
const
|
|
15
|
-
|
|
14
|
+
if (!integration) return null;
|
|
15
|
+
const id = decodeURIComponent(widgetId);
|
|
16
|
+
const widget = findWidget(integration, id);
|
|
17
|
+
const allHref = previewHref(integration.slug, "widgets");
|
|
18
|
+
if (!widget) {
|
|
19
|
+
return /* @__PURE__ */ jsx(
|
|
20
|
+
NotFoundState,
|
|
21
|
+
{
|
|
22
|
+
testId: "widget-not-found",
|
|
23
|
+
title: `No widget called \u201C${id}\u201D`,
|
|
24
|
+
description: `${integration.name} registers no widget with that id. Pick one it does register.`,
|
|
25
|
+
options: integration.widgets.map((entry) => ({
|
|
26
|
+
label: entry.id,
|
|
27
|
+
href: previewHref(
|
|
28
|
+
integration.slug,
|
|
29
|
+
`widgets/${encodeURIComponent(entry.id)}`
|
|
30
|
+
),
|
|
31
|
+
hint: entry.title
|
|
32
|
+
})),
|
|
33
|
+
...integration.widgets.length > 0 ? { optionsLabel: `The widgets ${integration.name} registers` } : {},
|
|
34
|
+
action: { label: "All widgets", href: allHref }
|
|
35
|
+
}
|
|
36
|
+
);
|
|
37
|
+
}
|
|
16
38
|
return /* @__PURE__ */ jsx("div", { className: "min-w-0", "data-test": "single-widget", children: /* @__PURE__ */ jsx(
|
|
17
39
|
WidgetSurface,
|
|
18
40
|
{
|
|
19
41
|
widgets: [withFocusedDefault(widget)],
|
|
20
|
-
productSlug: integration.slug
|
|
42
|
+
productSlug: integration.slug,
|
|
43
|
+
controls: true
|
|
21
44
|
}
|
|
22
45
|
) });
|
|
23
46
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare function TilePage(): import("react").JSX.Element;
|
|
1
|
+
export declare function TilePage(): import("react").JSX.Element | null;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
-
import { notFound } from "next/navigation";
|
|
4
3
|
import { Card } from "@ekanos/ui/card";
|
|
5
4
|
import { HARNESS_ACCOUNT_ID } from "../../registry.js";
|
|
6
5
|
import { ViewportFrame } from "../components/viewport-frame.js";
|
|
@@ -19,7 +18,7 @@ const NEIGHBOURS = [
|
|
|
19
18
|
];
|
|
20
19
|
function TilePage() {
|
|
21
20
|
const integration = useHarnessIntegration();
|
|
22
|
-
if (!integration)
|
|
21
|
+
if (!integration) return null;
|
|
23
22
|
const Tile = integration.tile;
|
|
24
23
|
return /* @__PURE__ */ jsx("div", { className: "flex min-w-0 flex-col gap-6", "data-test": "tile", children: Tile ? /* @__PURE__ */ jsx(ViewportFrame, { children: /* @__PURE__ */ jsxs("section", { className: "flex flex-col gap-4", children: [
|
|
25
24
|
/* @__PURE__ */ jsxs("header", { children: [
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare function WidgetsPage(): import("react").JSX.Element;
|
|
1
|
+
export declare function WidgetsPage(): import("react").JSX.Element | null;
|
|
@@ -1,16 +1,18 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx } from "react/jsx-runtime";
|
|
3
|
-
import { notFound } from "next/navigation";
|
|
4
3
|
import { WidgetSurface } from "../components/widget-surface.js";
|
|
4
|
+
import { previewHref } from "../lib/preview-sections.js";
|
|
5
5
|
import { useHarnessIntegration } from "../registry-context.js";
|
|
6
6
|
function WidgetsPage() {
|
|
7
7
|
const integration = useHarnessIntegration();
|
|
8
|
-
if (!integration)
|
|
8
|
+
if (!integration) return null;
|
|
9
9
|
return /* @__PURE__ */ jsx("div", { className: "min-w-0", "data-test": "widgets", children: integration.widgets.length === 0 ? /* @__PURE__ */ jsx("p", { className: "text-muted-foreground text-sm", children: "This integration registers no widgets." }) : /* @__PURE__ */ jsx(
|
|
10
10
|
WidgetSurface,
|
|
11
11
|
{
|
|
12
12
|
widgets: integration.widgets,
|
|
13
|
-
productSlug: integration.slug
|
|
13
|
+
productSlug: integration.slug,
|
|
14
|
+
controls: true,
|
|
15
|
+
widgetHref: (id) => previewHref(integration.slug, `widgets/${encodeURIComponent(id)}`)
|
|
14
16
|
}
|
|
15
17
|
) });
|
|
16
18
|
}
|
package/dist/registry.d.ts
CHANGED
|
@@ -85,6 +85,7 @@ export interface HarnessWidget {
|
|
|
85
85
|
size?: 'compact' | 'half' | 'full';
|
|
86
86
|
/** Same as an integration widget's `layouts`; the grid reads `lg.w` and `lg.maxHeight`. */
|
|
87
87
|
layouts?: WidgetLayouts;
|
|
88
|
+
/** @deprecated Ignored: widgets no longer collapse. */
|
|
88
89
|
isCollapsible?: boolean;
|
|
89
90
|
isPinnable?: boolean;
|
|
90
91
|
/** Renders the "Ask about this" AI footer bar. */
|
|
@@ -454,12 +455,10 @@ export declare function asHarnessDefinition<Schemas extends StorageSchemas>(defi
|
|
|
454
455
|
* DERIVE THE WIDGET LIST FROM THE DEFINITION YOU ALREADY WROTE
|
|
455
456
|
* ─────────────────────────────────────────────────────────────────────────────
|
|
456
457
|
*
|
|
457
|
-
* `HarnessWidget` restates `id`, `title`, `component`, `
|
|
458
|
-
* `
|
|
458
|
+
* `HarnessWidget` restates `id`, `title`, `component`, `isPinnable` and
|
|
459
|
+
* `aiFooterEnabled` — every one of which is already in
|
|
459
460
|
* `defineIntegration({ components: { widgets } })`. Writing both by hand means
|
|
460
|
-
* two declarations of the same thing with nothing detecting drift
|
|
461
|
-
* how `isCollapsible` came to be declared in one place and read from the
|
|
462
|
-
* other.
|
|
461
|
+
* two declarations of the same thing with nothing detecting drift.
|
|
463
462
|
*
|
|
464
463
|
* This derives the harness entry from the definition, so the definition stays
|
|
465
464
|
* the single source and the harness entry adds only what is genuinely
|
package/dist/registry.js
CHANGED
|
@@ -26,7 +26,6 @@ function harnessWidgetsFromDefinition(definition, overrides = {}) {
|
|
|
26
26
|
// Chrome flags come from the definition and are passed through ONLY when
|
|
27
27
|
// it declares them, so an undeclared flag still lands on the host's
|
|
28
28
|
// default rather than one invented here.
|
|
29
|
-
...widget.isCollapsible === void 0 ? {} : { isCollapsible: widget.isCollapsible },
|
|
30
29
|
...widget.isPinnable === void 0 ? {} : { isPinnable: widget.isPinnable },
|
|
31
30
|
...widget.aiFooterEnabled === void 0 ? {} : { aiFooterEnabled: widget.aiFooterEnabled },
|
|
32
31
|
...override
|
package/dist/routes.d.ts
CHANGED
|
@@ -43,8 +43,9 @@ export { TriggersPage } from './internal/routes/triggers-page.js';
|
|
|
43
43
|
* /experience ExperienceSummaryPage
|
|
44
44
|
* /experience/widgets ExperienceWidgetsPage
|
|
45
45
|
* /experience/widgets/[id] ExperienceWidgetPage
|
|
46
|
+
* /experience/pages ExperiencePagesPage
|
|
46
47
|
* /experience/pages/[id]/[...path] ExperiencePageHost
|
|
47
|
-
* /experience/layout ExperienceLayoutPage
|
|
48
|
+
* /experience/layout ExperienceLayoutPage (redirects to pages)
|
|
48
49
|
* /experience/workflows ExperienceWorkflowsPage
|
|
49
50
|
* /experience/workflows/[id] ExperienceWorkflowPage
|
|
50
51
|
* /experience/review-queue ExperienceReviewQueuePage
|
|
@@ -64,6 +65,7 @@ export { IntegrationRunsPage } from './internal/routes/integrations-runs-page.js
|
|
|
64
65
|
export { ExperienceSummaryPage } from './internal/routes/experience-summary-page.js';
|
|
65
66
|
export { ExperienceWidgetsPage } from './internal/routes/experience-widgets-page.js';
|
|
66
67
|
export { ExperienceWidgetPage } from './internal/routes/experience-widget-page.js';
|
|
68
|
+
export { ExperiencePagesPage } from './internal/routes/experience-pages-page.js';
|
|
67
69
|
export { ExperiencePageHost } from './internal/routes/experience-page-host.js';
|
|
68
70
|
export { ExperienceLayoutPage } from './internal/routes/experience-layout-page.js';
|
|
69
71
|
export { ExperienceWorkflowsPage } from './internal/routes/experience-workflows-page.js';
|
|
@@ -88,3 +90,8 @@ export { RepoHomePage } from './internal/routes/repo-home-page.js';
|
|
|
88
90
|
export { RepoConnectionsPage } from './internal/routes/repo-connections-page.js';
|
|
89
91
|
export { ExperienceConnectPage } from './internal/routes/experience-connect-page.js';
|
|
90
92
|
export { RepoExperienceLayout, RepoIntegrationLayout, } from './internal/routes/repo-package-layouts.js';
|
|
93
|
+
/**
|
|
94
|
+
* The shell's `app/not-found.tsx`: an address no route matches, in the
|
|
95
|
+
* harness's own header with a way home, instead of the framework's bare 404.
|
|
96
|
+
*/
|
|
97
|
+
export { NotFoundPage } from './internal/components/not-found-state.js';
|
package/dist/routes.js
CHANGED
|
@@ -23,6 +23,7 @@ import { IntegrationRunsPage } from "./internal/routes/integrations-runs-page.js
|
|
|
23
23
|
import { ExperienceSummaryPage } from "./internal/routes/experience-summary-page.js";
|
|
24
24
|
import { ExperienceWidgetsPage } from "./internal/routes/experience-widgets-page.js";
|
|
25
25
|
import { ExperienceWidgetPage } from "./internal/routes/experience-widget-page.js";
|
|
26
|
+
import { ExperiencePagesPage } from "./internal/routes/experience-pages-page.js";
|
|
26
27
|
import { ExperiencePageHost } from "./internal/routes/experience-page-host.js";
|
|
27
28
|
import { ExperienceLayoutPage } from "./internal/routes/experience-layout-page.js";
|
|
28
29
|
import { ExperienceWorkflowsPage } from "./internal/routes/experience-workflows-page.js";
|
|
@@ -37,6 +38,7 @@ import {
|
|
|
37
38
|
RepoExperienceLayout,
|
|
38
39
|
RepoIntegrationLayout
|
|
39
40
|
} from "./internal/routes/repo-package-layouts.js";
|
|
41
|
+
import { NotFoundPage } from "./internal/components/not-found-state.js";
|
|
40
42
|
export {
|
|
41
43
|
ActivationPage,
|
|
42
44
|
ConsoleHomePage,
|
|
@@ -44,6 +46,7 @@ export {
|
|
|
44
46
|
ExperienceConnectPage,
|
|
45
47
|
ExperienceLayoutPage,
|
|
46
48
|
ExperiencePageHost,
|
|
49
|
+
ExperiencePagesPage,
|
|
47
50
|
ExperienceReviewQueuePage,
|
|
48
51
|
ExperienceRunsPage,
|
|
49
52
|
ExperienceSummaryPage,
|
|
@@ -61,6 +64,7 @@ export {
|
|
|
61
64
|
IntegrationRunsPage,
|
|
62
65
|
IntegrationsListPage,
|
|
63
66
|
LegacyPreviewRedirect,
|
|
67
|
+
NotFoundPage,
|
|
64
68
|
PreviewIndexPage,
|
|
65
69
|
PreviewLayout,
|
|
66
70
|
RepoConnectionsPage,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ekanos/harness",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.29.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "The Ekanos integration dev harness — every surface of an integration rendered in real Ekanos chrome, from fixtures, with no Supabase or auth; and, in live mode, a real localhost OAuth loop over your own dev-app credentials.",
|
|
6
6
|
"homepage": "https://sdk.ekanos.dev/harness/overview",
|
|
@@ -72,34 +72,34 @@
|
|
|
72
72
|
"access": "public"
|
|
73
73
|
},
|
|
74
74
|
"dependencies": {
|
|
75
|
-
"@ekanos/integration-schema": "0.
|
|
75
|
+
"@ekanos/integration-schema": "0.29.0",
|
|
76
76
|
"next-themes": "0.4.6",
|
|
77
77
|
"tw-animate-css": "1.4.0"
|
|
78
78
|
},
|
|
79
79
|
"devDependencies": {
|
|
80
|
-
"@ekanos/sdk": "0.
|
|
81
|
-
"@ekanos/ui": "0.
|
|
80
|
+
"@ekanos/sdk": "0.29.0",
|
|
81
|
+
"@ekanos/ui": "0.29.0",
|
|
82
82
|
"@kit/tsconfig": "0.1.0",
|
|
83
|
-
"@tailwindcss/postcss": "4.3.
|
|
84
|
-
"@tanstack/react-query": "5.
|
|
83
|
+
"@tailwindcss/postcss": "4.3.5",
|
|
84
|
+
"@tanstack/react-query": "5.107.1",
|
|
85
85
|
"@types/node": "26.6.6",
|
|
86
86
|
"@types/react": "19.3.0",
|
|
87
87
|
"@types/react-dom": "19.3.0",
|
|
88
88
|
"jsdom": "23.0.1",
|
|
89
|
-
"next": "16.4.
|
|
90
|
-
"next-intl": "^4.
|
|
89
|
+
"next": "16.4.6",
|
|
90
|
+
"next-intl": "^4.15.1",
|
|
91
91
|
"react": "19.3.1",
|
|
92
92
|
"react-dom": "19.3.1",
|
|
93
|
-
"react-hook-form": "^7.
|
|
94
|
-
"tailwindcss": "4.3.
|
|
93
|
+
"react-hook-form": "^7.92.0",
|
|
94
|
+
"tailwindcss": "4.3.5",
|
|
95
95
|
"tsup": "9.0.0",
|
|
96
96
|
"typescript": "^7.0.2",
|
|
97
97
|
"vitest": "5.1.0",
|
|
98
98
|
"zod": "4.6.7"
|
|
99
99
|
},
|
|
100
100
|
"peerDependencies": {
|
|
101
|
-
"@ekanos/sdk": "^0.
|
|
102
|
-
"@ekanos/ui": "^0.
|
|
101
|
+
"@ekanos/sdk": "^0.29.0",
|
|
102
|
+
"@ekanos/ui": "^0.29.0",
|
|
103
103
|
"@tanstack/react-query": "^5.101.4",
|
|
104
104
|
"next": "^16.0.0",
|
|
105
105
|
"next-intl": "^4.14.7",
|
|
@@ -110,10 +110,10 @@
|
|
|
110
110
|
"zod": "^3.25.76 || ^4.0.0"
|
|
111
111
|
},
|
|
112
112
|
"ekanos": {
|
|
113
|
-
"shellContract":
|
|
113
|
+
"shellContract": 7
|
|
114
114
|
},
|
|
115
115
|
"scripts": {
|
|
116
|
-
"build": "tsup && tsc -p tsconfig.build.json && node scripts/rewrite-esm-specifiers.mjs && node scripts/build-css.mjs",
|
|
116
|
+
"build": "tsup && tsc -p tsconfig.build.json && node scripts/rewrite-esm-specifiers.mjs && node scripts/copy-fonts.mjs && node scripts/build-css.mjs",
|
|
117
117
|
"clean": "git clean -xdf .turbo node_modules dist",
|
|
118
118
|
"typecheck": "tsc --noEmit",
|
|
119
119
|
"test": "vitest run --config vitest.config.ts",
|