fix(products): fix breadcrumbs and product filtering (backport from main)
Some checks failed
Build & Deploy / 🔍 Prepare (push) Successful in 20s
Build & Deploy / 🧪 QA (push) Failing after 34s
Build & Deploy / 🏗️ Build (push) Has started running
Build & Deploy / 🚀 Deploy (push) Has been cancelled
Build & Deploy / 🧪 Smoke Test (push) Has been cancelled
Build & Deploy / ⚡ Lighthouse (push) Has been cancelled
Build & Deploy / 🔔 Notify (push) Has been cancelled

This commit is contained in:
2026-02-24 16:04:21 +01:00
parent 915eb61613
commit 5397309103
43805 changed files with 4324295 additions and 3 deletions

View File

@@ -0,0 +1,29 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
var _lowercase = require("./lowercase.js");
Object.keys(_lowercase).forEach(function (key) {
if (key === "default" || key === "__esModule") return;
if (key in exports && exports[key] === _lowercase[key]) return;
Object.defineProperty(exports, key, {
enumerable: true,
get: function () {
return _lowercase[key];
}
});
});
var _uppercase = require("./uppercase.js");
Object.keys(_uppercase).forEach(function (key) {
if (key === "default" || key === "__esModule") return;
if (key in exports && exports[key] === _uppercase[key]) return;
Object.defineProperty(exports, key, {
enumerable: true,
get: function () {
return _uppercase[key];
}
});
});
//# sourceMappingURL=index.js.map

View File

@@ -0,0 +1 @@
{"version":3,"sources":["../../../src/admin/elements/PublishButton.ts"],"sourcesContent":["import type { ServerProps } from '../../config/types.js'\n\nexport type PublishButtonClientProps = {}\n\nexport type PublishButtonServerPropsOnly = {} & ServerProps\n\nexport type PublishButtonServerProps = PublishButtonServerPropsOnly\n"],"names":[],"mappings":"AAMA,WAAmE"}

View File

@@ -0,0 +1 @@
{"version":3,"sources":["../../../src/mysql-core/columns/boolean.ts"],"sourcesContent":["import type { ColumnBuilderBaseConfig, ColumnBuilderRuntimeConfig, MakeColumnConfig } from '~/column-builder.ts';\nimport type { ColumnBaseConfig } from '~/column.ts';\nimport { entityKind } from '~/entity.ts';\nimport type { AnyMySqlTable } from '~/mysql-core/table.ts';\nimport { MySqlColumn, MySqlColumnBuilder } from './common.ts';\n\nexport type MySqlBooleanBuilderInitial<TName extends string> = MySqlBooleanBuilder<{\n\tname: TName;\n\tdataType: 'boolean';\n\tcolumnType: 'MySqlBoolean';\n\tdata: boolean;\n\tdriverParam: number | boolean;\n\tenumValues: undefined;\n}>;\n\nexport class MySqlBooleanBuilder<T extends ColumnBuilderBaseConfig<'boolean', 'MySqlBoolean'>>\n\textends MySqlColumnBuilder<T>\n{\n\tstatic override readonly [entityKind]: string = 'MySqlBooleanBuilder';\n\n\tconstructor(name: T['name']) {\n\t\tsuper(name, 'boolean', 'MySqlBoolean');\n\t}\n\n\t/** @internal */\n\toverride build<TTableName extends string>(\n\t\ttable: AnyMySqlTable<{ name: TTableName }>,\n\t): MySqlBoolean<MakeColumnConfig<T, TTableName>> {\n\t\treturn new MySqlBoolean<MakeColumnConfig<T, TTableName>>(\n\t\t\ttable,\n\t\t\tthis.config as ColumnBuilderRuntimeConfig<any, any>,\n\t\t);\n\t}\n}\n\nexport class MySqlBoolean<T extends ColumnBaseConfig<'boolean', 'MySqlBoolean'>> extends MySqlColumn<T> {\n\tstatic override readonly [entityKind]: string = 'MySqlBoolean';\n\n\tgetSQLType(): string {\n\t\treturn 'boolean';\n\t}\n\n\toverride mapFromDriverValue(value: number | boolean): boolean {\n\t\tif (typeof value === 'boolean') {\n\t\t\treturn value;\n\t\t}\n\t\treturn value === 1;\n\t}\n}\n\nexport function boolean(): MySqlBooleanBuilderInitial<''>;\nexport function boolean<TName extends string>(name: TName): MySqlBooleanBuilderInitial<TName>;\nexport function boolean(name?: string) {\n\treturn new MySqlBooleanBuilder(name ?? '');\n}\n"],"mappings":"AAEA,SAAS,kBAAkB;AAE3B,SAAS,aAAa,0BAA0B;AAWzC,MAAM,4BACJ,mBACT;AAAA,EACC,QAA0B,UAAU,IAAY;AAAA,EAEhD,YAAY,MAAiB;AAC5B,UAAM,MAAM,WAAW,cAAc;AAAA,EACtC;AAAA;AAAA,EAGS,MACR,OACgD;AAChD,WAAO,IAAI;AAAA,MACV;AAAA,MACA,KAAK;AAAA,IACN;AAAA,EACD;AACD;AAEO,MAAM,qBAA4E,YAAe;AAAA,EACvG,QAA0B,UAAU,IAAY;AAAA,EAEhD,aAAqB;AACpB,WAAO;AAAA,EACR;AAAA,EAES,mBAAmB,OAAkC;AAC7D,QAAI,OAAO,UAAU,WAAW;AAC/B,aAAO;AAAA,IACR;AACA,WAAO,UAAU;AAAA,EAClB;AACD;AAIO,SAAS,QAAQ,MAAe;AACtC,SAAO,IAAI,oBAAoB,QAAQ,EAAE;AAC1C;","names":[]}

View File

@@ -0,0 +1,18 @@
export type AnyValueScalar = string | number | boolean;
export type AnyValueArray = Array<AnyValue>;
/**
* AnyValueMap is a map from string to AnyValue (attribute value or a nested map)
*/
export interface AnyValueMap {
[attributeKey: string]: AnyValue;
}
/**
* AnyValue can be one of the following:
* - a scalar value
* - a byte array
* - array of any value
* - map from string to any value
* - empty value
*/
export type AnyValue = AnyValueScalar | Uint8Array | AnyValueArray | AnyValueMap | null | undefined;
//# sourceMappingURL=AnyValue.d.ts.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"MissingFile.d.ts","sourceRoot":"","sources":["../../src/errors/MissingFile.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,0BAA0B,CAAA;AAKzD,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAA;AAExC,qBAAa,WAAY,SAAQ,QAAQ;gBAC3B,CAAC,CAAC,EAAE,SAAS;CAM1B"}

View File

@@ -0,0 +1,12 @@
import type { Collection, CollectionSlug, DataFromCollectionSlug, PayloadRequest } from 'payload';
export type Resolver<TSlug extends CollectionSlug> = (_: unknown, args: {
draft: boolean;
fallbackLocale?: string;
id: number | string;
locale?: string;
trash?: boolean;
}, context: {
req: PayloadRequest;
}) => Promise<DataFromCollectionSlug<TSlug>>;
export declare function getDeleteResolver<TSlug extends CollectionSlug>(collection: Collection): Resolver<TSlug>;
//# sourceMappingURL=delete.d.ts.map

View File

@@ -0,0 +1,301 @@
"use strict";
// synchronous utility for filtering entries and calculating subwalks
Object.defineProperty(exports, "__esModule", { value: true });
exports.Processor = exports.SubWalks = exports.MatchRecord = exports.HasWalkedCache = void 0;
const minimatch_1 = require("minimatch");
/**
* A cache of which patterns have been processed for a given Path
*/
class HasWalkedCache {
store;
constructor(store = new Map()) {
this.store = store;
}
copy() {
return new HasWalkedCache(new Map(this.store));
}
hasWalked(target, pattern) {
return this.store.get(target.fullpath())?.has(pattern.globString());
}
storeWalked(target, pattern) {
const fullpath = target.fullpath();
const cached = this.store.get(fullpath);
if (cached)
cached.add(pattern.globString());
else
this.store.set(fullpath, new Set([pattern.globString()]));
}
}
exports.HasWalkedCache = HasWalkedCache;
/**
* A record of which paths have been matched in a given walk step,
* and whether they only are considered a match if they are a directory,
* and whether their absolute or relative path should be returned.
*/
class MatchRecord {
store = new Map();
add(target, absolute, ifDir) {
const n = (absolute ? 2 : 0) | (ifDir ? 1 : 0);
const current = this.store.get(target);
this.store.set(target, current === undefined ? n : n & current);
}
// match, absolute, ifdir
entries() {
return [...this.store.entries()].map(([path, n]) => [
path,
!!(n & 2),
!!(n & 1),
]);
}
}
exports.MatchRecord = MatchRecord;
/**
* A collection of patterns that must be processed in a subsequent step
* for a given path.
*/
class SubWalks {
store = new Map();
add(target, pattern) {
if (!target.canReaddir()) {
return;
}
const subs = this.store.get(target);
if (subs) {
if (!subs.find(p => p.globString() === pattern.globString())) {
subs.push(pattern);
}
}
else
this.store.set(target, [pattern]);
}
get(target) {
const subs = this.store.get(target);
/* c8 ignore start */
if (!subs) {
throw new Error('attempting to walk unknown path');
}
/* c8 ignore stop */
return subs;
}
entries() {
return this.keys().map(k => [k, this.store.get(k)]);
}
keys() {
return [...this.store.keys()].filter(t => t.canReaddir());
}
}
exports.SubWalks = SubWalks;
/**
* The class that processes patterns for a given path.
*
* Handles child entry filtering, and determining whether a path's
* directory contents must be read.
*/
class Processor {
hasWalkedCache;
matches = new MatchRecord();
subwalks = new SubWalks();
patterns;
follow;
dot;
opts;
constructor(opts, hasWalkedCache) {
this.opts = opts;
this.follow = !!opts.follow;
this.dot = !!opts.dot;
this.hasWalkedCache =
hasWalkedCache ? hasWalkedCache.copy() : new HasWalkedCache();
}
processPatterns(target, patterns) {
this.patterns = patterns;
const processingSet = patterns.map(p => [target, p]);
// map of paths to the magic-starting subwalks they need to walk
// first item in patterns is the filter
for (let [t, pattern] of processingSet) {
this.hasWalkedCache.storeWalked(t, pattern);
const root = pattern.root();
const absolute = pattern.isAbsolute() && this.opts.absolute !== false;
// start absolute patterns at root
if (root) {
t = t.resolve(root === '/' && this.opts.root !== undefined ?
this.opts.root
: root);
const rest = pattern.rest();
if (!rest) {
this.matches.add(t, true, false);
continue;
}
else {
pattern = rest;
}
}
if (t.isENOENT())
continue;
let p;
let rest;
let changed = false;
while (typeof (p = pattern.pattern()) === 'string' &&
(rest = pattern.rest())) {
const c = t.resolve(p);
t = c;
pattern = rest;
changed = true;
}
p = pattern.pattern();
rest = pattern.rest();
if (changed) {
if (this.hasWalkedCache.hasWalked(t, pattern))
continue;
this.hasWalkedCache.storeWalked(t, pattern);
}
// now we have either a final string for a known entry,
// more strings for an unknown entry,
// or a pattern starting with magic, mounted on t.
if (typeof p === 'string') {
// must not be final entry, otherwise we would have
// concatenated it earlier.
const ifDir = p === '..' || p === '' || p === '.';
this.matches.add(t.resolve(p), absolute, ifDir);
continue;
}
else if (p === minimatch_1.GLOBSTAR) {
// if no rest, match and subwalk pattern
// if rest, process rest and subwalk pattern
// if it's a symlink, but we didn't get here by way of a
// globstar match (meaning it's the first time THIS globstar
// has traversed a symlink), then we follow it. Otherwise, stop.
if (!t.isSymbolicLink() ||
this.follow ||
pattern.checkFollowGlobstar()) {
this.subwalks.add(t, pattern);
}
const rp = rest?.pattern();
const rrest = rest?.rest();
if (!rest || ((rp === '' || rp === '.') && !rrest)) {
// only HAS to be a dir if it ends in **/ or **/.
// but ending in ** will match files as well.
this.matches.add(t, absolute, rp === '' || rp === '.');
}
else {
if (rp === '..') {
// this would mean you're matching **/.. at the fs root,
// and no thanks, I'm not gonna test that specific case.
/* c8 ignore start */
const tp = t.parent || t;
/* c8 ignore stop */
if (!rrest)
this.matches.add(tp, absolute, true);
else if (!this.hasWalkedCache.hasWalked(tp, rrest)) {
this.subwalks.add(tp, rrest);
}
}
}
}
else if (p instanceof RegExp) {
this.subwalks.add(t, pattern);
}
}
return this;
}
subwalkTargets() {
return this.subwalks.keys();
}
child() {
return new Processor(this.opts, this.hasWalkedCache);
}
// return a new Processor containing the subwalks for each
// child entry, and a set of matches, and
// a hasWalkedCache that's a copy of this one
// then we're going to call
filterEntries(parent, entries) {
const patterns = this.subwalks.get(parent);
// put matches and entry walks into the results processor
const results = this.child();
for (const e of entries) {
for (const pattern of patterns) {
const absolute = pattern.isAbsolute();
const p = pattern.pattern();
const rest = pattern.rest();
if (p === minimatch_1.GLOBSTAR) {
results.testGlobstar(e, pattern, rest, absolute);
}
else if (p instanceof RegExp) {
results.testRegExp(e, p, rest, absolute);
}
else {
results.testString(e, p, rest, absolute);
}
}
}
return results;
}
testGlobstar(e, pattern, rest, absolute) {
if (this.dot || !e.name.startsWith('.')) {
if (!pattern.hasMore()) {
this.matches.add(e, absolute, false);
}
if (e.canReaddir()) {
// if we're in follow mode or it's not a symlink, just keep
// testing the same pattern. If there's more after the globstar,
// then this symlink consumes the globstar. If not, then we can
// follow at most ONE symlink along the way, so we mark it, which
// also checks to ensure that it wasn't already marked.
if (this.follow || !e.isSymbolicLink()) {
this.subwalks.add(e, pattern);
}
else if (e.isSymbolicLink()) {
if (rest && pattern.checkFollowGlobstar()) {
this.subwalks.add(e, rest);
}
else if (pattern.markFollowGlobstar()) {
this.subwalks.add(e, pattern);
}
}
}
}
// if the NEXT thing matches this entry, then also add
// the rest.
if (rest) {
const rp = rest.pattern();
if (typeof rp === 'string' &&
// dots and empty were handled already
rp !== '..' &&
rp !== '' &&
rp !== '.') {
this.testString(e, rp, rest.rest(), absolute);
}
else if (rp === '..') {
/* c8 ignore start */
const ep = e.parent || e;
/* c8 ignore stop */
this.subwalks.add(ep, rest);
}
else if (rp instanceof RegExp) {
this.testRegExp(e, rp, rest.rest(), absolute);
}
}
}
testRegExp(e, p, rest, absolute) {
if (!p.test(e.name))
return;
if (!rest) {
this.matches.add(e, absolute, false);
}
else {
this.subwalks.add(e, rest);
}
}
testString(e, p, rest, absolute) {
// should never happen?
if (!e.isNamed(p))
return;
if (!rest) {
this.matches.add(e, absolute, false);
}
else {
this.subwalks.add(e, rest);
}
}
}
exports.Processor = Processor;
//# sourceMappingURL=processor.js.map

View File

@@ -0,0 +1 @@
module.exports={C:{"5":0.01,"47":0.006,"48":0.002,"53":0.002,"54":0.004,"57":0.008,"69":0.002,"72":0.004,"73":0.002,"77":0.01599,"78":0.002,"83":0.008,"85":0.004,"104":0.002,"107":0.002,"111":0.004,"114":0.002,"115":0.17391,"117":0.002,"119":0.004,"121":0.008,"122":0.002,"123":0.004,"127":0.01199,"128":0.01,"133":0.002,"136":0.01399,"138":0.002,"139":0.004,"140":0.03198,"141":0.002,"142":0.01799,"143":0.01399,"144":0.03798,"145":0.41379,"146":0.72764,"147":0.002,_:"2 3 4 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 49 50 51 52 55 56 58 59 60 61 62 63 64 65 66 67 68 70 71 74 75 76 79 80 81 82 84 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 105 106 108 109 110 112 113 116 118 120 124 125 126 129 130 131 132 134 135 137 148 149 3.5 3.6"},D:{"34":0.002,"42":0.002,"43":0.004,"47":0.004,"53":0.002,"54":0.004,"58":0.002,"61":0.002,"62":0.002,"63":0.002,"65":0.002,"67":0.004,"69":0.01399,"70":0.008,"71":0.002,"72":0.004,"74":0.002,"75":0.004,"77":0.002,"79":0.01399,"80":0.002,"81":0.002,"83":0.008,"84":0.006,"86":0.006,"87":0.002,"89":0.004,"90":0.02199,"94":0.01,"96":0.006,"98":0.002,"99":0.002,"100":0.002,"101":0.002,"103":0.01799,"104":0.01999,"105":0.006,"106":0.006,"107":0.004,"108":0.002,"109":0.23188,"110":0.006,"111":0.01599,"112":0.002,"113":0.006,"114":0.01,"115":0.004,"116":0.01,"117":0.004,"119":0.04598,"120":0.01199,"122":0.01799,"123":0.002,"124":0.008,"125":0.01799,"126":0.05997,"127":0.01199,"128":0.01599,"130":0.01999,"131":0.06197,"132":0.02399,"133":0.008,"134":0.01799,"135":0.01799,"136":0.01399,"137":0.03198,"138":0.11194,"139":0.08196,"140":0.05197,"141":0.17191,"142":3.11244,"143":2.95452,"144":0.01,"145":0.008,_:"4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 35 36 37 38 39 40 41 44 45 46 48 49 50 51 52 55 56 57 59 60 64 66 68 73 76 78 85 88 91 92 93 95 97 102 118 121 129 146"},F:{"40":0.008,"42":0.006,"46":0.002,"49":0.002,"53":0.01199,"64":0.002,"79":0.01199,"82":0.002,"90":0.004,"93":0.01799,"95":0.01199,"106":0.002,"113":0.002,"119":0.002,"120":0.004,"122":0.004,"123":0.008,"124":0.38981,"125":0.25587,_:"9 11 12 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 41 43 44 45 47 48 50 51 52 54 55 56 57 58 60 62 63 65 66 67 68 69 70 71 72 73 74 75 76 77 78 80 81 83 84 85 86 87 88 89 91 92 94 96 97 98 99 100 101 102 103 104 105 107 108 109 110 111 112 114 115 116 117 118 121 9.5-9.6 10.0-10.1 10.5 10.6 11.1 11.5 11.6 12.1"},B:{"12":0.006,"13":0.002,"14":0.01,"16":0.004,"17":0.01599,"18":0.02999,"84":0.01199,"89":0.01599,"90":0.002,"92":0.06397,"95":0.002,"100":0.004,"106":0.004,"109":0.01999,"110":0.002,"111":0.004,"114":0.002,"115":0.002,"119":0.002,"121":0.002,"122":0.006,"124":0.01999,"125":0.002,"131":0.002,"132":0.008,"134":0.002,"135":0.002,"136":0.002,"137":0.002,"138":0.03198,"139":0.02799,"140":0.01999,"141":0.1999,"142":0.6077,"143":1.57921,_:"15 79 80 81 83 85 86 87 88 91 93 94 96 97 98 99 101 102 103 104 105 107 108 112 113 116 117 118 120 123 126 127 128 129 130 133"},E:{"6":0.002,_:"0 4 5 7 8 9 10 11 12 13 14 15 3.1 3.2 6.1 7.1 9.1 10.1 11.1 12.1 15.1 15.2-15.3 15.4 15.5 16.0 16.1 16.2 16.3 16.4 16.5 17.0 17.1 17.2 17.3 17.5 18.2 18.4 26.3","5.1":0.002,"13.1":0.002,"14.1":0.006,"15.6":0.01999,"16.6":0.004,"17.4":0.002,"17.6":0.01199,"18.0":0.006,"18.1":0.002,"18.3":0.004,"18.5-18.6":0.01399,"26.0":0.01399,"26.1":0.03798,"26.2":0.01399},G:{"8":0,"3.2":0,"4.0-4.1":0,"4.2-4.3":0.00042,"5.0-5.1":0,"6.0-6.1":0.00085,"7.0-7.1":0.00064,"8.1-8.4":0,"9.0-9.2":0,"9.3":0.0017,"10.0-10.2":0.00021,"10.3":0.00297,"11.0-11.2":0.03647,"11.3-11.4":0.00106,"12.0-12.1":0.00085,"12.2-12.5":0.00954,"13.0-13.1":0.00021,"13.2":0.00148,"13.3":0.00042,"13.4-13.7":0.00148,"14.0-14.4":0.00297,"14.5-14.8":0.00318,"15.0-15.1":0.00339,"15.2-15.3":0.00254,"15.4":0.00276,"15.5":0.00297,"15.6-15.8":0.04601,"16.0":0.0053,"16.1":0.01018,"16.2":0.0053,"16.3":0.00954,"16.4":0.00233,"16.5":0.00403,"16.6-16.7":0.05979,"17.0":0.00339,"17.1":0.00551,"17.2":0.00403,"17.3":0.00615,"17.4":0.01039,"17.5":0.02035,"17.6-17.7":0.04707,"18.0":0.0106,"18.1":0.02205,"18.2":0.01166,"18.3":0.03795,"18.4":0.01951,"18.5-18.7":1.40065,"26.0":0.02735,"26.1":0.2275,"26.2":0.04325,"26.3":0.00191},P:{"4":0.0203,"21":0.01015,"22":0.01015,"24":0.01015,"25":0.0609,"26":0.0203,"27":0.0406,"28":0.0812,"29":0.40602,_:"20 23 5.0-5.4 6.2-6.4 7.2-7.4 8.2 10.1 11.1-11.2 12.0 13.0 14.0 15.0 17.0 18.0 19.0","9.2":0.01015,"16.0":0.01015},I:{"0":0.03994,"3":0,"4":0,"2.1":0,"2.2":0,"2.3":0,"4.1":0,"4.2-4.3":0.00001,"4.4":0,"4.4.3-4.4.4":0.00003},A:{"11":0.02199,_:"6 7 8 9 10 5.5"},K:{"0":2.66241,_:"10 11 12 11.1 11.5 12.1"},N:{_:"10 11"},S:{_:"2.5 3.0-3.1"},J:{_:"7 10"},Q:{"14.9":0.008},O:{"0":0.19202},H:{"0":0.65},L:{"0":80.1516},R:{_:"0"},M:{"0":0.04801}};

View File

@@ -0,0 +1 @@
module.exports={A:{A:{"2":"K D E F A B zC"},B:{"1":"0 1 2 3 4 5 6 7 8 Q H R S T U V W X Y Z a b c d e f g h i j k l m n o p q r s t u v w x y z JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB I","2":"C L M G N O P"},C:{"1":"0 1 2 3 4 5 6 7 8 o p q r s t u v w x y z JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB I ZC aC OC 1C 2C 3C","2":"9 0C VC J bB K D E F A B C L M G N O P cB AB BB CB DB EB FB GB HB IB dB eB fB gB hB iB jB kB lB mB nB oB pB qB 4C 5C","194":"rB sB tB uB vB wB xB yB zB 0B 1B 2B 3B 4B 5B WC 6B XC 7B 8B 9B AC BC CC DC EC FC GC HC IC JC KC LC MC NC Q H R YC S T U V W X Y Z a b c d e f g h i j k l m n"},D:{"1":"0 1 2 3 4 5 6 7 8 EC FC GC HC IC JC KC LC MC NC Q H R S T U V W X Y Z a b c d e f g h i j k l m n o p q r s t u v w x y z JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB I ZC aC OC","2":"9 J bB K D E F A B C L M G N O P cB AB BB CB DB EB FB GB HB IB dB eB fB gB hB iB jB kB lB mB nB oB pB qB rB sB tB uB vB wB xB yB zB 0B 1B 2B 3B 4B","322":"5B WC 6B XC 7B 8B 9B AC BC CC DC"},E:{"1":"TC kC lC mC nC oC GD UC pC qC rC sC HD tC uC vC wC ID","2":"J bB K D E F A B C L M G 6C bC 7C 8C 9C AD cC PC QC BD CD DD dC eC RC ED SC fC","516":"gC hC iC jC FD"},F:{"1":"0 1 2 3 4 5 6 7 8 9B AC BC CC DC EC FC GC HC IC JC KC LC MC NC Q H R YC S T U V W X Y Z a b c d e f g h i j k l m n o p q r s t u v w x y z","2":"9 F B C G N O P cB AB BB CB DB EB FB GB HB IB dB eB fB gB hB iB jB kB lB mB nB oB pB qB rB JD KD LD MD PC xC ND QC","322":"sB tB uB vB wB xB yB zB 0B 1B 2B 3B 4B 5B 6B 7B 8B"},G:{"1":"TC kC lC mC nC oC kD UC pC qC rC sC lD tC uC vC wC","2":"E bC OD yC PD QD RD SD TD UD VD WD XD YD ZD aD bD cD dD eD fD gD hD dC eC RC iD SC fC","516":"gC hC iC jC jD"},H:{"2":"mD"},I:{"1":"I","2":"VC J nD oD pD qD yC rD sD"},J:{"2":"D A"},K:{"1":"H","2":"A B C PC xC QC"},L:{"1":"I"},M:{"1":"OC"},N:{"2":"A B"},O:{"1":"RC"},P:{"1":"9 AB BB CB DB EB FB GB HB IB cC yD zD 0D 1D 2D SC TC UC 3D","2":"J tD uD vD wD xD"},Q:{"1":"4D"},R:{"1":"5D"},S:{"194":"6D 7D"}},B:1,C:"OffscreenCanvas",D:true};

