fix(plugins): install local plugins on packaged desktop
The plugin compiler spawned esbuild through app.asar, and the subprocess imported the React client barrel. Point esbuild at the unpacked binary, add a react-free @paseo/plugin/server entry, and pass a typed PluginTheme so plugin UI follows the active theme on desktop and mobile.
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
import { describe, expect, it } from "vitest";
|
||||
import { lightTheme } from "@/styles/theme";
|
||||
import { toPluginTheme } from "./theme";
|
||||
|
||||
describe("toPluginTheme", () => {
|
||||
it("maps the app theme into the plugin color tokens", () => {
|
||||
expect(toPluginTheme(lightTheme)).toEqual({
|
||||
colors: {
|
||||
surface0: lightTheme.colors.surface0,
|
||||
foreground: lightTheme.colors.foreground,
|
||||
foregroundMuted: lightTheme.colors.foregroundMuted,
|
||||
accent: lightTheme.colors.accent,
|
||||
accentForeground: lightTheme.colors.accentForeground,
|
||||
statusDanger: lightTheme.colors.statusDanger,
|
||||
},
|
||||
});
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user