feat(android): add enableNativeBlockInserter feature flag#464
Draft
jkmassel wants to merge 2 commits intojkmassel/block-picker-modelsfrom
Draft
feat(android): add enableNativeBlockInserter feature flag#464jkmassel wants to merge 2 commits intojkmassel/block-picker-modelsfrom
jkmassel wants to merge 2 commits intojkmassel/block-picker-modelsfrom
Conversation
This was referenced Apr 22, 2026
New `EditorConfiguration.setEnableNativeBlockInserter(Boolean)` builder setter + propagation through `GBKitGlobal` to the JS global. Defaults to false, so existing consumers keep the web-based inserter until they opt in. Demo app wires the existing "Enable Native Inserter" toggle to the new setter, replacing the `// TODO` placeholder. No UI is rendered by turning the flag on alone — it suppresses the web inserter and dispatches `showBlockInserter` to the native bridge. The native handler lands in a follow-up PR.
5b56302 to
e0a3843
Compare
a11c583 to
32e096e
Compare
… gaps Adds EditorConfiguration tests for the new `enableNativeBlockInserter` flag (defaults, setter, toBuilder round-trip, equals/hashCode inequality, full-config) and fills pre-existing gaps by asserting hashCode inequality on every per-field "not equal" test. Also adds GBKitGlobal propagation tests for enableNativeBlockInserter and previously-untested pass-through fields (hideTitle, locale with null fallback, enableNetworkLogging, authHeader, postStatus, siteApiNamespace, namespaceExcludedPaths). Extends the JSON round-trip test to cover the new boolean flags.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Second of three stacked PRs for the native block inserter. Adds
EditorConfiguration.setEnableNativeBlockInserter(Boolean)and propagates the flag toGBKitGlobalso the web editor can decide whether to delegate inserter UI to the host. Defaults tofalse, so existing consumers keep the web-based inserter until they opt in.Demo app wires the existing "Enable Native Inserter" toggle to the new setter, replacing the
// TODOplaceholder.No UI is rendered by turning the flag on alone — it suppresses the web inserter and dispatches
showBlockInserterto the native bridge (dispatch wiring added in #463). The native handler lands in #461.Test plan
./gradlew :Gutenberg:compileDebugKotlin :app:compileDebugKotlin :Gutenberg:test detekt— BUILD SUCCESSFULRelated
Second of three stacked PRs:
enableNativeBlockInserterfeature flagGutenbergViewwiring