@jield/solodb-react-components 1.0.12 → 1.0.13

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.
@@ -1,9 +1,14 @@
1
1
  import { ServiceEventReportResult } from '@jield/solodb-typescript-core';
2
- export default function Criterion({ result, value, onChange, error, onSubmit, saving, }: {
2
+ type SaveStatusState = "idle" | "dirty" | "saving" | "saved" | "error";
3
+ type SaveStatus = {
4
+ state: SaveStatusState;
5
+ message?: string;
6
+ savedAt?: number;
7
+ };
8
+ export default function Criterion({ result, status, onAutoSave, onDirty, }: {
3
9
  result: ServiceEventReportResult;
4
- value: any;
5
- onChange: (cv: ServiceEventReportResult, raw: any) => void;
6
- error?: string;
7
- onSubmit: (cv: ServiceEventReportResult) => void;
8
- saving?: boolean;
10
+ status?: SaveStatus;
11
+ onAutoSave: (cv: ServiceEventReportResult) => void;
12
+ onDirty: (resultId: number) => void;
9
13
  }): import("react/jsx-runtime").JSX.Element;
14
+ export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jield/solodb-react-components",
3
- "version": "1.0.12",
3
+ "version": "1.0.13",
4
4
  "type": "module",
5
5
  "repository": "jield-webdev/solodb-react-components",
6
6
  "main": "./dist/index.cjs",