Update On Fri Jan 21 19:29:11 CET 2022
This commit is contained in:
parent
52ae598339
commit
0d42a856e4
338 changed files with 6817 additions and 19263 deletions
|
@ -660,11 +660,11 @@ mozilla::java::GeckoBundle::LocalRef AccessibleWrap::ToBundle(bool aSmall) {
|
|||
}
|
||||
|
||||
mozilla::java::GeckoBundle::LocalRef AccessibleWrap::ToBundle(
|
||||
const uint64_t aState, const nsIntRect& aBounds, const uint8_t aActionCount,
|
||||
const nsString& aName, const nsString& aTextValue,
|
||||
const nsString& aDOMNodeID, const nsString& aDescription,
|
||||
const double& aCurVal, const double& aMinVal, const double& aMaxVal,
|
||||
const double& aStep, AccAttributes* aAttributes) {
|
||||
const uint64_t aState, const LayoutDeviceIntRect& aBounds,
|
||||
const uint8_t aActionCount, const nsString& aName,
|
||||
const nsString& aTextValue, const nsString& aDOMNodeID,
|
||||
const nsString& aDescription, const double& aCurVal, const double& aMinVal,
|
||||
const double& aMaxVal, const double& aStep, AccAttributes* aAttributes) {
|
||||
if (!IsProxy() && IsDefunct()) {
|
||||
return nullptr;
|
||||
}
|
||||
|
|
|
@ -55,7 +55,7 @@ class AccessibleWrap : public LocalAccessible {
|
|||
mozilla::java::GeckoBundle::LocalRef ToBundle(bool aSmall = false);
|
||||
|
||||
mozilla::java::GeckoBundle::LocalRef ToBundle(
|
||||
const uint64_t aState, const nsIntRect& aBounds,
|
||||
const uint64_t aState, const LayoutDeviceIntRect& aBounds,
|
||||
const uint8_t aActionCount, const nsString& aName,
|
||||
const nsString& aTextValue, const nsString& aDOMNodeID,
|
||||
const nsString& aDescription,
|
||||
|
|
|
@ -74,7 +74,9 @@ void RemoteAccessibleWrap::Value(nsString& aValue) const {
|
|||
|
||||
uint64_t RemoteAccessibleWrap::State() { return Proxy()->State(); }
|
||||
|
||||
nsIntRect RemoteAccessibleWrap::Bounds() const { return Proxy()->Bounds(); }
|
||||
mozilla::LayoutDeviceIntRect RemoteAccessibleWrap::Bounds() const {
|
||||
return Proxy()->Bounds();
|
||||
}
|
||||
|
||||
void RemoteAccessibleWrap::ScrollTo(uint32_t aHow) const {
|
||||
Proxy()->ScrollTo(aHow);
|
||||
|
|
|
@ -41,7 +41,7 @@ class RemoteAccessibleWrap : public AccessibleWrap {
|
|||
|
||||
virtual uint64_t State() override;
|
||||
|
||||
virtual nsIntRect Bounds() const override;
|
||||
virtual LayoutDeviceIntRect Bounds() const override;
|
||||
|
||||
MOZ_CAN_RUN_SCRIPT
|
||||
virtual void ScrollTo(uint32_t aHow) const override;
|
||||
|
|
|
@ -105,7 +105,8 @@ AtkObject* refAccessibleAtPointHelper(AtkObject* aAtkObj, gint aX, gint aY,
|
|||
node = browser->GetOwnerElement();
|
||||
}
|
||||
MOZ_ASSERT(node);
|
||||
nsIntPoint winCoords = nsCoreUtils::GetScreenCoordsForWindow(node);
|
||||
mozilla::LayoutDeviceIntPoint winCoords =
|
||||
nsCoreUtils::GetScreenCoordsForWindow(node);
|
||||
aX += winCoords.x;
|
||||
aY += winCoords.y;
|
||||
}
|
||||
|
@ -138,11 +139,11 @@ void getExtentsHelper(AtkObject* aAtkObj, gint* aX, gint* aY, gint* aWidth,
|
|||
return;
|
||||
}
|
||||
|
||||
nsIntRect screenRect = accWrap->Bounds();
|
||||
mozilla::LayoutDeviceIntRect screenRect = accWrap->Bounds();
|
||||
if (screenRect.IsEmpty()) return;
|
||||
|
||||
if (aCoordType == ATK_XY_WINDOW) {
|
||||
nsIntPoint winCoords =
|
||||
mozilla::LayoutDeviceIntPoint winCoords =
|
||||
nsCoreUtils::GetScreenCoordsForWindow(accWrap->GetNode());
|
||||
screenRect.x -= winCoords.x;
|
||||
screenRect.y -= winCoords.y;
|
||||
|
|
|
@ -21,7 +21,7 @@ const gchar* getDescriptionCB(AtkObject* aAtkObj);
|
|||
|
||||
static void getImagePositionCB(AtkImage* aImage, gint* aAccX, gint* aAccY,
|
||||
AtkCoordType aCoordType) {
|
||||
nsIntPoint pos = nsIntPoint(-1, -1);
|
||||
LayoutDeviceIntPoint pos(-1, -1);
|
||||
uint32_t geckoCoordType =
|
||||
(aCoordType == ATK_XY_WINDOW)
|
||||
? nsIAccessibleCoordinateType::COORDTYPE_WINDOW_RELATIVE
|
||||
|
@ -45,7 +45,7 @@ static const gchar* getImageDescriptionCB(AtkImage* aImage) {
|
|||
|
||||
static void getImageSizeCB(AtkImage* aImage, gint* aAccWidth,
|
||||
gint* aAccHeight) {
|
||||
nsIntSize size = nsIntSize(-1, -1);
|
||||
LayoutDeviceIntSize size(-1, -1);
|
||||
AccessibleWrap* accWrap = GetAccessibleWrap(ATK_OBJECT(aImage));
|
||||
if (accWrap && accWrap->IsImage()) {
|
||||
size = accWrap->AsImage()->Size();
|
||||
|
|
|
@ -323,7 +323,7 @@ static void getCharacterExtentsCB(AtkText* aText, gint aOffset, gint* aX,
|
|||
}
|
||||
*aX = *aY = *aWidth = *aHeight = -1;
|
||||
|
||||
nsIntRect rect;
|
||||
LayoutDeviceIntRect rect;
|
||||
uint32_t geckoCoordType;
|
||||
if (aCoords == ATK_XY_SCREEN) {
|
||||
geckoCoordType = nsIAccessibleCoordinateType::COORDTYPE_SCREEN_RELATIVE;
|
||||
|
@ -359,7 +359,7 @@ static void getRangeExtentsCB(AtkText* aText, gint aStartOffset,
|
|||
}
|
||||
aRect->x = aRect->y = aRect->width = aRect->height = -1;
|
||||
|
||||
nsIntRect rect;
|
||||
LayoutDeviceIntRect rect;
|
||||
uint32_t geckoCoordType;
|
||||
if (aCoords == ATK_XY_SCREEN) {
|
||||
geckoCoordType = nsIAccessibleCoordinateType::COORDTYPE_SCREEN_RELATIVE;
|
||||
|
|
|
@ -547,8 +547,9 @@ Accessible* Pivot::AtPoint(int32_t aX, int32_t aY, PivotRule& aRule) {
|
|||
|
||||
// Match if no node below this is a match
|
||||
if ((filtered & nsIAccessibleTraversalRule::FILTER_MATCH) && !match) {
|
||||
nsIntRect childRect = child->IsLocal() ? child->AsLocal()->Bounds()
|
||||
: child->AsRemote()->Bounds();
|
||||
LayoutDeviceIntRect childRect = child->IsLocal()
|
||||
? child->AsLocal()->Bounds()
|
||||
: child->AsRemote()->Bounds();
|
||||
// Double-check child's bounds since the deepest child may have been out
|
||||
// of bounds. This assures we don't return a false positive.
|
||||
if (childRect.Contains(aX, aY)) {
|
||||
|
|
|
@ -244,10 +244,10 @@ HyperTextAccessible* nsAccUtils::GetTextContainer(nsINode* aNode) {
|
|||
return nullptr;
|
||||
}
|
||||
|
||||
nsIntPoint nsAccUtils::ConvertToScreenCoords(int32_t aX, int32_t aY,
|
||||
uint32_t aCoordinateType,
|
||||
LocalAccessible* aAccessible) {
|
||||
nsIntPoint coords(aX, aY);
|
||||
LayoutDeviceIntPoint nsAccUtils::ConvertToScreenCoords(
|
||||
int32_t aX, int32_t aY, uint32_t aCoordinateType,
|
||||
LocalAccessible* aAccessible) {
|
||||
LayoutDeviceIntPoint coords(aX, aY);
|
||||
|
||||
switch (aCoordinateType) {
|
||||
case nsIAccessibleCoordinateType::COORDTYPE_SCREEN_RELATIVE:
|
||||
|
@ -278,7 +278,7 @@ void nsAccUtils::ConvertScreenCoordsTo(int32_t* aX, int32_t* aY,
|
|||
break;
|
||||
|
||||
case nsIAccessibleCoordinateType::COORDTYPE_WINDOW_RELATIVE: {
|
||||
nsIntPoint coords =
|
||||
LayoutDeviceIntPoint coords =
|
||||
nsCoreUtils::GetScreenCoordsForWindow(aAccessible->GetNode());
|
||||
*aX -= coords.x;
|
||||
*aY -= coords.y;
|
||||
|
@ -286,7 +286,7 @@ void nsAccUtils::ConvertScreenCoordsTo(int32_t* aX, int32_t* aY,
|
|||
}
|
||||
|
||||
case nsIAccessibleCoordinateType::COORDTYPE_PARENT_RELATIVE: {
|
||||
nsIntPoint coords = GetScreenCoordsForParent(aAccessible);
|
||||
LayoutDeviceIntPoint coords = GetScreenCoordsForParent(aAccessible);
|
||||
*aX -= coords.x;
|
||||
*aY -= coords.y;
|
||||
break;
|
||||
|
@ -297,16 +297,18 @@ void nsAccUtils::ConvertScreenCoordsTo(int32_t* aX, int32_t* aY,
|
|||
}
|
||||
}
|
||||
|
||||
nsIntPoint nsAccUtils::GetScreenCoordsForParent(LocalAccessible* aAccessible) {
|
||||
LayoutDeviceIntPoint nsAccUtils::GetScreenCoordsForParent(
|
||||
LocalAccessible* aAccessible) {
|
||||
LocalAccessible* parent = aAccessible->LocalParent();
|
||||
if (!parent) return nsIntPoint(0, 0);
|
||||
if (!parent) return LayoutDeviceIntPoint(0, 0);
|
||||
|
||||
nsIFrame* parentFrame = parent->GetFrame();
|
||||
if (!parentFrame) return nsIntPoint(0, 0);
|
||||
if (!parentFrame) return LayoutDeviceIntPoint(0, 0);
|
||||
|
||||
nsRect rect = parentFrame->GetScreenRectInAppUnits();
|
||||
return nsPoint(rect.X(), rect.Y())
|
||||
.ToNearestPixels(parentFrame->PresContext()->AppUnitsPerDevPixel());
|
||||
nscoord appUnitsRatio = parentFrame->PresContext()->AppUnitsPerDevPixel();
|
||||
return LayoutDeviceIntPoint::FromAppUnitsToNearest(
|
||||
nsPoint(rect.X(), rect.Y()), appUnitsRatio);
|
||||
}
|
||||
|
||||
bool nsAccUtils::GetLiveAttrValue(uint32_t aRule, nsAString& aValue) {
|
||||
|
|
|
@ -131,24 +131,24 @@ class nsAccUtils {
|
|||
/**
|
||||
* Converts the given coordinates to coordinates relative screen.
|
||||
*
|
||||
* @param aX [in] the given x coord
|
||||
* @param aY [in] the given y coord
|
||||
* @param aX [in] the given x coord in dev pixels
|
||||
* @param aY [in] the given y coord in dev pixels
|
||||
* @param aCoordinateType [in] specifies coordinates origin (refer to
|
||||
* nsIAccessibleCoordinateType)
|
||||
* @param aAccessible [in] the accessible if coordinates are given
|
||||
* relative it.
|
||||
* @return converted coordinates
|
||||
*/
|
||||
static nsIntPoint ConvertToScreenCoords(int32_t aX, int32_t aY,
|
||||
uint32_t aCoordinateType,
|
||||
LocalAccessible* aAccessible);
|
||||
static LayoutDeviceIntPoint ConvertToScreenCoords(
|
||||
int32_t aX, int32_t aY, uint32_t aCoordinateType,
|
||||
LocalAccessible* aAccessible);
|
||||
|
||||
/**
|
||||
* Converts the given coordinates relative screen to another coordinate
|
||||
* system.
|
||||
*
|
||||
* @param aX [in, out] the given x coord
|
||||
* @param aY [in, out] the given y coord
|
||||
* @param aX [in, out] the given x coord in dev pixels
|
||||
* @param aY [in, out] the given y coord in dev pixels
|
||||
* @param aCoordinateType [in] specifies coordinates origin (refer to
|
||||
* nsIAccessibleCoordinateType)
|
||||
* @param aAccessible [in] the accessible if coordinates are given
|
||||
|
@ -159,11 +159,13 @@ class nsAccUtils {
|
|||
LocalAccessible* aAccessible);
|
||||
|
||||
/**
|
||||
* Returns coordinates relative screen for the parent of the given accessible.
|
||||
* Returns screen-relative coordinates (in dev pixels) for the parent of the
|
||||
* given accessible.
|
||||
*
|
||||
* @param [in] aAccessible the accessible
|
||||
*/
|
||||
static nsIntPoint GetScreenCoordsForParent(LocalAccessible* aAccessible);
|
||||
static LayoutDeviceIntPoint GetScreenCoordsForParent(
|
||||
LocalAccessible* aAccessible);
|
||||
|
||||
/**
|
||||
* Get the 'live' or 'container-live' object attribute value from the given
|
||||
|
|
|
@ -255,12 +255,12 @@ nsresult nsCoreUtils::ScrollSubstringTo(nsIFrame* aFrame, nsRange* aRange,
|
|||
|
||||
void nsCoreUtils::ScrollFrameToPoint(nsIFrame* aScrollableFrame,
|
||||
nsIFrame* aFrame,
|
||||
const nsIntPoint& aPoint) {
|
||||
const LayoutDeviceIntPoint& aPoint) {
|
||||
nsIScrollableFrame* scrollableFrame = do_QueryFrame(aScrollableFrame);
|
||||
if (!scrollableFrame) return;
|
||||
|
||||
nsPoint point =
|
||||
ToAppUnits(aPoint, aFrame->PresContext()->AppUnitsPerDevPixel());
|
||||
nsPoint point = LayoutDeviceIntPoint::ToAppUnits(
|
||||
aPoint, aFrame->PresContext()->AppUnitsPerDevPixel());
|
||||
nsRect frameRect = aFrame->GetScreenRectInAppUnits();
|
||||
nsPoint deltaPoint = point - frameRect.TopLeft();
|
||||
|
||||
|
@ -322,8 +322,8 @@ void nsCoreUtils::ConvertScrollTypeToPercents(uint32_t aScrollType,
|
|||
*aHorizontal = ScrollAxis(whereX, whenX);
|
||||
}
|
||||
|
||||
nsIntPoint nsCoreUtils::GetScreenCoordsForWindow(nsINode* aNode) {
|
||||
nsIntPoint coords(0, 0);
|
||||
LayoutDeviceIntPoint nsCoreUtils::GetScreenCoordsForWindow(nsINode* aNode) {
|
||||
LayoutDeviceIntPoint coords(0, 0);
|
||||
nsCOMPtr<nsIDocShellTreeItem> treeItem(GetDocShellFor(aNode));
|
||||
if (!treeItem) return coords;
|
||||
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
|
||||
#include "nsPoint.h"
|
||||
#include "nsTArray.h"
|
||||
#include "Units.h"
|
||||
|
||||
class nsRange;
|
||||
class nsTreeColumn;
|
||||
|
@ -167,10 +168,10 @@ class nsCoreUtils {
|
|||
*
|
||||
* @param aScrollableFrame the scrollable frame
|
||||
* @param aFrame the frame to scroll
|
||||
* @param aPoint the point scroll to
|
||||
* @param aPoint the point scroll to (in dev pixels)
|
||||
*/
|
||||
static void ScrollFrameToPoint(nsIFrame* aScrollableFrame, nsIFrame* aFrame,
|
||||
const nsIntPoint& aPoint);
|
||||
const mozilla::LayoutDeviceIntPoint& aPoint);
|
||||
|
||||
/**
|
||||
* Converts scroll type constant defined in nsIAccessibleScrollType to
|
||||
|
@ -186,7 +187,7 @@ class nsCoreUtils {
|
|||
*
|
||||
* @param aNode the DOM node hosted in the window.
|
||||
*/
|
||||
static nsIntPoint GetScreenCoordsForWindow(nsINode* aNode);
|
||||
static mozilla::LayoutDeviceIntPoint GetScreenCoordsForWindow(nsINode* aNode);
|
||||
|
||||
/**
|
||||
* Return document shell for the given DOM node.
|
||||
|
|
|
@ -10,6 +10,7 @@
|
|||
#include "mozilla/a11y/AccTypes.h"
|
||||
#include "nsString.h"
|
||||
#include "nsRect.h"
|
||||
#include "Units.h"
|
||||
|
||||
class nsAtom;
|
||||
|
||||
|
@ -157,7 +158,10 @@ class Accessible {
|
|||
virtual double MaxValue() const = 0;
|
||||
virtual double Step() const = 0;
|
||||
|
||||
virtual nsIntRect Bounds() const = 0;
|
||||
/**
|
||||
* Return boundaries in screen coordinates in device pixels.
|
||||
*/
|
||||
virtual LayoutDeviceIntRect Bounds() const = 0;
|
||||
|
||||
/**
|
||||
* Returns text of accessible if accessible has text role otherwise empty
|
||||
|
|
|
@ -94,7 +94,9 @@ Relation ApplicationAccessible::RelationByType(
|
|||
return Relation();
|
||||
}
|
||||
|
||||
nsIntRect ApplicationAccessible::Bounds() const { return nsIntRect(); }
|
||||
mozilla::LayoutDeviceIntRect ApplicationAccessible::Bounds() const {
|
||||
return mozilla::LayoutDeviceIntRect();
|
||||
}
|
||||
|
||||
nsRect ApplicationAccessible::BoundsInAppUnits() const { return nsRect(); }
|
||||
|
||||
|
|
|
@ -33,7 +33,7 @@ class ApplicationAccessible : public AccessibleWrap {
|
|||
|
||||
// LocalAccessible
|
||||
virtual void Shutdown() override;
|
||||
virtual nsIntRect Bounds() const override;
|
||||
virtual LayoutDeviceIntRect Bounds() const override;
|
||||
virtual nsRect BoundsInAppUnits() const override;
|
||||
virtual already_AddRefed<AccAttributes> NativeAttributes() override;
|
||||
virtual GroupPos GroupPosition() override;
|
||||
|
|
|
@ -1094,7 +1094,7 @@ void DocAccessible::BindToDocument(LocalAccessible* aAccessible,
|
|||
}
|
||||
}
|
||||
|
||||
if (mIPCDoc) {
|
||||
if (StaticPrefs::accessibility_cache_enabled_AtStartup()) {
|
||||
mInsertedAccessibles.EnsureInserted(aAccessible);
|
||||
}
|
||||
}
|
||||
|
@ -1414,7 +1414,7 @@ void DocAccessible::ProcessBoundsChanged() {
|
|||
}
|
||||
|
||||
void DocAccessible::SendAccessiblesWillMove() {
|
||||
if (!mIPCDoc) {
|
||||
if (!mIPCDoc || !StaticPrefs::accessibility_cache_enabled_AtStartup()) {
|
||||
return;
|
||||
}
|
||||
nsTArray<uint64_t> ids;
|
||||
|
@ -2345,7 +2345,7 @@ bool DocAccessible::MoveChild(LocalAccessible* aChild,
|
|||
if (curParent == aNewParent) {
|
||||
MOZ_ASSERT(aChild->IndexInParent() != aIdxInParent, "No move case");
|
||||
curParent->RelocateChild(aIdxInParent, aChild);
|
||||
if (mIPCDoc) {
|
||||
if (StaticPrefs::accessibility_cache_enabled_AtStartup()) {
|
||||
TrackMovedAccessible(aChild);
|
||||
}
|
||||
|
||||
|
@ -2374,7 +2374,7 @@ bool DocAccessible::MoveChild(LocalAccessible* aChild,
|
|||
|
||||
TreeMutation imut(aNewParent);
|
||||
aNewParent->InsertChildAt(aIdxInParent, aChild);
|
||||
if (mIPCDoc) {
|
||||
if (StaticPrefs::accessibility_cache_enabled_AtStartup()) {
|
||||
TrackMovedAccessible(aChild);
|
||||
}
|
||||
imut.AfterInsertion(aChild);
|
||||
|
|
|
@ -507,9 +507,6 @@ class DocAccessible : public HyperTextAccessibleWrap,
|
|||
*/
|
||||
void ProcessBoundsChanged();
|
||||
|
||||
/**
|
||||
* Only works in content process documents.
|
||||
*/
|
||||
bool IsAccessibleBeingMoved(LocalAccessible* aAcc) {
|
||||
return mMovedAccessibles.Contains(aAcc);
|
||||
}
|
||||
|
@ -747,8 +744,8 @@ class DocAccessible : public HyperTextAccessibleWrap,
|
|||
void SetRoleMapEntryForDoc(dom::Element* aElement);
|
||||
|
||||
/**
|
||||
* This must be called whenever an Accessible is moved in a content process.
|
||||
* It keeps track of Accessibles moved during this tick.
|
||||
* This must be called whenever an Accessible is moved if the cache is
|
||||
* enabled. It keeps track of Accessibles moved during this tick.
|
||||
*/
|
||||
void TrackMovedAccessible(LocalAccessible* aAcc);
|
||||
|
||||
|
@ -758,11 +755,11 @@ class DocAccessible : public HyperTextAccessibleWrap,
|
|||
DocAccessibleChild* mIPCDoc;
|
||||
|
||||
nsTHashSet<RefPtr<LocalAccessible>> mMaybeBoundsChanged;
|
||||
// A set of Accessibles moved during this tick. Only used in content
|
||||
// processes.
|
||||
// A set of Accessibles moved during this tick. Only used if the cache is
|
||||
// enabled.
|
||||
nsTHashSet<RefPtr<LocalAccessible>> mMovedAccessibles;
|
||||
// A set of Accessibles inserted during this tick. Only used in content
|
||||
// processes. This is needed to prevent insertions + moves of the same
|
||||
// A set of Accessibles inserted during this tick. Only used if the cache is
|
||||
// enabled. This is needed to prevent insertions + moves of the same
|
||||
// Accessible in the same tick from being tracked as moves.
|
||||
nsTHashSet<RefPtr<LocalAccessible>> mInsertedAccessibles;
|
||||
};
|
||||
|
|
|
@ -206,22 +206,22 @@ uint64_t HyperTextAccessible::NativeState() const {
|
|||
return states;
|
||||
}
|
||||
|
||||
nsIntRect HyperTextAccessible::GetBoundsInFrame(nsIFrame* aFrame,
|
||||
uint32_t aStartRenderedOffset,
|
||||
uint32_t aEndRenderedOffset) {
|
||||
LayoutDeviceIntRect HyperTextAccessible::GetBoundsInFrame(
|
||||
nsIFrame* aFrame, uint32_t aStartRenderedOffset,
|
||||
uint32_t aEndRenderedOffset) {
|
||||
nsPresContext* presContext = mDoc->PresContext();
|
||||
if (!aFrame->IsTextFrame()) {
|
||||
return aFrame->GetScreenRectInAppUnits().ToNearestPixels(
|
||||
presContext->AppUnitsPerDevPixel());
|
||||
return LayoutDeviceIntRect::FromAppUnitsToNearest(
|
||||
aFrame->GetScreenRectInAppUnits(), presContext->AppUnitsPerDevPixel());
|
||||
}
|
||||
|
||||
// Substring must be entirely within the same text node.
|
||||
int32_t startContentOffset, endContentOffset;
|
||||
nsresult rv = RenderedToContentOffset(aFrame, aStartRenderedOffset,
|
||||
&startContentOffset);
|
||||
NS_ENSURE_SUCCESS(rv, nsIntRect());
|
||||
NS_ENSURE_SUCCESS(rv, LayoutDeviceIntRect());
|
||||
rv = RenderedToContentOffset(aFrame, aEndRenderedOffset, &endContentOffset);
|
||||
NS_ENSURE_SUCCESS(rv, nsIntRect());
|
||||
NS_ENSURE_SUCCESS(rv, LayoutDeviceIntRect());
|
||||
|
||||
nsIFrame* frame;
|
||||
int32_t startContentOffsetInFrame;
|
||||
|
@ -229,7 +229,7 @@ nsIntRect HyperTextAccessible::GetBoundsInFrame(nsIFrame* aFrame,
|
|||
// the primary frame passed in
|
||||
rv = aFrame->GetChildFrameContainingOffset(
|
||||
startContentOffset, false, &startContentOffsetInFrame, &frame);
|
||||
NS_ENSURE_SUCCESS(rv, nsIntRect());
|
||||
NS_ENSURE_SUCCESS(rv, LayoutDeviceIntRect());
|
||||
|
||||
nsRect screenRect;
|
||||
while (frame && startContentOffset < endContentOffset) {
|
||||
|
@ -248,13 +248,13 @@ nsIntRect HyperTextAccessible::GetBoundsInFrame(nsIFrame* aFrame,
|
|||
// Add the point where the string starts to the frameScreenRect
|
||||
nsPoint frameTextStartPoint;
|
||||
rv = frame->GetPointFromOffset(startContentOffset, &frameTextStartPoint);
|
||||
NS_ENSURE_SUCCESS(rv, nsIntRect());
|
||||
NS_ENSURE_SUCCESS(rv, LayoutDeviceIntRect());
|
||||
|
||||
// Use the point for the end offset to calculate the width
|
||||
nsPoint frameTextEndPoint;
|
||||
rv = frame->GetPointFromOffset(startContentOffset + frameSubStringLength,
|
||||
&frameTextEndPoint);
|
||||
NS_ENSURE_SUCCESS(rv, nsIntRect());
|
||||
NS_ENSURE_SUCCESS(rv, LayoutDeviceIntRect());
|
||||
|
||||
frameScreenRect.SetRectX(
|
||||
frameScreenRect.X() +
|
||||
|
@ -269,7 +269,8 @@ nsIntRect HyperTextAccessible::GetBoundsInFrame(nsIFrame* aFrame,
|
|||
frame = frame->GetNextContinuation();
|
||||
}
|
||||
|
||||
return screenRect.ToNearestPixels(presContext->AppUnitsPerDevPixel());
|
||||
return LayoutDeviceIntRect::FromAppUnitsToNearest(
|
||||
screenRect, presContext->AppUnitsPerDevPixel());
|
||||
}
|
||||
|
||||
uint32_t HyperTextAccessible::DOMPointToOffset(nsINode* aNode,
|
||||
|
@ -1424,12 +1425,12 @@ int32_t HyperTextAccessible::OffsetAtPoint(int32_t aX, int32_t aY,
|
|||
nsIFrame* hyperFrame = GetFrame();
|
||||
if (!hyperFrame) return -1;
|
||||
|
||||
nsIntPoint coords =
|
||||
LayoutDeviceIntPoint coords =
|
||||
nsAccUtils::ConvertToScreenCoords(aX, aY, aCoordType, this);
|
||||
|
||||
nsPresContext* presContext = mDoc->PresContext();
|
||||
nsPoint coordsInAppUnits =
|
||||
ToAppUnits(coords, presContext->AppUnitsPerDevPixel());
|
||||
nsPoint coordsInAppUnits = LayoutDeviceIntPoint::ToAppUnits(
|
||||
coords, presContext->AppUnitsPerDevPixel());
|
||||
|
||||
nsRect frameScreenRect = hyperFrame->GetScreenRectInAppUnits();
|
||||
if (!frameScreenRect.Contains(coordsInAppUnits.x, coordsInAppUnits.y)) {
|
||||
|
@ -1485,15 +1486,15 @@ int32_t HyperTextAccessible::OffsetAtPoint(int32_t aX, int32_t aY,
|
|||
return -1; // Not found
|
||||
}
|
||||
|
||||
nsIntRect HyperTextAccessible::TextBounds(int32_t aStartOffset,
|
||||
int32_t aEndOffset,
|
||||
uint32_t aCoordType) {
|
||||
LayoutDeviceIntRect HyperTextAccessible::TextBounds(int32_t aStartOffset,
|
||||
int32_t aEndOffset,
|
||||
uint32_t aCoordType) {
|
||||
index_t startOffset = ConvertMagicOffset(aStartOffset);
|
||||
index_t endOffset = ConvertMagicOffset(aEndOffset);
|
||||
if (!startOffset.IsValid() || !endOffset.IsValid() ||
|
||||
startOffset > endOffset || endOffset > CharacterCount()) {
|
||||
NS_ERROR("Wrong in offset");
|
||||
return nsIntRect();
|
||||
return LayoutDeviceIntRect();
|
||||
}
|
||||
|
||||
if (CharacterCount() == 0) {
|
||||
|
@ -1501,16 +1502,16 @@ nsIntRect HyperTextAccessible::TextBounds(int32_t aStartOffset,
|
|||
// Empty content, use our own bound to at least get x,y coordinates
|
||||
nsIFrame* frame = GetFrame();
|
||||
if (!frame) {
|
||||
return nsIntRect();
|
||||
return LayoutDeviceIntRect();
|
||||
}
|
||||
return frame->GetScreenRectInAppUnits().ToNearestPixels(
|
||||
presContext->AppUnitsPerDevPixel());
|
||||
return LayoutDeviceIntRect::FromAppUnitsToNearest(
|
||||
frame->GetScreenRectInAppUnits(), presContext->AppUnitsPerDevPixel());
|
||||
}
|
||||
|
||||
int32_t childIdx = GetChildIndexAtOffset(startOffset);
|
||||
if (childIdx == -1) return nsIntRect();
|
||||
if (childIdx == -1) return LayoutDeviceIntRect();
|
||||
|
||||
nsIntRect bounds;
|
||||
LayoutDeviceIntRect bounds;
|
||||
int32_t prevOffset = GetChildOffset(childIdx);
|
||||
int32_t offset1 = startOffset - prevOffset;
|
||||
|
||||
|
@ -1540,8 +1541,9 @@ nsIntRect HyperTextAccessible::TextBounds(int32_t aStartOffset,
|
|||
// screen coordinates.
|
||||
nsPresContext* presContext = mDoc->PresContext();
|
||||
nsIFrame* rootFrame = presContext->PresShell()->GetRootFrame();
|
||||
nsIntRect orgRectPixels =
|
||||
rootFrame->GetScreenRectInAppUnits().ToNearestPixels(
|
||||
LayoutDeviceIntRect orgRectPixels =
|
||||
LayoutDeviceIntRect::FromAppUnitsToNearest(
|
||||
rootFrame->GetScreenRectInAppUnits(),
|
||||
presContext->AppUnitsPerDevPixel());
|
||||
bounds.MoveBy(-orgRectPixels.X(), -orgRectPixels.Y());
|
||||
bounds.ScaleRoundOut(presContext->PresShell()->GetResolution());
|
||||
|
@ -1803,7 +1805,7 @@ LayoutDeviceIntRect HyperTextAccessible::GetCaretRect(nsIWidget** aWidget) {
|
|||
// focus.
|
||||
return LayoutDeviceIntRect();
|
||||
}
|
||||
nsIntRect charRect = CharBounds(
|
||||
LayoutDeviceIntRect charRect = CharBounds(
|
||||
caretOffset, nsIAccessibleCoordinateType::COORDTYPE_SCREEN_RELATIVE);
|
||||
if (!charRect.IsEmpty()) {
|
||||
caretRect.SetTopEdge(charRect.Y());
|
||||
|
@ -1945,7 +1947,7 @@ void HyperTextAccessible::ScrollSubstringToPoint(int32_t aStartOffset,
|
|||
nsIFrame* frame = GetFrame();
|
||||
if (!frame) return;
|
||||
|
||||
nsIntPoint coords =
|
||||
LayoutDeviceIntPoint coords =
|
||||
nsAccUtils::ConvertToScreenCoords(aX, aY, aCoordinateType, this);
|
||||
|
||||
RefPtr<nsRange> domRange = nsRange::Create(mContent);
|
||||
|
@ -1955,8 +1957,8 @@ void HyperTextAccessible::ScrollSubstringToPoint(int32_t aStartOffset,
|
|||
}
|
||||
|
||||
nsPresContext* presContext = frame->PresContext();
|
||||
nsPoint coordsInAppUnits =
|
||||
ToAppUnits(coords, presContext->AppUnitsPerDevPixel());
|
||||
nsPoint coordsInAppUnits = LayoutDeviceIntPoint::ToAppUnits(
|
||||
coords, presContext->AppUnitsPerDevPixel());
|
||||
|
||||
bool initialScrolled = false;
|
||||
nsIFrame* parentFrame = frame;
|
||||
|
|
|
@ -184,18 +184,19 @@ class HyperTextAccessible : public AccessibleWrap,
|
|||
int32_t OffsetAtPoint(int32_t aX, int32_t aY, uint32_t aCoordType);
|
||||
|
||||
/**
|
||||
* Return a rect of the given text range relative given coordinate system.
|
||||
* Return a rect (in dev pixels) of the given text range relative given
|
||||
* coordinate system.
|
||||
*/
|
||||
nsIntRect TextBounds(
|
||||
LayoutDeviceIntRect TextBounds(
|
||||
int32_t aStartOffset, int32_t aEndOffset,
|
||||
uint32_t aCoordType =
|
||||
nsIAccessibleCoordinateType::COORDTYPE_SCREEN_RELATIVE);
|
||||
|
||||
/**
|
||||
* Return a rect for character at given offset relative given coordinate
|
||||
* system.
|
||||
* Return a rect (in dev pixels) for character at given offset relative given
|
||||
* coordinate system.
|
||||
*/
|
||||
nsIntRect CharBounds(int32_t aOffset, uint32_t aCoordType) {
|
||||
LayoutDeviceIntRect CharBounds(int32_t aOffset, uint32_t aCoordType) {
|
||||
int32_t endOffset = aOffset == static_cast<int32_t>(CharacterCount())
|
||||
? aOffset
|
||||
: aOffset + 1;
|
||||
|
@ -394,11 +395,13 @@ class HyperTextAccessible : public AccessibleWrap,
|
|||
EWordMovementType aWordMovementType = eDefaultBehavior);
|
||||
|
||||
/**
|
||||
* Return the boundaries of the substring in case of textual frame or
|
||||
* frame boundaries in case of non textual frame, offsets are ignored.
|
||||
* Return the boundaries (in dev pixels) of the substring in case of textual
|
||||
* frame or frame boundaries in case of non textual frame, offsets are
|
||||
* ignored.
|
||||
*/
|
||||
nsIntRect GetBoundsInFrame(nsIFrame* aFrame, uint32_t aStartRenderedOffset,
|
||||
uint32_t aEndRenderedOffset);
|
||||
LayoutDeviceIntRect GetBoundsInFrame(nsIFrame* aFrame,
|
||||
uint32_t aStartRenderedOffset,
|
||||
uint32_t aEndRenderedOffset);
|
||||
|
||||
// Selection helpers
|
||||
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
#include "nsPIDOMWindow.h"
|
||||
#include "nsIURI.h"
|
||||
|
||||
using namespace mozilla::a11y;
|
||||
namespace mozilla::a11y {
|
||||
|
||||
NS_IMPL_ISUPPORTS_INHERITED(ImageAccessible, LinkableAccessible,
|
||||
imgINotificationObserver)
|
||||
|
@ -137,7 +137,7 @@ bool ImageAccessible::DoAction(uint8_t aIndex) const {
|
|||
nsCOMPtr<nsPIDOMWindowOuter> piWindow = document->GetWindow();
|
||||
if (!piWindow) return false;
|
||||
|
||||
RefPtr<mozilla::dom::BrowsingContext> tmp;
|
||||
RefPtr<dom::BrowsingContext> tmp;
|
||||
return NS_SUCCEEDED(piWindow->Open(spec, u""_ns, u""_ns,
|
||||
/* aLoadInfo = */ nullptr,
|
||||
/* aForceNoOpener = */ false,
|
||||
|
@ -147,13 +147,13 @@ bool ImageAccessible::DoAction(uint8_t aIndex) const {
|
|||
////////////////////////////////////////////////////////////////////////////////
|
||||
// ImageAccessible
|
||||
|
||||
nsIntPoint ImageAccessible::Position(uint32_t aCoordType) {
|
||||
nsIntPoint point = Bounds().TopLeft();
|
||||
LayoutDeviceIntPoint ImageAccessible::Position(uint32_t aCoordType) {
|
||||
LayoutDeviceIntPoint point = Bounds().TopLeft();
|
||||
nsAccUtils::ConvertScreenCoordsTo(&point.x, &point.y, aCoordType, this);
|
||||
return point;
|
||||
}
|
||||
|
||||
nsIntSize ImageAccessible::Size() { return Bounds().Size(); }
|
||||
LayoutDeviceIntSize ImageAccessible::Size() { return Bounds().Size(); }
|
||||
|
||||
// LocalAccessible
|
||||
already_AddRefed<AccAttributes> ImageAccessible::NativeAttributes() {
|
||||
|
@ -247,3 +247,5 @@ void ImageAccessible::Notify(imgIRequest* aRequest, int32_t aType,
|
|||
|
||||
mImageRequestStatus = status;
|
||||
}
|
||||
|
||||
} // namespace mozilla::a11y
|
||||
|
|
|
@ -37,8 +37,8 @@ class ImageAccessible : public LinkableAccessible,
|
|||
virtual bool DoAction(uint8_t aIndex) const override;
|
||||
|
||||
// ImageAccessible
|
||||
nsIntPoint Position(uint32_t aCoordType);
|
||||
nsIntSize Size();
|
||||
LayoutDeviceIntPoint Position(uint32_t aCoordType);
|
||||
LayoutDeviceIntSize Size();
|
||||
|
||||
protected:
|
||||
virtual ~ImageAccessible();
|
||||
|
|
|
@ -501,7 +501,7 @@ LocalAccessible* LocalAccessible::LocalChildAtPoint(
|
|||
// If we can't find the point in a child, we will return the fallback answer:
|
||||
// we return |this| if the point is within it, otherwise nullptr.
|
||||
LocalAccessible* fallbackAnswer = nullptr;
|
||||
nsIntRect rect = Bounds();
|
||||
LayoutDeviceIntRect rect = Bounds();
|
||||
if (rect.Contains(aX, aY)) fallbackAnswer = this;
|
||||
|
||||
if (nsAccUtils::MustPrune(this)) { // Do not dig any further
|
||||
|
@ -611,7 +611,7 @@ LocalAccessible* LocalAccessible::LocalChildAtPoint(
|
|||
for (uint32_t childIdx = 0; childIdx < childCount; childIdx++) {
|
||||
LocalAccessible* child = accessible->LocalChildAt(childIdx);
|
||||
|
||||
nsIntRect childRect = child->Bounds();
|
||||
LayoutDeviceIntRect childRect = child->Bounds();
|
||||
if (childRect.Contains(aX, aY) &&
|
||||
(child->State() & states::INVISIBLE) == 0) {
|
||||
if (aWhichChild == EWhichChildAtPoint::DeepestChild) {
|
||||
|
@ -786,9 +786,9 @@ nsRect LocalAccessible::BoundsInAppUnits() const {
|
|||
return unionRectTwips;
|
||||
}
|
||||
|
||||
nsIntRect LocalAccessible::Bounds() const {
|
||||
return BoundsInAppUnits().ToNearestPixels(
|
||||
mDoc->PresContext()->AppUnitsPerDevPixel());
|
||||
LayoutDeviceIntRect LocalAccessible::Bounds() const {
|
||||
return LayoutDeviceIntRect::FromAppUnitsToNearest(
|
||||
BoundsInAppUnits(), mDoc->PresContext()->AppUnitsPerDevPixel());
|
||||
}
|
||||
|
||||
nsIntRect LocalAccessible::BoundsInCSSPixels() const {
|
||||
|
@ -2296,7 +2296,7 @@ void LocalAccessible::ScrollToPoint(uint32_t aCoordinateType, int32_t aX,
|
|||
nsIFrame* frame = GetFrame();
|
||||
if (!frame) return;
|
||||
|
||||
nsIntPoint coords =
|
||||
LayoutDeviceIntPoint coords =
|
||||
nsAccUtils::ConvertToScreenCoords(aX, aY, aCoordinateType, this);
|
||||
|
||||
nsIFrame* parentFrame = frame;
|
||||
|
|
|
@ -406,10 +406,7 @@ class LocalAccessible : public nsISupports, public Accessible {
|
|||
*/
|
||||
virtual nsRect BoundsInAppUnits() const;
|
||||
|
||||
/**
|
||||
* Return boundaries in screen coordinates.
|
||||
*/
|
||||
virtual nsIntRect Bounds() const override;
|
||||
virtual LayoutDeviceIntRect Bounds() const override;
|
||||
|
||||
/**
|
||||
* Return boundaries in screen coordinates in CSS pixels.
|
||||
|
|
|
@ -77,7 +77,7 @@ role OuterDocAccessible::NativeRole() const { return roles::INTERNAL_FRAME; }
|
|||
|
||||
LocalAccessible* OuterDocAccessible::LocalChildAtPoint(
|
||||
int32_t aX, int32_t aY, EWhichChildAtPoint aWhichChild) {
|
||||
nsIntRect docRect = Bounds();
|
||||
LayoutDeviceIntRect docRect = Bounds();
|
||||
if (!docRect.Contains(aX, aY)) return nullptr;
|
||||
|
||||
// Always return the inner doc as direct child accessible unless bounds
|
||||
|
@ -212,7 +212,7 @@ Accessible* OuterDocAccessible::ChildAt(uint32_t aIndex) const {
|
|||
|
||||
Accessible* OuterDocAccessible::ChildAtPoint(int32_t aX, int32_t aY,
|
||||
EWhichChildAtPoint aWhichChild) {
|
||||
nsIntRect docRect = Bounds();
|
||||
LayoutDeviceIntRect docRect = Bounds();
|
||||
if (!docRect.Contains(aX, aY)) return nullptr;
|
||||
|
||||
// Always return the inner doc as direct child accessible unless bounds
|
||||
|
|
|
@ -194,8 +194,8 @@ uint64_t HTMLSelectOptionAccessible::NativeState() const {
|
|||
// <select> is not collapsed: compare bounds to calculate OFFSCREEN
|
||||
LocalAccessible* listAcc = LocalParent();
|
||||
if (listAcc) {
|
||||
nsIntRect optionRect = Bounds();
|
||||
nsIntRect listRect = listAcc->Bounds();
|
||||
LayoutDeviceIntRect optionRect = Bounds();
|
||||
LayoutDeviceIntRect listRect = listAcc->Bounds();
|
||||
if (optionRect.Y() < listRect.Y() ||
|
||||
optionRect.YMost() > listRect.YMost()) {
|
||||
state |= states::OFFSCREEN;
|
||||
|
|
|
@ -916,10 +916,10 @@ void DocAccessibleParent::MaybeInitWindowEmulation() {
|
|||
MOZ_ASSERT(rootDocument);
|
||||
|
||||
bool isActive = true;
|
||||
nsIntRect rect(CW_USEDEFAULT, CW_USEDEFAULT, 0, 0);
|
||||
LayoutDeviceIntRect rect(CW_USEDEFAULT, CW_USEDEFAULT, 0, 0);
|
||||
if (Compatibility::IsDolphin()) {
|
||||
rect = Bounds();
|
||||
nsIntRect rootRect = rootDocument->Bounds();
|
||||
LayoutDeviceIntRect rootRect = rootDocument->Bounds();
|
||||
rect.MoveToX(rootRect.X() - rect.X());
|
||||
rect.MoveToY(rect.Y() - rootRect.Y());
|
||||
|
||||
|
|
|
@ -270,12 +270,12 @@ Maybe<nsRect> RemoteAccessibleBase<Derived>::RetrieveCachedBounds() const {
|
|||
}
|
||||
|
||||
template <class Derived>
|
||||
nsIntRect RemoteAccessibleBase<Derived>::Bounds() const {
|
||||
LayoutDeviceIntRect RemoteAccessibleBase<Derived>::Bounds() const {
|
||||
if (mCachedFields) {
|
||||
Maybe<nsRect> maybeBounds = RetrieveCachedBounds();
|
||||
if (maybeBounds) {
|
||||
nsRect bounds = *maybeBounds;
|
||||
nsIntRect devPxBounds;
|
||||
LayoutDeviceIntRect devPxBounds;
|
||||
dom::CanonicalBrowsingContext* cbc =
|
||||
static_cast<dom::BrowserParent*>(mDoc->Manager())
|
||||
->GetBrowsingContext()
|
||||
|
@ -290,11 +290,11 @@ nsIntRect RemoteAccessibleBase<Derived>::Bounds() const {
|
|||
const_cast<Accessible*>(acc)->AsLocal()) {
|
||||
// LocalAccessible::Bounds returns screen-relative bounds in
|
||||
// dev pixels.
|
||||
nsIntRect localBounds = localAcc->Bounds();
|
||||
LayoutDeviceIntRect localBounds = localAcc->Bounds();
|
||||
|
||||
// Convert our existing `bounds` rect from app units to dev pixels
|
||||
devPxBounds =
|
||||
bounds.ToNearestPixels(presContext->AppUnitsPerDevPixel());
|
||||
devPxBounds = LayoutDeviceIntRect::FromAppUnitsToNearest(
|
||||
bounds, presContext->AppUnitsPerDevPixel());
|
||||
|
||||
// We factor in our zoom level before offsetting by
|
||||
// `localBounds`, which has already taken zoom into account.
|
||||
|
@ -351,14 +351,14 @@ nsIntRect RemoteAccessibleBase<Derived>::Bounds() const {
|
|||
// viewport. We calculate the difference and translate our bounds here.
|
||||
nsPoint viewportOffset = presShell->GetVisualViewportOffset() -
|
||||
presShell->GetLayoutViewportOffset();
|
||||
devPxBounds.MoveBy(-(
|
||||
viewportOffset.ToNearestPixels(presContext->AppUnitsPerDevPixel())));
|
||||
devPxBounds.MoveBy(-(LayoutDeviceIntPoint::FromAppUnitsToNearest(
|
||||
viewportOffset, presContext->AppUnitsPerDevPixel())));
|
||||
|
||||
return devPxBounds;
|
||||
}
|
||||
}
|
||||
|
||||
return nsIntRect();
|
||||
return LayoutDeviceIntRect();
|
||||
}
|
||||
|
||||
template <class Derived>
|
||||
|
|
|
@ -176,7 +176,7 @@ class RemoteAccessibleBase : public Accessible, public HyperTextAccessibleBase {
|
|||
virtual double MaxValue() const override;
|
||||
virtual double Step() const override;
|
||||
|
||||
virtual nsIntRect Bounds() const override;
|
||||
virtual LayoutDeviceIntRect Bounds() const override;
|
||||
|
||||
virtual uint64_t State() override;
|
||||
|
||||
|
|
|
@ -94,12 +94,12 @@ void GetTextBeforeOffset(int32_t aOffset, AccessibleTextBoundary aBoundaryType,
|
|||
|
||||
char16_t CharAt(int32_t aOffset);
|
||||
|
||||
nsIntRect TextBounds(
|
||||
LayoutDeviceIntRect TextBounds(
|
||||
int32_t aStartOffset, int32_t aEndOffset,
|
||||
uint32_t aCoordType =
|
||||
nsIAccessibleCoordinateType::COORDTYPE_SCREEN_RELATIVE);
|
||||
|
||||
nsIntRect CharBounds(int32_t aOffset, uint32_t aCoordType);
|
||||
LayoutDeviceIntRect CharBounds(int32_t aOffset, uint32_t aCoordType);
|
||||
|
||||
int32_t OffsetAtPoint(int32_t aX, int32_t aY, uint32_t aCoordType);
|
||||
|
||||
|
@ -133,9 +133,9 @@ bool DeleteText(int32_t aStartPos, int32_t aEndPos);
|
|||
|
||||
bool PasteText(int32_t aPosition);
|
||||
|
||||
nsIntPoint ImagePosition(uint32_t aCoordType);
|
||||
LayoutDeviceIntPoint ImagePosition(uint32_t aCoordType);
|
||||
|
||||
nsIntSize ImageSize();
|
||||
LayoutDeviceIntSize ImageSize();
|
||||
|
||||
uint32_t EndOffset(bool* aOk);
|
||||
|
||||
|
@ -234,7 +234,7 @@ RemoteAccessible* FocusedChild();
|
|||
virtual Accessible* ChildAtPoint(
|
||||
int32_t aX, int32_t aY,
|
||||
LocalAccessible::EWhichChildAtPoint aWhichChild) override;
|
||||
nsIntRect Bounds() const override;
|
||||
LayoutDeviceIntRect Bounds() const override;
|
||||
nsIntRect BoundsInCSSPixels();
|
||||
|
||||
void Language(nsString& aLocale);
|
||||
|
|
|
@ -109,12 +109,12 @@ mozilla::ipc::IPCResult DocAccessiblePlatformExtChild::RecvTextForRange(
|
|||
mozilla::ipc::IPCResult DocAccessiblePlatformExtChild::RecvBoundsForRange(
|
||||
const uint64_t& aID, const int32_t& aStartOffset,
|
||||
const uint64_t& aEndContainer, const int32_t& aEndOffset,
|
||||
nsIntRect* aBounds) {
|
||||
LayoutDeviceIntRect* aBounds) {
|
||||
HyperTextAccessibleWrap* acc = IdToHyperTextAccessibleWrap(aID);
|
||||
HyperTextAccessibleWrap* endContainer =
|
||||
IdToHyperTextAccessibleWrap(aEndContainer);
|
||||
if (!acc || !endContainer) {
|
||||
*aBounds = nsIntRect();
|
||||
*aBounds = LayoutDeviceIntRect();
|
||||
return IPC_OK();
|
||||
}
|
||||
|
||||
|
|
|
@ -41,7 +41,7 @@ class DocAccessiblePlatformExtChild : public PDocAccessiblePlatformExtChild {
|
|||
const int32_t& aStartOffset,
|
||||
const uint64_t& aEndContainer,
|
||||
const int32_t& aEndOffset,
|
||||
nsIntRect* aBounds);
|
||||
LayoutDeviceIntRect* aBounds);
|
||||
|
||||
mozilla::ipc::IPCResult RecvLengthForRange(const uint64_t& aID,
|
||||
const int32_t& aStartOffset,
|
||||
|
|
|
@ -11,7 +11,7 @@ include "mozilla/GfxMessageUtils.h";
|
|||
using mozilla::a11y::EWhichRange from "mozilla/a11y/IPCTypes.h";
|
||||
using mozilla::a11y::EWhichPostFilter from "mozilla/a11y/IPCTypes.h";
|
||||
[RefCounted] using mozilla::a11y::AccAttributes from "mozilla/a11y/IPCTypes.h";
|
||||
using nsIntRect from "nsRect.h";
|
||||
using mozilla::LayoutDeviceIntRect from "Units.h";
|
||||
|
||||
namespace mozilla {
|
||||
namespace a11y {
|
||||
|
@ -43,7 +43,7 @@ child:
|
|||
returns(nsString aText);
|
||||
|
||||
[Nested=inside_sync] sync BoundsForRange(uint64_t aID, int32_t aStartOffset, uint64_t aEndContainer, int32_t aEndOffset)
|
||||
returns(nsIntRect aRetVal);
|
||||
returns(LayoutDeviceIntRect aRetVal);
|
||||
|
||||
[Nested=inside_sync] sync LengthForRange(uint64_t aID, int32_t aStartOffset, uint64_t aEndContainer, int32_t aEndOffset)
|
||||
returns(int32_t aLength);
|
||||
|
|
|
@ -419,7 +419,7 @@ mozilla::ipc::IPCResult DocAccessibleChild::RecvDefaultTextAttributes(
|
|||
|
||||
mozilla::ipc::IPCResult DocAccessibleChild::RecvTextBounds(
|
||||
const uint64_t& aID, const int32_t& aStartOffset, const int32_t& aEndOffset,
|
||||
const uint32_t& aCoordType, nsIntRect* aRetVal) {
|
||||
const uint32_t& aCoordType, LayoutDeviceIntRect* aRetVal) {
|
||||
HyperTextAccessible* acc = IdToHyperTextAccessible(aID);
|
||||
if (acc && acc->IsTextRole()) {
|
||||
*aRetVal = acc->TextBounds(aStartOffset, aEndOffset, aCoordType);
|
||||
|
@ -430,7 +430,7 @@ mozilla::ipc::IPCResult DocAccessibleChild::RecvTextBounds(
|
|||
|
||||
mozilla::ipc::IPCResult DocAccessibleChild::RecvCharBounds(
|
||||
const uint64_t& aID, const int32_t& aOffset, const uint32_t& aCoordType,
|
||||
nsIntRect* aRetVal) {
|
||||
LayoutDeviceIntRect* aRetVal) {
|
||||
HyperTextAccessible* acc = IdToHyperTextAccessible(aID);
|
||||
if (acc && acc->IsTextRole()) {
|
||||
*aRetVal = acc->CharBounds(aOffset, aCoordType);
|
||||
|
@ -606,7 +606,8 @@ mozilla::ipc::IPCResult DocAccessibleChild::RecvPasteText(
|
|||
}
|
||||
|
||||
mozilla::ipc::IPCResult DocAccessibleChild::RecvImagePosition(
|
||||
const uint64_t& aID, const uint32_t& aCoordType, nsIntPoint* aRetVal) {
|
||||
const uint64_t& aID, const uint32_t& aCoordType,
|
||||
LayoutDeviceIntPoint* aRetVal) {
|
||||
ImageAccessible* acc = IdToImageAccessible(aID);
|
||||
if (acc) {
|
||||
*aRetVal = acc->Position(aCoordType);
|
||||
|
@ -615,8 +616,8 @@ mozilla::ipc::IPCResult DocAccessibleChild::RecvImagePosition(
|
|||
return IPC_OK();
|
||||
}
|
||||
|
||||
mozilla::ipc::IPCResult DocAccessibleChild::RecvImageSize(const uint64_t& aID,
|
||||
nsIntSize* aRetVal) {
|
||||
mozilla::ipc::IPCResult DocAccessibleChild::RecvImageSize(
|
||||
const uint64_t& aID, LayoutDeviceIntSize* aRetVal) {
|
||||
ImageAccessible* acc = IdToImageAccessible(aID);
|
||||
if (acc) {
|
||||
*aRetVal = acc->Size();
|
||||
|
@ -1643,10 +1644,10 @@ mozilla::ipc::IPCResult DocAccessibleChild::RecvExtents(
|
|||
*aHeight = 0;
|
||||
LocalAccessible* acc = IdToAccessible(aID);
|
||||
if (acc && !acc->IsDefunct()) {
|
||||
nsIntRect screenRect = acc->Bounds();
|
||||
LayoutDeviceIntRect screenRect = acc->Bounds();
|
||||
if (!screenRect.IsEmpty()) {
|
||||
if (aNeedsScreenCoords) {
|
||||
nsIntPoint winCoords =
|
||||
LayoutDeviceIntPoint winCoords =
|
||||
nsCoreUtils::GetScreenCoordsForWindow(acc->GetNode());
|
||||
screenRect.x -= winCoords.x;
|
||||
screenRect.y -= winCoords.y;
|
||||
|
|
|
@ -143,16 +143,14 @@ class DocAccessibleChild : public DocAccessibleChildBase {
|
|||
virtual mozilla::ipc::IPCResult RecvDefaultTextAttributes(
|
||||
const uint64_t& aID, RefPtr<AccAttributes>* aAttributes) override;
|
||||
|
||||
virtual mozilla::ipc::IPCResult RecvTextBounds(const uint64_t& aID,
|
||||
const int32_t& aStartOffset,
|
||||
const int32_t& aEndOffset,
|
||||
const uint32_t& aCoordType,
|
||||
nsIntRect* aRetVal) override;
|
||||
virtual mozilla::ipc::IPCResult RecvTextBounds(
|
||||
const uint64_t& aID, const int32_t& aStartOffset,
|
||||
const int32_t& aEndOffset, const uint32_t& aCoordType,
|
||||
LayoutDeviceIntRect* aRetVal) override;
|
||||
|
||||
virtual mozilla::ipc::IPCResult RecvCharBounds(const uint64_t& aID,
|
||||
const int32_t& aOffset,
|
||||
const uint32_t& aCoordType,
|
||||
nsIntRect* aRetVal) override;
|
||||
virtual mozilla::ipc::IPCResult RecvCharBounds(
|
||||
const uint64_t& aID, const int32_t& aOffset, const uint32_t& aCoordType,
|
||||
LayoutDeviceIntRect* aRetVal) override;
|
||||
|
||||
virtual mozilla::ipc::IPCResult RecvOffsetAtPoint(const uint64_t& aID,
|
||||
const int32_t& aX,
|
||||
|
@ -219,10 +217,10 @@ class DocAccessibleChild : public DocAccessibleChildBase {
|
|||
|
||||
virtual mozilla::ipc::IPCResult RecvImagePosition(
|
||||
const uint64_t& aID, const uint32_t& aCoordType,
|
||||
nsIntPoint* aRetVal) override;
|
||||
LayoutDeviceIntPoint* aRetVal) override;
|
||||
|
||||
virtual mozilla::ipc::IPCResult RecvImageSize(const uint64_t& aID,
|
||||
nsIntSize* aRetVal) override;
|
||||
virtual mozilla::ipc::IPCResult RecvImageSize(
|
||||
const uint64_t& aID, LayoutDeviceIntSize* aRetVal) override;
|
||||
|
||||
virtual mozilla::ipc::IPCResult RecvStartOffset(const uint64_t& aID,
|
||||
uint32_t* aRetVal,
|
||||
|
|
|
@ -12,14 +12,14 @@ include DocAccessibleTypes;
|
|||
|
||||
include "mozilla/GfxMessageUtils.h";
|
||||
|
||||
using nsIntRect from "nsRect.h";
|
||||
using LayoutDeviceIntRect from "Units.h";
|
||||
using LayoutDeviceIntPoint from "Units.h";
|
||||
using LayoutDeviceIntSize from "Units.h";
|
||||
using mozilla::a11y::role from "mozilla/a11y/IPCTypes.h";
|
||||
using mozilla::a11y::AccType from "mozilla/a11y/IPCTypes.h";
|
||||
using mozilla::a11y::AccGenericType from "mozilla/a11y/IPCTypes.h";
|
||||
[RefCounted] using mozilla::a11y::AccAttributes from "mozilla/a11y/IPCTypes.h";
|
||||
using mozilla::a11y::CacheUpdateType from "mozilla/a11y/IPCTypes.h";
|
||||
using mozilla::gfx::IntSize from "mozilla/gfx/Point.h";
|
||||
using mozilla::gfx::IntPoint from "mozilla/gfx/Point.h";
|
||||
|
||||
namespace mozilla {
|
||||
namespace a11y {
|
||||
|
@ -44,7 +44,7 @@ struct BatchData
|
|||
OriginDocument Document;
|
||||
uint64_t ID;
|
||||
uint64_t State;
|
||||
nsIntRect Bounds;
|
||||
LayoutDeviceIntRect Bounds;
|
||||
uint8_t ActionCount;
|
||||
nsString Name;
|
||||
nsString TextValue;
|
||||
|
@ -200,9 +200,9 @@ child:
|
|||
|
||||
[Nested=inside_sync] sync TextBounds(uint64_t aID, int32_t aStartOffset, int32_t aEndOffset,
|
||||
uint32_t aCoordType)
|
||||
returns(nsIntRect aRetVal);
|
||||
returns(LayoutDeviceIntRect aRetVal);
|
||||
[Nested=inside_sync] sync CharBounds(uint64_t aID, int32_t aOffset, uint32_t aCoordType)
|
||||
returns(nsIntRect aRetVal);
|
||||
returns(LayoutDeviceIntRect aRetVal);
|
||||
|
||||
[Nested=inside_sync] sync OffsetAtPoint(uint64_t aID, int32_t aX, int32_t aY, uint32_t aCoordType)
|
||||
returns(int32_t aRetVal);
|
||||
|
@ -238,8 +238,8 @@ child:
|
|||
[Nested=inside_sync] sync PasteText(uint64_t aID, int32_t aPosition)
|
||||
returns(bool aValid);
|
||||
|
||||
[Nested=inside_sync] sync ImagePosition(uint64_t aID, uint32_t aCoordType) returns(IntPoint aRetVal);
|
||||
[Nested=inside_sync] sync ImageSize(uint64_t aID) returns(IntSize aRetVal);
|
||||
[Nested=inside_sync] sync ImagePosition(uint64_t aID, uint32_t aCoordType) returns(LayoutDeviceIntPoint aRetVal);
|
||||
[Nested=inside_sync] sync ImageSize(uint64_t aID) returns(LayoutDeviceIntSize aRetVal);
|
||||
|
||||
[Nested=inside_sync] sync StartOffset(uint64_t aID) returns(uint32_t aRetVal, bool aOk);
|
||||
[Nested=inside_sync] sync EndOffset(uint64_t aID) returns(uint32_t aRetVal, bool aOk);
|
||||
|
|
|
@ -260,16 +260,18 @@ already_AddRefed<AccAttributes> RemoteAccessible::DefaultTextAttributes() {
|
|||
return attrs.forget();
|
||||
}
|
||||
|
||||
nsIntRect RemoteAccessible::TextBounds(int32_t aStartOffset, int32_t aEndOffset,
|
||||
uint32_t aCoordType) {
|
||||
nsIntRect rect;
|
||||
LayoutDeviceIntRect RemoteAccessible::TextBounds(int32_t aStartOffset,
|
||||
int32_t aEndOffset,
|
||||
uint32_t aCoordType) {
|
||||
LayoutDeviceIntRect rect;
|
||||
Unused << mDoc->SendTextBounds(mID, aStartOffset, aEndOffset, aCoordType,
|
||||
&rect);
|
||||
return rect;
|
||||
}
|
||||
|
||||
nsIntRect RemoteAccessible::CharBounds(int32_t aOffset, uint32_t aCoordType) {
|
||||
nsIntRect rect;
|
||||
LayoutDeviceIntRect RemoteAccessible::CharBounds(int32_t aOffset,
|
||||
uint32_t aCoordType) {
|
||||
LayoutDeviceIntRect rect;
|
||||
Unused << mDoc->SendCharBounds(mID, aOffset, aCoordType, &rect);
|
||||
return rect;
|
||||
}
|
||||
|
@ -365,14 +367,14 @@ bool RemoteAccessible::PasteText(int32_t aPosition) {
|
|||
return valid;
|
||||
}
|
||||
|
||||
nsIntPoint RemoteAccessible::ImagePosition(uint32_t aCoordType) {
|
||||
nsIntPoint retVal;
|
||||
LayoutDeviceIntPoint RemoteAccessible::ImagePosition(uint32_t aCoordType) {
|
||||
LayoutDeviceIntPoint retVal;
|
||||
Unused << mDoc->SendImagePosition(mID, aCoordType, &retVal);
|
||||
return retVal;
|
||||
}
|
||||
|
||||
nsIntSize RemoteAccessible::ImageSize() {
|
||||
nsIntSize retVal;
|
||||
LayoutDeviceIntSize RemoteAccessible::ImageSize() {
|
||||
LayoutDeviceIntSize retVal;
|
||||
Unused << mDoc->SendImageSize(mID, &retVal);
|
||||
return retVal;
|
||||
}
|
||||
|
@ -872,7 +874,7 @@ Accessible* RemoteAccessible::ChildAtPoint(
|
|||
if (target->IsOuterDoc()) {
|
||||
if (target->ChildCount() == 0) {
|
||||
// Return the OuterDoc if the requested point is within its bounds.
|
||||
nsIntRect rect = target->Bounds();
|
||||
LayoutDeviceIntRect rect = target->Bounds();
|
||||
if (rect.Contains(aX, aY)) {
|
||||
return target;
|
||||
}
|
||||
|
@ -885,7 +887,7 @@ Accessible* RemoteAccessible::ChildAtPoint(
|
|||
// process, so they stop at OOP iframes.
|
||||
if (aWhichChild == Accessible::EWhichChildAtPoint::DirectChild) {
|
||||
// Return the child document if it's within the bounds of the iframe.
|
||||
nsIntRect docRect = target->Bounds();
|
||||
LayoutDeviceIntRect docRect = target->Bounds();
|
||||
if (docRect.Contains(aX, aY)) {
|
||||
return childDoc;
|
||||
}
|
||||
|
@ -908,12 +910,12 @@ Accessible* RemoteAccessible::ChildAtPoint(
|
|||
return target;
|
||||
}
|
||||
|
||||
nsIntRect RemoteAccessible::Bounds() const {
|
||||
LayoutDeviceIntRect RemoteAccessible::Bounds() const {
|
||||
if (StaticPrefs::accessibility_cache_enabled_AtStartup()) {
|
||||
return RemoteAccessibleBase<RemoteAccessible>::Bounds();
|
||||
}
|
||||
|
||||
nsIntRect rect;
|
||||
LayoutDeviceIntRect rect;
|
||||
Unused << mDoc->SendExtents(mID, false, &(rect.x), &(rect.y), &(rect.width),
|
||||
&(rect.height));
|
||||
return rect;
|
||||
|
|
|
@ -223,12 +223,12 @@ uint64_t RemoteAccessible::State() {
|
|||
return state;
|
||||
}
|
||||
|
||||
nsIntRect RemoteAccessible::Bounds() const {
|
||||
LayoutDeviceIntRect RemoteAccessible::Bounds() const {
|
||||
if (StaticPrefs::accessibility_cache_enabled_AtStartup()) {
|
||||
return RemoteAccessibleBase<RemoteAccessible>::Bounds();
|
||||
}
|
||||
|
||||
nsIntRect rect;
|
||||
LayoutDeviceIntRect rect;
|
||||
|
||||
RefPtr<IAccessible> acc;
|
||||
if (!GetCOMInterface((void**)getter_AddRefs(acc))) {
|
||||
|
|
|
@ -530,7 +530,7 @@ int32_t GeckoTextMarkerRange::Length() const {
|
|||
}
|
||||
|
||||
NSValue* GeckoTextMarkerRange::Bounds() const {
|
||||
nsIntRect rect;
|
||||
LayoutDeviceIntRect rect;
|
||||
if (mStart.mContainer->IsRemote() && mEnd.mContainer->IsRemote()) {
|
||||
DocAccessibleParent* ipcDoc = mStart.mContainer->AsRemote()->Document();
|
||||
Unused << ipcDoc->GetPlatformExtension()->SendBoundsForRange(
|
||||
|
|
|
@ -29,9 +29,9 @@ class HyperTextAccessibleWrap : public HyperTextAccessible {
|
|||
HyperTextAccessible* aEndContainer,
|
||||
int32_t aEndOffset);
|
||||
|
||||
nsIntRect BoundsForRange(int32_t aStartOffset,
|
||||
HyperTextAccessible* aEndContainer,
|
||||
int32_t aEndOffset);
|
||||
LayoutDeviceIntRect BoundsForRange(int32_t aStartOffset,
|
||||
HyperTextAccessible* aEndContainer,
|
||||
int32_t aEndOffset);
|
||||
|
||||
int32_t LengthForRange(int32_t aStartOffset,
|
||||
HyperTextAccessible* aEndContainer,
|
||||
|
|
|
@ -313,13 +313,13 @@ void HyperTextAccessibleWrap::AttributedTextForRange(
|
|||
}
|
||||
}
|
||||
|
||||
nsIntRect HyperTextAccessibleWrap::BoundsForRange(
|
||||
LayoutDeviceIntRect HyperTextAccessibleWrap::BoundsForRange(
|
||||
int32_t aStartOffset, HyperTextAccessible* aEndContainer,
|
||||
int32_t aEndOffset) {
|
||||
nsIntRect rect;
|
||||
LayoutDeviceIntRect rect;
|
||||
HyperTextIterator iter(this, aStartOffset, aEndContainer, aEndOffset);
|
||||
while (iter.Next()) {
|
||||
nsIntRect stringRect = iter.mCurrentContainer->TextBounds(
|
||||
LayoutDeviceIntRect stringRect = iter.mCurrentContainer->TextBounds(
|
||||
iter.mCurrentStartOffset, iter.mCurrentEndOffset);
|
||||
rect.UnionRect(rect, stringRect);
|
||||
}
|
||||
|
|
|
@ -689,9 +689,9 @@ struct RoleDescrComparator {
|
|||
- (NSValue*)moxFrame {
|
||||
MOZ_ASSERT(mGeckoAccessible);
|
||||
|
||||
nsIntRect rect = mGeckoAccessible->IsLocal()
|
||||
? mGeckoAccessible->AsLocal()->Bounds()
|
||||
: mGeckoAccessible->AsRemote()->Bounds();
|
||||
LayoutDeviceIntRect rect = mGeckoAccessible->IsLocal()
|
||||
? mGeckoAccessible->AsLocal()->Bounds()
|
||||
: mGeckoAccessible->AsRemote()->Bounds();
|
||||
NSScreen* mainView = [[NSScreen screens] objectAtIndex:0];
|
||||
CGFloat scaleFactor = nsCocoaUtils::GetBackingScaleFactor(mainView);
|
||||
|
||||
|
@ -906,12 +906,11 @@ struct RoleDescrComparator {
|
|||
- (void)moxPerformShowMenu {
|
||||
MOZ_ASSERT(mGeckoAccessible);
|
||||
|
||||
nsIntRect bounds = mGeckoAccessible->IsLocal()
|
||||
? mGeckoAccessible->AsLocal()->Bounds()
|
||||
: mGeckoAccessible->AsRemote()->Bounds();
|
||||
// We don't need to convert this rect into mac coordinates because the
|
||||
// mouse event synthesizer expects layout (gecko) coordinates.
|
||||
LayoutDeviceIntRect geckoRect = LayoutDeviceIntRect::FromUnknownRect(bounds);
|
||||
LayoutDeviceIntRect bounds = mGeckoAccessible->IsLocal()
|
||||
? mGeckoAccessible->AsLocal()->Bounds()
|
||||
: mGeckoAccessible->AsRemote()->Bounds();
|
||||
|
||||
LocalAccessible* rootAcc = mGeckoAccessible->IsLocal()
|
||||
? mGeckoAccessible->AsLocal()->RootAccessible()
|
||||
|
@ -921,9 +920,8 @@ struct RoleDescrComparator {
|
|||
id objOrView =
|
||||
GetObjectOrRepresentedView(GetNativeFromGeckoAccessible(rootAcc));
|
||||
|
||||
LayoutDeviceIntPoint p =
|
||||
LayoutDeviceIntPoint(geckoRect.X() + (geckoRect.Width() / 2),
|
||||
geckoRect.Y() + (geckoRect.Height() / 2));
|
||||
LayoutDeviceIntPoint p = LayoutDeviceIntPoint(
|
||||
bounds.X() + (bounds.Width() / 2), bounds.Y() + (bounds.Height() / 2));
|
||||
nsIWidget* widget = [objOrView widget];
|
||||
widget->SynthesizeNativeMouseEvent(
|
||||
p, nsIWidget::NativeMouseMessage::ButtonDown, MouseButton::eSecondary,
|
||||
|
|
|
@ -11,6 +11,11 @@ loadScripts(
|
|||
{ name: "states.js", dir: MOCHITESTS_DIR }
|
||||
);
|
||||
|
||||
const isCacheEnabled = Services.prefs.getBoolPref(
|
||||
"accessibility.cache.enabled",
|
||||
false
|
||||
);
|
||||
|
||||
/**
|
||||
* Test moving Accessibles:
|
||||
* 1. A moved Accessible keeps the same Accessible.
|
||||
|
@ -53,5 +58,11 @@ addAccessibleTask(
|
|||
// was moved. Ensure it is dead.
|
||||
ok(isDefunct(heading), "heading is dead");
|
||||
},
|
||||
{ chrome: true, topLevel: true, iframe: true, remoteIframe: true }
|
||||
{
|
||||
chrome: true,
|
||||
// Moves cause RemoteAccessible re-creation without the cache enabled.
|
||||
topLevel: isCacheEnabled,
|
||||
iframe: isCacheEnabled,
|
||||
remoteIframe: isCacheEnabled,
|
||||
}
|
||||
);
|
||||
|
|
|
@ -54,7 +54,7 @@ ia2AccessibleComponent::get_locationInParent(long* aX, long* aY) {
|
|||
uint64_t state = acc->State();
|
||||
if (state & states::INVISIBLE) return S_OK;
|
||||
|
||||
nsIntRect rect = acc->Bounds();
|
||||
LayoutDeviceIntRect rect = acc->Bounds();
|
||||
|
||||
// The coordinates of the returned position are relative to this object's
|
||||
// parent or relative to the screen on which this object is rendered if it
|
||||
|
@ -67,7 +67,7 @@ ia2AccessibleComponent::get_locationInParent(long* aX, long* aY) {
|
|||
|
||||
// The coordinates of the bounding box are given relative to the parent's
|
||||
// coordinate system.
|
||||
nsIntRect parentRect = acc->LocalParent()->Bounds();
|
||||
LayoutDeviceIntRect parentRect = acc->LocalParent()->Bounds();
|
||||
*aX = rect.X() - parentRect.X();
|
||||
*aY = rect.Y() - parentRect.Y();
|
||||
return S_OK;
|
||||
|
|
|
@ -63,7 +63,7 @@ ia2AccessibleImage::get_imagePosition(enum IA2CoordinateType aCoordType,
|
|||
? nsIAccessibleCoordinateType::COORDTYPE_SCREEN_RELATIVE
|
||||
: nsIAccessibleCoordinateType::COORDTYPE_PARENT_RELATIVE;
|
||||
|
||||
nsIntPoint pos = imageAcc->Position(geckoCoordType);
|
||||
LayoutDeviceIntPoint pos = imageAcc->Position(geckoCoordType);
|
||||
*aX = pos.x;
|
||||
*aY = pos.y;
|
||||
return S_OK;
|
||||
|
@ -79,7 +79,7 @@ ia2AccessibleImage::get_imageSize(long* aHeight, long* aWidth) {
|
|||
ImageAccessible* imageAcc = ImageAcc();
|
||||
if (!imageAcc) return CO_E_OBJNOTCONNECTED;
|
||||
|
||||
nsIntSize size = imageAcc->Size();
|
||||
LayoutDeviceIntSize size = imageAcc->Size();
|
||||
*aHeight = size.width;
|
||||
*aWidth = size.height;
|
||||
return S_OK;
|
||||
|
|
|
@ -111,7 +111,7 @@ ia2AccessibleText::get_characterExtents(long aOffset,
|
|||
(aCoordType == IA2_COORDTYPE_SCREEN_RELATIVE)
|
||||
? nsIAccessibleCoordinateType::COORDTYPE_SCREEN_RELATIVE
|
||||
: nsIAccessibleCoordinateType::COORDTYPE_PARENT_RELATIVE;
|
||||
nsIntRect rect;
|
||||
LayoutDeviceIntRect rect;
|
||||
auto [textAcc, hr] = LocalTextAcc();
|
||||
if (!textAcc) {
|
||||
return hr;
|
||||
|
|
|
@ -77,10 +77,10 @@ void DocAccessibleWrap::DoInitialUpdate() {
|
|||
MOZ_ASSERT(XRE_IsParentProcess());
|
||||
a11y::RootAccessible* rootDocument = RootAccessible();
|
||||
bool isActive = true;
|
||||
nsIntRect rect(CW_USEDEFAULT, CW_USEDEFAULT, 0, 0);
|
||||
LayoutDeviceIntRect rect(CW_USEDEFAULT, CW_USEDEFAULT, 0, 0);
|
||||
if (Compatibility::IsDolphin()) {
|
||||
rect = Bounds();
|
||||
nsIntRect rootRect = rootDocument->Bounds();
|
||||
LayoutDeviceIntRect rootRect = rootDocument->Bounds();
|
||||
rect.MoveToX(rootRect.X() - rect.X());
|
||||
rect.MoveByY(-rootRect.Y());
|
||||
|
||||
|
|
|
@ -332,6 +332,28 @@ AccessibleWrap* MsaaAccessible::LocalAcc() {
|
|||
return acc;
|
||||
}
|
||||
|
||||
/**
|
||||
* If this is an OOP iframe in a content process, return the COM proxy for the
|
||||
* child document.
|
||||
* This will only ever return something when the cache is disabled. When the
|
||||
* cache is enabled, traversing to OOP iframe documents is handled in the
|
||||
* parent process via the RemoteAccessible hierarchy.
|
||||
*/
|
||||
static already_AddRefed<IDispatch> MaybeGetOOPIframeDocCOMProxy(
|
||||
Accessible* aAcc) {
|
||||
if (!XRE_IsContentProcess() || !aAcc->IsOuterDoc()) {
|
||||
return nullptr;
|
||||
}
|
||||
MOZ_ASSERT(!StaticPrefs::accessibility_cache_enabled_AtStartup());
|
||||
LocalAccessible* outerDoc = aAcc->AsLocal();
|
||||
auto bridge = dom::BrowserBridgeChild::GetFrom(outerDoc->GetContent());
|
||||
if (!bridge) {
|
||||
// This isn't an OOP iframe.
|
||||
return nullptr;
|
||||
}
|
||||
return bridge->GetEmbeddedDocAccessible();
|
||||
}
|
||||
|
||||
/**
|
||||
* This function is a helper for implementing IAccessible methods that accept
|
||||
* a Child ID as a parameter. If the child ID is CHILDID_SELF, the function
|
||||
|
@ -374,6 +396,11 @@ MsaaAccessible::ResolveChild(const VARIANT& aVarChild,
|
|||
return S_OK;
|
||||
}
|
||||
|
||||
if (aVarChild.lVal == 1 && RefPtr{MaybeGetOOPIframeDocCOMProxy(mAcc)}) {
|
||||
// We can't access an OOP iframe document.
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
bool isDefunct = false;
|
||||
RefPtr<IAccessible> accessible = GetIAccessibleFor(aVarChild, &isDefunct);
|
||||
if (!accessible) {
|
||||
|
@ -462,28 +489,6 @@ static already_AddRefed<IDispatch> GetProxiedAccessibleInSubtree(
|
|||
return disp.forget();
|
||||
}
|
||||
|
||||
/**
|
||||
* If this is an OOP iframe in a content process, return the COM proxy for the
|
||||
* child document.
|
||||
* This will only ever return something when the cache is disabled. When the
|
||||
* cache is enabled, traversing to OOP iframe documents is handled in the
|
||||
* parent process via the RemoteAccessible hierarchy.
|
||||
*/
|
||||
static already_AddRefed<IDispatch> MaybeGetOOPIframeDocCOMProxy(
|
||||
Accessible* aAcc) {
|
||||
if (!XRE_IsContentProcess() || !aAcc->IsOuterDoc()) {
|
||||
return nullptr;
|
||||
}
|
||||
MOZ_ASSERT(!StaticPrefs::accessibility_cache_enabled_AtStartup());
|
||||
LocalAccessible* outerDoc = aAcc->AsLocal();
|
||||
auto bridge = dom::BrowserBridgeChild::GetFrom(outerDoc->GetContent());
|
||||
if (!bridge) {
|
||||
// This isn't an OOP iframe.
|
||||
return nullptr;
|
||||
}
|
||||
return bridge->GetEmbeddedDocAccessible();
|
||||
}
|
||||
|
||||
already_AddRefed<IAccessible> MsaaAccessible::GetIAccessibleFor(
|
||||
const VARIANT& aVarChild, bool* aIsDefunct) {
|
||||
if (aVarChild.vt != VT_I4) return nullptr;
|
||||
|
@ -1523,7 +1528,7 @@ MsaaAccessible::accLocation(
|
|||
kVarChildIdSelf);
|
||||
}
|
||||
|
||||
nsIntRect rect = Acc()->Bounds();
|
||||
LayoutDeviceIntRect rect = Acc()->Bounds();
|
||||
*pxLeft = rect.X();
|
||||
*pyTop = rect.Y();
|
||||
*pcxWidth = rect.Width();
|
||||
|
@ -1654,7 +1659,7 @@ MsaaAccessible::accHitTest(
|
|||
// This is an OOP iframe. ChildAtPoint can't traverse inside it. If the
|
||||
// coordinates are inside this iframe, return the COM proxy for the
|
||||
// OOP document.
|
||||
nsIntRect docRect = mAcc->AsLocal()->Bounds();
|
||||
LayoutDeviceIntRect docRect = mAcc->AsLocal()->Bounds();
|
||||
if (docRect.Contains(xLeft, yTop)) {
|
||||
pvarChild->vt = VT_DISPATCH;
|
||||
disp.forget(&pvarChild->pdispVal);
|
||||
|
|
|
@ -61,10 +61,10 @@ sdnTextAccessible::get_clippedSubstringBounds(
|
|||
document,
|
||||
"There must always be a doc accessible, but there isn't. Crash!");
|
||||
|
||||
nsIntRect docRect = document->Bounds();
|
||||
nsIntRect unclippedRect(x, y, width, height);
|
||||
LayoutDeviceIntRect docRect = document->Bounds();
|
||||
LayoutDeviceIntRect unclippedRect(x, y, width, height);
|
||||
|
||||
nsIntRect clippedRect;
|
||||
LayoutDeviceIntRect clippedRect;
|
||||
clippedRect.IntersectRect(unclippedRect, docRect);
|
||||
|
||||
*aX = clippedRect.X();
|
||||
|
|
|
@ -408,7 +408,7 @@ xpcAccessible::GetBounds(int32_t* aX, int32_t* aY, int32_t* aWidth,
|
|||
|
||||
if (!IntlGeneric()) return NS_ERROR_FAILURE;
|
||||
|
||||
nsIntRect rect;
|
||||
LayoutDeviceIntRect rect;
|
||||
if (LocalAccessible* acc = IntlGeneric()->AsLocal()) {
|
||||
rect = acc->Bounds();
|
||||
} else {
|
||||
|
|
|
@ -231,7 +231,7 @@ xpcAccessibleHyperText::GetCharacterExtents(int32_t aOffset, int32_t* aX,
|
|||
|
||||
if (!mIntl) return NS_ERROR_FAILURE;
|
||||
|
||||
nsIntRect rect;
|
||||
LayoutDeviceIntRect rect;
|
||||
if (mIntl->IsLocal()) {
|
||||
rect = IntlLocal()->CharBounds(aOffset, aCoordType);
|
||||
} else {
|
||||
|
@ -258,7 +258,7 @@ xpcAccessibleHyperText::GetRangeExtents(int32_t aStartOffset,
|
|||
|
||||
if (!mIntl) return NS_ERROR_FAILURE;
|
||||
|
||||
nsIntRect rect;
|
||||
LayoutDeviceIntRect rect;
|
||||
if (mIntl->IsLocal()) {
|
||||
rect = IntlLocal()->TextBounds(aStartOffset, aEndOffset, aCoordType);
|
||||
} else {
|
||||
|
|
|
@ -29,7 +29,7 @@ xpcAccessibleImage::GetImagePosition(uint32_t aCoordType, int32_t* aX,
|
|||
|
||||
if (!Intl()) return NS_ERROR_FAILURE;
|
||||
|
||||
nsIntPoint point = Intl()->Position(aCoordType);
|
||||
LayoutDeviceIntPoint point = Intl()->Position(aCoordType);
|
||||
*aX = point.x;
|
||||
*aY = point.y;
|
||||
return NS_OK;
|
||||
|
@ -44,7 +44,7 @@ xpcAccessibleImage::GetImageSize(int32_t* aWidth, int32_t* aHeight) {
|
|||
|
||||
if (!Intl()) return NS_ERROR_FAILURE;
|
||||
|
||||
nsIntSize size = Intl()->Size();
|
||||
LayoutDeviceIntSize size = Intl()->Size();
|
||||
*aWidth = size.width;
|
||||
*aHeight = size.height;
|
||||
return NS_OK;
|
||||
|
|
1
aclocal.m4
vendored
1
aclocal.m4
vendored
|
@ -3,7 +3,6 @@ dnl Local autoconf macros used with mozilla
|
|||
dnl The contents of this file are under the Public Domain.
|
||||
dnl
|
||||
|
||||
builtin(include, build/autoconf/hotfixes.m4)dnl
|
||||
builtin(include, build/autoconf/hooks.m4)dnl
|
||||
builtin(include, build/autoconf/config.status.m4)dnl
|
||||
builtin(include, build/autoconf/toolchain.m4)dnl
|
||||
|
|
|
@ -2123,6 +2123,12 @@ pref("app.normandy.onsync_skew_sec", 600);
|
|||
// AMO only serves language packs for release and beta versions.
|
||||
pref("intl.multilingual.downloadEnabled", false);
|
||||
#endif
|
||||
// With the preference enabled below, switching the browser language will do a live
|
||||
// reload rather than requiring a restart. Enable bidirectional below as well to allow
|
||||
// live reloading when switching between LTR and RTL languages.
|
||||
pref("intl.multilingual.liveReload", false);
|
||||
pref("intl.multilingual.liveReloadBidirectional", false);
|
||||
|
||||
|
||||
// Simulate conditions that will happen when the browser
|
||||
// is running with Fission enabled. This is meant to assist
|
||||
|
|
|
@ -2,9 +2,9 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
|
||||
* You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
/* import-globals-from ../../../../toolkit/content/globalOverlay.js */
|
||||
/* import-globals-from ../../../../toolkit/content/contentAreaUtils.js */
|
||||
/* import-globals-from ../../../../toolkit/content/treeUtils.js */
|
||||
/* import-globals-from /toolkit/content/globalOverlay.js */
|
||||
/* import-globals-from /toolkit/content/contentAreaUtils.js */
|
||||
/* import-globals-from /toolkit/content/treeUtils.js */
|
||||
/* import-globals-from ../utilityOverlay.js */
|
||||
/* import-globals-from permissions.js */
|
||||
/* import-globals-from security.js */
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
/* import-globals-from ../../../toolkit/content/preferencesBindings.js */
|
||||
/* import-globals-from /toolkit/content/preferencesBindings.js */
|
||||
|
||||
var { Sanitizer } = ChromeUtils.import("resource:///modules/Sanitizer.jsm");
|
||||
var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
|
||||
|
|
|
@ -10,7 +10,6 @@ skip-if = debug && os == 'mac' # Bug 1568570
|
|||
support-files = fullscreen.html fullscreen_frame.html
|
||||
[browser_bug1620341.js]
|
||||
support-files = fullscreen.html fullscreen_frame.html
|
||||
skip-if = win10_2004 # Bug 1727168 and Bug 1723574
|
||||
[browser_fullscreen_enterInUrlbar.js]
|
||||
skip-if = (os == 'mac') || (os == 'linux') #Bug 1648649
|
||||
[browser_fullscreen_window_open.js]
|
||||
|
|
|
@ -158,6 +158,12 @@ var DownloadsCommon = {
|
|||
ATTENTION_WARNING: "warning",
|
||||
ATTENTION_SEVERE: "severe",
|
||||
|
||||
// Bit flags for the attentionSuppressed property.
|
||||
SUPPRESS_NONE: 0,
|
||||
SUPPRESS_PANEL_OPEN: 1,
|
||||
SUPPRESS_ALL_DOWNLOADS_OPEN: 2,
|
||||
SUPPRESS_CONTENT_AREA_DOWNLOADS_OPEN: 4,
|
||||
|
||||
/**
|
||||
* Returns an object whose keys are the string names from the downloads string
|
||||
* bundle, and whose values are either the translated strings or functions
|
||||
|
@ -792,7 +798,7 @@ function DownloadsDataCtor({ isPrivate, isHistory, maxHistoryResults } = {}) {
|
|||
this._isPrivate = !!isPrivate;
|
||||
|
||||
// Contains all the available Download objects and their integer state.
|
||||
this.oldDownloadStates = new Map();
|
||||
this._oldDownloadStates = new WeakMap();
|
||||
|
||||
// For the history downloads list we don't need to register this as a view,
|
||||
// but we have to ensure that the DownloadsData object is initialized before
|
||||
|
@ -844,15 +850,15 @@ DownloadsDataCtor.prototype = {
|
|||
* Iterator for all the available Download objects. This is empty until the
|
||||
* data has been loaded using the JavaScript API for downloads.
|
||||
*/
|
||||
get downloads() {
|
||||
return this.oldDownloadStates.keys();
|
||||
get _downloads() {
|
||||
return ChromeUtils.nondeterministicGetWeakMapKeys(this._oldDownloadStates);
|
||||
},
|
||||
|
||||
/**
|
||||
* True if there are finished downloads that can be removed from the list.
|
||||
*/
|
||||
get canRemoveFinished() {
|
||||
for (let download of this.downloads) {
|
||||
for (let download of this._downloads) {
|
||||
// Stopped, paused, and failed downloads with partial data are removed.
|
||||
if (download.stopped && !(download.canceled && download.hasPartialData)) {
|
||||
return true;
|
||||
|
@ -869,10 +875,6 @@ DownloadsDataCtor.prototype = {
|
|||
Downloads.getList(this._isPrivate ? Downloads.PRIVATE : Downloads.PUBLIC)
|
||||
.then(list => list.removeFinished())
|
||||
.catch(Cu.reportError);
|
||||
let indicatorData = this._isPrivate
|
||||
? PrivateDownloadsIndicatorData
|
||||
: DownloadsIndicatorData;
|
||||
indicatorData.attention = DownloadsCommon.ATTENTION_NONE;
|
||||
},
|
||||
|
||||
// Integration with the asynchronous Downloads back-end
|
||||
|
@ -884,7 +886,7 @@ DownloadsDataCtor.prototype = {
|
|||
// for which the end time is stored differently, as a Places annotation.
|
||||
download.endTime = Date.now();
|
||||
|
||||
this.oldDownloadStates.set(
|
||||
this._oldDownloadStates.set(
|
||||
download,
|
||||
DownloadsCommon.stateOfDownload(download)
|
||||
);
|
||||
|
@ -894,9 +896,9 @@ DownloadsDataCtor.prototype = {
|
|||
},
|
||||
|
||||
onDownloadChanged(download) {
|
||||
let oldState = this.oldDownloadStates.get(download);
|
||||
let oldState = this._oldDownloadStates.get(download);
|
||||
let newState = DownloadsCommon.stateOfDownload(download);
|
||||
this.oldDownloadStates.set(download, newState);
|
||||
this._oldDownloadStates.set(download, newState);
|
||||
|
||||
if (oldState != newState) {
|
||||
if (
|
||||
|
@ -927,7 +929,7 @@ DownloadsDataCtor.prototype = {
|
|||
},
|
||||
|
||||
onDownloadRemoved(download) {
|
||||
this.oldDownloadStates.delete(download);
|
||||
this._oldDownloadStates.delete(download);
|
||||
},
|
||||
|
||||
// Registration of views
|
||||
|
@ -999,7 +1001,7 @@ DownloadsDataCtor.prototype = {
|
|||
Services.prefs.getBoolPref(
|
||||
"browser.download.improvements_to_download_panel"
|
||||
) &&
|
||||
DownloadsCommon.summarizeDownloads(this.downloads).numDownloading <= 1 &&
|
||||
DownloadsCommon.summarizeDownloads(this._downloads).numDownloading <= 1 &&
|
||||
gAlwaysOpenPanel;
|
||||
|
||||
if (
|
||||
|
@ -1219,7 +1221,7 @@ const DownloadsViewPrototype = {
|
|||
* @note Subclasses should override this.
|
||||
*/
|
||||
onDownloadRemoved(download) {
|
||||
throw Components.Exception("", Cr.NS_ERROR_NOT_IMPLEMENTED);
|
||||
this._oldDownloadStates.delete(download);
|
||||
},
|
||||
|
||||
/**
|
||||
|
@ -1275,6 +1277,27 @@ function DownloadsIndicatorDataCtor(aPrivate) {
|
|||
DownloadsIndicatorDataCtor.prototype = {
|
||||
__proto__: DownloadsViewPrototype,
|
||||
|
||||
/**
|
||||
* Map of the relative severities of different attention states.
|
||||
* Used in sorting the map of active downloads' attention states
|
||||
* to determine the attention state to be displayed.
|
||||
*/
|
||||
_attentionPriority: new Map([
|
||||
[DownloadsCommon.ATTENTION_NONE, 0],
|
||||
[DownloadsCommon.ATTENTION_SUCCESS, 1],
|
||||
[DownloadsCommon.ATTENTION_INFO, 2],
|
||||
[DownloadsCommon.ATTENTION_WARNING, 3],
|
||||
[DownloadsCommon.ATTENTION_SEVERE, 4],
|
||||
]),
|
||||
|
||||
/**
|
||||
* Iterator for all the available Download objects. This is empty until the
|
||||
* data has been loaded using the JavaScript API for downloads.
|
||||
*/
|
||||
get _downloads() {
|
||||
return ChromeUtils.nondeterministicGetWeakMapKeys(this._oldDownloadStates);
|
||||
},
|
||||
|
||||
/**
|
||||
* Removes an object previously added using addView.
|
||||
*
|
||||
|
@ -1296,6 +1319,10 @@ DownloadsIndicatorDataCtor.prototype = {
|
|||
},
|
||||
|
||||
onDownloadStateChanged(download) {
|
||||
if (this._attentionSuppressed !== DownloadsCommon.SUPPRESS_NONE) {
|
||||
return;
|
||||
}
|
||||
let attention;
|
||||
if (
|
||||
!download.succeeded &&
|
||||
download.error &&
|
||||
|
@ -1303,46 +1330,30 @@ DownloadsIndicatorDataCtor.prototype = {
|
|||
) {
|
||||
switch (download.error.reputationCheckVerdict) {
|
||||
case Downloads.Error.BLOCK_VERDICT_UNCOMMON:
|
||||
// Existing higher level attention indication trumps ATTENTION_INFO.
|
||||
if (
|
||||
this._attention != DownloadsCommon.ATTENTION_SEVERE &&
|
||||
this._attention != DownloadsCommon.ATTENTION_WARNING
|
||||
) {
|
||||
this.attention = DownloadsCommon.ATTENTION_INFO;
|
||||
}
|
||||
attention = DownloadsCommon.ATTENTION_INFO;
|
||||
break;
|
||||
case Downloads.Error.BLOCK_VERDICT_POTENTIALLY_UNWANTED: // fall-through
|
||||
case Downloads.Error.BLOCK_VERDICT_INSECURE:
|
||||
case Downloads.Error.BLOCK_VERDICT_DOWNLOAD_SPAM:
|
||||
// Existing higher level attention indication trumps ATTENTION_WARNING.
|
||||
if (this._attention != DownloadsCommon.ATTENTION_SEVERE) {
|
||||
this.attention = DownloadsCommon.ATTENTION_WARNING;
|
||||
}
|
||||
attention = DownloadsCommon.ATTENTION_WARNING;
|
||||
break;
|
||||
case Downloads.Error.BLOCK_VERDICT_MALWARE:
|
||||
this.attention = DownloadsCommon.ATTENTION_SEVERE;
|
||||
attention = DownloadsCommon.ATTENTION_SEVERE;
|
||||
break;
|
||||
default:
|
||||
this.attention = DownloadsCommon.ATTENTION_SEVERE;
|
||||
attention = DownloadsCommon.ATTENTION_SEVERE;
|
||||
Cu.reportError(
|
||||
"Unknown reputation verdict: " +
|
||||
download.error.reputationCheckVerdict
|
||||
);
|
||||
}
|
||||
} else if (download.succeeded) {
|
||||
// Existing higher level attention indication trumps ATTENTION_SUCCESS.
|
||||
if (
|
||||
this._attention != DownloadsCommon.ATTENTION_SEVERE &&
|
||||
this._attention != DownloadsCommon.ATTENTION_WARNING
|
||||
) {
|
||||
this.attention = DownloadsCommon.ATTENTION_SUCCESS;
|
||||
}
|
||||
attention = DownloadsCommon.ATTENTION_SUCCESS;
|
||||
} else if (download.error) {
|
||||
// Existing higher level attention indication trumps ATTENTION_WARNING.
|
||||
if (this._attention != DownloadsCommon.ATTENTION_SEVERE) {
|
||||
this.attention = DownloadsCommon.ATTENTION_WARNING;
|
||||
}
|
||||
attention = DownloadsCommon.ATTENTION_WARNING;
|
||||
}
|
||||
download.attention = attention;
|
||||
this.updateAttention();
|
||||
},
|
||||
|
||||
onDownloadChanged(download) {
|
||||
|
@ -1351,7 +1362,9 @@ DownloadsIndicatorDataCtor.prototype = {
|
|||
},
|
||||
|
||||
onDownloadRemoved(download) {
|
||||
DownloadsViewPrototype.onDownloadRemoved.call(this, download);
|
||||
this._itemCount--;
|
||||
this.updateAttention();
|
||||
this._updateViews();
|
||||
},
|
||||
|
||||
|
@ -1375,12 +1388,37 @@ DownloadsIndicatorDataCtor.prototype = {
|
|||
* Indicates whether the user is interacting with downloads, thus the
|
||||
* attention indication should not be shown even if requested.
|
||||
*/
|
||||
set attentionSuppressed(aValue) {
|
||||
this._attentionSuppressed = aValue;
|
||||
this._attention = DownloadsCommon.ATTENTION_NONE;
|
||||
this._updateViews();
|
||||
set attentionSuppressed(aFlags) {
|
||||
this._attentionSuppressed = aFlags;
|
||||
if (aFlags !== DownloadsCommon.SUPPRESS_NONE) {
|
||||
for (let download of this._downloads) {
|
||||
download.attention = DownloadsCommon.ATTENTION_NONE;
|
||||
}
|
||||
this.attention = DownloadsCommon.ATTENTION_NONE;
|
||||
}
|
||||
},
|
||||
get attentionSuppressed() {
|
||||
return this._attentionSuppressed;
|
||||
},
|
||||
_attentionSuppressed: DownloadsCommon.SUPPRESS_NONE,
|
||||
|
||||
/**
|
||||
* Set the indicator's attention to the most severe attention state among the
|
||||
* unseen displayed downloads, or DownloadsCommon.ATTENTION_NONE if empty.
|
||||
*/
|
||||
updateAttention() {
|
||||
let currentAttention = DownloadsCommon.ATTENTION_NONE;
|
||||
let currentPriority = 0;
|
||||
for (let download of this._downloads) {
|
||||
let { attention } = download;
|
||||
let priority = this._attentionPriority.get(attention);
|
||||
if (priority > currentPriority) {
|
||||
currentPriority = priority;
|
||||
currentAttention = attention;
|
||||
}
|
||||
}
|
||||
this.attention = currentAttention;
|
||||
},
|
||||
_attentionSuppressed: false,
|
||||
|
||||
/**
|
||||
* Updates the specified view with the current aggregate values.
|
||||
|
@ -1391,9 +1429,10 @@ DownloadsIndicatorDataCtor.prototype = {
|
|||
_updateView(aView) {
|
||||
aView.hasDownloads = this._hasDownloads;
|
||||
aView.percentComplete = this._percentComplete;
|
||||
aView.attention = this._attentionSuppressed
|
||||
? DownloadsCommon.ATTENTION_NONE
|
||||
: this._attention;
|
||||
aView.attention =
|
||||
this.attentionSuppressed !== DownloadsCommon.SUPPRESS_NONE
|
||||
? DownloadsCommon.ATTENTION_NONE
|
||||
: this._attention;
|
||||
},
|
||||
|
||||
// Property updating based on current download status
|
||||
|
@ -1411,8 +1450,8 @@ DownloadsIndicatorDataCtor.prototype = {
|
|||
*/
|
||||
*_activeDownloads() {
|
||||
let downloads = this._isPrivate
|
||||
? PrivateDownloadsData.downloads
|
||||
: DownloadsData.downloads;
|
||||
? PrivateDownloadsData._downloads
|
||||
: DownloadsData._downloads;
|
||||
for (let download of downloads) {
|
||||
if (!download.stopped || (download.canceled && download.hasPartialData)) {
|
||||
yield download;
|
||||
|
@ -1535,6 +1574,7 @@ DownloadsSummaryData.prototype = {
|
|||
},
|
||||
|
||||
onDownloadRemoved(download) {
|
||||
DownloadsViewPrototype.onDownloadRemoved.call(this, download);
|
||||
let itemIndex = this._downloads.indexOf(download);
|
||||
this._downloads.splice(itemIndex, 1);
|
||||
this._updateViews();
|
||||
|
|
|
@ -172,6 +172,8 @@ var DownloadsViewUI = {
|
|||
// Get the state and ensure only the appropriate items are displayed.
|
||||
let state = parseInt(element.getAttribute("state"), 10);
|
||||
|
||||
const document = contextMenu.ownerDocument;
|
||||
|
||||
const {
|
||||
DOWNLOAD_NOTSTARTED,
|
||||
DOWNLOAD_DOWNLOADING,
|
||||
|
@ -223,13 +225,22 @@ var DownloadsViewUI = {
|
|||
|
||||
let download = element._shell.download;
|
||||
let mimeInfo = DownloadsCommon.getMimeInfo(download);
|
||||
let { preferredAction, useSystemDefault } = mimeInfo ? mimeInfo : {};
|
||||
let { preferredAction, useSystemDefault, defaultDescription } = mimeInfo
|
||||
? mimeInfo
|
||||
: {};
|
||||
|
||||
// Hide the "Delete" item if there's no file data to delete.
|
||||
contextMenu.querySelector(".downloadDeleteFileMenuItem").hidden = !(
|
||||
download.target?.exists || download.target?.partFileExists
|
||||
);
|
||||
|
||||
// Hide the "Go To Download Page" item if there's no referrer. Ideally the
|
||||
// Downloads API will require a referrer (see bug 1723712) to create a
|
||||
// download, but this fallback will ensure any failures aren't user facing.
|
||||
contextMenu.querySelector(
|
||||
".downloadOpenReferrerMenuItem"
|
||||
).hidden = !download.source.referrerInfo?.originalReferrer;
|
||||
|
||||
// Hide the "use system viewer" and "always use system viewer" items
|
||||
// if the feature is disabled or this download doesn't support it:
|
||||
let useSystemViewerItem = contextMenu.querySelector(
|
||||
|
@ -248,6 +259,45 @@ var DownloadsViewUI = {
|
|||
!DownloadsCommon.alwaysOpenInSystemViewerItemEnabled ||
|
||||
!canViewInternally;
|
||||
|
||||
// Set menuitem labels to display the system viewer's name. Stop the l10n
|
||||
// mutation observer temporarily since we're going to synchronously
|
||||
// translate the elements to avoid translation delay. See bug 1737951 & bug
|
||||
// 1746748. This can be simplified when they're resolved.
|
||||
try {
|
||||
document.l10n.pauseObserving();
|
||||
// Handler descriptions longer than 40 characters will be skipped to avoid
|
||||
// unreasonably stretching the context menu.
|
||||
if (defaultDescription && defaultDescription.length < 40) {
|
||||
document.l10n.setAttributes(
|
||||
useSystemViewerItem,
|
||||
"downloads-cmd-use-system-default-named",
|
||||
{ handler: defaultDescription }
|
||||
);
|
||||
document.l10n.setAttributes(
|
||||
alwaysUseSystemViewerItem,
|
||||
"downloads-cmd-always-use-system-default-named",
|
||||
{ handler: defaultDescription }
|
||||
);
|
||||
} else {
|
||||
// In the unlikely event that defaultDescription is somehow missing/invalid,
|
||||
// fall back to the static "Open In System Viewer" label.
|
||||
document.l10n.setAttributes(
|
||||
useSystemViewerItem,
|
||||
"downloads-cmd-use-system-default"
|
||||
);
|
||||
document.l10n.setAttributes(
|
||||
alwaysUseSystemViewerItem,
|
||||
"downloads-cmd-always-use-system-default"
|
||||
);
|
||||
}
|
||||
} finally {
|
||||
document.l10n.resumeObserving();
|
||||
}
|
||||
document.l10n.translateElements([
|
||||
useSystemViewerItem,
|
||||
alwaysUseSystemViewerItem,
|
||||
]);
|
||||
|
||||
// If non default mime-type or cannot be opened internally, display
|
||||
// "always open similar files" item instead so that users can add a new
|
||||
// mimetype to about:preferences table and set to open with system default.
|
||||
|
|
|
@ -208,7 +208,11 @@ var DownloadsView = {
|
|||
* as they exist they "collapses" their history "counterpart" (So we don't show two
|
||||
* items for every download).
|
||||
*/
|
||||
function DownloadsPlacesView(aRichListBox, aActive = true) {
|
||||
function DownloadsPlacesView(
|
||||
aRichListBox,
|
||||
aActive = true,
|
||||
aSuppressionFlag = DownloadsCommon.SUPPRESS_ALL_DOWNLOADS_OPEN
|
||||
) {
|
||||
this._richlistbox = aRichListBox;
|
||||
this._richlistbox._placesView = this;
|
||||
window.controllers.insertControllerAt(0, this);
|
||||
|
@ -227,16 +231,23 @@ function DownloadsPlacesView(aRichListBox, aActive = true) {
|
|||
this._waitingForInitialData = true;
|
||||
this._downloadsData.addView(this);
|
||||
|
||||
// Get the Download button out of the attention state since we're about to
|
||||
// view all downloads.
|
||||
DownloadsCommon.getIndicatorData(window).attention =
|
||||
DownloadsCommon.ATTENTION_NONE;
|
||||
// Pause the download indicator as user is interacting with downloads. This is
|
||||
// skipped on about:downloads because it handles this by itself.
|
||||
if (aSuppressionFlag === DownloadsCommon.SUPPRESS_ALL_DOWNLOADS_OPEN) {
|
||||
DownloadsCommon.getIndicatorData(
|
||||
window
|
||||
).attentionSuppressed |= aSuppressionFlag;
|
||||
}
|
||||
|
||||
// Make sure to unregister the view if the window is closed.
|
||||
window.addEventListener(
|
||||
"unload",
|
||||
() => {
|
||||
window.controllers.removeController(this);
|
||||
// Unpause the main window's download indicator.
|
||||
DownloadsCommon.getIndicatorData(
|
||||
window
|
||||
).attentionSuppressed &= ~aSuppressionFlag;
|
||||
this._downloadsData.removeView(this);
|
||||
this.result = null;
|
||||
},
|
||||
|
@ -583,6 +594,10 @@ DownloadsPlacesView.prototype = {
|
|||
isCommandEnabled(aCommand) {
|
||||
switch (aCommand) {
|
||||
case "cmd_copy":
|
||||
return Array.prototype.some.call(
|
||||
this._richlistbox.selectedItems,
|
||||
element => !!element._shell.download.source?.url
|
||||
);
|
||||
case "downloadsCmd_openReferrer":
|
||||
case "downloadShowMenuItem":
|
||||
return this._richlistbox.selectedItems.length == 1;
|
||||
|
@ -603,8 +618,8 @@ DownloadsPlacesView.prototype = {
|
|||
_copySelectedDownloadsToClipboard() {
|
||||
let urls = Array.from(
|
||||
this._richlistbox.selectedItems,
|
||||
element => element._shell.download.source.url
|
||||
);
|
||||
element => element._shell.download.source?.url
|
||||
).filter(Boolean);
|
||||
|
||||
Cc["@mozilla.org/widget/clipboardhelper;1"]
|
||||
.getService(Ci.nsIClipboardHelper)
|
||||
|
@ -723,10 +738,19 @@ DownloadsPlacesView.prototype = {
|
|||
return false;
|
||||
}
|
||||
|
||||
DownloadsViewUI.updateContextMenuForElement(
|
||||
document.getElementById("downloadsContextMenu"),
|
||||
element
|
||||
let contextMenu = document.getElementById("downloadsContextMenu");
|
||||
DownloadsViewUI.updateContextMenuForElement(contextMenu, element);
|
||||
// Hide the copy location item if there is somehow no URL. We have to do
|
||||
// this here instead of in DownloadsViewUI because DownloadsView doesn't
|
||||
// allow selecting multiple downloads, so in that view the menuitem will be
|
||||
// shown according to whether just the selected item has a source URL.
|
||||
contextMenu.querySelector(
|
||||
".downloadCopyLocationMenuItem"
|
||||
).hidden = !Array.prototype.some.call(
|
||||
this._richlistbox.selectedItems,
|
||||
el => !!el._shell.download.source?.url
|
||||
);
|
||||
|
||||
let download = element._shell.download;
|
||||
if (!download.stopped) {
|
||||
// The hasPartialData property of a download may change at any time after
|
||||
|
|
|
@ -11,6 +11,7 @@ const { PrivateBrowsingUtils } = ChromeUtils.import(
|
|||
var ContentAreaDownloadsView = {
|
||||
init() {
|
||||
let box = document.getElementById("downloadsListBox");
|
||||
let suppressionFlag = DownloadsCommon.SUPPRESS_CONTENT_AREA_DOWNLOADS_OPEN;
|
||||
box.addEventListener(
|
||||
"InitialDownloadsLoaded",
|
||||
() => {
|
||||
|
@ -19,10 +20,24 @@ var ContentAreaDownloadsView = {
|
|||
document
|
||||
.getElementById("downloadsListBox")
|
||||
.focus({ preventFocusRing: true });
|
||||
// Pause the indicator if the browser is active.
|
||||
if (document.visibilityState === "visible") {
|
||||
DownloadsCommon.getIndicatorData(
|
||||
window
|
||||
).attentionSuppressed |= suppressionFlag;
|
||||
}
|
||||
},
|
||||
{ once: true }
|
||||
);
|
||||
let view = new DownloadsPlacesView(box);
|
||||
let view = new DownloadsPlacesView(box, true, suppressionFlag);
|
||||
document.addEventListener("visibilitychange", aEvent => {
|
||||
let indicator = DownloadsCommon.getIndicatorData(window);
|
||||
if (document.visibilityState === "visible") {
|
||||
indicator.attentionSuppressed |= suppressionFlag;
|
||||
} else {
|
||||
indicator.attentionSuppressed &= ~suppressionFlag;
|
||||
}
|
||||
});
|
||||
// Do not display the Places downloads in private windows
|
||||
if (!PrivateBrowsingUtils.isContentWindowPrivate(window)) {
|
||||
view.place = "place:transition=7&sort=4";
|
||||
|
|
|
@ -369,7 +369,8 @@ var DownloadsPanel = {
|
|||
this._state = this.kStateShown;
|
||||
|
||||
// Since at most one popup is open at any given time, we can set globally.
|
||||
DownloadsCommon.getIndicatorData(window).attentionSuppressed = true;
|
||||
DownloadsCommon.getIndicatorData(window).attentionSuppressed |=
|
||||
DownloadsCommon.SUPPRESS_PANEL_OPEN;
|
||||
|
||||
// Ensure that the first item is selected when the panel is focused.
|
||||
if (DownloadsView.richListBox.itemCount > 0) {
|
||||
|
@ -399,7 +400,9 @@ var DownloadsPanel = {
|
|||
this.keyFocusing = false;
|
||||
|
||||
// Since at most one popup is open at any given time, we can set globally.
|
||||
DownloadsCommon.getIndicatorData(window).attentionSuppressed = false;
|
||||
DownloadsCommon.getIndicatorData(
|
||||
window
|
||||
).attentionSuppressed &= ~DownloadsCommon.SUPPRESS_PANEL_OPEN;
|
||||
|
||||
// Allow the anchor to be hidden.
|
||||
DownloadsButton.releaseAnchor();
|
||||
|
@ -1067,6 +1070,13 @@ var DownloadsView = {
|
|||
DownloadsViewController.updateCommands();
|
||||
|
||||
DownloadsViewUI.updateContextMenuForElement(this.contextMenu, element);
|
||||
// Hide the copy location item if there is somehow no URL. We have to do
|
||||
// this here instead of in DownloadsViewUI because DownloadsPlacesView
|
||||
// allows selecting multiple downloads, so in that view the menuitem will be
|
||||
// shown according to whether at least one of the selected items has a URL.
|
||||
this.contextMenu.querySelector(
|
||||
".downloadCopyLocationMenuItem"
|
||||
).hidden = !element._shell.download.source?.url;
|
||||
},
|
||||
|
||||
onDownloadDragStart(aEvent) {
|
||||
|
@ -1166,8 +1176,9 @@ class DownloadsViewItem extends DownloadsViewUI.DownloadElementShell {
|
|||
let { target } = this.download;
|
||||
return target.exists || target.partFileExists;
|
||||
}
|
||||
case "cmd_delete":
|
||||
case "downloadsCmd_copyLocation":
|
||||
return !!this.download.source?.url;
|
||||
case "cmd_delete":
|
||||
case "downloadsCmd_doDefault":
|
||||
return true;
|
||||
case "downloadsCmd_showBlockedInfo":
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
/* import-globals-from allDownloadsView.js */
|
||||
/* import-globals-from ../../../../toolkit/content/globalOverlay.js */
|
||||
/* import-globals-from /toolkit/content/globalOverlay.js */
|
||||
|
||||
document.addEventListener("DOMContentLoaded", function() {
|
||||
let downloadCommands = document.getElementById("downloadCommands");
|
||||
|
|
|
@ -31,8 +31,10 @@
|
|||
<menuseparator class="downloadCommandsSeparator"/>
|
||||
|
||||
<menuitem command="downloadsCmd_openReferrer"
|
||||
class="downloadOpenReferrerMenuItem"
|
||||
data-l10n-id="downloads-cmd-go-to-download-page"/>
|
||||
<menuitem command="cmd_copy"
|
||||
class="downloadCopyLocationMenuItem"
|
||||
data-l10n-id="downloads-cmd-copy-download-link"/>
|
||||
|
||||
<menuseparator/>
|
||||
|
|
|
@ -98,8 +98,10 @@
|
|||
<menuseparator class="downloadCommandsSeparator"/>
|
||||
|
||||
<menuitem command="downloadsCmd_openReferrer"
|
||||
class="downloadOpenReferrerMenuItem"
|
||||
data-l10n-id="downloads-cmd-go-to-download-page"/>
|
||||
<menuitem command="downloadsCmd_copyLocation"
|
||||
class="downloadCopyLocationMenuItem"
|
||||
data-l10n-id="downloads-cmd-copy-download-link"/>
|
||||
|
||||
<menuseparator/>
|
||||
|
|
|
@ -5,6 +5,19 @@
|
|||
let gDownloadDir;
|
||||
const TestFiles = {};
|
||||
|
||||
let ReferrerInfo = Components.Constructor(
|
||||
"@mozilla.org/referrer-info;1",
|
||||
"nsIReferrerInfo",
|
||||
"init"
|
||||
);
|
||||
|
||||
// Load a new URI with a specific referrer.
|
||||
let exampleRefInfo = new ReferrerInfo(
|
||||
Ci.nsIReferrerInfo.EMPTY,
|
||||
true,
|
||||
Services.io.newURI("https://example.org")
|
||||
);
|
||||
|
||||
const MENU_ITEMS = {
|
||||
pause: ".downloadPauseMenuItem",
|
||||
resume: ".downloadResumeMenuItem",
|
||||
|
@ -14,10 +27,10 @@ const MENU_ITEMS = {
|
|||
alwaysOpenSimilarFiles: '[command="downloadsCmd_alwaysOpenSimilarFiles"]',
|
||||
show: '[command="downloadsCmd_show"]',
|
||||
commandsSeparator: "menuseparator,.downloadCommandsSeparator",
|
||||
openReferrer: '[command="downloadsCmd_openReferrer"]',
|
||||
copyLocation: '[command="downloadsCmd_copyLocation"]',
|
||||
openReferrer: ".downloadOpenReferrerMenuItem",
|
||||
copyLocation: ".downloadCopyLocationMenuItem",
|
||||
separator: "menuseparator",
|
||||
deleteFile: '[command="downloadsCmd_deleteFile"]',
|
||||
deleteFile: ".downloadDeleteFileMenuItem",
|
||||
delete: '[command="cmd_delete"]',
|
||||
clearList: '[command="downloadsCmd_clearList"]',
|
||||
clearDownloads: '[command="downloadsCmd_clearDownloads"]',
|
||||
|
@ -32,6 +45,9 @@ const TestCasesDefaultMimetypes = [
|
|||
state: DownloadsCommon.DOWNLOAD_FINISHED,
|
||||
contentType: "application/pdf",
|
||||
target: {},
|
||||
source: {
|
||||
referrerInfo: exampleRefInfo,
|
||||
},
|
||||
},
|
||||
],
|
||||
expected: {
|
||||
|
@ -49,6 +65,31 @@ const TestCasesDefaultMimetypes = [
|
|||
],
|
||||
},
|
||||
},
|
||||
{
|
||||
name:
|
||||
"Completed PDF download with improvements pref disabled and referrer info missing",
|
||||
prefEnabled: false,
|
||||
downloads: [
|
||||
{
|
||||
state: DownloadsCommon.DOWNLOAD_FINISHED,
|
||||
contentType: "application/pdf",
|
||||
target: {},
|
||||
},
|
||||
],
|
||||
expected: {
|
||||
menu: [
|
||||
MENU_ITEMS.openInSystemViewer,
|
||||
MENU_ITEMS.alwaysOpenInSystemViewer,
|
||||
MENU_ITEMS.show,
|
||||
MENU_ITEMS.commandsSeparator,
|
||||
MENU_ITEMS.copyLocation,
|
||||
MENU_ITEMS.separator,
|
||||
MENU_ITEMS.deleteFile,
|
||||
MENU_ITEMS.delete,
|
||||
MENU_ITEMS.clearList,
|
||||
],
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "Canceled PDF download with improvements pref disabled",
|
||||
prefEnabled: false,
|
||||
|
@ -57,6 +98,9 @@ const TestCasesDefaultMimetypes = [
|
|||
state: DownloadsCommon.DOWNLOAD_CANCELED,
|
||||
contentType: "application/pdf",
|
||||
target: {},
|
||||
source: {
|
||||
referrerInfo: exampleRefInfo,
|
||||
},
|
||||
},
|
||||
],
|
||||
expected: {
|
||||
|
@ -80,6 +124,9 @@ const TestCasesNewMimetypesPrefDisabled = [
|
|||
state: DownloadsCommon.DOWNLOAD_FINISHED,
|
||||
contentType: "text/plain",
|
||||
target: {},
|
||||
source: {
|
||||
referrerInfo: exampleRefInfo,
|
||||
},
|
||||
},
|
||||
],
|
||||
expected: {
|
||||
|
@ -103,6 +150,9 @@ const TestCasesNewMimetypesPrefDisabled = [
|
|||
state: DownloadsCommon.DOWNLOAD_CANCELED,
|
||||
contentType: "text/plain",
|
||||
target: {},
|
||||
source: {
|
||||
referrerInfo: exampleRefInfo,
|
||||
},
|
||||
},
|
||||
],
|
||||
expected: {
|
||||
|
@ -126,6 +176,9 @@ const TestCasesNewMimetypesPrefEnabled = [
|
|||
state: DownloadsCommon.DOWNLOAD_FINISHED,
|
||||
contentType: "text/plain",
|
||||
target: {},
|
||||
source: {
|
||||
referrerInfo: exampleRefInfo,
|
||||
},
|
||||
},
|
||||
],
|
||||
expected: {
|
||||
|
@ -150,6 +203,9 @@ const TestCasesNewMimetypesPrefEnabled = [
|
|||
state: DownloadsCommon.DOWNLOAD_CANCELED,
|
||||
contentType: "text/plain",
|
||||
target: {},
|
||||
source: {
|
||||
referrerInfo: exampleRefInfo,
|
||||
},
|
||||
},
|
||||
],
|
||||
expected: {
|
||||
|
@ -172,6 +228,9 @@ const TestCasesNewMimetypesPrefEnabled = [
|
|||
state: DownloadsCommon.DOWNLOAD_FINISHED,
|
||||
contentType: "application/octet-stream",
|
||||
target: {},
|
||||
source: {
|
||||
referrerInfo: exampleRefInfo,
|
||||
},
|
||||
},
|
||||
],
|
||||
expected: {
|
||||
|
@ -197,6 +256,9 @@ const TestCasesNewMimetypesPrefEnabled = [
|
|||
state: DownloadsCommon.DOWNLOAD_FINISHED,
|
||||
contentType: "application/octet-stream",
|
||||
target: {},
|
||||
source: {
|
||||
referrerInfo: exampleRefInfo,
|
||||
},
|
||||
},
|
||||
],
|
||||
expected: {
|
||||
|
@ -228,6 +290,9 @@ const TestCasesDeletedFile = [
|
|||
state: DownloadsCommon.DOWNLOAD_FINISHED,
|
||||
contentType: "application/pdf",
|
||||
target: {},
|
||||
source: {
|
||||
referrerInfo: exampleRefInfo,
|
||||
},
|
||||
},
|
||||
],
|
||||
expected: {
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
/* import-globals-from ../../../../../browser/extensions/formautofill/content/autofillEditForms.js*/
|
||||
/* import-globals-from /browser/extensions/formautofill/content/autofillEditForms.js*/
|
||||
import ObservedPropertiesMixin from "../mixins/ObservedPropertiesMixin.js";
|
||||
import RichOption from "./rich-option.js";
|
||||
/* import-globals-from ../unprivileged-fallbacks.js */
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
/* import-globals-from ../../../../../browser/extensions/formautofill/content/autofillEditForms.js*/
|
||||
/* import-globals-from /browser/extensions/formautofill/content/autofillEditForms.js*/
|
||||
import LabelledCheckbox from "../components/labelled-checkbox.js";
|
||||
import PaymentRequestPage from "../components/payment-request-page.js";
|
||||
import PaymentStateSubscriberMixin from "../mixins/PaymentStateSubscriberMixin.js";
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
/* import-globals-from ../../../../../browser/extensions/formautofill/content/autofillEditForms.js*/
|
||||
/* import-globals-from /browser/extensions/formautofill/content/autofillEditForms.js*/
|
||||
import AcceptedCards from "../components/accepted-cards.js";
|
||||
import BillingAddressPicker from "./billing-address-picker.js";
|
||||
import CscInput from "../components/csc-input.js";
|
||||
|
|
|
@ -3,10 +3,10 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
/* import-globals-from ../../../base/content/utilityOverlay.js */
|
||||
/* import-globals-from /browser/base/content/utilityOverlay.js */
|
||||
/* import-globals-from ../PlacesUIUtils.jsm */
|
||||
/* import-globals-from ../../../../toolkit/components/places/PlacesUtils.jsm */
|
||||
/* import-globals-from ../../../../toolkit/components/places/PlacesTransactions.jsm */
|
||||
/* import-globals-from /toolkit/components/places/PlacesUtils.jsm */
|
||||
/* import-globals-from /toolkit/components/places/PlacesTransactions.jsm */
|
||||
/* import-globals-from ./places.js */
|
||||
|
||||
/**
|
||||
|
|
|
@ -4,8 +4,8 @@
|
|||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
/* import-globals-from instantEditBookmark.js */
|
||||
/* import-globals-from ../../../../toolkit/content/contentAreaUtils.js */
|
||||
/* import-globals-from ../../downloads/content/allDownloadsView.js */
|
||||
/* import-globals-from /toolkit/content/contentAreaUtils.js */
|
||||
/* import-globals-from /browser/components/downloads/content/allDownloadsView.js */
|
||||
|
||||
/* Shared Places Import - change other consumers if you change this: */
|
||||
var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
|
||||
|
|
|
@ -240,7 +240,7 @@ add_task(async function test_typing_and_reload() {
|
|||
|
||||
info("reload");
|
||||
browser.reload();
|
||||
await BrowserTestUtils.browserLoaded(browser);
|
||||
await BrowserTestUtils.browserLoaded(browser, false, TEST_URL);
|
||||
|
||||
// First typing should have been recorded
|
||||
await assertDatabaseValues([
|
||||
|
@ -255,7 +255,7 @@ add_task(async function test_typing_and_reload() {
|
|||
|
||||
info("reload");
|
||||
browser.reload();
|
||||
await BrowserTestUtils.browserLoaded(browser);
|
||||
await BrowserTestUtils.browserLoaded(browser, false, TEST_URL);
|
||||
|
||||
// Second typing should have been recorded
|
||||
await assertDatabaseValues([
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
<script src="js/vendor/jquery-2.1.1.min.js"></script>
|
||||
<script src="js/vendor/handlebars.runtime.js"></script>
|
||||
<script src="js/tmpl.js"></script>
|
||||
<script src="js/vendor.bundle.js"></script>
|
||||
<script src="js/main.bundle.js"></script>
|
||||
<script src="js/home/entry.js"></script>
|
||||
</body>
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -1,32 +1,23 @@
|
|||
/*
|
||||
object-assign
|
||||
(c) Sindre Sorhus
|
||||
@license MIT
|
||||
*/
|
||||
/*!***********************************!*\
|
||||
!*** ./content/panels/js/main.js ***!
|
||||
\***********************************/
|
||||
|
||||
/** @license React v0.20.2
|
||||
* scheduler.production.min.js
|
||||
*
|
||||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*/
|
||||
/*!***************************************!*\
|
||||
!*** ./content/panels/js/messages.js ***!
|
||||
\***************************************/
|
||||
|
||||
/** @license React v17.0.2
|
||||
* react-dom.production.min.js
|
||||
*
|
||||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*/
|
||||
/*!*******************************************!*\
|
||||
!*** ./content/panels/js/home/overlay.js ***!
|
||||
\*******************************************/
|
||||
|
||||
/** @license React v17.0.2
|
||||
* react.production.min.js
|
||||
*
|
||||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*/
|
||||
/*!********************************************!*\
|
||||
!*** ./content/panels/js/saved/overlay.js ***!
|
||||
\********************************************/
|
||||
|
||||
/*!*********************************************!*\
|
||||
!*** ./content/panels/js/signup/overlay.js ***!
|
||||
\*********************************************/
|
||||
|
||||
/*!********************************************************!*\
|
||||
!*** ./content/panels/js/components/PopularTopics.jsx ***!
|
||||
\********************************************************/
|
||||
|
|
520
browser/components/pocket/content/panels/js/vendor.bundle.js
Normal file
520
browser/components/pocket/content/panels/js/vendor.bundle.js
Normal file
|
@ -0,0 +1,520 @@
|
|||
"use strict";
|
||||
(self["webpackChunksave_to_pocket_ff"] = self["webpackChunksave_to_pocket_ff"] || []).push([[736],{
|
||||
|
||||
/***/ 418:
|
||||
/***/ ((module) => {
|
||||
|
||||
/*
|
||||
object-assign
|
||||
(c) Sindre Sorhus
|
||||
@license MIT
|
||||
*/
|
||||
|
||||
|
||||
/* eslint-disable no-unused-vars */
|
||||
var getOwnPropertySymbols = Object.getOwnPropertySymbols;
|
||||
var hasOwnProperty = Object.prototype.hasOwnProperty;
|
||||
var propIsEnumerable = Object.prototype.propertyIsEnumerable;
|
||||
|
||||
function toObject(val) {
|
||||
if (val === null || val === undefined) {
|
||||
throw new TypeError('Object.assign cannot be called with null or undefined');
|
||||
}
|
||||
|
||||
return Object(val);
|
||||
}
|
||||
|
||||
function shouldUseNative() {
|
||||
try {
|
||||
if (!Object.assign) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Detect buggy property enumeration order in older V8 versions.
|
||||
|
||||
// https://bugs.chromium.org/p/v8/issues/detail?id=4118
|
||||
var test1 = new String('abc'); // eslint-disable-line no-new-wrappers
|
||||
test1[5] = 'de';
|
||||
if (Object.getOwnPropertyNames(test1)[0] === '5') {
|
||||
return false;
|
||||
}
|
||||
|
||||
// https://bugs.chromium.org/p/v8/issues/detail?id=3056
|
||||
var test2 = {};
|
||||
for (var i = 0; i < 10; i++) {
|
||||
test2['_' + String.fromCharCode(i)] = i;
|
||||
}
|
||||
var order2 = Object.getOwnPropertyNames(test2).map(function (n) {
|
||||
return test2[n];
|
||||
});
|
||||
if (order2.join('') !== '0123456789') {
|
||||
return false;
|
||||
}
|
||||
|
||||
// https://bugs.chromium.org/p/v8/issues/detail?id=3056
|
||||
var test3 = {};
|
||||
'abcdefghijklmnopqrst'.split('').forEach(function (letter) {
|
||||
test3[letter] = letter;
|
||||
});
|
||||
if (Object.keys(Object.assign({}, test3)).join('') !==
|
||||
'abcdefghijklmnopqrst') {
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
} catch (err) {
|
||||
// We don't expect any of the above to throw, but better to be safe.
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = shouldUseNative() ? Object.assign : function (target, source) {
|
||||
var from;
|
||||
var to = toObject(target);
|
||||
var symbols;
|
||||
|
||||
for (var s = 1; s < arguments.length; s++) {
|
||||
from = Object(arguments[s]);
|
||||
|
||||
for (var key in from) {
|
||||
if (hasOwnProperty.call(from, key)) {
|
||||
to[key] = from[key];
|
||||
}
|
||||
}
|
||||
|
||||
if (getOwnPropertySymbols) {
|
||||
symbols = getOwnPropertySymbols(from);
|
||||
for (var i = 0; i < symbols.length; i++) {
|
||||
if (propIsEnumerable.call(from, symbols[i])) {
|
||||
to[symbols[i]] = from[symbols[i]];
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return to;
|
||||
};
|
||||
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 448:
|
||||
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
||||
|
||||
/** @license React v17.0.2
|
||||
* react-dom.production.min.js
|
||||
*
|
||||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*/
|
||||
/*
|
||||
Modernizr 3.0.0pre (Custom Build) | MIT
|
||||
*/
|
||||
var aa=__webpack_require__(294),m=__webpack_require__(418),r=__webpack_require__(840);function y(a){for(var b="https://reactjs.org/docs/error-decoder.html?invariant="+a,c=1;c<arguments.length;c++)b+="&args[]="+encodeURIComponent(arguments[c]);return"Minified React error #"+a+"; visit "+b+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}if(!aa)throw Error(y(227));var ba=new Set,ca={};function da(a,b){ea(a,b);ea(a+"Capture",b)}
|
||||
function ea(a,b){ca[a]=b;for(a=0;a<b.length;a++)ba.add(b[a])}
|
||||
var fa=!("undefined"===typeof window||"undefined"===typeof window.document||"undefined"===typeof window.document.createElement),ha=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,ia=Object.prototype.hasOwnProperty,
|
||||
ja={},ka={};function la(a){if(ia.call(ka,a))return!0;if(ia.call(ja,a))return!1;if(ha.test(a))return ka[a]=!0;ja[a]=!0;return!1}function ma(a,b,c,d){if(null!==c&&0===c.type)return!1;switch(typeof b){case "function":case "symbol":return!0;case "boolean":if(d)return!1;if(null!==c)return!c.acceptsBooleans;a=a.toLowerCase().slice(0,5);return"data-"!==a&&"aria-"!==a;default:return!1}}
|
||||
function na(a,b,c,d){if(null===b||"undefined"===typeof b||ma(a,b,c,d))return!0;if(d)return!1;if(null!==c)switch(c.type){case 3:return!b;case 4:return!1===b;case 5:return isNaN(b);case 6:return isNaN(b)||1>b}return!1}function B(a,b,c,d,e,f,g){this.acceptsBooleans=2===b||3===b||4===b;this.attributeName=d;this.attributeNamespace=e;this.mustUseProperty=c;this.propertyName=a;this.type=b;this.sanitizeURL=f;this.removeEmptyString=g}var D={};
|
||||
"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(a){D[a]=new B(a,0,!1,a,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(a){var b=a[0];D[b]=new B(b,1,!1,a[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(a){D[a]=new B(a,2,!1,a.toLowerCase(),null,!1,!1)});
|
||||
["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(a){D[a]=new B(a,2,!1,a,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(a){D[a]=new B(a,3,!1,a.toLowerCase(),null,!1,!1)});
|
||||
["checked","multiple","muted","selected"].forEach(function(a){D[a]=new B(a,3,!0,a,null,!1,!1)});["capture","download"].forEach(function(a){D[a]=new B(a,4,!1,a,null,!1,!1)});["cols","rows","size","span"].forEach(function(a){D[a]=new B(a,6,!1,a,null,!1,!1)});["rowSpan","start"].forEach(function(a){D[a]=new B(a,5,!1,a.toLowerCase(),null,!1,!1)});var oa=/[\-:]([a-z])/g;function pa(a){return a[1].toUpperCase()}
|
||||
"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(a){var b=a.replace(oa,
|
||||
pa);D[b]=new B(b,1,!1,a,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(a){var b=a.replace(oa,pa);D[b]=new B(b,1,!1,a,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(a){var b=a.replace(oa,pa);D[b]=new B(b,1,!1,a,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(a){D[a]=new B(a,1,!1,a.toLowerCase(),null,!1,!1)});
|
||||
D.xlinkHref=new B("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(a){D[a]=new B(a,1,!1,a.toLowerCase(),null,!0,!0)});
|
||||
function qa(a,b,c,d){var e=D.hasOwnProperty(b)?D[b]:null;var f=null!==e?0===e.type:d?!1:!(2<b.length)||"o"!==b[0]&&"O"!==b[0]||"n"!==b[1]&&"N"!==b[1]?!1:!0;f||(na(b,c,e,d)&&(c=null),d||null===e?la(b)&&(null===c?a.removeAttribute(b):a.setAttribute(b,""+c)):e.mustUseProperty?a[e.propertyName]=null===c?3===e.type?!1:"":c:(b=e.attributeName,d=e.attributeNamespace,null===c?a.removeAttribute(b):(e=e.type,c=3===e||4===e&&!0===c?"":""+c,d?a.setAttributeNS(d,b,c):a.setAttribute(b,c))))}
|
||||
var ra=aa.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,sa=60103,ta=60106,ua=60107,wa=60108,xa=60114,ya=60109,za=60110,Aa=60112,Ba=60113,Ca=60120,Da=60115,Ea=60116,Fa=60121,Ga=60128,Ha=60129,Ia=60130,Ja=60131;
|
||||
if("function"===typeof Symbol&&Symbol.for){var E=Symbol.for;sa=E("react.element");ta=E("react.portal");ua=E("react.fragment");wa=E("react.strict_mode");xa=E("react.profiler");ya=E("react.provider");za=E("react.context");Aa=E("react.forward_ref");Ba=E("react.suspense");Ca=E("react.suspense_list");Da=E("react.memo");Ea=E("react.lazy");Fa=E("react.block");E("react.scope");Ga=E("react.opaque.id");Ha=E("react.debug_trace_mode");Ia=E("react.offscreen");Ja=E("react.legacy_hidden")}
|
||||
var Ka="function"===typeof Symbol&&Symbol.iterator;function La(a){if(null===a||"object"!==typeof a)return null;a=Ka&&a[Ka]||a["@@iterator"];return"function"===typeof a?a:null}var Ma;function Na(a){if(void 0===Ma)try{throw Error();}catch(c){var b=c.stack.trim().match(/\n( *(at )?)/);Ma=b&&b[1]||""}return"\n"+Ma+a}var Oa=!1;
|
||||
function Pa(a,b){if(!a||Oa)return"";Oa=!0;var c=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(b)if(b=function(){throw Error();},Object.defineProperty(b.prototype,"props",{set:function(){throw Error();}}),"object"===typeof Reflect&&Reflect.construct){try{Reflect.construct(b,[])}catch(k){var d=k}Reflect.construct(a,[],b)}else{try{b.call()}catch(k){d=k}a.call(b.prototype)}else{try{throw Error();}catch(k){d=k}a()}}catch(k){if(k&&d&&"string"===typeof k.stack){for(var e=k.stack.split("\n"),
|
||||
f=d.stack.split("\n"),g=e.length-1,h=f.length-1;1<=g&&0<=h&&e[g]!==f[h];)h--;for(;1<=g&&0<=h;g--,h--)if(e[g]!==f[h]){if(1!==g||1!==h){do if(g--,h--,0>h||e[g]!==f[h])return"\n"+e[g].replace(" at new "," at ");while(1<=g&&0<=h)}break}}}finally{Oa=!1,Error.prepareStackTrace=c}return(a=a?a.displayName||a.name:"")?Na(a):""}
|
||||
function Qa(a){switch(a.tag){case 5:return Na(a.type);case 16:return Na("Lazy");case 13:return Na("Suspense");case 19:return Na("SuspenseList");case 0:case 2:case 15:return a=Pa(a.type,!1),a;case 11:return a=Pa(a.type.render,!1),a;case 22:return a=Pa(a.type._render,!1),a;case 1:return a=Pa(a.type,!0),a;default:return""}}
|
||||
function Ra(a){if(null==a)return null;if("function"===typeof a)return a.displayName||a.name||null;if("string"===typeof a)return a;switch(a){case ua:return"Fragment";case ta:return"Portal";case xa:return"Profiler";case wa:return"StrictMode";case Ba:return"Suspense";case Ca:return"SuspenseList"}if("object"===typeof a)switch(a.$$typeof){case za:return(a.displayName||"Context")+".Consumer";case ya:return(a._context.displayName||"Context")+".Provider";case Aa:var b=a.render;b=b.displayName||b.name||"";
|
||||
return a.displayName||(""!==b?"ForwardRef("+b+")":"ForwardRef");case Da:return Ra(a.type);case Fa:return Ra(a._render);case Ea:b=a._payload;a=a._init;try{return Ra(a(b))}catch(c){}}return null}function Sa(a){switch(typeof a){case "boolean":case "number":case "object":case "string":case "undefined":return a;default:return""}}function Ta(a){var b=a.type;return(a=a.nodeName)&&"input"===a.toLowerCase()&&("checkbox"===b||"radio"===b)}
|
||||
function Ua(a){var b=Ta(a)?"checked":"value",c=Object.getOwnPropertyDescriptor(a.constructor.prototype,b),d=""+a[b];if(!a.hasOwnProperty(b)&&"undefined"!==typeof c&&"function"===typeof c.get&&"function"===typeof c.set){var e=c.get,f=c.set;Object.defineProperty(a,b,{configurable:!0,get:function(){return e.call(this)},set:function(a){d=""+a;f.call(this,a)}});Object.defineProperty(a,b,{enumerable:c.enumerable});return{getValue:function(){return d},setValue:function(a){d=""+a},stopTracking:function(){a._valueTracker=
|
||||
null;delete a[b]}}}}function Va(a){a._valueTracker||(a._valueTracker=Ua(a))}function Wa(a){if(!a)return!1;var b=a._valueTracker;if(!b)return!0;var c=b.getValue();var d="";a&&(d=Ta(a)?a.checked?"true":"false":a.value);a=d;return a!==c?(b.setValue(a),!0):!1}function Xa(a){a=a||("undefined"!==typeof document?document:void 0);if("undefined"===typeof a)return null;try{return a.activeElement||a.body}catch(b){return a.body}}
|
||||
function Ya(a,b){var c=b.checked;return m({},b,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:null!=c?c:a._wrapperState.initialChecked})}function Za(a,b){var c=null==b.defaultValue?"":b.defaultValue,d=null!=b.checked?b.checked:b.defaultChecked;c=Sa(null!=b.value?b.value:c);a._wrapperState={initialChecked:d,initialValue:c,controlled:"checkbox"===b.type||"radio"===b.type?null!=b.checked:null!=b.value}}function $a(a,b){b=b.checked;null!=b&&qa(a,"checked",b,!1)}
|
||||
function ab(a,b){$a(a,b);var c=Sa(b.value),d=b.type;if(null!=c)if("number"===d){if(0===c&&""===a.value||a.value!=c)a.value=""+c}else a.value!==""+c&&(a.value=""+c);else if("submit"===d||"reset"===d){a.removeAttribute("value");return}b.hasOwnProperty("value")?bb(a,b.type,c):b.hasOwnProperty("defaultValue")&&bb(a,b.type,Sa(b.defaultValue));null==b.checked&&null!=b.defaultChecked&&(a.defaultChecked=!!b.defaultChecked)}
|
||||
function cb(a,b,c){if(b.hasOwnProperty("value")||b.hasOwnProperty("defaultValue")){var d=b.type;if(!("submit"!==d&&"reset"!==d||void 0!==b.value&&null!==b.value))return;b=""+a._wrapperState.initialValue;c||b===a.value||(a.value=b);a.defaultValue=b}c=a.name;""!==c&&(a.name="");a.defaultChecked=!!a._wrapperState.initialChecked;""!==c&&(a.name=c)}
|
||||
function bb(a,b,c){if("number"!==b||Xa(a.ownerDocument)!==a)null==c?a.defaultValue=""+a._wrapperState.initialValue:a.defaultValue!==""+c&&(a.defaultValue=""+c)}function db(a){var b="";aa.Children.forEach(a,function(a){null!=a&&(b+=a)});return b}function eb(a,b){a=m({children:void 0},b);if(b=db(b.children))a.children=b;return a}
|
||||
function fb(a,b,c,d){a=a.options;if(b){b={};for(var e=0;e<c.length;e++)b["$"+c[e]]=!0;for(c=0;c<a.length;c++)e=b.hasOwnProperty("$"+a[c].value),a[c].selected!==e&&(a[c].selected=e),e&&d&&(a[c].defaultSelected=!0)}else{c=""+Sa(c);b=null;for(e=0;e<a.length;e++){if(a[e].value===c){a[e].selected=!0;d&&(a[e].defaultSelected=!0);return}null!==b||a[e].disabled||(b=a[e])}null!==b&&(b.selected=!0)}}
|
||||
function gb(a,b){if(null!=b.dangerouslySetInnerHTML)throw Error(y(91));return m({},b,{value:void 0,defaultValue:void 0,children:""+a._wrapperState.initialValue})}function hb(a,b){var c=b.value;if(null==c){c=b.children;b=b.defaultValue;if(null!=c){if(null!=b)throw Error(y(92));if(Array.isArray(c)){if(!(1>=c.length))throw Error(y(93));c=c[0]}b=c}null==b&&(b="");c=b}a._wrapperState={initialValue:Sa(c)}}
|
||||
function ib(a,b){var c=Sa(b.value),d=Sa(b.defaultValue);null!=c&&(c=""+c,c!==a.value&&(a.value=c),null==b.defaultValue&&a.defaultValue!==c&&(a.defaultValue=c));null!=d&&(a.defaultValue=""+d)}function jb(a){var b=a.textContent;b===a._wrapperState.initialValue&&""!==b&&null!==b&&(a.value=b)}var kb={html:"http://www.w3.org/1999/xhtml",mathml:"http://www.w3.org/1998/Math/MathML",svg:"http://www.w3.org/2000/svg"};
|
||||
function lb(a){switch(a){case "svg":return"http://www.w3.org/2000/svg";case "math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function mb(a,b){return null==a||"http://www.w3.org/1999/xhtml"===a?lb(b):"http://www.w3.org/2000/svg"===a&&"foreignObject"===b?"http://www.w3.org/1999/xhtml":a}
|
||||
var nb,ob=function(a){return"undefined"!==typeof MSApp&&MSApp.execUnsafeLocalFunction?function(b,c,d,e){MSApp.execUnsafeLocalFunction(function(){return a(b,c,d,e)})}:a}(function(a,b){if(a.namespaceURI!==kb.svg||"innerHTML"in a)a.innerHTML=b;else{nb=nb||document.createElement("div");nb.innerHTML="<svg>"+b.valueOf().toString()+"</svg>";for(b=nb.firstChild;a.firstChild;)a.removeChild(a.firstChild);for(;b.firstChild;)a.appendChild(b.firstChild)}});
|
||||
function pb(a,b){if(b){var c=a.firstChild;if(c&&c===a.lastChild&&3===c.nodeType){c.nodeValue=b;return}}a.textContent=b}
|
||||
var qb={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,
|
||||
floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},rb=["Webkit","ms","Moz","O"];Object.keys(qb).forEach(function(a){rb.forEach(function(b){b=b+a.charAt(0).toUpperCase()+a.substring(1);qb[b]=qb[a]})});function sb(a,b,c){return null==b||"boolean"===typeof b||""===b?"":c||"number"!==typeof b||0===b||qb.hasOwnProperty(a)&&qb[a]?(""+b).trim():b+"px"}
|
||||
function tb(a,b){a=a.style;for(var c in b)if(b.hasOwnProperty(c)){var d=0===c.indexOf("--"),e=sb(c,b[c],d);"float"===c&&(c="cssFloat");d?a.setProperty(c,e):a[c]=e}}var ub=m({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});
|
||||
function vb(a,b){if(b){if(ub[a]&&(null!=b.children||null!=b.dangerouslySetInnerHTML))throw Error(y(137,a));if(null!=b.dangerouslySetInnerHTML){if(null!=b.children)throw Error(y(60));if(!("object"===typeof b.dangerouslySetInnerHTML&&"__html"in b.dangerouslySetInnerHTML))throw Error(y(61));}if(null!=b.style&&"object"!==typeof b.style)throw Error(y(62));}}
|
||||
function wb(a,b){if(-1===a.indexOf("-"))return"string"===typeof b.is;switch(a){case "annotation-xml":case "color-profile":case "font-face":case "font-face-src":case "font-face-uri":case "font-face-format":case "font-face-name":case "missing-glyph":return!1;default:return!0}}function xb(a){a=a.target||a.srcElement||window;a.correspondingUseElement&&(a=a.correspondingUseElement);return 3===a.nodeType?a.parentNode:a}var yb=null,zb=null,Ab=null;
|
||||
function Bb(a){if(a=Cb(a)){if("function"!==typeof yb)throw Error(y(280));var b=a.stateNode;b&&(b=Db(b),yb(a.stateNode,a.type,b))}}function Eb(a){zb?Ab?Ab.push(a):Ab=[a]:zb=a}function Fb(){if(zb){var a=zb,b=Ab;Ab=zb=null;Bb(a);if(b)for(a=0;a<b.length;a++)Bb(b[a])}}function Gb(a,b){return a(b)}function Hb(a,b,c,d,e){return a(b,c,d,e)}function Ib(){}var Jb=Gb,Kb=!1,Lb=!1;function Mb(){if(null!==zb||null!==Ab)Ib(),Fb()}
|
||||
function Nb(a,b,c){if(Lb)return a(b,c);Lb=!0;try{return Jb(a,b,c)}finally{Lb=!1,Mb()}}
|
||||
function Ob(a,b){var c=a.stateNode;if(null===c)return null;var d=Db(c);if(null===d)return null;c=d[b];a:switch(b){case "onClick":case "onClickCapture":case "onDoubleClick":case "onDoubleClickCapture":case "onMouseDown":case "onMouseDownCapture":case "onMouseMove":case "onMouseMoveCapture":case "onMouseUp":case "onMouseUpCapture":case "onMouseEnter":(d=!d.disabled)||(a=a.type,d=!("button"===a||"input"===a||"select"===a||"textarea"===a));a=!d;break a;default:a=!1}if(a)return null;if(c&&"function"!==
|
||||
typeof c)throw Error(y(231,b,typeof c));return c}var Pb=!1;if(fa)try{var Qb={};Object.defineProperty(Qb,"passive",{get:function(){Pb=!0}});window.addEventListener("test",Qb,Qb);window.removeEventListener("test",Qb,Qb)}catch(a){Pb=!1}function Rb(a,b,c,d,e,f,g,h,k){var l=Array.prototype.slice.call(arguments,3);try{b.apply(c,l)}catch(n){this.onError(n)}}var Sb=!1,Tb=null,Ub=!1,Vb=null,Wb={onError:function(a){Sb=!0;Tb=a}};function Xb(a,b,c,d,e,f,g,h,k){Sb=!1;Tb=null;Rb.apply(Wb,arguments)}
|
||||
function Yb(a,b,c,d,e,f,g,h,k){Xb.apply(this,arguments);if(Sb){if(Sb){var l=Tb;Sb=!1;Tb=null}else throw Error(y(198));Ub||(Ub=!0,Vb=l)}}function Zb(a){var b=a,c=a;if(a.alternate)for(;b.return;)b=b.return;else{a=b;do b=a,0!==(b.flags&1026)&&(c=b.return),a=b.return;while(a)}return 3===b.tag?c:null}function $b(a){if(13===a.tag){var b=a.memoizedState;null===b&&(a=a.alternate,null!==a&&(b=a.memoizedState));if(null!==b)return b.dehydrated}return null}function ac(a){if(Zb(a)!==a)throw Error(y(188));}
|
||||
function bc(a){var b=a.alternate;if(!b){b=Zb(a);if(null===b)throw Error(y(188));return b!==a?null:a}for(var c=a,d=b;;){var e=c.return;if(null===e)break;var f=e.alternate;if(null===f){d=e.return;if(null!==d){c=d;continue}break}if(e.child===f.child){for(f=e.child;f;){if(f===c)return ac(e),a;if(f===d)return ac(e),b;f=f.sibling}throw Error(y(188));}if(c.return!==d.return)c=e,d=f;else{for(var g=!1,h=e.child;h;){if(h===c){g=!0;c=e;d=f;break}if(h===d){g=!0;d=e;c=f;break}h=h.sibling}if(!g){for(h=f.child;h;){if(h===
|
||||
c){g=!0;c=f;d=e;break}if(h===d){g=!0;d=f;c=e;break}h=h.sibling}if(!g)throw Error(y(189));}}if(c.alternate!==d)throw Error(y(190));}if(3!==c.tag)throw Error(y(188));return c.stateNode.current===c?a:b}function cc(a){a=bc(a);if(!a)return null;for(var b=a;;){if(5===b.tag||6===b.tag)return b;if(b.child)b.child.return=b,b=b.child;else{if(b===a)break;for(;!b.sibling;){if(!b.return||b.return===a)return null;b=b.return}b.sibling.return=b.return;b=b.sibling}}return null}
|
||||
function dc(a,b){for(var c=a.alternate;null!==b;){if(b===a||b===c)return!0;b=b.return}return!1}var ec,fc,gc,hc,ic=!1,jc=[],kc=null,lc=null,mc=null,nc=new Map,oc=new Map,pc=[],qc="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");
|
||||
function rc(a,b,c,d,e){return{blockedOn:a,domEventName:b,eventSystemFlags:c|16,nativeEvent:e,targetContainers:[d]}}function sc(a,b){switch(a){case "focusin":case "focusout":kc=null;break;case "dragenter":case "dragleave":lc=null;break;case "mouseover":case "mouseout":mc=null;break;case "pointerover":case "pointerout":nc.delete(b.pointerId);break;case "gotpointercapture":case "lostpointercapture":oc.delete(b.pointerId)}}
|
||||
function tc(a,b,c,d,e,f){if(null===a||a.nativeEvent!==f)return a=rc(b,c,d,e,f),null!==b&&(b=Cb(b),null!==b&&fc(b)),a;a.eventSystemFlags|=d;b=a.targetContainers;null!==e&&-1===b.indexOf(e)&&b.push(e);return a}
|
||||
function uc(a,b,c,d,e){switch(b){case "focusin":return kc=tc(kc,a,b,c,d,e),!0;case "dragenter":return lc=tc(lc,a,b,c,d,e),!0;case "mouseover":return mc=tc(mc,a,b,c,d,e),!0;case "pointerover":var f=e.pointerId;nc.set(f,tc(nc.get(f)||null,a,b,c,d,e));return!0;case "gotpointercapture":return f=e.pointerId,oc.set(f,tc(oc.get(f)||null,a,b,c,d,e)),!0}return!1}
|
||||
function vc(a){var b=wc(a.target);if(null!==b){var c=Zb(b);if(null!==c)if(b=c.tag,13===b){if(b=$b(c),null!==b){a.blockedOn=b;hc(a.lanePriority,function(){r.unstable_runWithPriority(a.priority,function(){gc(c)})});return}}else if(3===b&&c.stateNode.hydrate){a.blockedOn=3===c.tag?c.stateNode.containerInfo:null;return}}a.blockedOn=null}
|
||||
function xc(a){if(null!==a.blockedOn)return!1;for(var b=a.targetContainers;0<b.length;){var c=yc(a.domEventName,a.eventSystemFlags,b[0],a.nativeEvent);if(null!==c)return b=Cb(c),null!==b&&fc(b),a.blockedOn=c,!1;b.shift()}return!0}function zc(a,b,c){xc(a)&&c.delete(b)}
|
||||
function Ac(){for(ic=!1;0<jc.length;){var a=jc[0];if(null!==a.blockedOn){a=Cb(a.blockedOn);null!==a&&ec(a);break}for(var b=a.targetContainers;0<b.length;){var c=yc(a.domEventName,a.eventSystemFlags,b[0],a.nativeEvent);if(null!==c){a.blockedOn=c;break}b.shift()}null===a.blockedOn&&jc.shift()}null!==kc&&xc(kc)&&(kc=null);null!==lc&&xc(lc)&&(lc=null);null!==mc&&xc(mc)&&(mc=null);nc.forEach(zc);oc.forEach(zc)}
|
||||
function Bc(a,b){a.blockedOn===b&&(a.blockedOn=null,ic||(ic=!0,r.unstable_scheduleCallback(r.unstable_NormalPriority,Ac)))}
|
||||
function Cc(a){function b(b){return Bc(b,a)}if(0<jc.length){Bc(jc[0],a);for(var c=1;c<jc.length;c++){var d=jc[c];d.blockedOn===a&&(d.blockedOn=null)}}null!==kc&&Bc(kc,a);null!==lc&&Bc(lc,a);null!==mc&&Bc(mc,a);nc.forEach(b);oc.forEach(b);for(c=0;c<pc.length;c++)d=pc[c],d.blockedOn===a&&(d.blockedOn=null);for(;0<pc.length&&(c=pc[0],null===c.blockedOn);)vc(c),null===c.blockedOn&&pc.shift()}
|
||||
function Dc(a,b){var c={};c[a.toLowerCase()]=b.toLowerCase();c["Webkit"+a]="webkit"+b;c["Moz"+a]="moz"+b;return c}var Ec={animationend:Dc("Animation","AnimationEnd"),animationiteration:Dc("Animation","AnimationIteration"),animationstart:Dc("Animation","AnimationStart"),transitionend:Dc("Transition","TransitionEnd")},Fc={},Gc={};
|
||||
fa&&(Gc=document.createElement("div").style,"AnimationEvent"in window||(delete Ec.animationend.animation,delete Ec.animationiteration.animation,delete Ec.animationstart.animation),"TransitionEvent"in window||delete Ec.transitionend.transition);function Hc(a){if(Fc[a])return Fc[a];if(!Ec[a])return a;var b=Ec[a],c;for(c in b)if(b.hasOwnProperty(c)&&c in Gc)return Fc[a]=b[c];return a}
|
||||
var Ic=Hc("animationend"),Jc=Hc("animationiteration"),Kc=Hc("animationstart"),Lc=Hc("transitionend"),Mc=new Map,Nc=new Map,Oc=["abort","abort",Ic,"animationEnd",Jc,"animationIteration",Kc,"animationStart","canplay","canPlay","canplaythrough","canPlayThrough","durationchange","durationChange","emptied","emptied","encrypted","encrypted","ended","ended","error","error","gotpointercapture","gotPointerCapture","load","load","loadeddata","loadedData","loadedmetadata","loadedMetadata","loadstart","loadStart",
|
||||
"lostpointercapture","lostPointerCapture","playing","playing","progress","progress","seeking","seeking","stalled","stalled","suspend","suspend","timeupdate","timeUpdate",Lc,"transitionEnd","waiting","waiting"];function Pc(a,b){for(var c=0;c<a.length;c+=2){var d=a[c],e=a[c+1];e="on"+(e[0].toUpperCase()+e.slice(1));Nc.set(d,b);Mc.set(d,e);da(e,[d])}}var Qc=r.unstable_now;Qc();var F=8;
|
||||
function Rc(a){if(0!==(1&a))return F=15,1;if(0!==(2&a))return F=14,2;if(0!==(4&a))return F=13,4;var b=24&a;if(0!==b)return F=12,b;if(0!==(a&32))return F=11,32;b=192&a;if(0!==b)return F=10,b;if(0!==(a&256))return F=9,256;b=3584&a;if(0!==b)return F=8,b;if(0!==(a&4096))return F=7,4096;b=4186112&a;if(0!==b)return F=6,b;b=62914560&a;if(0!==b)return F=5,b;if(a&67108864)return F=4,67108864;if(0!==(a&134217728))return F=3,134217728;b=805306368&a;if(0!==b)return F=2,b;if(0!==(1073741824&a))return F=1,1073741824;
|
||||
F=8;return a}function Sc(a){switch(a){case 99:return 15;case 98:return 10;case 97:case 96:return 8;case 95:return 2;default:return 0}}function Tc(a){switch(a){case 15:case 14:return 99;case 13:case 12:case 11:case 10:return 98;case 9:case 8:case 7:case 6:case 4:case 5:return 97;case 3:case 2:case 1:return 95;case 0:return 90;default:throw Error(y(358,a));}}
|
||||
function Uc(a,b){var c=a.pendingLanes;if(0===c)return F=0;var d=0,e=0,f=a.expiredLanes,g=a.suspendedLanes,h=a.pingedLanes;if(0!==f)d=f,e=F=15;else if(f=c&134217727,0!==f){var k=f&~g;0!==k?(d=Rc(k),e=F):(h&=f,0!==h&&(d=Rc(h),e=F))}else f=c&~g,0!==f?(d=Rc(f),e=F):0!==h&&(d=Rc(h),e=F);if(0===d)return 0;d=31-Vc(d);d=c&((0>d?0:1<<d)<<1)-1;if(0!==b&&b!==d&&0===(b&g)){Rc(b);if(e<=F)return b;F=e}b=a.entangledLanes;if(0!==b)for(a=a.entanglements,b&=d;0<b;)c=31-Vc(b),e=1<<c,d|=a[c],b&=~e;return d}
|
||||
function Wc(a){a=a.pendingLanes&-1073741825;return 0!==a?a:a&1073741824?1073741824:0}function Xc(a,b){switch(a){case 15:return 1;case 14:return 2;case 12:return a=Yc(24&~b),0===a?Xc(10,b):a;case 10:return a=Yc(192&~b),0===a?Xc(8,b):a;case 8:return a=Yc(3584&~b),0===a&&(a=Yc(4186112&~b),0===a&&(a=512)),a;case 2:return b=Yc(805306368&~b),0===b&&(b=268435456),b}throw Error(y(358,a));}function Yc(a){return a&-a}function Zc(a){for(var b=[],c=0;31>c;c++)b.push(a);return b}
|
||||
function $c(a,b,c){a.pendingLanes|=b;var d=b-1;a.suspendedLanes&=d;a.pingedLanes&=d;a=a.eventTimes;b=31-Vc(b);a[b]=c}var Vc=Math.clz32?Math.clz32:ad,bd=Math.log,cd=Math.LN2;function ad(a){return 0===a?32:31-(bd(a)/cd|0)|0}var dd=r.unstable_UserBlockingPriority,ed=r.unstable_runWithPriority,fd=!0;function gd(a,b,c,d){Kb||Ib();var e=hd,f=Kb;Kb=!0;try{Hb(e,a,b,c,d)}finally{(Kb=f)||Mb()}}function id(a,b,c,d){ed(dd,hd.bind(null,a,b,c,d))}
|
||||
function hd(a,b,c,d){if(fd){var e;if((e=0===(b&4))&&0<jc.length&&-1<qc.indexOf(a))a=rc(null,a,b,c,d),jc.push(a);else{var f=yc(a,b,c,d);if(null===f)e&&sc(a,d);else{if(e){if(-1<qc.indexOf(a)){a=rc(f,a,b,c,d);jc.push(a);return}if(uc(f,a,b,c,d))return;sc(a,d)}jd(a,b,d,null,c)}}}}
|
||||
function yc(a,b,c,d){var e=xb(d);e=wc(e);if(null!==e){var f=Zb(e);if(null===f)e=null;else{var g=f.tag;if(13===g){e=$b(f);if(null!==e)return e;e=null}else if(3===g){if(f.stateNode.hydrate)return 3===f.tag?f.stateNode.containerInfo:null;e=null}else f!==e&&(e=null)}}jd(a,b,d,e,c);return null}var kd=null,ld=null,md=null;
|
||||
function nd(){if(md)return md;var a,b=ld,c=b.length,d,e="value"in kd?kd.value:kd.textContent,f=e.length;for(a=0;a<c&&b[a]===e[a];a++);var g=c-a;for(d=1;d<=g&&b[c-d]===e[f-d];d++);return md=e.slice(a,1<d?1-d:void 0)}function od(a){var b=a.keyCode;"charCode"in a?(a=a.charCode,0===a&&13===b&&(a=13)):a=b;10===a&&(a=13);return 32<=a||13===a?a:0}function pd(){return!0}function qd(){return!1}
|
||||
function rd(a){function b(b,d,e,f,g){this._reactName=b;this._targetInst=e;this.type=d;this.nativeEvent=f;this.target=g;this.currentTarget=null;for(var c in a)a.hasOwnProperty(c)&&(b=a[c],this[c]=b?b(f):f[c]);this.isDefaultPrevented=(null!=f.defaultPrevented?f.defaultPrevented:!1===f.returnValue)?pd:qd;this.isPropagationStopped=qd;return this}m(b.prototype,{preventDefault:function(){this.defaultPrevented=!0;var a=this.nativeEvent;a&&(a.preventDefault?a.preventDefault():"unknown"!==typeof a.returnValue&&
|
||||
(a.returnValue=!1),this.isDefaultPrevented=pd)},stopPropagation:function(){var a=this.nativeEvent;a&&(a.stopPropagation?a.stopPropagation():"unknown"!==typeof a.cancelBubble&&(a.cancelBubble=!0),this.isPropagationStopped=pd)},persist:function(){},isPersistent:pd});return b}
|
||||
var sd={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(a){return a.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},td=rd(sd),ud=m({},sd,{view:0,detail:0}),vd=rd(ud),wd,xd,yd,Ad=m({},ud,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:zd,button:0,buttons:0,relatedTarget:function(a){return void 0===a.relatedTarget?a.fromElement===a.srcElement?a.toElement:a.fromElement:a.relatedTarget},movementX:function(a){if("movementX"in
|
||||
a)return a.movementX;a!==yd&&(yd&&"mousemove"===a.type?(wd=a.screenX-yd.screenX,xd=a.screenY-yd.screenY):xd=wd=0,yd=a);return wd},movementY:function(a){return"movementY"in a?a.movementY:xd}}),Bd=rd(Ad),Cd=m({},Ad,{dataTransfer:0}),Dd=rd(Cd),Ed=m({},ud,{relatedTarget:0}),Fd=rd(Ed),Gd=m({},sd,{animationName:0,elapsedTime:0,pseudoElement:0}),Hd=rd(Gd),Id=m({},sd,{clipboardData:function(a){return"clipboardData"in a?a.clipboardData:window.clipboardData}}),Jd=rd(Id),Kd=m({},sd,{data:0}),Ld=rd(Kd),Md={Esc:"Escape",
|
||||
Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Nd={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",
|
||||
119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},Od={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Pd(a){var b=this.nativeEvent;return b.getModifierState?b.getModifierState(a):(a=Od[a])?!!b[a]:!1}function zd(){return Pd}
|
||||
var Qd=m({},ud,{key:function(a){if(a.key){var b=Md[a.key]||a.key;if("Unidentified"!==b)return b}return"keypress"===a.type?(a=od(a),13===a?"Enter":String.fromCharCode(a)):"keydown"===a.type||"keyup"===a.type?Nd[a.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:zd,charCode:function(a){return"keypress"===a.type?od(a):0},keyCode:function(a){return"keydown"===a.type||"keyup"===a.type?a.keyCode:0},which:function(a){return"keypress"===
|
||||
a.type?od(a):"keydown"===a.type||"keyup"===a.type?a.keyCode:0}}),Rd=rd(Qd),Sd=m({},Ad,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Td=rd(Sd),Ud=m({},ud,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:zd}),Vd=rd(Ud),Wd=m({},sd,{propertyName:0,elapsedTime:0,pseudoElement:0}),Xd=rd(Wd),Yd=m({},Ad,{deltaX:function(a){return"deltaX"in a?a.deltaX:"wheelDeltaX"in a?-a.wheelDeltaX:0},
|
||||
deltaY:function(a){return"deltaY"in a?a.deltaY:"wheelDeltaY"in a?-a.wheelDeltaY:"wheelDelta"in a?-a.wheelDelta:0},deltaZ:0,deltaMode:0}),Zd=rd(Yd),$d=[9,13,27,32],ae=fa&&"CompositionEvent"in window,be=null;fa&&"documentMode"in document&&(be=document.documentMode);var ce=fa&&"TextEvent"in window&&!be,de=fa&&(!ae||be&&8<be&&11>=be),ee=String.fromCharCode(32),fe=!1;
|
||||
function ge(a,b){switch(a){case "keyup":return-1!==$d.indexOf(b.keyCode);case "keydown":return 229!==b.keyCode;case "keypress":case "mousedown":case "focusout":return!0;default:return!1}}function he(a){a=a.detail;return"object"===typeof a&&"data"in a?a.data:null}var ie=!1;function je(a,b){switch(a){case "compositionend":return he(b);case "keypress":if(32!==b.which)return null;fe=!0;return ee;case "textInput":return a=b.data,a===ee&&fe?null:a;default:return null}}
|
||||
function ke(a,b){if(ie)return"compositionend"===a||!ae&&ge(a,b)?(a=nd(),md=ld=kd=null,ie=!1,a):null;switch(a){case "paste":return null;case "keypress":if(!(b.ctrlKey||b.altKey||b.metaKey)||b.ctrlKey&&b.altKey){if(b.char&&1<b.char.length)return b.char;if(b.which)return String.fromCharCode(b.which)}return null;case "compositionend":return de&&"ko"!==b.locale?null:b.data;default:return null}}
|
||||
var le={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function me(a){var b=a&&a.nodeName&&a.nodeName.toLowerCase();return"input"===b?!!le[a.type]:"textarea"===b?!0:!1}function ne(a,b,c,d){Eb(d);b=oe(b,"onChange");0<b.length&&(c=new td("onChange","change",null,c,d),a.push({event:c,listeners:b}))}var pe=null,qe=null;function re(a){se(a,0)}function te(a){var b=ue(a);if(Wa(b))return a}
|
||||
function ve(a,b){if("change"===a)return b}var we=!1;if(fa){var xe;if(fa){var ye="oninput"in document;if(!ye){var ze=document.createElement("div");ze.setAttribute("oninput","return;");ye="function"===typeof ze.oninput}xe=ye}else xe=!1;we=xe&&(!document.documentMode||9<document.documentMode)}function Ae(){pe&&(pe.detachEvent("onpropertychange",Be),qe=pe=null)}function Be(a){if("value"===a.propertyName&&te(qe)){var b=[];ne(b,qe,a,xb(a));a=re;if(Kb)a(b);else{Kb=!0;try{Gb(a,b)}finally{Kb=!1,Mb()}}}}
|
||||
function Ce(a,b,c){"focusin"===a?(Ae(),pe=b,qe=c,pe.attachEvent("onpropertychange",Be)):"focusout"===a&&Ae()}function De(a){if("selectionchange"===a||"keyup"===a||"keydown"===a)return te(qe)}function Ee(a,b){if("click"===a)return te(b)}function Fe(a,b){if("input"===a||"change"===a)return te(b)}function Ge(a,b){return a===b&&(0!==a||1/a===1/b)||a!==a&&b!==b}var He="function"===typeof Object.is?Object.is:Ge,Ie=Object.prototype.hasOwnProperty;
|
||||
function Je(a,b){if(He(a,b))return!0;if("object"!==typeof a||null===a||"object"!==typeof b||null===b)return!1;var c=Object.keys(a),d=Object.keys(b);if(c.length!==d.length)return!1;for(d=0;d<c.length;d++)if(!Ie.call(b,c[d])||!He(a[c[d]],b[c[d]]))return!1;return!0}function Ke(a){for(;a&&a.firstChild;)a=a.firstChild;return a}
|
||||
function Le(a,b){var c=Ke(a);a=0;for(var d;c;){if(3===c.nodeType){d=a+c.textContent.length;if(a<=b&&d>=b)return{node:c,offset:b-a};a=d}a:{for(;c;){if(c.nextSibling){c=c.nextSibling;break a}c=c.parentNode}c=void 0}c=Ke(c)}}function Me(a,b){return a&&b?a===b?!0:a&&3===a.nodeType?!1:b&&3===b.nodeType?Me(a,b.parentNode):"contains"in a?a.contains(b):a.compareDocumentPosition?!!(a.compareDocumentPosition(b)&16):!1:!1}
|
||||
function Ne(){for(var a=window,b=Xa();b instanceof a.HTMLIFrameElement;){try{var c="string"===typeof b.contentWindow.location.href}catch(d){c=!1}if(c)a=b.contentWindow;else break;b=Xa(a.document)}return b}function Oe(a){var b=a&&a.nodeName&&a.nodeName.toLowerCase();return b&&("input"===b&&("text"===a.type||"search"===a.type||"tel"===a.type||"url"===a.type||"password"===a.type)||"textarea"===b||"true"===a.contentEditable)}
|
||||
var Pe=fa&&"documentMode"in document&&11>=document.documentMode,Qe=null,Re=null,Se=null,Te=!1;
|
||||
function Ue(a,b,c){var d=c.window===c?c.document:9===c.nodeType?c:c.ownerDocument;Te||null==Qe||Qe!==Xa(d)||(d=Qe,"selectionStart"in d&&Oe(d)?d={start:d.selectionStart,end:d.selectionEnd}:(d=(d.ownerDocument&&d.ownerDocument.defaultView||window).getSelection(),d={anchorNode:d.anchorNode,anchorOffset:d.anchorOffset,focusNode:d.focusNode,focusOffset:d.focusOffset}),Se&&Je(Se,d)||(Se=d,d=oe(Re,"onSelect"),0<d.length&&(b=new td("onSelect","select",null,b,c),a.push({event:b,listeners:d}),b.target=Qe)))}
|
||||
Pc("cancel cancel click click close close contextmenu contextMenu copy copy cut cut auxclick auxClick dblclick doubleClick dragend dragEnd dragstart dragStart drop drop focusin focus focusout blur input input invalid invalid keydown keyDown keypress keyPress keyup keyUp mousedown mouseDown mouseup mouseUp paste paste pause pause play play pointercancel pointerCancel pointerdown pointerDown pointerup pointerUp ratechange rateChange reset reset seeked seeked submit submit touchcancel touchCancel touchend touchEnd touchstart touchStart volumechange volumeChange".split(" "),
|
||||
0);Pc("drag drag dragenter dragEnter dragexit dragExit dragleave dragLeave dragover dragOver mousemove mouseMove mouseout mouseOut mouseover mouseOver pointermove pointerMove pointerout pointerOut pointerover pointerOver scroll scroll toggle toggle touchmove touchMove wheel wheel".split(" "),1);Pc(Oc,2);for(var Ve="change selectionchange textInput compositionstart compositionend compositionupdate".split(" "),We=0;We<Ve.length;We++)Nc.set(Ve[We],0);ea("onMouseEnter",["mouseout","mouseover"]);
|
||||
ea("onMouseLeave",["mouseout","mouseover"]);ea("onPointerEnter",["pointerout","pointerover"]);ea("onPointerLeave",["pointerout","pointerover"]);da("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));da("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));da("onBeforeInput",["compositionend","keypress","textInput","paste"]);da("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));
|
||||
da("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));da("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Xe="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),Ye=new Set("cancel close invalid load scroll toggle".split(" ").concat(Xe));
|
||||
function Ze(a,b,c){var d=a.type||"unknown-event";a.currentTarget=c;Yb(d,b,void 0,a);a.currentTarget=null}
|
||||
function se(a,b){b=0!==(b&4);for(var c=0;c<a.length;c++){var d=a[c],e=d.event;d=d.listeners;a:{var f=void 0;if(b)for(var g=d.length-1;0<=g;g--){var h=d[g],k=h.instance,l=h.currentTarget;h=h.listener;if(k!==f&&e.isPropagationStopped())break a;Ze(e,h,l);f=k}else for(g=0;g<d.length;g++){h=d[g];k=h.instance;l=h.currentTarget;h=h.listener;if(k!==f&&e.isPropagationStopped())break a;Ze(e,h,l);f=k}}}if(Ub)throw a=Vb,Ub=!1,Vb=null,a;}
|
||||
function G(a,b){var c=$e(b),d=a+"__bubble";c.has(d)||(af(b,a,2,!1),c.add(d))}var bf="_reactListening"+Math.random().toString(36).slice(2);function cf(a){a[bf]||(a[bf]=!0,ba.forEach(function(b){Ye.has(b)||df(b,!1,a,null);df(b,!0,a,null)}))}
|
||||
function df(a,b,c,d){var e=4<arguments.length&&void 0!==arguments[4]?arguments[4]:0,f=c;"selectionchange"===a&&9!==c.nodeType&&(f=c.ownerDocument);if(null!==d&&!b&&Ye.has(a)){if("scroll"!==a)return;e|=2;f=d}var g=$e(f),h=a+"__"+(b?"capture":"bubble");g.has(h)||(b&&(e|=4),af(f,a,e,b),g.add(h))}
|
||||
function af(a,b,c,d){var e=Nc.get(b);switch(void 0===e?2:e){case 0:e=gd;break;case 1:e=id;break;default:e=hd}c=e.bind(null,b,c,a);e=void 0;!Pb||"touchstart"!==b&&"touchmove"!==b&&"wheel"!==b||(e=!0);d?void 0!==e?a.addEventListener(b,c,{capture:!0,passive:e}):a.addEventListener(b,c,!0):void 0!==e?a.addEventListener(b,c,{passive:e}):a.addEventListener(b,c,!1)}
|
||||
function jd(a,b,c,d,e){var f=d;if(0===(b&1)&&0===(b&2)&&null!==d)a:for(;;){if(null===d)return;var g=d.tag;if(3===g||4===g){var h=d.stateNode.containerInfo;if(h===e||8===h.nodeType&&h.parentNode===e)break;if(4===g)for(g=d.return;null!==g;){var k=g.tag;if(3===k||4===k)if(k=g.stateNode.containerInfo,k===e||8===k.nodeType&&k.parentNode===e)return;g=g.return}for(;null!==h;){g=wc(h);if(null===g)return;k=g.tag;if(5===k||6===k){d=f=g;continue a}h=h.parentNode}}d=d.return}Nb(function(){var d=f,e=xb(c),g=[];
|
||||
a:{var h=Mc.get(a);if(void 0!==h){var k=td,x=a;switch(a){case "keypress":if(0===od(c))break a;case "keydown":case "keyup":k=Rd;break;case "focusin":x="focus";k=Fd;break;case "focusout":x="blur";k=Fd;break;case "beforeblur":case "afterblur":k=Fd;break;case "click":if(2===c.button)break a;case "auxclick":case "dblclick":case "mousedown":case "mousemove":case "mouseup":case "mouseout":case "mouseover":case "contextmenu":k=Bd;break;case "drag":case "dragend":case "dragenter":case "dragexit":case "dragleave":case "dragover":case "dragstart":case "drop":k=
|
||||
Dd;break;case "touchcancel":case "touchend":case "touchmove":case "touchstart":k=Vd;break;case Ic:case Jc:case Kc:k=Hd;break;case Lc:k=Xd;break;case "scroll":k=vd;break;case "wheel":k=Zd;break;case "copy":case "cut":case "paste":k=Jd;break;case "gotpointercapture":case "lostpointercapture":case "pointercancel":case "pointerdown":case "pointermove":case "pointerout":case "pointerover":case "pointerup":k=Td}var w=0!==(b&4),z=!w&&"scroll"===a,u=w?null!==h?h+"Capture":null:h;w=[];for(var t=d,q;null!==
|
||||
t;){q=t;var v=q.stateNode;5===q.tag&&null!==v&&(q=v,null!==u&&(v=Ob(t,u),null!=v&&w.push(ef(t,v,q))));if(z)break;t=t.return}0<w.length&&(h=new k(h,x,null,c,e),g.push({event:h,listeners:w}))}}if(0===(b&7)){a:{h="mouseover"===a||"pointerover"===a;k="mouseout"===a||"pointerout"===a;if(h&&0===(b&16)&&(x=c.relatedTarget||c.fromElement)&&(wc(x)||x[ff]))break a;if(k||h){h=e.window===e?e:(h=e.ownerDocument)?h.defaultView||h.parentWindow:window;if(k){if(x=c.relatedTarget||c.toElement,k=d,x=x?wc(x):null,null!==
|
||||
x&&(z=Zb(x),x!==z||5!==x.tag&&6!==x.tag))x=null}else k=null,x=d;if(k!==x){w=Bd;v="onMouseLeave";u="onMouseEnter";t="mouse";if("pointerout"===a||"pointerover"===a)w=Td,v="onPointerLeave",u="onPointerEnter",t="pointer";z=null==k?h:ue(k);q=null==x?h:ue(x);h=new w(v,t+"leave",k,c,e);h.target=z;h.relatedTarget=q;v=null;wc(e)===d&&(w=new w(u,t+"enter",x,c,e),w.target=q,w.relatedTarget=z,v=w);z=v;if(k&&x)b:{w=k;u=x;t=0;for(q=w;q;q=gf(q))t++;q=0;for(v=u;v;v=gf(v))q++;for(;0<t-q;)w=gf(w),t--;for(;0<q-t;)u=
|
||||
gf(u),q--;for(;t--;){if(w===u||null!==u&&w===u.alternate)break b;w=gf(w);u=gf(u)}w=null}else w=null;null!==k&&hf(g,h,k,w,!1);null!==x&&null!==z&&hf(g,z,x,w,!0)}}}a:{h=d?ue(d):window;k=h.nodeName&&h.nodeName.toLowerCase();if("select"===k||"input"===k&&"file"===h.type)var J=ve;else if(me(h))if(we)J=Fe;else{J=De;var K=Ce}else(k=h.nodeName)&&"input"===k.toLowerCase()&&("checkbox"===h.type||"radio"===h.type)&&(J=Ee);if(J&&(J=J(a,d))){ne(g,J,c,e);break a}K&&K(a,h,d);"focusout"===a&&(K=h._wrapperState)&&
|
||||
K.controlled&&"number"===h.type&&bb(h,"number",h.value)}K=d?ue(d):window;switch(a){case "focusin":if(me(K)||"true"===K.contentEditable)Qe=K,Re=d,Se=null;break;case "focusout":Se=Re=Qe=null;break;case "mousedown":Te=!0;break;case "contextmenu":case "mouseup":case "dragend":Te=!1;Ue(g,c,e);break;case "selectionchange":if(Pe)break;case "keydown":case "keyup":Ue(g,c,e)}var Q;if(ae)b:{switch(a){case "compositionstart":var L="onCompositionStart";break b;case "compositionend":L="onCompositionEnd";break b;
|
||||
case "compositionupdate":L="onCompositionUpdate";break b}L=void 0}else ie?ge(a,c)&&(L="onCompositionEnd"):"keydown"===a&&229===c.keyCode&&(L="onCompositionStart");L&&(de&&"ko"!==c.locale&&(ie||"onCompositionStart"!==L?"onCompositionEnd"===L&&ie&&(Q=nd()):(kd=e,ld="value"in kd?kd.value:kd.textContent,ie=!0)),K=oe(d,L),0<K.length&&(L=new Ld(L,a,null,c,e),g.push({event:L,listeners:K}),Q?L.data=Q:(Q=he(c),null!==Q&&(L.data=Q))));if(Q=ce?je(a,c):ke(a,c))d=oe(d,"onBeforeInput"),0<d.length&&(e=new Ld("onBeforeInput",
|
||||
"beforeinput",null,c,e),g.push({event:e,listeners:d}),e.data=Q)}se(g,b)})}function ef(a,b,c){return{instance:a,listener:b,currentTarget:c}}function oe(a,b){for(var c=b+"Capture",d=[];null!==a;){var e=a,f=e.stateNode;5===e.tag&&null!==f&&(e=f,f=Ob(a,c),null!=f&&d.unshift(ef(a,f,e)),f=Ob(a,b),null!=f&&d.push(ef(a,f,e)));a=a.return}return d}function gf(a){if(null===a)return null;do a=a.return;while(a&&5!==a.tag);return a?a:null}
|
||||
function hf(a,b,c,d,e){for(var f=b._reactName,g=[];null!==c&&c!==d;){var h=c,k=h.alternate,l=h.stateNode;if(null!==k&&k===d)break;5===h.tag&&null!==l&&(h=l,e?(k=Ob(c,f),null!=k&&g.unshift(ef(c,k,h))):e||(k=Ob(c,f),null!=k&&g.push(ef(c,k,h))));c=c.return}0!==g.length&&a.push({event:b,listeners:g})}function jf(){}var kf=null,lf=null;function mf(a,b){switch(a){case "button":case "input":case "select":case "textarea":return!!b.autoFocus}return!1}
|
||||
function nf(a,b){return"textarea"===a||"option"===a||"noscript"===a||"string"===typeof b.children||"number"===typeof b.children||"object"===typeof b.dangerouslySetInnerHTML&&null!==b.dangerouslySetInnerHTML&&null!=b.dangerouslySetInnerHTML.__html}var of="function"===typeof setTimeout?setTimeout:void 0,pf="function"===typeof clearTimeout?clearTimeout:void 0;function qf(a){1===a.nodeType?a.textContent="":9===a.nodeType&&(a=a.body,null!=a&&(a.textContent=""))}
|
||||
function rf(a){for(;null!=a;a=a.nextSibling){var b=a.nodeType;if(1===b||3===b)break}return a}function sf(a){a=a.previousSibling;for(var b=0;a;){if(8===a.nodeType){var c=a.data;if("$"===c||"$!"===c||"$?"===c){if(0===b)return a;b--}else"/$"===c&&b++}a=a.previousSibling}return null}var tf=0;function uf(a){return{$$typeof:Ga,toString:a,valueOf:a}}var vf=Math.random().toString(36).slice(2),wf="__reactFiber$"+vf,xf="__reactProps$"+vf,ff="__reactContainer$"+vf,yf="__reactEvents$"+vf;
|
||||
function wc(a){var b=a[wf];if(b)return b;for(var c=a.parentNode;c;){if(b=c[ff]||c[wf]){c=b.alternate;if(null!==b.child||null!==c&&null!==c.child)for(a=sf(a);null!==a;){if(c=a[wf])return c;a=sf(a)}return b}a=c;c=a.parentNode}return null}function Cb(a){a=a[wf]||a[ff];return!a||5!==a.tag&&6!==a.tag&&13!==a.tag&&3!==a.tag?null:a}function ue(a){if(5===a.tag||6===a.tag)return a.stateNode;throw Error(y(33));}function Db(a){return a[xf]||null}
|
||||
function $e(a){var b=a[yf];void 0===b&&(b=a[yf]=new Set);return b}var zf=[],Af=-1;function Bf(a){return{current:a}}function H(a){0>Af||(a.current=zf[Af],zf[Af]=null,Af--)}function I(a,b){Af++;zf[Af]=a.current;a.current=b}var Cf={},M=Bf(Cf),N=Bf(!1),Df=Cf;
|
||||
function Ef(a,b){var c=a.type.contextTypes;if(!c)return Cf;var d=a.stateNode;if(d&&d.__reactInternalMemoizedUnmaskedChildContext===b)return d.__reactInternalMemoizedMaskedChildContext;var e={},f;for(f in c)e[f]=b[f];d&&(a=a.stateNode,a.__reactInternalMemoizedUnmaskedChildContext=b,a.__reactInternalMemoizedMaskedChildContext=e);return e}function Ff(a){a=a.childContextTypes;return null!==a&&void 0!==a}function Gf(){H(N);H(M)}function Hf(a,b,c){if(M.current!==Cf)throw Error(y(168));I(M,b);I(N,c)}
|
||||
function If(a,b,c){var d=a.stateNode;a=b.childContextTypes;if("function"!==typeof d.getChildContext)return c;d=d.getChildContext();for(var e in d)if(!(e in a))throw Error(y(108,Ra(b)||"Unknown",e));return m({},c,d)}function Jf(a){a=(a=a.stateNode)&&a.__reactInternalMemoizedMergedChildContext||Cf;Df=M.current;I(M,a);I(N,N.current);return!0}function Kf(a,b,c){var d=a.stateNode;if(!d)throw Error(y(169));c?(a=If(a,b,Df),d.__reactInternalMemoizedMergedChildContext=a,H(N),H(M),I(M,a)):H(N);I(N,c)}
|
||||
var Lf=null,Mf=null,Nf=r.unstable_runWithPriority,Of=r.unstable_scheduleCallback,Pf=r.unstable_cancelCallback,Qf=r.unstable_shouldYield,Rf=r.unstable_requestPaint,Sf=r.unstable_now,Tf=r.unstable_getCurrentPriorityLevel,Uf=r.unstable_ImmediatePriority,Vf=r.unstable_UserBlockingPriority,Wf=r.unstable_NormalPriority,Xf=r.unstable_LowPriority,Yf=r.unstable_IdlePriority,Zf={},$f=void 0!==Rf?Rf:function(){},ag=null,bg=null,cg=!1,dg=Sf(),O=1E4>dg?Sf:function(){return Sf()-dg};
|
||||
function eg(){switch(Tf()){case Uf:return 99;case Vf:return 98;case Wf:return 97;case Xf:return 96;case Yf:return 95;default:throw Error(y(332));}}function fg(a){switch(a){case 99:return Uf;case 98:return Vf;case 97:return Wf;case 96:return Xf;case 95:return Yf;default:throw Error(y(332));}}function gg(a,b){a=fg(a);return Nf(a,b)}function hg(a,b,c){a=fg(a);return Of(a,b,c)}function ig(){if(null!==bg){var a=bg;bg=null;Pf(a)}jg()}
|
||||
function jg(){if(!cg&&null!==ag){cg=!0;var a=0;try{var b=ag;gg(99,function(){for(;a<b.length;a++){var c=b[a];do c=c(!0);while(null!==c)}});ag=null}catch(c){throw null!==ag&&(ag=ag.slice(a+1)),Of(Uf,ig),c;}finally{cg=!1}}}var kg=ra.ReactCurrentBatchConfig;function lg(a,b){if(a&&a.defaultProps){b=m({},b);a=a.defaultProps;for(var c in a)void 0===b[c]&&(b[c]=a[c]);return b}return b}var mg=Bf(null),ng=null,og=null,pg=null;function qg(){pg=og=ng=null}
|
||||
function rg(a){var b=mg.current;H(mg);a.type._context._currentValue=b}function sg(a,b){for(;null!==a;){var c=a.alternate;if((a.childLanes&b)===b)if(null===c||(c.childLanes&b)===b)break;else c.childLanes|=b;else a.childLanes|=b,null!==c&&(c.childLanes|=b);a=a.return}}function tg(a,b){ng=a;pg=og=null;a=a.dependencies;null!==a&&null!==a.firstContext&&(0!==(a.lanes&b)&&(ug=!0),a.firstContext=null)}
|
||||
function vg(a,b){if(pg!==a&&!1!==b&&0!==b){if("number"!==typeof b||1073741823===b)pg=a,b=1073741823;b={context:a,observedBits:b,next:null};if(null===og){if(null===ng)throw Error(y(308));og=b;ng.dependencies={lanes:0,firstContext:b,responders:null}}else og=og.next=b}return a._currentValue}var wg=!1;function xg(a){a.updateQueue={baseState:a.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null},effects:null}}
|
||||
function yg(a,b){a=a.updateQueue;b.updateQueue===a&&(b.updateQueue={baseState:a.baseState,firstBaseUpdate:a.firstBaseUpdate,lastBaseUpdate:a.lastBaseUpdate,shared:a.shared,effects:a.effects})}function zg(a,b){return{eventTime:a,lane:b,tag:0,payload:null,callback:null,next:null}}function Ag(a,b){a=a.updateQueue;if(null!==a){a=a.shared;var c=a.pending;null===c?b.next=b:(b.next=c.next,c.next=b);a.pending=b}}
|
||||
function Bg(a,b){var c=a.updateQueue,d=a.alternate;if(null!==d&&(d=d.updateQueue,c===d)){var e=null,f=null;c=c.firstBaseUpdate;if(null!==c){do{var g={eventTime:c.eventTime,lane:c.lane,tag:c.tag,payload:c.payload,callback:c.callback,next:null};null===f?e=f=g:f=f.next=g;c=c.next}while(null!==c);null===f?e=f=b:f=f.next=b}else e=f=b;c={baseState:d.baseState,firstBaseUpdate:e,lastBaseUpdate:f,shared:d.shared,effects:d.effects};a.updateQueue=c;return}a=c.lastBaseUpdate;null===a?c.firstBaseUpdate=b:a.next=
|
||||
b;c.lastBaseUpdate=b}
|
||||
function Cg(a,b,c,d){var e=a.updateQueue;wg=!1;var f=e.firstBaseUpdate,g=e.lastBaseUpdate,h=e.shared.pending;if(null!==h){e.shared.pending=null;var k=h,l=k.next;k.next=null;null===g?f=l:g.next=l;g=k;var n=a.alternate;if(null!==n){n=n.updateQueue;var A=n.lastBaseUpdate;A!==g&&(null===A?n.firstBaseUpdate=l:A.next=l,n.lastBaseUpdate=k)}}if(null!==f){A=e.baseState;g=0;n=l=k=null;do{h=f.lane;var p=f.eventTime;if((d&h)===h){null!==n&&(n=n.next={eventTime:p,lane:0,tag:f.tag,payload:f.payload,callback:f.callback,
|
||||
next:null});a:{var C=a,x=f;h=b;p=c;switch(x.tag){case 1:C=x.payload;if("function"===typeof C){A=C.call(p,A,h);break a}A=C;break a;case 3:C.flags=C.flags&-4097|64;case 0:C=x.payload;h="function"===typeof C?C.call(p,A,h):C;if(null===h||void 0===h)break a;A=m({},A,h);break a;case 2:wg=!0}}null!==f.callback&&(a.flags|=32,h=e.effects,null===h?e.effects=[f]:h.push(f))}else p={eventTime:p,lane:h,tag:f.tag,payload:f.payload,callback:f.callback,next:null},null===n?(l=n=p,k=A):n=n.next=p,g|=h;f=f.next;if(null===
|
||||
f)if(h=e.shared.pending,null===h)break;else f=h.next,h.next=null,e.lastBaseUpdate=h,e.shared.pending=null}while(1);null===n&&(k=A);e.baseState=k;e.firstBaseUpdate=l;e.lastBaseUpdate=n;Dg|=g;a.lanes=g;a.memoizedState=A}}function Eg(a,b,c){a=b.effects;b.effects=null;if(null!==a)for(b=0;b<a.length;b++){var d=a[b],e=d.callback;if(null!==e){d.callback=null;d=c;if("function"!==typeof e)throw Error(y(191,e));e.call(d)}}}var Fg=(new aa.Component).refs;
|
||||
function Gg(a,b,c,d){b=a.memoizedState;c=c(d,b);c=null===c||void 0===c?b:m({},b,c);a.memoizedState=c;0===a.lanes&&(a.updateQueue.baseState=c)}
|
||||
var Kg={isMounted:function(a){return(a=a._reactInternals)?Zb(a)===a:!1},enqueueSetState:function(a,b,c){a=a._reactInternals;var d=Hg(),e=Ig(a),f=zg(d,e);f.payload=b;void 0!==c&&null!==c&&(f.callback=c);Ag(a,f);Jg(a,e,d)},enqueueReplaceState:function(a,b,c){a=a._reactInternals;var d=Hg(),e=Ig(a),f=zg(d,e);f.tag=1;f.payload=b;void 0!==c&&null!==c&&(f.callback=c);Ag(a,f);Jg(a,e,d)},enqueueForceUpdate:function(a,b){a=a._reactInternals;var c=Hg(),d=Ig(a),e=zg(c,d);e.tag=2;void 0!==b&&null!==b&&(e.callback=
|
||||
b);Ag(a,e);Jg(a,d,c)}};function Lg(a,b,c,d,e,f,g){a=a.stateNode;return"function"===typeof a.shouldComponentUpdate?a.shouldComponentUpdate(d,f,g):b.prototype&&b.prototype.isPureReactComponent?!Je(c,d)||!Je(e,f):!0}
|
||||
function Mg(a,b,c){var d=!1,e=Cf;var f=b.contextType;"object"===typeof f&&null!==f?f=vg(f):(e=Ff(b)?Df:M.current,d=b.contextTypes,f=(d=null!==d&&void 0!==d)?Ef(a,e):Cf);b=new b(c,f);a.memoizedState=null!==b.state&&void 0!==b.state?b.state:null;b.updater=Kg;a.stateNode=b;b._reactInternals=a;d&&(a=a.stateNode,a.__reactInternalMemoizedUnmaskedChildContext=e,a.__reactInternalMemoizedMaskedChildContext=f);return b}
|
||||
function Ng(a,b,c,d){a=b.state;"function"===typeof b.componentWillReceiveProps&&b.componentWillReceiveProps(c,d);"function"===typeof b.UNSAFE_componentWillReceiveProps&&b.UNSAFE_componentWillReceiveProps(c,d);b.state!==a&&Kg.enqueueReplaceState(b,b.state,null)}
|
||||
function Og(a,b,c,d){var e=a.stateNode;e.props=c;e.state=a.memoizedState;e.refs=Fg;xg(a);var f=b.contextType;"object"===typeof f&&null!==f?e.context=vg(f):(f=Ff(b)?Df:M.current,e.context=Ef(a,f));Cg(a,c,e,d);e.state=a.memoizedState;f=b.getDerivedStateFromProps;"function"===typeof f&&(Gg(a,b,f,c),e.state=a.memoizedState);"function"===typeof b.getDerivedStateFromProps||"function"===typeof e.getSnapshotBeforeUpdate||"function"!==typeof e.UNSAFE_componentWillMount&&"function"!==typeof e.componentWillMount||
|
||||
(b=e.state,"function"===typeof e.componentWillMount&&e.componentWillMount(),"function"===typeof e.UNSAFE_componentWillMount&&e.UNSAFE_componentWillMount(),b!==e.state&&Kg.enqueueReplaceState(e,e.state,null),Cg(a,c,e,d),e.state=a.memoizedState);"function"===typeof e.componentDidMount&&(a.flags|=4)}var Pg=Array.isArray;
|
||||
function Qg(a,b,c){a=c.ref;if(null!==a&&"function"!==typeof a&&"object"!==typeof a){if(c._owner){c=c._owner;if(c){if(1!==c.tag)throw Error(y(309));var d=c.stateNode}if(!d)throw Error(y(147,a));var e=""+a;if(null!==b&&null!==b.ref&&"function"===typeof b.ref&&b.ref._stringRef===e)return b.ref;b=function(a){var b=d.refs;b===Fg&&(b=d.refs={});null===a?delete b[e]:b[e]=a};b._stringRef=e;return b}if("string"!==typeof a)throw Error(y(284));if(!c._owner)throw Error(y(290,a));}return a}
|
||||
function Rg(a,b){if("textarea"!==a.type)throw Error(y(31,"[object Object]"===Object.prototype.toString.call(b)?"object with keys {"+Object.keys(b).join(", ")+"}":b));}
|
||||
function Sg(a){function b(b,c){if(a){var d=b.lastEffect;null!==d?(d.nextEffect=c,b.lastEffect=c):b.firstEffect=b.lastEffect=c;c.nextEffect=null;c.flags=8}}function c(c,d){if(!a)return null;for(;null!==d;)b(c,d),d=d.sibling;return null}function d(a,b){for(a=new Map;null!==b;)null!==b.key?a.set(b.key,b):a.set(b.index,b),b=b.sibling;return a}function e(a,b){a=Tg(a,b);a.index=0;a.sibling=null;return a}function f(b,c,d){b.index=d;if(!a)return c;d=b.alternate;if(null!==d)return d=d.index,d<c?(b.flags=2,
|
||||
c):d;b.flags=2;return c}function g(b){a&&null===b.alternate&&(b.flags=2);return b}function h(a,b,c,d){if(null===b||6!==b.tag)return b=Ug(c,a.mode,d),b.return=a,b;b=e(b,c);b.return=a;return b}function k(a,b,c,d){if(null!==b&&b.elementType===c.type)return d=e(b,c.props),d.ref=Qg(a,b,c),d.return=a,d;d=Vg(c.type,c.key,c.props,null,a.mode,d);d.ref=Qg(a,b,c);d.return=a;return d}function l(a,b,c,d){if(null===b||4!==b.tag||b.stateNode.containerInfo!==c.containerInfo||b.stateNode.implementation!==c.implementation)return b=
|
||||
Wg(c,a.mode,d),b.return=a,b;b=e(b,c.children||[]);b.return=a;return b}function n(a,b,c,d,f){if(null===b||7!==b.tag)return b=Xg(c,a.mode,d,f),b.return=a,b;b=e(b,c);b.return=a;return b}function A(a,b,c){if("string"===typeof b||"number"===typeof b)return b=Ug(""+b,a.mode,c),b.return=a,b;if("object"===typeof b&&null!==b){switch(b.$$typeof){case sa:return c=Vg(b.type,b.key,b.props,null,a.mode,c),c.ref=Qg(a,null,b),c.return=a,c;case ta:return b=Wg(b,a.mode,c),b.return=a,b}if(Pg(b)||La(b))return b=Xg(b,
|
||||
a.mode,c,null),b.return=a,b;Rg(a,b)}return null}function p(a,b,c,d){var e=null!==b?b.key:null;if("string"===typeof c||"number"===typeof c)return null!==e?null:h(a,b,""+c,d);if("object"===typeof c&&null!==c){switch(c.$$typeof){case sa:return c.key===e?c.type===ua?n(a,b,c.props.children,d,e):k(a,b,c,d):null;case ta:return c.key===e?l(a,b,c,d):null}if(Pg(c)||La(c))return null!==e?null:n(a,b,c,d,null);Rg(a,c)}return null}function C(a,b,c,d,e){if("string"===typeof d||"number"===typeof d)return a=a.get(c)||
|
||||
null,h(b,a,""+d,e);if("object"===typeof d&&null!==d){switch(d.$$typeof){case sa:return a=a.get(null===d.key?c:d.key)||null,d.type===ua?n(b,a,d.props.children,e,d.key):k(b,a,d,e);case ta:return a=a.get(null===d.key?c:d.key)||null,l(b,a,d,e)}if(Pg(d)||La(d))return a=a.get(c)||null,n(b,a,d,e,null);Rg(b,d)}return null}function x(e,g,h,k){for(var l=null,t=null,u=g,z=g=0,q=null;null!==u&&z<h.length;z++){u.index>z?(q=u,u=null):q=u.sibling;var n=p(e,u,h[z],k);if(null===n){null===u&&(u=q);break}a&&u&&null===
|
||||
n.alternate&&b(e,u);g=f(n,g,z);null===t?l=n:t.sibling=n;t=n;u=q}if(z===h.length)return c(e,u),l;if(null===u){for(;z<h.length;z++)u=A(e,h[z],k),null!==u&&(g=f(u,g,z),null===t?l=u:t.sibling=u,t=u);return l}for(u=d(e,u);z<h.length;z++)q=C(u,e,z,h[z],k),null!==q&&(a&&null!==q.alternate&&u.delete(null===q.key?z:q.key),g=f(q,g,z),null===t?l=q:t.sibling=q,t=q);a&&u.forEach(function(a){return b(e,a)});return l}function w(e,g,h,k){var l=La(h);if("function"!==typeof l)throw Error(y(150));h=l.call(h);if(null==
|
||||
h)throw Error(y(151));for(var t=l=null,u=g,z=g=0,q=null,n=h.next();null!==u&&!n.done;z++,n=h.next()){u.index>z?(q=u,u=null):q=u.sibling;var w=p(e,u,n.value,k);if(null===w){null===u&&(u=q);break}a&&u&&null===w.alternate&&b(e,u);g=f(w,g,z);null===t?l=w:t.sibling=w;t=w;u=q}if(n.done)return c(e,u),l;if(null===u){for(;!n.done;z++,n=h.next())n=A(e,n.value,k),null!==n&&(g=f(n,g,z),null===t?l=n:t.sibling=n,t=n);return l}for(u=d(e,u);!n.done;z++,n=h.next())n=C(u,e,z,n.value,k),null!==n&&(a&&null!==n.alternate&&
|
||||
u.delete(null===n.key?z:n.key),g=f(n,g,z),null===t?l=n:t.sibling=n,t=n);a&&u.forEach(function(a){return b(e,a)});return l}return function(a,d,f,h){var k="object"===typeof f&&null!==f&&f.type===ua&&null===f.key;k&&(f=f.props.children);var l="object"===typeof f&&null!==f;if(l)switch(f.$$typeof){case sa:a:{l=f.key;for(k=d;null!==k;){if(k.key===l){switch(k.tag){case 7:if(f.type===ua){c(a,k.sibling);d=e(k,f.props.children);d.return=a;a=d;break a}break;default:if(k.elementType===f.type){c(a,k.sibling);
|
||||
d=e(k,f.props);d.ref=Qg(a,k,f);d.return=a;a=d;break a}}c(a,k);break}else b(a,k);k=k.sibling}f.type===ua?(d=Xg(f.props.children,a.mode,h,f.key),d.return=a,a=d):(h=Vg(f.type,f.key,f.props,null,a.mode,h),h.ref=Qg(a,d,f),h.return=a,a=h)}return g(a);case ta:a:{for(k=f.key;null!==d;){if(d.key===k)if(4===d.tag&&d.stateNode.containerInfo===f.containerInfo&&d.stateNode.implementation===f.implementation){c(a,d.sibling);d=e(d,f.children||[]);d.return=a;a=d;break a}else{c(a,d);break}else b(a,d);d=d.sibling}d=
|
||||
Wg(f,a.mode,h);d.return=a;a=d}return g(a)}if("string"===typeof f||"number"===typeof f)return f=""+f,null!==d&&6===d.tag?(c(a,d.sibling),d=e(d,f),d.return=a,a=d):(c(a,d),d=Ug(f,a.mode,h),d.return=a,a=d),g(a);if(Pg(f))return x(a,d,f,h);if(La(f))return w(a,d,f,h);l&&Rg(a,f);if("undefined"===typeof f&&!k)switch(a.tag){case 1:case 22:case 0:case 11:case 15:throw Error(y(152,Ra(a.type)||"Component"));}return c(a,d)}}var Yg=Sg(!0),Zg=Sg(!1),$g={},ah=Bf($g),bh=Bf($g),ch=Bf($g);
|
||||
function dh(a){if(a===$g)throw Error(y(174));return a}function eh(a,b){I(ch,b);I(bh,a);I(ah,$g);a=b.nodeType;switch(a){case 9:case 11:b=(b=b.documentElement)?b.namespaceURI:mb(null,"");break;default:a=8===a?b.parentNode:b,b=a.namespaceURI||null,a=a.tagName,b=mb(b,a)}H(ah);I(ah,b)}function fh(){H(ah);H(bh);H(ch)}function gh(a){dh(ch.current);var b=dh(ah.current);var c=mb(b,a.type);b!==c&&(I(bh,a),I(ah,c))}function hh(a){bh.current===a&&(H(ah),H(bh))}var P=Bf(0);
|
||||
function ih(a){for(var b=a;null!==b;){if(13===b.tag){var c=b.memoizedState;if(null!==c&&(c=c.dehydrated,null===c||"$?"===c.data||"$!"===c.data))return b}else if(19===b.tag&&void 0!==b.memoizedProps.revealOrder){if(0!==(b.flags&64))return b}else if(null!==b.child){b.child.return=b;b=b.child;continue}if(b===a)break;for(;null===b.sibling;){if(null===b.return||b.return===a)return null;b=b.return}b.sibling.return=b.return;b=b.sibling}return null}var jh=null,kh=null,lh=!1;
|
||||
function mh(a,b){var c=nh(5,null,null,0);c.elementType="DELETED";c.type="DELETED";c.stateNode=b;c.return=a;c.flags=8;null!==a.lastEffect?(a.lastEffect.nextEffect=c,a.lastEffect=c):a.firstEffect=a.lastEffect=c}function oh(a,b){switch(a.tag){case 5:var c=a.type;b=1!==b.nodeType||c.toLowerCase()!==b.nodeName.toLowerCase()?null:b;return null!==b?(a.stateNode=b,!0):!1;case 6:return b=""===a.pendingProps||3!==b.nodeType?null:b,null!==b?(a.stateNode=b,!0):!1;case 13:return!1;default:return!1}}
|
||||
function ph(a){if(lh){var b=kh;if(b){var c=b;if(!oh(a,b)){b=rf(c.nextSibling);if(!b||!oh(a,b)){a.flags=a.flags&-1025|2;lh=!1;jh=a;return}mh(jh,c)}jh=a;kh=rf(b.firstChild)}else a.flags=a.flags&-1025|2,lh=!1,jh=a}}function qh(a){for(a=a.return;null!==a&&5!==a.tag&&3!==a.tag&&13!==a.tag;)a=a.return;jh=a}
|
||||
function rh(a){if(a!==jh)return!1;if(!lh)return qh(a),lh=!0,!1;var b=a.type;if(5!==a.tag||"head"!==b&&"body"!==b&&!nf(b,a.memoizedProps))for(b=kh;b;)mh(a,b),b=rf(b.nextSibling);qh(a);if(13===a.tag){a=a.memoizedState;a=null!==a?a.dehydrated:null;if(!a)throw Error(y(317));a:{a=a.nextSibling;for(b=0;a;){if(8===a.nodeType){var c=a.data;if("/$"===c){if(0===b){kh=rf(a.nextSibling);break a}b--}else"$"!==c&&"$!"!==c&&"$?"!==c||b++}a=a.nextSibling}kh=null}}else kh=jh?rf(a.stateNode.nextSibling):null;return!0}
|
||||
function sh(){kh=jh=null;lh=!1}var th=[];function uh(){for(var a=0;a<th.length;a++)th[a]._workInProgressVersionPrimary=null;th.length=0}var vh=ra.ReactCurrentDispatcher,wh=ra.ReactCurrentBatchConfig,xh=0,R=null,S=null,T=null,yh=!1,zh=!1;function Ah(){throw Error(y(321));}function Bh(a,b){if(null===b)return!1;for(var c=0;c<b.length&&c<a.length;c++)if(!He(a[c],b[c]))return!1;return!0}
|
||||
function Ch(a,b,c,d,e,f){xh=f;R=b;b.memoizedState=null;b.updateQueue=null;b.lanes=0;vh.current=null===a||null===a.memoizedState?Dh:Eh;a=c(d,e);if(zh){f=0;do{zh=!1;if(!(25>f))throw Error(y(301));f+=1;T=S=null;b.updateQueue=null;vh.current=Fh;a=c(d,e)}while(zh)}vh.current=Gh;b=null!==S&&null!==S.next;xh=0;T=S=R=null;yh=!1;if(b)throw Error(y(300));return a}function Hh(){var a={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};null===T?R.memoizedState=T=a:T=T.next=a;return T}
|
||||
function Ih(){if(null===S){var a=R.alternate;a=null!==a?a.memoizedState:null}else a=S.next;var b=null===T?R.memoizedState:T.next;if(null!==b)T=b,S=a;else{if(null===a)throw Error(y(310));S=a;a={memoizedState:S.memoizedState,baseState:S.baseState,baseQueue:S.baseQueue,queue:S.queue,next:null};null===T?R.memoizedState=T=a:T=T.next=a}return T}function Jh(a,b){return"function"===typeof b?b(a):b}
|
||||
function Kh(a){var b=Ih(),c=b.queue;if(null===c)throw Error(y(311));c.lastRenderedReducer=a;var d=S,e=d.baseQueue,f=c.pending;if(null!==f){if(null!==e){var g=e.next;e.next=f.next;f.next=g}d.baseQueue=e=f;c.pending=null}if(null!==e){e=e.next;d=d.baseState;var h=g=f=null,k=e;do{var l=k.lane;if((xh&l)===l)null!==h&&(h=h.next={lane:0,action:k.action,eagerReducer:k.eagerReducer,eagerState:k.eagerState,next:null}),d=k.eagerReducer===a?k.eagerState:a(d,k.action);else{var n={lane:l,action:k.action,eagerReducer:k.eagerReducer,
|
||||
eagerState:k.eagerState,next:null};null===h?(g=h=n,f=d):h=h.next=n;R.lanes|=l;Dg|=l}k=k.next}while(null!==k&&k!==e);null===h?f=d:h.next=g;He(d,b.memoizedState)||(ug=!0);b.memoizedState=d;b.baseState=f;b.baseQueue=h;c.lastRenderedState=d}return[b.memoizedState,c.dispatch]}
|
||||
function Lh(a){var b=Ih(),c=b.queue;if(null===c)throw Error(y(311));c.lastRenderedReducer=a;var d=c.dispatch,e=c.pending,f=b.memoizedState;if(null!==e){c.pending=null;var g=e=e.next;do f=a(f,g.action),g=g.next;while(g!==e);He(f,b.memoizedState)||(ug=!0);b.memoizedState=f;null===b.baseQueue&&(b.baseState=f);c.lastRenderedState=f}return[f,d]}
|
||||
function Mh(a,b,c){var d=b._getVersion;d=d(b._source);var e=b._workInProgressVersionPrimary;if(null!==e)a=e===d;else if(a=a.mutableReadLanes,a=(xh&a)===a)b._workInProgressVersionPrimary=d,th.push(b);if(a)return c(b._source);th.push(b);throw Error(y(350));}
|
||||
function Nh(a,b,c,d){var e=U;if(null===e)throw Error(y(349));var f=b._getVersion,g=f(b._source),h=vh.current,k=h.useState(function(){return Mh(e,b,c)}),l=k[1],n=k[0];k=T;var A=a.memoizedState,p=A.refs,C=p.getSnapshot,x=A.source;A=A.subscribe;var w=R;a.memoizedState={refs:p,source:b,subscribe:d};h.useEffect(function(){p.getSnapshot=c;p.setSnapshot=l;var a=f(b._source);if(!He(g,a)){a=c(b._source);He(n,a)||(l(a),a=Ig(w),e.mutableReadLanes|=a&e.pendingLanes);a=e.mutableReadLanes;e.entangledLanes|=a;for(var d=
|
||||
e.entanglements,h=a;0<h;){var k=31-Vc(h),v=1<<k;d[k]|=a;h&=~v}}},[c,b,d]);h.useEffect(function(){return d(b._source,function(){var a=p.getSnapshot,c=p.setSnapshot;try{c(a(b._source));var d=Ig(w);e.mutableReadLanes|=d&e.pendingLanes}catch(q){c(function(){throw q;})}})},[b,d]);He(C,c)&&He(x,b)&&He(A,d)||(a={pending:null,dispatch:null,lastRenderedReducer:Jh,lastRenderedState:n},a.dispatch=l=Oh.bind(null,R,a),k.queue=a,k.baseQueue=null,n=Mh(e,b,c),k.memoizedState=k.baseState=n);return n}
|
||||
function Ph(a,b,c){var d=Ih();return Nh(d,a,b,c)}function Qh(a){var b=Hh();"function"===typeof a&&(a=a());b.memoizedState=b.baseState=a;a=b.queue={pending:null,dispatch:null,lastRenderedReducer:Jh,lastRenderedState:a};a=a.dispatch=Oh.bind(null,R,a);return[b.memoizedState,a]}
|
||||
function Rh(a,b,c,d){a={tag:a,create:b,destroy:c,deps:d,next:null};b=R.updateQueue;null===b?(b={lastEffect:null},R.updateQueue=b,b.lastEffect=a.next=a):(c=b.lastEffect,null===c?b.lastEffect=a.next=a:(d=c.next,c.next=a,a.next=d,b.lastEffect=a));return a}function Sh(a){var b=Hh();a={current:a};return b.memoizedState=a}function Th(){return Ih().memoizedState}function Uh(a,b,c,d){var e=Hh();R.flags|=a;e.memoizedState=Rh(1|b,c,void 0,void 0===d?null:d)}
|
||||
function Vh(a,b,c,d){var e=Ih();d=void 0===d?null:d;var f=void 0;if(null!==S){var g=S.memoizedState;f=g.destroy;if(null!==d&&Bh(d,g.deps)){Rh(b,c,f,d);return}}R.flags|=a;e.memoizedState=Rh(1|b,c,f,d)}function Wh(a,b){return Uh(516,4,a,b)}function Xh(a,b){return Vh(516,4,a,b)}function Yh(a,b){return Vh(4,2,a,b)}function Zh(a,b){if("function"===typeof b)return a=a(),b(a),function(){b(null)};if(null!==b&&void 0!==b)return a=a(),b.current=a,function(){b.current=null}}
|
||||
function $h(a,b,c){c=null!==c&&void 0!==c?c.concat([a]):null;return Vh(4,2,Zh.bind(null,b,a),c)}function ai(){}function bi(a,b){var c=Ih();b=void 0===b?null:b;var d=c.memoizedState;if(null!==d&&null!==b&&Bh(b,d[1]))return d[0];c.memoizedState=[a,b];return a}function ci(a,b){var c=Ih();b=void 0===b?null:b;var d=c.memoizedState;if(null!==d&&null!==b&&Bh(b,d[1]))return d[0];a=a();c.memoizedState=[a,b];return a}
|
||||
function di(a,b){var c=eg();gg(98>c?98:c,function(){a(!0)});gg(97<c?97:c,function(){var c=wh.transition;wh.transition=1;try{a(!1),b()}finally{wh.transition=c}})}
|
||||
function Oh(a,b,c){var d=Hg(),e=Ig(a),f={lane:e,action:c,eagerReducer:null,eagerState:null,next:null},g=b.pending;null===g?f.next=f:(f.next=g.next,g.next=f);b.pending=f;g=a.alternate;if(a===R||null!==g&&g===R)zh=yh=!0;else{if(0===a.lanes&&(null===g||0===g.lanes)&&(g=b.lastRenderedReducer,null!==g))try{var h=b.lastRenderedState,k=g(h,c);f.eagerReducer=g;f.eagerState=k;if(He(k,h))return}catch(l){}finally{}Jg(a,e,d)}}
|
||||
var Gh={readContext:vg,useCallback:Ah,useContext:Ah,useEffect:Ah,useImperativeHandle:Ah,useLayoutEffect:Ah,useMemo:Ah,useReducer:Ah,useRef:Ah,useState:Ah,useDebugValue:Ah,useDeferredValue:Ah,useTransition:Ah,useMutableSource:Ah,useOpaqueIdentifier:Ah,unstable_isNewReconciler:!1},Dh={readContext:vg,useCallback:function(a,b){Hh().memoizedState=[a,void 0===b?null:b];return a},useContext:vg,useEffect:Wh,useImperativeHandle:function(a,b,c){c=null!==c&&void 0!==c?c.concat([a]):null;return Uh(4,2,Zh.bind(null,
|
||||
b,a),c)},useLayoutEffect:function(a,b){return Uh(4,2,a,b)},useMemo:function(a,b){var c=Hh();b=void 0===b?null:b;a=a();c.memoizedState=[a,b];return a},useReducer:function(a,b,c){var d=Hh();b=void 0!==c?c(b):b;d.memoizedState=d.baseState=b;a=d.queue={pending:null,dispatch:null,lastRenderedReducer:a,lastRenderedState:b};a=a.dispatch=Oh.bind(null,R,a);return[d.memoizedState,a]},useRef:Sh,useState:Qh,useDebugValue:ai,useDeferredValue:function(a){var b=Qh(a),c=b[0],d=b[1];Wh(function(){var b=wh.transition;
|
||||
wh.transition=1;try{d(a)}finally{wh.transition=b}},[a]);return c},useTransition:function(){var a=Qh(!1),b=a[0];a=di.bind(null,a[1]);Sh(a);return[a,b]},useMutableSource:function(a,b,c){var d=Hh();d.memoizedState={refs:{getSnapshot:b,setSnapshot:null},source:a,subscribe:c};return Nh(d,a,b,c)},useOpaqueIdentifier:function(){if(lh){var a=!1,b=uf(function(){a||(a=!0,c("r:"+(tf++).toString(36)));throw Error(y(355));}),c=Qh(b)[1];0===(R.mode&2)&&(R.flags|=516,Rh(5,function(){c("r:"+(tf++).toString(36))},
|
||||
void 0,null));return b}b="r:"+(tf++).toString(36);Qh(b);return b},unstable_isNewReconciler:!1},Eh={readContext:vg,useCallback:bi,useContext:vg,useEffect:Xh,useImperativeHandle:$h,useLayoutEffect:Yh,useMemo:ci,useReducer:Kh,useRef:Th,useState:function(){return Kh(Jh)},useDebugValue:ai,useDeferredValue:function(a){var b=Kh(Jh),c=b[0],d=b[1];Xh(function(){var b=wh.transition;wh.transition=1;try{d(a)}finally{wh.transition=b}},[a]);return c},useTransition:function(){var a=Kh(Jh)[0];return[Th().current,
|
||||
a]},useMutableSource:Ph,useOpaqueIdentifier:function(){return Kh(Jh)[0]},unstable_isNewReconciler:!1},Fh={readContext:vg,useCallback:bi,useContext:vg,useEffect:Xh,useImperativeHandle:$h,useLayoutEffect:Yh,useMemo:ci,useReducer:Lh,useRef:Th,useState:function(){return Lh(Jh)},useDebugValue:ai,useDeferredValue:function(a){var b=Lh(Jh),c=b[0],d=b[1];Xh(function(){var b=wh.transition;wh.transition=1;try{d(a)}finally{wh.transition=b}},[a]);return c},useTransition:function(){var a=Lh(Jh)[0];return[Th().current,
|
||||
a]},useMutableSource:Ph,useOpaqueIdentifier:function(){return Lh(Jh)[0]},unstable_isNewReconciler:!1},ei=ra.ReactCurrentOwner,ug=!1;function fi(a,b,c,d){b.child=null===a?Zg(b,null,c,d):Yg(b,a.child,c,d)}function gi(a,b,c,d,e){c=c.render;var f=b.ref;tg(b,e);d=Ch(a,b,c,d,f,e);if(null!==a&&!ug)return b.updateQueue=a.updateQueue,b.flags&=-517,a.lanes&=~e,hi(a,b,e);b.flags|=1;fi(a,b,d,e);return b.child}
|
||||
function ii(a,b,c,d,e,f){if(null===a){var g=c.type;if("function"===typeof g&&!ji(g)&&void 0===g.defaultProps&&null===c.compare&&void 0===c.defaultProps)return b.tag=15,b.type=g,ki(a,b,g,d,e,f);a=Vg(c.type,null,d,b,b.mode,f);a.ref=b.ref;a.return=b;return b.child=a}g=a.child;if(0===(e&f)&&(e=g.memoizedProps,c=c.compare,c=null!==c?c:Je,c(e,d)&&a.ref===b.ref))return hi(a,b,f);b.flags|=1;a=Tg(g,d);a.ref=b.ref;a.return=b;return b.child=a}
|
||||
function ki(a,b,c,d,e,f){if(null!==a&&Je(a.memoizedProps,d)&&a.ref===b.ref)if(ug=!1,0!==(f&e))0!==(a.flags&16384)&&(ug=!0);else return b.lanes=a.lanes,hi(a,b,f);return li(a,b,c,d,f)}
|
||||
function mi(a,b,c){var d=b.pendingProps,e=d.children,f=null!==a?a.memoizedState:null;if("hidden"===d.mode||"unstable-defer-without-hiding"===d.mode)if(0===(b.mode&4))b.memoizedState={baseLanes:0},ni(b,c);else if(0!==(c&1073741824))b.memoizedState={baseLanes:0},ni(b,null!==f?f.baseLanes:c);else return a=null!==f?f.baseLanes|c:c,b.lanes=b.childLanes=1073741824,b.memoizedState={baseLanes:a},ni(b,a),null;else null!==f?(d=f.baseLanes|c,b.memoizedState=null):d=c,ni(b,d);fi(a,b,e,c);return b.child}
|
||||
function oi(a,b){var c=b.ref;if(null===a&&null!==c||null!==a&&a.ref!==c)b.flags|=128}function li(a,b,c,d,e){var f=Ff(c)?Df:M.current;f=Ef(b,f);tg(b,e);c=Ch(a,b,c,d,f,e);if(null!==a&&!ug)return b.updateQueue=a.updateQueue,b.flags&=-517,a.lanes&=~e,hi(a,b,e);b.flags|=1;fi(a,b,c,e);return b.child}
|
||||
function pi(a,b,c,d,e){if(Ff(c)){var f=!0;Jf(b)}else f=!1;tg(b,e);if(null===b.stateNode)null!==a&&(a.alternate=null,b.alternate=null,b.flags|=2),Mg(b,c,d),Og(b,c,d,e),d=!0;else if(null===a){var g=b.stateNode,h=b.memoizedProps;g.props=h;var k=g.context,l=c.contextType;"object"===typeof l&&null!==l?l=vg(l):(l=Ff(c)?Df:M.current,l=Ef(b,l));var n=c.getDerivedStateFromProps,A="function"===typeof n||"function"===typeof g.getSnapshotBeforeUpdate;A||"function"!==typeof g.UNSAFE_componentWillReceiveProps&&
|
||||
"function"!==typeof g.componentWillReceiveProps||(h!==d||k!==l)&&Ng(b,g,d,l);wg=!1;var p=b.memoizedState;g.state=p;Cg(b,d,g,e);k=b.memoizedState;h!==d||p!==k||N.current||wg?("function"===typeof n&&(Gg(b,c,n,d),k=b.memoizedState),(h=wg||Lg(b,c,h,d,p,k,l))?(A||"function"!==typeof g.UNSAFE_componentWillMount&&"function"!==typeof g.componentWillMount||("function"===typeof g.componentWillMount&&g.componentWillMount(),"function"===typeof g.UNSAFE_componentWillMount&&g.UNSAFE_componentWillMount()),"function"===
|
||||
typeof g.componentDidMount&&(b.flags|=4)):("function"===typeof g.componentDidMount&&(b.flags|=4),b.memoizedProps=d,b.memoizedState=k),g.props=d,g.state=k,g.context=l,d=h):("function"===typeof g.componentDidMount&&(b.flags|=4),d=!1)}else{g=b.stateNode;yg(a,b);h=b.memoizedProps;l=b.type===b.elementType?h:lg(b.type,h);g.props=l;A=b.pendingProps;p=g.context;k=c.contextType;"object"===typeof k&&null!==k?k=vg(k):(k=Ff(c)?Df:M.current,k=Ef(b,k));var C=c.getDerivedStateFromProps;(n="function"===typeof C||
|
||||
"function"===typeof g.getSnapshotBeforeUpdate)||"function"!==typeof g.UNSAFE_componentWillReceiveProps&&"function"!==typeof g.componentWillReceiveProps||(h!==A||p!==k)&&Ng(b,g,d,k);wg=!1;p=b.memoizedState;g.state=p;Cg(b,d,g,e);var x=b.memoizedState;h!==A||p!==x||N.current||wg?("function"===typeof C&&(Gg(b,c,C,d),x=b.memoizedState),(l=wg||Lg(b,c,l,d,p,x,k))?(n||"function"!==typeof g.UNSAFE_componentWillUpdate&&"function"!==typeof g.componentWillUpdate||("function"===typeof g.componentWillUpdate&&g.componentWillUpdate(d,
|
||||
x,k),"function"===typeof g.UNSAFE_componentWillUpdate&&g.UNSAFE_componentWillUpdate(d,x,k)),"function"===typeof g.componentDidUpdate&&(b.flags|=4),"function"===typeof g.getSnapshotBeforeUpdate&&(b.flags|=256)):("function"!==typeof g.componentDidUpdate||h===a.memoizedProps&&p===a.memoizedState||(b.flags|=4),"function"!==typeof g.getSnapshotBeforeUpdate||h===a.memoizedProps&&p===a.memoizedState||(b.flags|=256),b.memoizedProps=d,b.memoizedState=x),g.props=d,g.state=x,g.context=k,d=l):("function"!==typeof g.componentDidUpdate||
|
||||
h===a.memoizedProps&&p===a.memoizedState||(b.flags|=4),"function"!==typeof g.getSnapshotBeforeUpdate||h===a.memoizedProps&&p===a.memoizedState||(b.flags|=256),d=!1)}return qi(a,b,c,d,f,e)}
|
||||
function qi(a,b,c,d,e,f){oi(a,b);var g=0!==(b.flags&64);if(!d&&!g)return e&&Kf(b,c,!1),hi(a,b,f);d=b.stateNode;ei.current=b;var h=g&&"function"!==typeof c.getDerivedStateFromError?null:d.render();b.flags|=1;null!==a&&g?(b.child=Yg(b,a.child,null,f),b.child=Yg(b,null,h,f)):fi(a,b,h,f);b.memoizedState=d.state;e&&Kf(b,c,!0);return b.child}function ri(a){var b=a.stateNode;b.pendingContext?Hf(a,b.pendingContext,b.pendingContext!==b.context):b.context&&Hf(a,b.context,!1);eh(a,b.containerInfo)}
|
||||
var si={dehydrated:null,retryLane:0};
|
||||
function ti(a,b,c){var d=b.pendingProps,e=P.current,f=!1,g;(g=0!==(b.flags&64))||(g=null!==a&&null===a.memoizedState?!1:0!==(e&2));g?(f=!0,b.flags&=-65):null!==a&&null===a.memoizedState||void 0===d.fallback||!0===d.unstable_avoidThisFallback||(e|=1);I(P,e&1);if(null===a){void 0!==d.fallback&&ph(b);a=d.children;e=d.fallback;if(f)return a=ui(b,a,e,c),b.child.memoizedState={baseLanes:c},b.memoizedState=si,a;if("number"===typeof d.unstable_expectedLoadTime)return a=ui(b,a,e,c),b.child.memoizedState={baseLanes:c},
|
||||
b.memoizedState=si,b.lanes=33554432,a;c=vi({mode:"visible",children:a},b.mode,c,null);c.return=b;return b.child=c}if(null!==a.memoizedState){if(f)return d=wi(a,b,d.children,d.fallback,c),f=b.child,e=a.child.memoizedState,f.memoizedState=null===e?{baseLanes:c}:{baseLanes:e.baseLanes|c},f.childLanes=a.childLanes&~c,b.memoizedState=si,d;c=xi(a,b,d.children,c);b.memoizedState=null;return c}if(f)return d=wi(a,b,d.children,d.fallback,c),f=b.child,e=a.child.memoizedState,f.memoizedState=null===e?{baseLanes:c}:
|
||||
{baseLanes:e.baseLanes|c},f.childLanes=a.childLanes&~c,b.memoizedState=si,d;c=xi(a,b,d.children,c);b.memoizedState=null;return c}function ui(a,b,c,d){var e=a.mode,f=a.child;b={mode:"hidden",children:b};0===(e&2)&&null!==f?(f.childLanes=0,f.pendingProps=b):f=vi(b,e,0,null);c=Xg(c,e,d,null);f.return=a;c.return=a;f.sibling=c;a.child=f;return c}
|
||||
function xi(a,b,c,d){var e=a.child;a=e.sibling;c=Tg(e,{mode:"visible",children:c});0===(b.mode&2)&&(c.lanes=d);c.return=b;c.sibling=null;null!==a&&(a.nextEffect=null,a.flags=8,b.firstEffect=b.lastEffect=a);return b.child=c}
|
||||
function wi(a,b,c,d,e){var f=b.mode,g=a.child;a=g.sibling;var h={mode:"hidden",children:c};0===(f&2)&&b.child!==g?(c=b.child,c.childLanes=0,c.pendingProps=h,g=c.lastEffect,null!==g?(b.firstEffect=c.firstEffect,b.lastEffect=g,g.nextEffect=null):b.firstEffect=b.lastEffect=null):c=Tg(g,h);null!==a?d=Tg(a,d):(d=Xg(d,f,e,null),d.flags|=2);d.return=b;c.return=b;c.sibling=d;b.child=c;return d}function yi(a,b){a.lanes|=b;var c=a.alternate;null!==c&&(c.lanes|=b);sg(a.return,b)}
|
||||
function zi(a,b,c,d,e,f){var g=a.memoizedState;null===g?a.memoizedState={isBackwards:b,rendering:null,renderingStartTime:0,last:d,tail:c,tailMode:e,lastEffect:f}:(g.isBackwards=b,g.rendering=null,g.renderingStartTime=0,g.last=d,g.tail=c,g.tailMode=e,g.lastEffect=f)}
|
||||
function Ai(a,b,c){var d=b.pendingProps,e=d.revealOrder,f=d.tail;fi(a,b,d.children,c);d=P.current;if(0!==(d&2))d=d&1|2,b.flags|=64;else{if(null!==a&&0!==(a.flags&64))a:for(a=b.child;null!==a;){if(13===a.tag)null!==a.memoizedState&&yi(a,c);else if(19===a.tag)yi(a,c);else if(null!==a.child){a.child.return=a;a=a.child;continue}if(a===b)break a;for(;null===a.sibling;){if(null===a.return||a.return===b)break a;a=a.return}a.sibling.return=a.return;a=a.sibling}d&=1}I(P,d);if(0===(b.mode&2))b.memoizedState=
|
||||
null;else switch(e){case "forwards":c=b.child;for(e=null;null!==c;)a=c.alternate,null!==a&&null===ih(a)&&(e=c),c=c.sibling;c=e;null===c?(e=b.child,b.child=null):(e=c.sibling,c.sibling=null);zi(b,!1,e,c,f,b.lastEffect);break;case "backwards":c=null;e=b.child;for(b.child=null;null!==e;){a=e.alternate;if(null!==a&&null===ih(a)){b.child=e;break}a=e.sibling;e.sibling=c;c=e;e=a}zi(b,!0,c,null,f,b.lastEffect);break;case "together":zi(b,!1,null,null,void 0,b.lastEffect);break;default:b.memoizedState=null}return b.child}
|
||||
function hi(a,b,c){null!==a&&(b.dependencies=a.dependencies);Dg|=b.lanes;if(0!==(c&b.childLanes)){if(null!==a&&b.child!==a.child)throw Error(y(153));if(null!==b.child){a=b.child;c=Tg(a,a.pendingProps);b.child=c;for(c.return=b;null!==a.sibling;)a=a.sibling,c=c.sibling=Tg(a,a.pendingProps),c.return=b;c.sibling=null}return b.child}return null}var Bi,Ci,Di,Ei;
|
||||
Bi=function(a,b){for(var c=b.child;null!==c;){if(5===c.tag||6===c.tag)a.appendChild(c.stateNode);else if(4!==c.tag&&null!==c.child){c.child.return=c;c=c.child;continue}if(c===b)break;for(;null===c.sibling;){if(null===c.return||c.return===b)return;c=c.return}c.sibling.return=c.return;c=c.sibling}};Ci=function(){};
|
||||
Di=function(a,b,c,d){var e=a.memoizedProps;if(e!==d){a=b.stateNode;dh(ah.current);var f=null;switch(c){case "input":e=Ya(a,e);d=Ya(a,d);f=[];break;case "option":e=eb(a,e);d=eb(a,d);f=[];break;case "select":e=m({},e,{value:void 0});d=m({},d,{value:void 0});f=[];break;case "textarea":e=gb(a,e);d=gb(a,d);f=[];break;default:"function"!==typeof e.onClick&&"function"===typeof d.onClick&&(a.onclick=jf)}vb(c,d);var g;c=null;for(l in e)if(!d.hasOwnProperty(l)&&e.hasOwnProperty(l)&&null!=e[l])if("style"===
|
||||
l){var h=e[l];for(g in h)h.hasOwnProperty(g)&&(c||(c={}),c[g]="")}else"dangerouslySetInnerHTML"!==l&&"children"!==l&&"suppressContentEditableWarning"!==l&&"suppressHydrationWarning"!==l&&"autoFocus"!==l&&(ca.hasOwnProperty(l)?f||(f=[]):(f=f||[]).push(l,null));for(l in d){var k=d[l];h=null!=e?e[l]:void 0;if(d.hasOwnProperty(l)&&k!==h&&(null!=k||null!=h))if("style"===l)if(h){for(g in h)!h.hasOwnProperty(g)||k&&k.hasOwnProperty(g)||(c||(c={}),c[g]="");for(g in k)k.hasOwnProperty(g)&&h[g]!==k[g]&&(c||
|
||||
(c={}),c[g]=k[g])}else c||(f||(f=[]),f.push(l,c)),c=k;else"dangerouslySetInnerHTML"===l?(k=k?k.__html:void 0,h=h?h.__html:void 0,null!=k&&h!==k&&(f=f||[]).push(l,k)):"children"===l?"string"!==typeof k&&"number"!==typeof k||(f=f||[]).push(l,""+k):"suppressContentEditableWarning"!==l&&"suppressHydrationWarning"!==l&&(ca.hasOwnProperty(l)?(null!=k&&"onScroll"===l&&G("scroll",a),f||h===k||(f=[])):"object"===typeof k&&null!==k&&k.$$typeof===Ga?k.toString():(f=f||[]).push(l,k))}c&&(f=f||[]).push("style",
|
||||
c);var l=f;if(b.updateQueue=l)b.flags|=4}};Ei=function(a,b,c,d){c!==d&&(b.flags|=4)};function Fi(a,b){if(!lh)switch(a.tailMode){case "hidden":b=a.tail;for(var c=null;null!==b;)null!==b.alternate&&(c=b),b=b.sibling;null===c?a.tail=null:c.sibling=null;break;case "collapsed":c=a.tail;for(var d=null;null!==c;)null!==c.alternate&&(d=c),c=c.sibling;null===d?b||null===a.tail?a.tail=null:a.tail.sibling=null:d.sibling=null}}
|
||||
function Gi(a,b,c){var d=b.pendingProps;switch(b.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return null;case 1:return Ff(b.type)&&Gf(),null;case 3:fh();H(N);H(M);uh();d=b.stateNode;d.pendingContext&&(d.context=d.pendingContext,d.pendingContext=null);if(null===a||null===a.child)rh(b)?b.flags|=4:d.hydrate||(b.flags|=256);Ci(b);return null;case 5:hh(b);var e=dh(ch.current);c=b.type;if(null!==a&&null!=b.stateNode)Di(a,b,c,d,e),a.ref!==b.ref&&(b.flags|=128);else{if(!d){if(null===
|
||||
b.stateNode)throw Error(y(166));return null}a=dh(ah.current);if(rh(b)){d=b.stateNode;c=b.type;var f=b.memoizedProps;d[wf]=b;d[xf]=f;switch(c){case "dialog":G("cancel",d);G("close",d);break;case "iframe":case "object":case "embed":G("load",d);break;case "video":case "audio":for(a=0;a<Xe.length;a++)G(Xe[a],d);break;case "source":G("error",d);break;case "img":case "image":case "link":G("error",d);G("load",d);break;case "details":G("toggle",d);break;case "input":Za(d,f);G("invalid",d);break;case "select":d._wrapperState=
|
||||
{wasMultiple:!!f.multiple};G("invalid",d);break;case "textarea":hb(d,f),G("invalid",d)}vb(c,f);a=null;for(var g in f)f.hasOwnProperty(g)&&(e=f[g],"children"===g?"string"===typeof e?d.textContent!==e&&(a=["children",e]):"number"===typeof e&&d.textContent!==""+e&&(a=["children",""+e]):ca.hasOwnProperty(g)&&null!=e&&"onScroll"===g&&G("scroll",d));switch(c){case "input":Va(d);cb(d,f,!0);break;case "textarea":Va(d);jb(d);break;case "select":case "option":break;default:"function"===typeof f.onClick&&(d.onclick=
|
||||
jf)}d=a;b.updateQueue=d;null!==d&&(b.flags|=4)}else{g=9===e.nodeType?e:e.ownerDocument;a===kb.html&&(a=lb(c));a===kb.html?"script"===c?(a=g.createElement("div"),a.innerHTML="<script>\x3c/script>",a=a.removeChild(a.firstChild)):"string"===typeof d.is?a=g.createElement(c,{is:d.is}):(a=g.createElement(c),"select"===c&&(g=a,d.multiple?g.multiple=!0:d.size&&(g.size=d.size))):a=g.createElementNS(a,c);a[wf]=b;a[xf]=d;Bi(a,b,!1,!1);b.stateNode=a;g=wb(c,d);switch(c){case "dialog":G("cancel",a);G("close",a);
|
||||
e=d;break;case "iframe":case "object":case "embed":G("load",a);e=d;break;case "video":case "audio":for(e=0;e<Xe.length;e++)G(Xe[e],a);e=d;break;case "source":G("error",a);e=d;break;case "img":case "image":case "link":G("error",a);G("load",a);e=d;break;case "details":G("toggle",a);e=d;break;case "input":Za(a,d);e=Ya(a,d);G("invalid",a);break;case "option":e=eb(a,d);break;case "select":a._wrapperState={wasMultiple:!!d.multiple};e=m({},d,{value:void 0});G("invalid",a);break;case "textarea":hb(a,d);e=
|
||||
gb(a,d);G("invalid",a);break;default:e=d}vb(c,e);var h=e;for(f in h)if(h.hasOwnProperty(f)){var k=h[f];"style"===f?tb(a,k):"dangerouslySetInnerHTML"===f?(k=k?k.__html:void 0,null!=k&&ob(a,k)):"children"===f?"string"===typeof k?("textarea"!==c||""!==k)&&pb(a,k):"number"===typeof k&&pb(a,""+k):"suppressContentEditableWarning"!==f&&"suppressHydrationWarning"!==f&&"autoFocus"!==f&&(ca.hasOwnProperty(f)?null!=k&&"onScroll"===f&&G("scroll",a):null!=k&&qa(a,f,k,g))}switch(c){case "input":Va(a);cb(a,d,!1);
|
||||
break;case "textarea":Va(a);jb(a);break;case "option":null!=d.value&&a.setAttribute("value",""+Sa(d.value));break;case "select":a.multiple=!!d.multiple;f=d.value;null!=f?fb(a,!!d.multiple,f,!1):null!=d.defaultValue&&fb(a,!!d.multiple,d.defaultValue,!0);break;default:"function"===typeof e.onClick&&(a.onclick=jf)}mf(c,d)&&(b.flags|=4)}null!==b.ref&&(b.flags|=128)}return null;case 6:if(a&&null!=b.stateNode)Ei(a,b,a.memoizedProps,d);else{if("string"!==typeof d&&null===b.stateNode)throw Error(y(166));
|
||||
c=dh(ch.current);dh(ah.current);rh(b)?(d=b.stateNode,c=b.memoizedProps,d[wf]=b,d.nodeValue!==c&&(b.flags|=4)):(d=(9===c.nodeType?c:c.ownerDocument).createTextNode(d),d[wf]=b,b.stateNode=d)}return null;case 13:H(P);d=b.memoizedState;if(0!==(b.flags&64))return b.lanes=c,b;d=null!==d;c=!1;null===a?void 0!==b.memoizedProps.fallback&&rh(b):c=null!==a.memoizedState;if(d&&!c&&0!==(b.mode&2))if(null===a&&!0!==b.memoizedProps.unstable_avoidThisFallback||0!==(P.current&1))0===V&&(V=3);else{if(0===V||3===V)V=
|
||||
4;null===U||0===(Dg&134217727)&&0===(Hi&134217727)||Ii(U,W)}if(d||c)b.flags|=4;return null;case 4:return fh(),Ci(b),null===a&&cf(b.stateNode.containerInfo),null;case 10:return rg(b),null;case 17:return Ff(b.type)&&Gf(),null;case 19:H(P);d=b.memoizedState;if(null===d)return null;f=0!==(b.flags&64);g=d.rendering;if(null===g)if(f)Fi(d,!1);else{if(0!==V||null!==a&&0!==(a.flags&64))for(a=b.child;null!==a;){g=ih(a);if(null!==g){b.flags|=64;Fi(d,!1);f=g.updateQueue;null!==f&&(b.updateQueue=f,b.flags|=4);
|
||||
null===d.lastEffect&&(b.firstEffect=null);b.lastEffect=d.lastEffect;d=c;for(c=b.child;null!==c;)f=c,a=d,f.flags&=2,f.nextEffect=null,f.firstEffect=null,f.lastEffect=null,g=f.alternate,null===g?(f.childLanes=0,f.lanes=a,f.child=null,f.memoizedProps=null,f.memoizedState=null,f.updateQueue=null,f.dependencies=null,f.stateNode=null):(f.childLanes=g.childLanes,f.lanes=g.lanes,f.child=g.child,f.memoizedProps=g.memoizedProps,f.memoizedState=g.memoizedState,f.updateQueue=g.updateQueue,f.type=g.type,a=g.dependencies,
|
||||
f.dependencies=null===a?null:{lanes:a.lanes,firstContext:a.firstContext}),c=c.sibling;I(P,P.current&1|2);return b.child}a=a.sibling}null!==d.tail&&O()>Ji&&(b.flags|=64,f=!0,Fi(d,!1),b.lanes=33554432)}else{if(!f)if(a=ih(g),null!==a){if(b.flags|=64,f=!0,c=a.updateQueue,null!==c&&(b.updateQueue=c,b.flags|=4),Fi(d,!0),null===d.tail&&"hidden"===d.tailMode&&!g.alternate&&!lh)return b=b.lastEffect=d.lastEffect,null!==b&&(b.nextEffect=null),null}else 2*O()-d.renderingStartTime>Ji&&1073741824!==c&&(b.flags|=
|
||||
64,f=!0,Fi(d,!1),b.lanes=33554432);d.isBackwards?(g.sibling=b.child,b.child=g):(c=d.last,null!==c?c.sibling=g:b.child=g,d.last=g)}return null!==d.tail?(c=d.tail,d.rendering=c,d.tail=c.sibling,d.lastEffect=b.lastEffect,d.renderingStartTime=O(),c.sibling=null,b=P.current,I(P,f?b&1|2:b&1),c):null;case 23:case 24:return Ki(),null!==a&&null!==a.memoizedState!==(null!==b.memoizedState)&&"unstable-defer-without-hiding"!==d.mode&&(b.flags|=4),null}throw Error(y(156,b.tag));}
|
||||
function Li(a){switch(a.tag){case 1:Ff(a.type)&&Gf();var b=a.flags;return b&4096?(a.flags=b&-4097|64,a):null;case 3:fh();H(N);H(M);uh();b=a.flags;if(0!==(b&64))throw Error(y(285));a.flags=b&-4097|64;return a;case 5:return hh(a),null;case 13:return H(P),b=a.flags,b&4096?(a.flags=b&-4097|64,a):null;case 19:return H(P),null;case 4:return fh(),null;case 10:return rg(a),null;case 23:case 24:return Ki(),null;default:return null}}
|
||||
function Mi(a,b){try{var c="",d=b;do c+=Qa(d),d=d.return;while(d);var e=c}catch(f){e="\nError generating stack: "+f.message+"\n"+f.stack}return{value:a,source:b,stack:e}}function Ni(a,b){try{console.error(b.value)}catch(c){setTimeout(function(){throw c;})}}var Oi="function"===typeof WeakMap?WeakMap:Map;function Pi(a,b,c){c=zg(-1,c);c.tag=3;c.payload={element:null};var d=b.value;c.callback=function(){Qi||(Qi=!0,Ri=d);Ni(a,b)};return c}
|
||||
function Si(a,b,c){c=zg(-1,c);c.tag=3;var d=a.type.getDerivedStateFromError;if("function"===typeof d){var e=b.value;c.payload=function(){Ni(a,b);return d(e)}}var f=a.stateNode;null!==f&&"function"===typeof f.componentDidCatch&&(c.callback=function(){"function"!==typeof d&&(null===Ti?Ti=new Set([this]):Ti.add(this),Ni(a,b));var c=b.stack;this.componentDidCatch(b.value,{componentStack:null!==c?c:""})});return c}var Ui="function"===typeof WeakSet?WeakSet:Set;
|
||||
function Vi(a){var b=a.ref;if(null!==b)if("function"===typeof b)try{b(null)}catch(c){Wi(a,c)}else b.current=null}function Xi(a,b){switch(b.tag){case 0:case 11:case 15:case 22:return;case 1:if(b.flags&256&&null!==a){var c=a.memoizedProps,d=a.memoizedState;a=b.stateNode;b=a.getSnapshotBeforeUpdate(b.elementType===b.type?c:lg(b.type,c),d);a.__reactInternalSnapshotBeforeUpdate=b}return;case 3:b.flags&256&&qf(b.stateNode.containerInfo);return;case 5:case 6:case 4:case 17:return}throw Error(y(163));}
|
||||
function Yi(a,b,c){switch(c.tag){case 0:case 11:case 15:case 22:b=c.updateQueue;b=null!==b?b.lastEffect:null;if(null!==b){a=b=b.next;do{if(3===(a.tag&3)){var d=a.create;a.destroy=d()}a=a.next}while(a!==b)}b=c.updateQueue;b=null!==b?b.lastEffect:null;if(null!==b){a=b=b.next;do{var e=a;d=e.next;e=e.tag;0!==(e&4)&&0!==(e&1)&&(Zi(c,a),$i(c,a));a=d}while(a!==b)}return;case 1:a=c.stateNode;c.flags&4&&(null===b?a.componentDidMount():(d=c.elementType===c.type?b.memoizedProps:lg(c.type,b.memoizedProps),a.componentDidUpdate(d,
|
||||
b.memoizedState,a.__reactInternalSnapshotBeforeUpdate)));b=c.updateQueue;null!==b&&Eg(c,b,a);return;case 3:b=c.updateQueue;if(null!==b){a=null;if(null!==c.child)switch(c.child.tag){case 5:a=c.child.stateNode;break;case 1:a=c.child.stateNode}Eg(c,b,a)}return;case 5:a=c.stateNode;null===b&&c.flags&4&&mf(c.type,c.memoizedProps)&&a.focus();return;case 6:return;case 4:return;case 12:return;case 13:null===c.memoizedState&&(c=c.alternate,null!==c&&(c=c.memoizedState,null!==c&&(c=c.dehydrated,null!==c&&Cc(c))));
|
||||
return;case 19:case 17:case 20:case 21:case 23:case 24:return}throw Error(y(163));}
|
||||
function aj(a,b){for(var c=a;;){if(5===c.tag){var d=c.stateNode;if(b)d=d.style,"function"===typeof d.setProperty?d.setProperty("display","none","important"):d.display="none";else{d=c.stateNode;var e=c.memoizedProps.style;e=void 0!==e&&null!==e&&e.hasOwnProperty("display")?e.display:null;d.style.display=sb("display",e)}}else if(6===c.tag)c.stateNode.nodeValue=b?"":c.memoizedProps;else if((23!==c.tag&&24!==c.tag||null===c.memoizedState||c===a)&&null!==c.child){c.child.return=c;c=c.child;continue}if(c===
|
||||
a)break;for(;null===c.sibling;){if(null===c.return||c.return===a)return;c=c.return}c.sibling.return=c.return;c=c.sibling}}
|
||||
function bj(a,b){if(Mf&&"function"===typeof Mf.onCommitFiberUnmount)try{Mf.onCommitFiberUnmount(Lf,b)}catch(f){}switch(b.tag){case 0:case 11:case 14:case 15:case 22:a=b.updateQueue;if(null!==a&&(a=a.lastEffect,null!==a)){var c=a=a.next;do{var d=c,e=d.destroy;d=d.tag;if(void 0!==e)if(0!==(d&4))Zi(b,c);else{d=b;try{e()}catch(f){Wi(d,f)}}c=c.next}while(c!==a)}break;case 1:Vi(b);a=b.stateNode;if("function"===typeof a.componentWillUnmount)try{a.props=b.memoizedProps,a.state=b.memoizedState,a.componentWillUnmount()}catch(f){Wi(b,
|
||||
f)}break;case 5:Vi(b);break;case 4:cj(a,b)}}function dj(a){a.alternate=null;a.child=null;a.dependencies=null;a.firstEffect=null;a.lastEffect=null;a.memoizedProps=null;a.memoizedState=null;a.pendingProps=null;a.return=null;a.updateQueue=null}function ej(a){return 5===a.tag||3===a.tag||4===a.tag}
|
||||
function fj(a){a:{for(var b=a.return;null!==b;){if(ej(b))break a;b=b.return}throw Error(y(160));}var c=b;b=c.stateNode;switch(c.tag){case 5:var d=!1;break;case 3:b=b.containerInfo;d=!0;break;case 4:b=b.containerInfo;d=!0;break;default:throw Error(y(161));}c.flags&16&&(pb(b,""),c.flags&=-17);a:b:for(c=a;;){for(;null===c.sibling;){if(null===c.return||ej(c.return)){c=null;break a}c=c.return}c.sibling.return=c.return;for(c=c.sibling;5!==c.tag&&6!==c.tag&&18!==c.tag;){if(c.flags&2)continue b;if(null===
|
||||
c.child||4===c.tag)continue b;else c.child.return=c,c=c.child}if(!(c.flags&2)){c=c.stateNode;break a}}d?gj(a,c,b):hj(a,c,b)}
|
||||
function gj(a,b,c){var d=a.tag,e=5===d||6===d;if(e)a=e?a.stateNode:a.stateNode.instance,b?8===c.nodeType?c.parentNode.insertBefore(a,b):c.insertBefore(a,b):(8===c.nodeType?(b=c.parentNode,b.insertBefore(a,c)):(b=c,b.appendChild(a)),c=c._reactRootContainer,null!==c&&void 0!==c||null!==b.onclick||(b.onclick=jf));else if(4!==d&&(a=a.child,null!==a))for(gj(a,b,c),a=a.sibling;null!==a;)gj(a,b,c),a=a.sibling}
|
||||
function hj(a,b,c){var d=a.tag,e=5===d||6===d;if(e)a=e?a.stateNode:a.stateNode.instance,b?c.insertBefore(a,b):c.appendChild(a);else if(4!==d&&(a=a.child,null!==a))for(hj(a,b,c),a=a.sibling;null!==a;)hj(a,b,c),a=a.sibling}
|
||||
function cj(a,b){for(var c=b,d=!1,e,f;;){if(!d){d=c.return;a:for(;;){if(null===d)throw Error(y(160));e=d.stateNode;switch(d.tag){case 5:f=!1;break a;case 3:e=e.containerInfo;f=!0;break a;case 4:e=e.containerInfo;f=!0;break a}d=d.return}d=!0}if(5===c.tag||6===c.tag){a:for(var g=a,h=c,k=h;;)if(bj(g,k),null!==k.child&&4!==k.tag)k.child.return=k,k=k.child;else{if(k===h)break a;for(;null===k.sibling;){if(null===k.return||k.return===h)break a;k=k.return}k.sibling.return=k.return;k=k.sibling}f?(g=e,h=c.stateNode,
|
||||
8===g.nodeType?g.parentNode.removeChild(h):g.removeChild(h)):e.removeChild(c.stateNode)}else if(4===c.tag){if(null!==c.child){e=c.stateNode.containerInfo;f=!0;c.child.return=c;c=c.child;continue}}else if(bj(a,c),null!==c.child){c.child.return=c;c=c.child;continue}if(c===b)break;for(;null===c.sibling;){if(null===c.return||c.return===b)return;c=c.return;4===c.tag&&(d=!1)}c.sibling.return=c.return;c=c.sibling}}
|
||||
function ij(a,b){switch(b.tag){case 0:case 11:case 14:case 15:case 22:var c=b.updateQueue;c=null!==c?c.lastEffect:null;if(null!==c){var d=c=c.next;do 3===(d.tag&3)&&(a=d.destroy,d.destroy=void 0,void 0!==a&&a()),d=d.next;while(d!==c)}return;case 1:return;case 5:c=b.stateNode;if(null!=c){d=b.memoizedProps;var e=null!==a?a.memoizedProps:d;a=b.type;var f=b.updateQueue;b.updateQueue=null;if(null!==f){c[xf]=d;"input"===a&&"radio"===d.type&&null!=d.name&&$a(c,d);wb(a,e);b=wb(a,d);for(e=0;e<f.length;e+=
|
||||
2){var g=f[e],h=f[e+1];"style"===g?tb(c,h):"dangerouslySetInnerHTML"===g?ob(c,h):"children"===g?pb(c,h):qa(c,g,h,b)}switch(a){case "input":ab(c,d);break;case "textarea":ib(c,d);break;case "select":a=c._wrapperState.wasMultiple,c._wrapperState.wasMultiple=!!d.multiple,f=d.value,null!=f?fb(c,!!d.multiple,f,!1):a!==!!d.multiple&&(null!=d.defaultValue?fb(c,!!d.multiple,d.defaultValue,!0):fb(c,!!d.multiple,d.multiple?[]:"",!1))}}}return;case 6:if(null===b.stateNode)throw Error(y(162));b.stateNode.nodeValue=
|
||||
b.memoizedProps;return;case 3:c=b.stateNode;c.hydrate&&(c.hydrate=!1,Cc(c.containerInfo));return;case 12:return;case 13:null!==b.memoizedState&&(jj=O(),aj(b.child,!0));kj(b);return;case 19:kj(b);return;case 17:return;case 23:case 24:aj(b,null!==b.memoizedState);return}throw Error(y(163));}function kj(a){var b=a.updateQueue;if(null!==b){a.updateQueue=null;var c=a.stateNode;null===c&&(c=a.stateNode=new Ui);b.forEach(function(b){var d=lj.bind(null,a,b);c.has(b)||(c.add(b),b.then(d,d))})}}
|
||||
function mj(a,b){return null!==a&&(a=a.memoizedState,null===a||null!==a.dehydrated)?(b=b.memoizedState,null!==b&&null===b.dehydrated):!1}var nj=Math.ceil,oj=ra.ReactCurrentDispatcher,pj=ra.ReactCurrentOwner,X=0,U=null,Y=null,W=0,qj=0,rj=Bf(0),V=0,sj=null,tj=0,Dg=0,Hi=0,uj=0,vj=null,jj=0,Ji=Infinity;function wj(){Ji=O()+500}var Z=null,Qi=!1,Ri=null,Ti=null,xj=!1,yj=null,zj=90,Aj=[],Bj=[],Cj=null,Dj=0,Ej=null,Fj=-1,Gj=0,Hj=0,Ij=null,Jj=!1;function Hg(){return 0!==(X&48)?O():-1!==Fj?Fj:Fj=O()}
|
||||
function Ig(a){a=a.mode;if(0===(a&2))return 1;if(0===(a&4))return 99===eg()?1:2;0===Gj&&(Gj=tj);if(0!==kg.transition){0!==Hj&&(Hj=null!==vj?vj.pendingLanes:0);a=Gj;var b=4186112&~Hj;b&=-b;0===b&&(a=4186112&~a,b=a&-a,0===b&&(b=8192));return b}a=eg();0!==(X&4)&&98===a?a=Xc(12,Gj):(a=Sc(a),a=Xc(a,Gj));return a}
|
||||
function Jg(a,b,c){if(50<Dj)throw Dj=0,Ej=null,Error(y(185));a=Kj(a,b);if(null===a)return null;$c(a,b,c);a===U&&(Hi|=b,4===V&&Ii(a,W));var d=eg();1===b?0!==(X&8)&&0===(X&48)?Lj(a):(Mj(a,c),0===X&&(wj(),ig())):(0===(X&4)||98!==d&&99!==d||(null===Cj?Cj=new Set([a]):Cj.add(a)),Mj(a,c));vj=a}function Kj(a,b){a.lanes|=b;var c=a.alternate;null!==c&&(c.lanes|=b);c=a;for(a=a.return;null!==a;)a.childLanes|=b,c=a.alternate,null!==c&&(c.childLanes|=b),c=a,a=a.return;return 3===c.tag?c.stateNode:null}
|
||||
function Mj(a,b){for(var c=a.callbackNode,d=a.suspendedLanes,e=a.pingedLanes,f=a.expirationTimes,g=a.pendingLanes;0<g;){var h=31-Vc(g),k=1<<h,l=f[h];if(-1===l){if(0===(k&d)||0!==(k&e)){l=b;Rc(k);var n=F;f[h]=10<=n?l+250:6<=n?l+5E3:-1}}else l<=b&&(a.expiredLanes|=k);g&=~k}d=Uc(a,a===U?W:0);b=F;if(0===d)null!==c&&(c!==Zf&&Pf(c),a.callbackNode=null,a.callbackPriority=0);else{if(null!==c){if(a.callbackPriority===b)return;c!==Zf&&Pf(c)}15===b?(c=Lj.bind(null,a),null===ag?(ag=[c],bg=Of(Uf,jg)):ag.push(c),
|
||||
c=Zf):14===b?c=hg(99,Lj.bind(null,a)):(c=Tc(b),c=hg(c,Nj.bind(null,a)));a.callbackPriority=b;a.callbackNode=c}}
|
||||
function Nj(a){Fj=-1;Hj=Gj=0;if(0!==(X&48))throw Error(y(327));var b=a.callbackNode;if(Oj()&&a.callbackNode!==b)return null;var c=Uc(a,a===U?W:0);if(0===c)return null;var d=c;var e=X;X|=16;var f=Pj();if(U!==a||W!==d)wj(),Qj(a,d);do try{Rj();break}catch(h){Sj(a,h)}while(1);qg();oj.current=f;X=e;null!==Y?d=0:(U=null,W=0,d=V);if(0!==(tj&Hi))Qj(a,0);else if(0!==d){2===d&&(X|=64,a.hydrate&&(a.hydrate=!1,qf(a.containerInfo)),c=Wc(a),0!==c&&(d=Tj(a,c)));if(1===d)throw b=sj,Qj(a,0),Ii(a,c),Mj(a,O()),b;a.finishedWork=
|
||||
a.current.alternate;a.finishedLanes=c;switch(d){case 0:case 1:throw Error(y(345));case 2:Uj(a);break;case 3:Ii(a,c);if((c&62914560)===c&&(d=jj+500-O(),10<d)){if(0!==Uc(a,0))break;e=a.suspendedLanes;if((e&c)!==c){Hg();a.pingedLanes|=a.suspendedLanes&e;break}a.timeoutHandle=of(Uj.bind(null,a),d);break}Uj(a);break;case 4:Ii(a,c);if((c&4186112)===c)break;d=a.eventTimes;for(e=-1;0<c;){var g=31-Vc(c);f=1<<g;g=d[g];g>e&&(e=g);c&=~f}c=e;c=O()-c;c=(120>c?120:480>c?480:1080>c?1080:1920>c?1920:3E3>c?3E3:4320>
|
||||
c?4320:1960*nj(c/1960))-c;if(10<c){a.timeoutHandle=of(Uj.bind(null,a),c);break}Uj(a);break;case 5:Uj(a);break;default:throw Error(y(329));}}Mj(a,O());return a.callbackNode===b?Nj.bind(null,a):null}function Ii(a,b){b&=~uj;b&=~Hi;a.suspendedLanes|=b;a.pingedLanes&=~b;for(a=a.expirationTimes;0<b;){var c=31-Vc(b),d=1<<c;a[c]=-1;b&=~d}}
|
||||
function Lj(a){if(0!==(X&48))throw Error(y(327));Oj();if(a===U&&0!==(a.expiredLanes&W)){var b=W;var c=Tj(a,b);0!==(tj&Hi)&&(b=Uc(a,b),c=Tj(a,b))}else b=Uc(a,0),c=Tj(a,b);0!==a.tag&&2===c&&(X|=64,a.hydrate&&(a.hydrate=!1,qf(a.containerInfo)),b=Wc(a),0!==b&&(c=Tj(a,b)));if(1===c)throw c=sj,Qj(a,0),Ii(a,b),Mj(a,O()),c;a.finishedWork=a.current.alternate;a.finishedLanes=b;Uj(a);Mj(a,O());return null}
|
||||
function Vj(){if(null!==Cj){var a=Cj;Cj=null;a.forEach(function(a){a.expiredLanes|=24&a.pendingLanes;Mj(a,O())})}ig()}function Wj(a,b){var c=X;X|=1;try{return a(b)}finally{X=c,0===X&&(wj(),ig())}}function Xj(a,b){var c=X;X&=-2;X|=8;try{return a(b)}finally{X=c,0===X&&(wj(),ig())}}function ni(a,b){I(rj,qj);qj|=b;tj|=b}function Ki(){qj=rj.current;H(rj)}
|
||||
function Qj(a,b){a.finishedWork=null;a.finishedLanes=0;var c=a.timeoutHandle;-1!==c&&(a.timeoutHandle=-1,pf(c));if(null!==Y)for(c=Y.return;null!==c;){var d=c;switch(d.tag){case 1:d=d.type.childContextTypes;null!==d&&void 0!==d&&Gf();break;case 3:fh();H(N);H(M);uh();break;case 5:hh(d);break;case 4:fh();break;case 13:H(P);break;case 19:H(P);break;case 10:rg(d);break;case 23:case 24:Ki()}c=c.return}U=a;Y=Tg(a.current,null);W=qj=tj=b;V=0;sj=null;uj=Hi=Dg=0}
|
||||
function Sj(a,b){do{var c=Y;try{qg();vh.current=Gh;if(yh){for(var d=R.memoizedState;null!==d;){var e=d.queue;null!==e&&(e.pending=null);d=d.next}yh=!1}xh=0;T=S=R=null;zh=!1;pj.current=null;if(null===c||null===c.return){V=1;sj=b;Y=null;break}a:{var f=a,g=c.return,h=c,k=b;b=W;h.flags|=2048;h.firstEffect=h.lastEffect=null;if(null!==k&&"object"===typeof k&&"function"===typeof k.then){var l=k;if(0===(h.mode&2)){var n=h.alternate;n?(h.updateQueue=n.updateQueue,h.memoizedState=n.memoizedState,h.lanes=n.lanes):
|
||||
(h.updateQueue=null,h.memoizedState=null)}var A=0!==(P.current&1),p=g;do{var C;if(C=13===p.tag){var x=p.memoizedState;if(null!==x)C=null!==x.dehydrated?!0:!1;else{var w=p.memoizedProps;C=void 0===w.fallback?!1:!0!==w.unstable_avoidThisFallback?!0:A?!1:!0}}if(C){var z=p.updateQueue;if(null===z){var u=new Set;u.add(l);p.updateQueue=u}else z.add(l);if(0===(p.mode&2)){p.flags|=64;h.flags|=16384;h.flags&=-2981;if(1===h.tag)if(null===h.alternate)h.tag=17;else{var t=zg(-1,1);t.tag=2;Ag(h,t)}h.lanes|=1;break a}k=
|
||||
void 0;h=b;var q=f.pingCache;null===q?(q=f.pingCache=new Oi,k=new Set,q.set(l,k)):(k=q.get(l),void 0===k&&(k=new Set,q.set(l,k)));if(!k.has(h)){k.add(h);var v=Yj.bind(null,f,l,h);l.then(v,v)}p.flags|=4096;p.lanes=b;break a}p=p.return}while(null!==p);k=Error((Ra(h.type)||"A React component")+" suspended while rendering, but no fallback UI was specified.\n\nAdd a <Suspense fallback=...> component higher in the tree to provide a loading indicator or placeholder to display.")}5!==V&&(V=2);k=Mi(k,h);p=
|
||||
g;do{switch(p.tag){case 3:f=k;p.flags|=4096;b&=-b;p.lanes|=b;var J=Pi(p,f,b);Bg(p,J);break a;case 1:f=k;var K=p.type,Q=p.stateNode;if(0===(p.flags&64)&&("function"===typeof K.getDerivedStateFromError||null!==Q&&"function"===typeof Q.componentDidCatch&&(null===Ti||!Ti.has(Q)))){p.flags|=4096;b&=-b;p.lanes|=b;var L=Si(p,f,b);Bg(p,L);break a}}p=p.return}while(null!==p)}Zj(c)}catch(va){b=va;Y===c&&null!==c&&(Y=c=c.return);continue}break}while(1)}
|
||||
function Pj(){var a=oj.current;oj.current=Gh;return null===a?Gh:a}function Tj(a,b){var c=X;X|=16;var d=Pj();U===a&&W===b||Qj(a,b);do try{ak();break}catch(e){Sj(a,e)}while(1);qg();X=c;oj.current=d;if(null!==Y)throw Error(y(261));U=null;W=0;return V}function ak(){for(;null!==Y;)bk(Y)}function Rj(){for(;null!==Y&&!Qf();)bk(Y)}function bk(a){var b=ck(a.alternate,a,qj);a.memoizedProps=a.pendingProps;null===b?Zj(a):Y=b;pj.current=null}
|
||||
function Zj(a){var b=a;do{var c=b.alternate;a=b.return;if(0===(b.flags&2048)){c=Gi(c,b,qj);if(null!==c){Y=c;return}c=b;if(24!==c.tag&&23!==c.tag||null===c.memoizedState||0!==(qj&1073741824)||0===(c.mode&4)){for(var d=0,e=c.child;null!==e;)d|=e.lanes|e.childLanes,e=e.sibling;c.childLanes=d}null!==a&&0===(a.flags&2048)&&(null===a.firstEffect&&(a.firstEffect=b.firstEffect),null!==b.lastEffect&&(null!==a.lastEffect&&(a.lastEffect.nextEffect=b.firstEffect),a.lastEffect=b.lastEffect),1<b.flags&&(null!==
|
||||
a.lastEffect?a.lastEffect.nextEffect=b:a.firstEffect=b,a.lastEffect=b))}else{c=Li(b);if(null!==c){c.flags&=2047;Y=c;return}null!==a&&(a.firstEffect=a.lastEffect=null,a.flags|=2048)}b=b.sibling;if(null!==b){Y=b;return}Y=b=a}while(null!==b);0===V&&(V=5)}function Uj(a){var b=eg();gg(99,dk.bind(null,a,b));return null}
|
||||
function dk(a,b){do Oj();while(null!==yj);if(0!==(X&48))throw Error(y(327));var c=a.finishedWork;if(null===c)return null;a.finishedWork=null;a.finishedLanes=0;if(c===a.current)throw Error(y(177));a.callbackNode=null;var d=c.lanes|c.childLanes,e=d,f=a.pendingLanes&~e;a.pendingLanes=e;a.suspendedLanes=0;a.pingedLanes=0;a.expiredLanes&=e;a.mutableReadLanes&=e;a.entangledLanes&=e;e=a.entanglements;for(var g=a.eventTimes,h=a.expirationTimes;0<f;){var k=31-Vc(f),l=1<<k;e[k]=0;g[k]=-1;h[k]=-1;f&=~l}null!==
|
||||
Cj&&0===(d&24)&&Cj.has(a)&&Cj.delete(a);a===U&&(Y=U=null,W=0);1<c.flags?null!==c.lastEffect?(c.lastEffect.nextEffect=c,d=c.firstEffect):d=c:d=c.firstEffect;if(null!==d){e=X;X|=32;pj.current=null;kf=fd;g=Ne();if(Oe(g)){if("selectionStart"in g)h={start:g.selectionStart,end:g.selectionEnd};else a:if(h=(h=g.ownerDocument)&&h.defaultView||window,(l=h.getSelection&&h.getSelection())&&0!==l.rangeCount){h=l.anchorNode;f=l.anchorOffset;k=l.focusNode;l=l.focusOffset;try{h.nodeType,k.nodeType}catch(va){h=null;
|
||||
break a}var n=0,A=-1,p=-1,C=0,x=0,w=g,z=null;b:for(;;){for(var u;;){w!==h||0!==f&&3!==w.nodeType||(A=n+f);w!==k||0!==l&&3!==w.nodeType||(p=n+l);3===w.nodeType&&(n+=w.nodeValue.length);if(null===(u=w.firstChild))break;z=w;w=u}for(;;){if(w===g)break b;z===h&&++C===f&&(A=n);z===k&&++x===l&&(p=n);if(null!==(u=w.nextSibling))break;w=z;z=w.parentNode}w=u}h=-1===A||-1===p?null:{start:A,end:p}}else h=null;h=h||{start:0,end:0}}else h=null;lf={focusedElem:g,selectionRange:h};fd=!1;Ij=null;Jj=!1;Z=d;do try{ek()}catch(va){if(null===
|
||||
Z)throw Error(y(330));Wi(Z,va);Z=Z.nextEffect}while(null!==Z);Ij=null;Z=d;do try{for(g=a;null!==Z;){var t=Z.flags;t&16&&pb(Z.stateNode,"");if(t&128){var q=Z.alternate;if(null!==q){var v=q.ref;null!==v&&("function"===typeof v?v(null):v.current=null)}}switch(t&1038){case 2:fj(Z);Z.flags&=-3;break;case 6:fj(Z);Z.flags&=-3;ij(Z.alternate,Z);break;case 1024:Z.flags&=-1025;break;case 1028:Z.flags&=-1025;ij(Z.alternate,Z);break;case 4:ij(Z.alternate,Z);break;case 8:h=Z;cj(g,h);var J=h.alternate;dj(h);null!==
|
||||
J&&dj(J)}Z=Z.nextEffect}}catch(va){if(null===Z)throw Error(y(330));Wi(Z,va);Z=Z.nextEffect}while(null!==Z);v=lf;q=Ne();t=v.focusedElem;g=v.selectionRange;if(q!==t&&t&&t.ownerDocument&&Me(t.ownerDocument.documentElement,t)){null!==g&&Oe(t)&&(q=g.start,v=g.end,void 0===v&&(v=q),"selectionStart"in t?(t.selectionStart=q,t.selectionEnd=Math.min(v,t.value.length)):(v=(q=t.ownerDocument||document)&&q.defaultView||window,v.getSelection&&(v=v.getSelection(),h=t.textContent.length,J=Math.min(g.start,h),g=void 0===
|
||||
g.end?J:Math.min(g.end,h),!v.extend&&J>g&&(h=g,g=J,J=h),h=Le(t,J),f=Le(t,g),h&&f&&(1!==v.rangeCount||v.anchorNode!==h.node||v.anchorOffset!==h.offset||v.focusNode!==f.node||v.focusOffset!==f.offset)&&(q=q.createRange(),q.setStart(h.node,h.offset),v.removeAllRanges(),J>g?(v.addRange(q),v.extend(f.node,f.offset)):(q.setEnd(f.node,f.offset),v.addRange(q))))));q=[];for(v=t;v=v.parentNode;)1===v.nodeType&&q.push({element:v,left:v.scrollLeft,top:v.scrollTop});"function"===typeof t.focus&&t.focus();for(t=
|
||||
0;t<q.length;t++)v=q[t],v.element.scrollLeft=v.left,v.element.scrollTop=v.top}fd=!!kf;lf=kf=null;a.current=c;Z=d;do try{for(t=a;null!==Z;){var K=Z.flags;K&36&&Yi(t,Z.alternate,Z);if(K&128){q=void 0;var Q=Z.ref;if(null!==Q){var L=Z.stateNode;switch(Z.tag){case 5:q=L;break;default:q=L}"function"===typeof Q?Q(q):Q.current=q}}Z=Z.nextEffect}}catch(va){if(null===Z)throw Error(y(330));Wi(Z,va);Z=Z.nextEffect}while(null!==Z);Z=null;$f();X=e}else a.current=c;if(xj)xj=!1,yj=a,zj=b;else for(Z=d;null!==Z;)b=
|
||||
Z.nextEffect,Z.nextEffect=null,Z.flags&8&&(K=Z,K.sibling=null,K.stateNode=null),Z=b;d=a.pendingLanes;0===d&&(Ti=null);1===d?a===Ej?Dj++:(Dj=0,Ej=a):Dj=0;c=c.stateNode;if(Mf&&"function"===typeof Mf.onCommitFiberRoot)try{Mf.onCommitFiberRoot(Lf,c,void 0,64===(c.current.flags&64))}catch(va){}Mj(a,O());if(Qi)throw Qi=!1,a=Ri,Ri=null,a;if(0!==(X&8))return null;ig();return null}
|
||||
function ek(){for(;null!==Z;){var a=Z.alternate;Jj||null===Ij||(0!==(Z.flags&8)?dc(Z,Ij)&&(Jj=!0):13===Z.tag&&mj(a,Z)&&dc(Z,Ij)&&(Jj=!0));var b=Z.flags;0!==(b&256)&&Xi(a,Z);0===(b&512)||xj||(xj=!0,hg(97,function(){Oj();return null}));Z=Z.nextEffect}}function Oj(){if(90!==zj){var a=97<zj?97:zj;zj=90;return gg(a,fk)}return!1}function $i(a,b){Aj.push(b,a);xj||(xj=!0,hg(97,function(){Oj();return null}))}function Zi(a,b){Bj.push(b,a);xj||(xj=!0,hg(97,function(){Oj();return null}))}
|
||||
function fk(){if(null===yj)return!1;var a=yj;yj=null;if(0!==(X&48))throw Error(y(331));var b=X;X|=32;var c=Bj;Bj=[];for(var d=0;d<c.length;d+=2){var e=c[d],f=c[d+1],g=e.destroy;e.destroy=void 0;if("function"===typeof g)try{g()}catch(k){if(null===f)throw Error(y(330));Wi(f,k)}}c=Aj;Aj=[];for(d=0;d<c.length;d+=2){e=c[d];f=c[d+1];try{var h=e.create;e.destroy=h()}catch(k){if(null===f)throw Error(y(330));Wi(f,k)}}for(h=a.current.firstEffect;null!==h;)a=h.nextEffect,h.nextEffect=null,h.flags&8&&(h.sibling=
|
||||
null,h.stateNode=null),h=a;X=b;ig();return!0}function gk(a,b,c){b=Mi(c,b);b=Pi(a,b,1);Ag(a,b);b=Hg();a=Kj(a,1);null!==a&&($c(a,1,b),Mj(a,b))}
|
||||
function Wi(a,b){if(3===a.tag)gk(a,a,b);else for(var c=a.return;null!==c;){if(3===c.tag){gk(c,a,b);break}else if(1===c.tag){var d=c.stateNode;if("function"===typeof c.type.getDerivedStateFromError||"function"===typeof d.componentDidCatch&&(null===Ti||!Ti.has(d))){a=Mi(b,a);var e=Si(c,a,1);Ag(c,e);e=Hg();c=Kj(c,1);if(null!==c)$c(c,1,e),Mj(c,e);else if("function"===typeof d.componentDidCatch&&(null===Ti||!Ti.has(d)))try{d.componentDidCatch(b,a)}catch(f){}break}}c=c.return}}
|
||||
function Yj(a,b,c){var d=a.pingCache;null!==d&&d.delete(b);b=Hg();a.pingedLanes|=a.suspendedLanes&c;U===a&&(W&c)===c&&(4===V||3===V&&(W&62914560)===W&&500>O()-jj?Qj(a,0):uj|=c);Mj(a,b)}function lj(a,b){var c=a.stateNode;null!==c&&c.delete(b);b=0;0===b&&(b=a.mode,0===(b&2)?b=1:0===(b&4)?b=99===eg()?1:2:(0===Gj&&(Gj=tj),b=Yc(62914560&~Gj),0===b&&(b=4194304)));c=Hg();a=Kj(a,b);null!==a&&($c(a,b,c),Mj(a,c))}var ck;
|
||||
ck=function(a,b,c){var d=b.lanes;if(null!==a)if(a.memoizedProps!==b.pendingProps||N.current)ug=!0;else if(0!==(c&d))ug=0!==(a.flags&16384)?!0:!1;else{ug=!1;switch(b.tag){case 3:ri(b);sh();break;case 5:gh(b);break;case 1:Ff(b.type)&&Jf(b);break;case 4:eh(b,b.stateNode.containerInfo);break;case 10:d=b.memoizedProps.value;var e=b.type._context;I(mg,e._currentValue);e._currentValue=d;break;case 13:if(null!==b.memoizedState){if(0!==(c&b.child.childLanes))return ti(a,b,c);I(P,P.current&1);b=hi(a,b,c);return null!==
|
||||
b?b.sibling:null}I(P,P.current&1);break;case 19:d=0!==(c&b.childLanes);if(0!==(a.flags&64)){if(d)return Ai(a,b,c);b.flags|=64}e=b.memoizedState;null!==e&&(e.rendering=null,e.tail=null,e.lastEffect=null);I(P,P.current);if(d)break;else return null;case 23:case 24:return b.lanes=0,mi(a,b,c)}return hi(a,b,c)}else ug=!1;b.lanes=0;switch(b.tag){case 2:d=b.type;null!==a&&(a.alternate=null,b.alternate=null,b.flags|=2);a=b.pendingProps;e=Ef(b,M.current);tg(b,c);e=Ch(null,b,d,a,e,c);b.flags|=1;if("object"===
|
||||
typeof e&&null!==e&&"function"===typeof e.render&&void 0===e.$$typeof){b.tag=1;b.memoizedState=null;b.updateQueue=null;if(Ff(d)){var f=!0;Jf(b)}else f=!1;b.memoizedState=null!==e.state&&void 0!==e.state?e.state:null;xg(b);var g=d.getDerivedStateFromProps;"function"===typeof g&&Gg(b,d,g,a);e.updater=Kg;b.stateNode=e;e._reactInternals=b;Og(b,d,a,c);b=qi(null,b,d,!0,f,c)}else b.tag=0,fi(null,b,e,c),b=b.child;return b;case 16:e=b.elementType;a:{null!==a&&(a.alternate=null,b.alternate=null,b.flags|=2);
|
||||
a=b.pendingProps;f=e._init;e=f(e._payload);b.type=e;f=b.tag=hk(e);a=lg(e,a);switch(f){case 0:b=li(null,b,e,a,c);break a;case 1:b=pi(null,b,e,a,c);break a;case 11:b=gi(null,b,e,a,c);break a;case 14:b=ii(null,b,e,lg(e.type,a),d,c);break a}throw Error(y(306,e,""));}return b;case 0:return d=b.type,e=b.pendingProps,e=b.elementType===d?e:lg(d,e),li(a,b,d,e,c);case 1:return d=b.type,e=b.pendingProps,e=b.elementType===d?e:lg(d,e),pi(a,b,d,e,c);case 3:ri(b);d=b.updateQueue;if(null===a||null===d)throw Error(y(282));
|
||||
d=b.pendingProps;e=b.memoizedState;e=null!==e?e.element:null;yg(a,b);Cg(b,d,null,c);d=b.memoizedState.element;if(d===e)sh(),b=hi(a,b,c);else{e=b.stateNode;if(f=e.hydrate)kh=rf(b.stateNode.containerInfo.firstChild),jh=b,f=lh=!0;if(f){a=e.mutableSourceEagerHydrationData;if(null!=a)for(e=0;e<a.length;e+=2)f=a[e],f._workInProgressVersionPrimary=a[e+1],th.push(f);c=Zg(b,null,d,c);for(b.child=c;c;)c.flags=c.flags&-3|1024,c=c.sibling}else fi(a,b,d,c),sh();b=b.child}return b;case 5:return gh(b),null===a&&
|
||||
ph(b),d=b.type,e=b.pendingProps,f=null!==a?a.memoizedProps:null,g=e.children,nf(d,e)?g=null:null!==f&&nf(d,f)&&(b.flags|=16),oi(a,b),fi(a,b,g,c),b.child;case 6:return null===a&&ph(b),null;case 13:return ti(a,b,c);case 4:return eh(b,b.stateNode.containerInfo),d=b.pendingProps,null===a?b.child=Yg(b,null,d,c):fi(a,b,d,c),b.child;case 11:return d=b.type,e=b.pendingProps,e=b.elementType===d?e:lg(d,e),gi(a,b,d,e,c);case 7:return fi(a,b,b.pendingProps,c),b.child;case 8:return fi(a,b,b.pendingProps.children,
|
||||
c),b.child;case 12:return fi(a,b,b.pendingProps.children,c),b.child;case 10:a:{d=b.type._context;e=b.pendingProps;g=b.memoizedProps;f=e.value;var h=b.type._context;I(mg,h._currentValue);h._currentValue=f;if(null!==g)if(h=g.value,f=He(h,f)?0:("function"===typeof d._calculateChangedBits?d._calculateChangedBits(h,f):1073741823)|0,0===f){if(g.children===e.children&&!N.current){b=hi(a,b,c);break a}}else for(h=b.child,null!==h&&(h.return=b);null!==h;){var k=h.dependencies;if(null!==k){g=h.child;for(var l=
|
||||
k.firstContext;null!==l;){if(l.context===d&&0!==(l.observedBits&f)){1===h.tag&&(l=zg(-1,c&-c),l.tag=2,Ag(h,l));h.lanes|=c;l=h.alternate;null!==l&&(l.lanes|=c);sg(h.return,c);k.lanes|=c;break}l=l.next}}else g=10===h.tag?h.type===b.type?null:h.child:h.child;if(null!==g)g.return=h;else for(g=h;null!==g;){if(g===b){g=null;break}h=g.sibling;if(null!==h){h.return=g.return;g=h;break}g=g.return}h=g}fi(a,b,e.children,c);b=b.child}return b;case 9:return e=b.type,f=b.pendingProps,d=f.children,tg(b,c),e=vg(e,
|
||||
f.unstable_observedBits),d=d(e),b.flags|=1,fi(a,b,d,c),b.child;case 14:return e=b.type,f=lg(e,b.pendingProps),f=lg(e.type,f),ii(a,b,e,f,d,c);case 15:return ki(a,b,b.type,b.pendingProps,d,c);case 17:return d=b.type,e=b.pendingProps,e=b.elementType===d?e:lg(d,e),null!==a&&(a.alternate=null,b.alternate=null,b.flags|=2),b.tag=1,Ff(d)?(a=!0,Jf(b)):a=!1,tg(b,c),Mg(b,d,e),Og(b,d,e,c),qi(null,b,d,!0,a,c);case 19:return Ai(a,b,c);case 23:return mi(a,b,c);case 24:return mi(a,b,c)}throw Error(y(156,b.tag));
|
||||
};function ik(a,b,c,d){this.tag=a;this.key=c;this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null;this.index=0;this.ref=null;this.pendingProps=b;this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null;this.mode=d;this.flags=0;this.lastEffect=this.firstEffect=this.nextEffect=null;this.childLanes=this.lanes=0;this.alternate=null}function nh(a,b,c,d){return new ik(a,b,c,d)}function ji(a){a=a.prototype;return!(!a||!a.isReactComponent)}
|
||||
function hk(a){if("function"===typeof a)return ji(a)?1:0;if(void 0!==a&&null!==a){a=a.$$typeof;if(a===Aa)return 11;if(a===Da)return 14}return 2}
|
||||
function Tg(a,b){var c=a.alternate;null===c?(c=nh(a.tag,b,a.key,a.mode),c.elementType=a.elementType,c.type=a.type,c.stateNode=a.stateNode,c.alternate=a,a.alternate=c):(c.pendingProps=b,c.type=a.type,c.flags=0,c.nextEffect=null,c.firstEffect=null,c.lastEffect=null);c.childLanes=a.childLanes;c.lanes=a.lanes;c.child=a.child;c.memoizedProps=a.memoizedProps;c.memoizedState=a.memoizedState;c.updateQueue=a.updateQueue;b=a.dependencies;c.dependencies=null===b?null:{lanes:b.lanes,firstContext:b.firstContext};
|
||||
c.sibling=a.sibling;c.index=a.index;c.ref=a.ref;return c}
|
||||
function Vg(a,b,c,d,e,f){var g=2;d=a;if("function"===typeof a)ji(a)&&(g=1);else if("string"===typeof a)g=5;else a:switch(a){case ua:return Xg(c.children,e,f,b);case Ha:g=8;e|=16;break;case wa:g=8;e|=1;break;case xa:return a=nh(12,c,b,e|8),a.elementType=xa,a.type=xa,a.lanes=f,a;case Ba:return a=nh(13,c,b,e),a.type=Ba,a.elementType=Ba,a.lanes=f,a;case Ca:return a=nh(19,c,b,e),a.elementType=Ca,a.lanes=f,a;case Ia:return vi(c,e,f,b);case Ja:return a=nh(24,c,b,e),a.elementType=Ja,a.lanes=f,a;default:if("object"===
|
||||
typeof a&&null!==a)switch(a.$$typeof){case ya:g=10;break a;case za:g=9;break a;case Aa:g=11;break a;case Da:g=14;break a;case Ea:g=16;d=null;break a;case Fa:g=22;break a}throw Error(y(130,null==a?a:typeof a,""));}b=nh(g,c,b,e);b.elementType=a;b.type=d;b.lanes=f;return b}function Xg(a,b,c,d){a=nh(7,a,d,b);a.lanes=c;return a}function vi(a,b,c,d){a=nh(23,a,d,b);a.elementType=Ia;a.lanes=c;return a}function Ug(a,b,c){a=nh(6,a,null,b);a.lanes=c;return a}
|
||||
function Wg(a,b,c){b=nh(4,null!==a.children?a.children:[],a.key,b);b.lanes=c;b.stateNode={containerInfo:a.containerInfo,pendingChildren:null,implementation:a.implementation};return b}
|
||||
function jk(a,b,c){this.tag=b;this.containerInfo=a;this.finishedWork=this.pingCache=this.current=this.pendingChildren=null;this.timeoutHandle=-1;this.pendingContext=this.context=null;this.hydrate=c;this.callbackNode=null;this.callbackPriority=0;this.eventTimes=Zc(0);this.expirationTimes=Zc(-1);this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0;this.entanglements=Zc(0);this.mutableSourceEagerHydrationData=null}
|
||||
function kk(a,b,c){var d=3<arguments.length&&void 0!==arguments[3]?arguments[3]:null;return{$$typeof:ta,key:null==d?null:""+d,children:a,containerInfo:b,implementation:c}}
|
||||
function lk(a,b,c,d){var e=b.current,f=Hg(),g=Ig(e);a:if(c){c=c._reactInternals;b:{if(Zb(c)!==c||1!==c.tag)throw Error(y(170));var h=c;do{switch(h.tag){case 3:h=h.stateNode.context;break b;case 1:if(Ff(h.type)){h=h.stateNode.__reactInternalMemoizedMergedChildContext;break b}}h=h.return}while(null!==h);throw Error(y(171));}if(1===c.tag){var k=c.type;if(Ff(k)){c=If(c,k,h);break a}}c=h}else c=Cf;null===b.context?b.context=c:b.pendingContext=c;b=zg(f,g);b.payload={element:a};d=void 0===d?null:d;null!==
|
||||
d&&(b.callback=d);Ag(e,b);Jg(e,g,f);return g}function mk(a){a=a.current;if(!a.child)return null;switch(a.child.tag){case 5:return a.child.stateNode;default:return a.child.stateNode}}function nk(a,b){a=a.memoizedState;if(null!==a&&null!==a.dehydrated){var c=a.retryLane;a.retryLane=0!==c&&c<b?c:b}}function ok(a,b){nk(a,b);(a=a.alternate)&&nk(a,b)}function pk(){return null}
|
||||
function qk(a,b,c){var d=null!=c&&null!=c.hydrationOptions&&c.hydrationOptions.mutableSources||null;c=new jk(a,b,null!=c&&!0===c.hydrate);b=nh(3,null,null,2===b?7:1===b?3:0);c.current=b;b.stateNode=c;xg(b);a[ff]=c.current;cf(8===a.nodeType?a.parentNode:a);if(d)for(a=0;a<d.length;a++){b=d[a];var e=b._getVersion;e=e(b._source);null==c.mutableSourceEagerHydrationData?c.mutableSourceEagerHydrationData=[b,e]:c.mutableSourceEagerHydrationData.push(b,e)}this._internalRoot=c}
|
||||
qk.prototype.render=function(a){lk(a,this._internalRoot,null,null)};qk.prototype.unmount=function(){var a=this._internalRoot,b=a.containerInfo;lk(null,a,null,function(){b[ff]=null})};function rk(a){return!(!a||1!==a.nodeType&&9!==a.nodeType&&11!==a.nodeType&&(8!==a.nodeType||" react-mount-point-unstable "!==a.nodeValue))}
|
||||
function sk(a,b){b||(b=a?9===a.nodeType?a.documentElement:a.firstChild:null,b=!(!b||1!==b.nodeType||!b.hasAttribute("data-reactroot")));if(!b)for(var c;c=a.lastChild;)a.removeChild(c);return new qk(a,0,b?{hydrate:!0}:void 0)}
|
||||
function tk(a,b,c,d,e){var f=c._reactRootContainer;if(f){var g=f._internalRoot;if("function"===typeof e){var h=e;e=function(){var a=mk(g);h.call(a)}}lk(b,g,a,e)}else{f=c._reactRootContainer=sk(c,d);g=f._internalRoot;if("function"===typeof e){var k=e;e=function(){var a=mk(g);k.call(a)}}Xj(function(){lk(b,g,a,e)})}return mk(g)}ec=function(a){if(13===a.tag){var b=Hg();Jg(a,4,b);ok(a,4)}};fc=function(a){if(13===a.tag){var b=Hg();Jg(a,67108864,b);ok(a,67108864)}};
|
||||
gc=function(a){if(13===a.tag){var b=Hg(),c=Ig(a);Jg(a,c,b);ok(a,c)}};hc=function(a,b){return b()};
|
||||
yb=function(a,b,c){switch(b){case "input":ab(a,c);b=c.name;if("radio"===c.type&&null!=b){for(c=a;c.parentNode;)c=c.parentNode;c=c.querySelectorAll("input[name="+JSON.stringify(""+b)+'][type="radio"]');for(b=0;b<c.length;b++){var d=c[b];if(d!==a&&d.form===a.form){var e=Db(d);if(!e)throw Error(y(90));Wa(d);ab(d,e)}}}break;case "textarea":ib(a,c);break;case "select":b=c.value,null!=b&&fb(a,!!c.multiple,b,!1)}};Gb=Wj;
|
||||
Hb=function(a,b,c,d,e){var f=X;X|=4;try{return gg(98,a.bind(null,b,c,d,e))}finally{X=f,0===X&&(wj(),ig())}};Ib=function(){0===(X&49)&&(Vj(),Oj())};Jb=function(a,b){var c=X;X|=2;try{return a(b)}finally{X=c,0===X&&(wj(),ig())}};function uk(a,b){var c=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;if(!rk(b))throw Error(y(200));return kk(a,b,null,c)}var vk={Events:[Cb,ue,Db,Eb,Fb,Oj,{current:!1}]},wk={findFiberByHostInstance:wc,bundleType:0,version:"17.0.2",rendererPackageName:"react-dom"};
|
||||
var xk={bundleType:wk.bundleType,version:wk.version,rendererPackageName:wk.rendererPackageName,rendererConfig:wk.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:ra.ReactCurrentDispatcher,findHostInstanceByFiber:function(a){a=cc(a);return null===a?null:a.stateNode},findFiberByHostInstance:wk.findFiberByHostInstance||
|
||||
pk,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null};if("undefined"!==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__){var yk=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!yk.isDisabled&&yk.supportsFiber)try{Lf=yk.inject(xk),Mf=yk}catch(a){}}exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=vk;exports.createPortal=uk;
|
||||
exports.findDOMNode=function(a){if(null==a)return null;if(1===a.nodeType)return a;var b=a._reactInternals;if(void 0===b){if("function"===typeof a.render)throw Error(y(188));throw Error(y(268,Object.keys(a)));}a=cc(b);a=null===a?null:a.stateNode;return a};exports.flushSync=function(a,b){var c=X;if(0!==(c&48))return a(b);X|=1;try{if(a)return gg(99,a.bind(null,b))}finally{X=c,ig()}};exports.hydrate=function(a,b,c){if(!rk(b))throw Error(y(200));return tk(null,a,b,!0,c)};
|
||||
exports.render=function(a,b,c){if(!rk(b))throw Error(y(200));return tk(null,a,b,!1,c)};exports.unmountComponentAtNode=function(a){if(!rk(a))throw Error(y(40));return a._reactRootContainer?(Xj(function(){tk(null,null,a,!1,function(){a._reactRootContainer=null;a[ff]=null})}),!0):!1};exports.unstable_batchedUpdates=Wj;exports.unstable_createPortal=function(a,b){return uk(a,b,2<arguments.length&&void 0!==arguments[2]?arguments[2]:null)};
|
||||
exports.unstable_renderSubtreeIntoContainer=function(a,b,c,d){if(!rk(c))throw Error(y(200));if(null==a||void 0===a._reactInternals)throw Error(y(38));return tk(a,b,c,!1,d)};exports.version="17.0.2";
|
||||
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 935:
|
||||
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
||||
|
||||
|
||||
|
||||
function checkDCE() {
|
||||
/* global __REACT_DEVTOOLS_GLOBAL_HOOK__ */
|
||||
if (
|
||||
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ === 'undefined' ||
|
||||
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE !== 'function'
|
||||
) {
|
||||
return;
|
||||
}
|
||||
if (false) {}
|
||||
try {
|
||||
// Verify that the code above has been dead code eliminated (DCE'd).
|
||||
__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(checkDCE);
|
||||
} catch (err) {
|
||||
// DevTools shouldn't crash React, no matter what.
|
||||
// We should still report in case we break this code.
|
||||
console.error(err);
|
||||
}
|
||||
}
|
||||
|
||||
if (true) {
|
||||
// DCE check should happen before ReactDOM bundle executes so that
|
||||
// DevTools can report bad minification during injection.
|
||||
checkDCE();
|
||||
module.exports = __webpack_require__(448);
|
||||
} else {}
|
||||
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 408:
|
||||
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
||||
|
||||
/** @license React v17.0.2
|
||||
* react.production.min.js
|
||||
*
|
||||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*/
|
||||
var l=__webpack_require__(418),n=60103,p=60106;exports.Fragment=60107;exports.StrictMode=60108;exports.Profiler=60114;var q=60109,r=60110,t=60112;exports.Suspense=60113;var u=60115,v=60116;
|
||||
if("function"===typeof Symbol&&Symbol.for){var w=Symbol.for;n=w("react.element");p=w("react.portal");exports.Fragment=w("react.fragment");exports.StrictMode=w("react.strict_mode");exports.Profiler=w("react.profiler");q=w("react.provider");r=w("react.context");t=w("react.forward_ref");exports.Suspense=w("react.suspense");u=w("react.memo");v=w("react.lazy")}var x="function"===typeof Symbol&&Symbol.iterator;
|
||||
function y(a){if(null===a||"object"!==typeof a)return null;a=x&&a[x]||a["@@iterator"];return"function"===typeof a?a:null}function z(a){for(var b="https://reactjs.org/docs/error-decoder.html?invariant="+a,c=1;c<arguments.length;c++)b+="&args[]="+encodeURIComponent(arguments[c]);return"Minified React error #"+a+"; visit "+b+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}
|
||||
var A={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},B={};function C(a,b,c){this.props=a;this.context=b;this.refs=B;this.updater=c||A}C.prototype.isReactComponent={};C.prototype.setState=function(a,b){if("object"!==typeof a&&"function"!==typeof a&&null!=a)throw Error(z(85));this.updater.enqueueSetState(this,a,b,"setState")};C.prototype.forceUpdate=function(a){this.updater.enqueueForceUpdate(this,a,"forceUpdate")};
|
||||
function D(){}D.prototype=C.prototype;function E(a,b,c){this.props=a;this.context=b;this.refs=B;this.updater=c||A}var F=E.prototype=new D;F.constructor=E;l(F,C.prototype);F.isPureReactComponent=!0;var G={current:null},H=Object.prototype.hasOwnProperty,I={key:!0,ref:!0,__self:!0,__source:!0};
|
||||
function J(a,b,c){var e,d={},k=null,h=null;if(null!=b)for(e in void 0!==b.ref&&(h=b.ref),void 0!==b.key&&(k=""+b.key),b)H.call(b,e)&&!I.hasOwnProperty(e)&&(d[e]=b[e]);var g=arguments.length-2;if(1===g)d.children=c;else if(1<g){for(var f=Array(g),m=0;m<g;m++)f[m]=arguments[m+2];d.children=f}if(a&&a.defaultProps)for(e in g=a.defaultProps,g)void 0===d[e]&&(d[e]=g[e]);return{$$typeof:n,type:a,key:k,ref:h,props:d,_owner:G.current}}
|
||||
function K(a,b){return{$$typeof:n,type:a.type,key:b,ref:a.ref,props:a.props,_owner:a._owner}}function L(a){return"object"===typeof a&&null!==a&&a.$$typeof===n}function escape(a){var b={"=":"=0",":":"=2"};return"$"+a.replace(/[=:]/g,function(a){return b[a]})}var M=/\/+/g;function N(a,b){return"object"===typeof a&&null!==a&&null!=a.key?escape(""+a.key):b.toString(36)}
|
||||
function O(a,b,c,e,d){var k=typeof a;if("undefined"===k||"boolean"===k)a=null;var h=!1;if(null===a)h=!0;else switch(k){case "string":case "number":h=!0;break;case "object":switch(a.$$typeof){case n:case p:h=!0}}if(h)return h=a,d=d(h),a=""===e?"."+N(h,0):e,Array.isArray(d)?(c="",null!=a&&(c=a.replace(M,"$&/")+"/"),O(d,b,c,"",function(a){return a})):null!=d&&(L(d)&&(d=K(d,c+(!d.key||h&&h.key===d.key?"":(""+d.key).replace(M,"$&/")+"/")+a)),b.push(d)),1;h=0;e=""===e?".":e+":";if(Array.isArray(a))for(var g=
|
||||
0;g<a.length;g++){k=a[g];var f=e+N(k,g);h+=O(k,b,c,f,d)}else if(f=y(a),"function"===typeof f)for(a=f.call(a),g=0;!(k=a.next()).done;)k=k.value,f=e+N(k,g++),h+=O(k,b,c,f,d);else if("object"===k)throw b=""+a,Error(z(31,"[object Object]"===b?"object with keys {"+Object.keys(a).join(", ")+"}":b));return h}function P(a,b,c){if(null==a)return a;var e=[],d=0;O(a,e,"","",function(a){return b.call(c,a,d++)});return e}
|
||||
function Q(a){if(-1===a._status){var b=a._result;b=b();a._status=0;a._result=b;b.then(function(b){0===a._status&&(b=b.default,a._status=1,a._result=b)},function(b){0===a._status&&(a._status=2,a._result=b)})}if(1===a._status)return a._result;throw a._result;}var R={current:null};function S(){var a=R.current;if(null===a)throw Error(z(321));return a}var T={ReactCurrentDispatcher:R,ReactCurrentBatchConfig:{transition:0},ReactCurrentOwner:G,IsSomeRendererActing:{current:!1},assign:l};
|
||||
exports.Children={map:P,forEach:function(a,b,c){P(a,function(){b.apply(this,arguments)},c)},count:function(a){var b=0;P(a,function(){b++});return b},toArray:function(a){return P(a,function(a){return a})||[]},only:function(a){if(!L(a))throw Error(z(143));return a}};exports.Component=C;exports.PureComponent=E;exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=T;
|
||||
exports.cloneElement=function(a,b,c){if(null===a||void 0===a)throw Error(z(267,a));var e=l({},a.props),d=a.key,k=a.ref,h=a._owner;if(null!=b){void 0!==b.ref&&(k=b.ref,h=G.current);void 0!==b.key&&(d=""+b.key);if(a.type&&a.type.defaultProps)var g=a.type.defaultProps;for(f in b)H.call(b,f)&&!I.hasOwnProperty(f)&&(e[f]=void 0===b[f]&&void 0!==g?g[f]:b[f])}var f=arguments.length-2;if(1===f)e.children=c;else if(1<f){g=Array(f);for(var m=0;m<f;m++)g[m]=arguments[m+2];e.children=g}return{$$typeof:n,type:a.type,
|
||||
key:d,ref:k,props:e,_owner:h}};exports.createContext=function(a,b){void 0===b&&(b=null);a={$$typeof:r,_calculateChangedBits:b,_currentValue:a,_currentValue2:a,_threadCount:0,Provider:null,Consumer:null};a.Provider={$$typeof:q,_context:a};return a.Consumer=a};exports.createElement=J;exports.createFactory=function(a){var b=J.bind(null,a);b.type=a;return b};exports.createRef=function(){return{current:null}};exports.forwardRef=function(a){return{$$typeof:t,render:a}};exports.isValidElement=L;
|
||||
exports.lazy=function(a){return{$$typeof:v,_payload:{_status:-1,_result:a},_init:Q}};exports.memo=function(a,b){return{$$typeof:u,type:a,compare:void 0===b?null:b}};exports.useCallback=function(a,b){return S().useCallback(a,b)};exports.useContext=function(a,b){return S().useContext(a,b)};exports.useDebugValue=function(){};exports.useEffect=function(a,b){return S().useEffect(a,b)};exports.useImperativeHandle=function(a,b,c){return S().useImperativeHandle(a,b,c)};
|
||||
exports.useLayoutEffect=function(a,b){return S().useLayoutEffect(a,b)};exports.useMemo=function(a,b){return S().useMemo(a,b)};exports.useReducer=function(a,b,c){return S().useReducer(a,b,c)};exports.useRef=function(a){return S().useRef(a)};exports.useState=function(a){return S().useState(a)};exports.version="17.0.2";
|
||||
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 294:
|
||||
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
||||
|
||||
|
||||
|
||||
if (true) {
|
||||
module.exports = __webpack_require__(408);
|
||||
} else {}
|
||||
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 53:
|
||||
/***/ ((__unused_webpack_module, exports) => {
|
||||
|
||||
/** @license React v0.20.2
|
||||
* scheduler.production.min.js
|
||||
*
|
||||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*/
|
||||
var f,g,h,k;if("object"===typeof performance&&"function"===typeof performance.now){var l=performance;exports.unstable_now=function(){return l.now()}}else{var p=Date,q=p.now();exports.unstable_now=function(){return p.now()-q}}
|
||||
if("undefined"===typeof window||"function"!==typeof MessageChannel){var t=null,u=null,w=function(){if(null!==t)try{var a=exports.unstable_now();t(!0,a);t=null}catch(b){throw setTimeout(w,0),b;}};f=function(a){null!==t?setTimeout(f,0,a):(t=a,setTimeout(w,0))};g=function(a,b){u=setTimeout(a,b)};h=function(){clearTimeout(u)};exports.unstable_shouldYield=function(){return!1};k=exports.unstable_forceFrameRate=function(){}}else{var x=window.setTimeout,y=window.clearTimeout;if("undefined"!==typeof console){var z=
|
||||
window.cancelAnimationFrame;"function"!==typeof window.requestAnimationFrame&&console.error("This browser doesn't support requestAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills");"function"!==typeof z&&console.error("This browser doesn't support cancelAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills")}var A=!1,B=null,C=-1,D=5,E=0;exports.unstable_shouldYield=function(){return exports.unstable_now()>=
|
||||
E};k=function(){};exports.unstable_forceFrameRate=function(a){0>a||125<a?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):D=0<a?Math.floor(1E3/a):5};var F=new MessageChannel,G=F.port2;F.port1.onmessage=function(){if(null!==B){var a=exports.unstable_now();E=a+D;try{B(!0,a)?G.postMessage(null):(A=!1,B=null)}catch(b){throw G.postMessage(null),b;}}else A=!1};f=function(a){B=a;A||(A=!0,G.postMessage(null))};g=function(a,b){C=
|
||||
x(function(){a(exports.unstable_now())},b)};h=function(){y(C);C=-1}}function H(a,b){var c=a.length;a.push(b);a:for(;;){var d=c-1>>>1,e=a[d];if(void 0!==e&&0<I(e,b))a[d]=b,a[c]=e,c=d;else break a}}function J(a){a=a[0];return void 0===a?null:a}
|
||||
function K(a){var b=a[0];if(void 0!==b){var c=a.pop();if(c!==b){a[0]=c;a:for(var d=0,e=a.length;d<e;){var m=2*(d+1)-1,n=a[m],v=m+1,r=a[v];if(void 0!==n&&0>I(n,c))void 0!==r&&0>I(r,n)?(a[d]=r,a[v]=c,d=v):(a[d]=n,a[m]=c,d=m);else if(void 0!==r&&0>I(r,c))a[d]=r,a[v]=c,d=v;else break a}}return b}return null}function I(a,b){var c=a.sortIndex-b.sortIndex;return 0!==c?c:a.id-b.id}var L=[],M=[],N=1,O=null,P=3,Q=!1,R=!1,S=!1;
|
||||
function T(a){for(var b=J(M);null!==b;){if(null===b.callback)K(M);else if(b.startTime<=a)K(M),b.sortIndex=b.expirationTime,H(L,b);else break;b=J(M)}}function U(a){S=!1;T(a);if(!R)if(null!==J(L))R=!0,f(V);else{var b=J(M);null!==b&&g(U,b.startTime-a)}}
|
||||
function V(a,b){R=!1;S&&(S=!1,h());Q=!0;var c=P;try{T(b);for(O=J(L);null!==O&&(!(O.expirationTime>b)||a&&!exports.unstable_shouldYield());){var d=O.callback;if("function"===typeof d){O.callback=null;P=O.priorityLevel;var e=d(O.expirationTime<=b);b=exports.unstable_now();"function"===typeof e?O.callback=e:O===J(L)&&K(L);T(b)}else K(L);O=J(L)}if(null!==O)var m=!0;else{var n=J(M);null!==n&&g(U,n.startTime-b);m=!1}return m}finally{O=null,P=c,Q=!1}}var W=k;exports.unstable_IdlePriority=5;
|
||||
exports.unstable_ImmediatePriority=1;exports.unstable_LowPriority=4;exports.unstable_NormalPriority=3;exports.unstable_Profiling=null;exports.unstable_UserBlockingPriority=2;exports.unstable_cancelCallback=function(a){a.callback=null};exports.unstable_continueExecution=function(){R||Q||(R=!0,f(V))};exports.unstable_getCurrentPriorityLevel=function(){return P};exports.unstable_getFirstCallbackNode=function(){return J(L)};
|
||||
exports.unstable_next=function(a){switch(P){case 1:case 2:case 3:var b=3;break;default:b=P}var c=P;P=b;try{return a()}finally{P=c}};exports.unstable_pauseExecution=function(){};exports.unstable_requestPaint=W;exports.unstable_runWithPriority=function(a,b){switch(a){case 1:case 2:case 3:case 4:case 5:break;default:a=3}var c=P;P=a;try{return b()}finally{P=c}};
|
||||
exports.unstable_scheduleCallback=function(a,b,c){var d=exports.unstable_now();"object"===typeof c&&null!==c?(c=c.delay,c="number"===typeof c&&0<c?d+c:d):c=d;switch(a){case 1:var e=-1;break;case 2:e=250;break;case 5:e=1073741823;break;case 4:e=1E4;break;default:e=5E3}e=c+e;a={id:N++,callback:b,priorityLevel:a,startTime:c,expirationTime:e,sortIndex:-1};c>d?(a.sortIndex=c,H(M,a),null===J(L)&&a===J(M)&&(S?h():S=!0,g(U,c-d))):(a.sortIndex=e,H(L,a),R||Q||(R=!0,f(V)));return a};
|
||||
exports.unstable_wrapCallback=function(a){var b=P;return function(){var c=P;P=b;try{return a.apply(this,arguments)}finally{P=c}}};
|
||||
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 840:
|
||||
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
||||
|
||||
|
||||
|
||||
if (true) {
|
||||
module.exports = __webpack_require__(53);
|
||||
} else {}
|
||||
|
||||
|
||||
/***/ })
|
||||
|
||||
}]);
|
|
@ -0,0 +1,32 @@
|
|||
/*
|
||||
object-assign
|
||||
(c) Sindre Sorhus
|
||||
@license MIT
|
||||
*/
|
||||
|
||||
/** @license React v0.20.2
|
||||
* scheduler.production.min.js
|
||||
*
|
||||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*/
|
||||
|
||||
/** @license React v17.0.2
|
||||
* react-dom.production.min.js
|
||||
*
|
||||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*/
|
||||
|
||||
/** @license React v17.0.2
|
||||
* react.production.min.js
|
||||
*
|
||||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*/
|
|
@ -14,6 +14,7 @@
|
|||
<script src="js/vendor/handlebars.runtime.js"></script>
|
||||
<script src="js/vendor/jquery.tokeninput.min.js"></script>
|
||||
<script src="js/tmpl.js"></script>
|
||||
<script src="js/vendor.bundle.js"></script>
|
||||
<script src="js/main.bundle.js"></script>
|
||||
<script src="js/saved/entry.js"></script>
|
||||
</body>
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
<body class="pkt_ext_containersignup" aria-live="polite">
|
||||
<script src="js/vendor/handlebars.runtime.js"></script>
|
||||
<script src="js/tmpl.js"></script>
|
||||
<script src="js/vendor.bundle.js"></script>
|
||||
<script src="js/main.bundle.js"></script>
|
||||
<script src="js/signup/entry.js"></script>
|
||||
</body>
|
||||
|
|
|
@ -16,6 +16,7 @@ browser.jar:
|
|||
content/pocket/panels/saved.html (content/panels/saved.html)
|
||||
content/pocket/panels/signup.html (content/panels/signup.html)
|
||||
content/pocket/panels/style-guide.html (content/panels/style-guide.html)
|
||||
content/pocket/panels/js/vendor.bundle.js (content/panels/js/vendor.bundle.js)
|
||||
content/pocket/panels/js/main.bundle.js (content/panels/js/main.bundle.js)
|
||||
content/pocket/panels/js/tmpl.js (content/panels/js/tmpl.js)
|
||||
content/pocket/panels/js/vendor (content/panels/js/vendor/*)
|
||||
|
|
|
@ -8,8 +8,14 @@ const testGlobal = {
|
|||
RPMAddMessageListener: () => {},
|
||||
RPMSendAsyncMessage: () => {},
|
||||
window: {},
|
||||
self: {},
|
||||
};
|
||||
|
||||
Services.scriptloader.loadSubScript(
|
||||
"chrome://pocket/content/panels/js/vendor.bundle.js",
|
||||
testGlobal
|
||||
);
|
||||
|
||||
Services.scriptloader.loadSubScript(
|
||||
"chrome://pocket/content/panels/js/main.bundle.js",
|
||||
testGlobal
|
||||
|
|
|
@ -4,7 +4,6 @@
|
|||
/* eslint-env node */
|
||||
|
||||
module.exports = {
|
||||
mode: "production",
|
||||
entry: {
|
||||
main: "./content/panels/js/main.js",
|
||||
},
|
||||
|
@ -27,4 +26,16 @@ module.exports = {
|
|||
resolve: {
|
||||
extensions: [".js", ".jsx"],
|
||||
},
|
||||
optimization: {
|
||||
minimize: false,
|
||||
splitChunks: {
|
||||
cacheGroups: {
|
||||
vendor: {
|
||||
test: /[\\/]node_modules[\\/](react|react-dom|scheduler|object-assign)[\\/]/,
|
||||
name: "vendor",
|
||||
chunks: "all",
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
};
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
/* import-globals-from ../../../../toolkit/content/preferencesBindings.js */
|
||||
/* import-globals-from /toolkit/content/preferencesBindings.js */
|
||||
|
||||
var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
|
||||
|
||||
|
@ -209,12 +209,24 @@ class OrderedListBox {
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* The sorted select list of Locales available for the app.
|
||||
*/
|
||||
class SortedItemSelectList {
|
||||
constructor({ menulist, button, onSelect, onChange, compareFn }) {
|
||||
/** @type {XULElement} */
|
||||
this.menulist = menulist;
|
||||
|
||||
/** @type {XULElement} */
|
||||
this.popup = menulist.menupopup;
|
||||
|
||||
/** @type {XULElement} */
|
||||
this.button = button;
|
||||
|
||||
/** @type {(a: LocaleDisplayInfo, b: LocaleDisplayInfo) => number} */
|
||||
this.compareFn = compareFn;
|
||||
|
||||
/** @type {Array<LocaleDisplayInfo>} */
|
||||
this.items = [];
|
||||
|
||||
// This will register the "command" listener.
|
||||
|
@ -240,6 +252,9 @@ class SortedItemSelectList {
|
|||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {Array<LocaleDisplayInfo>} items
|
||||
*/
|
||||
setItems(items) {
|
||||
this.items = items.sort(this.compareFn);
|
||||
this.populate();
|
||||
|
@ -318,6 +333,21 @@ class SortedItemSelectList {
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @typedef LocaleDisplayInfo
|
||||
* @type {object}
|
||||
* @prop {string} id - A unique ID.
|
||||
* @prop {string} label - The localized display name.
|
||||
* @prop {string} value - The BCP 47 locale identifier or the word "search".
|
||||
* @prop {boolean} canRemove - Locales that are part of the packaged locales cannot be
|
||||
* removed.
|
||||
* @prop {boolean} installed - Whether or not the locale is installed.
|
||||
*/
|
||||
|
||||
/**
|
||||
* @param {Array<string>} localeCodes - List of BCP 47 locale identifiers.
|
||||
* @returns {Array<LocaleDisplayInfo>}
|
||||
*/
|
||||
async function getLocaleDisplayInfo(localeCodes) {
|
||||
let availableLocales = new Set(await getAvailableLocales());
|
||||
let packagedLocales = new Set(Services.locale.packagedLocales);
|
||||
|
@ -337,6 +367,11 @@ async function getLocaleDisplayInfo(localeCodes) {
|
|||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {LocaleDisplayInfo} a
|
||||
* @param {LocaleDisplayInfo} b
|
||||
* @returns {number}
|
||||
*/
|
||||
function compareItems(a, b) {
|
||||
// Sort by installed.
|
||||
if (a.installed != b.installed) {
|
||||
|
@ -360,11 +395,32 @@ function compareItems(a, b) {
|
|||
}
|
||||
|
||||
var gBrowserLanguagesDialog = {
|
||||
telemetryId: null,
|
||||
accepted: false,
|
||||
_availableLocales: null,
|
||||
_selectedLocales: null,
|
||||
selectedLocales: null,
|
||||
/**
|
||||
* The publicly readable list of selected locales. It is only set when the dialog is
|
||||
* accepted, and can be retrieved elsewhere by directly reading the property
|
||||
* on gBrowserLanguagesDialog.
|
||||
*
|
||||
* let { selected } = gBrowserLanguagesDialog;
|
||||
*
|
||||
* @type {null | Array<string>}
|
||||
*/
|
||||
selected: null,
|
||||
|
||||
/**
|
||||
* @type {string | null} An ID used for telemetry pings. It is unique to the current
|
||||
* opening of the browser language.
|
||||
*/
|
||||
_telemetryId: null,
|
||||
|
||||
/**
|
||||
* @type {SortedItemSelectList}
|
||||
*/
|
||||
_availableLocalesUI: null,
|
||||
|
||||
/**
|
||||
* @type {OrderedListBox}
|
||||
*/
|
||||
_selectedLocalesUI: null,
|
||||
|
||||
get downloadEnabled() {
|
||||
// Downloading langpacks isn't always supported, check the pref.
|
||||
|
@ -376,31 +432,37 @@ var gBrowserLanguagesDialog = {
|
|||
"intl.ui.browserLanguage",
|
||||
method,
|
||||
"dialog",
|
||||
this.telemetryId,
|
||||
this._telemetryId,
|
||||
extra
|
||||
);
|
||||
},
|
||||
|
||||
beforeAccept() {
|
||||
this.selected = this.getSelectedLocales();
|
||||
this.accepted = true;
|
||||
},
|
||||
|
||||
async onLoad() {
|
||||
document
|
||||
.getElementById("BrowserLanguagesDialog")
|
||||
.addEventListener("beforeaccept", () => this.beforeAccept());
|
||||
// Maintain the previously selected locales even if we cancel out.
|
||||
let { telemetryId, selected, search } = window.arguments[0];
|
||||
this.telemetryId = telemetryId;
|
||||
this.selectedLocales = selected;
|
||||
/**
|
||||
* @typedef {Object} Options - Options passed in to configure the subdialog.
|
||||
* @property {string} telemetryId,
|
||||
* @property {Array<string>} [selectedLocalesForRestart] The optional list of
|
||||
* previously selected locales for when a restart is required. This list is
|
||||
* preserved between openings of the dialog.
|
||||
* @property {boolean} search Whether the user opened this from "Search for more
|
||||
* languages" option.
|
||||
*/
|
||||
|
||||
/** @type {Options} */
|
||||
let {
|
||||
telemetryId,
|
||||
selectedLocalesForRestart,
|
||||
search,
|
||||
} = window.arguments[0];
|
||||
|
||||
this._telemetryId = telemetryId;
|
||||
|
||||
// This is a list of available locales that the user selected. It's more
|
||||
// restricted than the Intl notion of `requested` as it only contains
|
||||
// locale codes for which we have matching locales available.
|
||||
// The first time this dialog is opened, populate with appLocalesAsBCP47.
|
||||
let selectedLocales =
|
||||
this.selectedLocales || Services.locale.appLocalesAsBCP47;
|
||||
selectedLocalesForRestart || Services.locale.appLocalesAsBCP47;
|
||||
let selectedLocaleSet = new Set(selectedLocales);
|
||||
let available = await getAvailableLocales();
|
||||
let availableSet = new Set(available);
|
||||
|
@ -417,10 +479,20 @@ var gBrowserLanguagesDialog = {
|
|||
await this.initAvailableLocales(available, search);
|
||||
|
||||
this.initialized = true;
|
||||
|
||||
// Now the component is initialized, it's safe to accept the results.
|
||||
document
|
||||
.getElementById("BrowserLanguagesDialog")
|
||||
.addEventListener("beforeaccept", () => {
|
||||
this.selected = this._selectedLocalesUI.items.map(item => item.value);
|
||||
});
|
||||
},
|
||||
|
||||
/**
|
||||
* @param {string[]} selectedLocales - BCP 47 locale identifiers
|
||||
*/
|
||||
async initSelectedLocales(selectedLocales) {
|
||||
this._selectedLocales = new OrderedListBox({
|
||||
this._selectedLocalesUI = new OrderedListBox({
|
||||
richlistbox: document.getElementById("selectedLocales"),
|
||||
upButton: document.getElementById("up"),
|
||||
downButton: document.getElementById("down"),
|
||||
|
@ -428,11 +500,18 @@ var gBrowserLanguagesDialog = {
|
|||
onRemove: item => this.selectedLocaleRemoved(item),
|
||||
onReorder: () => this.recordTelemetry("reorder"),
|
||||
});
|
||||
this._selectedLocales.setItems(await getLocaleDisplayInfo(selectedLocales));
|
||||
this._selectedLocalesUI.setItems(
|
||||
await getLocaleDisplayInfo(selectedLocales)
|
||||
);
|
||||
},
|
||||
|
||||
/**
|
||||
* @param {Set<string>} available - The set of available BCP 47 locale identifiers.
|
||||
* @param {boolean} search - Whether the user opened this from "Search for more
|
||||
* languages" option.
|
||||
*/
|
||||
async initAvailableLocales(available, search) {
|
||||
this._availableLocales = new SortedItemSelectList({
|
||||
this._availableLocalesUI = new SortedItemSelectList({
|
||||
menulist: document.getElementById("availableLocales"),
|
||||
button: document.getElementById("add"),
|
||||
compareFn: compareItems,
|
||||
|
@ -467,7 +546,9 @@ var gBrowserLanguagesDialog = {
|
|||
}
|
||||
|
||||
// Disable the dropdown while we hit the network.
|
||||
this._availableLocales.disableWithMessageId("browser-languages-searching");
|
||||
this._availableLocalesUI.disableWithMessageId(
|
||||
"browser-languages-searching"
|
||||
);
|
||||
|
||||
// Fetch the available langpacks from AMO.
|
||||
let availableLangpacks;
|
||||
|
@ -502,17 +583,20 @@ var gBrowserLanguagesDialog = {
|
|||
});
|
||||
|
||||
// Remove the search option and add the remote locales.
|
||||
let items = this._availableLocales.items;
|
||||
let items = this._availableLocalesUI.items;
|
||||
items.pop();
|
||||
items = items.concat(availableItems);
|
||||
|
||||
// Update the dropdown and enable it again.
|
||||
this._availableLocales.setItems(items);
|
||||
this._availableLocales.enableWithMessageId(
|
||||
this._availableLocalesUI.setItems(items);
|
||||
this._availableLocalesUI.enableWithMessageId(
|
||||
"browser-languages-select-language"
|
||||
);
|
||||
},
|
||||
|
||||
/**
|
||||
* @param {Set<string>} available - The set of available (BCP 47) locales.
|
||||
*/
|
||||
async loadLocalesFromInstalled(available) {
|
||||
let items;
|
||||
if (available.length) {
|
||||
|
@ -527,9 +611,12 @@ var gBrowserLanguagesDialog = {
|
|||
value: "search",
|
||||
});
|
||||
}
|
||||
this._availableLocales.setItems(items);
|
||||
this._availableLocalesUI.setItems(items);
|
||||
},
|
||||
|
||||
/**
|
||||
* @param {LocaleDisplayInfo} item
|
||||
*/
|
||||
async availableLanguageSelected(item) {
|
||||
if ((await getAvailableLocales()).includes(item.value)) {
|
||||
this.recordTelemetry("add");
|
||||
|
@ -542,23 +629,29 @@ var gBrowserLanguagesDialog = {
|
|||
}
|
||||
},
|
||||
|
||||
async requestLocalLanguage(item, available) {
|
||||
this._selectedLocales.addItem(item);
|
||||
let selectedCount = this._selectedLocales.items.length;
|
||||
/**
|
||||
* @param {LocaleDisplayInfo} item
|
||||
*/
|
||||
async requestLocalLanguage(item) {
|
||||
this._selectedLocalesUI.addItem(item);
|
||||
let selectedCount = this._selectedLocalesUI.items.length;
|
||||
let availableCount = (await getAvailableLocales()).length;
|
||||
if (selectedCount == availableCount) {
|
||||
// Remove the installed label, they're all installed.
|
||||
this._availableLocales.items.shift();
|
||||
this._availableLocales.setItems(this._availableLocales.items);
|
||||
this._availableLocalesUI.items.shift();
|
||||
this._availableLocalesUI.setItems(this._availableLocalesUI.items);
|
||||
}
|
||||
// The label isn't always reset when the selected item is removed, so set it again.
|
||||
this._availableLocales.enableWithMessageId(
|
||||
this._availableLocalesUI.enableWithMessageId(
|
||||
"browser-languages-select-language"
|
||||
);
|
||||
},
|
||||
|
||||
/**
|
||||
* @param {LocaleDisplayInfo} item
|
||||
*/
|
||||
async requestRemoteLanguage(item) {
|
||||
this._availableLocales.disableWithMessageId(
|
||||
this._availableLocalesUI.disableWithMessageId(
|
||||
"browser-languages-downloading"
|
||||
);
|
||||
|
||||
|
@ -580,8 +673,8 @@ var gBrowserLanguagesDialog = {
|
|||
}
|
||||
|
||||
item.installed = true;
|
||||
this._selectedLocales.addItem(item);
|
||||
this._availableLocales.enableWithMessageId(
|
||||
this._selectedLocalesUI.addItem(item);
|
||||
this._availableLocalesUI.enableWithMessageId(
|
||||
"browser-languages-select-language"
|
||||
);
|
||||
|
||||
|
@ -591,6 +684,9 @@ var gBrowserLanguagesDialog = {
|
|||
this.installDictionariesForLanguage(item.value);
|
||||
},
|
||||
|
||||
/**
|
||||
* @param {string} locale The BCP 47 locale identifier
|
||||
*/
|
||||
async installDictionariesForLanguage(locale) {
|
||||
try {
|
||||
let ids = await dictionaryIdsForLocale(locale);
|
||||
|
@ -605,7 +701,7 @@ var gBrowserLanguagesDialog = {
|
|||
|
||||
showError() {
|
||||
document.getElementById("warning-message").hidden = false;
|
||||
this._availableLocales.enableWithMessageId(
|
||||
this._availableLocalesUI.enableWithMessageId(
|
||||
"browser-languages-select-language"
|
||||
);
|
||||
|
||||
|
@ -623,18 +719,17 @@ var gBrowserLanguagesDialog = {
|
|||
document.getElementById("warning-message").hidden = true;
|
||||
},
|
||||
|
||||
getSelectedLocales() {
|
||||
return this._selectedLocales.items.map(item => item.value);
|
||||
},
|
||||
|
||||
/**
|
||||
* @param {LocaleDisplayInfo} item
|
||||
*/
|
||||
async selectedLocaleRemoved(item) {
|
||||
this.recordTelemetry("remove");
|
||||
|
||||
this._availableLocales.addItem(item);
|
||||
this._availableLocalesUI.addItem(item);
|
||||
|
||||
// If the item we added is at the top of the list, it needs the label.
|
||||
if (this._availableLocales.items[0] == item) {
|
||||
this._availableLocales.addItem(await this.createInstalledLabel());
|
||||
if (this._availableLocalesUI.items[0] == item) {
|
||||
this._availableLocalesUI.addItem(await this.createInstalledLabel());
|
||||
}
|
||||
},
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
/* import-globals-from ../../../../toolkit/content/preferencesBindings.js */
|
||||
/* import-globals-from /toolkit/content/preferencesBindings.js */
|
||||
|
||||
document
|
||||
.getElementById("ColorsDialog")
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
/* import-globals-from ../../../base/content/utilityOverlay.js */
|
||||
/* import-globals-from ../../../../toolkit/content/preferencesBindings.js */
|
||||
/* import-globals-from /browser/base/content/utilityOverlay.js */
|
||||
/* import-globals-from /toolkit/content/preferencesBindings.js */
|
||||
/* import-globals-from ../extensionControlled.js */
|
||||
|
||||
ChromeUtils.defineModuleGetter(
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
/* import-globals-from ../../../base/content/utilityOverlay.js */
|
||||
/* import-globals-from ../../../../toolkit/mozapps/preferences/fontbuilder.js */
|
||||
/* import-globals-from /browser/base/content/utilityOverlay.js */
|
||||
/* import-globals-from /toolkit/mozapps/preferences/fontbuilder.js */
|
||||
|
||||
// browser.display.languageList LOCK ALL when LOCKED
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
/* import-globals-from ../../../../toolkit/content/preferencesBindings.js */
|
||||
/* import-globals-from /toolkit/content/preferencesBindings.js */
|
||||
|
||||
var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
/* import-globals-from ../../../../toolkit/content/preferencesBindings.js */
|
||||
/* import-globals-from /toolkit/content/preferencesBindings.js */
|
||||
|
||||
document
|
||||
.querySelector("dialog")
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
|
||||
* You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
/* import-globals-from ../../../../toolkit/content/preferencesBindings.js */
|
||||
/* import-globals-from /toolkit/content/preferencesBindings.js */
|
||||
|
||||
const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
|
||||
|
||||
|
|
|
@ -277,7 +277,7 @@
|
|||
<vbox id="browserLanguagesBox" align="start" hidden="true">
|
||||
<description flex="1" controls="chooseBrowserLanguage" data-l10n-id="choose-browser-language-description"/>
|
||||
<hbox>
|
||||
<menulist id="defaultBrowserLanguage">
|
||||
<menulist id="primaryBrowserLocale">
|
||||
<menupopup/>
|
||||
</menulist>
|
||||
<button id="manageBrowserLanguagesButton"
|
||||
|
|
|
@ -4,8 +4,8 @@
|
|||
|
||||
/* import-globals-from extensionControlled.js */
|
||||
/* import-globals-from preferences.js */
|
||||
/* import-globals-from ../../../toolkit/mozapps/preferences/fontbuilder.js */
|
||||
/* import-globals-from ../../base/content/aboutDialog-appUpdater.js */
|
||||
/* import-globals-from /toolkit/mozapps/preferences/fontbuilder.js */
|
||||
/* import-globals-from /browser/base/content/aboutDialog-appUpdater.js */
|
||||
/* global MozXULElement */
|
||||
|
||||
XPCOMUtils.defineLazyModuleGetters(this, {
|
||||
|
@ -328,7 +328,7 @@ var gMainPane = {
|
|||
initializeProxyUI(gMainPane);
|
||||
|
||||
if (Services.prefs.getBoolPref("intl.multilingual.enabled")) {
|
||||
gMainPane.initBrowserLocale();
|
||||
gMainPane.initPrimaryBrowserLanguageUI();
|
||||
}
|
||||
|
||||
// We call `initDefaultZoomValues` to set and unhide the
|
||||
|
@ -396,7 +396,7 @@ var gMainPane = {
|
|||
Services.prefs.clearUserPref("browser.ctrlTab.migrated");
|
||||
});
|
||||
setEventListener("manageBrowserLanguagesButton", "command", function() {
|
||||
gMainPane.showBrowserLanguages({ search: false });
|
||||
gMainPane.showBrowserLanguagesSubDialog({ search: false });
|
||||
});
|
||||
if (AppConstants.MOZ_UPDATER) {
|
||||
// These elements are only compiled in when the updater is enabled
|
||||
|
@ -986,7 +986,7 @@ var gMainPane = {
|
|||
document.getElementById("zoomBox").hidden = false;
|
||||
},
|
||||
|
||||
initBrowserLocale() {
|
||||
initPrimaryBrowserLanguageUI() {
|
||||
// Enable telemetry.
|
||||
Services.telemetry.setEventRecordingEnabled(
|
||||
"intl.ui.browserLanguage",
|
||||
|
@ -994,20 +994,22 @@ var gMainPane = {
|
|||
);
|
||||
|
||||
// This will register the "command" listener.
|
||||
let menulist = document.getElementById("defaultBrowserLanguage");
|
||||
let menulist = document.getElementById("primaryBrowserLocale");
|
||||
new SelectionChangedMenulist(menulist, event => {
|
||||
gMainPane.onBrowserLanguageChange(event);
|
||||
gMainPane.onPrimaryBrowserLanguageMenuChange(event);
|
||||
});
|
||||
|
||||
gMainPane.setBrowserLocales(Services.locale.appLocaleAsBCP47);
|
||||
gMainPane.updatePrimaryBrowserLanguageUI(Services.locale.appLocaleAsBCP47);
|
||||
},
|
||||
|
||||
/**
|
||||
* Update the available list of locales and select the locale that the user
|
||||
* is "selecting". This could be the currently requested locale or a locale
|
||||
* that the user would like to switch to after confirmation.
|
||||
*
|
||||
* @param {string} selected - The selected BCP 47 locale.
|
||||
*/
|
||||
async setBrowserLocales(selected) {
|
||||
async updatePrimaryBrowserLanguageUI(selected) {
|
||||
let available = await getAvailableLocales();
|
||||
let localeNames = Services.intl.getLocaleDisplayNames(
|
||||
undefined,
|
||||
|
@ -1028,7 +1030,7 @@ var gMainPane = {
|
|||
// Add an option to search for more languages if downloading is supported.
|
||||
if (Services.prefs.getBoolPref("intl.multilingual.downloadEnabled")) {
|
||||
let menuitem = document.createXULElement("menuitem");
|
||||
menuitem.id = "defaultBrowserLanguageSearch";
|
||||
menuitem.id = "primaryBrowserLocaleSearch";
|
||||
menuitem.setAttribute(
|
||||
"label",
|
||||
await document.l10n.formatValue("browser-languages-search")
|
||||
|
@ -1037,7 +1039,7 @@ var gMainPane = {
|
|||
fragment.appendChild(menuitem);
|
||||
}
|
||||
|
||||
let menulist = document.getElementById("defaultBrowserLanguage");
|
||||
let menulist = document.getElementById("primaryBrowserLocale");
|
||||
let menupopup = menulist.querySelector("menupopup");
|
||||
menupopup.textContent = "";
|
||||
menupopup.appendChild(fragment);
|
||||
|
@ -1085,15 +1087,7 @@ var gMainPane = {
|
|||
let description = document.createXULElement("description");
|
||||
description.classList.add("message-bar-description");
|
||||
|
||||
// TODO: This should preferably use `Intl.LocaleInfo` when bug 1693576 is fixed.
|
||||
if (
|
||||
i == 0 &&
|
||||
(locales[0] == "ar" ||
|
||||
locales[0] == "ckb" ||
|
||||
locales[0] == "fa" ||
|
||||
locales[0] == "he" ||
|
||||
locales[0] == "ur")
|
||||
) {
|
||||
if (i == 0 && gMainPane.getLocaleDirection(locales[0]) === "rtl") {
|
||||
description.classList.add("rtl-locale");
|
||||
}
|
||||
description.setAttribute("flex", "1");
|
||||
|
@ -1114,7 +1108,7 @@ var gMainPane = {
|
|||
}
|
||||
|
||||
messageBar.hidden = false;
|
||||
gMainPane.selectedLocales = locales;
|
||||
gMainPane.selectedLocalesForRestart = locales;
|
||||
},
|
||||
|
||||
hideConfirmLanguageChangeMessageBar() {
|
||||
|
@ -1156,24 +1150,46 @@ var gMainPane = {
|
|||
},
|
||||
|
||||
/* Show or hide the confirm change message bar based on the new locale. */
|
||||
onBrowserLanguageChange(event) {
|
||||
onPrimaryBrowserLanguageMenuChange(event) {
|
||||
let locale = event.target.value;
|
||||
|
||||
if (locale == "search") {
|
||||
gMainPane.showBrowserLanguages({ search: true });
|
||||
gMainPane.showBrowserLanguagesSubDialog({ search: true });
|
||||
return;
|
||||
} else if (locale == Services.locale.appLocaleAsBCP47) {
|
||||
this.hideConfirmLanguageChangeMessageBar();
|
||||
return;
|
||||
}
|
||||
|
||||
// Note the change in telemetry.
|
||||
gMainPane.recordBrowserLanguagesTelemetry("reorder");
|
||||
|
||||
let locales = Array.from(
|
||||
let newLocales = Array.from(
|
||||
new Set([locale, ...Services.locale.requestedLocales]).values()
|
||||
);
|
||||
this.showConfirmLanguageChangeMessageBar(locales);
|
||||
|
||||
gMainPane.recordBrowserLanguagesTelemetry("reorder");
|
||||
|
||||
switch (gMainPane.getLanguageSwitchTransitionType(newLocales)) {
|
||||
case "requires-restart":
|
||||
// Prepare to change the locales, as they were different.
|
||||
gMainPane.showConfirmLanguageChangeMessageBar(newLocales);
|
||||
gMainPane.updatePrimaryBrowserLanguageUI(newLocales[0]);
|
||||
break;
|
||||
case "live-reload":
|
||||
Services.locale.requestedLocales = newLocales;
|
||||
gMainPane.updatePrimaryBrowserLanguageUI(
|
||||
Services.locale.appLocaleAsBCP47
|
||||
);
|
||||
gMainPane.hideConfirmLanguageChangeMessageBar();
|
||||
break;
|
||||
case "locales-match":
|
||||
// They matched, so we can reset the UI.
|
||||
gMainPane.updatePrimaryBrowserLanguageUI(
|
||||
Services.locale.appLocaleAsBCP47
|
||||
);
|
||||
gMainPane.hideConfirmLanguageChangeMessageBar();
|
||||
break;
|
||||
default:
|
||||
throw new Error("Unhandled transition type.");
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
|
@ -1341,7 +1357,14 @@ var gMainPane = {
|
|||
);
|
||||
},
|
||||
|
||||
showBrowserLanguages({ search }) {
|
||||
/**
|
||||
* Open the browser languages sub dialog in either the normal mode, or search mode.
|
||||
* The search mode is only available from the menu to change the primary browser
|
||||
* language.
|
||||
*
|
||||
* @param {{ search: boolean }}
|
||||
*/
|
||||
showBrowserLanguagesSubDialog({ search }) {
|
||||
// Record the telemetry event with an id to associate related actions.
|
||||
let telemetryId = parseInt(
|
||||
Services.telemetry.msSinceProcessStart(),
|
||||
|
@ -1350,7 +1373,11 @@ var gMainPane = {
|
|||
let method = search ? "search" : "manage";
|
||||
gMainPane.recordBrowserLanguagesTelemetry(method, telemetryId);
|
||||
|
||||
let opts = { selected: gMainPane.selectedLocales, search, telemetryId };
|
||||
let opts = {
|
||||
selectedLocalesForRestart: gMainPane.selectedLocalesForRestart,
|
||||
search,
|
||||
telemetryId,
|
||||
};
|
||||
gSubDialog.open(
|
||||
"chrome://browser/content/preferences/dialogs/browserLanguages.xhtml",
|
||||
{ closingCallback: this.browserLanguagesClosed },
|
||||
|
@ -1358,25 +1385,98 @@ var gMainPane = {
|
|||
);
|
||||
},
|
||||
|
||||
/**
|
||||
* Returns the assumed script directionality for known Firefox locales. This is
|
||||
* somewhat crude, but should work until Bug 1750781 lands.
|
||||
*
|
||||
* TODO (Bug 1750781) - This should use Intl.LocaleInfo once it is standardized (see
|
||||
* Bug 1693576), rather than maintaining a hardcoded list of RTL locales.
|
||||
*
|
||||
* @param {string} locale
|
||||
* @return {"ltr" | "rtl"}
|
||||
*/
|
||||
getLocaleDirection(locale) {
|
||||
if (
|
||||
locale == "ar" ||
|
||||
locale == "ckb" ||
|
||||
locale == "fa" ||
|
||||
locale == "he" ||
|
||||
locale == "ur"
|
||||
) {
|
||||
return "rtl";
|
||||
}
|
||||
return "ltr";
|
||||
},
|
||||
|
||||
/**
|
||||
* Determine the transition strategy for switching the locale based on prefs
|
||||
* and the switched locales.
|
||||
*
|
||||
* @param {Array<string>} newLocales - List of BCP 47 locale identifiers.
|
||||
* @returns {"locales-match" | "requires-restart" | "live-reload"}
|
||||
*/
|
||||
getLanguageSwitchTransitionType(newLocales) {
|
||||
const { appLocalesAsBCP47 } = Services.locale;
|
||||
if (appLocalesAsBCP47.join(",") === newLocales.join(",")) {
|
||||
// The selected locales match, the order matters.
|
||||
return "locales-match";
|
||||
}
|
||||
|
||||
if (Services.prefs.getBoolPref("intl.multilingual.liveReload")) {
|
||||
if (
|
||||
gMainPane.getLocaleDirection(newLocales[0]) !==
|
||||
gMainPane.getLocaleDirection(appLocalesAsBCP47[0]) &&
|
||||
!Services.prefs.getBoolPref("intl.multilingual.liveReloadBidirectional")
|
||||
) {
|
||||
// Bug 1750852: The directionality of the text changed, which requires a restart
|
||||
// until the quality of the switch can be improved.
|
||||
return "requires-restart";
|
||||
}
|
||||
|
||||
return "live-reload";
|
||||
}
|
||||
|
||||
return "requires-restart";
|
||||
},
|
||||
|
||||
/* Show or hide the confirm change message bar based on the updated ordering. */
|
||||
browserLanguagesClosed() {
|
||||
let { accepted, selected } = this.gBrowserLanguagesDialog;
|
||||
let active = Services.locale.appLocalesAsBCP47;
|
||||
// When the subdialog is closed, settings are stored on gBrowserLanguagesDialog.
|
||||
// The next time the dialog is opened, a new gBrowserLanguagesDialog is created.
|
||||
let { selected } = this.gBrowserLanguagesDialog;
|
||||
|
||||
this.gBrowserLanguagesDialog.recordTelemetry(
|
||||
accepted ? "accept" : "cancel"
|
||||
selected ? "accept" : "cancel"
|
||||
);
|
||||
|
||||
// Prepare for changing the locales if they are different than the current locales.
|
||||
if (selected && selected.join(",") != active.join(",")) {
|
||||
gMainPane.showConfirmLanguageChangeMessageBar(selected);
|
||||
gMainPane.setBrowserLocales(selected[0]);
|
||||
if (!selected) {
|
||||
// No locales were selected. Cancel the operation.
|
||||
return;
|
||||
}
|
||||
|
||||
// They matched, so we can reset the UI.
|
||||
gMainPane.setBrowserLocales(Services.locale.appLocaleAsBCP47);
|
||||
gMainPane.hideConfirmLanguageChangeMessageBar();
|
||||
switch (gMainPane.getLanguageSwitchTransitionType(selected)) {
|
||||
case "requires-restart":
|
||||
gMainPane.showConfirmLanguageChangeMessageBar(selected);
|
||||
gMainPane.updatePrimaryBrowserLanguageUI(selected[0]);
|
||||
break;
|
||||
case "live-reload":
|
||||
Services.locale.requestedLocales = selected;
|
||||
|
||||
gMainPane.updatePrimaryBrowserLanguageUI(
|
||||
Services.locale.appLocaleAsBCP47
|
||||
);
|
||||
gMainPane.hideConfirmLanguageChangeMessageBar();
|
||||
break;
|
||||
case "locales-match":
|
||||
// They matched, so we can reset the UI.
|
||||
gMainPane.updatePrimaryBrowserLanguageUI(
|
||||
Services.locale.appLocaleAsBCP47
|
||||
);
|
||||
gMainPane.hideConfirmLanguageChangeMessageBar();
|
||||
break;
|
||||
default:
|
||||
throw new Error("Unhandled transition type.");
|
||||
}
|
||||
},
|
||||
|
||||
displayUseSystemLocale() {
|
||||
|
@ -1819,7 +1919,7 @@ var gMainPane = {
|
|||
Cu.reportError(error);
|
||||
await Promise.all([
|
||||
this.readUpdateAutoPref(),
|
||||
this.reportUpdatePrefWriteError(error),
|
||||
this.reportUpdatePrefWriteError(),
|
||||
]);
|
||||
return;
|
||||
}
|
||||
|
@ -1902,7 +2002,7 @@ var gMainPane = {
|
|||
} catch (error) {
|
||||
Cu.reportError(error);
|
||||
await this.readBackgroundUpdatePref();
|
||||
await this.reportUpdatePrefWriteError(error);
|
||||
await this.reportUpdatePrefWriteError();
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -1910,12 +2010,12 @@ var gMainPane = {
|
|||
}
|
||||
},
|
||||
|
||||
async reportUpdatePrefWriteError(error) {
|
||||
async reportUpdatePrefWriteError() {
|
||||
let [title, message] = await document.l10n.formatValues([
|
||||
{ id: "update-setting-write-failure-title2" },
|
||||
{
|
||||
id: "update-setting-write-failure-message2",
|
||||
args: { path: error.path },
|
||||
args: { path: UpdateUtils.configFilePath },
|
||||
},
|
||||
]);
|
||||
|
||||
|
|
|
@ -35,7 +35,7 @@ var gMoreFromMozillaPane = {
|
|||
return this._option;
|
||||
},
|
||||
|
||||
getURL(url, option, hasEmail) {
|
||||
getURL(url, region, option, hasEmail) {
|
||||
const URL_PARAMS = {
|
||||
utm_source: "about-prefs",
|
||||
utm_campaign: "morefrommozilla",
|
||||
|
@ -44,21 +44,23 @@ var gMoreFromMozillaPane = {
|
|||
// UTM content param used in analytics to record
|
||||
// UI template used to open URL
|
||||
const utm_content = {
|
||||
default: "fxvt-default",
|
||||
simple: "fxvt-113-a-na",
|
||||
advanced: "fxvt-113-b-na",
|
||||
default: "default",
|
||||
simple: "fxvt-113-a",
|
||||
advanced: "fxvt-113-b",
|
||||
};
|
||||
|
||||
let pageUrl = new URL(url);
|
||||
for (let [key, val] of Object.entries(URL_PARAMS)) {
|
||||
pageUrl.searchParams.append(key, val);
|
||||
}
|
||||
// Append '-email' to utm_content when URL is opened
|
||||
|
||||
// Append region by product to utm_cotent and also
|
||||
// append '-email' when URL is opened
|
||||
// from send email link in QRCode box
|
||||
if (option) {
|
||||
pageUrl.searchParams.set(
|
||||
"utm_content",
|
||||
`${utm_content[option]}${hasEmail ? "-email" : ""}`
|
||||
`${utm_content[option]}-${region}${hasEmail ? "-email" : ""}`
|
||||
);
|
||||
}
|
||||
return pageUrl.toString();
|
||||
|
@ -70,6 +72,7 @@ var gMoreFromMozillaPane = {
|
|||
id: "firefox-mobile",
|
||||
title_string_id: "more-from-moz-firefox-mobile-title",
|
||||
description_string_id: "more-from-moz-firefox-mobile-description",
|
||||
region: "global",
|
||||
button: {
|
||||
id: "fxMobile",
|
||||
type: "link",
|
||||
|
@ -102,6 +105,7 @@ var gMoreFromMozillaPane = {
|
|||
id: "mozilla-vpn",
|
||||
title_string_id: "more-from-moz-mozilla-vpn-title",
|
||||
description_string_id: "more-from-moz-mozilla-vpn-description",
|
||||
region: "global",
|
||||
button: {
|
||||
id: "mozillaVPN",
|
||||
label_string_id: "more-from-moz-button-mozilla-vpn",
|
||||
|
@ -116,6 +120,7 @@ var gMoreFromMozillaPane = {
|
|||
id: "mozilla-rally",
|
||||
title_string_id: "more-from-moz-mozilla-rally-title",
|
||||
description_string_id: "more-from-moz-mozilla-rally-description",
|
||||
region: "na",
|
||||
button: {
|
||||
id: "mozillaRally",
|
||||
label_string_id: "more-from-moz-button-mozilla-rally",
|
||||
|
@ -175,7 +180,7 @@ var gMoreFromMozillaPane = {
|
|||
if (isLink) {
|
||||
actionElement.setAttribute(
|
||||
"href",
|
||||
this.getURL(product.button.actionURL, this.option)
|
||||
this.getURL(product.button.actionURL, product.region, this.option)
|
||||
);
|
||||
actionElement.setAttribute("target", "_blank");
|
||||
} else {
|
||||
|
@ -184,6 +189,7 @@ var gMoreFromMozillaPane = {
|
|||
mainWindow.openTrustedLinkIn(
|
||||
gMoreFromMozillaPane.getURL(
|
||||
product.button.actionURL,
|
||||
product.region,
|
||||
gMoreFromMozillaPane.option
|
||||
),
|
||||
"tab"
|
||||
|
@ -229,7 +235,12 @@ var gMoreFromMozillaPane = {
|
|||
);
|
||||
qrc_btn.setAttribute(
|
||||
"href",
|
||||
this.getURL(product.qrcode.button.actionURL, this.option, true)
|
||||
this.getURL(
|
||||
product.qrcode.button.actionURL,
|
||||
product.region,
|
||||
this.option,
|
||||
true
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
|
|
|
@ -12,8 +12,8 @@
|
|||
/* import-globals-from experimental.js */
|
||||
/* import-globals-from moreFromMozilla.js */
|
||||
/* import-globals-from findInPage.js */
|
||||
/* import-globals-from ../../base/content/utilityOverlay.js */
|
||||
/* import-globals-from ../../../toolkit/content/preferencesBindings.js */
|
||||
/* import-globals-from /browser/base/content/utilityOverlay.js */
|
||||
/* import-globals-from /toolkit/content/preferencesBindings.js */
|
||||
|
||||
"use strict";
|
||||
|
||||
|
|
|
@ -223,8 +223,8 @@ async function selectLocale(localeCode, available, selected, dialogDoc) {
|
|||
async function openDialog(doc, search = false) {
|
||||
let dialogLoaded = promiseLoadSubDialog(BROWSER_LANGUAGES_URL);
|
||||
if (search) {
|
||||
doc.getElementById("defaultBrowserLanguageSearch").doCommand();
|
||||
doc.getElementById("defaultBrowserLanguage").menupopup.hidePopup();
|
||||
doc.getElementById("primaryBrowserLocaleSearch").doCommand();
|
||||
doc.getElementById("primaryBrowserLocale").menupopup.hidePopup();
|
||||
} else {
|
||||
doc.getElementById("manageBrowserLanguagesButton").doCommand();
|
||||
}
|
||||
|
@ -246,6 +246,8 @@ add_task(async function testDisabledBrowserLanguages() {
|
|||
set: [
|
||||
["intl.multilingual.enabled", true],
|
||||
["intl.multilingual.downloadEnabled", true],
|
||||
["intl.multilingual.liveReload", false],
|
||||
["intl.multilingual.liveReloadBidirectional", false],
|
||||
["intl.locale.requested", "en-US,pl,he,de"],
|
||||
["extensions.langpacks.signatures.required", false],
|
||||
["extensions.getAddons.langpacks.url", langpacksUrl],
|
||||
|
@ -341,6 +343,8 @@ add_task(async function testReorderingBrowserLanguages() {
|
|||
set: [
|
||||
["intl.multilingual.enabled", true],
|
||||
["intl.multilingual.downloadEnabled", true],
|
||||
["intl.multilingual.liveReload", false],
|
||||
["intl.multilingual.liveReloadBidirectional", false],
|
||||
["intl.locale.requested", "en-US,pl,he,de"],
|
||||
["extensions.langpacks.signatures.required", false],
|
||||
],
|
||||
|
@ -441,6 +445,8 @@ add_task(async function testAddAndRemoveSelectedLanguages() {
|
|||
set: [
|
||||
["intl.multilingual.enabled", true],
|
||||
["intl.multilingual.downloadEnabled", true],
|
||||
["intl.multilingual.liveReload", false],
|
||||
["intl.multilingual.liveReloadBidirectional", false],
|
||||
["intl.locale.requested", "en-US"],
|
||||
["extensions.langpacks.signatures.required", false],
|
||||
],
|
||||
|
@ -550,6 +556,8 @@ add_task(async function testInstallFromAMO() {
|
|||
set: [
|
||||
["intl.multilingual.enabled", true],
|
||||
["intl.multilingual.downloadEnabled", true],
|
||||
["intl.multilingual.liveReload", false],
|
||||
["intl.multilingual.liveReloadBidirectional", false],
|
||||
["intl.locale.requested", "en-US"],
|
||||
["extensions.getAddons.langpacks.url", langpacksUrl],
|
||||
["extensions.langpacks.signatures.required", false],
|
||||
|
@ -565,6 +573,17 @@ add_task(async function testInstallFromAMO() {
|
|||
let messageBar = doc.getElementById("confirmBrowserLanguage");
|
||||
is(messageBar.hidden, true, "The message bar is hidden at first");
|
||||
|
||||
// Verify only en-US is listed on the main pane.
|
||||
let getMainPaneLocales = () => {
|
||||
let available = doc.getElementById("primaryBrowserLocale");
|
||||
let availableLocales = Array.from(available.menupopup.children);
|
||||
return availableLocales
|
||||
.map(item => item.value)
|
||||
.sort()
|
||||
.join(",");
|
||||
};
|
||||
is(getMainPaneLocales(), "en-US,search", "Only en-US installed to start");
|
||||
|
||||
// Open the dialog.
|
||||
let { dialog, dialogDoc, available, selected } = await openDialog(doc, true);
|
||||
let firstDialogId = getDialogId(dialogDoc);
|
||||
|
@ -647,6 +666,9 @@ add_task(async function testInstallFromAMO() {
|
|||
dialog.acceptDialog();
|
||||
await dialogClosed;
|
||||
|
||||
// Verify pl is now available to select.
|
||||
is(getMainPaneLocales(), "en-US,pl,search", "en-US and pl now available");
|
||||
|
||||
// Disable the Polish langpack.
|
||||
langpack = await AddonManager.getAddonByID("langpack-pl@firefox.mozilla.org");
|
||||
await langpack.disable();
|
||||
|
@ -695,6 +717,8 @@ add_task(async function testDownloadEnabled() {
|
|||
set: [
|
||||
["intl.multilingual.enabled", true],
|
||||
["intl.multilingual.downloadEnabled", true],
|
||||
["intl.multilingual.liveReload", false],
|
||||
["intl.multilingual.liveReloadBidirectional", false],
|
||||
],
|
||||
});
|
||||
|
||||
|
@ -703,7 +727,7 @@ add_task(async function testDownloadEnabled() {
|
|||
});
|
||||
let doc = gBrowser.contentDocument;
|
||||
|
||||
let defaultMenulist = doc.getElementById("defaultBrowserLanguage");
|
||||
let defaultMenulist = doc.getElementById("primaryBrowserLocale");
|
||||
ok(
|
||||
hasSearchOption(defaultMenulist.menupopup),
|
||||
"There's a search option in the General pane"
|
||||
|
@ -723,6 +747,8 @@ add_task(async function testDownloadDisabled() {
|
|||
set: [
|
||||
["intl.multilingual.enabled", true],
|
||||
["intl.multilingual.downloadEnabled", false],
|
||||
["intl.multilingual.liveReload", false],
|
||||
["intl.multilingual.liveReloadBidirectional", false],
|
||||
],
|
||||
});
|
||||
|
||||
|
@ -731,7 +757,7 @@ add_task(async function testDownloadDisabled() {
|
|||
});
|
||||
let doc = gBrowser.contentDocument;
|
||||
|
||||
let defaultMenulist = doc.getElementById("defaultBrowserLanguage");
|
||||
let defaultMenulist = doc.getElementById("primaryBrowserLocale");
|
||||
ok(
|
||||
!hasSearchOption(defaultMenulist.menupopup),
|
||||
"There's no search option in the General pane"
|
||||
|
@ -751,6 +777,8 @@ add_task(async function testReorderMainPane() {
|
|||
set: [
|
||||
["intl.multilingual.enabled", true],
|
||||
["intl.multilingual.downloadEnabled", false],
|
||||
["intl.multilingual.liveReload", false],
|
||||
["intl.multilingual.liveReloadBidirectional", false],
|
||||
["intl.locale.requested", "en-US"],
|
||||
["extensions.langpacks.signatures.required", false],
|
||||
],
|
||||
|
@ -775,7 +803,7 @@ add_task(async function testReorderMainPane() {
|
|||
let messageBar = doc.getElementById("confirmBrowserLanguage");
|
||||
is(messageBar.hidden, true, "The message bar is hidden at first");
|
||||
|
||||
let available = doc.getElementById("defaultBrowserLanguage");
|
||||
let available = doc.getElementById("primaryBrowserLocale");
|
||||
let availableLocales = Array.from(available.menupopup.children);
|
||||
let availableCodes = availableLocales
|
||||
.map(item => item.value)
|
||||
|
@ -789,8 +817,7 @@ add_task(async function testReorderMainPane() {
|
|||
|
||||
is(available.selectedItem.value, "en-US", "English is selected");
|
||||
|
||||
let hebrew =
|
||||
availableLocales[availableLocales.findIndex(item => item.value == "he")];
|
||||
let hebrew = availableLocales.find(item => item.value == "he");
|
||||
hebrew.click();
|
||||
available.menupopup.hidePopup();
|
||||
|
||||
|
@ -811,3 +838,222 @@ add_task(async function testReorderMainPane() {
|
|||
|
||||
assertTelemetryRecorded([["reorder", "main"]]);
|
||||
});
|
||||
|
||||
add_task(async function testLiveLanguageReloading() {
|
||||
await SpecialPowers.pushPrefEnv({
|
||||
set: [
|
||||
["intl.multilingual.enabled", true],
|
||||
["intl.multilingual.downloadEnabled", true],
|
||||
["intl.multilingual.liveReload", true],
|
||||
["intl.multilingual.liveReloadBidirectional", false],
|
||||
["intl.locale.requested", "en-US,fr,he,de"],
|
||||
["extensions.langpacks.signatures.required", false],
|
||||
],
|
||||
});
|
||||
|
||||
// Clear the telemetry from other tests.
|
||||
Services.telemetry.clearEvents();
|
||||
|
||||
let langpacks = await createTestLangpacks();
|
||||
let addons = await Promise.all(
|
||||
langpacks.map(async ([locale, file]) => {
|
||||
let install = await AddonTestUtils.promiseInstallFile(file);
|
||||
return install.addon;
|
||||
})
|
||||
);
|
||||
|
||||
await openPreferencesViaOpenPreferencesAPI("paneGeneral", {
|
||||
leaveOpen: true,
|
||||
});
|
||||
|
||||
let doc = gBrowser.contentDocument;
|
||||
|
||||
let available = doc.getElementById("primaryBrowserLocale");
|
||||
let availableLocales = Array.from(available.menupopup.children);
|
||||
|
||||
is(
|
||||
Services.locale.appLocaleAsBCP47,
|
||||
"en-US",
|
||||
"The app locale starts as English."
|
||||
);
|
||||
|
||||
Assert.deepEqual(
|
||||
Services.locale.requestedLocales,
|
||||
["en-US", "fr", "he", "de"],
|
||||
"The locale order starts as what was initially requested."
|
||||
);
|
||||
|
||||
// French and English are both LTR languages.
|
||||
let french = availableLocales.find(item => item.value == "fr");
|
||||
|
||||
french.click();
|
||||
available.menupopup.hidePopup();
|
||||
|
||||
is(
|
||||
Services.locale.appLocaleAsBCP47,
|
||||
"fr",
|
||||
"The app locale was changed to French"
|
||||
);
|
||||
|
||||
Assert.deepEqual(
|
||||
Services.locale.requestedLocales,
|
||||
["fr", "en-US", "he", "de"],
|
||||
"The locale order is switched to french first."
|
||||
);
|
||||
|
||||
await Promise.all(addons.map(addon => addon.uninstall()));
|
||||
BrowserTestUtils.removeTab(gBrowser.selectedTab);
|
||||
|
||||
assertTelemetryRecorded([["reorder", "main"]]);
|
||||
});
|
||||
|
||||
add_task(async function testLiveLanguageReloadingBidiOff() {
|
||||
await SpecialPowers.pushPrefEnv({
|
||||
set: [
|
||||
["intl.multilingual.enabled", true],
|
||||
["intl.multilingual.downloadEnabled", true],
|
||||
["intl.multilingual.liveReload", true],
|
||||
["intl.multilingual.liveReloadBidirectional", false],
|
||||
["intl.locale.requested", "en-US,fr,he,de"],
|
||||
["extensions.langpacks.signatures.required", false],
|
||||
],
|
||||
});
|
||||
|
||||
// Clear the telemetry from other tests.
|
||||
Services.telemetry.clearEvents();
|
||||
|
||||
let langpacks = await createTestLangpacks();
|
||||
let addons = await Promise.all(
|
||||
langpacks.map(async ([locale, file]) => {
|
||||
let install = await AddonTestUtils.promiseInstallFile(file);
|
||||
return install.addon;
|
||||
})
|
||||
);
|
||||
|
||||
await openPreferencesViaOpenPreferencesAPI("paneGeneral", {
|
||||
leaveOpen: true,
|
||||
});
|
||||
|
||||
let doc = gBrowser.contentDocument;
|
||||
|
||||
let available = doc.getElementById("primaryBrowserLocale");
|
||||
let availableLocales = Array.from(available.menupopup.children);
|
||||
|
||||
is(
|
||||
Services.locale.appLocaleAsBCP47,
|
||||
"en-US",
|
||||
"The app locale starts as English."
|
||||
);
|
||||
|
||||
Assert.deepEqual(
|
||||
Services.locale.requestedLocales,
|
||||
["en-US", "fr", "he", "de"],
|
||||
"The locale order starts as what was initially requested."
|
||||
);
|
||||
|
||||
let messageBar = doc.getElementById("confirmBrowserLanguage");
|
||||
is(messageBar.hidden, true, "The message bar is hidden at first");
|
||||
|
||||
// English is LTR and Hebrew is RTL.
|
||||
let hebrew = availableLocales.find(item => item.value == "he");
|
||||
|
||||
hebrew.click();
|
||||
available.menupopup.hidePopup();
|
||||
|
||||
await BrowserTestUtils.waitForCondition(
|
||||
() => !messageBar.hidden,
|
||||
"Wait for message bar to show"
|
||||
);
|
||||
|
||||
is(messageBar.hidden, false, "The message bar is now shown");
|
||||
|
||||
is(
|
||||
Services.locale.appLocaleAsBCP47,
|
||||
"en-US",
|
||||
"The app locale remains in English"
|
||||
);
|
||||
|
||||
Assert.deepEqual(
|
||||
Services.locale.requestedLocales,
|
||||
["en-US", "fr", "he", "de"],
|
||||
"The locale order did not change."
|
||||
);
|
||||
|
||||
await Promise.all(addons.map(addon => addon.uninstall()));
|
||||
BrowserTestUtils.removeTab(gBrowser.selectedTab);
|
||||
|
||||
assertTelemetryRecorded([["reorder", "main"]]);
|
||||
});
|
||||
|
||||
add_task(async function testLiveLanguageReloadingBidiOn() {
|
||||
await SpecialPowers.pushPrefEnv({
|
||||
set: [
|
||||
["intl.multilingual.enabled", true],
|
||||
["intl.multilingual.downloadEnabled", true],
|
||||
["intl.multilingual.liveReload", true],
|
||||
["intl.multilingual.liveReloadBidirectional", true],
|
||||
["intl.locale.requested", "en-US,fr,he,de"],
|
||||
["extensions.langpacks.signatures.required", false],
|
||||
],
|
||||
});
|
||||
|
||||
// Clear the telemetry from other tests.
|
||||
Services.telemetry.clearEvents();
|
||||
|
||||
let langpacks = await createTestLangpacks();
|
||||
let addons = await Promise.all(
|
||||
langpacks.map(async ([locale, file]) => {
|
||||
let install = await AddonTestUtils.promiseInstallFile(file);
|
||||
return install.addon;
|
||||
})
|
||||
);
|
||||
|
||||
await openPreferencesViaOpenPreferencesAPI("paneGeneral", {
|
||||
leaveOpen: true,
|
||||
});
|
||||
|
||||
let doc = gBrowser.contentDocument;
|
||||
|
||||
let available = doc.getElementById("primaryBrowserLocale");
|
||||
let availableLocales = Array.from(available.menupopup.children);
|
||||
|
||||
is(
|
||||
Services.locale.appLocaleAsBCP47,
|
||||
"en-US",
|
||||
"The app locale starts as English."
|
||||
);
|
||||
|
||||
Assert.deepEqual(
|
||||
Services.locale.requestedLocales,
|
||||
["en-US", "fr", "he", "de"],
|
||||
"The locale order starts as what was initially requested."
|
||||
);
|
||||
|
||||
let messageBar = doc.getElementById("confirmBrowserLanguage");
|
||||
is(messageBar.hidden, true, "The message bar is hidden at first");
|
||||
|
||||
// English is LTR and Hebrew is RTL.
|
||||
let hebrew = availableLocales.find(item => item.value == "he");
|
||||
|
||||
hebrew.click();
|
||||
available.menupopup.hidePopup();
|
||||
|
||||
is(messageBar.hidden, true, "The message bar is still hidden");
|
||||
|
||||
is(
|
||||
Services.locale.appLocaleAsBCP47,
|
||||
"he",
|
||||
"The app locale was changed to Hebrew."
|
||||
);
|
||||
|
||||
Assert.deepEqual(
|
||||
Services.locale.requestedLocales,
|
||||
["he", "en-US", "fr", "de"],
|
||||
"The locale changed with Hebrew first."
|
||||
);
|
||||
|
||||
await Promise.all(addons.map(addon => addon.uninstall()));
|
||||
BrowserTestUtils.removeTab(gBrowser.selectedTab);
|
||||
|
||||
assertTelemetryRecorded([["reorder", "main"]]);
|
||||
});
|
||||
|
|
|
@ -222,7 +222,7 @@ add_task(async function test_aboutpreferences_clickBtnVPN() {
|
|||
);
|
||||
Assert.equal(
|
||||
searchParams.get("utm_content"),
|
||||
"fxvt-113-a-na",
|
||||
"fxvt-113-a-global",
|
||||
"utm_content set"
|
||||
);
|
||||
|
||||
|
@ -241,6 +241,66 @@ add_task(async function test_aboutpreferences_clickBtnVPN() {
|
|||
BrowserTestUtils.removeTab(tab);
|
||||
});
|
||||
|
||||
add_task(async function test_aboutpreferences_clickBtnMobile() {
|
||||
await SpecialPowers.pushPrefEnv({
|
||||
set: [
|
||||
["browser.preferences.moreFromMozilla", true],
|
||||
["browser.preferences.moreFromMozilla.template", "simple"],
|
||||
],
|
||||
});
|
||||
await openPreferencesViaOpenPreferencesAPI("paneMoreFromMozilla", {
|
||||
leaveOpen: true,
|
||||
});
|
||||
|
||||
let doc = gBrowser.contentDocument;
|
||||
let tab = gBrowser.selectedTab;
|
||||
|
||||
let productCards = doc.querySelectorAll("vbox.simple");
|
||||
Assert.ok(productCards, "Simple template loaded");
|
||||
|
||||
const expectedUrl = "https://www.mozilla.org/firefox/browsers/mobile/";
|
||||
|
||||
let mobileUrl = new URL(doc.getElementById("simple-fxMobile").href);
|
||||
|
||||
Assert.ok(mobileUrl.href.startsWith(expectedUrl));
|
||||
|
||||
let searchParams = mobileUrl.searchParams;
|
||||
Assert.equal(
|
||||
searchParams.get("utm_source"),
|
||||
"about-prefs",
|
||||
"expected utm_source sent"
|
||||
);
|
||||
Assert.equal(
|
||||
searchParams.get("utm_campaign"),
|
||||
"morefrommozilla",
|
||||
"utm_campaign set"
|
||||
);
|
||||
Assert.equal(
|
||||
searchParams.get("utm_medium"),
|
||||
"firefox-desktop",
|
||||
"utm_medium set"
|
||||
);
|
||||
Assert.equal(
|
||||
searchParams.get("utm_content"),
|
||||
"fxvt-113-a-global",
|
||||
"default-global",
|
||||
"utm_content set"
|
||||
);
|
||||
|
||||
// Since we're not running MfM experiments in this release, we want to be sure that
|
||||
// our URL params aren't claiming that we are.
|
||||
Assert.ok(
|
||||
!searchParams.has("entrypoint_variation"),
|
||||
"entrypoint_variation should not be set"
|
||||
);
|
||||
Assert.ok(
|
||||
!searchParams.has("entrypoint_experiment"),
|
||||
"entrypoint_experiment should not be set"
|
||||
);
|
||||
|
||||
BrowserTestUtils.removeTab(tab);
|
||||
});
|
||||
|
||||
add_task(async function test_aboutpreferences_search() {
|
||||
await SpecialPowers.pushPrefEnv({
|
||||
set: [
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
<!-- This Source Code Form is subject to the terms of the Mozilla Public
|
||||
- License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
- file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
|
||||
<svg id="Layer_1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 46 46"><path id="bg" d="M7 42h32V5.1H7z" fill="context-stroke blue"/><g id="frame" transform="translate(0 6)"><path d="M40 5c.5 0 1 .4 1 1v24c0 .5-.5 1-1 1H6c-.6 0-1-.5-1-1V6c0-.6.4-1 1-1h34zM7 29h32V7H7v22z" fill="context-fill orange"/><path id="Fill-4" fill="context-fill red" d="M7 7h32V5H7z"/><path id="Fill-6" fill="context-fill red" d="M7 31h32v-2H7z"/></g><path id="dash" d="M38 11h1V9h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm-1 1h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-2-3H7v3h2v-1H8v-2zm-1-1h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1V9H7v2zm2-6H7v3h1V6h1V5zm1 1h2V5h-2v1zm3 0h2V5h-2v1zm3 0h2V5h-2v1zm3 0h2V5h-2v1zm3 0h2V5h-2v1zm3 0h2V5h-2v1zm3 0h2V5h-2v1zm3 0h2V5h-2v1zm3 0h2V5h-2v1zm5-1h-2v1h1v2h1V5z" fill="context-fill pink" opacity="0.5"/></svg>
|
||||
<svg id="Layer_1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 46 46"><path id="bg" d="M7 42h32V5.1H7z" fill="context-stroke #00fdff"/><g id="frame" transform="translate(0 6)"><path d="M40 5c.5 0 1 .4 1 1v24c0 .5-.5 1-1 1H6c-.6 0-1-.5-1-1V6c0-.6.4-1 1-1h34zM7 29h32V7H7v22z" fill="context-fill"/><path id="Fill-4" fill="context-fill" d="M7 7h32V5H7z"/><path id="Fill-6" fill="context-fill" d="M7 31h32v-2H7z"/></g><path id="dash" d="M38 11h1V9h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm-1 1h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-2-3H7v3h2v-1H8v-2zm-1-1h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1V9H7v2zm2-6H7v3h1V6h1V5zm1 1h2V5h-2v1zm3 0h2V5h-2v1zm3 0h2V5h-2v1zm3 0h2V5h-2v1zm3 0h2V5h-2v1zm3 0h2V5h-2v1zm3 0h2V5h-2v1zm3 0h2V5h-2v1zm3 0h2V5h-2v1zm5-1h-2v1h1v2h1V5z" fill="context-fill" opacity="0.5"/></svg>
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |
|
@ -1,4 +1,4 @@
|
|||
<!-- This Source Code Form is subject to the terms of the Mozilla Public
|
||||
- License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
- file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 46 46"><path d="M5 12c0-.6.5-1 1-1h34c.6 0 1 .5 1 1v24c0 .6-.5 1-1 1H6c-.6 0-1-.5-1-1V12zm2 23V13h32v22H7z" fill="context-fill"/><path d="M7 35h32V13H7z" fill="context-stroke blue"/><path id="dash" d="M38 19h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm-1 1h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-2-3H7v3h2v-1H8v-2zm-1-1h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm2-6H7v3h1v-2h1v-1zm1 1h2v-1h-2v1zm3 0h2v-1h-2v1zm3 0h2v-1h-2v1zm3 0h2v-1h-2v1zm3 0h2v-1h-2v1zm3 0h2v-1h-2v1zm3 0h2v-1h-2v1zm3 0h2v-1h-2v1zm3 0h2v-1h-2v1zm5-1h-2v1h1v2h1v-3z" fill="context-fill" opacity="0.5"/></svg>
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 46 46"><path d="M5 12c0-.6.5-1 1-1h34c.6 0 1 .5 1 1v24c0 .6-.5 1-1 1H6c-.6 0-1-.5-1-1V12zm2 23V13h32v22H7z" fill="context-fill"/><path d="M7 35h32V13H7z" fill="context-stroke #00fdff"/><path id="dash" d="M38 19h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm0 3h1v-2h-1v2zm-1 1h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-3 0h2v-1h-2v1zm-2-3H7v3h2v-1H8v-2zm-1-1h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm0-3h1v-2H7v2zm2-6H7v3h1v-2h1v-1zm1 1h2v-1h-2v1zm3 0h2v-1h-2v1zm3 0h2v-1h-2v1zm3 0h2v-1h-2v1zm3 0h2v-1h-2v1zm3 0h2v-1h-2v1zm3 0h2v-1h-2v1zm3 0h2v-1h-2v1zm3 0h2v-1h-2v1zm5-1h-2v1h1v2h1v-3z" fill="context-fill" opacity="0.5"/></svg>
|
Before Width: | Height: | Size: 1 KiB After Width: | Height: | Size: 1 KiB |
|
@ -2,7 +2,7 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
|
||||
* You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
/* import-globals-from ../../../base/content/utilityOverlay.js */
|
||||
/* import-globals-from /browser/base/content/utilityOverlay.js */
|
||||
|
||||
var gSetBackground = {
|
||||
_position: AppConstants.platform == "macosx" ? "STRETCH" : "",
|
||||
|
|
|
@ -194,7 +194,7 @@ Changelog
|
|||
``browser.urlbar.suggest.quicksuggest.nonsponsored``, and this event now
|
||||
corresponds to the latter pref. [Bug 1735976_]
|
||||
|
||||
Firefox 96:
|
||||
Firefox 96.0:
|
||||
The event is no longer recorded when the user interacts with the online
|
||||
modal dialog since the ``browser.urlbar.suggest.quicksuggest.nonsponsored``
|
||||
pref is no longer set when the user opts in or out. [Bug 1740965_]
|
||||
|
@ -211,7 +211,7 @@ The event's objects are the following:
|
|||
|
||||
:accept:
|
||||
The user accepted the dialog and opted in. This object was removed in Firefox
|
||||
96.0.1.
|
||||
96.0.2.
|
||||
:accept_2:
|
||||
The user accepted the dialog and opted in.
|
||||
:close_1:
|
||||
|
@ -225,15 +225,15 @@ The event's objects are the following:
|
|||
on main section. The user remains opted out in this case.
|
||||
:dismissed_escape_key:
|
||||
The user dismissed the dialog by pressing the Escape key. The user remains
|
||||
opted out in this case. This object was removed in Firefox 96.0.1.
|
||||
opted out in this case. This object was removed in Firefox 96.0.2.
|
||||
:dismissed_other:
|
||||
The dialog was dismissed in some unknown way. One case where this can happen
|
||||
is when the dialog is replaced with another higher priority dialog like the
|
||||
one shown when quitting the app. The user remains opted out in this case.
|
||||
This object was removed in Firefox 96.0.1.
|
||||
This object was removed in Firefox 96.0.2.
|
||||
:learn_more:
|
||||
The user clicked "Learn more". The user remains opted out in this case. This
|
||||
object was removed in Firefox 96.0.1.
|
||||
object was removed in Firefox 96.0.2.
|
||||
:learn_more_2:
|
||||
The user clicked "Learn more". The user remains opted out in this case.
|
||||
:not_now:
|
||||
|
@ -244,12 +244,12 @@ The event's objects are the following:
|
|||
this case.
|
||||
:not_now_link:
|
||||
The user clicked "Not now". The user remains opted out in this case. This
|
||||
object was removed in Firefox 96.0.1.
|
||||
object was removed in Firefox 96.0.2.
|
||||
:reject_2:
|
||||
The user rejected the dialog and opted out.
|
||||
:settings:
|
||||
The user clicked the "Customize" button. The user remains opted out in this
|
||||
case. This object was removed in Firefox 96.0.1.
|
||||
case. This object was removed in Firefox 96.0.2.
|
||||
|
||||
Changelog
|
||||
Firefox 92.0.1
|
||||
|
@ -262,7 +262,7 @@ Changelog
|
|||
``dismissed_other``, ``learn_more``, ``not_now_link``, and ``settings``.
|
||||
[Bug 1733687_]
|
||||
|
||||
Firefox 96.0.1
|
||||
Firefox 96.0.2
|
||||
Objects changed to: ``accept_2``, ``reject_2``, ``learn_more_2``,
|
||||
``close_1``, ``not_now_2``, ``dismiss_1`` and ``dismiss_2``.
|
||||
[Bug 1745026_]
|
||||
|
@ -292,7 +292,7 @@ Changelog
|
|||
Firefox 92.0.1
|
||||
Introduced. [Bug 1728430_]
|
||||
|
||||
Firefox 96:
|
||||
Firefox 96.0:
|
||||
The event is no longer recorded when the user interacts with the online
|
||||
modal dialog since the ``browser.urlbar.suggest.quicksuggest.sponsored``
|
||||
pref is no longer set when the user opts in or out. [Bug 1740965_]
|
||||
|
@ -318,7 +318,7 @@ string-valued pref with the following possible values:
|
|||
The user has not made a choice (e.g., because the dialog hasn't been shown).
|
||||
:accept:
|
||||
The user accepted the dialog and opted in. This object was removed in Firefox
|
||||
96.0.1.
|
||||
96.0.2.
|
||||
:accept_2:
|
||||
The user accepted the dialog and opted in.
|
||||
:close_1:
|
||||
|
@ -332,15 +332,15 @@ string-valued pref with the following possible values:
|
|||
on main section. The user remains opted out in this case.
|
||||
:dismissed_escape_key:
|
||||
The user dismissed the dialog by pressing the Escape key. The user remains
|
||||
opted out in this case. This object was removed in Firefox 96.0.1.
|
||||
opted out in this case. This object was removed in Firefox 96.0.2.
|
||||
:dismissed_other:
|
||||
The dialog was dismissed in some unknown way. One case where this can happen
|
||||
is when the dialog is replaced with another higher priority dialog like the
|
||||
one shown when quitting the app. The user remains opted out in this case. This
|
||||
object was removed in Firefox 96.0.1.
|
||||
object was removed in Firefox 96.0.2.
|
||||
:learn_more:
|
||||
The user clicked "Learn more". The user remains opted out in this case. This
|
||||
object was removed in Firefox 96.0.1.
|
||||
object was removed in Firefox 96.0.2.
|
||||
:learn_more_2:
|
||||
The user clicked "Learn more". The user remains opted out in this case.
|
||||
:not_now_2:
|
||||
|
@ -348,18 +348,18 @@ string-valued pref with the following possible values:
|
|||
this case.
|
||||
:not_now_link:
|
||||
The user clicked "Not now". The user remains opted out in this case. This
|
||||
object was removed in Firefox 96.0.1.
|
||||
object was removed in Firefox 96.0.2.
|
||||
:reject_2:
|
||||
The user rejected the dialog and opted out.
|
||||
:settings:
|
||||
The user clicked the "Customize" button. The user remains opted out in this
|
||||
case. This object was removed in Firefox 96.0.1.
|
||||
case. This object was removed in Firefox 96.0.2.
|
||||
|
||||
Changelog
|
||||
Firefox 94.0
|
||||
Introduced. [Bug 1734447_]
|
||||
|
||||
Firefox 96.0.1
|
||||
Firefox 96.0.2
|
||||
Added ``accept_2``, ``reject_2``, ``learn_more_2``, ``close_1``,
|
||||
``not_now_2``, ``dismiss_1``, ``dismiss_2`` and removed ``accept``,
|
||||
``dismissed_escape_key``, ``dismissed_other``, ``learn_more``,
|
||||
|
@ -412,7 +412,7 @@ Changelog
|
|||
Introduced. It replaces ``browser.urlbar.suggest.quicksuggest``. [Bug
|
||||
1735976_]
|
||||
|
||||
Firefox 96:
|
||||
Firefox 96.0:
|
||||
The pref is now true by default in the online scenario. Previously it was
|
||||
false by default in online. For users who were enrolled in the online
|
||||
scenario in older versions and who did not opt in or otherwise enable
|
||||
|
@ -434,7 +434,7 @@ Changelog
|
|||
Firefox 92.0.1
|
||||
Introduced. [Bug 1730721_]
|
||||
|
||||
Firefox 96:
|
||||
Firefox 96.0:
|
||||
The pref is now true by default in the online scenario. Previously it was
|
||||
false by default in online. For users who were enrolled in the online
|
||||
scenario in older versions and who did not opt in or otherwise enable
|
||||
|
|
|
@ -14,4 +14,5 @@ prefs =
|
|||
media.videocontrols.picture-in-picture.video-toggle.position="right"
|
||||
|
||||
[browser_mock_wrapper.js]
|
||||
skip-if = debug # Bug 1749819
|
||||
skip-if =
|
||||
debug || !nightly_build # Bug 1749819
|
||||
|
|
|
@ -36,15 +36,32 @@ downloads-cmd-show-menuitem-2 =
|
|||
}
|
||||
.accesskey = F
|
||||
|
||||
## Displayed in the downloads context menu for files that can be opened.
|
||||
## Variables:
|
||||
## $handler (String) - The name of the mime type's default file handler.
|
||||
## Example: "Notepad", "Acrobat Reader DC", "7-Zip File Manager"
|
||||
|
||||
downloads-cmd-use-system-default =
|
||||
.label = Open In System Viewer
|
||||
.accesskey = V
|
||||
.accesskey = I
|
||||
# This version is shown when the download's mime type has a valid file handler.
|
||||
downloads-cmd-use-system-default-named =
|
||||
.label = Open In { $handler }
|
||||
.accesskey = I
|
||||
|
||||
# We can use the same accesskey as downloads-cmd-always-open-similar-files.
|
||||
# Both should not be visible in the downloads context menu at the same time.
|
||||
downloads-cmd-always-use-system-default =
|
||||
.label = Always Open In System Viewer
|
||||
.accesskey = w
|
||||
# We can use the same accesskey as downloads-cmd-always-open-similar-files.
|
||||
# Both should not be visible in the downloads context menu at the same time.
|
||||
# This version is shown when the download's mime type has a valid file handler.
|
||||
downloads-cmd-always-use-system-default-named =
|
||||
.label = Always Open In { $handler }
|
||||
.accesskey = w
|
||||
|
||||
##
|
||||
|
||||
# We can use the same accesskey as downloads-cmd-always-use-system-default.
|
||||
# Both should not be visible in the downloads context menu at the same time.
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue