Skip to content
This repository was archived by the owner on Sep 15, 2025. It is now read-only.

Commit 92d3ce7

Browse files
authored
Merge pull request #598 from wordpress-mobile/task/site-editor-settings-model-changes
Update editor settings models for block based themes
2 parents 3d2b9e0 + b53d94b commit 92d3ce7

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

WordPressKit.podspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
Pod::Spec.new do |s|
44
s.name = 'WordPressKit'
5-
s.version = '8.0.0'
5+
s.version = '8.1.0-beta.1'
66

77
s.summary = 'WordPressKit offers a clean and simple WordPress.com and WordPress.org API.'
88
s.description = <<-DESC

WordPressKit/RemoteBlockEditorSettings.swift

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import Foundation
22

33
public class RemoteBlockEditorSettings: Codable {
44
enum CodingKeys: String, CodingKey {
5-
case isFSETheme = "__unstableEnableFullSiteEditingBlocks"
5+
case isFSETheme = "__unstableIsBlockBasedTheme"
66
case galleryWithImageBlocks = "__unstableGalleryWithImageBlocks"
77
case quoteBlockV2 = "__experimentalEnableQuoteBlockV2"
88
case listBlockV2 = "__experimentalEnableListBlockV2"
@@ -66,14 +66,17 @@ public struct RemoteEditorThemeSupport: Codable {
6666
enum CodingKeys: String, CodingKey {
6767
case colors = "editor-color-palette"
6868
case gradients = "editor-gradient-presets"
69+
case blockTemplates = "block-templates"
6970
}
7071

7172
public let colors: [[String: String]]?
7273
public let gradients: [[String: String]]?
74+
public let blockTemplates: Bool
7375

7476
public init(from decoder: Decoder) throws {
7577
let map = try decoder.container(keyedBy: CodingKeys.self)
7678
self.colors = try? map.decode([[String: String]].self, forKey: .colors)
7779
self.gradients = try? map.decode([[String: String]].self, forKey: .gradients)
80+
self.blockTemplates = (try? map.decode(Bool.self, forKey: .blockTemplates)) ?? false
7881
}
7982
}

0 commit comments

Comments
 (0)