Skip to content

Commit

Permalink
Sync Calypso locale to Atomic Classic & Atomic Default (#39009)
Browse files Browse the repository at this point in the history
* Sync locale on Atomic Classic

* changelog

* Update versions

* Revert "Sync locale on Atomic Classic"

This reverts commit 9a79265b5dccbc2d90fdd4852772c302b84854c7.

* Extract locale sync logic

* changelog

* Bump versions

* Fix phan errors

* Remove return type

* Add guard clause

* Revert version bump in masterbar

* Revert jetpack change

* Update composer.lock

* Change the directory name

* Load wpcom-profile-settings only for wpcom users

* Update composer.lock

* Remove locale sync from Masterbar package

* changelog

* Bump versions

Committed via a GitHub action: https://github.com/Automattic/jetpack/actions/runs/10504061625

Upstream-Ref: Automattic/jetpack@ba84857
  • Loading branch information
okmttdhr authored and matticbot committed Aug 22, 2024
1 parent 5272239 commit e4e26f5
Show file tree
Hide file tree
Showing 11 changed files with 216 additions and 108 deletions.
64 changes: 32 additions & 32 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions vendor/automattic/jetpack-masterbar/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [0.7.1-alpha] - unreleased
## [0.8.0-alpha] - unreleased

This is an alpha version! The changes listed here are not final.

### Changed
- Remove locale sync
- Updated package dependencies.

## [0.7.0] - 2024-08-21
Expand Down Expand Up @@ -101,7 +102,7 @@ This is an alpha version! The changes listed here are not final.
- Updated package dependencies. [#37669]
- Updated package dependencies. [#37706]

[0.7.1-alpha]: https://github.com/Automattic/jetpack-masterbar/compare/v0.7.0...v0.7.1-alpha
[0.8.0-alpha]: https://github.com/Automattic/jetpack-masterbar/compare/v0.7.0...v0.8.0-alpha
[0.7.0]: https://github.com/Automattic/jetpack-masterbar/compare/v0.6.1...v0.7.0
[0.6.1]: https://github.com/Automattic/jetpack-masterbar/compare/v0.6.0...v0.6.1
[0.6.0]: https://github.com/Automattic/jetpack-masterbar/compare/v0.5.0...v0.6.0
Expand Down
2 changes: 1 addition & 1 deletion vendor/automattic/jetpack-masterbar/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
"extra": {
"autotagger": true,
"branch-alias": {
"dev-trunk": "0.7.x-dev"
"dev-trunk": "0.8.x-dev"
},
"changelogger": {
"link-template": "https://github.com/Automattic/jetpack-masterbar/compare/v${old}...v${new}"
Expand Down
2 changes: 1 addition & 1 deletion vendor/automattic/jetpack-masterbar/src/class-main.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
*/
class Main {

const PACKAGE_VERSION = '0.7.1-alpha';
const PACKAGE_VERSION = '0.8.0-alpha';

/**
* Initializer.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -135,13 +135,6 @@ public function __construct() {
if ( isset( $this->user_data['use_wp_admin_links'] ) ) {
update_user_option( $this->user_id, 'jetpack_admin_menu_link_destination', $this->user_data['use_wp_admin_links'] ? '1' : '0' );
}
// If Atomic, store and install user locale.
if ( $this->site_woa && 'wp-admin' !== get_option( 'wpcom_admin_interface' ) ) {
$this->user_locale = $this->get_jetpack_locale( $this->user_locale );
$this->install_locale( $this->user_locale );
$this->unload_non_default_textdomains_on_wpcom_user_locale_switch( $this->user_locale );
update_user_option( $this->user_id, 'locale', $this->user_locale, true );
}

add_action( 'admin_bar_init', array( $this, 'init' ) );

Expand Down
3 changes: 3 additions & 0 deletions vendor/automattic/jetpack-mu-wpcom/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

This is an alpha version! The changes listed here are not final.

### Added
- Sync Calypso locale to Atomic Classic

### Changed
- Replace language selector with a link to WPCOM
- Updated package dependencies.
Expand Down
2 changes: 1 addition & 1 deletion vendor/automattic/jetpack-mu-wpcom/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"automattic/jetpack-calypsoify": "^0.1.4-alpha",
"automattic/jetpack-classic-theme-helper": "^0.5.2-alpha",
"automattic/jetpack-connection": "^2.12.4-alpha",
"automattic/jetpack-masterbar": "^0.7.1-alpha",
"automattic/jetpack-masterbar": "^0.8.0-alpha",
"automattic/jetpack-redirect": "^2.0.3-alpha",
"automattic/jetpack-stats-admin": "^0.21.1-alpha",
"automattic/jetpack-status": "^3.3.4-alpha",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,6 @@ public static function load_features() {
require_once __DIR__ . '/features/wpcom-block-editor/class-jetpack-wpcom-block-editor.php';
require_once __DIR__ . '/features/wpcom-block-editor/functions.editor-type.php';
require_once __DIR__ . '/features/wpcom-logout/wpcom-logout.php';
require_once __DIR__ . '/features/wpcom-profile-settings/profile-settings-link-to-wpcom.php';
require_once __DIR__ . '/features/wpcom-profile-settings/profile-settings-notices.php';
require_once __DIR__ . '/features/wpcom-themes/wpcom-theme-fixes.php';

// Initializers, if needed.
Expand Down Expand Up @@ -143,7 +141,10 @@ public static function load_wpcom_user_features() {
require_once __DIR__ . '/features/wpcom-admin-interface/wpcom-admin-interface.php';
require_once __DIR__ . '/features/wpcom-admin-menu/wpcom-admin-menu.php';
require_once __DIR__ . '/features/wpcom-command-palette/wpcom-command-palette.php';
require_once __DIR__ . '/features/wpcom-locale/sync-locale-from-calypso-to-atomic.php';
require_once __DIR__ . '/features/wpcom-plugins/wpcom-plugins.php';
require_once __DIR__ . '/features/wpcom-profile-settings/profile-settings-link-to-wpcom.php';
require_once __DIR__ . '/features/wpcom-profile-settings/profile-settings-notices.php';
require_once __DIR__ . '/features/wpcom-sidebar-notice/wpcom-sidebar-notice.php';
require_once __DIR__ . '/features/wpcom-site-management-widget/class-wpcom-site-management-widget.php';
require_once __DIR__ . '/features/wpcom-themes/wpcom-themes.php';
Expand Down
Loading

0 comments on commit e4e26f5

Please sign in to comment.