@honua/react 0.1.2-beta.0 → 0.1.4-beta.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 (281) hide show
  1. package/contract/discovery.d.ts +34 -0
  2. package/contract/discovery.d.ts.map +1 -1
  3. package/contract/index.d.ts +7 -5
  4. package/contract/index.d.ts.map +1 -1
  5. package/contract/index.js +3 -2
  6. package/contract/pmtiles.d.ts +10 -1
  7. package/contract/pmtiles.d.ts.map +1 -1
  8. package/contract/pmtiles.js +10 -2
  9. package/contract/protocol-module.d.ts +84 -9
  10. package/contract/protocol-module.d.ts.map +1 -1
  11. package/contract/query-filter-fes.d.ts +18 -0
  12. package/contract/query-filter-fes.d.ts.map +1 -0
  13. package/contract/query-filter-fes.js +122 -0
  14. package/contract/query-filter.d.ts +300 -0
  15. package/contract/query-filter.d.ts.map +1 -0
  16. package/contract/query-filter.js +883 -0
  17. package/contract/schema.d.ts +12 -0
  18. package/contract/schema.d.ts.map +1 -1
  19. package/contract/schema.js +34 -0
  20. package/contract/source-capability-support.d.ts.map +1 -1
  21. package/contract/source-capability-support.js +15 -3
  22. package/contract/source.d.ts +45 -25
  23. package/contract/source.d.ts.map +1 -1
  24. package/contract/source.js +719 -479
  25. package/contract/types.d.ts +87 -18
  26. package/contract/types.d.ts.map +1 -1
  27. package/contract/widget-source.d.ts.map +1 -1
  28. package/core/client.d.ts +45 -21
  29. package/core/client.d.ts.map +1 -1
  30. package/core/client.js +224 -46
  31. package/core/error-classifications.d.ts +6 -0
  32. package/core/error-classifications.d.ts.map +1 -1
  33. package/core/error-classifications.js +6 -0
  34. package/core/error-code-registry.d.ts +6 -0
  35. package/core/error-code-registry.d.ts.map +1 -1
  36. package/core/error-code-registry.js +6 -0
  37. package/core/error-envelope.js +2 -0
  38. package/core/errors.d.ts +1 -1
  39. package/core/errors.js +1 -1
  40. package/core/geoparquet-sql.d.ts +68 -4
  41. package/core/geoparquet-sql.d.ts.map +1 -1
  42. package/core/geoparquet-sql.js +325 -8
  43. package/core/odata-write-codec.d.ts.map +1 -1
  44. package/core/odata-write-codec.js +0 -1
  45. package/core/odata.d.ts +6 -0
  46. package/core/odata.d.ts.map +1 -1
  47. package/core/odata.js +6 -1
  48. package/core/ogc-processes.d.ts +182 -25
  49. package/core/ogc-processes.d.ts.map +1 -1
  50. package/core/ogc-processes.js +602 -30
  51. package/core/process-runner.d.ts +8 -1
  52. package/core/process-runner.d.ts.map +1 -1
  53. package/core/process-runner.js +1 -0
  54. package/core/protocol-transport.d.ts +2 -0
  55. package/core/protocol-transport.d.ts.map +1 -1
  56. package/core/stac.d.ts +31 -0
  57. package/core/stac.d.ts.map +1 -1
  58. package/core/stac.js +136 -19
  59. package/core/surfaces.d.ts.map +1 -1
  60. package/core/surfaces.js +273 -68
  61. package/core/types.d.ts +123 -9
  62. package/core/types.d.ts.map +1 -1
  63. package/core/wfs-axis-order.d.ts +18 -0
  64. package/core/wfs-axis-order.d.ts.map +1 -0
  65. package/core/wfs-axis-order.js +108 -0
  66. package/core/wfs-capabilities.d.ts +65 -24
  67. package/core/wfs-capabilities.d.ts.map +1 -1
  68. package/core/wfs-capabilities.js +237 -27
  69. package/core/wfs-filter.d.ts +26 -3
  70. package/core/wfs-filter.d.ts.map +1 -1
  71. package/core/wfs-filter.js +48 -53
  72. package/core/wfs-protocol-error.d.ts +12 -0
  73. package/core/wfs-protocol-error.d.ts.map +1 -0
  74. package/core/wfs-protocol-error.js +13 -0
  75. package/core/wfs.d.ts +53 -1
  76. package/core/wfs.d.ts.map +1 -1
  77. package/core/wfs.js +251 -29
  78. package/core/wms-feature-info.d.ts +92 -0
  79. package/core/wms-feature-info.d.ts.map +1 -0
  80. package/core/wms-feature-info.js +285 -0
  81. package/core/wms.d.ts +9 -0
  82. package/core/wms.d.ts.map +1 -1
  83. package/core/wms.js +17 -5
  84. package/esri-compat/event-bus.d.ts +20 -0
  85. package/esri-compat/event-bus.d.ts.map +1 -1
  86. package/esri-compat/feature-filter.d.ts +46 -1
  87. package/esri-compat/feature-filter.d.ts.map +1 -1
  88. package/esri-compat/feature-filter.js +49 -0
  89. package/esri-compat/geojson-layer.d.ts +4 -2
  90. package/esri-compat/geojson-layer.d.ts.map +1 -1
  91. package/esri-compat/geojson-layer.js +4 -2
  92. package/esri-compat/identity-manager.js +2 -2
  93. package/esri-compat/imagery-layer.d.ts +2 -1
  94. package/esri-compat/imagery-layer.d.ts.map +1 -1
  95. package/esri-compat/imagery-layer.js +2 -1
  96. package/esri-compat/layer-list.d.ts +8 -1
  97. package/esri-compat/layer-list.d.ts.map +1 -1
  98. package/esri-compat/layer-list.js +11 -4
  99. package/esri-compat/legend.d.ts.map +1 -1
  100. package/esri-compat/legend.js +1 -1
  101. package/esri-compat/locator.d.ts +297 -0
  102. package/esri-compat/locator.d.ts.map +1 -0
  103. package/esri-compat/locator.js +579 -0
  104. package/esri-compat/map-image-layer.d.ts.map +1 -1
  105. package/esri-compat/map-view.d.ts.map +1 -1
  106. package/esri-compat/map-view.js +1 -1
  107. package/esri-compat/scene-view.d.ts.map +1 -1
  108. package/esri-compat/time-slider.d.ts +29 -0
  109. package/esri-compat/time-slider.d.ts.map +1 -1
  110. package/esri-compat/time-slider.js +117 -0
  111. package/esri-compat/wfs-layer.d.ts +2 -1
  112. package/esri-compat/wfs-layer.d.ts.map +1 -1
  113. package/esri-compat/wfs-layer.js +2 -1
  114. package/esri-compat/widget-host.d.ts +42 -6
  115. package/esri-compat/widget-host.d.ts.map +1 -1
  116. package/esri-compat/widget-host.js +99 -10
  117. package/generated-app/projection.d.ts.map +1 -1
  118. package/generated-app/runtime.d.ts.map +1 -1
  119. package/map/data-to-map-bridge.d.ts +1 -1
  120. package/map/data-to-map-bridge.d.ts.map +1 -1
  121. package/map/data-to-map-bridge.js +1 -2
  122. package/map/honua-map.d.ts.map +1 -1
  123. package/map/honua-map.js +1 -1
  124. package/map/index.d.ts +2 -0
  125. package/map/index.d.ts.map +1 -1
  126. package/map/index.js +2 -0
  127. package/map/realtime-reconciliation-adapter.d.ts +98 -0
  128. package/map/realtime-reconciliation-adapter.d.ts.map +1 -0
  129. package/map/realtime-reconciliation-adapter.js +84 -0
  130. package/map/temporal-playback.d.ts +25 -0
  131. package/map/temporal-playback.d.ts.map +1 -1
  132. package/map/temporal-playback.js +29 -1
  133. package/package.json +4 -3
  134. package/query-planner/canonical-filter.d.ts +30 -0
  135. package/query-planner/canonical-filter.d.ts.map +1 -0
  136. package/query-planner/canonical-filter.js +30 -0
  137. package/query-planner/columnar-plan.d.ts +63 -0
  138. package/query-planner/columnar-plan.d.ts.map +1 -0
  139. package/query-planner/columnar-plan.js +94 -0
  140. package/query-planner/diagnostics.d.ts +3 -3
  141. package/query-planner/diagnostics.d.ts.map +1 -1
  142. package/query-planner/diagnostics.js +17 -4
  143. package/query-planner/duckdb.d.ts.map +1 -1
  144. package/query-planner/duckdb.js +16 -2
  145. package/query-planner/execution-context.d.ts.map +1 -1
  146. package/query-planner/execution-context.js +3 -1
  147. package/query-planner/executor.d.ts.map +1 -1
  148. package/query-planner/executor.js +7 -1
  149. package/query-planner/geoservices.d.ts.map +1 -1
  150. package/query-planner/geoservices.js +24 -5
  151. package/query-planner/grpc.d.ts.map +1 -1
  152. package/query-planner/grpc.js +29 -5
  153. package/query-planner/index.d.ts +20 -5
  154. package/query-planner/index.d.ts.map +1 -1
  155. package/query-planner/index.js +16 -3
  156. package/query-planner/ir.d.ts +6 -1
  157. package/query-planner/ir.d.ts.map +1 -1
  158. package/query-planner/ir.js +63 -1
  159. package/query-planner/odata-protocol-module.d.ts +54 -0
  160. package/query-planner/odata-protocol-module.d.ts.map +1 -0
  161. package/query-planner/odata-protocol-module.js +199 -0
  162. package/query-planner/odata-v1.d.ts +23 -0
  163. package/query-planner/odata-v1.d.ts.map +1 -0
  164. package/query-planner/odata-v1.js +202 -0
  165. package/query-planner/odata.d.ts +0 -3
  166. package/query-planner/odata.d.ts.map +1 -1
  167. package/query-planner/odata.js +0 -143
  168. package/query-planner/ogc-features.d.ts.map +1 -1
  169. package/query-planner/ogc-features.js +23 -1
  170. package/query-planner/planner.d.ts +2 -2
  171. package/query-planner/planner.d.ts.map +1 -1
  172. package/query-planner/planner.js +146 -27
  173. package/query-planner/representation.d.ts +59 -0
  174. package/query-planner/representation.d.ts.map +1 -0
  175. package/query-planner/representation.js +140 -0
  176. package/query-planner/types.d.ts +153 -3
  177. package/query-planner/types.d.ts.map +1 -1
  178. package/query-planner/wfs-protocol-module.d.ts +57 -0
  179. package/query-planner/wfs-protocol-module.d.ts.map +1 -0
  180. package/query-planner/wfs-protocol-module.js +731 -0
  181. package/query-planner/wfs-v1.d.ts +41 -0
  182. package/query-planner/wfs-v1.d.ts.map +1 -0
  183. package/query-planner/wfs-v1.js +366 -0
  184. package/query-planner/wfs.d.ts +1 -3
  185. package/query-planner/wfs.d.ts.map +1 -1
  186. package/query-planner/wfs.js +1 -70
  187. package/react/honua-map.d.ts +3 -1
  188. package/react/honua-map.d.ts.map +1 -1
  189. package/react/honua-map.js +11 -1
  190. package/react/hooks.d.ts +1 -1
  191. package/react/hooks.js +1 -1
  192. package/react/selection.d.ts.map +1 -1
  193. package/react/selection.js +0 -0
  194. package/react/use-mounted-source.d.ts +1 -1
  195. package/react/use-mounted-source.js +1 -1
  196. package/realtime/checkpoint-store.d.ts +206 -0
  197. package/realtime/checkpoint-store.d.ts.map +1 -0
  198. package/realtime/checkpoint-store.js +504 -0
  199. package/realtime/contract.d.ts +142 -0
  200. package/realtime/contract.d.ts.map +1 -0
  201. package/realtime/contract.js +154 -0
  202. package/realtime/exploration.d.ts +16 -0
  203. package/realtime/exploration.d.ts.map +1 -0
  204. package/realtime/exploration.js +32 -0
  205. package/realtime/honua-server.d.ts +131 -0
  206. package/realtime/honua-server.d.ts.map +1 -0
  207. package/realtime/honua-server.js +302 -0
  208. package/realtime/index.d.ts +39 -0
  209. package/realtime/index.d.ts.map +1 -0
  210. package/realtime/index.js +26 -0
  211. package/realtime/odata-delta.d.ts +114 -0
  212. package/realtime/odata-delta.d.ts.map +1 -0
  213. package/realtime/odata-delta.js +483 -0
  214. package/realtime/projections.d.ts +30 -0
  215. package/realtime/projections.d.ts.map +1 -0
  216. package/realtime/projections.js +51 -0
  217. package/realtime/reconciliation.d.ts +245 -0
  218. package/realtime/reconciliation.d.ts.map +1 -0
  219. package/realtime/reconciliation.js +377 -0
  220. package/realtime/reducer.d.ts +14 -0
  221. package/realtime/reducer.d.ts.map +1 -0
  222. package/realtime/reducer.js +351 -0
  223. package/realtime/resumable-transport.d.ts +111 -0
  224. package/realtime/resumable-transport.d.ts.map +1 -0
  225. package/realtime/resumable-transport.js +406 -0
  226. package/realtime/resumable.d.ts +104 -0
  227. package/realtime/resumable.d.ts.map +1 -0
  228. package/realtime/resumable.js +632 -0
  229. package/realtime/sse.d.ts +23 -0
  230. package/realtime/sse.d.ts.map +1 -0
  231. package/realtime/sse.js +147 -0
  232. package/realtime/store.d.ts +18 -0
  233. package/realtime/store.d.ts.map +1 -0
  234. package/realtime/store.js +63 -0
  235. package/realtime/types.d.ts +190 -0
  236. package/realtime/types.d.ts.map +1 -0
  237. package/realtime/types.js +10 -0
  238. package/realtime/websocket.d.ts +60 -0
  239. package/realtime/websocket.d.ts.map +1 -0
  240. package/realtime/websocket.js +157 -0
  241. package/realtime/wire.d.ts +28 -0
  242. package/realtime/wire.d.ts.map +1 -0
  243. package/realtime/wire.js +73 -0
  244. package/runtime/index.d.ts +6 -2
  245. package/runtime/index.d.ts.map +1 -1
  246. package/runtime/index.js +3 -1
  247. package/runtime/load-package.d.ts +24 -0
  248. package/runtime/load-package.d.ts.map +1 -1
  249. package/runtime/load-package.js +45 -1
  250. package/runtime/maplibre-renderer.d.ts +11 -0
  251. package/runtime/maplibre-renderer.d.ts.map +1 -1
  252. package/runtime/maplibre-renderer.js +32 -7
  253. package/runtime/offline-region-protocol.d.ts +73 -0
  254. package/runtime/offline-region-protocol.d.ts.map +1 -0
  255. package/runtime/offline-region-protocol.js +63 -0
  256. package/runtime/offline-region-style.d.ts +78 -0
  257. package/runtime/offline-region-style.d.ts.map +1 -0
  258. package/runtime/offline-region-style.js +147 -0
  259. package/runtime/pmtiles-protocol.d.ts +7 -8
  260. package/runtime/pmtiles-protocol.d.ts.map +1 -1
  261. package/runtime/pmtiles-protocol.js +19 -66
  262. package/runtime/protocol-registry.d.ts +55 -0
  263. package/runtime/protocol-registry.d.ts.map +1 -0
  264. package/runtime/protocol-registry.js +103 -0
  265. package/runtime/runtime.d.ts +2 -0
  266. package/runtime/runtime.d.ts.map +1 -1
  267. package/runtime/runtime.js +6 -1
  268. package/studio/index.d.ts +24 -7
  269. package/studio/index.d.ts.map +1 -1
  270. package/studio/index.js +21 -7
  271. package/studio/lifecycle-client.d.ts +164 -0
  272. package/studio/lifecycle-client.d.ts.map +1 -0
  273. package/studio/lifecycle-client.js +299 -0
  274. package/studio/lifecycle-errors.d.ts +91 -0
  275. package/studio/lifecycle-errors.d.ts.map +1 -0
  276. package/studio/lifecycle-errors.js +77 -0
  277. package/studio/lifecycle-types.d.ts +321 -0
  278. package/studio/lifecycle-types.d.ts.map +1 -0
  279. package/studio/lifecycle-types.js +22 -0
  280. package/webmap/convert-label.js +0 -1
  281. package/webmap/convert-symbol.d.ts.map +1 -1