View File

@@ -0,0 +1,19 @@
import { RestCommand } from "../../types.cjs";
//#region src/rest/commands/schema/snapshot.d.ts
type SchemaSnapshotOutput = {
version: number;
directus: string;
vendor: string;
collections: Record<string, any>[];
fields: Record<string, any>[];
relations: Record<string, any>[];
};
/**
* Retrieve the current schema. This endpoint is only available to admin users.
* @returns Returns the JSON object containing schema details.
*/
declare const schemaSnapshot: <Schema>() => RestCommand<SchemaSnapshotOutput, Schema>;
//#endregion
export { SchemaSnapshotOutput, schemaSnapshot };
//# sourceMappingURL=snapshot.d.cts.map

View File

@@ -0,0 +1,79 @@
import { SQL } from "../sql/sql.js";
import { entityKind } from "../entity.js";
import type { ExtraConfigColumn, PgColumn } from "./columns/index.js";
import { IndexedColumn } from "./columns/index.js";
import type { PgTable } from "./table.js";
interface IndexConfig {
name?: string;
columns: Partial<IndexedColumn | SQL>[];
/**
* If true, the index will be created as `create unique index` instead of `create index`.
*/
unique: boolean;
/**
* If true, the index will be created as `create index concurrently` instead of `create index`.
*/
concurrently?: boolean;
/**
* If true, the index will be created as `create index ... on only <table>` instead of `create index ... on <table>`.
*/
only: boolean;
/**
* Condition for partial index.
*/
where?: SQL;
/**
* The optional WITH clause specifies storage parameters for the index
*/
with?: Record<string, any>;
/**
* The optional WITH clause method for the index
*/
method?: 'btree' | string;
}
export type IndexColumn = PgColumn;
export type PgIndexMethod = 'btree' | 'hash' | 'gist' | 'spgist' | 'gin' | 'brin' | 'hnsw' | 'ivfflat' | (string & {});
export type PgIndexOpClass = 'abstime_ops' | 'access_method' | 'anyarray_eq' | 'anyarray_ge' | 'anyarray_gt' | 'anyarray_le' | 'anyarray_lt' | 'anyarray_ne' | 'bigint_ops' | 'bit_ops' | 'bool_ops' | 'box_ops' | 'bpchar_ops' | 'char_ops' | 'cidr_ops' | 'cstring_ops' | 'date_ops' | 'float_ops' | 'int2_ops' | 'int4_ops' | 'int8_ops' | 'interval_ops' | 'jsonb_ops' | 'macaddr_ops' | 'name_ops' | 'numeric_ops' | 'oid_ops' | 'oidint4_ops' | 'oidint8_ops' | 'oidname_ops' | 'oidvector_ops' | 'point_ops' | 'polygon_ops' | 'range_ops' | 'record_eq' | 'record_ge' | 'record_gt' | 'record_le' | 'record_lt' | 'record_ne' | 'text_ops' | 'time_ops' | 'timestamp_ops' | 'timestamptz_ops' | 'timetz_ops' | 'uuid_ops' | 'varbit_ops' | 'varchar_ops' | 'xml_ops' | 'vector_l2_ops' | 'vector_ip_ops' | 'vector_cosine_ops' | 'vector_l1_ops' | 'bit_hamming_ops' | 'bit_jaccard_ops' | 'halfvec_l2_ops' | 'sparsevec_l2_op' | (string & {});
export declare class IndexBuilderOn {
private unique;
private name?;
static readonly [entityKind]: string;
constructor(unique: boolean, name?: string | undefined);
on(...columns: [Partial<ExtraConfigColumn> | SQL, ...Partial<ExtraConfigColumn | SQL>[]]): IndexBuilder;
onOnly(...columns: [Partial<ExtraConfigColumn | SQL>, ...Partial<ExtraConfigColumn | SQL>[]]): IndexBuilder;
/**
* Specify what index method to use. Choices are `btree`, `hash`, `gist`, `spgist`, `gin`, `brin`, or user-installed access methods like `bloom`. The default method is `btree.
*
* If you have the `pg_vector` extension installed in your database, you can use the `hnsw` and `ivfflat` options, which are predefined types.
*
* **You can always specify any string you want in the method, in case Drizzle doesn't have it natively in its types**
*
* @param method The name of the index method to be used
* @param columns
* @returns
*/
using(method: PgIndexMethod, ...columns: [Partial<ExtraConfigColumn | SQL>, ...Partial<ExtraConfigColumn | SQL>[]]): IndexBuilder;
}
export interface AnyIndexBuilder {
build(table: PgTable): Index;
}
export interface IndexBuilder extends AnyIndexBuilder {
}
export declare class IndexBuilder implements AnyIndexBuilder {
static readonly [entityKind]: string;
constructor(columns: Partial<IndexedColumn | SQL>[], unique: boolean, only: boolean, name?: string, method?: string);
concurrently(): this;
with(obj: Record<string, any>): this;
where(condition: SQL): this;
}
export declare class Index {
static readonly [entityKind]: string;
readonly config: IndexConfig & {
table: PgTable;
};
constructor(config: IndexConfig, table: PgTable);
}
export type GetColumnsTableName<TColumns> = TColumns extends PgColumn ? TColumns['_']['name'] : TColumns extends PgColumn[] ? TColumns[number]['_']['name'] : never;
export declare function index(name?: string): IndexBuilderOn;
export declare function uniqueIndex(name?: string): IndexBuilderOn;
export {};

View File

@@ -0,0 +1,175 @@
/*
MIT License http://www.opensource.org/licenses/mit-license.php
Author Tobias Koppers @sokra
*/
"use strict";
const { RawSource } = require("webpack-sources");
const Module = require("../Module");
const {
JAVASCRIPT_TYPE,
JAVASCRIPT_TYPES
} = require("../ModuleSourceTypeConstants");
const { ASSET_MODULE_TYPE_RAW_DATA_URL } = require("../ModuleTypeConstants");
const RuntimeGlobals = require("../RuntimeGlobals");
const makeSerializable = require("../util/makeSerializable");
/** @typedef {import("../config/defaults").WebpackOptionsNormalizedWithDefaults} WebpackOptions */
/** @typedef {import("../Compilation")} Compilation */
/** @typedef {import("../Dependency").UpdateHashContext} UpdateHashContext */
/** @typedef {import("../Module").BuildCallback} BuildCallback */
/** @typedef {import("../Module").RuntimeRequirements} RuntimeRequirements */
/** @typedef {import("../Module").CodeGenerationContext} CodeGenerationContext */
/** @typedef {import("../Module").CodeGenerationResult} CodeGenerationResult */
/** @typedef {import("../Module").CodeGenerationResultData} CodeGenerationResultData */
/** @typedef {import("../Module").NeedBuildCallback} NeedBuildCallback */
/** @typedef {import("../Module").NeedBuildContext} NeedBuildContext */
/** @typedef {import("../Module").Sources} Sources */
/** @typedef {import("../Module").SourceTypes} SourceTypes */
/** @typedef {import("../RequestShortener")} RequestShortener */
/** @typedef {import("../ResolverFactory").ResolverWithOptions} ResolverWithOptions */
/** @typedef {import("../serialization/ObjectMiddleware").ObjectDeserializerContext} ObjectDeserializerContext */
/** @typedef {import("../serialization/ObjectMiddleware").ObjectSerializerContext} ObjectSerializerContext */
/** @typedef {import("../util/Hash")} Hash */
/** @typedef {import("../util/fs").InputFileSystem} InputFileSystem */
class RawDataUrlModule extends Module {
/**
* @param {string} url raw url
* @param {string} identifier unique identifier
* @param {string=} readableIdentifier readable identifier
*/
constructor(url, identifier, readableIdentifier) {
super(ASSET_MODULE_TYPE_RAW_DATA_URL, null);
this.url = url;
this.urlBuffer = url ? Buffer.from(url) : undefined;
this.identifierStr = identifier || this.url;
this.readableIdentifierStr = readableIdentifier || this.identifierStr;
}
/**
* @returns {SourceTypes} types available (do not mutate)
*/
getSourceTypes() {
return JAVASCRIPT_TYPES;
}
/**
* @returns {string} a unique identifier of the module
*/
identifier() {
return this.identifierStr;
}
/**
* @param {string=} type the source type for which the size should be estimated
* @returns {number} the estimated size of the module (must be non-zero)
*/
size(type) {
if (this.url === undefined) {
this.url = /** @type {Buffer} */ (this.urlBuffer).toString();
}
return Math.max(1, this.url.length);
}
/**
* @param {RequestShortener} requestShortener the request shortener
* @returns {string} a user readable identifier of the module
*/
readableIdentifier(requestShortener) {
return /** @type {string} */ (
requestShortener.shorten(this.readableIdentifierStr)
);
}
/**
* @param {NeedBuildContext} context context info
* @param {NeedBuildCallback} callback callback function, returns true, if the module needs a rebuild
* @returns {void}
*/
needBuild(context, callback) {
return callback(null, !this.buildMeta);
}
/**
* @param {WebpackOptions} options webpack options
* @param {Compilation} compilation the compilation
* @param {ResolverWithOptions} resolver the resolver
* @param {InputFileSystem} fs the file system
* @param {BuildCallback} callback callback function
* @returns {void}
*/
build(options, compilation, resolver, fs, callback) {
this.buildMeta = {};
this.buildInfo = {
cacheable: true
};
callback();
}
/**
* @param {CodeGenerationContext} context context for code generation
* @returns {CodeGenerationResult} result
*/
codeGeneration(context) {
if (this.url === undefined) {
this.url = /** @type {Buffer} */ (this.urlBuffer).toString();
}
/** @type {Sources} */
const sources = new Map();
sources.set(
JAVASCRIPT_TYPE,
new RawSource(`module.exports = ${JSON.stringify(this.url)};`)
);
/** @type {CodeGenerationResultData} */
const data = new Map();
data.set("url", {
javascript: this.url
});
/** @type {RuntimeRequirements} */
const runtimeRequirements = new Set();
runtimeRequirements.add(RuntimeGlobals.module);
return { sources, runtimeRequirements, data };
}
/**
* @param {Hash} hash the hash used to track dependencies
* @param {UpdateHashContext} context context
* @returns {void}
*/
updateHash(hash, context) {
hash.update(/** @type {Buffer} */ (this.urlBuffer));
super.updateHash(hash, context);
}
/**
* @param {ObjectSerializerContext} context context
*/
serialize(context) {
const { write } = context;
write(this.urlBuffer);
write(this.identifierStr);
write(this.readableIdentifierStr);
super.serialize(context);
}
/**
* @param {ObjectDeserializerContext} context context
*/
deserialize(context) {
const { read } = context;
this.urlBuffer = read();
this.identifierStr = read();
this.readableIdentifierStr = read();
super.deserialize(context);
}
}
makeSerializable(RawDataUrlModule, "webpack/lib/asset/RawDataUrlModule");
module.exports = RawDataUrlModule;

View File

