@thecms/next 0.20.1 → 0.20.2-dev.129

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/server.d.ts CHANGED
@@ -173,13 +173,14 @@ interface CmsPageProps {
173
173
  searchParams?: Promise<Record<string, string | string[] | undefined>>;
174
174
  }
175
175
  /** SITE-CONNECTION (D266): this package's version, as the site's server announces it (kept equal to package.json by a test). */
176
- declare const NEXT_VERSION = "0.20.1";
176
+ declare const NEXT_VERSION = "0.20.2-dev.129";
177
177
  /** The reader's session (D192) and the preview token (D190, P7: valid for the preview route only): httpOnly cookies of the site. */
178
178
  declare const READER_COOKIE = "cms_reader";
179
179
 
180
180
  /**
181
- * LLMS-PROXY (24/11/2026): where the site's own page is asked — first at the application's Site URL (the address its
182
- * visitors use: behind a reverse proxy that ends TLS, the public https one), then as this request reached the server,
181
+ * LLMS-PROXY (24/11/2026): where the site's own page is asked — first at the application's Site URL when the request
182
+ * reached the server at its host (the address its visitors use: behind a reverse proxy that ends TLS, the public
183
+ * https one; LLMS-OWN: never another host, which may be another site), then as this request reached the server,
183
184
  * with the proxy's forwarded scheme (`X-Forwarded-Proto`: the same host, never another one), then `req.url` as it is.
184
185
  * Never a host taken from a request header to BUILD an address: a forged `X-Forwarded-Host` would make the site read,
185
186
  * and keep as its own text, another site's page. (MULTISITE D638: the `Host` header only CHOOSES among the declared
package/dist/server.js CHANGED
@@ -597,7 +597,7 @@ function findTag(el, tag) {
597
597
  }
598
598
 
599
599
  // src/server.ts
600
- var NEXT_VERSION = "0.20.1";
600
+ var NEXT_VERSION = "0.20.2-dev.129";
601
601
  var READER_COOKIE = "cms_reader";
602
602
  var ENTRY_URL = "/api/cms/preview";
603
603
  function decodeSegment(segment) {
@@ -613,7 +613,8 @@ function sitePageOrigins(req, siteUrl) {
613
613
  const origins = [];
614
614
  if (siteUrl) {
615
615
  try {
616
- origins.push(new URL(siteUrl).origin);
616
+ const own = new URL(siteUrl);
617
+ if (own.host === url.host) origins.push(own.origin);
617
618
  } catch {
618
619
  }
619
620
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thecms/next",
3
- "version": "0.20.1",
3
+ "version": "0.20.2-dev.129",
4
4
  "license": "UNLICENSED",
5
5
  "description": "theCMS. for Next.js (App Router): pages, metadata, the blocks drawn with the site's components, preview, readers and an optional one-line route",
6
6
  "type": "module",
@@ -40,7 +40,7 @@
40
40
  "react": ">=19"
41
41
  },
42
42
  "dependencies": {
43
- "@thecms/sdk": "0.20.1"
43
+ "@thecms/sdk": "0.20.2-dev.129"
44
44
  },
45
45
  "devDependencies": {
46
46
  "@thecms/core": "0.0.1",