feat: add paragraphSpacing to checkbox list (iOS + Android)#470
Open
ErionTp wants to merge 1 commit intosoftware-mansion:mainfrom
Open
feat: add paragraphSpacing to checkbox list (iOS + Android)#470ErionTp wants to merge 1 commit intosoftware-mansion:mainfrom
ErionTp wants to merge 1 commit intosoftware-mansion:mainfrom
Conversation
Add a `paragraphSpacing` property to `ulCheckbox` in `HtmlStyle` to control vertical spacing between checkbox list items. iOS: Uses `NSMutableParagraphStyle.paragraphSpacing` which was already available but not wired up. Android: Extends `EnrichedCheckboxListSpan.chooseHeight()` to increase `fm.descent`/`fm.bottom` after the last line of each paragraph. Defaults to 0 (no change in existing behavior). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
afca9cd to
fe0a7d8
Compare
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
paragraphSpacingproperty toulCheckboxinHtmlStyleto control vertical spacing between checkbox list itemsNSMutableParagraphStyle.paragraphSpacingwhich was already available in the native layer but not wired upEnrichedCheckboxListSpan.chooseHeight()to increasefm.descent/fm.bottomafter the last line of each paragraph0so existing behavior is unchangedUsage
Changes
JS Layer (3 files):
src/types.ts— AddedparagraphSpacing?: numbertoulCheckboxsrc/spec/EnrichedTextInputNativeComponent.ts— AddedparagraphSpacing?: Floatto nativeulCheckboxsrc/utils/normalizeHtmlStyle.ts— AddedparagraphSpacing: 0defaultiOS Native (4 files):
ios/config/InputConfig.h— DeclaredcheckboxListParagraphSpacinggetter/setterios/config/InputConfig.mm— Added ivar, copy, getter/setterios/styles/CheckboxListStyle.mm— SetpStyle.paragraphSpacingwhen adding/removing checkbox attributesios/EnrichedTextInputView.mm— Read new prop and apply to configAndroid (3 files):
android/.../EnrichedStyle.kt— AddedulCheckboxParagraphSpacingto interfaceandroid/.../EnrichedCheckboxListSpan.kt— ExtendedchooseHeight()to add spacing after last line of paragraphandroid/.../HtmlStyle.kt— Added property, parsing,equals(),hashCode()Notes
0🤖 Generated with Claude Code