@@ -0,0 +1,91 @@
1
+ /**
2
+ * Error taxonomy for {@link HonuaStudioLifecycleClient}.
3
+ *
4
+ * Every non-2xx response from the Studio package lifecycle API
5
+ * (`/api/v{version}/studio`) is either a handler-generated client error
6
+ * (`400`/`404`/`409`) or a caught internal failure (`500`), and both use
7
+ * RFC 7807 problem details with `type: "https://honua.io/problems/studio"`
8
+ * (see `docs/internal/admin-api/studio-package-lifecycle.md` in
9
+ * `honua-server`). {@link HonuaStudioError} normalizes both into one typed
10
+ * shape so callers branch on `.code` instead of parsing HTTP status numbers
11
+ * or problem-detail strings.
12
+ *
13
+ * `generation-conflict` is a distinct discriminant (not folded into a
14
+ * generic `"conflict"` bucket) because it is the one Studio failure mode the
15
+ * SDK expects callers to *recover from automatically* — reload the draft and
16
+ * retry — rather than surface to a user. Use
17
+ * {@link isHonuaStudioGenerationConflict} to branch on it without comparing
18
+ * `.code` strings directly.
19
+ *
20
+ * This module intentionally does not join the central `HonuaSdkError`
21
+ * registry (`src/core/error-code-registry.ts`): `studio` is an
22
+ * `@experimental`, not-yet-semver-covered domain, matching the existing
23
+ * `HonuaCollaborationError` (`src/collaboration/errors.ts`) precedent for
24
+ * experimental-domain errors pending a scoped migration.
25
+ *
26
+ * @module
27
+ */
28
+ /**
29
+ * Discriminant classifying a {@link HonuaStudioError}. Derived from the HTTP
30
+ * status code of the failed response:
31
+ *
32
+ * - `validation` — `400`, request or envelope failed validation.
33
+ * - `not-found` — `404`, the draft/version/content item does not exist (or,
34
+ * per the API doc, is not reachable from the given `itemId`/`versionId`
35
+ * pair — cross-item ids are treated as not found).
36
+ * - `generation-conflict` — `409`, the draft's server-managed `generation`
37
+ * changed since the caller last read it (`PUT /package-drafts/{draftId}`
38
+ * optimistic-concurrency check). Reload the draft and retry.
39
+ * - `internal` — `500`, a caught internal failure.
40
+ * - `unknown` — any other status the doc does not enumerate.
41
+ *
42
+ * @experimental
43
+ */
44
+ export type HonuaStudioProblemKind = "validation" | "not-found" | "generation-conflict" | "internal" | "unknown";
45
+ /**
46
+ * RFC 7807 problem-details body returned by the Studio package lifecycle API.
47
+ * `type` is `"https://honua.io/problems/studio"` on every documented error
48
+ * response; `code` and `errors` are optional server-supplied extensions.
49
+ *
50
+ * @experimental
51
+ */
52
+ export interface HonuaStudioProblemDetails {
53
+ readonly type?: string;
54
+ readonly title?: string;
55
+ readonly status?: number;
56
+ readonly detail?: string;
57
+ readonly instance?: string;
58
+ readonly code?: string;
59
+ readonly errors?: Record<string, readonly string[]>;
60
+ readonly [extra: string]: unknown;
61
+ }
62
+ /** Canonical RFC 7807 `type` URI the Studio lifecycle API uses for every problem response. */
63
+ export declare const HONUA_STUDIO_PROBLEM_TYPE: "https://honua.io/problems/studio";
64
+ /**
65
+ * Thrown by every {@link HonuaStudioLifecycleClient} method when the server
66
+ * returns a non-2xx response. Carries the raw HTTP `statusCode`, the
67
+ * classified `.code` discriminant (see {@link HonuaStudioProblemKind}), and
68
+ * the parsed RFC 7807 `.problem` body when the response was problem+json.
69
+ *
70
+ * @experimental
71
+ */
72
+ export declare class HonuaStudioError extends Error {
73
+ readonly code: HonuaStudioProblemKind;
74
+ readonly statusCode: number;
75
+ readonly problem: HonuaStudioProblemDetails | undefined;
76
+ constructor(code: HonuaStudioProblemKind, statusCode: number, message: string, problem?: HonuaStudioProblemDetails, options?: {
77
+ readonly cause?: unknown;
78
+ });
79
+ }
80
+ /** Type guard for {@link HonuaStudioError}. */
81
+ export declare function isHonuaStudioError(error: unknown): error is HonuaStudioError;
82
+ /**
83
+ * True only for the `409` optimistic-concurrency discriminant — the draft's
84
+ * `generation` changed since the caller last read it. Callers should reload
85
+ * the draft (`drafts.get`) and retry the `PUT` with the fresh `generation`
86
+ * rather than surface this as a hard failure.
87
+ */
88
+ export declare function isHonuaStudioGenerationConflict(error: unknown): error is HonuaStudioError;
89
+ /** @internal Classify an HTTP status code into a {@link HonuaStudioProblemKind}. */
90
+ export declare function classifyStudioProblemStatus(statusCode: number): HonuaStudioProblemKind;
91
+ //# sourceMappingURL=lifecycle-errors.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"lifecycle-errors.d.ts","sourceRoot":"","sources":["../../../src/studio/lifecycle-errors.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AAEH;;;;;;;;;;;;;;;GAeG;AACH,MAAM,MAAM,sBAAsB,GAAG,YAAY,GAAG,WAAW,GAAG,qBAAqB,GAAG,UAAU,GAAG,SAAS,CAAC;AAEjH;;;;;;GAMG;AACH,MAAM,WAAW,yBAAyB;IACxC,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,SAAS,MAAM,EAAE,CAAC,CAAC;IACpD,QAAQ,EAAE,KAAK,EAAE,MAAM,GAAG,OAAO,CAAC;CACnC;AAED,8FAA8F;AAC9F,eAAO,MAAM,yBAAyB,EAAG,kCAA2C,CAAC;AAErF;;;;;;;GAOG;AACH,qBAAa,gBAAiB,SAAQ,KAAK;IACzC,SAAgB,IAAI,EAAE,sBAAsB,CAAC;IAC7C,SAAgB,UAAU,EAAE,MAAM,CAAC;IACnC,SAAgB,OAAO,EAAE,yBAAyB,GAAG,SAAS,CAAC;gBAG7D,IAAI,EAAE,sBAAsB,EAC5B,UAAU,EAAE,MAAM,EAClB,OAAO,EAAE,MAAM,EACf,OAAO,CAAC,EAAE,yBAAyB,EACnC,OAAO,GAAE;QAAE,QAAQ,CAAC,KAAK,CAAC,EAAE,OAAO,CAAA;KAAO;CAQ7C;AAED,+CAA+C;AAC/C,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,gBAAgB,CAE5E;AAED;;;;;GAKG;AACH,wBAAgB,+BAA+B,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,gBAAgB,CAEzF;AAED,oFAAoF;AACpF,wBAAgB,2BAA2B,CAAC,UAAU,EAAE,MAAM,GAAG,sBAAsB,CAatF"}
@@ -0,0 +1,77 @@
1
+ /**
2
+ * Error taxonomy for {@link HonuaStudioLifecycleClient}.
3
+ *
4
+ * Every non-2xx response from the Studio package lifecycle API
5
+ * (`/api/v{version}/studio`) is either a handler-generated client error
6
+ * (`400`/`404`/`409`) or a caught internal failure (`500`), and both use
7
+ * RFC 7807 problem details with `type: "https://honua.io/problems/studio"`
8
+ * (see `docs/internal/admin-api/studio-package-lifecycle.md` in
9
+ * `honua-server`). {@link HonuaStudioError} normalizes both into one typed
10
+ * shape so callers branch on `.code` instead of parsing HTTP status numbers
11
+ * or problem-detail strings.
12
+ *
13
+ * `generation-conflict` is a distinct discriminant (not folded into a
14
+ * generic `"conflict"` bucket) because it is the one Studio failure mode the
15
+ * SDK expects callers to *recover from automatically* — reload the draft and
16
+ * retry — rather than surface to a user. Use
17
+ * {@link isHonuaStudioGenerationConflict} to branch on it without comparing
18
+ * `.code` strings directly.
19
+ *
20
+ * This module intentionally does not join the central `HonuaSdkError`
21
+ * registry (`src/core/error-code-registry.ts`): `studio` is an
22
+ * `@experimental`, not-yet-semver-covered domain, matching the existing
23
+ * `HonuaCollaborationError` (`src/collaboration/errors.ts`) precedent for
24
+ * experimental-domain errors pending a scoped migration.
25
+ *
26
+ * @module
27
+ */
28
+ /** Canonical RFC 7807 `type` URI the Studio lifecycle API uses for every problem response. */
29
+ export const HONUA_STUDIO_PROBLEM_TYPE = "https://honua.io/problems/studio";
30
+ /**
31
+ * Thrown by every {@link HonuaStudioLifecycleClient} method when the server
32
+ * returns a non-2xx response. Carries the raw HTTP `statusCode`, the
33
+ * classified `.code` discriminant (see {@link HonuaStudioProblemKind}), and
34
+ * the parsed RFC 7807 `.problem` body when the response was problem+json.
35
+ *
36
+ * @experimental
37
+ */
38
+ export class HonuaStudioError extends Error {
39
+ code;
40
+ statusCode;
41
+ problem;
42
+ constructor(code, statusCode, message, problem, options = {}) {
43
+ super(message, "cause" in options ? { cause: options.cause } : undefined);
44
+ this.name = "HonuaStudioError";
45
+ this.code = code;
46
+ this.statusCode = statusCode;
47
+ this.problem = problem;
48
+ }
49
+ }
50
+ /** Type guard for {@link HonuaStudioError}. */
51
+ export function isHonuaStudioError(error) {
52
+ return error instanceof HonuaStudioError;
53
+ }
54
+ /**
55
+ * True only for the `409` optimistic-concurrency discriminant — the draft's
56
+ * `generation` changed since the caller last read it. Callers should reload
57
+ * the draft (`drafts.get`) and retry the `PUT` with the fresh `generation`
58
+ * rather than surface this as a hard failure.
59
+ */
60
+ export function isHonuaStudioGenerationConflict(error) {
61
+ return isHonuaStudioError(error) && error.code === "generation-conflict";
62
+ }
63
+ /** @internal Classify an HTTP status code into a {@link HonuaStudioProblemKind}. */
64
+ export function classifyStudioProblemStatus(statusCode) {
65
+ switch (statusCode) {
66
+ case 400:
67
+ return "validation";
68
+ case 404:
69
+ return "not-found";
70
+ case 409:
71
+ return "generation-conflict";
72
+ case 500:
73
+ return "internal";
74
+ default:
75
+ return "unknown";
76
+ }
77
+ }
@@ -0,0 +1,321 @@
1
+ /**
2
+ * Typed request/response models for the Studio package lifecycle API
3
+ * (`/api/v{version}/studio` in `honua-server`), backing
4
+ * {@link HonuaStudioLifecycleClient}.
5
+ *
6
+ * These mirror the DTOs documented in
7
+ * `docs/internal/admin-api/studio-package-lifecycle.md` (`honua-server`):
8
+ * `Honua.Core.Features.Studio.Domain` for the entities and
9
+ * `Honua.Server.Features.Studio.Models` for the request shapes. Every
10
+ * interface keeps an open `[extra: string]: unknown` index signature so
11
+ * additive server fields do not break existing clients, and reuses the
12
+ * existing {@link StudioPackageDiagnostic} / {@link HonuaStudioPackageFamily}
13
+ * projections from `./validation.js` / `./types.js` rather than redeclaring
14
+ * them.
15
+ *
16
+ * @experimental Not yet covered by the SDK's semver contract — these shapes
17
+ * may change in any minor release prior to `1.0.0`, and until a dedicated
18
+ * Studio OpenAPI snapshot is published this doc and the source-generated
19
+ * JSON contexts are `honua-server`'s only contract reference.
20
+ * @module
21
+ */
22
+ import type { HonuaStudioPackageFamily } from "./types.js";
23
+ import type { StudioPackageDiagnostic } from "./validation.js";
24
+ /**
25
+ * Successful `ApiResponse<T>` envelope every Studio lifecycle endpoint wraps
26
+ * its payload in. The source-generated JSON context omits `null`-valued
27
+ * properties, so `message` is present only on responses that carry one (for
28
+ * example the draft-delete response).
29
+ *
30
+ * @experimental
31
+ */
32
+ export interface StudioApiResponse<T> {
33
+ readonly success: true;
34
+ readonly data: T;
35
+ readonly timestamp: string;
36
+ readonly message?: string;
37
+ }
38
+ /** Depth of validation a package family currently receives. */
39
+ export type StudioValidationDepth = "full" | "envelope" | (string & {});
40
+ /** Deployment persistence backing for Studio lifecycle data. */
41
+ export type StudioPersistenceMode = "postgres" | "in-memory" | (string & {});
42
+ /** Support level a deployment advertises for a package family. */
43
+ export type StudioPackageFamilySupportLevel = "supported" | "limited" | (string & {});
44
+ /**
45
+ * One package-family-scoped operation name as returned by
46
+ * `GET /package-families`. `draft.delete` is available on every family but,
47
+ * per the API doc, is not itself advertised as a per-family capability
48
+ * operation.
49
+ */
50
+ export type StudioPackageFamilyOperation = "draft.create" | "draft.read" | "draft.update" | "validate" | "preview-plan" | "content-version.create" | "content-version.read" | "content-version.compare" | "publish-request.create" | "reopen" | "rollback" | (string & {});
51
+ /** Capability descriptor for one Studio package family. */
52
+ export interface StudioPackageFamilyCapability {
53
+ readonly family: HonuaStudioPackageFamily | (string & {});
54
+ readonly schemaVersion: string;
55
+ readonly format: string;
56
+ readonly supportLevel: StudioPackageFamilySupportLevel;
57
+ readonly supportedOperations: readonly StudioPackageFamilyOperation[];
58
+ readonly validationDepth: StudioValidationDepth;
59
+ readonly limitations?: readonly string[];
60
+ readonly maxPackageBytes: number;
61
+ readonly durable: boolean;
62
+ readonly persistenceMode?: StudioPersistenceMode;
63
+ readonly [extra: string]: unknown;
64
+ }
65
+ /** `GET /package-families` response payload — every registered package family. */
66
+ export interface StudioPackageFamilyCapabilities {
67
+ readonly families: readonly StudioPackageFamilyCapability[];
68
+ readonly [extra: string]: unknown;
69
+ }
70
+ /** Reference to a source a package envelope binds to. */
71
+ export interface StudioBindingRef {
72
+ readonly key: string;
73
+ readonly kind: string;
74
+ readonly ref: string;
75
+ readonly crs?: string;
76
+ readonly srid?: number;
77
+ readonly requiredPermissions?: readonly string[];
78
+ readonly [extra: string]: unknown;
79
+ }
80
+ /** Dependency lineage entry (e.g. on a content item's version) carried on an envelope. */
81
+ export interface StudioDependencyRef {
82
+ readonly kind: string;
83
+ readonly ref: string;
84
+ readonly versionId?: string;
85
+ readonly required?: boolean;
86
+ readonly [extra: string]: unknown;
87
+ }
88
+ /** Provenance lineage entry (e.g. the prompt or plan that generated the package). */
89
+ export interface StudioProvenanceRef {
90
+ readonly kind: string;
91
+ readonly ref: string;
92
+ readonly rel: string;
93
+ readonly [extra: string]: unknown;
94
+ }
95
+ /** Route/visibility a package declares it wants to publish to. */
96
+ export interface StudioPublicationIntent {
97
+ readonly route?: string;
98
+ readonly visibility?: "private" | "organization" | "public" | (string & {});
99
+ readonly [extra: string]: unknown;
100
+ }
101
+ /** `StudioValidationSummary.status` — see the API doc's "Validation And Preview" section. */
102
+ export type StudioValidationStatus = "not-validated" | "valid" | "warning" | "invalid";
103
+ /**
104
+ * Validation summary persisted on a draft or captured on a content version.
105
+ * Returned directly by `POST /package-drafts/{draftId}/validate` and embedded
106
+ * in every {@link StudioPackageEnvelope.validation}.
107
+ */
108
+ export interface StudioValidationSummary {
109
+ readonly status: StudioValidationStatus;
110
+ readonly diagnostics?: readonly StudioPackageDiagnostic[];
111
+ readonly unsupportedCapabilities?: readonly string[];
112
+ readonly generatedAt?: string;
113
+ readonly [extra: string]: unknown;
114
+ }
115
+ /**
116
+ * `StudioPackageEnvelope` — the wire shape shared by every package family.
117
+ * `schemaVersion` and `format` must match the descriptor
118
+ * {@link StudioPackageFamilyCapability} returns for `family` from
119
+ * `GET /package-families`. `body` is deliberately generic: for `map`/`app` it
120
+ * is validated against the existing `honua_map_package.v1` /
121
+ * `honua_app_package.v1` models (pass `HonuaMapPackage` /
122
+ * `HonuaGeneratedAppPackage` as `TBody` for full typing); every other family
123
+ * currently receives only envelope-level validation.
124
+ *
125
+ * @experimental
126
+ */
127
+ export interface StudioPackageEnvelope<TBody = Record<string, unknown>> {
128
+ readonly family: HonuaStudioPackageFamily | (string & {});
129
+ readonly schemaVersion: string;
130
+ readonly format: string;
131
+ readonly bindings?: readonly StudioBindingRef[];
132
+ readonly dependencies?: readonly StudioDependencyRef[];
133
+ readonly validation?: StudioValidationSummary;
134
+ readonly publicationIntent?: StudioPublicationIntent;
135
+ readonly provenance?: readonly StudioProvenanceRef[];
136
+ readonly body: TBody;
137
+ }
138
+ /** A mutable Studio package draft. `generation` increments on every successful `PUT`. */
139
+ export interface StudioPackageDraft {
140
+ readonly draftId: string;
141
+ readonly itemId: string;
142
+ readonly family: HonuaStudioPackageFamily | (string & {});
143
+ readonly packageKey: string;
144
+ readonly workspaceId?: string;
145
+ readonly ownerId?: string;
146
+ readonly generation: number;
147
+ readonly envelope: StudioPackageEnvelope;
148
+ readonly baseVersionId?: string;
149
+ readonly createdAt?: string;
150
+ readonly updatedAt?: string;
151
+ readonly [extra: string]: unknown;
152
+ }
153
+ /**
154
+ * `POST /package-drafts` request body. `packageKey` is trimmed, limited to
155
+ * 200 characters, and may contain only letters, numbers, dash, underscore, or
156
+ * dot. Omit `itemId` to let the server allocate a new Studio content item;
157
+ * omit `ownerId` to use the authenticated actor id.
158
+ */
159
+ export interface StudioPackageDraftCreateRequest {
160
+ readonly packageKey: string;
161
+ readonly workspaceId?: string;
162
+ readonly ownerId?: string;
163
+ readonly itemId?: string;
164
+ readonly envelope: StudioPackageEnvelope;
165
+ }
166
+ /**
167
+ * `PUT /package-drafts/{draftId}` request body. `workspaceId` uses replace
168
+ * semantics: omit it or send an empty string to clear the stored workspace.
169
+ * Omit `ownerId` to preserve the existing owner. Omit `generation` to update
170
+ * from the current server-loaded generation (last-write-wins); include the
171
+ * last-seen `generation` for strict optimistic-concurrency protection — a
172
+ * stale value throws {@link HonuaStudioError} with
173
+ * `code: "generation-conflict"` (`409`).
174
+ */
175
+ export interface StudioPackageDraftReplaceRequest {
176
+ readonly packageKey: string;
177
+ readonly workspaceId?: string;
178
+ readonly ownerId?: string;
179
+ readonly envelope: StudioPackageEnvelope;
180
+ readonly generation?: number;
181
+ }
182
+ /**
183
+ * `POST /package-drafts/{draftId}/preview-plan` response. `gp`, `etl`, and
184
+ * `workflow` drafts return `requiresJob: true, synchronous: false`; every
185
+ * other family returns `requiresJob: false, synchronous: true`.
186
+ */
187
+ export interface StudioPreviewPlan {
188
+ readonly requiresJob: boolean;
189
+ readonly synchronous: boolean;
190
+ readonly steps: readonly string[];
191
+ readonly [extra: string]: unknown;
192
+ }
193
+ /**
194
+ * An immutable Studio content version. Never edited in place — call
195
+ * `versions.reopen` to continue work as a new mutable draft.
196
+ */
197
+ export interface StudioContentVersion {
198
+ readonly versionId: string;
199
+ readonly itemId: string;
200
+ readonly family: HonuaStudioPackageFamily | (string & {});
201
+ readonly versionNumber: number;
202
+ readonly contentHash: string;
203
+ readonly envelope: StudioPackageEnvelope;
204
+ readonly validation?: StudioValidationSummary;
205
+ readonly dependencies?: readonly StudioDependencyRef[];
206
+ readonly provenance?: readonly StudioProvenanceRef[];
207
+ readonly baseDraftId?: string;
208
+ readonly createdAt?: string;
209
+ readonly createdBy?: string;
210
+ readonly [extra: string]: unknown;
211
+ }
212
+ /** `GET /content-items/{itemId}/versions` response — empty `versions` when none exist. */
213
+ export interface StudioContentVersionListResponse {
214
+ readonly itemId: string;
215
+ readonly versions: readonly StudioContentVersion[];
216
+ readonly [extra: string]: unknown;
217
+ }
218
+ /** `POST /content-items/{itemId}/version-comparisons` request body. */
219
+ export interface StudioVersionComparisonRequest {
220
+ readonly baseVersionId: string;
221
+ readonly compareVersionId: string;
222
+ }
223
+ /** Added/removed/unchanged partition for one comparison facet. */
224
+ export interface StudioVersionComparisonDiff<T> {
225
+ readonly added?: readonly T[];
226
+ readonly removed?: readonly T[];
227
+ readonly unchanged?: readonly T[];
228
+ readonly [extra: string]: unknown;
229
+ }
230
+ /**
231
+ * `POST /content-items/{itemId}/version-comparisons` response — compares two
232
+ * immutable versions by content hash, dependencies, validation, and
233
+ * provenance. The exact diff shape is not yet OpenAPI-pinned server-side;
234
+ * the documented facets are typed here and every field keeps its own open
235
+ * index signature so an unrecognized server addition still round-trips.
236
+ */
237
+ export interface StudioVersionComparison {
238
+ readonly itemId: string;
239
+ readonly baseVersionId: string;
240
+ readonly compareVersionId: string;
241
+ readonly contentHashChanged: boolean;
242
+ readonly dependencies?: StudioVersionComparisonDiff<StudioDependencyRef>;
243
+ readonly provenance?: StudioVersionComparisonDiff<StudioProvenanceRef>;
244
+ readonly validation?: {
245
+ readonly base?: StudioValidationSummary;
246
+ readonly compare?: StudioValidationSummary;
247
+ readonly [extra: string]: unknown;
248
+ };
249
+ readonly [extra: string]: unknown;
250
+ }
251
+ /**
252
+ * `pending` is reserved for later asynchronous publication execution and is
253
+ * not emitted by the API service today.
254
+ */
255
+ export type StudioPublicationRequestStatus = "accepted" | "rejected" | "pending" | (string & {});
256
+ /**
257
+ * `POST /content-items/{itemId}/versions/{versionId}/publish-requests`
258
+ * request body. `intent` overrides the version envelope's
259
+ * `publicationIntent` when supplied; an invalid override fails with `400`
260
+ * before a request is persisted. `warningAcknowledgment` is optional audit
261
+ * text for `warning`-status versions.
262
+ */
263
+ export interface StudioPublicationRequestInput {
264
+ readonly intent?: StudioPublicationIntent;
265
+ readonly warningAcknowledgment?: string;
266
+ readonly [extra: string]: unknown;
267
+ }
268
+ /**
269
+ * A persisted publication request. Versions whose captured validation status
270
+ * is `invalid` still produce a durable request with `status: "rejected"` and
271
+ * do not move the published pointer; `valid`/`warning` versions are
272
+ * `"accepted"` and do move it.
273
+ */
274
+ export interface StudioPublicationRequest {
275
+ readonly requestId: string;
276
+ readonly itemId: string;
277
+ readonly versionId: string;
278
+ readonly status: StudioPublicationRequestStatus;
279
+ readonly intent?: StudioPublicationIntent;
280
+ readonly createdAt?: string;
281
+ readonly createdBy?: string;
282
+ readonly [extra: string]: unknown;
283
+ }
284
+ /**
285
+ * `POST /content-items/{itemId}/versions/{versionId}/reopen` request body.
286
+ * No fields are documented as required; this is intentionally open for a
287
+ * future owner/workspace override.
288
+ */
289
+ export interface StudioReopenVersionRequest {
290
+ readonly ownerId?: string;
291
+ readonly workspaceId?: string;
292
+ readonly [extra: string]: unknown;
293
+ }
294
+ /** Which content-item pointer(s) a rollback request moves. */
295
+ export type StudioRollbackPointer = "current" | "published" | "both";
296
+ /** `POST /content-items/{itemId}/rollback-requests` request body. */
297
+ export interface StudioRollbackRequestInput {
298
+ readonly versionId: string;
299
+ readonly pointer: StudioRollbackPointer;
300
+ readonly message?: string;
301
+ readonly [extra: string]: unknown;
302
+ }
303
+ /** The Studio content item's current/published version pointers. */
304
+ export interface StudioContentItemPointers {
305
+ readonly itemId: string;
306
+ readonly currentVersionId?: string;
307
+ readonly publishedVersionId?: string;
308
+ readonly [extra: string]: unknown;
309
+ }
310
+ /** A persisted rollback request, carrying the resulting content-item pointers. */
311
+ export interface StudioRollbackRequest {
312
+ readonly requestId: string;
313
+ readonly itemId: string;
314
+ readonly versionId: string;
315
+ readonly pointer: StudioRollbackPointer;
316
+ readonly pointers: StudioContentItemPointers;
317
+ readonly createdAt?: string;
318
+ readonly createdBy?: string;
319
+ readonly [extra: string]: unknown;
320
+ }
321
+ //# sourceMappingURL=lifecycle-types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"lifecycle-types.d.ts","sourceRoot":"","sources":["../../../src/studio/lifecycle-types.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AAEH,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,YAAY,CAAC;AAC3D,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,iBAAiB,CAAC;AAE/D;;;;;;;GAOG;AACH,MAAM,WAAW,iBAAiB,CAAC,CAAC;IAClC,QAAQ,CAAC,OAAO,EAAE,IAAI,CAAC;IACvB,QAAQ,CAAC,IAAI,EAAE,CAAC,CAAC;IACjB,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC;CAC3B;AAMD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ClF,MAAM,WAAW,qBAAqB;IACpC,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,OAAO,EAAE,qBAAqB,CAAC;IACxC,QAAQ,CAAC,QAAQ,EAAE,yBAAyB,CAAC;IAC7C,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;IAC5B,QAAQ,EAAE,KAAK,EAAE,MAAM,GAAG,OAAO,CAAC;CACnC"}
@@ -0,0 +1,22 @@
1
+ /**
2
+ * Typed request/response models for the Studio package lifecycle API
3
+ * (`/api/v{version}/studio` in `honua-server`), backing
4
+ * {@link HonuaStudioLifecycleClient}.
5
+ *
6
+ * These mirror the DTOs documented in
7
+ * `docs/internal/admin-api/studio-package-lifecycle.md` (`honua-server`):
8
+ * `Honua.Core.Features.Studio.Domain` for the entities and
9
+ * `Honua.Server.Features.Studio.Models` for the request shapes. Every
10
+ * interface keeps an open `[extra: string]: unknown` index signature so
11
+ * additive server fields do not break existing clients, and reuses the
12
+ * existing {@link StudioPackageDiagnostic} / {@link HonuaStudioPackageFamily}
13
+ * projections from `./validation.js` / `./types.js` rather than redeclaring
14
+ * them.
15
+ *
16
+ * @experimental Not yet covered by the SDK's semver contract — these shapes
17
+ * may change in any minor release prior to `1.0.0`, and until a dedicated
18
+ * Studio OpenAPI snapshot is published this doc and the source-generated
19
+ * JSON contexts are `honua-server`'s only contract reference.
20
+ * @module
21
+ */
22
+ export {};
@@ -45,7 +45,6 @@ export function convertLabelingInfo(labelClasses, sourceId, baseLayerId, warn) {
45
45
  return layers;
46
46
  }
