WordPress.org

Making WordPress.org

Opened 3 months ago

Closed 3 months ago

#5892 closed enhancement (fixed)

Update WordPress.org Openverse theme to pass i18n/L10n info to the iframe

Reported by: dhruvkb Owned by: dd32
Milestone: Priority: normal
Component: General Keywords: has-patch
Cc:

Description

The GitHub PR (https://github.com/WordPress/wordpress.org/pull/39) adds styling to ensure that the iframe on site https://wordpress.org/openverse receives i18n data from the parent window (when it asks for it).

Change History (2)

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


3 months ago

Fixes WordPress/openverse-frontend#189

Closes https://meta.trac.wordpress.org/ticket/5892

---

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:
{{{json
{

"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 months 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.
Closes https://github.com/WordPress/wordpress.org/pull/39

Note: See TracTickets for help on using tickets.