@diagonal-hq/pages 0.4.0 → 0.5.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.
Files changed (2) hide show
  1. package/dist/index.d.ts +2 -13
  2. package/package.json +1 -1
package/dist/index.d.ts CHANGED
@@ -6542,7 +6542,7 @@ export type SdkHooks = {
6542
6542
  * Keys are isolated from the app's other React Query caches. Begin a key with
6543
6543
  * `'records'` when the endpoint's result depends on resource records, for example
6544
6544
  * `['records', resource.id, 'summary']`; successful resource create/update/delete/restore
6545
- * operations and record form submits then invalidate it automatically. Other keys refresh only through their
6545
+ * operations then invalidate it automatically. Other keys refresh only through their
6546
6546
  * returned `invalidate` function.
6547
6547
  *
6548
6548
  * Keep the key the same between renders. A clock read such as `Date.now()` in the key
@@ -7781,9 +7781,6 @@ export type SdkHooks = {
7781
7781
  * `form.errors` contains only 422 field validation. Other failures are available
7782
7782
  * as `form.failure`; for example, branch on
7783
7783
  * `Sdk.utils.error.isConflict(form.failure)` without inspecting status codes.
7784
- * A successful submit refreshes no other page data. Call the `invalidate()` of the
7785
- * data that the workflow changed in `onSuccess`, or `Sdk.hooks.useInvalidateAll()`
7786
- * when the page cannot name it.
7787
7784
  * Success callbacks receive the parsed workflow body directly. Synchronous
7788
7785
  * output can be a scalar, list, record, or object; asynchronous workflows return
7789
7786
  * `{ execution_id }`. Narrow the value before reading authored output fields.
@@ -7869,12 +7866,6 @@ export type SdkHooks = {
7869
7866
  * `reset()` also starts a fresh key lifecycle. The hook does not poll asynchronous
7870
7867
  * executions.
7871
7868
  *
7872
- * A successful run refreshes no other page data. When the workflow changes data that
7873
- * the page shows, call that data's `invalidate()` in `onSuccess`. Use
7874
- * `Sdk.hooks.useInvalidateAll()` only when the page cannot name what changed. A
7875
- * workflow that only reads, such as a search called inside a `Sdk.hooks.useApi`
7876
- * fetcher, needs no `onSuccess`.
7877
- *
7878
7869
  * @example
7879
7870
  * ```tsx
7880
7871
  * function ReserveButton({ slotId }) {
@@ -14248,9 +14239,7 @@ export type WorkflowFormProps = {
14248
14239
  * suppress. */
14249
14240
  successMessage?: string | null;
14250
14241
 
14251
- /** Called after a successful submission with the workflow's response payload. A
14252
- * submission refreshes no other page data, so call the `invalidate()` of the data
14253
- * that the workflow changed here. */
14242
+ /** Called after a successful submission with the workflow's response payload. */
14254
14243
  onSuccess?: (response: SdkWorkflowResponse) => void;
14255
14244
 
14256
14245
  /** Called when the submission resolves with a non-2xx response, with
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@diagonal-hq/pages",
3
- "version": "0.4.0",
3
+ "version": "0.5.0",
4
4
  "description": "The Page SDK for the pages of file-based Diagonal workspaces.",
5
5
  "license": "SEE LICENSE IN LICENSE",
6
6
  "repository": {