@@ -0,0 +1,92 @@
![React Email Markdown cover](https://react.email/static/covers/markdown.png)
<div align="center"><strong>@react-email/markdown</strong></div>
<div align="center">Convert Markdown to valid React Email template code.</div>
<br />
<div align="center">
<a href="https://react.email">Website</a>
<span> · </span>
<a href="https://react.email">Documentation</a>
<span> · </span>
<a href="https://react.email">Twitter</a>
</div>
## Install
Install component from your command line.
#### With yarn
```sh
yarn add @react-email/markdown -E
```
#### With npm
```sh
npm install @react-email/markdown -E
```
## Getting started
Add the component around your email body content.
```jsx
import { Markdown } from "@react-email/markdown";
import { Html } from "@react-email/html";
const Email = () => {
return (
<Html lang="en" dir="ltr">
<Markdown
markdownCustomStyles={{
h1: { color: "red" },
h2: { color: "blue" },
codeInline: { background: "grey" },
}}
markdownContainerStyles={{
padding: "12px",
border: "solid 1px black",
}}
>{`# Hello, World!`}</Markdown>
{/* OR */}
<Markdown children={`# This is a ~~strikethrough~~`} />
</Html>
);
```
## Props
### `children` field
- **Type**: string
Contains the markdown content that will be rendered in the email template.
### `markdownCustomStyles` field
- **Type**: object
- **Default**: `{}`
Provide custom styles for the corresponding HTML element (e.g., p, h1, h2, etc.).
### `markdownContainerStyles` field
- **Type**: object
- **Default**: `{}`
Provide custom styles for the containing `div` that wraps the markdown content.
## Support
This component was tested using the most popular email clients.
| <img src="https://react.email/static/icons/gmail.svg" width="48px" height="48px" alt="Gmail logo"> | <img src="https://react.email/static/icons/apple-mail.svg" width="48px" height="48px" alt="Apple Mail"> | <img src="https://react.email/static/icons/outlook.svg" width="48px" height="48px" alt="Outlook logo"> | <img src="https://react.email/static/icons/yahoo-mail.svg" width="48px" height="48px" alt="Yahoo! Mail logo"> | <img src="https://react.email/static/icons/hey.svg" width="48px" height="48px" alt="HEY logo"> | <img src="https://react.email/static/icons/superhuman.svg" width="48px" height="48px" alt="Superhuman logo"> |
| -------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ |
| Gmail ✔ | Apple Mail ✔ | Outlook ✔ | Yahoo! Mail ✔ | HEY ✔ | Superhuman ✔ |
## License
MIT License

View File

@@ -0,0 +1,183 @@
"use strict";
exports.localize = void 0;
var _index = require("../../_lib/buildLocalizeFn.cjs");
const eraValues = {
narrow: ["πΧ", "μΧ"],
abbreviated: ["π.Χ.", "μ.Χ."],
wide: ["προ Χριστού", "μετά Χριστόν"],
};
const quarterValues = {
narrow: ["1", "2", "3", "4"],
abbreviated: ["Τ1", "Τ2", "Τ3", "Τ4"],
wide: ["1ο τρίμηνο", "2ο τρίμηνο", "3ο τρίμηνο", "4ο τρίμηνο"],
};
const monthValues = {
narrow: ["Ι", "Φ", "Μ", "Α", "Μ", "Ι", "Ι", "Α", "Σ", "Ο", "Ν", "Δ"],
abbreviated: [
"Ιαν",
"Φεβ",
"Μάρ",
"Απρ",
"Μάι",
"Ιούν",
"Ιούλ",
"Αύγ",
"Σεπ",
"Οκτ",
"Νοέ",
"Δεκ",
],
wide: [
"Ιανουάριος",
"Φεβρουάριος",
"Μάρτιος",
"Απρίλιος",
"Μάιος",
"Ιούνιος",
"Ιούλιος",
"Αύγουστος",
"Σεπτέμβριος",
"Οκτώβριος",
"Νοέμβριος",
"Δεκέμβριος",
],
};
const formattingMonthValues = {
narrow: ["Ι", "Φ", "Μ", "Α", "Μ", "Ι", "Ι", "Α", "Σ", "Ο", "Ν", "Δ"],
abbreviated: [
"Ιαν",
"Φεβ",
"Μαρ",
"Απρ",
"Μαΐ",
"Ιουν",
"Ιουλ",
"Αυγ",
"Σεπ",
"Οκτ",
"Νοε",
"Δεκ",
],
wide: [
"Ιανουαρίου",
"Φεβρουαρίου",
"Μαρτίου",
"Απριλίου",
"Μαΐου",
"Ιουνίου",
"Ιουλίου",
"Αυγούστου",
"Σεπτεμβρίου",
"Οκτωβρίου",
"Νοεμβρίου",
"Δεκεμβρίου",
],
};
const dayValues = {
narrow: ["Κ", "Δ", "T", "Τ", "Π", "Π", "Σ"],
short: ["Κυ", "Δε", "Τρ", "Τε", "Πέ", "Πα", "Σά"],
abbreviated: ["Κυρ", "Δευ", "Τρί", "Τετ", "Πέμ", "Παρ", "Σάβ"],
wide: [
"Κυριακή",
"Δευτέρα",
"Τρίτη",
"Τετάρτη",
"Πέμπτη",
"Παρασκευή",
"Σάββατο",
],
};
const dayPeriodValues = {
narrow: {
am: "πμ",
pm: "μμ",
midnight: "μεσάνυχτα",
noon: "μεσημέρι",
morning: "πρωί",
afternoon: "απόγευμα",
evening: "βράδυ",
night: "νύχτα",
},
abbreviated: {
am: "π.μ.",
pm: "μ.μ.",
midnight: "μεσάνυχτα",
noon: "μεσημέρι",
morning: "πρωί",
afternoon: "απόγευμα",
evening: "βράδυ",
night: "νύχτα",
},
wide: {
am: "π.μ.",
pm: "μ.μ.",
midnight: "μεσάνυχτα",
noon: "μεσημέρι",
morning: "πρωί",
afternoon: "απόγευμα",
evening: "βράδυ",
night: "νύχτα",
},
};
const ordinalNumber = (dirtyNumber, options) => {
const number = Number(dirtyNumber);
const unit = options?.unit;
let suffix;
if (unit === "year" || unit === "month") {
suffix = "ος";
} else if (
unit === "week" ||
unit === "dayOfYear" ||
unit === "day" ||
unit === "hour" ||
unit === "date"
) {
suffix = "η";
} else {
suffix = "ο";
}
return number + suffix;
};
const localize = (exports.localize = {
ordinalNumber,
era: (0, _index.buildLocalizeFn)({
values: eraValues,
defaultWidth: "wide",
}),
quarter: (0, _index.buildLocalizeFn)({
values: quarterValues,
defaultWidth: "wide",
argumentCallback: (quarter) => quarter - 1,
}),
month: (0, _index.buildLocalizeFn)({
values: monthValues,
defaultWidth: "wide",
formattingValues: formattingMonthValues,
defaultFormattingWidth: "wide",
}),
day: (0, _index.buildLocalizeFn)({
values: dayValues,
defaultWidth: "wide",
}),
dayPeriod: (0, _index.buildLocalizeFn)({
values: dayPeriodValues,
defaultWidth: "wide",
}),
});

View File

@@ -0,0 +1,49 @@
{
"name": "cssfilter",
"version": "0.0.10",
"description": "Sanitize untrusted CSS with a configuration specified by a Whitelist. 根据白名单过滤CSS",
"main": "lib/index.js",
"files": [
"lib"
],
"scripts": {
"test": "istanbul cover _mocha --report lcovonly -- -t 5000 -R spec && cat ./coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js && rm -rf ./coverage",
"build": "./build",
"prepublish": "npm run test && npm run build"
},
"repository": {
"type": "git",
"url": "https://github.com/leizongmin/js-css-filter.git"
},
"keywords": [
"sanitization",
"xss",
"sanitize",
"sanitisation",
"input",
"security",
"escape",
"encode",
"filter",
"validator",
"html",
"css",
"injection",
"whitelist"
],
"author": "Zongmin Lei <leizongmin@gmail.com>",
"license": "MIT",
"bugs": {
"url": "https://github.com/leizongmin/js-css-filter/issues"
},
"homepage": "https://github.com/leizongmin/js-css-filter",
"devDependencies": {
"blanket": "^1.1.6",
"browserify": "^13.1.1",
"coveralls": "^2.11.14",
"istanbul": "^0.4.5",
"mocha": "^3.1.2",
"should": "^11.1.1",
"uglify-js": "^2.7.4"
}
}

View File

@@ -0,0 +1,17 @@
/*
* Copyright The OpenTelemetry Authors
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
export {};
//# sourceMappingURL=Meter.js.map

View File

@@ -0,0 +1,2 @@
const e=require(`../../utils/throw-if-empty.cjs`),t=(t,n,r)=>()=>(e.throwIfEmpty(t,`Provider cannot be empty`),{path:`/deployments/${t}`,params:r??{},body:JSON.stringify(n),method:`PATCH`}),n=(t,n)=>()=>(e.throwIfEmpty(t,`Provider cannot be empty`),{path:`/deployments/${t}/projects`,body:JSON.stringify(n),method:`PATCH`});exports.updateDeployment=t,exports.updateDeploymentProjects=n;
//# sourceMappingURL=deployment.cjs.map

View File

@@ -0,0 +1,7 @@
export declare const differenceInHoursWithOptions: import("./types.js").FPFn3<
number,
| import("../differenceInHours.js").DifferenceInHoursOptions
| undefined,
string | number | Date,
string | number | Date
>;

View File

@@ -0,0 +1,10 @@
"use strict";
exports.addHours = void 0;
var _index = require("../addHours.js");
var _index2 = require("./_lib/convertToFP.js"); // This file is generated automatically by `scripts/build/fp.ts`. Please, don't change it.
const addHours = (exports.addHours = (0, _index2.convertToFP)(
_index.addHours,
2,
));

View File

@@ -0,0 +1,16 @@
/**
* @license lucide-react v0.441.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
import createLucideIcon from '../createLucideIcon.js';
const ChevronsRightLeft = createLucideIcon("ChevronsRightLeft", [
["path", { d: "m20 17-5-5 5-5", key: "30x0n2" }],
["path", { d: "m4 17 5-5-5-5", key: "16spf4" }]
]);
export { ChevronsRightLeft as default };
//# sourceMappingURL=chevrons-right-left.js.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/platform/node/index.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;;;;;;;;;;;AAEH,+CAA6B","sourcesContent":["/*\n * Copyright The OpenTelemetry Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport * from './globalThis';\n"]}

View File

@@ -0,0 +1 @@
{"version":3,"sources":["../../../src/sqlite-core/query-builders/raw.ts"],"sourcesContent":["import { entityKind } from '~/entity.ts';\nimport { QueryPromise } from '~/query-promise.ts';\nimport type { RunnableQuery } from '~/runnable-query.ts';\nimport type { PreparedQuery } from '~/session.ts';\nimport type { SQL, SQLWrapper } from '~/sql/sql.ts';\nimport type { SQLiteAsyncDialect } from '../dialect.ts';\n\ntype SQLiteRawAction = 'all' | 'get' | 'values' | 'run';\nexport interface SQLiteRawConfig {\n\taction: SQLiteRawAction;\n}\n\nexport interface SQLiteRaw<TResult> extends QueryPromise<TResult>, RunnableQuery<TResult, 'sqlite'>, SQLWrapper {}\n\nexport class SQLiteRaw<TResult> extends QueryPromise<TResult>\n\timplements RunnableQuery<TResult, 'sqlite'>, SQLWrapper, PreparedQuery\n{\n\tstatic override readonly [entityKind]: string = 'SQLiteRaw';\n\n\tdeclare readonly _: {\n\t\treadonly dialect: 'sqlite';\n\t\treadonly result: TResult;\n\t};\n\n\t/** @internal */\n\tconfig: SQLiteRawConfig;\n\n\tconstructor(\n\t\tpublic execute: () => Promise<TResult>,\n\t\t/** @internal */\n\t\tpublic getSQL: () => SQL,\n\t\taction: SQLiteRawAction,\n\t\tprivate dialect: SQLiteAsyncDialect,\n\t\tprivate mapBatchResult: (result: unknown) => unknown,\n\t) {\n\t\tsuper();\n\t\tthis.config = { action };\n\t}\n\n\tgetQuery() {\n\t\treturn { ...this.dialect.sqlToQuery(this.getSQL()), method: this.config.action };\n\t}\n\n\tmapResult(result: unknown, isFromBatch?: boolean) {\n\t\treturn isFromBatch ? this.mapBatchResult(result) : result;\n\t}\n\n\t_prepare(): PreparedQuery {\n\t\treturn this;\n\t}\n\n\t/** @internal */\n\tisResponseInArrayMode(): boolean {\n\t\treturn false;\n\t}\n}\n"],"mappings":"AAAA,SAAS,kBAAkB;AAC3B,SAAS,oBAAoB;AAatB,MAAM,kBAA2B,aAExC;AAAA,EAWC,YACQ,SAEA,QACP,QACQ,SACA,gBACP;AACD,UAAM;AAPC;AAEA;AAEC;AACA;AAGR,SAAK,SAAS,EAAE,OAAO;AAAA,EACxB;AAAA,EApBA,QAA0B,UAAU,IAAY;AAAA;AAAA,EAQhD;AAAA,EAcA,WAAW;AACV,WAAO,EAAE,GAAG,KAAK,QAAQ,WAAW,KAAK,OAAO,CAAC,GAAG,QAAQ,KAAK,OAAO,OAAO;AAAA,EAChF;AAAA,EAEA,UAAU,QAAiB,aAAuB;AACjD,WAAO,cAAc,KAAK,eAAe,MAAM,IAAI;AAAA,EACpD;AAAA,EAEA,WAA0B;AACzB,WAAO;AAAA,EACR;AAAA;AAAA,EAGA,wBAAiC;AAChC,WAAO;AAAA,EACR;AACD;","names":[]}

View File

@@ -0,0 +1,26 @@
import { Forbidden } from '../errors/index.js';
export const executeAccess = async ({ id, data, disableErrors, isReadingStaticFile = false, req }, access)=>{
if (access) {
const resolvedConstraint = await access({
id,
data,
isReadingStaticFile,
req
});
if (!resolvedConstraint) {
if (!disableErrors) {
throw new Forbidden(req.t);
}
}
return resolvedConstraint;
}
if (req.user) {
return true;
}
if (!disableErrors) {
throw new Forbidden(req.t);
}
return false;
};
//# sourceMappingURL=executeAccess.js.map

View File

@@ -0,0 +1,6 @@
export declare const setWeekYearWithOptions: import("./types.js").FPFn3<
Date,
import("../setWeekYear.js").SetWeekYearOptions<Date> | undefined,
number,
import("../fp.js").DateArg<Date>
>;

View File

@@ -0,0 +1,13 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = _classCallCheck;
function _classCallCheck(instance, Constructor) {
if (!(instance instanceof Constructor)) {
throw new TypeError("Cannot call a class as a function");
}
}
//# sourceMappingURL=classCallCheck.js.map

View File

@@ -0,0 +1,17 @@
/**
* @license lucide-react v0.441.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
import createLucideIcon from '../createLucideIcon.js';
const ListFilter = createLucideIcon("ListFilter", [
["path", { d: "M3 6h18", key: "d0wm0j" }],
["path", { d: "M7 12h10", key: "b7w52i" }],
["path", { d: "M10 18h4", key: "1ulq68" }]
]);
export { ListFilter as default };
//# sourceMappingURL=list-filter.js.map

View File

@@ -0,0 +1,38 @@
/**
* Common exports shared between the main entry point (index.ts) and the light entry point (light/index.ts).
*
* Add exports here that should be available in both entry points. Entry-point-specific exports
* (e.g., OTel-dependent ones for index.ts, or light-specific ones for light/index.ts) should
* remain in their respective index files.
*
* Deprecated exports should NOT go in this file — they belong in the entry point that still
* needs to ship them for backwards compatibility.
*/
import * as logger from './logs/exports';
export { nodeContextIntegration } from './integrations/context';
export { contextLinesIntegration } from './integrations/contextlines';
export { localVariablesIntegration } from './integrations/local-variables';
export { modulesIntegration } from './integrations/modules';
export { onUncaughtExceptionIntegration } from './integrations/onuncaughtexception';
export { onUnhandledRejectionIntegration } from './integrations/onunhandledrejection';
export { spotlightIntegration } from './integrations/spotlight';
export { systemErrorIntegration } from './integrations/systemError';
export { childProcessIntegration } from './integrations/childProcess';
export { createSentryWinstonTransport } from './integrations/winston';
export { pinoIntegration } from './integrations/pino';
export { getSentryRelease, defaultStackParser } from './sdk/api';
export { createGetModuleFromFilename } from './utils/module';
export { addOriginToSpan } from './utils/addOriginToSpan';
export { getRequestUrl } from './utils/getRequestUrl';
export { initializeEsmLoader } from './sdk/esmLoader';
export { isCjs } from './utils/detection';
export { createMissingInstrumentationContext } from './utils/createMissingInstrumentationContext';
export { makeNodeTransport, NodeTransportOptions } from './transports';
export { HTTPModuleRequestIncomingMessage } from './transports/http-module';
export { cron } from './cron';
export { NODE_VERSION } from './nodeVersion';
export { NodeOptions } from './types';
export { addBreadcrumb, isInitialized, isEnabled, getGlobalScope, lastEventId, close, createTransport, flush, SDK_VERSION, getSpanStatusFromHttpCode, setHttpStatus, captureCheckIn, withMonitor, requestDataIntegration, functionToStringIntegration, eventFiltersIntegration, linkedErrorsIntegration, addEventProcessor, setContext, setExtra, setExtras, setTag, setTags, setUser, SEMANTIC_ATTRIBUTE_SENTRY_OP, SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN, SEMANTIC_ATTRIBUTE_SENTRY_SOURCE, SEMANTIC_ATTRIBUTE_SENTRY_SAMPLE_RATE, setCurrentClient, Scope, setMeasurement, getSpanDescendants, parameterize, getClient, getCurrentScope, getIsolationScope, getTraceData, getTraceMetaTags, continueTrace, withScope, withIsolationScope, captureException, captureEvent, captureMessage, captureFeedback, captureConsoleIntegration, dedupeIntegration, extraErrorDataIntegration, rewriteFramesIntegration, startSession, captureSession, endSession, addIntegration, startSpan, startSpanManual, startInactiveSpan, startNewTrace, suppressTracing, getActiveSpan, withActiveSpan, getRootSpan, spanToJSON, spanToTraceHeader, spanToBaggageHeader, trpcMiddleware, updateSpanName, supabaseIntegration, instrumentSupabaseClient, zodErrorsIntegration, profiler, consoleLoggingIntegration, createConsolaReporter, consoleIntegration, wrapMcpServerWithSentry, featureFlagsIntegration, metrics, envToBool, } from '@sentry/core';
export { Breadcrumb, BreadcrumbHint, PolymorphicRequest, RequestEventData, SdkInfo, Event, EventHint, ErrorEvent, Exception, Session, SeverityLevel, StackFrame, Stacktrace, Thread, User, Span, FeatureFlagsIntegration, } from '@sentry/core';
export { logger };
//# sourceMappingURL=common-exports.d.ts.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"enforceMaxVersions.d.ts","sourceRoot":"","sources":["../../src/versions/enforceMaxVersions.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,gCAAgC,CAAA;AAE/E,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,4BAA4B,CAAA;AACvE,OAAO,KAAK,EAAE,OAAO,EAAE,cAAc,EAAS,MAAM,mBAAmB,CAAA;AAEvE,KAAK,IAAI,GAAG;IACV,UAAU,CAAC,EAAE,yBAAyB,CAAA;IACtC,MAAM,CAAC,EAAE,qBAAqB,CAAA;IAC9B,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAAA;IACpB,GAAG,EAAE,MAAM,CAAA;IACX,OAAO,EAAE,OAAO,CAAA;IAChB,GAAG,CAAC,EAAE,cAAc,CAAA;CACrB,CAAA;AAED,eAAO,MAAM,kBAAkB,iEAO5B,IAAI,KAAG,OAAO,CAAC,IAAI,CAmErB,CAAA"}

View File

@@ -0,0 +1,21 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.textTransform = void 0;
exports.textTransform = {
name: 'text-transform',
initialValue: 'none',
prefix: false,
type: 2 /* IDENT_VALUE */,
parse: function (_context, textTransform) {
switch (textTransform) {
case 'uppercase':
return 2 /* UPPERCASE */;
case 'lowercase':
return 1 /* LOWERCASE */;
case 'capitalize':
return 3 /* CAPITALIZE */;
}
return 0 /* NONE */;
}
};
//# sourceMappingURL=text-transform.js.map

View File

@@ -0,0 +1,9 @@
// This file is generated automatically by `scripts/build/fp.ts`. Please, don't change it.
import { isValid as fn } from "../isValid.js";
import { convertToFP } from "./_lib/convertToFP.js";
export const isValid = convertToFP(fn, 1);
// Fallback for modularized imports:
export default isValid;

View File

@@ -0,0 +1,3 @@
export declare const PACKAGE_VERSION = "0.59.0";
export declare const PACKAGE_NAME = "@opentelemetry/instrumentation-koa";
//# sourceMappingURL=version.d.ts.map

View File

@@ -0,0 +1,427 @@
/*
MIT License http://www.opensource.org/licenses/mit-license.php
Author Tobias Koppers @sokra
*/
"use strict";
const { ConcatSource, PrefixSource } = require("webpack-sources");
const { WEBPACK_MODULE_TYPE_RUNTIME } = require("./ModuleTypeConstants");
const RuntimeGlobals = require("./RuntimeGlobals");
/** @typedef {import("webpack-sources").Source} Source */
/** @typedef {import("./config/defaults").OutputNormalizedWithDefaults} OutputOptions */
/** @typedef {import("./Chunk")} Chunk */
/** @typedef {import("./ChunkGraph")} ChunkGraph */
/** @typedef {import("./ChunkGraph").ModuleId} ModuleId */
/** @typedef {import("./CodeGenerationResults")} CodeGenerationResults */
/** @typedef {import("./Compilation").AssetInfo} AssetInfo */
/** @typedef {import("./Compilation").PathData} PathData */
/** @typedef {import("./DependencyTemplates")} DependencyTemplates */
/** @typedef {import("./Module")} Module */
/** @typedef {import("./ModuleGraph")} ModuleGraph */
/** @typedef {import("./ModuleTemplate")} ModuleTemplate */
/** @typedef {import("./RuntimeModule")} RuntimeModule */
/** @typedef {import("./RuntimeTemplate")} RuntimeTemplate */
/** @typedef {import("./TemplatedPathPlugin").TemplatePath} TemplatePath */
/** @typedef {import("./javascript/JavascriptModulesPlugin").ChunkRenderContext} ChunkRenderContext */
/** @typedef {import("./javascript/JavascriptModulesPlugin").RenderContext} RenderContext */
const START_LOWERCASE_ALPHABET_CODE = "a".charCodeAt(0);
const START_UPPERCASE_ALPHABET_CODE = "A".charCodeAt(0);
const DELTA_A_TO_Z = "z".charCodeAt(0) - START_LOWERCASE_ALPHABET_CODE + 1;
const NUMBER_OF_IDENTIFIER_START_CHARS = DELTA_A_TO_Z * 2 + 2; // a-z A-Z _ $
const NUMBER_OF_IDENTIFIER_CONTINUATION_CHARS =
NUMBER_OF_IDENTIFIER_START_CHARS + 10; // a-z A-Z _ $ 0-9
const FUNCTION_CONTENT_REGEX = /^function\s?\(\)\s?\{\r?\n?|\r?\n?\}$/g;
const INDENT_MULTILINE_REGEX = /^\t/gm;
const LINE_SEPARATOR_REGEX = /\r?\n/g;
const IDENTIFIER_NAME_REPLACE_REGEX = /^([^a-z$_])/i;
const IDENTIFIER_ALPHA_NUMERIC_NAME_REPLACE_REGEX = /[^a-z0-9$]+/gi;
const COMMENT_END_REGEX = /\*\//g;
const PATH_NAME_NORMALIZE_REPLACE_REGEX = /[^a-z0-9_!§$()=\-^°]+/gi;
const MATCH_PADDED_HYPHENS_REPLACE_REGEX = /^-|-$/g;
/**
* @typedef {object} RenderManifestOptions
* @property {Chunk} chunk the chunk used to render
* @property {string} hash
* @property {string} fullHash
* @property {OutputOptions} outputOptions
* @property {CodeGenerationResults} codeGenerationResults
* @property {{ javascript: ModuleTemplate }} moduleTemplates
* @property {DependencyTemplates} dependencyTemplates
* @property {RuntimeTemplate} runtimeTemplate
* @property {ModuleGraph} moduleGraph
* @property {ChunkGraph} chunkGraph
*/
/** @typedef {RenderManifestEntryTemplated | RenderManifestEntryStatic} RenderManifestEntry */
/**
* @typedef {object} RenderManifestEntryTemplated
* @property {() => Source} render
* @property {TemplatePath} filenameTemplate
* @property {PathData=} pathOptions
* @property {AssetInfo=} info
* @property {string} identifier
* @property {string=} hash
* @property {boolean=} auxiliary
*/
/**
* @typedef {object} RenderManifestEntryStatic
* @property {() => Source} render
* @property {string} filename
* @property {AssetInfo} info
* @property {string} identifier
* @property {string=} hash
* @property {boolean=} auxiliary
*/
/**
* @typedef {(module: Module) => boolean} ModuleFilterPredicate
*/
/**
* @typedef {object} Stringable
* @property {() => string} toString
*/
class Template {
/**
* @param {Stringable} fn a runtime function (.runtime.js) "template"
* @returns {string} the updated and normalized function string
*/
static getFunctionContent(fn) {
return fn
.toString()
.replace(FUNCTION_CONTENT_REGEX, "")
.replace(INDENT_MULTILINE_REGEX, "")
.replace(LINE_SEPARATOR_REGEX, "\n");
}
/**
* @param {string} str the string converted to identifier
* @returns {string} created identifier
*/
static toIdentifier(str) {
if (typeof str !== "string") return "";
return str
.replace(IDENTIFIER_NAME_REPLACE_REGEX, "_$1")
.replace(IDENTIFIER_ALPHA_NUMERIC_NAME_REPLACE_REGEX, "_");
}
/**
* @param {string} str string to be converted to commented in bundle code
* @returns {string} returns a commented version of string
*/
static toComment(str) {
if (!str) return "";
return `/*! ${str.replace(COMMENT_END_REGEX, "* /")} */`;
}
/**
* @param {string} str string to be converted to "normal comment"
* @returns {string} returns a commented version of string
*/
static toNormalComment(str) {
if (!str) return "";
return `/* ${str.replace(COMMENT_END_REGEX, "* /")} */`;
}
/**
* @param {string} str string path to be normalized
* @returns {string} normalized bundle-safe path
*/
static toPath(str) {
if (typeof str !== "string") return "";
return str
.replace(PATH_NAME_NORMALIZE_REPLACE_REGEX, "-")
.replace(MATCH_PADDED_HYPHENS_REPLACE_REGEX, "");
}
// map number to a single character a-z, A-Z or multiple characters if number is too big
/**
* @param {number} n number to convert to ident
* @returns {string} returns single character ident
*/
static numberToIdentifier(n) {
if (n >= NUMBER_OF_IDENTIFIER_START_CHARS) {
// use multiple letters
return (
Template.numberToIdentifier(n % NUMBER_OF_IDENTIFIER_START_CHARS) +
Template.numberToIdentifierContinuation(
Math.floor(n / NUMBER_OF_IDENTIFIER_START_CHARS)
)
);
}
// lower case
if (n < DELTA_A_TO_Z) {
return String.fromCharCode(START_LOWERCASE_ALPHABET_CODE + n);
}
n -= DELTA_A_TO_Z;
// upper case
if (n < DELTA_A_TO_Z) {
return String.fromCharCode(START_UPPERCASE_ALPHABET_CODE + n);
}
if (n === DELTA_A_TO_Z) return "_";
return "$";
}
/**
* @param {number} n number to convert to ident
* @returns {string} returns single character ident
*/
static numberToIdentifierContinuation(n) {
if (n >= NUMBER_OF_IDENTIFIER_CONTINUATION_CHARS) {
// use multiple letters
return (
Template.numberToIdentifierContinuation(
n % NUMBER_OF_IDENTIFIER_CONTINUATION_CHARS
) +
Template.numberToIdentifierContinuation(
Math.floor(n / NUMBER_OF_IDENTIFIER_CONTINUATION_CHARS)
)
);
}
// lower case
if (n < DELTA_A_TO_Z) {
return String.fromCharCode(START_LOWERCASE_ALPHABET_CODE + n);
}
n -= DELTA_A_TO_Z;
// upper case
if (n < DELTA_A_TO_Z) {
return String.fromCharCode(START_UPPERCASE_ALPHABET_CODE + n);
}
n -= DELTA_A_TO_Z;
// numbers
if (n < 10) {
return `${n}`;
}
if (n === 10) return "_";
return "$";
}
/**
* @param {string | string[]} s string to convert to identity
* @returns {string} converted identity
*/
static indent(s) {
if (Array.isArray(s)) {
return s.map(Template.indent).join("\n");
}
const str = s.trimEnd();
if (!str) return "";
const ind = str[0] === "\n" ? "" : "\t";
return ind + str.replace(/\n([^\n])/g, "\n\t$1");
}
/**
* @param {string | string[]} s string to create prefix for
* @param {string} prefix prefix to compose
* @returns {string} returns new prefix string
*/
static prefix(s, prefix) {
const str = Template.asString(s).trim();
if (!str) return "";
const ind = str[0] === "\n" ? "" : prefix;
return ind + str.replace(/\n([^\n])/g, `\n${prefix}$1`);
}
/**
* @param {string | string[]} str string or string collection
* @returns {string} returns a single string from array
*/
static asString(str) {
if (Array.isArray(str)) {
return str.join("\n");
}
return str;
}
/**
* @typedef {object} WithId
* @property {string | number} id
*/
/**
* @param {WithId[]} modules a collection of modules to get array bounds for
* @returns {[number, number] | false} returns the upper and lower array bounds
* or false if not every module has a number based id
*/
static getModulesArrayBounds(modules) {
let maxId = -Infinity;
let minId = Infinity;
for (const module of modules) {
const moduleId = module.id;
if (typeof moduleId !== "number") return false;
if (maxId < moduleId) maxId = moduleId;
if (minId > moduleId) minId = moduleId;
}
if (minId < 16 + String(minId).length) {
// add minId x ',' instead of 'Array(minId).concat(…)'
minId = 0;
}
// start with -1 because the first module needs no comma
let objectOverhead = -1;
for (const module of modules) {
// module id + colon + comma
objectOverhead += `${module.id}`.length + 2;
}
// number of commas, or when starting non-zero the length of Array(minId).concat()
const arrayOverhead = minId === 0 ? maxId : 16 + `${minId}`.length + maxId;
return arrayOverhead < objectOverhead ? [minId, maxId] : false;
}
/**
* @param {ChunkRenderContext} renderContext render context
* @param {Module[]} modules modules to render (should be ordered by identifier)
* @param {(module: Module, renderInArray?: boolean) => Source | null} renderModule function to render a module
* @param {string=} prefix applying prefix strings
* @returns {Source | null} rendered chunk modules in a Source object or null if no modules
*/
static renderChunkModules(renderContext, modules, renderModule, prefix = "") {
const { chunkGraph } = renderContext;
const source = new ConcatSource();
if (modules.length === 0) {
return null;
}
/** @type {{ id: ModuleId, module: Module }[]} */
const modulesWithId = modules.map((m) => ({
id: /** @type {ModuleId} */ (chunkGraph.getModuleId(m)),
module: m
}));
const bounds = Template.getModulesArrayBounds(modulesWithId);
const renderInObject = bounds === false;
/** @type {{ id: ModuleId, source: Source | "false" }[]} */
const allModules = modulesWithId.map(({ id, module }) => ({
id,
source: renderModule(module, renderInObject) || "false"
}));
if (bounds) {
// Render a spare array
const minId = bounds[0];
const maxId = bounds[1];
if (minId !== 0) {
source.add(`Array(${minId}).concat(`);
}
source.add("[\n");
/** @type {Map<ModuleId, { id: ModuleId, source: Source | "false" }>} */
const modules = new Map();
for (const module of allModules) {
modules.set(module.id, module);
}
for (let idx = minId; idx <= maxId; idx++) {
const module = modules.get(idx);
if (idx !== minId) {
source.add(",\n");
}
source.add(`/* ${idx} */`);
if (module) {
source.add("\n");
source.add(module.source);
}
}
source.add(`\n${prefix}]`);
if (minId !== 0) {
source.add(")");
}
} else {
// Render an object
source.add("{\n");
for (let i = 0; i < allModules.length; i++) {
const module = allModules[i];
if (i !== 0) {
source.add(",\n");
}
source.add(
`\n/***/ ${JSON.stringify(module.id)}${renderContext.runtimeTemplate.supportsMethodShorthand() && module.source !== "false" ? "" : ":"}\n`
);
source.add(module.source);
}
source.add(`\n\n${prefix}}`);
}
return source;
}
/**
* @param {RuntimeModule[]} runtimeModules array of runtime modules in order
* @param {RenderContext & { codeGenerationResults?: CodeGenerationResults }} renderContext render context
* @returns {Source} rendered runtime modules in a Source object
*/
static renderRuntimeModules(runtimeModules, renderContext) {
const source = new ConcatSource();
for (const module of runtimeModules) {
const codeGenerationResults = renderContext.codeGenerationResults;
/** @type {undefined | Source} */
let runtimeSource;
if (codeGenerationResults) {
runtimeSource = codeGenerationResults.getSource(
module,
renderContext.chunk.runtime,
WEBPACK_MODULE_TYPE_RUNTIME
);
} else {
const codeGenResult = module.codeGeneration({
chunkGraph: renderContext.chunkGraph,
dependencyTemplates: renderContext.dependencyTemplates,
moduleGraph: renderContext.moduleGraph,
runtimeTemplate: renderContext.runtimeTemplate,
runtime: renderContext.chunk.runtime,
runtimes: [renderContext.chunk.runtime],
codeGenerationResults
});
if (!codeGenResult) continue;
runtimeSource = codeGenResult.sources.get("runtime");
}
if (runtimeSource) {
source.add(`${Template.toNormalComment(module.identifier())}\n`);
if (!module.shouldIsolate()) {
source.add(runtimeSource);
source.add("\n\n");
} else if (renderContext.runtimeTemplate.supportsArrowFunction()) {
source.add("(() => {\n");
source.add(new PrefixSource("\t", runtimeSource));
source.add("\n})();\n\n");
} else {
source.add("!function() {\n");
source.add(new PrefixSource("\t", runtimeSource));
source.add("\n}();\n\n");
}
}
}
return source;
}
/**
* @param {RuntimeModule[]} runtimeModules array of runtime modules in order
* @param {RenderContext} renderContext render context
* @returns {Source} rendered chunk runtime modules in a Source object
*/
static renderChunkRuntimeModules(runtimeModules, renderContext) {
return new PrefixSource(
"/******/ ",
new ConcatSource(
`function(${RuntimeGlobals.require}) { // webpackRuntimeModules\n`,
this.renderRuntimeModules(runtimeModules, renderContext),
"}\n"
)
);
}
}
module.exports = Template;
module.exports.NUMBER_OF_IDENTIFIER_CONTINUATION_CHARS =
NUMBER_OF_IDENTIFIER_CONTINUATION_CHARS;
module.exports.NUMBER_OF_IDENTIFIER_START_CHARS =
NUMBER_OF_IDENTIFIER_START_CHARS;

View File

@@ -0,0 +1,24 @@
import { entityKind } from "../entity.cjs";
import type { MySqlColumn } from "./columns/index.cjs";
import type { MySqlTable } from "./table.cjs";
export declare function unique(name?: string): UniqueOnConstraintBuilder;
export declare function uniqueKeyName(table: MySqlTable, columns: string[]): string;
export declare class UniqueConstraintBuilder {
private name?;
static readonly [entityKind]: string;
constructor(columns: MySqlColumn[], name?: string | undefined);
}
export declare class UniqueOnConstraintBuilder {
static readonly [entityKind]: string;
constructor(name?: string);
on(...columns: [MySqlColumn, ...MySqlColumn[]]): UniqueConstraintBuilder;
}
export declare class UniqueConstraint {
readonly table: MySqlTable;
static readonly [entityKind]: string;
readonly columns: MySqlColumn[];
readonly name?: string;
readonly nullsNotDistinct: boolean;
constructor(table: MySqlTable, columns: MySqlColumn[], name?: string);
getName(): string | undefined;
}

View File

@@ -0,0 +1 @@
{"version":3,"file":"moon-star.js","sources":["../../../src/icons/moon-star.ts"],"sourcesContent":["import createLucideIcon from '../createLucideIcon';\n\n/**\n * @component @name MoonStar\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview ![img](data:image/svg+xml;base64,PHN2ZyAgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIgogIHdpZHRoPSIyNCIKICBoZWlnaHQ9IjI0IgogIHZpZXdCb3g9IjAgMCAyNCAyNCIKICBmaWxsPSJub25lIgogIHN0cm9rZT0iIzAwMCIgc3R5bGU9ImJhY2tncm91bmQtY29sb3I6ICNmZmY7IGJvcmRlci1yYWRpdXM6IDJweCIKICBzdHJva2Utd2lkdGg9IjIiCiAgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIgogIHN0cm9rZS1saW5lam9pbj0icm91bmQiCj4KICA8cGF0aCBkPSJNMTIgM2E2IDYgMCAwIDAgOSA5IDkgOSAwIDEgMS05LTkiIC8+CiAgPHBhdGggZD0iTTIwIDN2NCIgLz4KICA8cGF0aCBkPSJNMjIgNWgtNCIgLz4KPC9zdmc+Cg==) - https://lucide.dev/icons/moon-star\n * @see https://lucide.dev/guide/packages/lucide-react - Documentation\n *\n * @param {Object} props - Lucide icons props and any valid SVG attribute\n * @returns {JSX.Element} JSX Element\n *\n */\nconst MoonStar = createLucideIcon('MoonStar', [\n ['path', { d: 'M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9', key: '4ay0iu' }],\n ['path', { d: 'M20 3v4', key: '1olli1' }],\n ['path', { d: 'M22 5h-4', key: '1gvqau' }],\n]);\n\nexport default MoonStar;\n"],"names":[],"mappings":";;;;;;;;;AAaM,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAW,iBAAiB,UAAY,CAAA,CAAA,CAAA;AAAA,CAAA,CAC5C,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAqC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CAClE,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAW,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CACxC,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAY,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA;AAC3C,CAAC,CAAA,CAAA;;"}

