@uniweb/core 1.6.18 → 1.6.20
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 +2 -2
- package/src/block.js +7 -4
- package/src/uniweb.js +8 -6
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@uniweb/core",
|
|
3
|
-
"version": "1.6.
|
|
3
|
+
"version": "1.6.20",
|
|
4
4
|
"description": "Core classes for the Uniweb platform - Uniweb, Website, Page, Block",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|
|
@@ -53,7 +53,7 @@
|
|
|
53
53
|
"vitest": "^4.1.7"
|
|
54
54
|
},
|
|
55
55
|
"dependencies": {
|
|
56
|
-
"@uniweb/theming": "~1.3.
|
|
56
|
+
"@uniweb/theming": "~1.3.8",
|
|
57
57
|
"@uniweb/semantic-parser": "~1.13.6"
|
|
58
58
|
},
|
|
59
59
|
"scripts": {
|
package/src/block.js
CHANGED
|
@@ -679,10 +679,12 @@ export default class Block {
|
|
|
679
679
|
|
|
680
680
|
/**
|
|
681
681
|
* Whether the header lies over this section on its page: the section asks (`underHeader`, its
|
|
682
|
-
* author's setting or its type's default), it opens the page,
|
|
683
|
-
* layout's area named `header`, holding
|
|
684
|
-
*
|
|
685
|
-
*
|
|
682
|
+
* author's setting or its type's default), it opens the page, the page's layout lets a section lie
|
|
683
|
+
* under its header, and the page has a header — its layout's area named `header`, holding
|
|
684
|
+
* sections. A layout that sets its body beside its header, such as one with a sidebar, says no
|
|
685
|
+
* section lies under it: `underHeader: false` in its `meta.js`, whatever a section asks. One rule
|
|
686
|
+
* for the runtime, which lays the header over the section, and for a header, which reads it on
|
|
687
|
+
* its next block (`getBlockInfo().underHeader`) to paint itself see-through.
|
|
686
688
|
*
|
|
687
689
|
* ⛔ Until 2026-11-06 a header read the section's setting alone, so a header in an area named
|
|
688
690
|
* otherwise, which the runtime never lays over anything, painted itself see-through in the flow.
|
|
@@ -692,6 +694,7 @@ export default class Block {
|
|
|
692
694
|
liesUnderHeader() {
|
|
693
695
|
const page = this.page
|
|
694
696
|
if (!this.underHeader || !page || page.getBodyBlocks?.()?.[0] !== this) return false
|
|
697
|
+
if (this.website?.getLayoutMeta?.(page.getLayoutName?.())?.underHeader === false) return false
|
|
695
698
|
const header = page.getLayoutAreas?.()?.header
|
|
696
699
|
return Array.isArray(header) && header.length > 0
|
|
697
700
|
}
|
package/src/uniweb.js
CHANGED
|
@@ -105,12 +105,14 @@ export default class Uniweb {
|
|
|
105
105
|
// `defaultInsets` above.
|
|
106
106
|
this.tracking = null
|
|
107
107
|
|
|
108
|
-
//
|
|
109
|
-
//
|
|
110
|
-
//
|
|
111
|
-
//
|
|
112
|
-
//
|
|
113
|
-
//
|
|
108
|
+
// The site's client for its `backend` service. `@uniweb/api`, which the
|
|
109
|
+
// foundation bundles, makes it the first time one is needed and keeps it
|
|
110
|
+
// here. It lasts the whole visit: this singleton is made once, every page
|
|
111
|
+
// renders on it, so the session and the reads the client holds carry from
|
|
112
|
+
// page to page. A process holding several sites holds a Uniweb, and so a
|
|
113
|
+
// client, for each. Another copy of that package (an extension's) adopts
|
|
114
|
+
// the one kept here. Core implements nothing on it: declared null so the
|
|
115
|
+
// seal permits the assignment, nothing more. Same pattern as
|
|
114
116
|
// `defaultInsets` above.
|
|
115
117
|
this.api = null
|
|
116
118
|
|