Opened 3 years ago

Closed 3 years ago

#5892 closed enhancement (fixed)

Update Openverse theme to pass i18n/L10n info to the iframe

Reported by: dhruvkb's profile dhruvkb Owned by: dd32's profile dd32
Milestone: Priority: normal
Component: General Keywords: has-patch


The GitHub PR ( adds styling to ensure that the iframe on site receives i18n data from the parent window (when it asks for it).

Change History (2)

This ticket was mentioned in PR #39 on WordPress/ by dhruvkb.

3 years ago

Fixes WordPress/openverse-frontend#189



This PR adds functionality for the Openverse frontend loaded in the iframe to ask the parent window information about the locale.

iframe —(localeGet event)→ parent window
iframe ←(localeSet event)— parent window

## Description

The localeSet message contains the following data:

"type": "localeSet",
"value": {

"dir": "",
"lang": "en-US",
"locale": "en_US"



| Key | Interpretation |


| dir | Value of parent HTML dir attribute |
| lang | Value of parent HTML lang attribute |
| locale | Value of WordPress get_locale() function |

#2 @dd32
3 years ago

  • Owner set to dd32
  • Resolution set to fixed
  • Status changed from new to closed

In 11217:

Openverse: Update the theme to pass the locale.

Fixes #5892.

Note: See TracTickets for help on using tickets.