@planningcenter/topbar 12.4.1 → 12.5.0-qa-994.0
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/topbar.css +822 -60
- package/dist/topbar.css.map +1 -1
- package/dist/topbar.js +2094 -319
- package/dist/topbar.js.map +1 -1
- package/dist/topbar.modern.js +2093 -319
- package/dist/topbar.modern.js.map +1 -1
- package/dist/topbar.module.js +2093 -319
- package/dist/topbar.module.js.map +1 -1
- package/dist/topbar.umd.js +2094 -321
- package/dist/topbar.umd.js.map +1 -1
- package/package.json +8 -4
package/dist/topbar.module.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Link, Button, Popover, PopoverTrigger, PopoverContent, Modal } from '@planningcenter/tapestry';
|
|
1
|
+
import { Link, Button, Popover, PopoverTrigger, PopoverContent, Flex, Select, IconButton, Modal } from '@planningcenter/tapestry';
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
import React__default, { useState, useEffect, useMemo, useLayoutEffect, useContext, createContext, useCallback, useRef } from 'react';
|
|
4
4
|
import pcoUrl$1, { pcoUrl as pcoUrl$2, pcoApiUrl } from '@planningcenter/url';
|
|
@@ -6,18 +6,20 @@ import * as general from '@planningcenter/icons/paths/general';
|
|
|
6
6
|
import Jolt from '@planningcenter/jolt-client';
|
|
7
7
|
import { useSyncExternalStore } from 'use-sync-external-store/shim';
|
|
8
8
|
import 'react/jsx-runtime';
|
|
9
|
+
import * as toolbar from '@planningcenter/icons/paths/toolbar';
|
|
10
|
+
import datetimeFmt from '@planningcenter/datetime-fmt';
|
|
11
|
+
import pluralize from 'pluralize';
|
|
12
|
+
import * as logomarks from '@planningcenter/icons/paths/logomark';
|
|
9
13
|
import { ThemeProvider, Divider, Button as Button$1, StackView as StackView$2, Text, Icon as Icon$1, designSystem, Box, Heading, GridView, Avatar as Avatar$1, Link as Link$1, HeadingUppercase, List, Combobox, Logo, Dropdown, Spinner, Badge } from '@planningcenter/tapestry-react';
|
|
10
14
|
import { components, UiExtensionFirstPartyComponent, UiExtensionDataContext } from '@planningcenter/add-ons';
|
|
11
15
|
import * as churchCenter from '@planningcenter/icons/paths/church-center';
|
|
12
16
|
import * as people from '@planningcenter/icons/paths/people';
|
|
13
|
-
import * as toolbar from '@planningcenter/icons/paths/toolbar';
|
|
14
17
|
import { InlineWidget } from 'react-calendly';
|
|
15
18
|
import algoliasearch from 'algoliasearch';
|
|
16
19
|
import { useSearchBox, useHits, InstantSearch, Configure } from 'react-instantsearch-core';
|
|
17
20
|
import { TransitionGroup, Transition } from 'react-transition-group';
|
|
18
|
-
import datetimeFmt from '@planningcenter/datetime-fmt';
|
|
19
21
|
|
|
20
|
-
var styles$
|
|
22
|
+
var styles$u = {"accessibility-toolbar":"accessibility-toolbar-jgjUG"};
|
|
21
23
|
|
|
22
24
|
const AccessibilityToolbar = ({
|
|
23
25
|
children
|
|
@@ -29,7 +31,7 @@ const AccessibilityToolbar = ({
|
|
|
29
31
|
(_a = document.getElementById("main-content")) === null || _a === void 0 ? void 0 : _a.focus();
|
|
30
32
|
};
|
|
31
33
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
32
|
-
className: styles$
|
|
34
|
+
className: styles$u["accessibility-toolbar"]
|
|
33
35
|
}, /*#__PURE__*/React__default.createElement(Link, {
|
|
34
36
|
href: "#main-content",
|
|
35
37
|
kind: "primary",
|
|
@@ -348,11 +350,11 @@ const X = ({
|
|
|
348
350
|
fill: fill
|
|
349
351
|
})));
|
|
350
352
|
|
|
351
|
-
var styles$
|
|
353
|
+
var styles$t = {"announcement":"announcement-pI5tM","announcement--platform":"announcement--platform-EcUn2","announcement--promo":"announcement--promo-FarUk","announcement-icon":"announcement-icon-Ov39-","announcement-content":"announcement-content-q2ad6","dismiss":"dismiss-wUAoU","dismiss--promo":"dismiss--promo-7zvO4"};
|
|
352
354
|
|
|
353
355
|
function AnnouncementIcon() {
|
|
354
356
|
return /*#__PURE__*/React__default.createElement("svg", {
|
|
355
|
-
className: styles$
|
|
357
|
+
className: styles$t["announcement-icon"],
|
|
356
358
|
width: "16",
|
|
357
359
|
height: "16",
|
|
358
360
|
viewBox: "0 0 16 16",
|
|
@@ -477,7 +479,7 @@ let StyledAnnouncement$1 = class StyledAnnouncement extends React__default.Compo
|
|
|
477
479
|
} = this.props;
|
|
478
480
|
const isPromo = variant === "promo";
|
|
479
481
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
480
|
-
className: classnames(styles$
|
|
482
|
+
className: classnames(styles$t["announcement"], styles$t[`announcement--${variant !== null && variant !== void 0 ? variant : "platform"}`]),
|
|
481
483
|
"data-announcement-variant": variant !== null && variant !== void 0 ? variant : "platform",
|
|
482
484
|
style: isPromo ? {
|
|
483
485
|
backgroundImage: promoBackgroundUrl,
|
|
@@ -486,7 +488,7 @@ let StyledAnnouncement$1 = class StyledAnnouncement extends React__default.Compo
|
|
|
486
488
|
backgroundSize: "cover"
|
|
487
489
|
} : undefined
|
|
488
490
|
}, !isPromo && /*#__PURE__*/React__default.createElement(AnnouncementIcon, null), /*#__PURE__*/React__default.createElement("div", {
|
|
489
|
-
className: styles$
|
|
491
|
+
className: styles$t["announcement-content"],
|
|
490
492
|
style: style,
|
|
491
493
|
...platformProps
|
|
492
494
|
}));
|
|
@@ -535,7 +537,7 @@ function StyledDismissButton$1({
|
|
|
535
537
|
const isPromo = variant === "promo";
|
|
536
538
|
return /*#__PURE__*/React__default.createElement("button", {
|
|
537
539
|
type: "button",
|
|
538
|
-
className: classnames(styles$
|
|
540
|
+
className: classnames(styles$t.dismiss, isPromo && styles$t["dismiss--promo"]),
|
|
539
541
|
...props
|
|
540
542
|
}, /*#__PURE__*/React__default.createElement(X, {
|
|
541
543
|
fill: isPromo ? "currentColor" : "white",
|
|
@@ -615,9 +617,9 @@ class StyledAnnouncement extends React__default.Component {
|
|
|
615
617
|
...platformProps
|
|
616
618
|
} = this.props;
|
|
617
619
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
618
|
-
className: styles$
|
|
620
|
+
className: styles$t["announcement"]
|
|
619
621
|
}, /*#__PURE__*/React__default.createElement(AnnouncementIcon, null), /*#__PURE__*/React__default.createElement("div", {
|
|
620
|
-
className: styles$
|
|
622
|
+
className: styles$t["announcement-content"],
|
|
621
623
|
style: style,
|
|
622
624
|
...platformProps
|
|
623
625
|
}));
|
|
@@ -628,7 +630,7 @@ function StyledDismissButton({
|
|
|
628
630
|
}) {
|
|
629
631
|
return /*#__PURE__*/React__default.createElement("button", {
|
|
630
632
|
type: "button",
|
|
631
|
-
className: styles$
|
|
633
|
+
className: styles$t.dismiss,
|
|
632
634
|
...props
|
|
633
635
|
}, /*#__PURE__*/React__default.createElement(X, {
|
|
634
636
|
fill: "white",
|
|
@@ -1750,7 +1752,7 @@ function MonoAppIcon({
|
|
|
1750
1752
|
})) : (/*#__PURE__*/React__default.createElement("div", null, "appName not supported")));
|
|
1751
1753
|
}
|
|
1752
1754
|
|
|
1753
|
-
var styles$
|
|
1755
|
+
var styles$s = {"name":"name-UNqbW"};
|
|
1754
1756
|
|
|
1755
1757
|
const AppRow = ({
|
|
1756
1758
|
appName,
|
|
@@ -1758,25 +1760,23 @@ const AppRow = ({
|
|
|
1758
1760
|
iconSize = 24
|
|
1759
1761
|
}) => {
|
|
1760
1762
|
if (appName === "Accounts") {
|
|
1761
|
-
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(
|
|
1762
|
-
className: styles$k["icon-slot"]
|
|
1763
|
-
}, /*#__PURE__*/React__default.createElement(MonoAppIcon, {
|
|
1763
|
+
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(MonoAppIcon, {
|
|
1764
1764
|
appName: "Accounts",
|
|
1765
1765
|
colors: colors,
|
|
1766
1766
|
size: iconSize
|
|
1767
|
-
})
|
|
1768
|
-
className: styles$
|
|
1767
|
+
}), /*#__PURE__*/React__default.createElement("span", {
|
|
1768
|
+
className: styles$s.name
|
|
1769
1769
|
}, "Account settings"));
|
|
1770
1770
|
}
|
|
1771
1771
|
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(ColorAppIcon, {
|
|
1772
1772
|
appName: appName.replace(/[\s-]/, ""),
|
|
1773
1773
|
size: iconSize
|
|
1774
1774
|
}), /*#__PURE__*/React__default.createElement("span", {
|
|
1775
|
-
className: styles$
|
|
1775
|
+
className: styles$s.name
|
|
1776
1776
|
}, appName));
|
|
1777
1777
|
};
|
|
1778
1778
|
|
|
1779
|
-
var styles$
|
|
1779
|
+
var styles$r = {"button":"button-XMbeQ","label":"label-884of","chevron":"chevron-RRg9k"};
|
|
1780
1780
|
|
|
1781
1781
|
const AppsButton = /*#__PURE__*/React__default.forwardRef(({
|
|
1782
1782
|
appName,
|
|
@@ -1788,27 +1788,27 @@ const AppsButton = /*#__PURE__*/React__default.forwardRef(({
|
|
|
1788
1788
|
...restProps,
|
|
1789
1789
|
ref: ref,
|
|
1790
1790
|
"aria-label": `App switcher: ${appName}`,
|
|
1791
|
-
className: styles$
|
|
1791
|
+
className: styles$r.button,
|
|
1792
1792
|
kind: "neutral-inline",
|
|
1793
1793
|
label: /*#__PURE__*/React__default.createElement("span", {
|
|
1794
|
-
className: styles$
|
|
1794
|
+
className: styles$r.label
|
|
1795
1795
|
}, isAccounts ? "Account settings" : appName),
|
|
1796
1796
|
prefix: isAccounts ? (/*#__PURE__*/React__default.createElement(MonoAppIcon, {
|
|
1797
1797
|
appName: "Accounts",
|
|
1798
1798
|
colors: colors,
|
|
1799
|
-
size:
|
|
1799
|
+
size: 24
|
|
1800
1800
|
})) : (/*#__PURE__*/React__default.createElement(ColorAppIcon, {
|
|
1801
1801
|
appName: appName.replace(/[\s-]/, ""),
|
|
1802
|
-
size:
|
|
1802
|
+
size: 24
|
|
1803
1803
|
})),
|
|
1804
1804
|
suffix: /*#__PURE__*/React__default.createElement(DisclosureChevronIcon, {
|
|
1805
|
-
className: `${styles$
|
|
1805
|
+
className: `${styles$r.chevron} symbol`
|
|
1806
1806
|
})
|
|
1807
1807
|
});
|
|
1808
1808
|
});
|
|
1809
1809
|
AppsButton.displayName = "AppsButton";
|
|
1810
1810
|
|
|
1811
|
-
var styles$
|
|
1811
|
+
var styles$q = {"nav":"nav-y-6ML","popover-content":"popover-content-jOAAY","list":"list-jUxvp","link":"link-LMp2h","current":"current-4U4VL","accounts-item":"accounts-item-erJW0","accounts-link":"accounts-link-4jwPW"};
|
|
1812
1812
|
|
|
1813
1813
|
const AppsMenu = ({
|
|
1814
1814
|
appName,
|
|
@@ -1829,8 +1829,8 @@ const AppsMenu = ({
|
|
|
1829
1829
|
}, /*#__PURE__*/React__default.createElement("a", {
|
|
1830
1830
|
"aria-current": isCurrent ? "page" : undefined,
|
|
1831
1831
|
"aria-label": name,
|
|
1832
|
-
className: classnames(styles$
|
|
1833
|
-
[styles$
|
|
1832
|
+
className: classnames(styles$q.link, {
|
|
1833
|
+
[styles$q.current]: isCurrent
|
|
1834
1834
|
}),
|
|
1835
1835
|
"data-pendo": `app-switcher--change-app--${name}`,
|
|
1836
1836
|
"data-turbolinks": false,
|
|
@@ -1846,22 +1846,22 @@ const AppsMenu = ({
|
|
|
1846
1846
|
colors: colors
|
|
1847
1847
|
})), /*#__PURE__*/React__default.createElement(PopoverContent, {
|
|
1848
1848
|
"aria-label": "Switch app",
|
|
1849
|
-
className: styles$
|
|
1849
|
+
className: styles$q["popover-content"],
|
|
1850
1850
|
placement: "bottom start"
|
|
1851
1851
|
}, /*#__PURE__*/React__default.createElement("nav", {
|
|
1852
|
-
className: styles$
|
|
1852
|
+
className: styles$q.nav,
|
|
1853
1853
|
"data-pendo": "app-switcher"
|
|
1854
1854
|
}, /*#__PURE__*/React__default.createElement("ul", {
|
|
1855
|
-
className: styles$
|
|
1855
|
+
className: styles$q.list,
|
|
1856
1856
|
role: "list"
|
|
1857
1857
|
}, homeProduct && renderProductLink(homeProduct.name), restProducts.map(({
|
|
1858
1858
|
name
|
|
1859
1859
|
}) => renderProductLink(name)), accountsProduct && (/*#__PURE__*/React__default.createElement("li", {
|
|
1860
|
-
className: styles$
|
|
1860
|
+
className: styles$q["accounts-item"]
|
|
1861
1861
|
}, /*#__PURE__*/React__default.createElement("a", {
|
|
1862
1862
|
"aria-current": appName === accountsProduct.name ? "page" : undefined,
|
|
1863
1863
|
"aria-label": "Account settings",
|
|
1864
|
-
className: classnames(styles$
|
|
1864
|
+
className: classnames(styles$q.link, styles$q["accounts-link"]),
|
|
1865
1865
|
"data-pendo": "app-switcher--change-app--Accounts",
|
|
1866
1866
|
"data-turbolinks": false,
|
|
1867
1867
|
href: pcoUrl$1(env)("accounts") + getAppsSwitchProductPath(accountsProduct.name)
|
|
@@ -2069,7 +2069,7 @@ function MonoAppName({
|
|
|
2069
2069
|
})) : (/*#__PURE__*/React__default.createElement("div", null, "appName not supported"));
|
|
2070
2070
|
}
|
|
2071
2071
|
|
|
2072
|
-
var styles$
|
|
2072
|
+
var styles$p = {"unbutton":"unbutton-lEbTR"};
|
|
2073
2073
|
|
|
2074
2074
|
function Unbutton({
|
|
2075
2075
|
className,
|
|
@@ -2078,7 +2078,7 @@ function Unbutton({
|
|
|
2078
2078
|
...nativeProps
|
|
2079
2079
|
}) {
|
|
2080
2080
|
return /*#__PURE__*/React__default.createElement("button", {
|
|
2081
|
-
className: classnames(styles$
|
|
2081
|
+
className: classnames(styles$p.unbutton, className),
|
|
2082
2082
|
style: {
|
|
2083
2083
|
...style
|
|
2084
2084
|
},
|
|
@@ -2087,7 +2087,7 @@ function Unbutton({
|
|
|
2087
2087
|
});
|
|
2088
2088
|
}
|
|
2089
2089
|
|
|
2090
|
-
var styles$
|
|
2090
|
+
var styles$o = {"button":"button-wsipc","button-accounts":"button-accounts-zQmBM","chevron":"chevron-obyBF","is-expanded":"is-expanded-PoCQ9"};
|
|
2091
2091
|
|
|
2092
2092
|
const LegacyAppsButton = ({
|
|
2093
2093
|
appName,
|
|
@@ -2102,8 +2102,8 @@ const LegacyAppsButton = ({
|
|
|
2102
2102
|
"aria-haspopup": "true",
|
|
2103
2103
|
"aria-label": `App switcher: ${appName}`,
|
|
2104
2104
|
onClick: onClick,
|
|
2105
|
-
className: classnames(styles$
|
|
2106
|
-
[styles$
|
|
2105
|
+
className: classnames(styles$o.button, {
|
|
2106
|
+
[styles$o["is-expanded"]]: expanded
|
|
2107
2107
|
}),
|
|
2108
2108
|
type: "button",
|
|
2109
2109
|
style: style,
|
|
@@ -2112,7 +2112,7 @@ const LegacyAppsButton = ({
|
|
|
2112
2112
|
appName: "Accounts",
|
|
2113
2113
|
colors: colors
|
|
2114
2114
|
}), /*#__PURE__*/React__default.createElement("div", {
|
|
2115
|
-
className: styles$
|
|
2115
|
+
className: styles$o["button-accounts"]
|
|
2116
2116
|
}, "Account settings"))) : (/*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(ColorAppIcon, {
|
|
2117
2117
|
appName: appName.replace(/[\s-]/, "")
|
|
2118
2118
|
}), /*#__PURE__*/React__default.createElement(MonoAppName, {
|
|
@@ -2120,7 +2120,7 @@ const LegacyAppsButton = ({
|
|
|
2120
2120
|
key: "mono-app-name",
|
|
2121
2121
|
size: 24
|
|
2122
2122
|
}))), /*#__PURE__*/React__default.createElement(DisclosureChevronIcon, {
|
|
2123
|
-
className: styles$
|
|
2123
|
+
className: styles$o.chevron,
|
|
2124
2124
|
key: "disclosure-chevron-icon"
|
|
2125
2125
|
}));
|
|
2126
2126
|
};
|
|
@@ -2253,7 +2253,7 @@ class Outsider extends React__default.Component {
|
|
|
2253
2253
|
}
|
|
2254
2254
|
}
|
|
2255
2255
|
|
|
2256
|
-
var styles$
|
|
2256
|
+
var styles$n = {"popup-root":"popup-root-SeL5u","popup":"popup-nQXYW","is-visible":"is-visible-3DAUP"};
|
|
2257
2257
|
|
|
2258
2258
|
const Popup = ({
|
|
2259
2259
|
className,
|
|
@@ -2261,8 +2261,8 @@ const Popup = ({
|
|
|
2261
2261
|
isVisible,
|
|
2262
2262
|
...nativeProps
|
|
2263
2263
|
}) => (/*#__PURE__*/React__default.createElement(C, {
|
|
2264
|
-
className: classnames(styles$
|
|
2265
|
-
[styles$
|
|
2264
|
+
className: classnames(styles$n.popup, {
|
|
2265
|
+
[styles$n["is-visible"]]: isVisible
|
|
2266
2266
|
}, className),
|
|
2267
2267
|
...nativeProps
|
|
2268
2268
|
}));
|
|
@@ -2270,11 +2270,11 @@ const Popup = ({
|
|
|
2270
2270
|
const PopupRoot = ({
|
|
2271
2271
|
...nativeProps
|
|
2272
2272
|
}) => (/*#__PURE__*/React__default.createElement("div", {
|
|
2273
|
-
className: styles$
|
|
2273
|
+
className: styles$n["popup-root"],
|
|
2274
2274
|
...nativeProps
|
|
2275
2275
|
}));
|
|
2276
2276
|
|
|
2277
|
-
var styles$
|
|
2277
|
+
var styles$m = {"popup":"popup-bVhSa"};
|
|
2278
2278
|
|
|
2279
2279
|
const LegacyAppsMenu = ({
|
|
2280
2280
|
appName,
|
|
@@ -2312,7 +2312,7 @@ const LegacyAppsMenu = ({
|
|
|
2312
2312
|
cleanup: !visible,
|
|
2313
2313
|
component: Outsider,
|
|
2314
2314
|
onOutsideClick: toggle,
|
|
2315
|
-
className: styles$
|
|
2315
|
+
className: styles$m.popup,
|
|
2316
2316
|
isVisible: visible
|
|
2317
2317
|
}, /*#__PURE__*/React__default.createElement("menu", {
|
|
2318
2318
|
ref: menuRef,
|
|
@@ -3222,37 +3222,144 @@ const useUpdateStore = () => useCallback(updates => {
|
|
|
3222
3222
|
});
|
|
3223
3223
|
}, []);
|
|
3224
3224
|
|
|
3225
|
+
const collections = {
|
|
3226
|
+
general,
|
|
3227
|
+
toolbar
|
|
3228
|
+
};
|
|
3229
|
+
const paths = collections;
|
|
3230
|
+
function Icon({
|
|
3231
|
+
name,
|
|
3232
|
+
size = 16,
|
|
3233
|
+
style,
|
|
3234
|
+
theme,
|
|
3235
|
+
title,
|
|
3236
|
+
...props
|
|
3237
|
+
}) {
|
|
3238
|
+
const [collection, symbol] = name.split(".");
|
|
3239
|
+
return /*#__PURE__*/React__default.createElement("svg", {
|
|
3240
|
+
"aria-hidden": title ? undefined : true,
|
|
3241
|
+
fill: "currentColor",
|
|
3242
|
+
height: size,
|
|
3243
|
+
role: title ? "img" : undefined,
|
|
3244
|
+
style: {
|
|
3245
|
+
color: theme && `var(${theme})`,
|
|
3246
|
+
flexShrink: 0,
|
|
3247
|
+
...style
|
|
3248
|
+
},
|
|
3249
|
+
viewBox: "0 0 16 16",
|
|
3250
|
+
width: size,
|
|
3251
|
+
...props
|
|
3252
|
+
}, title && /*#__PURE__*/React__default.createElement("title", null, title), /*#__PURE__*/React__default.createElement("path", {
|
|
3253
|
+
d: paths[collection][symbol]
|
|
3254
|
+
}));
|
|
3255
|
+
}
|
|
3256
|
+
|
|
3257
|
+
const SEARCHABLE_PRODUCTS = [{
|
|
3258
|
+
appName: "Calendar",
|
|
3259
|
+
slug: "calendar"
|
|
3260
|
+
}, {
|
|
3261
|
+
appName: "Check-Ins",
|
|
3262
|
+
slug: "check-ins"
|
|
3263
|
+
}, {
|
|
3264
|
+
appName: "Giving",
|
|
3265
|
+
slug: "giving"
|
|
3266
|
+
}, {
|
|
3267
|
+
appName: "Groups",
|
|
3268
|
+
slug: "groups"
|
|
3269
|
+
}, {
|
|
3270
|
+
appName: "People",
|
|
3271
|
+
slug: "people"
|
|
3272
|
+
}, {
|
|
3273
|
+
appName: "Publishing",
|
|
3274
|
+
slug: "publishing"
|
|
3275
|
+
}, {
|
|
3276
|
+
appName: "Registrations",
|
|
3277
|
+
slug: "registrations"
|
|
3278
|
+
}, {
|
|
3279
|
+
appName: "Services",
|
|
3280
|
+
slug: "services"
|
|
3281
|
+
}];
|
|
3282
|
+
const KEYBOARD_SHORTCUTS = {
|
|
3283
|
+
copyLink: {
|
|
3284
|
+
key: "c",
|
|
3285
|
+
label: "Copy link",
|
|
3286
|
+
modifierKey: true
|
|
3287
|
+
},
|
|
3288
|
+
openInNewTab: {
|
|
3289
|
+
label: "Open in new tab"},
|
|
3290
|
+
openSearch: {
|
|
3291
|
+
key: "k",
|
|
3292
|
+
label: "Open search",
|
|
3293
|
+
modifierKey: true
|
|
3294
|
+
},
|
|
3295
|
+
select: {
|
|
3296
|
+
label: "Select",
|
|
3297
|
+
modifierKey: false,
|
|
3298
|
+
next: "ArrowDown",
|
|
3299
|
+
previous: "ArrowUp"
|
|
3300
|
+
}
|
|
3301
|
+
};
|
|
3302
|
+
|
|
3225
3303
|
const isMac = () => /Mac|iPhone|iPad|iPod/.test(navigator.platform);
|
|
3226
3304
|
const hasCommandKey = event => isMac() ? event.metaKey : event.ctrlKey;
|
|
3227
|
-
const
|
|
3228
|
-
|
|
3305
|
+
const matchesShortcut = (shortcut, event) => {
|
|
3306
|
+
var _a;
|
|
3307
|
+
// Chrome's autofill sends a keydown with no key.
|
|
3308
|
+
return ((_a = event.key) === null || _a === void 0 ? void 0 : _a.toLowerCase()) === shortcut.key && !event.altKey && !event.shiftKey && hasCommandKey(event) === shortcut.modifierKey;
|
|
3309
|
+
};
|
|
3310
|
+
const isSearchShortcut = event => matchesShortcut(KEYBOARD_SHORTCUTS.openSearch, event);
|
|
3229
3311
|
// Products opened their own search with `/` before this one replaced it.
|
|
3230
3312
|
const isLegacySearchShortcut = event => event.key === "/" && !event.altKey && !event.ctrlKey && !event.metaKey && !isTypingIn(event.target);
|
|
3231
|
-
const isCopyShortcut = event =>
|
|
3313
|
+
const isCopyShortcut = event => matchesShortcut(KEYBOARD_SHORTCUTS.copyLink, event);
|
|
3232
3314
|
const isTypingIn = target => target instanceof Element && target.closest('input, select, textarea, [contenteditable]:not([contenteditable="false"])') !== null;
|
|
3233
3315
|
const isTypingKey = event => event.key.length === 1 && event.key !== " " && !event.altKey && !event.ctrlKey && !event.metaKey;
|
|
3234
3316
|
const verticalStep = key => ({
|
|
3235
|
-
|
|
3236
|
-
|
|
3317
|
+
[KEYBOARD_SHORTCUTS.select.next]: 1,
|
|
3318
|
+
[KEYBOARD_SHORTCUTS.select.previous]: -1
|
|
3237
3319
|
})[key];
|
|
3238
3320
|
const horizontalStep = key => ({
|
|
3239
3321
|
ArrowLeft: -1,
|
|
3240
3322
|
ArrowRight: 1
|
|
3241
3323
|
})[key];
|
|
3242
3324
|
|
|
3325
|
+
var styles$l = {"searchButton":"searchButton-fYa5-"};
|
|
3326
|
+
|
|
3243
3327
|
function SearchButton({
|
|
3328
|
+
mobile = false,
|
|
3244
3329
|
onClick
|
|
3245
3330
|
}) {
|
|
3246
3331
|
return /*#__PURE__*/React__default.createElement("button", {
|
|
3247
|
-
"aria-keyshortcuts": `${isMac() ? "Meta
|
|
3332
|
+
"aria-keyshortcuts": mobile ? undefined : `${isMac() ? "Meta" : "Control"}+${KEYBOARD_SHORTCUTS.openSearch.key.toUpperCase()} /`,
|
|
3248
3333
|
"aria-label": "Search",
|
|
3334
|
+
className: styles$l.searchButton,
|
|
3335
|
+
"data-search-button": true,
|
|
3249
3336
|
onClick: onClick,
|
|
3250
3337
|
type: "button"
|
|
3251
|
-
}, /*#__PURE__*/React__default.createElement(
|
|
3252
|
-
|
|
3338
|
+
}, /*#__PURE__*/React__default.createElement(Icon, {
|
|
3339
|
+
name: "general.search",
|
|
3340
|
+
size: mobile ? 18 : 14
|
|
3253
3341
|
}));
|
|
3254
3342
|
}
|
|
3255
3343
|
|
|
3344
|
+
// With the search's own debounce, about 1.4 seconds after the last keystroke,
|
|
3345
|
+
// as in GOV.UK's accessible-autocomplete.
|
|
3346
|
+
const ANNOUNCEMENT_DELAY_MS = 1100;
|
|
3347
|
+
// Screen readers echo typing themselves, as each person has set them to, so
|
|
3348
|
+
// the message waits until typing settles instead of talking over it. Waiting
|
|
3349
|
+
// also lets VoiceOver finish what focus had to say, since it often skips a
|
|
3350
|
+
// change made as focus moves, as when a tab with cached results is selected,
|
|
3351
|
+
// and only the tab someone stops on when arrowing through them is announced.
|
|
3352
|
+
// The region empties at once, so a message that comes back is read again.
|
|
3353
|
+
function useAnnouncement(message) {
|
|
3354
|
+
const [announcement, setAnnouncement] = React__default.useState(null);
|
|
3355
|
+
React__default.useEffect(() => {
|
|
3356
|
+
setAnnouncement(null);
|
|
3357
|
+
const timeout = setTimeout(() => setAnnouncement(message), ANNOUNCEMENT_DELAY_MS);
|
|
3358
|
+
return () => clearTimeout(timeout);
|
|
3359
|
+
}, [message]);
|
|
3360
|
+
return announcement;
|
|
3361
|
+
}
|
|
3362
|
+
|
|
3256
3363
|
// useId isn't available on React 17, which our peer range still supports.
|
|
3257
3364
|
let instanceCount$1 = 0;
|
|
3258
3365
|
function useInstanceId(prefix) {
|
|
@@ -3522,7 +3629,7 @@ const store = createStore(getAllPcoMeta());
|
|
|
3522
3629
|
const recentlyVisitableMetadataStore = createStore({
|
|
3523
3630
|
metadata: getRecentlyVisitableMetadata()
|
|
3524
3631
|
});
|
|
3525
|
-
function sync() {
|
|
3632
|
+
function sync$1() {
|
|
3526
3633
|
const nextState = getAllPcoMeta();
|
|
3527
3634
|
if (!shallowCompare(store.getState(), nextState)) store.setState(nextState);
|
|
3528
3635
|
const metadata = getRecentlyVisitableMetadata();
|
|
@@ -3532,7 +3639,7 @@ function sync() {
|
|
|
3532
3639
|
});
|
|
3533
3640
|
}
|
|
3534
3641
|
}
|
|
3535
|
-
const observer = new MutationObserver(sync);
|
|
3642
|
+
const observer = new MutationObserver(sync$1);
|
|
3536
3643
|
let hasTriggeredObserve = false;
|
|
3537
3644
|
function observe() {
|
|
3538
3645
|
if (hasTriggeredObserve) return;
|
|
@@ -3543,7 +3650,7 @@ function observe() {
|
|
|
3543
3650
|
// never mutate afterward, so the observer alone would never catch them.
|
|
3544
3651
|
// Re-read once now, since observe() is only called once a consumer is
|
|
3545
3652
|
// actually mounting, which is always after the document has fully parsed.
|
|
3546
|
-
sync();
|
|
3653
|
+
sync$1();
|
|
3547
3654
|
observer.observe(document.head, {
|
|
3548
3655
|
attributes: true,
|
|
3549
3656
|
childList: true,
|
|
@@ -3559,21 +3666,19 @@ function useRecentlyVisitableMetadata() {
|
|
|
3559
3666
|
return useSyncExternalStore(recentlyVisitableMetadataStore.subscribe, () => recentlyVisitableMetadataStore.getState().metadata);
|
|
3560
3667
|
}
|
|
3561
3668
|
|
|
3562
|
-
// Entries match the ones home-mobile stores, so one list can sync across web
|
|
3563
|
-
// and mobile.
|
|
3564
|
-
const ENTRY_VERSION = 3;
|
|
3565
3669
|
const MAX_ENTRIES = 50;
|
|
3670
|
+
const MAX_ENTRY_BYTES = 1024;
|
|
3566
3671
|
const MAX_TEXT_LENGTH = 200;
|
|
3567
|
-
const PRODUCTS = ["accounts", "calendar", "check-ins", "giving", "groups", "home", "login", "people", "publishing", "registrations", "services"];
|
|
3672
|
+
const PRODUCTS$1 = ["accounts", "calendar", "check-ins", "giving", "groups", "home", "login", "people", "publishing", "registrations", "services"];
|
|
3568
3673
|
// Login has no pages worth returning to.
|
|
3569
|
-
const APPS = PRODUCTS.filter(product => product !== "login");
|
|
3674
|
+
const APPS = PRODUCTS$1.filter(product => product !== "login");
|
|
3570
3675
|
function isId(value) {
|
|
3571
3676
|
return value !== "" && Array.from(value).every(character => character >= "0" && character <= "9");
|
|
3572
3677
|
}
|
|
3573
3678
|
// A PCRL looks like `<product>/v2/<resource_type>/<id>`.
|
|
3574
3679
|
function isPcrl(value) {
|
|
3575
3680
|
const segments = value.split("/");
|
|
3576
|
-
return segments.length === 4 && PRODUCTS.some(product => product === segments[0]) && isId(segments[3]);
|
|
3681
|
+
return segments.length === 4 && PRODUCTS$1.some(product => product === segments[0]) && isId(segments[3]);
|
|
3577
3682
|
}
|
|
3578
3683
|
function isApp(value) {
|
|
3579
3684
|
return APPS.some(app => app === value);
|
|
@@ -3609,8 +3714,8 @@ function entryKey(entry) {
|
|
|
3609
3714
|
return `page:${entry.app}:${entry.path.split("?")[0]}`;
|
|
3610
3715
|
}
|
|
3611
3716
|
}
|
|
3612
|
-
function
|
|
3613
|
-
if (!isRecord(value) ||
|
|
3717
|
+
function hasEntryShape(value) {
|
|
3718
|
+
if (!isRecord(value) || typeof value.visitedAt !== "string") {
|
|
3614
3719
|
return false;
|
|
3615
3720
|
} else if (value.type === "resource") {
|
|
3616
3721
|
return typeof value.pcrl === "string" && isPcrl(value.pcrl);
|
|
@@ -3620,15 +3725,38 @@ function isEntry(value) {
|
|
|
3620
3725
|
return false;
|
|
3621
3726
|
}
|
|
3622
3727
|
}
|
|
3728
|
+
function utf8Length(value) {
|
|
3729
|
+
return Array.from(value).reduce((length, character) => {
|
|
3730
|
+
var _a;
|
|
3731
|
+
const codePoint = (_a = character.codePointAt(0)) !== null && _a !== void 0 ? _a : 0;
|
|
3732
|
+
if (codePoint < 0x80) {
|
|
3733
|
+
return length + 1;
|
|
3734
|
+
} else if (codePoint < 0x800) {
|
|
3735
|
+
return length + 2;
|
|
3736
|
+
} else if (codePoint < 0x10000) {
|
|
3737
|
+
return length + 3;
|
|
3738
|
+
} else {
|
|
3739
|
+
return length + 4;
|
|
3740
|
+
}
|
|
3741
|
+
}, 0);
|
|
3742
|
+
}
|
|
3743
|
+
function excessBytes(entry) {
|
|
3744
|
+
return utf8Length(JSON.stringify(entry)) - MAX_ENTRY_BYTES;
|
|
3745
|
+
}
|
|
3746
|
+
// user-store-sync rejects a whole write over one entry above its size limit,
|
|
3747
|
+
// so an entry that can't fit isn't one this list can hold.
|
|
3748
|
+
function isEntry(value) {
|
|
3749
|
+
return hasEntryShape(value) && excessBytes(value) <= 0;
|
|
3750
|
+
}
|
|
3623
3751
|
// Cuts on code points so a surrogate pair is never split.
|
|
3624
3752
|
function clampText(value) {
|
|
3625
3753
|
return Array.from(value).slice(0, MAX_TEXT_LENGTH).join("");
|
|
3626
3754
|
}
|
|
3627
|
-
function
|
|
3755
|
+
function metadataFrom({
|
|
3628
3756
|
details,
|
|
3629
3757
|
type
|
|
3630
3758
|
}) {
|
|
3631
|
-
|
|
3759
|
+
const metadata = {
|
|
3632
3760
|
...(details && {
|
|
3633
3761
|
details: clampText(details)
|
|
3634
3762
|
}),
|
|
@@ -3636,39 +3764,124 @@ function clampMetadata({
|
|
|
3636
3764
|
type: clampText(type)
|
|
3637
3765
|
})
|
|
3638
3766
|
};
|
|
3767
|
+
return Object.keys(metadata).length > 0 ? {
|
|
3768
|
+
metadata
|
|
3769
|
+
} : {};
|
|
3770
|
+
}
|
|
3771
|
+
function pageEntry({
|
|
3772
|
+
app,
|
|
3773
|
+
path,
|
|
3774
|
+
visitedAt
|
|
3775
|
+
}, {
|
|
3776
|
+
details,
|
|
3777
|
+
title,
|
|
3778
|
+
type
|
|
3779
|
+
}) {
|
|
3780
|
+
return {
|
|
3781
|
+
app,
|
|
3782
|
+
...metadataFrom({
|
|
3783
|
+
details,
|
|
3784
|
+
type
|
|
3785
|
+
}),
|
|
3786
|
+
path,
|
|
3787
|
+
title: clampText(title),
|
|
3788
|
+
type: "page",
|
|
3789
|
+
visitedAt
|
|
3790
|
+
};
|
|
3791
|
+
}
|
|
3792
|
+
function texts(entry) {
|
|
3793
|
+
var _a, _b, _c, _d;
|
|
3794
|
+
return {
|
|
3795
|
+
details: (_b = (_a = entry.metadata) === null || _a === void 0 ? void 0 : _a.details) !== null && _b !== void 0 ? _b : "",
|
|
3796
|
+
title: entry.title,
|
|
3797
|
+
type: (_d = (_c = entry.metadata) === null || _c === void 0 ? void 0 : _c.type) !== null && _d !== void 0 ? _d : ""
|
|
3798
|
+
};
|
|
3799
|
+
}
|
|
3800
|
+
function jsonBytes(value) {
|
|
3801
|
+
return utf8Length(JSON.stringify(value)) - 2;
|
|
3639
3802
|
}
|
|
3640
|
-
function
|
|
3641
|
-
|
|
3642
|
-
|
|
3803
|
+
function longestText(entry) {
|
|
3804
|
+
return Object.entries(texts(entry)).reduce((longest, candidate) => jsonBytes(candidate[1]) > jsonBytes(longest[1]) ? candidate : longest);
|
|
3805
|
+
}
|
|
3806
|
+
// Takes whole characters off the end until at least `excess` bytes are gone,
|
|
3807
|
+
// so a surrogate pair is never split.
|
|
3808
|
+
function shortenBy(value, excess, minLength) {
|
|
3809
|
+
var _a;
|
|
3810
|
+
const characters = Array.from(value);
|
|
3811
|
+
let removed = 0;
|
|
3812
|
+
while (characters.length > minLength && removed < excess) {
|
|
3813
|
+
removed += jsonBytes((_a = characters.pop()) !== null && _a !== void 0 ? _a : "");
|
|
3814
|
+
}
|
|
3815
|
+
return characters.join("");
|
|
3816
|
+
}
|
|
3817
|
+
// Trims the longest text field by the overflow, repeating until the entry
|
|
3818
|
+
// fits or the title is down to one character.
|
|
3819
|
+
function trimTexts(entry) {
|
|
3820
|
+
const excess = excessBytes(entry);
|
|
3821
|
+
const [field, value] = longestText(entry);
|
|
3822
|
+
const shortened = shortenBy(value, excess, field === "title" ? 1 : 0);
|
|
3823
|
+
if (excess <= 0 || shortened === value) {
|
|
3824
|
+
return entry;
|
|
3643
3825
|
} else {
|
|
3644
|
-
return {
|
|
3645
|
-
...
|
|
3646
|
-
|
|
3647
|
-
|
|
3648
|
-
|
|
3649
|
-
|
|
3650
|
-
|
|
3826
|
+
return trimTexts(pageEntry(entry, {
|
|
3827
|
+
...texts(entry),
|
|
3828
|
+
[field]: shortened
|
|
3829
|
+
}));
|
|
3830
|
+
}
|
|
3831
|
+
}
|
|
3832
|
+
// The query string is the first thing to go, since it's not part of the
|
|
3833
|
+
// page's identity; what's left is trimmed to fit under the service's limit.
|
|
3834
|
+
function fitPage(entry) {
|
|
3835
|
+
if (excessBytes(entry) <= 0) {
|
|
3836
|
+
return entry;
|
|
3837
|
+
} else {
|
|
3838
|
+
return trimTexts({
|
|
3839
|
+
...entry,
|
|
3840
|
+
path: entry.path.split("?")[0]
|
|
3841
|
+
});
|
|
3651
3842
|
}
|
|
3652
3843
|
}
|
|
3653
3844
|
function toEntry(visit, visitedAt) {
|
|
3654
|
-
|
|
3655
|
-
...
|
|
3656
|
-
version: ENTRY_VERSION,
|
|
3845
|
+
const entry = {
|
|
3846
|
+
...visit,
|
|
3657
3847
|
visitedAt: visitedAt.toISOString()
|
|
3658
3848
|
};
|
|
3849
|
+
if (entry.type === "resource") {
|
|
3850
|
+
return entry;
|
|
3851
|
+
} else {
|
|
3852
|
+
return fitPage(pageEntry(entry, {
|
|
3853
|
+
...texts(entry),
|
|
3854
|
+
title: entry.title.trim()
|
|
3855
|
+
}));
|
|
3856
|
+
}
|
|
3857
|
+
}
|
|
3858
|
+
// user-store-sync rejects a whole write over one field it doesn't know, so
|
|
3859
|
+
// anything else an entry carries (like the version older entries stored) is
|
|
3860
|
+
// dropped on the way in.
|
|
3861
|
+
function withKnownFields(entry) {
|
|
3862
|
+
if (entry.type === "resource") {
|
|
3863
|
+
return {
|
|
3864
|
+
pcrl: entry.pcrl,
|
|
3865
|
+
type: entry.type,
|
|
3866
|
+
visitedAt: entry.visitedAt
|
|
3867
|
+
};
|
|
3868
|
+
} else {
|
|
3869
|
+
return pageEntry(entry, texts(entry));
|
|
3870
|
+
}
|
|
3659
3871
|
}
|
|
3660
3872
|
// Recents are disposable: anything unexpected reads as an empty list (or, for
|
|
3661
3873
|
// a single bad entry, a list without it) rather than throwing.
|
|
3874
|
+
function entriesFrom(value) {
|
|
3875
|
+
if (Array.isArray(value)) {
|
|
3876
|
+
return value.filter(isEntry).map(withKnownFields);
|
|
3877
|
+
} else {
|
|
3878
|
+
return [];
|
|
3879
|
+
}
|
|
3880
|
+
}
|
|
3662
3881
|
function parseRecentlyVisited(value) {
|
|
3663
|
-
let parsed = null;
|
|
3664
3882
|
try {
|
|
3665
|
-
|
|
3883
|
+
return entriesFrom(JSON.parse(value !== null && value !== void 0 ? value : "null"));
|
|
3666
3884
|
} catch {
|
|
3667
|
-
parsed = null;
|
|
3668
|
-
}
|
|
3669
|
-
if (Array.isArray(parsed)) {
|
|
3670
|
-
return parsed.filter(isEntry);
|
|
3671
|
-
} else {
|
|
3672
3885
|
return [];
|
|
3673
3886
|
}
|
|
3674
3887
|
}
|
|
@@ -3676,6 +3889,39 @@ function addVisit(entries, entry) {
|
|
|
3676
3889
|
const key = entryKey(entry);
|
|
3677
3890
|
return [entry, ...entries.filter(existing => entryKey(existing) !== key)].slice(0, MAX_ENTRIES);
|
|
3678
3891
|
}
|
|
3892
|
+
// The service may write timestamps with fewer fractional digits than
|
|
3893
|
+
// toISOString, so they're compared as times rather than strings.
|
|
3894
|
+
function visitTime(entry) {
|
|
3895
|
+
return isRecord(entry) && typeof entry.visitedAt === "string" ? Date.parse(entry.visitedAt) || 0 : 0;
|
|
3896
|
+
}
|
|
3897
|
+
function newestFirst(entries) {
|
|
3898
|
+
const seen = new Set();
|
|
3899
|
+
return entries.sort((a, b) => visitTime(b) - visitTime(a)).filter(entry => {
|
|
3900
|
+
if (isEntry(entry)) {
|
|
3901
|
+
const key = entryKey(entry);
|
|
3902
|
+
const isFirst = !seen.has(key);
|
|
3903
|
+
seen.add(key);
|
|
3904
|
+
return isFirst;
|
|
3905
|
+
} else {
|
|
3906
|
+
return true;
|
|
3907
|
+
}
|
|
3908
|
+
}).slice(0, MAX_ENTRIES);
|
|
3909
|
+
}
|
|
3910
|
+
// One list from several, newest visit first wherever it was recorded.
|
|
3911
|
+
function mergeEntries(...lists) {
|
|
3912
|
+
return newestFirst(lists.flat());
|
|
3913
|
+
}
|
|
3914
|
+
// Products pin different topbar versions, so the shared list can hold entries
|
|
3915
|
+
// this build doesn't recognize (a newer app or type). They're kept, as stored,
|
|
3916
|
+
// in what's written back, so an older topbar never erases a newer client's
|
|
3917
|
+
// visits. Recognized entries lose unknown fields, as on any read, since one
|
|
3918
|
+
// unknown field would get every write rejected.
|
|
3919
|
+
function mergeStored(stored, local) {
|
|
3920
|
+
return newestFirst([...(Array.isArray(stored) ? stored : []).map(entry => isEntry(entry) ? withKnownFields(entry) : entry), ...local]);
|
|
3921
|
+
}
|
|
3922
|
+
function isSameList(a, b) {
|
|
3923
|
+
return a.length === b.length && a.every((entry, index) => entryKey(entry) === entryKey(b[index]) && visitTime(entry) === visitTime(b[index]));
|
|
3924
|
+
}
|
|
3679
3925
|
|
|
3680
3926
|
// The app whose URL, in this environment, has the current page's host.
|
|
3681
3927
|
// Reversing pcoUrl handles every environment @planningcenter/url knows about,
|
|
@@ -3786,9 +4032,195 @@ function useCurrentPersonId() {
|
|
|
3786
4032
|
return userId == null ? undefined : String(userId);
|
|
3787
4033
|
}
|
|
3788
4034
|
|
|
3789
|
-
//
|
|
3790
|
-
//
|
|
3791
|
-
|
|
4035
|
+
// Tokens last 15 minutes. Refreshing a minute early keeps one from expiring
|
|
4036
|
+
// between reading a token and the service checking it.
|
|
4037
|
+
const REFRESH_MARGIN_MS = 60000;
|
|
4038
|
+
// A failed mint (a CSRF 422, a 5xx, a body that isn't a token) isn't retried
|
|
4039
|
+
// on every visit and panel open; the product is left alone for a while.
|
|
4040
|
+
const MINT_BACKOFF_MS = 5 * 60000;
|
|
4041
|
+
const MAX_ATTEMPTS = 3;
|
|
4042
|
+
// A product without the endpoint answers 404 for the rest of the session, so
|
|
4043
|
+
// it's asked once per tab rather than on every page.
|
|
4044
|
+
const UNAVAILABLE_UNTIL_KEY = "topbar.user_store_sync.unavailable_until";
|
|
4045
|
+
const END_OF_SESSION = Number.MAX_SAFE_INTEGER;
|
|
4046
|
+
// Per person, so switching connected people never writes one person's visits
|
|
4047
|
+
// with another's token.
|
|
4048
|
+
function tokenKey(personId) {
|
|
4049
|
+
return `topbar.user_store_sync.token.${personId}`;
|
|
4050
|
+
}
|
|
4051
|
+
function readSession(key) {
|
|
4052
|
+
try {
|
|
4053
|
+
return sessionStorage.getItem(key);
|
|
4054
|
+
} catch {
|
|
4055
|
+
return null;
|
|
4056
|
+
}
|
|
4057
|
+
}
|
|
4058
|
+
function writeSession(key, value) {
|
|
4059
|
+
try {
|
|
4060
|
+
sessionStorage.setItem(key, value);
|
|
4061
|
+
} catch {
|
|
4062
|
+
// Without sessionStorage the next request just mints again.
|
|
4063
|
+
}
|
|
4064
|
+
}
|
|
4065
|
+
function isUserStoreSyncUnavailable() {
|
|
4066
|
+
return Number(readSession(UNAVAILABLE_UNTIL_KEY)) > Date.now();
|
|
4067
|
+
}
|
|
4068
|
+
function markUnavailable(until) {
|
|
4069
|
+
writeSession(UNAVAILABLE_UNTIL_KEY, String(until));
|
|
4070
|
+
}
|
|
4071
|
+
function isToken(value) {
|
|
4072
|
+
return isRecord(value) && typeof value.token === "string" && typeof value.url === "string" && Number.isFinite(value.expiresAt) && typeof value.readOnly === "boolean";
|
|
4073
|
+
}
|
|
4074
|
+
function cachedToken(personId) {
|
|
4075
|
+
var _a;
|
|
4076
|
+
try {
|
|
4077
|
+
const token = JSON.parse((_a = readSession(tokenKey(personId))) !== null && _a !== void 0 ? _a : "null");
|
|
4078
|
+
if (isToken(token) && token.expiresAt - REFRESH_MARGIN_MS > Date.now()) {
|
|
4079
|
+
return token;
|
|
4080
|
+
} else {
|
|
4081
|
+
return null;
|
|
4082
|
+
}
|
|
4083
|
+
} catch {
|
|
4084
|
+
return null;
|
|
4085
|
+
}
|
|
4086
|
+
}
|
|
4087
|
+
function tokenFrom(json) {
|
|
4088
|
+
if (isRecord(json)) {
|
|
4089
|
+
const token = {
|
|
4090
|
+
expiresAt: typeof json.expires_at === "string" ? Date.parse(json.expires_at) : NaN,
|
|
4091
|
+
readOnly: json.read_only === true,
|
|
4092
|
+
token: json.token,
|
|
4093
|
+
url: json.url
|
|
4094
|
+
};
|
|
4095
|
+
return isToken(token) ? token : null;
|
|
4096
|
+
} else {
|
|
4097
|
+
return null;
|
|
4098
|
+
}
|
|
4099
|
+
}
|
|
4100
|
+
// The JWT's subject is the person's account center id, the same id the
|
|
4101
|
+
// product gives the topbar as `userId`.
|
|
4102
|
+
function subject(token) {
|
|
4103
|
+
var _a;
|
|
4104
|
+
try {
|
|
4105
|
+
const payload = ((_a = token.split(".")[1]) !== null && _a !== void 0 ? _a : "").split("-").join("+").split("_").join("/");
|
|
4106
|
+
const claims = JSON.parse(atob(payload));
|
|
4107
|
+
return isRecord(claims) ? claims.sub : undefined;
|
|
4108
|
+
} catch {
|
|
4109
|
+
return undefined;
|
|
4110
|
+
}
|
|
4111
|
+
}
|
|
4112
|
+
async function mintToken(personId) {
|
|
4113
|
+
const {
|
|
4114
|
+
json,
|
|
4115
|
+
ok,
|
|
4116
|
+
response
|
|
4117
|
+
} = await apiRequest(railsCsrfFetch, `${window.location.origin}/user_store_sync/token`, {
|
|
4118
|
+
method: "POST"
|
|
4119
|
+
});
|
|
4120
|
+
const minted = ok ? tokenFrom(json) : null;
|
|
4121
|
+
// The product mints for whoever the session belongs to now. In a tab left
|
|
4122
|
+
// open after switching to another connected person, that isn't the person
|
|
4123
|
+
// this page rendered for, and syncing with their token would write this
|
|
4124
|
+
// person's visits into their list. The endpoint is working, so there's
|
|
4125
|
+
// nothing to back off from; the next page load picks up the new person.
|
|
4126
|
+
const token = minted && subject(minted.token) === personId ? minted : null;
|
|
4127
|
+
if (token) {
|
|
4128
|
+
writeSession(tokenKey(personId), JSON.stringify(token));
|
|
4129
|
+
} else if ((response === null || response === void 0 ? void 0 : response.status) === 404) {
|
|
4130
|
+
markUnavailable(END_OF_SESSION);
|
|
4131
|
+
} else if (!minted) {
|
|
4132
|
+
markUnavailable(Date.now() + MINT_BACKOFF_MS);
|
|
4133
|
+
}
|
|
4134
|
+
return token;
|
|
4135
|
+
}
|
|
4136
|
+
function hasReadOnlyToken(personId) {
|
|
4137
|
+
var _a;
|
|
4138
|
+
return ((_a = cachedToken(personId)) === null || _a === void 0 ? void 0 : _a.readOnly) === true;
|
|
4139
|
+
}
|
|
4140
|
+
async function request(personId, key, init = {}, isRetry = false) {
|
|
4141
|
+
var _a;
|
|
4142
|
+
const token = isRetry ? await mintToken(personId) : (_a = cachedToken(personId)) !== null && _a !== void 0 ? _a : await mintToken(personId);
|
|
4143
|
+
if (token) {
|
|
4144
|
+
const response = await fetch(`${token.url}/v1/data/${key}`, {
|
|
4145
|
+
...init,
|
|
4146
|
+
headers: {
|
|
4147
|
+
...init.headers,
|
|
4148
|
+
Authorization: `Bearer ${token.token}`
|
|
4149
|
+
}
|
|
4150
|
+
});
|
|
4151
|
+
if (response.status === 401 && !isRetry) {
|
|
4152
|
+
return request(personId, key, init, true);
|
|
4153
|
+
} else {
|
|
4154
|
+
return {
|
|
4155
|
+
response,
|
|
4156
|
+
token
|
|
4157
|
+
};
|
|
4158
|
+
}
|
|
4159
|
+
} else {
|
|
4160
|
+
return null;
|
|
4161
|
+
}
|
|
4162
|
+
}
|
|
4163
|
+
// The service answers version 0 for a person with nothing stored yet, and
|
|
4164
|
+
// takes `If-Match: "0"` for the first write. Without a version at all, the
|
|
4165
|
+
// write goes unconditioned.
|
|
4166
|
+
function ifMatch(version) {
|
|
4167
|
+
return typeof version === "number" ? {
|
|
4168
|
+
"If-Match": `"${version}"`
|
|
4169
|
+
} : {};
|
|
4170
|
+
}
|
|
4171
|
+
// Applies `change` to the stored value and writes the result, rereading and
|
|
4172
|
+
// retrying when another tab or device wrote in between. `change` returns null
|
|
4173
|
+
// when there's nothing to write. A read-only token (staff impersonating
|
|
4174
|
+
// someone) only reads, so nothing is written into the person's history.
|
|
4175
|
+
// Resolves to the value now stored, with whether the token was read-only, or
|
|
4176
|
+
// null when the service couldn't be reached.
|
|
4177
|
+
async function updateStoredValue(personId, key, change, attemptsLeft = MAX_ATTEMPTS) {
|
|
4178
|
+
const read = await request(personId, key);
|
|
4179
|
+
if (read === null || read === void 0 ? void 0 : read.response.ok) {
|
|
4180
|
+
const {
|
|
4181
|
+
value,
|
|
4182
|
+
version
|
|
4183
|
+
} = await read.response.json();
|
|
4184
|
+
const {
|
|
4185
|
+
readOnly
|
|
4186
|
+
} = read.token;
|
|
4187
|
+
const next = readOnly ? null : change(value);
|
|
4188
|
+
if (next === null) {
|
|
4189
|
+
return {
|
|
4190
|
+
readOnly,
|
|
4191
|
+
value: Array.isArray(value) ? value : []
|
|
4192
|
+
};
|
|
4193
|
+
} else {
|
|
4194
|
+
const write = await request(personId, key, {
|
|
4195
|
+
body: JSON.stringify({
|
|
4196
|
+
value: next
|
|
4197
|
+
}),
|
|
4198
|
+
headers: {
|
|
4199
|
+
"Content-Type": "application/json",
|
|
4200
|
+
...ifMatch(version)
|
|
4201
|
+
},
|
|
4202
|
+
method: "PUT"
|
|
4203
|
+
});
|
|
4204
|
+
if (write === null || write === void 0 ? void 0 : write.response.ok) {
|
|
4205
|
+
return {
|
|
4206
|
+
readOnly,
|
|
4207
|
+
value: next
|
|
4208
|
+
};
|
|
4209
|
+
} else if ((write === null || write === void 0 ? void 0 : write.response.status) === 409 && attemptsLeft > 1) {
|
|
4210
|
+
return updateStoredValue(personId, key, change, attemptsLeft - 1);
|
|
4211
|
+
} else {
|
|
4212
|
+
return null;
|
|
4213
|
+
}
|
|
4214
|
+
}
|
|
4215
|
+
} else {
|
|
4216
|
+
return null;
|
|
4217
|
+
}
|
|
4218
|
+
}
|
|
4219
|
+
|
|
4220
|
+
// Each product keeps its own copy in localStorage, and user-store-sync joins
|
|
4221
|
+
// the copies up across products and devices wherever the product can mint a
|
|
4222
|
+
// token for it.
|
|
4223
|
+
const SYNC_KEY = "recently_viewed";
|
|
3792
4224
|
function storageKey({
|
|
3793
4225
|
env,
|
|
3794
4226
|
personId
|
|
@@ -3807,17 +4239,65 @@ function readRecentlyVisited(scope) {
|
|
|
3807
4239
|
return [];
|
|
3808
4240
|
}
|
|
3809
4241
|
}
|
|
4242
|
+
function writeRecentlyVisited(scope, entries) {
|
|
4243
|
+
try {
|
|
4244
|
+
localStorage.setItem(storageKey(scope), JSON.stringify(entries));
|
|
4245
|
+
changes.setState({
|
|
4246
|
+
version: changes.getState().version + 1
|
|
4247
|
+
});
|
|
4248
|
+
} catch {
|
|
4249
|
+
// Storage can be full or blocked; recents are disposable.
|
|
4250
|
+
}
|
|
4251
|
+
}
|
|
4252
|
+
async function syncOnce(scope) {
|
|
4253
|
+
try {
|
|
4254
|
+
const synced = await updateStoredValue(scope.personId, SYNC_KEY, stored => {
|
|
4255
|
+
const shared = entriesFrom(stored);
|
|
4256
|
+
const local = readRecentlyVisited(scope);
|
|
4257
|
+
return isSameList(mergeEntries(shared, local), shared) ? null : mergeStored(stored, local);
|
|
4258
|
+
});
|
|
4259
|
+
if (synced) {
|
|
4260
|
+
const shared = entriesFrom(synced.value);
|
|
4261
|
+
writeRecentlyVisited(scope, synced.readOnly ? shared : mergeEntries(shared, readRecentlyVisited(scope)));
|
|
4262
|
+
}
|
|
4263
|
+
} catch {
|
|
4264
|
+
// The service is best-effort; the local copy stands on its own.
|
|
4265
|
+
}
|
|
4266
|
+
}
|
|
4267
|
+
const syncing = new Map();
|
|
4268
|
+
const syncAgain = new Set();
|
|
4269
|
+
// One sync per list at a time. A visit recorded while one runs schedules a
|
|
4270
|
+
// single follow-up, so it still reaches the service; anything else asking
|
|
4271
|
+
// mid-sync just waits for the one running.
|
|
4272
|
+
function sync(scope, followUp) {
|
|
4273
|
+
const key = storageKey(scope);
|
|
4274
|
+
const running = syncing.get(key);
|
|
4275
|
+
if (isUserStoreSyncUnavailable()) {
|
|
4276
|
+
return Promise.resolve();
|
|
4277
|
+
} else if (running) {
|
|
4278
|
+
if (followUp) syncAgain.add(key);
|
|
4279
|
+
return running;
|
|
4280
|
+
} else {
|
|
4281
|
+
const run = syncOnce(scope).then(() => {
|
|
4282
|
+
syncing.delete(key);
|
|
4283
|
+
return syncAgain.delete(key) ? sync(scope, false) : undefined;
|
|
4284
|
+
});
|
|
4285
|
+
syncing.set(key, run);
|
|
4286
|
+
return run;
|
|
4287
|
+
}
|
|
4288
|
+
}
|
|
4289
|
+
function syncRecentlyVisited(scope) {
|
|
4290
|
+
return sync(scope, false);
|
|
4291
|
+
}
|
|
4292
|
+
// Staff impersonating someone get a read-only token, and their visits stay out
|
|
4293
|
+
// of that person's list. Until the token is minted the visit is kept, and the
|
|
4294
|
+
// sync that mints it replaces the local list with the synced one, so recording
|
|
4295
|
+
// never waits on the network.
|
|
3810
4296
|
function recordVisit(visit, scope) {
|
|
3811
4297
|
const entry = toEntry(visit, new Date());
|
|
3812
|
-
if (isEntry(entry)) {
|
|
3813
|
-
|
|
3814
|
-
|
|
3815
|
-
changes.setState({
|
|
3816
|
-
version: changes.getState().version + 1
|
|
3817
|
-
});
|
|
3818
|
-
} catch {
|
|
3819
|
-
// Storage can be full or blocked; recents are disposable.
|
|
3820
|
-
}
|
|
4298
|
+
if (isEntry(entry) && !hasReadOnlyToken(scope.personId)) {
|
|
4299
|
+
writeRecentlyVisited(scope, addVisit(readRecentlyVisited(scope), entry));
|
|
4300
|
+
sync(scope, true);
|
|
3821
4301
|
}
|
|
3822
4302
|
}
|
|
3823
4303
|
function useRecentlyVisited({
|
|
@@ -3825,6 +4305,14 @@ function useRecentlyVisited({
|
|
|
3825
4305
|
personId
|
|
3826
4306
|
}) {
|
|
3827
4307
|
const version = useSyncExternalStore(changes.subscribe, () => changes.getState().version);
|
|
4308
|
+
useEffect(() => {
|
|
4309
|
+
if (personId) {
|
|
4310
|
+
syncRecentlyVisited({
|
|
4311
|
+
env,
|
|
4312
|
+
personId
|
|
4313
|
+
});
|
|
4314
|
+
}
|
|
4315
|
+
}, [env, personId]);
|
|
3828
4316
|
// `version` isn't read, but listing it re-reads storage after each visit.
|
|
3829
4317
|
return useMemo(() => personId ? readRecentlyVisited({
|
|
3830
4318
|
env,
|
|
@@ -3972,7 +4460,13 @@ function hasSelectedText(element) {
|
|
|
3972
4460
|
return selectedInField || ((_b = (_a = window.getSelection()) === null || _a === void 0 ? void 0 : _a.toString()) !== null && _b !== void 0 ? _b : "") !== "";
|
|
3973
4461
|
}
|
|
3974
4462
|
|
|
3975
|
-
|
|
4463
|
+
// eslint-disable-next-line sort-keys-fix/sort-keys-fix
|
|
4464
|
+
const COPIED_TIMING = {
|
|
4465
|
+
enter: 240,
|
|
4466
|
+
active: 1000,
|
|
4467
|
+
exit: 240
|
|
4468
|
+
};
|
|
4469
|
+
const COPIED_FEEDBACK_MS = COPIED_TIMING.enter + COPIED_TIMING.active + COPIED_TIMING.exit;
|
|
3976
4470
|
// `copiedUrl` stays set briefly after a copy so the UI can confirm it.
|
|
3977
4471
|
function useCopyLink() {
|
|
3978
4472
|
const [copiedUrl, setCopiedUrl] = React__default.useState(null);
|
|
@@ -3993,25 +4487,46 @@ function useCopyLink() {
|
|
|
3993
4487
|
};
|
|
3994
4488
|
}
|
|
3995
4489
|
|
|
4490
|
+
function indexOf(highlight, items, list) {
|
|
4491
|
+
const pinnedIndex = items.findIndex(({
|
|
4492
|
+
key
|
|
4493
|
+
}) => key === highlight.key);
|
|
4494
|
+
if (highlight.list !== list) {
|
|
4495
|
+
return 0;
|
|
4496
|
+
} else if (pinnedIndex >= 0) {
|
|
4497
|
+
return pinnedIndex;
|
|
4498
|
+
} else {
|
|
4499
|
+
return highlight.index;
|
|
4500
|
+
}
|
|
4501
|
+
}
|
|
3996
4502
|
// Remembering which list the index belongs to puts the highlight back on the
|
|
3997
4503
|
// first item whenever a new list replaces it, without an effect to reset it.
|
|
3998
|
-
// A list that grows
|
|
3999
|
-
|
|
4504
|
+
// A list that grows, fills in, or reorders under the same `list` keeps its
|
|
4505
|
+
// highlight on the same item, found again by key.
|
|
4506
|
+
// Disabled, nothing is highlighted and the keys and pointer leave it alone.
|
|
4507
|
+
function useResultNavigation(items, list, enabled = true) {
|
|
4000
4508
|
const [highlight, setHighlight] = React__default.useState({
|
|
4001
4509
|
index: 0,
|
|
4002
4510
|
list
|
|
4003
4511
|
});
|
|
4004
|
-
const highlightedIndex = highlight
|
|
4005
|
-
const highlighted = items[highlightedIndex];
|
|
4512
|
+
const highlightedIndex = indexOf(highlight, items, list);
|
|
4513
|
+
const highlighted = enabled ? items[highlightedIndex] : undefined;
|
|
4006
4514
|
const {
|
|
4007
4515
|
copiedUrl,
|
|
4008
4516
|
copy
|
|
4009
4517
|
} = useCopyLink();
|
|
4010
|
-
const highlightIndex = React__default.useCallback(index =>
|
|
4011
|
-
|
|
4012
|
-
|
|
4013
|
-
|
|
4518
|
+
const highlightIndex = React__default.useCallback(index => {
|
|
4519
|
+
var _a;
|
|
4520
|
+
if (!enabled) return;
|
|
4521
|
+
const key = (_a = items[index]) === null || _a === void 0 ? void 0 : _a.key;
|
|
4522
|
+
setHighlight(current => current.list === list && current.index === index && current.key === key ? current : {
|
|
4523
|
+
index,
|
|
4524
|
+
key,
|
|
4525
|
+
list
|
|
4526
|
+
});
|
|
4527
|
+
}, [enabled, items, list]);
|
|
4014
4528
|
const handleKeyDown = event => {
|
|
4529
|
+
if (!enabled) return;
|
|
4015
4530
|
const step = verticalStep(event.key);
|
|
4016
4531
|
if (step && items.length > 0) {
|
|
4017
4532
|
event.preventDefault();
|
|
@@ -4035,41 +4550,89 @@ function useResultNavigation(items, list) {
|
|
|
4035
4550
|
};
|
|
4036
4551
|
}
|
|
4037
4552
|
|
|
4038
|
-
|
|
4553
|
+
var styles$k = {"modal":"modal-NR3TO","visuallyHidden":"visuallyHidden-C28ju","panel":"panel-HlF7S"};
|
|
4554
|
+
|
|
4555
|
+
const FALLBACK_SLUGS = ["people", "services"];
|
|
4556
|
+
function defaultProduct(products, appName) {
|
|
4557
|
+
var _a;
|
|
4558
|
+
const current = products.find(product => product.appName === appName);
|
|
4559
|
+
const fallback = FALLBACK_SLUGS.map(slug => products.find(product => product.slug === slug)).find(Boolean);
|
|
4560
|
+
return (_a = current !== null && current !== void 0 ? current : fallback) !== null && _a !== void 0 ? _a : products[0];
|
|
4561
|
+
}
|
|
4562
|
+
|
|
4563
|
+
function groupSections(groups = [], timeZone) {
|
|
4039
4564
|
return groups.map(({
|
|
4040
4565
|
results,
|
|
4041
4566
|
type
|
|
4042
4567
|
}) => ({
|
|
4043
4568
|
heading: type,
|
|
4044
|
-
items: results.map(resultItem),
|
|
4569
|
+
items: results.map(result => resultItem(result, timeZone)),
|
|
4045
4570
|
key: type
|
|
4046
4571
|
}));
|
|
4047
4572
|
}
|
|
4048
4573
|
function resultItem({
|
|
4049
4574
|
attributes,
|
|
4050
4575
|
id
|
|
4051
|
-
}) {
|
|
4576
|
+
}, timeZone) {
|
|
4052
4577
|
return {
|
|
4578
|
+
category: attributes.category,
|
|
4579
|
+
imageUrl: attributes.image_url,
|
|
4053
4580
|
key: id,
|
|
4054
|
-
|
|
4581
|
+
product: attributes.product,
|
|
4582
|
+
subtitle: summarize(attributes, timeZone),
|
|
4055
4583
|
title: attributes.title,
|
|
4056
4584
|
url: attributes.url
|
|
4057
4585
|
};
|
|
4058
4586
|
}
|
|
4059
|
-
function visitItem(visit) {
|
|
4587
|
+
function visitItem(visit, timeZone) {
|
|
4060
4588
|
return {
|
|
4061
4589
|
key: entryKey(visit.entry),
|
|
4062
|
-
...describeVisit(visit)
|
|
4590
|
+
...describeVisit(visit, timeZone)
|
|
4063
4591
|
};
|
|
4064
4592
|
}
|
|
4065
|
-
|
|
4066
|
-
|
|
4593
|
+
const joinParts = (...parts) => parts.filter(Boolean).join(" · ");
|
|
4594
|
+
// Matches home-mobile's search subtitles, so a result reads the same in both.
|
|
4595
|
+
function summarize({
|
|
4596
|
+
category,
|
|
4597
|
+
metadata
|
|
4598
|
+
}, timeZone) {
|
|
4599
|
+
const text = key => {
|
|
4600
|
+
const value = metadata === null || metadata === void 0 ? void 0 : metadata[key];
|
|
4601
|
+
return typeof value === "string" ? value : "";
|
|
4602
|
+
};
|
|
4603
|
+
if (category === "profile") {
|
|
4604
|
+
return joinParts(text("phone"), text("email"));
|
|
4605
|
+
} else if (category === "event") {
|
|
4606
|
+
return eventTime(text("starts_at"), text("ends_at"), {
|
|
4607
|
+
recurring: (metadata === null || metadata === void 0 ? void 0 : metadata.recurring) === true,
|
|
4608
|
+
timeZone
|
|
4609
|
+
});
|
|
4610
|
+
} else {
|
|
4611
|
+
return text("details");
|
|
4612
|
+
}
|
|
4613
|
+
}
|
|
4614
|
+
// "Oct 25, 9–10:30am", in the organization's time zone like the rest
|
|
4615
|
+
// of Planning Center.
|
|
4616
|
+
function eventTime(startsAt, endsAt, {
|
|
4617
|
+
recurring,
|
|
4618
|
+
timeZone
|
|
4619
|
+
}) {
|
|
4620
|
+
if (startsAt === "") {
|
|
4621
|
+
return "";
|
|
4622
|
+
} else {
|
|
4623
|
+
const time = datetimeFmt.datetime(startsAt, endsAt || null, {
|
|
4624
|
+
style: "abbreviated",
|
|
4625
|
+
...(timeZone && {
|
|
4626
|
+
timeZone
|
|
4627
|
+
})
|
|
4628
|
+
});
|
|
4629
|
+
return recurring ? joinParts(time, "Repeating") : time;
|
|
4630
|
+
}
|
|
4067
4631
|
}
|
|
4068
4632
|
// Unlike search results, recents come from every product, so each one names
|
|
4069
|
-
// its product
|
|
4070
|
-
function describeVisit(visit) {
|
|
4633
|
+
// its type. The row's product icon says which product it came from.
|
|
4634
|
+
function describeVisit(visit, timeZone) {
|
|
4071
4635
|
var _a, _b;
|
|
4072
|
-
const subtitle = (...parts) => parts.filter(Boolean).join(" · ");
|
|
4073
4636
|
if (visit.status === "page") {
|
|
4074
4637
|
const {
|
|
4075
4638
|
app,
|
|
@@ -4077,65 +4640,313 @@ function describeVisit(visit) {
|
|
|
4077
4640
|
title
|
|
4078
4641
|
} = visit.entry;
|
|
4079
4642
|
return {
|
|
4080
|
-
|
|
4643
|
+
category: "generic",
|
|
4644
|
+
imageUrl: null,
|
|
4645
|
+
product: app,
|
|
4646
|
+
subtitle: joinParts(capitalize((_a = metadata === null || metadata === void 0 ? void 0 : metadata.type) !== null && _a !== void 0 ? _a : ""), (_b = metadata === null || metadata === void 0 ? void 0 : metadata.details) !== null && _b !== void 0 ? _b : ""),
|
|
4081
4647
|
title,
|
|
4082
4648
|
url: visit.url
|
|
4083
4649
|
};
|
|
4084
4650
|
} else {
|
|
4085
4651
|
const {
|
|
4086
|
-
|
|
4652
|
+
attributes
|
|
4653
|
+
} = visit.result;
|
|
4654
|
+
const {
|
|
4655
|
+
category,
|
|
4656
|
+
image_url,
|
|
4087
4657
|
product,
|
|
4088
4658
|
title,
|
|
4089
4659
|
type
|
|
4090
|
-
} =
|
|
4660
|
+
} = attributes;
|
|
4661
|
+
// Profiles and events say what they are with a phone number or a date.
|
|
4662
|
+
const kind = category === "generic" ? capitalize(pluralize.singular(type)) : "";
|
|
4091
4663
|
return {
|
|
4092
|
-
|
|
4664
|
+
category,
|
|
4665
|
+
imageUrl: image_url,
|
|
4666
|
+
product,
|
|
4667
|
+
subtitle: joinParts(kind, summarize(attributes, timeZone)),
|
|
4093
4668
|
title,
|
|
4094
4669
|
url: visit.url
|
|
4095
4670
|
};
|
|
4096
4671
|
}
|
|
4097
4672
|
}
|
|
4098
|
-
// check-ins → Check-Ins
|
|
4099
|
-
function productName(slug) {
|
|
4100
|
-
return slug.split("-").map(capitalize).join("-");
|
|
4101
|
-
}
|
|
4102
4673
|
function capitalize(word) {
|
|
4103
4674
|
return word.charAt(0).toUpperCase() + word.slice(1);
|
|
4104
4675
|
}
|
|
4105
4676
|
|
|
4106
|
-
|
|
4107
|
-
|
|
4108
|
-
|
|
4109
|
-
|
|
4110
|
-
|
|
4111
|
-
|
|
4112
|
-
}
|
|
4113
|
-
|
|
4114
|
-
|
|
4115
|
-
|
|
4116
|
-
|
|
4117
|
-
|
|
4118
|
-
|
|
4677
|
+
var styles$j = {"container":"container-YDdM1","hint":"hint-017Rd","keycap":"keycap-ENJM2","labels":"labels-GHPqL","copied":"copied-DUFa1"};
|
|
4678
|
+
|
|
4679
|
+
const SYMBOLS = {
|
|
4680
|
+
command: {
|
|
4681
|
+
label: "⌘",
|
|
4682
|
+
paths: ["M7 9a2 2 0 1 1 2 -2v10a2 2 0 1 1 -2 -2h10a2 2 0 1 1 -2 2v-10a2 2 0 1 1 2 2h-10"]
|
|
4683
|
+
},
|
|
4684
|
+
down: {
|
|
4685
|
+
label: "↓",
|
|
4686
|
+
paths: ["M12 6l0 12", "M16 14l-4 4", "M8 14l4 4"]
|
|
4687
|
+
},
|
|
4688
|
+
return: {
|
|
4689
|
+
label: "↵",
|
|
4690
|
+
paths: ["M18 6v6a3 3 0 0 1 -3 3h-10l4 -4m0 8l-4 -4"]
|
|
4691
|
+
},
|
|
4692
|
+
up: {
|
|
4693
|
+
label: "↑",
|
|
4694
|
+
paths: ["M12 6l0 12", "M16 10l-4 -4", "M8 10l4 -4"]
|
|
4119
4695
|
}
|
|
4696
|
+
};
|
|
4697
|
+
function Keycap(props) {
|
|
4698
|
+
return /*#__PURE__*/React__default.createElement("kbd", {
|
|
4699
|
+
className: styles$j.keycap
|
|
4700
|
+
}, "symbol" in props ? (/*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement("svg", {
|
|
4701
|
+
"aria-hidden": true,
|
|
4702
|
+
fill: "none",
|
|
4703
|
+
stroke: "currentColor",
|
|
4704
|
+
strokeLinecap: "round",
|
|
4705
|
+
strokeLinejoin: "round",
|
|
4706
|
+
viewBox: "0 0 24 24"
|
|
4707
|
+
}, SYMBOLS[props.symbol].paths.map(d => (/*#__PURE__*/React__default.createElement("path", {
|
|
4708
|
+
d: d,
|
|
4709
|
+
key: d
|
|
4710
|
+
})))), /*#__PURE__*/React__default.createElement("span", {
|
|
4711
|
+
className: styles$k.visuallyHidden
|
|
4712
|
+
}, SYMBOLS[props.symbol].label))) : props.label);
|
|
4713
|
+
}
|
|
4714
|
+
function CommandKey() {
|
|
4715
|
+
return isMac() ? /*#__PURE__*/React__default.createElement(Keycap, {
|
|
4716
|
+
symbol: "command"
|
|
4717
|
+
}) : /*#__PURE__*/React__default.createElement(Keycap, {
|
|
4718
|
+
label: "Ctrl"
|
|
4719
|
+
});
|
|
4120
4720
|
}
|
|
4121
|
-
function
|
|
4122
|
-
|
|
4123
|
-
|
|
4124
|
-
|
|
4125
|
-
|
|
4721
|
+
function EnterKey() {
|
|
4722
|
+
return isMac() ? /*#__PURE__*/React__default.createElement(Keycap, {
|
|
4723
|
+
symbol: "return"
|
|
4724
|
+
}) : /*#__PURE__*/React__default.createElement(Keycap, {
|
|
4725
|
+
label: "Enter"
|
|
4726
|
+
});
|
|
4126
4727
|
}
|
|
4127
|
-
|
|
4728
|
+
const {
|
|
4729
|
+
copyLink,
|
|
4730
|
+
openInNewTab,
|
|
4731
|
+
openSearch,
|
|
4732
|
+
select
|
|
4733
|
+
} = KEYBOARD_SHORTCUTS;
|
|
4128
4734
|
function KeyboardHints({
|
|
4129
4735
|
copied
|
|
4130
4736
|
}) {
|
|
4131
|
-
|
|
4132
|
-
|
|
4737
|
+
return /*#__PURE__*/React__default.createElement("ul", {
|
|
4738
|
+
"aria-label": "Keyboard shortcuts",
|
|
4739
|
+
className: styles$j.container,
|
|
4740
|
+
"data-platform": isMac() ? "mac" : "pc"
|
|
4741
|
+
}, /*#__PURE__*/React__default.createElement("li", {
|
|
4742
|
+
className: styles$j.hint
|
|
4743
|
+
}, /*#__PURE__*/React__default.createElement(Flex, {
|
|
4744
|
+
gap: 0.5
|
|
4745
|
+
}, select.modifierKey, /*#__PURE__*/React__default.createElement(Keycap, {
|
|
4746
|
+
symbol: "up"
|
|
4747
|
+
}), /*#__PURE__*/React__default.createElement(Keycap, {
|
|
4748
|
+
symbol: "down"
|
|
4749
|
+
})), select.label), /*#__PURE__*/React__default.createElement("li", {
|
|
4750
|
+
className: styles$j.hint
|
|
4751
|
+
}, /*#__PURE__*/React__default.createElement(Flex, {
|
|
4752
|
+
gap: 0.5
|
|
4753
|
+
}, /*#__PURE__*/React__default.createElement(CommandKey, null), /*#__PURE__*/React__default.createElement(EnterKey, null)), openInNewTab.label), /*#__PURE__*/React__default.createElement("li", {
|
|
4754
|
+
className: classnames(styles$j.hint, copied && styles$j.copied),
|
|
4755
|
+
style: {
|
|
4756
|
+
"--copied-active": `${COPIED_TIMING.active}ms`,
|
|
4757
|
+
"--copied-enter": `${COPIED_TIMING.enter}ms`,
|
|
4758
|
+
"--copied-exit": `${COPIED_TIMING.exit}ms`
|
|
4759
|
+
}
|
|
4760
|
+
}, /*#__PURE__*/React__default.createElement(Flex, {
|
|
4761
|
+
gap: 0.5
|
|
4762
|
+
}, /*#__PURE__*/React__default.createElement(CommandKey, null), /*#__PURE__*/React__default.createElement(Keycap, {
|
|
4763
|
+
label: copyLink.key.toUpperCase()
|
|
4764
|
+
})), /*#__PURE__*/React__default.createElement("span", {
|
|
4765
|
+
className: styles$j.labels
|
|
4766
|
+
}, /*#__PURE__*/React__default.createElement("span", {
|
|
4767
|
+
"aria-hidden": copied
|
|
4768
|
+
}, copyLink.label), /*#__PURE__*/React__default.createElement("span", {
|
|
4133
4769
|
role: "status"
|
|
4134
|
-
}, copied
|
|
4770
|
+
}, copied && "Copied!"))), /*#__PURE__*/React__default.createElement("li", {
|
|
4771
|
+
className: styles$j.hint
|
|
4772
|
+
}, /*#__PURE__*/React__default.createElement(Flex, {
|
|
4773
|
+
gap: 0.5
|
|
4774
|
+
}, /*#__PURE__*/React__default.createElement(CommandKey, null), /*#__PURE__*/React__default.createElement(Keycap, {
|
|
4775
|
+
label: openSearch.key.toUpperCase()
|
|
4776
|
+
})), openSearch.label));
|
|
4777
|
+
}
|
|
4778
|
+
|
|
4779
|
+
var styles$i = {"icon":"icon-XKLvN","squircle":"squircle-JCHr6"};
|
|
4780
|
+
|
|
4781
|
+
const PRODUCTS = {
|
|
4782
|
+
accounts: {
|
|
4783
|
+
gradient: "--t-fill-color-product-accounts-gradient-brand",
|
|
4784
|
+
path: logomarks.accounts
|
|
4785
|
+
},
|
|
4786
|
+
api: {
|
|
4787
|
+
gradient: "--t-fill-color-product-api-gradient-brand",
|
|
4788
|
+
path: logomarks.api
|
|
4789
|
+
},
|
|
4790
|
+
calendar: {
|
|
4791
|
+
gradient: "--t-fill-color-product-calendar-gradient-brand",
|
|
4792
|
+
path: logomarks.calendar
|
|
4793
|
+
},
|
|
4794
|
+
"check-ins": {
|
|
4795
|
+
gradient: "--t-fill-color-product-checkins-gradient-brand",
|
|
4796
|
+
path: logomarks.checkIns
|
|
4797
|
+
},
|
|
4798
|
+
"church-center": {
|
|
4799
|
+
gradient: "--t-fill-color-product-cc-gradient-brand",
|
|
4800
|
+
path: logomarks.churchCenter
|
|
4801
|
+
},
|
|
4802
|
+
giving: {
|
|
4803
|
+
gradient: "--t-fill-color-product-giving-gradient-brand",
|
|
4804
|
+
path: logomarks.giving
|
|
4805
|
+
},
|
|
4806
|
+
groups: {
|
|
4807
|
+
gradient: "--t-fill-color-product-groups-gradient-brand",
|
|
4808
|
+
path: logomarks.groups
|
|
4809
|
+
},
|
|
4810
|
+
home: {
|
|
4811
|
+
gradient: "--t-fill-color-product-home-gradient-brand",
|
|
4812
|
+
path: logomarks.home
|
|
4813
|
+
},
|
|
4814
|
+
"music-stand": {
|
|
4815
|
+
gradient: "--t-fill-color-product-musicstand-gradient-brand",
|
|
4816
|
+
path: logomarks.musicStand
|
|
4817
|
+
},
|
|
4818
|
+
people: {
|
|
4819
|
+
gradient: "--t-fill-color-product-people-gradient-brand",
|
|
4820
|
+
path: logomarks.people
|
|
4821
|
+
},
|
|
4822
|
+
publishing: {
|
|
4823
|
+
gradient: "--t-fill-color-product-publishing-gradient-brand",
|
|
4824
|
+
path: logomarks.publishing
|
|
4825
|
+
},
|
|
4826
|
+
registrations: {
|
|
4827
|
+
gradient: "--t-fill-color-product-registrations-gradient-brand",
|
|
4828
|
+
path: logomarks.registrations
|
|
4829
|
+
},
|
|
4830
|
+
services: {
|
|
4831
|
+
gradient: "--t-fill-color-product-services-gradient-brand",
|
|
4832
|
+
path: logomarks.services
|
|
4833
|
+
}
|
|
4834
|
+
};
|
|
4835
|
+
const isProductIconSlug = slug => Object.prototype.hasOwnProperty.call(PRODUCTS, slug);
|
|
4836
|
+
const maskFor = path => `url("data:image/svg+xml,${encodeURIComponent(`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16"><path d="${path}"/></svg>`)}")`;
|
|
4837
|
+
function ProductIcon({
|
|
4838
|
+
size = 16,
|
|
4839
|
+
slug
|
|
4840
|
+
}) {
|
|
4841
|
+
const {
|
|
4842
|
+
gradient,
|
|
4843
|
+
path
|
|
4844
|
+
} = PRODUCTS[slug];
|
|
4845
|
+
const mask = maskFor(path);
|
|
4846
|
+
return /*#__PURE__*/React__default.createElement("span", {
|
|
4847
|
+
"aria-hidden": true,
|
|
4848
|
+
className: styles$i.icon,
|
|
4849
|
+
style: {
|
|
4850
|
+
height: size,
|
|
4851
|
+
width: size
|
|
4852
|
+
}
|
|
4853
|
+
}, /*#__PURE__*/React__default.createElement("span", {
|
|
4854
|
+
className: styles$i.squircle,
|
|
4855
|
+
style: {
|
|
4856
|
+
WebkitMaskImage: mask,
|
|
4857
|
+
background: `var(${gradient})`,
|
|
4858
|
+
maskImage: mask
|
|
4859
|
+
}
|
|
4860
|
+
}));
|
|
4861
|
+
}
|
|
4862
|
+
|
|
4863
|
+
var styles$h = {"picker":"picker-iuzzj","option":"option--7LXg"};
|
|
4864
|
+
|
|
4865
|
+
// Phones have no room for a tab per product, so they pick from a dropdown.
|
|
4866
|
+
// Complex mode renders each option's logomark, in the list and the trigger.
|
|
4867
|
+
function ProductSelect({
|
|
4868
|
+
children,
|
|
4869
|
+
onSelect,
|
|
4870
|
+
products,
|
|
4871
|
+
selected
|
|
4872
|
+
}) {
|
|
4873
|
+
const options = products.map(({
|
|
4874
|
+
appName,
|
|
4875
|
+
slug
|
|
4876
|
+
}) => ({
|
|
4877
|
+
label: (/*#__PURE__*/React__default.createElement("span", {
|
|
4878
|
+
className: styles$h.option
|
|
4879
|
+
}, /*#__PURE__*/React__default.createElement(ProductIcon, {
|
|
4880
|
+
slug: slug
|
|
4881
|
+
}), appName)),
|
|
4882
|
+
textValue: appName,
|
|
4883
|
+
value: slug
|
|
4884
|
+
}));
|
|
4885
|
+
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement("div", {
|
|
4886
|
+
className: styles$h.picker
|
|
4887
|
+
}, /*#__PURE__*/React__default.createElement(Select, {
|
|
4888
|
+
"aria-label": "Product",
|
|
4889
|
+
complex: true,
|
|
4890
|
+
onChange: event => onSelect(event.target.value),
|
|
4891
|
+
options: options,
|
|
4892
|
+
value: selected.slug
|
|
4893
|
+
})), /*#__PURE__*/React__default.createElement("div", {
|
|
4894
|
+
className: styles$k.panel
|
|
4895
|
+
}, children));
|
|
4896
|
+
}
|
|
4897
|
+
|
|
4898
|
+
// Browsers match :focus-visible on every focused text field, keyboard or not,
|
|
4899
|
+
// since typing follows either way. So this remembers what last moved focus,
|
|
4900
|
+
// shared by every field and listened for once, in the capture phase so it's
|
|
4901
|
+
// known before focus moves.
|
|
4902
|
+
let lastInteraction = "pointer";
|
|
4903
|
+
let listening = false;
|
|
4904
|
+
function listen() {
|
|
4905
|
+
if (listening) return;
|
|
4906
|
+
listening = true;
|
|
4907
|
+
document.addEventListener("keydown", event => {
|
|
4908
|
+
// Shortcuts like ⌘C don't move focus.
|
|
4909
|
+
if (!event.metaKey && !event.ctrlKey && !event.altKey) {
|
|
4910
|
+
lastInteraction = "keyboard";
|
|
4911
|
+
}
|
|
4912
|
+
}, true);
|
|
4913
|
+
document.addEventListener("pointerdown", () => {
|
|
4914
|
+
lastInteraction = "pointer";
|
|
4915
|
+
}, true);
|
|
4916
|
+
}
|
|
4917
|
+
/**
|
|
4918
|
+
* Whether a field was focused from the keyboard, as by Tab, rather than by a
|
|
4919
|
+
* click or tap. Spread `focusProps` onto the field, and style it by
|
|
4920
|
+
* `data-focus-visible`.
|
|
4921
|
+
*/
|
|
4922
|
+
function useKeyboardFocus({
|
|
4923
|
+
onBlur,
|
|
4924
|
+
onFocus
|
|
4925
|
+
} = {}) {
|
|
4926
|
+
const [focusVisible, setFocusVisible] = React__default.useState(false);
|
|
4927
|
+
React__default.useEffect(listen, []);
|
|
4928
|
+
return {
|
|
4929
|
+
focusProps: {
|
|
4930
|
+
"data-focus-visible": focusVisible || undefined,
|
|
4931
|
+
onBlur: event => {
|
|
4932
|
+
setFocusVisible(false);
|
|
4933
|
+
onBlur === null || onBlur === void 0 ? void 0 : onBlur(event);
|
|
4934
|
+
},
|
|
4935
|
+
onFocus: event => {
|
|
4936
|
+
const keyboard = lastInteraction === "keyboard";
|
|
4937
|
+
setFocusVisible(keyboard);
|
|
4938
|
+
onFocus === null || onFocus === void 0 ? void 0 : onFocus(event, keyboard);
|
|
4939
|
+
}
|
|
4940
|
+
},
|
|
4941
|
+
focusVisible
|
|
4942
|
+
};
|
|
4135
4943
|
}
|
|
4136
4944
|
|
|
4137
|
-
var styles$
|
|
4945
|
+
var styles$g = {"tablist":"tablist-7ASvc","tab":"tab-dz8ki"};
|
|
4138
4946
|
|
|
4947
|
+
// With this many tabs or more, only the selected tab shows its name, so they
|
|
4948
|
+
// all fit. Fewer always fit with their names.
|
|
4949
|
+
const ICON_ONLY_TAB_COUNT = 5;
|
|
4139
4950
|
function ProductTabs({
|
|
4140
4951
|
children,
|
|
4141
4952
|
onKeyDown,
|
|
@@ -4146,6 +4957,7 @@ function ProductTabs({
|
|
|
4146
4957
|
const id = useInstanceId("product-tabs");
|
|
4147
4958
|
const tabId = slug => `${id}-tab-${slug}`;
|
|
4148
4959
|
const tabRefs = React__default.useRef(new Map());
|
|
4960
|
+
const showAllNames = products.length < ICON_ONLY_TAB_COUNT;
|
|
4149
4961
|
const handleKeyDown = event => {
|
|
4150
4962
|
var _a;
|
|
4151
4963
|
const offset = horizontalStep(event.key);
|
|
@@ -4160,13 +4972,13 @@ function ProductTabs({
|
|
|
4160
4972
|
}
|
|
4161
4973
|
};
|
|
4162
4974
|
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement("div", {
|
|
4163
|
-
"aria-label": "
|
|
4975
|
+
"aria-label": "Search in",
|
|
4976
|
+
className: styles$g.tablist,
|
|
4164
4977
|
onKeyDown: handleKeyDown,
|
|
4165
4978
|
role: "tablist"
|
|
4166
|
-
}, products.map(product => (/*#__PURE__*/React__default.createElement(
|
|
4979
|
+
}, products.map(product => (/*#__PURE__*/React__default.createElement(Tab, {
|
|
4167
4980
|
"aria-controls": `${id}-panel`,
|
|
4168
4981
|
"aria-selected": product === selected,
|
|
4169
|
-
className: styles$d.tab,
|
|
4170
4982
|
id: tabId(product.slug),
|
|
4171
4983
|
key: product.slug,
|
|
4172
4984
|
onClick: () => onSelect(product.slug),
|
|
@@ -4177,15 +4989,392 @@ function ProductTabs({
|
|
|
4177
4989
|
tabRefs.current.delete(product.slug);
|
|
4178
4990
|
}
|
|
4179
4991
|
},
|
|
4180
|
-
|
|
4181
|
-
|
|
4182
|
-
|
|
4183
|
-
}, product.appName
|
|
4992
|
+
tabIndex: product === selected ? 0 : -1
|
|
4993
|
+
}, /*#__PURE__*/React__default.createElement(ProductIcon, {
|
|
4994
|
+
slug: product.slug
|
|
4995
|
+
}), showAllNames || product === selected ? product.appName : (/*#__PURE__*/React__default.createElement("span", {
|
|
4996
|
+
className: styles$k.visuallyHidden
|
|
4997
|
+
}, product.appName)))))), /*#__PURE__*/React__default.createElement("div", {
|
|
4184
4998
|
"aria-labelledby": tabId(selected.slug),
|
|
4999
|
+
className: styles$k.panel,
|
|
4185
5000
|
id: `${id}-panel`,
|
|
4186
5001
|
role: "tabpanel"
|
|
4187
5002
|
}, children));
|
|
4188
5003
|
}
|
|
5004
|
+
// The modal's focus scope moves focus here by script when Tab is pressed, and
|
|
5005
|
+
// Safari doesn't match :focus-visible on focus moved by script. So the tab
|
|
5006
|
+
// remembers whether the keyboard brought focus, and the ring keys off that.
|
|
5007
|
+
const Tab = /*#__PURE__*/React__default.forwardRef(function Tab(props, ref) {
|
|
5008
|
+
const {
|
|
5009
|
+
focusProps
|
|
5010
|
+
} = useKeyboardFocus();
|
|
5011
|
+
return /*#__PURE__*/React__default.createElement("button", {
|
|
5012
|
+
className: styles$g.tab,
|
|
5013
|
+
ref: ref,
|
|
5014
|
+
role: "tab",
|
|
5015
|
+
type: "button",
|
|
5016
|
+
...props,
|
|
5017
|
+
...focusProps
|
|
5018
|
+
});
|
|
5019
|
+
});
|
|
5020
|
+
|
|
5021
|
+
function BlankStateRecentlyVisited(props) {
|
|
5022
|
+
const id = useInstanceId("blank-state-initial");
|
|
5023
|
+
return /*#__PURE__*/React__default.createElement("svg", {
|
|
5024
|
+
viewBox: "0 0 197 174",
|
|
5025
|
+
fill: "none",
|
|
5026
|
+
"aria-hidden": "true",
|
|
5027
|
+
focusable: "false",
|
|
5028
|
+
...props
|
|
5029
|
+
}, /*#__PURE__*/React__default.createElement("path", {
|
|
5030
|
+
d: "M139.863 32.119c10.938 10.028 21.777 20.154 32.912 30.084 8.376 7.373 21.975 15.828 23.157 28.02.592 6.095-2.167 11.993-5.321 17.204-24.635 40.8-81.098 67.148-127.412 48.862-30.646-12.093-76.172-47.387-59.716-85.041 15.865-36.377 64.84-55.056 83.957-57.71 21.876-4.621 34.883 2.457 52.423 18.58Z",
|
|
5031
|
+
fill: "currentColor"
|
|
5032
|
+
}), /*#__PURE__*/React__default.createElement("g", {
|
|
5033
|
+
clipPath: `url(#${id}-a)`
|
|
5034
|
+
}, /*#__PURE__*/React__default.createElement("path", {
|
|
5035
|
+
d: "M115.885 109.31c-.478-.686-.01-1.845 1.046-2.589s2.3-.791 2.778-.105c.478.686.009 1.845-1.047 2.589-1.056.744-2.299.791-2.777.105Z",
|
|
5036
|
+
fill: "#333"
|
|
5037
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5038
|
+
d: "M123.403 113.599c-3.456 0-6.259-2.817-6.259-6.293 0-3.475 2.803-6.293 6.259-6.293 3.457 0 6.259 2.818 6.259 6.293 0 3.476-2.802 6.293-6.259 6.293Z",
|
|
5039
|
+
fill: "#333"
|
|
5040
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5041
|
+
d: "M118.853 100.968a2.85 2.85 0 0 0 2.832-2.484 2.89 2.89 0 0 0-.071-1.115c-2.638-9.955-9.668-9.687-9.964-9.665l.311 5.716h-.104c.119 0 2.853.134 4.254 5.421a2.874 2.874 0 0 0 1.013 1.53 2.846 2.846 0 0 0 1.729.597Z",
|
|
5042
|
+
fill: "#4D4D4D"
|
|
5043
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5044
|
+
d: "M114.96 100.503c-.462-5.894 2.796-10.96 7.279-11.315 4.482-.356 8.491 4.134 8.953 10.027.462 5.894-2.796 10.96-7.279 11.315-4.482.356-8.491-4.134-8.953-10.027Z",
|
|
5045
|
+
fill: "#F2F2F2"
|
|
5046
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5047
|
+
d: "M125.964 107.738c-4.48.354-8.489-4.135-8.953-10.026a12.893 12.893 0 0 1 1.223-6.707c-2.249 2.046-3.591 5.59-3.283 9.505.463 5.895 4.469 10.384 8.953 10.027 2.594-.205 4.765-1.986 6.055-4.591a6.682 6.682 0 0 1-3.995 1.792Z",
|
|
5048
|
+
fill: "#E6E6E6"
|
|
5049
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5050
|
+
d: "M115.885 109.31c-.478-.686-.01-1.845 1.046-2.589s2.3-.791 2.778-.105c.478.686.009 1.845-1.047 2.589-1.056.744-2.299.791-2.777.105Z",
|
|
5051
|
+
fill: "#333"
|
|
5052
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5053
|
+
d: "M123.403 113.599c-3.456 0-6.259-2.817-6.259-6.293 0-3.475 2.803-6.293 6.259-6.293 3.457 0 6.259 2.818 6.259 6.293 0 3.476-2.802 6.293-6.259 6.293Z",
|
|
5054
|
+
fill: "#333"
|
|
5055
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5056
|
+
d: "M118.853 100.968a2.85 2.85 0 0 0 2.832-2.484 2.89 2.89 0 0 0-.071-1.115c-2.638-9.955-9.668-9.687-9.964-9.665l.311 5.716h-.104c.119 0 2.853.134 4.254 5.421a2.874 2.874 0 0 0 1.013 1.53 2.846 2.846 0 0 0 1.729.597Z",
|
|
5057
|
+
fill: "#4D4D4D"
|
|
5058
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5059
|
+
d: "M114.96 100.503c-.462-5.894 2.796-10.96 7.279-11.315 4.482-.356 8.491 4.134 8.953 10.027.462 5.894-2.796 10.96-7.279 11.315-4.482.356-8.491-4.134-8.953-10.027Z",
|
|
5060
|
+
fill: "#F2F2F2"
|
|
5061
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5062
|
+
d: "M125.964 107.738c-4.48.354-8.489-4.135-8.953-10.026a12.893 12.893 0 0 1 1.223-6.707c-2.249 2.046-3.591 5.59-3.283 9.505.463 5.895 4.469 10.384 8.953 10.027 2.594-.205 4.765-1.986 6.055-4.591a6.682 6.682 0 0 1-3.995 1.792Z",
|
|
5063
|
+
fill: "#E6E6E6"
|
|
5064
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5065
|
+
d: "M89.317 121.331a2.836 2.836 0 0 1-1.92-.752 2.869 2.869 0 0 1-.911-1.857c-.534-5.726 3.527-13.808 3.99-14.713a2.849 2.849 0 0 1 1.666-1.413 2.835 2.835 0 0 1 2.172.185 2.86 2.86 0 0 1 1.405 1.675 2.876 2.876 0 0 1-.184 2.183c-1.46 2.843-3.669 8.492-3.383 11.551a2.868 2.868 0 0 1-1.504 2.797 2.84 2.84 0 0 1-1.064.318 1.378 1.378 0 0 1-.267.026Z",
|
|
5066
|
+
fill: "#4D4D4D"
|
|
5067
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5068
|
+
d: "M92.155 112.314c3.308 0 5.989-2.696 5.989-6.021 0-3.326-2.681-6.021-5.989-6.021-3.307 0-5.988 2.695-5.988 6.021 0 3.325 2.681 6.021 5.988 6.021Z",
|
|
5069
|
+
fill: "gray"
|
|
5070
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5071
|
+
d: "M80.597 128.771h11.769v3.726a1.118 1.118 0 0 1-1.112 1.118H78.57a1.118 1.118 0 0 1-1.112-1.118v-.566c0-.841.332-1.648.924-2.242a3.144 3.144 0 0 1 2.23-.929l-.015.011Z",
|
|
5072
|
+
fill: "#333"
|
|
5073
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5074
|
+
d: "M89.572 132.084s8.075.119 6.3-8.268c-1.775-8.387-12.188-15.351-15.234-6.066-3.046 9.285-1.386 15.232 8.934 14.334Z",
|
|
5075
|
+
fill: "#F2F2F2"
|
|
5076
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5077
|
+
d: "M106.67 121.334h-.27a2.84 2.84 0 0 1-1.925-1.025 2.872 2.872 0 0 1-.639-2.093c.285-3.059-1.92-8.708-3.38-11.551a2.873 2.873 0 0 1 1.296-3.721 2.832 2.832 0 0 1 2.102-.199 2.848 2.848 0 0 1 1.66 1.312c.463.906 4.521 8.991 3.988 14.714a2.874 2.874 0 0 1-.926 1.828 2.832 2.832 0 0 1-1.906.735Z",
|
|
5078
|
+
fill: "#4D4D4D"
|
|
5079
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5080
|
+
d: "M103.835 112.314c3.307 0 5.988-2.696 5.988-6.021 0-3.326-2.681-6.021-5.988-6.021-3.307 0-5.988 2.695-5.988 6.021 0 3.325 2.681 6.021 5.988 6.021Z",
|
|
5081
|
+
fill: "gray"
|
|
5082
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5083
|
+
d: "m117.408 133.652-12.674-.002c-.295 0-.577-.118-.786-.328a1.121 1.121 0 0 1-.325-.79v-3.726l11.773.002c.837 0 1.639.334 2.23.929s.923 1.401.923 2.242v.567a1.116 1.116 0 0 1-1.141 1.106Z",
|
|
5084
|
+
fill: "#333"
|
|
5085
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5086
|
+
d: "M106.414 132.084s-8.075.119-6.318-8.268c1.756-8.387 12.195-15.343 15.237-6.062 3.043 9.281 1.405 15.235-8.919 14.33Z",
|
|
5087
|
+
fill: "#F2F2F2"
|
|
5088
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5089
|
+
d: "M109.107 94.58a2.305 2.305 0 0 0 2.191 2.412 2.302 2.302 0 0 0 2.399-2.202l.333-7.33a2.306 2.306 0 0 0-2.191-2.412 2.303 2.303 0 0 0-2.4 2.203l-.332 7.328Z",
|
|
5090
|
+
fill: "gray"
|
|
5091
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5092
|
+
d: "M80.968 109.31c.478-.686.01-1.845-1.047-2.589-1.056-.744-2.3-.791-2.777-.105-.478.686-.01 1.845 1.046 2.589s2.3.791 2.778.105Z",
|
|
5093
|
+
fill: "#333"
|
|
5094
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5095
|
+
d: "M73.448 113.599c3.457 0 6.26-2.817 6.26-6.293 0-3.475-2.803-6.293-6.26-6.293-3.456 0-6.258 2.818-6.258 6.293 0 3.476 2.802 6.293 6.258 6.293Z",
|
|
5096
|
+
fill: "#333"
|
|
5097
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5098
|
+
d: "M78 100.968a2.853 2.853 0 0 1-2.832-2.484 2.876 2.876 0 0 1 .07-1.115c2.639-9.955 9.669-9.687 9.965-9.665l-.311 5.716h.104c-.12 0-2.854.134-4.255 5.421a2.87 2.87 0 0 1-1.013 1.53 2.845 2.845 0 0 1-1.729.597Z",
|
|
5099
|
+
fill: "#4D4D4D"
|
|
5100
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5101
|
+
d: "M87.37 88.17a2.305 2.305 0 0 0-2.19-2.413 2.302 2.302 0 0 0-2.4 2.202l-.332 7.329a2.305 2.305 0 0 0 2.19 2.413 2.302 2.302 0 0 0 2.4-2.203l.332-7.328Z",
|
|
5102
|
+
fill: "gray"
|
|
5103
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5104
|
+
d: "M81.893 100.503c.462-5.894-2.797-10.96-7.28-11.315-4.482-.356-8.49 4.134-8.953 10.027-.462 5.894 2.797 10.96 7.28 11.315 4.482.356 8.49-4.134 8.953-10.027Z",
|
|
5105
|
+
fill: "#F2F2F2"
|
|
5106
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5107
|
+
d: "M70.888 107.738c4.48.354 8.49-4.135 8.953-10.026a12.89 12.89 0 0 0-1.223-6.707c2.25 2.046 3.591 5.59 3.284 9.505-.464 5.895-4.47 10.384-8.953 10.027-2.594-.205-4.766-1.986-6.055-4.591a6.682 6.682 0 0 0 3.994 1.792Z",
|
|
5108
|
+
fill: "#E6E6E6"
|
|
5109
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5110
|
+
d: "M112.717 94.105c-.511-9.095-7.459-11.703-15.82-11.226-8.36.477-14.97 3.856-14.451 12.951.518 9.095 7.707 16.081 16.067 15.605 8.36-.477 14.719-8.231 14.204-17.33Z",
|
|
5111
|
+
fill: "#F2F2F2"
|
|
5112
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5113
|
+
d: "M112.565 92.656c-1.056 7.496-6.799 13.413-14.059 13.812-7.852.451-14.67-5.686-15.897-13.965a14.571 14.571 0 0 0-.17 3.327c.51 9.095 7.704 16.081 16.067 15.605 8.364-.477 14.723-8.235 14.211-17.33a16.83 16.83 0 0 0-.152-1.45Z",
|
|
5114
|
+
fill: "#E6E6E6"
|
|
5115
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5116
|
+
d: "M103.546 90.353H91.61a.62.62 0 0 0-.619.623v1.762a.62.62 0 0 0 .62.622h11.935a.62.62 0 0 0 .619-.622v-1.762a.62.62 0 0 0-.619-.623Zm0 5.187H91.61a.62.62 0 0 0-.619.622v1.762a.62.62 0 0 0 .62.623h11.935a.62.62 0 0 0 .619-.623v-1.762a.62.62 0 0 0-.619-.622Zm-.004 5.19H91.606a.62.62 0 0 0-.619.622v1.763a.62.62 0 0 0 .62.622h11.935a.62.62 0 0 0 .619-.622v-1.763a.62.62 0 0 0-.619-.622Z",
|
|
5117
|
+
fill: "#3690EA"
|
|
5118
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5119
|
+
d: "M89.317 121.331a2.836 2.836 0 0 1-1.92-.752 2.869 2.869 0 0 1-.911-1.857c-.534-5.726 3.527-13.808 3.99-14.713a2.849 2.849 0 0 1 1.666-1.413 2.835 2.835 0 0 1 2.172.185 2.86 2.86 0 0 1 1.405 1.675 2.876 2.876 0 0 1-.184 2.183c-1.46 2.843-3.669 8.492-3.383 11.551a2.868 2.868 0 0 1-1.504 2.797 2.84 2.84 0 0 1-1.064.318 1.378 1.378 0 0 1-.267.026Z",
|
|
5120
|
+
fill: "#4D4D4D"
|
|
5121
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5122
|
+
d: "M92.155 112.314c3.308 0 5.989-2.696 5.989-6.021 0-3.326-2.681-6.021-5.989-6.021-3.307 0-5.988 2.695-5.988 6.021 0 3.325 2.681 6.021 5.988 6.021Z",
|
|
5123
|
+
fill: "gray"
|
|
5124
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5125
|
+
d: "M80.597 128.771h11.769v3.726a1.118 1.118 0 0 1-1.112 1.118H78.57a1.118 1.118 0 0 1-1.112-1.118v-.566c0-.841.332-1.648.924-2.242a3.144 3.144 0 0 1 2.23-.929l-.015.011Z",
|
|
5126
|
+
fill: "#333"
|
|
5127
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5128
|
+
d: "M89.572 132.084s8.075.119 6.3-8.268c-1.775-8.387-12.188-15.351-15.234-6.066-3.046 9.285-1.386 15.232 8.934 14.334Z",
|
|
5129
|
+
fill: "#F2F2F2"
|
|
5130
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5131
|
+
d: "M106.67 121.334h-.27a2.84 2.84 0 0 1-1.925-1.025 2.872 2.872 0 0 1-.639-2.093c.285-3.059-1.92-8.708-3.38-11.551a2.873 2.873 0 0 1 1.296-3.721 2.832 2.832 0 0 1 2.102-.199 2.848 2.848 0 0 1 1.66 1.312c.463.906 4.521 8.991 3.988 14.714a2.874 2.874 0 0 1-.926 1.828 2.832 2.832 0 0 1-1.906.735Z",
|
|
5132
|
+
fill: "#4D4D4D"
|
|
5133
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5134
|
+
d: "M103.835 112.314c3.307 0 5.988-2.696 5.988-6.021 0-3.326-2.681-6.021-5.988-6.021-3.307 0-5.988 2.695-5.988 6.021 0 3.325 2.681 6.021 5.988 6.021Z",
|
|
5135
|
+
fill: "gray"
|
|
5136
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5137
|
+
d: "m117.408 133.652-12.674-.002c-.295 0-.577-.118-.786-.328a1.121 1.121 0 0 1-.325-.79v-3.726l11.773.002c.837 0 1.639.334 2.23.929s.923 1.401.923 2.242v.567a1.116 1.116 0 0 1-1.141 1.106Z",
|
|
5138
|
+
fill: "#333"
|
|
5139
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5140
|
+
d: "M106.414 132.084s-8.075.119-6.318-8.268c1.756-8.387 12.195-15.343 15.237-6.062 3.043 9.281 1.405 15.235-8.919 14.33Z",
|
|
5141
|
+
fill: "#F2F2F2"
|
|
5142
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5143
|
+
d: "M109.107 94.58a2.305 2.305 0 0 0 2.191 2.412 2.302 2.302 0 0 0 2.399-2.202l.333-7.33a2.306 2.306 0 0 0-2.191-2.412 2.303 2.303 0 0 0-2.4 2.203l-.332 7.328Z",
|
|
5144
|
+
fill: "gray"
|
|
5145
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5146
|
+
d: "M80.968 109.31c.478-.686.01-1.845-1.047-2.589-1.056-.744-2.3-.791-2.777-.105-.478.686-.01 1.845 1.046 2.589s2.3.791 2.778.105Z",
|
|
5147
|
+
fill: "#333"
|
|
5148
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5149
|
+
d: "M73.448 113.599c3.457 0 6.26-2.817 6.26-6.293 0-3.475-2.803-6.293-6.26-6.293-3.456 0-6.258 2.818-6.258 6.293 0 3.476 2.802 6.293 6.258 6.293Z",
|
|
5150
|
+
fill: "#333"
|
|
5151
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5152
|
+
d: "M78 100.968a2.853 2.853 0 0 1-2.832-2.484 2.876 2.876 0 0 1 .07-1.115c2.639-9.955 9.669-9.687 9.965-9.665l-.311 5.716h.104c-.12 0-2.854.134-4.255 5.421a2.87 2.87 0 0 1-1.013 1.53 2.845 2.845 0 0 1-1.729.597Z",
|
|
5153
|
+
fill: "#4D4D4D"
|
|
5154
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5155
|
+
d: "M87.37 88.17a2.305 2.305 0 0 0-2.19-2.413 2.302 2.302 0 0 0-2.4 2.202l-.332 7.329a2.305 2.305 0 0 0 2.19 2.413 2.302 2.302 0 0 0 2.4-2.203l.332-7.328Z",
|
|
5156
|
+
fill: "gray"
|
|
5157
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5158
|
+
d: "M81.893 100.503c.462-5.894-2.797-10.96-7.28-11.315-4.482-.356-8.49 4.134-8.953 10.027-.462 5.894 2.797 10.96 7.28 11.315 4.482.356 8.49-4.134 8.953-10.027Z",
|
|
5159
|
+
fill: "#F2F2F2"
|
|
5160
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5161
|
+
d: "M70.888 107.738c4.48.354 8.49-4.135 8.953-10.026a12.89 12.89 0 0 0-1.223-6.707c2.25 2.046 3.591 5.59 3.284 9.505-.464 5.895-4.47 10.384-8.953 10.027-2.594-.205-4.766-1.986-6.055-4.591a6.682 6.682 0 0 0 3.994 1.792Z",
|
|
5162
|
+
fill: "#E6E6E6"
|
|
5163
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5164
|
+
d: "M112.717 94.105c-.511-9.095-7.459-11.703-15.82-11.226-8.36.477-14.97 3.856-14.451 12.951.518 9.095 7.707 16.081 16.067 15.605 8.36-.477 14.719-8.231 14.204-17.33Z",
|
|
5165
|
+
fill: "#F2F2F2"
|
|
5166
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5167
|
+
d: "M112.565 92.656c-1.056 7.496-6.799 13.413-14.059 13.812-7.852.451-14.67-5.686-15.897-13.965a14.571 14.571 0 0 0-.17 3.327c.51 9.095 7.704 16.081 16.067 15.605 8.364-.477 14.723-8.235 14.211-17.33a16.83 16.83 0 0 0-.152-1.45Z",
|
|
5168
|
+
fill: "#E6E6E6"
|
|
5169
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5170
|
+
d: "M94.626 78.445c-.114-.488 6.548-.927 5.815.246v.775c0 .746.033 1.49.033 2.258s.037 1.595.044 2.392c.278.593-6.473.935-5.817-.115v-.67c-.015-1.63-.06-3.257-.075-4.886Z",
|
|
5171
|
+
fill: "#999"
|
|
5172
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5173
|
+
d: "M103.546 90.353H91.61a.62.62 0 0 0-.619.623v1.762a.62.62 0 0 0 .62.622h11.935a.62.62 0 0 0 .619-.622v-1.762a.62.62 0 0 0-.619-.623Zm0 5.187H91.61a.62.62 0 0 0-.619.622v1.762a.62.62 0 0 0 .62.623h11.935a.62.62 0 0 0 .619-.623v-1.762a.62.62 0 0 0-.619-.622Zm-.004 5.19H91.606a.62.62 0 0 0-.619.622v1.763a.62.62 0 0 0 .62.622h11.935a.62.62 0 0 0 .619-.622v-1.763a.62.62 0 0 0-.619-.622ZM55.773 64.004c4.349 0 7.874-5.285 7.874-11.804s-3.525-11.804-7.874-11.804-7.875 5.285-7.875 11.804c0 6.52 3.526 11.804 7.875 11.804Zm84.17.015c4.349 0 7.874-5.285 7.874-11.804 0-6.52-3.525-11.804-7.874-11.804s-7.875 5.285-7.875 11.804 3.526 11.804 7.875 11.804Z",
|
|
5174
|
+
fill: "#3690EA"
|
|
5175
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5176
|
+
d: "M97.962 29.036c7.273 0 13.17-2.224 13.17-4.967 0-2.743-5.897-4.966-13.17-4.966-7.274 0-13.17 2.223-13.17 4.966 0 2.743 5.896 4.967 13.17 4.967Z",
|
|
5177
|
+
fill: "#B3B3B3"
|
|
5178
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5179
|
+
d: "M97.962 16.55c4.545 0 8.23-3.705 8.23-8.275S102.507 0 97.962 0c-4.546 0-8.23 3.705-8.23 8.275s3.684 8.275 8.23 8.275Z",
|
|
5180
|
+
fill: "#3690EA"
|
|
5181
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5182
|
+
d: "M141.607 59.283V45.147a19.038 19.038 0 0 0-3.687-11.301 18.872 18.872 0 0 0-9.653-6.874c-8.838-2.69-19.203-4.24-30.29-4.244-11.088-.004-21.452 1.546-30.29 4.233a18.871 18.871 0 0 0-9.668 6.866 19.041 19.041 0 0 0-3.699 11.305v14.132a19.03 19.03 0 0 0 3.685 11.303 18.86 18.86 0 0 0 9.656 6.872c8.841 2.694 19.206 4.244 30.29 4.244 11.083 0 21.452-1.542 30.294-4.233a18.858 18.858 0 0 0 9.666-6.863 19.028 19.028 0 0 0 3.696-11.304Z",
|
|
5183
|
+
fill: "#F2F2F2"
|
|
5184
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5185
|
+
d: "M97.954 75.051c-10.068 0-19.88-1.371-28.381-3.957a12.353 12.353 0 0 1-6.262-4.485 12.463 12.463 0 0 1-2.41-7.34V45.131c.006-2.642.85-5.214 2.411-7.34a12.345 12.345 0 0 1 6.264-4.482c8.501-2.586 18.317-3.95 28.382-3.95 10.065 0 19.877 1.371 28.382 3.96a12.35 12.35 0 0 1 6.262 4.486 12.46 12.46 0 0 1 2.409 7.34V59.28a12.453 12.453 0 0 1-2.41 7.341 12.343 12.343 0 0 1-6.265 4.482c-8.486 2.585-18.317 3.949-28.382 3.949Z",
|
|
5186
|
+
fill: "#E6E6E6"
|
|
5187
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5188
|
+
d: "M100.863 15.992h-5.81v1.293h5.81v-1.293Z",
|
|
5189
|
+
fill: "#F2F2F2"
|
|
5190
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5191
|
+
d: "M76.472 66.05c4.327 0 7.834-6.2 7.834-13.846 0-7.647-3.507-13.846-7.834-13.846-4.326 0-7.833 6.2-7.833 13.846s3.507 13.845 7.833 13.845Z",
|
|
5192
|
+
fill: "#1A1A1A"
|
|
5193
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5194
|
+
d: "M77.844 52.766c1.743 0 3.157-2.088 3.157-4.664 0-2.577-1.414-4.665-3.157-4.665-1.744 0-3.157 2.088-3.157 4.665 0 2.576 1.413 4.664 3.157 4.664Z",
|
|
5195
|
+
fill: "#fff"
|
|
5196
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5197
|
+
d: "M118.662 66.057c4.326 0 7.834-6.2 7.834-13.846s-3.508-13.845-7.834-13.845c-4.327 0-7.834 6.199-7.834 13.845 0 7.647 3.507 13.846 7.834 13.846Z",
|
|
5198
|
+
fill: "#1A1A1A"
|
|
5199
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5200
|
+
d: "M120.032 52.774c1.744 0 3.157-2.089 3.157-4.665s-1.413-4.665-3.157-4.665c-1.743 0-3.157 2.089-3.157 4.665s1.414 4.665 3.157 4.665Z",
|
|
5201
|
+
fill: "#fff"
|
|
5202
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5203
|
+
d: "M92.674 63.11a10.286 10.286 0 0 0 7.949 1.095 13.2 13.2 0 0 0 2.623-1.118.738.738 0 0 1 1.035.639.748.748 0 0 1-.119.453c-2.224 2.82-6.474 3.625-9.672 2.12a7.284 7.284 0 0 1-2.75-2.12.748.748 0 0 1 .465-1.139.738.738 0 0 1 .469.054v.015Z",
|
|
5204
|
+
fill: "#999"
|
|
5205
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5206
|
+
d: "M55.773 64.004c4.349 0 7.874-5.285 7.874-11.804s-3.525-11.804-7.874-11.804-7.875 5.285-7.875 11.804c0 6.52 3.526 11.804 7.875 11.804Zm84.17.015c4.349 0 7.874-5.285 7.874-11.804 0-6.52-3.525-11.804-7.874-11.804s-7.875 5.285-7.875 11.804 3.526 11.804 7.875 11.804Z",
|
|
5207
|
+
fill: "#3690EA"
|
|
5208
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5209
|
+
d: "M95.008 14.315c-.115-.488 6.548-.932 5.815.246v.771c0 .745.033 1.51.037 2.262.003.752.033 1.594.04 2.392.282.592-6.474.935-5.818-.116v-.67c-.014-1.629-.055-3.257-.074-4.885Z",
|
|
5210
|
+
fill: "#F2F2F2"
|
|
5211
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5212
|
+
d: "M97.962 29.036c7.273 0 13.17-2.224 13.17-4.967 0-2.743-5.897-4.966-13.17-4.966-7.274 0-13.17 2.223-13.17 4.966 0 2.743 5.896 4.967 13.17 4.967Z",
|
|
5213
|
+
fill: "#B3B3B3"
|
|
5214
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5215
|
+
d: "M97.962 16.55c4.545 0 8.23-3.705 8.23-8.275S102.507 0 97.962 0c-4.546 0-8.23 3.705-8.23 8.275s3.684 8.275 8.23 8.275Z",
|
|
5216
|
+
fill: "#3690EA"
|
|
5217
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5218
|
+
d: "M141.607 59.283V45.147a19.038 19.038 0 0 0-3.687-11.301 18.872 18.872 0 0 0-9.653-6.874c-8.838-2.69-19.203-4.24-30.29-4.244-11.088-.004-21.452 1.546-30.29 4.233a18.871 18.871 0 0 0-9.668 6.866 19.041 19.041 0 0 0-3.699 11.305v14.132a19.03 19.03 0 0 0 3.685 11.303 18.86 18.86 0 0 0 9.656 6.872c8.841 2.694 19.206 4.244 30.29 4.244 11.083 0 21.452-1.542 30.294-4.233a18.858 18.858 0 0 0 9.666-6.863 19.028 19.028 0 0 0 3.696-11.304Z",
|
|
5219
|
+
fill: "#F2F2F2"
|
|
5220
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5221
|
+
d: "M97.954 75.051c-10.068 0-19.88-1.371-28.381-3.957a12.353 12.353 0 0 1-6.262-4.485 12.463 12.463 0 0 1-2.41-7.34V45.131c.006-2.642.85-5.214 2.411-7.34a12.345 12.345 0 0 1 6.264-4.482c8.501-2.586 18.317-3.95 28.382-3.95 10.065 0 19.877 1.371 28.382 3.96a12.35 12.35 0 0 1 6.262 4.486 12.46 12.46 0 0 1 2.409 7.34V59.28a12.453 12.453 0 0 1-2.41 7.341 12.343 12.343 0 0 1-6.265 4.482c-8.486 2.585-18.317 3.949-28.382 3.949Zm2.909-59.059h-5.81v1.293h5.81v-1.293Z",
|
|
5222
|
+
fill: "#E6E6E6"
|
|
5223
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5224
|
+
d: "M76.472 66.05c4.327 0 7.834-6.2 7.834-13.846 0-7.647-3.507-13.846-7.834-13.846-4.326 0-7.833 6.2-7.833 13.846s3.507 13.845 7.833 13.845Z",
|
|
5225
|
+
fill: "#1A1A1A"
|
|
5226
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5227
|
+
d: "M77.844 52.766c1.743 0 3.157-2.088 3.157-4.664 0-2.577-1.414-4.665-3.157-4.665-1.744 0-3.157 2.088-3.157 4.665 0 2.576 1.413 4.664 3.157 4.664Z",
|
|
5228
|
+
fill: "#fff"
|
|
5229
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5230
|
+
d: "M118.662 66.057c4.326 0 7.834-6.2 7.834-13.846s-3.508-13.845-7.834-13.845c-4.327 0-7.834 6.199-7.834 13.845 0 7.647 3.507 13.846 7.834 13.846Z",
|
|
5231
|
+
fill: "#1A1A1A"
|
|
5232
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5233
|
+
d: "M120.032 52.774c1.744 0 3.157-2.089 3.157-4.665s-1.413-4.665-3.157-4.665c-1.743 0-3.157 2.089-3.157 4.665s1.414 4.665 3.157 4.665Z",
|
|
5234
|
+
fill: "#fff"
|
|
5235
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5236
|
+
d: "M92.674 63.11a10.286 10.286 0 0 0 7.949 1.095 13.2 13.2 0 0 0 2.623-1.118.738.738 0 0 1 1.035.639.748.748 0 0 1-.119.453c-2.224 2.82-6.474 3.625-9.672 2.12a7.284 7.284 0 0 1-2.75-2.12.748.748 0 0 1 .465-1.139.738.738 0 0 1 .469.054v.015Z",
|
|
5237
|
+
fill: "#999"
|
|
5238
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5239
|
+
d: "M101.117 9.562a3.035 3.035 0 0 0 3.027-3.043 3.035 3.035 0 0 0-3.027-3.043A3.035 3.035 0 0 0 98.09 6.52a3.035 3.035 0 0 0 3.027 3.043ZM51.578 54.84c.801 0 1.45-1.64 1.45-3.66 0-2.023-.649-3.662-1.45-3.662-.802 0-1.451 1.64-1.451 3.661 0 2.022.65 3.66 1.45 3.66Zm93.429 0c.802 0 1.451-1.64 1.451-3.66 0-2.023-.649-3.662-1.451-3.662-.801 0-1.45 1.64-1.45 3.661 0 2.022.649 3.66 1.45 3.66Z",
|
|
5240
|
+
fill: "#4BAAF7"
|
|
5241
|
+
}), /*#__PURE__*/React__default.createElement("g", {
|
|
5242
|
+
clipPath: `url(#${id}-b)`
|
|
5243
|
+
}, /*#__PURE__*/React__default.createElement("path", {
|
|
5244
|
+
d: "M52.39 160.841h-2.919a1.774 1.774 0 0 1-1.766-1.782v-7.334h9.035l-2.677 7.911a1.766 1.766 0 0 1-1.671 1.206l-.001-.001Zm91.774 0h2.919c.977 0 1.767-.799 1.767-1.782v-7.334h-9.036l2.677 7.911a1.767 1.767 0 0 0 1.672 1.206l.001-.001Z",
|
|
5245
|
+
fill: "#6D4932"
|
|
5246
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5247
|
+
d: "M163.181 108.015H33.375c-2.37 0-4.291 1.479-4.291 3.305v2.216c0 1.825 1.921 3.305 4.29 3.305h129.807c2.369 0 4.29-1.48 4.29-3.305v-2.216c0-1.826-1.921-3.305-4.29-3.305Z",
|
|
5248
|
+
fill: "#A87B5D"
|
|
5249
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5250
|
+
d: "M38.282 116.841h119.992v33.16c0 1.648-1.554 2.985-3.469 2.985H41.752c-1.915 0-3.468-1.337-3.468-2.985v-33.16h-.002Z",
|
|
5251
|
+
fill: "#916A50"
|
|
5252
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5253
|
+
opacity: ".3",
|
|
5254
|
+
d: "M131.002 109.794h-97.18a.996.996 0 0 0-.992 1.001c0 .552.444 1 .992 1h97.18a.996.996 0 0 0 .991-1 .996.996 0 0 0-.991-1.001Zm30.849 0h-24.24a.996.996 0 0 0-.992 1.001c0 .552.444 1 .992 1h24.24a.996.996 0 0 0 .992-1 .996.996 0 0 0-.992-1.001Z",
|
|
5255
|
+
fill: "#D4B097"
|
|
5256
|
+
})), /*#__PURE__*/React__default.createElement("g", {
|
|
5257
|
+
clipPath: `url(#${id}-c)`
|
|
5258
|
+
}, /*#__PURE__*/React__default.createElement("path", {
|
|
5259
|
+
d: "M151.367 97.536h2.894c1.6 0 2.895 1.307 2.895 2.913a2.906 2.906 0 0 1-2.895 2.914h-2.894v-5.827Z",
|
|
5260
|
+
strokeWidth: "6",
|
|
5261
|
+
strokeMiterlimit: "10",
|
|
5262
|
+
stroke: `url(#${id}-d)`
|
|
5263
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5264
|
+
d: "M135.876 93.304h17.017a.6.6 0 0 1 .597.602v10.166c0 1.942-1.566 3.522-3.499 3.522h-11.214c-1.933 0-3.499-1.58-3.499-3.522V93.906a.6.6 0 0 1 .598-.602Z",
|
|
5265
|
+
fill: `url(#${id}-e)`
|
|
5266
|
+
})), /*#__PURE__*/React__default.createElement("path", {
|
|
5267
|
+
d: "m37.492 78.174 38.863-6.725a3.453 3.453 0 0 1 3.455 3.45v30.087H34.04V81.623a3.452 3.452 0 0 1 3.452-3.45Z",
|
|
5268
|
+
fill: `url(#${id}-f)`
|
|
5269
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5270
|
+
d: "M34.1 108.015v-3.363h57.697v3.363H34.1Z",
|
|
5271
|
+
fill: `url(#${id}-g)`
|
|
5272
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5273
|
+
d: "M79.673 108.015v-3.363h12.124v3.363H79.673Z",
|
|
5274
|
+
fill: `url(#${id}-h)`
|
|
5275
|
+
})), /*#__PURE__*/React__default.createElement("defs", null, /*#__PURE__*/React__default.createElement("linearGradient", {
|
|
5276
|
+
id: `${id}-d`,
|
|
5277
|
+
x1: "150.254",
|
|
5278
|
+
y1: "100.449",
|
|
5279
|
+
x2: "158.273",
|
|
5280
|
+
y2: "100.449",
|
|
5281
|
+
gradientUnits: "userSpaceOnUse"
|
|
5282
|
+
}, /*#__PURE__*/React__default.createElement("stop", {
|
|
5283
|
+
stopColor: "#FEFEFE"
|
|
5284
|
+
}), /*#__PURE__*/React__default.createElement("stop", {
|
|
5285
|
+
offset: "1",
|
|
5286
|
+
stopColor: "#fff"
|
|
5287
|
+
})), /*#__PURE__*/React__default.createElement("linearGradient", {
|
|
5288
|
+
id: `${id}-e`,
|
|
5289
|
+
x1: "132.629",
|
|
5290
|
+
y1: "100.449",
|
|
5291
|
+
x2: "155.32",
|
|
5292
|
+
y2: "100.449",
|
|
5293
|
+
gradientUnits: "userSpaceOnUse"
|
|
5294
|
+
}, /*#__PURE__*/React__default.createElement("stop", {
|
|
5295
|
+
stopColor: "#FEFEFE"
|
|
5296
|
+
}), /*#__PURE__*/React__default.createElement("stop", {
|
|
5297
|
+
offset: "1",
|
|
5298
|
+
stopColor: "#F3F3F3"
|
|
5299
|
+
})), /*#__PURE__*/React__default.createElement("linearGradient", {
|
|
5300
|
+
id: `${id}-f`,
|
|
5301
|
+
x1: "56.925",
|
|
5302
|
+
y1: "45.291",
|
|
5303
|
+
x2: "56.925",
|
|
5304
|
+
y2: "93.076",
|
|
5305
|
+
gradientUnits: "userSpaceOnUse"
|
|
5306
|
+
}, /*#__PURE__*/React__default.createElement("stop", {
|
|
5307
|
+
stopColor: "#FEFEFE"
|
|
5308
|
+
}), /*#__PURE__*/React__default.createElement("stop", {
|
|
5309
|
+
offset: "1",
|
|
5310
|
+
stopColor: "#D1D6E7"
|
|
5311
|
+
})), /*#__PURE__*/React__default.createElement("linearGradient", {
|
|
5312
|
+
id: `${id}-g`,
|
|
5313
|
+
x1: "62.684",
|
|
5314
|
+
y1: "108.015",
|
|
5315
|
+
x2: "62.684",
|
|
5316
|
+
y2: "104.85",
|
|
5317
|
+
gradientUnits: "userSpaceOnUse"
|
|
5318
|
+
}, /*#__PURE__*/React__default.createElement("stop", {
|
|
5319
|
+
stopColor: "#D2D6E8"
|
|
5320
|
+
}), /*#__PURE__*/React__default.createElement("stop", {
|
|
5321
|
+
offset: ".726",
|
|
5322
|
+
stopColor: "#D1D6E7"
|
|
5323
|
+
})), /*#__PURE__*/React__default.createElement("linearGradient", {
|
|
5324
|
+
id: `${id}-h`,
|
|
5325
|
+
x1: "85.68",
|
|
5326
|
+
y1: "108.015",
|
|
5327
|
+
x2: "85.68",
|
|
5328
|
+
y2: "104.85",
|
|
5329
|
+
gradientUnits: "userSpaceOnUse"
|
|
5330
|
+
}, /*#__PURE__*/React__default.createElement("stop", {
|
|
5331
|
+
stopColor: "#D8DDF1"
|
|
5332
|
+
}), /*#__PURE__*/React__default.createElement("stop", {
|
|
5333
|
+
offset: ".726",
|
|
5334
|
+
stopColor: "#E2E6F6"
|
|
5335
|
+
})), /*#__PURE__*/React__default.createElement("clipPath", {
|
|
5336
|
+
id: `${id}-a`
|
|
5337
|
+
}, /*#__PURE__*/React__default.createElement("path", {
|
|
5338
|
+
fill: "#fff",
|
|
5339
|
+
transform: "translate(12.006)",
|
|
5340
|
+
d: "M0 0h172v174H0z"
|
|
5341
|
+
})), /*#__PURE__*/React__default.createElement("clipPath", {
|
|
5342
|
+
id: `${id}-b`
|
|
5343
|
+
}, /*#__PURE__*/React__default.createElement("path", {
|
|
5344
|
+
fill: "#fff",
|
|
5345
|
+
transform: "translate(29.084 105.073)",
|
|
5346
|
+
d: "M0 0h138.387v68.927H0z"
|
|
5347
|
+
})), /*#__PURE__*/React__default.createElement("clipPath", {
|
|
5348
|
+
id: `${id}-c`
|
|
5349
|
+
}, /*#__PURE__*/React__default.createElement("path", {
|
|
5350
|
+
fill: "#fff",
|
|
5351
|
+
transform: "translate(135.278 93.304)",
|
|
5352
|
+
d: "M0 0h22.995v14.29H0z"
|
|
5353
|
+
}))));
|
|
5354
|
+
}
|
|
5355
|
+
|
|
5356
|
+
var styles$f = {"blank_state":"blank_state-wMOWN","image":"image-uy0Fd"};
|
|
5357
|
+
|
|
5358
|
+
function BlankState$1({
|
|
5359
|
+
image,
|
|
5360
|
+
role,
|
|
5361
|
+
subtitle,
|
|
5362
|
+
title
|
|
5363
|
+
}) {
|
|
5364
|
+
return /*#__PURE__*/React__default.createElement(Flex, {
|
|
5365
|
+
role: role,
|
|
5366
|
+
className: styles$f.blank_state,
|
|
5367
|
+
direction: "column",
|
|
5368
|
+
align: "center",
|
|
5369
|
+
gap: 3
|
|
5370
|
+
}, /*#__PURE__*/React__default.createElement(Flex, {
|
|
5371
|
+
className: styles$f.image
|
|
5372
|
+
}, image), /*#__PURE__*/React__default.createElement(Flex, {
|
|
5373
|
+
direction: "column",
|
|
5374
|
+
align: "center",
|
|
5375
|
+
gap: 1
|
|
5376
|
+
}, /*#__PURE__*/React__default.createElement("h2", null, title), /*#__PURE__*/React__default.createElement("p", null, subtitle)));
|
|
5377
|
+
}
|
|
4189
5378
|
|
|
4190
5379
|
function EndOfResultsObserver({
|
|
4191
5380
|
onVisible
|
|
@@ -4205,39 +5394,119 @@ function EndOfResultsObserver({
|
|
|
4205
5394
|
|
|
4206
5395
|
const resultId = (listboxId, index) => `${listboxId}-result-${index}`;
|
|
4207
5396
|
|
|
4208
|
-
var styles$
|
|
5397
|
+
var styles$e = {"result":"result-Thq2C","title":"title-KYUEn","subtitle":"subtitle-R2haq","image":"image-KVDor","avatar":"avatar-6Gh62","photo":"photo-FZR3Q","badge":"badge-trUKt"};
|
|
4209
5398
|
|
|
4210
5399
|
function SearchResult({
|
|
5400
|
+
category,
|
|
5401
|
+
describedBy,
|
|
5402
|
+
headingAbove,
|
|
4211
5403
|
highlighted,
|
|
4212
5404
|
id,
|
|
5405
|
+
imageUrl,
|
|
4213
5406
|
onHighlight,
|
|
5407
|
+
onOpen,
|
|
5408
|
+
product,
|
|
4214
5409
|
subtitle,
|
|
4215
5410
|
title,
|
|
4216
5411
|
url
|
|
4217
5412
|
}) {
|
|
4218
5413
|
const ref = React__default.useRef(null);
|
|
5414
|
+
// A hovered result is already under the pointer, and scrolling it clear of
|
|
5415
|
+
// the panel's scroll padding would slide the list out from under the mouse.
|
|
5416
|
+
const highlightedByPointer = React__default.useRef(false);
|
|
4219
5417
|
React__default.useEffect(() => {
|
|
4220
|
-
var _a;
|
|
4221
|
-
if (highlighted)
|
|
4222
|
-
|
|
4223
|
-
|
|
4224
|
-
|
|
5418
|
+
var _a, _b;
|
|
5419
|
+
if (!highlighted) return;
|
|
5420
|
+
if (highlightedByPointer.current) {
|
|
5421
|
+
highlightedByPointer.current = false;
|
|
5422
|
+
} else {
|
|
5423
|
+
(_a = ref.current) === null || _a === void 0 ? void 0 : _a.scrollIntoView({
|
|
5424
|
+
block: "nearest"
|
|
5425
|
+
});
|
|
5426
|
+
// Scrolling up to a section's first result leaves its heading cut off
|
|
5427
|
+
// above it, so bring that in too. Scrolling down, it's already in view.
|
|
5428
|
+
if (headingAbove) {
|
|
5429
|
+
(_b = document.getElementById(headingAbove)) === null || _b === void 0 ? void 0 : _b.scrollIntoView({
|
|
5430
|
+
block: "nearest"
|
|
5431
|
+
});
|
|
5432
|
+
}
|
|
5433
|
+
}
|
|
5434
|
+
}, [headingAbove, highlighted]);
|
|
5435
|
+
const highlightFromPointer = () => {
|
|
5436
|
+
if (highlighted) return;
|
|
5437
|
+
highlightedByPointer.current = true;
|
|
5438
|
+
onHighlight();
|
|
5439
|
+
};
|
|
5440
|
+
// Closes search before the page goes, so coming back to it doesn't find
|
|
5441
|
+
// search still open. Clicks that open a new tab or window leave it open.
|
|
5442
|
+
const openFromClick = event => {
|
|
5443
|
+
if (event.button !== 0 || event.altKey || event.ctrlKey || event.metaKey || event.shiftKey) return;
|
|
5444
|
+
onOpen();
|
|
5445
|
+
};
|
|
4225
5446
|
// Focus stays in the search input, which points at the highlighted result
|
|
4226
5447
|
// with aria-activedescendant, so results are kept out of the tab order.
|
|
4227
5448
|
// Mouse move rather than enter: arrowing scrolls results under a resting
|
|
4228
5449
|
// pointer, and that shouldn't steal the highlight.
|
|
4229
|
-
|
|
4230
|
-
|
|
4231
|
-
|
|
4232
|
-
|
|
4233
|
-
|
|
4234
|
-
|
|
4235
|
-
|
|
4236
|
-
|
|
4237
|
-
|
|
4238
|
-
|
|
5450
|
+
// Results open with a full page load, like Enter does, rather than through
|
|
5451
|
+
// the product's router. Their URLs can go through server redirects, like
|
|
5452
|
+
// People's staff URLs, that Turbo would follow with fetch or prefetch on
|
|
5453
|
+
// hover, and they should open the same way in every product.
|
|
5454
|
+
return (
|
|
5455
|
+
/*#__PURE__*/
|
|
5456
|
+
// Named by the title alone, so screen readers say "Ada Lovelace" rather
|
|
5457
|
+
// than the whole row. The section and subtitle are read after a pause.
|
|
5458
|
+
React__default.createElement("a", {
|
|
5459
|
+
"aria-describedby": [describedBy, subtitle && `${id}-subtitle`].filter(Boolean).join(" ") || undefined,
|
|
5460
|
+
"aria-labelledby": title ? `${id}-title` : undefined,
|
|
5461
|
+
"aria-selected": highlighted,
|
|
5462
|
+
className: styles$e.result,
|
|
5463
|
+
"data-turbo": "false",
|
|
5464
|
+
href: url,
|
|
5465
|
+
id: id,
|
|
5466
|
+
onClick: openFromClick,
|
|
5467
|
+
onMouseMove: highlightFromPointer,
|
|
5468
|
+
ref: ref,
|
|
5469
|
+
role: "option",
|
|
5470
|
+
tabIndex: -1
|
|
5471
|
+
}, /*#__PURE__*/React__default.createElement(ResultImage, {
|
|
5472
|
+
category: category,
|
|
5473
|
+
imageUrl: imageUrl,
|
|
5474
|
+
product: product
|
|
5475
|
+
}), /*#__PURE__*/React__default.createElement("span", {
|
|
5476
|
+
className: styles$e.title,
|
|
5477
|
+
id: `${id}-title`
|
|
5478
|
+
}, title), /*#__PURE__*/React__default.createElement("span", {
|
|
5479
|
+
className: styles$e.subtitle,
|
|
5480
|
+
id: `${id}-subtitle`
|
|
5481
|
+
}, subtitle))
|
|
5482
|
+
);
|
|
5483
|
+
}
|
|
5484
|
+
// A person's photo or the result's own image, badged with its product, or
|
|
5485
|
+
// just the product's logomark when there's no image.
|
|
5486
|
+
function ResultImage({
|
|
5487
|
+
category,
|
|
5488
|
+
imageUrl,
|
|
5489
|
+
product
|
|
5490
|
+
}) {
|
|
5491
|
+
const icon = size => isProductIconSlug(product) ? (/*#__PURE__*/React__default.createElement(ProductIcon, {
|
|
5492
|
+
size: size,
|
|
5493
|
+
slug: product
|
|
5494
|
+
})) : null;
|
|
5495
|
+
return /*#__PURE__*/React__default.createElement("span", {
|
|
5496
|
+
"aria-hidden": true,
|
|
5497
|
+
className: styles$e.image
|
|
5498
|
+
}, imageUrl ? (/*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement("img", {
|
|
5499
|
+
alt: "",
|
|
5500
|
+
className: category === "profile" ? styles$e.avatar : styles$e.photo,
|
|
5501
|
+
loading: "lazy",
|
|
5502
|
+
src: imageUrl
|
|
5503
|
+
}), /*#__PURE__*/React__default.createElement("span", {
|
|
5504
|
+
className: styles$e.badge
|
|
5505
|
+
}, icon(16)))) : icon("100%"));
|
|
4239
5506
|
}
|
|
4240
5507
|
|
|
5508
|
+
var styles$d = {"heading":"heading-LioUF","group":"group-cKChg"};
|
|
5509
|
+
|
|
4241
5510
|
// Sections with a heading render as labelled groups; ones without render
|
|
4242
5511
|
// their items straight into the listbox. Indexes run across every section.
|
|
4243
5512
|
function ResultListbox({
|
|
@@ -4247,16 +5516,27 @@ function ResultListbox({
|
|
|
4247
5516
|
label,
|
|
4248
5517
|
labelledBy,
|
|
4249
5518
|
onHighlight,
|
|
5519
|
+
onOpen,
|
|
4250
5520
|
sections
|
|
4251
5521
|
}) {
|
|
4252
5522
|
let index = 0;
|
|
4253
|
-
|
|
5523
|
+
// With aria-activedescendant, screen readers don't reliably announce the
|
|
5524
|
+
// group a highlighted option is in, so each option names its heading too.
|
|
5525
|
+
const renderItem = (item, indexInSection, headingId) => {
|
|
4254
5526
|
const itemIndex = index++;
|
|
5527
|
+
// Sections without a heading of their own sit under the listbox's label.
|
|
5528
|
+
const headingAbove = indexInSection > 0 ? undefined : headingId !== null && headingId !== void 0 ? headingId : itemIndex === 0 ? labelledBy : undefined;
|
|
4255
5529
|
return /*#__PURE__*/React__default.createElement(SearchResult, {
|
|
5530
|
+
category: item.category,
|
|
5531
|
+
describedBy: headingId,
|
|
5532
|
+
headingAbove: headingAbove,
|
|
4256
5533
|
highlighted: itemIndex === highlightedIndex,
|
|
4257
5534
|
id: resultId(id, itemIndex),
|
|
5535
|
+
imageUrl: item.imageUrl,
|
|
4258
5536
|
key: item.key,
|
|
4259
5537
|
onHighlight: () => onHighlight(itemIndex),
|
|
5538
|
+
onOpen: onOpen,
|
|
5539
|
+
product: item.product,
|
|
4260
5540
|
subtitle: item.subtitle,
|
|
4261
5541
|
title: item.title,
|
|
4262
5542
|
url: item.url
|
|
@@ -4272,16 +5552,18 @@ function ResultListbox({
|
|
|
4272
5552
|
if (section.heading === undefined) {
|
|
4273
5553
|
return /*#__PURE__*/React__default.createElement(React__default.Fragment, {
|
|
4274
5554
|
key: section.key
|
|
4275
|
-
}, section.items.map(renderItem));
|
|
5555
|
+
}, section.items.map((item, itemIndex) => renderItem(item, itemIndex)));
|
|
4276
5556
|
}
|
|
4277
5557
|
const headingId = `${id}-group-${sectionIndex}`;
|
|
4278
5558
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
4279
5559
|
"aria-labelledby": headingId,
|
|
5560
|
+
className: styles$d.group,
|
|
4280
5561
|
key: section.key,
|
|
4281
5562
|
role: "group"
|
|
4282
5563
|
}, /*#__PURE__*/React__default.createElement("div", {
|
|
5564
|
+
className: styles$d.heading,
|
|
4283
5565
|
id: headingId
|
|
4284
|
-
}, section.heading), section.items.map(renderItem));
|
|
5566
|
+
}, section.heading), section.items.map((item, itemIndex) => renderItem(item, itemIndex, headingId)));
|
|
4285
5567
|
}));
|
|
4286
5568
|
}
|
|
4287
5569
|
|
|
@@ -4295,9 +5577,14 @@ function RecentlyVisited({
|
|
|
4295
5577
|
}) {
|
|
4296
5578
|
const headingId = `${navigation.id}-heading`;
|
|
4297
5579
|
if (items.length === 0 && !hasMore && !loading) {
|
|
4298
|
-
return /*#__PURE__*/React__default.createElement(
|
|
5580
|
+
return /*#__PURE__*/React__default.createElement(BlankState$1, {
|
|
5581
|
+
image: /*#__PURE__*/React__default.createElement(BlankStateRecentlyVisited, null),
|
|
5582
|
+
subtitle: "Pages you visit will show up here.",
|
|
5583
|
+
title: "Recently visited"
|
|
5584
|
+
});
|
|
4299
5585
|
} else {
|
|
4300
5586
|
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement("div", {
|
|
5587
|
+
className: styles$d.heading,
|
|
4301
5588
|
id: headingId
|
|
4302
5589
|
}, "Recently visited"), /*#__PURE__*/React__default.createElement(ResultListbox, {
|
|
4303
5590
|
labelledBy: headingId,
|
|
@@ -4313,6 +5600,8 @@ function RecentlyVisited({
|
|
|
4313
5600
|
}
|
|
4314
5601
|
}
|
|
4315
5602
|
|
|
5603
|
+
var styles$c = {"row":"row-5P7UQ","header":"header-sXEyG","closeButton":"closeButton-rPJJV","input":"input-YQkTC","clearButton":"clearButton-9Yh9w"};
|
|
5604
|
+
|
|
4316
5605
|
// A combobox: focus stays here while aria-activedescendant points screen
|
|
4317
5606
|
// readers at the highlighted result in the listbox it controls.
|
|
4318
5607
|
function SearchInput({
|
|
@@ -4321,29 +5610,441 @@ function SearchInput({
|
|
|
4321
5610
|
inputRef,
|
|
4322
5611
|
listboxId,
|
|
4323
5612
|
onChange,
|
|
5613
|
+
onClose,
|
|
4324
5614
|
onFocus,
|
|
4325
5615
|
onKeyDown,
|
|
4326
5616
|
value
|
|
4327
5617
|
}) {
|
|
4328
|
-
|
|
5618
|
+
const {
|
|
5619
|
+
focusProps
|
|
5620
|
+
} = useKeyboardFocus({
|
|
5621
|
+
onFocus: (event, keyboard) => {
|
|
5622
|
+
// Tabbing in selects the whole term, which the next keystroke would
|
|
5623
|
+
// replace. Put the cursor after it instead, to keep typing. The
|
|
5624
|
+
// browser selects after the focus event, so this waits a frame and
|
|
5625
|
+
// only undoes that select-all: typing on the tabs moves focus here by
|
|
5626
|
+
// script, which keeps the cursor, and the keystroke may already be in.
|
|
5627
|
+
if (keyboard) {
|
|
5628
|
+
const input = event.currentTarget;
|
|
5629
|
+
requestAnimationFrame(() => {
|
|
5630
|
+
const length = input.value.length;
|
|
5631
|
+
const selectedAll = length > 0 && input.selectionStart === 0 && input.selectionEnd === length;
|
|
5632
|
+
if (document.activeElement !== input || !selectedAll) return;
|
|
5633
|
+
input.setSelectionRange(length, length);
|
|
5634
|
+
});
|
|
5635
|
+
}
|
|
5636
|
+
onFocus();
|
|
5637
|
+
}
|
|
5638
|
+
});
|
|
5639
|
+
return /*#__PURE__*/React__default.createElement("div", {
|
|
5640
|
+
className: styles$c.row
|
|
5641
|
+
}, /*#__PURE__*/React__default.createElement("label", {
|
|
5642
|
+
className: styles$c.header,
|
|
5643
|
+
id: "topbar_product_search_label"
|
|
5644
|
+
}, /*#__PURE__*/React__default.createElement(Icon, {
|
|
5645
|
+
name: "general.search",
|
|
5646
|
+
size: 20,
|
|
5647
|
+
theme: "--t-icon-color-dim"
|
|
5648
|
+
}), /*#__PURE__*/React__default.createElement("input", {
|
|
4329
5649
|
"aria-activedescendant": highlightedIndex === null ? undefined : resultId(listboxId, highlightedIndex),
|
|
4330
5650
|
"aria-autocomplete": "list",
|
|
4331
5651
|
"aria-controls": expanded ? listboxId : undefined,
|
|
4332
5652
|
"aria-expanded": expanded,
|
|
4333
5653
|
"aria-label": "Search",
|
|
4334
5654
|
autoFocus: true,
|
|
5655
|
+
className: styles$c.input,
|
|
5656
|
+
id: "product_search",
|
|
4335
5657
|
onChange: event => onChange(event.target.value),
|
|
4336
|
-
onFocus: onFocus,
|
|
4337
5658
|
onKeyDown: onKeyDown,
|
|
4338
5659
|
placeholder: "Search",
|
|
4339
5660
|
ref: inputRef,
|
|
4340
5661
|
role: "combobox",
|
|
4341
5662
|
type: "search",
|
|
4342
|
-
value: value
|
|
4343
|
-
|
|
5663
|
+
value: value,
|
|
5664
|
+
...focusProps
|
|
5665
|
+
}), !onClose && value !== "" && (/*#__PURE__*/React__default.createElement("button", {
|
|
5666
|
+
"aria-label": "Clear search",
|
|
5667
|
+
className: styles$c.clearButton,
|
|
5668
|
+
onClick: () => {
|
|
5669
|
+
var _a;
|
|
5670
|
+
onChange("");
|
|
5671
|
+
(_a = inputRef.current) === null || _a === void 0 ? void 0 : _a.focus();
|
|
5672
|
+
},
|
|
5673
|
+
tabIndex: -1,
|
|
5674
|
+
type: "button"
|
|
5675
|
+
}, /*#__PURE__*/React__default.createElement("svg", {
|
|
5676
|
+
"aria-hidden": true,
|
|
5677
|
+
viewBox: "0 0 20 20"
|
|
5678
|
+
}, /*#__PURE__*/React__default.createElement("circle", {
|
|
5679
|
+
cx: "10",
|
|
5680
|
+
cy: "10",
|
|
5681
|
+
r: "10"
|
|
5682
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5683
|
+
d: "M6.5 6.5l7 7m0 -7l-7 7"
|
|
5684
|
+
}))))), onClose && (/*#__PURE__*/React__default.createElement(IconButton, {
|
|
5685
|
+
"aria-label": "Close search",
|
|
5686
|
+
className: styles$c.closeButton,
|
|
5687
|
+
icon: /*#__PURE__*/React__default.createElement(Icon, {
|
|
5688
|
+
name: "general.x",
|
|
5689
|
+
theme: "--t-icon-color-dim"
|
|
5690
|
+
}),
|
|
5691
|
+
kind: "ghost",
|
|
5692
|
+
onClick: onClose,
|
|
5693
|
+
size: "md"
|
|
5694
|
+
})));
|
|
5695
|
+
}
|
|
5696
|
+
|
|
5697
|
+
function BlankStateError(props) {
|
|
5698
|
+
const id = useInstanceId("blank-state-error");
|
|
5699
|
+
return /*#__PURE__*/React__default.createElement("svg", {
|
|
5700
|
+
viewBox: "0 0 197 158",
|
|
5701
|
+
fill: "none",
|
|
5702
|
+
"aria-hidden": "true",
|
|
5703
|
+
focusable: "false",
|
|
5704
|
+
...props
|
|
5705
|
+
}, /*#__PURE__*/React__default.createElement("path", {
|
|
5706
|
+
d: "M139.863 26.119c10.938 10.028 21.777 20.154 32.912 30.084 8.376 7.373 21.975 15.828 23.157 28.02.592 6.095-2.167 11.993-5.321 17.204-24.635 40.8-81.098 67.148-127.412 48.862-30.646-12.093-76.172-47.387-59.716-85.041C19.348 28.87 68.323 10.192 87.44 7.538c21.876-4.621 34.883 2.457 52.423 18.58Z",
|
|
5707
|
+
fill: "currentColor"
|
|
5708
|
+
}), /*#__PURE__*/React__default.createElement("g", {
|
|
5709
|
+
clipPath: `url(#${id}-a)`
|
|
5710
|
+
}, /*#__PURE__*/React__default.createElement("path", {
|
|
5711
|
+
d: "M76.296 111.268c-2.63 0-5.95-.883-9.822-3.622a3.39 3.39 0 0 1-1.375-2.212 3.375 3.375 0 0 1 .603-2.529 3.44 3.44 0 0 1 4.777-.767c5.305 3.786 7.949 1.838 8.056 1.767a1.23 1.23 0 0 0-.094.08l4.62 5.004a10.434 10.434 0 0 1-6.765 2.279Z",
|
|
5712
|
+
fill: "#4D4D4D"
|
|
5713
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5714
|
+
d: "M83.313 102.999a2.751 2.751 0 0 0-2.882-2.611 2.747 2.747 0 0 0-2.63 2.86l.399 8.688a2.751 2.751 0 0 0 2.882 2.611 2.746 2.746 0 0 0 2.63-2.86l-.399-8.688Z",
|
|
5715
|
+
fill: "gray"
|
|
5716
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5717
|
+
d: "M119.428 111.268a10.438 10.438 0 0 1-6.751-2.292l4.619-5.005a1.387 1.387 0 0 0-.093-.079c.106.084 2.75 2.032 8.055-1.767a3.439 3.439 0 0 1 4.777.766 3.378 3.378 0 0 1-.772 4.742c-3.885 2.774-7.205 3.635-9.835 3.635Z",
|
|
5718
|
+
fill: "#4D4D4D"
|
|
5719
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5720
|
+
d: "M101.658 18.962H94.68v1.533h6.978v-1.533Z",
|
|
5721
|
+
fill: "#F2F2F2"
|
|
5722
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5723
|
+
d: "M91.823 74.82a12.502 12.502 0 0 0 9.546 1.299 16.005 16.005 0 0 0 3.151-1.326.894.894 0 0 1 1.035.24.882.882 0 0 1 .064 1.053c-2.67 3.345-7.775 4.294-11.62 2.514a8.803 8.803 0 0 1-3.302-2.513.879.879 0 0 1 .561-1.353.887.887 0 0 1 .565.068v.017Z",
|
|
5724
|
+
fill: "#999"
|
|
5725
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5726
|
+
d: "M88.236 143.397a3.433 3.433 0 0 1-2.304-.891 3.383 3.383 0 0 1-1.096-2.201c-.636-6.788 4.237-16.369 4.798-17.442a3.41 3.41 0 0 1 2-1.643 3.442 3.442 0 0 1 2.586.227 3.398 3.398 0 0 1 1.68 1.965 3.368 3.368 0 0 1-.196 2.569c-1.75 3.37-4.402 10.066-4.059 13.693a3.38 3.38 0 0 1-.773 2.479 3.43 3.43 0 0 1-2.31 1.213l-.326.031Z",
|
|
5727
|
+
fill: "#4D4D4D"
|
|
5728
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5729
|
+
d: "M91.645 132.708c3.972 0 7.192-3.195 7.192-7.138 0-3.942-3.22-7.137-7.192-7.137s-7.191 3.195-7.191 7.137c0 3.943 3.22 7.138 7.191 7.138Z",
|
|
5730
|
+
fill: "gray"
|
|
5731
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5732
|
+
d: "M77.765 152.218h14.134v4.417c0 .351-.141.689-.391.937-.25.249-.59.388-.944.388H75.33a1.34 1.34 0 0 1-.945-.388 1.32 1.32 0 0 1-.39-.937v-.671c0-.997.398-1.953 1.109-2.658a3.801 3.801 0 0 1 2.678-1.101l-.018.013Z",
|
|
5733
|
+
fill: "#333"
|
|
5734
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5735
|
+
d: "M88.548 156.141s9.697.141 7.592-9.797c-2.105-9.939-14.641-18.198-18.295-7.191-3.654 11.007-1.695 18.056 10.703 16.988Z",
|
|
5736
|
+
fill: "#F2F2F2"
|
|
5737
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5738
|
+
d: "M109.077 143.402h-.325a3.427 3.427 0 0 1-2.313-1.216 3.38 3.38 0 0 1-.771-2.481c.342-3.627-2.305-10.323-4.054-13.693a3.371 3.371 0 0 1-.11-2.514c.29-.821.887-1.5 1.666-1.897a3.44 3.44 0 0 1 2.525-.236 3.413 3.413 0 0 1 1.993 1.555c.556 1.069 5.429 10.654 4.789 17.443a3.383 3.383 0 0 1-1.113 2.167 3.426 3.426 0 0 1-2.287.872Z",
|
|
5739
|
+
fill: "#4D4D4D"
|
|
5740
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5741
|
+
d: "M105.672 132.708c3.972 0 7.192-3.195 7.192-7.138 0-3.942-3.22-7.137-7.192-7.137s-7.191 3.195-7.191 7.137c0 3.943 3.219 7.138 7.191 7.138Z",
|
|
5742
|
+
fill: "gray"
|
|
5743
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5744
|
+
d: "m121.972 158.007-15.22-.003c-.354 0-.693-.139-.943-.388a1.317 1.317 0 0 1-.391-.937v-4.417l14.139.003c1.004 0 1.967.396 2.678 1.101a3.745 3.745 0 0 1 1.108 2.658v.671c0 .352-.141.689-.391.937-.25.249-.59.388-.944.388l-.036-.013Z",
|
|
5745
|
+
fill: "#333"
|
|
5746
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5747
|
+
d: "M108.769 156.145s-9.701.137-7.587-9.801c2.114-9.939 14.645-18.19 18.295-7.187 3.649 11.003 1.682 18.061-10.708 16.988Z",
|
|
5748
|
+
fill: "#F2F2F2"
|
|
5749
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5750
|
+
d: "M112.002 111.683c-.07 1.51 1.108 2.791 2.63 2.86a2.75 2.75 0 0 0 2.882-2.611l.399-8.688a2.746 2.746 0 0 0-2.63-2.86 2.75 2.75 0 0 0-2.882 2.611l-.399 8.688Z",
|
|
5751
|
+
fill: "gray"
|
|
5752
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5753
|
+
d: "M47.508 75.88c5.223 0 9.457-6.265 9.457-13.994 0-7.728-4.234-13.993-9.457-13.993-5.223 0-9.457 6.265-9.457 13.993 0 7.729 4.234 13.993 9.457 13.993Zm101.082.017c5.223 0 9.457-6.265 9.457-13.993 0-7.728-4.234-13.993-9.457-13.993-5.223 0-9.457 6.265-9.457 13.993 0 7.728 4.234 13.993 9.457 13.993Z",
|
|
5754
|
+
fill: "#3690EA"
|
|
5755
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5756
|
+
d: "M94.622 16.97c-.133-.574 7.868-1.1 6.987.296 0 .305 0 .61.022.914 0 .884.04 1.767.04 2.681 0 .915.041 1.886.054 2.832.334.706-7.78 1.113-6.991-.133v-.795c-.036-1.935-.09-3.86-.112-5.795Z",
|
|
5757
|
+
fill: "#F2F2F2"
|
|
5758
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5759
|
+
d: "M98.174 34.426c8.734 0 15.816-2.636 15.816-5.888s-7.082-5.888-15.816-5.888c-8.736 0-15.817 2.637-15.817 5.888 0 3.252 7.082 5.888 15.817 5.888Z",
|
|
5760
|
+
fill: "#B3B3B3"
|
|
5761
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5762
|
+
d: "M98.174 19.625c5.458 0 9.883-4.393 9.883-9.81 0-5.418-4.425-9.81-9.883-9.81-5.46 0-9.884 4.392-9.884 9.81s4.425 9.81 9.883 9.81Z",
|
|
5763
|
+
fill: "#3690EA"
|
|
5764
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5765
|
+
d: "M116.339 111.123c-.614-10.782-8.958-13.874-19.002-13.309-10.044.566-17.979 4.567-17.356 15.354.623 10.786 9.252 19.063 19.296 18.498 10.044-.565 17.676-9.761 17.062-20.543Z",
|
|
5766
|
+
fill: "#F2F2F2"
|
|
5767
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5768
|
+
d: "M116.139 109.4c-1.268 8.891-8.171 15.901-16.884 16.378-9.43.53-17.623-6.74-19.096-16.559a17.615 17.615 0 0 0-.205 3.949c.619 10.781 9.257 19.063 19.297 18.498 10.039-.566 17.685-9.762 17.07-20.544a11.69 11.69 0 0 0-.182-1.722Z",
|
|
5769
|
+
fill: "#E6E6E6"
|
|
5770
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5771
|
+
d: "M94.609 92.558c-.134-.579 7.868-1.1 6.987.291v.915c0 .883.035 1.789.04 2.68.004.893.04 1.891.053 2.837.334.702-7.779 1.108-6.991-.137v-.796c-.013-1.93-.067-3.86-.089-5.79Z",
|
|
5772
|
+
fill: "#999"
|
|
5773
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5774
|
+
d: "M150.588 70.279V53.525a22.366 22.366 0 0 0-4.425-13.4 22.645 22.645 0 0 0-11.596-8.146c-10.613-3.19-23.061-5.027-36.376-5.031-13.315-.004-25.762 1.833-36.38 5.018a22.654 22.654 0 0 0-11.609 8.14 22.374 22.374 0 0 0-4.438 13.401v16.754a22.375 22.375 0 0 0 4.435 13.403 22.654 22.654 0 0 0 11.607 8.143c10.614 3.19 23.061 5.026 36.376 5.031 13.315.004 25.763-1.833 36.376-5.018a22.658 22.658 0 0 0 11.598-8.144 22.377 22.377 0 0 0 4.432-13.397Z",
|
|
5775
|
+
fill: "#F2F2F2"
|
|
5776
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5777
|
+
d: "M98.16 88.976c-12.087 0-23.87-1.626-34.08-4.695a14.817 14.817 0 0 1-7.522-5.316 14.635 14.635 0 0 1-2.891-8.704V53.507a14.64 14.64 0 0 1 2.89-8.698 14.82 14.82 0 0 1 7.514-5.317c10.21-3.065 21.993-4.682 34.085-4.682 12.091 0 23.871 1.626 34.079 4.696a14.817 14.817 0 0 1 7.523 5.315 14.635 14.635 0 0 1 2.891 8.704V70.28a14.635 14.635 0 0 1-2.897 8.703 14.824 14.824 0 0 1-7.525 5.312c-10.191 3.047-21.976 4.682-34.067 4.682Zm3.498-70.014H94.68v1.533h6.978v-1.533Z",
|
|
5778
|
+
fill: "#E6E6E6"
|
|
5779
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5780
|
+
d: "M72.367 78.304c5.195 0 9.407-7.348 9.407-16.413 0-9.065-4.212-16.414-9.407-16.414-5.196 0-9.408 7.349-9.408 16.414 0 9.065 4.212 16.413 9.408 16.413Z",
|
|
5781
|
+
fill: "#1A1A1A"
|
|
5782
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5783
|
+
d: "M74.013 62.558c2.094 0 3.792-2.476 3.792-5.53 0-3.054-1.698-5.53-3.792-5.53s-3.791 2.476-3.791 5.53c0 3.054 1.697 5.53 3.791 5.53Z",
|
|
5784
|
+
fill: "#fff"
|
|
5785
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5786
|
+
d: "M123.032 78.313c5.196 0 9.408-7.349 9.408-16.413 0-9.065-4.212-16.414-9.408-16.414-5.195 0-9.407 7.349-9.407 16.414 0 9.065 4.212 16.413 9.407 16.413Z",
|
|
5787
|
+
fill: "#1A1A1A"
|
|
5788
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5789
|
+
d: "M124.679 62.567c2.094 0 3.792-2.476 3.792-5.53 0-3.054-1.698-5.53-3.792-5.53s-3.792 2.476-3.792 5.53c0 3.054 1.698 5.53 3.792 5.53Z",
|
|
5790
|
+
fill: "#fff"
|
|
5791
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5792
|
+
d: "M105.325 106.675H90.991a.74.74 0 0 0-.743.737v2.089a.74.74 0 0 0 .743.738h14.334a.74.74 0 0 0 .743-.738v-2.089a.74.74 0 0 0-.743-.737Zm0 6.148H90.991a.74.74 0 0 0-.743.738v2.089a.74.74 0 0 0 .743.738h14.334c.41 0 .743-.331.743-.738v-2.089a.74.74 0 0 0-.743-.738Zm-.004 6.153H90.987a.74.74 0 0 0-.744.737v2.09a.74.74 0 0 0 .744.737h14.334a.74.74 0 0 0 .743-.737v-2.09a.74.74 0 0 0-.743-.737Z",
|
|
5793
|
+
fill: "#3690EA"
|
|
5794
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5795
|
+
d: "M140.653 109.023c5.67-4.178 7.656-11.053 4.438-15.356-3.219-4.303-10.424-4.405-16.094-.227-5.67 4.177-7.656 11.052-4.438 15.356 3.219 4.303 10.424 4.405 16.094.227Z",
|
|
5796
|
+
fill: "#F2F2F2"
|
|
5797
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5798
|
+
d: "M144.211 97.717c-3.217-4.302-10.422-4.417-16.092-.23a15.277 15.277 0 0 0-5.087 6.339c.067-3.613 2.194-7.58 5.964-10.358 5.669-4.174 12.874-4.073 16.092.23 1.86 2.486 1.976 5.83.649 9.019a7.943 7.943 0 0 0-1.526-5Z",
|
|
5799
|
+
fill: "#E6E6E6"
|
|
5800
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5801
|
+
d: "M141.051 91.524c.966-1.66.874-3.508-.205-4.126-1.08-.618-2.737.226-3.703 1.887-.966 1.66-.874 3.508.205 4.126 1.079.619 2.737-.226 3.703-1.887Z",
|
|
5802
|
+
fill: "#333"
|
|
5803
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5804
|
+
d: "M142.711 103.49c4.151 0 7.517-3.34 7.517-7.46s-3.366-7.46-7.517-7.46-7.516 3.34-7.516 7.46 3.365 7.46 7.516 7.46Z",
|
|
5805
|
+
fill: "#333"
|
|
5806
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5807
|
+
d: "M70.234 108.894c3.219-4.303 1.232-11.178-4.437-15.356-5.67-4.178-12.875-4.076-16.094.227-3.219 4.303-1.232 11.179 4.438 15.356 5.67 4.178 12.875 4.076 16.093-.227Z",
|
|
5808
|
+
fill: "#F2F2F2"
|
|
5809
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5810
|
+
d: "M50.574 97.717c3.218-4.302 10.422-4.417 16.092-.23a15.273 15.273 0 0 1 5.087 6.339c-.067-3.613-2.194-7.58-5.964-10.358-5.67-4.174-12.874-4.073-16.092.23-1.86 2.486-1.971 5.83-.65 9.019a7.945 7.945 0 0 1 1.527-5Z",
|
|
5811
|
+
fill: "#E6E6E6"
|
|
5812
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5813
|
+
d: "M57.434 93.41c1.08-.618 1.171-2.466.206-4.126-.966-1.66-2.624-2.506-3.703-1.887-1.08.618-1.171 2.466-.205 4.126.965 1.66 2.623 2.506 3.702 1.887Z",
|
|
5814
|
+
fill: "#333"
|
|
5815
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5816
|
+
d: "M52.074 103.49c4.151 0 7.516-3.34 7.516-7.46s-3.365-7.46-7.516-7.46-7.517 3.34-7.517 7.46 3.366 7.46 7.517 7.46Z",
|
|
5817
|
+
fill: "#333"
|
|
5818
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5819
|
+
d: "M98.485 83.08c1.523-.183 2.609-1.544 2.426-3.041-.183-1.497-1.565-2.561-3.088-2.378-1.522.183-2.608 1.544-2.425 3.041.182 1.497 1.565 2.561 3.087 2.378Z",
|
|
5820
|
+
fill: "#1A1A1A"
|
|
5821
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5822
|
+
d: "M101.729 11.17c1.733 0 3.138-1.394 3.138-3.113 0-1.72-1.405-3.114-3.138-3.114-1.733 0-3.137 1.394-3.137 3.114s1.404 3.114 3.137 3.114Zm52.37 52.753c.829 0 1.5-1.677 1.5-3.746s-.671-3.746-1.5-3.746c-.828 0-1.499 1.677-1.499 3.746s.671 3.746 1.499 3.746Zm-111.549 0c.829 0 1.5-1.677 1.5-3.746s-.671-3.746-1.5-3.746c-.828 0-1.5 1.677-1.5 3.746s.672 3.746 1.5 3.746Z",
|
|
5823
|
+
fill: "#4BAAF7"
|
|
5824
|
+
})), /*#__PURE__*/React__default.createElement("mask", {
|
|
5825
|
+
id: `${id}-b`,
|
|
5826
|
+
style: {
|
|
5827
|
+
maskType: "alpha"
|
|
5828
|
+
},
|
|
5829
|
+
maskUnits: "userSpaceOnUse",
|
|
5830
|
+
x: "0",
|
|
5831
|
+
y: "6",
|
|
5832
|
+
width: "197",
|
|
5833
|
+
height: "151"
|
|
5834
|
+
}, /*#__PURE__*/React__default.createElement("path", {
|
|
5835
|
+
d: "M139.863 26.12c10.938 10.028 21.777 20.154 32.912 30.084 8.376 7.373 21.975 15.828 23.157 28.02.592 6.095-2.167 11.993-5.321 17.204-24.635 40.8-81.098 67.148-127.412 48.862-30.646-12.093-76.172-47.387-59.716-85.041 15.865-36.377 64.84-55.056 83.957-57.71 21.876-4.621 34.883 2.457 52.423 18.58Z",
|
|
5836
|
+
fill: "#CEE1FF",
|
|
5837
|
+
fillOpacity: ".8"
|
|
5838
|
+
})), /*#__PURE__*/React__default.createElement("g", {
|
|
5839
|
+
mask: `url(#${id}-b)`
|
|
5840
|
+
}, /*#__PURE__*/React__default.createElement("path", {
|
|
5841
|
+
d: "m59.006 101 8 4m-4 1-4-5h6",
|
|
5842
|
+
stroke: "#FFD463"
|
|
5843
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5844
|
+
d: "M60.006 100.999c-14.02-9.35-30.69-13.01-50-11S-26.916 103.01-38.276 115",
|
|
5845
|
+
strokeWidth: "2",
|
|
5846
|
+
stroke: "#fff"
|
|
5847
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5848
|
+
d: "m125.304 89-8.08 3.84m1.68-3.77 6.4-.07-3.7 4.72",
|
|
5849
|
+
stroke: "#FFD463"
|
|
5850
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5851
|
+
d: "M123.724 89.5c26.45-8.66 23 40.5 47 42.5 22.399 1.867 36.5-31.001 63 12",
|
|
5852
|
+
strokeWidth: "2",
|
|
5853
|
+
stroke: "#fff"
|
|
5854
|
+
})), /*#__PURE__*/React__default.createElement("defs", null, /*#__PURE__*/React__default.createElement("clipPath", {
|
|
5855
|
+
id: `${id}-a`
|
|
5856
|
+
}, /*#__PURE__*/React__default.createElement("path", {
|
|
5857
|
+
fill: "#fff",
|
|
5858
|
+
transform: "translate(38.051)",
|
|
5859
|
+
d: "M0 0h120v158H0z"
|
|
5860
|
+
}))));
|
|
4344
5861
|
}
|
|
4345
5862
|
|
|
4346
|
-
|
|
5863
|
+
function BlankStateNoResults(props) {
|
|
5864
|
+
const id = useInstanceId("blank-state-no-results");
|
|
5865
|
+
return /*#__PURE__*/React__default.createElement("svg", {
|
|
5866
|
+
viewBox: "0 0 197 152",
|
|
5867
|
+
fill: "none",
|
|
5868
|
+
"aria-hidden": "true",
|
|
5869
|
+
focusable: "false",
|
|
5870
|
+
...props
|
|
5871
|
+
}, /*#__PURE__*/React__default.createElement("path", {
|
|
5872
|
+
d: "M139.863 19.971C150.801 30 161.64 40.126 172.775 50.055c8.376 7.374 21.975 15.829 23.157 28.02.592 6.095-2.167 11.994-5.321 17.205-24.635 40.8-81.098 67.148-127.412 48.862C32.553 132.049-12.973 96.754 3.483 59.1 19.348 22.724 68.323 4.044 87.44 1.39c21.876-4.62 34.883 2.458 52.423 18.581Z",
|
|
5873
|
+
fill: "currentColor"
|
|
5874
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5875
|
+
d: "M94.382 27.326c4.859 0 8.797-3.932 8.797-8.783 0-4.85-3.938-8.783-8.797-8.783-4.858 0-8.796 3.933-8.796 8.783 0 4.851 3.938 8.783 8.796 8.783Z",
|
|
5876
|
+
fill: "#3690EA"
|
|
5877
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5878
|
+
d: "M97.481 19.861a3.22 3.22 0 0 0 3.222-3.217 3.22 3.22 0 0 0-3.222-3.217 3.22 3.22 0 0 0-3.222 3.217 3.22 3.22 0 0 0 3.222 3.217Z",
|
|
5879
|
+
fill: "#4BAAF7"
|
|
5880
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5881
|
+
d: "M97.564 26.688h-6.248v3.565h6.248v-3.565Z",
|
|
5882
|
+
fill: "#F2F2F2"
|
|
5883
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5884
|
+
d: "M49.297 77.706c4.649 0 8.417-5.61 8.417-12.53 0-6.921-3.768-12.531-8.417-12.531s-8.417 5.61-8.417 12.53c0 6.92 3.768 12.531 8.417 12.531Zm89.958 0c4.649 0 8.417-5.61 8.417-12.53 0-6.921-3.768-12.531-8.417-12.531s-8.417 5.61-8.417 12.53c0 6.92 3.768 12.531 8.417 12.531Z",
|
|
5885
|
+
fill: "#3690EA"
|
|
5886
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5887
|
+
d: "M94.379 40.574c7.774 0 14.076-2.36 14.076-5.271 0-2.912-6.302-5.272-14.076-5.272-7.774 0-14.076 2.36-14.076 5.272 0 2.911 6.302 5.271 14.076 5.271Z",
|
|
5888
|
+
fill: "#B3B3B3"
|
|
5889
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5890
|
+
d: "M141.036 72.671V57.672a20.118 20.118 0 0 0-3.949-12 20.166 20.166 0 0 0-10.333-7.29c-9.448-2.852-20.529-4.497-32.379-4.497-11.849 0-22.926 1.645-32.374 4.497a20.167 20.167 0 0 0-10.331 7.29 20.117 20.117 0 0 0-3.95 12v15a20.112 20.112 0 0 0 3.949 12A20.163 20.163 0 0 0 62 91.962c9.448 2.856 20.53 4.496 32.375 4.496 11.844 0 22.93-1.64 32.378-4.496a20.153 20.153 0 0 0 10.333-7.289 20.107 20.107 0 0 0 3.949-12.002Z",
|
|
5891
|
+
fill: "#F2F2F2"
|
|
5892
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5893
|
+
d: "M94.387 89.422c-10.76 0-21.248-1.448-30.348-4.193a13.19 13.19 0 0 1-6.698-4.759 13.159 13.159 0 0 1-2.576-7.794v-15a13.163 13.163 0 0 1 2.577-7.793 13.196 13.196 0 0 1 6.697-4.76c9.082-2.744 19.574-4.193 30.348-4.193 10.773 0 21.248 1.449 30.348 4.194a13.2 13.2 0 0 1 6.701 4.757 13.17 13.17 0 0 1 2.582 7.795v15a13.164 13.164 0 0 1-2.577 7.794 13.195 13.195 0 0 1-6.697 4.759c-9.109 2.727-19.597 4.193-30.357 4.193Z",
|
|
5894
|
+
fill: "#E6E6E6"
|
|
5895
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5896
|
+
d: "M71.426 79.868c4.624 0 8.373-6.58 8.373-14.696s-3.749-14.696-8.373-14.696c-4.624 0-8.372 6.58-8.372 14.696 0 8.117 3.748 14.697 8.372 14.697Z",
|
|
5897
|
+
fill: "#1A1A1A"
|
|
5898
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5899
|
+
d: "M72.894 65.765c1.863 0 3.373-2.217 3.373-4.95 0-2.735-1.51-4.952-3.373-4.952-1.864 0-3.375 2.217-3.375 4.951 0 2.734 1.511 4.95 3.374 4.95Z",
|
|
5900
|
+
fill: "#fff"
|
|
5901
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5902
|
+
d: "M116.517 79.868c4.624 0 8.373-6.58 8.373-14.696s-3.749-14.696-8.373-14.696c-4.624 0-8.372 6.58-8.372 14.696 0 8.117 3.748 14.697 8.372 14.697Z",
|
|
5903
|
+
fill: "#1A1A1A"
|
|
5904
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5905
|
+
d: "M117.981 65.765c1.864 0 3.374-2.217 3.374-4.95 0-2.735-1.51-4.952-3.374-4.952-1.863 0-3.374 2.217-3.374 4.951 0 2.734 1.511 4.95 3.374 4.95Z",
|
|
5906
|
+
fill: "#fff"
|
|
5907
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5908
|
+
d: "M100.012 80.196a14.156 14.156 0 0 0-2.785-1.159 10.598 10.598 0 0 0-5.713 0 14.09 14.09 0 0 0-2.78 1.159h-.027a.773.773 0 0 1-.973-1.159 8.74 8.74 0 0 1 6.639-3.049 8.754 8.754 0 0 1 6.638 3.05.773.773 0 0 1-.977 1.158h-.022Z",
|
|
5909
|
+
fill: "#999"
|
|
5910
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5911
|
+
d: "M44.788 67.69c.853 0 1.545-1.731 1.545-3.867 0-2.137-.692-3.868-1.545-3.868-.852 0-1.544 1.731-1.544 3.867 0 2.137.691 3.868 1.544 3.868Zm99.38 0c.853 0 1.544-1.731 1.544-3.867 0-2.137-.691-3.868-1.544-3.868-.853 0-1.544 1.731-1.544 3.867 0 2.137.691 3.868 1.544 3.868Z",
|
|
5912
|
+
fill: "#4BAAF7"
|
|
5913
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5914
|
+
d: "M79.596 106.857s-13.835 0-13.835-18.752",
|
|
5915
|
+
strokeWidth: "13.63",
|
|
5916
|
+
strokeMiterlimit: "10",
|
|
5917
|
+
strokeLinecap: "round",
|
|
5918
|
+
stroke: "#4D4D4D"
|
|
5919
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5920
|
+
d: "M79.295 99.708h-.004a2.453 2.453 0 0 0-2.34 2.56l.353 7.781a2.453 2.453 0 0 0 2.564 2.337h.004a2.452 2.452 0 0 0 2.34-2.559l-.353-7.782a2.453 2.453 0 0 0-2.564-2.337Z",
|
|
5921
|
+
fill: "gray"
|
|
5922
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5923
|
+
d: "M109.137 104.385s3.851 3.681 10.947-1.181",
|
|
5924
|
+
strokeWidth: "13.63",
|
|
5925
|
+
strokeMiterlimit: "10",
|
|
5926
|
+
strokeLinecap: "round",
|
|
5927
|
+
stroke: "#4D4D4D"
|
|
5928
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5929
|
+
d: "m107.907 112.125.004.001a2.455 2.455 0 0 0 2.859-1.966l1.414-7.661a2.451 2.451 0 0 0-1.97-2.854h-.004a2.455 2.455 0 0 0-2.859 1.965l-1.413 7.661a2.45 2.45 0 0 0 1.969 2.854Z",
|
|
5930
|
+
fill: "gray"
|
|
5931
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5932
|
+
d: "M89.494 121.176s-4.44 8.569-3.936 13.934",
|
|
5933
|
+
strokeWidth: "13.63",
|
|
5934
|
+
strokeMiterlimit: "10",
|
|
5935
|
+
strokeLinecap: "round",
|
|
5936
|
+
stroke: "#4D4D4D"
|
|
5937
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5938
|
+
d: "M88.59 128.571c3.535 0 6.4-2.861 6.4-6.39a6.395 6.395 0 0 0-6.4-6.39 6.395 6.395 0 0 0-6.4 6.39 6.395 6.395 0 0 0 6.4 6.39Z",
|
|
5939
|
+
fill: "gray"
|
|
5940
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5941
|
+
d: "M76.233 146.043h12.585v3.966a1.205 1.205 0 0 1-1.205 1.204H74.068a1.205 1.205 0 0 1-1.205-1.204v-.601a3.367 3.367 0 0 1 .989-2.378 3.38 3.38 0 0 1 2.38-.987Z",
|
|
5942
|
+
fill: "#333"
|
|
5943
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5944
|
+
d: "M85.808 149.557s8.631.125 6.752-8.774c-1.878-8.899-13-16.291-16.263-6.434-3.262 9.857-1.499 16.166 9.511 15.208Z",
|
|
5945
|
+
fill: "#F2F2F2"
|
|
5946
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5947
|
+
d: "M100.159 121.176s4.463 8.569 3.937 13.934",
|
|
5948
|
+
strokeWidth: "13.63",
|
|
5949
|
+
strokeMiterlimit: "10",
|
|
5950
|
+
strokeLinecap: "round",
|
|
5951
|
+
stroke: "#4D4D4D"
|
|
5952
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5953
|
+
d: "M101.064 128.571c3.534 0 6.4-2.861 6.4-6.39 0-3.529-2.866-6.39-6.4-6.39a6.395 6.395 0 0 0-6.4 6.39 6.395 6.395 0 0 0 6.4 6.39Z",
|
|
5954
|
+
fill: "gray"
|
|
5955
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5956
|
+
d: "M115.584 151.216h-13.545a1.206 1.206 0 0 1-1.205-1.203v-3.98h12.586a3.37 3.37 0 0 1 3.374 3.369v.602a1.21 1.21 0 0 1-.745 1.121 1.23 1.23 0 0 1-.465.091Z",
|
|
5957
|
+
fill: "#333"
|
|
5958
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5959
|
+
d: "M103.838 149.557s-8.632.125-6.757-8.774c1.874-8.899 13.036-16.291 16.285-6.434 3.249 9.857 1.5 16.166-9.528 15.208Zm6.725-40.315c-.549-9.652-7.975-12.415-16.91-11.907-8.935.508-16.004 4.091-15.455 13.748.549 9.656 8.243 17.067 17.178 16.559 8.935-.508 15.736-8.743 15.187-18.4Z",
|
|
5960
|
+
fill: "#F2F2F2"
|
|
5961
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5962
|
+
d: "M110.402 107.707c-1.129 7.958-7.271 14.228-15.027 14.665-8.39.477-15.683-6.034-16.995-14.821a15.77 15.77 0 0 0-.183 3.533c.549 9.652 8.239 17.067 17.178 16.559 8.939-.508 15.736-8.742 15.174-18.399a14.03 14.03 0 0 0-.147-1.537Z",
|
|
5963
|
+
fill: "#E6E6E6"
|
|
5964
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5965
|
+
d: "M100.76 105.262H88a.66.66 0 0 0-.66.66v1.871c0 .365.296.66.66.66h12.76a.66.66 0 0 0 .66-.66v-1.871a.66.66 0 0 0-.66-.66Zm0 5.512H88a.66.66 0 0 0-.66.66v1.871c0 .364.296.66.66.66h12.76a.66.66 0 0 0 .66-.66v-1.871a.66.66 0 0 0-.66-.66Zm0 5.505H88a.66.66 0 0 0-.66.66v1.871c0 .364.296.66.66.66h12.76a.66.66 0 0 0 .66-.66v-1.871a.66.66 0 0 0-.66-.66Z",
|
|
5966
|
+
fill: "#3690EA"
|
|
5967
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5968
|
+
d: "M133.43 107.146c5.688-4.463 7.529-11.6 4.111-15.943-3.417-4.343-10.799-4.245-16.487.218-5.688 4.463-7.529 11.601-4.111 15.943 3.417 4.343 10.799 4.245 16.487-.218Z",
|
|
5969
|
+
fill: "#F2F2F2"
|
|
5970
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5971
|
+
d: "M136.74 95.34c-3.418-4.344-10.8-4.246-16.486.22a15.744 15.744 0 0 0-5.034 6.683c-.031-3.725 2.035-7.87 5.802-10.837 5.69-4.456 13.072-4.559 16.491-.218 1.972 2.508 2.182 5.953.919 9.273a8.246 8.246 0 0 0-1.692-5.12Z",
|
|
5972
|
+
fill: "#E6E6E6"
|
|
5973
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5974
|
+
d: "M127.405 89.78c1.87.546 3.824.751 5.766.605v0a16.153 16.153 0 0 0 9.056-3.631",
|
|
5975
|
+
strokeWidth: "13.63",
|
|
5976
|
+
strokeMiterlimit: "10",
|
|
5977
|
+
strokeLinecap: "round",
|
|
5978
|
+
stroke: "#333"
|
|
5979
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5980
|
+
d: "M79.875 85.766c2.25-7.476-.567-14.93-6.293-16.649-5.727-1.718-12.194 2.949-14.444 10.425-2.251 7.476.567 14.93 6.293 16.648 5.727 1.719 12.194-2.948 14.444-10.424Z",
|
|
5981
|
+
fill: "#F2F2F2"
|
|
5982
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5983
|
+
d: "M69.713 71.558c5.726 1.72 8.542 9.175 6.293 16.652a16.978 16.978 0 0 1-4.74 7.687c3.767-1.435 7.141-5.151 8.627-10.12 2.232-7.477-.567-14.932-6.293-16.648-3.311-.993-6.863.152-9.706 2.736 1.85-.75 3.9-.858 5.82-.307Z",
|
|
5984
|
+
fill: "#E6E6E6"
|
|
5985
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5986
|
+
d: "M77.006 68.04a6.195 6.195 0 0 1-4.269-1.866 6.176 6.176 0 0 1 0-8.623 6.195 6.195 0 0 1 4.27-1.867",
|
|
5987
|
+
strokeWidth: "13.63",
|
|
5988
|
+
strokeMiterlimit: "10",
|
|
5989
|
+
strokeLinecap: "round",
|
|
5990
|
+
stroke: "#333"
|
|
5991
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5992
|
+
d: "M81.567 54.262c-.103.03-.205.07-.303.106l-.304.112-.303.111-.3.112-.303.111c-.103.031-.2.071-.303.111-.103.04-.201.072-.304.108l-.299.11-.303.112-.304.112c-.102.03-.2.071-.303.111l-.3.107-.303.111-.303.112-.304.111c-.098.031-.2.072-.299.112-.098.04-.205.07-.303.111-.099.04-.201.071-.304.107l-.299.111-.303.112a5.63 5.63 0 0 0-3.824 4.578 5.62 5.62 0 0 0 1.101 4.178 5.578 5.578 0 0 0 2.754 1.956l.303.112.304.111.308.112.303.11.304.112.303.112.304.111.303.112.308.111.304.111.303.112.304.111c.102.036.2.076.303.107l.308.116c.098.036.2.076.303.107.103.031.201.08.304.111.103.031.2.08.303.112.103.03.201.08.304.111.103.031.2.08.303.111.103.032.206.08.308.112a8.12 8.12 0 0 0 10.027-3.863 8.087 8.087 0 0 0-2.619-10.407 8.117 8.117 0 0 0-7.479-.88v.004Z",
|
|
5993
|
+
fill: "#2278D6"
|
|
5994
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5995
|
+
d: "M97.105 47.237c-.192.062-.389.138-.58.21-.193.07-.393.142-.585.213-.192.072-.389.138-.585.214-.196.076-.388.138-.58.214-.192.076-.393.138-.585.214-.192.076-.388.138-.584.214-.197.076-.389.138-.585.214-.197.075-.388.138-.58.214-.192.075-.389.138-.585.213-.196.076-.388.139-.585.21-.196.071-.388.143-.58.214-.192.071-.392.138-.584.214-.192.075-.389.138-.585.214-.196.075-.388.138-.585.213-.196.076-.388.139-.58.214-.192.076-.393.139-.585.214-.191.076-.388.138-.584.214-.197.076-.389.138-.585.214-.196.076-.388.134-.58.21-.192.075-.388.138-.585.213a10.762 10.762 0 0 0-3.146 1.65 10.844 10.844 0 0 0-1.674 15.763 10.879 10.879 0 0 0 4.883 3.233c.196.075.388.151.589.213.2.063.388.152.585.214.196.063.392.152.589.219.196.067.388.147.584.214l.59.213c.196.076.388.152.589.214.2.063.388.152.584.214.197.063.388.152.59.214.2.063.388.152.584.219.196.066.388.147.59.213.2.067.387.148.584.214.196.067.388.147.589.214.2.067.388.152.584.214.197.063.393.152.59.214.196.062.388.151.584.218l.59.214c.196.072.388.147.584.214.196.067.393.147.59.214.196.067.387.151.588.214.201.062.388.151.585.214a15.669 15.669 0 0 0 14.439-1.806 15.624 15.624 0 0 0 6.706-12.895 15.597 15.597 0 0 0-1.829-7.256 15.659 15.659 0 0 0-19.454-7.244Z",
|
|
5996
|
+
fill: "#3690EA"
|
|
5997
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
5998
|
+
d: "M119.065 37.388a25.93 25.93 0 0 0-.978.356c-.326.125-.651.232-.977.357-.326.125-.652.232-.978.356-.325.125-.651.232-.977.361-.326.13-.652.232-.977.357-.326.125-.652.232-.978.356-.326.125-.656.232-.977.357-.322.125-.656.232-.978.36-.321.13-.651.228-.977.357-.326.13-.656.232-.977.357-.322.124-.656.231-.978.356-.321.125-.656.232-.977.357-.321.125-.656.231-.977.36-.322.13-.657.228-.978.357-.321.13-.656.232-.977.357-.322.124-.656.231-.978.356-.321.125-.656.232-.982.361-.325.13-.651.227-.977.357-.326.129-.651.227-.973.356-.321.13-.656.232-.982.357a18.217 18.217 0 0 0-7.281 4.523A18.158 18.158 0 0 0 90.716 72.8a18.097 18.097 0 0 0 8.926 6.314c.326.13.651.254.986.361.335.107.652.254.982.361.33.107.652.25.986.36.335.112.647.25.982.357.335.107.652.254.982.361.33.107.652.25.986.361.335.112.652.25.982.357.33.107.652.254.986.36.335.108.648.25.982.362.335.111.652.25.982.356.33.107.652.254.986.361.335.107.652.25.982.361.331.111.652.25.982.357.33.106.656.253.986.36.331.107.652.254.982.361.331.107.652.25.987.361.334.112.651.25.981.357.331.107.652.254.987.36.334.108.647.25.982.362.334.111.651.25.981.356a26.26 26.26 0 0 0 24.2-3.02 26.2 26.2 0 0 0 8.29-9.42 26.147 26.147 0 0 0-.114-24.35 26.194 26.194 0 0 0-8.377-9.343 26.244 26.244 0 0 0-24.226-2.795l-.022.009Z",
|
|
5999
|
+
fill: "#50B0FF"
|
|
6000
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
6001
|
+
d: "M128.994 80.692a18.926 18.926 0 0 1-11.736-4.091 18.853 18.853 0 0 1-5.352-22.825 18.889 18.889 0 0 1 8.696-8.867 18.93 18.93 0 0 1 22.967 4.864 18.856 18.856 0 0 1 .514 23.437 18.738 18.738 0 0 1-6.655 5.529 18.772 18.772 0 0 1-8.434 1.953Z",
|
|
6002
|
+
fill: "#D6DEE5"
|
|
6003
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
6004
|
+
d: "M129.021 45.14a16.719 16.719 0 0 1 10.373 3.604 16.67 16.67 0 0 1 5.887 9.258 16.65 16.65 0 0 1-1.144 10.906 16.687 16.687 0 0 1-7.681 7.838 16.724 16.724 0 0 1-10.896 1.38 16.704 16.704 0 0 1-9.398-5.675 16.657 16.657 0 0 1-.449-20.708 16.64 16.64 0 0 1 13.322-6.604h-.014Zm.014-4.417a21.143 21.143 0 0 0-13.684 5.01 21.066 21.066 0 0 0-4.43 26.958 21.12 21.12 0 0 0 11.363 9.113 21.153 21.153 0 0 0 14.569-.404 21.113 21.113 0 0 0 10.84-9.728 21.063 21.063 0 0 0 1.948-14.422 21.086 21.086 0 0 0-7.869-12.249 20.973 20.973 0 0 0-12.737-4.278Z",
|
|
6005
|
+
fill: "#1B64CE"
|
|
6006
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
6007
|
+
d: "M131.495 67.397c4.287 0 7.762-3.47 7.762-7.749 0-4.28-3.475-7.75-7.762-7.75-4.286 0-7.761 3.47-7.761 7.75 0 4.28 3.475 7.75 7.761 7.75Z",
|
|
6008
|
+
fill: "#fff"
|
|
6009
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
6010
|
+
d: "M137.039 56.638a3.996 3.996 0 0 0 3.999-3.993 3.996 3.996 0 0 0-3.999-3.992 3.996 3.996 0 0 0-3.999 3.992 3.996 3.996 0 0 0 3.999 3.993Z",
|
|
6011
|
+
fill: "#fff"
|
|
6012
|
+
}), /*#__PURE__*/React__default.createElement("mask", {
|
|
6013
|
+
id: `${id}-a`,
|
|
6014
|
+
style: {
|
|
6015
|
+
maskType: "alpha"
|
|
6016
|
+
},
|
|
6017
|
+
maskUnits: "userSpaceOnUse",
|
|
6018
|
+
x: "90",
|
|
6019
|
+
y: "96",
|
|
6020
|
+
width: "9",
|
|
6021
|
+
height: "4"
|
|
6022
|
+
}, /*#__PURE__*/React__default.createElement("path", {
|
|
6023
|
+
d: "M94.651 96.461c-1.785 0-3.26-.038-3.78-.038v2.897h7.14v-2.897c-.371 0-1.574.038-3.36.038Z",
|
|
6024
|
+
fill: "#000"
|
|
6025
|
+
})), /*#__PURE__*/React__default.createElement("g", {
|
|
6026
|
+
mask: `url(#${id}-a)`
|
|
6027
|
+
}, /*#__PURE__*/React__default.createElement("path", {
|
|
6028
|
+
d: "M94.51 95.545c-1.732.049-3.124.25-3.124.494v2.617c0 .245 1.392.446 3.124.495 1.731.049 3.124-.138 3.124-.384v-2.839c0-.245-1.393-.432-3.124-.383Z",
|
|
6029
|
+
fill: "#999"
|
|
6030
|
+
})));
|
|
6031
|
+
}
|
|
6032
|
+
|
|
6033
|
+
var styles$b = {"spinner":"spinner-b5tlz"};
|
|
6034
|
+
|
|
6035
|
+
function LoadingSpinner({
|
|
6036
|
+
size = 48,
|
|
6037
|
+
trackWidth = 6
|
|
6038
|
+
}) {
|
|
6039
|
+
return /*#__PURE__*/React__default.createElement("span", {
|
|
6040
|
+
"aria-hidden": "true",
|
|
6041
|
+
className: styles$b.spinner,
|
|
6042
|
+
style: {
|
|
6043
|
+
"--spinner-size": `${size}px`,
|
|
6044
|
+
"--spinner-track-width": `${trackWidth}px`
|
|
6045
|
+
}
|
|
6046
|
+
});
|
|
6047
|
+
}
|
|
4347
6048
|
|
|
4348
6049
|
function SearchResults({
|
|
4349
6050
|
label,
|
|
@@ -4364,18 +6065,36 @@ function SearchResults({
|
|
|
4364
6065
|
...navigation
|
|
4365
6066
|
});
|
|
4366
6067
|
}
|
|
4367
|
-
return /*#__PURE__*/React__default.createElement(
|
|
4368
|
-
role: "status"
|
|
4369
|
-
|
|
6068
|
+
return /*#__PURE__*/React__default.createElement(Flex, {
|
|
6069
|
+
role: "status",
|
|
6070
|
+
justify: "center",
|
|
6071
|
+
align: "center",
|
|
6072
|
+
gap: 2,
|
|
6073
|
+
direction: "column",
|
|
6074
|
+
style: {
|
|
6075
|
+
color: "var(--t-text-color-placeholder)",
|
|
6076
|
+
fontSize: "var(--t-font-size-md)",
|
|
6077
|
+
marginTop: 48
|
|
6078
|
+
}
|
|
6079
|
+
}, /*#__PURE__*/React__default.createElement(LoadingSpinner, {
|
|
6080
|
+
size: 40,
|
|
6081
|
+
trackWidth: 5
|
|
6082
|
+
}), "Searching\u2026");
|
|
4370
6083
|
case "error":
|
|
4371
|
-
return /*#__PURE__*/React__default.createElement(
|
|
4372
|
-
|
|
4373
|
-
|
|
6084
|
+
return /*#__PURE__*/React__default.createElement(BlankState$1, {
|
|
6085
|
+
image: /*#__PURE__*/React__default.createElement(BlankStateError, null),
|
|
6086
|
+
role: "alert",
|
|
6087
|
+
subtitle: "Try again in a moment.",
|
|
6088
|
+
title: "Search isn\u2019t working right now"
|
|
6089
|
+
});
|
|
4374
6090
|
case "done":
|
|
4375
6091
|
if (sections.length === 0) {
|
|
4376
|
-
|
|
4377
|
-
|
|
4378
|
-
|
|
6092
|
+
// The panel's result count announces this, so it isn't read twice.
|
|
6093
|
+
return /*#__PURE__*/React__default.createElement(BlankState$1, {
|
|
6094
|
+
image: /*#__PURE__*/React__default.createElement(BlankStateNoResults, null),
|
|
6095
|
+
subtitle: "Clear search and try again.",
|
|
6096
|
+
title: `No results for “${term.trim()}”`
|
|
6097
|
+
});
|
|
4379
6098
|
}
|
|
4380
6099
|
return /*#__PURE__*/React__default.createElement(ResultListbox, {
|
|
4381
6100
|
busy: false,
|
|
@@ -4390,31 +6109,43 @@ function SearchResults({
|
|
|
4390
6109
|
// stays put as more recents load and as their lookups answer.
|
|
4391
6110
|
const RECENTS = "recents";
|
|
4392
6111
|
function SearchPanel({
|
|
6112
|
+
appName,
|
|
6113
|
+
mobile = false,
|
|
4393
6114
|
env,
|
|
6115
|
+
onClose,
|
|
6116
|
+
onOpenResult,
|
|
4394
6117
|
products
|
|
4395
6118
|
}) {
|
|
4396
6119
|
var _a, _b;
|
|
4397
6120
|
const listboxId = useInstanceId("product-search-results");
|
|
4398
6121
|
const [term, setTerm] = React__default.useState("");
|
|
4399
|
-
const [selectedSlug, setSelectedSlug] = React__default.useState(() =>
|
|
6122
|
+
const [selectedSlug, setSelectedSlug] = React__default.useState(() => defaultProduct(products, appName).slug);
|
|
4400
6123
|
const product = (_a = products.find(({
|
|
4401
6124
|
slug
|
|
4402
6125
|
}) => slug === selectedSlug)) !== null && _a !== void 0 ? _a : products[0];
|
|
4403
6126
|
const hasTerm = term.trim() !== "";
|
|
4404
6127
|
const search = useProductSearch(product.slug, term);
|
|
4405
6128
|
const groups = "groups" in search ? search.groups : undefined;
|
|
4406
|
-
const
|
|
6129
|
+
const {
|
|
6130
|
+
organizationTimeZone
|
|
6131
|
+
} = useStore();
|
|
6132
|
+
const sections = React__default.useMemo(() => groupSections(groups, organizationTimeZone), [groups, organizationTimeZone]);
|
|
4407
6133
|
const {
|
|
4408
6134
|
visits,
|
|
4409
6135
|
...recents
|
|
4410
6136
|
} = useRecentVisits(env);
|
|
4411
|
-
const recentItems = visits.map(visitItem);
|
|
6137
|
+
const recentItems = visits.map(visit => visitItem(visit, organizationTimeZone));
|
|
4412
6138
|
const items = hasTerm ? sections.flatMap(section => section.items) : recentItems;
|
|
4413
|
-
|
|
6139
|
+
// Phones open results by tapping them, with no highlight to arrow through.
|
|
6140
|
+
// A narrow window with a keyboard and mouse keeps both, as does the desktop
|
|
6141
|
+
// layout on a touch device, whose keyboard hints still advertise them.
|
|
6142
|
+
const touchOnly = useMediaQuery("(hover: none) and (pointer: coarse)");
|
|
6143
|
+
const navigation = useResultNavigation(items, hasTerm ? sections : RECENTS, !(mobile && touchOnly));
|
|
4414
6144
|
const {
|
|
4415
6145
|
highlightedIndex
|
|
4416
6146
|
} = navigation;
|
|
4417
6147
|
const inputRef = React__default.useRef(null);
|
|
6148
|
+
const resultCount = useAnnouncement(hasTerm && search.status === "done" ? `${items.length === 0 ? "No results" : `${items.length} ${items.length === 1 ? "result" : "results"}`} for “${term.trim()}” in ${product.appName}` : null);
|
|
4418
6149
|
const [announceHighlight, setAnnounceHighlight] = React__default.useState(false);
|
|
4419
6150
|
// The tabs keep focus while arrowing through results, but only the focused
|
|
4420
6151
|
// input can point screen readers at the highlight, so from the tabs it's
|
|
@@ -4430,41 +6161,50 @@ function SearchPanel({
|
|
|
4430
6161
|
navigation.handleKeyDown(event);
|
|
4431
6162
|
}
|
|
4432
6163
|
};
|
|
4433
|
-
React__default.
|
|
4434
|
-
|
|
4435
|
-
|
|
6164
|
+
const results = hasTerm ? (/*#__PURE__*/React__default.createElement(SearchResults, {
|
|
6165
|
+
highlightedIndex: highlightedIndex,
|
|
6166
|
+
id: listboxId,
|
|
6167
|
+
label: `Results from Planning Center ${product.appName}`,
|
|
6168
|
+
onHighlight: navigation.highlightIndex,
|
|
6169
|
+
onOpen: onOpenResult,
|
|
6170
|
+
sections: sections,
|
|
6171
|
+
status: search.status,
|
|
6172
|
+
term: term
|
|
6173
|
+
})) : (/*#__PURE__*/React__default.createElement(RecentlyVisited, {
|
|
6174
|
+
highlightedIndex: highlightedIndex,
|
|
6175
|
+
id: listboxId,
|
|
6176
|
+
items: recentItems,
|
|
6177
|
+
onHighlight: navigation.highlightIndex,
|
|
6178
|
+
onOpen: onOpenResult,
|
|
6179
|
+
...recents
|
|
6180
|
+
}));
|
|
4436
6181
|
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(SearchInput, {
|
|
4437
6182
|
expanded: items.length > 0,
|
|
4438
6183
|
highlightedIndex: highlightedIndex,
|
|
4439
6184
|
inputRef: inputRef,
|
|
4440
6185
|
listboxId: listboxId,
|
|
4441
6186
|
onChange: setTerm,
|
|
6187
|
+
onClose: onClose,
|
|
4442
6188
|
onFocus: () => setAnnounceHighlight(false),
|
|
4443
6189
|
onKeyDown: navigation.handleKeyDown,
|
|
4444
6190
|
value: term
|
|
4445
|
-
}), /*#__PURE__*/React__default.createElement(
|
|
6191
|
+
}), mobile ? (/*#__PURE__*/React__default.createElement(ProductSelect, {
|
|
6192
|
+
onSelect: setSelectedSlug,
|
|
6193
|
+
products: products,
|
|
6194
|
+
selected: product
|
|
6195
|
+
}, results)) : (/*#__PURE__*/React__default.createElement(ProductTabs, {
|
|
4446
6196
|
onKeyDown: handleTabsKeyDown,
|
|
4447
6197
|
onSelect: setSelectedSlug,
|
|
4448
6198
|
products: products,
|
|
4449
6199
|
selected: product
|
|
4450
|
-
},
|
|
4451
|
-
highlightedIndex: highlightedIndex,
|
|
4452
|
-
id: listboxId,
|
|
4453
|
-
label: `${product.appName} results`,
|
|
4454
|
-
onHighlight: navigation.highlightIndex,
|
|
4455
|
-
sections: sections,
|
|
4456
|
-
status: search.status,
|
|
4457
|
-
term: term
|
|
4458
|
-
})) : (/*#__PURE__*/React__default.createElement(RecentlyVisited, {
|
|
4459
|
-
highlightedIndex: highlightedIndex,
|
|
4460
|
-
id: listboxId,
|
|
4461
|
-
items: recentItems,
|
|
4462
|
-
onHighlight: navigation.highlightIndex,
|
|
4463
|
-
...recents
|
|
4464
|
-
}))), /*#__PURE__*/React__default.createElement("div", {
|
|
6200
|
+
}, results)), /*#__PURE__*/React__default.createElement("div", {
|
|
4465
6201
|
"aria-live": "polite",
|
|
4466
|
-
className: styles$
|
|
4467
|
-
}, announceHighlight ? (_b = navigation.highlighted) === null || _b === void 0 ? void 0 : _b.title : null), /*#__PURE__*/React__default.createElement(
|
|
6202
|
+
className: styles$k.visuallyHidden
|
|
6203
|
+
}, announceHighlight ? (_b = navigation.highlighted) === null || _b === void 0 ? void 0 : _b.title : null), /*#__PURE__*/React__default.createElement("div", {
|
|
6204
|
+
"aria-live": "polite",
|
|
6205
|
+
className: styles$k.visuallyHidden,
|
|
6206
|
+
"data-testid": "result-count"
|
|
6207
|
+
}, resultCount), mobile ? null : /*#__PURE__*/React__default.createElement(KeyboardHints, {
|
|
4468
6208
|
copied: navigation.copied
|
|
4469
6209
|
}));
|
|
4470
6210
|
}
|
|
@@ -4535,32 +6275,6 @@ function useSearchShortcut(enabled, open, setOpen) {
|
|
|
4535
6275
|
}, [enabled, open, setOpen]);
|
|
4536
6276
|
}
|
|
4537
6277
|
|
|
4538
|
-
const SEARCHABLE_PRODUCTS = [{
|
|
4539
|
-
appName: "Calendar",
|
|
4540
|
-
slug: "calendar"
|
|
4541
|
-
}, {
|
|
4542
|
-
appName: "Check-Ins",
|
|
4543
|
-
slug: "check-ins"
|
|
4544
|
-
}, {
|
|
4545
|
-
appName: "Giving",
|
|
4546
|
-
slug: "giving"
|
|
4547
|
-
}, {
|
|
4548
|
-
appName: "Groups",
|
|
4549
|
-
slug: "groups"
|
|
4550
|
-
}, {
|
|
4551
|
-
appName: "People",
|
|
4552
|
-
slug: "people"
|
|
4553
|
-
}, {
|
|
4554
|
-
appName: "Publishing",
|
|
4555
|
-
slug: "publishing"
|
|
4556
|
-
}, {
|
|
4557
|
-
appName: "Registrations",
|
|
4558
|
-
slug: "registrations"
|
|
4559
|
-
}, {
|
|
4560
|
-
appName: "Services",
|
|
4561
|
-
slug: "services"
|
|
4562
|
-
}];
|
|
4563
|
-
|
|
4564
6278
|
const PERMISSION_CHECKS = {
|
|
4565
6279
|
"check-ins": () => fetchMe("check-ins", "permission").then(({
|
|
4566
6280
|
permission
|
|
@@ -4665,24 +6379,60 @@ function inSwitcherOrder(apps) {
|
|
|
4665
6379
|
return groupApps(apps).restProducts.flatMap(app => SEARCHABLE_PRODUCTS.filter(product => product.appName === app.name));
|
|
4666
6380
|
}
|
|
4667
6381
|
|
|
6382
|
+
/**
|
|
6383
|
+
* Writes the height of the visible part of the page to the parent of `ref`'s
|
|
6384
|
+
* element as `--visual-viewport-height`. It shrinks when an on-screen keyboard
|
|
6385
|
+
* opens; `100dvh` doesn't, since mobile Safari draws the keyboard over it.
|
|
6386
|
+
*/
|
|
6387
|
+
function useVisualViewportHeight(ref, enabled) {
|
|
6388
|
+
React__default.useEffect(() => {
|
|
6389
|
+
var _a;
|
|
6390
|
+
const viewport = window.visualViewport;
|
|
6391
|
+
const parent = (_a = ref.current) === null || _a === void 0 ? void 0 : _a.parentElement;
|
|
6392
|
+
if (!enabled || !viewport || !parent) return undefined;
|
|
6393
|
+
const update = () => parent.style.setProperty("--visual-viewport-height", `${viewport.height}px`);
|
|
6394
|
+
update();
|
|
6395
|
+
viewport.addEventListener("resize", update);
|
|
6396
|
+
return () => {
|
|
6397
|
+
viewport.removeEventListener("resize", update);
|
|
6398
|
+
parent.style.removeProperty("--visual-viewport-height");
|
|
6399
|
+
};
|
|
6400
|
+
}, [enabled, ref]);
|
|
6401
|
+
}
|
|
6402
|
+
|
|
4668
6403
|
function ProductSearch({
|
|
6404
|
+
appName,
|
|
4669
6405
|
apps,
|
|
6406
|
+
mobile = false,
|
|
4670
6407
|
env
|
|
4671
6408
|
}) {
|
|
4672
6409
|
const searchable = useSearchableProducts(apps);
|
|
4673
6410
|
const [open, setOpen] = React__default.useState(false);
|
|
6411
|
+
const modalRef = React__default.useRef(null);
|
|
6412
|
+
// Sizes Tapestry's modal frame, the dialog's parent, to fit above the keyboard.
|
|
6413
|
+
useVisualViewportHeight(modalRef, mobile && open);
|
|
4674
6414
|
const available = searchable.status === "done" && searchable.products.length > 0;
|
|
4675
6415
|
useSearchShortcut(available, open, setOpen);
|
|
4676
6416
|
if (!available) return null;
|
|
4677
6417
|
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(SearchButton, {
|
|
6418
|
+
mobile: mobile,
|
|
4678
6419
|
onClick: () => setOpen(true)
|
|
4679
6420
|
}), /*#__PURE__*/React__default.createElement(Modal, {
|
|
4680
6421
|
"aria-label": "Search",
|
|
6422
|
+
className: styles$k.modal,
|
|
4681
6423
|
dismissible: true,
|
|
6424
|
+
id: "product_search_modal",
|
|
4682
6425
|
onClose: () => setOpen(false),
|
|
4683
|
-
open: open
|
|
6426
|
+
open: open,
|
|
6427
|
+
ref: modalRef,
|
|
6428
|
+
size: "lg"
|
|
4684
6429
|
}, /*#__PURE__*/React__default.createElement(SearchPanel, {
|
|
6430
|
+
appName: appName,
|
|
6431
|
+
mobile: mobile,
|
|
4685
6432
|
env: env,
|
|
6433
|
+
// Phones have no Esc, so mobile search gets a close button.
|
|
6434
|
+
onClose: mobile ? () => setOpen(false) : undefined,
|
|
6435
|
+
onOpenResult: () => setOpen(false),
|
|
4686
6436
|
products: searchable.products
|
|
4687
6437
|
})));
|
|
4688
6438
|
}
|
|
@@ -4976,6 +6726,7 @@ const NotSmallTopbar = ({
|
|
|
4976
6726
|
margin: "auto"
|
|
4977
6727
|
}
|
|
4978
6728
|
}), !notificationsEnabled && notifications(), productSearchEnabled ? (/*#__PURE__*/React__default.createElement(ProductSearch, {
|
|
6729
|
+
appName: props.appName,
|
|
4979
6730
|
apps: props.apps,
|
|
4980
6731
|
env: props.env
|
|
4981
6732
|
})) : search({
|
|
@@ -32890,7 +34641,7 @@ ClientStorage.defaultProps = {
|
|
|
32890
34641
|
method: "localStorage"
|
|
32891
34642
|
};
|
|
32892
34643
|
|
|
32893
|
-
var styles$6 = {"appmenu-button":"appmenu-button-b0UvT","appmenu-layer":"appmenu-layer-0IQpN","appmenu-container":"appmenu-container-gackd","appmenu-scroll":"appmenu-scroll-mPSx0","appmenu-list":"appmenu-list-h7clX","appmenu-list-a":"appmenu-list-a-rGIQN","appmenu-list-a--top":"appmenu-list-a--top-RT-2F","appmenu-list-a--bottom":"appmenu-list-a--bottom-YDeBC","appmenu-close-button":"appmenu-close-button-vv9bV","current-route":"current-route-wpJgz","is-active":"is-active-wy8Bg","routes":"routes-Nmt1S","route":"route-kkknQ","profile-button":"profile-button-a2WO2"};
|
|
34644
|
+
var styles$6 = {"appmenu-button":"appmenu-button-b0UvT","appmenu-layer":"appmenu-layer-0IQpN","appmenu-container":"appmenu-container-gackd","appmenu-scroll":"appmenu-scroll-mPSx0","appmenu-list":"appmenu-list-h7clX","appmenu-list-a":"appmenu-list-a-rGIQN","appmenu-list-a--top":"appmenu-list-a--top-RT-2F","appmenu-list-a--bottom":"appmenu-list-a--bottom-YDeBC","appmenu-close-button":"appmenu-close-button-vv9bV","current-route":"current-route-wpJgz","actions":"actions-INQ7-","is-active":"is-active-wy8Bg","routes":"routes-Nmt1S","route":"route-kkknQ","profile-button":"profile-button-a2WO2"};
|
|
32894
34645
|
|
|
32895
34646
|
function AccountSettingsLink({
|
|
32896
34647
|
env
|
|
@@ -33110,7 +34861,14 @@ const SmallTopbar = ({
|
|
|
33110
34861
|
setProductSwitcherVisible(false);
|
|
33111
34862
|
setRoutesMenuVisible(visible => !visible);
|
|
33112
34863
|
} : null
|
|
33113
|
-
}, /*#__PURE__*/React__default.createElement(CurrentRouteComponent, null, capitalize$1(currentRouteText)), props.routes.length > 0 && /*#__PURE__*/React__default.createElement(DisclosureChevronIcon, null)), /*#__PURE__*/React__default.createElement("
|
|
34864
|
+
}, /*#__PURE__*/React__default.createElement(CurrentRouteComponent, null, capitalize$1(currentRouteText)), props.routes.length > 0 && /*#__PURE__*/React__default.createElement(DisclosureChevronIcon, null)), /*#__PURE__*/React__default.createElement("div", {
|
|
34865
|
+
className: styles$6["actions"]
|
|
34866
|
+
}, productSearchEnabled && (/*#__PURE__*/React__default.createElement(ProductSearch, {
|
|
34867
|
+
appName: props.appName,
|
|
34868
|
+
apps: props.apps,
|
|
34869
|
+
mobile: true,
|
|
34870
|
+
env: props.env
|
|
34871
|
+
})), /*#__PURE__*/React__default.createElement("button", {
|
|
33114
34872
|
type: "button",
|
|
33115
34873
|
className: styles$6["profile-button"],
|
|
33116
34874
|
onClick: () => {
|
|
@@ -33121,7 +34879,7 @@ const SmallTopbar = ({
|
|
|
33121
34879
|
}, /*#__PURE__*/React__default.createElement(Avatar, {
|
|
33122
34880
|
env: props.env,
|
|
33123
34881
|
url: props.userAvatarPath
|
|
33124
|
-
})));
|
|
34882
|
+
}))));
|
|
33125
34883
|
};
|
|
33126
34884
|
const SmallRoute = ({
|
|
33127
34885
|
active,
|
|
@@ -33611,38 +35369,6 @@ const SwitchView = ({
|
|
|
33611
35369
|
}));
|
|
33612
35370
|
};
|
|
33613
35371
|
|
|
33614
|
-
const collections = {
|
|
33615
|
-
general,
|
|
33616
|
-
toolbar
|
|
33617
|
-
};
|
|
33618
|
-
const paths = collections;
|
|
33619
|
-
function Icon({
|
|
33620
|
-
name,
|
|
33621
|
-
size = 16,
|
|
33622
|
-
style,
|
|
33623
|
-
theme,
|
|
33624
|
-
title,
|
|
33625
|
-
...props
|
|
33626
|
-
}) {
|
|
33627
|
-
const [collection, symbol] = name.split(".");
|
|
33628
|
-
return /*#__PURE__*/React__default.createElement("svg", {
|
|
33629
|
-
"aria-hidden": title ? undefined : true,
|
|
33630
|
-
fill: "currentColor",
|
|
33631
|
-
height: size,
|
|
33632
|
-
role: title ? "img" : undefined,
|
|
33633
|
-
style: {
|
|
33634
|
-
color: theme && `var(${theme})`,
|
|
33635
|
-
flexShrink: 0,
|
|
33636
|
-
...style
|
|
33637
|
-
},
|
|
33638
|
-
viewBox: "0 0 16 16",
|
|
33639
|
-
width: size,
|
|
33640
|
-
...props
|
|
33641
|
-
}, title && /*#__PURE__*/React__default.createElement("title", null, title), /*#__PURE__*/React__default.createElement("path", {
|
|
33642
|
-
d: paths[collection][symbol]
|
|
33643
|
-
}));
|
|
33644
|
-
}
|
|
33645
|
-
|
|
33646
35372
|
var styles$3 = {"color-mode-switcher":"color-mode-switcher-JpczO","color-mode-switcher-label":"color-mode-switcher-label-3jPM2","color-mode-switcher-modes":"color-mode-switcher-modes-u-bic"};
|
|
33647
35373
|
|
|
33648
35374
|
const COLOR_MODES = [{
|
|
@@ -34855,9 +36581,9 @@ function HelpdeskComponent({
|
|
|
34855
36581
|
const Helpdesk = {
|
|
34856
36582
|
component: HelpdeskComponent,
|
|
34857
36583
|
icons: {
|
|
34858
|
-
|
|
34859
|
-
staticPath: "M16 10C14.9391 10 13.9217 10.4214 13.1716 11.1716C12.4214 11.9217 12 12.9391 12 14H14C14 13.4696 14.2107 12.9609 14.5858 12.5858C14.9609 12.2107 15.4696 12 16 12C16.5304 12 17.0391 12.2107 17.4142 12.5858C17.7893 12.9609 18 13.4696 18 14C18 16 15 15.75 15 19H17C17 16.75 20 16.5 20 14C20 12.9391 19.5786 11.9217 18.8284 11.1716C18.0783 10.4214 17.0609 10 16 10ZM16 24C14.4178 24 12.871 23.5308 11.5554 22.6518C10.2399 21.7727 9.21447 20.5233 8.60897 19.0615C8.00347 17.5997 7.84504 15.9911 8.15372 14.4393C8.4624 12.8874 9.22433 11.462 10.3432 10.3431C11.462 9.22433 12.8874 8.4624 14.4393 8.15372C15.9911 7.84504 17.5997 8.00346 19.0615 8.60896C20.5233 9.21446 21.7727 10.2398 22.6518 11.5554C23.5308 12.871 24 14.4177 24 16C23.9974 18.1209 23.1537 20.1542 21.6539 21.6539C20.1542 23.1537 18.1209 23.9974 16 24ZM16 6C14.0222 6 12.0888 6.58649 10.4443 7.6853C8.79981 8.78412 7.51809 10.3459 6.76121 12.1732C6.00433 14.0004 5.8063 16.0111 6.19215 17.9509C6.578 19.8907 7.53041 21.6725 8.92894 23.0711C10.3275 24.4696 12.1093 25.422 14.0491 25.8079C15.9889 26.1937 17.9996 25.9957 19.8268 25.2388C21.6541 24.4819 23.2159 23.2002 24.3147 21.5557C25.4135 19.9112 26 17.9778 26 16C26 13.3478 24.9464 10.8043 23.0711 8.92893C21.1957 7.05357 18.6522 6 16 6V6ZM15 22H17V20H15V22Z"
|
|
36584
|
+
path: "M16.9997 19.9977v1.9992h-1.9975v-1.9992z m-0.9987-9.9937c1.0595 0.0001 2.0774 0.4207 2.8266 1.1699 0.7492 0.7508 1.1698 1.7671 1.17 2.8266 0 2.4989-2.9979 2.7488-2.9979 4.9969h-1.9975c0-3.2467 2.9978-2.9981 2.9978-4.9969-0.0001-0.5289-0.2112-1.0388-0.5857-1.4133-0.3746-0.3746-0.8828-0.5856-1.4133-0.5857-0.5304 0-1.0387 0.2114-1.4134 0.5857-0.3746 0.3746-0.5856 0.8844-0.5857 1.4133h-1.9991c0.0001-1.0595 0.4222-2.0758 1.1715-2.8266 0.7493-0.7491 1.7672-1.1699 2.8267-1.1699z m0-3.9966c2.6499 0.0001 5.1917 1.0523 7.0651 2.9271 1.8748 1.8733 2.927 4.4151 2.9271 7.0651 0 1.9762-0.5853 3.9094-1.6835 5.5528-1.0983 1.6418-2.6583 2.9236-4.485 3.6794-1.8249 0.7574-3.835 0.9542-5.7726 0.5684-1.9392-0.3859-3.7204-1.3366-5.1178-2.734-1.3974-1.3974-2.3496-3.1785-2.7355-5.1178-0.3858-1.9376-0.1873-3.9477 0.57-5.7726 0.7558-1.8267 2.0375-3.3867 3.6809-4.485 1.6418-1.0982 3.575-1.6834 5.5513-1.6834z m3.059 2.6068c-1.4616-0.6045-3.07-0.7641-4.62-0.4554-1.5499 0.3088-2.9749 1.07-4.0923 2.1891-1.119 1.1175-1.8788 2.5424-2.1876 4.0923-0.3087 1.5501-0.1508 3.1583 0.4539 4.62 0.6045 1.4598 1.6294 2.7072 2.9444 3.5868 1.3154 0.878 2.8618 1.3458 4.4426 1.3458 2.1192-0.0018 4.1516-0.846 5.6486-2.3446 1.4985-1.4971 2.3429-3.5294 2.3445-5.6486 0-1.5806-0.4679-3.1257-1.3458-4.441-0.8796-1.3154-2.1283-2.3398-3.5883-2.9444z"
|
|
34860
36585
|
},
|
|
36586
|
+
label: "Help and Support",
|
|
34861
36587
|
name: "Helpdesk",
|
|
34862
36588
|
storageExemptPaths: ["email", "phone"]
|
|
34863
36589
|
};
|
|
@@ -35130,13 +36856,15 @@ const useNotifications = ({
|
|
|
35130
36856
|
return notification.data;
|
|
35131
36857
|
}
|
|
35132
36858
|
};
|
|
35133
|
-
const updateStateFromJoltMessage = React__default.useCallback(message => {
|
|
36859
|
+
const updateStateFromJoltMessage = React__default.useCallback(async message => {
|
|
35134
36860
|
try {
|
|
35135
36861
|
const joltMessageNotificationDataPayload = extractPayloadFromJoltMessage(message);
|
|
35136
|
-
fetchNotification(joltMessageNotificationDataPayload.data.id)
|
|
35137
|
-
|
|
35138
|
-
|
|
35139
|
-
}
|
|
36862
|
+
const resp = await fetchNotification(joltMessageNotificationDataPayload.data.id);
|
|
36863
|
+
if (!(resp === null || resp === void 0 ? void 0 : resp.data)) {
|
|
36864
|
+
return;
|
|
36865
|
+
}
|
|
36866
|
+
const notification = buildNotificationFromApiResponse(resp.data, resp);
|
|
36867
|
+
setNotifications(notifications => [...notifications.filter(candidate => candidate.id !== notification.id), notification]);
|
|
35140
36868
|
} catch (exception) {
|
|
35141
36869
|
console.error("topbar encountered error when updating state from jolt message", exception);
|
|
35142
36870
|
}
|
|
@@ -35389,13 +37117,12 @@ function NotificationsComponent({
|
|
|
35389
37117
|
const Notifications = {
|
|
35390
37118
|
component: NotificationsComponent,
|
|
35391
37119
|
icons: {
|
|
35392
|
-
|
|
35393
|
-
staticPath: "M16.0003 6C12.4122 6 9.50357 8.90867 9.50357 12.4967V16.5862L6.54499 19.7387C5.34665 21.0156 6.25199 23.1069 8.00314 23.1069H13.335C13.7864 24.1303 14.81 24.8438 16.0001 24.8438C17.1902 24.8438 18.2138 24.1303 18.6653 23.1069H23.9973C25.7484 23.1069 26.6538 21.0156 25.4554 19.7387L22.497 16.5863V12.4967C22.497 8.90867 19.5883 6 16.0003 6ZM11.5036 12.4967C11.5036 10.0132 13.5168 8 16.0003 8C18.4837 8 20.497 10.0132 20.497 12.4967V16.9821V17.3778L20.7678 17.6664L23.9843 21.0938H8.01612L11.2327 17.6663L11.5036 17.3777V16.982V12.4967ZM8.00474 21.1059L8.00378 21.1069H8.00474V21.1059ZM23.9952 21.1069H23.9966L23.9952 21.1053V21.1069Z"
|
|
37120
|
+
path: "M15.9991 6.0078c1.8733 0.0145 3.6659 0.7729 4.9811 2.1075 1.3154 1.3346 2.0464 3.1362 2.0353 5.011v4.4975l2.5078 2.9931c0.2489 0.2923 0.407 0.6509 0.4586 1.0318 0.0515 0.3809-0.0072 0.7691-0.1711 1.118-0.1528 0.3473-0.4041 0.6421-0.7225 0.8496-0.3182 0.2073-0.69 0.3173-1.0693 0.3156h-4.9781c-0.2428 0.6075-0.6612 1.13-1.2029 1.4981-0.5435 0.3666-1.1828 0.5622-1.8389 0.5622-0.6542 0-1.294-0.1957-1.8357-0.5622-0.4742-0.3221-0.8546-0.7629-1.104-1.275l-0.0989-0.2231h-4.9765c-0.3794 0.0032-0.7527-0.1068-1.071-0.314-0.32-0.2074-0.5712-0.5038-0.7239-0.8512-0.1623-0.3489-0.2226-0.7386-0.1712-1.1196 0.0515-0.3808 0.2111-0.7392 0.4585-1.0318l2.5095-2.9915v-4.4975c-0.0111-1.8733 0.7199-3.6764 2.0352-5.011 1.3136-1.3344 3.105-2.0912 4.978-2.1075z m-0.0047 1.9755c-0.6751 0.0001-1.344 0.1338-1.9677 0.3926-0.6239 0.2589-1.1901 0.6374-1.6677 1.115-0.4776 0.4776-0.8561 1.0438-1.1149 1.6677-0.2587 0.6237-0.3894 1.2926-0.3895 1.9677v4.8351c0 0.2395-0.0844 0.4731-0.2387 0.658l-2.712 3.2475 0.0801 0.1476h16.035l0.0768-0.1507-2.7213-3.246c-0.1544-0.1849-0.2388-0.4184-0.2388-0.6595v-4.832c0-0.6752-0.1338-1.3439-0.3925-1.9677-0.2573-0.6238-0.636-1.1902-1.1134-1.6677-0.4775-0.4775-1.0439-0.8561-1.6677-1.115-0.6239-0.2589-1.2939-0.3926-1.9677-0.3926z"
|
|
35394
37121
|
},
|
|
35395
37122
|
name: "Notifications"
|
|
35396
37123
|
};
|
|
35397
37124
|
|
|
35398
|
-
const SPARKLE_PATH = "
|
|
37125
|
+
const SPARKLE_PATH = "M9.2474 19.7799c0.2619-0.0002 0.4863 0.1883 0.5324 0.4459 0.0932 0.527 0.2872 0.904 0.5528 1.17 0.2659 0.2658 0.643 0.4594 1.1699 0.5527 0.2577 0.0457 0.447 0.2708 0.4475 0.5325-0.0001 0.2621-0.1893 0.4869-0.4475 0.5322-0.527 0.0928-0.9041 0.2872-1.1699 0.5529-0.2655 0.2656-0.4594 0.6427-0.5528 1.1698-0.0456 0.2583-0.2701 0.4477-0.5324 0.4475-0.2621-0.0002-0.4869-0.1893-0.5323-0.4475-0.0929-0.5274-0.2858-0.9058-0.5512-1.1714-0.2655-0.2653-0.6432-0.4585-1.1699-0.5513-0.2578-0.0457-0.4459-0.2705-0.446-0.5322 0.0005-0.2616 0.1883-0.4868 0.446-0.5325 0.5271-0.0933 0.9043-0.2856 1.1699-0.5512 0.2655-0.2658 0.4584-0.6442 0.5512-1.1715l0.0251-0.0926c0.077-0.2087 0.278-0.3531 0.5072-0.3533z m9.2369-9.6672c0.469 0 0.8756 0.3248 0.9799 0.7821 0.3678 1.6148 1.0327 2.8589 1.9599 3.7861 0.9272 0.9272 2.1714 1.5921 3.7861 1.9598 0.4573 0.1041 0.7818 0.5109 0.782 0.9799 0 0.4691-0.3247 0.8758-0.782 0.98-1.6146 0.3677-2.859 1.0324-3.7861 1.9597-0.9272 0.9275-1.5921 2.1725-1.9599 3.7878-0.104 0.4575-0.5107 0.782-0.9799 0.782-0.469 0-0.8758-0.3247-0.9799-0.782-0.3677-1.6153-1.0324-2.8602-1.9598-3.7878-0.9275-0.9274-2.1724-1.5921-3.7877-1.9597-0.4574-0.1042-0.782-0.5108-0.7821-0.98 0.0001-0.469 0.3247-0.8758 0.7821-0.9799 1.6155-0.3677 2.8602-1.0325 3.7877-1.9598 0.9274-0.9272 1.5921-2.1714 1.9598-3.7861 0.1042-0.4572 0.511-0.7819 0.9799-0.7821z m0 3.9228c-0.4094 0.7713-0.9141 1.4622-1.5185 2.0666-0.6047 0.6045-1.2964 1.1092-2.0682 1.5185 0.7718 0.4094 1.4635 0.914 2.0682 1.5186 0.6043 0.6042 1.1092 1.2954 1.5185 2.0666 0.4092-0.7712 0.9144-1.4624 1.5186-2.0666 0.6045-0.6046 1.2951-1.1107 2.0666-1.5201-0.7711-0.4093-1.4625-0.9128-2.0666-1.517-0.6043-0.6044-1.1092-1.2953-1.5186-2.0666z m-9.2369-7.2189c0.2594 0 0.4822 0.1849 0.5308 0.4397 0.1282 0.6719 0.3843 1.1692 0.7428 1.5279 0.3588 0.3588 0.8571 0.6145 1.5295 0.7428 0.2546 0.0485 0.4395 0.2716 0.4397 0.5308 0 0.2594-0.1849 0.4822-0.4397 0.5308-0.6725 0.1282-1.1707 0.3839-1.5295 0.7427-0.3589 0.3589-0.6146 0.8571-0.7428 1.5296-0.0486 0.2548-0.2714 0.4397-0.5308 0.4397-0.2592-0.0002-0.4822-0.1851-0.5307-0.4397-0.1282-0.6725-0.3842-1.1707-0.7428-1.5296-0.3585-0.3584-0.8552-0.6146-1.5264-0.7427-0.2548-0.0486-0.4397-0.2714-0.4397-0.5308 0.0002-0.2592 0.1851-0.4822 0.4397-0.5308 0.6714-0.1282 1.1679-0.3841 1.5264-0.7428 0.3585-0.3587 0.6145-0.8558 0.7428-1.5279 0.0485-0.2547 0.2716-0.4395 0.5307-0.4397z";
|
|
35399
37126
|
// Helpdesk reads this context off the email path to open its email form the
|
|
35400
37127
|
// same way a handoff inside its own drawer does.
|
|
35401
37128
|
function emailPathWithContext(context = {}) {
|
|
@@ -35537,9 +37264,9 @@ function LoadError({
|
|
|
35537
37264
|
const Picobot = {
|
|
35538
37265
|
component: PicobotComponent,
|
|
35539
37266
|
icons: {
|
|
35540
|
-
|
|
35541
|
-
staticPath: SPARKLE_PATH
|
|
37267
|
+
path: SPARKLE_PATH
|
|
35542
37268
|
},
|
|
37269
|
+
label: "Ask AI",
|
|
35543
37270
|
name: "Picobot"
|
|
35544
37271
|
};
|
|
35545
37272
|
|
|
@@ -35744,8 +37471,7 @@ function JoltEffectV1({
|
|
|
35744
37471
|
const Tasks = {
|
|
35745
37472
|
component: TasksComponent,
|
|
35746
37473
|
icons: {
|
|
35747
|
-
|
|
35748
|
-
staticPath: "M14 8V10H18V8H14ZM13.5 6C12.6716 6 12 6.67157 12 7.5V8H9C7.89543 8 7 8.89543 7 10V24C7 25.1046 7.89543 26 9 26H23C24.1046 26 25 25.1046 25 24V10C25 8.89543 24.1046 8 23 8H20V7.5C20 6.67157 19.3284 6 18.5 6H13.5ZM20 10.5V10H23V24H9L9 10H12V10.5C12 11.3284 12.6716 12 13.5 12H18.5C19.3284 12 20 11.3284 20 10.5ZM18.3485 14.1464C18.5437 13.9512 18.8603 13.9512 19.0556 14.1464L20.0686 15.1594C20.2638 15.3547 20.2638 15.6713 20.0686 15.8665L15.4282 20.5069C15.3814 20.5536 15.3278 20.5892 15.2705 20.6135C15.0875 20.6934 14.8665 20.6585 14.7167 20.5088L11.9433 17.7353C11.7481 17.5401 11.7481 17.2235 11.9433 17.0282L12.9571 16.0144C13.1524 15.8192 13.469 15.8192 13.6642 16.0144L15.0724 17.4226L18.3485 14.1464Z"
|
|
37474
|
+
path: "M18.4215 14.5192c0.3756-0.4084 1.0126-0.4352 1.4212-0.0597 0.408 0.3755 0.4345 1.0111 0.0597 1.4196l-3.8537 4.1929c-0.358 0.389-0.957 0.4347-1.3694 0.1037l-2.4827-1.9944c-0.4327-0.3476-0.5014-0.9806-0.1539-1.4134 0.3476-0.4324 0.9807-0.5014 1.4133-0.1539l1.7478 1.404z m-0.3078-8.5114c1.1852 0.0002 2.1569 0.9114 2.255 2.0713h0.9015l0.3282 0.0157c0.7593 0.0756 1.4736 0.4121 2.0178 0.9564 0.6218 0.6221 0.9706 1.4666 0.9706 2.3461v11.2783c-0.0002 0.8798-0.3485 1.7242-0.9706 2.3461-0.622 0.622-1.4664 0.9705-2.346 0.9705h-10.5388c-0.8796 0-1.724-0.3486-2.3461-0.9705-0.622-0.622-0.972-1.4664-0.9721-2.3461v-11.2799c0-0.8798 0.35-1.724 0.9721-2.3461 0.6221-0.6221 1.4663-0.9721 2.3461-0.972h0.9108c0.0988-1.1593 1.0702-2.0697 2.2551-2.0698z m-7.3823 4.0798c-0.3467 0-0.6798 0.138-0.9249 0.3832-0.2451 0.2452-0.3832 0.5783-0.3832 0.9249v11.2799c0.0001 0.3467 0.1381 0.6799 0.3832 0.9249 0.2451 0.2449 0.5785 0.3816 0.9249 0.3816h10.5388c0.3462 0 0.6783-0.137 0.9233-0.3816 0.2451-0.2451 0.383-0.5783 0.3832-0.9249v-11.2783c0-0.3467-0.1381-0.6798-0.3832-0.9249-0.2145-0.2144-0.4956-0.3471-0.7947-0.3769l-0.1286-0.0063h-0.892v0.1822c-0.0003 1.25-1.0145 2.2627-2.2645 2.2628h-4.2164c-1.2502 0-2.2641-1.0127-2.2645-2.2628v-0.1838z m3.1659-2.0697c-0.1403 0-0.2544 0.1141-0.2544 0.2544v1.9991c0.0003 0.14 0.1143 0.2528 0.2544 0.2528h4.2164c0.1399-0.0002 0.2541-0.1129 0.2544-0.2528v-1.1731c-0.0001-0.0047-0.0016-0.0094-0.0016-0.0141 0-0.0052 0.0015-0.0105 0.0016-0.0157v-0.7962c0-0.1402-0.1143-0.2542-0.2544-0.2544z"
|
|
35749
37475
|
},
|
|
35750
37476
|
name: "Tasks"
|
|
35751
37477
|
};
|
|
@@ -35868,8 +37594,7 @@ function ChatTool({
|
|
|
35868
37594
|
const Chat = {
|
|
35869
37595
|
component: ChatTool,
|
|
35870
37596
|
icons: {
|
|
35871
|
-
|
|
35872
|
-
staticPath: "M13.8284 20L15.9998 22.1714L18.1713 20H23C23.5523 20 24 19.5523 24 19V10C24 9.44772 23.5523 9 23 9H9C8.44772 9 8 9.44772 8 10V19C8 19.5523 8.44772 20 9 20H13.8284ZM15.9998 24.9998L13 22H9C7.34315 22 6 20.6569 6 19V10C6 8.34315 7.34315 7 9 7H23C24.6569 7 26 8.34315 26 10V19C26 20.6569 24.6569 22 23 22H18.9997L15.9998 24.9998Z"
|
|
37597
|
+
path: "M23.0509 7.005c0.7801 0 1.5293 0.3105 2.0808 0.8621 0.5512 0.5515 0.8605 1.2994 0.8605 2.0792v8.5898c0 0.7797-0.3092 1.5276-0.8605 2.0792-0.5516 0.5516-1.3008 0.8621-2.0808 0.8621h-2.9884l-4.0672 3.5176-4.0688-3.5176h-2.9774c-0.78 0-1.5276-0.3105-2.0792-0.8621-0.5516-0.5516-0.8621-1.2991-0.8621-2.0792v-8.5898c0-0.78 0.3106-1.5276 0.8621-2.0792 0.5516-0.5516 1.2991-0.8621 2.0792-0.8621z m-14.1018 2.01c-0.2469 0-0.4834 0.0986-0.658 0.2733-0.1746 0.1746-0.2732 0.411-0.2732 0.658v8.5898c0 0.2469 0.0986 0.4834 0.2732 0.658 0.1746 0.1746 0.411 0.2732 0.658 0.2733h3.7265l0.2842 0.2449 3.034 2.6241 3.0355-2.6241 0.2842-0.2449h3.7374c0.247 0 0.485-0.0986 0.6596-0.2733 0.1743-0.1746 0.2716-0.4113 0.2716-0.658v-8.5898c0-0.2467-0.0973-0.4834-0.2716-0.658-0.1746-0.1746-0.4126-0.2732-0.6596-0.2733z"
|
|
35873
37598
|
},
|
|
35874
37599
|
name: "Chat",
|
|
35875
37600
|
storageExemptPaths: ["blankstate"]
|
|
@@ -35976,8 +37701,7 @@ const usePicobotConfig = ({
|
|
|
35976
37701
|
const Profile = {
|
|
35977
37702
|
component: UserProfile,
|
|
35978
37703
|
icons: {
|
|
35979
|
-
|
|
35980
|
-
staticPath: ""
|
|
37704
|
+
path: ""
|
|
35981
37705
|
},
|
|
35982
37706
|
name: "Profile"
|
|
35983
37707
|
};
|
|
@@ -36043,13 +37767,14 @@ function Toolbar({
|
|
|
36043
37767
|
} = state;
|
|
36044
37768
|
const mounted = !!currentContent;
|
|
36045
37769
|
const storeData = useStore();
|
|
37770
|
+
const devStoreDataOverride = env === "development" ? _storeDataOverride !== null && _storeDataOverride !== void 0 ? _storeDataOverride : {} : {};
|
|
36046
37771
|
const {
|
|
36047
37772
|
indicatorVisible,
|
|
36048
37773
|
joltPromise,
|
|
36049
37774
|
userId
|
|
36050
37775
|
} = {
|
|
36051
37776
|
...storeData,
|
|
36052
|
-
...
|
|
37777
|
+
...devStoreDataOverride
|
|
36053
37778
|
};
|
|
36054
37779
|
const updateStore = useUpdateStore();
|
|
36055
37780
|
const {
|
|
@@ -36307,22 +38032,26 @@ function Toolbar({
|
|
|
36307
38032
|
};
|
|
36308
38033
|
const indicatorState = {
|
|
36309
38034
|
...indicatorVisible,
|
|
36310
|
-
Chat: unreadIndicator
|
|
38035
|
+
Chat: unreadIndicator,
|
|
38036
|
+
// Chat's dot comes from its own config, so a dev override has to land last.
|
|
38037
|
+
...devStoreDataOverride.indicatorVisible
|
|
36311
38038
|
};
|
|
36312
38039
|
return /*#__PURE__*/React__default.createElement(ThemeProvider, {
|
|
36313
38040
|
theme: topbarTheme
|
|
36314
38041
|
}, /*#__PURE__*/React__default.createElement(UiExtensionDataContext, null, /*#__PURE__*/React__default.createElement("div", {
|
|
36315
38042
|
className: styles$2["toolbar"],
|
|
36316
38043
|
"data-pendo": "toolbar-profile-support-wrapper"
|
|
36317
|
-
}, /*#__PURE__*/React__default.createElement(
|
|
36318
|
-
"
|
|
38044
|
+
}, /*#__PURE__*/React__default.createElement(ToolbarDrawerButton, {
|
|
38045
|
+
tooltip: "Profile",
|
|
38046
|
+
"aria-label": `Profile, ${userName}`,
|
|
36319
38047
|
onClick: () => toggleDrawer(Profile),
|
|
36320
38048
|
"data-pendo": "toolbar-profile",
|
|
36321
|
-
className: styles$2["toolbar-button--avatar"]
|
|
36322
|
-
|
|
36323
|
-
|
|
36324
|
-
|
|
36325
|
-
|
|
38049
|
+
className: styles$2["toolbar-button--avatar"],
|
|
38050
|
+
icon: /*#__PURE__*/React__default.createElement(Avatar, {
|
|
38051
|
+
env: env,
|
|
38052
|
+
url: userAvatarPath
|
|
38053
|
+
})
|
|
38054
|
+
}), /*#__PURE__*/React__default.createElement(ToolbarButton, {
|
|
36326
38055
|
className: styles$2["toolbar-button--home"],
|
|
36327
38056
|
onClick: () => closeDrawer()
|
|
36328
38057
|
}, /*#__PURE__*/React__default.createElement(Icon$1, {
|
|
@@ -36332,17 +38061,18 @@ function Toolbar({
|
|
|
36332
38061
|
var _a;
|
|
36333
38062
|
const current = open && currentContent === tool;
|
|
36334
38063
|
const indicator = indicatorState[tool.name];
|
|
36335
|
-
return /*#__PURE__*/React__default.createElement(
|
|
38064
|
+
return /*#__PURE__*/React__default.createElement(ToolbarDrawerButton, {
|
|
36336
38065
|
current: current,
|
|
36337
38066
|
onClick: () => handleToolOnClick(tool),
|
|
36338
38067
|
id: getDataPendoAttribute(tool.name),
|
|
36339
|
-
|
|
38068
|
+
tooltip: (_a = tool.label) !== null && _a !== void 0 ? _a : tool.name,
|
|
36340
38069
|
"data-pendo": getDataPendoAttribute(tool.name),
|
|
36341
|
-
key: tool.name
|
|
36342
|
-
|
|
36343
|
-
|
|
36344
|
-
|
|
36345
|
-
|
|
38070
|
+
key: tool.name,
|
|
38071
|
+
icon: /*#__PURE__*/React__default.createElement(ToolbarToolIcon, {
|
|
38072
|
+
icons: tool.icons,
|
|
38073
|
+
dot: !!indicator
|
|
38074
|
+
})
|
|
38075
|
+
});
|
|
36346
38076
|
})), /*#__PURE__*/React__default.createElement(DrawerWrap, {
|
|
36347
38077
|
isVisible: open
|
|
36348
38078
|
}, mounted && (/*#__PURE__*/React__default.createElement(Drawer, {
|
|
@@ -36366,6 +38096,24 @@ const ToolbarButton = ({
|
|
|
36366
38096
|
...restProps
|
|
36367
38097
|
}, children);
|
|
36368
38098
|
};
|
|
38099
|
+
const ToolbarDrawerButton = ({
|
|
38100
|
+
"aria-label": ariaLabel,
|
|
38101
|
+
className,
|
|
38102
|
+
current = false,
|
|
38103
|
+
tooltip,
|
|
38104
|
+
...restProps
|
|
38105
|
+
}) => {
|
|
38106
|
+
// Below 600px the toolbar sits along the bottom, where tooltips get in the way.
|
|
38107
|
+
const isSideToolbar = useMediaQuery("(min-width: 600px)");
|
|
38108
|
+
return /*#__PURE__*/React__default.createElement(IconButton, {
|
|
38109
|
+
className: classnames(styles$2["toolbar-button"], className, current && styles$2["is-current"]),
|
|
38110
|
+
"aria-label": ariaLabel !== null && ariaLabel !== void 0 ? ariaLabel : tooltip,
|
|
38111
|
+
tooltip: isSideToolbar ? tooltip : undefined,
|
|
38112
|
+
tooltipPlacement: "left",
|
|
38113
|
+
"data-toolbar-link": "true",
|
|
38114
|
+
...restProps
|
|
38115
|
+
});
|
|
38116
|
+
};
|
|
36369
38117
|
function ToolbarToolIcon({
|
|
36370
38118
|
dot,
|
|
36371
38119
|
icons
|
|
@@ -36374,31 +38122,57 @@ function ToolbarToolIcon({
|
|
|
36374
38122
|
return /*#__PURE__*/React__default.createElement(icons.component, null);
|
|
36375
38123
|
} else {
|
|
36376
38124
|
return /*#__PURE__*/React__default.createElement(ToolbarButtonIcon, {
|
|
36377
|
-
path:
|
|
38125
|
+
path: icons.path,
|
|
36378
38126
|
dot: dot
|
|
36379
38127
|
});
|
|
36380
38128
|
}
|
|
36381
38129
|
}
|
|
38130
|
+
// The dot sits on the icon's top-right corner. A mask knocks a transparent
|
|
38131
|
+
// ring out of the glyph around it, so the gap reads correctly on any button
|
|
38132
|
+
// background (hover, current, dark mode) without a second, pre-cut path.
|
|
38133
|
+
const DOT = {
|
|
38134
|
+
cx: 24,
|
|
38135
|
+
cy: 8,
|
|
38136
|
+
gap: 2,
|
|
38137
|
+
r: 4
|
|
38138
|
+
};
|
|
38139
|
+
// React 17 has no useId, and mask ids are document-global: count instead so
|
|
38140
|
+
// several toolbars (or icons) on one page never share a mask.
|
|
38141
|
+
let dotMaskCount = 0;
|
|
36382
38142
|
function ToolbarButtonIcon({
|
|
36383
38143
|
dot,
|
|
36384
38144
|
path
|
|
36385
38145
|
}) {
|
|
38146
|
+
const [maskId] = React__default.useState(() => `topbar-toolbar-dot-mask-${++dotMaskCount}`);
|
|
36386
38147
|
return /*#__PURE__*/React__default.createElement("svg", {
|
|
36387
38148
|
"aria-hidden": "true",
|
|
36388
38149
|
width: "32",
|
|
36389
38150
|
height: "32",
|
|
36390
38151
|
viewBox: "0 0 32 32",
|
|
36391
38152
|
xmlns: "http://www.w3.org/2000/svg"
|
|
36392
|
-
}, /*#__PURE__*/React__default.createElement("
|
|
38153
|
+
}, dot && (/*#__PURE__*/React__default.createElement("mask", {
|
|
38154
|
+
id: maskId,
|
|
38155
|
+
maskUnits: "userSpaceOnUse"
|
|
38156
|
+
}, /*#__PURE__*/React__default.createElement("rect", {
|
|
38157
|
+
width: "32",
|
|
38158
|
+
height: "32",
|
|
38159
|
+
fill: "white"
|
|
38160
|
+
}), /*#__PURE__*/React__default.createElement("circle", {
|
|
38161
|
+
cx: DOT.cx,
|
|
38162
|
+
cy: DOT.cy,
|
|
38163
|
+
r: DOT.r + DOT.gap,
|
|
38164
|
+
fill: "black"
|
|
38165
|
+
}))), /*#__PURE__*/React__default.createElement("path", {
|
|
36393
38166
|
fill: "currentColor",
|
|
36394
38167
|
fillRule: "evenodd",
|
|
36395
38168
|
clipRule: "evenodd",
|
|
36396
|
-
d: path
|
|
38169
|
+
d: path,
|
|
38170
|
+
mask: dot ? `url(#${maskId})` : undefined
|
|
36397
38171
|
}), dot && (/*#__PURE__*/React__default.createElement("circle", {
|
|
36398
38172
|
fill: "var(--t-icon-color-status-error)",
|
|
36399
|
-
cx:
|
|
36400
|
-
cy:
|
|
36401
|
-
r:
|
|
38173
|
+
cx: DOT.cx,
|
|
38174
|
+
cy: DOT.cy,
|
|
38175
|
+
r: DOT.r
|
|
36402
38176
|
})));
|
|
36403
38177
|
}
|
|
36404
38178
|
function getDataPendoAttribute(toolName) {
|