@aifeatures/admin-react 0.9.0 → 0.11.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.
package/dist/index.d.cts CHANGED
@@ -109,8 +109,24 @@ interface ApiError {
109
109
  * cannot be answered for this site and period, which is a thing the merchant
110
110
  * can act on. Rendering it as "we can't reach analytics" strands them with a
111
111
  * filter applied, every report gone, and a Retry that repeats the failure.
112
+ *
113
+ * `range_invalid` is the same kind of fact about an explicit `from`/`to`
114
+ * window: it is inverted, malformed, longer than the maximum span, or sent
115
+ * alongside a `period` that names a different window. The panel does not
116
+ * send ranges today, but a TypeScript consumer of this package that does
117
+ * cannot narrow on a code the union omits.
118
+ *
119
+ * `dimension_unsupported` is the cross-tab equivalent: the report cannot be
120
+ * crossed against the second dimension asked for — because it is `channel`,
121
+ * which is classified rather than stored; because the report already spends
122
+ * its one second-dimension slot on a disambiguator; or because that kind of
123
+ * report has no row set to split at all.
124
+ *
125
+ * All three are EXPECTED consequences of the request, never outages, so a
126
+ * client that cannot tell them apart from an unreachable source shows the
127
+ * wrong recovery for every one of them.
112
128
  */
113
- code?: 'filter_unsupported';
129
+ code?: 'filter_unsupported' | 'range_invalid' | 'dimension_unsupported';
114
130
  }
115
131
  /**
116
132
  * A site's payment readiness (sites.paymentsStatus)
package/dist/index.d.ts CHANGED
@@ -109,8 +109,24 @@ interface ApiError {
109
109
  * cannot be answered for this site and period, which is a thing the merchant
110
110
  * can act on. Rendering it as "we can't reach analytics" strands them with a
111
111
  * filter applied, every report gone, and a Retry that repeats the failure.
112
+ *
113
+ * `range_invalid` is the same kind of fact about an explicit `from`/`to`
114
+ * window: it is inverted, malformed, longer than the maximum span, or sent
115
+ * alongside a `period` that names a different window. The panel does not
116
+ * send ranges today, but a TypeScript consumer of this package that does
117
+ * cannot narrow on a code the union omits.
118
+ *
119
+ * `dimension_unsupported` is the cross-tab equivalent: the report cannot be
120
+ * crossed against the second dimension asked for — because it is `channel`,
121
+ * which is classified rather than stored; because the report already spends
122
+ * its one second-dimension slot on a disambiguator; or because that kind of
123
+ * report has no row set to split at all.
124
+ *
125
+ * All three are EXPECTED consequences of the request, never outages, so a
126
+ * client that cannot tell them apart from an unreachable source shows the
127
+ * wrong recovery for every one of them.
112
128
  */
113
- code?: 'filter_unsupported';
129
+ code?: 'filter_unsupported' | 'range_invalid' | 'dimension_unsupported';
114
130
  }
115
131
  /**
116
132
  * A site's payment readiness (sites.paymentsStatus)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aifeatures/admin-react",
3
- "version": "0.9.0",
3
+ "version": "0.11.0",
4
4
  "description": "React components for managing aifeatures forms",
5
5
  "type": "module",
6
6
  "main": "./dist/index.cjs",
@@ -22,6 +22,18 @@
22
22
  "files": [
23
23
  "dist"
24
24
  ],
25
+ "scripts": {
26
+ "build": "tsup && pnpm build:css",
27
+ "prepack": "pnpm build",
28
+ "build:css": "tailwindcss -i ./src/styles.css -o ./dist/styles.css --minify",
29
+ "dev": "tsup --watch",
30
+ "dev:css": "tailwindcss -i ./src/styles.css -o ./dist/styles.css --watch",
31
+ "lint": "eslint src/",
32
+ "typecheck": "tsc --noEmit",
33
+ "test": "vitest run",
34
+ "storybook": "storybook dev -p 6006",
35
+ "build-storybook": "storybook build"
36
+ },
25
37
  "peerDependencies": {
26
38
  "react": ">=18",
27
39
  "react-dom": ">=18"
@@ -69,16 +81,5 @@
69
81
  "workerDirectory": [
70
82
  ".storybook/public"
71
83
  ]
72
- },
73
- "scripts": {
74
- "build": "tsup && pnpm build:css",
75
- "build:css": "tailwindcss -i ./src/styles.css -o ./dist/styles.css --minify",
76
- "dev": "tsup --watch",
77
- "dev:css": "tailwindcss -i ./src/styles.css -o ./dist/styles.css --watch",
78
- "lint": "eslint src/",
79
- "typecheck": "tsc --noEmit",
80
- "test": "vitest run",
81
- "storybook": "storybook dev -p 6006",
82
- "build-storybook": "storybook build"
83
84
  }
84
- }
85
+ }