diff --git a/internal/server/content_test.go b/internal/server/content_test.go index ec98f019..a4a0e89f 100644 --- a/internal/server/content_test.go +++ b/internal/server/content_test.go @@ -72,7 +72,7 @@ func TestContentAPIAnswersTheHandshakeWithoutASession(t *testing.T) { if !strings.Contains(body, `"api":0`) { t.Errorf("body = %q, want the api generation", body) } - if !strings.Contains(body, `"kit":["0.9.0","0.10.0","0.11.0","0.12.0","0.13.0","0.14.0","0.15.0"]`) { + if !strings.Contains(body, `"kit":["0.9.0","0.10.0","0.11.0","0.12.0","0.13.0","0.14.0","0.15.0","0.15.1"]`) { t.Errorf("body = %q, want the kit versions served", body) } if !strings.Contains(body, `"gophenberg"`) { @@ -358,7 +358,8 @@ func TestContentAPIAdvertisesTheTypesItServes(t *testing.T) { if handshake.API != 0 { t.Errorf("api = %d, want 0", handshake.API) } - if !slices.Equal(handshake.Kit, []string{"0.9.0", "0.10.0", "0.11.0", "0.12.0", "0.13.0", "0.14.0", "0.15.0"}) { + want := []string{"0.9.0", "0.10.0", "0.11.0", "0.12.0", "0.13.0", "0.14.0", "0.15.0", "0.15.1"} + if !slices.Equal(handshake.Kit, want) { t.Errorf("kit = %v, want the kit versions this release serves", handshake.Kit) } if len(handshake.Types) != 1 { diff --git a/internal/themehost/kit.go b/internal/themehost/kit.go index a2a93319..b77af3af 100644 --- a/internal/themehost/kit.go +++ b/internal/themehost/kit.go @@ -9,7 +9,7 @@ import ( ) // servedKits names the theme kit versions this release serves, oldest first. -var servedKits = []string{"0.9.0", "0.10.0", "0.11.0", "0.12.0", "0.13.0", "0.14.0", "0.15.0"} +var servedKits = []string{"0.9.0", "0.10.0", "0.11.0", "0.12.0", "0.13.0", "0.14.0", "0.15.0", "0.15.1"} // ServedKits returns the theme kit versions this release serves. func ServedKits() []string { diff --git a/internal/themehost/kit_test.go b/internal/themehost/kit_test.go index 99c7d1d5..3a1b11e5 100644 --- a/internal/themehost/kit_test.go +++ b/internal/themehost/kit_test.go @@ -17,10 +17,10 @@ func TestServedKitsNamesWhatThisReleaseServes(t *testing.T) { served := themehost.ServedKits() - if !slices.Equal(served, []string{"0.9.0", "0.10.0", "0.11.0", "0.12.0", "0.13.0", "0.14.0", "0.15.0"}) { + if !slices.Equal(served, []string{"0.9.0", "0.10.0", "0.11.0", "0.12.0", "0.13.0", "0.14.0", "0.15.0", "0.15.1"}) { t.Errorf("ServedKits() = %v, want the kit versions this release serves", served) } - if themehost.NewestKit() != "0.15.0" { + if themehost.NewestKit() != "0.15.1" { t.Errorf("NewestKit() = %q, want the newest of them", themehost.NewestKit()) } } @@ -28,12 +28,12 @@ func TestServedKitsNamesWhatThisReleaseServes(t *testing.T) { func TestAThemeOnEitherServedKitIsAccepted(t *testing.T) { t.Parallel() - for _, declared := range []string{"0.9.0", "0.10.0", "0.11.0", "0.12.0", "0.13.0", "0.14.0", "0.15.0"} { + for _, declared := range []string{"0.9.0", "0.10.0", "0.11.0", "0.12.0", "0.13.0", "0.14.0", "0.15.0", "0.15.1"} { if !themehost.ServesKit(declared) { t.Errorf("ServesKit(%q) = false, want a theme on a served kit accepted", declared) } } - for _, declared := range []string{"0.8.0", "0.10.3"} { + for _, declared := range []string{"0.8.0", "0.10.3", "0.15.2"} { if themehost.ServesKit(declared) { t.Errorf("ServesKit(%q) = true, want a kit this release cannot serve turned away", declared) } @@ -45,7 +45,7 @@ func TestServedKitsCannotBeChangedByACaller(t *testing.T) { themehost.ServedKits()[0] = "9.9.9" - if themehost.NewestKit() != "0.15.0" { + if themehost.NewestKit() != "0.15.1" { t.Errorf("NewestKit() = %q after a caller wrote to the returned slice", themehost.NewestKit()) } } diff --git a/sdk/astro/CHANGELOG.md b/sdk/astro/CHANGELOG.md index fc6ec227..9386894c 100644 --- a/sdk/astro/CHANGELOG.md +++ b/sdk/astro/CHANGELOG.md @@ -11,10 +11,11 @@ npm-style tag stays invisible to the Go toolchain, unlike a `sdk/astro/vX.Y.Z` tag naming the directory as a module. Versions through 0.8.0 shipped in step with Gophenberg under its `vX.Y.Z` tags. -## Unreleased +## [0.15.1] - 2026-10-13 ### Changed +- A theme built on 0.15.1 needs Gophenberg 0.18.2 or newer. - The kit parses blocks with `@wordpress/block-serialization-default-parser` 5.57.0. ### Fixed diff --git a/sdk/astro/README.md b/sdk/astro/README.md index 1568dc1f..ea665c39 100644 --- a/sdk/astro/README.md +++ b/sdk/astro/README.md @@ -18,6 +18,10 @@ pnpm add @gophenberg/astro Astro 7 is a peer dependency. +A site runs a theme only when its Gophenberg release serves the kit +version the theme was built on. See +[Theme compatibility](https://docs.gophenberg.org/themes/compatibility/). + ## Use Two files make an Astro project a theme. diff --git a/sdk/astro/package.json b/sdk/astro/package.json index 7944c688..881be15e 100644 --- a/sdk/astro/package.json +++ b/sdk/astro/package.json @@ -1,6 +1,6 @@ { "name": "@gophenberg/astro", - "version": "0.15.0", + "version": "0.15.1", "type": "module", "license": "Apache-2.0", "description": "Build a Gophenberg theme in Astro: routes, block rendering, and the theme contract.",