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,189 @@
/*
MIT License http://www.opensource.org/licenses/mit-license.php
Author Tobias Koppers @sokra
*/
"use strict";
const RuntimeGlobals = require("../RuntimeGlobals");
const makeSerializable = require("../util/makeSerializable");
const NullDependency = require("./NullDependency");
/** @typedef {import("webpack-sources").ReplaceSource} ReplaceSource */
/** @typedef {import("../AsyncDependenciesBlock")} AsyncDependenciesBlock */
/** @typedef {import("../Dependency")} Dependency */
/** @typedef {import("../DependencyTemplate").DependencyTemplateContext} DependencyTemplateContext */
/** @typedef {import("../javascript/JavascriptParser").Range} Range */
/** @typedef {import("../serialization/ObjectMiddleware").ObjectDeserializerContext} ObjectDeserializerContext */
/** @typedef {import("../serialization/ObjectMiddleware").ObjectSerializerContext} ObjectSerializerContext */
class AMDRequireDependency extends NullDependency {
/**
* @param {Range} outerRange outer range
* @param {Range} arrayRange array range
* @param {Range | null} functionRange function range
* @param {Range | null} errorCallbackRange error callback range
*/
constructor(outerRange, arrayRange, functionRange, errorCallbackRange) {
super();
this.outerRange = outerRange;
this.arrayRange = arrayRange;
this.functionRange = functionRange;
this.errorCallbackRange = errorCallbackRange;
this.functionBindThis = false;
this.errorCallbackBindThis = false;
}
get category() {
return "amd";
}
/**
* @param {ObjectSerializerContext} context context
*/
serialize(context) {
const { write } = context;
write(this.outerRange);
write(this.arrayRange);
write(this.functionRange);
write(this.errorCallbackRange);
write(this.functionBindThis);
write(this.errorCallbackBindThis);
super.serialize(context);
}
/**
* @param {ObjectDeserializerContext} context context
*/
deserialize(context) {
const { read } = context;
this.outerRange = read();
this.arrayRange = read();
this.functionRange = read();
this.errorCallbackRange = read();
this.functionBindThis = read();
this.errorCallbackBindThis = read();
super.deserialize(context);
}
}
makeSerializable(
AMDRequireDependency,
"webpack/lib/dependencies/AMDRequireDependency"
);
AMDRequireDependency.Template = class AMDRequireDependencyTemplate extends (
NullDependency.Template
) {
/**
* @param {Dependency} dependency the dependency for which the template should be applied
* @param {ReplaceSource} source the current replace source which can be modified
* @param {DependencyTemplateContext} templateContext the context object
* @returns {void}
*/
apply(
dependency,
source,
{ runtimeTemplate, moduleGraph, chunkGraph, runtimeRequirements }
) {
const dep = /** @type {AMDRequireDependency} */ (dependency);
const depBlock = /** @type {AsyncDependenciesBlock} */ (
moduleGraph.getParentBlock(dep)
);
const promise = runtimeTemplate.blockPromise({
chunkGraph,
block: depBlock,
message: "AMD require",
runtimeRequirements
});
// has array range but no function range
if (dep.arrayRange && !dep.functionRange) {
const startBlock = `${promise}.then(function() {`;
const endBlock = `;})['catch'](${RuntimeGlobals.uncaughtErrorHandler})`;
runtimeRequirements.add(RuntimeGlobals.uncaughtErrorHandler);
source.replace(dep.outerRange[0], dep.arrayRange[0] - 1, startBlock);
source.replace(dep.arrayRange[1], dep.outerRange[1] - 1, endBlock);
return;
}
// has function range but no array range
if (dep.functionRange && !dep.arrayRange) {
const startBlock = `${promise}.then((`;
const endBlock = `).bind(exports, ${RuntimeGlobals.require}, exports, module))['catch'](${RuntimeGlobals.uncaughtErrorHandler})`;
runtimeRequirements.add(RuntimeGlobals.uncaughtErrorHandler);
source.replace(dep.outerRange[0], dep.functionRange[0] - 1, startBlock);
source.replace(dep.functionRange[1], dep.outerRange[1] - 1, endBlock);
return;
}
// has array range, function range, and errorCallbackRange
if (dep.arrayRange && dep.functionRange && dep.errorCallbackRange) {
const startBlock = `${promise}.then(function() { `;
const errorRangeBlock = `}${
dep.functionBindThis ? ".bind(this)" : ""
})['catch'](`;
const endBlock = `${dep.errorCallbackBindThis ? ".bind(this)" : ""})`;
source.replace(dep.outerRange[0], dep.arrayRange[0] - 1, startBlock);
source.insert(dep.arrayRange[0], "var __WEBPACK_AMD_REQUIRE_ARRAY__ = ");
source.replace(dep.arrayRange[1], dep.functionRange[0] - 1, "; (");
source.insert(
dep.functionRange[1],
").apply(null, __WEBPACK_AMD_REQUIRE_ARRAY__);"
);
source.replace(
dep.functionRange[1],
dep.errorCallbackRange[0] - 1,
errorRangeBlock
);
source.replace(
dep.errorCallbackRange[1],
dep.outerRange[1] - 1,
endBlock
);
return;
}
// has array range, function range, but no errorCallbackRange
if (dep.arrayRange && dep.functionRange) {
const startBlock = `${promise}.then(function() { `;
const endBlock = `}${
dep.functionBindThis ? ".bind(this)" : ""
})['catch'](${RuntimeGlobals.uncaughtErrorHandler})`;
runtimeRequirements.add(RuntimeGlobals.uncaughtErrorHandler);
source.replace(dep.outerRange[0], dep.arrayRange[0] - 1, startBlock);
source.insert(dep.arrayRange[0], "var __WEBPACK_AMD_REQUIRE_ARRAY__ = ");
source.replace(dep.arrayRange[1], dep.functionRange[0] - 1, "; (");
source.insert(
dep.functionRange[1],
").apply(null, __WEBPACK_AMD_REQUIRE_ARRAY__);"
);
source.replace(dep.functionRange[1], dep.outerRange[1] - 1, endBlock);
}
}
};
module.exports = AMDRequireDependency;

View File

@@ -0,0 +1 @@
{"version":3,"file":"ComponentLogger.js","sourceRoot":"","sources":["../../../src/diag/ComponentLogger.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;;AAEH,2DAAqD;AAGrD;;;;;;;;GAQG;AACH,MAAa,mBAAmB;IAG9B,YAAY,KAA6B;QACvC,IAAI,CAAC,UAAU,GAAG,KAAK,CAAC,SAAS,IAAI,qBAAqB,CAAC;IAC7D,CAAC;IAEM,KAAK,CAAC,GAAG,IAAW;QACzB,OAAO,QAAQ,CAAC,OAAO,EAAE,IAAI,CAAC,UAAU,EAAE,IAAI,CAAC,CAAC;IAClD,CAAC;IAEM,KAAK,CAAC,GAAG,IAAW;QACzB,OAAO,QAAQ,CAAC,OAAO,EAAE,IAAI,CAAC,UAAU,EAAE,IAAI,CAAC,CAAC;IAClD,CAAC;IAEM,IAAI,CAAC,GAAG,IAAW;QACxB,OAAO,QAAQ,CAAC,MAAM,EAAE,IAAI,CAAC,UAAU,EAAE,IAAI,CAAC,CAAC;IACjD,CAAC;IAEM,IAAI,CAAC,GAAG,IAAW;QACxB,OAAO,QAAQ,CAAC,MAAM,EAAE,IAAI,CAAC,UAAU,EAAE,IAAI,CAAC,CAAC;IACjD,CAAC;IAEM,OAAO,CAAC,GAAG,IAAW;QAC3B,OAAO,QAAQ,CAAC,SAAS,EAAE,IAAI,CAAC,UAAU,EAAE,IAAI,CAAC,CAAC;IACpD,CAAC;CACF;AA1BD,kDA0BC;AAED,SAAS,QAAQ,CACf,QAA0B,EAC1B,SAAiB,EACjB,IAAS;IAET,MAAM,MAAM,GAAG,IAAA,wBAAS,EAAC,MAAM,CAAC,CAAC;IACjC,6BAA6B;IAC7B,IAAI,CAAC,MAAM,EAAE;QACX,OAAO;KACR;IAED,IAAI,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC;IACxB,OAAO,MAAM,CAAC,QAAQ,CAAC,CAAC,GAAI,IAAoC,CAAC,CAAC;AACpE,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 */\n\nimport { getGlobal } from '../internal/global-utils';\nimport { ComponentLoggerOptions, DiagLogger, DiagLogFunction } from './types';\n\n/**\n * Component Logger which is meant to be used as part of any component which\n * will add automatically additional namespace in front of the log message.\n * It will then forward all message to global diag logger\n * @example\n * const cLogger = diag.createComponentLogger({ namespace: '@opentelemetry/instrumentation-http' });\n * cLogger.debug('test');\n * // @opentelemetry/instrumentation-http test\n */\nexport class DiagComponentLogger implements DiagLogger {\n private _namespace: string;\n\n constructor(props: ComponentLoggerOptions) {\n this._namespace = props.namespace || 'DiagComponentLogger';\n }\n\n public debug(...args: any[]): void {\n return logProxy('debug', this._namespace, args);\n }\n\n public error(...args: any[]): void {\n return logProxy('error', this._namespace, args);\n }\n\n public info(...args: any[]): void {\n return logProxy('info', this._namespace, args);\n }\n\n public warn(...args: any[]): void {\n return logProxy('warn', this._namespace, args);\n }\n\n public verbose(...args: any[]): void {\n return logProxy('verbose', this._namespace, args);\n }\n}\n\nfunction logProxy(\n funcName: keyof DiagLogger,\n namespace: string,\n args: any\n): void {\n const logger = getGlobal('diag');\n // shortcut if logger not set\n if (!logger) {\n return;\n }\n\n args.unshift(namespace);\n return logger[funcName](...(args as Parameters<DiagLogFunction>));\n}\n"]}

View File

@@ -0,0 +1,111 @@
var baseToString = require('./_baseToString'),
castSlice = require('./_castSlice'),
hasUnicode = require('./_hasUnicode'),
isObject = require('./isObject'),
isRegExp = require('./isRegExp'),
stringSize = require('./_stringSize'),
stringToArray = require('./_stringToArray'),
toInteger = require('./toInteger'),
toString = require('./toString');
/** Used as default options for `_.truncate`. */
var DEFAULT_TRUNC_LENGTH = 30,
DEFAULT_TRUNC_OMISSION = '...';
/** Used to match `RegExp` flags from their coerced string values. */
var reFlags = /\w*$/;
/**
* Truncates `string` if it's longer than the given maximum string length.
* The last characters of the truncated string are replaced with the omission
* string which defaults to "...".
*
* @static
* @memberOf _
* @since 4.0.0
* @category String
* @param {string} [string=''] The string to truncate.
* @param {Object} [options={}] The options object.
* @param {number} [options.length=30] The maximum string length.
* @param {string} [options.omission='...'] The string to indicate text is omitted.
* @param {RegExp|string} [options.separator] The separator pattern to truncate to.
* @returns {string} Returns the truncated string.
* @example
*
* _.truncate('hi-diddly-ho there, neighborino');
* // => 'hi-diddly-ho there, neighbo...'
*
* _.truncate('hi-diddly-ho there, neighborino', {
* 'length': 24,
* 'separator': ' '
* });
* // => 'hi-diddly-ho there,...'
*
* _.truncate('hi-diddly-ho there, neighborino', {
* 'length': 24,
* 'separator': /,? +/
* });
* // => 'hi-diddly-ho there...'
*
* _.truncate('hi-diddly-ho there, neighborino', {
* 'omission': ' [...]'
* });
* // => 'hi-diddly-ho there, neig [...]'
*/
function truncate(string, options) {
var length = DEFAULT_TRUNC_LENGTH,
omission = DEFAULT_TRUNC_OMISSION;
if (isObject(options)) {
var separator = 'separator' in options ? options.separator : separator;
length = 'length' in options ? toInteger(options.length) : length;
omission = 'omission' in options ? baseToString(options.omission) : omission;
}
string = toString(string);
var strLength = string.length;
if (hasUnicode(string)) {
var strSymbols = stringToArray(string);
strLength = strSymbols.length;
}
if (length >= strLength) {
return string;
}
var end = length - stringSize(omission);
if (end < 1) {
return omission;
}
var result = strSymbols
? castSlice(strSymbols, 0, end).join('')
: string.slice(0, end);
if (separator === undefined) {
return result + omission;
}
if (strSymbols) {
end += (result.length - end);
}
if (isRegExp(separator)) {
if (string.slice(end).search(separator)) {
var match,
substring = result;
if (!separator.global) {
separator = RegExp(separator.source, toString(reFlags.exec(separator)) + 'g');
}
separator.lastIndex = 0;
while ((match = separator.exec(substring))) {
var newEnd = match.index;
}
result = result.slice(0, newEnd === undefined ? end : newEnd);
}
} else if (string.indexOf(baseToString(separator), end) != end) {
var index = result.lastIndexOf(separator);
if (index > -1) {
result = result.slice(0, index);
}
}
return result + omission;
}
module.exports = truncate;

View File

@@ -0,0 +1,24 @@
import type { ColumnBuilderBaseConfig } from "../../column-builder.cjs";
import type { ColumnBaseConfig } from "../../column.cjs";
import { entityKind } from "../../entity.cjs";
import { PgColumn } from "./common.cjs";
import { PgIntColumnBaseBuilder } from "./int.common.cjs";
export type PgSmallIntBuilderInitial<TName extends string> = PgSmallIntBuilder<{
name: TName;
dataType: 'number';
columnType: 'PgSmallInt';
data: number;
driverParam: number | string;
enumValues: undefined;
}>;
export declare class PgSmallIntBuilder<T extends ColumnBuilderBaseConfig<'number', 'PgSmallInt'>> extends PgIntColumnBaseBuilder<T> {
static readonly [entityKind]: string;
constructor(name: T['name']);
}
export declare class PgSmallInt<T extends ColumnBaseConfig<'number', 'PgSmallInt'>> extends PgColumn<T> {
static readonly [entityKind]: string;
getSQLType(): string;
mapFromDriverValue: (value: number | string) => number;
}
export declare function smallint(): PgSmallIntBuilderInitial<''>;
export declare function smallint<TName extends string>(name: TName): PgSmallIntBuilderInitial<TName>;

View File

@@ -0,0 +1 @@
{"version":3,"sources":["../../src/node-postgres/index.ts"],"sourcesContent":["export * from './driver.ts';\nexport * from './session.ts';\n"],"mappings":"AAAA,cAAc;AACd,cAAc;","names":[]}

View File

@@ -0,0 +1,58 @@
module.exports = {
'castArray': require('./castArray'),
'clone': require('./clone'),
'cloneDeep': require('./cloneDeep'),
'cloneDeepWith': require('./cloneDeepWith'),
'cloneWith': require('./cloneWith'),
'conformsTo': require('./conformsTo'),
'eq': require('./eq'),
'gt': require('./gt'),
'gte': require('./gte'),
'isArguments': require('./isArguments'),
'isArray': require('./isArray'),
'isArrayBuffer': require('./isArrayBuffer'),
'isArrayLike': require('./isArrayLike'),
'isArrayLikeObject': require('./isArrayLikeObject'),
'isBoolean': require('./isBoolean'),
'isBuffer': require('./isBuffer'),
'isDate': require('./isDate'),
'isElement': require('./isElement'),
'isEmpty': require('./isEmpty'),
'isEqual': require('./isEqual'),
'isEqualWith': require('./isEqualWith'),
'isError': require('./isError'),
'isFinite': require('./isFinite'),
'isFunction': require('./isFunction'),
'isInteger': require('./isInteger'),
'isLength': require('./isLength'),
'isMap': require('./isMap'),
'isMatch': require('./isMatch'),
'isMatchWith': require('./isMatchWith'),
'isNaN': require('./isNaN'),
'isNative': require('./isNative'),
'isNil': require('./isNil'),
'isNull': require('./isNull'),
'isNumber': require('./isNumber'),
'isObject': require('./isObject'),
'isObjectLike': require('./isObjectLike'),
'isPlainObject': require('./isPlainObject'),
'isRegExp': require('./isRegExp'),
'isSafeInteger': require('./isSafeInteger'),
'isSet': require('./isSet'),
'isString': require('./isString'),
'isSymbol': require('./isSymbol'),
'isTypedArray': require('./isTypedArray'),
'isUndefined': require('./isUndefined'),
'isWeakMap': require('./isWeakMap'),
'isWeakSet': require('./isWeakSet'),
'lt': require('./lt'),
'lte': require('./lte'),
'toArray': require('./toArray'),
'toFinite': require('./toFinite'),
'toInteger': require('./toInteger'),
'toLength': require('./toLength'),
'toNumber': require('./toNumber'),
'toPlainObject': require('./toPlainObject'),
'toSafeInteger': require('./toSafeInteger'),
'toString': require('./toString')
};

View File

