0.9.9
This release adds a lot of new RichTextAction
cases and adjusts the context and coordinator subscription.
This release also deprecates RichTextAttributeReader
and RichTextAttributeWriter
functionality that are not used by the library, in favor of RichTextViewComponent
, to reduce the complexity of the library.
Until now, these functions mostly did the same thing, but sometimes the RichTextViewComponent
have to use its text storage or layout manager, or update the typing attributes. This caused the code to diverge and mostly identical copies had co-exist, where the reader and writer versions were not even used by the library.
By deprecating these functions, we can simplify the library in 1.0, and focus more on unifying the different RichTextViewComponent
implementations (UITextView
in iOS and NSTextView
in macOS), rather than providing a low level string handling interface.
✨ Features
FontRepresentable
has new extensions.RichTextAction
has a newlabel
property.RichTextCommand.ActionButtonGroup
has new inits.RichTextCommand.FormatMenu
is a lot more configurable.RichTextFormatSheet
is now available on all platforms.RichTextFormatSheet
has new configuration and style types.RichTextFormatSidebar
has new configuration and style types.RichTextFormatToolbar
is a new rich text formatting toolbar.RichTextKeyboardToolbar
has a new config to always be shown.RichTextLine
is a new namespace with support for linespacing.RichTextStyle.Button
now supports using custom button styles.RichTextView
has a new theme that lets you define its style.RichTextViewComponent
has a newhasRichTextStyle
function.RichTextViewComponent
has a newtoggleRichTextStyle
function.RichTextViewComponent
now handles superscript changes properly.
🚨 Important
RichTextFormatToolbar
is no longer navigation wrapped by default.RichTextFormatToolbar
has a newasSheet()
function that does this.
💡 Adjustments
RichTextColor
icon
is no longer optional.RichTextColor
has a newtitleKey
property.RichTextContext
makes coordinator handle alignment.RichTextCoordinator
now syncs an extra time at ends editing.
🐛 Bug Fixes
- The library once again builds on visionOS.
RichTextAlignment
now behaves better.RichTextAlignment.Picker
now uses provided values.RichTextCoordinator
now handles indentation changes.
🗑️ Deprecations
RichTextAttributeReader
has deprecated a lot of functions.RichTextAttributeWriter
has deprecated a lot of functions.RichTextCommand.AlignmentOptionsGroup
has been deprecated.RichTextCommand.FontSizeOptionsGroup
has been deprecated.RichTextCommand.IndentOptionsGroup
has been deprecated.RichTextCommand.StyleOptionsGroup
has been deprecated.RichTextCommand.SuperscriptOptionsGroup
has been deprecated.RichTextContext
replaces individual colors with a singlecolors
.RichTextContext
replaces individual styles with a singlestyles
.RichTextContext
userActionPublisher
is renamed toactionPublisher
.RichTextCoordinator
functions callinghandle(_:)
have been deprecated.RichTextFormatSheet
has been renamed toRichTextFormatToolbar
.RTKL10n.bundle
has been deprecated since we can use the.module
bundle.
💥 Breaking Changes
RichTextColor.undefined
was no longer used and has been removed.