@krak-stack/assets 0.1.6 → 0.1.7

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/CHANGELOG.md CHANGED
@@ -1,5 +1,19 @@
1
1
  # @krak-stack/assets
2
2
 
3
+ ## 0.1.7
4
+
5
+ ### Patch Changes
6
+
7
+ - Share asset library query wiring across React and Effect UI HTML. React reads query snapshots directly while preserving the existing asset library API and refreshing the list after publish or delete.
8
+ - Updated dependencies
9
+ - Updated dependencies
10
+ - Updated dependencies
11
+ - Updated dependencies
12
+ - Updated dependencies
13
+ - Updated dependencies
14
+ - Updated dependencies
15
+ - @krak-stack/registry@0.11.10
16
+
3
17
  ## 0.1.6
4
18
 
5
19
  ### Patch Changes
package/README.md CHANGED
@@ -237,7 +237,7 @@ const libraryLayer = assetLibraryLayer.pipe(Layer.provide(assetsClientLayer)); /
237
237
 
238
238
  - **React:** Pass `{ runtime, access }` to either component. For example,
239
239
  `<AssetTable runtime={runtime} access={access} />`. For a picker, also
240
- pass `label`, `value`, and `onChange`. The components use `useModel`;
240
+ pass `label`, `value`, and `onChange`. The components use `useView`;
241
241
  no app-owned asset atoms are needed. Dashboard consumers can use
242
242
  `useAssetLibrary` from `@krak-stack/assets/asset-table/react`.
243
243
  - **Effect UI HTML:** Provide `libraryLayer` to the parent with
@@ -1,5 +1,5 @@
1
1
  import { Redacted } from "effect";
2
- import { AssetLibraryActions, AssetList } from "../../services/assets/library.js";
2
+ import { AssetLibraryActions } from "../../services/assets/library.js";
3
3
  import { Component } from "effect/ui";
4
4
  import { Html } from "effect/ui/html";
5
5
  export { AssetInputEvents, RunAssetUpload, AssetUploadResult, assetUploadLayer, } from "./index.js";
@@ -67,4 +67,6 @@ export declare const AssetInput: Component.Component<"AssetInputConnection", {
67
67
  readonly _tag: "Published";
68
68
  readonly assetId: string;
69
69
  readonly file: Redacted.Redacted<File>;
70
- }, AssetLibraryActions | AssetList | import("./index.js").RunAssetUpload, Html.Elements, {}, "uploadAction">;
70
+ }, AssetLibraryActions | import("../../services/assets/library.js").AssetList | import("./index.js").RunAssetUpload, Html.Elements, {
71
+ readonly library: Component.QueryOne<typeof import("../../services/assets/library.js").AssetList>;
72
+ }, "uploadAction">;