@letsrunit/playwright 0.1.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/README.md +44 -0
- package/dist/index.d.ts +106 -0
- package/dist/index.js +3006 -0
- package/dist/index.js.map +1 -0
- package/package.json +67 -0
- package/src/browser.ts +20 -0
- package/src/field/calendar.ts +300 -0
- package/src/field/date-group.ts +253 -0
- package/src/field/date-text-input.ts +270 -0
- package/src/field/index.ts +57 -0
- package/src/field/native-checkbox.ts +21 -0
- package/src/field/native-date.ts +62 -0
- package/src/field/native-input.ts +17 -0
- package/src/field/native-select.ts +75 -0
- package/src/field/otp.ts +22 -0
- package/src/field/radio-group.ts +27 -0
- package/src/field/slider.ts +132 -0
- package/src/field/types.ts +16 -0
- package/src/format-html.ts +17 -0
- package/src/index.ts +12 -0
- package/src/locator.ts +102 -0
- package/src/page-info.ts +33 -0
- package/src/screenshot.ts +84 -0
- package/src/scroll.ts +10 -0
- package/src/scrub-html.ts +333 -0
- package/src/selector/date-selector.ts +272 -0
- package/src/selector/field-selector.ts +121 -0
- package/src/selector/index.ts +2 -0
- package/src/snapshot.ts +55 -0
- package/src/suppress-interferences.ts +288 -0
- package/src/translations/af.ts +41 -0
- package/src/translations/ar.ts +7 -0
- package/src/translations/az.ts +40 -0
- package/src/translations/bg.ts +7 -0
- package/src/translations/bn.ts +40 -0
- package/src/translations/bs.ts +7 -0
- package/src/translations/ca.ts +41 -0
- package/src/translations/cs.ts +7 -0
- package/src/translations/da.ts +44 -0
- package/src/translations/de.ts +47 -0
- package/src/translations/el.ts +40 -0
- package/src/translations/en.ts +7 -0
- package/src/translations/es.ts +7 -0
- package/src/translations/et.ts +7 -0
- package/src/translations/eu.ts +7 -0
- package/src/translations/fa.ts +7 -0
- package/src/translations/fi.ts +39 -0
- package/src/translations/fr.ts +42 -0
- package/src/translations/ga.ts +40 -0
- package/src/translations/he.ts +45 -0
- package/src/translations/hi.ts +39 -0
- package/src/translations/hr.ts +7 -0
- package/src/translations/hu.ts +7 -0
- package/src/translations/hy.ts +7 -0
- package/src/translations/id.ts +7 -0
- package/src/translations/index.ts +68 -0
- package/src/translations/is.ts +7 -0
- package/src/translations/it.ts +7 -0
- package/src/translations/ja.ts +7 -0
- package/src/translations/ka.ts +36 -0
- package/src/translations/ko.ts +7 -0
- package/src/translations/lt.ts +7 -0
- package/src/translations/lv.ts +43 -0
- package/src/translations/nl.ts +43 -0
- package/src/translations/no.ts +46 -0
- package/src/translations/pl.ts +39 -0
- package/src/translations/pt.ts +41 -0
- package/src/translations/ro.ts +40 -0
- package/src/translations/ru.ts +7 -0
- package/src/translations/sk.ts +7 -0
- package/src/translations/sl.ts +7 -0
- package/src/translations/sv.ts +44 -0
- package/src/translations/sw.ts +7 -0
- package/src/translations/ta.ts +7 -0
- package/src/translations/th.ts +39 -0
- package/src/translations/tl.ts +7 -0
- package/src/translations/tr.ts +41 -0
- package/src/translations/uk.ts +7 -0
- package/src/translations/ur.ts +43 -0
- package/src/translations/vi.ts +7 -0
- package/src/translations/zh.ts +7 -0
- package/src/types.ts +37 -0
- package/src/unified-html-diff.ts +22 -0
- package/src/utils/date.ts +40 -0
- package/src/utils/pick-field-element.ts +48 -0
- package/src/utils/type-check.ts +7 -0
- package/src/wait.ts +170 -0
package/dist/index.js
ADDED
|
@@ -0,0 +1,3006 @@
|
|
|
1
|
+
import { getWeekNumber, sleep, chain, hashKey, isRange, isDate, isArray, cartesian } from '@letsrunit/utils';
|
|
2
|
+
import { diffArray, uniqueItem } from '@letsrunit/utils/src/array';
|
|
3
|
+
import rehypeFormat from 'rehype-format';
|
|
4
|
+
import rehypeParse from 'rehype-parse';
|
|
5
|
+
import rehypeStringify from 'rehype-stringify';
|
|
6
|
+
import { unified } from 'unified';
|
|
7
|
+
|
|
8
|
+
// src/browser.ts
|
|
9
|
+
async function browse(browser, options = {}) {
|
|
10
|
+
const context = await browser.newContext({
|
|
11
|
+
viewport: { width: 1920, height: 1080 },
|
|
12
|
+
userAgent: "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36",
|
|
13
|
+
locale: "en-US",
|
|
14
|
+
...options
|
|
15
|
+
});
|
|
16
|
+
await context.addInitScript(() => {
|
|
17
|
+
window.__name = window.__name || ((fn) => fn);
|
|
18
|
+
});
|
|
19
|
+
return await context.newPage();
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
// src/utils/pick-field-element.ts
|
|
23
|
+
async function pickFieldElement(elements) {
|
|
24
|
+
const count = await elements.count();
|
|
25
|
+
if (count === 1) return elements;
|
|
26
|
+
const candidates = [];
|
|
27
|
+
for (let i = 0; i < count; i++) {
|
|
28
|
+
const el = elements.nth(i);
|
|
29
|
+
const [tag, role, isVisible] = await el.evaluate((e) => [
|
|
30
|
+
e.tagName.toLowerCase(),
|
|
31
|
+
e.getAttribute("role")?.toLowerCase() || null,
|
|
32
|
+
e.getAttribute("type") !== "hidden" && e.getAttribute("aria-hidden") !== "true"
|
|
33
|
+
]);
|
|
34
|
+
candidates.push({ el, tag, role, isVisible });
|
|
35
|
+
}
|
|
36
|
+
const formControls = ["input", "textarea", "select"];
|
|
37
|
+
const controlRoles = ["checkbox", "radio", "textbox", "combobox", "listbox", "slider", "spinbutton"];
|
|
38
|
+
const primary = candidates.filter(
|
|
39
|
+
(c) => (formControls.includes(c.tag) || c.role && controlRoles.includes(c.role)) && c.isVisible
|
|
40
|
+
);
|
|
41
|
+
if (primary.length === 1) return primary[0].el;
|
|
42
|
+
const groups = candidates.filter((c) => c.role === "group");
|
|
43
|
+
if (groups.length === 1) return groups[0].el;
|
|
44
|
+
const isParent = await elements.evaluateAll((elems) => {
|
|
45
|
+
const results = elems.map((el, i) => {
|
|
46
|
+
const others = elems.filter((_, j) => i !== j);
|
|
47
|
+
return others.every((other) => el.contains(other));
|
|
48
|
+
});
|
|
49
|
+
const parentIndex = results.indexOf(true);
|
|
50
|
+
return parentIndex !== -1 ? parentIndex : null;
|
|
51
|
+
});
|
|
52
|
+
if (isParent !== null) {
|
|
53
|
+
return elements.nth(isParent);
|
|
54
|
+
}
|
|
55
|
+
return elements;
|
|
56
|
+
}
|
|
57
|
+
function formatDateForInput(date, type) {
|
|
58
|
+
const pad = (n) => String(n).padStart(2, "0");
|
|
59
|
+
const yyyy = date.getFullYear();
|
|
60
|
+
const mm = pad(date.getMonth() + 1);
|
|
61
|
+
const dd = pad(date.getDate());
|
|
62
|
+
const hh = pad(date.getHours());
|
|
63
|
+
const min = pad(date.getMinutes());
|
|
64
|
+
switch (type) {
|
|
65
|
+
case "number":
|
|
66
|
+
return date.getTime().toString();
|
|
67
|
+
case "datetime-local":
|
|
68
|
+
return `${yyyy}-${mm}-${dd}T${hh}:${min}`;
|
|
69
|
+
case "month":
|
|
70
|
+
return `${yyyy}-${mm}`;
|
|
71
|
+
case "week": {
|
|
72
|
+
const week = getWeekNumber(date);
|
|
73
|
+
return `${yyyy}-W${pad(week)}`;
|
|
74
|
+
}
|
|
75
|
+
case "time":
|
|
76
|
+
return `${hh}:${min}`;
|
|
77
|
+
case "date":
|
|
78
|
+
default:
|
|
79
|
+
return `${yyyy}-${mm}-${dd}`;
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
function formatDate(d, format) {
|
|
83
|
+
const dd = String(d.getDate()).padStart(2, "0");
|
|
84
|
+
const mm = String(d.getMonth() + 1).padStart(2, "0");
|
|
85
|
+
const yyyy = String(d.getFullYear());
|
|
86
|
+
return format.replace("DD", dd).replace("MM", mm).replace("YYYY", yyyy);
|
|
87
|
+
}
|
|
88
|
+
function getMonthNames(locale) {
|
|
89
|
+
const formatter = new Intl.DateTimeFormat(locale, { month: "long" });
|
|
90
|
+
return Array.from({ length: 12 }, (_, i) => formatter.format(new Date(2e3, i, 1)));
|
|
91
|
+
}
|
|
92
|
+
async function waitForIdle(page, timeout = 2500) {
|
|
93
|
+
await page.waitForLoadState("domcontentloaded");
|
|
94
|
+
try {
|
|
95
|
+
await page.waitForLoadState("networkidle", { timeout });
|
|
96
|
+
} catch {
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
async function waitForMeta(page, timeout = 2500) {
|
|
100
|
+
await waitForIdle(page);
|
|
101
|
+
page.getByRole("navigation");
|
|
102
|
+
await page.waitForFunction(
|
|
103
|
+
() => {
|
|
104
|
+
const head = document.head;
|
|
105
|
+
if (!head) return false;
|
|
106
|
+
return Boolean(
|
|
107
|
+
document.title.trim() || head.querySelector('meta[property^="og:"]') || head.querySelector('meta[name^="twitter:"]') || head.querySelector('script[type="application/ld+json"]')
|
|
108
|
+
);
|
|
109
|
+
},
|
|
110
|
+
{ timeout }
|
|
111
|
+
).catch(() => {
|
|
112
|
+
});
|
|
113
|
+
}
|
|
114
|
+
async function waitForDomIdle(page, { quiet = 500, timeout = 1e4 } = {}) {
|
|
115
|
+
await page.waitForFunction(
|
|
116
|
+
(q) => new Promise((resolve) => {
|
|
117
|
+
let last = performance.now();
|
|
118
|
+
const obs = new MutationObserver(() => last = performance.now());
|
|
119
|
+
obs.observe(document, {
|
|
120
|
+
subtree: true,
|
|
121
|
+
childList: true,
|
|
122
|
+
attributes: true,
|
|
123
|
+
characterData: true
|
|
124
|
+
});
|
|
125
|
+
const tick = () => {
|
|
126
|
+
if (performance.now() - last >= q) {
|
|
127
|
+
obs.disconnect();
|
|
128
|
+
resolve(true);
|
|
129
|
+
return;
|
|
130
|
+
}
|
|
131
|
+
requestAnimationFrame(tick);
|
|
132
|
+
};
|
|
133
|
+
tick();
|
|
134
|
+
}),
|
|
135
|
+
quiet,
|
|
136
|
+
{ timeout }
|
|
137
|
+
);
|
|
138
|
+
}
|
|
139
|
+
async function waitForAnimationsToFinish(root) {
|
|
140
|
+
await root.page().waitForFunction(
|
|
141
|
+
(el) => {
|
|
142
|
+
const animations = el.getAnimations?.({ subtree: true }) ?? [];
|
|
143
|
+
return animations.every((a) => a.playState !== "running");
|
|
144
|
+
},
|
|
145
|
+
await root.elementHandle()
|
|
146
|
+
);
|
|
147
|
+
await root.evaluate(() => new Promise((r) => requestAnimationFrame(() => requestAnimationFrame(() => r()))));
|
|
148
|
+
}
|
|
149
|
+
async function waitForUrlChange(page, prevUrl, timeout) {
|
|
150
|
+
try {
|
|
151
|
+
await page.waitForFunction((u) => location.href !== u, prevUrl, { timeout });
|
|
152
|
+
return true;
|
|
153
|
+
} catch {
|
|
154
|
+
return false;
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
async function waitUntilEnabled(page, target, timeout) {
|
|
158
|
+
await target.waitFor({ state: "attached", timeout }).catch(() => {
|
|
159
|
+
});
|
|
160
|
+
const handle = await target.elementHandle().catch(() => null);
|
|
161
|
+
if (!handle) return;
|
|
162
|
+
await page.waitForFunction(
|
|
163
|
+
(el) => {
|
|
164
|
+
if (!el || !el.isConnected) return true;
|
|
165
|
+
const aria = el.getAttribute("aria-disabled");
|
|
166
|
+
const disabled = el.disabled || aria === "true" || el.getAttribute("disabled") !== null;
|
|
167
|
+
return !disabled;
|
|
168
|
+
},
|
|
169
|
+
handle,
|
|
170
|
+
{ timeout }
|
|
171
|
+
).catch(() => {
|
|
172
|
+
});
|
|
173
|
+
}
|
|
174
|
+
async function waitAfterInteraction(page, target, opts = {}) {
|
|
175
|
+
const navTimeout = opts.navTimeout ?? 8e3;
|
|
176
|
+
const settleTimeout = opts.settleTimeout ?? 6e3;
|
|
177
|
+
const quietMs = opts.quietMs ?? 500;
|
|
178
|
+
const prevUrl = opts.prevUrl ?? page.url();
|
|
179
|
+
const kind = await elementKind(target).catch(() => "other");
|
|
180
|
+
if (kind === "link") {
|
|
181
|
+
const urlChanged = await waitForUrlChange(page, prevUrl, navTimeout);
|
|
182
|
+
if (urlChanged) {
|
|
183
|
+
await page.waitForLoadState("domcontentloaded").catch(() => {
|
|
184
|
+
});
|
|
185
|
+
await waitForDomIdle(page, { quiet: quietMs, timeout: navTimeout }).catch(() => {
|
|
186
|
+
});
|
|
187
|
+
return;
|
|
188
|
+
}
|
|
189
|
+
await waitForDomIdle(page, { quiet: quietMs }).catch(() => {
|
|
190
|
+
});
|
|
191
|
+
return;
|
|
192
|
+
}
|
|
193
|
+
if (kind === "button" && await target.isDisabled()) {
|
|
194
|
+
await Promise.race([
|
|
195
|
+
waitUntilEnabled(page, target, settleTimeout).catch(() => {
|
|
196
|
+
}),
|
|
197
|
+
target.waitFor({ state: "hidden", timeout: settleTimeout }).catch(() => {
|
|
198
|
+
}),
|
|
199
|
+
target.waitFor({ state: "detached", timeout: settleTimeout }).catch(() => {
|
|
200
|
+
}),
|
|
201
|
+
waitForUrlChange(page, prevUrl, settleTimeout).catch(() => {
|
|
202
|
+
})
|
|
203
|
+
]);
|
|
204
|
+
await sleep(1e3);
|
|
205
|
+
await waitForDomIdle(page, { quiet: quietMs }).catch(() => {
|
|
206
|
+
});
|
|
207
|
+
return;
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
async function elementKind(target) {
|
|
211
|
+
const role = await target.getAttribute("role").catch(() => null);
|
|
212
|
+
if (role === "link") return "link";
|
|
213
|
+
if (role === "button") return "button";
|
|
214
|
+
const tag = await target.evaluate((el) => el.tagName.toLowerCase()).catch(() => "");
|
|
215
|
+
if (tag === "a") return "link";
|
|
216
|
+
if (tag === "button") return "button";
|
|
217
|
+
if (tag === "input") {
|
|
218
|
+
const type = await target.getAttribute("type").catch(() => null);
|
|
219
|
+
if (type === "button" || type === "submit" || type === "reset") return "button";
|
|
220
|
+
}
|
|
221
|
+
return "other";
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
// src/field/calendar.ts
|
|
225
|
+
async function getDialog(root, options) {
|
|
226
|
+
const role = await root.getAttribute("role", options).catch(() => null);
|
|
227
|
+
if (role !== "combobox") return null;
|
|
228
|
+
const ariaControls = await root.getAttribute("aria-controls", options).catch(() => null);
|
|
229
|
+
if (!ariaControls) return null;
|
|
230
|
+
const calendar = root.page().locator(`#${ariaControls}`);
|
|
231
|
+
if (await calendar.count() === 0) {
|
|
232
|
+
await root.click(options);
|
|
233
|
+
}
|
|
234
|
+
const count = await calendar.count();
|
|
235
|
+
return count > 0 ? calendar : null;
|
|
236
|
+
}
|
|
237
|
+
async function isCalendarGrid(grid) {
|
|
238
|
+
const cells = grid.locator('td, [role="gridcell"]');
|
|
239
|
+
const cellCount = await cells.count();
|
|
240
|
+
if (cellCount < 28 || cellCount > 80) return false;
|
|
241
|
+
const texts = await cells.allTextContents();
|
|
242
|
+
const days = texts.map((t) => t.trim()).filter((t) => /^\d{1,2}$/.test(t)).map(Number).filter((n) => n >= 1 && n <= 31);
|
|
243
|
+
const last = days.reduce((max, cur) => cur === max + 1 ? cur : max, 0);
|
|
244
|
+
return last >= 28;
|
|
245
|
+
}
|
|
246
|
+
async function getCalendar(root, options) {
|
|
247
|
+
const gridSelector = 'table, [role="grid"]';
|
|
248
|
+
let container = await root.locator(gridSelector).count() > 0 ? root : await getDialog(root, options);
|
|
249
|
+
if (!container && await isCalendarGrid(root)) {
|
|
250
|
+
return { calendar: root, tables: [root] };
|
|
251
|
+
}
|
|
252
|
+
if (!container) return null;
|
|
253
|
+
const found = await container.locator(gridSelector).all();
|
|
254
|
+
const tables = [];
|
|
255
|
+
if (await isCalendarGrid(container)) {
|
|
256
|
+
tables.push(container);
|
|
257
|
+
}
|
|
258
|
+
for (const grid of found) {
|
|
259
|
+
if (await isCalendarGrid(grid)) {
|
|
260
|
+
tables.push(grid);
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
const uniqueTables = tables.filter((t, i, self) => self.indexOf(t) === i);
|
|
264
|
+
return uniqueTables.length > 0 ? { calendar: container, tables: uniqueTables } : null;
|
|
265
|
+
}
|
|
266
|
+
function uniqueMonthYearPairs(pairs) {
|
|
267
|
+
const map = pairs.reduce(
|
|
268
|
+
(acc, r) => acc.set(`${r.year}-${r.month}`, r),
|
|
269
|
+
/* @__PURE__ */ new Map()
|
|
270
|
+
);
|
|
271
|
+
return Array.from(map.values());
|
|
272
|
+
}
|
|
273
|
+
function inferYearForMonth(target, month) {
|
|
274
|
+
const ty = target.getFullYear();
|
|
275
|
+
const tm = target.getMonth();
|
|
276
|
+
const targetTotal = ty * 12 + tm;
|
|
277
|
+
const candidates = [ty - 1, ty, ty + 1].map((y) => ({ year: y, total: y * 12 + month }));
|
|
278
|
+
candidates.sort((a, b) => Math.abs(a.total - targetTotal) - Math.abs(b.total - targetTotal));
|
|
279
|
+
return candidates[0].year;
|
|
280
|
+
}
|
|
281
|
+
async function getCurrentMonthsAndYears(root, target) {
|
|
282
|
+
const lang = await root.page().locator("html").getAttribute("lang").catch(() => void 0);
|
|
283
|
+
const locales = lang && !lang.startsWith("en") ? [lang, "en-US"] : ["en-US"];
|
|
284
|
+
const text = await root.innerText();
|
|
285
|
+
const monthSets = locales.map(getMonthNames);
|
|
286
|
+
const pairs = monthSets.flatMap((months2) => {
|
|
287
|
+
const matches = text.matchAll(new RegExp(`(${months2.join("|")})\\W*(\\d{4})`, "gi"));
|
|
288
|
+
return Array.from(matches).map((m) => ({
|
|
289
|
+
month: months2.findIndex((x) => x.toLowerCase() === m[1].toLowerCase()),
|
|
290
|
+
year: Number.parseInt(m[2], 10)
|
|
291
|
+
})).filter((r) => r.month !== -1);
|
|
292
|
+
});
|
|
293
|
+
if (pairs.length) {
|
|
294
|
+
return uniqueMonthYearPairs(pairs);
|
|
295
|
+
}
|
|
296
|
+
const months = monthSets.flatMap((ms) => ms.map((name, i) => new RegExp(name, "i").test(text) ? i : -1)).filter(uniqueItem).filter((i) => i >= 0).sort((a, b) => a - b);
|
|
297
|
+
const years = (text.match(/\b20\d{2}\b/g) ?? []).map((y) => Number.parseInt(y, 10)).filter(uniqueItem).sort((a, b) => a - b);
|
|
298
|
+
if (!months.length) return [];
|
|
299
|
+
if (years.length === 1) {
|
|
300
|
+
return months.map((month) => ({ month, year: years[0] }));
|
|
301
|
+
}
|
|
302
|
+
if (years.length === 2) {
|
|
303
|
+
return months.map((month) => ({ month, year: month >= 6 ? years[0] : years[1] })).sort((a, b) => a.year * 12 + a.month - (b.year * 12 + b.month));
|
|
304
|
+
}
|
|
305
|
+
return months.map((month) => ({ month, year: inferYearForMonth(target, month) })).sort((a, b) => a.year * 12 + a.month - (b.year * 12 + b.month));
|
|
306
|
+
}
|
|
307
|
+
async function navigateToMonth(root, target, options) {
|
|
308
|
+
const currentMonths = await getCurrentMonthsAndYears(root, target);
|
|
309
|
+
if (currentMonths.length === 0) return false;
|
|
310
|
+
const targetTotal = target.getFullYear() * 12 + target.getMonth();
|
|
311
|
+
if (currentMonths.find((m) => m.year * 12 + m.month === targetTotal)) {
|
|
312
|
+
return true;
|
|
313
|
+
}
|
|
314
|
+
const firstMonthTotal = currentMonths[0].year * 12 + currentMonths[0].month;
|
|
315
|
+
const diff = targetTotal - firstMonthTotal;
|
|
316
|
+
const btn = diff < 0 ? root.locator('button[aria-label*="prev"], button[class*="prev"]').filter({ visible: true }).first() : root.locator('button[aria-label*="next"], button[class*="next"]').filter({ visible: true }).first();
|
|
317
|
+
if (!await btn.count()) return false;
|
|
318
|
+
for (let i = 0; i < Math.abs(diff); i++) {
|
|
319
|
+
await btn.click(options);
|
|
320
|
+
await root.page().waitForTimeout(options?.wait ?? 50);
|
|
321
|
+
}
|
|
322
|
+
await waitForAnimationsToFinish(root);
|
|
323
|
+
const afterMonths = await getCurrentMonthsAndYears(root, target);
|
|
324
|
+
if (afterMonths.some((m) => m.year * 12 + m.month === targetTotal)) return true;
|
|
325
|
+
if ((options?.retry ?? 0) < 3) {
|
|
326
|
+
const retry = (options?.retry ?? 0) + 1;
|
|
327
|
+
return await navigateToMonth(root, target, { ...options, wait: 50 + 50 * retry, retry });
|
|
328
|
+
}
|
|
329
|
+
return false;
|
|
330
|
+
}
|
|
331
|
+
async function setDayByAriaLabel(table, value, options) {
|
|
332
|
+
const formats = ["DD/MM/YYYY", "MM/DD/YYYY", "DD-MM-YYYY", "YYYY-MM-DD"];
|
|
333
|
+
const candidateLabels = [value.toDateString(), ...formats.map((fmt) => formatDate(value, fmt))];
|
|
334
|
+
const cells = (await Promise.all(
|
|
335
|
+
candidateLabels.map(async (label) => {
|
|
336
|
+
const cell = table.locator(`[aria-label="${label}"], [aria-label*="${label}"]`).first();
|
|
337
|
+
return await cell.isVisible(options) ? cell : null;
|
|
338
|
+
})
|
|
339
|
+
)).filter((l) => l !== null);
|
|
340
|
+
if (cells.length === 0) return false;
|
|
341
|
+
if (cells.length === 1) {
|
|
342
|
+
await cells[0].click(options);
|
|
343
|
+
return true;
|
|
344
|
+
}
|
|
345
|
+
const probeDate = new Date(value.getFullYear(), value.getMonth(), 22);
|
|
346
|
+
const probeResults = await Promise.all(
|
|
347
|
+
formats.map(async (fmt) => {
|
|
348
|
+
const label = formatDate(probeDate, fmt);
|
|
349
|
+
const cell = table.locator(`[aria-label="${label}"], [aria-label*="${label}"]`).first();
|
|
350
|
+
return await cell.isVisible(options) ? fmt : null;
|
|
351
|
+
})
|
|
352
|
+
);
|
|
353
|
+
const finalFormat = probeResults.find((fmt) => fmt !== null);
|
|
354
|
+
const finalCell = finalFormat ? table.locator(`[aria-label="${formatDate(value, finalFormat)}"], [aria-label*="${formatDate(value, finalFormat)}"]`).first() : cells[0];
|
|
355
|
+
await finalCell.click(options);
|
|
356
|
+
return true;
|
|
357
|
+
}
|
|
358
|
+
async function setDayByByCellText(table, value, options) {
|
|
359
|
+
const day = value.getDate();
|
|
360
|
+
const cells = table.locator('td, [role="gridcell"]').filter({ visible: true });
|
|
361
|
+
const allTexts = await cells.allInnerTexts();
|
|
362
|
+
const foundIndices = allTexts.map((text, i) => text.trim() === String(day) ? i : -1).filter((i) => i !== -1);
|
|
363
|
+
if (foundIndices.length === 0) return false;
|
|
364
|
+
const index = foundIndices.length === 1 || day < 15 ? foundIndices[0] : foundIndices[foundIndices.length - 1];
|
|
365
|
+
await cells.nth(index).click(options);
|
|
366
|
+
return true;
|
|
367
|
+
}
|
|
368
|
+
async function setDates(calendar, tables, dates, options) {
|
|
369
|
+
let method = void 0;
|
|
370
|
+
for (const date of dates) {
|
|
371
|
+
if (!await navigateToMonth(calendar, date, options)) {
|
|
372
|
+
throw new Error(`Failed to navigate to "${formatDateForInput(date, "month")}"`);
|
|
373
|
+
}
|
|
374
|
+
const currentMonths = await getCurrentMonthsAndYears(calendar, date);
|
|
375
|
+
const targetTotal = date.getFullYear() * 12 + date.getMonth();
|
|
376
|
+
const tableIndex = currentMonths.findIndex((m) => m.year * 12 + m.month === targetTotal);
|
|
377
|
+
const table = tables[tableIndex] ?? tables[0];
|
|
378
|
+
if (method !== "text" && await setDayByAriaLabel(table, date, options)) {
|
|
379
|
+
method ??= "aria";
|
|
380
|
+
continue;
|
|
381
|
+
}
|
|
382
|
+
if (method !== "aria" && await setDayByByCellText(table, date, options)) {
|
|
383
|
+
method ??= "text";
|
|
384
|
+
continue;
|
|
385
|
+
}
|
|
386
|
+
throw new Error(`Failed to set date "${formatDateForInput(date, "date")}"`);
|
|
387
|
+
}
|
|
388
|
+
}
|
|
389
|
+
async function setCalendarDate({ el, tag }, value, options) {
|
|
390
|
+
if (!(value instanceof Date) && !isArray(value, isDate) && !isRange(value, isDate)) return false;
|
|
391
|
+
const dates = isArray(value, isDate) ? value : isRange(value) ? [value.from, value.to] : [value];
|
|
392
|
+
const { calendar, tables } = await getCalendar(el, options) ?? {};
|
|
393
|
+
if (!calendar || !tables || tables.length === 0) return false;
|
|
394
|
+
try {
|
|
395
|
+
await setDates(calendar, tables, dates, options);
|
|
396
|
+
} finally {
|
|
397
|
+
if (tag === "input") {
|
|
398
|
+
await el.page().keyboard.press("Escape").catch();
|
|
399
|
+
await el.blur().catch();
|
|
400
|
+
}
|
|
401
|
+
}
|
|
402
|
+
return true;
|
|
403
|
+
}
|
|
404
|
+
async function clearSelect(el, opts) {
|
|
405
|
+
const isMultiple = await el.evaluate((e) => e.multiple, opts);
|
|
406
|
+
const options = await el.evaluate(
|
|
407
|
+
(e) => Array.from(e.options).map((o) => ({
|
|
408
|
+
value: o.value,
|
|
409
|
+
disabled: o.disabled
|
|
410
|
+
})),
|
|
411
|
+
opts
|
|
412
|
+
);
|
|
413
|
+
if (isMultiple) {
|
|
414
|
+
await el.selectOption([], opts);
|
|
415
|
+
return;
|
|
416
|
+
}
|
|
417
|
+
const empty = options.find((o) => o.value === "" && !o.disabled);
|
|
418
|
+
if (empty) {
|
|
419
|
+
await el.selectOption({ value: "" }, opts);
|
|
420
|
+
return;
|
|
421
|
+
}
|
|
422
|
+
const firstEnabled = options.find((o) => !o.disabled);
|
|
423
|
+
if (firstEnabled) {
|
|
424
|
+
await el.selectOption({ value: firstEnabled.value }, opts);
|
|
425
|
+
}
|
|
426
|
+
}
|
|
427
|
+
async function multiSelect(el, value, opts) {
|
|
428
|
+
const isMultiple = await el.evaluate((e) => e.multiple, opts);
|
|
429
|
+
if (!isMultiple) throw new Error("Select is not multiple");
|
|
430
|
+
const requested = value.map((v) => String(v));
|
|
431
|
+
const selected = await el.selectOption(requested, opts);
|
|
432
|
+
const missing = diffArray(selected, requested);
|
|
433
|
+
if (missing.length > 0) {
|
|
434
|
+
throw new Error(`Options not found in select: ${missing.join(", ")}`);
|
|
435
|
+
}
|
|
436
|
+
}
|
|
437
|
+
async function singleSelect(el, value, opts) {
|
|
438
|
+
const result = await el.selectOption(value, opts);
|
|
439
|
+
if (result.length === 0) {
|
|
440
|
+
throw new Error(`Option "${value}" not found in select`);
|
|
441
|
+
}
|
|
442
|
+
}
|
|
443
|
+
async function selectNative({ el, tag }, value, options) {
|
|
444
|
+
if (tag !== "select") return false;
|
|
445
|
+
if (value instanceof Date || isRange(value)) {
|
|
446
|
+
return false;
|
|
447
|
+
}
|
|
448
|
+
if (value === null) {
|
|
449
|
+
await clearSelect(el, options);
|
|
450
|
+
return true;
|
|
451
|
+
}
|
|
452
|
+
if (Array.isArray(value)) {
|
|
453
|
+
if (value.some((v) => v instanceof Date)) return false;
|
|
454
|
+
await multiSelect(el, value, options);
|
|
455
|
+
return true;
|
|
456
|
+
}
|
|
457
|
+
await singleSelect(el, String(value), options);
|
|
458
|
+
return true;
|
|
459
|
+
}
|
|
460
|
+
|
|
461
|
+
// src/field/date-group.ts
|
|
462
|
+
async function getCandidateLocs(el, options) {
|
|
463
|
+
const candidates = await el.locator("input, select").all();
|
|
464
|
+
if (candidates.length < 2 || candidates.length > 3) return [];
|
|
465
|
+
return Promise.all(
|
|
466
|
+
candidates.map(async (c) => {
|
|
467
|
+
const info = await c.evaluate((node) => {
|
|
468
|
+
const e = node;
|
|
469
|
+
const attrs = {};
|
|
470
|
+
for (const attr of e.attributes) {
|
|
471
|
+
attrs[attr.name] = attr.value;
|
|
472
|
+
}
|
|
473
|
+
let options2 = [];
|
|
474
|
+
if (e.tagName.toLowerCase() === "select") {
|
|
475
|
+
options2 = Array.from(e.options).map((o) => ({
|
|
476
|
+
value: o.value,
|
|
477
|
+
text: o.text
|
|
478
|
+
}));
|
|
479
|
+
}
|
|
480
|
+
return {
|
|
481
|
+
tag: e.tagName.toLowerCase(),
|
|
482
|
+
type: e.getAttribute("type"),
|
|
483
|
+
name: e.getAttribute("name"),
|
|
484
|
+
id: e.getAttribute("id"),
|
|
485
|
+
ariaLabel: e.getAttribute("aria-label"),
|
|
486
|
+
placeholder: e.getAttribute("placeholder"),
|
|
487
|
+
min: e.getAttribute("min"),
|
|
488
|
+
max: e.getAttribute("max"),
|
|
489
|
+
inputMode: e.getAttribute("inputmode"),
|
|
490
|
+
attrs,
|
|
491
|
+
options: options2
|
|
492
|
+
};
|
|
493
|
+
}, options);
|
|
494
|
+
return { el: c, ...info };
|
|
495
|
+
})
|
|
496
|
+
);
|
|
497
|
+
}
|
|
498
|
+
function scoreByAttributes(candidateLocs) {
|
|
499
|
+
const scores = candidateLocs.map(() => ({ day: 0, month: 0, year: 0 }));
|
|
500
|
+
candidateLocs.forEach((loc, i) => {
|
|
501
|
+
const text = [loc.name, loc.id, loc.ariaLabel, loc.placeholder, ...Object.values(loc.attrs)].join(" ").toLowerCase();
|
|
502
|
+
if (/\b(day|dd|d)\b/i.test(text)) scores[i].day += 5;
|
|
503
|
+
if (/\b(month|mm|m)\b/i.test(text)) scores[i].month += 5;
|
|
504
|
+
if (/\b(year|yyyy|yy|y)\b/i.test(text)) scores[i].year += 5;
|
|
505
|
+
if (loc.max) {
|
|
506
|
+
const max = parseInt(loc.max, 10);
|
|
507
|
+
if (max >= 1 && max <= 31) scores[i].day += 2;
|
|
508
|
+
if (max >= 1 && max <= 12) scores[i].month += 2;
|
|
509
|
+
if (max > 1900) scores[i].year += 2;
|
|
510
|
+
}
|
|
511
|
+
if (loc.tag === "select") {
|
|
512
|
+
if (loc.options.length >= 12 && loc.options.length <= 13) {
|
|
513
|
+
scores[i].month += 3;
|
|
514
|
+
}
|
|
515
|
+
const allNumeric = loc.options.every((o) => !isNaN(parseInt(o.value, 10)) || !o.value);
|
|
516
|
+
if (allNumeric && loc.options.length >= 12 && loc.options.length <= 13) {
|
|
517
|
+
scores[i].month += 2;
|
|
518
|
+
}
|
|
519
|
+
}
|
|
520
|
+
});
|
|
521
|
+
return scores;
|
|
522
|
+
}
|
|
523
|
+
async function behavioralProbe(candidateLocs, scores, options) {
|
|
524
|
+
const sorted = [...scores].sort((a, b) => Math.max(b.day, b.month, b.year) - Math.max(a.day, a.month, a.year));
|
|
525
|
+
if (sorted[0].day < 2 && sorted[0].month < 2 && sorted[0].year < 2) {
|
|
526
|
+
for (let i = 0; i < candidateLocs.length; i++) {
|
|
527
|
+
const loc = candidateLocs[i];
|
|
528
|
+
if (loc.tag === "input") {
|
|
529
|
+
const can_be_day = await loc.el.evaluate((node) => {
|
|
530
|
+
const e = node;
|
|
531
|
+
const old = e.value;
|
|
532
|
+
e.value = "31";
|
|
533
|
+
const valid = e.checkValidity();
|
|
534
|
+
e.value = old;
|
|
535
|
+
return valid;
|
|
536
|
+
}, options);
|
|
537
|
+
if (can_be_day) scores[i].day += 1;
|
|
538
|
+
const cannot_be_day = await loc.el.evaluate((node) => {
|
|
539
|
+
const e = node;
|
|
540
|
+
const old = e.value;
|
|
541
|
+
e.value = "32";
|
|
542
|
+
const valid = !e.checkValidity();
|
|
543
|
+
e.value = old;
|
|
544
|
+
return valid;
|
|
545
|
+
}, options);
|
|
546
|
+
if (cannot_be_day) scores[i].day += 1;
|
|
547
|
+
const can_be_month = await loc.el.evaluate((node) => {
|
|
548
|
+
const e = node;
|
|
549
|
+
const old = e.value;
|
|
550
|
+
e.value = "12";
|
|
551
|
+
const valid = e.checkValidity();
|
|
552
|
+
e.value = old;
|
|
553
|
+
return valid;
|
|
554
|
+
}, options);
|
|
555
|
+
if (can_be_month) scores[i].month += 1;
|
|
556
|
+
const cannot_be_month = await loc.el.evaluate((node) => {
|
|
557
|
+
const e = node;
|
|
558
|
+
const old = e.value;
|
|
559
|
+
e.value = "13";
|
|
560
|
+
const valid = !e.checkValidity();
|
|
561
|
+
e.value = old;
|
|
562
|
+
return valid;
|
|
563
|
+
}, options);
|
|
564
|
+
if (cannot_be_month) scores[i].month += 1;
|
|
565
|
+
const can_be_year = await loc.el.evaluate((node) => {
|
|
566
|
+
const e = node;
|
|
567
|
+
const old = e.value;
|
|
568
|
+
e.value = "2024";
|
|
569
|
+
const valid = e.checkValidity();
|
|
570
|
+
e.value = old;
|
|
571
|
+
return valid;
|
|
572
|
+
}, options);
|
|
573
|
+
if (can_be_year) scores[i].year += 1;
|
|
574
|
+
}
|
|
575
|
+
}
|
|
576
|
+
}
|
|
577
|
+
}
|
|
578
|
+
function applyTieBreakers(candidateLocs, scores) {
|
|
579
|
+
if (candidateLocs.length === 3) {
|
|
580
|
+
scores[0].day += 0.1;
|
|
581
|
+
scores[1].month += 0.1;
|
|
582
|
+
scores[2].year += 0.1;
|
|
583
|
+
}
|
|
584
|
+
}
|
|
585
|
+
function resolveDateFields(scores) {
|
|
586
|
+
const result = {};
|
|
587
|
+
const used = /* @__PURE__ */ new Set();
|
|
588
|
+
for (const field of ["year", "month", "day"]) {
|
|
589
|
+
let bestIdx = -1;
|
|
590
|
+
let bestScore = -1;
|
|
591
|
+
for (let i = 0; i < scores.length; i++) {
|
|
592
|
+
if (!used.has(i) && scores[i][field] > bestScore) {
|
|
593
|
+
bestScore = scores[i][field];
|
|
594
|
+
bestIdx = i;
|
|
595
|
+
}
|
|
596
|
+
}
|
|
597
|
+
if (bestIdx !== -1 && bestScore > 0) {
|
|
598
|
+
result[field] = bestIdx;
|
|
599
|
+
used.add(bestIdx);
|
|
600
|
+
}
|
|
601
|
+
}
|
|
602
|
+
if (result.day === void 0 || result.month === void 0 || result.year === void 0) {
|
|
603
|
+
return null;
|
|
604
|
+
}
|
|
605
|
+
return result;
|
|
606
|
+
}
|
|
607
|
+
async function setMonthField(monthLoc, monthVal, options) {
|
|
608
|
+
if (monthLoc.tag === "select") {
|
|
609
|
+
const options_list = monthLoc.options;
|
|
610
|
+
const valueMatch = options_list.find((o) => parseInt(o.value, 10) === monthVal);
|
|
611
|
+
if (valueMatch) {
|
|
612
|
+
await monthLoc.el.selectOption(valueMatch.value, options);
|
|
613
|
+
} else {
|
|
614
|
+
const offset = options_list.length === 13 ? 1 : 0;
|
|
615
|
+
await monthLoc.el.selectOption({ index: monthVal - 1 + offset }, options);
|
|
616
|
+
}
|
|
617
|
+
} else {
|
|
618
|
+
await monthLoc.el.fill(String(monthVal), options);
|
|
619
|
+
}
|
|
620
|
+
}
|
|
621
|
+
async function clearFields(locs, options) {
|
|
622
|
+
for (const loc of locs) {
|
|
623
|
+
if (loc.tag === "select") {
|
|
624
|
+
await clearSelect(loc.el, options);
|
|
625
|
+
} else {
|
|
626
|
+
await loc.el.clear(options);
|
|
627
|
+
}
|
|
628
|
+
}
|
|
629
|
+
}
|
|
630
|
+
async function setDateGroup({ el, tag }, value, options) {
|
|
631
|
+
if (!(value instanceof Date) && value !== null) return false;
|
|
632
|
+
if (tag === "input" || tag === "textarea" || tag === "select") return false;
|
|
633
|
+
const candidateLocs = await getCandidateLocs(el, options);
|
|
634
|
+
if (candidateLocs.length === 0) return false;
|
|
635
|
+
if (value === null) {
|
|
636
|
+
await clearFields(candidateLocs, options);
|
|
637
|
+
return true;
|
|
638
|
+
}
|
|
639
|
+
const scores = scoreByAttributes(candidateLocs);
|
|
640
|
+
await behavioralProbe(candidateLocs, scores, options);
|
|
641
|
+
applyTieBreakers(candidateLocs, scores);
|
|
642
|
+
const result = resolveDateFields(scores);
|
|
643
|
+
if (!result) {
|
|
644
|
+
const candidatesStr = candidateLocs.map((c) => `${c.tag}[name=${c.name}]`).join(", ");
|
|
645
|
+
throw new Error(`Could not reliably detect date fields for ${tag}. Detected candidates: ${candidatesStr}`);
|
|
646
|
+
}
|
|
647
|
+
const dayVal = value.getDate();
|
|
648
|
+
const monthVal = value.getMonth() + 1;
|
|
649
|
+
const yearVal = value.getFullYear();
|
|
650
|
+
await candidateLocs[result.day].el.fill(String(dayVal), options);
|
|
651
|
+
await setMonthField(candidateLocs[result.month], monthVal, options);
|
|
652
|
+
await candidateLocs[result.year].el.fill(String(yearVal), options);
|
|
653
|
+
return true;
|
|
654
|
+
}
|
|
655
|
+
function pad2(n) {
|
|
656
|
+
return String(n).padStart(2, "0");
|
|
657
|
+
}
|
|
658
|
+
function buildDateString(date, order, sep, pad) {
|
|
659
|
+
const d = date.getDate();
|
|
660
|
+
const m = date.getMonth() + 1;
|
|
661
|
+
const y = date.getFullYear();
|
|
662
|
+
const parts = {
|
|
663
|
+
day: pad ? pad2(d) : String(d),
|
|
664
|
+
month: pad ? pad2(m) : String(m),
|
|
665
|
+
year: String(y)
|
|
666
|
+
};
|
|
667
|
+
return order.map((p) => parts[p]).join(sep);
|
|
668
|
+
}
|
|
669
|
+
function parseDateString(value, order, sep) {
|
|
670
|
+
const raw = value.trim();
|
|
671
|
+
if (!raw) return null;
|
|
672
|
+
const tokens = raw.split(sep);
|
|
673
|
+
if (tokens.length !== 3) return null;
|
|
674
|
+
const nums = tokens.map((t) => Number(t));
|
|
675
|
+
if (nums.some((n) => !Number.isFinite(n))) return null;
|
|
676
|
+
const map = { day: 0, month: 0, year: 0 };
|
|
677
|
+
for (let i = 0; i < 3; i++) map[order[i]] = nums[i];
|
|
678
|
+
const year = map.year;
|
|
679
|
+
const month = map.month;
|
|
680
|
+
const day = map.day;
|
|
681
|
+
if (month < 1 || month > 12) return null;
|
|
682
|
+
if (day < 1 || day > 31) return null;
|
|
683
|
+
const dt = new Date(year, month - 1, day);
|
|
684
|
+
if (dt.getFullYear() !== year || dt.getMonth() !== month - 1 || dt.getDate() !== day) return null;
|
|
685
|
+
return dt;
|
|
686
|
+
}
|
|
687
|
+
async function inferLocaleAndPattern(el, options) {
|
|
688
|
+
return el.evaluate(() => {
|
|
689
|
+
const lang = document.documentElement.getAttribute("lang") || navigator.language || "en-US";
|
|
690
|
+
const dtf = new Intl.DateTimeFormat(lang, { year: "numeric", month: "2-digit", day: "2-digit" });
|
|
691
|
+
const parts = dtf.formatToParts(new Date(2033, 10, 22));
|
|
692
|
+
const order = [];
|
|
693
|
+
let sep = "/";
|
|
694
|
+
for (const p of parts) {
|
|
695
|
+
if (p.type === "day" || p.type === "month" || p.type === "year") order.push(p.type);
|
|
696
|
+
if (p.type === "literal") {
|
|
697
|
+
const lit = p.value.trim();
|
|
698
|
+
if (lit) sep = lit;
|
|
699
|
+
}
|
|
700
|
+
}
|
|
701
|
+
const finalOrder = order.length === 3 ? order : ["day", "month", "year"];
|
|
702
|
+
return { locale: lang, order: finalOrder, sep };
|
|
703
|
+
}, options);
|
|
704
|
+
}
|
|
705
|
+
async function fillAndReadBack(el, s, options, nextInput) {
|
|
706
|
+
await el.clear(options);
|
|
707
|
+
await el.fill(s, options);
|
|
708
|
+
if (nextInput) {
|
|
709
|
+
await nextInput.focus(options);
|
|
710
|
+
} else {
|
|
711
|
+
await el.evaluate((el2) => el2.blur(), options);
|
|
712
|
+
}
|
|
713
|
+
await el.evaluate(() => new Promise(requestAnimationFrame));
|
|
714
|
+
return await el.inputValue(options);
|
|
715
|
+
}
|
|
716
|
+
function isAmbiguous(value, value2) {
|
|
717
|
+
if (value2 && value instanceof Date) value = [value, value2];
|
|
718
|
+
return toDateArray(value).every((date) => date.getDate() <= 12);
|
|
719
|
+
}
|
|
720
|
+
function toDateArray(value) {
|
|
721
|
+
return isRange(value) ? [value.from, value.to] : isArray(value) ? value : [value];
|
|
722
|
+
}
|
|
723
|
+
async function setDateValue(el, value, order, sep, pad, options, nextInput) {
|
|
724
|
+
const dates = toDateArray(value);
|
|
725
|
+
const glue = isRange(value) ? " - " : ",";
|
|
726
|
+
const s = dates.map((d) => buildDateString(d, order, sep, pad)).join(glue);
|
|
727
|
+
const back = await fillAndReadBack(el, s, options, nextInput);
|
|
728
|
+
if (!back) return false;
|
|
729
|
+
const backParts = back.split(glue);
|
|
730
|
+
const failed = backParts.length !== dates.length || dates.some((date, i) => {
|
|
731
|
+
const part = backParts[i]?.trim();
|
|
732
|
+
const parsed = parseDateString(part, order, sep);
|
|
733
|
+
return !parsed || !sameYMD(parsed, date);
|
|
734
|
+
});
|
|
735
|
+
return !failed;
|
|
736
|
+
}
|
|
737
|
+
async function tryProbe(el, value, order, sep, pad, options, nextInput) {
|
|
738
|
+
const baseDate = isRange(value) ? value.from : isArray(value) ? value[0] : value;
|
|
739
|
+
const y = baseDate.getFullYear();
|
|
740
|
+
const m = baseDate.getMonth();
|
|
741
|
+
const probeMonths = [m, m - 1, m + 1];
|
|
742
|
+
for (const month of probeMonths) {
|
|
743
|
+
const probeValue = isRange(value) ? { from: new Date(y, month, 22), to: new Date(y, month, 23) } : new Date(y, month, 22);
|
|
744
|
+
const success = await setDateValue(el, probeValue, order, sep, pad, options, nextInput);
|
|
745
|
+
if (success) return true;
|
|
746
|
+
}
|
|
747
|
+
return null;
|
|
748
|
+
}
|
|
749
|
+
function sameYMD(a, b) {
|
|
750
|
+
return a.getFullYear() === b.getFullYear() && a.getMonth() === b.getMonth() && a.getDate() === b.getDate();
|
|
751
|
+
}
|
|
752
|
+
async function formatCombinations(el, options) {
|
|
753
|
+
const { order: localeOrder, sep: localeSep } = await inferLocaleAndPattern(el, options);
|
|
754
|
+
const orders = [
|
|
755
|
+
localeOrder,
|
|
756
|
+
["year", "month", "day"],
|
|
757
|
+
// ISO order
|
|
758
|
+
["day", "month", "year"],
|
|
759
|
+
["month", "day", "year"]
|
|
760
|
+
];
|
|
761
|
+
const seenOrders = /* @__PURE__ */ new Set();
|
|
762
|
+
const uniqueOrders = [];
|
|
763
|
+
for (const o of orders) {
|
|
764
|
+
const key = o.join(",");
|
|
765
|
+
if (!seenOrders.has(key)) {
|
|
766
|
+
seenOrders.add(key);
|
|
767
|
+
uniqueOrders.push(o);
|
|
768
|
+
}
|
|
769
|
+
}
|
|
770
|
+
const seps = Array.from(/* @__PURE__ */ new Set([localeSep, "-", "/", "."]));
|
|
771
|
+
const pads = [true, false];
|
|
772
|
+
const combinations = cartesian(uniqueOrders, seps, pads);
|
|
773
|
+
const score = ([o, s]) => o.join(s) === localeOrder.join(localeSep) ? 0 : o.join(s) === "year-month-day" ? 1 : 2;
|
|
774
|
+
combinations.sort((a, b) => score(a) - score(b));
|
|
775
|
+
return { combinations, localeSep };
|
|
776
|
+
}
|
|
777
|
+
async function setInputValue(el, value, el2, value2, options) {
|
|
778
|
+
if (await el.evaluate((el3) => el3.readOnly, options)) return false;
|
|
779
|
+
if (el2 && await el2.evaluate((el3) => el3.readOnly, options)) return false;
|
|
780
|
+
const { combinations, localeSep } = await formatCombinations(el, options);
|
|
781
|
+
let fallbackMatch = null;
|
|
782
|
+
for (const [order, sep, pad] of combinations) {
|
|
783
|
+
if (sep !== localeSep && !pad) continue;
|
|
784
|
+
const success = await setDateValue(el, value, order, sep, pad, options, el2);
|
|
785
|
+
if (!success) continue;
|
|
786
|
+
if (el2 && value2) {
|
|
787
|
+
const success2 = await setDateValue(el2, value2, order, sep, pad, options);
|
|
788
|
+
if (!success2) continue;
|
|
789
|
+
}
|
|
790
|
+
if (!isAmbiguous(value, value2)) return true;
|
|
791
|
+
const probeResult = await tryProbe(el, value, order, sep, pad, options, el2);
|
|
792
|
+
if (probeResult === true) {
|
|
793
|
+
await setDateValue(el, value, order, sep, pad, options, el2);
|
|
794
|
+
if (el2 && value2) await setDateValue(el2, value2, order, sep, pad, options);
|
|
795
|
+
return true;
|
|
796
|
+
}
|
|
797
|
+
if (probeResult === null && !fallbackMatch) fallbackMatch = [order, sep, pad];
|
|
798
|
+
}
|
|
799
|
+
if (fallbackMatch) {
|
|
800
|
+
const [order, sep, pad] = fallbackMatch;
|
|
801
|
+
const success = await setDateValue(el, value, order, sep, pad, options, el2);
|
|
802
|
+
if (el2 && value2) {
|
|
803
|
+
const success2 = await setDateValue(el2, value2, order, sep, pad, options);
|
|
804
|
+
return success && success2;
|
|
805
|
+
}
|
|
806
|
+
return success;
|
|
807
|
+
}
|
|
808
|
+
return false;
|
|
809
|
+
}
|
|
810
|
+
async function setDateTextInput({ el, tag, type }, value, options) {
|
|
811
|
+
if (!(value instanceof Date) && !isArray(value, isDate) && !isRange(value, isDate)) return false;
|
|
812
|
+
if (tag === "textarea" || tag === "select") return false;
|
|
813
|
+
if (tag !== "input" && isRange(value, isDate)) {
|
|
814
|
+
const inputs = el.locator("input[type=text], input:not([type])");
|
|
815
|
+
if (await inputs.count() === 2) {
|
|
816
|
+
return await setInputValue(inputs.nth(0), value.from, inputs.nth(1), value.to, options);
|
|
817
|
+
}
|
|
818
|
+
}
|
|
819
|
+
if (tag === "input" && type && type !== "text") return false;
|
|
820
|
+
let input = el;
|
|
821
|
+
if (tag !== "input") {
|
|
822
|
+
const inputs = el.locator("input[type=text], input:not([type])");
|
|
823
|
+
if (await inputs.count() !== 1) return false;
|
|
824
|
+
input = inputs.nth(0);
|
|
825
|
+
}
|
|
826
|
+
return await setInputValue(input, value, void 0, void 0, options);
|
|
827
|
+
}
|
|
828
|
+
|
|
829
|
+
// src/field/native-checkbox.ts
|
|
830
|
+
async function setNativeCheckbox({ el, tag, type }, value, options) {
|
|
831
|
+
if (typeof value !== "boolean" && value !== null) return false;
|
|
832
|
+
if (tag === "select" || tag === "textarea" || tag === "button") return false;
|
|
833
|
+
let target = el;
|
|
834
|
+
if (tag !== "input" || type !== "checkbox" && type !== "radio") {
|
|
835
|
+
target = el.locator("input[type=checkbox], input[type=radio]");
|
|
836
|
+
if (await target.count() !== 1) return false;
|
|
837
|
+
}
|
|
838
|
+
if (value) {
|
|
839
|
+
await target.check(options);
|
|
840
|
+
} else {
|
|
841
|
+
await target.uncheck(options);
|
|
842
|
+
}
|
|
843
|
+
return true;
|
|
844
|
+
}
|
|
845
|
+
async function setSingleDate({ el, tag, type }, value, options) {
|
|
846
|
+
let target = el;
|
|
847
|
+
let targetType = type;
|
|
848
|
+
if (tag !== "input" || !type || !["date", "datetime-local", "month", "week", "time"].includes(type)) {
|
|
849
|
+
const inputs = el.locator(
|
|
850
|
+
"input[type=date], input[type=datetime-local], input[type=month], input[type=week], input[type=time]"
|
|
851
|
+
);
|
|
852
|
+
if (await inputs.count() === 1) {
|
|
853
|
+
const isVisible = await inputs.evaluate((e) => {
|
|
854
|
+
const style = window.getComputedStyle(e);
|
|
855
|
+
return style.display !== "none" && style.visibility !== "hidden" && e.getAttribute("type") !== "hidden";
|
|
856
|
+
});
|
|
857
|
+
if (isVisible) {
|
|
858
|
+
target = inputs;
|
|
859
|
+
targetType = await target.getAttribute("type", options) || null;
|
|
860
|
+
} else {
|
|
861
|
+
return false;
|
|
862
|
+
}
|
|
863
|
+
} else {
|
|
864
|
+
return false;
|
|
865
|
+
}
|
|
866
|
+
}
|
|
867
|
+
if (!targetType) return false;
|
|
868
|
+
const val = formatDateForInput(value, targetType);
|
|
869
|
+
await target.fill(val, options);
|
|
870
|
+
return true;
|
|
871
|
+
}
|
|
872
|
+
async function setDateRange({ el, tag }, value, options) {
|
|
873
|
+
if (tag === "input" || tag === "select" || tag === "textarea" || tag === "button") return false;
|
|
874
|
+
const inputs = el.locator("input[type=date]");
|
|
875
|
+
if (await inputs.count() !== 2) return false;
|
|
876
|
+
const from = formatDateForInput(value.from, "date");
|
|
877
|
+
const to = formatDateForInput(value.to, "date");
|
|
878
|
+
await inputs.nth(0).fill(from, options);
|
|
879
|
+
await inputs.nth(1).fill(to, options);
|
|
880
|
+
return true;
|
|
881
|
+
}
|
|
882
|
+
async function setNativeDate(loc, value, options) {
|
|
883
|
+
if (value instanceof Date) {
|
|
884
|
+
return await setSingleDate(loc, value, options);
|
|
885
|
+
}
|
|
886
|
+
if (isRange(value, isDate)) {
|
|
887
|
+
return await setDateRange(loc, value, options);
|
|
888
|
+
}
|
|
889
|
+
return false;
|
|
890
|
+
}
|
|
891
|
+
|
|
892
|
+
// src/field/native-input.ts
|
|
893
|
+
async function setNativeInput({ el, tag }, value, options) {
|
|
894
|
+
if (tag !== "input" && tag !== "textarea") return false;
|
|
895
|
+
if (value === null) {
|
|
896
|
+
await el.clear(options);
|
|
897
|
+
return true;
|
|
898
|
+
}
|
|
899
|
+
if (typeof value === "string" || typeof value === "number") {
|
|
900
|
+
await el.fill(String(value), options);
|
|
901
|
+
return true;
|
|
902
|
+
}
|
|
903
|
+
return false;
|
|
904
|
+
}
|
|
905
|
+
|
|
906
|
+
// src/field/otp.ts
|
|
907
|
+
async function setOtpValue({ el, tag }, value, options) {
|
|
908
|
+
if (typeof value !== "string") return false;
|
|
909
|
+
if (tag === "input" || tag === "select" || tag === "button" || tag === "textarea") return false;
|
|
910
|
+
const chars = value.replace(/\W/g, "").split("");
|
|
911
|
+
if (chars.length < 3 || chars.length > 8) return false;
|
|
912
|
+
const inputs = await el.locator('input[type="text"], input:not([type])').all();
|
|
913
|
+
if (inputs.length !== chars.length) return false;
|
|
914
|
+
for (let i = 0; i < chars.length; i++) {
|
|
915
|
+
await inputs[i].fill(chars[i], options);
|
|
916
|
+
}
|
|
917
|
+
return true;
|
|
918
|
+
}
|
|
919
|
+
|
|
920
|
+
// src/field/radio-group.ts
|
|
921
|
+
async function setRadioGroup({ el }, value, options) {
|
|
922
|
+
if (typeof value !== "string" && typeof value !== "number") return false;
|
|
923
|
+
const stringValue = String(value);
|
|
924
|
+
if (stringValue.includes("\n") || stringValue.includes('"')) return false;
|
|
925
|
+
const radio = el.locator(`input[type=radio][value="${stringValue}"]`);
|
|
926
|
+
if (await radio.count() === 1) {
|
|
927
|
+
await radio.check(options);
|
|
928
|
+
return true;
|
|
929
|
+
}
|
|
930
|
+
const radioByLabel = el.getByLabel(String(value), { exact: true }).locator("input[type=radio]");
|
|
931
|
+
if (await radioByLabel.count() === 1) {
|
|
932
|
+
await radioByLabel.check(options);
|
|
933
|
+
return true;
|
|
934
|
+
}
|
|
935
|
+
return false;
|
|
936
|
+
}
|
|
937
|
+
|
|
938
|
+
// src/field/slider.ts
|
|
939
|
+
async function setSliderValue({ el, tag }, value, options) {
|
|
940
|
+
if (typeof value !== "number") return false;
|
|
941
|
+
if (["input", "select", "button", "textarea"].includes(tag)) return false;
|
|
942
|
+
const slider = await getSliderElement(el, options);
|
|
943
|
+
if (!slider) return false;
|
|
944
|
+
const { min, max, orientation, valuenow: initialValue } = await getSliderAttributes(slider, options);
|
|
945
|
+
if (value < min || value > max) {
|
|
946
|
+
throw new Error(`Value ${value} is out of range [${min}, ${max}]`);
|
|
947
|
+
}
|
|
948
|
+
if (initialValue === null) return false;
|
|
949
|
+
if (initialValue === value) return true;
|
|
950
|
+
const { centerX, centerY } = await prepareMouse(slider, options);
|
|
951
|
+
const page = slider.page();
|
|
952
|
+
try {
|
|
953
|
+
const ratio = await calculateRatio(slider, initialValue, value, centerX, centerY, orientation, options);
|
|
954
|
+
await seekValue(slider, initialValue, value, centerX, centerY, orientation, ratio, options);
|
|
955
|
+
} finally {
|
|
956
|
+
await page.mouse.up();
|
|
957
|
+
}
|
|
958
|
+
return true;
|
|
959
|
+
}
|
|
960
|
+
async function prepareMouse(slider, options) {
|
|
961
|
+
await slider.scrollIntoViewIfNeeded(options);
|
|
962
|
+
const box = await slider.boundingBox(options);
|
|
963
|
+
if (!box) throw new Error("Slider has no bounding box");
|
|
964
|
+
const centerX = box.x + (box.width || 10) / 2;
|
|
965
|
+
const centerY = box.y + (box.height || 10) / 2;
|
|
966
|
+
const page = slider.page();
|
|
967
|
+
await page.mouse.move(centerX, centerY);
|
|
968
|
+
await page.mouse.down();
|
|
969
|
+
return { centerX, centerY };
|
|
970
|
+
}
|
|
971
|
+
async function seekValue(slider, initialValue, targetValue, centerX, centerY, orientation, ratio, options) {
|
|
972
|
+
const page = slider.page();
|
|
973
|
+
for (let i = 0; i < 4; i++) {
|
|
974
|
+
const distance = (targetValue - initialValue) / ratio;
|
|
975
|
+
await moveMouse(page, centerX, centerY, orientation, distance);
|
|
976
|
+
const currentValAttr = await slider.getAttribute("aria-valuenow", options);
|
|
977
|
+
const currentVal = parseFloat(currentValAttr || "0");
|
|
978
|
+
if (currentVal === targetValue) break;
|
|
979
|
+
if (distance !== 0) {
|
|
980
|
+
const newRatio = (currentVal - initialValue) / distance;
|
|
981
|
+
if (newRatio !== 0) ratio = newRatio;
|
|
982
|
+
}
|
|
983
|
+
}
|
|
984
|
+
}
|
|
985
|
+
async function calculateRatio(slider, initialValue, targetValue, centerX, centerY, orientation, options) {
|
|
986
|
+
const page = slider.page();
|
|
987
|
+
const testMove = targetValue > initialValue ? 20 : -20;
|
|
988
|
+
await moveMouse(page, centerX, centerY, orientation, testMove);
|
|
989
|
+
const valAfterMoveAttr = await slider.getAttribute("aria-valuenow", options);
|
|
990
|
+
const valAfterMove = parseFloat(valAfterMoveAttr || "0");
|
|
991
|
+
const diff = valAfterMove - initialValue;
|
|
992
|
+
if (diff === 0) {
|
|
993
|
+
throw new Error("Slider appears to be disabled or unresponsive");
|
|
994
|
+
}
|
|
995
|
+
return diff / testMove;
|
|
996
|
+
}
|
|
997
|
+
async function getSliderElement(el, options) {
|
|
998
|
+
const role = await el.getAttribute("role", options).catch(() => null);
|
|
999
|
+
if (role === "slider") return el;
|
|
1000
|
+
const slider = el.getByRole("slider");
|
|
1001
|
+
if (await slider.count() > 0) {
|
|
1002
|
+
return slider.first();
|
|
1003
|
+
}
|
|
1004
|
+
return null;
|
|
1005
|
+
}
|
|
1006
|
+
async function getSliderAttributes(slider, options) {
|
|
1007
|
+
const [minStr, maxStr, orient, nowStr] = await Promise.all([
|
|
1008
|
+
slider.getAttribute("aria-valuemin", options),
|
|
1009
|
+
slider.getAttribute("aria-valuemax", options),
|
|
1010
|
+
slider.getAttribute("aria-orientation", options),
|
|
1011
|
+
slider.getAttribute("aria-valuenow", options)
|
|
1012
|
+
]);
|
|
1013
|
+
return {
|
|
1014
|
+
min: parseFloat(minStr || "0"),
|
|
1015
|
+
max: parseFloat(maxStr || "100"),
|
|
1016
|
+
orientation: orient || "horizontal",
|
|
1017
|
+
valuenow: nowStr !== null ? parseFloat(nowStr) : null
|
|
1018
|
+
};
|
|
1019
|
+
}
|
|
1020
|
+
async function moveMouse(page, centerX, centerY, orientation, distance) {
|
|
1021
|
+
if (orientation === "vertical") {
|
|
1022
|
+
await page.mouse.move(centerX, centerY - distance);
|
|
1023
|
+
} else {
|
|
1024
|
+
await page.mouse.move(centerX + distance, centerY);
|
|
1025
|
+
}
|
|
1026
|
+
}
|
|
1027
|
+
|
|
1028
|
+
// src/field/index.ts
|
|
1029
|
+
function toString(value) {
|
|
1030
|
+
if (isRange(value)) return `${String(value.from)} - ${String(value.to)}`;
|
|
1031
|
+
if (isArray(value)) return value.map((v) => String(v)).join("\n");
|
|
1032
|
+
return String(value);
|
|
1033
|
+
}
|
|
1034
|
+
async function setFallback({ el }, value, options) {
|
|
1035
|
+
await el.fill(toString(value), options);
|
|
1036
|
+
return true;
|
|
1037
|
+
}
|
|
1038
|
+
async function setFieldValue(el, value, options) {
|
|
1039
|
+
const setValue = chain(
|
|
1040
|
+
// native
|
|
1041
|
+
selectNative,
|
|
1042
|
+
setNativeCheckbox,
|
|
1043
|
+
setRadioGroup,
|
|
1044
|
+
setNativeDate,
|
|
1045
|
+
setNativeInput,
|
|
1046
|
+
// aria / components
|
|
1047
|
+
setDateTextInput,
|
|
1048
|
+
setDateGroup,
|
|
1049
|
+
setCalendarDate,
|
|
1050
|
+
setOtpValue,
|
|
1051
|
+
setSliderValue,
|
|
1052
|
+
// fallback (eg contenteditable or will fail)
|
|
1053
|
+
setFallback
|
|
1054
|
+
);
|
|
1055
|
+
if (await el.count() > 1) {
|
|
1056
|
+
el = await pickFieldElement(el);
|
|
1057
|
+
}
|
|
1058
|
+
const tag = await el.evaluate((e) => e.tagName.toLowerCase(), options);
|
|
1059
|
+
const type = await el.getAttribute("type", options).then((s) => s && s.toLowerCase()).catch(() => null);
|
|
1060
|
+
const loc = { el, tag, type };
|
|
1061
|
+
await setValue(loc, value, options);
|
|
1062
|
+
}
|
|
1063
|
+
async function formatHtml(page) {
|
|
1064
|
+
const html = typeof page === "string" ? page : await page.content();
|
|
1065
|
+
const file = await unified().use(rehypeParse, { fragment: true }).use(rehypeFormat, { indent: 2 }).use(rehypeStringify).process(html);
|
|
1066
|
+
return String(file);
|
|
1067
|
+
}
|
|
1068
|
+
|
|
1069
|
+
// src/locator.ts
|
|
1070
|
+
async function locator(page, selector) {
|
|
1071
|
+
const primary = page.locator(selector).first();
|
|
1072
|
+
if (await primary.count()) return primary;
|
|
1073
|
+
return await tryRelaxNameToHasText(page, selector) || await tryTagInsteadOfRole(page, selector) || await tryRoleNameProximity(page, selector) || await tryFieldAlternative(page, selector) || await tryAsField(page, selector) || primary;
|
|
1074
|
+
}
|
|
1075
|
+
async function firstMatch(page, sel, opts = {}) {
|
|
1076
|
+
for (const selector of Array.isArray(sel) ? sel : [sel]) {
|
|
1077
|
+
const loc = page.locator(selector, opts).first();
|
|
1078
|
+
if (await loc.count()) return loc;
|
|
1079
|
+
}
|
|
1080
|
+
return null;
|
|
1081
|
+
}
|
|
1082
|
+
async function tryRelaxNameToHasText(page, selector) {
|
|
1083
|
+
const matchAnyNameFull = selector.match(/^(role=.*)\[name="([^"]+)"i?](.*)$/i);
|
|
1084
|
+
if (!matchAnyNameFull) return null;
|
|
1085
|
+
const [, pre, nameText, post] = matchAnyNameFull;
|
|
1086
|
+
const containsSelector = `${pre}${post}`;
|
|
1087
|
+
return firstMatch(page, containsSelector, { hasText: nameText });
|
|
1088
|
+
}
|
|
1089
|
+
async function tryTagInsteadOfRole(page, selector) {
|
|
1090
|
+
const matchAnyNameFull = selector.match(/^role=(link|button|option)\s*\[name="([^"]+)"i?](.*)$/i);
|
|
1091
|
+
if (!matchAnyNameFull) return null;
|
|
1092
|
+
const [, role, nameText, post] = matchAnyNameFull;
|
|
1093
|
+
const tag = role === "link" ? "a" : role;
|
|
1094
|
+
const containsSelector = `css=${tag}${post}`;
|
|
1095
|
+
return firstMatch(page, containsSelector, { hasText: nameText });
|
|
1096
|
+
}
|
|
1097
|
+
async function tryRoleNameProximity(page, selector) {
|
|
1098
|
+
const matchRole = selector.match(/^role=(\w+)\s*\[name="([^"]+)"i?](.*)$/i);
|
|
1099
|
+
if (!matchRole) return null;
|
|
1100
|
+
const [, role, name, rest] = matchRole;
|
|
1101
|
+
const proximitySelector = `text=${name} >> .. >> role=${role}${rest}`;
|
|
1102
|
+
return firstMatch(page, proximitySelector);
|
|
1103
|
+
}
|
|
1104
|
+
async function tryFieldAlternative(page, selector) {
|
|
1105
|
+
const matchField = selector.match(/^field="([^"]+)"i?$/i);
|
|
1106
|
+
if (!matchField) return null;
|
|
1107
|
+
const [, field] = matchField;
|
|
1108
|
+
return firstMatch(page, `#${field} > input`);
|
|
1109
|
+
}
|
|
1110
|
+
async function tryAsField(page, selector) {
|
|
1111
|
+
const matchRole = selector.match(/^role=(\w+)\s*\[name="([^"]+)"i?](.*)$/i);
|
|
1112
|
+
if (!matchRole) return null;
|
|
1113
|
+
const [, role, name, rest] = matchRole;
|
|
1114
|
+
const fieldRoles = /* @__PURE__ */ new Set([
|
|
1115
|
+
"button",
|
|
1116
|
+
// Sometimes used for date pickers or checkboxes
|
|
1117
|
+
"textbox",
|
|
1118
|
+
"searchbox",
|
|
1119
|
+
"combobox",
|
|
1120
|
+
"spinbutton",
|
|
1121
|
+
"slider",
|
|
1122
|
+
"checkbox",
|
|
1123
|
+
"switch",
|
|
1124
|
+
"radio",
|
|
1125
|
+
"radiogroup",
|
|
1126
|
+
"listbox",
|
|
1127
|
+
"option"
|
|
1128
|
+
]);
|
|
1129
|
+
if (!fieldRoles.has(role.toLowerCase())) return null;
|
|
1130
|
+
return firstMatch(page, `field=${name}${rest}`);
|
|
1131
|
+
}
|
|
1132
|
+
|
|
1133
|
+
// src/selector/date-selector.ts
|
|
1134
|
+
var createDateEngine = () => ({
|
|
1135
|
+
// Single match (Playwright will call this in some contexts)
|
|
1136
|
+
query(root, body) {
|
|
1137
|
+
const all = this.queryAll(root, body);
|
|
1138
|
+
return all[0] ?? null;
|
|
1139
|
+
},
|
|
1140
|
+
// All matches
|
|
1141
|
+
queryAll(root, body) {
|
|
1142
|
+
const targetDate = this._parseSelector(body);
|
|
1143
|
+
if (!targetDate) return [];
|
|
1144
|
+
const doc = root instanceof Document ? root : root.ownerDocument || document;
|
|
1145
|
+
const locale = doc.documentElement.lang || "en-US";
|
|
1146
|
+
const candidates = [];
|
|
1147
|
+
const walker = doc.createTreeWalker(root, NodeFilter.SHOW_ELEMENT, null);
|
|
1148
|
+
let currentNode = walker.nextNode();
|
|
1149
|
+
while (currentNode) {
|
|
1150
|
+
const el = currentNode;
|
|
1151
|
+
const { matched, type } = this._matchesDate(el, targetDate, locale, body);
|
|
1152
|
+
if (matched) {
|
|
1153
|
+
candidates.push({ el, type });
|
|
1154
|
+
}
|
|
1155
|
+
currentNode = walker.nextNode();
|
|
1156
|
+
}
|
|
1157
|
+
const results = candidates.filter((c) => {
|
|
1158
|
+
const el = c.el;
|
|
1159
|
+
const hasMatchingDescendant = candidates.some((other) => {
|
|
1160
|
+
if (other.el === el || !el.contains(other.el)) return false;
|
|
1161
|
+
return !(c.type === "full" && other.type === "partial");
|
|
1162
|
+
});
|
|
1163
|
+
return !hasMatchingDescendant;
|
|
1164
|
+
}).map((c) => c.el);
|
|
1165
|
+
if (results.length === 0 && candidates.length > 0) ;
|
|
1166
|
+
return results;
|
|
1167
|
+
},
|
|
1168
|
+
_parseSelector(body) {
|
|
1169
|
+
const now = /* @__PURE__ */ new Date();
|
|
1170
|
+
const trimmed = body.toLowerCase().trim();
|
|
1171
|
+
if (trimmed === "today") return now;
|
|
1172
|
+
if (trimmed === "tomorrow") {
|
|
1173
|
+
const d = new Date(now);
|
|
1174
|
+
d.setDate(d.getDate() + 1);
|
|
1175
|
+
return d;
|
|
1176
|
+
}
|
|
1177
|
+
if (trimmed === "yesterday") {
|
|
1178
|
+
const d = new Date(now);
|
|
1179
|
+
d.setDate(d.getDate() - 1);
|
|
1180
|
+
return d;
|
|
1181
|
+
}
|
|
1182
|
+
const relativeMatch = trimmed.match(/^(\d+)\s+(day|month|year)s?\s+(ago|from now)$/);
|
|
1183
|
+
if (relativeMatch) {
|
|
1184
|
+
const [_, amount, unit, direction] = relativeMatch;
|
|
1185
|
+
const d = new Date(now);
|
|
1186
|
+
const sign = direction === "ago" ? -1 : 1;
|
|
1187
|
+
const val = parseInt(amount, 10) * sign;
|
|
1188
|
+
if (unit === "day") d.setDate(d.getDate() + val);
|
|
1189
|
+
else if (unit === "month") d.setMonth(d.getMonth() + val);
|
|
1190
|
+
else if (unit === "year") d.setFullYear(d.getFullYear() + val);
|
|
1191
|
+
return d;
|
|
1192
|
+
}
|
|
1193
|
+
const atMatch = trimmed.match(/^(today|tomorrow|yesterday)\s+at\s+(\d{1,2}):(\d{2})(?::(\d{2}))?(?:\s*(am|pm))?$/);
|
|
1194
|
+
if (atMatch) {
|
|
1195
|
+
const [_, dayStr, hourStr, min, sec, ampm] = atMatch;
|
|
1196
|
+
const d = new Date(now);
|
|
1197
|
+
if (dayStr === "tomorrow") d.setDate(d.getDate() + 1);
|
|
1198
|
+
if (dayStr === "yesterday") d.setDate(d.getDate() - 1);
|
|
1199
|
+
let hour = parseInt(hourStr, 10);
|
|
1200
|
+
if (ampm === "pm" && hour < 12) hour += 12;
|
|
1201
|
+
if (ampm === "am" && hour === 12) hour = 0;
|
|
1202
|
+
d.setHours(hour, parseInt(min, 10), parseInt(sec || "0", 10), 0);
|
|
1203
|
+
return d;
|
|
1204
|
+
}
|
|
1205
|
+
const absDate = new Date(body);
|
|
1206
|
+
if (!isNaN(absDate.getTime())) return absDate;
|
|
1207
|
+
return null;
|
|
1208
|
+
},
|
|
1209
|
+
_matchesDate(el, targetDate, locale, body) {
|
|
1210
|
+
const text = el.textContent?.trim() || "";
|
|
1211
|
+
if (!text) return { matched: false, type: "partial" };
|
|
1212
|
+
const normalizedText = text.replace(/\s+/g, " ").trim();
|
|
1213
|
+
const cleanText = normalizedText.toLowerCase().replace(/[.,\/#!$%\^&\*;:{}=\-_`~()]/g, " ").replace(/\s+/g, " ").trim();
|
|
1214
|
+
const options = [
|
|
1215
|
+
{ year: "numeric", month: "short", day: "numeric" },
|
|
1216
|
+
{ year: "numeric", month: "long", day: "numeric" },
|
|
1217
|
+
{ year: "2-digit", month: "numeric", day: "numeric" },
|
|
1218
|
+
{ year: "numeric", month: "numeric", day: "numeric" },
|
|
1219
|
+
{ month: "short", day: "numeric" },
|
|
1220
|
+
{ month: "long", day: "numeric" }
|
|
1221
|
+
];
|
|
1222
|
+
let dateMatched = false;
|
|
1223
|
+
let matchType = "partial";
|
|
1224
|
+
for (const opt of options) {
|
|
1225
|
+
const formatter = new Intl.DateTimeFormat(locale, opt);
|
|
1226
|
+
const formatted = formatter.format(targetDate);
|
|
1227
|
+
const normalizedFormatted = formatted.replace(/\s+/g, " ").trim();
|
|
1228
|
+
const cleanFormatted = normalizedFormatted.toLowerCase().replace(/[.,\/#!$%\^&\*;:{}=\-_`~()]/g, " ").replace(/\s+/g, " ").trim();
|
|
1229
|
+
if (normalizedText.includes(normalizedFormatted) || cleanText.includes(cleanFormatted)) {
|
|
1230
|
+
if (opt.year && opt.month === "numeric" && opt.day === "numeric") {
|
|
1231
|
+
const yearVal = targetDate.getFullYear().toString();
|
|
1232
|
+
const shortYearVal = yearVal.slice(-2);
|
|
1233
|
+
if (!normalizedText.includes(yearVal) && !normalizedText.includes(shortYearVal)) {
|
|
1234
|
+
continue;
|
|
1235
|
+
}
|
|
1236
|
+
}
|
|
1237
|
+
if (opt.year && (opt.month === "short" || opt.month === "long")) {
|
|
1238
|
+
const yearVal = targetDate.getFullYear().toString();
|
|
1239
|
+
const otherYearMatch = normalizedText.match(/\b\d{4}\b/g);
|
|
1240
|
+
if (otherYearMatch && !otherYearMatch.includes(yearVal)) {
|
|
1241
|
+
continue;
|
|
1242
|
+
}
|
|
1243
|
+
}
|
|
1244
|
+
dateMatched = true;
|
|
1245
|
+
if (opt.year) matchType = "full";
|
|
1246
|
+
break;
|
|
1247
|
+
}
|
|
1248
|
+
if (opt.month === "numeric" && opt.day === "numeric") {
|
|
1249
|
+
const parts = formatter.formatToParts(targetDate);
|
|
1250
|
+
const day = parts.find((p) => p.type === "day")?.value;
|
|
1251
|
+
const month = parts.find((p) => p.type === "month")?.value;
|
|
1252
|
+
const year = parts.find((p) => p.type === "year")?.value;
|
|
1253
|
+
if (day && month) {
|
|
1254
|
+
const seps = [".", "-", "/", " ", ""];
|
|
1255
|
+
const d2 = day.padStart(2, "0");
|
|
1256
|
+
const m2 = month.padStart(2, "0");
|
|
1257
|
+
const dayVariations = Array.from(/* @__PURE__ */ new Set([day, d2]));
|
|
1258
|
+
const monthVariations = Array.from(/* @__PURE__ */ new Set([month, m2]));
|
|
1259
|
+
let numericMatched = false;
|
|
1260
|
+
for (const sep of seps) {
|
|
1261
|
+
for (const d of dayVariations) {
|
|
1262
|
+
for (const m of monthVariations) {
|
|
1263
|
+
if (year) {
|
|
1264
|
+
const y2 = year.slice(-2);
|
|
1265
|
+
const yearVariations = Array.from(/* @__PURE__ */ new Set([year, y2]));
|
|
1266
|
+
for (const y of yearVariations) {
|
|
1267
|
+
if (normalizedText.includes(`${d}${sep}${m}${sep}${y}`) || normalizedText.includes(`${m}${sep}${d}${sep}${y}`) || normalizedText.includes(`${y}${sep}${m}${sep}${d}`)) {
|
|
1268
|
+
numericMatched = true;
|
|
1269
|
+
matchType = "full";
|
|
1270
|
+
break;
|
|
1271
|
+
}
|
|
1272
|
+
}
|
|
1273
|
+
}
|
|
1274
|
+
if (numericMatched) break;
|
|
1275
|
+
if (normalizedText.includes(`${d}${sep}${m}`) || normalizedText.includes(`${m}${sep}${d}`)) {
|
|
1276
|
+
if (!normalizedText.match(/\d{4}/)) {
|
|
1277
|
+
numericMatched = true;
|
|
1278
|
+
matchType = "partial";
|
|
1279
|
+
}
|
|
1280
|
+
}
|
|
1281
|
+
}
|
|
1282
|
+
if (numericMatched) break;
|
|
1283
|
+
}
|
|
1284
|
+
if (numericMatched) break;
|
|
1285
|
+
}
|
|
1286
|
+
if (numericMatched) {
|
|
1287
|
+
dateMatched = true;
|
|
1288
|
+
break;
|
|
1289
|
+
}
|
|
1290
|
+
}
|
|
1291
|
+
}
|
|
1292
|
+
}
|
|
1293
|
+
if (!dateMatched && normalizedText.includes(targetDate.toISOString().split("T")[0])) {
|
|
1294
|
+
dateMatched = true;
|
|
1295
|
+
matchType = "full";
|
|
1296
|
+
}
|
|
1297
|
+
if (!dateMatched) return { matched: false, type: "partial" };
|
|
1298
|
+
const queryHasYear = body.match(/\d{4}|'\d{2}/);
|
|
1299
|
+
if (queryHasYear && matchType === "partial") {
|
|
1300
|
+
return { matched: false, type: "partial" };
|
|
1301
|
+
}
|
|
1302
|
+
const elementYearMatch = normalizedText.match(/\b\d{4}\b/g);
|
|
1303
|
+
if (elementYearMatch && elementYearMatch.some((y) => parseInt(y, 10) !== targetDate.getFullYear())) {
|
|
1304
|
+
if (!elementYearMatch.includes(targetDate.getFullYear().toString())) {
|
|
1305
|
+
return { matched: false, type: "partial" };
|
|
1306
|
+
}
|
|
1307
|
+
}
|
|
1308
|
+
const queryStr = body.toLowerCase();
|
|
1309
|
+
const queryHasTime = queryStr.includes(" at ") || queryStr.includes(":") || (queryStr.includes("am") || queryStr.includes("pm"));
|
|
1310
|
+
if (queryHasTime) {
|
|
1311
|
+
const timeMatch = normalizedText.match(/(\d{1,2})[:.](\d{2})(?::(\d{2}))?\s*(am|pm|om|u)?/i);
|
|
1312
|
+
if (timeMatch) {
|
|
1313
|
+
const [_, h, m, s, ampm] = timeMatch;
|
|
1314
|
+
let hour = parseInt(h, 10);
|
|
1315
|
+
if (ampm?.toLowerCase() === "pm" && hour < 12) hour += 12;
|
|
1316
|
+
if (ampm?.toLowerCase() === "am" && hour === 12) hour = 0;
|
|
1317
|
+
if (hour !== targetDate.getHours() || parseInt(m, 10) !== targetDate.getMinutes()) {
|
|
1318
|
+
return { matched: false, type: "full" };
|
|
1319
|
+
}
|
|
1320
|
+
if (s && parseInt(s, 10) !== targetDate.getSeconds()) {
|
|
1321
|
+
return { matched: false, type: "full" };
|
|
1322
|
+
}
|
|
1323
|
+
} else {
|
|
1324
|
+
return { matched: false, type: "full" };
|
|
1325
|
+
}
|
|
1326
|
+
}
|
|
1327
|
+
return { matched: true, type: matchType };
|
|
1328
|
+
}
|
|
1329
|
+
});
|
|
1330
|
+
|
|
1331
|
+
// src/selector/field-selector.ts
|
|
1332
|
+
var createFieldEngine = () => ({
|
|
1333
|
+
// Helper: compile matcher from `field=...` body
|
|
1334
|
+
_compileMatcher(body) {
|
|
1335
|
+
const trimmed = body.trim();
|
|
1336
|
+
if (trimmed.startsWith("/") && trimmed.lastIndexOf("/") > 0) {
|
|
1337
|
+
const last = trimmed.lastIndexOf("/");
|
|
1338
|
+
const pattern = trimmed.slice(1, last);
|
|
1339
|
+
const flags = trimmed.slice(last + 1);
|
|
1340
|
+
const re = new RegExp(pattern, flags);
|
|
1341
|
+
return (s) => !!s && re.test(s);
|
|
1342
|
+
}
|
|
1343
|
+
const sanitize = (s) => s.toLowerCase().replace(/[^\w\s]+/g, "").replace(/\s{2,}/g, " ").replace(/\*\s*$/, "").trim();
|
|
1344
|
+
const needle = sanitize(trimmed.replace(/^"(.*)"(i?)$/, "$1"));
|
|
1345
|
+
return ((s) => !!s && sanitize(s) === needle);
|
|
1346
|
+
},
|
|
1347
|
+
// Single match (Playwright will call this in some contexts)
|
|
1348
|
+
query(root, body) {
|
|
1349
|
+
const all = this.queryAll(root, body);
|
|
1350
|
+
return all[0] ?? null;
|
|
1351
|
+
},
|
|
1352
|
+
// All matches
|
|
1353
|
+
queryAll(root, body) {
|
|
1354
|
+
const match = this._compileMatcher(body);
|
|
1355
|
+
const candidates = Array.from(
|
|
1356
|
+
root.querySelectorAll(
|
|
1357
|
+
[
|
|
1358
|
+
"input",
|
|
1359
|
+
"textarea",
|
|
1360
|
+
"select",
|
|
1361
|
+
'[role="textbox"]',
|
|
1362
|
+
'[role="combobox"]',
|
|
1363
|
+
'[role="spinbutton"]',
|
|
1364
|
+
'[role="slider"]',
|
|
1365
|
+
'[role="switch"]',
|
|
1366
|
+
'[role="checkbox"]',
|
|
1367
|
+
'[role="radio"]',
|
|
1368
|
+
'[role="radiogroup"]',
|
|
1369
|
+
'[contenteditable=""]',
|
|
1370
|
+
'[contenteditable="true"]'
|
|
1371
|
+
].join(", ")
|
|
1372
|
+
)
|
|
1373
|
+
);
|
|
1374
|
+
const byId = /* @__PURE__ */ new Map();
|
|
1375
|
+
Array.from(root.querySelectorAll("[id]")).forEach((el) => byId.set(el.id, el));
|
|
1376
|
+
function textFor(el) {
|
|
1377
|
+
const texts = [];
|
|
1378
|
+
let parent = el.parentElement;
|
|
1379
|
+
while (parent) {
|
|
1380
|
+
if (parent.tagName === "LABEL") {
|
|
1381
|
+
texts.push(parent.textContent ?? "");
|
|
1382
|
+
break;
|
|
1383
|
+
}
|
|
1384
|
+
parent = parent.parentElement;
|
|
1385
|
+
}
|
|
1386
|
+
let id = el.id;
|
|
1387
|
+
if (!id) {
|
|
1388
|
+
const p = el.parentElement;
|
|
1389
|
+
if (p && (p.tagName === "DIV" || p.tagName === "SPAN") && p.id) {
|
|
1390
|
+
id = p.id;
|
|
1391
|
+
}
|
|
1392
|
+
}
|
|
1393
|
+
if (id) {
|
|
1394
|
+
const forLabels = Array.from(
|
|
1395
|
+
root.querySelectorAll(`label[for="${CSS.escape(id)}"]`)
|
|
1396
|
+
);
|
|
1397
|
+
forLabels.forEach((l) => texts.push(l.textContent ?? ""));
|
|
1398
|
+
}
|
|
1399
|
+
const ariaLabel = el.getAttribute("aria-label");
|
|
1400
|
+
if (ariaLabel) texts.push(ariaLabel);
|
|
1401
|
+
const labelledBy = el.getAttribute("aria-labelledby");
|
|
1402
|
+
if (labelledBy) {
|
|
1403
|
+
const extAriaLabel = labelledBy.split(/\s+/).map((idref) => byId.get(idref)).filter((ref) => !!ref?.textContent.trim()).map((ref) => ref.textContent).join(" ");
|
|
1404
|
+
if (extAriaLabel) texts.push(extAriaLabel);
|
|
1405
|
+
}
|
|
1406
|
+
const name = el.getAttribute("name");
|
|
1407
|
+
if (name) texts.push(name);
|
|
1408
|
+
const ph = el.placeholder ?? el.getAttribute("placeholder");
|
|
1409
|
+
if (ph) texts.push(ph);
|
|
1410
|
+
return texts;
|
|
1411
|
+
}
|
|
1412
|
+
return candidates.map((el) => ({ el, texts: textFor(el) })).filter(({ texts }) => texts.some(match)).map(({ el }) => el);
|
|
1413
|
+
}
|
|
1414
|
+
});
|
|
1415
|
+
async function screenshot(page, options) {
|
|
1416
|
+
const buffer = options?.mask?.length ? await screenshotWithMask(page, options) : await page.screenshot(options);
|
|
1417
|
+
const filename = await hashKey(`screenshot-{hash}.png`, buffer);
|
|
1418
|
+
return new File([new Uint8Array(buffer)], filename, { type: "image/png" });
|
|
1419
|
+
}
|
|
1420
|
+
async function screenshotWithMask(page, options) {
|
|
1421
|
+
const { mask: locators, ...otherOptions } = options;
|
|
1422
|
+
if (!locators?.length) throw new Error("No locators specified");
|
|
1423
|
+
await page.evaluate(() => {
|
|
1424
|
+
const doc = document;
|
|
1425
|
+
if (!doc.getElementById("lri-mask-style")) {
|
|
1426
|
+
const style = doc.createElement("style");
|
|
1427
|
+
style.id = "lri-mask-style";
|
|
1428
|
+
style.textContent = `
|
|
1429
|
+
.lri-mask-overlay {
|
|
1430
|
+
position: fixed;
|
|
1431
|
+
inset: 0;
|
|
1432
|
+
background: rgba(0, 0, 0, 0.65);
|
|
1433
|
+
pointer-events: none;
|
|
1434
|
+
z-index: 2147483646;
|
|
1435
|
+
}
|
|
1436
|
+
.lri-mask-highlight {
|
|
1437
|
+
position: relative !important;
|
|
1438
|
+
z-index: 2147483647 !important;
|
|
1439
|
+
box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.95);
|
|
1440
|
+
border-radius: 4px;
|
|
1441
|
+
}
|
|
1442
|
+
`;
|
|
1443
|
+
doc.head.appendChild(style);
|
|
1444
|
+
}
|
|
1445
|
+
if (!doc.getElementById("lri-mask-overlay")) {
|
|
1446
|
+
const overlay = doc.createElement("div");
|
|
1447
|
+
overlay.id = "lri-mask-overlay";
|
|
1448
|
+
overlay.className = "lri-mask-overlay";
|
|
1449
|
+
doc.body.appendChild(overlay);
|
|
1450
|
+
}
|
|
1451
|
+
});
|
|
1452
|
+
const handleGroups = await Promise.all(locators.map((loc) => loc.elementHandles()));
|
|
1453
|
+
const handles = handleGroups.flat();
|
|
1454
|
+
await Promise.all(
|
|
1455
|
+
handles.map(
|
|
1456
|
+
(h) => h.evaluate((el) => {
|
|
1457
|
+
el.classList.add("lri-mask-highlight");
|
|
1458
|
+
})
|
|
1459
|
+
)
|
|
1460
|
+
);
|
|
1461
|
+
try {
|
|
1462
|
+
return await page.screenshot(otherOptions);
|
|
1463
|
+
} finally {
|
|
1464
|
+
await Promise.all(
|
|
1465
|
+
handles.map(
|
|
1466
|
+
(h) => h.evaluate((el) => {
|
|
1467
|
+
el.classList.remove("lri-mask-highlight");
|
|
1468
|
+
})
|
|
1469
|
+
)
|
|
1470
|
+
);
|
|
1471
|
+
await page.evaluate(() => {
|
|
1472
|
+
const overlay = document.getElementById("lri-mask-overlay");
|
|
1473
|
+
if (overlay) overlay.remove();
|
|
1474
|
+
const style = document.getElementById("lri-mask-style");
|
|
1475
|
+
if (style) style.remove();
|
|
1476
|
+
});
|
|
1477
|
+
}
|
|
1478
|
+
}
|
|
1479
|
+
|
|
1480
|
+
// src/snapshot.ts
|
|
1481
|
+
async function snapshot(page) {
|
|
1482
|
+
await sleep(500);
|
|
1483
|
+
await waitForDomIdle(page);
|
|
1484
|
+
const [url, html, file] = await Promise.all([page.url(), getContentWithMarkedHidden(page), screenshot(page)]);
|
|
1485
|
+
return { url, html, screenshot: file };
|
|
1486
|
+
}
|
|
1487
|
+
async function getContentWithMarkedHidden(page) {
|
|
1488
|
+
try {
|
|
1489
|
+
await page.evaluate(() => {
|
|
1490
|
+
const changed = [];
|
|
1491
|
+
window.__undoAriaHidden = () => {
|
|
1492
|
+
for (const el of changed) el.removeAttribute("aria-hidden");
|
|
1493
|
+
changed.length = 0;
|
|
1494
|
+
delete window.__undoAriaHidden;
|
|
1495
|
+
};
|
|
1496
|
+
const isHidden = (el) => {
|
|
1497
|
+
if (el.hasAttribute("hidden")) return true;
|
|
1498
|
+
if (el.hasAttribute("inert")) return true;
|
|
1499
|
+
if (el.getAttribute("aria-hidden") === "true") return true;
|
|
1500
|
+
const cs = getComputedStyle(el);
|
|
1501
|
+
return cs.display === "none" || cs.visibility === "hidden" || cs.opacity === "0";
|
|
1502
|
+
};
|
|
1503
|
+
const walk = (el) => {
|
|
1504
|
+
if (isHidden(el)) {
|
|
1505
|
+
if (!el.hasAttribute("aria-hidden")) {
|
|
1506
|
+
el.setAttribute("aria-hidden", "true");
|
|
1507
|
+
changed.push(el);
|
|
1508
|
+
}
|
|
1509
|
+
return;
|
|
1510
|
+
}
|
|
1511
|
+
for (const c of el.children) walk(c);
|
|
1512
|
+
};
|
|
1513
|
+
for (const c of document.body.children) walk(c);
|
|
1514
|
+
});
|
|
1515
|
+
return await page.content();
|
|
1516
|
+
} finally {
|
|
1517
|
+
await page.evaluate(() => window.__undoAriaHidden?.()).catch(() => {
|
|
1518
|
+
});
|
|
1519
|
+
}
|
|
1520
|
+
}
|
|
1521
|
+
|
|
1522
|
+
// src/scroll.ts
|
|
1523
|
+
async function scrollToCenter(locator2) {
|
|
1524
|
+
const count = await locator2.count();
|
|
1525
|
+
if (!count) return;
|
|
1526
|
+
await locator2.evaluate((el) => {
|
|
1527
|
+
el.scrollIntoView({ block: "center", inline: "center", behavior: "instant" });
|
|
1528
|
+
});
|
|
1529
|
+
}
|
|
1530
|
+
|
|
1531
|
+
// src/translations/af.ts
|
|
1532
|
+
var translations = {
|
|
1533
|
+
accept: [
|
|
1534
|
+
"Aanvaar",
|
|
1535
|
+
"Aanvaar alles",
|
|
1536
|
+
"Stem saam",
|
|
1537
|
+
"Laat toe",
|
|
1538
|
+
"Laat alles toe",
|
|
1539
|
+
"OK",
|
|
1540
|
+
"Reg so",
|
|
1541
|
+
"Ek verstaan",
|
|
1542
|
+
"Gaan voort",
|
|
1543
|
+
"Stoor en aanvaar",
|
|
1544
|
+
"Bevestig"
|
|
1545
|
+
],
|
|
1546
|
+
reject: [
|
|
1547
|
+
"Verwerp",
|
|
1548
|
+
"Verwerp alles",
|
|
1549
|
+
"Weier",
|
|
1550
|
+
"Moenie toelaat nie",
|
|
1551
|
+
"Slegs noodsaaklik",
|
|
1552
|
+
"Net noodsaaklike koekies",
|
|
1553
|
+
"Gaan voort sonder koekies",
|
|
1554
|
+
"Nee dankie",
|
|
1555
|
+
"Moenie aanvaar nie",
|
|
1556
|
+
"Weier alles"
|
|
1557
|
+
],
|
|
1558
|
+
close: [
|
|
1559
|
+
"Sluit",
|
|
1560
|
+
"Kanselleer",
|
|
1561
|
+
"Maak toe",
|
|
1562
|
+
"Verwyder",
|
|
1563
|
+
"Nie nou nie",
|
|
1564
|
+
"Nee dankie",
|
|
1565
|
+
"Later",
|
|
1566
|
+
"\xD7",
|
|
1567
|
+
"Slaan oor",
|
|
1568
|
+
"Maak venster toe"
|
|
1569
|
+
]
|
|
1570
|
+
};
|
|
1571
|
+
var af_default = translations;
|
|
1572
|
+
|
|
1573
|
+
// src/translations/ar.ts
|
|
1574
|
+
var translations2 = {
|
|
1575
|
+
accept: ["\u0645\u0648\u0627\u0641\u0642", "\u0623\u0648\u0627\u0641\u0642", "\u0642\u0628\u0648\u0644", "\u0642\u0628\u0648\u0644 \u0627\u0644\u0643\u0644", "\u0627\u0644\u0645\u0648\u0627\u0641\u0642\u0629 \u0639\u0644\u0649 \u0627\u0644\u0643\u0644", "\u0627\u0644\u0633\u0645\u0627\u062D", "\u062D\u0633\u0646\u064B\u0627", "\u062A\u0645", "\u062A\u0645\u0627\u0645", "\u0645\u062A\u0627\u0628\u0639\u0629", "\u062A\u0627\u0628\u0639", "\u062D\u0641\u0638 \u0648\u0627\u0644\u0645\u0648\u0627\u0641\u0642\u0629", "\u062D\u0641\u0638 \u0648\u0627\u0644\u0642\u0628\u0648\u0644"],
|
|
1576
|
+
reject: ["\u0631\u0641\u0636", "\u0631\u0641\u0636 \u0627\u0644\u0643\u0644", "\u0639\u062F\u0645 \u0627\u0644\u0645\u0648\u0627\u0641\u0642\u0629", "\u0639\u062F\u0645 \u0627\u0644\u0633\u0645\u0627\u062D", "\u0627\u0644\u0636\u0631\u0648\u0631\u064A\u0629 \u0641\u0642\u0637", "\u0627\u0644\u0623\u0633\u0627\u0633\u064A\u0629 \u0641\u0642\u0637", "\u0627\u0644\u0645\u062A\u0627\u0628\u0639\u0629 \u0628\u062F\u0648\u0646 \u0645\u0644\u0641\u0627\u062A \u062A\u0639\u0631\u064A\u0641 \u0627\u0644\u0627\u0631\u062A\u0628\u0627\u0637", "\u0627\u0644\u0627\u0633\u062A\u0645\u0631\u0627\u0631 \u0628\u062F\u0648\u0646 \u0645\u0644\u0641\u0627\u062A \u062A\u0639\u0631\u064A\u0641 \u0627\u0644\u0627\u0631\u062A\u0628\u0627\u0637", "\u0644\u0627 \u0634\u0643\u0631\u064B\u0627", "\u0644\u0627\u060C \u0634\u0643\u0631\u064B\u0627"],
|
|
1577
|
+
close: ["\u0625\u063A\u0644\u0627\u0642", "\u0625\u0644\u063A\u0627\u0621", "\u062A\u062C\u0627\u0647\u0644", "\u0644\u064A\u0633 \u0627\u0644\u0622\u0646", "\u0644\u0627 \u0634\u0643\u0631\u064B\u0627", "\u0644\u0627\u062D\u0642\u064B\u0627", "\xD7", "\u0625\u062E\u0641\u0627\u0621", "\u062A\u062E\u0637\u064A"]
|
|
1578
|
+
};
|
|
1579
|
+
var ar_default = translations2;
|
|
1580
|
+
|
|
1581
|
+
// src/translations/az.ts
|
|
1582
|
+
var translations3 = {
|
|
1583
|
+
accept: [
|
|
1584
|
+
"Q\u0259bul et",
|
|
1585
|
+
"Ham\u0131s\u0131n\u0131 q\u0259bul et",
|
|
1586
|
+
"Raz\u0131yam",
|
|
1587
|
+
"T\u0259sdiq et",
|
|
1588
|
+
"\u0130caz\u0259 ver",
|
|
1589
|
+
"Ham\u0131s\u0131na icaz\u0259 ver",
|
|
1590
|
+
"OK",
|
|
1591
|
+
"Oldu",
|
|
1592
|
+
"Ba\u015Fa d\xFC\u015Fd\xFCm",
|
|
1593
|
+
"Anlad\u0131m",
|
|
1594
|
+
"Davam et",
|
|
1595
|
+
"Saxla v\u0259 q\u0259bul et"
|
|
1596
|
+
],
|
|
1597
|
+
reject: [
|
|
1598
|
+
"R\u0259dd et",
|
|
1599
|
+
"Ham\u0131s\u0131n\u0131 r\u0259dd et",
|
|
1600
|
+
"\u0130mtina et",
|
|
1601
|
+
"\u0130caz\u0259 verm\u0259",
|
|
1602
|
+
"Yaln\u0131z z\u0259ruri kukil\u0259r",
|
|
1603
|
+
"Yaln\u0131z z\u0259ruri",
|
|
1604
|
+
"Kukil\u0259rsiz davam et",
|
|
1605
|
+
"He\xE7 birin\u0259 icaz\u0259 verm\u0259",
|
|
1606
|
+
"Q\u0259bul etmir\u0259m",
|
|
1607
|
+
"Yox, sa\u011F olun"
|
|
1608
|
+
],
|
|
1609
|
+
close: [
|
|
1610
|
+
"Ba\u011Fla",
|
|
1611
|
+
"L\u0259\u011Fv et",
|
|
1612
|
+
"Geri",
|
|
1613
|
+
"Ke\xE7",
|
|
1614
|
+
"\u0130ndi yox",
|
|
1615
|
+
"Sonra",
|
|
1616
|
+
"Yox, sa\u011F olun",
|
|
1617
|
+
"\xD7"
|
|
1618
|
+
]
|
|
1619
|
+
};
|
|
1620
|
+
var az_default = translations3;
|
|
1621
|
+
|
|
1622
|
+
// src/translations/bg.ts
|
|
1623
|
+
var translations4 = {
|
|
1624
|
+
accept: ["\u041F\u0440\u0438\u0435\u043C\u0438", "\u041F\u0440\u0438\u0435\u043C\u0438 \u0432\u0441\u0438\u0447\u043A\u0438", "\u0421\u044A\u0433\u043B\u0430\u0441\u044F\u0432\u0430\u043C \u0441\u0435", "\u0421\u044A\u0433\u043B\u0430\u0441\u0435\u043D \u0441\u044A\u043C", "\u0420\u0430\u0437\u0440\u0435\u0448\u0438", "\u0420\u0430\u0437\u0440\u0435\u0448\u0438 \u0432\u0441\u0438\u0447\u043A\u0438", "\u041E\u041A", "\u0414\u043E\u0431\u0440\u0435", "\u0420\u0430\u0437\u0431\u0440\u0430\u0445", "\u041F\u0440\u043E\u0434\u044A\u043B\u0436\u0438", "\u0417\u0430\u043F\u0430\u0437\u0438 \u0438 \u043F\u0440\u0438\u0435\u043C\u0438", "\u0414\u0430, \u043F\u0440\u0438\u0435\u043C\u0430\u043C"],
|
|
1625
|
+
reject: ["\u041E\u0442\u043A\u0430\u0436\u0438", "\u041E\u0442\u043A\u0430\u0436\u0438 \u0432\u0441\u0438\u0447\u043A\u0438", "\u041E\u0442\u043A\u0430\u0437\u0432\u0430\u043C", "\u041E\u0442\u0445\u0432\u044A\u0440\u043B\u0438", "\u0421\u0430\u043C\u043E \u043D\u0435\u043E\u0431\u0445\u043E\u0434\u0438\u043C\u0438\u0442\u0435", "\u0421\u0430\u043C\u043E \u0437\u0430\u0434\u044A\u043B\u0436\u0438\u0442\u0435\u043B\u043D\u0438\u0442\u0435", "\u0421\u0430\u043C\u043E \u043E\u0441\u043D\u043E\u0432\u043D\u0438\u0442\u0435", "\u041F\u0440\u043E\u0434\u044A\u043B\u0436\u0438 \u0431\u0435\u0437 \u0431\u0438\u0441\u043A\u0432\u0438\u0442\u043A\u0438", "\u041D\u0435, \u0431\u043B\u0430\u0433\u043E\u0434\u0430\u0440\u044F", "\u0417\u0430\u0431\u0440\u0430\u043D\u0438", "\u0417\u0430\u0431\u0440\u0430\u043D\u0438 \u0432\u0441\u0438\u0447\u043A\u0438", "\u041D\u0435 \u043F\u043E\u0437\u0432\u043E\u043B\u044F\u0432\u0430\u043C"],
|
|
1626
|
+
close: ["\u0417\u0430\u0442\u0432\u043E\u0440\u0438", "\u041E\u0442\u043A\u0430\u0437", "\u041E\u0442\u043C\u0435\u043D\u0438", "\u0421\u043A\u0440\u0438\u0439", "\u041D\u0435 \u0441\u0435\u0433\u0430", "\u041F\u043E-\u043A\u044A\u0441\u043D\u043E", "\u041D\u0435, \u0431\u043B\u0430\u0433\u043E\u0434\u0430\u0440\u044F", "\u0413\u043E\u0442\u043E\u0432\u043E", "\xD7"]
|
|
1627
|
+
};
|
|
1628
|
+
var bg_default = translations4;
|
|
1629
|
+
|
|
1630
|
+
// src/translations/bn.ts
|
|
1631
|
+
var translations5 = {
|
|
1632
|
+
accept: [
|
|
1633
|
+
"\u09B8\u09CD\u09AC\u09C0\u0995\u09BE\u09B0 \u0995\u09B0\u09C1\u09A8",
|
|
1634
|
+
"\u09B8\u09AC \u09B8\u09CD\u09AC\u09C0\u0995\u09BE\u09B0 \u0995\u09B0\u09C1\u09A8",
|
|
1635
|
+
"\u09B8\u09AE\u09CD\u09AE\u09A4\u09BF \u09A6\u09BF\u099A\u09CD\u099B\u09BF",
|
|
1636
|
+
"\u09B8\u09AE\u09CD\u09AE\u09A4",
|
|
1637
|
+
"\u0985\u09A8\u09C1\u09AE\u09A4\u09BF \u09A6\u09BF\u09A8",
|
|
1638
|
+
"\u09B8\u09AC \u0985\u09A8\u09C1\u09AE\u09A4\u09BF \u09A6\u09BF\u09A8",
|
|
1639
|
+
"\u09A0\u09BF\u0995 \u0986\u099B\u09C7",
|
|
1640
|
+
"\u09AC\u09CB\u099D\u09BE \u0997\u09C7\u09B2",
|
|
1641
|
+
"\u099A\u09BE\u09B2\u09BF\u09AF\u09BC\u09C7 \u09AF\u09BE\u09A8",
|
|
1642
|
+
"\u09B8\u0982\u09B0\u0995\u09CD\u09B7\u09A3 \u0995\u09B0\u09C7 \u09B8\u09CD\u09AC\u09C0\u0995\u09BE\u09B0",
|
|
1643
|
+
"\u09B8\u09C7\u09AD \u0995\u09B0\u09C7 \u099A\u09BE\u09B2\u09BF\u09AF\u09BC\u09C7 \u09AF\u09BE\u09A8",
|
|
1644
|
+
"\u0986\u09AE\u09BF \u09B0\u09BE\u099C\u09BF"
|
|
1645
|
+
],
|
|
1646
|
+
reject: [
|
|
1647
|
+
"\u09AA\u09CD\u09B0\u09A4\u09CD\u09AF\u09BE\u0996\u09CD\u09AF\u09BE\u09A8 \u0995\u09B0\u09C1\u09A8",
|
|
1648
|
+
"\u09B8\u09AC \u09AA\u09CD\u09B0\u09A4\u09CD\u09AF\u09BE\u0996\u09CD\u09AF\u09BE\u09A8 \u0995\u09B0\u09C1\u09A8",
|
|
1649
|
+
"\u09A8\u09BE\u09AE\u099E\u09CD\u099C\u09C1\u09B0",
|
|
1650
|
+
"\u0985\u09A8\u09C1\u09AE\u09A4\u09BF \u09A6\u09C7\u09AC \u09A8\u09BE",
|
|
1651
|
+
"\u09B6\u09C1\u09A7\u09C1 \u09AA\u09CD\u09B0\u09AF\u09BC\u09CB\u099C\u09A8\u09C0\u09AF\u09BC",
|
|
1652
|
+
"\u09B6\u09C1\u09A7\u09C1\u09AE\u09BE\u09A4\u09CD\u09B0 \u09A6\u09B0\u0995\u09BE\u09B0\u09BF",
|
|
1653
|
+
"\u0995\u09C1\u0995\u09BF \u099B\u09BE\u09A1\u09BC\u09BE\u0987 \u099A\u09BE\u09B2\u09BF\u09AF\u09BC\u09C7 \u09AF\u09BE\u09A8",
|
|
1654
|
+
"\u09A8\u09BE, \u09A7\u09A8\u09CD\u09AF\u09AC\u09BE\u09A6",
|
|
1655
|
+
"\u09A8\u09BE",
|
|
1656
|
+
"\u09B8\u09AE\u09CD\u09AE\u09A4\u09BF \u09A6\u09BF\u099A\u09CD\u099B\u09BF \u09A8\u09BE"
|
|
1657
|
+
],
|
|
1658
|
+
close: [
|
|
1659
|
+
"\u09AC\u09A8\u09CD\u09A7 \u0995\u09B0\u09C1\u09A8",
|
|
1660
|
+
"\u09AC\u09BE\u09A4\u09BF\u09B2",
|
|
1661
|
+
"\u0995\u09CD\u09AF\u09BE\u09A8\u09CD\u09B8\u09C7\u09B2",
|
|
1662
|
+
"\u098F\u0996\u09A8 \u09A8\u09AF\u09BC",
|
|
1663
|
+
"\u09AA\u09B0\u09C7",
|
|
1664
|
+
"\u09A8\u09BE, \u09A7\u09A8\u09CD\u09AF\u09AC\u09BE\u09A6",
|
|
1665
|
+
"\u09A6\u09C7\u0996\u09C7\u099B\u09BF",
|
|
1666
|
+
"\xD7"
|
|
1667
|
+
]
|
|
1668
|
+
};
|
|
1669
|
+
var bn_default = translations5;
|
|
1670
|
+
|
|
1671
|
+
// src/translations/bs.ts
|
|
1672
|
+
var translations6 = {
|
|
1673
|
+
accept: ["Prihvati", "Prihvati sve", "Sla\u017Eem se", "Dozvoli", "Dozvoli sve", "U redu", "OK", "Razumijem", "Nastavi", "Sa\u010Duvaj i prihvati", "Potvrdi", "Prihvati i nastavi"],
|
|
1674
|
+
reject: ["Odbij", "Odbij sve", "Ne prihvatam", "Ne dozvoli", "Samo neophodni", "Samo obavezni", "Nastavi bez kola\u010Di\u0107a", "Ne, hvala", "Onemogu\u0107i sve"],
|
|
1675
|
+
close: ["Zatvori", "Otka\u017Ei", "Odustani", "Odbaci", "Ne sada", "Ne, hvala", "Kasnije", "\xD7"]
|
|
1676
|
+
};
|
|
1677
|
+
var bs_default = translations6;
|
|
1678
|
+
|
|
1679
|
+
// src/translations/ca.ts
|
|
1680
|
+
var translations7 = {
|
|
1681
|
+
accept: [
|
|
1682
|
+
"Acceptar",
|
|
1683
|
+
"Acceptar-ho tot",
|
|
1684
|
+
"D'acord",
|
|
1685
|
+
"Permetre",
|
|
1686
|
+
"Permetre-ho tot",
|
|
1687
|
+
"OK",
|
|
1688
|
+
"Entesos",
|
|
1689
|
+
"Ho entenc",
|
|
1690
|
+
"Continuar",
|
|
1691
|
+
"Desa i accepta",
|
|
1692
|
+
"S\xED, accepto"
|
|
1693
|
+
],
|
|
1694
|
+
reject: [
|
|
1695
|
+
"Rebutjar",
|
|
1696
|
+
"Rebutjar-ho tot",
|
|
1697
|
+
"Denegar",
|
|
1698
|
+
"No permetre",
|
|
1699
|
+
"Nom\xE9s les necess\xE0ries",
|
|
1700
|
+
"Nom\xE9s essencials",
|
|
1701
|
+
"Continuar sense galetes",
|
|
1702
|
+
"No, gr\xE0cies",
|
|
1703
|
+
"Desactivar totes",
|
|
1704
|
+
"Continuar sense acceptar"
|
|
1705
|
+
],
|
|
1706
|
+
close: [
|
|
1707
|
+
"Tancar",
|
|
1708
|
+
"Cancel\xB7lar",
|
|
1709
|
+
"Descartar",
|
|
1710
|
+
"Ara no",
|
|
1711
|
+
"No, gr\xE0cies",
|
|
1712
|
+
"M\xE9s tard",
|
|
1713
|
+
"\xD7",
|
|
1714
|
+
"Tanca la finestra",
|
|
1715
|
+
"Ometre",
|
|
1716
|
+
"Fer-ho m\xE9s tard"
|
|
1717
|
+
]
|
|
1718
|
+
};
|
|
1719
|
+
var ca_default = translations7;
|
|
1720
|
+
|
|
1721
|
+
// src/translations/cs.ts
|
|
1722
|
+
var translations8 = {
|
|
1723
|
+
accept: ["P\u0159ijmout", "P\u0159ijmout v\u0161e", "Souhlas\xEDm", "Povolit", "Povolit v\u0161e", "OK", "Rozum\xEDm", "Pokra\u010Dovat", "Ulo\u017Eit a p\u0159ijmout", "Potvrdit"],
|
|
1724
|
+
reject: ["Odm\xEDtnout", "Odm\xEDtnout v\u0161e", "Nesouhlas\xEDm", "Nepovolovat", "Pouze nezbytn\xE9", "Jen nezbytn\xE9", "Pouze nutn\xE9 cookies", "Pouze z\xE1kladn\xED", "Pokra\u010Dovat bez cookies", "Ne, d\xEDky"],
|
|
1725
|
+
close: ["Zav\u0159\xEDt", "Zru\u0161it", "Skr\xFDt", "Ne te\u010F", "Pozd\u011Bji", "Ne, d\xEDky", "\xD7"]
|
|
1726
|
+
};
|
|
1727
|
+
var cs_default = translations8;
|
|
1728
|
+
|
|
1729
|
+
// src/translations/da.ts
|
|
1730
|
+
var translations9 = {
|
|
1731
|
+
accept: [
|
|
1732
|
+
"accepter",
|
|
1733
|
+
"accepter alle",
|
|
1734
|
+
"accepter alle cookies",
|
|
1735
|
+
"godkend",
|
|
1736
|
+
"tillad",
|
|
1737
|
+
"tillad alle",
|
|
1738
|
+
"ok",
|
|
1739
|
+
"okay",
|
|
1740
|
+
"forst\xE5et",
|
|
1741
|
+
"forts\xE6t",
|
|
1742
|
+
"g\xE5 videre",
|
|
1743
|
+
"gem og accepter",
|
|
1744
|
+
"gem indstillinger",
|
|
1745
|
+
"accepter valg"
|
|
1746
|
+
],
|
|
1747
|
+
reject: [
|
|
1748
|
+
"afvis",
|
|
1749
|
+
"afvis alle",
|
|
1750
|
+
"afvis alle cookies",
|
|
1751
|
+
"afsl\xE5",
|
|
1752
|
+
"tillad ikke",
|
|
1753
|
+
"kun n\xF8dvendige",
|
|
1754
|
+
"kun n\xF8dvendige cookies",
|
|
1755
|
+
"kun p\xE5kr\xE6vede",
|
|
1756
|
+
"forts\xE6t uden cookies",
|
|
1757
|
+
"nej tak",
|
|
1758
|
+
"begr\xE6ns til n\xF8dvendige"
|
|
1759
|
+
],
|
|
1760
|
+
close: [
|
|
1761
|
+
"luk",
|
|
1762
|
+
"annuller",
|
|
1763
|
+
"skjul",
|
|
1764
|
+
"ikke nu",
|
|
1765
|
+
"nej tak",
|
|
1766
|
+
"senere",
|
|
1767
|
+
"\xD7",
|
|
1768
|
+
"m\xE5ske senere",
|
|
1769
|
+
"luk besked"
|
|
1770
|
+
]
|
|
1771
|
+
};
|
|
1772
|
+
var da_default = translations9;
|
|
1773
|
+
|
|
1774
|
+
// src/translations/de.ts
|
|
1775
|
+
var translations10 = {
|
|
1776
|
+
accept: [
|
|
1777
|
+
"Akzeptieren",
|
|
1778
|
+
"Alle akzeptieren",
|
|
1779
|
+
"Zustimmen",
|
|
1780
|
+
"Ich stimme zu",
|
|
1781
|
+
"Erlauben",
|
|
1782
|
+
"Alle erlauben",
|
|
1783
|
+
"Zulassen",
|
|
1784
|
+
"Alles zulassen",
|
|
1785
|
+
"OK",
|
|
1786
|
+
"Okay",
|
|
1787
|
+
"Verstanden",
|
|
1788
|
+
"Weiter",
|
|
1789
|
+
"Speichern & akzeptieren",
|
|
1790
|
+
"Speichern und fortfahren",
|
|
1791
|
+
"Alles klar"
|
|
1792
|
+
],
|
|
1793
|
+
reject: [
|
|
1794
|
+
"Ablehnen",
|
|
1795
|
+
"Alle ablehnen",
|
|
1796
|
+
"Nicht erlauben",
|
|
1797
|
+
"Nicht zustimmen",
|
|
1798
|
+
"Nur notwendige",
|
|
1799
|
+
"Nur notwendige Cookies",
|
|
1800
|
+
"Nur essenzielle",
|
|
1801
|
+
"Nur erforderliche",
|
|
1802
|
+
"Ohne Cookies fortfahren",
|
|
1803
|
+
"Nein danke",
|
|
1804
|
+
"Zugriff verweigern",
|
|
1805
|
+
"Ablehnen und schlie\xDFen"
|
|
1806
|
+
],
|
|
1807
|
+
close: [
|
|
1808
|
+
"Schlie\xDFen",
|
|
1809
|
+
"Abbrechen",
|
|
1810
|
+
"Ausblenden",
|
|
1811
|
+
"Jetzt nicht",
|
|
1812
|
+
"Nein danke",
|
|
1813
|
+
"Sp\xE4ter",
|
|
1814
|
+
"\xD7",
|
|
1815
|
+
"Fenster schlie\xDFen",
|
|
1816
|
+
"Verwerfen",
|
|
1817
|
+
"Zur\xFCck"
|
|
1818
|
+
]
|
|
1819
|
+
};
|
|
1820
|
+
var de_default = translations10;
|
|
1821
|
+
|
|
1822
|
+
// src/translations/el.ts
|
|
1823
|
+
var translations11 = {
|
|
1824
|
+
accept: [
|
|
1825
|
+
"\u0391\u03C0\u03BF\u03B4\u03BF\u03C7\u03AE",
|
|
1826
|
+
"\u0391\u03C0\u03BF\u03B4\u03BF\u03C7\u03AE \u03CC\u03BB\u03C9\u03BD",
|
|
1827
|
+
"\u03A3\u03C5\u03BC\u03C6\u03C9\u03BD\u03CE",
|
|
1828
|
+
"\u0395\u03BD\u03C4\u03AC\u03BE\u03B5\u03B9",
|
|
1829
|
+
"\u039F\u039A",
|
|
1830
|
+
"\u03A4\u03BF \u03BA\u03B1\u03C4\u03AC\u03BB\u03B1\u03B2\u03B1",
|
|
1831
|
+
"\u03A3\u03C5\u03BD\u03AD\u03C7\u03B5\u03B9\u03B1",
|
|
1832
|
+
"\u0395\u03C0\u03B9\u03C4\u03C1\u03AD\u03C0\u03C9",
|
|
1833
|
+
"\u0395\u03C0\u03B9\u03C4\u03C1\u03AD\u03C0\u03C9 \u03CC\u03BB\u03B1",
|
|
1834
|
+
"\u0391\u03C0\u03BF\u03B8\u03AE\u03BA\u03B5\u03C5\u03C3\u03B7 \u03BA\u03B1\u03B9 \u03B1\u03C0\u03BF\u03B4\u03BF\u03C7\u03AE",
|
|
1835
|
+
"\u03A0\u03C1\u03BF\u03C7\u03CE\u03C1\u03B7\u03C3\u03B5"
|
|
1836
|
+
],
|
|
1837
|
+
reject: [
|
|
1838
|
+
"\u0391\u03C0\u03CC\u03C1\u03C1\u03B9\u03C8\u03B7",
|
|
1839
|
+
"\u0391\u03C0\u03CC\u03C1\u03C1\u03B9\u03C8\u03B7 \u03CC\u03BB\u03C9\u03BD",
|
|
1840
|
+
"\u0386\u03C1\u03BD\u03B7\u03C3\u03B7",
|
|
1841
|
+
"\u039C\u03B7 \u03B1\u03C0\u03BF\u03B4\u03BF\u03C7\u03AE",
|
|
1842
|
+
"\u039C\u03CC\u03BD\u03BF \u03C4\u03B1 \u03B1\u03C0\u03B1\u03C1\u03B1\u03AF\u03C4\u03B7\u03C4\u03B1",
|
|
1843
|
+
"\u039C\u03CC\u03BD\u03BF \u03C4\u03B1 \u03B1\u03BD\u03B1\u03B3\u03BA\u03B1\u03AF\u03B1",
|
|
1844
|
+
"\u03A3\u03C5\u03BD\u03AD\u03C7\u03B5\u03B9\u03B1 \u03C7\u03C9\u03C1\u03AF\u03C2 cookies",
|
|
1845
|
+
"\u03A7\u03C9\u03C1\u03AF\u03C2 cookies",
|
|
1846
|
+
"\u038C\u03C7\u03B9, \u03B5\u03C5\u03C7\u03B1\u03C1\u03B9\u03C3\u03C4\u03CE"
|
|
1847
|
+
],
|
|
1848
|
+
close: [
|
|
1849
|
+
"\u039A\u03BB\u03B5\u03AF\u03C3\u03B9\u03BC\u03BF",
|
|
1850
|
+
"\u039A\u03BB\u03B5\u03AF\u03C3\u03B5",
|
|
1851
|
+
"\u0386\u03BA\u03C5\u03C1\u03BF",
|
|
1852
|
+
"\u0391\u03BA\u03CD\u03C1\u03C9\u03C3\u03B7",
|
|
1853
|
+
"\u03A0\u03B1\u03C1\u03AC\u03B2\u03BB\u03B5\u03C8\u03B7",
|
|
1854
|
+
"\u038C\u03C7\u03B9 \u03C4\u03CE\u03C1\u03B1",
|
|
1855
|
+
"\u0391\u03C1\u03B3\u03CC\u03C4\u03B5\u03C1\u03B1",
|
|
1856
|
+
"\u0395\u03C0\u03B9\u03C3\u03C4\u03C1\u03BF\u03C6\u03AE",
|
|
1857
|
+
"\xD7",
|
|
1858
|
+
"\u03A7"
|
|
1859
|
+
]
|
|
1860
|
+
};
|
|
1861
|
+
var el_default = translations11;
|
|
1862
|
+
|
|
1863
|
+
// src/translations/en.ts
|
|
1864
|
+
var translations12 = {
|
|
1865
|
+
accept: ["accept", "accept all", "agree", "allow", "allow all", "ok", "okay", "got it", "continue", "save & accept"],
|
|
1866
|
+
reject: ["reject", "reject all", "decline", "deny", "only necessary", "necessary only", "only essential", "essential only", "continue without cookies", "no thanks"],
|
|
1867
|
+
close: ["close", "cancel", "dismiss", "not now", "no thanks", "later", "\xD7"]
|
|
1868
|
+
};
|
|
1869
|
+
var en_default = translations12;
|
|
1870
|
+
|
|
1871
|
+
// src/translations/es.ts
|
|
1872
|
+
var translations13 = {
|
|
1873
|
+
accept: ["Aceptar", "Aceptar todo", "Estoy de acuerdo", "Permitir", "Permitir todo", "OK", "De acuerdo", "Entendido", "Continuar", "Guardar y aceptar", "S\xED, acepto"],
|
|
1874
|
+
reject: ["Rechazar", "Rechazar todo", "Denegar", "No permitir", "Solo las necesarias", "Solo lo esencial", "Continuar sin cookies", "No, gracias", "Seguir sin aceptar", "No aceptar"],
|
|
1875
|
+
close: ["Cerrar", "Cancelar", "Descartar", "Ahora no", "No, gracias", "M\xE1s tarde", "\xD7", "Omitir", "Ignorar", "Volver"]
|
|
1876
|
+
};
|
|
1877
|
+
var es_default = translations13;
|
|
1878
|
+
|
|
1879
|
+
// src/translations/et.ts
|
|
1880
|
+
var translations14 = {
|
|
1881
|
+
accept: ["N\xF5ustun", "Olen n\xF5us", "Luba k\xF5ik", "Luba", "OK", "Olgu", "Sain aru", "J\xE4tka", "Salvesta ja n\xF5ustu", "Kinnita"],
|
|
1882
|
+
reject: ["Keeldu", "Keeldu k\xF5igist k\xFCpsistest", "\xC4ra luba", "Ainult vajalikud", "Vaid h\xE4davajalikud", "J\xE4tka ilma k\xFCpsisteta", "Ei, ait\xE4h", "\xC4ra salvesta"],
|
|
1883
|
+
close: ["Sulge", "T\xFChista", "Loobu", "Mitte praegu", "Ei, ait\xE4h", "Hiljem", "Pane kinni", "\xD7"]
|
|
1884
|
+
};
|
|
1885
|
+
var et_default = translations14;
|
|
1886
|
+
|
|
1887
|
+
// src/translations/eu.ts
|
|
1888
|
+
var translations15 = {
|
|
1889
|
+
accept: ["Onartu", "Guztiak onartu", "Ados", "Baimendu", "Guztiak baimendu", "Ulertuta", "Jarraitu", "Onartzen dut", "Gorde eta onartu", "OK"],
|
|
1890
|
+
reject: ["Ez onartu", "Guztiak ukatu", "Ukatu", "Ez baimendu", "Ezeztatu", "Beharrezkoak bakarrik", "Funtsezkoak bakarrik", "Cookie-rik gabe jarraitu", "Onartu gabe jarraitu", "Ez, eskerrik asko"],
|
|
1891
|
+
close: ["Itxi", "Ezeztatu", "Baztertu", "Orain ez", "Ez, eskerrik asko", "Geroago", "Utzi", "\xD7"]
|
|
1892
|
+
};
|
|
1893
|
+
var eu_default = translations15;
|
|
1894
|
+
|
|
1895
|
+
// src/translations/fa.ts
|
|
1896
|
+
var translations16 = {
|
|
1897
|
+
accept: ["\u067E\u0630\u06CC\u0631\u0641\u062A\u0646", "\u067E\u0630\u06CC\u0631\u0641\u062A\u0646 \u0647\u0645\u0647", "\u0642\u0628\u0648\u0644 \u0645\u06CC\u200C\u06A9\u0646\u0645", "\u0645\u0648\u0627\u0641\u0642\u0645", "\u0627\u062C\u0627\u0632\u0647 \u0645\u06CC\u200C\u062F\u0647\u0645", "\u0628\u0627\u0634\u0647", "\u062A\u0623\u06CC\u06CC\u062F", "\u0627\u062F\u0627\u0645\u0647", "\u0630\u062E\u06CC\u0631\u0647 \u0648 \u067E\u0630\u06CC\u0631\u0634", "\u062A\u0623\u06CC\u06CC\u062F \u0648 \u0627\u062F\u0627\u0645\u0647"],
|
|
1898
|
+
reject: ["\u0631\u062F \u06A9\u0631\u062F\u0646", "\u0631\u062F \u0647\u0645\u0647", "\u0639\u062F\u0645 \u067E\u0630\u06CC\u0631\u0634", "\u0627\u062C\u0627\u0632\u0647 \u0646\u0645\u06CC\u200C\u062F\u0647\u0645", "\u0641\u0642\u0637 \u0636\u0631\u0648\u0631\u06CC\u200C\u0647\u0627", "\u0641\u0642\u0637 \u0645\u0648\u0627\u0631\u062F \u0644\u0627\u0632\u0645", "\u0627\u062F\u0627\u0645\u0647 \u0628\u062F\u0648\u0646 \u06A9\u0648\u06A9\u06CC", "\u0628\u062F\u0648\u0646 \u06A9\u0648\u06A9\u06CC \u0627\u062F\u0627\u0645\u0647 \u0628\u062F\u0647", "\u0646\u0647\u060C \u0645\u0645\u0646\u0648\u0646", "\u0646\u0645\u06CC\u200C\u062E\u0648\u0627\u0647\u0645", "\u0646\u067E\u0630\u06CC\u0631\u0641\u062A\u0646"],
|
|
1899
|
+
close: ["\u0628\u0633\u062A\u0646", "\u0644\u063A\u0648", "\u0627\u0646\u0635\u0631\u0627\u0641", "\u0627\u0644\u0627\u0646 \u0646\u0647", "\u0641\u0639\u0644\u0627\u064B \u0646\u0647", "\u0628\u0639\u062F\u0627\u064B", "\xD7", "\u0628\u0627\u0632\u06AF\u0634\u062A", "\u062E\u0631\u0648\u062C"]
|
|
1900
|
+
};
|
|
1901
|
+
var fa_default = translations16;
|
|
1902
|
+
|
|
1903
|
+
// src/translations/fi.ts
|
|
1904
|
+
var translations17 = {
|
|
1905
|
+
accept: [
|
|
1906
|
+
"Hyv\xE4ksy",
|
|
1907
|
+
"Hyv\xE4ksy kaikki",
|
|
1908
|
+
"Salli",
|
|
1909
|
+
"Salli kaikki",
|
|
1910
|
+
"OK",
|
|
1911
|
+
"Okei",
|
|
1912
|
+
"Selv\xE4",
|
|
1913
|
+
"Jatka",
|
|
1914
|
+
"Tallenna ja hyv\xE4ksy",
|
|
1915
|
+
"Suostun",
|
|
1916
|
+
"Vahvista"
|
|
1917
|
+
],
|
|
1918
|
+
reject: [
|
|
1919
|
+
"Hylk\xE4\xE4",
|
|
1920
|
+
"Hylk\xE4\xE4 kaikki",
|
|
1921
|
+
"Kielt\xE4ydy",
|
|
1922
|
+
"\xC4l\xE4 salli",
|
|
1923
|
+
"Vain v\xE4ltt\xE4m\xE4tt\xF6m\xE4t",
|
|
1924
|
+
"Vain pakolliset",
|
|
1925
|
+
"Jatka ilman ev\xE4steit\xE4",
|
|
1926
|
+
"Ei kiitos",
|
|
1927
|
+
"Est\xE4",
|
|
1928
|
+
"\xC4l\xE4 hyv\xE4ksy"
|
|
1929
|
+
],
|
|
1930
|
+
close: [
|
|
1931
|
+
"Sulje",
|
|
1932
|
+
"Peruuta",
|
|
1933
|
+
"Piilota",
|
|
1934
|
+
"Ei nyt",
|
|
1935
|
+
"Ei kiitos",
|
|
1936
|
+
"My\xF6hemmin",
|
|
1937
|
+
"Valmis",
|
|
1938
|
+
"\xD7"
|
|
1939
|
+
]
|
|
1940
|
+
};
|
|
1941
|
+
var fi_default = translations17;
|
|
1942
|
+
|
|
1943
|
+
// src/translations/fr.ts
|
|
1944
|
+
var translations18 = {
|
|
1945
|
+
accept: [
|
|
1946
|
+
"Accepter",
|
|
1947
|
+
"Tout accepter",
|
|
1948
|
+
"J'accepte",
|
|
1949
|
+
"Autoriser",
|
|
1950
|
+
"Tout autoriser",
|
|
1951
|
+
"OK",
|
|
1952
|
+
"D'accord",
|
|
1953
|
+
"Compris",
|
|
1954
|
+
"Continuer",
|
|
1955
|
+
"Enregistrer et accepter",
|
|
1956
|
+
"Valider",
|
|
1957
|
+
"Accepter et continuer"
|
|
1958
|
+
],
|
|
1959
|
+
reject: [
|
|
1960
|
+
"Refuser",
|
|
1961
|
+
"Tout refuser",
|
|
1962
|
+
"Je refuse",
|
|
1963
|
+
"Refuser tout",
|
|
1964
|
+
"N'autoriser que l'essentiel",
|
|
1965
|
+
"Essentiels uniquement",
|
|
1966
|
+
"Uniquement le n\xE9cessaire",
|
|
1967
|
+
"Continuer sans cookies",
|
|
1968
|
+
"Non merci",
|
|
1969
|
+
"Ne pas autoriser",
|
|
1970
|
+
"Refuser et continuer"
|
|
1971
|
+
],
|
|
1972
|
+
close: [
|
|
1973
|
+
"Fermer",
|
|
1974
|
+
"Annuler",
|
|
1975
|
+
"Ignorer",
|
|
1976
|
+
"Pas maintenant",
|
|
1977
|
+
"Non merci",
|
|
1978
|
+
"Plus tard",
|
|
1979
|
+
"\xD7",
|
|
1980
|
+
"Fermer la fen\xEAtre",
|
|
1981
|
+
"Masquer"
|
|
1982
|
+
]
|
|
1983
|
+
};
|
|
1984
|
+
var fr_default = translations18;
|
|
1985
|
+
|
|
1986
|
+
// src/translations/ga.ts
|
|
1987
|
+
var translations19 = {
|
|
1988
|
+
accept: [
|
|
1989
|
+
"Glac",
|
|
1990
|
+
"Glac leis",
|
|
1991
|
+
"Glac le gach rud",
|
|
1992
|
+
"Aonta\xEDm",
|
|
1993
|
+
"Ceadaigh",
|
|
1994
|
+
"Ceadaigh gach rud",
|
|
1995
|
+
"OK",
|
|
1996
|
+
"Ceart go leor",
|
|
1997
|
+
"Tuigim",
|
|
1998
|
+
"Lean ar aghaidh",
|
|
1999
|
+
"S\xE1bh\xE1il agus glac"
|
|
2000
|
+
],
|
|
2001
|
+
reject: [
|
|
2002
|
+
"Di\xFAltaigh",
|
|
2003
|
+
"Di\xFAltaigh gach rud",
|
|
2004
|
+
"Di\xFAlta\xEDm",
|
|
2005
|
+
"N\xE1 glac",
|
|
2006
|
+
"N\xE1 ceadaigh",
|
|
2007
|
+
"Na cinn riachtanacha amh\xE1in",
|
|
2008
|
+
"Gan ach na riachtanacha",
|
|
2009
|
+
"Lean ar aghaidh gan fhian\xE1in",
|
|
2010
|
+
"Gan fhian\xE1in",
|
|
2011
|
+
"N\xEDl, go raibh maith agat"
|
|
2012
|
+
],
|
|
2013
|
+
close: [
|
|
2014
|
+
"D\xFAn",
|
|
2015
|
+
"Cealaigh",
|
|
2016
|
+
"Cuir ar ceal",
|
|
2017
|
+
"Scoir",
|
|
2018
|
+
"N\xE1 bac leis",
|
|
2019
|
+
"N\xED anois",
|
|
2020
|
+
"N\xEDos d\xE9ana\xED",
|
|
2021
|
+
"Ar ball",
|
|
2022
|
+
"\xD7"
|
|
2023
|
+
]
|
|
2024
|
+
};
|
|
2025
|
+
var ga_default = translations19;
|
|
2026
|
+
|
|
2027
|
+
// src/translations/he.ts
|
|
2028
|
+
var translations20 = {
|
|
2029
|
+
accept: [
|
|
2030
|
+
"\u05D0\u05E9\u05E8",
|
|
2031
|
+
"\u05D0\u05E9\u05E8 \u05D4\u05DB\u05DC",
|
|
2032
|
+
"\u05DE\u05E1\u05DB\u05D9\u05DD",
|
|
2033
|
+
"\u05D0\u05E0\u05D9 \u05DE\u05E1\u05DB\u05D9\u05DD",
|
|
2034
|
+
"\u05D0\u05E4\u05E9\u05E8",
|
|
2035
|
+
"\u05D0\u05E4\u05E9\u05E8 \u05D4\u05DB\u05DC",
|
|
2036
|
+
"\u05D1\u05E1\u05D3\u05E8",
|
|
2037
|
+
"\u05D0\u05D5\u05E7\u05D9\u05D9",
|
|
2038
|
+
"\u05D4\u05D1\u05E0\u05EA\u05D9",
|
|
2039
|
+
"\u05D4\u05DE\u05E9\u05DA",
|
|
2040
|
+
"\u05E9\u05DE\u05D5\u05E8 \u05D5\u05D0\u05E9\u05E8",
|
|
2041
|
+
"\u05E9\u05DE\u05D5\u05E8 \u05D5\u05D4\u05DE\u05E9\u05DA",
|
|
2042
|
+
"\u05E7\u05D1\u05DC \u05D4\u05DB\u05DC"
|
|
2043
|
+
],
|
|
2044
|
+
reject: [
|
|
2045
|
+
"\u05D3\u05D7\u05D4",
|
|
2046
|
+
"\u05D3\u05D7\u05D4 \u05D4\u05DB\u05DC",
|
|
2047
|
+
"\u05E1\u05E8\u05D1",
|
|
2048
|
+
"\u05D0\u05DC \u05EA\u05D0\u05E9\u05E8",
|
|
2049
|
+
"\u05D0\u05DC \u05EA\u05D0\u05E4\u05E9\u05E8",
|
|
2050
|
+
"\u05E8\u05E7 \u05D4\u05DB\u05E8\u05D7\u05D9",
|
|
2051
|
+
"\u05D4\u05DB\u05E8\u05D7\u05D9 \u05D1\u05DC\u05D1\u05D3",
|
|
2052
|
+
"\u05D4\u05DE\u05E9\u05DA \u05DC\u05DC\u05D0 \u05E7\u05D5\u05D1\u05E6\u05D9 Cookie",
|
|
2053
|
+
"\u05D4\u05DE\u05E9\u05DA \u05D1\u05DC\u05D9 \u05E2\u05D5\u05D2\u05D9\u05D5\u05EA",
|
|
2054
|
+
"\u05DC\u05D0 \u05EA\u05D5\u05D3\u05D4",
|
|
2055
|
+
"\u05D0\u05DC \u05EA\u05E9\u05DE\u05D5\u05E8",
|
|
2056
|
+
"\u05D1\u05D8\u05DC \u05D4\u05E1\u05DB\u05DE\u05D4"
|
|
2057
|
+
],
|
|
2058
|
+
close: [
|
|
2059
|
+
"\u05E1\u05D2\u05D5\u05E8",
|
|
2060
|
+
"\u05E1\u05D2\u05D9\u05E8\u05D4",
|
|
2061
|
+
"\u05D1\u05D8\u05DC",
|
|
2062
|
+
"\u05D1\u05D9\u05D8\u05D5\u05DC",
|
|
2063
|
+
"\u05DC\u05D0 \u05E2\u05DB\u05E9\u05D9\u05D5",
|
|
2064
|
+
"\u05DE\u05D0\u05D5\u05D7\u05E8 \u05D9\u05D5\u05EA\u05E8",
|
|
2065
|
+
"\u05D0\u05D7\u05E8 \u05DB\u05DA",
|
|
2066
|
+
"\xD7",
|
|
2067
|
+
"\u05E1\u05D2\u05D5\u05E8 \u05D7\u05DC\u05D5\u05DF",
|
|
2068
|
+
"\u05D7\u05D6\u05E8\u05D4"
|
|
2069
|
+
]
|
|
2070
|
+
};
|
|
2071
|
+
var he_default = translations20;
|
|
2072
|
+
|
|
2073
|
+
// src/translations/hi.ts
|
|
2074
|
+
var translations21 = {
|
|
2075
|
+
accept: [
|
|
2076
|
+
"\u0938\u094D\u0935\u0940\u0915\u093E\u0930 \u0915\u0930\u0947\u0902",
|
|
2077
|
+
"\u0938\u092D\u0940 \u0938\u094D\u0935\u0940\u0915\u093E\u0930 \u0915\u0930\u0947\u0902",
|
|
2078
|
+
"\u092E\u0948\u0902 \u0938\u0939\u092E\u0924 \u0939\u0942\u0901",
|
|
2079
|
+
"\u0905\u0928\u0941\u092E\u0924\u093F \u0926\u0947\u0902",
|
|
2080
|
+
"\u0938\u092D\u0940 \u0915\u094B \u0905\u0928\u0941\u092E\u0924\u093F \u0926\u0947\u0902",
|
|
2081
|
+
"\u0920\u0940\u0915 \u0939\u0948",
|
|
2082
|
+
"\u091C\u093E\u0930\u0940 \u0930\u0916\u0947\u0902",
|
|
2083
|
+
"\u0938\u094D\u0935\u0940\u0915\u093E\u0930 \u0915\u0930\u0915\u0947 \u0906\u0917\u0947 \u092C\u0922\u093C\u0947\u0902",
|
|
2084
|
+
"\u0938\u0939\u0947\u091C\u0947\u0902 \u0914\u0930 \u0938\u094D\u0935\u0940\u0915\u093E\u0930\u0947\u0902",
|
|
2085
|
+
"\u0939\u093E\u0901"
|
|
2086
|
+
],
|
|
2087
|
+
reject: [
|
|
2088
|
+
"\u0905\u0938\u094D\u0935\u0940\u0915\u093E\u0930 \u0915\u0930\u0947\u0902",
|
|
2089
|
+
"\u0938\u092D\u0940 \u0905\u0938\u094D\u0935\u0940\u0915\u093E\u0930 \u0915\u0930\u0947\u0902",
|
|
2090
|
+
"\u0907\u0902\u0915\u093E\u0930 \u0915\u0930\u0947\u0902",
|
|
2091
|
+
"\u0905\u0928\u0941\u092E\u0924\u093F \u0928 \u0926\u0947\u0902",
|
|
2092
|
+
"\u0915\u0947\u0935\u0932 \u0906\u0935\u0936\u094D\u092F\u0915",
|
|
2093
|
+
"\u0938\u093F\u0930\u094D\u092B \u0906\u0935\u0936\u094D\u092F\u0915",
|
|
2094
|
+
"\u0915\u0947\u0935\u0932 \u0906\u0935\u0936\u094D\u092F\u0915 \u0915\u0941\u0915\u0940\u091C\u093C",
|
|
2095
|
+
"\u0915\u0941\u0915\u0940\u091C\u093C \u0915\u0947 \u092C\u093F\u0928\u093E \u091C\u093E\u0930\u0940 \u0930\u0916\u0947\u0902",
|
|
2096
|
+
"\u0928\u0939\u0940\u0902, \u0927\u0928\u094D\u092F\u0935\u093E\u0926",
|
|
2097
|
+
"\u0938\u094D\u0935\u0940\u0915\u093E\u0930 \u0928 \u0915\u0930\u0947\u0902"
|
|
2098
|
+
],
|
|
2099
|
+
close: [
|
|
2100
|
+
"\u092C\u0902\u0926 \u0915\u0930\u0947\u0902",
|
|
2101
|
+
"\u0930\u0926\u094D\u0926 \u0915\u0930\u0947\u0902",
|
|
2102
|
+
"\u0916\u093E\u0930\u093F\u091C \u0915\u0930\u0947\u0902",
|
|
2103
|
+
"\u0905\u092D\u0940 \u0928\u0939\u0940\u0902",
|
|
2104
|
+
"\u0928\u0939\u0940\u0902, \u0927\u0928\u094D\u092F\u0935\u093E\u0926",
|
|
2105
|
+
"\u092C\u093E\u0926 \u092E\u0947\u0902",
|
|
2106
|
+
"\xD7",
|
|
2107
|
+
"\u0935\u093E\u092A\u0938",
|
|
2108
|
+
"\u092C\u093E\u0939\u0930 \u0928\u093F\u0915\u0932\u0947\u0902"
|
|
2109
|
+
]
|
|
2110
|
+
};
|
|
2111
|
+
var hi_default = translations21;
|
|
2112
|
+
|
|
2113
|
+
// src/translations/hr.ts
|
|
2114
|
+
var translations22 = {
|
|
2115
|
+
accept: ["Prihvati", "Prihvati sve", "Sla\u017Eem se", "Dopusti", "Dopusti sve", "U redu", "OK", "Razumijem", "Nastavi", "Spremi i prihvati", "Spremi postavke", "Potvrdi"],
|
|
2116
|
+
reject: ["Odbij", "Odbij sve", "Odbijam", "Ne prihva\u0107am", "Ne dopu\u0161tam", "Samo nu\u017Eni", "Samo osnovno", "Nastavi bez kola\u010Di\u0107a", "Bez dodatnih kola\u010Di\u0107a", "Ne, hvala"],
|
|
2117
|
+
close: ["Zatvori", "Odustani", "Odbaci", "Zanemari", "Ne sada", "Ne, hvala", "Kasnije", "\xD7", "Zatvori prozor", "Zatvori obavijest"]
|
|
2118
|
+
};
|
|
2119
|
+
var hr_default = translations22;
|
|
2120
|
+
|
|
2121
|
+
// src/translations/hu.ts
|
|
2122
|
+
var translations23 = {
|
|
2123
|
+
accept: ["Elfogadom", "Mindet elfogadom", "Hozz\xE1j\xE1rulok", "Enged\xE9lyezem", "\xD6sszes elfogad\xE1sa", "\xD6sszes enged\xE9lyez\xE9se", "OK", "Ok\xE9", "\xC9rtettem", "Tov\xE1bb", "Rendben", "Be\xE1ll\xEDt\xE1sok ment\xE9se", "Ment\xE9s \xE9s elfogadom"],
|
|
2124
|
+
reject: ["Elutas\xEDtom", "Mindet elutas\xEDtom", "Nem fogadom el", "Nem enged\xE9lyezem", "Csak a sz\xFCks\xE9geseket", "Csak a n\xE9lk\xFCl\xF6zhetetlenek", "Csak alapbe\xE1ll\xEDt\xE1sok", "Csak k\xF6telez\u0151k", "Folytat\xE1s s\xFCtik n\xE9lk\xFCl", "K\xF6sz\xF6n\xF6m, nem", "Nem k\xE9rem"],
|
|
2125
|
+
close: ["Bez\xE1r\xE1s", "Bez\xE1r", "M\xE9gse", "Most nem", "Nem most", "K\xE9s\u0151bb", "Nem k\xE9rem", "\xD7"]
|
|
2126
|
+
};
|
|
2127
|
+
var hu_default = translations23;
|
|
2128
|
+
|
|
2129
|
+
// src/translations/hy.ts
|
|
2130
|
+
var translations24 = {
|
|
2131
|
+
accept: ["\u0538\u0576\u0564\u0578\u0582\u0576\u0565\u056C", "\u0538\u0576\u0564\u0578\u0582\u0576\u0565\u056C \u0562\u0578\u056C\u0578\u0580\u0568", "\u0540\u0561\u0574\u0561\u0571\u0561\u0575\u0576 \u0565\u0574", "\u0539\u0578\u0582\u0575\u056C\u0561\u057F\u0580\u0565\u056C", "\u0539\u0578\u0582\u0575\u056C\u0561\u057F\u0580\u0565\u056C \u0562\u0578\u056C\u0578\u0580\u0568", "\u053C\u0561\u057E", "OK", "\u0540\u0561\u057D\u056F\u0561\u0581\u0561", "\u0547\u0561\u0580\u0578\u0582\u0576\u0561\u056F\u0565\u056C", "\u054A\u0561\u0570\u057A\u0561\u0576\u0565\u056C \u0587 \u0568\u0576\u0564\u0578\u0582\u0576\u0565\u056C", "\u0540\u0561\u057D\u057F\u0561\u057F\u0565\u056C"],
|
|
2132
|
+
reject: ["\u0544\u0565\u0580\u056A\u0565\u056C", "\u0544\u0565\u0580\u056A\u0565\u056C \u0562\u0578\u056C\u0578\u0580\u0568", "\u0549\u0565\u0574 \u0570\u0561\u0574\u0561\u0571\u0561\u0575\u0576\u057E\u0578\u0582\u0574", "\u0549\u0569\u0578\u0582\u0575\u056C\u0561\u057F\u0580\u0565\u056C", "\u0544\u056B\u0561\u0575\u0576 \u0561\u0576\u0570\u0580\u0561\u056A\u0565\u0577\u057F\u0568", "\u0544\u056B\u0561\u0575\u0576 \u0567\u0561\u056F\u0561\u0576\u0568", "\u0544\u056B\u0561\u0575\u0576 \u057A\u0561\u0580\u057F\u0561\u0564\u056B\u0580\u0576\u0565\u0580\u0568", "\u0547\u0561\u0580\u0578\u0582\u0576\u0561\u056F\u0565\u056C \u0561\u057C\u0561\u0576\u0581 \u0584\u0578\u0582\u0584\u056B\u0576\u0565\u0580\u056B", "\u0548\u0579, \u0577\u0576\u0578\u0580\u0570\u0561\u056F\u0561\u056C\u0578\u0582\u0569\u0575\u0578\u0582\u0576"],
|
|
2133
|
+
close: ["\u0553\u0561\u056F\u0565\u056C", "\u0549\u0565\u0572\u0561\u0580\u056F\u0565\u056C", "\u0531\u0576\u057F\u0565\u057D\u0565\u056C", "\u0548\u0579 \u0570\u056B\u0574\u0561", "\u0548\u0579, \u0577\u0576\u0578\u0580\u0570\u0561\u056F\u0561\u056C\u0578\u0582\u0569\u0575\u0578\u0582\u0576", "\u0540\u0565\u057F\u0578", "\u0553\u0561\u056F\u0565\u056C \u057A\u0561\u057F\u0578\u0582\u0570\u0561\u0576\u0568", "\xD7"]
|
|
2134
|
+
};
|
|
2135
|
+
var hy_default = translations24;
|
|
2136
|
+
|
|
2137
|
+
// src/translations/id.ts
|
|
2138
|
+
var translations25 = {
|
|
2139
|
+
accept: ["Setuju", "Setujui semua", "Terima", "Terima semua", "Izinkan", "Izinkan semua", "OK", "Oke", "Baik", "Saya mengerti", "Lanjutkan", "Simpan & setujui", "Simpan pengaturan"],
|
|
2140
|
+
reject: ["Tolak", "Tolak semua", "Jangan izinkan", "Hanya yang diperlukan", "Esensial saja", "Yang penting saja", "Lanjut tanpa cookie", "Tidak, terima kasih"],
|
|
2141
|
+
close: ["Tutup", "Batal", "Abaikan", "Tidak sekarang", "Nanti saja", "Lewati dulu", "\xD7"]
|
|
2142
|
+
};
|
|
2143
|
+
var id_default = translations25;
|
|
2144
|
+
|
|
2145
|
+
// src/translations/is.ts
|
|
2146
|
+
var translations26 = {
|
|
2147
|
+
accept: ["Sam\xFEykkja", "Sam\xFEykkja allt", "\xC9g sam\xFEykki", "Leyfa", "Leyfa allt", "Allt \xED lagi", "\xCD lagi", "OK", "Skil", "Halda \xE1fram", "Vista og sam\xFEykkja", "Sta\xF0festa", "Sam\xFEykkja og halda \xE1fram"],
|
|
2148
|
+
reject: ["Hafna", "Hafna \xF6llu", "Neita", "Neita \xF6llum", "Leyfi ekki", "A\xF0eins nau\xF0synlegar", "Einungis nau\xF0synlegar", "Halda \xE1fram \xE1n vafrakaka", "Engar vafrak\xF6kur", "Nei, takk"],
|
|
2149
|
+
close: ["Loka", "H\xE6tta vi\xF0", "Hunsa", "Ekki n\xFAna", "Nei, takk", "S\xED\xF0ar", "Seinna", "\xD7", "Loka glugga"]
|
|
2150
|
+
};
|
|
2151
|
+
var is_default = translations26;
|
|
2152
|
+
|
|
2153
|
+
// src/translations/it.ts
|
|
2154
|
+
var translations27 = {
|
|
2155
|
+
accept: ["Aceptar", "Aceptar todo", "Estoy de acuerdo", "Permitir", "Permitir todo", "OK", "Vale", "Entendido", "Continuar", "Guardar y aceptar", "Aceptar y continuar", "S\xED, acepto"],
|
|
2156
|
+
reject: ["Rechazar", "Rechazar todo", "Declinar", "Denegar", "Solo necesarias", "Solo lo esencial", "Continuar sin cookies", "No, gracias", "Rechazar opcionales", "No aceptar", "Usar solo las imprescindibles"],
|
|
2157
|
+
close: ["Cerrar", "Cancelar", "Descartar", "Ahora no", "No, gracias", "M\xE1s tarde", "\xD7", "Omitir", "Volver", "Cerrar ventana"]
|
|
2158
|
+
};
|
|
2159
|
+
var it_default = translations27;
|
|
2160
|
+
|
|
2161
|
+
// src/translations/ja.ts
|
|
2162
|
+
var translations28 = {
|
|
2163
|
+
accept: ["\u540C\u610F\u3059\u308B", "\u3059\u3079\u3066\u540C\u610F", "\u8A31\u53EF\u3059\u308B", "\u3059\u3079\u3066\u8A31\u53EF", "OK", "\u306F\u3044", "\u308F\u304B\u308A\u307E\u3057\u305F", "\u7D9A\u884C", "\u540C\u610F\u3057\u3066\u7D9A\u884C", "\u4FDD\u5B58\u3057\u3066\u540C\u610F", "\u4FDD\u5B58\u3057\u3066\u7D9A\u884C"],
|
|
2164
|
+
reject: ["\u62D2\u5426\u3059\u308B", "\u3059\u3079\u3066\u62D2\u5426", "\u540C\u610F\u3057\u306A\u3044", "\u8A31\u53EF\u3057\u306A\u3044", "\u5FC5\u9808\u306E\u307F", "\u5FC5\u8981\u6700\u4F4E\u9650\u306E\u307F", "\u5FC5\u8981\u306A\u3082\u306E\u306E\u307F\u8A31\u53EF", "\u540C\u610F\u305B\u305A\u306B\u7D9A\u884C", "Cookie\u306A\u3057\u3067\u7D9A\u884C", "\u4ECA\u56DE\u306F\u898B\u9001\u308B"],
|
|
2165
|
+
close: ["\u9589\u3058\u308B", "\u30AD\u30E3\u30F3\u30BB\u30EB", "\u4ECA\u306F\u3057\u306A\u3044", "\u5F8C\u3067", "\xD7", "\u30B9\u30AD\u30C3\u30D7", "\u53D6\u308A\u6D88\u3057", "\u4ECA\u306F\u3084\u3081\u3066\u304A\u304F"]
|
|
2166
|
+
};
|
|
2167
|
+
var ja_default = translations28;
|
|
2168
|
+
|
|
2169
|
+
// src/translations/ka.ts
|
|
2170
|
+
var translations29 = {
|
|
2171
|
+
accept: [
|
|
2172
|
+
"\u10D5\u10D4\u10D7\u10D0\u10DC\u10EE\u10DB\u10D4\u10D1\u10D8",
|
|
2173
|
+
"\u10DB\u10D8\u10E6\u10D4\u10D1\u10D0",
|
|
2174
|
+
"\u10D3\u10D0\u10D3\u10D0\u10E1\u10E2\u10E3\u10E0\u10D4\u10D1\u10D0",
|
|
2175
|
+
"\u10D3\u10D0\u10E8\u10D5\u10D4\u10D1\u10D0",
|
|
2176
|
+
"\u10E7\u10D5\u10D4\u10DA\u10D0\u10E4\u10E0\u10D8\u10E1 \u10DB\u10D8\u10E6\u10D4\u10D1\u10D0",
|
|
2177
|
+
"\u10E7\u10D5\u10D4\u10DA\u10D0\u10E1 \u10D3\u10D0\u10E8\u10D5\u10D4\u10D1\u10D0",
|
|
2178
|
+
"\u10D9\u10D0\u10E0\u10D2\u10D8",
|
|
2179
|
+
"\u10D2\u10D0\u10E1\u10D0\u10D2\u10D4\u10D1\u10D8\u10D0",
|
|
2180
|
+
"\u10D2\u10D0\u10D2\u10E0\u10EB\u10D4\u10DA\u10D4\u10D1\u10D0",
|
|
2181
|
+
"\u10E8\u10D4\u10DC\u10D0\u10EE\u10D5\u10D0 \u10D3\u10D0 \u10D7\u10D0\u10DC\u10EE\u10DB\u10DD\u10D1\u10D0",
|
|
2182
|
+
"\u10E8\u10D4\u10DC\u10D0\u10EE\u10D5\u10D0 \u10D3\u10D0 \u10DB\u10D8\u10E6\u10D4\u10D1\u10D0"
|
|
2183
|
+
],
|
|
2184
|
+
reject: [
|
|
2185
|
+
"\u10E3\u10D0\u10E0\u10E7\u10DD\u10E4\u10D0",
|
|
2186
|
+
"\u10E7\u10D5\u10D4\u10DA\u10D0\u10E4\u10E0\u10D8\u10E1 \u10E3\u10D0\u10E0\u10E7\u10DD\u10E4\u10D0",
|
|
2187
|
+
"\u10E3\u10D0\u10E0\u10D8\u10E1 \u10D7\u10E5\u10DB\u10D0",
|
|
2188
|
+
"\u10D0\u10E0 \u10D3\u10D0\u10D5\u10E3\u10E8\u10D5\u10D0",
|
|
2189
|
+
"\u10DB\u10EE\u10DD\u10DA\u10DD\u10D3 \u10D0\u10E3\u10EA\u10D8\u10DA\u10D4\u10D1\u10D4\u10DA\u10D8",
|
|
2190
|
+
"\u10DB\u10EE\u10DD\u10DA\u10DD\u10D3 \u10D0\u10E3\u10EA\u10D8\u10DA\u10D4\u10D1\u10D4\u10DA\u10D8 \u10E5\u10E3\u10E5\u10D8-\u10E4\u10D0\u10D8\u10DA\u10D4\u10D1\u10D8",
|
|
2191
|
+
"\u10D2\u10D0\u10D2\u10E0\u10EB\u10D4\u10DA\u10D4\u10D1\u10D0 \u10E5\u10E3\u10E5\u10D8-\u10E4\u10D0\u10D8\u10DA\u10D4\u10D1\u10D8\u10E1 \u10D2\u10D0\u10E0\u10D4\u10E8\u10D4",
|
|
2192
|
+
"\u10D0\u10E0\u10D0, \u10DB\u10D0\u10D3\u10DA\u10DD\u10D1\u10D0"
|
|
2193
|
+
],
|
|
2194
|
+
close: [
|
|
2195
|
+
"\u10D3\u10D0\u10EE\u10E3\u10E0\u10D5\u10D0",
|
|
2196
|
+
"\u10D2\u10D0\u10E3\u10E5\u10DB\u10D4\u10D1\u10D0",
|
|
2197
|
+
"\u10D3\u10D0\u10DB\u10D0\u10DA\u10D5\u10D0",
|
|
2198
|
+
"\u10D0\u10EE\u10DA\u10D0 \u10D0\u10E0\u10D0",
|
|
2199
|
+
"\u10D0\u10E0\u10D0, \u10DB\u10D0\u10D3\u10DA\u10DD\u10D1\u10D0",
|
|
2200
|
+
"\u10DB\u10DD\u10D2\u10D5\u10D8\u10D0\u10DC\u10D4\u10D1\u10D8\u10D7",
|
|
2201
|
+
"\xD7"
|
|
2202
|
+
]
|
|
2203
|
+
};
|
|
2204
|
+
var ka_default = translations29;
|
|
2205
|
+
|
|
2206
|
+
// src/translations/ko.ts
|
|
2207
|
+
var translations30 = {
|
|
2208
|
+
accept: ["\uB3D9\uC758", "\uBAA8\uB450 \uB3D9\uC758", "\uD5C8\uC6A9", "\uC804\uCCB4 \uD5C8\uC6A9", "\uD655\uC778", "\uC54C\uACA0\uC2B5\uB2C8\uB2E4", "\uACC4\uC18D", "\uB3D9\uC758\uD558\uACE0 \uACC4\uC18D", "\uC800\uC7A5\uD558\uACE0 \uB3D9\uC758", "\uC801\uC6A9"],
|
|
2209
|
+
reject: ["\uAC70\uBD80", "\uBAA8\uB450 \uAC70\uBD80", "\uB3D9\uC758 \uC548 \uD568", "\uD5C8\uC6A9 \uC548 \uD568", "\uD544\uC218\uB9CC \uD5C8\uC6A9", "\uD544\uC218 \uD56D\uBAA9\uB9CC", "\uCFE0\uD0A4 \uC5C6\uC774 \uACC4\uC18D", "\uAC74\uB108\uB6F0\uAE30", "\uAD1C\uCC2E\uC2B5\uB2C8\uB2E4"],
|
|
2210
|
+
close: ["\uB2EB\uAE30", "\uCDE8\uC18C", "\uC228\uAE30\uAE30", "\uC9C0\uAE08\uC740 \uC548 \uD568", "\uB098\uC911\uC5D0", "\xD7"]
|
|
2211
|
+
};
|
|
2212
|
+
var ko_default = translations30;
|
|
2213
|
+
|
|
2214
|
+
// src/translations/lt.ts
|
|
2215
|
+
var translations31 = {
|
|
2216
|
+
accept: ["Sutinku", "Leisti", "Leisti visk\u0105", "Gerai", "Supratau", "T\u0119sti", "Patvirtinti", "I\u0161saugoti ir sutikti", "OK"],
|
|
2217
|
+
reject: ["Atmesti", "Atmesti visus", "Atsisakyti", "Neleisti", "Tik b\u016Btini slapukai", "Tik esminiai slapukai", "T\u0119sti be slapuk\u0173", "Ne, a\u010Di\u016B"],
|
|
2218
|
+
close: ["U\u017Edaryti", "U\u017Everti", "At\u0161aukti", "Ne dabar", "V\u0117liau", "A\u010Di\u016B, ne", "Gr\u012F\u017Eti", "\xD7"]
|
|
2219
|
+
};
|
|
2220
|
+
var lt_default = translations31;
|
|
2221
|
+
|
|
2222
|
+
// src/translations/lv.ts
|
|
2223
|
+
var translations32 = {
|
|
2224
|
+
accept: [
|
|
2225
|
+
"Piekr\u012Btu",
|
|
2226
|
+
"Pie\u0146emt",
|
|
2227
|
+
"Pie\u0146emt visu",
|
|
2228
|
+
"At\u013Caut",
|
|
2229
|
+
"At\u013Caut visu",
|
|
2230
|
+
"Labi",
|
|
2231
|
+
"OK",
|
|
2232
|
+
"Sapratu",
|
|
2233
|
+
"Turpin\u0101t",
|
|
2234
|
+
"Apstiprin\u0101t",
|
|
2235
|
+
"Apstiprin\u0101t izv\u0113li",
|
|
2236
|
+
"Saglab\u0101t un piekrist",
|
|
2237
|
+
"Saglab\u0101t iestat\u012Bjumus"
|
|
2238
|
+
],
|
|
2239
|
+
reject: [
|
|
2240
|
+
"Noraid\u012Bt",
|
|
2241
|
+
"Noraid\u012Bt visu",
|
|
2242
|
+
"Nepiekrist",
|
|
2243
|
+
"Neat\u013Caut",
|
|
2244
|
+
"Neat\u013Caut nevienu",
|
|
2245
|
+
"Tikai nepiecie\u0161am\u0101s",
|
|
2246
|
+
"Tikai b\u016Btisk\u0101s s\u012Bkdatnes",
|
|
2247
|
+
"Turpin\u0101t bez s\u012Bkdatn\u0113m",
|
|
2248
|
+
"N\u0113, paldies",
|
|
2249
|
+
"Aizliegt",
|
|
2250
|
+
"Atteikties"
|
|
2251
|
+
],
|
|
2252
|
+
close: [
|
|
2253
|
+
"Aizv\u0113rt",
|
|
2254
|
+
"Aizv\u0113rt logu",
|
|
2255
|
+
"Atcelt",
|
|
2256
|
+
"Ner\u0101d\u012Bt tagad",
|
|
2257
|
+
"Ne tagad",
|
|
2258
|
+
"N\u0113, paldies",
|
|
2259
|
+
"V\u0113l\u0101k",
|
|
2260
|
+
"\xD7",
|
|
2261
|
+
"Aizv\u0113rt pazi\u0146ojumu"
|
|
2262
|
+
]
|
|
2263
|
+
};
|
|
2264
|
+
var lv_default = translations32;
|
|
2265
|
+
|
|
2266
|
+
// src/translations/nl.ts
|
|
2267
|
+
var translations33 = {
|
|
2268
|
+
accept: [
|
|
2269
|
+
"Accepteren",
|
|
2270
|
+
"Alles accepteren",
|
|
2271
|
+
"Ik ga akkoord",
|
|
2272
|
+
"Toestaan",
|
|
2273
|
+
"Alles toestaan",
|
|
2274
|
+
"OK",
|
|
2275
|
+
"Ok\xE9",
|
|
2276
|
+
"Begrepen",
|
|
2277
|
+
"Doorgaan",
|
|
2278
|
+
"Opslaan en accepteren",
|
|
2279
|
+
"Akkoord",
|
|
2280
|
+
"Verder",
|
|
2281
|
+
"Ja, prima"
|
|
2282
|
+
],
|
|
2283
|
+
reject: [
|
|
2284
|
+
"Weigeren",
|
|
2285
|
+
"Alles weigeren",
|
|
2286
|
+
"Afwijzen",
|
|
2287
|
+
"Niet toestaan",
|
|
2288
|
+
"Alleen noodzakelijke cookies",
|
|
2289
|
+
"Alleen essenti\xEBle cookies",
|
|
2290
|
+
"Alleen strikt noodzakelijke cookies",
|
|
2291
|
+
"Verder zonder cookies",
|
|
2292
|
+
"Nee, bedankt",
|
|
2293
|
+
"Alleen functioneel",
|
|
2294
|
+
"Minimale instellingen"
|
|
2295
|
+
],
|
|
2296
|
+
close: [
|
|
2297
|
+
"Sluiten",
|
|
2298
|
+
"Annuleren",
|
|
2299
|
+
"Afbreken",
|
|
2300
|
+
"Niet nu",
|
|
2301
|
+
"Nee, bedankt",
|
|
2302
|
+
"Later",
|
|
2303
|
+
"\xD7",
|
|
2304
|
+
"Terug",
|
|
2305
|
+
"Venster sluiten"
|
|
2306
|
+
]
|
|
2307
|
+
};
|
|
2308
|
+
var nl_default = translations33;
|
|
2309
|
+
|
|
2310
|
+
// src/translations/no.ts
|
|
2311
|
+
var translations34 = {
|
|
2312
|
+
accept: [
|
|
2313
|
+
"Godta",
|
|
2314
|
+
"Godta alle",
|
|
2315
|
+
"Aksepter",
|
|
2316
|
+
"Aksepter alle",
|
|
2317
|
+
"Tillat",
|
|
2318
|
+
"Tillat alle",
|
|
2319
|
+
"OK",
|
|
2320
|
+
"Greit",
|
|
2321
|
+
"Forst\xE5tt",
|
|
2322
|
+
"Fortsett",
|
|
2323
|
+
"G\xE5 videre",
|
|
2324
|
+
"Lagre og godta",
|
|
2325
|
+
"Lagre og aksepter",
|
|
2326
|
+
"Jeg samtykker",
|
|
2327
|
+
"Bekreft"
|
|
2328
|
+
],
|
|
2329
|
+
reject: [
|
|
2330
|
+
"Avsl\xE5",
|
|
2331
|
+
"Avsl\xE5 alle",
|
|
2332
|
+
"Avvis",
|
|
2333
|
+
"Avvis alle",
|
|
2334
|
+
"Ikke tillat",
|
|
2335
|
+
"Kun n\xF8dvendige",
|
|
2336
|
+
"Bare n\xF8dvendige",
|
|
2337
|
+
"Kun essensielle",
|
|
2338
|
+
"Kun n\xF8dvendige informasjonskapsler",
|
|
2339
|
+
"Fortsett uten informasjonskapsler",
|
|
2340
|
+
"Fortsett uten cookies",
|
|
2341
|
+
"Nei takk"
|
|
2342
|
+
],
|
|
2343
|
+
close: [
|
|
2344
|
+
"Lukk",
|
|
2345
|
+
"Avbryt",
|
|
2346
|
+
"Skjul",
|
|
2347
|
+
"Ikke n\xE5",
|
|
2348
|
+
"Nei takk",
|
|
2349
|
+
"Senere",
|
|
2350
|
+
"Tilbake",
|
|
2351
|
+
"Lukk uten \xE5 lagre",
|
|
2352
|
+
"\xD7"
|
|
2353
|
+
]
|
|
2354
|
+
};
|
|
2355
|
+
var no_default = translations34;
|
|
2356
|
+
|
|
2357
|
+
// src/translations/pl.ts
|
|
2358
|
+
var translations35 = {
|
|
2359
|
+
accept: [
|
|
2360
|
+
"Akceptuj\u0119",
|
|
2361
|
+
"Akceptuj\u0119 wszystkie",
|
|
2362
|
+
"Zgadzam si\u0119",
|
|
2363
|
+
"Zezw\xF3l",
|
|
2364
|
+
"Zezw\xF3l na wszystkie",
|
|
2365
|
+
"OK",
|
|
2366
|
+
"Okej",
|
|
2367
|
+
"Rozumiem",
|
|
2368
|
+
"Kontynuuj",
|
|
2369
|
+
"Zapisz i zaakceptuj",
|
|
2370
|
+
"Potwierd\u017A"
|
|
2371
|
+
],
|
|
2372
|
+
reject: [
|
|
2373
|
+
"Odrzu\u0107",
|
|
2374
|
+
"Odrzu\u0107 wszystkie",
|
|
2375
|
+
"Nie zgadzam si\u0119",
|
|
2376
|
+
"Odm\xF3w",
|
|
2377
|
+
"Tylko niezb\u0119dne",
|
|
2378
|
+
"Wy\u0142\u0105cznie niezb\u0119dne",
|
|
2379
|
+
"Kontynuuj bez zgody",
|
|
2380
|
+
"Kontynuuj bez plik\xF3w cookie",
|
|
2381
|
+
"Nie, dzi\u0119kuj\u0119",
|
|
2382
|
+
"Zabro\u0144"
|
|
2383
|
+
],
|
|
2384
|
+
close: [
|
|
2385
|
+
"Zamknij",
|
|
2386
|
+
"Anuluj",
|
|
2387
|
+
"Ukryj",
|
|
2388
|
+
"Nie teraz",
|
|
2389
|
+
"Nie, dzi\u0119kuj\u0119",
|
|
2390
|
+
"P\xF3\u017Aniej",
|
|
2391
|
+
"\xD7",
|
|
2392
|
+
"Zamknij okno"
|
|
2393
|
+
]
|
|
2394
|
+
};
|
|
2395
|
+
var pl_default = translations35;
|
|
2396
|
+
|
|
2397
|
+
// src/translations/pt.ts
|
|
2398
|
+
var translations36 = {
|
|
2399
|
+
accept: [
|
|
2400
|
+
"Aceitar",
|
|
2401
|
+
"Aceitar tudo",
|
|
2402
|
+
"Concordo",
|
|
2403
|
+
"Permitir",
|
|
2404
|
+
"Permitir tudo",
|
|
2405
|
+
"OK",
|
|
2406
|
+
"Percebi",
|
|
2407
|
+
"Entendi",
|
|
2408
|
+
"Continuar",
|
|
2409
|
+
"Guardar e aceitar",
|
|
2410
|
+
"Aceitar e continuar",
|
|
2411
|
+
"Concordar e prosseguir"
|
|
2412
|
+
],
|
|
2413
|
+
reject: [
|
|
2414
|
+
"Rejeitar",
|
|
2415
|
+
"Rejeitar tudo",
|
|
2416
|
+
"Recusar",
|
|
2417
|
+
"N\xE3o permitir",
|
|
2418
|
+
"Apenas o necess\xE1rio",
|
|
2419
|
+
"S\xF3 o essencial",
|
|
2420
|
+
"Apenas cookies essenciais",
|
|
2421
|
+
"Continuar sem cookies",
|
|
2422
|
+
"Continuar sem aceitar",
|
|
2423
|
+
"N\xE3o, obrigado"
|
|
2424
|
+
],
|
|
2425
|
+
close: [
|
|
2426
|
+
"Fechar",
|
|
2427
|
+
"Cancelar",
|
|
2428
|
+
"Dispensar",
|
|
2429
|
+
"Agora n\xE3o",
|
|
2430
|
+
"N\xE3o, obrigado",
|
|
2431
|
+
"Mais tarde",
|
|
2432
|
+
"Voltar",
|
|
2433
|
+
"Fechar janela",
|
|
2434
|
+
"\xD7"
|
|
2435
|
+
]
|
|
2436
|
+
};
|
|
2437
|
+
var pt_default = translations36;
|
|
2438
|
+
|
|
2439
|
+
// src/translations/ro.ts
|
|
2440
|
+
var translations37 = {
|
|
2441
|
+
accept: [
|
|
2442
|
+
"Accept",
|
|
2443
|
+
"Accept toate",
|
|
2444
|
+
"Sunt de acord",
|
|
2445
|
+
"Permite",
|
|
2446
|
+
"Permite tot",
|
|
2447
|
+
"OK",
|
|
2448
|
+
"\xCEn regul\u0103",
|
|
2449
|
+
"Am \xEEn\u021Beles",
|
|
2450
|
+
"Continu\u0103",
|
|
2451
|
+
"Salveaz\u0103 \u0219i accept\u0103",
|
|
2452
|
+
"De acord",
|
|
2453
|
+
"Accept cookie\u2011urile"
|
|
2454
|
+
],
|
|
2455
|
+
reject: [
|
|
2456
|
+
"Refuz",
|
|
2457
|
+
"Refuz toate",
|
|
2458
|
+
"Respinge",
|
|
2459
|
+
"Nu permit",
|
|
2460
|
+
"Doar necesare",
|
|
2461
|
+
"Numai esen\u021Biale",
|
|
2462
|
+
"Continu\u0103 f\u0103r\u0103 cookie\u2011uri",
|
|
2463
|
+
"Nu, mul\u021Bumesc",
|
|
2464
|
+
"Respinge op\u021Bionale",
|
|
2465
|
+
"Dezactiveaz\u0103 tot"
|
|
2466
|
+
],
|
|
2467
|
+
close: [
|
|
2468
|
+
"\xCEnchide",
|
|
2469
|
+
"Anuleaz\u0103",
|
|
2470
|
+
"Renun\u021B\u0103",
|
|
2471
|
+
"Nu acum",
|
|
2472
|
+
"Nu, mul\u021Bumesc",
|
|
2473
|
+
"Mai t\xE2rziu",
|
|
2474
|
+
"\xD7",
|
|
2475
|
+
"\xCEnchide fereastra"
|
|
2476
|
+
]
|
|
2477
|
+
};
|
|
2478
|
+
var ro_default = translations37;
|
|
2479
|
+
|
|
2480
|
+
// src/translations/ru.ts
|
|
2481
|
+
var translations38 = {
|
|
2482
|
+
accept: ["\u041F\u0440\u0438\u043D\u044F\u0442\u044C", "\u041F\u0440\u0438\u043D\u044F\u0442\u044C \u0432\u0441\u0435", "\u0421\u043E\u0433\u043B\u0430\u0441\u0438\u0442\u044C\u0441\u044F", "\u0420\u0430\u0437\u0440\u0435\u0448\u0438\u0442\u044C", "\u0420\u0430\u0437\u0440\u0435\u0448\u0438\u0442\u044C \u0432\u0441\u0435", "\u041E\u041A", "\u0425\u043E\u0440\u043E\u0448\u043E", "\u041F\u043E\u043D\u044F\u0442\u043D\u043E", "\u041F\u0440\u043E\u0434\u043E\u043B\u0436\u0438\u0442\u044C", "\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C \u0438 \u043F\u0440\u0438\u043D\u044F\u0442\u044C", "\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C \u0432\u044B\u0431\u043E\u0440"],
|
|
2483
|
+
reject: ["\u041E\u0442\u043A\u043B\u043E\u043D\u0438\u0442\u044C", "\u041E\u0442\u043A\u043B\u043E\u043D\u0438\u0442\u044C \u0432\u0441\u0435", "\u041E\u0442\u043A\u0430\u0437\u0430\u0442\u044C\u0441\u044F", "\u0417\u0430\u043F\u0440\u0435\u0442\u0438\u0442\u044C", "\u0422\u043E\u043B\u044C\u043A\u043E \u043D\u0435\u043E\u0431\u0445\u043E\u0434\u0438\u043C\u044B\u0435", "\u0422\u043E\u043B\u044C\u043A\u043E \u043E\u0431\u044F\u0437\u0430\u0442\u0435\u043B\u044C\u043D\u044B\u0435", "\u0422\u043E\u043B\u044C\u043A\u043E \u0441\u0442\u0440\u043E\u0433\u043E \u043D\u0435\u043E\u0431\u0445\u043E\u0434\u0438\u043C\u044B\u0435", "\u041F\u0440\u043E\u0434\u043E\u043B\u0436\u0438\u0442\u044C \u0431\u0435\u0437 \u0444\u0430\u0439\u043B\u043E\u0432 cookie", "\u041D\u0435 \u043F\u0440\u0438\u043D\u0438\u043C\u0430\u0442\u044C", "\u041D\u0435\u0442, \u0441\u043F\u0430\u0441\u0438\u0431\u043E"],
|
|
2484
|
+
close: ["\u0417\u0430\u043A\u0440\u044B\u0442\u044C", "\u041E\u0442\u043C\u0435\u043D\u0430", "\u0421\u043A\u0440\u044B\u0442\u044C", "\u041D\u0435 \u0441\u0435\u0439\u0447\u0430\u0441", "\u041D\u0435\u0442, \u0441\u043F\u0430\u0441\u0438\u0431\u043E", "\u041F\u043E\u0437\u0436\u0435", "\xD7"]
|
|
2485
|
+
};
|
|
2486
|
+
var ru_default = translations38;
|
|
2487
|
+
|
|
2488
|
+
// src/translations/sk.ts
|
|
2489
|
+
var translations39 = {
|
|
2490
|
+
accept: ["S\xFAhlas\xEDm", "S\xFAhlas\xEDm so v\u0161etk\xFDm", "Prija\u0165", "Prija\u0165 v\u0161etko", "Povoli\u0165", "Povoli\u0165 v\u0161etko", "OK", "Dobre", "Rozumiem", "Pokra\u010Dova\u0165", "Ulo\u017Ei\u0165 a prija\u0165", "S\xFAhlas\xEDm s cookies"],
|
|
2491
|
+
reject: ["Odmietnu\u0165", "Odmietnu\u0165 v\u0161etko", "Nes\xFAhlas\xEDm", "Nepovoli\u0165", "Len nevyhnutn\xE9", "Iba nevyhnutn\xE9", "Len z\xE1kladn\xE9", "Pokra\u010Dova\u0165 bez cookies", "Nie, \u010Fakujem", "Bez \u010Fal\u0161\xEDch cookies"],
|
|
2492
|
+
close: ["Zavrie\u0165", "Zru\u0161i\u0165", "Skry\u0165", "Teraz nie", "Nesk\xF4r", "Nie, \u010Fakujem", "Sp\xE4\u0165", "\xD7"]
|
|
2493
|
+
};
|
|
2494
|
+
var sk_default = translations39;
|
|
2495
|
+
|
|
2496
|
+
// src/translations/sl.ts
|
|
2497
|
+
var translations40 = {
|
|
2498
|
+
accept: ["Sprejmi", "Sprejmi vse", "Strinjam se", "Dovoli", "Dovoli vse", "V redu", "OK", "Razumem", "Nadaljuj", "Shrani in sprejmi", "Potrdi", "Shrani nastavitve"],
|
|
2499
|
+
reject: ["Zavrni", "Zavrni vse", "Ne sprejemam", "Ne dovoli", "Samo nujno", "Le nujni pi\u0161kotki", "Nadaljuj brez pi\u0161kotkov", "Ne, hvala", "Onemogo\u010Di vse", "Zavrni neobvezne"],
|
|
2500
|
+
close: ["Zapri", "Prekli\u010Di", "Ne zdaj", "Kasneje", "\xD7", "Skrij", "Zapri obvestilo", "Nazaj", "Zapri okno"]
|
|
2501
|
+
};
|
|
2502
|
+
var sl_default = translations40;
|
|
2503
|
+
|
|
2504
|
+
// src/translations/sv.ts
|
|
2505
|
+
var translations41 = {
|
|
2506
|
+
accept: [
|
|
2507
|
+
"Godk\xE4nn",
|
|
2508
|
+
"Godk\xE4nn alla",
|
|
2509
|
+
"Acceptera",
|
|
2510
|
+
"Acceptera alla",
|
|
2511
|
+
"Jag samtycker",
|
|
2512
|
+
"Till\xE5t",
|
|
2513
|
+
"Till\xE5t alla",
|
|
2514
|
+
"OK",
|
|
2515
|
+
"Okej",
|
|
2516
|
+
"Jag f\xF6rst\xE5r",
|
|
2517
|
+
"Forts\xE4tt",
|
|
2518
|
+
"Spara och godk\xE4nn",
|
|
2519
|
+
"Bekr\xE4fta",
|
|
2520
|
+
"G\xE5 vidare",
|
|
2521
|
+
"Klart"
|
|
2522
|
+
],
|
|
2523
|
+
reject: [
|
|
2524
|
+
"Avvisa",
|
|
2525
|
+
"Avvisa alla",
|
|
2526
|
+
"Avb\xF6j",
|
|
2527
|
+
"Neka",
|
|
2528
|
+
"Neka alla",
|
|
2529
|
+
"Endast n\xF6dv\xE4ndiga",
|
|
2530
|
+
"Enbart n\xF6dv\xE4ndiga",
|
|
2531
|
+
"Forts\xE4tt utan kakor",
|
|
2532
|
+
"Nej tack",
|
|
2533
|
+
"Avst\xE5"
|
|
2534
|
+
],
|
|
2535
|
+
close: [
|
|
2536
|
+
"St\xE4ng",
|
|
2537
|
+
"Avbryt",
|
|
2538
|
+
"St\xE4ng f\xF6nster",
|
|
2539
|
+
"Inte nu",
|
|
2540
|
+
"Nej tack",
|
|
2541
|
+
"Senare",
|
|
2542
|
+
"Hoppa \xF6ver",
|
|
2543
|
+
"Tillbaka",
|
|
2544
|
+
"\xD7"
|
|
2545
|
+
]
|
|
2546
|
+
};
|
|
2547
|
+
var sv_default = translations41;
|
|
2548
|
+
|
|
2549
|
+
// src/translations/sw.ts
|
|
2550
|
+
var translations42 = {
|
|
2551
|
+
accept: ["Kubali", "Kubali yote", "Ruhusu", "Ruhusu yote", "Sawa", "Sawa sawa", "Nimeelewa", "Endelea", "Hifadhi na kubali", "Nakubali"],
|
|
2552
|
+
reject: ["Kataa", "Kataa yote", "Usiruhusu", "Usikubali", "Muhimu tu", "Ya lazima pekee", "Endelea bila vidakuzi", "Hapana, asante"],
|
|
2553
|
+
close: ["Funga", "Ghairi", "Ondoa", "Puuza", "Tupilia mbali", "Si sasa", "Baadaye", "\xD7"]
|
|
2554
|
+
};
|
|
2555
|
+
var sw_default = translations42;
|
|
2556
|
+
|
|
2557
|
+
// src/translations/ta.ts
|
|
2558
|
+
var translations43 = {
|
|
2559
|
+
accept: ["\u0B8F\u0BB1\u0BCD\u0B95\u0BB5\u0BC1\u0BAE\u0BCD", "\u0B85\u0BA9\u0BC8\u0BA4\u0BCD\u0BA4\u0BC8\u0BAF\u0BC1\u0BAE\u0BCD \u0B8F\u0BB1\u0BCD\u0B95\u0BB5\u0BC1\u0BAE\u0BCD", "\u0B89\u0B9F\u0BA9\u0BCD\u0BAA\u0B9F\u0BC1\u0B95\u0BBF\u0BB1\u0BC7\u0BA9\u0BCD", "\u0B85\u0BA9\u0BC1\u0BAE\u0BA4\u0BBF\u0B95\u0BCD\u0B95\u0BB5\u0BC1\u0BAE\u0BCD", "\u0B85\u0BA9\u0BC8\u0BA4\u0BCD\u0BA4\u0BC8\u0BAF\u0BC1\u0BAE\u0BCD \u0B85\u0BA9\u0BC1\u0BAE\u0BA4\u0BBF\u0B95\u0BCD\u0B95\u0BB5\u0BC1\u0BAE\u0BCD", "\u0B9A\u0BB0\u0BBF", "\u0B93\u0B95\u0BC7", "\u0BAA\u0BC1\u0BB0\u0BBF\u0BA8\u0BCD\u0BA4\u0BA4\u0BC1", "\u0BA4\u0BCA\u0B9F\u0BB0\u0BB5\u0BC1\u0BAE\u0BCD", "\u0B9A\u0BC7\u0BAE\u0BBF\u0BA4\u0BCD\u0BA4\u0BC1 \u0B8F\u0BB1\u0BCD\u0B95\u0BB5\u0BC1\u0BAE\u0BCD"],
|
|
2560
|
+
reject: ["\u0BA8\u0BBF\u0BB0\u0BBE\u0B95\u0BB0\u0BBF\u0B95\u0BCD\u0B95\u0BB5\u0BC1\u0BAE\u0BCD", "\u0B85\u0BA9\u0BC8\u0BA4\u0BCD\u0BA4\u0BC8\u0BAF\u0BC1\u0BAE\u0BCD \u0BA8\u0BBF\u0BB0\u0BBE\u0B95\u0BB0\u0BBF\u0B95\u0BCD\u0B95\u0BB5\u0BC1\u0BAE\u0BCD", "\u0BAE\u0BB1\u0BC1\u0B95\u0BCD\u0B95\u0BB5\u0BC1\u0BAE\u0BCD", "\u0B85\u0BA9\u0BC1\u0BAE\u0BA4\u0BBF\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BBE\u0BAE\u0BCD", "\u0BA4\u0BC7\u0BB5\u0BC8\u0BAF\u0BBE\u0BA9\u0BB5\u0BC8 \u0BAE\u0B9F\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD", "\u0BAE\u0BC1\u0B95\u0BCD\u0B95\u0BBF\u0BAF\u0BAE\u0BBE\u0BA9\u0BB5\u0BC8 \u0BAE\u0B9F\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD", "\u0B95\u0BC1\u0B95\u0BCD\u0B95\u0BC0\u0B95\u0BB3\u0BCD \u0B87\u0BB2\u0BCD\u0BB2\u0BBE\u0BAE\u0BB2\u0BCD \u0BA4\u0BCA\u0B9F\u0BB0\u0BB5\u0BC1\u0BAE\u0BCD", "\u0B87\u0BB2\u0BCD\u0BB2\u0BC8, \u0BA8\u0BA9\u0BCD\u0BB1\u0BBF"],
|
|
2561
|
+
close: ["\u0BAE\u0BC2\u0B9F\u0BB5\u0BC1\u0BAE\u0BCD", "\u0BB0\u0BA4\u0BCD\u0BA4\u0BC1 \u0B9A\u0BC6\u0BAF\u0BCD\u0BAF\u0BB5\u0BC1\u0BAE\u0BCD", "\u0BA4\u0BB5\u0BBF\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BB5\u0BC1\u0BAE\u0BCD", "\u0B87\u0BAA\u0BCD\u0BAA\u0BCB\u0BA4\u0BC1 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BBE\u0BAE\u0BCD", "\u0B87\u0BB2\u0BCD\u0BB2\u0BC8, \u0BA8\u0BA9\u0BCD\u0BB1\u0BBF", "\u0BAA\u0BBF\u0BA9\u0BCD\u0BA9\u0BB0\u0BCD", "\xD7"]
|
|
2562
|
+
};
|
|
2563
|
+
var ta_default = translations43;
|
|
2564
|
+
|
|
2565
|
+
// src/translations/th.ts
|
|
2566
|
+
var translations44 = {
|
|
2567
|
+
accept: [
|
|
2568
|
+
"\u0E22\u0E2D\u0E21\u0E23\u0E31\u0E1A",
|
|
2569
|
+
"\u0E22\u0E2D\u0E21\u0E23\u0E31\u0E1A\u0E17\u0E31\u0E49\u0E07\u0E2B\u0E21\u0E14",
|
|
2570
|
+
"\u0E40\u0E2B\u0E47\u0E19\u0E14\u0E49\u0E27\u0E22",
|
|
2571
|
+
"\u0E2D\u0E19\u0E38\u0E0D\u0E32\u0E15",
|
|
2572
|
+
"\u0E2D\u0E19\u0E38\u0E0D\u0E32\u0E15\u0E17\u0E31\u0E49\u0E07\u0E2B\u0E21\u0E14",
|
|
2573
|
+
"\u0E15\u0E01\u0E25\u0E07",
|
|
2574
|
+
"\u0E42\u0E2D\u0E40\u0E04",
|
|
2575
|
+
"\u0E23\u0E31\u0E1A\u0E17\u0E23\u0E32\u0E1A",
|
|
2576
|
+
"\u0E14\u0E33\u0E40\u0E19\u0E34\u0E19\u0E01\u0E32\u0E23\u0E15\u0E48\u0E2D",
|
|
2577
|
+
"\u0E1A\u0E31\u0E19\u0E17\u0E36\u0E01\u0E41\u0E25\u0E30\u0E22\u0E2D\u0E21\u0E23\u0E31\u0E1A",
|
|
2578
|
+
"\u0E1A\u0E31\u0E19\u0E17\u0E36\u0E01\u0E01\u0E32\u0E23\u0E15\u0E31\u0E49\u0E07\u0E04\u0E48\u0E32\u0E41\u0E25\u0E30\u0E22\u0E2D\u0E21\u0E23\u0E31\u0E1A",
|
|
2579
|
+
"\u0E22\u0E37\u0E19\u0E22\u0E31\u0E19"
|
|
2580
|
+
],
|
|
2581
|
+
reject: [
|
|
2582
|
+
"\u0E1B\u0E0F\u0E34\u0E40\u0E2A\u0E18",
|
|
2583
|
+
"\u0E1B\u0E0F\u0E34\u0E40\u0E2A\u0E18\u0E17\u0E31\u0E49\u0E07\u0E2B\u0E21\u0E14",
|
|
2584
|
+
"\u0E44\u0E21\u0E48\u0E22\u0E2D\u0E21\u0E23\u0E31\u0E1A",
|
|
2585
|
+
"\u0E44\u0E21\u0E48\u0E2D\u0E19\u0E38\u0E0D\u0E32\u0E15",
|
|
2586
|
+
"\u0E40\u0E09\u0E1E\u0E32\u0E30\u0E04\u0E38\u0E01\u0E01\u0E35\u0E49\u0E17\u0E35\u0E48\u0E08\u0E33\u0E40\u0E1B\u0E47\u0E19",
|
|
2587
|
+
"\u0E43\u0E0A\u0E49\u0E40\u0E09\u0E1E\u0E32\u0E30\u0E17\u0E35\u0E48\u0E08\u0E33\u0E40\u0E1B\u0E47\u0E19",
|
|
2588
|
+
"\u0E44\u0E1B\u0E15\u0E48\u0E2D\u0E42\u0E14\u0E22\u0E44\u0E21\u0E48\u0E43\u0E0A\u0E49\u0E04\u0E38\u0E01\u0E01\u0E35\u0E49",
|
|
2589
|
+
"\u0E44\u0E21\u0E48 \u0E02\u0E2D\u0E1A\u0E04\u0E38\u0E13",
|
|
2590
|
+
"\u0E02\u0E49\u0E32\u0E21"
|
|
2591
|
+
],
|
|
2592
|
+
close: [
|
|
2593
|
+
"\u0E1B\u0E34\u0E14",
|
|
2594
|
+
"\u0E22\u0E01\u0E40\u0E25\u0E34\u0E01",
|
|
2595
|
+
"\u0E1B\u0E34\u0E14\u0E2B\u0E19\u0E49\u0E32\u0E15\u0E48\u0E32\u0E07",
|
|
2596
|
+
"\u0E1B\u0E34\u0E14\u0E01\u0E32\u0E23\u0E41\u0E08\u0E49\u0E07\u0E40\u0E15\u0E37\u0E2D\u0E19",
|
|
2597
|
+
"\u0E22\u0E31\u0E07\u0E44\u0E21\u0E48\u0E43\u0E0A\u0E48\u0E15\u0E2D\u0E19\u0E19\u0E35\u0E49",
|
|
2598
|
+
"\u0E44\u0E27\u0E49\u0E17\u0E35\u0E2B\u0E25\u0E31\u0E07",
|
|
2599
|
+
"\u0E17\u0E35\u0E2B\u0E25\u0E31\u0E07",
|
|
2600
|
+
"\xD7"
|
|
2601
|
+
]
|
|
2602
|
+
};
|
|
2603
|
+
var th_default = translations44;
|
|
2604
|
+
|
|
2605
|
+
// src/translations/tl.ts
|
|
2606
|
+
var translations45 = {
|
|
2607
|
+
accept: ["Tanggapin", "Tanggapin lahat", "Sumang-ayon", "Payagan", "Payagan lahat", "OK", "Okay", "Sige", "Naintindihan", "Magpatuloy", "I-save at tanggapin"],
|
|
2608
|
+
reject: ["Tanggihan", "Tanggihan lahat", "Huwag payagan", "Kinakailangan lang", "Mga kinakailangan lang", "Mahahalaga lang", "Magpatuloy nang walang mga cookie", "Hindi, salamat", "Huwag na lang"],
|
|
2609
|
+
close: ["Isara", "Kanselahin", "Isantabi", "Hindi ngayon", "Huwag muna", "Mamaya", "\xD7"]
|
|
2610
|
+
};
|
|
2611
|
+
var tl_default = translations45;
|
|
2612
|
+
|
|
2613
|
+
// src/translations/tr.ts
|
|
2614
|
+
var translations46 = {
|
|
2615
|
+
accept: [
|
|
2616
|
+
"Kabul et",
|
|
2617
|
+
"T\xFCm\xFCn\xFC kabul et",
|
|
2618
|
+
"Onayla",
|
|
2619
|
+
"\u0130zin ver",
|
|
2620
|
+
"T\xFCm\xFCne izin ver",
|
|
2621
|
+
"Anlad\u0131m",
|
|
2622
|
+
"Devam et",
|
|
2623
|
+
"Kaydet ve kabul et",
|
|
2624
|
+
"Ayarlar\u0131 kaydet",
|
|
2625
|
+
"Kabul ediyorum"
|
|
2626
|
+
],
|
|
2627
|
+
reject: [
|
|
2628
|
+
"Reddet",
|
|
2629
|
+
"T\xFCm\xFCn\xFC reddet",
|
|
2630
|
+
"Kabul etmiyorum",
|
|
2631
|
+
"\u0130zin verme",
|
|
2632
|
+
"Yaln\u0131zca gerekli olanlar",
|
|
2633
|
+
"Sadece zorunlu olanlar",
|
|
2634
|
+
"Gerekli olanlarla devam et",
|
|
2635
|
+
"\xC7erez olmadan devam et",
|
|
2636
|
+
"\xC7erezsiz devam et",
|
|
2637
|
+
"Hay\u0131r, te\u015Fekk\xFCrler",
|
|
2638
|
+
"Yaln\u0131zca zorunlu \xE7erezlere izin ver"
|
|
2639
|
+
],
|
|
2640
|
+
close: [
|
|
2641
|
+
"Kapat",
|
|
2642
|
+
"\u0130ptal",
|
|
2643
|
+
"Vazge\xE7",
|
|
2644
|
+
"\u015Eimdilik de\u011Fil",
|
|
2645
|
+
"Daha sonra",
|
|
2646
|
+
"Geri",
|
|
2647
|
+
"Pencereyi kapat",
|
|
2648
|
+
"\xD7",
|
|
2649
|
+
"X",
|
|
2650
|
+
"Tamam"
|
|
2651
|
+
]
|
|
2652
|
+
};
|
|
2653
|
+
var tr_default = translations46;
|
|
2654
|
+
|
|
2655
|
+
// src/translations/uk.ts
|
|
2656
|
+
var translations47 = {
|
|
2657
|
+
accept: ["\u041F\u0440\u0438\u0439\u043D\u044F\u0442\u0438", "\u041F\u0440\u0438\u0439\u043D\u044F\u0442\u0438 \u0432\u0441\u0435", "\u041F\u043E\u0433\u043E\u0434\u0438\u0442\u0438\u0441\u044F", "\u0414\u043E\u0437\u0432\u043E\u043B\u0438\u0442\u0438", "\u0414\u043E\u0437\u0432\u043E\u043B\u0438\u0442\u0438 \u0432\u0441\u0435", "\u041E\u041A", "\u0414\u043E\u0431\u0440\u0435", "\u0417\u0440\u043E\u0437\u0443\u043C\u0456\u043B\u043E", "\u041F\u0440\u043E\u0434\u043E\u0432\u0436\u0438\u0442\u0438", "\u0417\u0431\u0435\u0440\u0435\u0433\u0442\u0438 \u0442\u0430 \u043F\u0440\u0438\u0439\u043D\u044F\u0442\u0438", "\u041F\u0456\u0434\u0442\u0432\u0435\u0440\u0434\u0438\u0442\u0438", "\u0422\u0430\u043A", "\u0413\u0430\u0440\u0430\u0437\u0434", "\u0414\u0430\u043B\u0456"],
|
|
2658
|
+
reject: ["\u0412\u0456\u0434\u0445\u0438\u043B\u0438\u0442\u0438", "\u0412\u0456\u0434\u0445\u0438\u043B\u0438\u0442\u0438 \u0432\u0441\u0435", "\u0412\u0456\u0434\u043C\u043E\u0432\u0438\u0442\u0438\u0441\u044F", "\u041D\u0435 \u043F\u0440\u0438\u0439\u043C\u0430\u0442\u0438", "\u041D\u0435 \u0434\u043E\u0437\u0432\u043E\u043B\u044F\u0442\u0438", "\u041B\u0438\u0448\u0435 \u043D\u0435\u043E\u0431\u0445\u0456\u0434\u043D\u0456", "\u0422\u0456\u043B\u044C\u043A\u0438 \u043D\u0435\u043E\u0431\u0445\u0456\u0434\u043D\u0456", "\u041B\u0438\u0448\u0435 \u043E\u0431\u043E\u0432\u2019\u044F\u0437\u043A\u043E\u0432\u0456", "\u041F\u0440\u043E\u0434\u043E\u0432\u0436\u0438\u0442\u0438 \u0431\u0435\u0437 \u0444\u0430\u0439\u043B\u0456\u0432 cookie", "\u0411\u0435\u0437 \u0444\u0430\u0439\u043B\u0456\u0432 cookie", "\u041D\u0456, \u0434\u044F\u043A\u0443\u044E"],
|
|
2659
|
+
close: ["\u0417\u0430\u043A\u0440\u0438\u0442\u0438", "\u0421\u043A\u0430\u0441\u0443\u0432\u0430\u0442\u0438", "\u0417\u0430\u043A\u0440\u0438\u0442\u0438 \u0432\u0456\u043A\u043D\u043E", "\u041D\u0435 \u0437\u0430\u0440\u0430\u0437", "\u041F\u0456\u0437\u043D\u0456\u0448\u0435", "\u041F\u0440\u043E\u043F\u0443\u0441\u0442\u0438\u0442\u0438", "\u0413\u043E\u0442\u043E\u0432\u043E", "\xD7"]
|
|
2660
|
+
};
|
|
2661
|
+
var uk_default = translations47;
|
|
2662
|
+
|
|
2663
|
+
// src/translations/ur.ts
|
|
2664
|
+
var translations48 = {
|
|
2665
|
+
accept: [
|
|
2666
|
+
"\u0642\u0628\u0648\u0644 \u06A9\u0631\u06CC\u06BA",
|
|
2667
|
+
"\u0633\u0628 \u0642\u0628\u0648\u0644 \u06A9\u0631\u06CC\u06BA",
|
|
2668
|
+
"\u0642\u0628\u0648\u0644 \u06C1\u06D2",
|
|
2669
|
+
"\u0645\u06CC\u06BA \u0645\u062A\u0641\u0642 \u06C1\u0648\u06BA",
|
|
2670
|
+
"\u0627\u062C\u0627\u0632\u062A \u062F\u06CC\u06BA",
|
|
2671
|
+
"\u062A\u0645\u0627\u0645 \u06A9\u06CC \u0627\u062C\u0627\u0632\u062A \u062F\u06CC\u06BA",
|
|
2672
|
+
"\u0679\u06BE\u06CC\u06A9 \u06C1\u06D2",
|
|
2673
|
+
"\u0627\u0648\u06A9\u06D2",
|
|
2674
|
+
"\u062C\u0627\u0631\u06CC \u0631\u06A9\u06BE\u06CC\u06BA",
|
|
2675
|
+
"\u0622\u06AF\u06D2 \u0628\u0691\u06BE\u06CC\u06BA",
|
|
2676
|
+
"\u0645\u062D\u0641\u0648\u0638 \u06A9\u0631\u06CC\u06BA \u0627\u0648\u0631 \u0642\u0628\u0648\u0644 \u06A9\u0631\u06CC\u06BA",
|
|
2677
|
+
"\u06C1\u0627\u06BA"
|
|
2678
|
+
],
|
|
2679
|
+
reject: [
|
|
2680
|
+
"\u0631\u062F \u06A9\u0631\u06CC\u06BA",
|
|
2681
|
+
"\u0633\u0628 \u0631\u062F \u06A9\u0631\u06CC\u06BA",
|
|
2682
|
+
"\u0627\u0646\u06A9\u0627\u0631 \u06A9\u0631\u06CC\u06BA",
|
|
2683
|
+
"\u0627\u062C\u0627\u0632\u062A \u0646\u06C1 \u062F\u06CC\u06BA",
|
|
2684
|
+
"\u0635\u0631\u0641 \u0636\u0631\u0648\u0631\u06CC",
|
|
2685
|
+
"\u0635\u0631\u0641 \u0644\u0627\u0632\u0645\u06CC",
|
|
2686
|
+
"\u0635\u0631\u0641 \u0628\u0646\u06CC\u0627\u062F\u06CC",
|
|
2687
|
+
"\u06A9\u0648\u06A9\u06CC\u0632 \u06A9\u06D2 \u0628\u063A\u06CC\u0631 \u062C\u0627\u0631\u06CC \u0631\u06A9\u06BE\u06CC\u06BA",
|
|
2688
|
+
"\u0646\u06C1\u06CC\u06BA\u060C \u0634\u06A9\u0631\u06CC\u06C1",
|
|
2689
|
+
"\u0642\u0628\u0648\u0644 \u0646\u06C1\u06CC\u06BA",
|
|
2690
|
+
"\u0645\u0646\u0639 \u06A9\u0631\u06CC\u06BA",
|
|
2691
|
+
"\u0627\u062E\u062A\u06CC\u0627\u0631\u0627\u062A \u0645\u062D\u062F\u0648\u062F \u06A9\u0631\u06CC\u06BA"
|
|
2692
|
+
],
|
|
2693
|
+
close: [
|
|
2694
|
+
"\u0628\u0646\u062F \u06A9\u0631\u06CC\u06BA",
|
|
2695
|
+
"\u0645\u0646\u0633\u0648\u062E \u06A9\u0631\u06CC\u06BA",
|
|
2696
|
+
"\u062E\u0627\u0631\u062C \u06A9\u0631\u06CC\u06BA",
|
|
2697
|
+
"\u0627\u0628\u06BE\u06CC \u0646\u06C1\u06CC\u06BA",
|
|
2698
|
+
"\u0628\u0639\u062F \u0645\u06CC\u06BA",
|
|
2699
|
+
"\u0646\u06C1\u06CC\u06BA\u060C \u0634\u06A9\u0631\u06CC\u06C1",
|
|
2700
|
+
"\xD7",
|
|
2701
|
+
"\u0648\u0627\u067E\u0633",
|
|
2702
|
+
"\u0686\u06BE\u067E\u0627\u0626\u06CC\u06BA"
|
|
2703
|
+
]
|
|
2704
|
+
};
|
|
2705
|
+
var ur_default = translations48;
|
|
2706
|
+
|
|
2707
|
+
// src/translations/vi.ts
|
|
2708
|
+
var translations49 = {
|
|
2709
|
+
accept: ["\u0110\u1ED3ng \xFD", "T\xF4i \u0111\u1ED3ng \xFD", "Ch\u1EA5p nh\u1EADn", "Ch\u1EA5p nh\u1EADn t\u1EA5t c\u1EA3", "Cho ph\xE9p", "Cho ph\xE9p t\u1EA5t c\u1EA3", "OK", "\u0110\xE3 hi\u1EC3u", "Ti\u1EBFp t\u1EE5c", "L\u01B0u v\xE0 ch\u1EA5p nh\u1EADn"],
|
|
2710
|
+
reject: ["T\u1EEB ch\u1ED1i", "T\u1EEB ch\u1ED1i t\u1EA5t c\u1EA3", "Kh\xF4ng \u0111\u1ED3ng \xFD", "Kh\xF4ng cho ph\xE9p", "Ch\u1EC9 b\u1EAFt bu\u1ED9c", "Ch\u1EC9 cho ph\xE9p c\u1EA7n thi\u1EBFt", "Ti\u1EBFp t\u1EE5c m\xE0 kh\xF4ng c\u1EA7n cookie", "Kh\xF4ng, c\u1EA3m \u01A1n"],
|
|
2711
|
+
close: ["\u0110\xF3ng", "H\u1EE7y", "B\u1ECF qua", "Kh\xF4ng ph\u1EA3i b\xE2y gi\u1EDD", "\u0110\u1EC3 sau", "Kh\xF4ng, c\u1EA3m \u01A1n", "\xD7", "T\u1EAFt", "\u1EA8n"]
|
|
2712
|
+
};
|
|
2713
|
+
var vi_default = translations49;
|
|
2714
|
+
|
|
2715
|
+
// src/translations/zh.ts
|
|
2716
|
+
var translations50 = {
|
|
2717
|
+
accept: ["\u540C\u610F", "\u5168\u90E8\u540C\u610F", "\u63A5\u53D7", "\u5168\u90E8\u63A5\u53D7", "\u5141\u8BB8", "\u5168\u90E8\u5141\u8BB8", "\u786E\u5B9A", "\u597D\u7684", "\u6211\u77E5\u9053\u4E86", "\u7EE7\u7EED", "\u4FDD\u5B58\u5E76\u63A5\u53D7", "\u7EE7\u7EED\u5E76\u540C\u610F"],
|
|
2718
|
+
reject: ["\u62D2\u7EDD", "\u5168\u90E8\u62D2\u7EDD", "\u4E0D\u540C\u610F", "\u4E0D\u5141\u8BB8", "\u4EC5\u4FDD\u7559\u5FC5\u8981\u9879", "\u4EC5\u9650\u5FC5\u8981", "\u4EC5\u542F\u7528\u5FC5\u8981\u529F\u80FD", "\u4EC5\u4F7F\u7528\u5FC5\u8981 Cookie", "\u7EE7\u7EED\u4F46\u4E0D\u4F7F\u7528 Cookie", "\u4E0D\u7528\u4E86\uFF0C\u8C22\u8C22", "\u6682\u4E0D\u540C\u610F"],
|
|
2719
|
+
close: ["\u5173\u95ED", "\u53D6\u6D88", "\u5FFD\u7565", "\u6682\u4E0D", "\u7A0D\u540E", "\u4EE5\u540E\u518D\u8BF4", "\u8FD4\u56DE", "\xD7"]
|
|
2720
|
+
};
|
|
2721
|
+
var zh_default = translations50;
|
|
2722
|
+
|
|
2723
|
+
// src/translations/index.ts
|
|
2724
|
+
var languages = {
|
|
2725
|
+
af: af_default,
|
|
2726
|
+
ar: ar_default,
|
|
2727
|
+
az: az_default,
|
|
2728
|
+
bg: bg_default,
|
|
2729
|
+
bn: bn_default,
|
|
2730
|
+
bs: bs_default,
|
|
2731
|
+
ca: ca_default,
|
|
2732
|
+
cs: cs_default,
|
|
2733
|
+
da: da_default,
|
|
2734
|
+
de: de_default,
|
|
2735
|
+
el: el_default,
|
|
2736
|
+
en: en_default,
|
|
2737
|
+
es: es_default,
|
|
2738
|
+
et: et_default,
|
|
2739
|
+
eu: eu_default,
|
|
2740
|
+
fa: fa_default,
|
|
2741
|
+
fi: fi_default,
|
|
2742
|
+
fr: fr_default,
|
|
2743
|
+
ga: ga_default,
|
|
2744
|
+
he: he_default,
|
|
2745
|
+
hi: hi_default,
|
|
2746
|
+
hr: hr_default,
|
|
2747
|
+
hu: hu_default,
|
|
2748
|
+
hy: hy_default,
|
|
2749
|
+
id: id_default,
|
|
2750
|
+
is: is_default,
|
|
2751
|
+
it: it_default,
|
|
2752
|
+
ja: ja_default,
|
|
2753
|
+
ka: ka_default,
|
|
2754
|
+
ko: ko_default,
|
|
2755
|
+
lt: lt_default,
|
|
2756
|
+
lv: lv_default,
|
|
2757
|
+
nl: nl_default,
|
|
2758
|
+
no: no_default,
|
|
2759
|
+
pl: pl_default,
|
|
2760
|
+
pt: pt_default,
|
|
2761
|
+
ro: ro_default,
|
|
2762
|
+
ru: ru_default,
|
|
2763
|
+
sk: sk_default,
|
|
2764
|
+
sl: sl_default,
|
|
2765
|
+
sv: sv_default,
|
|
2766
|
+
sw: sw_default,
|
|
2767
|
+
ta: ta_default,
|
|
2768
|
+
th: th_default,
|
|
2769
|
+
tl: tl_default,
|
|
2770
|
+
tr: tr_default,
|
|
2771
|
+
uk: uk_default,
|
|
2772
|
+
ur: ur_default,
|
|
2773
|
+
vi: vi_default,
|
|
2774
|
+
zh: zh_default
|
|
2775
|
+
};
|
|
2776
|
+
function normalizeLang(input) {
|
|
2777
|
+
const code = input.toLowerCase();
|
|
2778
|
+
if (code in languages) return code;
|
|
2779
|
+
return "en";
|
|
2780
|
+
}
|
|
2781
|
+
function getTranslations(lang) {
|
|
2782
|
+
const code = normalizeLang(lang);
|
|
2783
|
+
return languages[code];
|
|
2784
|
+
}
|
|
2785
|
+
|
|
2786
|
+
// src/suppress-interferences.ts
|
|
2787
|
+
var knownCMPSelectors = [
|
|
2788
|
+
{ name: "OneTrust", accept: ["#onetrust-accept-btn-handler"], reject: ["#onetrust-reject-all-handler"] },
|
|
2789
|
+
{
|
|
2790
|
+
name: "Cookiebot",
|
|
2791
|
+
accept: ["#CybotCookiebotDialogBodyLevelButtonLevelOptinAllowAll"],
|
|
2792
|
+
reject: ["#CybotCookiebotDialogBodyLevelButtonDecline"]
|
|
2793
|
+
},
|
|
2794
|
+
{ name: "Didomi", accept: ["button.didomi-accept-all"], reject: ["button.didomi-reject-all"] },
|
|
2795
|
+
{
|
|
2796
|
+
name: "Quantcast",
|
|
2797
|
+
accept: ['button[qc-cmp2-action="accept_all"]'],
|
|
2798
|
+
reject: ['button[qc-cmp2-action="reject_all"]']
|
|
2799
|
+
},
|
|
2800
|
+
{
|
|
2801
|
+
name: "TrustArc",
|
|
2802
|
+
accept: ["#truste-consent-button"],
|
|
2803
|
+
reject: ["#truste-reject-button", "#truste-consent-required"]
|
|
2804
|
+
},
|
|
2805
|
+
{ name: "Iubenda", accept: ["button.iubenda-cs-accept-btn"], reject: ["button.iubenda-cs-reject-btn"] },
|
|
2806
|
+
{
|
|
2807
|
+
name: "CookieYes",
|
|
2808
|
+
accept: ["#wt-cli-accept-all-btn", "#cookie_action_close_header"],
|
|
2809
|
+
reject: ["#wt-cli-reject-btn"]
|
|
2810
|
+
},
|
|
2811
|
+
{ name: "Osano", accept: [".osano-cm-accept-all"], reject: [".osano-cm-reject-all"] },
|
|
2812
|
+
{ name: "Klaro", accept: [".cm-btn-accept"], reject: [".cm-btn-decline"] }
|
|
2813
|
+
];
|
|
2814
|
+
function escapeRegex(text) {
|
|
2815
|
+
return text.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
2816
|
+
}
|
|
2817
|
+
function normalizePhrase(p) {
|
|
2818
|
+
return escapeRegex(p.trim()).replace(/\s+/g, "\\s+");
|
|
2819
|
+
}
|
|
2820
|
+
function buildRegexFromTranslations(phrases, opts) {
|
|
2821
|
+
const unique = Array.from(new Set(phrases.map(normalizePhrase))).filter((s) => s.length > 0);
|
|
2822
|
+
const body = unique.length ? unique.join("|") : "";
|
|
2823
|
+
const source = opts?.anchorWhole ? `^(?:${body})$` : `(?:${body})`;
|
|
2824
|
+
return new RegExp(source, opts?.flags ?? "i");
|
|
2825
|
+
}
|
|
2826
|
+
async function tryClick(page, selectors, _label) {
|
|
2827
|
+
for (const s of selectors) {
|
|
2828
|
+
const el = page.locator(s).first();
|
|
2829
|
+
if (await el.count().catch(() => 0)) {
|
|
2830
|
+
try {
|
|
2831
|
+
await el.scrollIntoViewIfNeeded({ timeout: 250 });
|
|
2832
|
+
await el.click({ timeout: 500 });
|
|
2833
|
+
return true;
|
|
2834
|
+
} catch {
|
|
2835
|
+
}
|
|
2836
|
+
}
|
|
2837
|
+
}
|
|
2838
|
+
return false;
|
|
2839
|
+
}
|
|
2840
|
+
async function closeNativeJsAlerts(page) {
|
|
2841
|
+
page.on("dialog", (d) => d.accept().catch(() => {
|
|
2842
|
+
}));
|
|
2843
|
+
}
|
|
2844
|
+
async function sweepKnownCMPs(page, preferReject) {
|
|
2845
|
+
for (const cmp of knownCMPSelectors) {
|
|
2846
|
+
if (preferReject && await tryClick(page, cmp.reject, `${cmp.name} reject`)) return true;
|
|
2847
|
+
if (await tryClick(page, cmp.accept, `${cmp.name} accept`)) return true;
|
|
2848
|
+
if (!preferReject && await tryClick(page, cmp.reject, `${cmp.name} reject`)) return true;
|
|
2849
|
+
}
|
|
2850
|
+
return false;
|
|
2851
|
+
}
|
|
2852
|
+
async function clickByRoleAndText(page, preferReject, regex) {
|
|
2853
|
+
const dialogs = page.getByRole("dialog");
|
|
2854
|
+
if (await dialogs.count().catch(() => 0)) {
|
|
2855
|
+
const target = preferReject ? dialogs.getByRole("button", { name: regex.reject }).first() : dialogs.getByRole("button", { name: regex.accept }).first();
|
|
2856
|
+
if (await target.count().catch(() => 0)) {
|
|
2857
|
+
try {
|
|
2858
|
+
await target.click({ timeout: 700 });
|
|
2859
|
+
return true;
|
|
2860
|
+
} catch {
|
|
2861
|
+
}
|
|
2862
|
+
}
|
|
2863
|
+
const any = await dialogs.getByRole("button", { name: regex.accept }).first().count() || await dialogs.getByRole("button", { name: regex.reject }).first().count();
|
|
2864
|
+
if (any) {
|
|
2865
|
+
try {
|
|
2866
|
+
const btn = dialogs.getByRole("button", { name: regex.accept }).first();
|
|
2867
|
+
await (await btn.count() ? btn : dialogs.getByRole("button", { name: regex.reject }).first()).click({
|
|
2868
|
+
timeout: 700
|
|
2869
|
+
});
|
|
2870
|
+
return true;
|
|
2871
|
+
} catch {
|
|
2872
|
+
}
|
|
2873
|
+
}
|
|
2874
|
+
const close = dialogs.getByRole("button", { name: regex.close }).first();
|
|
2875
|
+
if (await close.count().catch(() => 0)) {
|
|
2876
|
+
try {
|
|
2877
|
+
await close.click({ timeout: 700 });
|
|
2878
|
+
return true;
|
|
2879
|
+
} catch {
|
|
2880
|
+
}
|
|
2881
|
+
}
|
|
2882
|
+
}
|
|
2883
|
+
const generic = page.getByRole("button", { name: preferReject ? regex.reject : regex.accept }).first();
|
|
2884
|
+
if (await generic.count().catch(() => 0)) {
|
|
2885
|
+
try {
|
|
2886
|
+
await generic.click({ timeout: 700 });
|
|
2887
|
+
return true;
|
|
2888
|
+
} catch {
|
|
2889
|
+
}
|
|
2890
|
+
}
|
|
2891
|
+
return false;
|
|
2892
|
+
}
|
|
2893
|
+
async function sweepNewsletter(page, regex) {
|
|
2894
|
+
const modalLike = page.locator("*:visible").filter({
|
|
2895
|
+
has: page.locator('input[type="email"],input[placeholder*="email" i]')
|
|
2896
|
+
});
|
|
2897
|
+
if (await modalLike.count().catch(() => 0)) {
|
|
2898
|
+
const close = modalLike.getByRole("button", { name: regex.close }).first();
|
|
2899
|
+
if (await close.count().catch(() => 0)) {
|
|
2900
|
+
try {
|
|
2901
|
+
await close.click({ timeout: 700 });
|
|
2902
|
+
return true;
|
|
2903
|
+
} catch {
|
|
2904
|
+
}
|
|
2905
|
+
}
|
|
2906
|
+
const overlay = page.locator('div[role="presentation"], .modal-backdrop, .overlay, .ReactModal__Overlay');
|
|
2907
|
+
if (await overlay.count().catch(() => 0)) {
|
|
2908
|
+
try {
|
|
2909
|
+
await overlay.first().click({ timeout: 500, position: { x: 5, y: 5 } });
|
|
2910
|
+
return true;
|
|
2911
|
+
} catch {
|
|
2912
|
+
}
|
|
2913
|
+
}
|
|
2914
|
+
}
|
|
2915
|
+
return false;
|
|
2916
|
+
}
|
|
2917
|
+
async function sweepOverlays(page, regex) {
|
|
2918
|
+
const acceptRxSource = regex.accept.source;
|
|
2919
|
+
const acceptRxFlags = regex.accept.flags;
|
|
2920
|
+
return await page.evaluate(
|
|
2921
|
+
([source, flags]) => {
|
|
2922
|
+
const acceptRx = new RegExp(source, flags);
|
|
2923
|
+
const isBig = (el) => {
|
|
2924
|
+
const r = el.getBoundingClientRect?.();
|
|
2925
|
+
return r && r.width > window.innerWidth * 0.6 && r.height > window.innerHeight * 0.4;
|
|
2926
|
+
};
|
|
2927
|
+
const candidates = Array.from(document.querySelectorAll("body *")).filter((el) => {
|
|
2928
|
+
const s = getComputedStyle(el);
|
|
2929
|
+
if (!s) return false;
|
|
2930
|
+
const fixed = s.position === "fixed" || s.position === "sticky";
|
|
2931
|
+
const z = parseInt(s.zIndex || "0", 10);
|
|
2932
|
+
return fixed && z >= 1e3 && isBig(el) && el.offsetParent !== null;
|
|
2933
|
+
}).slice(0, 5);
|
|
2934
|
+
for (const el of candidates) {
|
|
2935
|
+
const btn = el.querySelector(
|
|
2936
|
+
'[aria-label*="close" i], button[aria-label*="close" i], button:has(svg), .close, [data-close], .btn-close'
|
|
2937
|
+
);
|
|
2938
|
+
if (btn) {
|
|
2939
|
+
btn.click();
|
|
2940
|
+
return true;
|
|
2941
|
+
}
|
|
2942
|
+
const clickByText = (rx) => {
|
|
2943
|
+
const walker = document.createTreeWalker(el, NodeFilter.SHOW_ELEMENT);
|
|
2944
|
+
let n;
|
|
2945
|
+
while (n = walker.nextNode()) {
|
|
2946
|
+
const e = n;
|
|
2947
|
+
if (!e) continue;
|
|
2948
|
+
if (!e.offsetParent) continue;
|
|
2949
|
+
const text = e.innerText?.trim();
|
|
2950
|
+
if (text && rx.test(text)) {
|
|
2951
|
+
e.click();
|
|
2952
|
+
return true;
|
|
2953
|
+
}
|
|
2954
|
+
}
|
|
2955
|
+
return false;
|
|
2956
|
+
};
|
|
2957
|
+
if (clickByText(acceptRx)) return true;
|
|
2958
|
+
}
|
|
2959
|
+
return false;
|
|
2960
|
+
},
|
|
2961
|
+
[acceptRxSource, acceptRxFlags]
|
|
2962
|
+
).catch(() => false);
|
|
2963
|
+
}
|
|
2964
|
+
async function suppressInterferences(page, opts = {}) {
|
|
2965
|
+
const timeoutMs = opts.timeoutMs ?? 4e3;
|
|
2966
|
+
const preferReject = opts.preferReject ?? false;
|
|
2967
|
+
const pollIntervalMs = opts.pollIntervalMs ?? 120;
|
|
2968
|
+
const settleAfterActionMs = opts.settleAfterActionMs ?? 500;
|
|
2969
|
+
const quietPeriodMs = opts.quietPeriodMs ?? 800;
|
|
2970
|
+
const minSweepMs = opts.minSweepMs ?? 500;
|
|
2971
|
+
const maxActions = opts.maxActions ?? 6;
|
|
2972
|
+
const { accept, reject, close } = getTranslations(opts.lang ?? "en");
|
|
2973
|
+
const regex = {
|
|
2974
|
+
accept: buildRegexFromTranslations(accept, { anchorWhole: true }),
|
|
2975
|
+
reject: buildRegexFromTranslations(reject, { anchorWhole: true }),
|
|
2976
|
+
close: buildRegexFromTranslations(close, { anchorWhole: false })
|
|
2977
|
+
};
|
|
2978
|
+
await closeNativeJsAlerts(page);
|
|
2979
|
+
let actions = 0;
|
|
2980
|
+
const startedAt = Date.now();
|
|
2981
|
+
let lastActivityAt = startedAt;
|
|
2982
|
+
while (Date.now() < lastActivityAt + timeoutMs) {
|
|
2983
|
+
const did = await sweepKnownCMPs(page, preferReject) || await clickByRoleAndText(page, preferReject, regex) || await sweepNewsletter(page, regex) || await sweepOverlays(page, regex);
|
|
2984
|
+
if (did) {
|
|
2985
|
+
actions += 1;
|
|
2986
|
+
lastActivityAt = Date.now();
|
|
2987
|
+
if (actions >= maxActions) {
|
|
2988
|
+
if (opts.verbose) console.log(`[suppressInterferences] Max actions ${maxActions} reached, stopping.`);
|
|
2989
|
+
break;
|
|
2990
|
+
}
|
|
2991
|
+
await sleep(settleAfterActionMs);
|
|
2992
|
+
continue;
|
|
2993
|
+
}
|
|
2994
|
+
const quietFor = Date.now() - lastActivityAt;
|
|
2995
|
+
const ranFor = Date.now() - startedAt;
|
|
2996
|
+
if (quietFor >= quietPeriodMs && ranFor >= minSweepMs) {
|
|
2997
|
+
if (opts.verbose) console.log(`[suppressInterferences] Quiet for ${quietFor}ms, stopping early.`);
|
|
2998
|
+
break;
|
|
2999
|
+
}
|
|
3000
|
+
await sleep(pollIntervalMs);
|
|
3001
|
+
}
|
|
3002
|
+
}
|
|
3003
|
+
|
|
3004
|
+
export { browse, createDateEngine, createFieldEngine, formatDate, formatDateForInput, formatHtml, getMonthNames, locator, screenshot, scrollToCenter, setFieldValue, snapshot, suppressInterferences, waitAfterInteraction, waitForAnimationsToFinish, waitForDomIdle, waitForIdle, waitForMeta, waitForUrlChange, waitUntilEnabled };
|
|
3005
|
+
//# sourceMappingURL=index.js.map
|
|
3006
|
+
//# sourceMappingURL=index.js.map
|