mirror of
https://github.com/react/react-native-devtools-frontend.git
synced 2026-10-12 17:45:49 +08:00
This reverts commit012f9c0fc7. Reason for revert: upstream web test is now temporarily disabled https://chromium-review.googlesource.com/c/chromium/src/+/2119533 Original change's description: > Revert "Enable emulating locales" > > This reverts commita36992378f. > > Reason for revert: https://ci.chromium.org/p/chromium/builders/try/mac-rel/333856? > > Original change's description: > > Enable emulating locales > > > > This patch adds support for emulating locales through the Sensors > > drawer. Similar to timezone emulation, it’s tied to geolocation > > emulation, completing the “user location emulation” feature set. > > > > Locale emulation affects: > > > > - *.prototype.toLocaleString > > e.g. `123_456..toLocaleString()` > > - Intl.* APIs > > e.g. `new Intl.NumberFormat().resolvedOptions().locale` > > - navigator.language > > - navigator.languages > > - the Accept-Language HTTP header > > > > Note that until chromium:1057096 gets fixed, updates to > > `navigator.language` and `navigator.languages` are not visible > > immediately, but only after the next navigation/page reload. > > > > Changes to the `Accept-Language` HTTP header are only reflected > > for subsequent requests (but that’s unsurprising). > > > > Once chromium:1051186 is fixed, we can simplify the implementation > > by dropping the call to Emulation.setUserAgentOverride. > > > > Boring but useful test/demo pages: > > - https://mathiasbynens.be/demo/locale > > - https://mathiasbynens.be/demo/locale#includeExtras > > > > Demo video: https://www.youtube.com/watch?v=lZEFwACYPo0 > > > > Design doc: https://goo.gle/devtools-locale-emulation > > > > Bug: chromium:1051186, chromium:1051822, chromium:1057096 > > Change-Id: I0371f450ed23511816941f3a59c14236aea64408 > > Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2082371 > > Commit-Queue: Mathias Bynens <mathias@chromium.org> > > Reviewed-by: Changhao Han <changhaohan@chromium.org> > > TBR=mathias@chromium.org,changhaohan@chromium.org > > Change-Id: Iffcacdb304aa107c787266e07dca87cadbe79337 > No-Presubmit: true > No-Tree-Checks: true > No-Try: true > Bug: chromium:1051186, chromium:1051822, chromium:1057096 > Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2116238 > Reviewed-by: Yang Guo <yangguo@chromium.org> > Commit-Queue: Yang Guo <yangguo@chromium.org> TBR=yangguo@chromium.org,mathias@chromium.org,changhaohan@chromium.org Cq-Depend: chromium:2119533 Change-Id: I003287fd4524dd88aceac0dbfb7e88e90f26b03f No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: chromium:1051186, chromium:1051822, chromium:1057096 Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2119672 Commit-Queue: Mathias Bynens <mathias@chromium.org> Reviewed-by: Mathias Bynens <mathias@chromium.org> Reviewed-by: Yang Guo <yangguo@chromium.org>
42 lines
1.4 KiB
JavaScript
42 lines
1.4 KiB
JavaScript
// Copyright 2019 The Chromium Authors. All rights reserved.
|
|
// Use of this source code is governed by a BSD-style license that can be
|
|
// found in the LICENSE file.
|
|
|
|
import './AdvancedApp.js';
|
|
import './EmulatedDevices.js';
|
|
import './DevicesSettingsTab.js';
|
|
import './InspectedPagePlaceholder.js';
|
|
import './MediaQueryInspector.js';
|
|
import './SensorsView.js';
|
|
import './DeviceModeModel.js';
|
|
import './DeviceModeToolbar.js';
|
|
import './DeviceModeView.js';
|
|
import './DeviceModeWrapper.js';
|
|
import './LocationsSettingsTab.js';
|
|
|
|
import * as AdvancedApp from './AdvancedApp.js';
|
|
import * as DeviceModeModel from './DeviceModeModel.js';
|
|
import * as DeviceModeToolbar from './DeviceModeToolbar.js';
|
|
import * as DeviceModeView from './DeviceModeView.js';
|
|
import * as DeviceModeWrapper from './DeviceModeWrapper.js';
|
|
import * as DevicesSettingsTab from './DevicesSettingsTab.js';
|
|
import * as EmulatedDevices from './EmulatedDevices.js';
|
|
import * as InspectedPagePlaceholder from './InspectedPagePlaceholder.js';
|
|
import * as LocationsSettingsTab from './LocationsSettingsTab.js';
|
|
import * as MediaQueryInspector from './MediaQueryInspector.js';
|
|
import * as SensorsView from './SensorsView.js';
|
|
|
|
export {
|
|
AdvancedApp,
|
|
DeviceModeModel,
|
|
DeviceModeToolbar,
|
|
DeviceModeView,
|
|
DeviceModeWrapper,
|
|
DevicesSettingsTab,
|
|
EmulatedDevices,
|
|
InspectedPagePlaceholder,
|
|
LocationsSettingsTab,
|
|
MediaQueryInspector,
|
|
SensorsView,
|
|
};
|