47
47
  const FEATURE_FIELD_RE = /^\$feature\.(\w+)$/;
48
- const FEATURE_FIELD_GLOBAL_RE = /\$feature\.(\w+)/g;
49
48
  function parseLabelExpression(lc, warn) {
50
49
  // Prefer labelExpressionInfo (Arcade-based)
51
50
  if (lc.labelExpressionInfo?.expression) {
@@ -1 +1 @@
1
- {"version":3,"file":"convert-symbol.d.ts","sourceRoot":"","sources":["../../../src/webmap/convert-symbol.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAAO,KAAK,EACV,SAAS,EAKT,YAAY,EAEb,MAAM,YAAY,CAAC;AACpB,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AAItD,iEAAiE;AACjE,wBAAgB,cAAc,CAAC,KAAK,EAAE,SAAS,GAAG,SAAS,GAAG,MAAM,GAAG,SAAS,CAM/E;AAaD,wBAAgB,wBAAwB,CAAC,KAAK,EAAE,MAAM,GAAG,SAAS,GAAG,MAAM,EAAE,GAAG,SAAS,CAGxF;AAID,MAAM,WAAW,sBAAsB;IACrC,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAC/B,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CACjC;AAED,wBAAgB,aAAa,CAC3B,MAAM,EAAE,YAAY,GAAG,SAAS,EAChC,IAAI,EAAE,gBAAgB,GACrB,sBAAsB,GAAG,SAAS,CAkBpC"}
1
+ {"version":3,"file":"convert-symbol.d.ts","sourceRoot":"","sources":["../../../src/webmap/convert-symbol.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EACV,SAAS,EAKT,YAAY,EAEb,MAAM,YAAY,CAAC;AACpB,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AAItD,iEAAiE;AACjE,wBAAgB,cAAc,CAAC,KAAK,EAAE,SAAS,GAAG,SAAS,GAAG,MAAM,GAAG,SAAS,CAM/E;AAaD,wBAAgB,wBAAwB,CAAC,KAAK,EAAE,MAAM,GAAG,SAAS,GAAG,MAAM,EAAE,GAAG,SAAS,CAGxF;AAID,MAAM,W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