Skip to content
This repository was archived by the owner on Sep 22, 2024. It is now read-only.

Commit c2440c5

Browse files
committed
0.5.104
1 parent b548ec4 commit c2440c5

File tree

4 files changed

+16
-9
lines changed

4 files changed

+16
-9
lines changed

Diff for: lib/cli/src/version.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// latest version of netzo/cli (see https://github.com/netzo/netzo/releases)
2-
export const VERSION = "0.5.103";
2+
export const VERSION = "0.5.104";
33

44
// minimum version of Deno required to run this CLI
55
// (see https://github.com/denoland/deployctl/blob/main/src/version.ts)

Diff for: lib/components/blocks/plot.tsx

+13-6
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import { type Signal } from "@preact/signals-core";
2+
import { IS_BROWSER } from "fresh/runtime.ts";
23
import { createElement as h } from "preact";
34
import { useEffect, useRef } from "preact/compat";
45
import * as Plot from "../../deps/@observablehq/plot.ts";
@@ -19,13 +20,19 @@ export * from "../../deps/@observablehq/plot.ts";
1920
*/
2021
export function Figure({ options }: { options: Plot.PlotOptions }) {
2122
const containerRef = useRef();
23+
// replace client-side rendered plot with client-side (hydrated) plot entirely
2224

23-
// client-side: uses a real DOM container and the usePlot() hook for mounting
24-
useEffect(() => {
25-
// replace server-side rendered plot with client-side (hydrated) plot entirely
26-
const plot = Plot.plot(options);
27-
containerRef.current = plot;
28-
}, [options]);
25+
if (IS_BROWSER) {
26+
useEffect(() => {
27+
// FIXME: use something like .replaceWith() instead of .append()/.remove() to avoid
28+
// flickering on first client-side render without breaking hydration (e.g. tooltips)
29+
const plot = Plot.plot(options);
30+
containerRef.current.append(plot);
31+
return () => plot.remove();
32+
}, [options]);
33+
34+
return <figure ref={containerRef} />;
35+
}
2936

3037
// server-side: uses a virtual Document implementation to generate HTML
3138
return (

Diff for: lib/plugins/auth/plugin.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@ import type { FreshContext, Plugin, PluginRoute } from "fresh/server.ts";
22
import { HTMLAttributes } from "preact/compat";
33
import type { NetzoState } from "../../mod.ts";
44
import {
5-
NetzoStateWithAuth,
65
assertUserIsMemberOfWorkspaceOfApiKeyIfProviderIsNetzo,
76
createAssertUserIsAuthorized,
87
createAuthState,
98
ensureSignedIn,
9+
NetzoStateWithAuth,
1010
setRequestState,
1111
setSessionState,
1212
} from "./middlewares/mod.ts";

Diff for: lib/plugins/unocss/preset-shadcn/mod.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -735,7 +735,7 @@ export function presetShadcn(options: PresetShadcnOptions = {}): Preset<Theme> {
735735
"relative",
736736
"flex-1",
737737
"rounded-full",
738-
"bg-border"
738+
"bg-border",
739739
],
740740
// select:
741741
...[

0 commit comments

Comments
 (0)