Skip to content

Add updateStyle method to TextInputConnectionDecorator#2917

Closed
Renzo-Olivares wants to merge 5 commits into
Flutter-Bounty-Hunters:mainfrom
Renzo-Olivares:implement-updateStyle
Closed

Add updateStyle method to TextInputConnectionDecorator#2917
Renzo-Olivares wants to merge 5 commits into
Flutter-Bounty-Hunters:mainfrom
Renzo-Olivares:implement-updateStyle

Conversation

@Renzo-Olivares

Copy link
Copy Markdown
Contributor

In flutter/flutter#180436 a breaking change was introduced to pass additional styling information to the web engine in order to fix flutter/flutter#161592. Historically the framework passes this information using TextInputConnection.setStyle(......), however after the breaking change the framework introduced TextInputConnection.updateStyle(TextInputStyle style) and deprecated the old method in an effort to minimize future breaking changes when passing additional style parameters to the engine.

This change fixes the breakage by adding an implementation for the new method added TextInputConnection.updateStyle.

A full migration to updateStyle in addition to providing the additional styling information to the web engine will still be needed if experiencing flutter/flutter#161592.

@Renzo-Olivares Renzo-Olivares marked this pull request as draft February 15, 2026 14:53
@matthew-carroll

Copy link
Copy Markdown
Contributor

@Renzo-Olivares looks like you've got multiple test failures in this PR. At first glance, they look to be related to the API you're updating.

@Renzo-Olivares

Copy link
Copy Markdown
Contributor Author

@matthew-carroll It looks like it might be because the super_editor package needs to be updated, and that update rolled into packages that depend on it like super_editor_clipboard, super_editor_markdown, and super_editor_quill. If so, is that something I should do in this PR?

@matthew-carroll

Copy link
Copy Markdown
Contributor

@Renzo-Olivares for this PR at this stage, if you need other packages in the mono-repo to use your super_editor changes, then you should change the pubspec for each of those packages by adding a dependency override that points to the local version of super_editor. E.g.:

dependency_overrides:
  super_editor:
    path: ../super_editor

@Renzo-Olivares

Copy link
Copy Markdown
Contributor Author

@matthew-carroll I updated the dependencies to use the local copy of super_editor but I think i've hit a snag. super_editor_quill and super_editor_markdown were recently moved into super_editor and those packages are only compatible with older versions of super_editor. Adding a local override ends up causing import conflicts because classes are defined in both super_editor and the sub-package. If the plan is to move those packages into super_editor should I go ahead and delete the sub-package implementations to fix the conflicts?

@matthew-carroll

Copy link
Copy Markdown
Contributor

@Renzo-Olivares that's a good question. Let me think about it. We might just merge as-is and deal with it later. We'll see. I plan to get this PR merged in the next day or two.

@matthew-carroll

Copy link
Copy Markdown
Contributor

@Renzo-Olivares I deleted those pckages. I'm going to attempt to pull down your branch and rebase it. We'll see how it goes.

@matthew-carroll

Copy link
Copy Markdown
Contributor

@Renzo-Olivares gonna close this PR in favor of the copy I put up with adjustments for the removal of those 2 packages: #2950

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Incorrect position of Japanese predictive conversion popup in TextFormField using maxLines on the Web

2 participants