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

[Editor] Utilize Fluent "better" when localizing the AltText #18971

Merged
merged 1 commit into from
Oct 28, 2024

Conversation

Snuffleupagus
Copy link
Collaborator

Currently we manually localize and update the DOM-elements of the AltText-button, and it seems nicer to utilize Fluent "properly" for that task.
This can be achieved by introducing an explicit span-element on the AltText-button (similar to e.g. the regular toolbar-buttons), and adding a few more l10n-strings, since that allows just setting the data-l10n-id-attribute on all the relevant DOM-elements.

Finally, note how we no longer need to localize any strings eagerly when initializing the various editors.

@Snuffleupagus Snuffleupagus added editor l10n Localization labels Oct 28, 2024
@Snuffleupagus Snuffleupagus requested a review from a team as a code owner October 28, 2024 14:58
@Snuffleupagus Snuffleupagus marked this pull request as draft October 28, 2024 15:11
@Snuffleupagus Snuffleupagus removed the request for review from calixteman October 28, 2024 15:11
@mozilla mozilla deleted a comment from moz-tools-bot Oct 28, 2024
@mozilla mozilla deleted a comment from moz-tools-bot Oct 28, 2024
@mozilla mozilla deleted a comment from moz-tools-bot Oct 28, 2024
@mozilla mozilla deleted a comment from moz-tools-bot Oct 28, 2024
@mozilla mozilla deleted a comment from moz-tools-bot Oct 28, 2024
@mozilla mozilla deleted a comment from moz-tools-bot Oct 28, 2024
@mozilla mozilla deleted a comment from moz-tools-bot Oct 28, 2024
@mozilla mozilla deleted a comment from moz-tools-bot Oct 28, 2024
@Snuffleupagus Snuffleupagus force-pushed the AltText-fluent branch 3 times, most recently from dbeda77 to 9888998 Compare October 28, 2024 16:04
@mozilla mozilla deleted a comment from moz-tools-bot Oct 28, 2024
@mozilla mozilla deleted a comment from moz-tools-bot Oct 28, 2024
@mozilla mozilla deleted a comment from moz-tools-bot Oct 28, 2024
@mozilla mozilla deleted a comment from moz-tools-bot Oct 28, 2024
Currently we manually localize and update the DOM-elements of the AltText-button, and it seems nicer to utilize Fluent "properly" for that task.
This can be achieved by introducing an explicit `span`-element on the AltText-button (similar to e.g. the regular toolbar-buttons), and adding a few more l10n-strings, since that allows just setting the `data-l10n-id`-attribute on all the relevant DOM-elements.

Finally, note how we no longer need to localize any strings eagerly when initializing the various editors.
@mozilla mozilla deleted a comment from moz-tools-bot Oct 28, 2024
@mozilla mozilla deleted a comment from moz-tools-bot Oct 28, 2024
@mozilla mozilla deleted a comment from moz-tools-bot Oct 28, 2024
@mozilla mozilla deleted a comment from moz-tools-bot Oct 28, 2024
@Snuffleupagus
Copy link
Collaborator Author

/botio integrationtest

@moz-tools-bot
Copy link
Collaborator

From: Bot.io (Linux m4)


Received

Command cmd_integrationtest from @Snuffleupagus received. Current queue size: 0

Live output at: http://54.241.84.105:8877/eab393dc5ffb726/output.txt

@moz-tools-bot
Copy link
Collaborator

From: Bot.io (Windows)


Received

Command cmd_integrationtest from @Snuffleupagus received. Current queue size: 0

Live output at: http://54.193.163.58:8877/c59a59754927e49/output.txt

@moz-tools-bot
Copy link
Collaborator

From: Bot.io (Linux m4)


Success

Full output at http://54.241.84.105:8877/eab393dc5ffb726/output.txt

Total script time: 8.95 mins

  • Integration Tests: Passed

@moz-tools-bot
Copy link
Collaborator

From: Bot.io (Windows)


Failed

Full output at http://54.193.163.58:8877/c59a59754927e49/output.txt

Total script time: 20.21 mins

  • Integration Tests: FAILED

@Snuffleupagus Snuffleupagus marked this pull request as ready for review October 28, 2024 16:50
Copy link
Contributor

@calixteman calixteman left a comment

Choose a reason for hiding this comment

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

LGTM. Thank you.

@Snuffleupagus Snuffleupagus merged commit 93961e2 into mozilla:master Oct 28, 2024
11 checks passed
@Snuffleupagus Snuffleupagus deleted the AltText-fluent branch October 28, 2024 19:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
editor l10n Localization
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants