Opened 6 weeks ago
Closed 6 weeks ago
#64410 closed defect (bug) (reported-upstream)
Language dialog pops up twice; language chosen the first time not being applied.
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Milestone: | Priority: | normal | |
| Severity: | normal | Version: | 6.9 |
| Component: | Editor | Keywords: | |
| Focuses: | Cc: |
Description
The Language / text direction selector, in the block editor, pops up twice when selected. If I enter a language code the first time, but not the second time, the <bdo> element inserted ends up having an empty language attribute. In other words, the selected language is not being applied, ending up with markup like this:
<p><bdo lang="" dir="ltr">I Danmark taler de fleste dansk</bdo></p>
I'm not sure whether that is by design, but I don't assume it is.
Can you reproduce?
Attachments (1)
Change History (8)
#1
@
6 weeks ago
- Component changed from General to Editor
- Milestone changed from Awaiting Review to 6.9.1
#2
@
6 weeks ago
I was unable to reproduce the issue on 6.9. Is my testing procedure correct?
- Access https://playground.wordpress.net/?wp=6.9
- Open the initial post with the title Hello world!
- Select the word "WordPress"
- Click the "Language" button in the block toolbar
- The language popover opens
- Fill the Language field with
en - Click the Apply button
- The language popover closes
- Open the code editor
- Confirm that the bdo tag is applied correctly
<!-- wp:paragraph --> <p>Welcome to <bdo lang="en" dir="ltr">WordPress</bdo>. This is your first post. Edit or delete it, then start writing!</p> <!-- /wp:paragraph -->
#3
@
6 weeks ago
I tested this bug in my environment but also unable to reproduce same as @wildworks .
See the below image for verify :
https://ibb.co/cch9mQF7
#4
@
6 weeks ago
@wildworks Yes, that is the procedure; however, I'm getting different results.
After step 7, clicking the apply button, the dialog closes and immediately reopens, with the language field empty. If I just click apply again, the <bdo> element is added with an empty language attribute.
I made a quick screencast to illustrate my results.
https://oldrup.dk/wp-content/uploads/2025/12/language-popup-twice.mp4
This is how it works on all the WP 6.9 installations I've tested it on. On WP 6.8, the dialog is only shown once (my attempt to rule out a browser issue)
#5
@
6 weeks ago
@oldrup Thanks for the reply. I discovered that this issue cannot be reproduced in Chrome, but can be reproduced in Firefox. Right?
#6
@
6 weeks ago
@wildworks Ah, confirmed; tested on WordPress Playground in Chrome and Firefox 146 in incognito/private mode (no extensions activated)
✅In Chrome it works as expecte
⚠️In Firefox the dialog is shown twice, the second time with an empty language field.
I've tested in Firefox on two different computers and on numerous websites, including WP 6.8 sites, where I don't have this issue.
I can reproduce the behavior in 6.9, but not with Gutenberg 22.2.0 activated. It might have been fixed in the plugin already, but I did not find a related issue or PR in the Gutenberg repository (or its changelog).