uniweb 0.9.6 → 0.9.7

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "uniweb",
3
- "version": "0.9.6",
3
+ "version": "0.9.7",
4
4
  "description": "Create structured Vite + React sites with content/code separation",
5
5
  "type": "module",
6
6
  "bin": {
@@ -41,12 +41,12 @@
41
41
  "js-yaml": "^4.1.0",
42
42
  "prompts": "^2.4.2",
43
43
  "tar": "^7.0.0",
44
- "@uniweb/runtime": "0.7.4",
45
- "@uniweb/core": "0.6.1",
46
- "@uniweb/kit": "0.8.2"
44
+ "@uniweb/core": "0.6.2",
45
+ "@uniweb/runtime": "0.7.5",
46
+ "@uniweb/kit": "0.8.3"
47
47
  },
48
48
  "peerDependencies": {
49
- "@uniweb/build": "0.9.4",
49
+ "@uniweb/build": "0.9.5",
50
50
  "@uniweb/content-reader": "1.1.4",
51
51
  "@uniweb/semantic-parser": "1.1.9"
52
52
  },
@@ -865,6 +865,21 @@ function MyComponent({ content, params, block }) {
865
865
 
866
866
  All non-reserved frontmatter fields become `params`. Reserved: `type`, `preset`, `input`, `data`, `id`, `background`, `theme`, `source`, `where`. Everything else flows to the component.
867
867
 
868
+ ### Data
869
+
870
+ A component on a page with a `data:` or `fetch:` declaration automatically receives that data in `content.data.{schema}`. No opt-in required in `meta.js`. On a template page (`[slug]/`), the matched item is also delivered as `content.data.{singular}` (e.g. `content.data.article` when the parent declares `data: articles`).
871
+
872
+ ```jsx
873
+ function Article({ content, block }) {
874
+ if (block.dataLoading) return <DataPlaceholder />
875
+ const article = content.data.article
876
+ if (!article) return <NotFound />
877
+ return <ArticleView article={article} />
878
+ }
879
+ ```
880
+
881
+ Components can ignore keys in `content.data` they don't need — the same way unused `params` are ignored. For declarative shape hints consumed by the editor and `prepare-props`, add `data: { entity: 'articles' }` to `meta.js`. For an explicit opt-out (rare), set `data: false`. See [Data Fetching](https://github.com/uniweb/docs/blob/main/reference/data-fetching.md) for the full model.
882
+
868
883
  ### block properties
869
884
 
870
885
  | Property | Type | Description |
@@ -1,9 +1,9 @@
1
1
  {
2
2
  "schemaVersion": 1,
3
- "generatedAt": "2026-04-16T22:34:02.528Z",
3
+ "generatedAt": "2026-04-18T18:19:51.002Z",
4
4
  "packages": {
5
5
  "@uniweb/build": {
6
- "version": "0.9.4",
6
+ "version": "0.9.5",
7
7
  "path": "framework/build",
8
8
  "deps": [
9
9
  "@uniweb/content-reader",
@@ -24,13 +24,18 @@
24
24
  "deps": []
25
25
  },
26
26
  "@uniweb/core": {
27
- "version": "0.6.1",
27
+ "version": "0.6.2",
28
28
  "path": "framework/core",
29
29
  "deps": [
30
30
  "@uniweb/semantic-parser",
31
31
  "@uniweb/theming"
32
32
  ]
33
33
  },
34
+ "@uniweb/fetchers": {
35
+ "version": "0.1.0",
36
+ "path": "framework/fetchers",
37
+ "deps": []
38
+ },
34
39
  "@uniweb/frame-bridge": {
35
40
  "version": "0.2.3",
36
41
  "path": "framework/frame-bridge",
@@ -42,7 +47,7 @@
42
47
  "deps": []
43
48
  },
44
49
  "@uniweb/kit": {
45
- "version": "0.8.2",
50
+ "version": "0.8.3",
46
51
  "path": "framework/kit",
47
52
  "deps": [
48
53
  "@uniweb/core"
@@ -54,12 +59,17 @@
54
59
  "deps": []
55
60
  },
56
61
  "@uniweb/press": {
57
- "version": "0.2.4",
62
+ "version": "0.2.8",
58
63
  "path": "framework/press",
59
64
  "deps": []
60
65
  },
66
+ "@uniweb/query": {
67
+ "version": "0.1.0",
68
+ "path": "framework/query",
69
+ "deps": []
70
+ },
61
71
  "@uniweb/runtime": {
62
- "version": "0.7.4",
72
+ "version": "0.7.5",
63
73
  "path": "framework/runtime",
64
74
  "deps": [
65
75
  "@uniweb/core",
@@ -82,7 +92,7 @@
82
92
  "deps": []
83
93
  },
84
94
  "@uniweb/templates": {
85
- "version": "0.7.29",
95
+ "version": "0.7.30",
86
96
  "path": "framework/templates",
87
97
  "deps": []
88
98
  },
@@ -199,6 +209,20 @@
199
209
  "tables",
200
210
  "bibliography"
201
211
  ]
212
+ },
213
+ "academic-metrics": {
214
+ "name": "Academic Metrics (xlsx showcase)",
215
+ "description": "A docusite whose content is also a downloadable Excel workbook. Aggregates academic metrics (publications, funding, supervisions) across multiple members of a university unit. Rich web previews + flat tabular xlsx sheets from the same data. Ships with three 19th-century naturalists as sample members.",
216
+ "tags": [
217
+ "academic-metrics",
218
+ "docusite",
219
+ "press",
220
+ "xlsx",
221
+ "report",
222
+ "members",
223
+ "aggregate",
224
+ "academic"
225
+ ]
202
226
  }
203
227
  }
204
228
  }