@activecollab/components 2.0.575 → 2.0.576
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/components/Popper/Popper.js +14 -0
- package/dist/cjs/components/Popper/Popper.js.map +1 -1
- package/dist/cjs/components/Popper/anchorMove.js +42 -0
- package/dist/cjs/components/Popper/anchorMove.js.map +1 -0
- package/dist/cjs/components/ViewSettings/Styles.js +8 -3
- package/dist/cjs/components/ViewSettings/Styles.js.map +1 -1
- package/dist/cjs/components/ViewSettings/ViewSettings.js +64 -3
- package/dist/cjs/components/ViewSettings/ViewSettings.js.map +1 -1
- package/dist/cjs/components/ViewSwitcher/ApplyToAllTab.js +199 -0
- package/dist/cjs/components/ViewSwitcher/ApplyToAllTab.js.map +1 -0
- package/dist/cjs/components/ViewSwitcher/Styles.js +73 -61
- package/dist/cjs/components/ViewSwitcher/Styles.js.map +1 -1
- package/dist/cjs/components/ViewSwitcher/{ViewSwitcherMenu.js → SubViewSwitcher.js} +70 -22
- package/dist/cjs/components/ViewSwitcher/SubViewSwitcher.js.map +1 -0
- package/dist/cjs/components/ViewSwitcher/ViewSwitcher.js +46 -184
- package/dist/cjs/components/ViewSwitcher/ViewSwitcher.js.map +1 -1
- package/dist/cjs/components/ViewSwitcher/index.js +4 -4
- package/dist/cjs/components/ViewSwitcher/index.js.map +1 -1
- package/dist/cjs/components/ViewSwitcher/useApplyToAllOffer.js +179 -0
- package/dist/cjs/components/ViewSwitcher/useApplyToAllOffer.js.map +1 -0
- package/dist/cjs/presentation/shared/ActivityFeed.js +1 -2
- package/dist/cjs/presentation/shared/ActivityFeed.js.map +1 -1
- package/dist/esm/components/Popper/Popper.d.ts.map +1 -1
- package/dist/esm/components/Popper/Popper.js +12 -0
- package/dist/esm/components/Popper/Popper.js.map +1 -1
- package/dist/esm/components/Popper/anchorMove.d.ts +4 -0
- package/dist/esm/components/Popper/anchorMove.d.ts.map +1 -0
- package/dist/esm/components/Popper/anchorMove.js +33 -0
- package/dist/esm/components/Popper/anchorMove.js.map +1 -0
- package/dist/esm/components/ViewSettings/Styles.d.ts +1 -0
- package/dist/esm/components/ViewSettings/Styles.d.ts.map +1 -1
- package/dist/esm/components/ViewSettings/Styles.js +7 -2
- package/dist/esm/components/ViewSettings/Styles.js.map +1 -1
- package/dist/esm/components/ViewSettings/ViewSettings.d.ts +12 -0
- package/dist/esm/components/ViewSettings/ViewSettings.d.ts.map +1 -1
- package/dist/esm/components/ViewSettings/ViewSettings.js +66 -5
- package/dist/esm/components/ViewSettings/ViewSettings.js.map +1 -1
- package/dist/esm/components/ViewSwitcher/ApplyToAllTab.d.ts +24 -0
- package/dist/esm/components/ViewSwitcher/ApplyToAllTab.d.ts.map +1 -0
- package/dist/esm/components/ViewSwitcher/ApplyToAllTab.js +179 -0
- package/dist/esm/components/ViewSwitcher/ApplyToAllTab.js.map +1 -0
- package/dist/esm/components/ViewSwitcher/Styles.d.ts +15 -15
- package/dist/esm/components/ViewSwitcher/Styles.d.ts.map +1 -1
- package/dist/esm/components/ViewSwitcher/Styles.js +72 -60
- package/dist/esm/components/ViewSwitcher/Styles.js.map +1 -1
- package/dist/esm/components/ViewSwitcher/SubViewSwitcher.d.ts +50 -0
- package/dist/esm/components/ViewSwitcher/SubViewSwitcher.d.ts.map +1 -0
- package/dist/esm/components/ViewSwitcher/SubViewSwitcher.js +149 -0
- package/dist/esm/components/ViewSwitcher/SubViewSwitcher.js.map +1 -0
- package/dist/esm/components/ViewSwitcher/ViewSwitcher.d.ts +8 -8
- package/dist/esm/components/ViewSwitcher/ViewSwitcher.d.ts.map +1 -1
- package/dist/esm/components/ViewSwitcher/ViewSwitcher.js +48 -163
- package/dist/esm/components/ViewSwitcher/ViewSwitcher.js.map +1 -1
- package/dist/esm/components/ViewSwitcher/index.d.ts +1 -1
- package/dist/esm/components/ViewSwitcher/index.d.ts.map +1 -1
- package/dist/esm/components/ViewSwitcher/index.js +1 -1
- package/dist/esm/components/ViewSwitcher/index.js.map +1 -1
- package/dist/esm/components/ViewSwitcher/useApplyToAllOffer.d.ts +27 -0
- package/dist/esm/components/ViewSwitcher/useApplyToAllOffer.d.ts.map +1 -0
- package/dist/esm/components/ViewSwitcher/useApplyToAllOffer.js +159 -0
- package/dist/esm/components/ViewSwitcher/useApplyToAllOffer.js.map +1 -0
- package/dist/esm/presentation/shared/ActivityFeed.d.ts.map +1 -1
- package/dist/esm/presentation/shared/ActivityFeed.js +1 -2
- package/dist/esm/presentation/shared/ActivityFeed.js.map +1 -1
- package/dist/index.js +656 -280
- package/dist/index.js.map +1 -1
- package/dist/index.min.js +1 -1
- package/dist/index.min.js.map +1 -1
- package/package.json +1 -1
- package/dist/cjs/components/ViewSwitcher/ViewSwitcherMenu.js.map +0 -1
- package/dist/esm/components/ViewSwitcher/ViewSwitcherMenu.d.ts +0 -39
- package/dist/esm/components/ViewSwitcher/ViewSwitcherMenu.d.ts.map +0 -1
- package/dist/esm/components/ViewSwitcher/ViewSwitcherMenu.js +0 -101
- package/dist/esm/components/ViewSwitcher/ViewSwitcherMenu.js.map +0 -1
|
@@ -2,6 +2,18 @@ import React, { ButtonHTMLAttributes } from "react";
|
|
|
2
2
|
export interface ViewSettingsProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
3
3
|
/** The tooltip and the accessible name of the button. */
|
|
4
4
|
label: string;
|
|
5
|
+
/** Turns on the check button that slides out after a change. A result of false shows no confirmation. */
|
|
6
|
+
onApplyToAll?: () => unknown;
|
|
7
|
+
/** A new value opens the check button, for a change made in the settings. */
|
|
8
|
+
offerKey?: string | number;
|
|
9
|
+
/** Tooltip and accessible name of the check button. */
|
|
10
|
+
applyToAllTitle?: string;
|
|
11
|
+
/** Text that a screen reader reads after the apply. */
|
|
12
|
+
appliedLabel?: string;
|
|
13
|
+
/** Tooltip and accessible name of the button that closes the extra action. */
|
|
14
|
+
/** Visible text of the apply button, shown where it has room. */
|
|
15
|
+
applyToAllLabel?: string;
|
|
16
|
+
dismissLabel?: string;
|
|
5
17
|
}
|
|
6
18
|
/** The settings button of a page view, with the look of ViewSwitcher and one icon. It sits left of the view switcher. */
|
|
7
19
|
export declare const ViewSettings: React.ForwardRefExoticComponent<ViewSettingsProps & React.RefAttributes<HTMLButtonElement>>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ViewSettings.d.ts","sourceRoot":"","sources":["../../../../src/components/ViewSettings/ViewSettings.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"ViewSettings.d.ts","sourceRoot":"","sources":["../../../../src/components/ViewSettings/ViewSettings.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EACZ,oBAAoB,EAKrB,MAAM,OAAO,CAAC;AAef,MAAM,WAAW,iBACf,SAAQ,oBAAoB,CAAC,iBAAiB,CAAC;IAC/C,yDAAyD;IACzD,KAAK,EAAE,MAAM,CAAC;IACd,yGAAyG;IACzG,YAAY,CAAC,EAAE,MAAM,OAAO,CAAC;IAC7B,6EAA6E;IAC7E,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC3B,uDAAuD;IACvD,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,uDAAuD;IACvD,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,8EAA8E;IAC9E,iEAAiE;IACjE,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,yHAAyH;AACzH,eAAO,MAAM,YAAY,6FAyFxB,CAAC"}
|
|
@@ -1,26 +1,87 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
2
2
|
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
|
|
3
|
-
const _excluded = ["label", "className"];
|
|
4
|
-
import React, { forwardRef } from "react";
|
|
3
|
+
const _excluded = ["label", "className", "onApplyToAll", "offerKey", "applyToAllTitle", "appliedLabel", "applyToAllLabel", "dismissLabel"];
|
|
4
|
+
import React, { forwardRef, useCallback, useEffect, useRef } from "react";
|
|
5
5
|
import classnames from "classnames";
|
|
6
|
-
import { StyledViewSettings, StyledViewSettingsButton } from "./Styles";
|
|
6
|
+
import { StyledViewSettings, StyledViewSettingsButton, StyledViewSettingsHost } from "./Styles";
|
|
7
|
+
import useForkRef from "../../utils/useForkRef";
|
|
7
8
|
import { SettingsIcon } from "../Icons";
|
|
8
9
|
import { Tooltip } from "../Tooltip";
|
|
10
|
+
import { ApplyToAllTab } from "../ViewSwitcher/ApplyToAllTab";
|
|
11
|
+
import { useApplyToAllOffer } from "../ViewSwitcher/useApplyToAllOffer";
|
|
9
12
|
/** The settings button of a page view, with the look of ViewSwitcher and one icon. It sits left of the view switcher. */
|
|
10
13
|
export const ViewSettings = /*#__PURE__*/forwardRef((_ref, ref) => {
|
|
11
14
|
let label = _ref.label,
|
|
12
15
|
className = _ref.className,
|
|
16
|
+
onApplyToAll = _ref.onApplyToAll,
|
|
17
|
+
offerKey = _ref.offerKey,
|
|
18
|
+
_ref$applyToAllTitle = _ref.applyToAllTitle,
|
|
19
|
+
applyToAllTitle = _ref$applyToAllTitle === void 0 ? "Apply to All Projects" : _ref$applyToAllTitle,
|
|
20
|
+
_ref$appliedLabel = _ref.appliedLabel,
|
|
21
|
+
appliedLabel = _ref$appliedLabel === void 0 ? "Applied" : _ref$appliedLabel,
|
|
22
|
+
_ref$applyToAllLabel = _ref.applyToAllLabel,
|
|
23
|
+
applyToAllLabel = _ref$applyToAllLabel === void 0 ? "All Projects?" : _ref$applyToAllLabel,
|
|
24
|
+
_ref$dismissLabel = _ref.dismissLabel,
|
|
25
|
+
dismissLabel = _ref$dismissLabel === void 0 ? "Dismiss" : _ref$dismissLabel,
|
|
13
26
|
rest = _objectWithoutPropertiesLoose(_ref, _excluded);
|
|
14
|
-
|
|
27
|
+
const hostRef = useRef(null);
|
|
28
|
+
const buttonRef = useRef(null);
|
|
29
|
+
const handleButtonRef = useForkRef(buttonRef, ref);
|
|
30
|
+
const focusButton = useCallback(() => {
|
|
31
|
+
var _buttonRef$current;
|
|
32
|
+
return (_buttonRef$current = buttonRef.current) == null ? void 0 : _buttonRef$current.focus();
|
|
33
|
+
}, []);
|
|
34
|
+
const offer = useApplyToAllOffer({
|
|
35
|
+
rootRef: hostRef,
|
|
36
|
+
onApplyToAll,
|
|
37
|
+
onRestoreFocus: focusButton
|
|
38
|
+
});
|
|
39
|
+
const show = offer.show;
|
|
40
|
+
const seenOfferKeyRef = useRef(offerKey);
|
|
41
|
+
const hasChangeRef = useRef(false);
|
|
42
|
+
const expanded = rest["aria-expanded"];
|
|
43
|
+
const isMenuOpen = expanded === true || expanded === "true";
|
|
44
|
+
|
|
45
|
+
// A change made in the open menu offers the apply once the menu closes.
|
|
46
|
+
useEffect(() => {
|
|
47
|
+
if (seenOfferKeyRef.current !== offerKey) {
|
|
48
|
+
seenOfferKeyRef.current = offerKey;
|
|
49
|
+
hasChangeRef.current = true;
|
|
50
|
+
}
|
|
51
|
+
if (hasChangeRef.current && !isMenuOpen) {
|
|
52
|
+
hasChangeRef.current = false;
|
|
53
|
+
show(true);
|
|
54
|
+
}
|
|
55
|
+
}, [isMenuOpen, offerKey, show]);
|
|
56
|
+
const track = /*#__PURE__*/React.createElement(StyledViewSettings, {
|
|
15
57
|
className: classnames("c-view-settings", className),
|
|
16
58
|
"data-testid": "view-settings"
|
|
17
59
|
}, /*#__PURE__*/React.createElement(Tooltip, {
|
|
18
60
|
title: label
|
|
19
61
|
}, /*#__PURE__*/React.createElement(StyledViewSettingsButton, _extends({}, rest, {
|
|
20
|
-
ref:
|
|
62
|
+
ref: handleButtonRef,
|
|
21
63
|
type: "button",
|
|
22
64
|
"aria-label": label
|
|
23
65
|
}), /*#__PURE__*/React.createElement(SettingsIcon, null))));
|
|
66
|
+
if (!onApplyToAll) {
|
|
67
|
+
return track;
|
|
68
|
+
}
|
|
69
|
+
return /*#__PURE__*/React.createElement(StyledViewSettingsHost, {
|
|
70
|
+
ref: hostRef,
|
|
71
|
+
onKeyDown: offer.handleKeyDown,
|
|
72
|
+
onBlur: offer.handleBlur
|
|
73
|
+
}, track, offer.isShown ? /*#__PURE__*/React.createElement(ApplyToAllTab, {
|
|
74
|
+
ref: offer.tabRef,
|
|
75
|
+
phase: offer.phase,
|
|
76
|
+
isConfirmed: offer.isConfirmed,
|
|
77
|
+
title: applyToAllTitle,
|
|
78
|
+
appliedLabel: appliedLabel,
|
|
79
|
+
onApply: offer.apply,
|
|
80
|
+
onDismiss: offer.leave,
|
|
81
|
+
onHold: offer.hold,
|
|
82
|
+
dismissLabel: dismissLabel,
|
|
83
|
+
applyToAllLabel: applyToAllLabel
|
|
84
|
+
}) : null);
|
|
24
85
|
});
|
|
25
86
|
ViewSettings.displayName = "ViewSettings";
|
|
26
87
|
//# sourceMappingURL=ViewSettings.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ViewSettings.js","names":["React","forwardRef","classnames","StyledViewSettings","StyledViewSettingsButton","SettingsIcon","Tooltip","ViewSettings","_ref","ref","label","className","rest","_objectWithoutPropertiesLoose","_excluded","createElement","title","_extends","type","displayName"],"sources":["../../../../src/components/ViewSettings/ViewSettings.tsx"],"sourcesContent":["import React, {
|
|
1
|
+
{"version":3,"file":"ViewSettings.js","names":["React","forwardRef","useCallback","useEffect","useRef","classnames","StyledViewSettings","StyledViewSettingsButton","StyledViewSettingsHost","useForkRef","SettingsIcon","Tooltip","ApplyToAllTab","useApplyToAllOffer","ViewSettings","_ref","ref","label","className","onApplyToAll","offerKey","_ref$applyToAllTitle","applyToAllTitle","_ref$appliedLabel","appliedLabel","_ref$applyToAllLabel","applyToAllLabel","_ref$dismissLabel","dismissLabel","rest","_objectWithoutPropertiesLoose","_excluded","hostRef","buttonRef","handleButtonRef","focusButton","_buttonRef$current","current","focus","offer","rootRef","onRestoreFocus","show","seenOfferKeyRef","hasChangeRef","expanded","isMenuOpen","track","createElement","title","_extends","type","onKeyDown","handleKeyDown","onBlur","handleBlur","isShown","tabRef","phase","isConfirmed","onApply","apply","onDismiss","leave","onHold","hold","displayName"],"sources":["../../../../src/components/ViewSettings/ViewSettings.tsx"],"sourcesContent":["import React, {\n ButtonHTMLAttributes,\n forwardRef,\n useCallback,\n useEffect,\n useRef,\n} from \"react\";\n\nimport classnames from \"classnames\";\n\nimport {\n StyledViewSettings,\n StyledViewSettingsButton,\n StyledViewSettingsHost,\n} from \"./Styles\";\nimport useForkRef from \"../../utils/useForkRef\";\nimport { SettingsIcon } from \"../Icons\";\nimport { Tooltip } from \"../Tooltip\";\nimport { ApplyToAllTab } from \"../ViewSwitcher/ApplyToAllTab\";\nimport { useApplyToAllOffer } from \"../ViewSwitcher/useApplyToAllOffer\";\n\nexport interface ViewSettingsProps\n extends ButtonHTMLAttributes<HTMLButtonElement> {\n /** The tooltip and the accessible name of the button. */\n label: string;\n /** Turns on the check button that slides out after a change. A result of false shows no confirmation. */\n onApplyToAll?: () => unknown;\n /** A new value opens the check button, for a change made in the settings. */\n offerKey?: string | number;\n /** Tooltip and accessible name of the check button. */\n applyToAllTitle?: string;\n /** Text that a screen reader reads after the apply. */\n appliedLabel?: string;\n /** Tooltip and accessible name of the button that closes the extra action. */\n /** Visible text of the apply button, shown where it has room. */\n applyToAllLabel?: string;\n dismissLabel?: string;\n}\n\n/** The settings button of a page view, with the look of ViewSwitcher and one icon. It sits left of the view switcher. */\nexport const ViewSettings = forwardRef<HTMLButtonElement, ViewSettingsProps>(\n (\n {\n label,\n className,\n onApplyToAll,\n offerKey,\n applyToAllTitle = \"Apply to All Projects\",\n appliedLabel = \"Applied\",\n applyToAllLabel = \"All Projects?\",\n dismissLabel = \"Dismiss\",\n ...rest\n },\n ref\n ) => {\n const hostRef = useRef<HTMLSpanElement | null>(null);\n const buttonRef = useRef<HTMLButtonElement | null>(null);\n const handleButtonRef = useForkRef(buttonRef, ref);\n const focusButton = useCallback(() => buttonRef.current?.focus(), []);\n const offer = useApplyToAllOffer<true>({\n rootRef: hostRef,\n onApplyToAll,\n onRestoreFocus: focusButton,\n });\n const { show } = offer;\n const seenOfferKeyRef = useRef(offerKey);\n const hasChangeRef = useRef(false);\n const expanded = rest[\"aria-expanded\"];\n const isMenuOpen = expanded === true || expanded === \"true\";\n\n // A change made in the open menu offers the apply once the menu closes.\n useEffect(() => {\n if (seenOfferKeyRef.current !== offerKey) {\n seenOfferKeyRef.current = offerKey;\n hasChangeRef.current = true;\n }\n\n if (hasChangeRef.current && !isMenuOpen) {\n hasChangeRef.current = false;\n show(true);\n }\n }, [isMenuOpen, offerKey, show]);\n\n const track = (\n <StyledViewSettings\n className={classnames(\"c-view-settings\", className)}\n data-testid=\"view-settings\"\n >\n <Tooltip title={label}>\n <StyledViewSettingsButton\n {...rest}\n ref={handleButtonRef}\n type=\"button\"\n aria-label={label}\n >\n <SettingsIcon />\n </StyledViewSettingsButton>\n </Tooltip>\n </StyledViewSettings>\n );\n\n if (!onApplyToAll) {\n return track;\n }\n\n return (\n <StyledViewSettingsHost\n ref={hostRef}\n onKeyDown={offer.handleKeyDown}\n onBlur={offer.handleBlur}\n >\n {track}\n {offer.isShown ? (\n <ApplyToAllTab\n ref={offer.tabRef}\n phase={offer.phase}\n isConfirmed={offer.isConfirmed}\n title={applyToAllTitle}\n appliedLabel={appliedLabel}\n onApply={offer.apply}\n onDismiss={offer.leave}\n onHold={offer.hold}\n dismissLabel={dismissLabel}\n applyToAllLabel={applyToAllLabel}\n />\n ) : null}\n </StyledViewSettingsHost>\n );\n }\n);\n\nViewSettings.displayName = \"ViewSettings\";\n"],"mappings":";;;AAAA,OAAOA,KAAK,IAEVC,UAAU,EACVC,WAAW,EACXC,SAAS,EACTC,MAAM,QACD,OAAO;AAEd,OAAOC,UAAU,MAAM,YAAY;AAEnC,SACEC,kBAAkB,EAClBC,wBAAwB,EACxBC,sBAAsB,QACjB,UAAU;AACjB,OAAOC,UAAU,MAAM,wBAAwB;AAC/C,SAASC,YAAY,QAAQ,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BQ,GAAG,EAAEgB,OAAQ;IACboB,SAAS,EAAEb,KAAK,CAACc,aAAc;IAC/BC,MAAM,EAAEf,KAAK,CAACgB;EAAW,GAExBR,KAAK,EACLR,KAAK,CAACiB,OAAO,gBACZxD,KAAA,CAAAgD,aAAA,CAACpC,aAAa;IACZI,GAAG,EAAEuB,KAAK,CAACkB,MAAO;IAClBC,KAAK,EAAEnB,KAAK,CAACmB,KAAM;IACnBC,WAAW,EAAEpB,KAAK,CAACoB,WAAY;IAC/BV,KAAK,EAAE3B,eAAgB;IACvBE,YAAY,EAAEA,YAAa;IAC3BoC,OAAO,EAAErB,KAAK,CAACsB,KAAM;IACrBC,SAAS,EAAEvB,KAAK,CAACwB,KAAM;IACvBC,MAAM,EAAEzB,KAAK,CAAC0B,IAAK;IACnBrC,YAAY,EAAEA,YAAa;IAC3BF,eAAe,EAAEA;EAAgB,CAClC,CAAC,GACA,IACkB,CAAC;AAE7B,CACF,CAAC;AAEDZ,YAAY,CAACoD,WAAW,GAAG,cAAc","ignoreList":[]}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import React, { ReactNode } from "react";
|
|
2
|
+
import { ApplyToAllPhase } from "./useApplyToAllOffer";
|
|
3
|
+
interface ApplyToAllTabProps {
|
|
4
|
+
phase: ApplyToAllPhase;
|
|
5
|
+
isConfirmed: boolean;
|
|
6
|
+
/** Tooltip and accessible name of the button. */
|
|
7
|
+
title: string;
|
|
8
|
+
/** Accessible name of the group. */
|
|
9
|
+
label?: ReactNode;
|
|
10
|
+
/** Text that confirms the apply. */
|
|
11
|
+
appliedLabel: string;
|
|
12
|
+
onApply: () => void;
|
|
13
|
+
/** Visible text of the apply button, shown where the button has room for it. */
|
|
14
|
+
applyToAllLabel?: string;
|
|
15
|
+
/** Tooltip and accessible name of the button that closes the tab. */
|
|
16
|
+
dismissLabel?: string;
|
|
17
|
+
onDismiss?: () => void;
|
|
18
|
+
/** Called with true while the pointer is over the tab, so the tab does not go away under it. */
|
|
19
|
+
onHold?: (isHeld: boolean) => void;
|
|
20
|
+
}
|
|
21
|
+
/** The extension that comes out from under a view control and applies its value to all projects. */
|
|
22
|
+
export declare const ApplyToAllTab: React.ForwardRefExoticComponent<ApplyToAllTabProps & React.RefAttributes<HTMLDivElement>>;
|
|
23
|
+
export {};
|
|
24
|
+
//# sourceMappingURL=ApplyToAllTab.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ApplyToAllTab.d.ts","sourceRoot":"","sources":["../../../../src/components/ViewSwitcher/ApplyToAllTab.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAGZ,SAAS,EAKV,MAAM,OAAO,CAAC;AAYf,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AA6GvD,UAAU,kBAAkB;IAC1B,KAAK,EAAE,eAAe,CAAC;IACvB,WAAW,EAAE,OAAO,CAAC;IACrB,iDAAiD;IACjD,KAAK,EAAE,MAAM,CAAC;IACd,oCAAoC;IACpC,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,oCAAoC;IACpC,YAAY,EAAE,MAAM,CAAC;IACrB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,gFAAgF;IAChF,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,qEAAqE;IACrE,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;IACvB,gGAAgG;IAChG,MAAM,CAAC,EAAE,CAAC,MAAM,EAAE,OAAO,KAAK,IAAI,CAAC;CACpC;AAED,oGAAoG;AACpG,eAAO,MAAM,aAAa,2FA4GzB,CAAC"}
|
|
@@ -0,0 +1,179 @@
|
|
|
1
|
+
import React, { forwardRef, useId, useLayoutEffect, useRef, useState } from "react";
|
|
2
|
+
import { StyledApplyToAllButton, StyledApplyToAllDismiss, StyledApplyToAllDone, StyledApplyToAllLine, StyledApplyToAllSlide, StyledApplyToAllTab, StyledViewSwitcherPromptTitle, TAB_RING } from "./Styles";
|
|
3
|
+
import { Portal } from "../../helpers";
|
|
4
|
+
import useForkRef from "../../utils/useForkRef";
|
|
5
|
+
import { CheckIcon, CloseIcon } from "../Icons";
|
|
6
|
+
import { ANCHOR_MOVE_EVENT, useAnnounceAnchorMove } from "../Popper/anchorMove";
|
|
7
|
+
import { Tooltip } from "../Tooltip";
|
|
8
|
+
|
|
9
|
+
// A control at least this wide gives the apply button room for its text.
|
|
10
|
+
const LABEL_ROOM = 120;
|
|
11
|
+
// The outline of the tab with a hole in the shape of the control, so the control shows on top of it.
|
|
12
|
+
const controlHole = (width, height, hole) => {
|
|
13
|
+
const r = Math.min(hole.height, hole.width) / 2;
|
|
14
|
+
const left = hole.x + r;
|
|
15
|
+
const right = hole.x + hole.width - r;
|
|
16
|
+
const bottom = hole.y + hole.height;
|
|
17
|
+
return "path(evenodd, \"M0 0H" + width + "V" + height + "H0Z M" + left + " " + hole.y + "H" + right + "A" + r + " " + r + " 0 0 1 " + right + " " + bottom + "H" + left + "A" + r + " " + r + " 0 0 1 " + left + " " + hole.y + "Z\")";
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
// The tab draws on top of the page, so neither the titlebar nor the paper under it cut it. It wraps the control with a
|
|
21
|
+
// thin ring, and a hole in the shape of the control keeps the control in front. A tab is wider only when its buttons
|
|
22
|
+
// need the room.
|
|
23
|
+
const usePlace = isConfirmed => {
|
|
24
|
+
var _keptRef$current;
|
|
25
|
+
const markerRef = useRef(null);
|
|
26
|
+
const tabRef = useRef(null);
|
|
27
|
+
const _useState = useState(null),
|
|
28
|
+
place = _useState[0],
|
|
29
|
+
setPlace = _useState[1];
|
|
30
|
+
// The confirmation keeps the size and the shape of the tab it replaces.
|
|
31
|
+
const keptRef = useRef(null);
|
|
32
|
+
const isConfirmedRef = useRef(isConfirmed);
|
|
33
|
+
isConfirmedRef.current = isConfirmed;
|
|
34
|
+
useLayoutEffect(() => {
|
|
35
|
+
var _markerRef$current;
|
|
36
|
+
const control = (_markerRef$current = markerRef.current) == null ? void 0 : _markerRef$current.parentElement;
|
|
37
|
+
if (!control) {
|
|
38
|
+
return undefined;
|
|
39
|
+
}
|
|
40
|
+
const measure = () => {
|
|
41
|
+
var _ref, _kept$width, _tabRef$current, _tabRef$current$offse, _tabRef$current2, _kept$isWrapping;
|
|
42
|
+
const rect = control.getBoundingClientRect();
|
|
43
|
+
const kept = isConfirmedRef.current ? keptRef.current : null;
|
|
44
|
+
const width = (_ref = (_kept$width = kept == null ? void 0 : kept.width) != null ? _kept$width : (_tabRef$current = tabRef.current) == null ? void 0 : _tabRef$current.offsetWidth) != null ? _ref : 0;
|
|
45
|
+
const height = (_tabRef$current$offse = (_tabRef$current2 = tabRef.current) == null ? void 0 : _tabRef$current2.offsetHeight) != null ? _tabRef$current$offse : 0;
|
|
46
|
+
const isWrapping = (_kept$isWrapping = kept == null ? void 0 : kept.isWrapping) != null ? _kept$isWrapping : width > rect.width + 2 * TAB_RING + 0.5;
|
|
47
|
+
if (!isConfirmedRef.current) {
|
|
48
|
+
keptRef.current = {
|
|
49
|
+
width,
|
|
50
|
+
isWrapping
|
|
51
|
+
};
|
|
52
|
+
}
|
|
53
|
+
const tuck = rect.height + TAB_RING;
|
|
54
|
+
setPlace({
|
|
55
|
+
top: rect.bottom - tuck,
|
|
56
|
+
left: rect.left + rect.width / 2,
|
|
57
|
+
minWidth: kept ? width : rect.width + 2 * TAB_RING,
|
|
58
|
+
width: kept ? width : undefined,
|
|
59
|
+
isLabeled: !isWrapping && rect.width >= LABEL_ROOM,
|
|
60
|
+
tuck,
|
|
61
|
+
clipPath: width && height ? controlHole(width, height, {
|
|
62
|
+
x: (width - rect.width) / 2,
|
|
63
|
+
y: TAB_RING,
|
|
64
|
+
width: rect.width,
|
|
65
|
+
height: rect.height
|
|
66
|
+
}) : undefined
|
|
67
|
+
});
|
|
68
|
+
};
|
|
69
|
+
measure();
|
|
70
|
+
// The width of the tab is known after its first draw.
|
|
71
|
+
const frame = requestAnimationFrame(measure);
|
|
72
|
+
window.addEventListener("resize", measure);
|
|
73
|
+
window.addEventListener("scroll", measure, true);
|
|
74
|
+
window.addEventListener(ANCHOR_MOVE_EVENT, measure);
|
|
75
|
+
return () => {
|
|
76
|
+
cancelAnimationFrame(frame);
|
|
77
|
+
window.removeEventListener("resize", measure);
|
|
78
|
+
window.removeEventListener("scroll", measure, true);
|
|
79
|
+
window.removeEventListener(ANCHOR_MOVE_EVENT, measure);
|
|
80
|
+
};
|
|
81
|
+
}, []);
|
|
82
|
+
|
|
83
|
+
// The kept width applies in the same draw as the confirmation, before a new measure.
|
|
84
|
+
const keptWidth = isConfirmed ? (_keptRef$current = keptRef.current) == null ? void 0 : _keptRef$current.width : undefined;
|
|
85
|
+
return {
|
|
86
|
+
markerRef,
|
|
87
|
+
tabRef,
|
|
88
|
+
place,
|
|
89
|
+
keptWidth
|
|
90
|
+
};
|
|
91
|
+
};
|
|
92
|
+
/** The extension that comes out from under a view control and applies its value to all projects. */
|
|
93
|
+
export const ApplyToAllTab = /*#__PURE__*/forwardRef((_ref2, ref) => {
|
|
94
|
+
var _place$tuck;
|
|
95
|
+
let phase = _ref2.phase,
|
|
96
|
+
isConfirmed = _ref2.isConfirmed,
|
|
97
|
+
title = _ref2.title,
|
|
98
|
+
label = _ref2.label,
|
|
99
|
+
appliedLabel = _ref2.appliedLabel,
|
|
100
|
+
onApply = _ref2.onApply,
|
|
101
|
+
_ref2$applyToAllLabel = _ref2.applyToAllLabel,
|
|
102
|
+
applyToAllLabel = _ref2$applyToAllLabel === void 0 ? "All Projects?" : _ref2$applyToAllLabel,
|
|
103
|
+
_ref2$dismissLabel = _ref2.dismissLabel,
|
|
104
|
+
dismissLabel = _ref2$dismissLabel === void 0 ? "Dismiss" : _ref2$dismissLabel,
|
|
105
|
+
onDismiss = _ref2.onDismiss,
|
|
106
|
+
onHold = _ref2.onHold;
|
|
107
|
+
const labelId = useId();
|
|
108
|
+
const _usePlace = usePlace(isConfirmed),
|
|
109
|
+
markerRef = _usePlace.markerRef,
|
|
110
|
+
tabRef = _usePlace.tabRef,
|
|
111
|
+
place = _usePlace.place,
|
|
112
|
+
keptWidth = _usePlace.keptWidth;
|
|
113
|
+
const handleRef = useForkRef(tabRef, ref);
|
|
114
|
+
|
|
115
|
+
// The tab grows and shrinks beside the controls, so it moves the ones before it.
|
|
116
|
+
useAnnounceAnchorMove([phase, isConfirmed]);
|
|
117
|
+
const style = {
|
|
118
|
+
top: place == null ? void 0 : place.top,
|
|
119
|
+
left: place == null ? void 0 : place.left,
|
|
120
|
+
minWidth: keptWidth != null ? keptWidth : place == null ? void 0 : place.minWidth,
|
|
121
|
+
width: keptWidth != null ? keptWidth : place == null ? void 0 : place.width,
|
|
122
|
+
clipPath: place == null ? void 0 : place.clipPath,
|
|
123
|
+
position: "fixed",
|
|
124
|
+
translate: "-50% 0",
|
|
125
|
+
visibility: place ? undefined : "hidden",
|
|
126
|
+
"--apply-to-all-tuck": ((_place$tuck = place == null ? void 0 : place.tuck) != null ? _place$tuck : 32 + TAB_RING) + "px"
|
|
127
|
+
};
|
|
128
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("span", {
|
|
129
|
+
ref: markerRef,
|
|
130
|
+
hidden: true
|
|
131
|
+
}), /*#__PURE__*/React.createElement(Portal, null, /*#__PURE__*/React.createElement(StyledApplyToAllTab, {
|
|
132
|
+
ref: handleRef,
|
|
133
|
+
style: style,
|
|
134
|
+
role: "group",
|
|
135
|
+
"aria-labelledby": label ? labelId : undefined,
|
|
136
|
+
"aria-label": label ? undefined : title,
|
|
137
|
+
className: "c-apply-to-all",
|
|
138
|
+
"data-phase": phase,
|
|
139
|
+
"data-confirmed": isConfirmed || undefined,
|
|
140
|
+
"data-labeled": (place == null ? void 0 : place.isLabeled) || undefined
|
|
141
|
+
// A menu that opens on a click around its control must not open from the tab.
|
|
142
|
+
,
|
|
143
|
+
onClick: event => event.stopPropagation(),
|
|
144
|
+
onPointerEnter: () => onHold == null ? void 0 : onHold(true),
|
|
145
|
+
onPointerLeave: () => onHold == null ? void 0 : onHold(false)
|
|
146
|
+
}, label ? /*#__PURE__*/React.createElement(StyledViewSwitcherPromptTitle, {
|
|
147
|
+
id: labelId
|
|
148
|
+
}, label) : null, /*#__PURE__*/React.createElement(StyledApplyToAllSlide, {
|
|
149
|
+
className: "c-apply-to-all__slide"
|
|
150
|
+
}, isConfirmed ? /*#__PURE__*/React.createElement(StyledApplyToAllDone, {
|
|
151
|
+
role: "status",
|
|
152
|
+
className: "c-apply-to-all__done"
|
|
153
|
+
}, /*#__PURE__*/React.createElement(CheckIcon, null), /*#__PURE__*/React.createElement("span", {
|
|
154
|
+
className: "c-apply-to-all__done-text"
|
|
155
|
+
}, appliedLabel)) : /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Tooltip, {
|
|
156
|
+
title: title,
|
|
157
|
+
placement: "bottom"
|
|
158
|
+
}, /*#__PURE__*/React.createElement(StyledApplyToAllButton, {
|
|
159
|
+
type: "button",
|
|
160
|
+
"aria-label": title,
|
|
161
|
+
className: "c-apply-to-all__button",
|
|
162
|
+
onClick: onApply
|
|
163
|
+
}, /*#__PURE__*/React.createElement(CheckIcon, null), /*#__PURE__*/React.createElement("span", {
|
|
164
|
+
className: "c-apply-to-all__label",
|
|
165
|
+
"aria-hidden": true
|
|
166
|
+
}, applyToAllLabel))), onDismiss ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(StyledApplyToAllLine, {
|
|
167
|
+
className: "c-apply-to-all__line"
|
|
168
|
+
}), /*#__PURE__*/React.createElement(Tooltip, {
|
|
169
|
+
title: dismissLabel,
|
|
170
|
+
placement: "bottom"
|
|
171
|
+
}, /*#__PURE__*/React.createElement(StyledApplyToAllDismiss, {
|
|
172
|
+
type: "button",
|
|
173
|
+
"aria-label": dismissLabel,
|
|
174
|
+
className: "c-apply-to-all__dismiss",
|
|
175
|
+
onClick: onDismiss
|
|
176
|
+
}, /*#__PURE__*/React.createElement(CloseIcon, null)))) : null)))));
|
|
177
|
+
});
|
|
178
|
+
ApplyToAllTab.displayName = "ApplyToAllTab";
|
|
179
|
+
//# sourceMappingURL=ApplyToAllTab.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ApplyToAllTab.js","names":["React","forwardRef","useId","useLayoutEffect","useRef","useState","StyledApplyToAllButton","StyledApplyToAllDismiss","StyledApplyToAllDone","StyledApplyToAllLine","StyledApplyToAllSlide","StyledApplyToAllTab","StyledViewSwitcherPromptTitle","TAB_RING","Portal","useForkRef","CheckIcon","CloseIcon","ANCHOR_MOVE_EVENT","useAnnounceAnchorMove","Tooltip","LABEL_ROOM","controlHole","width","height","hole","r","Math","min","left","x","right","bottom","y","usePlace","isConfirmed","_keptRef$current","markerRef","tabRef","_useState","place","setPlace","keptRef","isConfirmedRef","current","_markerRef$current","control","parentElement","undefined","measure","_ref","_kept$width","_tabRef$current","_tabRef$current$offse","_tabRef$current2","_kept$isWrapping","rect","getBoundingClientRect","kept","offsetWidth","offsetHeight","isWrapping","tuck","top","minWidth","isLabeled","clipPath","frame","requestAnimationFrame","window","addEventListener","cancelAnimationFrame","removeEventListener","keptWidth","ApplyToAllTab","_ref2","ref","_place$tuck","phase","title","label","appliedLabel","onApply","_ref2$applyToAllLabel","applyToAllLabel","_ref2$dismissLabel","dismissLabel","onDismiss","onHold","labelId","_usePlace","handleRef","style","position","translate","visibility","createElement","Fragment","hidden","role","className","onClick","event","stopPropagation","onPointerEnter","onPointerLeave","id","placement","type","displayName"],"sources":["../../../../src/components/ViewSwitcher/ApplyToAllTab.tsx"],"sourcesContent":["import React, {\n CSSProperties,\n forwardRef,\n ReactNode,\n useId,\n useLayoutEffect,\n useRef,\n useState,\n} from \"react\";\n\nimport {\n StyledApplyToAllButton,\n StyledApplyToAllDismiss,\n StyledApplyToAllDone,\n StyledApplyToAllLine,\n StyledApplyToAllSlide,\n StyledApplyToAllTab,\n StyledViewSwitcherPromptTitle,\n TAB_RING,\n} from \"./Styles\";\nimport { ApplyToAllPhase } from \"./useApplyToAllOffer\";\nimport { Portal } from \"../../helpers\";\nimport useForkRef from \"../../utils/useForkRef\";\nimport { CheckIcon, CloseIcon } from \"../Icons\";\nimport { ANCHOR_MOVE_EVENT, useAnnounceAnchorMove } from \"../Popper/anchorMove\";\nimport { Tooltip } from \"../Tooltip\";\n\n// A control at least this wide gives the apply button room for its text.\nconst LABEL_ROOM = 120;\n\ninterface Place {\n top: number;\n left: number;\n minWidth: number;\n width?: number;\n isLabeled: boolean;\n tuck: number;\n clipPath?: string;\n}\n\n// The outline of the tab with a hole in the shape of the control, so the control shows on top of it.\nconst controlHole = (\n width: number,\n height: number,\n hole: { x: number; y: number; width: number; height: number }\n) => {\n const r = Math.min(hole.height, hole.width) / 2;\n const left = hole.x + r;\n const right = hole.x + hole.width - r;\n const bottom = hole.y + hole.height;\n\n return `path(evenodd, \"M0 0H${width}V${height}H0Z M${left} ${hole.y}H${right}A${r} ${r} 0 0 1 ${right} ${bottom}H${left}A${r} ${r} 0 0 1 ${left} ${hole.y}Z\")`;\n};\n\n// The tab draws on top of the page, so neither the titlebar nor the paper under it cut it. It wraps the control with a\n// thin ring, and a hole in the shape of the control keeps the control in front. A tab is wider only when its buttons\n// need the room.\nconst usePlace = (isConfirmed: boolean) => {\n const markerRef = useRef<HTMLSpanElement | null>(null);\n const tabRef = useRef<HTMLDivElement | null>(null);\n const [place, setPlace] = useState<Place | null>(null);\n // The confirmation keeps the size and the shape of the tab it replaces.\n const keptRef = useRef<{ width: number; isWrapping: boolean } | null>(null);\n const isConfirmedRef = useRef(isConfirmed);\n\n isConfirmedRef.current = isConfirmed;\n\n useLayoutEffect(() => {\n const control = markerRef.current?.parentElement;\n\n if (!control) {\n return undefined;\n }\n\n const measure = () => {\n const rect = control.getBoundingClientRect();\n const kept = isConfirmedRef.current ? keptRef.current : null;\n const width = kept?.width ?? tabRef.current?.offsetWidth ?? 0;\n const height = tabRef.current?.offsetHeight ?? 0;\n const isWrapping =\n kept?.isWrapping ?? width > rect.width + 2 * TAB_RING + 0.5;\n\n if (!isConfirmedRef.current) {\n keptRef.current = { width, isWrapping };\n }\n\n const tuck = rect.height + TAB_RING;\n\n setPlace({\n top: rect.bottom - tuck,\n left: rect.left + rect.width / 2,\n minWidth: kept ? width : rect.width + 2 * TAB_RING,\n width: kept ? width : undefined,\n isLabeled: !isWrapping && rect.width >= LABEL_ROOM,\n tuck,\n clipPath:\n width && height\n ? controlHole(width, height, {\n x: (width - rect.width) / 2,\n y: TAB_RING,\n width: rect.width,\n height: rect.height,\n })\n : undefined,\n });\n };\n\n measure();\n // The width of the tab is known after its first draw.\n const frame = requestAnimationFrame(measure);\n\n window.addEventListener(\"resize\", measure);\n window.addEventListener(\"scroll\", measure, true);\n window.addEventListener(ANCHOR_MOVE_EVENT, measure);\n\n return () => {\n cancelAnimationFrame(frame);\n window.removeEventListener(\"resize\", measure);\n window.removeEventListener(\"scroll\", measure, true);\n window.removeEventListener(ANCHOR_MOVE_EVENT, measure);\n };\n }, []);\n\n // The kept width applies in the same draw as the confirmation, before a new measure.\n const keptWidth = isConfirmed ? keptRef.current?.width : undefined;\n\n return { markerRef, tabRef, place, keptWidth };\n};\n\ninterface ApplyToAllTabProps {\n phase: ApplyToAllPhase;\n isConfirmed: boolean;\n /** Tooltip and accessible name of the button. */\n title: string;\n /** Accessible name of the group. */\n label?: ReactNode;\n /** Text that confirms the apply. */\n appliedLabel: string;\n onApply: () => void;\n /** Visible text of the apply button, shown where the button has room for it. */\n applyToAllLabel?: string;\n /** Tooltip and accessible name of the button that closes the tab. */\n dismissLabel?: string;\n onDismiss?: () => void;\n /** Called with true while the pointer is over the tab, so the tab does not go away under it. */\n onHold?: (isHeld: boolean) => void;\n}\n\n/** The extension that comes out from under a view control and applies its value to all projects. */\nexport const ApplyToAllTab = forwardRef<HTMLDivElement, ApplyToAllTabProps>(\n (\n {\n phase,\n isConfirmed,\n title,\n label,\n appliedLabel,\n onApply,\n applyToAllLabel = \"All Projects?\",\n dismissLabel = \"Dismiss\",\n onDismiss,\n onHold,\n },\n ref\n ) => {\n const labelId = useId();\n const { markerRef, tabRef, place, keptWidth } = usePlace(isConfirmed);\n const handleRef = useForkRef(tabRef, ref);\n\n // The tab grows and shrinks beside the controls, so it moves the ones before it.\n useAnnounceAnchorMove([phase, isConfirmed]);\n\n const style = {\n top: place?.top,\n left: place?.left,\n minWidth: keptWidth ?? place?.minWidth,\n width: keptWidth ?? place?.width,\n clipPath: place?.clipPath,\n position: \"fixed\",\n translate: \"-50% 0\",\n visibility: place ? undefined : \"hidden\",\n \"--apply-to-all-tuck\": `${place?.tuck ?? 32 + TAB_RING}px`,\n } as CSSProperties;\n\n return (\n <>\n <span ref={markerRef} hidden />\n <Portal>\n <StyledApplyToAllTab\n ref={handleRef}\n style={style}\n role=\"group\"\n aria-labelledby={label ? labelId : undefined}\n aria-label={label ? undefined : title}\n className=\"c-apply-to-all\"\n data-phase={phase}\n data-confirmed={isConfirmed || undefined}\n data-labeled={place?.isLabeled || undefined}\n // A menu that opens on a click around its control must not open from the tab.\n onClick={(event) => event.stopPropagation()}\n onPointerEnter={() => onHold?.(true)}\n onPointerLeave={() => onHold?.(false)}\n >\n {label ? (\n <StyledViewSwitcherPromptTitle id={labelId}>\n {label}\n </StyledViewSwitcherPromptTitle>\n ) : null}\n <StyledApplyToAllSlide className=\"c-apply-to-all__slide\">\n {isConfirmed ? (\n <StyledApplyToAllDone\n role=\"status\"\n className=\"c-apply-to-all__done\"\n >\n <CheckIcon />\n <span className=\"c-apply-to-all__done-text\">\n {appliedLabel}\n </span>\n </StyledApplyToAllDone>\n ) : (\n <>\n <Tooltip title={title} placement=\"bottom\">\n <StyledApplyToAllButton\n type=\"button\"\n aria-label={title}\n className=\"c-apply-to-all__button\"\n onClick={onApply}\n >\n <CheckIcon />\n <span className=\"c-apply-to-all__label\" aria-hidden>\n {applyToAllLabel}\n </span>\n </StyledApplyToAllButton>\n </Tooltip>\n {onDismiss ? (\n <>\n <StyledApplyToAllLine className=\"c-apply-to-all__line\" />\n <Tooltip title={dismissLabel} placement=\"bottom\">\n <StyledApplyToAllDismiss\n type=\"button\"\n aria-label={dismissLabel}\n className=\"c-apply-to-all__dismiss\"\n onClick={onDismiss}\n >\n <CloseIcon />\n </StyledApplyToAllDismiss>\n </Tooltip>\n </>\n ) : null}\n </>\n )}\n </StyledApplyToAllSlide>\n </StyledApplyToAllTab>\n </Portal>\n </>\n );\n }\n);\n\nApplyToAllTab.displayName = \"ApplyToAllTab\";\n"],"mappings":"AAAA,OAAOA,KAAK,IAEVC,UAAU,EAEVC,KAAK,EACLC,eAAe,EACfC,MAAM,EACNC,QAAQ,QACH,OAAO;AAEd,SACEC,sBAAsB,EACtBC,uBAAuB,EACvBC,oBAAoB,EACpBC,oBAAoB,EACpBC,qBAAqB,EACrBC,mBAAmB,EACnBC,6BAA6B,EAC7BC,QAAQ,QACH,UAAU;AAEjB,SAASC,MAAM,QAAQ,eAAe;AACtC,OAAOC,UAAU,MAAM,wBAAwB;AAC/C,SAASC,SAAS,EAAEC,SAAS,QAAQ,UAAU;AAC/C,SAASC,iBAAiB,EAAEC,qBAAqB,QAAQ,sBAAsB;AAC/E,SAASC,OAAO,QAAQ,YAAY;;AAEpC;AACA,MAAMC,UAAU,GAAG,GAAG;AAYtB;AACA,MAAMC,WAAW,GAAGA,CAClBC,KAAa,EACbC,MAAc,EACdC,IAA6D,KAC1D;EACH,MAAMC,CAAC,GAAGC,IAAI,CAACC,GAAG,CAACH,IAAI,CAACD,MAAM,EAAEC,IAAI,CAACF,KAAK,CAAC,GAAG,CAAC;EAC/C,MAAMM,IAAI,GAAGJ,IAAI,CAACK,CAAC,GAAGJ,CAAC;EACvB,MAAMK,KAAK,GAAGN,IAAI,CAACK,CAAC,GAAGL,IAAI,CAACF,KAAK,GAAGG,CAAC;EACrC,MAAMM,MAAM,GAAGP,IAAI,CAACQ,CAAC,GAAGR,IAAI,CAACD,MAAM;EAEnC,iC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ACG,CACc,CAAC,gBAEvBjF,KAAA,CAAAgG,aAAA,CAAAhG,KAAA,CAAAiG,QAAA,qBACEjG,KAAA,CAAAgG,aAAA,CAAC5E,OAAO;IAAC2D,KAAK,EAAEA,KAAM;IAAC4B,SAAS,EAAC;EAAQ,gBACvC3G,KAAA,CAAAgG,aAAA,CAAC1F,sBAAsB;IACrBsG,IAAI,EAAC,QAAQ;IACb,cAAY7B,KAAM;IAClBqB,SAAS,EAAC,wBAAwB;IAClCC,OAAO,EAAEnB;EAAQ,gBAEjBlF,KAAA,CAAAgG,aAAA,CAAChF,SAAS,MAAE,CAAC,eACbhB,KAAA,CAAAgG,aAAA;IAAMI,SAAS,EAAC,uBAAuB;IAAC;EAAW,GAChDhB,eACG,CACgB,CACjB,CAAC,EACTG,SAAS,gBACRvF,KAAA,CAAAgG,aAAA,CAAAhG,KAAA,CAAAiG,QAAA,qBACEjG,KAAA,CAAAgG,aAAA,CAACvF,oBAAoB;IAAC2F,SAAS,EAAC;EAAsB,CAAE,CAAC,eACzDpG,KAAA,CAAAgG,aAAA,CAAC5E,OAAO;IAAC2D,KAAK,EAAEO,YAAa;IAACqB,SAAS,EAAC;EAAQ,gBAC9C3G,KAAA,CAAAgG,aAAA,CAACzF,uBAAuB;IACtBqG,IAAI,EAAC,QAAQ;IACb,cAAYtB,YAAa;IACzBc,SAAS,EAAC,yBAAyB;IACnCC,OAAO,EAAEd;EAAU,gBAEnBvF,KAAA,CAAAgG,aAAA,CAAC/E,SAAS,MAAE,CACW,CAClB,CACT,CAAC,GACD,IACJ,CAEiB,CACJ,CACf,CACR,CAAC;AAEP,CACF,CAAC;AAEDyD,aAAa,CAACmC,WAAW,GAAG,eAAe","ignoreList":[]}
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
export declare const VIEW_SWITCHER_PROMPT_DELAY_MS = 100;
|
|
2
|
-
export declare const
|
|
3
|
-
export declare const
|
|
2
|
+
export declare const VIEW_SWITCHER_APPLIED_MS = 1400;
|
|
3
|
+
export declare const VIEW_SWITCHER_OPEN_MS = 3000;
|
|
4
4
|
export declare const VIEW_SWITCHER_LEAVE_MS = 200;
|
|
5
5
|
export declare const StyledViewSwitcher: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
6
6
|
export declare const StyledViewSwitcherTrack: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
7
7
|
export declare const StyledViewSwitcherOptions: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
8
8
|
export declare const StyledViewSwitcherOption: import("styled-components").StyledComponent<"button", any, {}, never>;
|
|
9
|
-
export declare const
|
|
10
|
-
export declare const
|
|
11
|
-
export declare const
|
|
12
|
-
export declare const
|
|
13
|
-
export declare const
|
|
9
|
+
export declare const StyledSubViewSwitcherOption: import("styled-components").StyledComponent<"button", any, {}, never>;
|
|
10
|
+
export declare const StyledSubViewSwitcherRoot: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
11
|
+
export declare const StyledSubViewSwitcherClip: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
12
|
+
export declare const StyledSubViewSwitcherIcon: import("styled-components").StyledComponent<"span", any, {}, never>;
|
|
13
|
+
export declare const StyledSubViewSwitcherList: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("..").ListProps & {
|
|
14
14
|
children?: import("react").ReactNode | undefined;
|
|
15
15
|
} & import("react").HTMLAttributes<HTMLUListElement> & import("react").RefAttributes<HTMLUListElement>> & {
|
|
16
16
|
Item: import("react").ForwardRefExoticComponent<import("..").ListItemProps & {
|
|
@@ -21,13 +21,13 @@ export declare const StyledViewSwitcherMenuList: import("styled-components").Sty
|
|
|
21
21
|
displayName: string;
|
|
22
22
|
};
|
|
23
23
|
}, any, {}, never>;
|
|
24
|
-
export declare const
|
|
24
|
+
export declare const StyledSubViewSwitcherLabel: import("styled-components").StyledComponent<"span", any, {}, never>;
|
|
25
25
|
export declare const StyledViewSwitcherPromptTitle: import("styled-components").StyledComponent<"span", any, {}, never>;
|
|
26
|
-
export declare const
|
|
27
|
-
export declare const
|
|
28
|
-
export declare const
|
|
29
|
-
export declare const
|
|
30
|
-
export declare const
|
|
31
|
-
export declare const
|
|
32
|
-
export declare const
|
|
26
|
+
export declare const TAB_RING = 2;
|
|
27
|
+
export declare const StyledApplyToAllTab: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
28
|
+
export declare const StyledApplyToAllSlide: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
29
|
+
export declare const StyledApplyToAllButton: import("styled-components").StyledComponent<"button", any, {}, never>;
|
|
30
|
+
export declare const StyledApplyToAllLine: import("styled-components").StyledComponent<"i", any, {}, never>;
|
|
31
|
+
export declare const StyledApplyToAllDismiss: import("styled-components").StyledComponent<"button", any, {}, never>;
|
|
32
|
+
export declare const StyledApplyToAllDone: import("styled-components").StyledComponent<"span", any, {}, never>;
|
|
33
33
|
//# sourceMappingURL=Styles.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Styles.d.ts","sourceRoot":"","sources":["../../../../src/components/ViewSwitcher/Styles.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Styles.d.ts","sourceRoot":"","sources":["../../../../src/components/ViewSwitcher/Styles.ts"],"names":[],"mappings":"AAOA,eAAO,MAAM,6BAA6B,MAAM,CAAC;AACjD,eAAO,MAAM,wBAAwB,OAAO,CAAC;AAC7C,eAAO,MAAM,qBAAqB,OAAO,CAAC;AAC1C,eAAO,MAAM,sBAAsB,MAAM,CAAC;AAE1C,eAAO,MAAM,kBAAkB,oEAK9B,CAAC;AAIF,eAAO,MAAM,uBAAuB,oEAUnC,CAAC;AAIF,eAAO,MAAM,yBAAyB,oEAGrC,CAAC;AAIF,eAAO,MAAM,wBAAwB,uEA4CpC,CAAC;AAIF,eAAO,MAAM,2BAA2B,uEAwDvC,CAAC;AA6BF,eAAO,MAAM,yBAAyB,oEA8BrC,CAAC;AAIF,eAAO,MAAM,yBAAyB,oEAOrC,CAAC;AAIF,eAAO,MAAM,yBAAyB,qEAKrC,CAAC;AAIF,eAAO,MAAM,yBAAyB;;;;;;;;;;kBAErC,CAAC;AAIF,eAAO,MAAM,0BAA0B,qEAOtC,CAAC;AAIF,eAAO,MAAM,6BAA6B,qEAOzC,CAAC;AAQF,eAAO,MAAM,QAAQ,IAAI,CAAC;AAmC1B,eAAO,MAAM,mBAAmB,oEAiD/B,CAAC;AAKF,eAAO,MAAM,qBAAqB,oEAQjC,CAAC;AAKF,eAAO,MAAM,sBAAsB,uEAoClC,CAAC;AAKF,eAAO,MAAM,oBAAoB,kEAMhC,CAAC;AAIF,eAAO,MAAM,uBAAuB,uEA+BnC,CAAC;AAKF,eAAO,MAAM,oBAAoB,qEAgChC,CAAC"}
|