@styleflow.app/flowpress-astro-core 1.0.0-beta.5 → 1.0.0-beta.50
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/CHANGELOG.md +307 -1
- package/README.md +121 -6
- package/dist/accessibility-panel.d.ts +2 -0
- package/dist/accessibility-panel.d.ts.map +1 -0
- package/dist/accessibility-panel.js +81 -0
- package/dist/accessibility-panel.js.map +1 -0
- package/dist/astro/BaseLayout.astro +34 -17
- package/dist/astro/CompositionRenderer.astro +170 -0
- package/dist/astro/DefaultBlockAdapter.astro +37 -0
- package/dist/astro/EditorialMedia.astro +47 -0
- package/dist/astro/FontStylesheets.astro +35 -0
- package/dist/astro/GutenbergRenderer.astro +270 -84
- package/dist/astro/Media.astro +27 -0
- package/dist/astro/StyleflowElement.astro +25 -0
- package/dist/astro/ThemeRuntime.astro +26 -0
- package/dist/astro/blocks/CarouselBlock.astro +72 -101
- package/dist/astro/blocks/CarouselItemBlock.astro +4 -4
- package/dist/astro/blocks/ColumnBlock.astro +4 -5
- package/dist/astro/blocks/CoverBlock.astro +158 -0
- package/dist/astro/blocks/FormBlock.astro +23 -20
- package/dist/astro/blocks/GridBlock.astro +5 -4
- package/dist/astro/blocks/HeroBlock.astro +6 -6
- package/dist/astro/blocks/ImageBlock.astro +6 -6
- package/dist/astro/blocks/ListItemFallback.astro +9 -7
- package/dist/astro/blocks/NumberSpinnerBlock.astro +29 -22
- package/dist/astro/blocks/SemanticElement.astro +35 -0
- package/dist/astro/blocks/SiteLogoBlock.astro +54 -0
- package/dist/astro/blocks/TextBlock.astro +33 -28
- package/dist/astro/blocks/ThemeToggleBlock.astro +13 -0
- package/dist/astro/blocks/cover.d.ts +13 -0
- package/dist/astro/blocks/cover.d.ts.map +1 -0
- package/dist/astro/blocks/cover.js +105 -0
- package/dist/astro/blocks/cover.js.map +1 -0
- package/dist/astro/blocks/cover.ts +119 -0
- package/dist/astro/blocks/helpers.d.ts +10 -1
- package/dist/astro/blocks/helpers.d.ts.map +1 -1
- package/dist/astro/blocks/helpers.js +55 -39
- package/dist/astro/blocks/helpers.js.map +1 -1
- package/dist/astro/blocks/helpers.ts +69 -44
- package/dist/astro/motion/AccordionRuntime.astro +9 -0
- package/dist/astro/motion/MotionBoot.astro +21 -0
- package/dist/astro/motion/MotionRuntime.astro +31 -0
- package/dist/astro/motion/accordion.css +163 -0
- package/dist/astro/motion/accordion.d.ts +3 -0
- package/dist/astro/motion/accordion.d.ts.map +1 -0
- package/dist/astro/motion/accordion.js +98 -0
- package/dist/astro/motion/accordion.js.map +1 -0
- package/dist/astro/motion/accordion.ts +109 -0
- package/dist/astro/motion/motion-controller.d.ts +12 -0
- package/dist/astro/motion/motion-controller.d.ts.map +1 -0
- package/dist/astro/motion/motion-controller.js +312 -0
- package/dist/astro/motion/motion-controller.js.map +1 -0
- package/dist/astro/motion/motion-controller.ts +393 -0
- package/dist/astro/motion/motion.css +600 -0
- package/dist/astro/motion/motion.d.ts +132 -0
- package/dist/astro/motion/motion.d.ts.map +1 -0
- package/dist/astro/motion/motion.js +265 -0
- package/dist/astro/motion/motion.js.map +1 -0
- package/dist/astro/motion/motion.ts +430 -0
- package/dist/astro/native/AccordionRuntime.astro +11 -0
- package/dist/astro/native/Blob.astro +113 -0
- package/dist/astro/native/BlobBlock.astro +52 -0
- package/dist/astro/native/CustomFieldValue.astro +88 -0
- package/dist/astro/native/LevelTag.astro +20 -0
- package/dist/astro/native/MapBlock.astro +41 -0
- package/dist/astro/native/NativeHtmlBlock.astro +12 -0
- package/dist/astro/native/NativeIconBlock.astro +42 -0
- package/dist/astro/native/ProjectTimelineBlock.astro +34 -0
- package/dist/astro/native/ReservedLogin.astro +107 -0
- package/dist/astro/native/ResolvedBlocks.astro +91 -0
- package/dist/astro/native/SyncedPatternContent.astro +94 -0
- package/dist/astro/native/TermFieldValue.astro +39 -0
- package/dist/astro/native/Timeline.astro +22 -0
- package/dist/astro/native/TimelineCardBlock.astro +7 -0
- package/dist/astro/native/accordion-controller.d.ts +3 -0
- package/dist/astro/native/accordion-controller.d.ts.map +1 -0
- package/dist/astro/native/accordion-controller.js +143 -0
- package/dist/astro/native/accordion-controller.js.map +1 -0
- package/dist/astro/native/accordion-controller.ts +108 -0
- package/dist/astro/native/accordion.css +36 -0
- package/dist/astro/native/accordion.d.ts +24 -0
- package/dist/astro/native/accordion.d.ts.map +1 -0
- package/dist/astro/native/accordion.js +82 -0
- package/dist/astro/native/accordion.js.map +1 -0
- package/dist/astro/native/accordion.ts +91 -0
- package/dist/astro/native/blob/blob-shapes.generated.d.ts +2 -0
- package/dist/astro/native/blob/blob-shapes.generated.d.ts.map +1 -0
- package/dist/astro/native/blob/blob-shapes.generated.js +2 -0
- package/dist/astro/native/blob/blob-shapes.generated.js.map +1 -0
- package/dist/astro/native/blob/blob-shapes.generated.ts +1 -0
- package/dist/astro/native/blob/config.d.ts +49 -0
- package/dist/astro/native/blob/config.d.ts.map +1 -0
- package/dist/astro/native/blob/config.js +86 -0
- package/dist/astro/native/blob/config.js.map +1 -0
- package/dist/astro/native/blob/config.ts +132 -0
- package/dist/astro/native/blob/controller.d.ts +11 -0
- package/dist/astro/native/blob/controller.d.ts.map +1 -0
- package/dist/astro/native/blob/controller.js +240 -0
- package/dist/astro/native/blob/controller.js.map +1 -0
- package/dist/astro/native/blob/controller.ts +248 -0
- package/dist/astro/native/blob/geometry.d.ts +2 -0
- package/dist/astro/native/blob/geometry.d.ts.map +1 -0
- package/dist/astro/native/blob/geometry.js +2 -0
- package/dist/astro/native/blob/geometry.js.map +1 -0
- package/dist/astro/native/blob/geometry.ts +1 -0
- package/dist/astro/native/blob/ids.d.ts +7 -0
- package/dist/astro/native/blob/ids.d.ts.map +1 -0
- package/dist/astro/native/blob/ids.js +11 -0
- package/dist/astro/native/blob/ids.js.map +1 -0
- package/dist/astro/native/blob/ids.ts +11 -0
- package/dist/astro/native/blob.css +83 -0
- package/dist/astro/native/block-sizing.css +34 -0
- package/dist/astro/native/button-template.d.ts +31 -0
- package/dist/astro/native/button-template.d.ts.map +1 -0
- package/dist/astro/native/button-template.js +54 -0
- package/dist/astro/native/button-template.js.map +1 -0
- package/dist/astro/native/button-template.ts +92 -0
- package/dist/astro/native/button.d.ts +13 -0
- package/dist/astro/native/button.d.ts.map +1 -0
- package/dist/astro/native/button.js +26 -0
- package/dist/astro/native/button.js.map +1 -0
- package/dist/astro/native/button.ts +26 -0
- package/dist/astro/native/carousel.css +323 -0
- package/dist/astro/native/core-accordion-heading.astro +23 -0
- package/dist/astro/native/core-accordion-item.astro +8 -0
- package/dist/astro/native/core-accordion-panel.astro +8 -0
- package/dist/astro/native/core-accordion.astro +8 -0
- package/dist/astro/native/core-block.astro +18 -0
- package/dist/astro/native/core-button-fallback.astro +43 -0
- package/dist/astro/native/core-button.astro +65 -0
- package/dist/astro/native/core-buttons.astro +14 -0
- package/dist/astro/native/core-group.astro +25 -0
- package/dist/astro/native/core-home-link.astro +12 -0
- package/dist/astro/native/core-html.astro +8 -0
- package/dist/astro/native/core-icon.astro +7 -0
- package/dist/astro/native/core-image.astro +136 -0
- package/dist/astro/native/core-navigation-link.astro +71 -0
- package/dist/astro/native/core-navigation-submenu.astro +33 -0
- package/dist/astro/native/core-navigation.astro +101 -0
- package/dist/astro/native/core-page-list-data-item.astro +19 -0
- package/dist/astro/native/core-page-list-item.astro +8 -0
- package/dist/astro/native/core-page-list.astro +40 -0
- package/dist/astro/native/core-post-date.astro +21 -0
- package/dist/astro/native/core-post-excerpt.astro +26 -0
- package/dist/astro/native/core-post-featured-image.astro +40 -0
- package/dist/astro/native/core-post-template-fallback.astro +30 -0
- package/dist/astro/native/core-post-template.astro +23 -0
- package/dist/astro/native/core-post-terms.astro +47 -0
- package/dist/astro/native/core-post-title.astro +23 -0
- package/dist/astro/native/core-query-no-results.astro +12 -0
- package/dist/astro/native/core-query.astro +22 -0
- package/dist/astro/native/core-separator.astro +18 -0
- package/dist/astro/native/core-site-title.astro +16 -0
- package/dist/astro/native/core-term-description.astro +12 -0
- package/dist/astro/native/core-term-name.astro +21 -0
- package/dist/astro/native/core-term-template.astro +30 -0
- package/dist/astro/native/core-terms-query.astro +19 -0
- package/dist/astro/native/core-transparent.astro +11 -0
- package/dist/astro/native/flowpress-navigation-controller.d.ts +2 -0
- package/dist/astro/native/flowpress-navigation-controller.d.ts.map +1 -0
- package/dist/astro/native/flowpress-navigation-controller.js +217 -0
- package/dist/astro/native/flowpress-navigation-controller.js.map +1 -0
- package/dist/astro/native/flowpress-navigation-controller.ts +215 -0
- package/dist/astro/native/flowpress-navigation.css +18 -0
- package/dist/astro/native/grid-bleed.d.ts +2 -0
- package/dist/astro/native/grid-bleed.d.ts.map +1 -0
- package/dist/astro/native/grid-bleed.js +123 -0
- package/dist/astro/native/grid-bleed.js.map +1 -0
- package/dist/astro/native/grid.css +180 -0
- package/dist/astro/native/grid.d.ts +17 -0
- package/dist/astro/native/grid.d.ts.map +1 -0
- package/dist/astro/native/grid.js +108 -0
- package/dist/astro/native/grid.js.map +1 -0
- package/dist/astro/native/grid.ts +132 -0
- package/dist/astro/native/group.css +36 -0
- package/dist/astro/native/group.d.ts +15 -0
- package/dist/astro/native/group.d.ts.map +1 -0
- package/dist/astro/native/group.js +66 -0
- package/dist/astro/native/group.js.map +1 -0
- package/dist/astro/native/group.ts +61 -0
- package/dist/astro/native/html.d.ts +6 -0
- package/dist/astro/native/html.d.ts.map +1 -0
- package/dist/astro/native/html.js +10 -0
- package/dist/astro/native/html.js.map +1 -0
- package/dist/astro/native/html.ts +9 -0
- package/dist/astro/native/icon.d.ts +3 -0
- package/dist/astro/native/icon.d.ts.map +1 -0
- package/dist/astro/native/icon.js +23 -0
- package/dist/astro/native/icon.js.map +1 -0
- package/dist/astro/native/icon.ts +21 -0
- package/dist/astro/native/image.d.ts +5 -0
- package/dist/astro/native/image.d.ts.map +1 -0
- package/dist/astro/native/image.js +65 -0
- package/dist/astro/native/image.js.map +1 -0
- package/dist/astro/native/image.ts +56 -0
- package/dist/astro/native/inline-text.css +15 -0
- package/dist/astro/native/map.d.ts +14 -0
- package/dist/astro/native/map.d.ts.map +1 -0
- package/dist/astro/native/map.js +60 -0
- package/dist/astro/native/map.js.map +1 -0
- package/dist/astro/native/map.ts +70 -0
- package/dist/astro/native/motion-preference.d.ts +50 -0
- package/dist/astro/native/motion-preference.d.ts.map +1 -0
- package/dist/astro/native/motion-preference.js +132 -0
- package/dist/astro/native/motion-preference.js.map +1 -0
- package/dist/astro/native/motion-preference.ts +158 -0
- package/dist/astro/native/motion.d.ts +101 -0
- package/dist/astro/native/motion.d.ts.map +1 -0
- package/dist/astro/native/motion.js +168 -0
- package/dist/astro/native/motion.js.map +1 -0
- package/dist/astro/native/motion.ts +312 -0
- package/dist/astro/native/query-carousel.d.ts +13 -0
- package/dist/astro/native/query-carousel.d.ts.map +1 -0
- package/dist/astro/native/query-carousel.js +36 -0
- package/dist/astro/native/query-carousel.js.map +1 -0
- package/dist/astro/native/query-carousel.ts +60 -0
- package/dist/astro/native/query-loop.d.ts +38 -0
- package/dist/astro/native/query-loop.d.ts.map +1 -0
- package/dist/astro/native/query-loop.js +20 -0
- package/dist/astro/native/query-loop.js.map +1 -0
- package/dist/astro/native/query-loop.ts +67 -0
- package/dist/astro/native/registry.d.ts +3 -0
- package/dist/astro/native/registry.d.ts.map +1 -0
- package/dist/astro/native/registry.js +91 -0
- package/dist/astro/native/registry.js.map +1 -0
- package/dist/astro/native/registry.ts +93 -0
- package/dist/astro/native/sf-block-binding.astro +20 -0
- package/dist/astro/native/sf-post-field.astro +9 -0
- package/dist/astro/native/sf-slot.astro +6 -0
- package/dist/astro/native/sf-term-field.astro +9 -0
- package/dist/astro/native/timeline.css +4 -0
- package/dist/astro/native/timeline.d.ts +28 -0
- package/dist/astro/native/timeline.d.ts.map +1 -0
- package/dist/astro/native/timeline.js +43 -0
- package/dist/astro/native/timeline.js.map +1 -0
- package/dist/astro/native/timeline.ts +79 -0
- package/dist/astro/preferences/AccessibilityPanel.astro +105 -0
- package/dist/astro/preferences/ColorModeToggle.astro +26 -0
- package/dist/astro/preferences/MotionToggle.astro +27 -0
- package/dist/astro/preferences/PreferencesRuntime.astro +9 -0
- package/dist/astro/preferences/ThemeToggle.astro +30 -0
- package/dist/astro/preferences/Toggle.astro +50 -0
- package/dist/astro/preferences/preferences.css +125 -0
- package/dist/block-renderers.d.ts +23 -3
- package/dist/block-renderers.d.ts.map +1 -1
- package/dist/block-renderers.js.map +1 -1
- package/dist/build-cache.d.ts +8 -0
- package/dist/build-cache.d.ts.map +1 -0
- package/dist/build-cache.js +82 -0
- package/dist/build-cache.js.map +1 -0
- package/dist/carousel.d.ts +56 -6
- package/dist/carousel.d.ts.map +1 -1
- package/dist/carousel.js +183 -27
- package/dist/carousel.js.map +1 -1
- package/dist/client.d.ts +34 -2
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +124 -42
- package/dist/client.js.map +1 -1
- package/dist/composition.d.ts +14 -0
- package/dist/composition.d.ts.map +1 -0
- package/dist/composition.js +125 -0
- package/dist/composition.js.map +1 -0
- package/dist/default-blocks.d.ts +9 -0
- package/dist/default-blocks.d.ts.map +1 -0
- package/dist/default-blocks.js +122 -0
- package/dist/default-blocks.js.map +1 -0
- package/dist/env.d.ts +21 -0
- package/dist/env.d.ts.map +1 -1
- package/dist/env.js +53 -0
- package/dist/env.js.map +1 -1
- package/dist/index.d.ts +7 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +6 -0
- package/dist/index.js.map +1 -1
- package/dist/media.d.ts +20 -0
- package/dist/media.d.ts.map +1 -0
- package/dist/media.js +106 -0
- package/dist/media.js.map +1 -0
- package/dist/motion-preference.d.ts +50 -0
- package/dist/motion-preference.d.ts.map +1 -0
- package/dist/motion-preference.js +132 -0
- package/dist/motion-preference.js.map +1 -0
- package/dist/preferences-runtime.d.ts +3 -0
- package/dist/preferences-runtime.d.ts.map +1 -0
- package/dist/preferences-runtime.js +23 -0
- package/dist/preferences-runtime.js.map +1 -0
- package/dist/preferences-styleflow.d.ts +3 -0
- package/dist/preferences-styleflow.d.ts.map +1 -0
- package/dist/preferences-styleflow.js +14 -0
- package/dist/preferences-styleflow.js.map +1 -0
- package/dist/preferences.d.ts +4 -0
- package/dist/preferences.d.ts.map +1 -0
- package/dist/preferences.js +4 -0
- package/dist/preferences.js.map +1 -0
- package/dist/reserved-area.d.ts +10 -0
- package/dist/reserved-area.d.ts.map +1 -0
- package/dist/reserved-area.js +93 -0
- package/dist/reserved-area.js.map +1 -0
- package/dist/styleflow.d.ts +18 -1
- package/dist/styleflow.d.ts.map +1 -1
- package/dist/styleflow.js +82 -11
- package/dist/styleflow.js.map +1 -1
- package/dist/svg-media-runtime.d.ts +3 -0
- package/dist/svg-media-runtime.d.ts.map +1 -0
- package/dist/svg-media-runtime.js +33 -0
- package/dist/svg-media-runtime.js.map +1 -0
- package/dist/svg-media-types.d.ts +11 -0
- package/dist/svg-media-types.d.ts.map +1 -0
- package/dist/svg-media-types.js +2 -0
- package/dist/svg-media-types.js.map +1 -0
- package/dist/svg-media.d.ts +13 -0
- package/dist/svg-media.d.ts.map +1 -0
- package/dist/svg-media.js +47 -0
- package/dist/svg-media.js.map +1 -0
- package/dist/template-hierarchy.d.ts +0 -7
- package/dist/template-hierarchy.d.ts.map +1 -1
- package/dist/template-hierarchy.js +0 -21
- package/dist/template-hierarchy.js.map +1 -1
- package/dist/text.d.ts +3 -0
- package/dist/text.d.ts.map +1 -0
- package/dist/text.js +6 -0
- package/dist/text.js.map +1 -0
- package/dist/theme-runtime.d.ts +16 -0
- package/dist/theme-runtime.d.ts.map +1 -0
- package/dist/theme-runtime.js +100 -0
- package/dist/theme-runtime.js.map +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/types.d.ts +75 -1
- package/dist/types.d.ts.map +1 -1
- package/dist/types.js.map +1 -1
- package/dist/vivid-colors-preference.d.ts +31 -0
- package/dist/vivid-colors-preference.d.ts.map +1 -0
- package/dist/vivid-colors-preference.js +102 -0
- package/dist/vivid-colors-preference.js.map +1 -0
- package/package.json +58 -7
- package/dist/astro/DefaultTemplate.astro +0 -42
- package/dist/templates.d.ts +0 -19
- package/dist/templates.d.ts.map +0 -1
- package/dist/templates.js +0 -20
- package/dist/templates.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,313 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 1.0.0-beta.50 — 2026-11-23
|
|
4
|
+
|
|
5
|
+
- Accordion nativo:
|
|
6
|
+
- Il pulsante non riceve più come `title` HTML il titolo rich text, che mostrava i tag come tooltip.
|
|
7
|
+
- Il markup del server riporta lo stato iniziale in `aria-expanded`. Con lo scripting attivo un foglio di stile tiene chiusi gli elementi chiusi fino all'avvio del runtime, quindi il contenuto non si sposta al caricamento né dopo la navigazione client. Senza JavaScript tutto resta leggibile.
|
|
8
|
+
- Il pannello conserva il proprio `display` durante l'animazione (i ruoli `stack` restano flex con il loro gap) e anima anche il padding verticale. Il livello del titolo segue `headingLevel` del gruppo, come nell'editor. Un SVG del registro non valido usa il simbolo nativo con un avviso, invece di far fallire la pagina.
|
|
9
|
+
- Verifiche statiche e SSR dei valori effettivi dei pattern sincronizzati (già su `main`).
|
|
10
|
+
- [Rapporto canonico](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-11-23-revisione-slot-accordion-qbd.md).
|
|
11
|
+
|
|
12
|
+
## 1.0.0-beta.49 — 2026-11-17
|
|
13
|
+
|
|
14
|
+
- Propaga le impostazioni dell’accordion anche nei blocchi risolti di pattern e loop, senza modificare i dati sorgente.
|
|
15
|
+
- Conserva la modalità a due icone e il cambio immediato anche quando un riferimento SVG non è disponibile, usando il simbolo nativo come fallback.
|
|
16
|
+
- [Rapporto canonico](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-11-17-accordion-nativo.md).
|
|
17
|
+
|
|
18
|
+
## 1.0.0-beta.48 — 2026-11-17
|
|
19
|
+
|
|
20
|
+
- Aggiunge i quattro adapter ufficiali della famiglia `core/accordion`, catalogo default v8, props StyleFlow sul pulsante e icone configurabili risolte dal CMS.
|
|
21
|
+
- Runtime autonomo con scorrimento e rotazione da variabili CSS globali, tastiera, autoclose, hash, gruppi annidati, cleanup Astro e contenuti leggibili senza JavaScript. I renderer `sf/*` rimangono disponibili.
|
|
22
|
+
- [Rapporto canonico](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-11-17-accordion-nativo.md).
|
|
23
|
+
|
|
24
|
+
## 1.0.0-beta.47 — 2026-11-16
|
|
25
|
+
|
|
26
|
+
- Add the official `sf/slot` adapter. WordPress materializes each instance's blocks as `innerBlocks`; Astro renders only those children, with no wrapper, HTML attributes or visual context from the slot.
|
|
27
|
+
- Preserve the rendered parent and inherited tone through nested slots. Responsive grids count and decorate the actual slot children, including empty and nested slots, so spans and edge bleed match the DOM.
|
|
28
|
+
- Verify empty and populated slots, inherited context, synced-pattern content and responsive grid children through both Gutenberg and Site Editor renderer builds.
|
|
29
|
+
- Depend on `@styleflow.app/flowpress-components` 1.0.0-beta.19 for the shared structural slot contract.
|
|
30
|
+
- [Canonical report](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-11-16-slot-pattern-sincronizzati.md).
|
|
31
|
+
|
|
32
|
+
## 1.0.0-beta.46 — 2026-11-04
|
|
33
|
+
|
|
34
|
+
- Menu toggle of `core/navigation`: the two bars sit 0.5rem apart and the cross is centred on the button. `flowpress-navigation.css` placed the bars at 35%/65% with `inset-inline: 0` and won over the `motion.css` insets, while `motion.css` still applied its centred transforms, so every offset counted twice: bars 14px apart and 10px left of the icon, cross 10px above the button centre (seen on friviera.it).
|
|
35
|
+
- `flowpress-navigation.css`: the static bars (pages without `motion.css`) use the same centred geometry as `motion.css` and zero specificity (`:where()`), so the two stylesheets compose in any order. The icon is centred in the 2.75rem button (`margin-inline: auto`).
|
|
36
|
+
- `motion.css`: the closed bars include the `-50%` of their own height, so the pair is symmetric around the icon centre (it sat 1px low), and bars are `0.125rem` thick, the 2px every navigation rendered so far. The `--bars` variant is unchanged.
|
|
37
|
+
- New renderer fixture pages `navigation-toggle` (with `motion.css`) and `navigation-static` (without) and browser check `tests/browser/navigation-toggle.js` (gap, vertical centre and cross centre, full and reduced motion).
|
|
38
|
+
- [Canonical report](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-11-04-toggle-menu-navigazione.md).
|
|
39
|
+
|
|
40
|
+
## 1.0.0-beta.45 — 2026-11-04
|
|
41
|
+
|
|
42
|
+
- `sf/carousel` slides animate again. The track used `sf-motion-disable`, whose `transition: none !important` overrode the transition Splide writes inline on the list (slide) and on the slides (fade), so every move jumped. The track now uses the new `sf-reveal-skip`.
|
|
43
|
+
- New `sf-reveal-skip` class (`SF_REVEAL_SKIP_CLASS`): opts a subtree out of reveals exactly like `sf-motion-disable` (controller, pre-paint boot CSS, authored `.sf-reveal` kept visible) but leaves its transitions and animations running. `sf-motion-disable` is unchanged.
|
|
44
|
+
- New renderer fixture page `carousel-motion` and browser check `tests/browser/carousel-motion.js` (slide, centred loop and fade under the motion runtime, full and reduced motion).
|
|
45
|
+
- [Activity report](docs/activities/2026-11-04-1112-carousel-slide-transition.md).
|
|
46
|
+
|
|
47
|
+
## 1.0.0-beta.44 — 2026-11-04
|
|
48
|
+
|
|
49
|
+
- `sf/carousel` follows the extended contract of Components beta.18: fractional items per view, fixed slide width and peek per breakpoint (`fixedWidth`, `padding`), centred focus, aspect ratio, equal height, fade, rewind, start index, free drag, wheel, arrow position/shape/size with a mobile position, dots, bars or a fraction counter, and controls background from StyleFlow tone and intensity. Carousels saved with the original fields mount with exactly the same Splide options.
|
|
50
|
+
- New shared stylesheet `native/carousel.css` (also exported) and `carouselLayout()`: the page before Splide mounts shows the same geometry as the mounted carousel at rest, without relying on `splide-core.css`. WordPress Core copies the stylesheet verbatim for the block editor; `tests/fixtures/carousel-layout.json` is shared with its port. Arrows are SVG chevrons and dots are visible by default.
|
|
51
|
+
- Slides no longer reveal one by one (`sf-motion-disable` on the track), so loop clones never stay hidden; the carousel also follows the site's reduced-motion switch. The root keeps native flex-item sizing (`--fp-flex-basis`) next to the carousel geometry.
|
|
52
|
+
- Depend on `@styleflow.app/flowpress-components` 1.0.0-beta.18.
|
|
53
|
+
- [Canonical report](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-11-04-carosello-completo.md).
|
|
54
|
+
|
|
55
|
+
## 1.0.0-beta.43 — 2026-10-30
|
|
56
|
+
|
|
57
|
+
- Retry GraphQL query documents after a timeout, a network failure or HTTP 429/502/503/504. Every attempt has a fresh timeout that also covers the response body, backoff starts at `retryDelayMs` and doubles, and each retry logs one warning. Mutations, GraphQL errors and other statuses are never replayed. Defaults: 15000 ms per attempt and 1 retry.
|
|
58
|
+
- Add `readFlowpressGraphqlOptions()` for `FLOWPRESS_GRAPHQL_TIMEOUT_MS` and `FLOWPRESS_GRAPHQL_RETRIES`. It refuses budgets that reach the shared 120 s lock of the build request store. The build store keeps storing only final successes.
|
|
59
|
+
- [Canonical report](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-30-graphql-cold-start-retry.md).
|
|
60
|
+
|
|
61
|
+
## 1.0.0-beta.42 — 2026-10-27
|
|
62
|
+
|
|
63
|
+
- Add the one-shot `sf-reveal--zoom-in` preset: the editorial media scales from 1.25 to 1 over 2000 ms inside a stationary clipping frame, without fading or moving the block or caption.
|
|
64
|
+
- Share SSR media frames across native Image, Post Featured Image, Styleflow Image and Gallery items; preserve intrinsic dimensions, responsive geometry, crop/focal settings, inline SVG and link semantics.
|
|
65
|
+
- Wait for inner media transitions, including stagger delays, before settling; keep focus, deep links, print and reduced-motion fallbacks immediate. Preserve priority metadata when an image becomes inline SVG.
|
|
66
|
+
- [Canonical release and adoption report](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-27-reveal-zoom-immagini.md).
|
|
67
|
+
|
|
68
|
+
## 1.0.0-beta.41 — 2026-10-27
|
|
69
|
+
|
|
70
|
+
- Fill the assigned layout space by default for structural blocks and editorial images, while allowing Styleflow recipes and responsive CSS widths to override the defaults.
|
|
71
|
+
- Preserve fixed flex sizing, grid spans, image crop/focal settings, and authored image dimensions; remove stronger Cover/Grid width resets.
|
|
72
|
+
- Keep normal and wide Separator widths consistent with the WordPress canvas.
|
|
73
|
+
- [Canonical report](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-27-larghezze-blocchi.md).
|
|
74
|
+
|
|
75
|
+
## 1.0.0-beta.40 — 2026-10-27
|
|
76
|
+
|
|
77
|
+
- Honor native Image aspect ratios, cover/contain/fill scale and focal points on the actual media in Gutenberg and Site Editor rendering.
|
|
78
|
+
- Preserve authored CSS dimensions and responsive sources without letting intrinsic attachment dimensions override the selected ratio; keep captions and links outside the crop.
|
|
79
|
+
- Cover nested synced patterns, native units, invalid inputs and inline SVG presentation.
|
|
80
|
+
- [Canonical verification](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-27-core-image-proporzioni-focale.md).
|
|
81
|
+
|
|
82
|
+
## 1.0.0-beta.39 — 2026-10-26
|
|
83
|
+
|
|
84
|
+
- Let structural sections and constrained Groups fill aligned Cover content while preserving authored maximum widths.
|
|
85
|
+
- [Canonical verification](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-26-adozione-simab.md).
|
|
86
|
+
|
|
87
|
+
## 1.0.0-beta.38 — 2026-10-26
|
|
88
|
+
|
|
89
|
+
- Preserve the available width of responsive FlowPress grids inside aligned Cover content instead of shrinking columns to their intrinsic minimum.
|
|
90
|
+
- [Canonical verification](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-26-adozione-simab.md).
|
|
91
|
+
|
|
92
|
+
## 1.0.0-beta.37 — 2026-10-26
|
|
93
|
+
|
|
94
|
+
- Scan immutable SVG media trees once per render request, preserving nested/resolved media, scoped SVG IDs, and the explicit registration API for mutable caller data.
|
|
95
|
+
- [Canonical verification](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-26-prestazioni-oauth-dmo.md).
|
|
96
|
+
|
|
97
|
+
## 1.0.0-beta.36 — 2026-10-26
|
|
98
|
+
|
|
99
|
+
- Align StyleFlow Astro beta.11 and Components beta.16 so every default/native renderer shares the compiled design contract instead of allocating it for every primitive.
|
|
100
|
+
- [Canonical verification](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-26-prestazioni-oauth-dmo.md).
|
|
101
|
+
|
|
102
|
+
## 1.0.0-beta.35 — 2026-10-26
|
|
103
|
+
|
|
104
|
+
- Add a fresh CMS content revision API and an optional request store; HTTP remains the default.
|
|
105
|
+
- Export a separate Node build store for private, revision-bound data shared across processes. Authenticated queries, mutations and failed responses bypass storage.
|
|
106
|
+
- [Canonical report](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-26-prestazioni-oauth-dmo.md).
|
|
107
|
+
|
|
108
|
+
## 1.0.0-beta.34 — 2026-10-20
|
|
109
|
+
|
|
110
|
+
- Make page loading composition-only and retire content-loader and conventional Astro template APIs.
|
|
111
|
+
- Remove pilot block aliases and media proxies; redirect historical file URLs to their real origins while preserving editorial /media pages.
|
|
112
|
+
- [Canonical report](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-20-sync-site-editor-ritiro-legacy.md).
|
|
113
|
+
|
|
114
|
+
## 1.0.0-beta.33 — 2026-10-15
|
|
115
|
+
|
|
116
|
+
- Preserve inherited surfaces and layout on native blocks rendered in nested semantic passes, including dynamic query titles.
|
|
117
|
+
- Point README installation and release instructions to the current pins and canonical release evidence.
|
|
118
|
+
- [Canonical verification](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-14-consolidamento-tessari.md).
|
|
119
|
+
|
|
120
|
+
## 1.0.0-beta.32 — 2026-10-15
|
|
121
|
+
|
|
122
|
+
- Preserve project renderer overrides through Query Loop, Query Carousel and synced-pattern resolved passes, including semantic rendering without a composition registry.
|
|
123
|
+
- Add an actual Astro build regression with custom renderers in all three paths.
|
|
124
|
+
- [Canonical integration report](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-14-consolidamento-tessari.md).
|
|
125
|
+
|
|
126
|
+
## 1.0.0-beta.31 — 2026-10-14
|
|
127
|
+
|
|
128
|
+
- Official renderers, inline SVG, inherited color validation, preferences, portable motion and accordion runtimes.
|
|
129
|
+
- Preserve inline typography and explicit inherited tones; provide readable uninitialized carousels.
|
|
130
|
+
- [Canonical integration report](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-14-consolidamento-tessari.md).
|
|
131
|
+
|
|
132
|
+
|
|
133
|
+
## 1.0.0-beta.30 — 2026-10-09
|
|
134
|
+
|
|
135
|
+
- Ship native `core/icon` structural CSS with the Astro renderer: apply validated WordPress widths, proportional SVG dimensions and alignment, and paint icons from the StyleFlow foreground through `currentColor`.
|
|
136
|
+
- Verify native/project icons in traditional Gutenberg and Site Editor compositions, including inherited colors, accessible labels, invalid width fallback and scoped SVG IDs.
|
|
137
|
+
- [Canonical verification](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-09-core-icon-frontend.md).
|
|
138
|
+
|
|
139
|
+
## 1.0.0-beta.29 — 2026-10-08
|
|
140
|
+
|
|
141
|
+
- Extend the escaped plain-text entity decoding to buttons, cards, spinner segments, excerpts, timeline, list fallbacks, forms and accessibility labels. Keep RichText fragments unchanged.
|
|
142
|
+
- [Canonical verification](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-08-tipografia-tag-mapping.md).
|
|
143
|
+
|
|
144
|
+
## 1.0.0-beta.28 — 2026-10-08
|
|
145
|
+
|
|
146
|
+
- Decode WordPress entities once for escaped plain text across site titles, navigation, terms, custom fields and metadata.
|
|
147
|
+
- Add the official core/separator adapter with Styleflow props and a line painted from foreground via currentColor; preserve wide and dots variants.
|
|
148
|
+
- [Canonical verification](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-08-tipografia-tag-mapping.md).
|
|
149
|
+
|
|
150
|
+
## 1.0.0-beta.27 — 2026-10-08
|
|
151
|
+
|
|
152
|
+
- Render Gutenberg defaults through HTML tag mapping without text data attributes across official blocks, native adapters and independent Number Spinner segments. Preserve explicit typography overrides.
|
|
153
|
+
- [Canonical verification](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-08-tipografia-tag-mapping.md).
|
|
154
|
+
|
|
155
|
+
## 1.0.0-beta.26 — 2026-10-08
|
|
156
|
+
|
|
157
|
+
- Keep inherited panel visibility out of generic transitions and disable transitions throughout the panel when motion is reduced, so every switch receives keyboard focus reliably.
|
|
158
|
+
- [Canonical verification](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-08-pannello-accessibilita-default.md).
|
|
159
|
+
|
|
160
|
+
## 1.0.0-beta.25 — 2026-10-08
|
|
161
|
+
|
|
162
|
+
- Focus the first accessibility switch after the panel becomes visible; cancel pending focus on close and cleanup.
|
|
163
|
+
- [Canonical verification](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-08-pannello-accessibilita-default.md).
|
|
164
|
+
|
|
165
|
+
## 1.0.0-beta.24 — 2026-10-08
|
|
166
|
+
|
|
167
|
+
- Validate the accessibility trigger intensity against the current project contract, including Starter designs with only main/base.
|
|
168
|
+
- [Canonical verification](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-08-pannello-accessibilita-default.md).
|
|
169
|
+
|
|
170
|
+
## 1.0.0-beta.23 — 2026-10-08
|
|
171
|
+
|
|
172
|
+
- Promote the pilot accessibility panel and theme/motion/vivid-color switches to public, styled defaults. Preserve visitor preferences and keyboard behavior; ship geometry without consumer Tailwind scanning.
|
|
173
|
+
- [Canonical verification](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-08-pannello-accessibilita-default.md).
|
|
174
|
+
|
|
175
|
+
## 1.0.0-beta.22 — 2026-10-08
|
|
176
|
+
|
|
177
|
+
- Expose shared site defaults and initialize BaseLayout without locking nested themes. Complete default adapter catalog v4 from both pilots and restore active grid bleed for container items.
|
|
178
|
+
- [Canonical verification](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-08-default-css-adapter-bleed.md).
|
|
179
|
+
|
|
180
|
+
## 1.0.0-beta.21 — 2026-10-08
|
|
181
|
+
|
|
182
|
+
- Apply responsive native grid columns, child spans and container bleed in Site Editor compositions, including structural CSS and the bleed runtime. Preserve saved breakpoint values and cap rendered spans to the parent grid.
|
|
183
|
+
- [Cloudflare and responsive grid verification](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-08-cloudflare-rendering-commonjs.md).
|
|
184
|
+
|
|
185
|
+
## 1.0.0-beta.20 — 2026-10-07
|
|
186
|
+
|
|
187
|
+
- Normalize composition route SEO exactly like the route query: JSON-LD, Twitter metadata and image alt text remain intact when using the single-call page loader. Also accept already normalized composition SEO.
|
|
188
|
+
- Retain beta.19 media/query/runtime optimizations. [Canonical verification](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-07-media-diretti-runtime.md).
|
|
189
|
+
|
|
190
|
+
## 1.0.0-beta.19 — 2026-10-07
|
|
191
|
+
|
|
192
|
+
- Publish the direct-media and editorial/runtime optimizations described below with a lockfile verified by clean installation and StyleFlow beta.9.
|
|
193
|
+
- Supersedes the unpublished beta.18 candidate; its immutable Git tag is retained.
|
|
194
|
+
|
|
195
|
+
## 1.0.0-beta.18 — unpublished candidate, 2026-10-07
|
|
196
|
+
|
|
197
|
+
- Deliver media at their real WordPress/R2 origin; undo legacy frontend aliases without inventing offload URLs. Preserve mixed libraries, srcset and external URLs. Proxy exports are deprecated compatibility APIs.
|
|
198
|
+
- Add `getPage` to reuse the route already returned by Site Editor compositions and optional `includeContent: false` (WordPress Core beta.19) for unused HTML. Existing APIs retain their defaults; previews are not cached across requests.
|
|
199
|
+
- Prepare descriptor/diagnostic indexes once per recursive composition, share unchanged media payload branches and consume StyleFlow Astro beta.9 contract indexes.
|
|
200
|
+
- [Canonical verification](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-07-media-diretti-runtime.md).
|
|
201
|
+
|
|
202
|
+
## 1.0.0-beta.17 — 2026-10-07
|
|
203
|
+
|
|
204
|
+
- Official native and sf/* renderers at every nesting depth; responsive grids and measured container bleed, maps, neutral organic shapes, timeline and accessible navigation.
|
|
205
|
+
- Canonical behavior, migration and verification: [pilot integration](https://github.com/StyleFlow-App/styleflow-docs/blob/main/wiki/piloti-flowpress.md), [report](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-07-integrazione-piloti-flowpress.md).
|
|
206
|
+
|
|
3
207
|
## Unreleased
|
|
208
|
+
- Agent rules only, no runtime or API change: `AGENTS.md` names the canonical
|
|
209
|
+
docs vault path (2026-10-18) and requires every published change to be
|
|
210
|
+
merged into `main`, with its branches, worktrees and stashes removed in the
|
|
211
|
+
same task.
|
|
212
|
+
[Canonical report](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-19-branch-residui-e-regole-di-chiusura.md).
|
|
213
|
+
|
|
214
|
+
## 1.0.0-beta.16
|
|
215
|
+
|
|
216
|
+
- Rebase owned composition media to the current frontend, including nested
|
|
217
|
+
query data, authoring attributes and responsive sources. WordPress uploads
|
|
218
|
+
keep `/app/uploads/`; offloaded assets keep `/media/`. External media and
|
|
219
|
+
raw HTML remain unchanged.
|
|
220
|
+
- Export `rewriteFlowpressMediaUrl`, `rewriteFlowpressMediaUrls` and explicit
|
|
221
|
+
frontend/backend/offload origin options for project integrations.
|
|
222
|
+
- Follow storage redirects server-side with a bounded redirect count. Proxy
|
|
223
|
+
responses no longer expose backend/CDN `Location` headers to the browser.
|
|
224
|
+
|
|
225
|
+
## 1.0.0-beta.15
|
|
226
|
+
|
|
227
|
+
- Fixed `proxyFlowpressMedia` forwarding the `/media/` route prefix to the
|
|
228
|
+
upstream `FLOWPRESS_MEDIA` origin. `/media/` is a frontend-only routing
|
|
229
|
+
marker with no equivalent on either upstream (an offload CDN root, or the
|
|
230
|
+
WordPress backend as a fallback), so it is now stripped before the request
|
|
231
|
+
is forwarded: `/media/2026/09/x.jpg` resolves to `<origin>/2026/09/x.jpg`
|
|
232
|
+
instead of `<origin>/media/2026/09/x.jpg`, which 404s.
|
|
233
|
+
- `proxyFlowpressUpload` (`/app/uploads/`) is unaffected: that prefix mirrors
|
|
234
|
+
a real path on the WordPress backend and continues to be forwarded as-is.
|
|
235
|
+
|
|
236
|
+
## 1.0.0-beta.14
|
|
237
|
+
|
|
238
|
+
- Adopted `@styleflow.app/astro@1.0.0-beta.7` and Typography vNext contract
|
|
239
|
+
axes with per-type `weightsByType` and partial HTML `tagMappings`.
|
|
240
|
+
- Updated the real renderer fixture to build format `2.0.0` bundles while
|
|
241
|
+
preserving the complete Cover, carousel, composition and Gutenberg suite.
|
|
242
|
+
- Added strict regression coverage for weights disabled on a selected type.
|
|
243
|
+
|
|
244
|
+
## 1.0.0-beta.13
|
|
245
|
+
|
|
246
|
+
- Added `scrimOpacity` as an explicit `0–100` percentage for the official
|
|
247
|
+
Cover renderer, clamped at the public boundary and emitted through a scoped
|
|
248
|
+
CSS custom property.
|
|
249
|
+
- Preserved legacy Cover content by using native `dimRatio` as the opacity
|
|
250
|
+
fallback only when `scrimOpacity` is absent or invalid.
|
|
251
|
+
|
|
252
|
+
## 1.0.0-beta.12
|
|
253
|
+
|
|
254
|
+
- Added the official `core/cover` renderer and editable default adapter with
|
|
255
|
+
image/video media, focal point, validated minimum height, nested content and
|
|
256
|
+
Styleflow root props.
|
|
257
|
+
- Added prefixed Styleflow coordinates for semantic scrims and kept native
|
|
258
|
+
`dimRatio` only as a temporary compatibility switch, never as raw CSS.
|
|
259
|
+
- Added a `default` root export so Node CommonJS resolution can locate the ESM
|
|
260
|
+
entry used by project scaffolding commands.
|
|
261
|
+
|
|
262
|
+
## 1.0.0-beta.11
|
|
263
|
+
|
|
264
|
+
- Made the official default adapter usable by both Site Editor compositions
|
|
265
|
+
and traditional Gutenberg rendering.
|
|
266
|
+
- Kept nested project overrides active in traditional rendering while applying
|
|
267
|
+
composition fingerprint gates only when a composition is present.
|
|
268
|
+
|
|
269
|
+
## 1.0.0-beta.10
|
|
270
|
+
|
|
271
|
+
- Added a versioned catalog of official default block adapters and a public
|
|
272
|
+
source generator for editable project overrides.
|
|
273
|
+
- Let an official default render a block without recursively selecting the
|
|
274
|
+
override currently wrapping it, while preserving certified overrides for
|
|
275
|
+
every nested child.
|
|
276
|
+
- Added reusable `FLOWPRESS_MEDIA` resolution, Astro image remote patterns and
|
|
277
|
+
safe upload/media proxy helpers with `GET`, `HEAD`, range and cache support.
|
|
278
|
+
- Extended normalized block HTML props with an explicit safe attribute
|
|
279
|
+
allowlist; Gutenberg event handlers, inline styles and Styleflow-owned data
|
|
280
|
+
attributes remain blocked.
|
|
281
|
+
|
|
282
|
+
## 1.0.0-beta.9
|
|
283
|
+
|
|
284
|
+
- Validated typography variants against the union of contract variants when
|
|
285
|
+
the block adapter has not yet supplied its typography type, preventing the
|
|
286
|
+
composition registry from rejecting valid heading-only variants early.
|
|
287
|
+
|
|
288
|
+
## 1.0.0-beta.8
|
|
289
|
+
|
|
290
|
+
- Normalized finite numeric CMS values for enumerated Styleflow axes to their
|
|
291
|
+
canonical contract strings, so typography variants such as WordPress `v=0`
|
|
292
|
+
remain valid in strict production builds without emitting a fallback.
|
|
293
|
+
|
|
294
|
+
## 1.0.0-beta.7
|
|
295
|
+
|
|
296
|
+
- Fixed theme-aware logo selection by placing fallback visibility variables on
|
|
297
|
+
the document root, allowing the nearest global or nested Styleflow theme to
|
|
298
|
+
override them while preserving per-block logo overrides.
|
|
299
|
+
|
|
300
|
+
## 1.0.0-beta.6
|
|
301
|
+
|
|
302
|
+
- Added required `htmlProps`, `styleflowProps`, composition and deterministic
|
|
303
|
+
render context to every certified block adapter.
|
|
304
|
+
- Added single-emission composition stylesheets for validated WordPress block
|
|
305
|
+
CSS, plus theme-aware positive/negative Site Logo rendering.
|
|
306
|
+
- Added the no-hydration multi-theme runtime and `sf/theme-toggle` adapter.
|
|
307
|
+
- Made `<S.*>` the only public Astro authoring syntax in package sources.
|
|
308
|
+
- Added `FlowpressCompositionV1`, typed `resolvedData`,
|
|
309
|
+
`FlowpressClient.getComposition()` and recursive production fail-closed
|
|
310
|
+
rendering with exact compatibility commands in development.
|
|
4
311
|
|
|
5
312
|
## 1.0.0-beta.5
|
|
6
313
|
|
|
@@ -44,7 +351,6 @@
|
|
|
44
351
|
- Updated the exact `@styleflow.app/astro` dependency to `1.0.0-beta.1`,
|
|
45
352
|
keeping consumer trees on one runtime while adopting deterministic CLI
|
|
46
353
|
reports. Runtime behavior is unchanged.
|
|
47
|
-
|
|
48
354
|
## 1.0.0-beta.0
|
|
49
355
|
|
|
50
356
|
- Adopted the grouped Styleflow vNext project contract and the exact Astro v1
|
package/README.md
CHANGED
|
@@ -6,11 +6,14 @@ CMS values.
|
|
|
6
6
|
|
|
7
7
|
The package must not import from an application or project plugin.
|
|
8
8
|
|
|
9
|
+
Editorial media frames and the `sf-reveal--zoom-in` motion preset are documented
|
|
10
|
+
in the [canonical motion guide](https://github.com/StyleFlow-App/styleflow-docs/blob/main/wiki/motion.md).
|
|
11
|
+
|
|
9
12
|
## Install
|
|
10
13
|
|
|
11
14
|
```bash
|
|
12
|
-
pnpm add @styleflow.app/flowpress-astro-core@1.0.0-beta.
|
|
13
|
-
@styleflow.app/astro@1.0.0-beta.
|
|
15
|
+
pnpm add @styleflow.app/flowpress-astro-core@1.0.0-beta.44 \
|
|
16
|
+
@styleflow.app/astro@1.0.0-beta.11
|
|
14
17
|
```
|
|
15
18
|
|
|
16
19
|
Prereleases are pinned exactly. The package expects Astro 7 or newer and the
|
|
@@ -32,10 +35,23 @@ remain hidden unless `debug: true` is explicitly set for local development.
|
|
|
32
35
|
```ts
|
|
33
36
|
const client = new FlowpressClient({
|
|
34
37
|
endpoint: process.env.BACKEND_GRAPHQL_URL!,
|
|
35
|
-
debug: process.env.APP_ENV === "local"
|
|
38
|
+
debug: process.env.APP_ENV === "local",
|
|
39
|
+
...readFlowpressGraphqlOptions(process.env)
|
|
36
40
|
});
|
|
37
41
|
```
|
|
38
42
|
|
|
43
|
+
Each attempt has its own `timeoutMs` (default 15000 ms, covering the body
|
|
44
|
+
as well as the headers). Query documents are retried `retries` times (default 1)
|
|
45
|
+
after a timeout, a network failure or HTTP 429/502/503/504, with backoff that
|
|
46
|
+
starts at `retryDelayMs` (default 1000 ms) and doubles. Each retry logs one
|
|
47
|
+
`console.warn` with the operation, the attempt and the elapsed time.
|
|
48
|
+
Mutations, GraphQL `errors` and other HTTP statuses are never replayed. A build
|
|
49
|
+
request store receives only the final successful response.
|
|
50
|
+
`readFlowpressGraphqlOptions()` reads optional `FLOWPRESS_GRAPHQL_TIMEOUT_MS`
|
|
51
|
+
(1000–60000) and `FLOWPRESS_GRAPHQL_RETRIES` (0–5) values. It refuses any pair
|
|
52
|
+
whose worst case reaches the 120 s lock that build processes wait on in the
|
|
53
|
+
shared request store.
|
|
54
|
+
|
|
39
55
|
For local Cloudflare development, prefer an HTTP loopback endpoint dedicated
|
|
40
56
|
to server-to-server traffic. Keep the public HTTPS backend URL separate for
|
|
41
57
|
canonical URL rewriting.
|
|
@@ -79,6 +95,89 @@ grid and dead controls are hidden. If a legacy carousel contains any direct
|
|
|
79
95
|
child other than `sf/carousel-item`, no interactive instance is initialized:
|
|
80
96
|
the complete content renders statically, with a development diagnostic.
|
|
81
97
|
|
|
98
|
+
## Site Editor composition
|
|
99
|
+
|
|
100
|
+
`FlowpressClient.getComposition(uri, locale)` reads the public
|
|
101
|
+
`FlowpressCompositionV1` contract. `CompositionRenderer.astro` walks its block
|
|
102
|
+
tree through an explicit `FlowpressBlockAdapters` registry, passes authored
|
|
103
|
+
attributes and `resolvedData` separately, and never renders `innerHtml` as a
|
|
104
|
+
fallback. Blocking WordPress diagnostics always fail the render. Missing or
|
|
105
|
+
draft adapters, absent block-type descriptors and schema-fingerprint drift
|
|
106
|
+
are visible diagnostics in development and fail closed in production with
|
|
107
|
+
the exact scaffold, refresh or approval command. The fingerprint comparison
|
|
108
|
+
is repeated by Astro and does not rely only on the CMS gate.
|
|
109
|
+
Before invoking an adapter, the renderer resolves the universal Styleflow
|
|
110
|
+
attributes through the same framework-neutral validator used by the built-in
|
|
111
|
+
renderer and passes them as `styleflowProps`. Project adapters can therefore
|
|
112
|
+
apply the authored semantic context to their real root without accepting raw
|
|
113
|
+
WordPress visual values.
|
|
114
|
+
|
|
115
|
+
At the composition root, owned media URLs are rebased to the current request
|
|
116
|
+
origin using explicit `BACKEND_URL`, `FLOWPRESS_MEDIA`, `SITE_URL` and the
|
|
117
|
+
composition's canonical frontend origin. This also covers nested query items
|
|
118
|
+
and responsive `srcSet` data passed to project adapters. WordPress uploads
|
|
119
|
+
remain under `/app/uploads/` and offloaded files under `/media/`; third-party
|
|
120
|
+
assets and raw HTML/CSS/scripts are preserved. A `media` prop of type
|
|
121
|
+
`FlowpressFrontendMediaOptions` can supply explicit origins. Projects can
|
|
122
|
+
also use exported `rewriteFlowpressMediaUrl` / `rewriteFlowpressMediaUrls`
|
|
123
|
+
for data rendered outside a composition. These functions do not mutate the
|
|
124
|
+
CMS payload.
|
|
125
|
+
|
|
126
|
+
The upload and media proxies follow HTTP(S) storage redirects on the server
|
|
127
|
+
(at most five), forwarding only safe request headers and preserving range,
|
|
128
|
+
validator and cache semantics. They never return an upstream `Location` or
|
|
129
|
+
`Set-Cookie` header: the browser stays on the public frontend URL.
|
|
130
|
+
|
|
131
|
+
Every adapter also receives required normalized `htmlProps` (`anchor` → `id`
|
|
132
|
+
and the additional classes), the full composition and a deterministic render
|
|
133
|
+
context. The public HTML allowlist also preserves `title`, `role`, `lang`,
|
|
134
|
+
`dir`, `tabindex`, `aria-*` and project `data-*` attributes. Inline styles,
|
|
135
|
+
event handlers and Styleflow-owned `data-*` attributes are never copied from
|
|
136
|
+
Gutenberg indiscriminately. WordPress-processed block custom CSS is emitted
|
|
137
|
+
once at the root.
|
|
138
|
+
`ThemeRuntime.astro` applies the persisted contract theme before paint and
|
|
139
|
+
progressively enhances `sf/theme-toggle` without hydrating React. The shared
|
|
140
|
+
Site Logo adapter renders positive and negative variants while inherited CSS
|
|
141
|
+
variables make the nearest nested theme authoritative.
|
|
142
|
+
|
|
143
|
+
```astro
|
|
144
|
+
---
|
|
145
|
+
import CompositionRenderer from "@styleflow.app/flowpress-astro-core/CompositionRenderer.astro";
|
|
146
|
+
import { blockAdapters } from "./generated/block-adapter-registry";
|
|
147
|
+
---
|
|
148
|
+
|
|
149
|
+
<CompositionRenderer composition={composition} adapters={blockAdapters} />
|
|
150
|
+
```
|
|
151
|
+
|
|
152
|
+
The package publishes a versioned `flowpressDefaultBlockCatalog` and
|
|
153
|
+
`DefaultBlockAdapter.astro`. A project registry can therefore resolve a block
|
|
154
|
+
in this order: conventional local `namespace-block.astro`, explicit manifest
|
|
155
|
+
renderer, official default. Calling the official default skips only the
|
|
156
|
+
current override and keeps the same registry for nested children, avoiding
|
|
157
|
+
recursion without losing child overrides. The same adapter works in Site
|
|
158
|
+
Editor compositions and in traditional Gutenberg rendering; fingerprint gates
|
|
159
|
+
remain composition-only. File discovery never changes a
|
|
160
|
+
`draft`, missing or stale fingerprint into a certified adapter.
|
|
161
|
+
|
|
162
|
+
`createFlowpressDefaultBlockAdapterSource(blockName)` returns the editable
|
|
163
|
+
source used by scaffolding when `--from-default` is selected. Unsupported
|
|
164
|
+
blocks throw instead of pretending that a semantic implementation exists.
|
|
165
|
+
|
|
166
|
+
`core/cover` is part of catalog version 2. Its public `CoverBlock.astro`
|
|
167
|
+
renderer accepts the native image/video URL, focal point, content position and
|
|
168
|
+
minimum height, renders nested blocks through a slot and keeps media at
|
|
169
|
+
`object-fit: cover`. The root uses the normal Styleflow props; the overlay uses
|
|
170
|
+
the same validated contract through prefixed attributes such as `scrimTone`,
|
|
171
|
+
`scrimIntensity`, `scrimSurface` and `scrimTheme`. `scrimEnabled` controls its
|
|
172
|
+
presence and `scrimOpacity` accepts an explicit percentage from `0` to `100`.
|
|
173
|
+
Values outside the interval are clamped. Native `dimRatio` remains a
|
|
174
|
+
compatibility input for both activation and opacity when the explicit
|
|
175
|
+
Styleflow-facing fields are absent.
|
|
176
|
+
|
|
177
|
+
Static adapters produce no JavaScript by default. A project opts into client
|
|
178
|
+
runtime only inside adapters classified as interactive; React views rendered
|
|
179
|
+
without `client:*` remain server-only HTML.
|
|
180
|
+
|
|
82
181
|
Heading, rich-text, quote and matching core blocks accept Gutenberg alignment
|
|
83
182
|
from either `style.typography.textAlign` or the FlowPress `textAlign` field.
|
|
84
183
|
Only `left`, `center`, `right`, `justify`, `start` and `end` reach CSS.
|
|
@@ -147,6 +246,18 @@ assistive technology and without JavaScript; `prefers-reduced-motion: reduce`
|
|
|
147
246
|
skips the animation entirely. Browsers without viewport observation keep the
|
|
148
247
|
server-rendered final value instead of guessing when to start.
|
|
149
248
|
|
|
249
|
+
## Media
|
|
250
|
+
|
|
251
|
+
`resolveFlowpressMediaUrl()` reads `FLOWPRESS_MEDIA`, falling back to
|
|
252
|
+
`BACKEND_URL`, while `flowpressMediaRemotePattern()` returns the matching Astro
|
|
253
|
+
image pattern. URLs with credentials, query strings or fragments are rejected.
|
|
254
|
+
|
|
255
|
+
`proxyFlowpressUpload()` and `proxyFlowpressMedia()` are shared request
|
|
256
|
+
handlers for server output and static Pages Functions. They accept only
|
|
257
|
+
`GET`/`HEAD`, preserve conditional and Range requests plus cache metadata, and
|
|
258
|
+
use explicit request/response header allowlists so cookies, authorization and
|
|
259
|
+
other sensitive headers never cross the proxy boundary.
|
|
260
|
+
|
|
150
261
|
## Release
|
|
151
262
|
|
|
152
263
|
```bash
|
|
@@ -167,9 +278,13 @@ The TypeScript template-hierarchy suite is self-contained. Its additional PHP
|
|
|
167
278
|
parity test runs when the sibling `flowpress-wordpress-core` checkout is
|
|
168
279
|
available locally and is skipped in a standalone package checkout.
|
|
169
280
|
|
|
170
|
-
Publish
|
|
171
|
-
|
|
172
|
-
|
|
281
|
+
Publish prereleases on `next` through CI/OIDC from an immutable version tag on main.
|
|
282
|
+
Inspect the workflow, registry, `gitHead`, integrity and downloaded tarball.
|
|
283
|
+
Canonical release and adoption evidence is in the [consolidation report](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-14-consolidamento-tessari.md).
|
|
173
284
|
|
|
174
285
|
Release activity reports are indexed in
|
|
175
286
|
[`docs/activities/README.md`](docs/activities/README.md).
|
|
287
|
+
|
|
288
|
+
Pilot integration in `1.0.0-beta.17`: Canonical behavior, migration and verification: [pilot integration](https://github.com/StyleFlow-App/styleflow-docs/blob/main/wiki/piloti-flowpress.md), [report](https://github.com/StyleFlow-App/styleflow-docs/blob/main/dev/rapporti/2026-10-07-integrazione-piloti-flowpress.md).
|
|
289
|
+
|
|
290
|
+
Direct media and query loading: [canonical guide](https://github.com/StyleFlow-App/styleflow-docs/blob/main/wiki/runtime-editoriale.md), [media migration](https://github.com/StyleFlow-App/styleflow-docs/blob/main/wiki/asset.md).
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"accessibility-panel.d.ts","sourceRoot":"","sources":["../src/accessibility-panel.ts"],"names":[],"mappings":"AAWA,wBAAgB,4BAA4B,CAAC,KAAK,GAAE,UAAqB,GAAG,MAAM,IAAI,CAGrF"}
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Behaviour of the floating accessibility panel: a round button that opens a
|
|
3
|
+
* small non-modal dialog. Escape closes it and returns focus to the button;
|
|
4
|
+
* a press or focus outside closes it without stealing focus.
|
|
5
|
+
*/
|
|
6
|
+
const ROOT_SELECTOR = "[data-sf-a11y]";
|
|
7
|
+
const TRIGGER_SELECTOR = "[data-sf-a11y-trigger]";
|
|
8
|
+
const PANEL_SELECTOR = "[data-sf-a11y-panel]";
|
|
9
|
+
const FOCUSABLE_SELECTOR = "button:not([disabled]), [href], input:not([disabled]), [tabindex]:not([tabindex='-1'])";
|
|
10
|
+
const BOUND = "sfA11yBound";
|
|
11
|
+
export function initializeAccessibilityPanel(scope = document) {
|
|
12
|
+
const disposers = [...scope.querySelectorAll(ROOT_SELECTOR)].map(bindPanel);
|
|
13
|
+
return () => disposers.forEach((dispose) => dispose());
|
|
14
|
+
}
|
|
15
|
+
function bindPanel(root) {
|
|
16
|
+
const documentObject = root.ownerDocument;
|
|
17
|
+
const windowObject = documentObject.defaultView;
|
|
18
|
+
let focusFrame;
|
|
19
|
+
const trigger = root?.querySelector(TRIGGER_SELECTOR);
|
|
20
|
+
const panel = root?.querySelector(PANEL_SELECTOR);
|
|
21
|
+
if (!root || !trigger || !panel || root.dataset[BOUND] === "true")
|
|
22
|
+
return () => { };
|
|
23
|
+
root.dataset[BOUND] = "true";
|
|
24
|
+
const isOpen = () => trigger.getAttribute("aria-expanded") === "true";
|
|
25
|
+
const label = (state) => trigger.dataset[state === "open" ? "openLabel" : "closeLabel"] ?? trigger.getAttribute("aria-label") ?? "";
|
|
26
|
+
const setOpen = (open, restoreFocus = false) => {
|
|
27
|
+
if (focusFrame !== undefined)
|
|
28
|
+
windowObject?.cancelAnimationFrame(focusFrame);
|
|
29
|
+
focusFrame = undefined;
|
|
30
|
+
trigger.setAttribute("aria-expanded", String(open));
|
|
31
|
+
trigger.setAttribute("aria-label", label(open ? "close" : "open"));
|
|
32
|
+
panel.dataset.state = open ? "open" : "closed";
|
|
33
|
+
panel.inert = !open;
|
|
34
|
+
if (open) {
|
|
35
|
+
// Removing inert and changing CSS visibility needs a frame before focus.
|
|
36
|
+
const focusFirst = () => {
|
|
37
|
+
focusFrame = undefined;
|
|
38
|
+
if (isOpen())
|
|
39
|
+
panel.querySelector(FOCUSABLE_SELECTOR)?.focus({ preventScroll: true });
|
|
40
|
+
};
|
|
41
|
+
if (windowObject)
|
|
42
|
+
focusFrame = windowObject.requestAnimationFrame(focusFirst);
|
|
43
|
+
else
|
|
44
|
+
focusFirst();
|
|
45
|
+
}
|
|
46
|
+
else if (restoreFocus)
|
|
47
|
+
trigger.focus();
|
|
48
|
+
};
|
|
49
|
+
const onTrigger = () => setOpen(!isOpen());
|
|
50
|
+
const onKeydown = (event) => {
|
|
51
|
+
if (event.key !== "Escape" || !isOpen())
|
|
52
|
+
return;
|
|
53
|
+
event.preventDefault();
|
|
54
|
+
setOpen(false, true);
|
|
55
|
+
};
|
|
56
|
+
const onPointerDown = (event) => {
|
|
57
|
+
if (isOpen() && event.target instanceof Node && !root.contains(event.target))
|
|
58
|
+
setOpen(false);
|
|
59
|
+
};
|
|
60
|
+
const onFocusOut = (event) => {
|
|
61
|
+
if (isOpen() && event.relatedTarget instanceof Node && !root.contains(event.relatedTarget))
|
|
62
|
+
setOpen(false);
|
|
63
|
+
};
|
|
64
|
+
trigger.addEventListener("click", onTrigger);
|
|
65
|
+
root.addEventListener("keydown", onKeydown);
|
|
66
|
+
root.addEventListener("focusout", onFocusOut);
|
|
67
|
+
documentObject.addEventListener("pointerdown", onPointerDown);
|
|
68
|
+
setOpen(false);
|
|
69
|
+
// Without scripts the controls cannot work, so the markup ships hidden.
|
|
70
|
+
root.hidden = false;
|
|
71
|
+
return () => {
|
|
72
|
+
setOpen(false);
|
|
73
|
+
root.hidden = true;
|
|
74
|
+
trigger.removeEventListener("click", onTrigger);
|
|
75
|
+
root.removeEventListener("keydown", onKeydown);
|
|
76
|
+
root.removeEventListener("focusout", onFocusOut);
|
|
77
|
+
documentObject.removeEventListener("pointerdown", onPointerDown);
|
|
78
|
+
delete root.dataset[BOUND];
|
|
79
|
+
};
|
|
80
|
+
}
|
|
81
|
+
//# sourceMappingURL=accessibility-panel.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"accessibility-panel.js","sourceRoot":"","sources":["../src/accessibility-panel.ts"],"names":[],"mappings":"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","sourcesContent":["/**\n * Behaviour of the floating accessibility panel: a round button that opens a\n * small non-modal dialog. Escape closes it and returns focus to the button;\n * a press or focus outside closes it without stealing focus.\n */\nconst ROOT_SELECTOR = \"[data-sf-a11y]\";\nconst TRIGGER_SELECTOR = \"[data-sf-a11y-trigger]\";\nconst PANEL_SELECTOR = \"[data-sf-a11y-panel]\";\nconst FOCUSABLE_SELECTOR = \"button:not([disabled]), [href], input:not([disabled]), [tabindex]:not([tabindex='-1'])\";\nconst BOUND = \"sfA11yBound\";\n\nexport function initializeAccessibilityPanel(scope: ParentNode = document): () => void {\n const disposers = [...scope.querySelectorAll<HTMLElement>(ROOT_SELECTOR)].map(bindPanel);\n return () => disposers.forEach((dispose) => dispose());\n}\n\nfunction bindPanel(root: HTMLElement): () => void {\n const documentObject = root.ownerDocument;\n const windowObject = documentObject.defaultView;\n let focusFrame: number | undefined;\n const trigger = root?.querySelector<HTMLButtonElement>(TRIGGER_SELECTOR);\n const panel = root?.querySelector<HTMLElement>(PANEL_SELECTOR);\n if (!root || !trigger || !panel || root.dataset[BOUND] === \"true\") return () => {};\n root.dataset[BOUND] = \"true\";\n\n const isOpen = () => trigger.getAttribute(\"aria-expanded\") === \"true\";\n const label = (state: \"open\" | \"close\") =>\n trigger.dataset[state === \"open\" ? \"openLabel\" : \"closeLabel\"] ?? trigger.getAttribute(\"aria-label\") ?? \"\";\n\n const setOpen = (open: boolean, restoreFocus = false) => {\n if (focusFrame !== undefined) windowObject?.cancelAnimationFrame(focusFrame);\n focusFrame = undefined;\n trigger.setAttribute(\"aria-expanded\", String(open));\n trigger.setAttribute(\"aria-label\", label(open ? \"close\" : \"open\"));\n panel.dataset.state = open ? \"open\" : \"closed\";\n panel.inert = !open;\n if (open) {\n // Removing inert and changing CSS visibility needs a frame before focus.\n const focusFirst = () => {\n focusFrame = undefined;\n if (isOpen()) panel.querySelector<HTMLElement>(FOCUSABLE_SELECTOR)?.focus({ preventScroll: true });\n };\n if (windowObject) focusFrame = windowObject.requestAnimationFrame(focusFirst);\n else focusFirst();\n } else if (restoreFocus) trigger.focus();\n };\n\n const onTrigger = () => setOpen(!isOpen());\n const onKeydown = (event: KeyboardEvent) => {\n if (event.key !== \"Escape\" || !isOpen()) return;\n event.preventDefault();\n setOpen(false, true);\n };\n const onPointerDown = (event: PointerEvent) => {\n if (isOpen() && event.target instanceof Node && !root.contains(event.target)) setOpen(false);\n };\n const onFocusOut = (event: FocusEvent) => {\n if (isOpen() && event.relatedTarget instanceof Node && !root.contains(event.relatedTarget)) setOpen(false);\n };\n\n trigger.addEventListener(\"click\", onTrigger);\n root.addEventListener(\"keydown\", onKeydown);\n root.addEventListener(\"focusout\", onFocusOut);\n documentObject.addEventListener(\"pointerdown\", onPointerDown);\n setOpen(false);\n // Without scripts the controls cannot work, so the markup ships hidden.\n root.hidden = false;\n\n return () => {\n setOpen(false);\n root.hidden = true;\n trigger.removeEventListener(\"click\", onTrigger);\n root.removeEventListener(\"keydown\", onKeydown);\n root.removeEventListener(\"focusout\", onFocusOut);\n documentObject.removeEventListener(\"pointerdown\", onPointerDown);\n delete root.dataset[BOUND];\n };\n}\n"]}
|