View File

@@ -0,0 +1,25 @@
/**
* Returns true if the provided object is an Object (i.e. not a string literal)
* and implements the Iterator protocol.
*
* This may be used in place of [Array.isArray()][isArray] to determine if
* an object should be iterated-over e.g. Array, Map, Set, Int8Array,
* TypedArray, etc. but excludes string literals.
*
* @example
* ```ts
* isIterableObject([ 1, 2, 3 ]) // true
* isIterableObject(new Map()) // true
* isIterableObject('ABC') // false
* isIterableObject({ key: 'value' }) // false
* isIterableObject({ length: 1, 0: 'Alpha' }) // false
* ```
*/
export function isIterableObject(maybeIterable) {
return (
typeof maybeIterable === 'object' &&
typeof (maybeIterable === null || maybeIterable === void 0
? void 0
: maybeIterable[Symbol.iterator]) === 'function'
);
}

View File

@@ -0,0 +1,12 @@
import type { GraphQLResolveInfo } from 'graphql';
import type { Document, SanitizedGlobalConfig } from 'payload';
import type { Context } from '../types.js';
export type Resolver = (_: unknown, args: {
draft?: boolean;
fallbackLocale?: string;
id: number | string;
locale?: string;
select?: boolean;
}, context: Context, info: GraphQLResolveInfo) => Promise<Document>;
export declare function findVersionByID(globalConfig: SanitizedGlobalConfig): Resolver;
//# sourceMappingURL=findVersionByID.d.ts.map

View File

@@ -0,0 +1,24 @@
var castPath = require('./_castPath'),
toKey = require('./_toKey');
/**
* The base implementation of `_.get` without support for default values.
*
* @private
* @param {Object} object The object to query.
* @param {Array|string} path The path of the property to get.
* @returns {*} Returns the resolved value.
*/
function baseGet(object, path) {
path = castPath(path, object);
var index = 0,
length = path.length;
while (object != null && index < length) {
object = object[toKey(path[index++])];
}
return (index && index == length) ? object : undefined;
}
module.exports = baseGet;

View File

@@ -0,0 +1,23 @@
const Ajv = require("ajv")
const ajv = new Ajv({allErrors: true})
const schema = {
type: "object",
properties: {
foo: {type: "string"},
bar: {type: "number", maximum: 3},
},
required: ["foo", "bar"],
additionalProperties: false,
}
const validate = ajv.compile(schema)
test({foo: "abc", bar: 2})
test({foo: 2, bar: 4})
function test(data) {
const valid = validate(data)
if (valid) console.log("Valid!")
else console.log("Invalid: " + ajv.errorsText(validate.errors))
}

View File

@@ -0,0 +1,35 @@
var assocIndexOf = require('./_assocIndexOf');
/** Used for built-in method references. */
var arrayProto = Array.prototype;
/** Built-in value references. */
var splice = arrayProto.splice;
/**
* Removes `key` and its value from the list cache.
*
* @private
* @name delete
* @memberOf ListCache
* @param {string} key The key of the value to remove.
* @returns {boolean} Returns `true` if the entry was removed, else `false`.
*/
function listCacheDelete(key) {
var data = this.__data__,
index = assocIndexOf(data, key);
if (index < 0) {
return false;
}
var lastIndex = data.length - 1;
if (index == lastIndex) {
data.pop();
} else {
splice.call(data, index, 1);
}
--this.size;
return true;
}
module.exports = listCacheDelete;

View File

@@ -0,0 +1 @@
{"version":3,"file":"flag-off.js","sources":["../../../src/icons/flag-off.ts"],"sourcesContent":["import createLucideIcon from '../createLucideIcon';\n\n/**\n * @component @name FlagOff\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview ![img](data:image/svg+xml;base64,PHN2ZyAgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIgogIHdpZHRoPSIyNCIKICBoZWlnaHQ9IjI0IgogIHZpZXdCb3g9IjAgMCAyNCAyNCIKICBmaWxsPSJub25lIgogIHN0cm9rZT0iIzAwMCIgc3R5bGU9ImJhY2tncm91bmQtY29sb3I6ICNmZmY7IGJvcmRlci1yYWRpdXM6IDJweCIKICBzdHJva2Utd2lkdGg9IjIiCiAgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIgogIHN0cm9rZS1saW5lam9pbj0icm91bmQiCj4KICA8cGF0aCBkPSJNOCAyYzMgMCA1IDIgOCAyczQtMSA0LTF2MTEiIC8+CiAgPHBhdGggZD0iTTQgMjJWNCIgLz4KICA8cGF0aCBkPSJNNCAxNXMxLTEgNC0xIDUgMiA4IDIiIC8+CiAgPGxpbmUgeDE9IjIiIHgyPSIyMiIgeTE9IjIiIHkyPSIyMiIgLz4KPC9zdmc+Cg==) - https://lucide.dev/icons/flag-off\n * @see https://lucide.dev/guide/packages/lucide-react - Documentation\n *\n * @param {Object} props - Lucide icons props and any valid SVG attribute\n * @returns {JSX.Element} JSX Element\n *\n */\nconst FlagOff = createLucideIcon('FlagOff', [\n ['path', { d: 'M8 2c3 0 5 2 8 2s4-1 4-1v11', key: '9rwyz9' }],\n ['path', { d: 'M4 22V4', key: '1plyxx' }],\n ['path', { d: 'M4 15s1-1 4-1 5 2 8 2', key: '1myooe' }],\n ['line', { x1: '2', x2: '22', y1: '2', y2: '22', key: 'a6p6uj' }],\n]);\n\nexport default FlagOff;\n"],"names":[],"mappings":";;;;;;;;;AAaM,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAU,iBAAiB,SAAW,CAAA,CAAA,CAAA;AAAA,CAAA,CAC1C,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAA+B,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CAC5D,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAW,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CACxC,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAyB,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CACtD,CAAA,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAE,CAAA,CAAA,CAAA,EAAI,CAAK,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAI,CAAM,CAAA,CAAA,CAAA,CAAA,CAAA,EAAA,CAAI,CAAA,CAAA,CAAA,CAAK,CAAA,CAAA,CAAA,CAAA,CAAI,CAAA,CAAA,CAAA,CAAA,CAAM,EAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA;AAClE,CAAC,CAAA,CAAA;;"}

View File

@@ -0,0 +1,133 @@
import { MissingEditorProp } from 'payload';
import { fieldAffectsData, getFieldPaths, tabHasName } from 'payload/shared';
export const traverseFields = ({
config,
fields,
i18n,
parentIndexPath,
parentSchemaPath,
schemaMap
}) => {
for (const [index, field] of fields.entries()) {
const {
indexPath,
schemaPath
} = getFieldPaths({
field,
index,
parentIndexPath,
parentSchemaPath
});
schemaMap.set(schemaPath, field);
switch (field.type) {
case 'array':
traverseFields({
config,
fields: field.fields,
i18n,
parentIndexPath: '',
parentSchemaPath: schemaPath,
schemaMap
});
break;
case 'blocks':
;
(field.blockReferences ?? field.blocks).map(_block => {
// TODO: iterate over blocks mapped to block slug in v4, or pass through payload.blocks
const block = typeof _block === 'string' ? config.blocks.find(b => b.slug === _block) : _block;
const blockSchemaPath = `${schemaPath}.${block.slug}`;
schemaMap.set(blockSchemaPath, block);
traverseFields({
config,
fields: block.fields,
i18n,
parentIndexPath: '',
parentSchemaPath: schemaPath + '.' + block.slug,
schemaMap
});
});
break;
case 'collapsible':
case 'row':
traverseFields({
config,
fields: field.fields,
i18n,
parentIndexPath: indexPath,
parentSchemaPath: schemaPath,
schemaMap
});
break;
case 'group':
if (fieldAffectsData(field)) {
traverseFields({
config,
fields: field.fields,
i18n,
parentIndexPath: '',
parentSchemaPath: schemaPath,
schemaMap
});
} else {
traverseFields({
config,
fields: field.fields,
i18n,
parentIndexPath: indexPath,
parentSchemaPath: schemaPath,
schemaMap
});
}
break;
case 'richText':
{
if (!field?.editor) {
throw new MissingEditorProp(field) // while we allow disabling editor functionality, you should not have any richText fields defined if you do not have an editor
;
}
if (typeof field.editor === 'function') {
throw new Error('Attempted to access unsanitized rich text editor.');
}
if (typeof field.editor.generateSchemaMap === 'function') {
field.editor.generateSchemaMap({
config,
field,
i18n,
schemaMap,
schemaPath
});
}
break;
}
case 'tab':
{
const isNamedTab = tabHasName(field);
traverseFields({
config,
fields: field.fields,
i18n,
parentIndexPath: isNamedTab ? '' : indexPath,
parentSchemaPath: schemaPath,
schemaMap
});
break;
}
case 'tabs':
{
traverseFields({
config,
fields: field.tabs.map(tab => ({
...tab,
type: 'tab'
})),
i18n,
parentIndexPath: indexPath,
parentSchemaPath: schemaPath,
schemaMap
});
break;
}
}
}
};
//# sourceMappingURL=traverseFields.js.map

View File

@@ -0,0 +1,22 @@
'use strict';
const strip = require('./strip');
const { erase, cursor } = require('sisteransi');
const width = str => [...strip(str)].length;
/**
* @param {string} prompt
* @param {number} perLine
*/
module.exports = function(prompt, perLine) {
if (!perLine) return erase.line + cursor.to(0);
let rows = 0;
const lines = prompt.split(/\r?\n/);
for (let line of lines) {
rows += 1 + Math.floor(Math.max(width(line) - 1, 0) / perLine);
}
return erase.lines(rows);
};

View File

@@ -0,0 +1,72 @@
import { status as httpStatus } from 'http-status';
import { APIError } from '../../errors/index.js';
import { appendNonTrashedFilter } from '../../utilities/appendNonTrashedFilter.js';
import { commitTransaction } from '../../utilities/commitTransaction.js';
import { initTransaction } from '../../utilities/initTransaction.js';
import { killTransaction } from '../../utilities/killTransaction.js';
export const logoutOperation = async (incomingArgs)=>{
let args = incomingArgs;
const { allSessions, collection: { config: collectionConfig }, req: { user }, req } = incomingArgs;
if (!user) {
throw new APIError('No User', httpStatus.BAD_REQUEST);
}
if (user.collection !== collectionConfig.slug) {
throw new APIError('Incorrect collection', httpStatus.FORBIDDEN);
}
const shouldCommit = await initTransaction(req);
try {
if (collectionConfig.hooks?.afterLogout?.length) {
for (const hook of collectionConfig.hooks.afterLogout){
args = await hook({
collection: args.collection?.config,
context: req.context,
req
}) || args;
}
}
if (collectionConfig.auth.disableLocalStrategy !== true && collectionConfig.auth.useSessions) {
const where = appendNonTrashedFilter({
enableTrash: Boolean(collectionConfig.trash),
trash: false,
where: {
id: {
equals: user.id
}
}
});
const userWithSessions = await req.payload.db.findOne({
collection: collectionConfig.slug,
req,
where
});
if (!userWithSessions) {
throw new APIError('No User', httpStatus.BAD_REQUEST);
}
if (allSessions) {
userWithSessions.sessions = [];
} else {
const sessionsAfterLogout = (userWithSessions?.sessions || []).filter((s)=>s.id !== req?.user?._sid);
userWithSessions.sessions = sessionsAfterLogout;
}
// Prevent updatedAt from being updated when only removing a session
;
userWithSessions.updatedAt = null;
await req.payload.db.updateOne({
id: user.id,
collection: collectionConfig.slug,
data: userWithSessions,
req,
returning: false
});
}
if (shouldCommit) {
await commitTransaction(req);
}
return true;
} catch (error) {
await killTransaction(req);
throw error;
}
};
//# sourceMappingURL=logout.js.map

View File

@@ -0,0 +1,24 @@
import { getTranslation } from '@payloadcms/translations';
import { generateMetadata } from '../../utilities/meta.js';
export const generateListViewMetadata = async args => {
const {
collectionConfig,
config,
i18n
} = args;
let title = '';
const description = '';
const keywords = '';
if (collectionConfig) {
title = getTranslation(collectionConfig.labels.plural, i18n);
}
return generateMetadata({
...(config.admin.meta || {}),
description,
keywords,
serverURL: config.serverURL,
title,
...(collectionConfig?.admin?.meta || {})
});
};
//# sourceMappingURL=metadata.js.map

View File

@@ -0,0 +1 @@
export declare function useUniqueId(prefix: string, value?: string): string;

View File

@@ -0,0 +1,529 @@
function _typeof(o) {"@babel/helpers - typeof";return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {return typeof o;} : function (o) {return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;}, _typeof(o);}function ownKeys(e, r) {var t = Object.keys(e);if (Object.getOwnPropertySymbols) {var o = Object.getOwnPropertySymbols(e);r && (o = o.filter(function (r) {return Object.getOwnPropertyDescriptor(e, r).enumerable;})), t.push.apply(t, o);}return t;}function _objectSpread(e) {for (var r = 1; r < arguments.length; r++) {var t = null != arguments[r] ? arguments[r] : {};r % 2 ? ownKeys(Object(t), !0).forEach(function (r) {_defineProperty(e, r, t[r]);}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) {Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));});}return e;}function _defineProperty(obj, key, value) {key = _toPropertyKey(key);if (key in obj) {Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true });} else {obj[key] = value;}return obj;}function _toPropertyKey(t) {var i = _toPrimitive(t, "string");return "symbol" == _typeof(i) ? i : String(i);}function _toPrimitive(t, r) {if ("object" != _typeof(t) || !t) return t;var e = t[Symbol.toPrimitive];if (void 0 !== e) {var i = e.call(t, r || "default");if ("object" != _typeof(i)) return i;throw new TypeError("@@toPrimitive must return a primitive value.");}return ("string" === r ? String : Number)(t);}(function (_window$dateFns) {var __defProp = Object.defineProperty;
var __export = function __export(target, all) {
for (var name in all)
__defProp(target, name, {
get: all[name],
enumerable: true,
configurable: true,
set: function set(newValue) {return all[name] = function () {return newValue;};}
});
};
// lib/locale/en-US/_lib/formatDistance.mjs
var formatDistanceLocale = {
lessThanXSeconds: {
one: "less than a second",
other: "less than {{count}} seconds"
},
xSeconds: {
one: "1 second",
other: "{{count}} seconds"
},
halfAMinute: "half a minute",
lessThanXMinutes: {
one: "less than a minute",
other: "less than {{count}} minutes"
},
xMinutes: {
one: "1 minute",
other: "{{count}} minutes"
},
aboutXHours: {
one: "about 1 hour",
other: "about {{count}} hours"
},
xHours: {
one: "1 hour",
other: "{{count}} hours"
},
xDays: {
one: "1 day",
other: "{{count}} days"
},
aboutXWeeks: {
one: "about 1 week",
other: "about {{count}} weeks"
},
xWeeks: {
one: "1 week",
other: "{{count}} weeks"
},
aboutXMonths: {
one: "about 1 month",
other: "about {{count}} months"
},
xMonths: {
one: "1 month",
other: "{{count}} months"
},
aboutXYears: {
one: "about 1 year",
other: "about {{count}} years"
},
xYears: {
one: "1 year",
other: "{{count}} years"
},
overXYears: {
one: "over 1 year",
other: "over {{count}} years"
},
almostXYears: {
one: "almost 1 year",
other: "almost {{count}} years"
}
};
var formatDistance = function formatDistance(token, count, options) {
var result;
var tokenValue = formatDistanceLocale[token];
if (typeof tokenValue === "string") {
result = tokenValue;
} else if (count === 1) {
result = tokenValue.one;
} else {
result = tokenValue.other.replace("{{count}}", count.toString());
}
if (options !== null && options !== void 0 && options.addSuffix) {
if (options.comparison && options.comparison > 0) {
return "in " + result;
} else {
return result + " ago";
}
}
return result;
};
// lib/locale/en-US/_lib/formatRelative.mjs
var formatRelativeLocale = {
lastWeek: "'last' eeee 'at' p",
yesterday: "'yesterday at' p",
today: "'today at' p",
tomorrow: "'tomorrow at' p",
nextWeek: "eeee 'at' p",
other: "P"
};
var formatRelative = function formatRelative(token, _date, _baseDate, _options) {return formatRelativeLocale[token];};
// lib/locale/_lib/buildLocalizeFn.mjs
function buildLocalizeFn(args) {
return function (value, options) {
var context = options !== null && options !== void 0 && options.context ? String(options.context) : "standalone";
var valuesArray;
if (context === "formatting" && args.formattingValues) {
var defaultWidth = args.defaultFormattingWidth || args.defaultWidth;
var width = options !== null && options !== void 0 && options.width ? String(options.width) : defaultWidth;
valuesArray = args.formattingValues[width] || args.formattingValues[defaultWidth];
} else {
var _defaultWidth = args.defaultWidth;
var _width = options !== null && options !== void 0 && options.width ? String(options.width) : args.defaultWidth;
valuesArray = args.values[_width] || args.values[_defaultWidth];
}
var index = args.argumentCallback ? args.argumentCallback(value) : value;
return valuesArray[index];
};
}
// lib/locale/en-US/_lib/localize.mjs
var eraValues = {
narrow: ["B", "A"],
abbreviated: ["BC", "AD"],
wide: ["Before Christ", "Anno Domini"]
};
var quarterValues = {
narrow: ["1", "2", "3", "4"],
abbreviated: ["Q1", "Q2", "Q3", "Q4"],
wide: ["1st quarter", "2nd quarter", "3rd quarter", "4th quarter"]
};
var monthValues = {
narrow: ["J", "F", "M", "A", "M", "J", "J", "A", "S", "O", "N", "D"],
abbreviated: [
"Jan",
"Feb",
"Mar",
"Apr",
"May",
"Jun",
"Jul",
"Aug",
"Sep",
"Oct",
"Nov",
"Dec"],
wide: [
"January",
"February",
"March",
"April",
"May",
"June",
"July",
"August",
"September",
"October",
"November",
"December"]
};
var dayValues = {
narrow: ["S", "M", "T", "W", "T", "F", "S"],
short: ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"],
abbreviated: ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"],
wide: [
"Sunday",
"Monday",
"Tuesday",
"Wednesday",
"Thursday",
"Friday",
"Saturday"]
};
var dayPeriodValues = {
narrow: {
am: "a",
pm: "p",
midnight: "mi",
noon: "n",
morning: "morning",
afternoon: "afternoon",
evening: "evening",
night: "night"
},
abbreviated: {
am: "AM",
pm: "PM",
midnight: "midnight",
noon: "noon",
morning: "morning",
afternoon: "afternoon",
evening: "evening",
night: "night"
},
wide: {
am: "a.m.",
pm: "p.m.",
midnight: "midnight",
noon: "noon",
morning: "morning",
afternoon: "afternoon",
evening: "evening",
night: "night"
}
};
var formattingDayPeriodValues = {
narrow: {
am: "a",
pm: "p",
midnight: "mi",
noon: "n",
morning: "in the morning",
afternoon: "in the afternoon",
evening: "in the evening",
night: "at night"
},
abbreviated: {
am: "AM",
pm: "PM",
midnight: "midnight",
noon: "noon",
morning: "in the morning",
afternoon: "in the afternoon",
evening: "in the evening",
night: "at night"
},
wide: {
am: "a.m.",
pm: "p.m.",
midnight: "midnight",
noon: "noon",
morning: "in the morning",
afternoon: "in the afternoon",
evening: "in the evening",
night: "at night"
}
};
var ordinalNumber = function ordinalNumber(dirtyNumber, _options) {
var number = Number(dirtyNumber);
var rem100 = number % 100;
if (rem100 > 20 || rem100 < 10) {
switch (rem100 % 10) {
case 1:
return number + "st";
case 2:
return number + "nd";
case 3:
return number + "rd";
}
}
return number + "th";
};
var localize = {
ordinalNumber: ordinalNumber,
era: buildLocalizeFn({
values: eraValues,
defaultWidth: "wide"
}),
quarter: buildLocalizeFn({
values: quarterValues,
defaultWidth: "wide",
argumentCallback: function argumentCallback(quarter) {return quarter - 1;}
}),
month: buildLocalizeFn({
values: monthValues,
defaultWidth: "wide"
}),
day: buildLocalizeFn({
values: dayValues,
defaultWidth: "wide"
}),
dayPeriod: buildLocalizeFn({
values: dayPeriodValues,
defaultWidth: "wide",
formattingValues: formattingDayPeriodValues,
defaultFormattingWidth: "wide"
})
};
// lib/locale/_lib/buildMatchFn.mjs
function buildMatchFn(args) {
return function (string) {var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
var width = options.width;
var matchPattern = width && args.matchPatterns[width] || args.matchPatterns[args.defaultMatchWidth];
var matchResult = string.match(matchPattern);
if (!matchResult) {
return null;
}
var matchedString = matchResult[0];
var parsePatterns = width && args.parsePatterns[width] || args.parsePatterns[args.defaultParseWidth];
var key = Array.isArray(parsePatterns) ? findIndex(parsePatterns, function (pattern) {return pattern.test(matchedString);}) : findKey(parsePatterns, function (pattern) {return pattern.test(matchedString);});
var value;
value = args.valueCallback ? args.valueCallback(key) : key;
value = options.valueCallback ? options.valueCallback(value) : value;
var rest = string.slice(matchedString.length);
return { value: value, rest: rest };
};
}
var findKey = function findKey(object, predicate) {
for (var key in object) {
if (Object.prototype.hasOwnProperty.call(object, key) && predicate(object[key])) {
return key;
}
}
return;
};
var findIndex = function findIndex(array, predicate) {
for (var key = 0; key < array.length; key++) {
if (predicate(array[key])) {
return key;
}
}
return;
};
// lib/locale/_lib/buildMatchPatternFn.mjs
function buildMatchPatternFn(args) {
return function (string) {var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
var matchResult = string.match(args.matchPattern);
if (!matchResult)
return null;
var matchedString = matchResult[0];
var parseResult = string.match(args.parsePattern);
if (!parseResult)
return null;
var value = args.valueCallback ? args.valueCallback(parseResult[0]) : parseResult[0];
value = options.valueCallback ? options.valueCallback(value) : value;
var rest = string.slice(matchedString.length);
return { value: value, rest: rest };
};
}
// lib/locale/en-US/_lib/match.mjs
var matchOrdinalNumberPattern = /^(\d+)(th|st|nd|rd)?/i;
var parseOrdinalNumberPattern = /\d+/i;
var matchEraPatterns = {
narrow: /^(b|a)/i,
abbreviated: /^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,
wide: /^(before christ|before common era|anno domini|common era)/i
};
var parseEraPatterns = {
any: [/^b/i, /^(a|c)/i]
};
var matchQuarterPatterns = {
narrow: /^[1234]/i,
abbreviated: /^q[1234]/i,
wide: /^[1234](th|st|nd|rd)? quarter/i
};
var parseQuarterPatterns = {
any: [/1/i, /2/i, /3/i, /4/i]
};
var matchMonthPatterns = {
narrow: /^[jfmasond]/i,
abbreviated: /^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,
wide: /^(january|february|march|april|may|june|july|august|september|october|november|december)/i
};
var parseMonthPatterns = {
narrow: [
/^j/i,
/^f/i,
/^m/i,
/^a/i,
/^m/i,
/^j/i,
/^j/i,
/^a/i,
/^s/i,
/^o/i,
/^n/i,
/^d/i],
any: [
/^ja/i,
/^f/i,
/^mar/i,
/^ap/i,
/^may/i,
/^jun/i,
/^jul/i,
/^au/i,
/^s/i,
/^o/i,
/^n/i,
/^d/i]
};
var matchDayPatterns = {
narrow: /^[smtwf]/i,
short: /^(su|mo|tu|we|th|fr|sa)/i,
abbreviated: /^(sun|mon|tue|wed|thu|fri|sat)/i,
wide: /^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i
};
var parseDayPatterns = {
narrow: [/^s/i, /^m/i, /^t/i, /^w/i, /^t/i, /^f/i, /^s/i],
any: [/^su/i, /^m/i, /^tu/i, /^w/i, /^th/i, /^f/i, /^sa/i]
};
var matchDayPeriodPatterns = {
narrow: /^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,
any: /^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i
};
var parseDayPeriodPatterns = {
any: {
am: /^a/i,
pm: /^p/i,
midnight: /^mi/i,
noon: /^no/i,
morning: /morning/i,
afternoon: /afternoon/i,
evening: /evening/i,
night: /night/i
}
};
var match = {
ordinalNumber: buildMatchPatternFn({
matchPattern: matchOrdinalNumberPattern,
parsePattern: parseOrdinalNumberPattern,
valueCallback: function valueCallback(value) {return parseInt(value, 10);}
}),
era: buildMatchFn({
matchPatterns: matchEraPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseEraPatterns,
defaultParseWidth: "any"
}),
quarter: buildMatchFn({
matchPatterns: matchQuarterPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseQuarterPatterns,
defaultParseWidth: "any",
valueCallback: function valueCallback(index) {return index + 1;}
}),
month: buildMatchFn({
matchPatterns: matchMonthPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseMonthPatterns,
defaultParseWidth: "any"
}),
day: buildMatchFn({
matchPatterns: matchDayPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseDayPatterns,
defaultParseWidth: "any"
}),
dayPeriod: buildMatchFn({
matchPatterns: matchDayPeriodPatterns,
defaultMatchWidth: "any",
parsePatterns: parseDayPeriodPatterns,
defaultParseWidth: "any"
})
};
// lib/locale/_lib/buildFormatLongFn.mjs
function buildFormatLongFn(args) {
return function () {var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
var width = options.width ? String(options.width) : args.defaultWidth;
var format = args.formats[width] || args.formats[args.defaultWidth];
return format;
};
}
// lib/locale/en-GB/_lib/formatLong.mjs
var dateFormats = {
full: "EEEE, d MMMM yyyy",
long: "d MMMM yyyy",
medium: "d MMM yyyy",
short: "dd/MM/yyyy"
};
var timeFormats = {
full: "HH:mm:ss zzzz",
long: "HH:mm:ss z",
medium: "HH:mm:ss",
short: "HH:mm"
};
var dateTimeFormats = {
full: "{{date}} 'at' {{time}}",
long: "{{date}} 'at' {{time}}",
medium: "{{date}}, {{time}}",
short: "{{date}}, {{time}}"
};
var formatLong = {
date: buildFormatLongFn({
formats: dateFormats,
defaultWidth: "full"
}),
time: buildFormatLongFn({
formats: timeFormats,
defaultWidth: "full"
}),
dateTime: buildFormatLongFn({
formats: dateTimeFormats,
defaultWidth: "full"
})
};
// lib/locale/en-GB.mjs
var enGB = {
code: "en-GB",
formatDistance: formatDistance,
formatLong: formatLong,
formatRelative: formatRelative,
localize: localize,
match: match,
options: {
weekStartsOn: 1,
firstWeekContainsDate: 4
}
};
// lib/locale/en-GB/cdn.js
window.dateFns = _objectSpread(_objectSpread({},
window.dateFns), {}, {
locale: _objectSpread(_objectSpread({}, (_window$dateFns =
window.dateFns) === null || _window$dateFns === void 0 ? void 0 : _window$dateFns.locale), {}, {
enGB: enGB }) });
//# debugId=913268B1D7140CB964756e2164756e21
})();
//# sourceMappingURL=cdn.js.map

