create-vidra-app 0.6.0 → 0.6.2

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-vidra-app",
3
- "version": "0.6.0",
3
+ "version": "0.6.2",
4
4
  "description": "Scaffold a new Vidra application (React + .NET MAUI)",
5
5
  "type": "module",
6
6
  "bin": {
@@ -17,6 +17,13 @@
17
17
  <SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'android'">21.0</SupportedOSPlatformVersion>
18
18
  <DefineConstants Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'android' And '$(VidraAndroidTestRuntime)' == 'true'">$(DefineConstants);VIDRA_ANDROID_TEST_RUNTIME</DefineConstants>
19
19
  <UseMaui>true</UseMaui>
20
+ <!--
21
+ Left unset, MauiVersion is whatever the installed maui workload ships,
22
+ which can be older than the Microsoft.Maui.Controls floor that the
23
+ Vidra packages declare; restore then fails with NU1605. Keep this at or
24
+ above that floor.
25
+ -->
26
+ <MauiVersion>10.0.120</MauiVersion>
20
27
  <SingleProject>true</SingleProject>
21
28
  <ImplicitUsings>enable</ImplicitUsings>
22
29
  <Nullable>enable</Nullable>
@@ -0,0 +1,7 @@
1
+ // Auto-generated by vidra-codegen. Do not edit.
2
+
3
+ export const native = {
4
+ } as const;
5
+
6
+ export const events = {
7
+ } as const;
@@ -1,10 +1,9 @@
1
1
  // Auto-generated by vidra-codegen. Do not edit.
2
- import type { VidraClient } from "@vidra-dev/sdk";
2
+ import type { VidraBridge } from "@vidra-dev/sdk";
3
3
 
4
- export class CounterHandlers {
5
- constructor(private client: VidraClient) {}
4
+ export const createCounterHandlers = (bridge: VidraBridge) => ({
5
+ increment: (handler: () => number | Promise<number>): (() => void) =>
6
+ bridge.unsafe.handle("counter", "increment", handler),
7
+ });
6
8
 
7
- increment(handler: () => number | Promise<number>): () => void {
8
- return this.client.unsafe.handle("counter", "increment", handler);
9
- }
10
- }
9
+ export type CounterHandlers = ReturnType<typeof createCounterHandlers>;
@@ -1,9 +1,10 @@
1
1
  // Auto-generated by vidra-codegen. Do not edit.
2
- import { vidra } from "@vidra-dev/sdk";
3
- import { CounterHandlers } from "./counter.js";
2
+ import { bridge, expectations } from "@vidra-dev/sdk";
3
+ import { createCounterHandlers } from "./counter.js";
4
4
 
5
- vidra.registerGeneratedManifest("app", "d3044812d17c42049962d730fced04a6ecd711e287cdd0da7b218b327ee6cd56");
5
+ expectations.declare("app", "d3044812d17c42049962d730fced04a6ecd711e287cdd0da7b218b327ee6cd56");
6
6
 
7
- export const counterHandlers = new CounterHandlers(vidra);
7
+ export const counterHandlers = createCounterHandlers(bridge);
8
8
 
9
9
  export * from "./counter.js";
10
+ export { native, events } from "./access.js";
@@ -1,6 +1,4 @@
1
1
  // Generated by the Vidra CLI. Do not edit.
2
- import { vidra } from "@vidra-dev/sdk";
2
+ import { expectations } from "@vidra-dev/sdk";
3
3
 
4
- vidra.registerExpectedAccessFingerprint(
5
- "f8e12289e430f3ecfce80c132a8b23e9539c041a0912b7c116feae722f510f68",
6
- );
4
+ expectations.declare("access", "f8e12289e430f3ecfce80c132a8b23e9539c041a0912b7c116feae722f510f68");