-
Notifications
You must be signed in to change notification settings - Fork 1.1k
feat: GutenbergKit supports mentions and cross-posts #24733
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
27abe35
to
1b0c3e8
Compare
|
App Name | WordPress | |
Configuration | Release-Alpha | |
Build Number | 28505 | |
Version | PR #24733 | |
Bundle ID | org.wordpress.alpha | |
Commit | f943390 | |
Installation URL | 13rmb7siop5vg |
|
App Name | Jetpack | |
Configuration | Release-Alpha | |
Build Number | 28505 | |
Version | PR #24733 | |
Bundle ID | com.jetpack.alpha | |
Commit | f943390 | |
Installation URL | 3kmt8gbnnlafo |
Stepping through history state may retrigger autocompletion events, which led to rendering duplicative UI views.
Improve performance and avoid displaying empty suggestions UI for blogs without support for suggestions.
51b3508
to
96080f3
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR integrates GutenbergKit's autocompleter functionality to support @mention
and +cross-post
suggestions in the WordPress editor. The implementation leverages GutenbergKit's new onAutocompleterTriggered
event and appendTextAtCursor
method to provide a seamless user experience for mentions and cross-posts.
- Implements autocompleter delegate method to handle mention and cross-post triggers
- Adds keyboard observation and constraint management for suggestions UI
- Updates GutenbergKit dependency to support new autocompleter functionality
Reviewed Changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.
File | Description |
---|---|
NewGutenbergViewController.swift | Main implementation of autocompleter functionality with keyboard handling and suggestions UI |
CommentGutenbergEditorViewController.swift | Adds empty implementation of autocompleter delegate method |
Package.swift | Updates GutenbergKit dependency to specific revision with autocompleter support |
Package.resolved | Updates resolved package state for GutenbergKit |
Comments suppressed due to low confidence (1)
WordPress/Classes/ViewRelated/NewGutenberg/NewGutenbergViewController.swift:58
- Using a specific revision instead of a semantic version makes dependency management difficult and prevents automatic updates. Consider using a tagged version once the GutenbergKit changes are released.
refreshInterface()
WordPress/Classes/ViewRelated/NewGutenberg/NewGutenbergViewController.swift
Outdated
Show resolved
Hide resolved
WordPress/Classes/ViewRelated/NewGutenberg/NewGutenbergViewController.swift
Outdated
Show resolved
Hide resolved
WordPress/Classes/ViewRelated/NewGutenberg/NewGutenbergViewController.swift
Outdated
Show resolved
Hide resolved
WordPress/Classes/ViewRelated/NewGutenberg/NewGutenbergViewController.swift
Outdated
Show resolved
Hide resolved
WordPress/Classes/ViewRelated/NewGutenberg/NewGutenbergViewController.swift
Outdated
Show resolved
Hide resolved
WordPress/Classes/ViewRelated/NewGutenberg/NewGutenbergViewController.swift
Outdated
Show resolved
Hide resolved
|
Description
Close CMM-454. Dependent upon wordpress-mobile/GutenbergKit#165.
Leverage GutenbergKit's
onAutocompleterTriggered
event andappendTextAtCursor
method for displaying and inserting@mention
and+cross-post
suggestions.Testing instructions
Explore
@mention
and+cross-post
autocompletion. Try inserting triggers at various locations to verify expected behavior:<line-start>@<cursor>
@text<cursor>
text@<cursor>
text @<cursor>more
text more@<cursor>