@notis_ai/cli 0.2.30 → 0.2.32

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 (87) hide show
  1. package/README.md +15 -0
  2. package/config/notis_app_design_rules.json +22 -0
  3. package/dist/agent-hooks/notis-agent-hook.mjs +38244 -10823
  4. package/dist/base-skills/notis-cli/.notis-base-skill.json +1 -1
  5. package/dist/base-skills/notis-cli/references/native-databases.md +1 -1
  6. package/dist/base-skills/notis-query/.notis-base-skill.json +1 -1
  7. package/dist/base-skills/notis-query/references/query.md +6 -4
  8. package/dist/base-skills/notis-spaces/.notis-base-skill.json +1 -1
  9. package/dist/base-skills/notis-spaces/SKILL.md +12 -4
  10. package/dist/base-skills/notis-spaces/references/architecture.md +4 -1
  11. package/dist/base-skills/notis-spaces/references/design.md +7 -1
  12. package/dist/base-skills/notis-spaces/references/fixtures.md +29 -2
  13. package/dist/base-skills/notis-spaces/references/reading.md +3 -1
  14. package/dist/base-skills/notis-spaces/references/release.md +3 -1
  15. package/dist/base-skills/notis-spaces/references/sdk.md +112 -33
  16. package/dist/base-skills/notis-spaces/references/troubleshooting.md +3 -0
  17. package/dist/base-skills/notis-spaces/references/views.md +20 -0
  18. package/dist/sdk/src/hooks/useNativeDocuments.ts +50 -12
  19. package/dist/sdk/src/index.ts +1 -1
  20. package/dist/sdk/src/space.ts +3 -1
  21. package/dist/sdk/src/tailwind.ts +53 -3
  22. package/dist/sdk/src/ui/icons.tsx +18 -1
  23. package/dist/sdk/src/words/types.ts +28 -0
  24. package/dist/skill-sync/index.js +10 -90
  25. package/dist/skill-sync-worker.mjs +50 -93
  26. package/dist/space-harness/host.js +155 -82
  27. package/dist/space-sdk/dist/chunk-I4Z4UFGB.js +3 -0
  28. package/dist/space-sdk/dist/index.js +2 -2
  29. package/dist/space-sdk/dist/ui.js +12 -12
  30. package/dist/space-sdk/src/hooks/useNativeDocuments.d.ts +23 -0
  31. package/dist/space-sdk/src/index.d.ts +1 -1
  32. package/dist/space-sdk/src/space.ts +3 -1
  33. package/dist/space-sdk/src/tailwind-candidates.d.ts +315 -2
  34. package/dist/space-sdk/src/tailwind.ts +53 -3
  35. package/dist/space-sdk/src/ui/blocks/DataTable.d.ts +19 -4
  36. package/dist/space-sdk/src/ui/blocks/Meter.d.ts +12 -3
  37. package/dist/space-sdk/src/ui/blocks/Tabs.d.ts +7 -1
  38. package/dist/space-sdk/src/ui/blocks/blocks.d.ts +18 -0
  39. package/dist/space-sdk/src/ui/blocks/index.d.ts +3 -3
  40. package/dist/space-sdk/src/ui/charts/CalendarHeatmap.d.ts +69 -0
  41. package/dist/space-sdk/src/ui/charts/Chart.d.ts +18 -3
  42. package/dist/space-sdk/src/ui/charts/chartData.d.ts +19 -0
  43. package/dist/space-sdk/src/ui/charts/heatmapData.d.ts +81 -0
  44. package/dist/space-sdk/src/ui/icons.d.ts +6 -0
  45. package/dist/space-sdk/src/ui/index.d.ts +5 -3
  46. package/dist/space-sdk/src/ui/list/ListReader.d.ts +8 -0
  47. package/dist/space-sdk/src/ui/list/Row.d.ts +11 -1
  48. package/dist/space-sdk/src/ui/period/dateFormat.d.ts +2 -0
  49. package/dist/space-sdk/src/ui/period/dateWords.d.ts +9 -0
  50. package/dist/space-sdk/src/ui/period/periods.d.ts +15 -2
  51. package/dist/space-sdk/src/words/types.ts +28 -0
  52. package/dist/view-renderer/dist/host.js +224 -151
  53. package/dist/view-renderer/src/dom.js +3 -2
  54. package/dist/view-renderer/src/errors.js +9 -0
  55. package/dist/view-renderer/src/host.tsx +12 -5
  56. package/dist/view-renderer/src/remote-broker.js +3 -1
  57. package/dist/view-renderer/src/renderer.js +63 -16
  58. package/dist/view-renderer/src/skeleton.js +70 -18
  59. package/package.json +5 -4
  60. package/skills/notis-query/cli.md +3 -0
  61. package/skills/notis-spaces/cli.md +14 -0
  62. package/src/command-specs/spaces.js +138 -15
  63. package/src/command-specs/tools.js +3 -0
  64. package/src/runtime/api-hosts.generated.js +35 -0
  65. package/src/runtime/api-hosts.js +27 -10
  66. package/src/runtime/app-boundary-validator.js +248 -3
  67. package/src/runtime/app-data-literals.js +32 -23
  68. package/src/runtime/app-platform.js +68 -24
  69. package/src/runtime/http-agent.js +53 -0
  70. package/src/runtime/native-record-files.js +11 -0
  71. package/src/runtime/oauth.js +2 -1
  72. package/src/runtime/skill-sync/cloud-client.ts +0 -10
  73. package/src/runtime/skill-sync/index.ts +13 -15
  74. package/src/runtime/skill-sync/local-scanner.ts +0 -67
  75. package/src/runtime/skill-sync/types.ts +1 -0
  76. package/src/runtime/skill-sync/write-cloud-skill.ts +7 -23
  77. package/src/runtime/space-dependencies.js +66 -0
  78. package/src/runtime/space-fixture-broker.js +23 -8
  79. package/src/runtime/space-platform.js +47 -3
  80. package/src/runtime/space-source.js +10 -1
  81. package/src/runtime/space-test-server.js +124 -6
  82. package/src/runtime/space-verification.js +103 -43
  83. package/src/runtime/space-view-manifest.js +38 -5
  84. package/src/runtime/transport.js +19 -4
  85. package/src/runtime/view-render.js +4 -1
  86. package/template/tailwind.config.ts +2 -35
  87. package/dist/space-sdk/dist/chunk-6GJ2BS7B.js +0 -3