View File

@@ -0,0 +1,27 @@
import { operationToHookOperation } from './types.js';
// Implementation
export async function buildBeforeOperation(operationArgs) {
const { args, collection, operation, overrideAccess } = operationArgs;
let newArgs = args;
if (args.collection.config.hooks?.beforeOperation?.length) {
// TODO: v4 should not need this mapping
// Map the operation to the hook operation type for backward compatibility
const hookOperation = operationToHookOperation[operation];
for (const hook of args.collection.config.hooks.beforeOperation){
const hookResult = await hook({
args: newArgs,
collection,
context: args.req.context,
operation: hookOperation,
overrideAccess,
req: args.req
});
if (hookResult !== undefined) {
newArgs = hookResult;
}
}
}
return newArgs;
}
//# sourceMappingURL=buildBeforeOperation.js.map

View File

@@ -0,0 +1 @@
{"version":3,"sources":["../../../src/resolvers/globals/findVersions.ts"],"sourcesContent":["import type { GraphQLResolveInfo } from 'graphql'\nimport type { Document, SanitizedGlobalConfig, Where } from 'payload'\n\nimport { findVersionsOperationGlobal, isolateObjectProperty } from 'payload'\n\nimport type { Context } from '../types.js'\n\nimport { buildSelectForCollectionMany } from '../../utilities/select.js'\n\nexport type Resolver = (\n _: unknown,\n args: {\n fallbackLocale?: string\n limit?: number\n locale?: string\n page?: number\n pagination?: boolean\n select?: boolean\n sort?: string\n where: Where\n },\n context: Context,\n info: GraphQLResolveInfo,\n) => Promise<Document>\n\nexport function findVersions(globalConfig: SanitizedGlobalConfig): Resolver {\n return async function resolver(_, args, context, info) {\n const req = (context.req = isolateObjectProperty(context.req, [\n 'locale',\n 'fallbackLocale',\n 'transactionID',\n ]))\n const select = (context.select = args.select ? buildSelectForCollectionMany(info) : undefined)\n\n req.locale = args.locale || req.locale\n req.fallbackLocale = args.fallbackLocale || req.fallbackLocale\n req.query = req.query || {}\n\n const { sort } = args\n\n const options = {\n depth: 0,\n globalConfig,\n limit: args.limit,\n page: args.page,\n pagination: args.pagination,\n req,\n select,\n sort: sort && typeof sort === 'string' ? sort.split(',') : undefined,\n where: args.where,\n }\n\n const result = await findVersionsOperationGlobal(options)\n return result\n }\n}\n"],"names":["findVersionsOperationGlobal","isolateObjectProperty","buildSelectForCollectionMany","findVersions","globalConfig","resolver","_","args","context","info","req","select","undefined","locale","fallbackLocale","query","sort","options","depth","limit","page","pagination","split","where","result"],"mappings":"AAGA,SAASA,2BAA2B,EAAEC,qBAAqB,QAAQ,UAAS;AAI5E,SAASC,4BAA4B,QAAQ,4BAA2B;AAkBxE,OAAO,SAASC,aAAaC,YAAmC;IAC9D,OAAO,eAAeC,SAASC,CAAC,EAAEC,IAAI,EAAEC,OAAO,EAAEC,IAAI;QACnD,MAAMC,MAAOF,QAAQE,GAAG,GAAGT,sBAAsBO,QAAQE,GAAG,EAAE;YAC5D;YACA;YACA;SACD;QACD,MAAMC,SAAUH,QAAQG,MAAM,GAAGJ,KAAKI,MAAM,GAAGT,6BAA6BO,QAAQG;QAEpFF,IAAIG,MAAM,GAAGN,KAAKM,MAAM,IAAIH,IAAIG,MAAM;QACtCH,IAAII,cAAc,GAAGP,KAAKO,cAAc,IAAIJ,IAAII,cAAc;QAC9DJ,IAAIK,KAAK,GAAGL,IAAIK,KAAK,IAAI,CAAC;QAE1B,MAAM,EAAEC,IAAI,EAAE,GAAGT;QAEjB,MAAMU,UAAU;YACdC,OAAO;YACPd;YACAe,OAAOZ,KAAKY,KAAK;YACjBC,MAAMb,KAAKa,IAAI;YACfC,YAAYd,KAAKc,UAAU;YAC3BX;YACAC;YACAK,MAAMA,QAAQ,OAAOA,SAAS,WAAWA,KAAKM,KAAK,CAAC,OAAOV;YAC3DW,OAAOhB,KAAKgB,KAAK;QACnB;QAEA,MAAMC,SAAS,MAAMxB,4BAA4BiB;QACjD,OAAOO;IACT;AACF"}

View File

@@ -0,0 +1,80 @@
import Benchmark from "benchmark";
import { z } from "zod/v3";
const doubleSuite = new Benchmark.Suite("z.union: double");
const manySuite = new Benchmark.Suite("z.union: many");
const aSchema = z.object({
type: z.literal("a"),
});
const objA = {
type: "a",
};
const bSchema = z.object({
type: z.literal("b"),
});
const objB = {
type: "b",
};
const cSchema = z.object({
type: z.literal("c"),
});
const objC = {
type: "c",
};
const dSchema = z.object({
type: z.literal("d"),
});
const double = z.union([aSchema, bSchema]);
const many = z.union([aSchema, bSchema, cSchema, dSchema]);
doubleSuite
.add("valid: a", () => {
double.parse(objA);
})
.add("valid: b", () => {
double.parse(objB);
})
.add("invalid: null", () => {
try {
double.parse(null);
} catch (_err) {}
})
.add("invalid: wrong shape", () => {
try {
double.parse(objC);
} catch (_err) {}
})
.on("cycle", (e: Benchmark.Event) => {
console.log(`${(doubleSuite as any).name}: ${e.target}`);
});
manySuite
.add("valid: a", () => {
many.parse(objA);
})
.add("valid: c", () => {
many.parse(objC);
})
.add("invalid: null", () => {
try {
many.parse(null);
} catch (_err) {}
})
.add("invalid: wrong shape", () => {
try {
many.parse({ type: "unknown" });
} catch (_err) {}
})
.on("cycle", (e: Benchmark.Event) => {
console.log(`${(manySuite as any).name}: ${e.target}`);
});
export default {
suites: [doubleSuite, manySuite],
};

View File

@@ -0,0 +1,59 @@
import { AnthropicAiOptions } from '@sentry/core';
export declare const instrumentAnthropicAi: ((options?: AnthropicAiOptions | undefined) => import("@opentelemetry/instrumentation").Instrumentation<import("@opentelemetry/instrumentation").InstrumentationConfig>) & {
id: string;
};
/**
* Adds Sentry tracing instrumentation for the Anthropic AI SDK.
*
* This integration is enabled by default.
*
* When configured, this integration automatically instruments Anthropic AI SDK client instances
* to capture telemetry data following OpenTelemetry Semantic Conventions for Generative AI.
*
* @example
* ```javascript
* import * as Sentry from '@sentry/node';
*
* Sentry.init({
* integrations: [Sentry.anthropicAIIntegration()],
* });
* ```
*
* ## Options
*
* - `recordInputs`: Whether to record prompt messages (default: respects `sendDefaultPii` client option)
* - `recordOutputs`: Whether to record response text (default: respects `sendDefaultPii` client option)
*
* ### Default Behavior
*
* By default, the integration will:
* - Record inputs and outputs ONLY if `sendDefaultPii` is set to `true` in your Sentry client options
* - Otherwise, inputs and outputs are NOT recorded unless explicitly enabled
*
* @example
* ```javascript
* // Record inputs and outputs when sendDefaultPii is false
* Sentry.init({
* integrations: [
* Sentry.anthropicAIIntegration({
* recordInputs: true,
* recordOutputs: true
* })
* ],
* });
*
* // Never record inputs/outputs regardless of sendDefaultPii
* Sentry.init({
* sendDefaultPii: true,
* integrations: [
* Sentry.anthropicAIIntegration({
* recordInputs: false,
* recordOutputs: false
* })
* ],
* });
* ```
*
*/
export declare const anthropicAIIntegration: (options?: AnthropicAiOptions | undefined) => import("@sentry/core").Integration;
//# sourceMappingURL=index.d.ts.map

View File

@@ -0,0 +1,5 @@
var convert = require('./convert'),
func = convert('floor', require('../floor'));
func.placeholder = require('./placeholder');
module.exports = func;

View File

@@ -0,0 +1,10 @@
"use strict";
exports.subMonths = void 0;
var _index = require("../subMonths.js");
var _index2 = require("./_lib/convertToFP.js"); // This file is generated automatically by `scripts/build/fp.ts`. Please, don't change it.
const subMonths = (exports.subMonths = (0, _index2.convertToFP)(
_index.subMonths,
2,
));

View File