@@ -0,0 +1 @@
{"version":3,"file":"git-merge.js","sources":["../../../src/icons/git-merge.ts"],"sourcesContent":["import createLucideIcon from '../createLucideIcon';\n\n/**\n * @component @name GitMerge\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview ![img](data:image/svg+xml;base64,PHN2ZyAgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIgogIHdpZHRoPSIyNCIKICBoZWlnaHQ9IjI0IgogIHZpZXdCb3g9IjAgMCAyNCAyNCIKICBmaWxsPSJub25lIgogIHN0cm9rZT0iIzAwMCIgc3R5bGU9ImJhY2tncm91bmQtY29sb3I6ICNmZmY7IGJvcmRlci1yYWRpdXM6IDJweCIKICBzdHJva2Utd2lkdGg9IjIiCiAgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIgogIHN0cm9rZS1saW5lam9pbj0icm91bmQiCj4KICA8Y2lyY2xlIGN4PSIxOCIgY3k9IjE4IiByPSIzIiAvPgogIDxjaXJjbGUgY3g9IjYiIGN5PSI2IiByPSIzIiAvPgogIDxwYXRoIGQ9Ik02IDIxVjlhOSA5IDAgMCAwIDkgOSIgLz4KPC9zdmc+Cg==) - https://lucide.dev/icons/git-merge\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 GitMerge = createLucideIcon('GitMerge', [\n ['circle', { cx: '18', cy: '18', r: '3', key: '1xkwt0' }],\n ['circle', { cx: '6', cy: '6', r: '3', key: '1lh9wr' }],\n ['path', { d: 'M6 21V9a9 9 0 0 0 9 9', key: '7kw0sc' }],\n]);\n\nexport default GitMerge;\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,CAC5C,CAAA,CAAC,QAAU,CAAA,CAAA,CAAA,CAAE,EAAI,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,EAAM,CAAI,CAAA,CAAA,CAAA,IAAA,CAAM,CAAA,CAAG,EAAA,CAAA,CAAA,CAAA,CAAA,CAAK,GAAK,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,EAAU,CAAA,CAAA;AAAA,CACxD,CAAA,CAAC,QAAU,CAAA,CAAA,CAAA,CAAE,EAAI,CAAA,CAAA,CAAA,CAAA,CAAA,EAAK,CAAI,CAAA,CAAA,CAAA,GAAA,CAAK,CAAA,CAAG,EAAA,CAAA,CAAA,CAAA,CAAA,CAAK,GAAK,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,EAAU,CAAA,CAAA;AAAA,CAAA,CACtD,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;AACxD,CAAC,CAAA,CAAA;;"}

View File

@@ -0,0 +1,57 @@
var baseRest = require('./_baseRest'),
createWrap = require('./_createWrap'),
getHolder = require('./_getHolder'),
replaceHolders = require('./_replaceHolders');
/** Used to compose bitmasks for function metadata. */
var WRAP_BIND_FLAG = 1,
WRAP_PARTIAL_FLAG = 32;
/**
* Creates a function that invokes `func` with the `this` binding of `thisArg`
* and `partials` prepended to the arguments it receives.
*
* The `_.bind.placeholder` value, which defaults to `_` in monolithic builds,
* may be used as a placeholder for partially applied arguments.
*
* **Note:** Unlike native `Function#bind`, this method doesn't set the "length"
* property of bound functions.
*
* @static
* @memberOf _
* @since 0.1.0
* @category Function
* @param {Function} func The function to bind.
* @param {*} thisArg The `this` binding of `func`.
* @param {...*} [partials] The arguments to be partially applied.
* @returns {Function} Returns the new bound function.
* @example
*
* function greet(greeting, punctuation) {
* return greeting + ' ' + this.user + punctuation;
* }
*
* var object = { 'user': 'fred' };
*
* var bound = _.bind(greet, object, 'hi');
* bound('!');
* // => 'hi fred!'
*
* // Bound with placeholders.
* var bound = _.bind(greet, object, _, '!');
* bound('hi');
* // => 'hi fred!'
*/
var bind = baseRest(function(func, thisArg, partials) {
var bitmask = WRAP_BIND_FLAG;
if (partials.length) {
var holders = replaceHolders(partials, getHolder(bind));
bitmask |= WRAP_PARTIAL_FLAG;
}
return createWrap(func, bitmask, thisArg, partials, holders);
});
// Assign default placeholders.
bind.placeholder = {};
module.exports = bind;

View File

@@ -0,0 +1,22 @@
import type { ParameterizedString } from '../types-hoist/parameterize';
/**
* Tagged template function which returns parameterized representation of the message
* For example: parameterize`This is a log statement with ${x} and ${y} params`, would return:
* "__sentry_template_string__": 'This is a log statement with %s and %s params',
* "__sentry_template_values__": ['first', 'second']
*
* @param strings An array of string values splitted between expressions
* @param values Expressions extracted from template string
*
* @returns A `ParameterizedString` object that can be passed into `captureMessage` or Sentry.logger.X methods.
*/
export declare function parameterize(strings: TemplateStringsArray, ...values: unknown[]): ParameterizedString;
/**
* Tagged template function which returns parameterized representation of the message.
*
* @param strings An array of string values splitted between expressions
* @param values Expressions extracted from template string
* @returns A `ParameterizedString` object that can be passed into `captureMessage` or Sentry.logger.X methods.
*/
export declare const fmt: typeof parameterize;
//# sourceMappingURL=parameterize.d.ts.map

View File

@@ -0,0 +1,28 @@
import * as React from 'react';
import { DistributiveOmit, PropsOf } from "./types.js";
export interface Theme {
}
export interface ThemeProviderProps {
theme: Partial<Theme> | ((outerTheme: Theme) => Theme);
children: React.ReactNode;
}
export interface ThemeProvider {
(props: ThemeProviderProps): React.ReactElement;
}
export type WithTheme<P, T> = P extends {
theme: infer Theme;
} ? P & {
theme: Exclude<Theme, undefined>;
} : P & {
theme: T;
};
export declare const ThemeContext: React.Context<Theme>;
export declare const useTheme: () => Theme;
export interface ThemeProviderProps {
theme: Partial<Theme> | ((outerTheme: Theme) => Theme);
children: React.ReactNode;
}
export declare const ThemeProvider: (props: ThemeProviderProps) => React.JSX.Element;
export declare function withTheme<C extends React.ComponentType<React.ComponentProps<C>>>(Component: C): React.ForwardRefExoticComponent<DistributiveOmit<PropsOf<C>, 'theme'> & {
theme?: Theme;
}>;

View File

@@ -0,0 +1 @@
{"version":3,"sources":["../../src/d1/driver.ts"],"sourcesContent":["/// <reference types=\"@cloudflare/workers-types\" />\nimport type { D1Database as MiniflareD1Database } from '@miniflare/d1';\nimport type { BatchItem, BatchResponse } from '~/batch.ts';\nimport { entityKind } from '~/entity.ts';\nimport { DefaultLogger } from '~/logger.ts';\nimport {\n\tcreateTableRelationsHelpers,\n\textractTablesRelationalConfig,\n\ttype ExtractTablesWithRelations,\n\ttype RelationalSchemaConfig,\n\ttype TablesRelationalConfig,\n} from '~/relations.ts';\nimport { BaseSQLiteDatabase } from '~/sqlite-core/db.ts';\nimport { SQLiteAsyncDialect } from '~/sqlite-core/dialect.ts';\nimport type { DrizzleConfig, IfNotImported } from '~/utils.ts';\nimport { SQLiteD1Session } from './session.ts';\n\nexport type AnyD1Database = IfNotImported<\n\tD1Database,\n\tMiniflareD1Database,\n\tD1Database | IfNotImported<MiniflareD1Database, never, MiniflareD1Database>\n>;\n\nexport class DrizzleD1Database<\n\tTSchema extends Record<string, unknown> = Record<string, never>,\n> extends BaseSQLiteDatabase<'async', D1Result, TSchema> {\n\tstatic override readonly [entityKind]: string = 'D1Database';\n\n\t/** @internal */\n\tdeclare readonly session: SQLiteD1Session<TSchema, ExtractTablesWithRelations<TSchema>>;\n\n\tasync batch<U extends BatchItem<'sqlite'>, T extends Readonly<[U, ...U[]]>>(\n\t\tbatch: T,\n\t): Promise<BatchResponse<T>> {\n\t\treturn this.session.batch(batch) as Promise<BatchResponse<T>>;\n\t}\n}\n\nexport function drizzle<\n\tTSchema extends Record<string, unknown> = Record<string, never>,\n\tTClient extends AnyD1Database = AnyD1Database,\n>(\n\tclient: TClient,\n\tconfig: DrizzleConfig<TSchema> = {},\n): DrizzleD1Database<TSchema> & {\n\t$client: TClient;\n} {\n\tconst dialect = new SQLiteAsyncDialect({ casing: config.casing });\n\tlet logger;\n\tif (config.logger === true) {\n\t\tlogger = new DefaultLogger();\n\t} else if (config.logger !== false) {\n\t\tlogger = config.logger;\n\t}\n\n\tlet schema: RelationalSchemaConfig<TablesRelationalConfig> | undefined;\n\tif (config.schema) {\n\t\tconst tablesConfig = extractTablesRelationalConfig(\n\t\t\tconfig.schema,\n\t\t\tcreateTableRelationsHelpers,\n\t\t);\n\t\tschema = {\n\t\t\tfullSchema: config.schema,\n\t\t\tschema: tablesConfig.tables,\n\t\t\ttableNamesMap: tablesConfig.tableNamesMap,\n\t\t};\n\t}\n\n\tconst session = new SQLiteD1Session(client as D1Database, dialect, schema, { logger, cache: config.cache });\n\tconst db = new DrizzleD1Database('async', dialect, session, schema) as DrizzleD1Database<TSchema>;\n\t(<any> db).$client = client;\n\t(<any> db).$cache = config.cache;\n\tif ((<any> db).$cache) {\n\t\t(<any> db).$cache['invalidate'] = config.cache?.onMutate;\n\t}\n\n\treturn db as any;\n}\n"],"mappings":"AAGA,SAAS,kBAAkB;AAC3B,SAAS,qBAAqB;AAC9B;AAAA,EACC;AAAA,EACA;AAAA,OAIM;AACP,SAAS,0BAA0B;AACnC,SAAS,0BAA0B;AAEnC,SAAS,uBAAuB;AAQzB,MAAM,0BAEH,mBAA+C;AAAA,EACxD,QAA0B,UAAU,IAAY;AAAA,EAKhD,MAAM,MACL,OAC4B;AAC5B,WAAO,KAAK,QAAQ,MAAM,KAAK;AAAA,EAChC;AACD;AAEO,SAAS,QAIf,QACA,SAAiC,CAAC,GAGjC;AACD,QAAM,UAAU,IAAI,mBAAmB,EAAE,QAAQ,OAAO,OAAO,CAAC;AAChE,MAAI;AACJ,MAAI,OAAO,WAAW,MAAM;AAC3B,aAAS,IAAI,cAAc;AAAA,EAC5B,WAAW,OAAO,WAAW,OAAO;AACnC,aAAS,OAAO;AAAA,EACjB;AAEA,MAAI;AACJ,MAAI,OAAO,QAAQ;AAClB,UAAM,eAAe;AAAA,MACpB,OAAO;AAAA,MACP;AAAA,IACD;AACA,aAAS;AAAA,MACR,YAAY,OAAO;AAAA,MACnB,QAAQ,aAAa;AAAA,MACrB,eAAe,aAAa;AAAA,IAC7B;AAAA,EACD;AAEA,QAAM,UAAU,IAAI,gBAAgB,QAAsB,SAAS,QAAQ,EAAE,QAAQ,OAAO,OAAO,MAAM,CAAC;AAC1G,QAAM,KAAK,IAAI,kBAAkB,SAAS,SAAS,SAAS,MAAM;AAClE,EAAO,GAAI,UAAU;AACrB,EAAO,GAAI,SAAS,OAAO;AAC3B,MAAW,GAAI,QAAQ;AACtB,IAAO,GAAI,OAAO,YAAY,IAAI,OAAO,OAAO;AAAA,EACjD;AAEA,SAAO;AACR;","names":[]}

View File

@@ -0,0 +1 @@
{"version":3,"file":"archive-restore.js","sources":["../../../src/icons/archive-restore.ts"],"sourcesContent":["import createLucideIcon from '../createLucideIcon';\n\n/**\n * @component @name ArchiveRestore\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview ![img](data:image/svg+xml;base64,PHN2ZyAgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIgogIHdpZHRoPSIyNCIKICBoZWlnaHQ9IjI0IgogIHZpZXdCb3g9IjAgMCAyNCAyNCIKICBmaWxsPSJub25lIgogIHN0cm9rZT0iIzAwMCIgc3R5bGU9ImJhY2tncm91bmQtY29sb3I6ICNmZmY7IGJvcmRlci1yYWRpdXM6IDJweCIKICBzdHJva2Utd2lkdGg9IjIiCiAgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIgogIHN0cm9rZS1saW5lam9pbj0icm91bmQiCj4KICA8cmVjdCB3aWR0aD0iMjAiIGhlaWdodD0iNSIgeD0iMiIgeT0iMyIgcng9IjEiIC8+CiAgPHBhdGggZD0iTTQgOHYxMWEyIDIgMCAwIDAgMiAyaDIiIC8+CiAgPHBhdGggZD0iTTIwIDh2MTFhMiAyIDAgMCAxLTIgMmgtMiIgLz4KICA8cGF0aCBkPSJtOSAxNSAzLTMgMyAzIiAvPgogIDxwYXRoIGQ9Ik0xMiAxMnY5IiAvPgo8L3N2Zz4K) - https://lucide.dev/icons/archive-restore\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 ArchiveRestore = createLucideIcon('ArchiveRestore', [\n ['rect', { width: '20', height: '5', x: '2', y: '3', rx: '1', key: '1wp1u1' }],\n ['path', { d: 'M4 8v11a2 2 0 0 0 2 2h2', key: 'tvwodi' }],\n ['path', { d: 'M20 8v11a2 2 0 0 1-2 2h-2', key: '1gkqxj' }],\n ['path', { d: 'm9 15 3-3 3 3', key: '1pd0qc' }],\n ['path', { d: 'M12 12v9', key: '192myk' }],\n]);\n\nexport default ArchiveRestore;\n"],"names":[],"mappings":";;;;;;;;;AAaM,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAiB,iBAAiB,gBAAkB,CAAA,CAAA,CAAA;AAAA,CAAA,CACxD,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAE,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAO,MAAM,CAAQ,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,CAAG,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,GAAG,CAAK,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAI,CAAK,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CAC7E,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAA2B,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,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,CACxD,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,CAAA;AAAA,CAAA,CAC1D,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAiB,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,CAC9C,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,18 @@
"use client";
import { IntlProvider } from 'use-intl/react';
import { jsx } from 'react/jsx-runtime';
function NextIntlClientProvider({
locale,
...rest
}) {
if (!locale) {
throw new Error("Couldn't infer the `locale` prop in `NextIntlClientProvider`, please provide it explicitly.\n\nSee https://next-intl.dev/docs/configuration#locale" );
}
return /*#__PURE__*/jsx(IntlProvider, {
locale: locale,
...rest
});
}
export { NextIntlClientProvider as default };

View File

@@ -0,0 +1 @@
{"version":3,"file":"gen-ai-attributes.d.ts","sourceRoot":"","sources":["../../../../src/tracing/ai/gen-ai-attributes.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAMH;;GAEG;AACH,eAAO,MAAM,uBAAuB,kBAAkB,CAAC;AAEvD;;;GAGG;AACH,eAAO,MAAM,uBAAuB,kBAAkB,CAAC;AAEvD;;;GAGG;AACH,eAAO,MAAM,8BAA8B,yBAAyB,CAAC;AAErE;;GAEG;AACH,eAAO,MAAM,+BAA+B,0BAA0B,CAAC;AAEvE;;GAEG;AACH,eAAO,MAAM,oCAAoC,+BAA+B,CAAC;AAEjF;;GAEG;AACH,eAAO,MAAM,mCAAmC,8BAA8B,CAAC;AAE/E;;GAEG;AACH,eAAO,MAAM,0CAA0C,qCAAqC,CAAC;AAE7F;;GAEG;AACH,eAAO,MAAM,yCAAyC,oCAAoC,CAAC;AAE3F;;GAEG;AACH,eAAO,MAAM,8BAA8B,yBAAyB,CAAC;AAErE;;GAEG;AACH,eAAO,MAAM,8BAA8B,yBAAyB,CAAC;AAErE;;GAEG;AACH,eAAO,MAAM,uCAAuC,kCAAkC,CAAC;AAEvF;;GAEG;AACH,eAAO,MAAM,wCAAwC,mCAAmC,CAAC;AAEzF;;GAEG;AACH,eAAO,MAAM,mCAAmC,8BAA8B,CAAC;AAE/E;;GAEG;AACH,eAAO,MAAM,wCAAwC,mCAAmC,CAAC;AAEzF;;GAEG;AACH,eAAO,MAAM,+BAA+B,0BAA0B,CAAC;AAEvE;;GAEG;AACH,eAAO,MAAM,4BAA4B,uBAAuB,CAAC;AAEjE;;GAEG;AACH,eAAO,MAAM,qCAAqC,gCAAgC,CAAC;AAEnF;;GAEG;AACH,eAAO,MAAM,mCAAmC,8BAA8B,CAAC;AAE/E;;GAEG;AACH,eAAO,MAAM,oCAAoC,+BAA+B,CAAC;AAEjF;;GAEG;AACH,eAAO,MAAM,mCAAmC,8BAA8B,CAAC;AAE/E;;GAEG;AACH,eAAO,MAAM,+BAA+B,0BAA0B,CAAC;AAEvE;;GAEG;AACH,eAAO,MAAM,+CAA+C,0DAA0D,CAAC;AAEvH;;;GAGG;AACH,eAAO,MAAM,+BAA+B,0BAA0B,CAAC;AAEvE;;;;GAIG;AACH,eAAO,MAAM,oCAAoC,+BAA+B,CAAC;AAEjF;;;GAGG;AACH,eAAO,MAAM,8BAA8B,yBAAyB,CAAC;AAErE;;;GAGG;AACH,eAAO,MAAM,wCAAwC,mCAAmC,CAAC;AAEzF;;GAEG;AACH,eAAO,MAAM,mCAAmC,8BAA8B,CAAC;AAE/E;;;GAGG;AACH,eAAO,MAAM,oCAAoC,+BAA+B,CAAC;AAEjF;;GAEG;AACH,eAAO,MAAM,2BAA2B,sBAAsB,CAAC;AAE/D;;GAEG;AACH,eAAO,MAAM,8BAA8B,yBAAyB,CAAC;AAErE;;;;GAIG;AACH,eAAO,MAAM,gCAAgC,2BAA2B,CAAC;AAEzE;;GAEG;AACH,eAAO,MAAM,kDAAkD,6CAA6C,CAAC;AAE7G;;GAEG;AACH,eAAO,MAAM,8CAA8C,yCAAyC,CAAC;AAErG;;GAEG;AACH,eAAO,MAAM,+CAA+C,0CAA0C,CAAC;AAEvG;;GAEG;AACH,eAAO,MAAM,0CAA0C,qCAAqC,CAAC;AAE7F;;GAEG;AACH,eAAO,MAAM,uCAAuC,wBAAwB,CAAC;AAE7E;;GAEG;AACH,eAAO,MAAM,oDAAoD,yBAAyB,CAAC;AAE3F;;GAEG;AACH,eAAO,MAAM,gDAAgD,uBAAuB,CAAC;AAErF;;GAEG;AACH,eAAO,MAAM,sDAAsD,2BAA2B,CAAC;AAE/F;;GAEG;AACH,eAAO,MAAM,kDAAkD,yBAAyB,CAAC;AAEzF;;;GAGG;AACH,eAAO,MAAM,iCAAiC,4BAA4B,CAAC;AAE3E;;GAEG;AACH,eAAO,MAAM,yCAAyC,iBAAiB,CAAC;AAExE;;GAEG;AACH,eAAO,MAAM,8CAA8C,sBAAsB,CAAC;AAElF;;GAEG;AACH,eAAO,MAAM,2CAA2C,kBAAkB,CAAC;AAE3E;;GAEG;AACH,eAAO,MAAM,uCAAuC,wBAAwB,CAAC;AAE7E;;GAEG;AACH,eAAO,MAAM,0BAA0B,qBAAqB,CAAC;AAE7D;;GAEG;AACH,eAAO,MAAM,6BAA6B,wBAAwB,CAAC;AAEnE;;GAEG;AACH,eAAO,MAAM,0BAA0B,qBAAqB,CAAC;AAE7D;;GAEG;AACH,eAAO,MAAM,2BAA2B,sBAAsB,CAAC;AAE/D;;GAEG;AACH,eAAO,MAAM,4BAA4B,uBAAuB,CAAC;AAMjE;;GAEG;AACH,eAAO,MAAM,4BAA4B,uBAAuB,CAAC;AAEjE;;GAEG;AACH,eAAO,MAAM,+BAA+B,0BAA0B,CAAC;AAEvE;;GAEG;AACH,eAAO,MAAM,mCAAmC,8BAA8B,CAAC;AAE/E;;GAEG;AACH,eAAO,MAAM,wCAAwC,mCAAmC,CAAC;AAEzF;;GAEG;AACH,eAAO,MAAM,oCAAoC,+BAA+B,CAAC;AAMjF;;;GAGG;AACH,eAAO,MAAM,iBAAiB;;;CAGpB,CAAC;AAMX;;GAEG;AACH,eAAO,MAAM,yCAAyC,iCAAiC,CAAC"}

View File

@@ -0,0 +1,36 @@
import { toDate } from "./toDate.js";
/**
* The {@link startOfMinute} function options.
*/
/**
* @name startOfMinute
* @category Minute Helpers
* @summary Return the start of a minute for the given date.
*
* @description
* Return the start of a minute for the given date.
* The result will be in the local timezone.
*
* @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).
* @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.
*
* @param date - The original date
* @param options - An object with options
*
* @returns The start of a minute
*
* @example
* // The start of a minute for 1 December 2014 22:15:45.400:
* const result = startOfMinute(new Date(2014, 11, 1, 22, 15, 45, 400))
* //=> Mon Dec 01 2014 22:15:00
*/
export function startOfMinute(date, options) {
const date_ = toDate(date, options?.in);
date_.setSeconds(0, 0);
return date_;
}
// Fallback for modularized imports:
export default startOfMinute;

View File

@@ -0,0 +1,118 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.createHandler = exports.parseRequestParams = void 0;
const handler_1 = require("../handler");
/**
* The GraphQL over HTTP spec compliant request parser for an incoming GraphQL request.
*
* If the HTTP request _is not_ a [well-formatted GraphQL over HTTP request](https://graphql.github.io/graphql-over-http/draft/#sec-Request), the function will respond
* on the `ServerResponse` argument and return `null`.
*
* If the HTTP request _is_ a [well-formatted GraphQL over HTTP request](https://graphql.github.io/graphql-over-http/draft/#sec-Request), but is invalid or malformed,
* the function will throw an error and it is up to the user to handle and respond as they see fit.
*
* ```js
* import http from 'http';
* import { parseRequestParams } from 'graphql-http/lib/use/http';
*
* const server = http.createServer(async (req, res) => {
* if (req.url.startsWith('/graphql')) {
* try {
* const maybeParams = await parseRequestParams(req, res);
* if (!maybeParams) {
* // not a well-formatted GraphQL over HTTP request,
* // parser responded and there's nothing else to do
* return;
* }
*
* // well-formatted GraphQL over HTTP request,
* // with valid parameters
* res.writeHead(200).end(JSON.stringify(maybeParams, null, ' '));
* } catch (err) {
* // well-formatted GraphQL over HTTP request,
* // but with invalid parameters
* res.writeHead(400).end(err.message);
* }
* } else {
* res.writeHead(404).end();
* }
* });
*
* server.listen(4000);
* console.log('Listening to port 4000');
* ```
*
* @category Server/http
*/
async function parseRequestParams(req, res) {
const rawReq = toRequest(req, res);
const paramsOrRes = await (0, handler_1.parseRequestParams)(rawReq);
if (!('query' in paramsOrRes)) {
const [body, init] = paramsOrRes;
res.writeHead(init.status, init.statusText, init.headers).end(body);
return null;
}
return paramsOrRes;
}
exports.parseRequestParams = parseRequestParams;
/**
* Create a GraphQL over HTTP spec compliant request handler for
* the Node environment http module.
*
* ```js
* import http from 'http';
* import { createHandler } from 'graphql-http/lib/use/http';
* import { schema } from './my-graphql-schema';
*
* const server = http.createServer(createHandler({ schema }));
*
* server.listen(4000);
* console.log('Listening to port 4000');
* ```
*
* @category Server/http
*/
function createHandler(options) {
const handle = (0, handler_1.createHandler)(options);
return async function requestListener(req, res) {
try {
if (!req.url) {
throw new Error('Missing request URL');
}
if (!req.method) {
throw new Error('Missing request method');
}
const [body, init] = await handle(toRequest(req, res));
res.writeHead(init.status, init.statusText, init.headers).end(body);
}
catch (err) {
// The handler shouldnt throw errors.
// If you wish to handle them differently, consider implementing your own request handler.
console.error('Internal error occurred during request handling. ' +
'Please check your implementation.', err);
res.writeHead(500).end();
}
};
}
exports.createHandler = createHandler;
function toRequest(req, res) {
if (!req.url) {
throw new Error('Missing request URL');
}
if (!req.method) {
throw new Error('Missing request method');
}
return {
url: req.url,
method: req.method,
headers: req.headers,
body: () => new Promise((resolve) => {
let body = '';
req.setEncoding('utf-8');
req.on('data', (chunk) => (body += chunk));
req.on('end', () => resolve(body));
}),
raw: req,
context: { res },
};
}

View File

@@ -0,0 +1 @@
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/detectors/platform/node/index.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;;AAEH,+CAA8C;AAArC,4GAAA,YAAY,OAAA;AACrB,2CAA0C;AAAjC,wGAAA,UAAU,OAAA;AACnB,qDAAoD;AAA3C,kHAAA,eAAe,OAAA;AACxB,yEAAwE;AAA/D,sIAAA,yBAAyB,OAAA","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 { hostDetector } from './HostDetector';\nexport { osDetector } from './OSDetector';\nexport { processDetector } from './ProcessDetector';\nexport { serviceInstanceIdDetector } from './ServiceInstanceIdDetector';\n"]}

View File

@@ -0,0 +1 @@
{"version":3,"sources":["../../../src/pg-core/columns/macaddr.ts"],"sourcesContent":["import type { ColumnBuilderBaseConfig, ColumnBuilderRuntimeConfig, MakeColumnConfig } from '~/column-builder.ts';\nimport type { ColumnBaseConfig } from '~/column.ts';\nimport { entityKind } from '~/entity.ts';\nimport type { AnyPgTable } from '../table.ts';\nimport { PgColumn, PgColumnBuilder } from './common.ts';\n\nexport type PgMacaddrBuilderInitial<TName extends string> = PgMacaddrBuilder<{\n\tname: TName;\n\tdataType: 'string';\n\tcolumnType: 'PgMacaddr';\n\tdata: string;\n\tdriverParam: string;\n\tenumValues: undefined;\n}>;\n\nexport class PgMacaddrBuilder<T extends ColumnBuilderBaseConfig<'string', 'PgMacaddr'>> extends PgColumnBuilder<T> {\n\tstatic override readonly [entityKind]: string = 'PgMacaddrBuilder';\n\n\tconstructor(name: T['name']) {\n\t\tsuper(name, 'string', 'PgMacaddr');\n\t}\n\n\t/** @internal */\n\toverride build<TTableName extends string>(\n\t\ttable: AnyPgTable<{ name: TTableName }>,\n\t): PgMacaddr<MakeColumnConfig<T, TTableName>> {\n\t\treturn new PgMacaddr<MakeColumnConfig<T, TTableName>>(table, this.config as ColumnBuilderRuntimeConfig<any, any>);\n\t}\n}\n\nexport class PgMacaddr<T extends ColumnBaseConfig<'string', 'PgMacaddr'>> extends PgColumn<T> {\n\tstatic override readonly [entityKind]: string = 'PgMacaddr';\n\n\tgetSQLType(): string {\n\t\treturn 'macaddr';\n\t}\n}\n\nexport function macaddr(): PgMacaddrBuilderInitial<''>;\nexport function macaddr<TName extends string>(name: TName): PgMacaddrBuilderInitial<TName>;\nexport function macaddr(name?: string) {\n\treturn new PgMacaddrBuilder(name ?? '');\n}\n"],"mappings":"AAEA,SAAS,kBAAkB;AAE3B,SAAS,UAAU,uBAAuB;AAWnC,MAAM,yBAAmF,gBAAmB;AAAA,EAClH,QAA0B,UAAU,IAAY;AAAA,EAEhD,YAAY,MAAiB;AAC5B,UAAM,MAAM,UAAU,WAAW;AAAA,EAClC;AAAA;AAAA,EAGS,MACR,OAC6C;AAC7C,WAAO,IAAI,UAA2C,OAAO,KAAK,MAA8C;AAAA,EACjH;AACD;AAEO,MAAM,kBAAqE,SAAY;AAAA,EAC7F,QAA0B,UAAU,IAAY;AAAA,EAEhD,aAAqB;AACpB,WAAO;AAAA,EACR;AACD;AAIO,SAAS,QAAQ,MAAe;AACtC,SAAO,IAAI,iBAAiB,QAAQ,EAAE;AACvC;","names":[]}

View File

@@ -0,0 +1,25 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const codegen_1 = require("../../compile/codegen");
const util_1 = require("../../compile/util");
const equal_1 = require("../../runtime/equal");
const error = {
message: "must be equal to constant",
params: ({ schemaCode }) => (0, codegen_1._) `{allowedValue: ${schemaCode}}`,
};
const def = {
keyword: "const",
$data: true,
error,
code(cxt) {
const { gen, data, $data, schemaCode, schema } = cxt;
if ($data || (schema && typeof schema == "object")) {
cxt.fail$data((0, codegen_1._) `!${(0, util_1.useFunc)(gen, equal_1.default)}(${data}, ${schemaCode})`);
}
else {
cxt.fail((0, codegen_1._) `${schema} !== ${data}`);
}
},
};
exports.default = def;
//# sourceMappingURL=const.js.map

View File

@@ -0,0 +1,56 @@
"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 schema_exports = {};
__export(schema_exports, {
MySqlSchema: () => MySqlSchema,
isMySqlSchema: () => isMySqlSchema,
mysqlDatabase: () => mysqlDatabase,
mysqlSchema: () => mysqlSchema
});
module.exports = __toCommonJS(schema_exports);
var import_entity = require("../entity.cjs");
var import_table = require("./table.cjs");
var import_view = require("./view.cjs");
class MySqlSchema {
constructor(schemaName) {
this.schemaName = schemaName;
}
static [import_entity.entityKind] = "MySqlSchema";
table = (name, columns, extraConfig) => {
return (0, import_table.mysqlTableWithSchema)(name, columns, extraConfig, this.schemaName);
};
view = (name, columns) => {
return (0, import_view.mysqlViewWithSchema)(name, columns, this.schemaName);
};
}
function isMySqlSchema(obj) {
return (0, import_entity.is)(obj, MySqlSchema);
}
function mysqlDatabase(name) {
return new MySqlSchema(name);
}
const mysqlSchema = mysqlDatabase;
// Annotate the CommonJS export names for ESM import in node:
0 && (module.exports = {
MySqlSchema,
isMySqlSchema,
mysqlDatabase,
mysqlSchema
});
//# sourceMappingURL=schema.cjs.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"operations.js","names":[],"sources":["../../../../src/rest/commands/delete/operations.ts"],"sourcesContent":["import type { DirectusOperation } from '../../../schema/operation.js';\nimport type { RestCommand } from '../../types.js';\nimport { throwIfEmpty } from '../../utils/index.js';\n\n/**\n * Delete multiple existing operations.\n * @param keys\n * @returns\n * @throws Will throw if keys is empty\n */\nexport const deleteOperations =\n\t<Schema>(keys: DirectusOperation<Schema>['id'][]): RestCommand<void, Schema> =>\n\t() => {\n\t\tthrowIfEmpty(keys, 'Keys cannot be empty');\n\n\t\treturn {\n\t\t\tpath: `/operations`,\n\t\t\tbody: JSON.stringify(keys),\n\t\t\tmethod: 'DELETE',\n\t\t};\n\t};\n\n/**\n * Delete an existing operation.\n * @param key\n * @returns\n * @throws Will throw if key is empty\n */\nexport const deleteOperation =\n\t<Schema>(key: DirectusOperation<Schema>['id']): RestCommand<void, Schema> =>\n\t() => {\n\t\tthrowIfEmpty(key, 'Key cannot be empty');\n\n\t\treturn {\n\t\t\tpath: `/operations/${key}`,\n\t\t\tmethod: 'DELETE',\n\t\t};\n\t};\n"],"mappings":"6DAUA,MAAa,EACH,QAER,EAAa,EAAM,uBAAuB,CAEnC,CACN,KAAM,cACN,KAAM,KAAK,UAAU,EAAK,CAC1B,OAAQ,SACR,EASU,EACH,QAER,EAAa,EAAK,sBAAsB,CAEjC,CACN,KAAM,eAAe,IACrB,OAAQ,SACR"}

View File

@@ -0,0 +1,16 @@
import type {Vocabulary} from "../../types"
import idKeyword from "./id"
import refKeyword from "./ref"
const core: Vocabulary = [
"$schema",
"$id",
"$defs",
"$vocabulary",
{keyword: "$comment"},
"definitions",
idKeyword,
refKeyword,
]
export default core

View File

@@ -0,0 +1,10 @@
/* Fallback, in case JS does not run, to ensure the code is at least visible */
[class*='lang-'] script[type='text/plain'],
[class*='language-'] script[type='text/plain'],
script[type='text/plain'][class*='lang-'],
script[type='text/plain'][class*='language-'] {
display: block;
font: 100% Consolas, Monaco, monospace;
white-space: pre;
overflow: auto;
}

View File

@@ -0,0 +1,18 @@
import { DirectusUser } from "./user.cjs";
import { MergeCoreCollection } from "../types/schema.cjs";
//#region src/schema/notification.d.ts
type DirectusNotification<Schema = any> = MergeCoreCollection<Schema, 'directus_notifications', {
id: string;
timestamp: 'datetime' | null;
status: string | null;
recipient: DirectusUser<Schema> | string;
sender: DirectusUser<Schema> | string | null;
subject: string;
message: string | null;
collection: string | null;
item: string | null;
}>;
//#endregion
export { DirectusNotification };
//# sourceMappingURL=notification.d.cts.map

View File

@@ -0,0 +1,47 @@
declare function getComputedStyle_2(element: Element): CSSStyleDeclaration;
export { getComputedStyle_2 as getComputedStyle }
export declare function getContainingBlock(element: Element): HTMLElement | null;
export declare function getDocumentElement(node: Node | Window): HTMLElement;
export declare function getFrameElement(win: Window): Element | null;
export declare function getNearestOverflowAncestor(node: Node): HTMLElement;
export declare function getNodeName(node: Node | Window): string;
export declare function getNodeScroll(element: Element | Window): {
scrollLeft: number;
scrollTop: number;
};
export declare function getOverflowAncestors(node: Node, list?: OverflowAncestors, traverseIframes?: boolean): OverflowAncestors;
export declare function getParentNode(node: Node): Node;
export declare function getWindow(node: any): typeof window;
export declare function isContainingBlock(elementOrCss: Element | CSSStyleDeclaration): boolean;
export declare function isElement(value: unknown): value is Element;
export declare function isHTMLElement(value: unknown): value is HTMLElement;
export declare function isLastTraversableNode(node: Node): boolean;
export declare function isNode(value: unknown): value is Node;
export declare function isOverflowElement(element: Element): boolean;
export declare function isShadowRoot(value: unknown): value is ShadowRoot;
export declare function isTableElement(element: Element): boolean;
export declare function isTopLayer(element: Element): boolean;
export declare function isWebKit(): boolean;
declare type OverflowAncestors = Array<Element | Window | VisualViewport>;
export { }

View File

@@ -0,0 +1,2 @@
import type { Localize } from "../../types.js";
export declare const localize: Localize;

View File

@@ -0,0 +1,38 @@
import { GraphQLScalarType, Kind } from 'graphql';
import { createGraphQLError } from '../error.js';
const RGBA_REGEX = /^rgba\(\s*(-?\d+|-?\d*\.\d+(?=%))(%?)\s*,\s*(-?\d+|-?\d*\.\d+(?=%))(\2)\s*,\s*(-?\d+|-?\d*\.\d+(?=%))(\2)\s*,\s*(-?\d+|-?\d*.\d+)\s*\)$/;
const validate = (value, ast) => {
if (typeof value !== 'string') {
throw createGraphQLError(`Value is not string: ${value}`, ast ? { nodes: ast } : undefined);
}
if (!RGBA_REGEX.test(value)) {
throw createGraphQLError(`Value is not a valid RGBA color: ${value}`, ast ? { nodes: ast } : undefined);
}
return value;
};
export const GraphQLRGBA = /*#__PURE__*/ new GraphQLScalarType({
name: `RGBA`,
description: `A field whose value is a CSS RGBA color: https://developer.mozilla.org/en-US/docs/Web/CSS/color_value#rgb()_and_rgba().`,
serialize(value) {
return validate(value);
},
parseValue(value) {
return validate(value);
},
parseLiteral(ast) {
if (ast.kind !== Kind.STRING) {
throw createGraphQLError(`Can only validate strings as RGBA colors but got a: ${ast.kind}`, {
nodes: ast,
});
}
return validate(ast.value, ast);
},
extensions: {
codegenScalarType: 'string',
jsonSchema: {
title: 'RGBA',
type: 'string',
pattern: RGBA_REGEX.source,
},
},
});

View File

@@ -0,0 +1,2 @@
export { MouseSensor } from './MouseSensor';
export type { MouseSensorOptions, MouseSensorProps } from './MouseSensor';

View File

@@ -0,0 +1,35 @@
"use strict";
/*
* 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.
*/
Object.defineProperty(exports, "__esModule", { value: true });
exports.getStringListFromEnv = exports.getNumberFromEnv = exports.getBooleanFromEnv = exports.getStringFromEnv = void 0;
function getStringFromEnv(_) {
return undefined;
}
exports.getStringFromEnv = getStringFromEnv;
function getBooleanFromEnv(_) {
return undefined;
}
exports.getBooleanFromEnv = getBooleanFromEnv;
function getNumberFromEnv(_) {
return undefined;
}
exports.getNumberFromEnv = getNumberFromEnv;
function getStringListFromEnv(_) {
return undefined;
}
exports.getStringListFromEnv = getStringListFromEnv;
//# sourceMappingURL=environment.js.map

View File

@@ -0,0 +1,4 @@
export declare const nextTuesday: import("./types.js").FPFn1<
Date,
import("../fp.js").DateArg<Date>
>;

View File

@@ -0,0 +1,23 @@
/**
* Takes the SDK metadata and adds the user-agent header to the transport options.
* This ensures that the SDK sends the user-agent header with SDK name and version to
* all requests made by the transport.
*
* @see https://develop.sentry.dev/sdk/overview/#user-agent
*/
function addUserAgentToTransportHeaders(options) {
const sdkMetadata = options._metadata?.sdk;
const sdkUserAgent =
sdkMetadata?.name && sdkMetadata?.version ? `${sdkMetadata?.name}/${sdkMetadata?.version}` : undefined;
options.transportOptions = {
...options.transportOptions,
headers: {
...(sdkUserAgent && { 'user-agent': sdkUserAgent }),
...options.transportOptions?.headers,
},
};
}
export { addUserAgentToTransportHeaders };
//# sourceMappingURL=userAgent.js.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"getNameFromDrizzleTable.d.ts","sourceRoot":"","sources":["../../src/utilities/getNameFromDrizzleTable.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,aAAa,CAAA;AAIxC,eAAO,MAAM,uBAAuB,UAAW,KAAK,KAAG,MAEtD,CAAA"}

View File

@@ -0,0 +1,103 @@
import { getNamedType, isInterfaceType, isObjectType, isUnionType, Kind } from 'graphql';
export function buildSelectForCollection(info) {
return buildSelect(info);
}
export function buildSelectForCollectionMany(info) {
return buildSelect(info).docs;
}
export function resolveSelect(info, select) {
if (select) {
const traversePath = [];
const traverseTree = (path)=>{
const pathKey = path.key;
const pathType = info.schema.getType(path.typename);
if (pathType) {
const field = pathType?.getFields()?.[pathKey]?.extensions?.field;
if (field?.type === 'join') {
path = path.prev;
traversePath.unshift('docs');
}
if (field?.type === 'relationship' && Array.isArray(field.relationTo)) {
path = path.prev;
traversePath.unshift('value');
}
if (field) {
traversePath.unshift(field.name);
}
}
if (path.prev) {
traverseTree(path.prev);
}
};
traverseTree(info.path);
traversePath.forEach((key)=>{
select = select?.[key];
});
}
return select;
}
function buildSelect(info) {
const returnType = getNamedType(info.returnType);
const selectionSet = info.fieldNodes[0].selectionSet;
if (!returnType) {
return;
}
return buildSelectTree(info, selectionSet, returnType);
}
function buildSelectTree(info, selectionSet, type) {
const fieldMap = type.getFields?.();
const fieldTree = {};
for (const selection of selectionSet.selections){
switch(selection.kind){
case Kind.FIELD:
{
const fieldName = selection.name.value;
const fieldSchema = fieldMap?.[fieldName];
const field = fieldSchema?.extensions?.field;
const fieldNameOriginal = field?.name || fieldName;
if (fieldName === '__typename') {
continue;
}
if (fieldSchema == undefined) {
continue;
}
if (selection.selectionSet) {
const type = getNamedType(fieldSchema.type);
if (isObjectType(type) || isInterfaceType(type) || isUnionType(type)) {
fieldTree[fieldNameOriginal] = buildSelectTree(info, selection.selectionSet, type);
continue;
}
}
fieldTree[fieldNameOriginal] = true;
break;
}
case Kind.FRAGMENT_SPREAD:
{
const fragmentName = selection.name.value;
const fragment = info.fragments[fragmentName];
const fragmentType = fragment && info.schema.getType(fragment.typeCondition.name.value);
if (fragmentType) {
Object.assign(fieldTree, buildSelectTree(info, fragment.selectionSet, fragmentType));
}
break;
}
case Kind.INLINE_FRAGMENT:
{
const fragmentType = selection.typeCondition ? info.schema.getType(selection.typeCondition.name.value) : type;
if (fragmentType) {
// Block types in unions need selections nested under their slug
const blockSlug = fragmentType.extensions?.blockSlug;
if (blockSlug && isUnionType(type)) {
fieldTree[blockSlug] = buildSelectTree(info, selection.selectionSet, fragmentType);
} else {
Object.assign(fieldTree, buildSelectTree(info, selection.selectionSet, fragmentType));
}
}
break;
}
}
}
return fieldTree;
}
//# sourceMappingURL=select.js.map

View File

@@ -0,0 +1,224 @@
import { DEBUG_BUILD } from '../debug-build.js';
import { defineIntegration } from '../integration.js';
import { debug } from '../utils/debug-logger.js';
import { getPossibleEventMessages } from '../utils/eventUtils.js';
import { getEventDescription } from '../utils/misc.js';
import { stringMatchesSomePattern } from '../utils/string.js';
// "Script error." is hard coded into browsers for errors that it can't read.
// this is the result of a script being pulled in from an external domain and CORS.
const DEFAULT_IGNORE_ERRORS = [
/^Script error\.?$/,
/^Javascript error: Script error\.? on line 0$/,
/^ResizeObserver loop completed with undelivered notifications.$/, // The browser logs this when a ResizeObserver handler takes a bit longer. Usually this is not an actual issue though. It indicates slowness.
/^Cannot redefine property: googletag$/, // This is thrown when google tag manager is used in combination with an ad blocker
/^Can't find variable: gmo$/, // Error from Google Search App https://issuetracker.google.com/issues/396043331
/^undefined is not an object \(evaluating 'a\.[A-Z]'\)$/, // Random error that happens but not actionable or noticeable to end-users.
'can\'t redefine non-configurable property "solana"', // Probably a browser extension or custom browser (Brave) throwing this error
"vv().getRestrictions is not a function. (In 'vv().getRestrictions(1,a)', 'vv().getRestrictions' is undefined)", // Error thrown by GTM, seemingly not affecting end-users
"Can't find variable: _AutofillCallbackHandler", // Unactionable error in instagram webview https://developers.facebook.com/community/threads/320013549791141/
/^Non-Error promise rejection captured with value: Object Not Found Matching Id:\d+, MethodName:simulateEvent, ParamCount:\d+$/, // unactionable error from CEFSharp, a .NET library that embeds chromium in .NET apps
/^Java exception was raised during method invocation$/, // error from Facebook Mobile browser (https://github.com/getsentry/sentry-javascript/issues/15065)
];
/** Options for the EventFilters integration */
const INTEGRATION_NAME = 'EventFilters';
/**
* An integration that filters out events (errors and transactions) based on:
*
* - (Errors) A curated list of known low-value or irrelevant errors (see {@link DEFAULT_IGNORE_ERRORS})
* - (Errors) A list of error messages or urls/filenames passed in via
* - Top level Sentry.init options (`ignoreErrors`, `denyUrls`, `allowUrls`)
* - The same options passed to the integration directly via @param options
* - (Transactions/Spans) A list of root span (transaction) names passed in via
* - Top level Sentry.init option (`ignoreTransactions`)
* - The same option passed to the integration directly via @param options
*
* Events filtered by this integration will not be sent to Sentry.
*/
const eventFiltersIntegration = defineIntegration((options = {}) => {
let mergedOptions;
return {
name: INTEGRATION_NAME,
setup(client) {
const clientOptions = client.getOptions();
mergedOptions = _mergeOptions(options, clientOptions);
},
processEvent(event, _hint, client) {
if (!mergedOptions) {
const clientOptions = client.getOptions();
mergedOptions = _mergeOptions(options, clientOptions);
}
return _shouldDropEvent(event, mergedOptions) ? null : event;
},
};
});
/**
* An integration that filters out events (errors and transactions) based on:
*
* - (Errors) A curated list of known low-value or irrelevant errors (see {@link DEFAULT_IGNORE_ERRORS})
* - (Errors) A list of error messages or urls/filenames passed in via
* - Top level Sentry.init options (`ignoreErrors`, `denyUrls`, `allowUrls`)
* - The same options passed to the integration directly via @param options
* - (Transactions/Spans) A list of root span (transaction) names passed in via
* - Top level Sentry.init option (`ignoreTransactions`)
* - The same option passed to the integration directly via @param options
*
* Events filtered by this integration will not be sent to Sentry.
*
* @deprecated this integration was renamed and will be removed in a future major version.
* Use `eventFiltersIntegration` instead.
*/
const inboundFiltersIntegration = defineIntegration(((options = {}) => {
return {
...eventFiltersIntegration(options),
name: 'InboundFilters',
};
}) );
function _mergeOptions(
internalOptions = {},
clientOptions = {},
) {
return {
allowUrls: [...(internalOptions.allowUrls || []), ...(clientOptions.allowUrls || [])],
denyUrls: [...(internalOptions.denyUrls || []), ...(clientOptions.denyUrls || [])],
ignoreErrors: [
...(internalOptions.ignoreErrors || []),
...(clientOptions.ignoreErrors || []),
...(internalOptions.disableErrorDefaults ? [] : DEFAULT_IGNORE_ERRORS),
],
ignoreTransactions: [...(internalOptions.ignoreTransactions || []), ...(clientOptions.ignoreTransactions || [])],
};
}
function _shouldDropEvent(event, options) {
if (!event.type) {
// Filter errors
if (_isIgnoredError(event, options.ignoreErrors)) {
DEBUG_BUILD &&
debug.warn(
`Event dropped due to being matched by \`ignoreErrors\` option.\nEvent: ${getEventDescription(event)}`,
);
return true;
}
if (_isUselessError(event)) {
DEBUG_BUILD &&
debug.warn(
`Event dropped due to not having an error message, error type or stacktrace.\nEvent: ${getEventDescription(
event,
)}`,
);
return true;
}
if (_isDeniedUrl(event, options.denyUrls)) {
DEBUG_BUILD &&
debug.warn(
`Event dropped due to being matched by \`denyUrls\` option.\nEvent: ${getEventDescription(
event,
)}.\nUrl: ${_getEventFilterUrl(event)}`,
);
return true;
}
if (!_isAllowedUrl(event, options.allowUrls)) {
DEBUG_BUILD &&
debug.warn(
`Event dropped due to not being matched by \`allowUrls\` option.\nEvent: ${getEventDescription(
event,
)}.\nUrl: ${_getEventFilterUrl(event)}`,
);
return true;
}
} else if (event.type === 'transaction') {
// Filter transactions
if (_isIgnoredTransaction(event, options.ignoreTransactions)) {
DEBUG_BUILD &&
debug.warn(
`Event dropped due to being matched by \`ignoreTransactions\` option.\nEvent: ${getEventDescription(event)}`,
);
return true;
}
}
return false;
}
function _isIgnoredError(event, ignoreErrors) {
if (!ignoreErrors?.length) {
return false;
}
return getPossibleEventMessages(event).some(message => stringMatchesSomePattern(message, ignoreErrors));
}
function _isIgnoredTransaction(event, ignoreTransactions) {
if (!ignoreTransactions?.length) {
return false;
}
const name = event.transaction;
return name ? stringMatchesSomePattern(name, ignoreTransactions) : false;
}
function _isDeniedUrl(event, denyUrls) {
if (!denyUrls?.length) {
return false;
}
const url = _getEventFilterUrl(event);
return !url ? false : stringMatchesSomePattern(url, denyUrls);
}
function _isAllowedUrl(event, allowUrls) {
if (!allowUrls?.length) {
return true;
}
const url = _getEventFilterUrl(event);
return !url ? true : stringMatchesSomePattern(url, allowUrls);
}
function _getLastValidUrl(frames = []) {
for (let i = frames.length - 1; i >= 0; i--) {
const frame = frames[i];
if (frame && frame.filename !== '<anonymous>' && frame.filename !== '[native code]') {
return frame.filename || null;
}
}
return null;
}
function _getEventFilterUrl(event) {
try {
// If there are linked exceptions or exception aggregates we only want to match against the top frame of the "root" (the main exception)
// The root always comes last in linked exceptions
const rootException = [...(event.exception?.values ?? [])]
.reverse()
.find(value => value.mechanism?.parent_id === undefined && value.stacktrace?.frames?.length);
const frames = rootException?.stacktrace?.frames;
return frames ? _getLastValidUrl(frames) : null;
} catch {
DEBUG_BUILD && debug.error(`Cannot extract url for event ${getEventDescription(event)}`);
return null;
}
}
function _isUselessError(event) {
// We only want to consider events for dropping that actually have recorded exception values.
if (!event.exception?.values?.length) {
return false;
}
return (
// No top-level message
!event.message &&
// There are no exception values that have a stacktrace, a non-generic-Error type or value
!event.exception.values.some(value => value.stacktrace || (value.type && value.type !== 'Error') || value.value)
);
}
export { eventFiltersIntegration, inboundFiltersIntegration };
//# sourceMappingURL=eventFilters.js.map

View File

@@ -0,0 +1,18 @@
/**
* @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 FileKey = createLucideIcon("FileKey", [
["path", { d: "M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z", key: "1rqfz7" }],
["circle", { cx: "10", cy: "16", r: "2", key: "4ckbqe" }],
["path", { d: "m16 10-4.5 4.5", key: "7p3ebg" }],
["path", { d: "m15 11 1 1", key: "1bsyx3" }]
]);
export { FileKey as default };
//# sourceMappingURL=file-key.js.map

View File

@@ -0,0 +1,38 @@
import { GraphQLScalarType, Kind } from 'graphql';
import { createGraphQLError } from '../error.js';
const HSLA_REGEX = /^hsla\(\s*(-?\d+|-?\d*.\d+)\s*,\s*(-?\d+|-?\d*.\d+)%\s*,\s*(-?\d+|-?\d*.\d+)%\s*,\s*(-?\d+|-?\d*.\d+)\s*\)$/;
const validate = (value, ast) => {
if (typeof value !== 'string') {
throw createGraphQLError(`Value is not string: ${value}`, ast ? { nodes: ast } : undefined);
}
if (!HSLA_REGEX.test(value)) {
throw createGraphQLError(`Value is not a valid HSLA color: ${value}`, ast ? { nodes: ast } : undefined);
}
return value;
};
export const GraphQLHSLA = /*#__PURE__*/ new GraphQLScalarType({
name: `HSLA`,
description: `A field whose value is a CSS HSLA color: https://developer.mozilla.org/en-US/docs/Web/CSS/color_value#hsl()_and_hsla().`,
serialize(value) {
return validate(value);
},
parseValue(value) {
return validate(value);
},
parseLiteral(ast) {
if (ast.kind !== Kind.STRING) {
throw createGraphQLError(`Can only validate strings as HSLA colors but got a: ${ast.kind}`, {
nodes: ast,
});
}
return validate(ast.value, ast);
},
extensions: {
codegenScalarType: 'string',
jsonSchema: {
title: 'HSLA',
type: 'string',
pattern: HSLA_REGEX.source,
},
},
});

View File

@@ -0,0 +1 @@
{"version":3,"file":"version.js","sourceRoot":"","sources":["../../src/version.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,4DAA4D;AAC5D,MAAM,CAAC,IAAM,OAAO,GAAG,OAAO,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 */\n\n// this is autogenerated file, see scripts/version-update.js\nexport const VERSION = '1.9.0';\n"]}

View File

@@ -0,0 +1,485 @@
import { describe, it, expect } from 'vitest';
import { sanitizeConfig } from '../config/sanitize.js';
import { configToJSONSchema } from './configToJSONSchema.js';
describe('configToJSONSchema', ()=>{
it('should handle optional arrays with required fields', async ()=>{
// @ts-expect-error
const config = {
collections: [
{
slug: 'test',
fields: [
{
name: 'someRequiredField',
type: 'array',
fields: [
{
name: 'someRequiredField',
type: 'text',
required: true
}
]
}
],
timestamps: false
}
]
};
const sanitizedConfig = await sanitizeConfig(config);
const schema = configToJSONSchema(sanitizedConfig, 'text');
expect(schema?.definitions?.test).toStrictEqual({
type: 'object',
additionalProperties: false,
properties: {
id: {
type: 'string'
},
someRequiredField: {
type: [
'array',
'null'
],
items: {
type: 'object',
additionalProperties: false,
properties: {
id: {
type: [
'string',
'null'
]
},
someRequiredField: {
type: 'string'
}
},
required: [
'someRequiredField'
]
}
}
},
required: [
'id'
],
title: 'Test'
});
});
it('should handle block fields with no blocks', async ()=>{
// @ts-expect-error
const config = {
collections: [
{
slug: 'test',
fields: [
{
name: 'blockField',
type: 'blocks',
blocks: []
},
{
name: 'blockFieldRequired',
type: 'blocks',
blocks: [],
required: true
},
{
name: 'blockFieldWithFields',
type: 'blocks',
blocks: [
{
slug: 'test',
fields: [
{
name: 'field',
type: 'text'
}
]
}
]
},
{
name: 'blockFieldWithFieldsRequired',
type: 'blocks',
blocks: [
{
slug: 'test',
fields: [
{
name: 'field',
type: 'text',
required: true
}
]
}
]
}
],
timestamps: false
}
]
};
const sanitizedConfig = await sanitizeConfig(config);
const schema = configToJSONSchema(sanitizedConfig, 'text');
expect(schema?.definitions?.test).toStrictEqual({
type: 'object',
additionalProperties: false,
properties: {
id: {
type: 'string'
},
blockField: {
type: [
'array',
'null'
],
items: {}
},
blockFieldRequired: {
type: 'array',
items: {}
},
blockFieldWithFields: {
type: [
'array',
'null'
],
items: {
oneOf: [
{
type: 'object',
additionalProperties: false,
properties: {
id: {
type: [
'string',
'null'
]
},
blockName: {
type: [
'string',
'null'
]
},
blockType: {
const: 'test'
},
field: {
type: [
'string',
'null'
]
}
},
required: [
'blockType'
]
}
]
}
},
blockFieldWithFieldsRequired: {
type: [
'array',
'null'
],
items: {
oneOf: [
{
type: 'object',
additionalProperties: false,
properties: {
id: {
type: [
'string',
'null'
]
},
blockName: {
type: [
'string',
'null'
]
},
blockType: {
const: 'test'
},
field: {
type: 'string'
}
},
required: [
'blockType',
'field'
]
}
]
}
}
},
required: [
'id',
'blockFieldRequired'
],
title: 'Test'
});
});
it('should handle tabs and named tabs with required fields', async ()=>{
// @ts-expect-error
const config = {
collections: [
{
slug: 'test',
fields: [
{
type: 'tabs',
tabs: [
{
fields: [
{
name: 'fieldInUnnamedTab',
type: 'text'
}
],
label: 'unnamedTab'
},
{
name: 'namedTab',
fields: [
{
name: 'fieldInNamedTab',
type: 'text'
}
],
label: 'namedTab'
},
{
name: 'namedTabWithRequired',
fields: [
{
name: 'fieldInNamedTab',
type: 'text',
required: true
}
],
label: 'namedTabWithRequired'
}
]
}
],
timestamps: false
}
]
};
const sanitizedConfig = await sanitizeConfig(config);
const schema = configToJSONSchema(sanitizedConfig, 'text');
expect(schema?.definitions?.test).toStrictEqual({
type: 'object',
additionalProperties: false,
properties: {
id: {
type: 'string'
},
fieldInUnnamedTab: {
type: [
'string',
'null'
]
},
namedTab: {
type: 'object',
additionalProperties: false,
properties: {
fieldInNamedTab: {
type: [
'string',
'null'
]
}
},
required: []
},
namedTabWithRequired: {
type: 'object',
additionalProperties: false,
properties: {
fieldInNamedTab: {
type: 'string'
}
},
required: [
'fieldInNamedTab'
]
}
},
required: [
'id',
'namedTabWithRequired'
],
title: 'Test'
});
});
it('should handle custom typescript schema and JSON field schema', async ()=>{
const customSchema = {
type: 'object',
properties: {
id: {
type: 'number'
},
required: [
'id'
]
}
};
const config = {
collections: [
{
slug: 'test',
fields: [
{
name: 'withCustom',
type: 'text',
typescriptSchema: [
()=>customSchema
]
},
{
name: 'jsonWithSchema',
type: 'json',
jsonSchema: {
fileMatch: [
'a://b/foo.json'
],
schema: customSchema,
uri: 'a://b/foo.json'
}
}
],
timestamps: false
}
]
};
const sanitizedConfig = await sanitizeConfig(config);
const schema = configToJSONSchema(sanitizedConfig, 'text');
expect(schema?.definitions?.test).toStrictEqual({
type: 'object',
additionalProperties: false,
properties: {
id: {
type: 'string'
},
jsonWithSchema: customSchema,
withCustom: customSchema
},
required: [
'id'
],
title: 'Test'
});
});
it('should handle same block object being referenced in both collection and config.blocks', async ()=>{
const sharedBlock = {
slug: 'sharedBlock',
interfaceName: 'SharedBlock',
fields: [
{
name: 'richText',
type: 'richText',
editor: ()=>{
// stub rich text editor
return {
CellComponent: '',
FieldComponent: '',
validate: ()=>true
};
}
}
]
};
// @ts-expect-error
const config = {
blocks: [
sharedBlock
],
collections: [
{
slug: 'test',
fields: [
{
name: 'someBlockField',
type: 'blocks',
blocks: [
sharedBlock
]
}
],
timestamps: false
}
]
};
// Ensure both rich text editor are sanitized
const sanitizedConfig = await sanitizeConfig(config);
expect(typeof sanitizedConfig?.blocks?.[0]?.fields?.[0]?.editor).toBe('object');
expect(typeof sanitizedConfig.collections[0].fields[0]?.blocks?.[0]?.fields?.[0]?.editor).toBe('object');
const schema = configToJSONSchema(sanitizedConfig, 'text');
expect(schema?.definitions?.test).toStrictEqual({
type: 'object',
additionalProperties: false,
title: 'Test',
properties: {
id: {
type: 'string'
},
someBlockField: {
type: [
'array',
'null'
],
items: {
oneOf: [
{
$ref: '#/definitions/SharedBlock'
}
]
}
}
},
required: [
'id'
]
});
expect(schema?.definitions?.SharedBlock).toBeDefined();
});
it('should allow overriding required to false', async ()=>{
// @ts-expect-error
const config = {
collections: [
{
slug: 'test',
fields: [
{
name: 'title',
type: 'text',
required: true,
defaultValue: 'test',
typescriptSchema: [
()=>({
type: 'string',
required: false
})
]
}
],
timestamps: false
}
]
};
const sanitizedConfig = await sanitizeConfig(config);
const schema = configToJSONSchema(sanitizedConfig, 'text');
// @ts-expect-error
expect(schema.definitions.test.properties.title.required).toStrictEqual(false);
});
});
//# sourceMappingURL=configToJSONSchema.spec.js.map

View File

@@ -0,0 +1,11 @@
import { HTMLProjectionNode } from '../../projection/node/HTMLProjectionNode.mjs';
import { MeasureLayout } from './layout/MeasureLayout.mjs';
const layout = {
layout: {
ProjectionNode: HTMLProjectionNode,
MeasureLayout,
},
};
export { layout };

View File

@@ -0,0 +1,4 @@
/** If this attribute is true, it means that the parent is a remote span. */
export declare const SEMANTIC_ATTRIBUTE_SENTRY_PARENT_IS_REMOTE = "sentry.parentIsRemote";
export declare const SEMANTIC_ATTRIBUTE_SENTRY_GRAPHQL_OPERATION = "sentry.graphql.operation";
//# sourceMappingURL=semanticAttributes.d.ts.map

View File

@@ -0,0 +1,29 @@
import { formatDistance } from "./is/_lib/formatDistance.js";
import { formatLong } from "./is/_lib/formatLong.js";
import { formatRelative } from "./is/_lib/formatRelative.js";
import { localize } from "./is/_lib/localize.js";
import { match } from "./is/_lib/match.js";
/**
* @category Locales
* @summary Icelandic locale.
* @language Icelandic
* @iso-639-2 isl
* @author Derek Blank [@derekblank](https://github.com/derekblank)
* @author Arnór Ýmir [@lamayg](https://github.com/lamayg)
*/
export const is = {
code: "is",
formatDistance: formatDistance,
formatLong: formatLong,
formatRelative: formatRelative,
localize: localize,
match: match,
options: {
weekStartsOn: 1 /* Monday */,
firstWeekContainsDate: 4,
},
};
// Fallback for modularized imports:
export default is;

View File

@@ -0,0 +1,164 @@
/*
MIT License http://www.opensource.org/licenses/mit-license.php
Author Tobias Koppers @sokra
*/
"use strict";
const TOMBSTONE = Symbol("tombstone");
const UNDEFINED_MARKER = Symbol("undefined");
/**
* @template T
* @typedef {T | undefined} Cell<T>
*/
/**
* @template T
* @typedef {T | typeof TOMBSTONE | typeof UNDEFINED_MARKER} InternalCell<T>
*/
/**
* @template K
* @template V
* @param {[K, InternalCell<V>]} pair the internal cell
* @returns {[K, Cell<V>]} its “safe” representation
*/
const extractPair = (pair) => {
const key = pair[0];
const val = pair[1];
if (val === UNDEFINED_MARKER || val === TOMBSTONE) {
return [key, undefined];
}
return /** @type {[K, Cell<V>]} */ (pair);
};
/**
* @template K
* @template V
*/
class StackedMap {
/**
* @param {Map<K, InternalCell<V>>[]=} parentStack an optional parent
*/
constructor(parentStack) {
/** @type {Map<K, InternalCell<V>>} */
this.map = new Map();
/** @type {Map<K, InternalCell<V>>[]} */
this.stack = parentStack === undefined ? [] : [...parentStack];
this.stack.push(this.map);
}
/**
* @param {K} item the key of the element to add
* @param {V} value the value of the element to add
* @returns {void}
*/
set(item, value) {
this.map.set(item, value === undefined ? UNDEFINED_MARKER : value);
}
/**
* @param {K} item the item to delete
* @returns {void}
*/
delete(item) {
if (this.stack.length > 1) {
this.map.set(item, TOMBSTONE);
} else {
this.map.delete(item);
}
}
/**
* @param {K} item the item to test
* @returns {boolean} true if the item exists in this set
*/
has(item) {
const topValue = this.map.get(item);
if (topValue !== undefined) {
return topValue !== TOMBSTONE;
}
if (this.stack.length > 1) {
for (let i = this.stack.length - 2; i >= 0; i--) {
const value = this.stack[i].get(item);
if (value !== undefined) {
this.map.set(item, value);
return value !== TOMBSTONE;
}
}
this.map.set(item, TOMBSTONE);
}
return false;
}
/**
* @param {K} item the key of the element to return
* @returns {Cell<V>} the value of the element
*/
get(item) {
const topValue = this.map.get(item);
if (topValue !== undefined) {
return topValue === TOMBSTONE || topValue === UNDEFINED_MARKER
? undefined
: topValue;
}
if (this.stack.length > 1) {
for (let i = this.stack.length - 2; i >= 0; i--) {
const value = this.stack[i].get(item);
if (value !== undefined) {
this.map.set(item, value);
return value === TOMBSTONE || value === UNDEFINED_MARKER
? undefined
: value;
}
}
this.map.set(item, TOMBSTONE);
}
}
_compress() {
if (this.stack.length === 1) return;
this.map = new Map();
for (const data of this.stack) {
for (const pair of data) {
if (pair[1] === TOMBSTONE) {
this.map.delete(pair[0]);
} else {
this.map.set(pair[0], pair[1]);
}
}
}
this.stack = [this.map];
}
asArray() {
this._compress();
return [...this.map.keys()];
}
asSet() {
this._compress();
return new Set(this.map.keys());
}
asPairArray() {
this._compress();
return Array.from(this.map.entries(), extractPair);
}
asMap() {
return new Map(this.asPairArray());
}
get size() {
this._compress();
return this.map.size;
}
createChild() {
return new StackedMap(this.stack);
}
}
module.exports = StackedMap;

View File

@@ -0,0 +1 @@
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/platform/node/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAE,kBAAkB,EAAE,MAAM,6BAA6B,CAAC;AACjE,OAAO,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,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 */\n\nexport { BatchSpanProcessor } from './export/BatchSpanProcessor';\nexport { RandomIdGenerator } from './RandomIdGenerator';\n"]}

View File

@@ -0,0 +1,30 @@
import { formatDistance } from "./fi/_lib/formatDistance.js";
import { formatLong } from "./fi/_lib/formatLong.js";
import { formatRelative } from "./fi/_lib/formatRelative.js";
import { localize } from "./fi/_lib/localize.js";
import { match } from "./fi/_lib/match.js";
/**
* @category Locales
* @summary Finnish locale.
* @language Finnish
* @iso-639-2 fin
* @author Pyry-Samuli Lahti [@Pyppe](https://github.com/Pyppe)
* @author Edo Rivai [@mikolajgrzyb](https://github.com/mikolajgrzyb)
* @author Samu Juvonen [@sjuvonen](https://github.com/sjuvonen)
*/
export const fi = {
code: "fi",
formatDistance: formatDistance,
formatLong: formatLong,
formatRelative: formatRelative,
localize: localize,
match: match,
options: {
weekStartsOn: 1 /* Monday */,
firstWeekContainsDate: 4,
},
};
// Fallback for modularized imports:
export default fi;

View File

@@ -0,0 +1,9 @@
/**
* 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 e=require("@lexical/clipboard"),t=require("@lexical/selection"),n=require("@lexical/utils"),r=require("lexical");const i="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement,o=i&&"documentMode"in document?document.documentMode:null,a=!(!i||!("InputEvent"in window)||o)&&"getTargetRanges"in new window.InputEvent("input"),l=i&&/Version\/[\d.]+.*Safari/.test(navigator.userAgent),s=i&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream,R=i&&/^(?=.*Chrome).*/i.test(navigator.userAgent),c=i&&/AppleWebKit\/[\d.]+/.test(navigator.userAgent)&&!R;function O(t,i){i.update((()=>{if(null!==t){const o=n.objectKlassEquals(t,KeyboardEvent)?null:t.clipboardData,a=r.$getSelection();if(null!==a&&null!=o){t.preventDefault();const n=e.$getHtmlContent(i);null!==n&&o.setData("text/html",n),o.setData("text/plain",a.getTextContent())}}}))}exports.registerPlainText=function(i){const o=n.mergeRegister(i.registerCommand(r.DELETE_CHARACTER_COMMAND,(e=>{const t=r.$getSelection();return!!r.$isRangeSelection(t)&&(t.deleteCharacter(e),!0)}),r.COMMAND_PRIORITY_EDITOR),i.registerCommand(r.DELETE_WORD_COMMAND,(e=>{const t=r.$getSelection();return!!r.$isRangeSelection(t)&&(t.deleteWord(e),!0)}),r.COMMAND_PRIORITY_EDITOR),i.registerCommand(r.DELETE_LINE_COMMAND,(e=>{const t=r.$getSelection();return!!r.$isRangeSelection(t)&&(t.deleteLine(e),!0)}),r.COMMAND_PRIORITY_EDITOR),i.registerCommand(r.CONTROLLED_TEXT_INSERTION_COMMAND,(t=>{const n=r.$getSelection();if(!r.$isRangeSelection(n))return!1;if("string"==typeof t)n.insertText(t);else{const r=t.dataTransfer;if(null!=r)e.$insertDataTransferForPlainText(r,n);else{const e=t.data;e&&n.insertText(e)}}return!0}),r.COMMAND_PRIORITY_EDITOR),i.registerCommand(r.REMOVE_TEXT_COMMAND,(()=>{const e=r.$getSelection();return!!r.$isRangeSelection(e)&&(e.removeText(),!0)}),r.COMMAND_PRIORITY_EDITOR),i.registerCommand(r.INSERT_LINE_BREAK_COMMAND,(e=>{const t=r.$getSelection();return!!r.$isRangeSelection(t)&&(t.insertLineBreak(e),!0)}),r.COMMAND_PRIORITY_EDITOR),i.registerCommand(r.INSERT_PARAGRAPH_COMMAND,(()=>{const e=r.$getSelection();return!!r.$isRangeSelection(e)&&(e.insertLineBreak(),!0)}),r.COMMAND_PRIORITY_EDITOR),i.registerCommand(r.KEY_ARROW_LEFT_COMMAND,(e=>{const n=r.$getSelection();if(!r.$isRangeSelection(n))return!1;const i=e,o=i.shiftKey;return!!t.$shouldOverrideDefaultCharacterSelection(n,!0)&&(i.preventDefault(),t.$moveCharacter(n,o,!0),!0)}),r.COMMAND_PRIORITY_EDITOR),i.registerCommand(r.KEY_ARROW_RIGHT_COMMAND,(e=>{const n=r.$getSelection();if(!r.$isRangeSelection(n))return!1;const i=e,o=i.shiftKey;return!!t.$shouldOverrideDefaultCharacterSelection(n,!1)&&(i.preventDefault(),t.$moveCharacter(n,o,!1),!0)}),r.COMMAND_PRIORITY_EDITOR),i.registerCommand(r.KEY_BACKSPACE_COMMAND,(e=>{const t=r.$getSelection();return!!r.$isRangeSelection(t)&&((!s||"ko-KR"!==navigator.language)&&(e.preventDefault(),i.dispatchCommand(r.DELETE_CHARACTER_COMMAND,!0)))}),r.COMMAND_PRIORITY_EDITOR),i.registerCommand(r.KEY_DELETE_COMMAND,(e=>{const t=r.$getSelection();return!!r.$isRangeSelection(t)&&(e.preventDefault(),i.dispatchCommand(r.DELETE_CHARACTER_COMMAND,!1))}),r.COMMAND_PRIORITY_EDITOR),i.registerCommand(r.KEY_ENTER_COMMAND,(e=>{const t=r.$getSelection();if(!r.$isRangeSelection(t))return!1;if(null!==e){if((s||l||c)&&a)return!1;e.preventDefault()}return i.dispatchCommand(r.INSERT_LINE_BREAK_COMMAND,!1)}),r.COMMAND_PRIORITY_EDITOR),i.registerCommand(r.SELECT_ALL_COMMAND,(()=>(r.$selectAll(),!0)),r.COMMAND_PRIORITY_EDITOR),i.registerCommand(r.COPY_COMMAND,(e=>{const t=r.$getSelection();return!!r.$isRangeSelection(t)&&(O(e,i),!0)}),r.COMMAND_PRIORITY_EDITOR),i.registerCommand(r.CUT_COMMAND,(e=>{const t=r.$getSelection();return!!r.$isRangeSelection(t)&&(function(e,t){O(e,t),t.update((()=>{const e=r.$getSelection();r.$isRangeSelection(e)&&e.removeText()}))}(e,i),!0)}),r.COMMAND_PRIORITY_EDITOR),i.registerCommand(r.PASTE_COMMAND,(t=>{const o=r.$getSelection();return!!r.$isRangeSelection(o)&&(function(t,i){t.preventDefault(),i.update((()=>{const i=r.$getSelection(),o=n.objectKlassEquals(t,ClipboardEvent)?t.clipboardData:null;null!=o&&r.$isRangeSelection(i)&&e.$insertDataTransferForPlainText(o,i)}),{tag:r.PASTE_TAG})}(t,i),!0)}),r.COMMAND_PRIORITY_EDITOR),i.registerCommand(r.DROP_COMMAND,(e=>{const t=r.$getSelection();return!!r.$isRangeSelection(t)&&(e.preventDefault(),!0)}),r.COMMAND_PRIORITY_EDITOR),i.registerCommand(r.DRAGSTART_COMMAND,(e=>{const t=r.$getSelection();return!!r.$isRangeSelection(t)&&(e.preventDefault(),!0)}),r.COMMAND_PRIORITY_EDITOR));return o};

View File

@@ -0,0 +1,55 @@
"use strict";
exports.LocalWeekParser = void 0;
var _index = require("../../../setWeek.js");
var _index2 = require("../../../startOfWeek.js");
var _constants = require("../constants.js");
var _Parser = require("../Parser.js");
var _utils = require("../utils.js");
// Local week of year
class LocalWeekParser extends _Parser.Parser {
priority = 100;
parse(dateString, token, match) {
switch (token) {
case "w":
return (0, _utils.parseNumericPattern)(
_constants.numericPatterns.week,
dateString,
);
case "wo":
return match.ordinalNumber(dateString, { unit: "week" });
default:
return (0, _utils.parseNDigits)(token.length, dateString);
}
}
validate(_date, value) {
return value >= 1 && value <= 53;
}
set(date, _flags, value, options) {
return (0, _index2.startOfWeek)(
(0, _index.setWeek)(date, value, options),
options,
);
}
incompatibleTokens = [
"y",
"R",
"u",
"q",
"Q",
"M",
"L",
"I",
"d",
"D",
"i",
"t",
"T",
];
}
exports.LocalWeekParser = LocalWeekParser;

View File

@@ -0,0 +1,69 @@
{
"name": "@opentelemetry/instrumentation-ioredis",
"version": "0.59.0",
"description": "OpenTelemetry instrumentation for `ioredis` database redis client for Redis",
"main": "build/src/index.js",
"types": "build/src/index.d.ts",
"repository": {
"type": "git",
"url": "https://github.com/open-telemetry/opentelemetry-js-contrib.git",
"directory": "packages/instrumentation-ioredis"
},
"scripts": {
"clean": "rimraf build/*",
"compile": "tsc -p .",
"compile:with-dependencies": "nx run-many -t compile -p @opentelemetry/instrumentation-ioredis",
"lint:readme": "node ../../scripts/lint-readme.js",
"prepublishOnly": "npm run compile",
"test": "nyc --no-clean mocha 'test/**/*.test.ts'",
"test-all-versions": "tav",
"tdd": "npm run test -- --watch-extensions ts --watch",
"test:debug": "cross-env RUN_REDIS_TESTS=true mocha --inspect-brk --no-timeouts 'test/**/*.test.ts'",
"test:with-services-env": "cross-env NODE_OPTIONS='-r dotenv/config' DOTENV_CONFIG_PATH=../../test/test-services.env npm test",
"test-all-versions:with-services-env": "cross-env NODE_OPTIONS='-r dotenv/config' DOTENV_CONFIG_PATH=../../test/test-services.env npm run test-all-versions",
"test-services:start": "cd ../.. && npm run test-services:start redis",
"test-services:stop": "cd ../.. && npm run test-services:stop redis",
"version:update": "node ../../scripts/version-update.js"
},
"keywords": [
"instrumentation",
"ioredis",
"nodejs",
"opentelemetry",
"profiling",
"redis",
"tracing"
],
"author": "OpenTelemetry Authors",
"license": "Apache-2.0",
"engines": {
"node": "^18.19.0 || >=20.6.0"
},
"files": [
"build/src/**/*.js",
"build/src/**/*.js.map",
"build/src/**/*.d.ts"
],
"publishConfig": {
"access": "public"
},
"peerDependencies": {
"@opentelemetry/api": "^1.3.0"
},
"devDependencies": {
"@opentelemetry/api": "^1.3.0",
"@opentelemetry/context-async-hooks": "^2.0.0",
"@opentelemetry/contrib-test-utils": "^0.58.0",
"@opentelemetry/sdk-trace-base": "^2.0.0",
"@opentelemetry/sdk-trace-node": "^2.0.0",
"@types/ioredis4": "npm:@types/ioredis@4.28.10",
"ioredis": "5.8.2"
},
"dependencies": {
"@opentelemetry/instrumentation": "^0.211.0",
"@opentelemetry/redis-common": "^0.38.2",
"@opentelemetry/semantic-conventions": "^1.33.0"
},
"homepage": "https://github.com/open-telemetry/opentelemetry-js-contrib/tree/main/packages/instrumentation-ioredis#readme",
"gitHead": "7a5f3c0a09b6a2d32c712b2962b95137c906a016"
}

View File

@@ -0,0 +1,19 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.addInspectMethod = exports.format = void 0;
/**
* Ono supports custom formatters for error messages. In Node.js, it defaults
* to the `util.format()` function. In browsers, it defaults to `Array.join()`.
*
* The Node.js functionality can be used in a web browser via a polyfill,
* such as "format-util".
*
* @see https://github.com/tmpfs/format-util
*/
exports.format = false;
/**
* The `util.inspect()` functionality only applies to Node.js.
* We return the constant `false` here so that the Node-specific code gets removed by tree-shaking.
*/
exports.addInspectMethod = false;
//# sourceMappingURL=isomorphic.browser.js.map

View File

@@ -0,0 +1,33 @@
import type { Config } from '../../config/types.js';
import type { GlobalConfig } from '../../globals/config/types.js';
import type { TaskType } from './types/taskTypes.js';
import type { WorkflowTypes } from './types/workflowTypes.js';
export declare const jobStatsGlobalSlug = "payload-jobs-stats";
/**
* Type for data stored in the payload-jobs-stats global.
*/
export type JobStats = {
stats?: {
scheduledRuns?: {
queues?: {
[queueSlug: string]: {
tasks?: {
[taskSlug: TaskType]: {
lastScheduledRun: string;
};
};
workflows?: {
[workflowSlug: WorkflowTypes]: {
lastScheduledRun: string;
};
};
};
};
};
};
};
/**
* Global config for job statistics.
*/
export declare const getJobStatsGlobal: (config: Config) => GlobalConfig;
//# sourceMappingURL=global.d.ts.map

View File

@@ -0,0 +1,226 @@
"use strict";
exports.localize = void 0;
var _index = require("../../_lib/buildLocalizeFn.cjs");
const eraValues = {
narrow: ["pr. Kr.", "po Kr."],
abbreviated: ["pr. Kr.", "po Kr."],
wide: ["prieš Kristų", "po Kristaus"],
};
const quarterValues = {
narrow: ["1", "2", "3", "4"],
abbreviated: ["I ketv.", "II ketv.", "III ketv.", "IV ketv."],
wide: ["I ketvirtis", "II ketvirtis", "III ketvirtis", "IV ketvirtis"],
};
const formattingQuarterValues = {
narrow: ["1", "2", "3", "4"],
abbreviated: ["I k.", "II k.", "III k.", "IV k."],
wide: ["I ketvirtis", "II ketvirtis", "III ketvirtis", "IV ketvirtis"],
};
const monthValues = {
narrow: ["S", "V", "K", "B", "G", "B", "L", "R", "R", "S", "L", "G"],
abbreviated: [
"saus.",
"vas.",
"kov.",
"bal.",
"geg.",
"birž.",
"liep.",
"rugp.",
"rugs.",
"spal.",
"lapkr.",
"gruod.",
],
wide: [
"sausis",
"vasaris",
"kovas",
"balandis",
"gegužė",
"birželis",
"liepa",
"rugpjūtis",
"rugsėjis",
"spalis",
"lapkritis",
"gruodis",
],
};
const formattingMonthValues = {
narrow: ["S", "V", "K", "B", "G", "B", "L", "R", "R", "S", "L", "G"],
abbreviated: [
"saus.",
"vas.",
"kov.",
"bal.",
"geg.",
"birž.",
"liep.",
"rugp.",
"rugs.",
"spal.",
"lapkr.",
"gruod.",
],
wide: [
"sausio",
"vasario",
"kovo",
"balandžio",
"gegužės",
"birželio",
"liepos",
"rugpjūčio",
"rugsėjo",
"spalio",
"lapkričio",
"gruodžio",
],
};
const dayValues = {
narrow: ["S", "P", "A", "T", "K", "P", "Š"],
short: ["Sk", "Pr", "An", "Tr", "Kt", "Pn", "Št"],
abbreviated: ["sk", "pr", "an", "tr", "kt", "pn", "št"],
wide: [
"sekmadienis",
"pirmadienis",
"antradienis",
"trečiadienis",
"ketvirtadienis",
"penktadienis",
"šeštadienis",
],
};
const formattingDayValues = {
narrow: ["S", "P", "A", "T", "K", "P", "Š"],
short: ["Sk", "Pr", "An", "Tr", "Kt", "Pn", "Št"],
abbreviated: ["sk", "pr", "an", "tr", "kt", "pn", "št"],
wide: [
"sekmadienį",
"pirmadienį",
"antradienį",
"trečiadienį",
"ketvirtadienį",
"penktadienį",
"šeštadienį",
],
};
const dayPeriodValues = {
narrow: {
am: "pr. p.",
pm: "pop.",
midnight: "vidurnaktis",
noon: "vidurdienis",
morning: "rytas",
afternoon: "diena",
evening: "vakaras",
night: "naktis",
},
abbreviated: {
am: "priešpiet",
pm: "popiet",
midnight: "vidurnaktis",
noon: "vidurdienis",
morning: "rytas",
afternoon: "diena",
evening: "vakaras",
night: "naktis",
},
wide: {
am: "priešpiet",
pm: "popiet",
midnight: "vidurnaktis",
noon: "vidurdienis",
morning: "rytas",
afternoon: "diena",
evening: "vakaras",
night: "naktis",
},
};
const formattingDayPeriodValues = {
narrow: {
am: "pr. p.",
pm: "pop.",
midnight: "vidurnaktis",
noon: "perpiet",
morning: "rytas",
afternoon: "popietė",
evening: "vakaras",
night: "naktis",
},
abbreviated: {
am: "priešpiet",
pm: "popiet",
midnight: "vidurnaktis",
noon: "perpiet",
morning: "rytas",
afternoon: "popietė",
evening: "vakaras",
night: "naktis",
},
wide: {
am: "priešpiet",
pm: "popiet",
midnight: "vidurnaktis",
noon: "perpiet",
morning: "rytas",
afternoon: "popietė",
evening: "vakaras",
night: "naktis",
},
};
const ordinalNumber = (dirtyNumber, _options) => {
const number = Number(dirtyNumber);
return number + "-oji";
};
const localize = (exports.localize = {
ordinalNumber,
era: (0, _index.buildLocalizeFn)({
values: eraValues,
defaultWidth: "wide",
}),
quarter: (0, _index.buildLocalizeFn)({
values: quarterValues,
defaultWidth: "wide",
formattingValues: formattingQuarterValues,
defaultFormattingWidth: "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",
formattingValues: formattingDayValues,
defaultFormattingWidth: "wide",
}),
dayPeriod: (0, _index.buildLocalizeFn)({
values: dayPeriodValues,
defaultWidth: "wide",
formattingValues: formattingDayPeriodValues,
defaultFormattingWidth: "wide",
}),
});

View File

@@ -0,0 +1,155 @@
"use client";
import { consoleSandbox, GLOBAL_OBJ, applySdkMetadata, addEventProcessor, getGlobalScope } from '@sentry/core';
import { init as init$1, getDefaultIntegrations as getDefaultIntegrations$1 } from '@sentry/react';
export * from '@sentry/react';
import { DEBUG_BUILD } from '../common/debug-build.js';
import { devErrorSymbolicationEventProcessor } from '../common/devErrorSymbolicationEventProcessor.js';
import { getVercelEnv } from '../common/getVercelEnv.js';
import { isRedirectNavigationError } from '../common/nextNavigationErrorUtils.js';
import { browserTracingIntegration } from './browserTracingIntegration.js';
import { nextjsClientStackFrameNormalizationIntegration } from './clientNormalizationIntegration.js';
import { INCOMPLETE_APP_ROUTER_INSTRUMENTATION_TRANSACTION_NAME } from './routing/appRouterRoutingInstrumentation.js';
export { captureRouterTransitionStart } from './routing/appRouterRoutingInstrumentation.js';
import { removeIsrSsgTraceMetaTags } from './routing/isrRoutingTracing.js';
import { applyTunnelRouteOption } from './tunnelRoute.js';
export { wrapGetStaticPropsWithSentry } from '../common/pages-router-instrumentation/wrapGetStaticPropsWithSentry.js';
export { wrapGetInitialPropsWithSentry } from '../common/pages-router-instrumentation/wrapGetInitialPropsWithSentry.js';
export { wrapAppGetInitialPropsWithSentry } from '../common/pages-router-instrumentation/wrapAppGetInitialPropsWithSentry.js';
export { wrapDocumentGetInitialPropsWithSentry } from '../common/pages-router-instrumentation/wrapDocumentGetInitialPropsWithSentry.js';
export { wrapErrorGetInitialPropsWithSentry } from '../common/pages-router-instrumentation/wrapErrorGetInitialPropsWithSentry.js';
export { wrapGetServerSidePropsWithSentry } from '../common/pages-router-instrumentation/wrapGetServerSidePropsWithSentry.js';
export { wrapServerComponentWithSentry } from '../common/wrapServerComponentWithSentry.js';
export { wrapRouteHandlerWithSentry } from '../common/wrapRouteHandlerWithSentry.js';
export { wrapApiHandlerWithSentryVercelCrons } from '../common/pages-router-instrumentation/wrapApiHandlerWithSentryVercelCrons.js';
export { wrapMiddlewareWithSentry } from '../common/wrapMiddlewareWithSentry.js';
export { wrapPageComponentWithSentry } from '../common/pages-router-instrumentation/wrapPageComponentWithSentry.js';
export { wrapGenerationFunctionWithSentry } from '../common/wrapGenerationFunctionWithSentry.js';
export { withServerActionInstrumentation } from '../common/withServerActionInstrumentation.js';
export { captureRequestError } from '../common/captureRequestError.js';
export { captureUnderscoreErrorException } from '../common/pages-router-instrumentation/_error.js';
export { startInactiveSpan, startSpan, startSpanManual } from '../common/utils/nextSpan.js';
let clientIsInitialized = false;
const globalWithInjectedValues = GLOBAL_OBJ
;
// Treeshakable guard to remove all code related to tracing
/** Inits the Sentry NextJS SDK on the browser with the React SDK. */
function init(options) {
if (clientIsInitialized) {
consoleSandbox(() => {
// eslint-disable-next-line no-console
console.warn(
'[@sentry/nextjs] You are calling `Sentry.init()` more than once on the client. This can happen if you have both a `sentry.client.config.ts` and a `instrumentation-client.ts` file with `Sentry.init()` calls. It is recommended to call `Sentry.init()` once in `instrumentation-client.ts`.',
);
});
}
clientIsInitialized = true;
if (!DEBUG_BUILD && options.debug) {
consoleSandbox(() => {
// eslint-disable-next-line no-console
console.warn(
'[@sentry/nextjs] You have enabled `debug: true`, but Sentry debug logging was removed from your bundle (likely via `withSentryConfig({ disableLogger: true })` / `webpack.treeshake.removeDebugLogging: true`). Set that option to `false` to see Sentry debug output.',
);
});
}
// Remove cached trace meta tags for ISR/SSG pages before initializing
// This prevents the browser tracing integration from using stale trace IDs
if (typeof __SENTRY_TRACING__ === 'undefined' || __SENTRY_TRACING__) {
removeIsrSsgTraceMetaTags();
}
const opts = {
environment: getVercelEnv(true) || process.env.NODE_ENV,
defaultIntegrations: getDefaultIntegrations(options),
release: process.env._sentryRelease || globalWithInjectedValues._sentryRelease,
...options,
} ;
applyTunnelRouteOption(opts);
applySdkMetadata(opts, 'nextjs', ['nextjs', 'react']);
const client = init$1(opts);
const filterTransactions = event =>
event.type === 'transaction' && event.transaction === '/404' ? null : event;
filterTransactions.id = 'NextClient404Filter';
addEventProcessor(filterTransactions);
const filterIncompleteNavigationTransactions = event =>
event.type === 'transaction' && event.transaction === INCOMPLETE_APP_ROUTER_INSTRUMENTATION_TRANSACTION_NAME
? null
: event;
filterIncompleteNavigationTransactions.id = 'IncompleteTransactionFilter';
addEventProcessor(filterIncompleteNavigationTransactions);
const filterNextRedirectError = (event, hint) =>
isRedirectNavigationError(hint?.originalException) || event.exception?.values?.[0]?.value === 'NEXT_REDIRECT'
? null
: event;
filterNextRedirectError.id = 'NextRedirectErrorFilter';
addEventProcessor(filterNextRedirectError);
if (process.env.NODE_ENV === 'development') {
addEventProcessor(devErrorSymbolicationEventProcessor);
}
try {
// @ts-expect-error `process.turbopack` is a magic string that will be replaced by Next.js
if (process.turbopack) {
getGlobalScope().setTag('turbopack', true);
}
} catch {
// Noop
// The statement above can throw because process is not defined on the client
}
return client;
}
function getDefaultIntegrations(options) {
const customDefaultIntegrations = getDefaultIntegrations$1(options);
// This evaluates to true unless __SENTRY_TRACING__ is text-replaced with "false",
// in which case everything inside will get tree-shaken away
if (typeof __SENTRY_TRACING__ === 'undefined' || __SENTRY_TRACING__) {
customDefaultIntegrations.push(browserTracingIntegration());
}
// These values are injected at build time, based on the output directory specified in the build config. Though a default
// is set there, we set it here as well, just in case something has gone wrong with the injection.
const rewriteFramesAssetPrefixPath =
process.env._sentryRewriteFramesAssetPrefixPath ||
globalWithInjectedValues._sentryRewriteFramesAssetPrefixPath ||
'';
const assetPrefix = process.env._sentryAssetPrefix || globalWithInjectedValues._sentryAssetPrefix;
const basePath = process.env._sentryBasePath || globalWithInjectedValues._sentryBasePath;
const experimentalThirdPartyOriginStackFrames =
process.env._experimentalThirdPartyOriginStackFrames === 'true' ||
globalWithInjectedValues._experimentalThirdPartyOriginStackFrames === 'true';
customDefaultIntegrations.push(
nextjsClientStackFrameNormalizationIntegration({
assetPrefix,
basePath,
rewriteFramesAssetPrefixPath,
experimentalThirdPartyOriginStackFrames,
}),
);
return customDefaultIntegrations;
}
/**
* Just a passthrough in case this is imported from the client.
*/
function withSentryConfig(exportedUserNextConfig) {
return exportedUserNextConfig;
}
export { browserTracingIntegration, init, withSentryConfig };
//# sourceMappingURL=index.js.map

View File

@@ -0,0 +1,133 @@
const lockDurationDefault = 300 // Default 5 minutes in seconds
;
export const handleFormStateLocking = async ({
id,
collectionSlug,
globalSlug,
req,
updateLastEdited
}) => {
let result;
// Check if the locked-documents collection exists
if (!req.payload.collections?.['payload-locked-documents']) {
// If the collection doesn't exist, locking is not available
return result;
}
if (id || globalSlug) {
let lockedDocumentQuery;
if (collectionSlug) {
lockedDocumentQuery = {
and: [{
'document.relationTo': {
equals: collectionSlug
}
}, {
'document.value': {
equals: id
}
}]
};
} else if (globalSlug) {
lockedDocumentQuery = {
and: [{
globalSlug: {
equals: globalSlug
}
}]
};
}
const lockDocumentsProp = collectionSlug ? req.payload.collections?.[collectionSlug]?.config.lockDocuments : req.payload.config.globals.find(g => g.slug === globalSlug)?.lockDocuments;
const lockDuration = typeof lockDocumentsProp === 'object' ? lockDocumentsProp.duration : lockDurationDefault;
const lockDurationInMilliseconds = lockDuration * 1000;
const now = new Date().getTime();
if (lockedDocumentQuery) {
// Query where the lock is newer than the current time minus the lock duration
lockedDocumentQuery.and.push({
updatedAt: {
greater_than: new Date(now - lockDurationInMilliseconds).toISOString()
}
});
const lockedDocument = await req.payload.find({
collection: 'payload-locked-documents',
depth: 1,
limit: 1,
overrideAccess: false,
pagination: false,
user: req.user,
where: lockedDocumentQuery
});
if (lockedDocument.docs && lockedDocument.docs.length > 0) {
result = {
isLocked: true,
lastEditedAt: lockedDocument.docs[0]?.updatedAt,
user: lockedDocument.docs[0]?.user?.value
};
const lockOwnerID = typeof lockedDocument.docs[0]?.user?.value === 'object' ? lockedDocument.docs[0]?.user?.value?.id : lockedDocument.docs[0]?.user?.value;
// Should only update doc if the incoming / current user is also the owner of the locked doc
if (updateLastEdited && req.user && lockOwnerID === req.user.id) {
await req.payload.db.updateOne({
id: lockedDocument.docs[0].id,
collection: 'payload-locked-documents',
data: {},
returning: false
});
}
} else {
// If NO ACTIVE lock document exists, first delete any expired locks and then create a fresh lock
// Where updatedAt is older than the duration that is specified in the config
let deleteExpiredLocksQuery;
if (collectionSlug) {
deleteExpiredLocksQuery = {
and: [{
'document.relationTo': {
equals: collectionSlug
}
}, {
updatedAt: {
less_than: new Date(now - lockDurationInMilliseconds).toISOString()
}
}]
};
} else if (globalSlug) {
deleteExpiredLocksQuery = {
and: [{
globalSlug: {
equals: globalSlug
}
}, {
updatedAt: {
less_than: new Date(now - lockDurationInMilliseconds).toISOString()
}
}]
};
}
await req.payload.db.deleteMany({
collection: 'payload-locked-documents',
where: deleteExpiredLocksQuery
});
await req.payload.db.create({
collection: 'payload-locked-documents',
data: {
document: collectionSlug ? {
relationTo: collectionSlug,
value: id
} : undefined,
globalSlug: globalSlug ? globalSlug : undefined,
user: {
relationTo: req.user.collection,
value: req.user.id
}
},
returning: false
});
result = {
isLocked: true,
lastEditedAt: new Date().toISOString(),
user: req.user
};
}
}
}
return result;
};
//# sourceMappingURL=handleFormStateLocking.js.map

View File

@@ -0,0 +1 @@
import{match as e}from"@formatjs/intl-localematcher";import o from"negotiator";import{getPathnameMatch as l,isLocaleSupportedOnDomain as t,getHost as a}from"./utils.js";function c(l,t,a){let c;const n=new o({headers:{"accept-language":l.get("accept-language")||void 0}}).languages();try{const o=function(e){return e.slice().sort(((e,o)=>o.length-e.length))}(t);c=e(n,o,a)}catch{}return c}function n(e,o){if(e.localeCookie&&o.has(e.localeCookie.name)){const l=o.get(e.localeCookie.name)?.value;if(l&&e.locales.includes(l))return l}}function i(e,o,t,a){let i;return a&&(i=l(a,e.locales,e.localePrefix)?.locale),!i&&e.localeDetection&&(i=n(e,t)),!i&&e.localeDetection&&(i=c(o,e.locales,e.defaultLocale)),i||(i=e.defaultLocale),i}function r(e,o,r,f){const u=function(e,o){const l=a(e);if(l)return o.find((e=>e.domain===l))}(o,e.domains);if(!u)return{locale:i(e,o,r,f)};let s;if(f){const o=l(f,e.locales,e.localePrefix,u)?.locale;if(o){if(!t(o,u))return{locale:o,domain:u};s=o}}if(!s&&e.localeDetection){const o=n(e,r);o&&t(o,u)&&(s=o)}if(!s&&e.localeDetection){const e=c(o,u.locales,u.defaultLocale);e&&(s=e)}return s||(s=u.defaultLocale),{locale:s,domain:u}}function f(e,o,l,t){return e.domains?r(e,o,l,t):{locale:i(e,o,l,t)}}export{f as default,c as getAcceptLanguageLocale};

View File

@@ -0,0 +1,25 @@
"use strict";
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __hasOwnProp = Object.prototype.hasOwnProperty;
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 __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
var gel_exports = {};
module.exports = __toCommonJS(gel_exports);
__reExport(gel_exports, require("./driver.cjs"), module.exports);
__reExport(gel_exports, require("./session.cjs"), module.exports);
// Annotate the CommonJS export names for ESM import in node:
0 && (module.exports = {
...require("./driver.cjs"),
...require("./session.cjs")
});
//# sourceMappingURL=index.cjs.map

View File

@@ -0,0 +1,38 @@
"use strict";
exports.formatLong = void 0;
var _index = require("../../_lib/buildFormatLongFn.js");
const dateFormats = {
full: "EEEE, do MMMM, y",
long: "do MMMM, y",
medium: "d MMM, y",
short: "dd/MM/yyyy",
};
const timeFormats = {
full: "H:mm:ss zzzz",
long: "H:mm:ss z",
medium: "H:mm:ss",
short: "H:mm",
};
const dateTimeFormats = {
any: "{{date}}, {{time}}",
};
const formatLong = (exports.formatLong = {
date: (0, _index.buildFormatLongFn)({
formats: dateFormats,
defaultWidth: "full",
}),
time: (0, _index.buildFormatLongFn)({
formats: timeFormats,
defaultWidth: "full",
}),
dateTime: (0, _index.buildFormatLongFn)({
formats: dateTimeFormats,
defaultWidth: "any",
}),
});

View File

@@ -0,0 +1,65 @@
import { isValid } from "./isValid.mjs";
import { toDate } from "./toDate.mjs";
import { addLeadingZeros } from "./_lib/addLeadingZeros.mjs";
const days = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"];
const months = [
"Jan",
"Feb",
"Mar",
"Apr",
"May",
"Jun",
"Jul",
"Aug",
"Sep",
"Oct",
"Nov",
"Dec",
];
/**
* @name formatRFC7231
* @category Common Helpers
* @summary Format the date according to the RFC 7231 standard (https://tools.ietf.org/html/rfc7231#section-7.1.1.1).
*
* @description
* Return the formatted date string in RFC 7231 format.
* The result will always be in UTC timezone.
*
* @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 date - The original date
*
* @returns The formatted date string
*
* @throws `date` must not be Invalid Date
*
* @example
* // Represent 18 September 2019 in RFC 7231 format:
* const result = formatRFC7231(new Date(2019, 8, 18, 19, 0, 52))
* //=> 'Wed, 18 Sep 2019 19:00:52 GMT'
*/
export function formatRFC7231(date) {
const _date = toDate(date);
if (!isValid(_date)) {
throw new RangeError("Invalid time value");
}
const dayName = days[_date.getUTCDay()];
const dayOfMonth = addLeadingZeros(_date.getUTCDate(), 2);
const monthName = months[_date.getUTCMonth()];
const year = _date.getUTCFullYear();
const hour = addLeadingZeros(_date.getUTCHours(), 2);
const minute = addLeadingZeros(_date.getUTCMinutes(), 2);
const second = addLeadingZeros(_date.getUTCSeconds(), 2);
// Result variables.
return `${dayName}, ${dayOfMonth} ${monthName} ${year} ${hour}:${minute}:${second} GMT`;
}
// Fallback for modularized imports:
export default formatRFC7231;

View File

@@ -0,0 +1,81 @@
import { decodeJwt } from 'jose';
export const meOperation = async (args)=>{
const { collection, currentToken, depth, draft, joins, populate, req, select } = args;
let result = {
user: null
};
if (req.user) {
const { pathname } = req;
const isGraphQL = pathname === `/api${req.payload.config.routes.graphQL}`;
const user = await req.payload.findByID({
id: req.user.id,
collection: collection.config.slug,
depth: isGraphQL ? 0 : depth ?? collection.config.auth.depth,
draft,
joins,
overrideAccess: false,
populate,
req,
select,
showHiddenFields: false
});
if (user) {
user.collection = collection.config.slug;
user._strategy = req.user._strategy;
}
if (req.user.collection !== collection.config.slug) {
return {
user: null
};
}
// /////////////////////////////////////
// me hook - Collection
// /////////////////////////////////////
for (const meHook of collection.config.hooks.me){
const hookResult = await meHook({
args,
user
});
if (hookResult) {
result.user = hookResult.user;
result.exp = hookResult.exp;
break;
}
}
result.collection = req.user.collection;
/** @deprecated
* use:
* ```ts
* user._strategy
* ```
*/ result.strategy = req.user._strategy;
if (!result.user) {
result.user = user;
if (currentToken) {
const decoded = decodeJwt(currentToken);
if (decoded) {
result.exp = decoded.exp;
}
if (!collection.config.auth.removeTokenFromResponses) {
result.token = currentToken;
}
}
}
}
// /////////////////////////////////////
// After Me - Collection
// /////////////////////////////////////
if (collection.config.hooks?.afterMe?.length) {
for (const hook of collection.config.hooks.afterMe){
result = await hook({
collection: collection?.config,
context: req.context,
req,
response: result
}) || result;
}
}
return result;
};
//# sourceMappingURL=me.js.map

View File

@@ -0,0 +1,30 @@
"use strict";
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
Object.defineProperty(exports, "__esModule", { value: true });
exports.TextareaElementContainer = void 0;
var element_container_1 = require("../element-container");
var TextareaElementContainer = /** @class */ (function (_super) {
__extends(TextareaElementContainer, _super);
function TextareaElementContainer(context, element) {
var _this = _super.call(this, context, element) || this;
_this.value = element.value;
return _this;
}
return TextareaElementContainer;
}(element_container_1.ElementContainer));
exports.TextareaElementContainer = TextareaElementContainer;
//# sourceMappingURL=textarea-element-container.js.map

View File

@@ -0,0 +1,83 @@
import crypto from 'crypto';
import { describe, expect, it } from 'vitest';
import { authenticateLocalStrategy } from './authenticate.js';
// Helper to generate hash/salt like Payload does
const generateHashAndSalt = (password)=>{
const salt = crypto.randomBytes(32).toString('hex');
const hash = crypto.pbkdf2Sync(password, salt, 25000, 512, 'sha256').toString('hex');
return {
hash,
salt
};
};
describe('authenticateLocalStrategy', ()=>{
it('should return doc when password is valid', async ()=>{
const password = 'test-password';
const { hash, salt } = generateHashAndSalt(password);
const doc = {
id: 1,
hash,
salt
};
const result = await authenticateLocalStrategy({
doc,
password
});
expect(result).toEqual(doc);
});
it('should return null when password is invalid', async ()=>{
const { hash, salt } = generateHashAndSalt('correct-password');
const doc = {
id: 1,
hash,
salt
};
const result = await authenticateLocalStrategy({
doc,
password: 'wrong-password'
});
expect(result).toBeNull();
});
it('should return null when salt is missing', async ()=>{
const { hash } = generateHashAndSalt('test-password');
const doc = {
id: 1,
hash
};
const result = await authenticateLocalStrategy({
doc,
password: 'test-password'
});
expect(result).toBeNull();
});
it('should return null when hash is missing', async ()=>{
const { salt } = generateHashAndSalt('test-password');
const doc = {
id: 1,
salt
};
const result = await authenticateLocalStrategy({
doc,
password: 'test-password'
});
expect(result).toBeNull();
});
it('should return null when hash has different length (tampered)', async ()=>{
const password = 'test-password';
const { salt } = generateHashAndSalt(password);
// Truncated hash - different length than expected 512 bytes
const shortHash = 'abcd1234';
const doc = {
id: 1,
hash: shortHash,
salt
};
const result = await authenticateLocalStrategy({
doc,
password
});
expect(result).toBeNull();
});
});
//# sourceMappingURL=authenticate.spec.js.map

View File

@@ -0,0 +1 @@
{"version":3,"sources":["../../src/tidb-serverless/index.ts"],"sourcesContent":["export * from './driver.ts';\nexport * from './session.ts';\n"],"mappings":";;;;;;;;;;;;;;;AAAA;AAAA;AAAA,oCAAc,wBAAd;AACA,oCAAc,yBADd;","names":[]}

View File

@@ -0,0 +1,17 @@
'use strict';
const pico = require('./lib/picomatch');
const utils = require('./lib/utils');
function picomatch(glob, options, returnState = false) {
// default to os.platform()
if (options && (options.windows === null || options.windows === undefined)) {
// don't mutate the original options object
options = { ...options, windows: utils.isWindows() };
}
return pico(glob, options, returnState);
}
Object.assign(picomatch, pico);
module.exports = picomatch;

View File

@@ -0,0 +1 @@
{"version":3,"file":"processMultipart.d.ts","sourceRoot":"","sources":["../../../src/uploads/fetchAPI-multipart/processMultipart.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,uBAAuB,CAAA;AACtE,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,YAAY,CAAA;AAS5D,QAAA,MAAM,iBAAiB,eAAuC,CAAA;AAE9D,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,OAAO;QACf,CAAC,iBAAiB,CAAC,CAAC,EAAE,OAAO,CAAC,GAAG,CAAC,EAAE,CAAA;KACrC;CACF;AAED,KAAK,gBAAgB,GAAG,CAAC,IAAI,EAAE;IAC7B,OAAO,EAAE,yBAAyB,CAAA;IAClC,OAAO,EAAE,OAAO,CAAA;CACjB,KAAK,OAAO,CAAC,0BAA0B,CAAC,CAAA;AACzC,eAAO,MAAM,gBAAgB,EAAE,gBAwM9B,CAAA"}

View File

@@ -0,0 +1,34 @@
import type { ContextOptions, DateArg } from "./types.js";
/**
* The {@link lastDayOfDecade} function options.
*/
export interface LastDayOfDecadeOptions<DateType extends Date = Date>
extends ContextOptions<DateType> {}
/**
* @name lastDayOfDecade
* @category Decade Helpers
* @summary Return the last day of a decade for the given date.
*
* @description
* Return the last day of a decade for the given date.
*
* @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows using extensions like [`UTCDate`](https://github.com/date-fns/utc).
* @typeParam ResultDate - The result `Date` type; inferred from arguments or specified by context.
*
* @param date - The original date
* @param options - The options
*
* @returns The last day of a decade
*
* @example
* // The last day of a decade for 21 December 2012 21:12:00:
* const result = lastDayOfDecade(new Date(2012, 11, 21, 21, 12, 00))
* //=> Wed Dec 31 2019 00:00:00
*/
export declare function lastDayOfDecade<
DateType extends Date,
ResultDate extends Date = DateType,
>(
date: DateArg<DateType>,
options?: LastDayOfDecadeOptions<ResultDate> | undefined,
): ResultDate;

View File

@@ -0,0 +1 @@
{"version":3,"file":"eventbuilder.d.ts","sourceRoot":"","sources":["../../../src/eventbuilder.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,KAAK,EACL,SAAS,EACT,SAAS,EACT,mBAAmB,EACnB,aAAa,EAEb,WAAW,EACZ,MAAM,cAAc,CAAC;AAoBtB;;GAEG;AACH,wBAAgB,kBAAkB,CAAC,WAAW,EAAE,WAAW,EAAE,EAAE,EAAE,KAAK,GAAG,SAAS,CAkBjF;AA8HD;;;;GAIG;AACH,wBAAgB,WAAW,CAAC,EAAE,EAAE,KAAK,GAAG;IAAE,OAAO,EAAE;QAAE,KAAK,CAAC,EAAE,KAAK,CAAA;KAAE,CAAA;CAAE,GAAG,MAAM,GAAG,SAAS,CAY1F;AAED;;;;GAIG;AACH,wBAAgB,cAAc,CAAC,EAAE,EAAE,KAAK,GAAG;IAAE,OAAO,EAAE;QAAE,KAAK,CAAC,EAAE,KAAK,CAAA;KAAE,CAAA;CAAE,GAAG,MAAM,CAoBjF;AAED;;;GAGG;AACH,wBAAgB,kBAAkB,CAChC,WAAW,EAAE,WAAW,EACxB,SAAS,EAAE,OAAO,EAClB,IAAI,CAAC,EAAE,SAAS,EAChB,gBAAgB,CAAC,EAAE,OAAO,GACzB,WAAW,CAAC,KAAK,CAAC,CASpB;AAED;;;GAGG;AACH,wBAAgB,gBAAgB,CAC9B,WAAW,EAAE,WAAW,EACxB,OAAO,EAAE,mBAAmB,EAC5B,KAAK,GAAE,aAAsB,EAC7B,IAAI,CAAC,EAAE,SAAS,EAChB,gBAAgB,CAAC,EAAE,OAAO,GACzB,WAAW,CAAC,KAAK,CAAC,CAQpB;AAED;;GAEG;AACH,wBAAgB,qBAAqB,CACnC,WAAW,EAAE,WAAW,EACxB,SAAS,EAAE,OAAO,EAClB,kBAAkB,CAAC,EAAE,KAAK,EAC1B,gBAAgB,CAAC,EAAE,OAAO,EAC1B,oBAAoB,CAAC,EAAE,OAAO,GAC7B,KAAK,CAkEP"}

View File

@@ -0,0 +1 @@
{"version":3,"sources":["../../../src/admin/fields/Hidden.ts"],"sourcesContent":["import type { ClientFieldBase } from '../types.js'\n\ntype HiddenFieldBaseClientProps = {\n readonly disableModifyingForm?: false\n readonly field?: never\n readonly path: string\n readonly value?: unknown\n}\n\nexport type HiddenFieldProps = HiddenFieldBaseClientProps &\n Pick<ClientFieldBase, 'forceRender' | 'schemaPath'>\n"],"names":[],"mappings":"AASA,WACqD"}

View File

@@ -0,0 +1,33 @@
span.inline-color-wrapper {
/*
* The background image is the following SVG inline in base 64:
*
* <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 2 2">
* <path fill="gray" d="M0 0h2v2H0z"/>
* <path fill="white" d="M0 0h1v1H0zM1 1h1v1H1z"/>
* </svg>
*
* SVG-inlining explained:
* https://stackoverflow.com/a/21626701/7595472
*/
background: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyIDIiPjxwYXRoIGZpbGw9ImdyYXkiIGQ9Ik0wIDBoMnYySDB6Ii8+PHBhdGggZmlsbD0id2hpdGUiIGQ9Ik0wIDBoMXYxSDB6TTEgMWgxdjFIMXoiLz48L3N2Zz4=");
/* This is to prevent visual glitches where one pixel from the repeating pattern could be seen. */
background-position: center;
background-size: 110%;
display: inline-block;
height: 1.333ch;
width: 1.333ch;
margin: 0 .333ch;
box-sizing: border-box;
border: 1px solid white;
outline: 1px solid rgba(0,0,0,.5);
overflow: hidden;
}
span.inline-color {
display: block;
/* To prevent visual glitches again */
height: 120%;
width: 120%;
}

View File

@@ -0,0 +1,6 @@
// Fixes https://github.com/motiondivision/motion/issues/2270
const getContextWindow = ({ current }) => {
return current ? current.ownerDocument.defaultView : null;
};
export { getContextWindow };

View File

@@ -0,0 +1,155 @@
# esm-loader
[Node.js loader](https://nodejs.org/api/esm.html#loaders) for loading TypeScript files.
### Features
- Transforms TypeScript to ESM on demand
- Classic Node.js resolution (extensionless & directory imports)
- Cached for performance boost
- Supports Node.js v12.20.0+
- Handles `node:` import prefixes
- Resolves `tsconfig.json` [`paths`](https://www.typescriptlang.org/tsconfig#paths)
- Named imports from JSON modules
> **Protip: use with _cjs-loader_ or _tsx_**
>
> _esm-loader_ only transforms ES modules (`.mjs`/`.mts` extensions or `.js` files in `module` type packages).
>
> To transform CommonJS files (`.cjs`/`.cts` extensions or `.js` files in `commonjs` type packages), use this with [_cjs-loader_](https://github.com/esbuild-kit/cjs-loader).
>
> Alternatively, use [tsx](https://github.com/esbuild-kit/tsx) to handle them both automatically.
<br>
<p align="center">
<a href="https://privatenumber-sponsors.vercel.app/api/sponsor?tier=platinum">
<picture>
<source width="830" media="(prefers-color-scheme: dark)" srcset="https://privatenumber-sponsors.vercel.app/api/sponsor?tier=platinum&image=dark">
<source width="830" media="(prefers-color-scheme: light)" srcset="https://privatenumber-sponsors.vercel.app/api/sponsor?tier=platinum&image">
<img width="830" src="https://privatenumber-sponsors.vercel.app/api/sponsor?tier=platinum&image" alt="Premium sponsor banner">
</picture>
</a>
</p>
## Install
```sh
npm install --save-dev @esbuild-kit/esm-loader
```
## Usage
Pass `@esbuild-kit/esm-loader` into the [`--loader`](https://nodejs.org/api/cli.html#--experimental-loadermodule) flag.
```sh
node --loader @esbuild-kit/esm-loader ./file.ts
```
### TypeScript configuration
The following properties are used from `tsconfig.json` in the working directory:
- [`strict`](https://www.typescriptlang.org/tsconfig#strict): Whether to transform to strict mode
- [`jsx`](https://esbuild.github.io/api/#jsx): Whether to transform JSX
> **Warning:** When set to `preserve`, the JSX syntax will remain untransformed. To prevent Node.js from throwing a syntax error, chain another Node.js loader that can transform JSX to JS.
- [`jsxFactory`](https://esbuild.github.io/api/#jsx-factory): How to transform JSX
- [`jsxFragmentFactory`](https://esbuild.github.io/api/#jsx-fragment): How to transform JSX Fragments
- [`jsxImportSource`](https://www.typescriptlang.org/tsconfig#jsxImportSource): Where to import JSX functions from
- [`allowJs`](https://www.typescriptlang.org/tsconfig#allowJs): Whether to apply the tsconfig to JS files
- [`paths`](https://www.typescriptlang.org/tsconfig#paths): For resolving aliases
#### Custom `tsconfig.json` path
By default, `tsconfig.json` will be detected from the current working directory.
To set a custom path, use the `ESBK_TSCONFIG_PATH` environment variable:
```sh
ESBK_TSCONFIG_PATH=./path/to/tsconfig.custom.json node --loader @esbuild-kit/esm-loader ./file.ts
```
### Cache
Modules transformations are cached in the system cache directory ([`TMPDIR`](https://en.wikipedia.org/wiki/TMPDIR)). Transforms are cached by content hash so duplicate dependencies are not re-transformed.
Set environment variable `ESBK_DISABLE_CACHE` to a truthy value to disable the cache:
```sh
ESBK_DISABLE_CACHE=1 node --loader @esbuild-kit/esm-loader ./file.ts
```
<br>
<p align="center">
<a href="https://privatenumber-sponsors.vercel.app/api/sponsor?tier=gold">
<picture>
<source width="830" media="(prefers-color-scheme: dark)" srcset="https://privatenumber-sponsors.vercel.app/api/sponsor?tier=gold&image=dark">
<source width="830" media="(prefers-color-scheme: light)" srcset="https://privatenumber-sponsors.vercel.app/api/sponsor?tier=gold&image">
<img width="830" src="https://privatenumber-sponsors.vercel.app/api/sponsor?tier=gold&image" alt="Premium sponsor banner">
</picture>
</a>
</p>
## FAQ
### Can it import JSON modules?
Yes. This loader transpiles JSON modules so it's also compatible with named imports.
### Can it import ESM modules over network?
Node.js has built-in support for network imports [behind the `--experimental-network-imports` flag](https://nodejs.org/api/esm.html#network-based-loading-is-not-enabled-by-default).
You can pass it in with `esm-loader`:
```sh
node --loader @esbuild-kit/esm-loader --experimental-network-imports ./file.ts
```
### Can it resolve files without an extension?
In ESM, import paths must be explicit (must include file name and extension).
For backwards compatibility, this loader adds support for classic Node resolution for extensions: `.js`, `.json`, `.ts`, `.tsx`, `.jsx`. Resolving a `index` file by the directory name works too.
```js
import file from './file' // -> ./file.js
import directory from './directory' // -> ./directory/index.js
```
### Can it use Node.js's CommonJS resolution algorithm?
ESM import resolution expects explicit import paths, whereas CommonJS resolution expects implicit imports (eg. extensionless & directory imports).
As a result of this change, Node.js changes how it imports a path that matches both a file and directory. In ESM, the directory would be imported, but in CJS, the file would be imported.
To use to the CommonJS resolution algorithm, use the [`--experimental-specifier-resolution=node`](https://nodejs.org/api/cli.html#--experimental-specifier-resolutionmode) flag.
```sh
node --loader @esbuild-kit/esm-loader --experimental-specifier-resolution=node ./file.ts
```
## Related
- [tsx](https://github.com/esbuild-kit/tsx) - Node.js runtime powered by esbuild using [`@esbuild-kit/cjs-loader`](https://github.com/esbuild-kit/cjs-loader) and [`@esbuild-kit/esm-loader`](https://github.com/esbuild-kit/esm-loader).
- [@esbuild-kit/cjs-loader](https://github.com/esbuild-kit/cjs-loader) - TypeScript & ESM to CJS transpiler using the Node.js loader API.
## Sponsors
<p align="center">
<a href="https://privatenumber-sponsors.vercel.app/api/sponsor?tier=silver1">
<picture>
<source width="410" media="(prefers-color-scheme: dark)" srcset="https://privatenumber-sponsors.vercel.app/api/sponsor?tier=silver1&image=dark">
<source width="410" media="(prefers-color-scheme: light)" srcset="https://privatenumber-sponsors.vercel.app/api/sponsor?tier=silver1&image">
<img width="410" src="https://privatenumber-sponsors.vercel.app/api/sponsor?tier=silver1&image" alt="Premium sponsor banner">
</picture>
</a>
<a href="https://privatenumber-sponsors.vercel.app/api/sponsor?tier=silver2">
<picture>
<source width="410" media="(prefers-color-scheme: dark)" srcset="https://privatenumber-sponsors.vercel.app/api/sponsor?tier=silver2&image=dark">
<source width="410" media="(prefers-color-scheme: light)" srcset="https://privatenumber-sponsors.vercel.app/api/sponsor?tier=silver2&image">
<img width="410" src="https://privatenumber-sponsors.vercel.app/api/sponsor?tier=silver2&image" alt="Premium sponsor banner">
</picture>
</a>
</p>
<p align="center">
<a href="https://github.com/sponsors/privatenumber">
<img src="https://cdn.jsdelivr.net/gh/privatenumber/sponsors/sponsorkit/sponsors.svg">
</a>
</p>

View File

@@ -0,0 +1,201 @@
'use strict';
const color = require('kleur');
const _require = require('sisteransi'),
cursor = _require.cursor;
const MultiselectPrompt = require('./multiselect');
const _require2 = require('../util'),
clear = _require2.clear,
style = _require2.style,
figures = _require2.figures;
/**
* MultiselectPrompt Base Element
* @param {Object} opts Options
* @param {String} opts.message Message
* @param {Array} opts.choices Array of choice objects
* @param {String} [opts.hint] Hint to display
* @param {String} [opts.warn] Hint shown for disabled choices
* @param {Number} [opts.max] Max choices
* @param {Number} [opts.cursor=0] Cursor start position
* @param {Stream} [opts.stdin] The Readable stream to listen to
* @param {Stream} [opts.stdout] The Writable stream to write readline data to
*/
class AutocompleteMultiselectPrompt extends MultiselectPrompt {
constructor(opts = {}) {
opts.overrideRender = true;
super(opts);
this.inputValue = '';
this.clear = clear('', this.out.columns);
this.filteredOptions = this.value;
this.render();
}
last() {
this.cursor = this.filteredOptions.length - 1;
this.render();
}
next() {
this.cursor = (this.cursor + 1) % this.filteredOptions.length;
this.render();
}
up() {
if (this.cursor === 0) {
this.cursor = this.filteredOptions.length - 1;
} else {
this.cursor--;
}
this.render();
}
down() {
if (this.cursor === this.filteredOptions.length - 1) {
this.cursor = 0;
} else {
this.cursor++;
}
this.render();
}
left() {
this.filteredOptions[this.cursor].selected = false;
this.render();
}
right() {
if (this.value.filter(e => e.selected).length >= this.maxChoices) return this.bell();
this.filteredOptions[this.cursor].selected = true;
this.render();
}
delete() {
if (this.inputValue.length) {
this.inputValue = this.inputValue.substr(0, this.inputValue.length - 1);
this.updateFilteredOptions();
}
}
updateFilteredOptions() {
const currentHighlight = this.filteredOptions[this.cursor];
this.filteredOptions = this.value.filter(v => {
if (this.inputValue) {
if (typeof v.title === 'string') {
if (v.title.toLowerCase().includes(this.inputValue.toLowerCase())) {
return true;
}
}
if (typeof v.value === 'string') {
if (v.value.toLowerCase().includes(this.inputValue.toLowerCase())) {
return true;
}
}
return false;
}
return true;
});
const newHighlightIndex = this.filteredOptions.findIndex(v => v === currentHighlight);
this.cursor = newHighlightIndex < 0 ? 0 : newHighlightIndex;
this.render();
}
handleSpaceToggle() {
const v = this.filteredOptions[this.cursor];
if (v.selected) {
v.selected = false;
this.render();
} else if (v.disabled || this.value.filter(e => e.selected).length >= this.maxChoices) {
return this.bell();
} else {
v.selected = true;
this.render();
}
}
handleInputChange(c) {
this.inputValue = this.inputValue + c;
this.updateFilteredOptions();
}
_(c, key) {
if (c === ' ') {
this.handleSpaceToggle();
} else {
this.handleInputChange(c);
}
}
renderInstructions() {
if (this.instructions === undefined || this.instructions) {
if (typeof this.instructions === 'string') {
return this.instructions;
}
return `
Instructions:
${figures.arrowUp}/${figures.arrowDown}: Highlight option
${figures.arrowLeft}/${figures.arrowRight}/[space]: Toggle selection
[a,b,c]/delete: Filter choices
enter/return: Complete answer
`;
}
return '';
}
renderCurrentInput() {
return `
Filtered results for: ${this.inputValue ? this.inputValue : color.gray('Enter something to filter')}\n`;
}
renderOption(cursor, v, i) {
let title;
if (v.disabled) title = cursor === i ? color.gray().underline(v.title) : color.strikethrough().gray(v.title);else title = cursor === i ? color.cyan().underline(v.title) : v.title;
return (v.selected ? color.green(figures.radioOn) : figures.radioOff) + ' ' + title;
}
renderDoneOrInstructions() {
if (this.done) {
return this.value.filter(e => e.selected).map(v => v.title).join(', ');
}
const output = [color.gray(this.hint), this.renderInstructions(), this.renderCurrentInput()];
if (this.filteredOptions.length && this.filteredOptions[this.cursor].disabled) {
output.push(color.yellow(this.warn));
}
return output.join(' ');
}
render() {
if (this.closed) return;
if (this.firstRender) this.out.write(cursor.hide);
super.render(); // print prompt
let prompt = [style.symbol(this.done, this.aborted), color.bold(this.msg), style.delimiter(false), this.renderDoneOrInstructions()].join(' ');
if (this.showMinError) {
prompt += color.red(`You must select a minimum of ${this.minSelected} choices.`);
this.showMinError = false;
}
prompt += this.renderOptions(this.filteredOptions);
this.out.write(this.clear + prompt);
this.clear = clear(prompt, this.out.columns);
}
}
module.exports = AutocompleteMultiselectPrompt;

View File

@@ -0,0 +1,6 @@
import React from 'react';
import './index.scss';
export declare function FolderIcon({ className }: {
className?: string;
}): React.JSX.Element;
//# sourceMappingURL=index.d.ts.map

View File

@@ -0,0 +1,30 @@
import { createClient } from "@libsql/client";
import { isConfig } from "../utils.js";
import { construct } from "./driver-core.js";
import { LibSQLDatabase } from "./driver-core.js";
function drizzle(...params) {
if (typeof params[0] === "string") {
const instance = createClient({
url: params[0]
});
return construct(instance, params[1]);
}
if (isConfig(params[0])) {
const { connection, client, ...drizzleConfig } = params[0];
if (client) return construct(client, drizzleConfig);
const instance = typeof connection === "string" ? createClient({ url: connection }) : createClient(connection);
return construct(instance, drizzleConfig);
}
return construct(params[0], params[1]);
}
((drizzle2) => {
function mock(config) {
return construct({}, config);
}
drizzle2.mock = mock;
})(drizzle || (drizzle = {}));
export {
LibSQLDatabase,
drizzle
};
//# sourceMappingURL=driver.js.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"MissingFieldType.d.ts","sourceRoot":"","sources":["../../src/errors/MissingFieldType.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,2BAA2B,CAAA;AAGtD,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAA;AAExC,qBAAa,gBAAiB,SAAQ,QAAQ;gBAChC,KAAK,EAAE,KAAK;CAOzB"}

View File

@@ -0,0 +1,234 @@
"use strict";
exports.localize = void 0;
var _index = require("../../_lib/buildLocalizeFn.js");
/**
* General information
* Reference: https://aplicacions.llengua.gencat.cat
* Reference: https://www.uoc.edu/portal/ca/servei-linguistic/convencions/abreviacions/simbols/simbols-habituals.html
*/
/**
* Abans de Crist: https://aplicacions.llengua.gencat.cat/llc/AppJava/index.html?input_cercar=abans+de+crist&action=Principal&method=detall_completa&numPagina=1&idHit=6876&database=FITXES_PUB&tipusFont=Fitxes%20de%20l%27Optimot&idFont=6876&titol=abans%20de%20Crist%20(abreviatura)%20/%20abans%20de%20Crist%20(sigla)&numeroResultat=1&clickLink=detall&tipusCerca=cerca.fitxes
* Desprest de Crist: https://aplicacions.llengua.gencat.cat/llc/AppJava/index.html?input_cercar=despr%E9s+de+crist&action=Principal&method=detall_completa&numPagina=1&idHit=6879&database=FITXES_PUB&tipusFont=Fitxes%20de%20l%27Optimot&idFont=6879&titol=despr%E9s%20de%20Crist%20(sigla)%20/%20despr%E9s%20de%20Crist%20(abreviatura)&numeroResultat=1&clickLink=detall&tipusCerca=cerca.fitxes
*/
const eraValues = {
narrow: ["aC", "dC"],
abbreviated: ["a. de C.", "d. de C."],
wide: ["abans de Crist", "després de Crist"],
};
const quarterValues = {
narrow: ["1", "2", "3", "4"],
abbreviated: ["T1", "T2", "T3", "T4"],
wide: ["1r trimestre", "2n trimestre", "3r trimestre", "4t trimestre"],
};
/**
* Dins d'un text convé fer servir la forma sencera dels mesos, ja que sempre és més clar el mot sencer que l'abreviatura, encara que aquesta sigui força coneguda.
* Cal reservar, doncs, les abreviatures per a les llistes o classificacions, els gràfics, les taules o quadres estadístics, els textos publicitaris, etc.
*
* Reference: https://aplicacions.llengua.gencat.cat/llc/AppJava/index.html?input_cercar=abreviacions+mesos&action=Principal&method=detall_completa&numPagina=1&idHit=8402&database=FITXES_PUB&tipusFont=Fitxes%20de%20l%27Optimot&idFont=8402&titol=abreviatures%20dels%20mesos%20de%20l%27any&numeroResultat=5&clickLink=detall&tipusCerca=cerca.fitxes
*/
const monthValues = {
narrow: [
"GN",
"FB",
"MÇ",
"AB",
"MG",
"JN",
"JL",
"AG",
"ST",
"OC",
"NV",
"DS",
],
/**
* Les abreviatures dels mesos de l'any es formen seguint una de les normes generals de formació d'abreviatures.
* S'escriu la primera síl·laba i les consonants de la síl·laba següent anteriors a la primera vocal.
* Els mesos de març, maig i juny no s'abreugen perquè són paraules d'una sola síl·laba.
*/
abbreviated: [
"gen.",
"febr.",
"març",
"abr.",
"maig",
"juny",
"jul.",
"ag.",
"set.",
"oct.",
"nov.",
"des.",
],
wide: [
"gener",
"febrer",
"març",
"abril",
"maig",
"juny",
"juliol",
"agost",
"setembre",
"octubre",
"novembre",
"desembre",
],
};
/**
* Les abreviatures dels dies de la setmana comencen totes amb la lletra d.
* Tot seguit porten la consonant següent a la i, excepte en el cas de dimarts, dimecres i diumenge, en què aquesta consonant és la m i, per tant, hi podria haver confusió.
* Per evitar-ho, s'ha substituït la m per una t (en el cas de dimarts), una c (en el cas de dimecres) i una g (en el cas de diumenge), respectivament.
*
* Seguint la norma general d'ús de les abreviatures, les dels dies de la setmana sempre porten punt final.
* Igualment, van amb la primera lletra en majúscula quan la paraula sencera també hi aniria.
* En canvi, van amb la primera lletra en minúscula quan la inicial de la paraula sencera també hi aniria.
*
* Reference: https://aplicacions.llengua.gencat.cat/llc/AppJava/index.html?input_cercar=abreviatures+dies&action=Principal&method=detall_completa&numPagina=1&idHit=8387&database=FITXES_PUB&tipusFont=Fitxes%20de%20l%27Optimot&idFont=8387&titol=abreviatures%20dels%20dies%20de%20la%20setmana&numeroResultat=1&clickLink=detall&tipusCerca=cerca.tot
*/
const dayValues = {
narrow: ["dg.", "dl.", "dt.", "dm.", "dj.", "dv.", "ds."],
short: ["dg.", "dl.", "dt.", "dm.", "dj.", "dv.", "ds."],
abbreviated: ["dg.", "dl.", "dt.", "dm.", "dj.", "dv.", "ds."],
wide: [
"diumenge",
"dilluns",
"dimarts",
"dimecres",
"dijous",
"divendres",
"dissabte",
],
};
/**
* Reference: https://aplicacions.llengua.gencat.cat/llc/AppJava/index.html?action=Principal&method=detall&input_cercar=parts+del+dia&numPagina=1&database=FITXES_PUB&idFont=12801&idHit=12801&tipusFont=Fitxes+de+l%27Optimot&numeroResultat=1&databases_avansada=&categories_avansada=&clickLink=detall&titol=Nom+de+les+parts+del+dia&tematica=&tipusCerca=cerca.fitxes
*/
const dayPeriodValues = {
narrow: {
am: "am",
pm: "pm",
midnight: "mitjanit",
noon: "migdia",
morning: "matí",
afternoon: "tarda",
evening: "vespre",
night: "nit",
},
abbreviated: {
am: "a.m.",
pm: "p.m.",
midnight: "mitjanit",
noon: "migdia",
morning: "matí",
afternoon: "tarda",
evening: "vespre",
night: "nit",
},
wide: {
am: "ante meridiem",
pm: "post meridiem",
midnight: "mitjanit",
noon: "migdia",
morning: "matí",
afternoon: "tarda",
evening: "vespre",
night: "nit",
},
};
const formattingDayPeriodValues = {
narrow: {
am: "am",
pm: "pm",
midnight: "de la mitjanit",
noon: "del migdia",
morning: "del matí",
afternoon: "de la tarda",
evening: "del vespre",
night: "de la nit",
},
abbreviated: {
am: "AM",
pm: "PM",
midnight: "de la mitjanit",
noon: "del migdia",
morning: "del matí",
afternoon: "de la tarda",
evening: "del vespre",
night: "de la nit",
},
wide: {
am: "ante meridiem",
pm: "post meridiem",
midnight: "de la mitjanit",
noon: "del migdia",
morning: "del matí",
afternoon: "de la tarda",
evening: "del vespre",
night: "de la nit",
},
};
/**
* Quan van en singular, els nombres ordinals es representen, en forma dabreviatura, amb la xifra seguida de lúltima lletra del mot desplegat.
* És optatiu posar punt després de la lletra.
*
* Reference: https://aplicacions.llengua.gencat.cat/llc/AppJava/pdf/abrevia.pdf#page=18
*/
const ordinalNumber = (dirtyNumber, _options) => {
const number = Number(dirtyNumber);
const rem100 = number % 100;
if (rem100 > 20 || rem100 < 10) {
switch (rem100 % 10) {
case 1:
return number + "r";
case 2:
return number + "n";
case 3:
return number + "r";
case 4:
return number + "t";
}
}
return number + "è";
};
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",
}),
day: (0, _index.buildLocalizeFn)({
values: dayValues,
defaultWidth: "wide",
}),
dayPeriod: (0, _index.buildLocalizeFn)({
values: dayPeriodValues,
defaultWidth: "wide",
formattingValues: formattingDayPeriodValues,
defaultFormattingWidth: "wide",
}),
});

View File

@@ -0,0 +1,2 @@
export { rsLatin } from '@payloadcms/translations/languages/rsLatin';
//# sourceMappingURL=rsLatin.d.ts.map

View File

@@ -0,0 +1,85 @@
import { context } from '@opentelemetry/api';
import { ATTR_HTTP_REQUEST_METHOD, SEMATTRS_HTTP_METHOD, ATTR_HTTP_ROUTE } from '@opentelemetry/semantic-conventions';
import { spanToJSON, getRootSpan, SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN, getIsolationScope, getCapturedScopesOnSpan, getCurrentScope, setCapturedScopesOnSpan } from '@sentry/core';
import { getScopesFromContext } from '@sentry/opentelemetry';
import { ATTR_NEXT_ROUTE, ATTR_NEXT_SPAN_TYPE, ATTR_NEXT_SPAN_NAME } from '../common/nextSpanAttributes.js';
import { addHeadersAsAttributes } from '../common/utils/addHeadersAsAttributes.js';
import { dropMiddlewareTunnelRequests } from '../common/utils/dropMiddlewareTunnelRequests.js';
import { maybeEnhanceServerComponentSpanName } from '../common/utils/tracingUtils.js';
import { maybeStartCronCheckIn } from './vercelCronsMonitoring.js';
/**
* Handles the on span start event for Next.js spans.
* This function is used to enhance the span with additional information such as the route, the method, the headers, etc.
* It is called for every span that is started by Next.js.
* @param span The span that is starting.
*/
function handleOnSpanStart(span) {
const spanAttributes = spanToJSON(span).data;
const rootSpan = getRootSpan(span);
const rootSpanAttributes = spanToJSON(rootSpan).data;
const isRootSpan = span === rootSpan;
dropMiddlewareTunnelRequests(span, spanAttributes);
// What we do in this glorious piece of code, is hoist any information about parameterized routes from spans emitted
// by Next.js via the `next.route` attribute, up to the transaction by setting the http.route attribute.
if (typeof spanAttributes?.[ATTR_NEXT_ROUTE] === 'string') {
// Only hoist the http.route attribute if the transaction doesn't already have it
if (
// eslint-disable-next-line deprecation/deprecation
(rootSpanAttributes?.[ATTR_HTTP_REQUEST_METHOD] || rootSpanAttributes?.[SEMATTRS_HTTP_METHOD]) &&
!rootSpanAttributes?.[ATTR_HTTP_ROUTE]
) {
const route = spanAttributes[ATTR_NEXT_ROUTE].replace(/\/route$/, '');
rootSpan.updateName(route);
rootSpan.setAttribute(ATTR_HTTP_ROUTE, route);
// Preserving the original attribute despite internally not depending on it
rootSpan.setAttribute(ATTR_NEXT_ROUTE, route);
// Check if this is a Vercel cron request and start a check-in
maybeStartCronCheckIn(rootSpan, route);
}
}
if (spanAttributes?.[ATTR_NEXT_SPAN_TYPE] === 'Middleware.execute') {
const middlewareName = spanAttributes[ATTR_NEXT_SPAN_NAME];
if (typeof middlewareName === 'string') {
rootSpan.updateName(middlewareName);
rootSpan.setAttribute(ATTR_HTTP_ROUTE, middlewareName);
rootSpan.setAttribute(ATTR_NEXT_SPAN_NAME, middlewareName);
}
span.setAttribute(SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN, 'auto');
}
// We want to skip span data inference for any spans generated by Next.js. Reason being that Next.js emits spans
// with patterns (e.g. http.server spans) that will produce confusing data.
if (spanAttributes?.[ATTR_NEXT_SPAN_TYPE] !== undefined) {
span.setAttribute(SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN, 'auto');
}
if (isRootSpan) {
const headers = getIsolationScope().getScopeData().sdkProcessingMetadata?.normalizedRequest?.headers;
addHeadersAsAttributes(headers, rootSpan);
}
// We want to fork the isolation scope for incoming requests
if (spanAttributes?.[ATTR_NEXT_SPAN_TYPE] === 'BaseServer.handleRequest' && isRootSpan) {
const scopes = getCapturedScopesOnSpan(span);
const isolationScope = (scopes.isolationScope || getIsolationScope()).clone();
const scope = scopes.scope || getCurrentScope();
const currentScopesPointer = getScopesFromContext(context.active());
if (currentScopesPointer) {
currentScopesPointer.isolationScope = isolationScope;
}
setCapturedScopesOnSpan(span, scope, isolationScope);
}
maybeEnhanceServerComponentSpanName(span, spanAttributes, rootSpanAttributes);
}
export { handleOnSpanStart };
//# sourceMappingURL=handleOnSpanStart.js.map

View File

@@ -0,0 +1,2 @@
const e=(e,t)=>()=>({path:`/auth/password/request`,method:`POST`,body:JSON.stringify({email:e,...t?{reset_url:t}:{}})});export{e as passwordRequest};
//# sourceMappingURL=password-request.js.map

View File

@@ -0,0 +1,27 @@
"use strict";
exports.te = void 0;
var _index = require("./te/_lib/formatDistance.js");
var _index2 = require("./te/_lib/formatLong.js");
var _index3 = require("./te/_lib/formatRelative.js");
var _index4 = require("./te/_lib/localize.js");
var _index5 = require("./te/_lib/match.js");
/**
* @category Locales
* @summary Telugu locale
* @language Telugu
* @iso-639-2 tel
* @author Kranthi Lakum [@kranthilakum](https://github.com/kranthilakum)
*/
const te = (exports.te = {
code: "te",
formatDistance: _index.formatDistance,
formatLong: _index2.formatLong,
formatRelative: _index3.formatRelative,
localize: _index4.localize,
match: _index5.match,
options: {
weekStartsOn: 0 /* Sunday */,
firstWeekContainsDate: 1,
},
});

View File

@@ -0,0 +1 @@
{"version":3,"file":"buildFindManyArgs.d.ts","sourceRoot":"","sources":["../../src/find/buildFindManyArgs.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAChD,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,SAAS,CAAA;AAIpE,OAAO,KAAK,EAAE,qBAAqB,EAAE,cAAc,EAAE,MAAM,aAAa,CAAA;AAIxE,KAAK,kBAAkB,GAAG;IACxB,OAAO,EAAE,cAAc,CAAA;IACvB,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,KAAK,EAAE,MAAM,CAAA;IACb,aAAa,CAAC,EAAE,OAAO,CAAA;IACvB,MAAM,EAAE,cAAc,EAAE,CAAA;IACxB,SAAS,CAAC,EAAE,SAAS,CAAA;IACrB;;OAEG;IACH,KAAK,CAAC,EAAE,qBAAqB,CAAA;IAC7B,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,MAAM,CAAC,EAAE,UAAU,CAAA;IACnB,SAAS,EAAE,MAAM,CAAA;IACjB,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB,CAAA;AAED,MAAM,MAAM,MAAM,GAAG;IACnB,IAAI,CAAC,EAAE;QACL,QAAQ,CAAC,EAAE,aAAa,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,EAAE,GAAG,CAAC,CAAA;KACjD,GAAG,aAAa,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,EAAE,GAAG,CAAC,CAAA;CAC1C,GAAG,aAAa,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,EAAE,GAAG,CAAC,CAAA;AAIzC,eAAO,MAAM,iBAAiB,sHAY3B,kBAAkB,KAAG,MAkGvB,CAAA"}

View File

@@ -0,0 +1,8 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.isLength = void 0;
var isLength = function (token) {
return token.type === 17 /* NUMBER_TOKEN */ || token.type === 15 /* DIMENSION_TOKEN */;
};
exports.isLength = isLength;
//# sourceMappingURL=length.js.map

View File

@@ -0,0 +1 @@
const a=0,s=1,c=2,e=3,o=4,t=5,b=6;export{a as T,o as a,t as b,b as c,s as d,e,c as f};

View File

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

View File

@@ -0,0 +1,104 @@
"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 datetime_exports = {};
__export(datetime_exports, {
MySqlDateTime: () => MySqlDateTime,
MySqlDateTimeBuilder: () => MySqlDateTimeBuilder,
MySqlDateTimeString: () => MySqlDateTimeString,
MySqlDateTimeStringBuilder: () => MySqlDateTimeStringBuilder,
datetime: () => datetime
});
module.exports = __toCommonJS(datetime_exports);
var import_entity = require("../../entity.cjs");
var import_utils = require("../../utils.cjs");
var import_common = require("./common.cjs");
class MySqlDateTimeBuilder extends import_common.MySqlColumnBuilder {
static [import_entity.entityKind] = "MySqlDateTimeBuilder";
constructor(name, config) {
super(name, "date", "MySqlDateTime");
this.config.fsp = config?.fsp;
}
/** @internal */
build(table) {
return new MySqlDateTime(
table,
this.config
);
}
}
class MySqlDateTime extends import_common.MySqlColumn {
static [import_entity.entityKind] = "MySqlDateTime";
fsp;
constructor(table, config) {
super(table, config);
this.fsp = config.fsp;
}
getSQLType() {
const precision = this.fsp === void 0 ? "" : `(${this.fsp})`;
return `datetime${precision}`;
}
mapToDriverValue(value) {
return value.toISOString().replace("T", " ").replace("Z", "");
}
mapFromDriverValue(value) {
return /* @__PURE__ */ new Date(value.replace(" ", "T") + "Z");
}
}
class MySqlDateTimeStringBuilder extends import_common.MySqlColumnBuilder {
static [import_entity.entityKind] = "MySqlDateTimeStringBuilder";
constructor(name, config) {
super(name, "string", "MySqlDateTimeString");
this.config.fsp = config?.fsp;
}
/** @internal */
build(table) {
return new MySqlDateTimeString(
table,
this.config
);
}
}
class MySqlDateTimeString extends import_common.MySqlColumn {
static [import_entity.entityKind] = "MySqlDateTimeString";
fsp;
constructor(table, config) {
super(table, config);
this.fsp = config.fsp;
}
getSQLType() {
const precision = this.fsp === void 0 ? "" : `(${this.fsp})`;
return `datetime${precision}`;
}
}
function datetime(a, b) {
const { name, config } = (0, import_utils.getColumnNameAndConfig)(a, b);
if (config?.mode === "string") {
return new MySqlDateTimeStringBuilder(name, config);
}
return new MySqlDateTimeBuilder(name, config);
}
// Annotate the CommonJS export names for ESM import in node:
0 && (module.exports = {
MySqlDateTime,
MySqlDateTimeBuilder,
MySqlDateTimeString,
MySqlDateTimeStringBuilder,
datetime
});
//# sourceMappingURL=datetime.cjs.map

View File

@@ -0,0 +1,52 @@
import { DirectusFolder } from "../../../schema/folder.cjs";
import { DirectusFile } from "../../../schema/file.cjs";
import { AssetResponse, AssetsQuery } from "../../../types/assets.cjs";
import { RestCommand } from "../../types.cjs";
//#region src/rest/commands/read/assets.d.ts
/**
* Read the contents of a file as a ReadableStream
*
* @param {string} key
* @param {AssetsQuery} query
* @returns {ReadableStream<Uint8Array>}
*/
declare const readAssetRaw: <Schema>(key: DirectusFile<Schema>["id"], query?: AssetsQuery) => RestCommand<ReadableStream<Uint8Array>, Schema>;
/**
* Read the contents of a file as a Blob
*
* @param {string} key
* @param {AssetsQuery} query
* @returns {Blob}
*/
declare const readAssetBlob: <Schema>(key: DirectusFile<Schema>["id"], query?: AssetsQuery) => RestCommand<Blob, Schema>;
/**
* Read the contents of a file as a ArrayBuffer
*
* @param {string} key
* @param {AssetsQuery} query
* @returns {ArrayBuffer}
*/
declare const readAssetArrayBuffer: <Schema>(key: DirectusFile<Schema>["id"], query?: AssetsQuery) => RestCommand<ArrayBuffer, Schema>;
/**
* Download a ZIP archive containing the specified files.
*
* @param keys An array of file IDs to include in the ZIP archive, must contain at least one ID.
* @param options
*/
declare const downloadFilesZip: <Schema, R extends keyof AssetResponse = "raw">(keys: DirectusFile<Schema>["id"][], options?: {
output: R;
}) => RestCommand<AssetResponse[R], Schema>;
/**
* Download a ZIP archive of an entire folder tree.
*
* @param key The root folder ID to download.
* @param options
*/
declare const downloadFolderZip: <Schema, R extends keyof AssetResponse = "raw">(key: DirectusFolder<Schema>["id"], options?: {
output: R;
}) => RestCommand<AssetResponse[R], Schema>;
//#endregion
export { downloadFilesZip, downloadFolderZip, readAssetArrayBuffer, readAssetBlob, readAssetRaw };
//# sourceMappingURL=assets.d.cts.map

View File

@@ -0,0 +1,52 @@
import { getDate } from "./getDate.mjs";
import { getDay } from "./getDay.mjs";
import { startOfMonth } from "./startOfMonth.mjs";
import { getDefaultOptions } from "./_lib/defaultOptions.mjs";
/**
* The {@link getWeekOfMonth} function options.
*/
/**
* @name getWeekOfMonth
* @category Week Helpers
* @summary Get the week of the month of the given date.
*
* @description
* Get the week of the month of the given date.
*
* @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 date - The given date
* @param options - An object with options.
*
* @returns The week of month
*
* @example
* // Which week of the month is 9 November 2017?
* const result = getWeekOfMonth(new Date(2017, 10, 9))
* //=> 2
*/
export function getWeekOfMonth(date, options) {
const defaultOptions = getDefaultOptions();
const weekStartsOn =
options?.weekStartsOn ??
options?.locale?.options?.weekStartsOn ??
defaultOptions.weekStartsOn ??
defaultOptions.locale?.options?.weekStartsOn ??
0;
const currentDayOfMonth = getDate(date);
if (isNaN(currentDayOfMonth)) return NaN;
const startWeekDay = getDay(startOfMonth(date));
let lastDayOfFirstWeek = weekStartsOn - startWeekDay;
if (lastDayOfFirstWeek <= 0) lastDayOfFirstWeek += 7;
const remainingDaysAfterFirstWeek = currentDayOfMonth - lastDayOfFirstWeek;
return Math.ceil(remainingDaysAfterFirstWeek / 7) + 1;
}
// Fallback for modularized imports:
export default getWeekOfMonth;

View File

@@ -0,0 +1,302 @@
#include <stdint.h>
#include "./BSER.hh"
BSERType decodeType(std::istream &iss) {
int8_t type;
iss.read(reinterpret_cast<char*>(&type), sizeof(type));
return (BSERType) type;
}
void expectType(std::istream &iss, BSERType expected) {
BSERType got = decodeType(iss);
if (got != expected) {
throw std::runtime_error("Unexpected BSER type");
}
}
void encodeType(std::ostream &oss, BSERType type) {
int8_t t = (int8_t)type;
oss.write(reinterpret_cast<char*>(&t), sizeof(t));
}
template<typename T>
class Value : public BSERValue {
public:
T value;
Value(T val) {
value = val;
}
Value() {}
};
class BSERInteger : public Value<int64_t> {
public:
BSERInteger(int64_t value) : Value(value) {}
BSERInteger(std::istream &iss) {
int8_t int8;
int16_t int16;
int32_t int32;
int64_t int64;
BSERType type = decodeType(iss);
switch (type) {
case BSER_INT8:
iss.read(reinterpret_cast<char*>(&int8), sizeof(int8));
value = int8;
break;
case BSER_INT16:
iss.read(reinterpret_cast<char*>(&int16), sizeof(int16));
value = int16;
break;
case BSER_INT32:
iss.read(reinterpret_cast<char*>(&int32), sizeof(int32));
value = int32;
break;
case BSER_INT64:
iss.read(reinterpret_cast<char*>(&int64), sizeof(int64));
value = int64;
break;
default:
throw std::runtime_error("Invalid BSER int type");
}
}
int64_t intValue() override {
return value;
}
void encode(std::ostream &oss) override {
if (value <= INT8_MAX) {
encodeType(oss, BSER_INT8);
int8_t v = (int8_t)value;
oss.write(reinterpret_cast<char*>(&v), sizeof(v));
} else if (value <= INT16_MAX) {
encodeType(oss, BSER_INT16);
int16_t v = (int16_t)value;
oss.write(reinterpret_cast<char*>(&v), sizeof(v));
} else if (value <= INT32_MAX) {
encodeType(oss, BSER_INT32);
int32_t v = (int32_t)value;
oss.write(reinterpret_cast<char*>(&v), sizeof(v));
} else {
encodeType(oss, BSER_INT64);
oss.write(reinterpret_cast<char*>(&value), sizeof(value));
}
}
};
class BSERArray : public Value<BSER::Array> {
public:
BSERArray() : Value() {}
BSERArray(BSER::Array value) : Value(value) {}
BSERArray(std::istream &iss) {
expectType(iss, BSER_ARRAY);
int64_t len = BSERInteger(iss).intValue();
for (int64_t i = 0; i < len; i++) {
value.push_back(BSER(iss));
}
}
BSER::Array arrayValue() override {
return value;
}
void encode(std::ostream &oss) override {
encodeType(oss, BSER_ARRAY);
BSERInteger(value.size()).encode(oss);
for (auto it = value.begin(); it != value.end(); it++) {
it->encode(oss);
}
}
};
class BSERString : public Value<std::string> {
public:
BSERString(std::string value) : Value(value) {}
BSERString(std::istream &iss) {
expectType(iss, BSER_STRING);
int64_t len = BSERInteger(iss).intValue();
value.resize(len);
iss.read(&value[0], len);
}
std::string stringValue() override {
return value;
}
void encode(std::ostream &oss) override {
encodeType(oss, BSER_STRING);
BSERInteger(value.size()).encode(oss);
oss << value;
}
};
class BSERObject : public Value<BSER::Object> {
public:
BSERObject() : Value() {}
BSERObject(BSER::Object value) : Value(value) {}
BSERObject(std::istream &iss) {
expectType(iss, BSER_OBJECT);
int64_t len = BSERInteger(iss).intValue();
for (int64_t i = 0; i < len; i++) {
auto key = BSERString(iss).stringValue();
auto val = BSER(iss);
value.emplace(key, val);
}
}
BSER::Object objectValue() override {
return value;
}
void encode(std::ostream &oss) override {
encodeType(oss, BSER_OBJECT);
BSERInteger(value.size()).encode(oss);
for (auto it = value.begin(); it != value.end(); it++) {
BSERString(it->first).encode(oss);
it->second.encode(oss);
}
}
};
class BSERDouble : public Value<double> {
public:
BSERDouble(double value) : Value(value) {}
BSERDouble(std::istream &iss) {
expectType(iss, BSER_REAL);
iss.read(reinterpret_cast<char*>(&value), sizeof(value));
}
double doubleValue() override {
return value;
}
void encode(std::ostream &oss) override {
encodeType(oss, BSER_REAL);
oss.write(reinterpret_cast<char*>(&value), sizeof(value));
}
};
class BSERBoolean : public Value<bool> {
public:
BSERBoolean(bool value) : Value(value) {}
bool boolValue() override { return value; }
void encode(std::ostream &oss) override {
int8_t t = value == true ? static_cast<int8_t>(BSER_BOOL_TRUE) : static_cast<int8_t>(BSER_BOOL_FALSE);
oss.write(reinterpret_cast<char*>(&t), sizeof(t));
}
};
class BSERNull : public Value<bool> {
public:
BSERNull() : Value(false) {}
void encode(std::ostream &oss) override {
encodeType(oss, BSER_NULL);
}
};
std::shared_ptr<BSERArray> decodeTemplate(std::istream &iss) {
expectType(iss, BSER_TEMPLATE);
auto keys = BSERArray(iss).arrayValue();
auto len = BSERInteger(iss).intValue();
std::shared_ptr<BSERArray> arr = std::make_shared<BSERArray>();
for (int64_t i = 0; i < len; i++) {
BSER::Object obj;
for (auto it = keys.begin(); it != keys.end(); it++) {
if (iss.peek() == 0x0c) {
iss.ignore(1);
continue;
}
auto val = BSER(iss);
obj.emplace(it->stringValue(), val);
}
arr->value.push_back(obj);
}
return arr;
}
BSER::BSER(std::istream &iss) {
BSERType type = decodeType(iss);
iss.unget();
switch (type) {
case BSER_ARRAY:
m_ptr = std::make_shared<BSERArray>(iss);
break;
case BSER_OBJECT:
m_ptr = std::make_shared<BSERObject>(iss);
break;
case BSER_STRING:
m_ptr = std::make_shared<BSERString>(iss);
break;
case BSER_INT8:
case BSER_INT16:
case BSER_INT32:
case BSER_INT64:
m_ptr = std::make_shared<BSERInteger>(iss);
break;
case BSER_REAL:
m_ptr = std::make_shared<BSERDouble>(iss);
break;
case BSER_BOOL_TRUE:
iss.ignore(1);
m_ptr = std::make_shared<BSERBoolean>(true);
break;
case BSER_BOOL_FALSE:
iss.ignore(1);
m_ptr = std::make_shared<BSERBoolean>(false);
break;
case BSER_NULL:
iss.ignore(1);
m_ptr = std::make_shared<BSERNull>();
break;
case BSER_TEMPLATE:
m_ptr = decodeTemplate(iss);
break;
default:
throw std::runtime_error("unknown BSER type");
}
}
BSER::BSER() : m_ptr(std::make_shared<BSERNull>()) {}
BSER::BSER(BSER::Array value) : m_ptr(std::make_shared<BSERArray>(value)) {}
BSER::BSER(BSER::Object value) : m_ptr(std::make_shared<BSERObject>(value)) {}
BSER::BSER(const char *value) : m_ptr(std::make_shared<BSERString>(value)) {}
BSER::BSER(std::string value) : m_ptr(std::make_shared<BSERString>(value)) {}
BSER::BSER(int64_t value) : m_ptr(std::make_shared<BSERInteger>(value)) {}
BSER::BSER(double value) : m_ptr(std::make_shared<BSERDouble>(value)) {}
BSER::BSER(bool value) : m_ptr(std::make_shared<BSERBoolean>(value)) {}
BSER::Array BSER::arrayValue() { return m_ptr->arrayValue(); }
BSER::Object BSER::objectValue() { return m_ptr->objectValue(); }
std::string BSER::stringValue() { return m_ptr->stringValue(); }
int64_t BSER::intValue() { return m_ptr->intValue(); }
double BSER::doubleValue() { return m_ptr->doubleValue(); }
bool BSER::boolValue() { return m_ptr->boolValue(); }
void BSER::encode(std::ostream &oss) {
m_ptr->encode(oss);
}
int64_t BSER::decodeLength(std::istream &iss) {
char pdu[2];
if (!iss.read(pdu, 2) || pdu[0] != 0 || pdu[1] != 1) {
throw std::runtime_error("Invalid BSER");
}
return BSERInteger(iss).intValue();
}
std::string BSER::encode() {
std::ostringstream oss(std::ios_base::binary);
encode(oss);
std::ostringstream res(std::ios_base::binary);
res.write("\x00\x01", 2);
BSERInteger(oss.str().size()).encode(res);
res << oss.str();
return res.str();
}

View File

@@ -0,0 +1 @@
{"version":3,"file":"corner-down-left.js","sources":["../../../src/icons/corner-down-left.ts"],"sourcesContent":["import createLucideIcon from '../createLucideIcon';\n\n/**\n * @component @name CornerDownLeft\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview ![img](data:image/svg+xml;base64,PHN2ZyAgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIgogIHdpZHRoPSIyNCIKICBoZWlnaHQ9IjI0IgogIHZpZXdCb3g9IjAgMCAyNCAyNCIKICBmaWxsPSJub25lIgogIHN0cm9rZT0iIzAwMCIgc3R5bGU9ImJhY2tncm91bmQtY29sb3I6ICNmZmY7IGJvcmRlci1yYWRpdXM6IDJweCIKICBzdHJva2Utd2lkdGg9IjIiCiAgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIgogIHN0cm9rZS1saW5lam9pbj0icm91bmQiCj4KICA8cG9seWxpbmUgcG9pbnRzPSI5IDEwIDQgMTUgOSAyMCIgLz4KICA8cGF0aCBkPSJNMjAgNHY3YTQgNCAwIDAgMS00IDRINCIgLz4KPC9zdmc+Cg==) - https://lucide.dev/icons/corner-down-left\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 CornerDownLeft = createLucideIcon('CornerDownLeft', [\n ['polyline', { points: '9 10 4 15 9 20', key: 'r3jprv' }],\n ['path', { d: 'M20 4v7a4 4 0 0 1-4 4H4', key: '6o5b7l' }],\n]);\n\nexport default CornerDownLeft;\n"],"names":[],"mappings":";;;;;;;;;AAaM,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAiB,iBAAiB,gBAAkB,CAAA,CAAA,CAAA;AAAA,CAAA,CACxD,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAY,CAAA,CAAA,CAAA,CAAE,QAAQ,CAAkB,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,CACxD,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAA2B,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,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;AAC1D,CAAC,CAAA,CAAA;;"}

View File

@@ -0,0 +1,124 @@
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
const carrier = require('../carrier.js');
const debugBuild = require('../debug-build.js');
const worldwide = require('./worldwide.js');
const CONSOLE_LEVELS = [
'debug',
'info',
'warn',
'error',
'log',
'assert',
'trace',
] ;
/** Prefix for logging strings */
const PREFIX = 'Sentry Logger ';
/** This may be mutated by the console instrumentation. */
const originalConsoleMethods
= {};
/**
* Temporarily disable sentry console instrumentations.
*
* @param callback The function to run against the original `console` messages
* @returns The results of the callback
*/
function consoleSandbox(callback) {
if (!('console' in worldwide.GLOBAL_OBJ)) {
return callback();
}
const console = worldwide.GLOBAL_OBJ.console;
const wrappedFuncs = {};
const wrappedLevels = Object.keys(originalConsoleMethods) ;
// Restore all wrapped console methods
wrappedLevels.forEach(level => {
const originalConsoleMethod = originalConsoleMethods[level];
wrappedFuncs[level] = console[level] ;
console[level] = originalConsoleMethod ;
});
try {
return callback();
} finally {
// Revert restoration to wrapped state
wrappedLevels.forEach(level => {
console[level] = wrappedFuncs[level] ;
});
}
}
function enable() {
_getLoggerSettings().enabled = true;
}
function disable() {
_getLoggerSettings().enabled = false;
}
function isEnabled() {
return _getLoggerSettings().enabled;
}
function log(...args) {
_maybeLog('log', ...args);
}
function warn(...args) {
_maybeLog('warn', ...args);
}
function error(...args) {
_maybeLog('error', ...args);
}
function _maybeLog(level, ...args) {
if (!debugBuild.DEBUG_BUILD) {
return;
}
if (isEnabled()) {
consoleSandbox(() => {
worldwide.GLOBAL_OBJ.console[level](`${PREFIX}[${level}]:`, ...args);
});
}
}
function _getLoggerSettings() {
if (!debugBuild.DEBUG_BUILD) {
return { enabled: false };
}
return carrier.getGlobalSingleton('loggerSettings', () => ({ enabled: false }));
}
/**
* This is a logger singleton which either logs things or no-ops if logging is not enabled.
*/
const debug = {
/** Enable logging. */
enable,
/** Disable logging. */
disable,
/** Check if logging is enabled. */
isEnabled,
/** Log a message. */
log,
/** Log a warning. */
warn,
/** Log an error. */
error,
} ;
exports.CONSOLE_LEVELS = CONSOLE_LEVELS;
exports.consoleSandbox = consoleSandbox;
exports.debug = debug;
exports.originalConsoleMethods = originalConsoleMethods;
//# sourceMappingURL=debug-logger.js.map

View File

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

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