@getquick/content 0.4.2 → 0.5.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/README.md +34 -0
- package/dist/consent-html.js +1 -1
- package/dist/consent.js +1 -1
- package/dist/{site-language-BCGjkpWY.js → design-fonts-B0ts54vY.js} +3764 -1
- package/dist/index.d.ts +2 -17
- package/dist/index.js +2 -2
- package/dist/server.d.ts +1 -1
- package/dist/server.js +88 -3556
- package/dist/{version-CGZoRnsU.js → version-CmdZGJvZ.js} +1 -1
- package/dist/{wordpress-BvkTDMA0.d.ts → wordpress-OWJxnbAF.d.ts} +113 -2
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -309,6 +309,40 @@ per response, using the delivered `theme` from entry/home/chrome. Resolve defaul
|
|
|
309
309
|
with `resolveDesignTheme` for older stored publications. A changed theme requires
|
|
310
310
|
regenerating both stylesheets, including its media thresholds.
|
|
311
311
|
|
|
312
|
+
### Fonts and text styles
|
|
313
|
+
|
|
314
|
+
GQ Design 0.10.1 (contract 2.1.0) delivers the Site's self-hosted font families
|
|
315
|
+
(faces on the Site's own or media host, each with a metric-matched local
|
|
316
|
+
fallback), the `sans`/`serif`/`mono` slot assignments and the Heading and
|
|
317
|
+
Paragraph text styles. The design presets carry them as optional `fonts` and
|
|
318
|
+
`textStyles`: read with the other presets, stored with them, refreshed by the
|
|
319
|
+
`design` settings event (a global styles save, a font slot assignment, or a
|
|
320
|
+
Font Library family or face saved or deleted) and compared by reconciliation.
|
|
321
|
+
A CMS whose GQ Design predates them rejects the fields; the presets are read
|
|
322
|
+
again without them, with a warning, and pages keep the theme's system stacks.
|
|
323
|
+
|
|
324
|
+
Emit them once per response, in the head, after `designThemeStyleSheet(theme)`:
|
|
325
|
+
|
|
326
|
+
```astro
|
|
327
|
+
<style is:inline set:html={designThemeStyleSheet(theme)} />
|
|
328
|
+
<Fragment set:html={designFontsHead(await runtime.designPresets())} />
|
|
329
|
+
```
|
|
330
|
+
|
|
331
|
+
`designFontsHead(presets, { root? })` returns, in order: at most two
|
|
332
|
+
`<link rel="preload" as="font" type="font/woff2" href="…" crossorigin>` for the
|
|
333
|
+
faces GQ Design marks (the text styles' primary Latin files); a
|
|
334
|
+
`<style data-gqd-fonts>` with the `@font-face` rules (`font-display` as
|
|
335
|
+
delivered, `swap` from GQ Design), the fallback faces and the assigned slots'
|
|
336
|
+
`--gqd-font-*` stacks; and a `<style data-gqd-text-styles>` with the text
|
|
337
|
+
styles under `root` (default `.gqd-content`, the theme's root). The slot stacks
|
|
338
|
+
are set on `:root` and again on the root, because the theme stylesheet declares
|
|
339
|
+
the system stacks there. It is empty without fonts or text styles, or with no
|
|
340
|
+
families. Font URLs only come from the presets: faces with a relative URL or a
|
|
341
|
+
file on a Google host are dropped, so a visitor's browser never contacts
|
|
342
|
+
Google. Media hosts need a public CORS rule for cross-origin font files.
|
|
343
|
+
`designFontStyleSheet`, `designFontPreloads` (link descriptors for another
|
|
344
|
+
serializer) and `designTextStyleSheet` return the parts.
|
|
345
|
+
|
|
312
346
|
`presentationHtml(name, shell, presentation, { attributes, model? })` decorates an
|
|
313
347
|
existing root shell. Pass the complete block attributes for native Group layout
|
|
314
348
|
context. `presentationVariables` takes the same attributes context. Both delegate
|
package/dist/consent-html.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { S as SERVICE_CATALOG, T as copyLanguage, c as grantedCategories, d as promptReason, f as readConsentCookie, x as OPTIONAL_CATEGORIES } from "./state-BYWc5TUB.js";
|
|
2
2
|
import { a as CONSENT_COPY, c as legalRevisions, r as escapeHtml } from "./embeds-CJJemAmE.js";
|
|
3
|
-
import { t as CONSENT_UI_VERSION } from "./version-
|
|
3
|
+
import { t as CONSENT_UI_VERSION } from "./version-CmdZGJvZ.js";
|
|
4
4
|
import { t as CONSENT_CONFIG_ID } from "./client-config-B3LNSOxl.js";
|
|
5
5
|
import { t as CONSENT_PATH } from "./paths-Cmzzof3v.js";
|
|
6
6
|
//#region frontend/src/consent/html.ts
|
package/dist/consent.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { C as SERVICE_IDS, D as hostMatches, E as embedService, O as hostService, S as SERVICE_CATALOG, T as copyLanguage, _ as consentConfiguration, a as consentCookie, b as COPY_LANGUAGES, c as grantedCategories, d as promptReason, f as readConsentCookie, g as MEASUREMENT_ID, h as CONSENT_COPY_REVISION, i as DECISION_VALIDITY_MS, k as isServiceId, l as isConsentId, m as serviceGranted, n as CONSENT_COOKIE, o as decide, p as serializeConsentState, r as CONSENT_COOKIE_MAX_AGE_SECONDS, s as denyAll, t as CONSENT_ACTIONS, u as parseConsentState, v as needsBanner, w as catalogService, x as OPTIONAL_CATEGORIES, y as CONSENT_CATEGORIES } from "./state-BYWc5TUB.js";
|
|
2
2
|
import { a as parseConsentRecordRequest, i as isRecordToken, n as consentRecordRequest, r as isLegalRoleName, t as MAX_RECORD_BYTES } from "./records-Dumrz759.js";
|
|
3
3
|
import { a as CONSENT_COPY, c as legalRevisions, i as rewriteEmbeds, l as parseLegalLanguage, n as embedPlaceholder, o as LEGAL_ROLES, r as escapeHtml, s as REQUIRED_LEGAL_ROLES, t as blockedPlaceholder } from "./embeds-CJJemAmE.js";
|
|
4
|
-
import { t as CONSENT_UI_VERSION } from "./version-
|
|
4
|
+
import { t as CONSENT_UI_VERSION } from "./version-CmdZGJvZ.js";
|
|
5
5
|
export { CONSENT_ACTIONS, CONSENT_CATEGORIES, CONSENT_COOKIE, CONSENT_COOKIE_MAX_AGE_SECONDS, CONSENT_COPY, CONSENT_COPY_REVISION, CONSENT_UI_VERSION, COPY_LANGUAGES, DECISION_VALIDITY_MS, LEGAL_ROLES, MAX_RECORD_BYTES, MEASUREMENT_ID, OPTIONAL_CATEGORIES, REQUIRED_LEGAL_ROLES, SERVICE_CATALOG, SERVICE_IDS, blockedPlaceholder, catalogService, consentConfiguration, consentCookie, consentRecordRequest, copyLanguage, decide, denyAll, embedPlaceholder, embedService, escapeHtml, grantedCategories, hostMatches, hostService, isConsentId, isLegalRoleName, isRecordToken, isServiceId, legalRevisions, needsBanner, parseConsentRecordRequest, parseConsentState, parseLegalLanguage, promptReason, readConsentCookie, rewriteEmbeds, serializeConsentState, serviceGranted };
|