@@ -23,6 +23,29 @@ export declare function useNativeDocuments(binding: string, options?: {
23
23
  schemaRevision?: number;
24
24
  live: boolean;
25
25
  };
26
+ /** What a count reads: the rows its filter keeps, archived ones too when asked. */
27
+ export type NativeCountQuery = Pick<NativeQuery, 'filter' | 'include_archived'>;
28
+ /**
29
+ * How many rows of a database binding match `query.filter`, read with the native query's `mode: 'count'` through the
30
+ * same declared query action as `useNativeDocuments`: no row is loaded. `count` is undefined until the first answer;
31
+ * `loading`, `isFetching` and `error` behave as in every `useQuery` read. When the filter changes, the last count
32
+ * stays shown (`isPreviousData` true) until the new one is read; a new binding starts empty instead. A write
33
+ * refreshes it once confirmed, never before: an optimistic row does not move the count. `subscribe` follows the live
34
+ * change feed as in `useNativeDocuments`.
35
+ */
36
+ export declare function useNativeCount(binding: string, options?: {
37
+ query?: NativeCountQuery;
38
+ enabled?: boolean;
39
+ staleTimeMs?: number;
40
+ subscribe?: boolean;
41
+ }): UseQueryResult<{
42
+ count: number;
43
+ schemaRevision: number;
44
+ }> & {
45
+ count?: number;
46
+ schemaRevision?: number;
47
+ live: boolean;
48
+ };
26
49
  /** Options of one native write. */
27
50
  export interface NativeMutationOptions {
28
51
  schemaRevision: number;
@@ -9,7 +9,7 @@
9
9
  export { NotisProvider, useNotisRuntime } from './provider';
10
10
  export { useAction, useActionQuery } from './hooks/useAction';
11
11
  export type { UseActionQueryOptions } from './hooks/useAction';
12
- export { useNativeDocuments, useNativeMutation, useNativeDelete, type NativeDeleteManyResult, type NativeMutationOptions } from './hooks/useNativeDocuments';
12
+ export { useNativeDocuments, useNativeCount, useNativeMutation, useNativeDelete, type NativeCountQuery, type NativeDeleteManyResult, type NativeMutationOptions } from './hooks/useNativeDocuments';
13
13
  export type { NativeField, NativeFilter, NativeQuery, NativeInsert, NativeUpdate, NativeDelete, NativeMutationReceipt } from './nativeData';
14
14
  export type { SpaceDatabaseCreate, SpaceResourceReference } from './space';
15
15
  export type { SpaceActionTemplate, SpaceActionDescriptor, SpaceRuntimeDescriptor, SpaceActionOptions } from './space';
@@ -897,7 +897,9 @@ export interface SpaceActionFailureDetails {
897
897
  pendingRequestIds?: string[];
898
898
  /**
899
899
  * Why a settled action failed, when the host knows a stable reason: `read_timeout` (a read its time limit stopped)
900
- * or `rate_limited` (the provider refused the call for sending too fast; it did not run, so retry after a few seconds).
900
+ * or `rate_limited` (the provider refused the call for sending too fast; it did not run, so retry after a few seconds)
901
+ * or `connection_unavailable` (the connection the action runs through is not usable as saved: a retry never clears it;
902
+ * the Editor who published the Space reconnects that integration, or publishes the Space again).
901
903
  */
902
904
  code?: string;
903
905
  }