@@ -0,0 +1 @@
{"version":3,"file":"countDistinct.d.ts","sourceRoot":"","sources":["../../src/postgres/countDistinct.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAuB,aAAa,EAAE,MAAM,YAAY,CAAA;AAEpE,eAAO,MAAM,aAAa,EAAE,aAqC3B,CAAA"}

View File

@@ -0,0 +1 @@
{"version":3,"file":"profiling.js","sources":["../../src/profiling.ts"],"sourcesContent":["import { getClient } from './currentScopes';\nimport { DEBUG_BUILD } from './debug-build';\nimport type { Profiler, ProfilingIntegration } from './types-hoist/profiling';\nimport { debug } from './utils/debug-logger';\n\nfunction isProfilingIntegrationWithProfiler(\n integration: ProfilingIntegration | undefined,\n): integration is ProfilingIntegration {\n return (\n !!integration &&\n typeof integration['_profiler'] !== 'undefined' &&\n typeof integration['_profiler']['start'] === 'function' &&\n typeof integration['_profiler']['stop'] === 'function'\n );\n}\n/**\n * Starts the Sentry continuous profiler.\n * This mode is exclusive with the transaction profiler and will only work if the profilesSampleRate is set to a falsy value.\n * In continuous profiling mode, the profiler will keep reporting profile chunks to Sentry until it is stopped, which allows for continuous profiling of the application.\n */\nfunction startProfiler(): void {\n const client = getClient();\n if (!client) {\n DEBUG_BUILD && debug.warn('No Sentry client available, profiling is not started');\n return;\n }\n\n const integration = client.getIntegrationByName<ProfilingIntegration>('ProfilingIntegration');\n\n if (!integration) {\n DEBUG_BUILD && debug.warn('ProfilingIntegration is not available');\n return;\n }\n\n if (!isProfilingIntegrationWithProfiler(integration)) {\n DEBUG_BUILD && debug.warn('Profiler is not available on profiling integration.');\n return;\n }\n\n integration._profiler.start();\n}\n\n/**\n * Stops the Sentry continuous profiler.\n * Calls to stop will stop the profiler and flush the currently collected profile data to Sentry.\n */\nfunction stopProfiler(): void {\n const client = getClient();\n if (!client) {\n DEBUG_BUILD && debug.warn('No Sentry client available, profiling is not started');\n return;\n }\n\n const integration = client.getIntegrationByName<ProfilingIntegration>('ProfilingIntegration');\n if (!integration) {\n DEBUG_BUILD && debug.warn('ProfilingIntegration is not available');\n return;\n }\n\n if (!isProfilingIntegrationWithProfiler(integration)) {\n DEBUG_BUILD && debug.warn('Profiler is not available on profiling integration.');\n return;\n }\n\n integration._profiler.stop();\n}\n\n/**\n * Profiler namespace for controlling the profiler in 'manual' mode.\n *\n * Requires the `nodeProfilingIntegration` from the `@sentry/profiling-node` package.\n */\nexport const profiler: Profiler = {\n startProfiler,\n stopProfiler,\n};\n"],"names":[],"mappings":";;;;AAKA,SAAS,kCAAkC;AAC3C,EAAE,WAAW;AACb,EAAuC;AACvC,EAAE;AACF,IAAI,CAAC,CAAC,WAAA;AACN,IAAI,OAAO,WAAW,CAAC,WAAW,CAAA,KAAM,WAAA;AACxC,IAAI,OAAO,WAAW,CAAC,WAAW,CAAC,CAAC,OAAO,CAAA,KAAM,UAAA;AACjD,IAAI,OAAO,WAAW,CAAC,WAAW,CAAC,CAAC,MAAM,MAAM;AAChD;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS,aAAa,GAAS;AAC/B,EAAE,MAAM,MAAA,GAAS,SAAS,EAAE;AAC5B,EAAE,IAAI,CAAC,MAAM,EAAE;AACf,IAAI,eAAe,KAAK,CAAC,IAAI,CAAC,sDAAsD,CAAC;AACrF,IAAI;AACJ,EAAE;;AAEF,EAAE,MAAM,cAAc,MAAM,CAAC,oBAAoB,CAAuB,sBAAsB,CAAC;;AAE/F,EAAE,IAAI,CAAC,WAAW,EAAE;AACpB,IAAI,eAAe,KAAK,CAAC,IAAI,CAAC,uCAAuC,CAAC;AACtE,IAAI;AACJ,EAAE;;AAEF,EAAE,IAAI,CAAC,kCAAkC,CAAC,WAAW,CAAC,EAAE;AACxD,IAAI,eAAe,KAAK,CAAC,IAAI,CAAC,qDAAqD,CAAC;AACpF,IAAI;AACJ,EAAE;;AAEF,EAAE,WAAW,CAAC,SAAS,CAAC,KAAK,EAAE;AAC/B;;AAEA;AACA;AACA;AACA;AACA,SAAS,YAAY,GAAS;AAC9B,EAAE,MAAM,MAAA,GAAS,SAAS,EAAE;AAC5B,EAAE,IAAI,CAAC,MAAM,EAAE;AACf,IAAI,eAAe,KAAK,CAAC,IAAI,CAAC,sDAAsD,CAAC;AACrF,IAAI;AACJ,EAAE;;AAEF,EAAE,MAAM,cAAc,MAAM,CAAC,oBAAoB,CAAuB,sBAAsB,CAAC;AAC/F,EAAE,IAAI,CAAC,WAAW,EAAE;AACpB,IAAI,eAAe,KAAK,CAAC,IAAI,CAAC,uCAAuC,CAAC;AACtE,IAAI;AACJ,EAAE;;AAEF,EAAE,IAAI,CAAC,kCAAkC,CAAC,WAAW,CAAC,EAAE;AACxD,IAAI,eAAe,KAAK,CAAC,IAAI,CAAC,qDAAqD,CAAC;AACpF,IAAI;AACJ,EAAE;;AAEF,EAAE,WAAW,CAAC,SAAS,CAAC,IAAI,EAAE;AAC9B;;AAEA;AACA;AACA;AACA;AACA;AACO,MAAM,QAAQ,GAAa;AAClC,EAAE,aAAa;AACf,EAAE,YAAY;AACd;;;;"}

View File

@@ -0,0 +1,58 @@
<h1 align="center">Welcome to atomic-sleep ⏱️</h1>
<p>
<img alt="Version" src="https://img.shields.io/badge/version-1.0.0-blue.svg?cacheSeconds=2592000" />
<a href="#" target="_blank">
<img alt="License: MIT" src="https://img.shields.io/badge/License-MIT-yellow.svg" />
</a>
<a href="https://twitter.com/davidmarkclem" target="_blank">
<img alt="Twitter: davidmarkclem" src="https://img.shields.io/twitter/follow/davidmarkclem.svg?style=social" />
</a>
</p>
> Zero CPU overhead, zero dependency, true event-loop blocking sleep
## Usage
```js
const sleep = require('atomic-sleep')
console.time('sleep')
setTimeout(() => { console.timeEnd('sleep') }, 100)
sleep(1000)
```
The `console.time` will report a time of just over 1000ms despite the `setTimeout`
being 100ms. This is because the event loop is paused for 1000ms and the setTimeout
fires immediately after the event loop is no longer blocked (as more than 100ms have passed).
## Install
```sh
npm install
```
## Run tests
```sh
npm test
```
## Support
Node and Browser versions that support both `SharedArrayBuffer` and `Atomics` will have (virtually) zero CPU overhead sleep.
For Node, Atomic Sleep can provide zero CPU overhead sleep from Node 8 and up.
For browser support see https://caniuse.com/#feat=sharedarraybuffer and https://caniuse.com/#feat=mdn-javascript_builtins_atomics.
For older Node versions and olders browsers we fall back to blocking the event loop in a way that will cause a CPU spike.
## Author
👤 **David Mark Clements (@davidmarkclem)**
* Twitter: [@davidmarkclem](https://twitter.com/davidmarkclem)
* Github: [@davidmarkclements](https://github.com/davidmarkclements)

View File

@@ -0,0 +1 @@
{"version":3,"file":"crypto.d.ts","sourceRoot":"","sources":["../../src/auth/crypto.ts"],"names":[],"mappings":"AAIA,wBAAgB,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAU5C;AAED,wBAAgB,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAS5C"}

View File

@@ -0,0 +1,123 @@
# OpenTelemetry Postgres Instrumentation for Node.js
[![NPM Published Version][npm-img]][npm-url]
[![Apache License][license-image]][license-image]
This module provides automatic instrumentation for the [`pg`](https://github.com/brianc/node-postgres)module, which may be loaded using the [`@opentelemetry/sdk-trace-node`](https://github.com/open-telemetry/opentelemetry-js/tree/main/packages/opentelemetry-sdk-trace-node) package and is included in the [`@opentelemetry/auto-instrumentations-node`](https://www.npmjs.com/package/@opentelemetry/auto-instrumentations-node) bundle.
If total installation size is not constrained, it is recommended to use the [`@opentelemetry/auto-instrumentations-node`](https://www.npmjs.com/package/@opentelemetry/auto-instrumentations-node) bundle with [@opentelemetry/sdk-node](`https://www.npmjs.com/package/@opentelemetry/sdk-node`) for the most seamless instrumentation experience.
Compatible with OpenTelemetry JS API and SDK `1.0+`.
## Installation
```bash
npm install --save @opentelemetry/instrumentation-pg
```
### Supported Versions
- [`pg`](https://www.npmjs.com/package/pg) versions `>=8.0.3 <9`
- [`pg-pool`](https://www.npmjs.com/package/pg-pool) versions `>=2.0.0 <4`
## Usage
```js
const { PgInstrumentation } = require('@opentelemetry/instrumentation-pg');
const { NodeTracerProvider } = require('@opentelemetry/sdk-trace-node');
const { registerInstrumentations } = require('@opentelemetry/instrumentation');
const provider = new NodeTracerProvider();
provider.register();
registerInstrumentations({
instrumentations: [
new PgInstrumentation(),
],
});
```
PgInstrumentation contains both pg and [`pg.Pool`](https://node-postgres.com/api/pool) so it will be instrumented automatically.
### Span Types Created
This instrumentation creates the following span types:
| Span Name | Description | When Created |
| --------- | ----------- | ------------ |
| `pg.query:<OPERATION> <database>` | Database query execution | When `client.query()` is called |
| `pg.connect` | Client connection to database | When `new Client().connect()` is called directly |
| `pg-pool.connect` | Pool connection acquisition wait time | When acquiring a connection from `pg-pool` |
The `pg-pool.connect` spans measure the time spent waiting to acquire a connection from the pool. This can be valuable for identifying connection pool exhaustion or sizing issues. However, in high-throughput scenarios where connections are readily available, these spans may add noise with minimal diagnostic value. Consider using the `requireParentSpan` option or sampling strategies if pool connect spans become excessive.
### PostgreSQL Instrumentation Options
PostgreSQL instrumentation has few options available to choose from. You can set the following:
| Options | Type | Description |
| ------- | ---- | ----------- |
| [`enhancedDatabaseReporting`](./src/types.ts#L30) | `boolean` | If true, additional information about query parameters and results will be attached (as `attributes`) to spans representing database operations |
| `requestHook` | `PgInstrumentationExecutionRequestHook` (function) | Function for adding custom span attributes using information about the query being issued and the db to which it's directed |
| `responseHook` | `PgInstrumentationExecutionResponseHook` (function) | Function for adding custom span attributes from db response |
| `requireParentSpan` | `boolean` | If true, requires a parent span to create new spans (default false) |
| `addSqlCommenterCommentToQueries` | `boolean` | If true, adds [sqlcommenter](https://github.com/open-telemetry/opentelemetry-sqlcommenter) specification compliant comment to queries with tracing context (default false). _NOTE: A comment will not be added to queries that already contain `--` or `/* ... */` in them, even if these are not actually part of comments_ |
| `ignoreConnectSpans` | `boolean` | If true, `pg.connect` and `pg-pool.connect` spans will not be created. Query spans and pool metrics are still recorded (default false) |
## Semantic Conventions
Prior to version `0.55.0`, this instrumentation created spans and metrics targeting an experimental semantic convention Version 1.27.0.
Database semantic conventions (semconv) were stabilized in v1.34.0, and a [migration process](https://github.com/open-telemetry/semantic-conventions/blob/main/docs/non-normative/db-migration.md) was defined.
`@opentelemetry/instrumentation-pg` versions 0.55.0 and later include support for migrating to stable Database semantic conventions, as described below.
The intent is to provide an approximate 6 month time window for users of this instrumentation to migrate to the new Database semconv, after which a new minor version will use the new semconv by default and drop support for the old semconv.
To select which semconv version(s) is emitted from this instrumentation, use the `OTEL_SEMCONV_STABILITY_OPT_IN` environment variable.
- `database`: emit the new (stable) v1.34.0+ semantics
- `database/dup`: emit **both** the old v1.27.0 and the new (stable) v1.34.0+ semantics
- By default, if `OTEL_SEMCONV_STABILITY_OPT_IN` includes neither of the above tokens, the old v1.27.0 semconv is used.
### Attributes collected
| v1.27.0 semconv | v1.34.0 semconv | Short Description |
| ----------------------- | ----------------------------------------------- | ------------------------------------------------------------------------------------------ |
| `db.connection_string` | Removed | String used to connect to the database |
| `db.user` | Removed | User used to connect to the database |
| `db.name` | Removed, integrated into the new `db.namespace` | The name of the database. |
| (not included) | `db.namespace` | The name of the database, fully qualified within the server address and port. |
| `db.statement` | `db.query.text` | The database query being executed. |
| `db.system` | `db.system.name` | The database management system (DBMS) product as identified by the client instrumentation. |
| `net.peer.port` | `server.port` | Remote port number. |
| `net.peer.name` | `server.address` | Remote hostname or similar. |
Metrics Exported:
- [`db.client.operation.duration`](https://github.com/open-telemetry/semantic-conventions/blob/main/docs/database/database-metrics.md#metric-dbclientoperationduration)
### Upgrading Semantic Conventions
When upgrading to the new semantic conventions, it is recommended to do so in the following order:
1. Upgrade `@opentelemetry/opentelemetry-instrumentation-pg` to the latest version
2. Set `OTEL_SEMCONV_STABILITY_OPT_IN=database/dup` to emit both old and new semantic conventions
3. Modify alerts, dashboards, metrics, and other processes to expect the new semantic conventions
4. Set `OTEL_SEMCONV_STABILITY_OPT_IN=database` to emit only the new semantic conventions
This will cause both the old and new semantic conventions to be emitted during the transition period.
## Useful links
- For more information on OpenTelemetry, visit: <https://opentelemetry.io/>
- For more about OpenTelemetry JavaScript: <https://github.com/open-telemetry/opentelemetry-js>
- For help or feedback on this project, join us in [GitHub Discussions][discussions-url]
## License
Apache 2.0 - See [LICENSE][license-url] for more information.
[discussions-url]: https://github.com/open-telemetry/opentelemetry-js/discussions
[license-url]: https://github.com/open-telemetry/opentelemetry-js-contrib/blob/main/LICENSE
[license-image]: https://img.shields.io/badge/license-Apache_2.0-green.svg?style=flat
[npm-url]: https://www.npmjs.com/package/@opentelemetry/instrumentation-pg
[npm-img]: https://badge.fury.io/js/%40opentelemetry%2Finstrumentation-pg.svg

View File

@@ -0,0 +1 @@
{"version":3,"file":"index.js","names":["c","_c","useParams","useNextParams","React","createContext","use","Context","ParamsProvider","t0","$","children","params","t1","_jsx","value"],"sources":["../../../src/providers/Params/index.tsx"],"sourcesContent":["'use client'\n\nimport { useParams as useNextParams } from 'next/navigation.js'\nimport React, { createContext, use } from 'react'\n\nexport type Params = ReturnType<typeof useNextParams>\ninterface IParamsContext extends Params {}\n\nconst Context = createContext<IParamsContext>({} as IParamsContext)\n\n/**\n * @deprecated\n * The ParamsProvider is deprecated and will be removed in the next major release. Instead, use the `useParams` hook from `next/navigation` directly. See https://github.com/payloadcms/payload/pull/9581.\n * @example\n * ```tsx\n * import { useParams } from 'next/navigation'\n * ```\n */\nexport const ParamsProvider: React.FC<{ children?: React.ReactNode }> = ({ children }) => {\n const params = useNextParams()\n return <Context value={params}>{children}</Context>\n}\n\n/**\n * @deprecated\n * The `useParams` hook is deprecated and will be removed in the next major release. Instead, use the `useParams` hook from `next/navigation` directly. See https://github.com/payloadcms/payload/pull/9581.\n * @example\n * ```tsx\n * import { useParams } from 'next/navigation'\n * ```\n */\nexport const useParams = (): IParamsContext => use(Context)\n"],"mappings":"AAAA;;AAAA,SAAAA,CAAA,IAAAC,EAAA;;AAEA,SAASC,SAAA,IAAaC,aAAa,QAAQ;AAC3C,OAAOC,KAAA,IAASC,aAAa,EAAEC,GAAG,QAAQ;AAK1C,MAAMC,OAAA,gBAAUF,aAAA,CAA8B,CAAC;AAE/C;;;;;;;;AAQA,OAAO,MAAMG,cAAA,GAA2DC,EAAA;EAAA,MAAAC,CAAA,GAAAT,EAAA;EAAC;IAAAU;EAAA,IAAAF,EAAY;EACnF,MAAAG,MAAA,GAAeT,aAAA;EAAA,IAAAU,EAAA;EAAA,IAAAH,CAAA,QAAAC,QAAA,IAAAD,CAAA,QAAAE,MAAA;IACRC,EAAA,GAAAC,IAAA,CAAAP,OAAA;MAAAQ,KAAA,EAAgBH,MAAA;MAAAD;IAAA,C;;;;;;;SAAhBE,E;CACT;AAEA;;;;;;;;AAQA,OAAO,MAAMX,SAAA,GAAYA,CAAA,KAAsBI,GAAA,CAAIC,OAAA","ignoreList":[]}

View File

@@ -0,0 +1 @@
{"version":3,"file":"logout.js","names":["logoutData: LogoutOptions"],"sources":["../../../../src/rest/commands/auth/logout.ts"],"sourcesContent":["import type { LogoutOptions } from '../../../index.js';\nimport type { RestCommand } from '../../types.js';\n\n/**\n * Invalidate the refresh token thus destroying the user's session.\n *\n * @param options Optional logout settings.\n *\n * @returns Empty body.\n */\nexport const logout =\n\t<Schema>(options: LogoutOptions = {}): RestCommand<void, Schema> =>\n\t() => {\n\t\tconst logoutData: LogoutOptions = {\n\t\t\tmode: options.mode ?? 'cookie',\n\t\t};\n\n\t\tif (logoutData.mode === 'json' && options.refresh_token) {\n\t\t\tlogoutData['refresh_token'] = options.refresh_token;\n\t\t}\n\n\t\treturn {\n\t\t\tpath: '/auth/logout',\n\t\t\tmethod: 'POST',\n\t\t\tbody: JSON.stringify(logoutData),\n\t\t};\n\t};\n"],"mappings":"AAUA,MAAa,GACH,EAAyB,EAAE,OAC9B,CACL,IAAMA,EAA4B,CACjC,KAAM,EAAQ,MAAQ,SACtB,CAMD,OAJI,EAAW,OAAS,QAAU,EAAQ,gBACzC,EAAW,cAAmB,EAAQ,eAGhC,CACN,KAAM,eACN,OAAQ,OACR,KAAM,KAAK,UAAU,EAAW,CAChC"}

View File

@@ -0,0 +1,5 @@
var convert = require('./convert'),
func = convert('assignInWith', require('../assignInWith'));
func.placeholder = require('./placeholder');
module.exports = func;

View File

@@ -0,0 +1 @@
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/preferences/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,aAAa,CAAA;AACxD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAA;AAEvD,MAAM,MAAM,iBAAiB,GAAG;IAC9B,GAAG,EAAE,MAAM,CAAA;IACX,cAAc,CAAC,EAAE,OAAO,CAAA;IACxB,GAAG,EAAE,cAAc,CAAA;IACnB,IAAI,EAAE,cAAc,CAAC,MAAM,CAAC,CAAA;CAC7B,CAAA;AAED,MAAM,MAAM,uBAAuB,GAAG;IAAE,KAAK,EAAE,OAAO,CAAA;CAAE,GAAG,iBAAiB,CAAA;AAE5E,MAAM,MAAM,oBAAoB,GAAG,MAAM,EAAE,CAAA;AAE3C,MAAM,MAAM,eAAe,GAAG,KAAK,CAAC;IAClC,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAAA;CACvB,CAAC,CAAA;AAEF,MAAM,MAAM,uBAAuB,GAAG;IACpC,SAAS,EAAE,oBAAoB,CAAA;IAC/B,QAAQ,EAAE,MAAM,CAAA;CACjB,CAAA;AAED,MAAM,MAAM,iBAAiB,GAAG;IAC9B,CAAC,GAAG,EAAE,MAAM,GAAG,uBAAuB,CAAA;CACvC,CAAA;AAED,MAAM,MAAM,mBAAmB,GAAG;IAChC,MAAM,EAAE,iBAAiB,CAAA;CAC1B,CAAA;AAED,MAAM,MAAM,gBAAgB,GAAG;IAC7B,QAAQ,EAAE,MAAM,CAAA;IAChB,MAAM,EAAE,OAAO,CAAA;CAChB,CAAA;AAED,MAAM,MAAM,qBAAqB,GAAG;IAClC,OAAO,CAAC,EAAE,gBAAgB,EAAE,CAAA;IAC5B,YAAY,CAAC,EAAE,SAAS,GAAG,cAAc,CAAA;IACzC,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,YAAY,CAAC,EAAE,SAAS,GAAG,MAAM,CAAA;IACjC,MAAM,CAAC,EAAE,qBAAqB,CAAA;IAC9B,IAAI,CAAC,EAAE,MAAM,CAAA;CACd,CAAA"}

View File

@@ -0,0 +1,9 @@
// This file is generated automatically by `scripts/build/fp.ts`. Please, don't change it.
import { getDate as fn } from "../getDate.js";
import { convertToFP } from "./_lib/convertToFP.js";
export const getDateWithOptions = convertToFP(fn, 2);
// Fallback for modularized imports:
export default getDateWithOptions;

View File

@@ -0,0 +1 @@
{"version":3,"file":"folder-lock.js","sources":["../../../src/icons/folder-lock.ts"],"sourcesContent":["import createLucideIcon from '../createLucideIcon';\n\n/**\n * @component @name FolderLock\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview ![img](data:image/svg+xml;base64,PHN2ZyAgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIgogIHdpZHRoPSIyNCIKICBoZWlnaHQ9IjI0IgogIHZpZXdCb3g9IjAgMCAyNCAyNCIKICBmaWxsPSJub25lIgogIHN0cm9rZT0iIzAwMCIgc3R5bGU9ImJhY2tncm91bmQtY29sb3I6ICNmZmY7IGJvcmRlci1yYWRpdXM6IDJweCIKICBzdHJva2Utd2lkdGg9IjIiCiAgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIgogIHN0cm9rZS1saW5lam9pbj0icm91bmQiCj4KICA8cmVjdCB3aWR0aD0iOCIgaGVpZ2h0PSI1IiB4PSIxNCIgeT0iMTciIHJ4PSIxIiAvPgogIDxwYXRoIGQ9Ik0xMCAyMEg0YTIgMiAwIDAgMS0yLTJWNWEyIDIgMCAwIDEgMi0yaDMuOWEyIDIgMCAwIDEgMS42OS45bC44MSAxLjJhMiAyIDAgMCAwIDEuNjcuOUgyMGEyIDIgMCAwIDEgMiAydjIuNSIgLz4KICA8cGF0aCBkPSJNMjAgMTd2LTJhMiAyIDAgMSAwLTQgMHYyIiAvPgo8L3N2Zz4K) - https://lucide.dev/icons/folder-lock\n * @see https://lucide.dev/guide/packages/lucide-react - Documentation\n *\n * @param {Object} props - Lucide icons props and any valid SVG attribute\n * @returns {JSX.Element} JSX Element\n *\n */\nconst FolderLock = createLucideIcon('FolderLock', [\n ['rect', { width: '8', height: '5', x: '14', y: '17', rx: '1', key: '19aais' }],\n [\n 'path',\n {\n d: 'M10 20H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H20a2 2 0 0 1 2 2v2.5',\n key: '1w6v7t',\n },\n ],\n ['path', { d: 'M20 17v-2a2 2 0 1 0-4 0v2', key: 'pwaxnr' }],\n]);\n\nexport default FolderLock;\n"],"names":[],"mappings":";;;;;;;;;AAaM,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAa,iBAAiB,YAAc,CAAA,CAAA,CAAA;AAAA,CAAA,CAChD,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAE,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAO,KAAK,CAAQ,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,CAAG,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAM,GAAG,CAAM,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAI,CAAK,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAC9E,CAAA,CAAA;AAAA,CAAA,CAAA,CAAA,CACE,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAAA,CACA,CAAA,CAAA,CAAA,CAAA;AAAA,CACE,CAAA,CAAA,CAAA,CAAA,CAAA,CAAG,EAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAAA,CACH,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,EAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAAA,CACP,CAAA,CAAA,CAAA,CAAA;AAAA,CACF,CAAA,CAAA,CAAA;AAAA,CAAA,CACA,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAA6B,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA;AAC5D,CAAC,CAAA,CAAA;;"}

View File

@@ -0,0 +1,24 @@
{
"name": "pump",
"version": "3.0.3",
"repository": "git://github.com/mafintosh/pump.git",
"license": "MIT",
"description": "pipe streams together and close all of them if one of them closes",
"browser": {
"fs": false
},
"keywords": [
"streams",
"pipe",
"destroy",
"callback"
],
"author": "Mathias Buus Madsen <mathiasbuus@gmail.com>",
"dependencies": {
"end-of-stream": "^1.1.0",
"once": "^1.3.1"
},
"scripts": {
"test": "node test-browser.js && node test-node.js"
}
}

View File

@@ -0,0 +1,23 @@
{
"name": "@webassemblyjs/ieee754",
"version": "1.13.2",
"description": "IEEE754 decoder and encoder",
"license": "MIT",
"main": "lib/index.js",
"module": "esm/index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"repository": {
"type": "git",
"url": "https://github.com/xtuc/webassemblyjs.git",
"directory": "packages/ieee754"
},
"publishConfig": {
"access": "public"
},
"dependencies": {
"@xtuc/ieee754": "^1.2.0"
},
"gitHead": "897aeb784f042a46a00626f1d1cca96159aa5db3"
}

View File

@@ -0,0 +1,3 @@
export type PickProperties<Type, Value> = {
[Key in keyof Type as Type[Key] extends Value ? Key : never]: Type[Key];
};

View File

@@ -0,0 +1,36 @@
"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
const internal_table_1 = __importDefault(require("./internalTable/internal-table"));
const table_helpers_1 = require("./utils/table-helpers");
class Table {
constructor(options) {
this.table = new internal_table_1.default(options);
}
addColumn(column) {
this.table.addColumn(column);
return this;
}
addColumns(columns) {
this.table.addColumns(columns);
return this;
}
addRow(text, rowOptions) {
this.table.addRow(text, (0, table_helpers_1.convertRawRowOptionsToStandard)(rowOptions));
return this;
}
addRows(toBeInsertedRows, rowOptions) {
this.table.addRows(toBeInsertedRows, (0, table_helpers_1.convertRawRowOptionsToStandard)(rowOptions));
return this;
}
printTable() {
const tableRendered = this.table.renderTable();
console.log(tableRendered);
}
render() {
return this.table.renderTable();
}
}
exports.default = Table;

View File

@@ -0,0 +1,29 @@
import { formatDistance } from "./bn/_lib/formatDistance.mjs";
import { formatLong } from "./bn/_lib/formatLong.mjs";
import { formatRelative } from "./bn/_lib/formatRelative.mjs";
import { localize } from "./bn/_lib/localize.mjs";
import { match } from "./bn/_lib/match.mjs";
/**
* @category Locales
* @summary Bengali locale.
* @language Bengali
* @iso-639-2 ben
* @author Touhidur Rahman [@touhidrahman](https://github.com/touhidrahman)
* @author Farhad Yasir [@nutboltu](https://github.com/nutboltu)
*/
export const bn = {
code: "bn",
formatDistance: formatDistance,
formatLong: formatLong,
formatRelative: formatRelative,
localize: localize,
match: match,
options: {
weekStartsOn: 0 /* Sunday */,
firstWeekContainsDate: 1,
},
};
// Fallback for modularized imports:
export default bn;

View File

@@ -0,0 +1 @@
{"version":3,"file":"diamond-minus.js","sources":["../../../src/icons/diamond-minus.ts"],"sourcesContent":["import createLucideIcon from '../createLucideIcon';\n\n/**\n * @component @name DiamondMinus\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview ![img](data:image/svg+xml;base64,PHN2ZyAgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIgogIHdpZHRoPSIyNCIKICBoZWlnaHQ9IjI0IgogIHZpZXdCb3g9IjAgMCAyNCAyNCIKICBmaWxsPSJub25lIgogIHN0cm9rZT0iIzAwMCIgc3R5bGU9ImJhY2tncm91bmQtY29sb3I6ICNmZmY7IGJvcmRlci1yYWRpdXM6IDJweCIKICBzdHJva2Utd2lkdGg9IjIiCiAgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIgogIHN0cm9rZS1saW5lam9pbj0icm91bmQiCj4KICA8cGF0aCBkPSJNMi43IDEwLjNhMi40MSAyLjQxIDAgMCAwIDAgMy40MWw3LjU5IDcuNTlhMi40MSAyLjQxIDAgMCAwIDMuNDEgMGw3LjU5LTcuNTlhMi40MSAyLjQxIDAgMCAwIDAtMy40MUwxMy43IDIuNzFhMi40MSAyLjQxIDAgMCAwLTMuNDEgMHoiIC8+CiAgPHBhdGggZD0iTTggMTJoOCIgLz4KPC9zdmc+) - https://lucide.dev/icons/diamond-minus\n * @see https://lucide.dev/guide/packages/lucide-react - Documentation\n *\n * @param {Object} props - Lucide icons props and any valid SVG attribute\n * @returns {JSX.Element} JSX Element\n *\n */\nconst DiamondMinus = createLucideIcon('DiamondMinus', [\n [\n 'path',\n {\n d: 'M2.7 10.3a2.41 2.41 0 0 0 0 3.41l7.59 7.59a2.41 2.41 0 0 0 3.41 0l7.59-7.59a2.41 2.41 0 0 0 0-3.41L13.7 2.71a2.41 2.41 0 0 0-3.41 0z',\n key: '1ey20j',\n },\n ],\n ['path', { d: 'M8 12h8', key: '1wcyev' }],\n]);\n\nexport default DiamondMinus;\n"],"names":[],"mappings":";;;;;;;;;AAaM,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAe,iBAAiB,cAAgB,CAAA,CAAA,CAAA;AAAA,CACpD,CAAA,CAAA;AAAA,CAAA,CAAA,CAAA,CACE,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAAA,CACA,CAAA,CAAA,CAAA,CAAA;AAAA,CACE,CAAA,CAAA,CAAA,CAAA,CAAA,CAAG,EAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAAA,CACH,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,EAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAAA,CACP,CAAA,CAAA,CAAA,CAAA;AAAA,CACF,CAAA,CAAA,CAAA;AAAA,CAAA,CACA,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAW,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA;AAC1C,CAAC,CAAA,CAAA;;"}

View File

@@ -0,0 +1,25 @@
/**
* @license lucide-react v0.441.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
import createLucideIcon from '../createLucideIcon.js';
const Container = createLucideIcon("Container", [
[
"path",
{
d: "M22 7.7c0-.6-.4-1.2-.8-1.5l-6.3-3.9a1.72 1.72 0 0 0-1.7 0l-10.3 6c-.5.2-.9.8-.9 1.4v6.6c0 .5.4 1.2.8 1.5l6.3 3.9a1.72 1.72 0 0 0 1.7 0l10.3-6c.5-.3.9-1 .9-1.5Z",
key: "1t2lqe"
}
],
["path", { d: "M10 21.9V14L2.1 9.1", key: "o7czzq" }],
["path", { d: "m10 14 11.9-6.9", key: "zm5e20" }],
["path", { d: "M14 19.8v-8.1", key: "159ecu" }],
["path", { d: "M18 17.5V9.4", key: "11uown" }]
]);
export { Container as default };
//# sourceMappingURL=container.js.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"internal-types.js","sourceRoot":"","sources":["../../src/internal-types.ts"],"names":[],"mappings":";;;AAsCA;;;GAGG;AACU,QAAA,aAAa,GAAkB,MAAM,CAAC,mBAAmB,CAAC,CAAC","sourcesContent":["/*\n * Copyright The OpenTelemetry Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport type { Middleware, ParameterizedContext, DefaultState } from 'koa';\nimport type * as Router from '@koa/router';\n\n/**\n * Type compatibility note:\n *\n * This package uses @types/koa@3.x, but @types/koa__router@12.x depends on\n * @types/koa@2.x. This creates type conflicts when working with router middleware.\n * At runtime, koa@3.x is used throughout, so all methods exist and work correctly.\n *\n * The type casts in instrumentation.ts are necessary to bridge this gap.\n *\n * TODO: Remove type casts when @types/koa__router@13+ with @types/koa@3.x support is available\n */\n\nexport type KoaContext = ParameterizedContext<\n DefaultState,\n Router.RouterParamContext\n>;\nexport type KoaMiddleware = Middleware<DefaultState, KoaContext> & {\n router?: Router;\n};\n\n/**\n * This symbol is used to mark a Koa layer as being already instrumented\n * since its possible to use a given layer multiple times (ex: middlewares)\n */\nexport const kLayerPatched: unique symbol = Symbol('koa-layer-patched');\n\nexport type KoaPatchedMiddleware = KoaMiddleware & {\n [kLayerPatched]?: boolean;\n};\n"]}

View File

@@ -0,0 +1,144 @@
"use strict";
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
var desc = Object.getOwnPropertyDescriptor(m, k);
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
desc = { enumerable: true, get: function() { return m[k]; } };
}
Object.defineProperty(o, k2, desc);
}) : (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
o[k2] = m[k];
}));
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
Object.defineProperty(o, "default", { enumerable: true, value: v });
}) : function(o, v) {
o["default"] = v;
});
var __importStar = (this && this.__importStar) || function (mod) {
if (mod && mod.__esModule) return mod;
var result = {};
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
__setModuleDefault(result, mod);
return result;
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.default = default_1;
const util = __importStar(require("../core/util.cjs"));
const error = () => {
const Sizable = {
string: { unit: "знаци", verb: "да имаат" },
file: { unit: "бајти", verb: "да имаат" },
array: { unit: "ставки", verb: "да имаат" },
set: { unit: "ставки", verb: "да имаат" },
};
function getSizing(origin) {
return Sizable[origin] ?? null;
}
const parsedType = (data) => {
const t = typeof data;
switch (t) {
case "number": {
return Number.isNaN(data) ? "NaN" : "број";
}
case "object": {
if (Array.isArray(data)) {
return "низа";
}
if (data === null) {
return "null";
}
if (Object.getPrototypeOf(data) !== Object.prototype && data.constructor) {
return data.constructor.name;
}
}
}
return t;
};
const Nouns = {
regex: "внес",
email: "адреса на е-пошта",
url: "URL",
emoji: "емоџи",
uuid: "UUID",
uuidv4: "UUIDv4",
uuidv6: "UUIDv6",
nanoid: "nanoid",
guid: "GUID",
cuid: "cuid",
cuid2: "cuid2",
ulid: "ULID",
xid: "XID",
ksuid: "KSUID",
datetime: "ISO датум и време",
date: "ISO датум",
time: "ISO време",
duration: "ISO времетраење",
ipv4: "IPv4 адреса",
ipv6: "IPv6 адреса",
cidrv4: "IPv4 опсег",
cidrv6: "IPv6 опсег",
base64: "base64-енкодирана низа",
base64url: "base64url-енкодирана низа",
json_string: "JSON низа",
e164: "E.164 број",
jwt: "JWT",
template_literal: "внес",
};
return (issue) => {
switch (issue.code) {
case "invalid_type":
return `Грешен внес: се очекува ${issue.expected}, примено ${parsedType(issue.input)}`;
// return `Invalid input: expected ${issue.expected}, received ${util.getParsedType(issue.input)}`;
case "invalid_value":
if (issue.values.length === 1)
return `Invalid input: expected ${util.stringifyPrimitive(issue.values[0])}`;
return `Грешана опција: се очекува една ${util.joinValues(issue.values, "|")}`;
case "too_big": {
const adj = issue.inclusive ? "<=" : "<";
const sizing = getSizing(issue.origin);
if (sizing)
return `Премногу голем: се очекува ${issue.origin ?? "вредноста"} да има ${adj}${issue.maximum.toString()} ${sizing.unit ?? "елементи"}`;
return `Премногу голем: се очекува ${issue.origin ?? "вредноста"} да биде ${adj}${issue.maximum.toString()}`;
}
case "too_small": {
const adj = issue.inclusive ? ">=" : ">";
const sizing = getSizing(issue.origin);
if (sizing) {
return `Премногу мал: се очекува ${issue.origin} да има ${adj}${issue.minimum.toString()} ${sizing.unit}`;
}
return `Премногу мал: се очекува ${issue.origin} да биде ${adj}${issue.minimum.toString()}`;
}
case "invalid_format": {
const _issue = issue;
if (_issue.format === "starts_with") {
return `Неважечка низа: мора да започнува со "${_issue.prefix}"`;
}
if (_issue.format === "ends_with")
return `Неважечка низа: мора да завршува со "${_issue.suffix}"`;
if (_issue.format === "includes")
return `Неважечка низа: мора да вклучува "${_issue.includes}"`;
if (_issue.format === "regex")
return `Неважечка низа: мора да одгоара на патернот ${_issue.pattern}`;
return `Invalid ${Nouns[_issue.format] ?? issue.format}`;
}
case "not_multiple_of":
return `Грешен број: мора да биде делив со ${issue.divisor}`;
case "unrecognized_keys":
return `${issue.keys.length > 1 ? "Непрепознаени клучеви" : "Непрепознаен клуч"}: ${util.joinValues(issue.keys, ", ")}`;
case "invalid_key":
return `Грешен клуч во ${issue.origin}`;
case "invalid_union":
return "Грешен внес";
case "invalid_element":
return `Грешна вредност во ${issue.origin}`;
default:
return `Грешен внес`;
}
};
};
function default_1() {
return {
localeError: error(),
};
}

View File

@@ -0,0 +1,571 @@
/**
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*
*/
'use strict';
var utils = require('@lexical/utils');
var lexical = require('lexical');
/**
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*
*/
// Do not require this module directly! Use normal `invariant` calls.
function formatDevErrorMessage(message) {
throw new Error(message);
}
const SUPPORTED_URL_PROTOCOLS = new Set(['http:', 'https:', 'mailto:', 'sms:', 'tel:']);
/** @noInheritDoc */
class LinkNode extends lexical.ElementNode {
/** @internal */
/** @internal */
/** @internal */
/** @internal */
static getType() {
return 'link';
}
static clone(node) {
return new LinkNode(node.__url, {
rel: node.__rel,
target: node.__target,
title: node.__title
}, node.__key);
}
constructor(url = '', attributes = {}, key) {
super(key);
const {
target = null,
rel = null,
title = null
} = attributes;
this.__url = url;
this.__target = target;
this.__rel = rel;
this.__title = title;
}
createDOM(config) {
const element = document.createElement('a');
this.updateLinkDOM(null, element, config);
utils.addClassNamesToElement(element, config.theme.link);
return element;
}
updateLinkDOM(prevNode, anchor, config) {
if (utils.isHTMLAnchorElement(anchor)) {
if (!prevNode || prevNode.__url !== this.__url) {
anchor.href = this.sanitizeUrl(this.__url);
}
for (const attr of ['target', 'rel', 'title']) {
const key = `__${attr}`;
const value = this[key];
if (!prevNode || prevNode[key] !== value) {
if (value) {
anchor[attr] = value;
} else {
anchor.removeAttribute(attr);
}
}
}
}
}
updateDOM(prevNode, anchor, config) {
this.updateLinkDOM(prevNode, anchor, config);
return false;
}
static importDOM() {
return {
a: node => ({
conversion: $convertAnchorElement,
priority: 1
})
};
}
static importJSON(serializedNode) {
return $createLinkNode().updateFromJSON(serializedNode);
}
updateFromJSON(serializedNode) {
return super.updateFromJSON(serializedNode).setURL(serializedNode.url).setRel(serializedNode.rel || null).setTarget(serializedNode.target || null).setTitle(serializedNode.title || null);
}
sanitizeUrl(url) {
url = formatUrl(url);
try {
const parsedUrl = new URL(formatUrl(url));
// eslint-disable-next-line no-script-url
if (!SUPPORTED_URL_PROTOCOLS.has(parsedUrl.protocol)) {
return 'about:blank';
}
} catch (_unused) {
return url;
}
return url;
}
exportJSON() {
return {
...super.exportJSON(),
rel: this.getRel(),
target: this.getTarget(),
title: this.getTitle(),
url: this.getURL()
};
}
getURL() {
return this.getLatest().__url;
}
setURL(url) {
const writable = this.getWritable();
writable.__url = url;
return writable;
}
getTarget() {
return this.getLatest().__target;
}
setTarget(target) {
const writable = this.getWritable();
writable.__target = target;
return writable;
}
getRel() {
return this.getLatest().__rel;
}
setRel(rel) {
const writable = this.getWritable();
writable.__rel = rel;
return writable;
}
getTitle() {
return this.getLatest().__title;
}
setTitle(title) {
const writable = this.getWritable();
writable.__title = title;
return writable;
}
insertNewAfter(_, restoreSelection = true) {
const linkNode = $createLinkNode(this.__url, {
rel: this.__rel,
target: this.__target,
title: this.__title
});
this.insertAfter(linkNode, restoreSelection);
return linkNode;
}
canInsertTextBefore() {
return false;
}
canInsertTextAfter() {
return false;
}
canBeEmpty() {
return false;
}
isInline() {
return true;
}
extractWithChild(child, selection, destination) {
if (!lexical.$isRangeSelection(selection)) {
return false;
}
const anchorNode = selection.anchor.getNode();
const focusNode = selection.focus.getNode();
return this.isParentOf(anchorNode) && this.isParentOf(focusNode) && selection.getTextContent().length > 0;
}
isEmailURI() {
return this.__url.startsWith('mailto:');
}
isWebSiteURI() {
return this.__url.startsWith('https://') || this.__url.startsWith('http://');
}
}
function $convertAnchorElement(domNode) {
let node = null;
if (utils.isHTMLAnchorElement(domNode)) {
const content = domNode.textContent;
if (content !== null && content !== '' || domNode.children.length > 0) {
node = $createLinkNode(domNode.getAttribute('href') || '', {
rel: domNode.getAttribute('rel'),
target: domNode.getAttribute('target'),
title: domNode.getAttribute('title')
});
}
}
return {
node
};
}
/**
* Takes a URL and creates a LinkNode.
* @param url - The URL the LinkNode should direct to.
* @param attributes - Optional HTML a tag attributes \\{ target, rel, title \\}
* @returns The LinkNode.
*/
function $createLinkNode(url = '', attributes) {
return lexical.$applyNodeReplacement(new LinkNode(url, attributes));
}
/**
* Determines if node is a LinkNode.
* @param node - The node to be checked.
* @returns true if node is a LinkNode, false otherwise.
*/
function $isLinkNode(node) {
return node instanceof LinkNode;
}
// Custom node type to override `canInsertTextAfter` that will
// allow typing within the link
class AutoLinkNode extends LinkNode {
/** @internal */
/** Indicates whether the autolink was ever unlinked. **/
constructor(url = '', attributes = {}, key) {
super(url, attributes, key);
this.__isUnlinked = attributes.isUnlinked !== undefined && attributes.isUnlinked !== null ? attributes.isUnlinked : false;
}
static getType() {
return 'autolink';
}
static clone(node) {
return new AutoLinkNode(node.__url, {
isUnlinked: node.__isUnlinked,
rel: node.__rel,
target: node.__target,
title: node.__title
}, node.__key);
}
getIsUnlinked() {
return this.__isUnlinked;
}
setIsUnlinked(value) {
const self = this.getWritable();
self.__isUnlinked = value;
return self;
}
createDOM(config) {
if (this.__isUnlinked) {
return document.createElement('span');
} else {
return super.createDOM(config);
}
}
updateDOM(prevNode, anchor, config) {
return super.updateDOM(prevNode, anchor, config) || prevNode.__isUnlinked !== this.__isUnlinked;
}
static importJSON(serializedNode) {
return $createAutoLinkNode().updateFromJSON(serializedNode);
}
updateFromJSON(serializedNode) {
return super.updateFromJSON(serializedNode).setIsUnlinked(serializedNode.isUnlinked || false);
}
static importDOM() {
// TODO: Should link node should handle the import over autolink?
return null;
}
exportJSON() {
return {
...super.exportJSON(),
isUnlinked: this.__isUnlinked
};
}
insertNewAfter(selection, restoreSelection = true) {
const element = this.getParentOrThrow().insertNewAfter(selection, restoreSelection);
if (lexical.$isElementNode(element)) {
const linkNode = $createAutoLinkNode(this.__url, {
isUnlinked: this.__isUnlinked,
rel: this.__rel,
target: this.__target,
title: this.__title
});
element.append(linkNode);
return linkNode;
}
return null;
}
}
/**
* Takes a URL and creates an AutoLinkNode. AutoLinkNodes are generally automatically generated
* during typing, which is especially useful when a button to generate a LinkNode is not practical.
* @param url - The URL the LinkNode should direct to.
* @param attributes - Optional HTML a tag attributes. \\{ target, rel, title \\}
* @returns The LinkNode.
*/
function $createAutoLinkNode(url = '', attributes) {
return lexical.$applyNodeReplacement(new AutoLinkNode(url, attributes));
}
/**
* Determines if node is an AutoLinkNode.
* @param node - The node to be checked.
* @returns true if node is an AutoLinkNode, false otherwise.
*/
function $isAutoLinkNode(node) {
return node instanceof AutoLinkNode;
}
const TOGGLE_LINK_COMMAND = lexical.createCommand('TOGGLE_LINK_COMMAND');
function $getPointNode(point, offset) {
if (point.type === 'element') {
const node = point.getNode();
if (!lexical.$isElementNode(node)) {
formatDevErrorMessage(`$getPointNode: element point is not an ElementNode`);
}
const childNode = node.getChildren()[point.offset + offset];
return childNode || null;
}
return null;
}
/**
* Preserve the logical start/end of a RangeSelection in situations where
* the point is an element that may be reparented in the callback.
*
* @param $fn The function to run
* @returns The result of the callback
*/
function $withSelectedNodes($fn) {
const initialSelection = lexical.$getSelection();
if (!lexical.$isRangeSelection(initialSelection)) {
return $fn();
}
const normalized = lexical.$normalizeSelection__EXPERIMENTAL(initialSelection);
const isBackwards = normalized.isBackward();
const anchorNode = $getPointNode(normalized.anchor, isBackwards ? -1 : 0);
const focusNode = $getPointNode(normalized.focus, isBackwards ? 0 : -1);
const rval = $fn();
if (anchorNode || focusNode) {
const updatedSelection = lexical.$getSelection();
if (lexical.$isRangeSelection(updatedSelection)) {
const finalSelection = updatedSelection.clone();
if (anchorNode) {
const anchorParent = anchorNode.getParent();
if (anchorParent) {
finalSelection.anchor.set(anchorParent.getKey(), anchorNode.getIndexWithinParent() + (isBackwards ? 1 : 0), 'element');
}
}
if (focusNode) {
const focusParent = focusNode.getParent();
if (focusParent) {
finalSelection.focus.set(focusParent.getKey(), focusNode.getIndexWithinParent() + (isBackwards ? 0 : 1), 'element');
}
}
lexical.$setSelection(lexical.$normalizeSelection__EXPERIMENTAL(finalSelection));
}
}
return rval;
}
/**
* Generates or updates a LinkNode. It can also delete a LinkNode if the URL is null,
* but saves any children and brings them up to the parent node.
* @param url - The URL the link directs to.
* @param attributes - Optional HTML a tag attributes. \\{ target, rel, title \\}
*/
function $toggleLink(url, attributes = {}) {
const {
target,
title
} = attributes;
const rel = attributes.rel === undefined ? 'noreferrer' : attributes.rel;
const selection = lexical.$getSelection();
if (selection === null || !lexical.$isRangeSelection(selection) && !lexical.$isNodeSelection(selection)) {
return;
}
if (lexical.$isNodeSelection(selection)) {
const nodes = selection.getNodes();
if (nodes.length === 0) {
return;
}
// Handle all selected nodes
nodes.forEach(node => {
if (url === null) {
// Remove link
const linkParent = utils.$findMatchingParent(node, parent => !$isAutoLinkNode(parent) && $isLinkNode(parent));
if (linkParent) {
linkParent.insertBefore(node);
if (linkParent.getChildren().length === 0) {
linkParent.remove();
}
}
} else {
// Add/Update link
const existingLink = utils.$findMatchingParent(node, parent => !$isAutoLinkNode(parent) && $isLinkNode(parent));
if (existingLink) {
existingLink.setURL(url);
if (target !== undefined) {
existingLink.setTarget(target);
}
if (rel !== undefined) {
existingLink.setRel(rel);
}
} else {
const linkNode = $createLinkNode(url, {
rel,
target
});
node.insertBefore(linkNode);
linkNode.append(node);
}
}
});
return;
}
// Handle RangeSelection
const nodes = selection.extract();
if (url === null) {
// Remove LinkNodes
nodes.forEach(node => {
const parentLink = utils.$findMatchingParent(node, parent => !$isAutoLinkNode(parent) && $isLinkNode(parent));
if (parentLink) {
const children = parentLink.getChildren();
for (let i = 0; i < children.length; i++) {
parentLink.insertBefore(children[i]);
}
parentLink.remove();
}
});
return;
}
const updatedNodes = new Set();
const updateLinkNode = linkNode => {
if (updatedNodes.has(linkNode.getKey())) {
return;
}
updatedNodes.add(linkNode.getKey());
linkNode.setURL(url);
if (target !== undefined) {
linkNode.setTarget(target);
}
if (rel !== undefined) {
linkNode.setRel(rel);
}
if (title !== undefined) {
linkNode.setTitle(title);
}
};
// Add or merge LinkNodes
if (nodes.length === 1) {
const firstNode = nodes[0];
// if the first node is a LinkNode or if its
// parent is a LinkNode, we update the URL, target and rel.
const linkNode = $getAncestor(firstNode, $isLinkNode);
if (linkNode !== null) {
return updateLinkNode(linkNode);
}
}
$withSelectedNodes(() => {
let linkNode = null;
for (const node of nodes) {
if (!node.isAttached()) {
continue;
}
const parentLinkNode = $getAncestor(node, $isLinkNode);
if (parentLinkNode) {
updateLinkNode(parentLinkNode);
continue;
}
if (lexical.$isElementNode(node)) {
if (!node.isInline()) {
// Ignore block nodes, if there are any children we will see them
// later and wrap in a new LinkNode
continue;
}
if ($isLinkNode(node)) {
// If it's not an autolink node and we don't already have a LinkNode
// in this block then we can update it and re-use it
if (!$isAutoLinkNode(node) && (linkNode === null || !linkNode.getParentOrThrow().isParentOf(node))) {
updateLinkNode(node);
linkNode = node;
continue;
}
// Unwrap LinkNode, we already have one or it's an AutoLinkNode
for (const child of node.getChildren()) {
node.insertBefore(child);
}
node.remove();
continue;
}
}
const prevLinkNode = node.getPreviousSibling();
if ($isLinkNode(prevLinkNode) && prevLinkNode.is(linkNode)) {
prevLinkNode.append(node);
continue;
}
linkNode = $createLinkNode(url, {
rel,
target,
title
});
node.insertAfter(linkNode);
linkNode.append(node);
}
});
}
/** @deprecated renamed to {@link $toggleLink} by @lexical/eslint-plugin rules-of-lexical */
const toggleLink = $toggleLink;
function $getAncestor(node, predicate) {
let parent = node;
while (parent !== null && parent.getParent() !== null && !predicate(parent)) {
parent = parent.getParentOrThrow();
}
return predicate(parent) ? parent : null;
}
const PHONE_NUMBER_REGEX = /^\+?[0-9\s()-]{5,}$/;
/**
* Formats a URL string by adding appropriate protocol if missing
*
* @param url - URL to format
* @returns Formatted URL with appropriate protocol
*/
function formatUrl(url) {
// Check if URL already has a protocol
if (url.match(/^[a-z][a-z0-9+.-]*:/i)) {
// URL already has a protocol, leave it as is
return url;
}
// Check if it's a relative path (starting with '/', '.', or '#')
else if (url.match(/^[/#.]/)) {
// Relative path, leave it as is
return url;
}
// Check for email address
else if (url.includes('@')) {
return `mailto:${url}`;
}
// Check for phone number
else if (PHONE_NUMBER_REGEX.test(url)) {
return `tel:${url}`;
}
// For everything else, return with https:// prefix
return `https://${url}`;
}
exports.$createAutoLinkNode = $createAutoLinkNode;
exports.$createLinkNode = $createLinkNode;
exports.$isAutoLinkNode = $isAutoLinkNode;
exports.$isLinkNode = $isLinkNode;
exports.$toggleLink = $toggleLink;
exports.AutoLinkNode = AutoLinkNode;
exports.LinkNode = LinkNode;
exports.TOGGLE_LINK_COMMAND = TOGGLE_LINK_COMMAND;
exports.formatUrl = formatUrl;
exports.toggleLink = toggleLink;

View File

@@ -0,0 +1,50 @@
/* eslint-disable yoda */
'use strict';
const isFullwidthCodePoint = codePoint => {
if (Number.isNaN(codePoint)) {
return false;
}
// Code points are derived from:
// http://www.unix.org/Public/UNIDATA/EastAsianWidth.txt
if (
codePoint >= 0x1100 && (
codePoint <= 0x115F || // Hangul Jamo
codePoint === 0x2329 || // LEFT-POINTING ANGLE BRACKET
codePoint === 0x232A || // RIGHT-POINTING ANGLE BRACKET
// CJK Radicals Supplement .. Enclosed CJK Letters and Months
(0x2E80 <= codePoint && codePoint <= 0x3247 && codePoint !== 0x303F) ||
// Enclosed CJK Letters and Months .. CJK Unified Ideographs Extension A
(0x3250 <= codePoint && codePoint <= 0x4DBF) ||
// CJK Unified Ideographs .. Yi Radicals
(0x4E00 <= codePoint && codePoint <= 0xA4C6) ||
// Hangul Jamo Extended-A
(0xA960 <= codePoint && codePoint <= 0xA97C) ||
// Hangul Syllables
(0xAC00 <= codePoint && codePoint <= 0xD7A3) ||
// CJK Compatibility Ideographs
(0xF900 <= codePoint && codePoint <= 0xFAFF) ||
// Vertical Forms
(0xFE10 <= codePoint && codePoint <= 0xFE19) ||
// CJK Compatibility Forms .. Small Form Variants
(0xFE30 <= codePoint && codePoint <= 0xFE6B) ||
// Halfwidth and Fullwidth Forms
(0xFF01 <= codePoint && codePoint <= 0xFF60) ||
(0xFFE0 <= codePoint && codePoint <= 0xFFE6) ||
// Kana Supplement
(0x1B000 <= codePoint && codePoint <= 0x1B001) ||
// Enclosed Ideographic Supplement
(0x1F200 <= codePoint && codePoint <= 0x1F251) ||
// CJK Unified Ideographs Extension B .. Tertiary Ideographic Plane
(0x20000 <= codePoint && codePoint <= 0x3FFFD)
)
) {
return true;
}
return false;
};
module.exports = isFullwidthCodePoint;
module.exports.default = isFullwidthCodePoint;

View File

@@ -0,0 +1,22 @@
import { expect, test } from "vitest";
import { parsedType } from "../../../locales/en.js";
test("parsedType", () => {
expect(parsedType("string")).toBe("string");
expect(parsedType(1)).toBe("number");
expect(parsedType(true)).toBe("boolean");
expect(parsedType(null)).toBe("null");
expect(parsedType(undefined)).toBe("undefined");
expect(parsedType([])).toBe("array");
expect(parsedType({})).toBe("object");
expect(parsedType(new Date())).toBe("Date");
expect(parsedType(new Map())).toBe("Map");
expect(parsedType(new Set())).toBe("Set");
expect(parsedType(new Error())).toBe("Error");
const nullPrototype = Object.create(null);
expect(parsedType(nullPrototype)).toBe("object");
const doubleNullPrototype = Object.create(Object.create(null));
expect(parsedType(doubleNullPrototype)).toBe("object");
});

View File

@@ -0,0 +1,6 @@
import { ElementContainer } from '../element-container';
import { Context } from '../../core/context';
export declare class LIElementContainer extends ElementContainer {
readonly value: number;
constructor(context: Context, element: HTMLLIElement);
}

View File

@@ -0,0 +1 @@
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/providers/DocumentTitle/index.tsx"],"names":[],"mappings":"AASA,KAAK,qBAAqB,GAAG;IAC3B,gBAAgB,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAA;IACzC,KAAK,EAAE,MAAM,CAAA;CACd,CAAA;AAID,eAAO,MAAM,gBAAgB,QAAO,qBAAkD,CAAA;AAEtF,eAAO,MAAM,qBAAqB,EAAE,KAAK,CAAC,EAAE,CAAC;IAC3C,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAA;CAC1B,CAoCA,CAAA"}

View File

@@ -0,0 +1,191 @@
/*
MIT License http://www.opensource.org/licenses/mit-license.php
Author Tobias Koppers @sokra and Zackary Jackson @ScriptedAlchemy
*/
"use strict";
const { RawSource } = require("webpack-sources");
const Module = require("../Module");
const {
JAVASCRIPT_TYPE,
JAVASCRIPT_TYPES
} = require("../ModuleSourceTypeConstants");
const { WEBPACK_MODULE_TYPE_FALLBACK } = require("../ModuleTypeConstants");
const RuntimeGlobals = require("../RuntimeGlobals");
const Template = require("../Template");
const makeSerializable = require("../util/makeSerializable");
const FallbackItemDependency = require("./FallbackItemDependency");
/** @typedef {import("../config/defaults").WebpackOptionsNormalizedWithDefaults} WebpackOptions */
/** @typedef {import("../Chunk")} Chunk */
/** @typedef {import("../Compilation")} Compilation */
/** @typedef {import("../Module").BuildCallback} BuildCallback */
/** @typedef {import("../Module").CodeGenerationContext} CodeGenerationContext */
/** @typedef {import("../Module").CodeGenerationResult} CodeGenerationResult */
/** @typedef {import("../Module").LibIdentOptions} LibIdentOptions */
/** @typedef {import("../Module").LibIdent} LibIdent */
/** @typedef {import("../Module").NameForCondition} NameForCondition */
/** @typedef {import("../Module").NeedBuildCallback} NeedBuildCallback */
/** @typedef {import("../Module").NeedBuildContext} NeedBuildContext */
/** @typedef {import("../Module").Sources} Sources */
/** @typedef {import("../Module").SourceTypes} SourceTypes */
/** @typedef {import("../RequestShortener")} RequestShortener */
/** @typedef {import("../ResolverFactory").ResolverWithOptions} ResolverWithOptions */
/** @typedef {import("../serialization/ObjectMiddleware").ObjectDeserializerContext} ObjectDeserializerContext */
/** @typedef {import("../serialization/ObjectMiddleware").ObjectSerializerContext} ObjectSerializerContext */
/** @typedef {import("../util/fs").InputFileSystem} InputFileSystem */
/** @typedef {import("./RemoteModule").ExternalRequests} ExternalRequests */
const RUNTIME_REQUIREMENTS = new Set([RuntimeGlobals.module]);
class FallbackModule extends Module {
/**
* @param {ExternalRequests} requests list of requests to choose one
*/
constructor(requests) {
super(WEBPACK_MODULE_TYPE_FALLBACK);
this.requests = requests;
this._identifier = `fallback ${this.requests.join(" ")}`;
}
/**
* @returns {string} a unique identifier of the module
*/
identifier() {
return this._identifier;
}
/**
* @param {RequestShortener} requestShortener the request shortener
* @returns {string} a user readable identifier of the module
*/
readableIdentifier(requestShortener) {
return this._identifier;
}
/**
* @param {LibIdentOptions} options options
* @returns {LibIdent | null} an identifier for library inclusion
*/
libIdent(options) {
return `${this.layer ? `(${this.layer})/` : ""}webpack/container/fallback/${
this.requests[0]
}/and ${this.requests.length - 1} more`;
}
/**
* @param {Chunk} chunk the chunk which condition should be checked
* @param {Compilation} compilation the compilation
* @returns {boolean} true, if the chunk is ok for the module
*/
chunkCondition(chunk, { chunkGraph }) {
return chunkGraph.getNumberOfEntryModules(chunk) > 0;
}
/**
* @param {NeedBuildContext} context context info
* @param {NeedBuildCallback} callback callback function, returns true, if the module needs a rebuild
* @returns {void}
*/
needBuild(context, callback) {
callback(null, !this.buildInfo);
}
/**
* @param {WebpackOptions} options webpack options
* @param {Compilation} compilation the compilation
* @param {ResolverWithOptions} resolver the resolver
* @param {InputFileSystem} fs the file system
* @param {BuildCallback} callback callback function
* @returns {void}
*/
build(options, compilation, resolver, fs, callback) {
this.buildMeta = {};
this.buildInfo = {
strict: true
};
this.clearDependenciesAndBlocks();
for (const request of this.requests) {
this.addDependency(new FallbackItemDependency(request));
}
callback();
}
/**
* @param {string=} type the source type for which the size should be estimated
* @returns {number} the estimated size of the module (must be non-zero)
*/
size(type) {
return this.requests.length * 5 + 42;
}
/**
* @returns {SourceTypes} types available (do not mutate)
*/
getSourceTypes() {
return JAVASCRIPT_TYPES;
}
/**
* @param {CodeGenerationContext} context context for code generation
* @returns {CodeGenerationResult} result
*/
codeGeneration({ runtimeTemplate, moduleGraph, chunkGraph }) {
const ids = this.dependencies.map((dep) =>
chunkGraph.getModuleId(/** @type {Module} */ (moduleGraph.getModule(dep)))
);
const code = Template.asString([
`var ids = ${JSON.stringify(ids)};`,
"var error, result, i = 0;",
`var loop = ${runtimeTemplate.basicFunction("next", [
"while(i < ids.length) {",
Template.indent([
`try { next = ${RuntimeGlobals.require}(ids[i++]); } catch(e) { return handleError(e); }`,
"if(next) return next.then ? next.then(handleResult, handleError) : handleResult(next);"
]),
"}",
"if(error) throw error;"
])}`,
`var handleResult = ${runtimeTemplate.basicFunction("result", [
"if(result) return result;",
"return loop();"
])};`,
`var handleError = ${runtimeTemplate.basicFunction("e", [
"error = e;",
"return loop();"
])};`,
"module.exports = loop();"
]);
/** @type {Sources} */
const sources = new Map();
sources.set(JAVASCRIPT_TYPE, new RawSource(code));
return { sources, runtimeRequirements: RUNTIME_REQUIREMENTS };
}
/**
* @param {ObjectSerializerContext} context context
*/
serialize(context) {
const { write } = context;
write(this.requests);
super.serialize(context);
}
/**
* @param {ObjectDeserializerContext} context context
* @returns {FallbackModule} deserialized fallback module
*/
static deserialize(context) {
const { read } = context;
const obj = new FallbackModule(read());
obj.deserialize(context);
return obj;
}
}
makeSerializable(FallbackModule, "webpack/lib/container/FallbackModule");
module.exports = FallbackModule;

View File

@@ -0,0 +1,23 @@
import { countOperation, isolateObjectProperty } from 'payload';
export function countResolver(collection) {
return async function resolver(_, args, context) {
let { req } = context;
const locale = req.locale;
const fallbackLocale = req.fallbackLocale;
req = isolateObjectProperty(req, 'locale');
req = isolateObjectProperty(req, 'fallbackLocale');
req.locale = args.locale || locale;
req.fallbackLocale = fallbackLocale;
context.req = req;
const options = {
collection,
req: isolateObjectProperty(req, 'transactionID'),
trash: args.trash,
where: args.where
};
const results = await countOperation(options);
return results;
};
}
//# sourceMappingURL=count.js.map

View File

@@ -0,0 +1,143 @@
"use strict";
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
var desc = Object.getOwnPropertyDescriptor(m, k);
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
desc = { enumerable: true, get: function() { return m[k]; } };
}
Object.defineProperty(o, k2, desc);
}) : (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
o[k2] = m[k];
}));
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
Object.defineProperty(o, "default", { enumerable: true, value: v });
}) : function(o, v) {
o["default"] = v;
});
var __importStar = (this && this.__importStar) || function (mod) {
if (mod && mod.__esModule) return mod;
var result = {};
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
__setModuleDefault(result, mod);
return result;
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.default = default_1;
const util = __importStar(require("../core/util.cjs"));
const error = () => {
const Sizable = {
string: { unit: "символів", verb: "матиме" },
file: { unit: "байтів", verb: "матиме" },
array: { unit: "елементів", verb: "матиме" },
set: { unit: "елементів", verb: "матиме" },
};
function getSizing(origin) {
return Sizable[origin] ?? null;
}
const parsedType = (data) => {
const t = typeof data;
switch (t) {
case "number": {
return Number.isNaN(data) ? "NaN" : "число";
}
case "object": {
if (Array.isArray(data)) {
return "масив";
}
if (data === null) {
return "null";
}
if (Object.getPrototypeOf(data) !== Object.prototype && data.constructor) {
return data.constructor.name;
}
}
}
return t;
};
const Nouns = {
regex: "вхідні дані",
email: "адреса електронної пошти",
url: "URL",
emoji: "емодзі",
uuid: "UUID",
uuidv4: "UUIDv4",
uuidv6: "UUIDv6",
nanoid: "nanoid",
guid: "GUID",
cuid: "cuid",
cuid2: "cuid2",
ulid: "ULID",
xid: "XID",
ksuid: "KSUID",
datetime: "дата та час ISO",
date: "дата ISO",
time: "час ISO",
duration: "тривалість ISO",
ipv4: "адреса IPv4",
ipv6: "адреса IPv6",
cidrv4: "діапазон IPv4",
cidrv6: "діапазон IPv6",
base64: "рядок у кодуванні base64",
base64url: "рядок у кодуванні base64url",
json_string: "рядок JSON",
e164: "номер E.164",
jwt: "JWT",
template_literal: "вхідні дані",
};
return (issue) => {
switch (issue.code) {
case "invalid_type":
return `Неправильні вхідні дані: очікується ${issue.expected}, отримано ${parsedType(issue.input)}`;
// return `Неправильні вхідні дані: очікується ${issue.expected}, отримано ${util.getParsedType(issue.input)}`;
case "invalid_value":
if (issue.values.length === 1)
return `Неправильні вхідні дані: очікується ${util.stringifyPrimitive(issue.values[0])}`;
return `Неправильна опція: очікується одне з ${util.joinValues(issue.values, "|")}`;
case "too_big": {
const adj = issue.inclusive ? "<=" : "<";
const sizing = getSizing(issue.origin);
if (sizing)
return `Занадто велике: очікується, що ${issue.origin ?? "значення"} ${sizing.verb} ${adj}${issue.maximum.toString()} ${sizing.unit ?? "елементів"}`;
return `Занадто велике: очікується, що ${issue.origin ?? "значення"} буде ${adj}${issue.maximum.toString()}`;
}
case "too_small": {
const adj = issue.inclusive ? ">=" : ">";
const sizing = getSizing(issue.origin);
if (sizing) {
return `Занадто мале: очікується, що ${issue.origin} ${sizing.verb} ${adj}${issue.minimum.toString()} ${sizing.unit}`;
}
return `Занадто мале: очікується, що ${issue.origin} буде ${adj}${issue.minimum.toString()}`;
}
case "invalid_format": {
const _issue = issue;
if (_issue.format === "starts_with")
return `Неправильний рядок: повинен починатися з "${_issue.prefix}"`;
if (_issue.format === "ends_with")
return `Неправильний рядок: повинен закінчуватися на "${_issue.suffix}"`;
if (_issue.format === "includes")
return `Неправильний рядок: повинен містити "${_issue.includes}"`;
if (_issue.format === "regex")
return `Неправильний рядок: повинен відповідати шаблону ${_issue.pattern}`;
return `Неправильний ${Nouns[_issue.format] ?? issue.format}`;
}
case "not_multiple_of":
return `Неправильне число: повинно бути кратним ${issue.divisor}`;
case "unrecognized_keys":
return `Нерозпізнаний ключ${issue.keys.length > 1 ? "і" : ""}: ${util.joinValues(issue.keys, ", ")}`;
case "invalid_key":
return `Неправильний ключ у ${issue.origin}`;
case "invalid_union":
return "Неправильні вхідні дані";
case "invalid_element":
return `Неправильне значення у ${issue.origin}`;
default:
return `Неправильні вхідні дані`;
}
};
};
function default_1() {
return {
localeError: error(),
};
}

View File

@@ -0,0 +1,39 @@
/*
MIT License http://www.opensource.org/licenses/mit-license.php
Author Natsu @xiaoxiaojx
*/
"use strict";
// data URL scheme: "data:text/javascript;charset=utf-8;base64,some-string"
// http://www.ietf.org/rfc/rfc2397.txt
const URIRegEx = /^data:([^;,]+)?((?:;[^;,]+)*?)(?:;(base64)?)?,(.*)$/i;
/**
* @param {string} uri data URI
* @returns {Buffer | null} decoded data
*/
const decodeDataURI = (uri) => {
const match = URIRegEx.exec(uri);
if (!match) return null;
const isBase64 = match[3];
const body = match[4];
if (isBase64) {
return Buffer.from(body, "base64");
}
// CSS allows to use `data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg"><rect width="100%" height="100%" style="stroke: rgb(223,224,225); stroke-width: 2px; fill: none; stroke-dasharray: 6px 3px" /></svg>`
// so we return original body if we can't `decodeURIComponent`
try {
return Buffer.from(decodeURIComponent(body), "ascii");
} catch (_) {
return Buffer.from(body, "ascii");
}
};
module.exports = {
URIRegEx,
decodeDataURI
};

View File

@@ -0,0 +1,3 @@
'use strict';
module.exports = require('./async').rejectLimit;

View File

@@ -0,0 +1 @@
{"version":3,"file":"cherry.js","sources":["../../../src/icons/cherry.ts"],"sourcesContent":["import createLucideIcon from '../createLucideIcon';\n\n/**\n * @component @name Cherry\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview ![img](data:image/svg+xml;base64,PHN2ZyAgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIgogIHdpZHRoPSIyNCIKICBoZWlnaHQ9IjI0IgogIHZpZXdCb3g9IjAgMCAyNCAyNCIKICBmaWxsPSJub25lIgogIHN0cm9rZT0iIzAwMCIgc3R5bGU9ImJhY2tncm91bmQtY29sb3I6ICNmZmY7IGJvcmRlci1yYWRpdXM6IDJweCIKICBzdHJva2Utd2lkdGg9IjIiCiAgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIgogIHN0cm9rZS1saW5lam9pbj0icm91bmQiCj4KICA8cGF0aCBkPSJNMiAxN2E1IDUgMCAwIDAgMTAgMGMwLTIuNzYtMi41LTUtNS0zLTIuNS0yLTUgLjI0LTUgM1oiIC8+CiAgPHBhdGggZD0iTTEyIDE3YTUgNSAwIDAgMCAxMCAwYzAtMi43Ni0yLjUtNS01LTMtMi41LTItNSAuMjQtNSAzWiIgLz4KICA8cGF0aCBkPSJNNyAxNGMzLjIyLTIuOTEgNC4yOS04Ljc1IDUtMTIgMS42NiAyLjM4IDQuOTQgOSA1IDEyIiAvPgogIDxwYXRoIGQ9Ik0yMiA5Yy00LjI5IDAtNy4xNC0yLjMzLTEwLTcgNS43MSAwIDEwIDQuNjcgMTAgN1oiIC8+Cjwvc3ZnPgo=) - https://lucide.dev/icons/cherry\n * @see https://lucide.dev/guide/packages/lucide-react - Documentation\n *\n * @param {Object} props - Lucide icons props and any valid SVG attribute\n * @returns {JSX.Element} JSX Element\n *\n */\nconst Cherry = createLucideIcon('Cherry', [\n ['path', { d: 'M2 17a5 5 0 0 0 10 0c0-2.76-2.5-5-5-3-2.5-2-5 .24-5 3Z', key: 'cvxqlc' }],\n ['path', { d: 'M12 17a5 5 0 0 0 10 0c0-2.76-2.5-5-5-3-2.5-2-5 .24-5 3Z', key: '1ostrc' }],\n ['path', { d: 'M7 14c3.22-2.91 4.29-8.75 5-12 1.66 2.38 4.94 9 5 12', key: 'hqx58h' }],\n ['path', { d: 'M22 9c-4.29 0-7.14-2.33-10-7 5.71 0 10 4.67 10 7Z', key: 'eykp1o' }],\n]);\n\nexport default Cherry;\n"],"names":[],"mappings":";;;;;;;;;AAaM,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAS,iBAAiB,QAAU,CAAA,CAAA,CAAA;AAAA,CAAA,CACxC,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAA0D,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CACvF,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAA2D,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CACxF,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAwD,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CACrF,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAqD,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA;AACpF,CAAC,CAAA,CAAA;;"}

View File

@@ -0,0 +1 @@
{"version":3,"file":"nl.d.ts","sourceRoot":"","sources":["../../../src/exports/i18n/nl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAE,MAAM,uCAAuC,CAAA"}

View File

@@ -0,0 +1,131 @@
"use strict";
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __hasOwnProp = Object.prototype.hasOwnProperty;
var __export = (target, all) => {
for (var name in all)
__defProp(target, name, { get: all[name], enumerable: true });
};
var __copyProps = (to, from, except, desc) => {
if (from && typeof from === "object" || typeof from === "function") {
for (let key of __getOwnPropNames(from))
if (!__hasOwnProp.call(to, key) && key !== except)
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
}
return to;
};
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
var delete_exports = {};
__export(delete_exports, {
MySqlDeleteBase: () => MySqlDeleteBase
});
module.exports = __toCommonJS(delete_exports);
var import_entity = require("../../entity.cjs");
var import_query_promise = require("../../query-promise.cjs");
var import_selection_proxy = require("../../selection-proxy.cjs");
var import_table = require("../../table.cjs");
var import_utils = require("../utils.cjs");
class MySqlDeleteBase extends import_query_promise.QueryPromise {
constructor(table, session, dialect, withList) {
super();
this.table = table;
this.session = session;
this.dialect = dialect;
this.config = { table, withList };
}
static [import_entity.entityKind] = "MySqlDelete";
config;
/**
* Adds a `where` clause to the query.
*
* Calling this method will delete only those rows that fulfill a specified condition.
*
* See docs: {@link https://orm.drizzle.team/docs/delete}
*
* @param where the `where` clause.
*
* @example
* You can use conditional operators and `sql function` to filter the rows to be deleted.
*
* ```ts
* // Delete all cars with green color
* db.delete(cars).where(eq(cars.color, 'green'));
* // or
* db.delete(cars).where(sql`${cars.color} = 'green'`)
* ```
*
* You can logically combine conditional operators with `and()` and `or()` operators:
*
* ```ts
* // Delete all BMW cars with a green color
* db.delete(cars).where(and(eq(cars.color, 'green'), eq(cars.brand, 'BMW')));
*
* // Delete all cars with the green or blue color
* db.delete(cars).where(or(eq(cars.color, 'green'), eq(cars.color, 'blue')));
* ```
*/
where(where) {
this.config.where = where;
return this;
}
orderBy(...columns) {
if (typeof columns[0] === "function") {
const orderBy = columns[0](
new Proxy(
this.config.table[import_table.Table.Symbol.Columns],
new import_selection_proxy.SelectionProxyHandler({ sqlAliasedBehavior: "alias", sqlBehavior: "sql" })
)
);
const orderByArray = Array.isArray(orderBy) ? orderBy : [orderBy];
this.config.orderBy = orderByArray;
} else {
const orderByArray = columns;
this.config.orderBy = orderByArray;
}
return this;
}
limit(limit) {
this.config.limit = limit;
return this;
}
/** @internal */
getSQL() {
return this.dialect.buildDeleteQuery(this.config);
}
toSQL() {
const { typings: _typings, ...rest } = this.dialect.sqlToQuery(this.getSQL());
return rest;
}
prepare() {
return this.session.prepareQuery(
this.dialect.sqlToQuery(this.getSQL()),
this.config.returning,
void 0,
void 0,
void 0,
{
type: "delete",
tables: (0, import_utils.extractUsedTable)(this.config.table)
}
);
}
execute = (placeholderValues) => {
return this.prepare().execute(placeholderValues);
};
createIterator = () => {
const self = this;
return async function* (placeholderValues) {
yield* self.prepare().iterator(placeholderValues);
};
};
iterator = this.createIterator();
$dynamic() {
return this;
}
}
// Annotate the CommonJS export names for ESM import in node:
0 && (module.exports = {
MySqlDeleteBase
});
//# sourceMappingURL=delete.cjs.map

View File

@@ -0,0 +1 @@
module.exports={A:{A:{"1":"E F A B","2":"zC","8":"K D"},B:{"1":"0 1 2 3 4 5 6 7 8 C L M G N O P Q H R S T U V W X Y Z a b c d e f g h i j k l m n o p q r s t u v w x y z JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB I"},C:{"1":"0 1 2 3 4 5 6 7 8 9 J bB K D E F A B C L M G N O P cB AB BB CB DB EB FB GB HB IB dB eB fB gB hB iB jB kB lB mB nB oB pB qB rB sB tB uB vB wB xB yB zB 0B 1B 2B 3B 4B 5B WC 6B XC 7B 8B 9B AC BC CC DC EC FC GC HC IC JC KC LC MC NC Q H R YC S T U V W X Y Z a b c d e f g h i j k l m n o p q r s t u v w x y z JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB I ZC aC OC 1C 2C 3C 4C 5C","4":"0C VC"},D:{"1":"0 1 2 3 4 5 6 7 8 9 J bB K D E F A B C L M G N O P cB AB BB CB DB EB FB GB HB IB dB eB fB gB hB iB jB kB lB mB nB oB pB qB rB sB tB uB vB wB xB yB zB 0B 1B 2B 3B 4B 5B WC 6B XC 7B 8B 9B AC BC CC DC EC FC GC HC IC JC KC LC MC NC Q H R S T U V W X Y Z a b c d e f g h i j k l m n o p q r s t u v w x y z JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB I ZC aC OC"},E:{"1":"J bB K D E F A B C L M G 7C 8C 9C AD cC PC QC BD CD DD dC eC RC ED SC fC gC hC iC jC FD TC kC lC mC nC oC GD UC pC qC rC sC HD tC uC vC wC ID","2":"6C bC"},F:{"1":"0 1 2 3 4 5 6 7 8 9 B C G N O P cB AB BB CB DB EB FB GB HB IB dB eB fB gB hB iB jB kB lB mB nB oB pB qB rB sB tB uB vB wB xB yB zB 0B 1B 2B 3B 4B 5B 6B 7B 8B 9B AC BC CC DC EC FC GC HC IC JC KC LC MC NC Q H R YC S T U V W X Y Z a b c d e f g h i j k l m n o p q r s t u v w x y z LD MD PC xC ND QC","2":"F JD KD"},G:{"1":"E bC OD yC PD QD RD SD TD UD VD WD XD YD ZD aD bD cD dD eD fD gD hD dC eC RC iD SC fC gC hC iC jC jD TC kC lC mC nC oC kD UC pC qC rC sC lD tC uC vC wC"},H:{"2":"mD"},I:{"1":"VC J I nD oD pD qD yC rD sD"},J:{"1":"D A"},K:{"1":"B C H PC xC QC","2":"A"},L:{"1":"I"},M:{"1":"OC"},N:{"1":"A B"},O:{"1":"RC"},P:{"1":"9 J AB BB CB DB EB FB GB HB IB tD uD vD wD xD cC yD zD 0D 1D 2D SC TC UC 3D"},Q:{"1":"4D"},R:{"1":"5D"},S:{"1":"6D 7D"}},B:1,C:"Web Storage - name/value pairs",D:true};

View File

@@ -0,0 +1,61 @@
/*
MIT License http://www.opensource.org/licenses/mit-license.php
Author Tobias Koppers @sokra, Zackary Jackson @ScriptedAlchemy, Marais Rossouw @maraisr
*/
"use strict";
const ModuleDependency = require("../dependencies/ModuleDependency");
const makeSerializable = require("../util/makeSerializable");
/** @typedef {import("../serialization/ObjectMiddleware").ObjectDeserializerContext} ObjectDeserializerContext */
/** @typedef {import("../serialization/ObjectMiddleware").ObjectSerializerContext} ObjectSerializerContext */
class ContainerExposedDependency extends ModuleDependency {
/**
* @param {string} exposedName public name
* @param {string} request request to module
*/
constructor(exposedName, request) {
super(request);
this.exposedName = exposedName;
}
get type() {
return "container exposed";
}
get category() {
return "esm";
}
/**
* @returns {string | null} an identifier to merge equal requests
*/
getResourceIdentifier() {
return `exposed dependency ${this.exposedName}=${this.request}`;
}
/**
* @param {ObjectSerializerContext} context context
*/
serialize(context) {
context.write(this.exposedName);
super.serialize(context);
}
/**
* @param {ObjectDeserializerContext} context context
*/
deserialize(context) {
this.exposedName = context.read();
super.deserialize(context);
}
}
makeSerializable(
ContainerExposedDependency,
"webpack/lib/container/ContainerExposedDependency"
);
module.exports = ContainerExposedDependency;

View File

@@ -0,0 +1,56 @@
"use strict";
exports.differenceInCalendarDays = differenceInCalendarDays;
var _index = require("./constants.js");
var _index2 = require("./startOfDay.js");
var _index3 = require("./_lib/getTimezoneOffsetInMilliseconds.js");
/**
* @name differenceInCalendarDays
* @category Day Helpers
* @summary Get the number of calendar days between the given dates.
*
* @description
* Get the number of calendar days between the given dates. This means that the times are removed
* from the dates and then the difference in days is calculated.
*
* @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).
*
* @param dateLeft - The later date
* @param dateRight - The earlier date
*
* @returns The number of calendar days
*
* @example
* // How many calendar days are between
* // 2 July 2011 23:00:00 and 2 July 2012 00:00:00?
* const result = differenceInCalendarDays(
* new Date(2012, 6, 2, 0, 0),
* new Date(2011, 6, 2, 23, 0)
* )
* //=> 366
* // How many calendar days are between
* // 2 July 2011 23:59:00 and 3 July 2011 00:01:00?
* const result = differenceInCalendarDays(
* new Date(2011, 6, 3, 0, 1),
* new Date(2011, 6, 2, 23, 59)
* )
* //=> 1
*/
function differenceInCalendarDays(dateLeft, dateRight) {
const startOfDayLeft = (0, _index2.startOfDay)(dateLeft);
const startOfDayRight = (0, _index2.startOfDay)(dateRight);
const timestampLeft =
+startOfDayLeft -
(0, _index3.getTimezoneOffsetInMilliseconds)(startOfDayLeft);
const timestampRight =
+startOfDayRight -
(0, _index3.getTimezoneOffsetInMilliseconds)(startOfDayRight);
// Round the number of days to the nearest integer because the number of
// milliseconds in a day is not constant (e.g. it's different in the week of
// the daylight saving time clock shift).
return Math.round(
(timestampLeft - timestampRight) / _index.millisecondsInDay,
);
}

View File

@@ -0,0 +1 @@
{"version":3,"file":"font-family.js","sourceRoot":"","sources":["../../../../../src/css/property-descriptors/__tests__/font-family.ts"],"names":[],"mappings":";;AAAA,iCAAiC;AACjC,8CAA2C;AAC3C,8CAA0C;AAG1C,IAAM,eAAe,GAAG,UAAC,KAAa,IAAK,OAAA,wBAAU,CAAC,KAAK,CAAC,EAAa,EAAE,eAAM,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC,EAA1D,CAA0D,CAAC;AAEtG,QAAQ,CAAC,sBAAsB,EAAE;IAC7B,QAAQ,CAAC,aAAa,EAAE;QACpB,EAAE,CAAC,YAAY,EAAE,cAAM,OAAA,kBAAS,CAAC,eAAe,CAAC,YAAY,CAAC,EAAE,CAAC,YAAY,CAAC,CAAC,EAAxD,CAAwD,CAAC,CAAC;QAEjF,EAAE,CAAC,wBAAwB,EAAE;YACzB,OAAA,kBAAS,CAAC,eAAe,CAAC,wBAAwB,CAAC,EAAE,CAAC,0BAA0B,CAAC,CAAC;QAAlF,CAAkF,CAAC,CAAC;QAExF,EAAE,CAAC,8CAA8C,EAAE;YAC/C,OAAA,kBAAS,CAAC,eAAe,CAAC,8CAA8C,CAAC,EAAE;gBACvE,kBAAkB;gBAClB,wBAAwB;gBACxB,MAAM;aACT,CAAC;QAJF,CAIE,CAAC,CAAC;QAER,EAAE,CAAC,0BAA0B,EAAE;YAC3B,OAAA,kBAAS,CAAC,eAAe,CAAC,0BAA0B,CAAC,EAAE,CAAC,wBAAwB,CAAC,CAAC;QAAlF,CAAkF,CAAC,CAAC;IAC5F,CAAC,CAAC,CAAC;AACP,CAAC,CAAC,CAAC"}

View File

@@ -0,0 +1,10 @@
// Avoid rollup's `replace` plugin to compile this away
const nodeEnvKey = 'NODE_ENV'.trim();
// We avoid reading `argv.includes('dev')` related to
// https://github.com/amannn/next-intl/issues/2006
const isDevelopment = process.env[nodeEnvKey] === 'development';
const isNextBuild = process.argv.includes('build');
const isDevelopmentOrNextBuild = isDevelopment || isNextBuild;
export { isDevelopment, isDevelopmentOrNextBuild, isNextBuild };

View File

@@ -0,0 +1,3 @@
export { featureFlagsIntegration, type FeatureFlagsIntegration } from './featureFlagsIntegration';
export { growthbookIntegration } from './growthbook';
//# sourceMappingURL=index.d.ts.map

View File

@@ -0,0 +1,20 @@
import { MongooseInstrumentation } from '@opentelemetry/instrumentation-mongoose';
export declare const instrumentMongoose: ((options?: unknown) => MongooseInstrumentation) & {
id: string;
};
/**
* Adds Sentry tracing instrumentation for the [mongoose](https://www.npmjs.com/package/mongoose) library.
*
* For more information, see the [`mongooseIntegration` documentation](https://docs.sentry.io/platforms/javascript/guides/node/configuration/integrations/mongoose/).
*
* @example
* ```javascript
* const Sentry = require('@sentry/node');
*
* Sentry.init({
* integrations: [Sentry.mongooseIntegration()],
* });
* ```
*/
export declare const mongooseIntegration: () => import("@sentry/core").Integration;
//# sourceMappingURL=mongoose.d.ts.map

Some files were not shown because too many files have changed in this diff Show More