Skip to content
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

Auto format trigger #2684

Merged
merged 6 commits into from
Jun 6, 2024
Merged

Auto format trigger #2684

merged 6 commits into from
Jun 6, 2024

Conversation

juliaroldi
Copy link
Contributor

@juliaroldi juliaroldi commented Jun 5, 2024

Trigger event Auto format event in AutoFormatPlugin, so we can trigger the AutoFormat UI on OWA.
Screenshot 2024-06-05 at 19 52 23

autoFormatUI

);
if (formatOptions.changeSource) {
Copy link
Contributor

@BryanValverdeU BryanValverdeU Jun 6, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What if instead of triggering another plugin event here we change the formatWithContentModel implementation by moving line 27
(Or at least the ChangeSource and ApiName properties destructing declaration) before line 81 but after calling the formatter callback

Since the option object is destructed to get the values before the callback and we modify the options object in the format callback the AutoFormat Change source is not correctly set.

@JiuqingSong to check if this is okay.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, @BryanValverdeU!! That worked out better that my solution.

@juliaroldi juliaroldi merged commit 091e319 into master Jun 6, 2024
7 checks passed
BryanValverdeU pushed a commit that referenced this pull request Jun 6, 2024
BryanValverdeU added a commit that referenced this pull request Jun 6, 2024
* Merge Link & Image Format when using MergeModel (#2681)

* mergeLinkFormat

* Also fix for images

* remove unneeded changes

* Remove more unneeded changes

* Address comment

* nit

---------

Co-authored-by: Jiuqing Song <jisong@microsoft.com>

* update versions

* Merge pull request #2684 from microsoft/u/juliaroldi/trigger-auto-format

Auto format trigger

---------

Co-authored-by: Jiuqing Song <jisong@microsoft.com>
Co-authored-by: Julia Roldi <87443959+juliaroldi@users.noreply.github.com>
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.

3 participants