PageSourceSearch

https://hunter.io/assets/reveal-save-dropdown-abkRRssE.js

js hunter.io collected 2026-09-24 07:50:41 UTC 6,460 bytes, 142 lines download raw bytes

1(function() {
2	try {
3		var e = "undefined" != typeof window ? window : "undefined" != typeof global ? global : "undefined" != typeof globalThis ? globalThis : "undefined" != typeof self ? self : {};
4		e.SENTRY_RELEASE = { id: "b96dc26" };
5		var n = new e.Error().stack;
6		n && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[n] = "0964e266-2b52-4096-b327-dd4d3a83a6c4", e._sentryDebugIdIdentifier = "sentry-dbid-0964e266-2b52-4096-b327-dd4d3a83a6c4");
7	} catch (e) {}
8})();
9import { a as __toESM, n as __esmMin } from "./rolldown-runtime-sLwMD6dS.js";
10import { Et as DropdownMenuTrigger, M as init_currency_helper, _t as DropdownMenuHint, bt as DropdownMenuItem, ft as DropdownMenu, ht as DropdownMenuDivider, j as CurrencyHelper, kt as init_dropdown_menu, mt as DropdownMenuContent } from "./controllers-jdPQjaCB.js";
11import { t as require_jsx_runtime } from "./jsx-runtime-CHSMGLHp.js";
12import { t as require_react } from "./react-CrLPhuc5.js";
13import { n as init_icon, t as Icon } from "./icon-BNzYbsdJ.js";
14import { n as ButtonSuffix, r as init_button, t as Button } from "./button-DOiPZHfy.js";
15import { n as init_cost_indicator, t as CostIndicator } from "./cost-indicator-DKlBRQzL.js";
16import { a as LeadSaveManager, l as init_lead_save_manager, u as isLeadSavePickerLayer } from "./lead-campaigns-manager-Chy_HL1G.js";
17//#region app/frontend/lib/fetch-with-retry.ts
18async function fetchWithRetry(input, init, retryStatuses = []) {
19	const signal = init?.signal;
20	for (let attempt = 0;; attempt++) {
21		signal?.throwIfAborted();
22		try {
23			const response = await fetch(input, init);
24			if (retryStatuses.length === 0 || !retryStatuses.includes(response.status) || attempt >= RETRY_DELAYS_MS.length) return response;
25		} catch (error) {
26			if (!(error instanceof TypeError) || attempt >= RETRY_DELAYS_MS.length) throw error;
27		}
28		await new Promise((resolve, reject) => {
29			signal?.throwIfAborted();
30			const onAbort = () => {
31				clearTimeout(timer);
32				reject(signal?.reason);
33			};
34			const timer = setTimeout(() => {
35				signal?.removeEventListener("abort", onAbort);
36				resolve();
37			}, RETRY_DELAYS_MS[attempt]);
38			signal?.addEventListener("abort", onAbort, { once: true });
39		});
40	}
41}
42var RETRY_DELAYS_MS;
43function init_fetch_with_retry() {
44	return (init_fetch_with_retry = __esmMin((() => {
45		RETRY_DELAYS_MS = [500, 1500];
46	})))();
47}
48//#endregion
49//#region app/frontend/react/components/reveal-save-dropdown.tsx
50var import_react, import_jsx_runtime, RevealSaveDropdown;
51function init_reveal_save_dropdown() {
52	return (init_reveal_save_dropdown = __esmMin((() => {
53		import_react = /* @__PURE__ */ __toESM(require_react());
54		init_dropdown_menu();
55		init_button();
56		init_icon();
57		init_currency_helper();
58		init_cost_indicator();
59		init_lead_save_manager();
60		import_jsx_runtime = require_jsx_runtime();
61		RevealSaveDropdown = ({ id, label, cost, count, costIsEstimate = false, disabled = false, onReveal, onSave, leadsLists, folders = [], hint, currentList }) => {
62			const nothingToReveal = cost === 0;
63			const rootRef = import_react.useRef(null);
64			const [isOpen, setIsOpen] = import_react.useState(false);
65			const handleListSave = (name, listId) => {
66				onSave(name, listId);
67				setIsOpen(false);
68			};
69			return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(DropdownMenu, {
70				ref: rootRef,
71				open: isOpen,
72				onOpenChange: setIsOpen,
73				children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DropdownMenuTrigger, {
74					asChild: true,
75					children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Button, {
76						variant: "primary",
77						children: [label, cost != null && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ButtonSuffix, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(CostIndicator, {
78							variant: "bare",
79							cost
80						}) })]
81					})
82				}), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(DropdownMenuContent, {
83					onPointerDownOutside: (event) => {
84						if (isLeadSavePickerLayer(event)) event.preventDefault();
85					},
86					onFocusOutside: (event_0) => {
87						if (isLeadSavePickerLayer(event_0)) event_0.preventDefault();
88					},
89					children: [
90						cost != null && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("li", { children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(DropdownMenuHint, { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Icon, {
91							icon: "coin",
92							size: "xs",
93							className: "cost-indicator__icon"
94						}), i18n.t(costIsEstimate ? "js.multi_domain_search.footer.cost_tooltip_estimate" : "js.multi_domain_search.footer.cost_tooltip", {
95							count,
96							cost: CurrencyHelper.numberWithDelimiter(cost)
97						})] }) }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("li", { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(DropdownMenuDivider, {}) })] }),
98						currentList && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(DropdownMenuItem, {
99							asChild: true,
100							closeOnClick: true,
101							children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("button", {
102								type: "button",
103								disabled,
104								onClick: () => onSave(currentList.name, currentList.id),
105								className: "dropdown-item",
106								children: i18n.t("js.multi_domain_search.footer.save_in_the_current_list")
107							})
108						}),
109						/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(LeadSaveManager, {
110							nested: true,
111							className: "w-100",
112							id,
113							leadsLists,
114							folders,
115							onSave: handleListSave,
116							disableButtons: disabled,
117							cost: cost ?? null,
118							hint,
119							children: [currentList ? i18n.t("js.multi_domain_search.footer.save_in_another_list") : i18n.t("js.multi_domain_search.footer.save_in_a_specific_list"), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Icon, {
120								icon: "angle-right",
121								size: "sm",
122								"aria-hidden": "true"
123							})]
124						}),
125						/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DropdownMenuItem, {
126							asChild: true,
127							closeOnClick: true,
128							children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("button", {
129								disabled: disabled || nothingToReveal,
130								onClick: onReveal,
131								className: "dropdown-item",
132								children: i18n.t("js.multi_domain_search.footer.save_in_leads")
133							})
134						})
135					]
136				})]
137			});
138		};
139	})))();
140}
141//#endregion
142export { init_fetch_with_retry as i, init_reveal_save_dropdown as n, fetchWithRetry as r, RevealSaveDropdown as t };

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.