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 @@
{"version":3,"file":"index.js","names":["React","useTranslation","Button","Dropzone","DrawerHeader","baseClass","AddFilesView","acceptMimeTypes","onCancel","onDrop","t","inputRef","useRef","_jsxs","className","_jsx","onClose","title","multipleFiles","onChange","buttonStyle","iconPosition","onClick","current","click","size","accept","hidden","multiple","e","target","files","length","ref","type"],"sources":["../../../../src/elements/BulkUpload/AddFilesView/index.tsx"],"sourcesContent":["'use client'\n\nimport React from 'react'\n\nimport { useTranslation } from '../../../providers/Translation/index.js'\nimport { Button } from '../../Button/index.js'\nimport { Dropzone } from '../../Dropzone/index.js'\nimport { DrawerHeader } from '../Header/index.js'\nimport './index.scss'\n\nconst baseClass = 'bulk-upload--add-files'\n\ntype Props = {\n readonly acceptMimeTypes?: string\n readonly onCancel: () => void\n readonly onDrop: (acceptedFiles: FileList) => void\n}\nexport function AddFilesView({ acceptMimeTypes, onCancel, onDrop }: Props) {\n const { t } = useTranslation()\n\n const inputRef = React.useRef(null)\n\n return (\n <div className={baseClass}>\n <DrawerHeader onClose={onCancel} title={t('upload:addFiles')} />\n <div className={`${baseClass}__dropArea`}>\n <Dropzone multipleFiles onChange={onDrop}>\n <Button\n buttonStyle=\"subtle\"\n iconPosition=\"left\"\n onClick={() => {\n if (inputRef.current) {\n inputRef.current.click()\n }\n }}\n size=\"small\"\n >\n {t('upload:selectFile')}\n </Button>\n <input\n accept={acceptMimeTypes}\n aria-hidden=\"true\"\n className={`${baseClass}__hidden-input`}\n hidden\n multiple\n onChange={(e) => {\n if (e.target.files && e.target.files.length > 0) {\n onDrop(e.target.files)\n }\n }}\n ref={inputRef}\n type=\"file\"\n />\n\n <p className={`${baseClass}__dragAndDropText`}>\n {t('general:or')} {t('upload:dragAndDrop')}\n </p>\n </Dropzone>\n </div>\n </div>\n )\n}\n"],"mappings":"AAAA;;;AAEA,OAAOA,KAAA,MAAW;AAElB,SAASC,cAAc,QAAQ;AAC/B,SAASC,MAAM,QAAQ;AACvB,SAASC,QAAQ,QAAQ;AACzB,SAASC,YAAY,QAAQ;AAC7B,OAAO;AAEP,MAAMC,SAAA,GAAY;AAOlB,OAAO,SAASC,aAAa;EAAEC,eAAe;EAAEC,QAAQ;EAAEC;AAAM,CAAS;EACvE,MAAM;IAAEC;EAAC,CAAE,GAAGT,cAAA;EAEd,MAAMU,QAAA,GAAWX,KAAA,CAAMY,MAAM,CAAC;EAE9B,oBACEC,KAAA,CAAC;IAAIC,SAAA,EAAWT,SAAA;4BACdU,IAAA,CAACX,YAAA;MAAaY,OAAA,EAASR,QAAA;MAAUS,KAAA,EAAOP,CAAA,CAAE;qBAC1CK,IAAA,CAAC;MAAID,SAAA,EAAW,GAAGT,SAAA,YAAqB;gBACtC,aAAAQ,KAAA,CAACV,QAAA;QAASe,aAAa;QAACC,QAAA,EAAUV,MAAA;gCAChCM,IAAA,CAACb,MAAA;UACCkB,WAAA,EAAY;UACZC,YAAA,EAAa;UACbC,OAAA,EAASA,CAAA;YACP,IAAIX,QAAA,CAASY,OAAO,EAAE;cACpBZ,QAAA,CAASY,OAAO,CAACC,KAAK;YACxB;UACF;UACAC,IAAA,EAAK;oBAEJf,CAAA,CAAE;yBAELK,IAAA,CAAC;UACCW,MAAA,EAAQnB,eAAA;UACR,eAAY;UACZO,SAAA,EAAW,GAAGT,SAAA,gBAAyB;UACvCsB,MAAM;UACNC,QAAQ;UACRT,QAAA,EAAWU,CAAA;YACT,IAAIA,CAAA,CAAEC,MAAM,CAACC,KAAK,IAAIF,CAAA,CAAEC,MAAM,CAACC,KAAK,CAACC,MAAM,GAAG,GAAG;cAC/CvB,MAAA,CAAOoB,CAAA,CAAEC,MAAM,CAACC,KAAK;YACvB;UACF;UACAE,GAAA,EAAKtB,QAAA;UACLuB,IAAA,EAAK;yBAGPrB,KAAA,CAAC;UAAEC,SAAA,EAAW,GAAGT,SAAA,mBAA4B;qBAC1CK,CAAA,CAAE,eAAc,KAAEA,CAAA,CAAE;;;;;AAMjC","ignoreList":[]}

View File

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

View File

@@ -0,0 +1,19 @@
/**
* @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 Cigarette = createLucideIcon("Cigarette", [
["path", { d: "M17 12H3a1 1 0 0 0-1 1v2a1 1 0 0 0 1 1h14", key: "1mb5g1" }],
["path", { d: "M18 8c0-2.5-2-2.5-2-5", key: "1il607" }],
["path", { d: "M21 16a1 1 0 0 0 1-1v-2a1 1 0 0 0-1-1", key: "1yl5r7" }],
["path", { d: "M22 8c0-2.5-2-2.5-2-5", key: "1gah44" }],
["path", { d: "M7 12v4", key: "jqww69" }]
]);
export { Cigarette as default };
//# sourceMappingURL=cigarette.js.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/elements/ListHeader/TitleActions/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,2BAA2B,CAAA;AAChE,OAAO,EAAE,mBAAmB,EAAE,MAAM,6BAA6B,CAAA;AACjE,OAAO,EAAE,8BAA8B,EAAE,MAAM,qCAAqC,CAAA;AACpF,OAAO,EAAE,oBAAoB,EAAE,MAAM,2BAA2B,CAAA"}

View File

@@ -0,0 +1 @@
{"version":3,"file":"briefcase-medical.js","sources":["../../../src/icons/briefcase-medical.ts"],"sourcesContent":["import createLucideIcon from '../createLucideIcon';\n\n/**\n * @component @name BriefcaseMedical\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview ![img](data:image/svg+xml;base64,PHN2ZyAgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIgogIHdpZHRoPSIyNCIKICBoZWlnaHQ9IjI0IgogIHZpZXdCb3g9IjAgMCAyNCAyNCIKICBmaWxsPSJub25lIgogIHN0cm9rZT0iIzAwMCIgc3R5bGU9ImJhY2tncm91bmQtY29sb3I6ICNmZmY7IGJvcmRlci1yYWRpdXM6IDJweCIKICBzdHJva2Utd2lkdGg9IjIiCiAgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIgogIHN0cm9rZS1saW5lam9pbj0icm91bmQiCj4KICA8cGF0aCBkPSJNMTIgMTF2NCIgLz4KICA8cGF0aCBkPSJNMTQgMTNoLTQiIC8+CiAgPHBhdGggZD0iTTE2IDZWNGEyIDIgMCAwIDAtMi0yaC00YTIgMiAwIDAgMC0yIDJ2MiIgLz4KICA8cGF0aCBkPSJNMTggNnYxNCIgLz4KICA8cGF0aCBkPSJNNiA2djE0IiAvPgogIDxyZWN0IHdpZHRoPSIyMCIgaGVpZ2h0PSIxNCIgeD0iMiIgeT0iNiIgcng9IjIiIC8+Cjwvc3ZnPgo=) - https://lucide.dev/icons/briefcase-medical\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 BriefcaseMedical = createLucideIcon('BriefcaseMedical', [\n ['path', { d: 'M12 11v4', key: 'a6ujw6' }],\n ['path', { d: 'M14 13h-4', key: '1pl8zg' }],\n ['path', { d: 'M16 6V4a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v2', key: '1ksdt3' }],\n ['path', { d: 'M18 6v14', key: '1mu4gy' }],\n ['path', { d: 'M6 6v14', key: '1s15cj' }],\n ['rect', { width: '20', height: '14', x: '2', y: '6', rx: '2', key: 'i6l2r4' }],\n]);\n\nexport default BriefcaseMedical;\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,CAAA,CAAA,CAAmB,iBAAiB,kBAAoB,CAAA,CAAA,CAAA;AAAA,CAAA,CAC5D,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,CAAA;AAAA,CAAA,CACzC,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAa,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CAC1C,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAA4C,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,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,CACzE,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,CAAA;AAAA,CAAA,CACzC,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAW,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CACxC,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,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,CAAA,CAAM,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;AAChF,CAAC,CAAA,CAAA;;"}

View File

@@ -0,0 +1,161 @@
"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 decimal_exports = {};
__export(decimal_exports, {
MySqlDecimal: () => MySqlDecimal,
MySqlDecimalBigInt: () => MySqlDecimalBigInt,
MySqlDecimalBigIntBuilder: () => MySqlDecimalBigIntBuilder,
MySqlDecimalBuilder: () => MySqlDecimalBuilder,
MySqlDecimalNumber: () => MySqlDecimalNumber,
MySqlDecimalNumberBuilder: () => MySqlDecimalNumberBuilder,
decimal: () => decimal
});
module.exports = __toCommonJS(decimal_exports);
var import_entity = require("../../entity.cjs");
var import_utils = require("../../utils.cjs");
var import_common = require("./common.cjs");
class MySqlDecimalBuilder extends import_common.MySqlColumnBuilderWithAutoIncrement {
static [import_entity.entityKind] = "MySqlDecimalBuilder";
constructor(name, config) {
super(name, "string", "MySqlDecimal");
this.config.precision = config?.precision;
this.config.scale = config?.scale;
this.config.unsigned = config?.unsigned;
}
/** @internal */
build(table) {
return new MySqlDecimal(
table,
this.config
);
}
}
class MySqlDecimal extends import_common.MySqlColumnWithAutoIncrement {
static [import_entity.entityKind] = "MySqlDecimal";
precision = this.config.precision;
scale = this.config.scale;
unsigned = this.config.unsigned;
mapFromDriverValue(value) {
if (typeof value === "string") return value;
return String(value);
}
getSQLType() {
let type = "";
if (this.precision !== void 0 && this.scale !== void 0) {
type += `decimal(${this.precision},${this.scale})`;
} else if (this.precision === void 0) {
type += "decimal";
} else {
type += `decimal(${this.precision})`;
}
type = type === "decimal(10,0)" || type === "decimal(10)" ? "decimal" : type;
return this.unsigned ? `${type} unsigned` : type;
}
}
class MySqlDecimalNumberBuilder extends import_common.MySqlColumnBuilderWithAutoIncrement {
static [import_entity.entityKind] = "MySqlDecimalNumberBuilder";
constructor(name, config) {
super(name, "number", "MySqlDecimalNumber");
this.config.precision = config?.precision;
this.config.scale = config?.scale;
this.config.unsigned = config?.unsigned;
}
/** @internal */
build(table) {
return new MySqlDecimalNumber(
table,
this.config
);
}
}
class MySqlDecimalNumber extends import_common.MySqlColumnWithAutoIncrement {
static [import_entity.entityKind] = "MySqlDecimalNumber";
precision = this.config.precision;
scale = this.config.scale;
unsigned = this.config.unsigned;
mapFromDriverValue(value) {
if (typeof value === "number") return value;
return Number(value);
}
mapToDriverValue = String;
getSQLType() {
let type = "";
if (this.precision !== void 0 && this.scale !== void 0) {
type += `decimal(${this.precision},${this.scale})`;
} else if (this.precision === void 0) {
type += "decimal";
} else {
type += `decimal(${this.precision})`;
}
type = type === "decimal(10,0)" || type === "decimal(10)" ? "decimal" : type;
return this.unsigned ? `${type} unsigned` : type;
}
}
class MySqlDecimalBigIntBuilder extends import_common.MySqlColumnBuilderWithAutoIncrement {
static [import_entity.entityKind] = "MySqlDecimalBigIntBuilder";
constructor(name, config) {
super(name, "bigint", "MySqlDecimalBigInt");
this.config.precision = config?.precision;
this.config.scale = config?.scale;
this.config.unsigned = config?.unsigned;
}
/** @internal */
build(table) {
return new MySqlDecimalBigInt(
table,
this.config
);
}
}
class MySqlDecimalBigInt extends import_common.MySqlColumnWithAutoIncrement {
static [import_entity.entityKind] = "MySqlDecimalBigInt";
precision = this.config.precision;
scale = this.config.scale;
unsigned = this.config.unsigned;
mapFromDriverValue = BigInt;
mapToDriverValue = String;
getSQLType() {
let type = "";
if (this.precision !== void 0 && this.scale !== void 0) {
type += `decimal(${this.precision},${this.scale})`;
} else if (this.precision === void 0) {
type += "decimal";
} else {
type += `decimal(${this.precision})`;
}
type = type === "decimal(10,0)" || type === "decimal(10)" ? "decimal" : type;
return this.unsigned ? `${type} unsigned` : type;
}
}
function decimal(a, b = {}) {
const { name, config } = (0, import_utils.getColumnNameAndConfig)(a, b);
const mode = config?.mode;
return mode === "number" ? new MySqlDecimalNumberBuilder(name, config) : mode === "bigint" ? new MySqlDecimalBigIntBuilder(name, config) : new MySqlDecimalBuilder(name, config);
}
// Annotate the CommonJS export names for ESM import in node:
0 && (module.exports = {
MySqlDecimal,
MySqlDecimalBigInt,
MySqlDecimalBigIntBuilder,
MySqlDecimalBuilder,
MySqlDecimalNumber,
MySqlDecimalNumberBuilder,
decimal
});
//# sourceMappingURL=decimal.cjs.map

View File

@@ -0,0 +1,37 @@
"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 date_common_exports = {};
__export(date_common_exports, {
GelLocalDateColumnBaseBuilder: () => GelLocalDateColumnBaseBuilder
});
module.exports = __toCommonJS(date_common_exports);
var import_entity = require("../../entity.cjs");
var import_sql = require("../../sql/sql.cjs");
var import_common = require("./common.cjs");
class GelLocalDateColumnBaseBuilder extends import_common.GelColumnBuilder {
static [import_entity.entityKind] = "GelLocalDateColumnBaseBuilder";
defaultNow() {
return this.default(import_sql.sql`now()`);
}
}
// Annotate the CommonJS export names for ESM import in node:
0 && (module.exports = {
GelLocalDateColumnBaseBuilder
});
//# sourceMappingURL=date.common.cjs.map

View File

@@ -0,0 +1,99 @@
/**
* 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.
*
* @flow strict
*/
import type {
DOMConversionMap,
EditorConfig,
LexicalNode,
NodeKey,
RangeSelection,
LexicalCommand,
SerializedElementNode,
} from 'lexical';
import {addClassNamesToElement} from '@lexical/utils';
import {$isElementNode, ElementNode} from 'lexical';
export type LinkAttributes = $ReadOnly<{
rel?: null | string,
target?: null | string,
title?: null | string,
}>;
export type SerializedLinkNode = {
...SerializedElementNode,
rel?: null | string,
target?: null | string,
title?: null | string,
url: string,
...
};
declare export class LinkNode extends ElementNode {
__url: string;
__target: null | string;
__rel: null | string;
__title: null | string;
static getType(): string;
static clone(node: LinkNode): LinkNode;
constructor(url: string, attributes?: LinkAttributes, key?: NodeKey): void;
createDOM(config: EditorConfig): HTMLElement;
static importDOM(): DOMConversionMap | null;
exportJSON(): SerializedLinkNode;
getURL(): string;
setURL(url: string): void;
getTarget(): null | string;
setTarget(target: null | string): void;
getRel(): null | string;
setRel(rel: null | string): void;
getTitle(): null | string;
setTitle(title: null | string): void;
insertNewAfter(
selection: RangeSelection,
restoreSelection?: boolean,
): null | ElementNode;
canInsertTextBefore(): false;
canInsertTextAfter(): false;
canBeEmpty(): false;
isInline(): true;
}
declare export function $createLinkNode(
url: string,
attributes?: LinkAttributes,
): LinkNode;
declare export function $isLinkNode(
node: ?LexicalNode,
): node is LinkNode;
export type SerializedAutoLinkNode = {
...SerializedLinkNode,
isUnlinked: boolean,
...
};
declare export class AutoLinkNode extends LinkNode {
static getType(): string;
// $FlowFixMe[incompatible-type] clone method inheritance
static clone(node: AutoLinkNode): AutoLinkNode;
insertNewAfter(
selection: RangeSelection,
restoreSelection?: boolean,
): null | ElementNode;
}
declare export function $createAutoLinkNode(
url: string,
attributes?: LinkAttributes,
): AutoLinkNode;
declare export function $isAutoLinkNode(
node: ?LexicalNode,
): node is AutoLinkNode;
declare export var TOGGLE_LINK_COMMAND: LexicalCommand<
string | {url: string, ...LinkAttributes} | null,
>;
declare export function $toggleLink(
url: null | string,
attributes: LinkAttributes,
): void;
/** @deprecated renamed to {@link $toggleLink} by @lexical/eslint-plugin rules-of-lexical */
declare const toggleLink: typeof $toggleLink;
declare export function formatUrl(url: string): string;

View File

@@ -0,0 +1,61 @@
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
const index$1 = require('./config/withSentryConfig/index.js');
const index = require('./server/index.js');
const node = require('@sentry/node');
const captureRequestError = require('./common/captureRequestError.js');
const _error = require('./common/pages-router-instrumentation/_error.js');
const nextSpan = require('./common/utils/nextSpan.js');
const withServerActionInstrumentation = require('./common/withServerActionInstrumentation.js');
const wrapApiHandlerWithSentry = require('./common/pages-router-instrumentation/wrapApiHandlerWithSentry.js');
const wrapApiHandlerWithSentryVercelCrons = require('./common/pages-router-instrumentation/wrapApiHandlerWithSentryVercelCrons.js');
const wrapAppGetInitialPropsWithSentry = require('./common/pages-router-instrumentation/wrapAppGetInitialPropsWithSentry.js');
const wrapDocumentGetInitialPropsWithSentry = require('./common/pages-router-instrumentation/wrapDocumentGetInitialPropsWithSentry.js');
const wrapErrorGetInitialPropsWithSentry = require('./common/pages-router-instrumentation/wrapErrorGetInitialPropsWithSentry.js');
const wrapGenerationFunctionWithSentry = require('./common/wrapGenerationFunctionWithSentry.js');
const wrapGetInitialPropsWithSentry = require('./common/pages-router-instrumentation/wrapGetInitialPropsWithSentry.js');
const wrapGetServerSidePropsWithSentry = require('./common/pages-router-instrumentation/wrapGetServerSidePropsWithSentry.js');
const wrapGetStaticPropsWithSentry = require('./common/pages-router-instrumentation/wrapGetStaticPropsWithSentry.js');
const wrapMiddlewareWithSentry = require('./common/wrapMiddlewareWithSentry.js');
const wrapPageComponentWithSentry = require('./common/pages-router-instrumentation/wrapPageComponentWithSentry.js');
const wrapRouteHandlerWithSentry = require('./common/wrapRouteHandlerWithSentry.js');
const wrapServerComponentWithSentry = require('./common/wrapServerComponentWithSentry.js');
exports.withSentryConfig = index$1.withSentryConfig;
exports.ErrorBoundary = index.ErrorBoundary;
exports.createReduxEnhancer = index.createReduxEnhancer;
exports.init = index.init;
exports.showReportDialog = index.showReportDialog;
exports.withErrorBoundary = index.withErrorBoundary;
exports.captureRequestError = captureRequestError.captureRequestError;
exports.captureUnderscoreErrorException = _error.captureUnderscoreErrorException;
exports.startInactiveSpan = nextSpan.startInactiveSpan;
exports.startSpan = nextSpan.startSpan;
exports.startSpanManual = nextSpan.startSpanManual;
exports.withServerActionInstrumentation = withServerActionInstrumentation.withServerActionInstrumentation;
exports.wrapApiHandlerWithSentry = wrapApiHandlerWithSentry.wrapApiHandlerWithSentry;
exports.wrapApiHandlerWithSentryVercelCrons = wrapApiHandlerWithSentryVercelCrons.wrapApiHandlerWithSentryVercelCrons;
exports.wrapAppGetInitialPropsWithSentry = wrapAppGetInitialPropsWithSentry.wrapAppGetInitialPropsWithSentry;
exports.wrapDocumentGetInitialPropsWithSentry = wrapDocumentGetInitialPropsWithSentry.wrapDocumentGetInitialPropsWithSentry;
exports.wrapErrorGetInitialPropsWithSentry = wrapErrorGetInitialPropsWithSentry.wrapErrorGetInitialPropsWithSentry;
exports.wrapGenerationFunctionWithSentry = wrapGenerationFunctionWithSentry.wrapGenerationFunctionWithSentry;
exports.wrapGetInitialPropsWithSentry = wrapGetInitialPropsWithSentry.wrapGetInitialPropsWithSentry;
exports.wrapGetServerSidePropsWithSentry = wrapGetServerSidePropsWithSentry.wrapGetServerSidePropsWithSentry;
exports.wrapGetStaticPropsWithSentry = wrapGetStaticPropsWithSentry.wrapGetStaticPropsWithSentry;
exports.wrapMiddlewareWithSentry = wrapMiddlewareWithSentry.wrapMiddlewareWithSentry;
exports.wrapPageComponentWithSentry = wrapPageComponentWithSentry.wrapPageComponentWithSentry;
exports.wrapRouteHandlerWithSentry = wrapRouteHandlerWithSentry.wrapRouteHandlerWithSentry;
exports.wrapServerComponentWithSentry = wrapServerComponentWithSentry.wrapServerComponentWithSentry;
Object.prototype.hasOwnProperty.call(node, '__proto__') &&
!Object.prototype.hasOwnProperty.call(exports, '__proto__') &&
Object.defineProperty(exports, '__proto__', {
enumerable: true,
value: node['__proto__']
});
Object.keys(node).forEach(k => {
if (k !== 'default' && !Object.prototype.hasOwnProperty.call(exports, k)) exports[k] = node[k];
});
//# sourceMappingURL=index.server.js.map

View File

@@ -0,0 +1,154 @@
/*
MIT License http://www.opensource.org/licenses/mit-license.php
Author Tobias Koppers @sokra
*/
"use strict";
const RuntimeGlobals = require("../RuntimeGlobals");
const RuntimeModule = require("../RuntimeModule");
const Template = require("../Template");
/** @typedef {import("../Chunk")} Chunk */
/** @typedef {import("../Compilation")} Compilation */
/** @typedef {(wasmModuleSrcPath: string) => string} GenerateBeforeLoadBinaryCode */
/** @typedef {(wasmModuleSrcPath: string) => string} GenerateLoadBinaryCode */
/** @typedef {() => string} GenerateBeforeInstantiateStreaming */
/**
* @typedef {object} AsyncWasmLoadingRuntimeModuleOptions
* @property {GenerateLoadBinaryCode} generateLoadBinaryCode
* @property {GenerateBeforeLoadBinaryCode=} generateBeforeLoadBinaryCode
* @property {GenerateBeforeInstantiateStreaming=} generateBeforeInstantiateStreaming
* @property {boolean} supportsStreaming
*/
class AsyncWasmLoadingRuntimeModule extends RuntimeModule {
/**
* @param {AsyncWasmLoadingRuntimeModuleOptions} options options
*/
constructor({
generateLoadBinaryCode,
generateBeforeLoadBinaryCode,
generateBeforeInstantiateStreaming,
supportsStreaming
}) {
super("wasm loading", RuntimeModule.STAGE_NORMAL);
/** @type {GenerateLoadBinaryCode} */
this.generateLoadBinaryCode = generateLoadBinaryCode;
/** @type {generateBeforeLoadBinaryCode | undefined} */
this.generateBeforeLoadBinaryCode = generateBeforeLoadBinaryCode;
/** @type {generateBeforeInstantiateStreaming | undefined} */
this.generateBeforeInstantiateStreaming =
generateBeforeInstantiateStreaming;
/** @type {boolean} */
this.supportsStreaming = supportsStreaming;
}
/**
* @returns {string | null} runtime code
*/
generate() {
const compilation = /** @type {Compilation} */ (this.compilation);
const chunk = /** @type {Chunk} */ (this.chunk);
const { outputOptions, runtimeTemplate } = compilation;
const fn = RuntimeGlobals.instantiateWasm;
const wasmModuleSrcPath = compilation.getPath(
JSON.stringify(outputOptions.webassemblyModuleFilename),
{
hash: `" + ${RuntimeGlobals.getFullHash}() + "`,
hashWithLength: (length) =>
`" + ${RuntimeGlobals.getFullHash}}().slice(0, ${length}) + "`,
module: {
id: '" + wasmModuleId + "',
hash: '" + wasmModuleHash + "',
hashWithLength(length) {
return `" + wasmModuleHash.slice(0, ${length}) + "`;
}
},
runtime: chunk.runtime
}
);
const loader = this.generateLoadBinaryCode(wasmModuleSrcPath);
const fallback = [
`.then(${runtimeTemplate.returningFunction("x.arrayBuffer()", "x")})`,
`.then(${runtimeTemplate.returningFunction(
"WebAssembly.instantiate(bytes, importsObj)",
"bytes"
)})`,
`.then(${runtimeTemplate.returningFunction(
"Object.assign(exports, res.instance.exports)",
"res"
)})`
];
const getStreaming = () => {
/**
* @param {string[]} text text
* @returns {string} merged text
*/
const concat = (...text) => text.join("");
return [
this.generateBeforeLoadBinaryCode
? this.generateBeforeLoadBinaryCode(wasmModuleSrcPath)
: "",
`var req = ${loader};`,
`var fallback = ${runtimeTemplate.returningFunction(
Template.asString(["req", Template.indent(fallback)])
)};`,
concat(
"return req.then(",
runtimeTemplate.basicFunction("res", [
'if (typeof WebAssembly.instantiateStreaming === "function") {',
Template.indent(
this.generateBeforeInstantiateStreaming
? this.generateBeforeInstantiateStreaming()
: ""
),
Template.indent([
"return WebAssembly.instantiateStreaming(res, importsObj)",
Template.indent([
".then(",
Template.indent([
`${runtimeTemplate.returningFunction(
"Object.assign(exports, res.instance.exports)",
"res"
)},`,
runtimeTemplate.basicFunction("e", [
'if(res.headers.get("Content-Type") !== "application/wasm") {',
Template.indent([
'console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\\n", e);',
"return fallback();"
]),
"}",
"throw e;"
])
]),
");"
])
]),
"}",
"return fallback();"
]),
");"
)
];
};
return `${fn} = ${runtimeTemplate.basicFunction(
"exports, wasmModuleId, wasmModuleHash, importsObj",
this.supportsStreaming
? getStreaming()
: [
this.generateBeforeLoadBinaryCode
? this.generateBeforeLoadBinaryCode(wasmModuleSrcPath)
: "",
`return ${loader}`,
`${Template.indent(fallback)};`
]
)};`;
}
}
module.exports = AsyncWasmLoadingRuntimeModule;

View File

@@ -0,0 +1 @@
{"version":3,"file":"sentryNonRecordingSpan.js","sources":["../../../src/tracing/sentryNonRecordingSpan.ts"],"sourcesContent":["import type {\n SentrySpanArguments,\n Span,\n SpanAttributes,\n SpanAttributeValue,\n SpanContextData,\n SpanTimeInput,\n} from '../types-hoist/span';\nimport type { SpanStatus } from '../types-hoist/spanStatus';\nimport { generateSpanId, generateTraceId } from '../utils/propagationContext';\nimport { TRACE_FLAG_NONE } from '../utils/spanUtils';\n\n/**\n * A Sentry Span that is non-recording, meaning it will not be sent to Sentry.\n */\nexport class SentryNonRecordingSpan implements Span {\n private _traceId: string;\n private _spanId: string;\n\n public constructor(spanContext: SentrySpanArguments = {}) {\n this._traceId = spanContext.traceId || generateTraceId();\n this._spanId = spanContext.spanId || generateSpanId();\n }\n\n /** @inheritdoc */\n public spanContext(): SpanContextData {\n return {\n spanId: this._spanId,\n traceId: this._traceId,\n traceFlags: TRACE_FLAG_NONE,\n };\n }\n\n /** @inheritdoc */\n public end(_timestamp?: SpanTimeInput): void {}\n\n /** @inheritdoc */\n public setAttribute(_key: string, _value: SpanAttributeValue | undefined): this {\n return this;\n }\n\n /** @inheritdoc */\n public setAttributes(_values: SpanAttributes): this {\n return this;\n }\n\n /** @inheritdoc */\n public setStatus(_status: SpanStatus): this {\n return this;\n }\n\n /** @inheritdoc */\n public updateName(_name: string): this {\n return this;\n }\n\n /** @inheritdoc */\n public isRecording(): boolean {\n return false;\n }\n\n /** @inheritdoc */\n public addEvent(\n _name: string,\n _attributesOrStartTime?: SpanAttributes | SpanTimeInput,\n _startTime?: SpanTimeInput,\n ): this {\n return this;\n }\n\n /** @inheritDoc */\n public addLink(_link: unknown): this {\n return this;\n }\n\n /** @inheritDoc */\n public addLinks(_links: unknown[]): this {\n return this;\n }\n\n /**\n * This should generally not be used,\n * but we need it for being compliant with the OTEL Span interface.\n *\n * @hidden\n * @internal\n */\n public recordException(_exception: unknown, _time?: number | undefined): void {\n // noop\n }\n}\n"],"names":[],"mappings":";;;AAYA;AACA;AACA;AACO,MAAM,wBAAuC;;AAIpD,GAAS,WAAW,CAAC,WAAW,GAAwB,EAAE,EAAE;AAC5D,IAAI,IAAI,CAAC,QAAA,GAAW,WAAW,CAAC,OAAA,IAAW,eAAe,EAAE;AAC5D,IAAI,IAAI,CAAC,OAAA,GAAU,WAAW,CAAC,MAAA,IAAU,cAAc,EAAE;AACzD,EAAE;;AAEF;AACA,GAAS,WAAW,GAAoB;AACxC,IAAI,OAAO;AACX,MAAM,MAAM,EAAE,IAAI,CAAC,OAAO;AAC1B,MAAM,OAAO,EAAE,IAAI,CAAC,QAAQ;AAC5B,MAAM,UAAU,EAAE,eAAe;AACjC,KAAK;AACL,EAAE;;AAEF;AACA,GAAS,GAAG,CAAC,UAAU,EAAwB,CAAC;;AAEhD;AACA,GAAS,YAAY,CAAC,IAAI,EAAU,MAAM,EAAwC;AAClF,IAAI,OAAO,IAAI;AACf,EAAE;;AAEF;AACA,GAAS,aAAa,CAAC,OAAO,EAAwB;AACtD,IAAI,OAAO,IAAI;AACf,EAAE;;AAEF;AACA,GAAS,SAAS,CAAC,OAAO,EAAoB;AAC9C,IAAI,OAAO,IAAI;AACf,EAAE;;AAEF;AACA,GAAS,UAAU,CAAC,KAAK,EAAgB;AACzC,IAAI,OAAO,IAAI;AACf,EAAE;;AAEF;AACA,GAAS,WAAW,GAAY;AAChC,IAAI,OAAO,KAAK;AAChB,EAAE;;AAEF;AACA,GAAS,QAAQ;AACjB,IAAI,KAAK;AACT,IAAI,sBAAsB;AAC1B,IAAI,UAAU;AACd,IAAU;AACV,IAAI,OAAO,IAAI;AACf,EAAE;;AAEF;AACA,GAAS,OAAO,CAAC,KAAK,EAAiB;AACvC,IAAI,OAAO,IAAI;AACf,EAAE;;AAEF;AACA,GAAS,QAAQ,CAAC,MAAM,EAAmB;AAC3C,IAAI,OAAO,IAAI;AACf,EAAE;;AAEF;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAS,eAAe,CAAC,UAAU,EAAW,KAAK,EAA6B;AAChF;AACA,EAAE;AACF;;;;"}

View File

@@ -0,0 +1,89 @@
/*
* 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.
*/
import { getGlobal, registerGlobal, unregisterGlobal, } from '../internal/global-utils';
import { NoopTextMapPropagator } from '../propagation/NoopTextMapPropagator';
import { defaultTextMapGetter, defaultTextMapSetter, } from '../propagation/TextMapPropagator';
import { getBaggage, getActiveBaggage, setBaggage, deleteBaggage, } from '../baggage/context-helpers';
import { createBaggage } from '../baggage/utils';
import { DiagAPI } from './diag';
var API_NAME = 'propagation';
var NOOP_TEXT_MAP_PROPAGATOR = new NoopTextMapPropagator();
/**
* Singleton object which represents the entry point to the OpenTelemetry Propagation API
*/
var PropagationAPI = /** @class */ (function () {
/** Empty private constructor prevents end users from constructing a new instance of the API */
function PropagationAPI() {
this.createBaggage = createBaggage;
this.getBaggage = getBaggage;
this.getActiveBaggage = getActiveBaggage;
this.setBaggage = setBaggage;
this.deleteBaggage = deleteBaggage;
}
/** Get the singleton instance of the Propagator API */
PropagationAPI.getInstance = function () {
if (!this._instance) {
this._instance = new PropagationAPI();
}
return this._instance;
};
/**
* Set the current propagator.
*
* @returns true if the propagator was successfully registered, else false
*/
PropagationAPI.prototype.setGlobalPropagator = function (propagator) {
return registerGlobal(API_NAME, propagator, DiagAPI.instance());
};
/**
* Inject context into a carrier to be propagated inter-process
*
* @param context Context carrying tracing data to inject
* @param carrier carrier to inject context into
* @param setter Function used to set values on the carrier
*/
PropagationAPI.prototype.inject = function (context, carrier, setter) {
if (setter === void 0) { setter = defaultTextMapSetter; }
return this._getGlobalPropagator().inject(context, carrier, setter);
};
/**
* Extract context from a carrier
*
* @param context Context which the newly created context will inherit from
* @param carrier Carrier to extract context from
* @param getter Function used to extract keys from a carrier
*/
PropagationAPI.prototype.extract = function (context, carrier, getter) {
if (getter === void 0) { getter = defaultTextMapGetter; }
return this._getGlobalPropagator().extract(context, carrier, getter);
};
/**
* Return a list of all fields which may be used by the propagator.
*/
PropagationAPI.prototype.fields = function () {
return this._getGlobalPropagator().fields();
};
/** Remove the global propagator */
PropagationAPI.prototype.disable = function () {
unregisterGlobal(API_NAME, DiagAPI.instance());
};
PropagationAPI.prototype._getGlobalPropagator = function () {
return getGlobal(API_NAME) || NOOP_TEXT_MAP_PROPAGATOR;
};
return PropagationAPI;
}());
export { PropagationAPI };
//# sourceMappingURL=propagation.js.map

View File

@@ -0,0 +1,5 @@
import { IImage } from './interface.mjs';
declare const WEBP: IImage;
export { WEBP };

View File

@@ -0,0 +1,4 @@
export { replayIntegration } from './integration';
export type { ReplayConfiguration, ReplayEventType, ReplayEventWithTime, ReplayBreadcrumbFrame, ReplayBreadcrumbFrameEvent, ReplayOptionFrameEvent, ReplayFrame, ReplayFrameEvent, ReplaySpanFrame, ReplaySpanFrameEvent, CanvasManagerInterface, CanvasManagerOptions, } from './types';
export { getReplay } from './util/getReplay';
//# sourceMappingURL=index.d.ts.map

View File

@@ -0,0 +1,252 @@
import { entityKind } from "../entity.js";
import { SelectionProxyHandler } from "../selection-proxy.js";
import { sql } from "../sql/sql.js";
import { WithSubquery } from "../subquery.js";
import { SingleStoreCountBuilder } from "./query-builders/count.js";
import {
QueryBuilder,
SingleStoreDeleteBase,
SingleStoreInsertBuilder,
SingleStoreSelectBuilder,
SingleStoreUpdateBuilder
} from "./query-builders/index.js";
class SingleStoreDatabase {
constructor(dialect, session, schema) {
this.dialect = dialect;
this.session = session;
this._ = schema ? {
schema: schema.schema,
fullSchema: schema.fullSchema,
tableNamesMap: schema.tableNamesMap
} : {
schema: void 0,
fullSchema: {},
tableNamesMap: {}
};
this.query = {};
this.$cache = { invalidate: async (_params) => {
} };
}
static [entityKind] = "SingleStoreDatabase";
// We are waiting for SingleStore support for `json_array` function
/**@inrernal */
query;
/**
* Creates a subquery that defines a temporary named result set as a CTE.
*
* It is useful for breaking down complex queries into simpler parts and for reusing the result set in subsequent parts of the query.
*
* See docs: {@link https://orm.drizzle.team/docs/select#with-clause}
*
* @param alias The alias for the subquery.
*
* Failure to provide an alias will result in a DrizzleTypeError, preventing the subquery from being referenced in other queries.
*
* @example
*
* ```ts
* // Create a subquery with alias 'sq' and use it in the select query
* const sq = db.$with('sq').as(db.select().from(users).where(eq(users.id, 42)));
*
* const result = await db.with(sq).select().from(sq);
* ```
*
* To select arbitrary SQL values as fields in a CTE and reference them in other CTEs or in the main query, you need to add aliases to them:
*
* ```ts
* // Select an arbitrary SQL value as a field in a CTE and reference it in the main query
* const sq = db.$with('sq').as(db.select({
* name: sql<string>`upper(${users.name})`.as('name'),
* })
* .from(users));
*
* const result = await db.with(sq).select({ name: sq.name }).from(sq);
* ```
*/
$with = (alias, selection) => {
const self = this;
const as = (qb) => {
if (typeof qb === "function") {
qb = qb(new QueryBuilder(self.dialect));
}
return new Proxy(
new WithSubquery(
qb.getSQL(),
selection ?? ("getSelectedFields" in qb ? qb.getSelectedFields() ?? {} : {}),
alias,
true
),
new SelectionProxyHandler({ alias, sqlAliasedBehavior: "alias", sqlBehavior: "error" })
);
};
return { as };
};
$count(source, filters) {
return new SingleStoreCountBuilder({ source, filters, session: this.session });
}
/**
* Incorporates a previously defined CTE (using `$with`) into the main query.
*
* This method allows the main query to reference a temporary named result set.
*
* See docs: {@link https://orm.drizzle.team/docs/select#with-clause}
*
* @param queries The CTEs to incorporate into the main query.
*
* @example
*
* ```ts
* // Define a subquery 'sq' as a CTE using $with
* const sq = db.$with('sq').as(db.select().from(users).where(eq(users.id, 42)));
*
* // Incorporate the CTE 'sq' into the main query and select from it
* const result = await db.with(sq).select().from(sq);
* ```
*/
with(...queries) {
const self = this;
function select(fields) {
return new SingleStoreSelectBuilder({
fields: fields ?? void 0,
session: self.session,
dialect: self.dialect,
withList: queries
});
}
function selectDistinct(fields) {
return new SingleStoreSelectBuilder({
fields: fields ?? void 0,
session: self.session,
dialect: self.dialect,
withList: queries,
distinct: true
});
}
function update(table) {
return new SingleStoreUpdateBuilder(table, self.session, self.dialect, queries);
}
function delete_(table) {
return new SingleStoreDeleteBase(table, self.session, self.dialect, queries);
}
return { select, selectDistinct, update, delete: delete_ };
}
select(fields) {
return new SingleStoreSelectBuilder({ fields: fields ?? void 0, session: this.session, dialect: this.dialect });
}
selectDistinct(fields) {
return new SingleStoreSelectBuilder({
fields: fields ?? void 0,
session: this.session,
dialect: this.dialect,
distinct: true
});
}
/**
* Creates an update query.
*
* Calling this method without `.where()` clause will update all rows in a table. The `.where()` clause specifies which rows should be updated.
*
* Use `.set()` method to specify which values to update.
*
* See docs: {@link https://orm.drizzle.team/docs/update}
*
* @param table The table to update.
*
* @example
*
* ```ts
* // Update all rows in the 'cars' table
* await db.update(cars).set({ color: 'red' });
*
* // Update rows with filters and conditions
* await db.update(cars).set({ color: 'red' }).where(eq(cars.brand, 'BMW'));
* ```
*/
update(table) {
return new SingleStoreUpdateBuilder(table, this.session, this.dialect);
}
/**
* Creates an insert query.
*
* Calling this method will create new rows in a table. Use `.values()` method to specify which values to insert.
*
* See docs: {@link https://orm.drizzle.team/docs/insert}
*
* @param table The table to insert into.
*
* @example
*
* ```ts
* // Insert one row
* await db.insert(cars).values({ brand: 'BMW' });
*
* // Insert multiple rows
* await db.insert(cars).values([{ brand: 'BMW' }, { brand: 'Porsche' }]);
* ```
*/
insert(table) {
return new SingleStoreInsertBuilder(table, this.session, this.dialect);
}
/**
* Creates a delete query.
*
* Calling this method without `.where()` clause will delete all rows in a table. The `.where()` clause specifies which rows should be deleted.
*
* See docs: {@link https://orm.drizzle.team/docs/delete}
*
* @param table The table to delete from.
*
* @example
*
* ```ts
* // Delete all rows in the 'cars' table
* await db.delete(cars);
*
* // Delete rows with filters and conditions
* await db.delete(cars).where(eq(cars.color, 'green'));
* ```
*/
delete(table) {
return new SingleStoreDeleteBase(table, this.session, this.dialect);
}
execute(query) {
return this.session.execute(typeof query === "string" ? sql.raw(query) : query.getSQL());
}
$cache;
transaction(transaction, config) {
return this.session.transaction(transaction, config);
}
}
const withReplicas = (primary, replicas, getReplica = () => replicas[Math.floor(Math.random() * replicas.length)]) => {
const select = (...args) => getReplica(replicas).select(...args);
const selectDistinct = (...args) => getReplica(replicas).selectDistinct(...args);
const $count = (...args) => getReplica(replicas).$count(...args);
const $with = (...args) => getReplica(replicas).with(...args);
const update = (...args) => primary.update(...args);
const insert = (...args) => primary.insert(...args);
const $delete = (...args) => primary.delete(...args);
const execute = (...args) => primary.execute(...args);
const transaction = (...args) => primary.transaction(...args);
return {
...primary,
update,
insert,
delete: $delete,
execute,
transaction,
$primary: primary,
$replicas: replicas,
select,
selectDistinct,
$count,
with: $with,
get query() {
return getReplica(replicas).query;
}
};
};
export {
SingleStoreDatabase,
withReplicas
};
//# sourceMappingURL=db.js.map

View File

@@ -0,0 +1,4 @@
function _non_iterable_spread() {
throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
}
export { _non_iterable_spread as _ };

View File

@@ -0,0 +1,15 @@
ISC License
Copyright (c) 2021-2024 Oleksii Raspopov, Kostiantyn Denysov, Anton Verinov
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted, provided that the above
copyright notice and this permission notice appear in all copies.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.

View File

@@ -0,0 +1,134 @@
import { buildMatchFn } from "../../_lib/buildMatchFn.mjs";
import { buildMatchPatternFn } from "../../_lib/buildMatchPatternFn.mjs";
const matchOrdinalNumberPattern = /^(\d+)[ºªo]?/i;
const parseOrdinalNumberPattern = /\d+/i;
const matchEraPatterns = {
narrow: /^(ac|dc|a|d)/i,
abbreviated: /^(a\.?\s?c\.?|d\.?\s?c\.?)/i,
wide: /^(antes de cristo|depois de cristo)/i,
};
const parseEraPatterns = {
any: [/^ac/i, /^dc/i],
wide: [/^antes de cristo/i, /^depois de cristo/i],
};
const matchQuarterPatterns = {
narrow: /^[1234]/i,
abbreviated: /^T[1234]/i,
wide: /^[1234](º)? trimestre/i,
};
const parseQuarterPatterns = {
any: [/1/i, /2/i, /3/i, /4/i],
};
const matchMonthPatterns = {
narrow: /^[jfmajsond]/i,
abbreviated: /^(jan|fev|mar|abr|mai|jun|jul|ago|set|out|nov|dez)/i,
wide: /^(janeiro|fevereiro|março|abril|maio|junho|julho|agosto|setembro|outubro|novembro|dezembro)/i,
};
const parseMonthPatterns = {
narrow: [
/^j/i,
/^f/i,
/^m/i,
/^a/i,
/^m/i,
/^j/i,
/^j/i,
/^a/i,
/^s/i,
/^o/i,
/^n/i,
/^d/i,
],
any: [
/^ja/i,
/^fev/i,
/^mar/i,
/^abr/i,
/^mai/i,
/^jun/i,
/^jul/i,
/^ago/i,
/^set/i,
/^out/i,
/^nov/i,
/^dez/i,
],
};
const matchDayPatterns = {
narrow: /^(dom|[23456]ª?|s[aá]b)/i,
short: /^(dom|[23456]ª?|s[aá]b)/i,
abbreviated: /^(dom|seg|ter|qua|qui|sex|s[aá]b)/i,
wide: /^(domingo|(segunda|ter[cç]a|quarta|quinta|sexta)([- ]feira)?|s[aá]bado)/i,
};
const parseDayPatterns = {
short: [/^d/i, /^2/i, /^3/i, /^4/i, /^5/i, /^6/i, /^s[aá]/i],
narrow: [/^d/i, /^2/i, /^3/i, /^4/i, /^5/i, /^6/i, /^s[aá]/i],
any: [/^d/i, /^seg/i, /^t/i, /^qua/i, /^qui/i, /^sex/i, /^s[aá]b/i],
};
const matchDayPeriodPatterns = {
narrow: /^(a|p|mn|md|(da) (manhã|tarde|noite))/i,
any: /^([ap]\.?\s?m\.?|meia[-\s]noite|meio[-\s]dia|(da) (manhã|tarde|noite))/i,
};
const parseDayPeriodPatterns = {
any: {
am: /^a/i,
pm: /^p/i,
midnight: /^mn|^meia[-\s]noite/i,
noon: /^md|^meio[-\s]dia/i,
morning: /manhã/i,
afternoon: /tarde/i,
evening: /tarde/i,
night: /noite/i,
},
};
export const match = {
ordinalNumber: buildMatchPatternFn({
matchPattern: matchOrdinalNumberPattern,
parsePattern: parseOrdinalNumberPattern,
valueCallback: (value) => parseInt(value, 10),
}),
era: buildMatchFn({
matchPatterns: matchEraPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseEraPatterns,
defaultParseWidth: "any",
}),
quarter: buildMatchFn({
matchPatterns: matchQuarterPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseQuarterPatterns,
defaultParseWidth: "any",
valueCallback: (index) => index + 1,
}),
month: buildMatchFn({
matchPatterns: matchMonthPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseMonthPatterns,
defaultParseWidth: "any",
}),
day: buildMatchFn({
matchPatterns: matchDayPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseDayPatterns,
defaultParseWidth: "any",
}),
dayPeriod: buildMatchFn({
matchPatterns: matchDayPeriodPatterns,
defaultMatchWidth: "any",
parsePatterns: parseDayPeriodPatterns,
defaultParseWidth: "any",
}),
};

View File

@@ -0,0 +1 @@
{"version":3,"file":"extra.d.ts","sourceRoot":"","sources":["../../../src/types-hoist/extra.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,KAAK,GAAG,OAAO,CAAC;AAC5B,MAAM,MAAM,MAAM,GAAG,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC"}

View File

@@ -0,0 +1,34 @@
Prism.languages.autoit = {
'comment': [
/;.*/,
{
// The multi-line comments delimiters can actually be commented out with ";"
pattern: /(^[\t ]*)#(?:comments-start|cs)[\s\S]*?^[ \t]*#(?:ce|comments-end)/m,
lookbehind: true
}
],
'url': {
pattern: /(^[\t ]*#include\s+)(?:<[^\r\n>]+>|"[^\r\n"]+")/m,
lookbehind: true
},
'string': {
pattern: /(["'])(?:\1\1|(?!\1)[^\r\n])*\1/,
greedy: true,
inside: {
'variable': /([%$@])\w+\1/
}
},
'directive': {
pattern: /(^[\t ]*)#[\w-]+/m,
lookbehind: true,
alias: 'keyword'
},
'function': /\b\w+(?=\()/,
// Variables and macros
'variable': /[$@]\w+/,
'keyword': /\b(?:Case|Const|Continue(?:Case|Loop)|Default|Dim|Do|Else(?:If)?|End(?:Func|If|Select|Switch|With)|Enum|Exit(?:Loop)?|For|Func|Global|If|In|Local|Next|Null|ReDim|Select|Static|Step|Switch|Then|To|Until|Volatile|WEnd|While|With)\b/i,
'number': /\b(?:0x[\da-f]+|\d+(?:\.\d+)?(?:e[+-]?\d+)?)\b/i,
'boolean': /\b(?:False|True)\b/i,
'operator': /<[=>]?|[-+*\/=&>]=?|[?^]|\b(?:And|Not|Or)\b/i,
'punctuation': /[\[\]().,:]/
};

View File

@@ -0,0 +1 @@
Prism.languages.sql={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,lookbehind:!0},variable:[{pattern:/@(["'`])(?:\\[\s\S]|(?!\1)[^\\])+\1/,greedy:!0},/@[\w.$]+/],string:{pattern:/(^|[^@\\])("|')(?:\\[\s\S]|(?!\2)[^\\]|\2\2)*\2/,greedy:!0,lookbehind:!0},identifier:{pattern:/(^|[^@\\])`(?:\\[\s\S]|[^`\\]|``)*`/,greedy:!0,lookbehind:!0,inside:{punctuation:/^`|`$/}},function:/\b(?:AVG|COUNT|FIRST|FORMAT|LAST|LCASE|LEN|MAX|MID|MIN|MOD|NOW|ROUND|SUM|UCASE)(?=\s*\()/i,keyword:/\b(?:ACTION|ADD|AFTER|ALGORITHM|ALL|ALTER|ANALYZE|ANY|APPLY|AS|ASC|AUTHORIZATION|AUTO_INCREMENT|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADED?|CASE|CHAIN|CHAR(?:ACTER|SET)?|CHECK(?:POINT)?|CLOSE|CLUSTERED|COALESCE|COLLATE|COLUMNS?|COMMENT|COMMIT(?:TED)?|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS(?:TABLE)?|CONTINUE|CONVERT|CREATE|CROSS|CURRENT(?:_DATE|_TIME|_TIMESTAMP|_USER)?|CURSOR|CYCLE|DATA(?:BASES?)?|DATE(?:TIME)?|DAY|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DELIMITERS?|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DROP|DUMMY|DUMP(?:FILE)?|DUPLICATE|ELSE(?:IF)?|ENABLE|ENCLOSED|END|ENGINE|ENUM|ERRLVL|ERRORS|ESCAPED?|EXCEPT|EXEC(?:UTE)?|EXISTS|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR(?: EACH ROW)?|FORCE|FOREIGN|FREETEXT(?:TABLE)?|FROM|FULL|FUNCTION|GEOMETRY(?:COLLECTION)?|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|HOUR|IDENTITY(?:COL|_INSERT)?|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTERVAL|INTO|INVOKER|ISOLATION|ITERATE|JOIN|KEYS?|KILL|LANGUAGE|LAST|LEAVE|LEFT|LEVEL|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONG(?:BLOB|TEXT)|LOOP|MATCH(?:ED)?|MEDIUM(?:BLOB|INT|TEXT)|MERGE|MIDDLEINT|MINUTE|MODE|MODIFIES|MODIFY|MONTH|MULTI(?:LINESTRING|POINT|POLYGON)|NATIONAL|NATURAL|NCHAR|NEXT|NO|NONCLUSTERED|NULLIF|NUMERIC|OFF?|OFFSETS?|ON|OPEN(?:DATASOURCE|QUERY|ROWSET)?|OPTIMIZE|OPTION(?:ALLY)?|ORDER|OUT(?:ER|FILE)?|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREPARE|PREV|PRIMARY|PRINT|PRIVILEGES|PROC(?:EDURE)?|PUBLIC|PURGE|QUICK|RAISERROR|READS?|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEAT(?:ABLE)?|REPLACE|REPLICATION|REQUIRE|RESIGNAL|RESTORE|RESTRICT|RETURN(?:ING|S)?|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROW(?:COUNT|GUIDCOL|S)?|RTREE|RULE|SAVE(?:POINT)?|SCHEMA|SECOND|SELECT|SERIAL(?:IZABLE)?|SESSION(?:_USER)?|SET(?:USER)?|SHARE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|SQL|START(?:ING)?|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLES?|TABLESPACE|TEMP(?:ORARY|TABLE)?|TERMINATED|TEXT(?:SIZE)?|THEN|TIME(?:STAMP)?|TINY(?:BLOB|INT|TEXT)|TOP?|TRAN(?:SACTIONS?)?|TRIGGER|TRUNCATE|TSEQUAL|TYPES?|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNIQUE|UNLOCK|UNPIVOT|UNSIGNED|UPDATE(?:TEXT)?|USAGE|USE|USER|USING|VALUES?|VAR(?:BINARY|CHAR|CHARACTER|YING)|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH(?: ROLLUP|IN)?|WORK|WRITE(?:TEXT)?|YEAR)\b/i,boolean:/\b(?:FALSE|NULL|TRUE)\b/i,number:/\b0x[\da-f]+\b|\b\d+(?:\.\d*)?|\B\.\d+\b/i,operator:/[-+*\/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,punctuation:/[;[\]()`,.]/};

View File

@@ -0,0 +1 @@
{"version":3,"file":"scopeData.d.ts","sourceRoot":"","sources":["../../../src/utils/scopeData.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,KAAK,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAGjD,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,sBAAsB,CAAC;AAKlD;;GAEG;AACH,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,KAAK,EAAE,IAAI,EAAE,SAAS,GAAG,IAAI,CAgBzE;AAED,yCAAyC;AACzC,wBAAgB,cAAc,CAAC,IAAI,EAAE,SAAS,EAAE,SAAS,EAAE,SAAS,GAAG,IAAI,CAuD1E;AAED;;;GAGG;AACH,wBAAgB,0BAA0B,CACxC,IAAI,SAAS,OAAO,GAAG,MAAM,GAAG,YAAY,GAAG,MAAM,GAAG,UAAU,GAAG,uBAAuB,EAC5F,IAAI,SAAS,SAAS,EACtB,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,CAAC,IAAI,CAAC,GAAG,IAAI,CAEpD;AAED,8BAA8B;AAC9B,wBAAgB,UAAU,CAAC,IAAI,SAAS,aAAa,GAAG,aAAa,EACnE,KAAK,EAAE,KAAK,EACZ,IAAI,EAAE,IAAI,EACV,QAAQ,EAAE,SAAS,CAAC,IAAI,CAAC,GACxB,IAAI,CAUN;AAED;;;;;;GAMG;AACH,wBAAgB,oBAAoB,CAAC,cAAc,EAAE,KAAK,GAAG,SAAS,EAAE,YAAY,EAAE,KAAK,GAAG,SAAS,GAAG,SAAS,CAKlH"}

View File

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

View File

@@ -0,0 +1,16 @@
/**
* 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.
*
*/
const mod = await (process.env.NODE_ENV !== 'production' ? import('./LexicalText.dev.mjs') : import('./LexicalText.prod.mjs'));
export const $canShowPlaceholder = mod.$canShowPlaceholder;
export const $canShowPlaceholderCurry = mod.$canShowPlaceholderCurry;
export const $findTextIntersectionFromCharacters = mod.$findTextIntersectionFromCharacters;
export const $isRootTextContentEmpty = mod.$isRootTextContentEmpty;
export const $isRootTextContentEmptyCurry = mod.$isRootTextContentEmptyCurry;
export const $rootTextContent = mod.$rootTextContent;
export const registerLexicalTextEntity = mod.registerLexicalTextEntity;

View File

@@ -0,0 +1,11 @@
const formatRelativeLocale = {
lastWeek: "'هەفتەی ڕابردوو' eeee 'کاتژمێر' p",
yesterday: "'دوێنێ کاتژمێر' p",
today: "'ئەمڕۆ کاتژمێر' p",
tomorrow: "'بەیانی کاتژمێر' p",
nextWeek: "eeee 'کاتژمێر' p",
other: "P",
};
export const formatRelative = (token, _date, _baseDate, _options) =>
formatRelativeLocale[token];

View File

@@ -0,0 +1,483 @@
function _typeof(o) {"@babel/helpers - typeof";return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {return typeof o;} : function (o) {return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;}, _typeof(o);}function ownKeys(e, r) {var t = Object.keys(e);if (Object.getOwnPropertySymbols) {var o = Object.getOwnPropertySymbols(e);r && (o = o.filter(function (r) {return Object.getOwnPropertyDescriptor(e, r).enumerable;})), t.push.apply(t, o);}return t;}function _objectSpread(e) {for (var r = 1; r < arguments.length; r++) {var t = null != arguments[r] ? arguments[r] : {};r % 2 ? ownKeys(Object(t), !0).forEach(function (r) {_defineProperty(e, r, t[r]);}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) {Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));});}return e;}function _defineProperty(obj, key, value) {key = _toPropertyKey(key);if (key in obj) {Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true });} else {obj[key] = value;}return obj;}function _toPropertyKey(t) {var i = _toPrimitive(t, "string");return "symbol" == _typeof(i) ? i : String(i);}function _toPrimitive(t, r) {if ("object" != _typeof(t) || !t) return t;var e = t[Symbol.toPrimitive];if (void 0 !== e) {var i = e.call(t, r || "default");if ("object" != _typeof(i)) return i;throw new TypeError("@@toPrimitive must return a primitive value.");}return ("string" === r ? String : Number)(t);}(function (_window$dateFns) {var __defProp = Object.defineProperty;
var __export = function __export(target, all) {
for (var name in all)
__defProp(target, name, {
get: all[name],
enumerable: true,
configurable: true,
set: function set(newValue) {return all[name] = function () {return newValue;};}
});
};
// lib/locale/nl/_lib/formatDistance.mjs
var formatDistanceLocale = {
lessThanXSeconds: {
one: "minder dan een seconde",
other: "minder dan {{count}} seconden"
},
xSeconds: {
one: "1 seconde",
other: "{{count}} seconden"
},
halfAMinute: "een halve minuut",
lessThanXMinutes: {
one: "minder dan een minuut",
other: "minder dan {{count}} minuten"
},
xMinutes: {
one: "een minuut",
other: "{{count}} minuten"
},
aboutXHours: {
one: "ongeveer 1 uur",
other: "ongeveer {{count}} uur"
},
xHours: {
one: "1 uur",
other: "{{count}} uur"
},
xDays: {
one: "1 dag",
other: "{{count}} dagen"
},
aboutXWeeks: {
one: "ongeveer 1 week",
other: "ongeveer {{count}} weken"
},
xWeeks: {
one: "1 week",
other: "{{count}} weken"
},
aboutXMonths: {
one: "ongeveer 1 maand",
other: "ongeveer {{count}} maanden"
},
xMonths: {
one: "1 maand",
other: "{{count}} maanden"
},
aboutXYears: {
one: "ongeveer 1 jaar",
other: "ongeveer {{count}} jaar"
},
xYears: {
one: "1 jaar",
other: "{{count}} jaar"
},
overXYears: {
one: "meer dan 1 jaar",
other: "meer dan {{count}} jaar"
},
almostXYears: {
one: "bijna 1 jaar",
other: "bijna {{count}} jaar"
}
};
var formatDistance = function formatDistance(token, count, options) {
var result;
var tokenValue = formatDistanceLocale[token];
if (typeof tokenValue === "string") {
result = tokenValue;
} else if (count === 1) {
result = tokenValue.one;
} else {
result = tokenValue.other.replace("{{count}}", String(count));
}
if (options !== null && options !== void 0 && options.addSuffix) {
if (options.comparison && options.comparison > 0) {
return "over " + result;
} else {
return result + " geleden";
}
}
return result;
};
// lib/locale/_lib/buildFormatLongFn.mjs
function buildFormatLongFn(args) {
return function () {var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
var width = options.width ? String(options.width) : args.defaultWidth;
var format = args.formats[width] || args.formats[args.defaultWidth];
return format;
};
}
// lib/locale/nl/_lib/formatLong.mjs
var dateFormats = {
full: "EEEE d MMMM y",
long: "d MMMM y",
medium: "d MMM y",
short: "dd-MM-y"
};
var timeFormats = {
full: "HH:mm:ss zzzz",
long: "HH:mm:ss z",
medium: "HH:mm:ss",
short: "HH:mm"
};
var dateTimeFormats = {
full: "{{date}} 'om' {{time}}",
long: "{{date}} 'om' {{time}}",
medium: "{{date}}, {{time}}",
short: "{{date}}, {{time}}"
};
var formatLong = {
date: buildFormatLongFn({
formats: dateFormats,
defaultWidth: "full"
}),
time: buildFormatLongFn({
formats: timeFormats,
defaultWidth: "full"
}),
dateTime: buildFormatLongFn({
formats: dateTimeFormats,
defaultWidth: "full"
})
};
// lib/locale/nl/_lib/formatRelative.mjs
var formatRelativeLocale = {
lastWeek: "'afgelopen' eeee 'om' p",
yesterday: "'gisteren om' p",
today: "'vandaag om' p",
tomorrow: "'morgen om' p",
nextWeek: "eeee 'om' p",
other: "P"
};
var formatRelative = function formatRelative(token, _date, _baseDate, _options) {return formatRelativeLocale[token];};
// lib/locale/_lib/buildLocalizeFn.mjs
function buildLocalizeFn(args) {
return function (value, options) {
var context = options !== null && options !== void 0 && options.context ? String(options.context) : "standalone";
var valuesArray;
if (context === "formatting" && args.formattingValues) {
var defaultWidth = args.defaultFormattingWidth || args.defaultWidth;
var width = options !== null && options !== void 0 && options.width ? String(options.width) : defaultWidth;
valuesArray = args.formattingValues[width] || args.formattingValues[defaultWidth];
} else {
var _defaultWidth = args.defaultWidth;
var _width = options !== null && options !== void 0 && options.width ? String(options.width) : args.defaultWidth;
valuesArray = args.values[_width] || args.values[_defaultWidth];
}
var index = args.argumentCallback ? args.argumentCallback(value) : value;
return valuesArray[index];
};
}
// lib/locale/nl/_lib/localize.mjs
var eraValues = {
narrow: ["v.C.", "n.C."],
abbreviated: ["v.Chr.", "n.Chr."],
wide: ["voor Christus", "na Christus"]
};
var quarterValues = {
narrow: ["1", "2", "3", "4"],
abbreviated: ["K1", "K2", "K3", "K4"],
wide: ["1e kwartaal", "2e kwartaal", "3e kwartaal", "4e kwartaal"]
};
var monthValues = {
narrow: ["J", "F", "M", "A", "M", "J", "J", "A", "S", "O", "N", "D"],
abbreviated: [
"jan.",
"feb.",
"mrt.",
"apr.",
"mei",
"jun.",
"jul.",
"aug.",
"sep.",
"okt.",
"nov.",
"dec."],
wide: [
"januari",
"februari",
"maart",
"april",
"mei",
"juni",
"juli",
"augustus",
"september",
"oktober",
"november",
"december"]
};
var dayValues = {
narrow: ["Z", "M", "D", "W", "D", "V", "Z"],
short: ["zo", "ma", "di", "wo", "do", "vr", "za"],
abbreviated: ["zon", "maa", "din", "woe", "don", "vri", "zat"],
wide: [
"zondag",
"maandag",
"dinsdag",
"woensdag",
"donderdag",
"vrijdag",
"zaterdag"]
};
var dayPeriodValues = {
narrow: {
am: "AM",
pm: "PM",
midnight: "middernacht",
noon: "het middaguur",
morning: "'s ochtends",
afternoon: "'s middags",
evening: "'s avonds",
night: "'s nachts"
},
abbreviated: {
am: "AM",
pm: "PM",
midnight: "middernacht",
noon: "het middaguur",
morning: "'s ochtends",
afternoon: "'s middags",
evening: "'s avonds",
night: "'s nachts"
},
wide: {
am: "AM",
pm: "PM",
midnight: "middernacht",
noon: "het middaguur",
morning: "'s ochtends",
afternoon: "'s middags",
evening: "'s avonds",
night: "'s nachts"
}
};
var ordinalNumber = function ordinalNumber(dirtyNumber, _options) {
var number = Number(dirtyNumber);
return number + "e";
};
var localize = {
ordinalNumber: ordinalNumber,
era: buildLocalizeFn({
values: eraValues,
defaultWidth: "wide"
}),
quarter: buildLocalizeFn({
values: quarterValues,
defaultWidth: "wide",
argumentCallback: function argumentCallback(quarter) {return quarter - 1;}
}),
month: buildLocalizeFn({
values: monthValues,
defaultWidth: "wide"
}),
day: buildLocalizeFn({
values: dayValues,
defaultWidth: "wide"
}),
dayPeriod: buildLocalizeFn({
values: dayPeriodValues,
defaultWidth: "wide"
})
};
// lib/locale/_lib/buildMatchFn.mjs
function buildMatchFn(args) {
return function (string) {var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
var width = options.width;
var matchPattern = width && args.matchPatterns[width] || args.matchPatterns[args.defaultMatchWidth];
var matchResult = string.match(matchPattern);
if (!matchResult) {
return null;
}
var matchedString = matchResult[0];
var parsePatterns = width && args.parsePatterns[width] || args.parsePatterns[args.defaultParseWidth];
var key = Array.isArray(parsePatterns) ? findIndex(parsePatterns, function (pattern) {return pattern.test(matchedString);}) : findKey(parsePatterns, function (pattern) {return pattern.test(matchedString);});
var value;
value = args.valueCallback ? args.valueCallback(key) : key;
value = options.valueCallback ? options.valueCallback(value) : value;
var rest = string.slice(matchedString.length);
return { value: value, rest: rest };
};
}
var findKey = function findKey(object, predicate) {
for (var key in object) {
if (Object.prototype.hasOwnProperty.call(object, key) && predicate(object[key])) {
return key;
}
}
return;
};
var findIndex = function findIndex(array, predicate) {
for (var key = 0; key < array.length; key++) {
if (predicate(array[key])) {
return key;
}
}
return;
};
// lib/locale/_lib/buildMatchPatternFn.mjs
function buildMatchPatternFn(args) {
return function (string) {var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
var matchResult = string.match(args.matchPattern);
if (!matchResult)
return null;
var matchedString = matchResult[0];
var parseResult = string.match(args.parsePattern);
if (!parseResult)
return null;
var value = args.valueCallback ? args.valueCallback(parseResult[0]) : parseResult[0];
value = options.valueCallback ? options.valueCallback(value) : value;
var rest = string.slice(matchedString.length);
return { value: value, rest: rest };
};
}
// lib/locale/nl/_lib/match.mjs
var matchOrdinalNumberPattern = /^(\d+)e?/i;
var parseOrdinalNumberPattern = /\d+/i;
var matchEraPatterns = {
narrow: /^([vn]\.? ?C\.?)/,
abbreviated: /^([vn]\. ?Chr\.?)/,
wide: /^((voor|na) Christus)/
};
var parseEraPatterns = {
any: [/^v/, /^n/]
};
var matchQuarterPatterns = {
narrow: /^[1234]/i,
abbreviated: /^K[1234]/i,
wide: /^[1234]e kwartaal/i
};
var parseQuarterPatterns = {
any: [/1/i, /2/i, /3/i, /4/i]
};
var matchMonthPatterns = {
narrow: /^[jfmasond]/i,
abbreviated: /^(jan.|feb.|mrt.|apr.|mei|jun.|jul.|aug.|sep.|okt.|nov.|dec.)/i,
wide: /^(januari|februari|maart|april|mei|juni|juli|augustus|september|oktober|november|december)/i
};
var parseMonthPatterns = {
narrow: [
/^j/i,
/^f/i,
/^m/i,
/^a/i,
/^m/i,
/^j/i,
/^j/i,
/^a/i,
/^s/i,
/^o/i,
/^n/i,
/^d/i],
any: [
/^jan/i,
/^feb/i,
/^m(r|a)/i,
/^apr/i,
/^mei/i,
/^jun/i,
/^jul/i,
/^aug/i,
/^sep/i,
/^okt/i,
/^nov/i,
/^dec/i]
};
var matchDayPatterns = {
narrow: /^[zmdwv]/i,
short: /^(zo|ma|di|wo|do|vr|za)/i,
abbreviated: /^(zon|maa|din|woe|don|vri|zat)/i,
wide: /^(zondag|maandag|dinsdag|woensdag|donderdag|vrijdag|zaterdag)/i
};
var parseDayPatterns = {
narrow: [/^z/i, /^m/i, /^d/i, /^w/i, /^d/i, /^v/i, /^z/i],
any: [/^zo/i, /^ma/i, /^di/i, /^wo/i, /^do/i, /^vr/i, /^za/i]
};
var matchDayPeriodPatterns = {
any: /^(am|pm|middernacht|het middaguur|'s (ochtends|middags|avonds|nachts))/i
};
var parseDayPeriodPatterns = {
any: {
am: /^am/i,
pm: /^pm/i,
midnight: /^middernacht/i,
noon: /^het middaguur/i,
morning: /ochtend/i,
afternoon: /middag/i,
evening: /avond/i,
night: /nacht/i
}
};
var match = {
ordinalNumber: buildMatchPatternFn({
matchPattern: matchOrdinalNumberPattern,
parsePattern: parseOrdinalNumberPattern,
valueCallback: function valueCallback(value) {return parseInt(value, 10);}
}),
era: buildMatchFn({
matchPatterns: matchEraPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseEraPatterns,
defaultParseWidth: "any"
}),
quarter: buildMatchFn({
matchPatterns: matchQuarterPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseQuarterPatterns,
defaultParseWidth: "any",
valueCallback: function valueCallback(index) {return index + 1;}
}),
month: buildMatchFn({
matchPatterns: matchMonthPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseMonthPatterns,
defaultParseWidth: "any"
}),
day: buildMatchFn({
matchPatterns: matchDayPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseDayPatterns,
defaultParseWidth: "any"
}),
dayPeriod: buildMatchFn({
matchPatterns: matchDayPeriodPatterns,
defaultMatchWidth: "any",
parsePatterns: parseDayPeriodPatterns,
defaultParseWidth: "any"
})
};
// lib/locale/nl.mjs
var nl = {
code: "nl",
formatDistance: formatDistance,
formatLong: formatLong,
formatRelative: formatRelative,
localize: localize,
match: match,
options: {
weekStartsOn: 1,
firstWeekContainsDate: 4
}
};
// lib/locale/nl/cdn.js
window.dateFns = _objectSpread(_objectSpread({},
window.dateFns), {}, {
locale: _objectSpread(_objectSpread({}, (_window$dateFns =
window.dateFns) === null || _window$dateFns === void 0 ? void 0 : _window$dateFns.locale), {}, {
nl: nl }) });
//# debugId=2C62968F3036508F64756e2164756e21
})();
//# sourceMappingURL=cdn.js.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"font-metrics.js","sourceRoot":"","sources":["../../../src/render/font-metrics.ts"],"names":[],"mappings":";;;AAAA,qCAAyC;AAMzC,IAAM,WAAW,GAAG,aAAa,CAAC;AAElC;IAII,qBAAY,QAAkB;QAC1B,IAAI,CAAC,KAAK,GAAG,EAAE,CAAC;QAChB,IAAI,CAAC,SAAS,GAAG,QAAQ,CAAC;IAC9B,CAAC;IAEO,kCAAY,GAApB,UAAqB,UAAkB,EAAE,QAAgB;QACrD,IAAM,SAAS,GAAG,IAAI,CAAC,SAAS,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;QACtD,IAAM,GAAG,GAAG,IAAI,CAAC,SAAS,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;QAChD,IAAM,IAAI,GAAG,IAAI,CAAC,SAAS,CAAC,aAAa,CAAC,MAAM,CAAC,CAAC;QAElD,IAAM,IAAI,GAAG,IAAI,CAAC,SAAS,CAAC,IAAuB,CAAC;QAEpD,SAAS,CAAC,KAAK,CAAC,UAAU,GAAG,QAAQ,CAAC;QACtC,SAAS,CAAC,KAAK,CAAC,UAAU,GAAG,UAAU,CAAC;QACxC,SAAS,CAAC,KAAK,CAAC,QAAQ,GAAG,QAAQ,CAAC;QACpC,SAAS,CAAC,KAAK,CAAC,MAAM,GAAG,GAAG,CAAC;QAC7B,SAAS,CAAC,KAAK,CAAC,OAAO,GAAG,GAAG,CAAC;QAC9B,SAAS,CAAC,KAAK,CAAC,UAAU,GAAG,QAAQ,CAAC;QAEtC,IAAI,CAAC,WAAW,CAAC,SAAS,CAAC,CAAC;QAE5B,GAAG,CAAC,GAAG,GAAG,kBAAW,CAAC;QACtB,GAAG,CAAC,KAAK,GAAG,CAAC,CAAC;QACd,GAAG,CAAC,MAAM,GAAG,CAAC,CAAC;QAEf,GAAG,CAAC,KAAK,CAAC,MAAM,GAAG,GAAG,CAAC;QACvB,GAAG,CAAC,KAAK,CAAC,OAAO,GAAG,GAAG,CAAC;QACxB,GAAG,CAAC,KAAK,CAAC,aAAa,GAAG,UAAU,CAAC;QAErC,IAAI,CAAC,KAAK,CAAC,UAAU,GAAG,UAAU,CAAC;QACnC,IAAI,CAAC,KAAK,CAAC,QAAQ,GAAG,QAAQ,CAAC;QAC/B,IAAI,CAAC,KAAK,CAAC,MAAM,GAAG,GAAG,CAAC;QACxB,IAAI,CAAC,KAAK,CAAC,OAAO,GAAG,GAAG,CAAC;QAEzB,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,SAAS,CAAC,cAAc,CAAC,WAAW,CAAC,CAAC,CAAC;QAC7D,SAAS,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;QAC5B,SAAS,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC;QAC3B,IAAM,QAAQ,GAAG,GAAG,CAAC,SAAS,GAAG,IAAI,CAAC,SAAS,GAAG,CAAC,CAAC;QAEpD,SAAS,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;QAC5B,SAAS,CAAC,WAAW,CAAC,IAAI,CAAC,SAAS,CAAC,cAAc,CAAC,WAAW,CAAC,CAAC,CAAC;QAElE,SAAS,CAAC,KAAK,CAAC,UAAU,GAAG,QAAQ,CAAC;QACtC,GAAG,CAAC,KAAK,CAAC,aAAa,GAAG,OAAO,CAAC;QAElC,IAAM,MAAM,GAAG,GAAG,CAAC,SAAS,GAAG,SAAS,CAAC,SAAS,GAAG,CAAC,CAAC;QAEvD,IAAI,CAAC,WAAW,CAAC,SAAS,CAAC,CAAC;QAE5B,OAAO,EAAC,QAAQ,UAAA,EAAE,MAAM,QAAA,EAAC,CAAC;IAC9B,CAAC;IACD,gCAAU,GAAV,UAAW,UAAkB,EAAE,QAAgB;QAC3C,IAAM,GAAG,GAAM,UAAU,SAAI,QAAU,CAAC;QACxC,IAAI,OAAO,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,KAAK,WAAW,EAAE;YACxC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,IAAI,CAAC,YAAY,CAAC,UAAU,EAAE,QAAQ,CAAC,CAAC;SAC7D;QAED,OAAO,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IAC3B,CAAC;IACL,kBAAC;AAAD,CAAC,AA/DD,IA+DC;AA/DY,kCAAW"}

View File

@@ -0,0 +1,65 @@
import { isCSSVariableName } from '../../dom/utils/is-css-variable.mjs';
import { getValueAsType } from '../../dom/value-types/get-as-type.mjs';
import { numberValueTypes } from '../../dom/value-types/number.mjs';
import { buildTransform } from './build-transform.mjs';
import { transformProps } from './keys-transform.mjs';
function buildHTMLStyles(state, latestValues, transformTemplate) {
const { style, vars, transformOrigin } = state;
// Track whether we encounter any transform or transformOrigin values.
let hasTransform = false;
let hasTransformOrigin = false;
/**
* Loop over all our latest animated values and decide whether to handle them
* as a style or CSS variable.
*
* Transforms and transform origins are kept separately for further processing.
*/
for (const key in latestValues) {
const value = latestValues[key];
if (transformProps.has(key)) {
// If this is a transform, flag to enable further transform processing
hasTransform = true;
continue;
}
else if (isCSSVariableName(key)) {
vars[key] = value;
continue;
}
else {
// Convert the value to its default value type, ie 0 -> "0px"
const valueAsType = getValueAsType(value, numberValueTypes[key]);
if (key.startsWith("origin")) {
// If this is a transform origin, flag and enable further transform-origin processing
hasTransformOrigin = true;
transformOrigin[key] =
valueAsType;
}
else {
style[key] = valueAsType;
}
}
}
if (!latestValues.transform) {
if (hasTransform || transformTemplate) {
style.transform = buildTransform(latestValues, state.transform, transformTemplate);
}
else if (style.transform) {
/**
* If we have previously created a transform but currently don't have any,
* reset transform style to none.
*/
style.transform = "none";
}
}
/**
* Build a transformOrigin style. Uses the same defaults as the browser for
* undefined origins.
*/
if (hasTransformOrigin) {
const { originX = "50%", originY = "50%", originZ = 0, } = transformOrigin;
style.transformOrigin = `${originX} ${originY} ${originZ}`;
}
}
export { buildHTMLStyles };

View File

@@ -0,0 +1 @@
{"version":3,"sources":["../../../src/admin/fields/UI.ts"],"sourcesContent":["import type { MarkOptional } from 'ts-essentials'\n\nimport type { UIField, UIFieldClient } from '../../fields/config/types.js'\nimport type {\n ClientFieldBase,\n FieldClientComponent,\n FieldDiffClientComponent,\n FieldDiffServerComponent,\n FieldPaths,\n FieldServerComponent,\n ServerFieldBase,\n} from '../types.js'\n\ntype UIFieldClientWithoutType = MarkOptional<UIFieldClient, 'type'>\n\ntype UIFieldBaseClientProps = {\n readonly path: string\n}\n\ntype UIFieldBaseServerProps = Pick<FieldPaths, 'path'>\n\nexport type UIFieldClientProps = ClientFieldBase<UIFieldClientWithoutType> & UIFieldBaseClientProps\n\nexport type UIFieldServerProps = ServerFieldBase<UIField, UIFieldClientWithoutType> &\n UIFieldBaseServerProps\n\nexport type UIFieldClientComponent = FieldClientComponent<\n UIFieldClientWithoutType,\n UIFieldBaseClientProps\n>\n\nexport type UIFieldServerComponent = FieldServerComponent<\n UIField,\n UIFieldClientWithoutType,\n UIFieldBaseServerProps\n>\n\nexport type UIFieldDiffServerComponent = FieldDiffServerComponent<UIField, UIFieldClient>\n\nexport type UIFieldDiffClientComponent = FieldDiffClientComponent<UIFieldClient>\n"],"names":[],"mappings":"AAuCA,WAAgF"}

View File

@@ -0,0 +1,53 @@
import { ElementPaint, StackingContext } from '../stacking-context';
import { Color } from '../../css/types/color';
import { ElementContainer } from '../../dom/element-container';
import { BORDER_STYLE } from '../../css/property-descriptors/border-style';
import { CSSParsedDeclaration } from '../../css';
import { TextContainer } from '../../dom/text-container';
import { Path } from '../path';
import { BoundCurves } from '../bound-curves';
import { TextBounds } from '../../css/layout/text';
import { ReplacedElementContainer } from '../../dom/replaced-elements';
import { IElementEffect } from '../effects';
import { Renderer } from '../renderer';
import { Context } from '../../core/context';
export declare type RenderConfigurations = RenderOptions & {
backgroundColor: Color | null;
};
export interface RenderOptions {
scale: number;
canvas?: HTMLCanvasElement;
x: number;
y: number;
width: number;
height: number;
}
export declare class CanvasRenderer extends Renderer {
canvas: HTMLCanvasElement;
ctx: CanvasRenderingContext2D;
private readonly _activeEffects;
private readonly fontMetrics;
constructor(context: Context, options: RenderConfigurations);
applyEffects(effects: IElementEffect[]): void;
applyEffect(effect: IElementEffect): void;
popEffect(): void;
renderStack(stack: StackingContext): Promise<void>;
renderNode(paint: ElementPaint): Promise<void>;
renderTextWithLetterSpacing(text: TextBounds, letterSpacing: number, baseline: number): void;
private createFontStyle;
renderTextNode(text: TextContainer, styles: CSSParsedDeclaration): Promise<void>;
renderReplacedElement(container: ReplacedElementContainer, curves: BoundCurves, image: HTMLImageElement | HTMLCanvasElement): void;
renderNodeContent(paint: ElementPaint): Promise<void>;
renderStackContent(stack: StackingContext): Promise<void>;
mask(paths: Path[]): void;
path(paths: Path[]): void;
formatPath(paths: Path[]): void;
renderRepeat(path: Path[], pattern: CanvasPattern | CanvasGradient, offsetX: number, offsetY: number): void;
resizeImage(image: HTMLImageElement, width: number, height: number): HTMLCanvasElement | HTMLImageElement;
renderBackgroundImage(container: ElementContainer): Promise<void>;
renderSolidBorder(color: Color, side: number, curvePoints: BoundCurves): Promise<void>;
renderDoubleBorder(color: Color, width: number, side: number, curvePoints: BoundCurves): Promise<void>;
renderNodeBackgroundAndBorders(paint: ElementPaint): Promise<void>;
renderDashedDottedBorder(color: Color, width: number, side: number, curvePoints: BoundCurves, style: BORDER_STYLE): Promise<void>;
render(element: ElementContainer): Promise<HTMLCanvasElement>;
}

View File

@@ -0,0 +1 @@
{"version":3,"file":"react-select-base.cjs.d.ts","sourceRoot":"","sources":["../../dist/declarations/src/base/index.d.ts"],"names":[],"mappings":"AAAA"}

View File

@@ -0,0 +1,84 @@
(function (Prism) {
// https://cuelang.org/docs/references/spec/
// eslint-disable-next-line regexp/strict
var stringEscape = /\\(?:(?!\2)|\2(?:[^()\r\n]|\([^()]*\)))/.source;
// eslint-disable-next-line regexp/strict
var stringTypes = /"""(?:[^\\"]|"(?!""\2)|<esc>)*"""/.source +
// eslint-disable-next-line regexp/strict
'|' + /'''(?:[^\\']|'(?!''\2)|<esc>)*'''/.source +
// eslint-disable-next-line regexp/strict
'|' + /"(?:[^\\\r\n"]|"(?!\2)|<esc>)*"/.source +
// eslint-disable-next-line regexp/strict
'|' + /'(?:[^\\\r\n']|'(?!\2)|<esc>)*'/.source;
var stringLiteral = '(?:' + stringTypes.replace(/<esc>/g, stringEscape) + ')';
Prism.languages.cue = {
'comment': {
pattern: /\/\/.*/,
greedy: true
},
'string-literal': {
// eslint-disable-next-line regexp/strict
pattern: RegExp(/(^|[^#"'\\])(#*)/.source + stringLiteral + /(?!["'])\2/.source),
lookbehind: true,
greedy: true,
inside: {
// I'm using dirty hack here. We have to know the number hashes at the start of the string somehow,
// but we can't look back. So instead, we will use a lookahead, go to the end of the string, and
// capture the hashes at the end of the string.
'escape': {
pattern: /(?=[\s\S]*["'](#*)$)\\\1(?:U[a-fA-F0-9]{1,8}|u[a-fA-F0-9]{1,4}|x[a-fA-F0-9]{1,2}|\d{2,3}|[^(])/,
greedy: true,
alias: 'string'
},
'interpolation': {
pattern: /(?=[\s\S]*["'](#*)$)\\\1\([^()]*\)/,
greedy: true,
inside: {
'punctuation': /^\\#*\(|\)$/,
'expression': {
pattern: /[\s\S]+/,
inside: null
}
}
},
'string': /[\s\S]+/
}
},
'keyword': {
pattern: /(^|[^\w$])(?:for|if|import|in|let|null|package)(?![\w$])/,
lookbehind: true
},
'boolean': {
pattern: /(^|[^\w$])(?:false|true)(?![\w$])/,
lookbehind: true
},
'builtin': {
pattern: /(^|[^\w$])(?:bool|bytes|float|float(?:32|64)|u?int(?:8|16|32|64|128)?|number|rune|string)(?![\w$])/,
lookbehind: true
},
'attribute': {
pattern: /@[\w$]+(?=\s*\()/,
alias: 'function'
},
'function': {
pattern: /(^|[^\w$])[a-z_$][\w$]*(?=\s*\()/i,
lookbehind: true
},
'number': {
pattern: /(^|[^\w$.])(?:0b[01]+(?:_[01]+)*|0o[0-7]+(?:_[0-7]+)*|0[xX][0-9A-Fa-f]+(?:_[0-9A-Fa-f]+)*|(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[eE][+-]?\d+(?:_\d+)*)?(?:[KMGTP]i?)?)(?![\w$])/,
lookbehind: true
},
'operator': /\.{3}|_\|_|&&?|\|\|?|[=!]~|[<>=!]=?|[+\-*/?]/,
'punctuation': /[()[\]{},.:]/
};
Prism.languages.cue['string-literal'].inside.interpolation.inside.expression.inside = Prism.languages.cue;
}(Prism));

View File

@@ -0,0 +1 @@
{"version":3,"file":"clipboard-pen.js","sources":["../../../src/icons/clipboard-pen.ts"],"sourcesContent":["import createLucideIcon from '../createLucideIcon';\n\n/**\n * @component @name ClipboardPen\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview ![img](data:image/svg+xml;base64,PHN2ZyAgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIgogIHdpZHRoPSIyNCIKICBoZWlnaHQ9IjI0IgogIHZpZXdCb3g9IjAgMCAyNCAyNCIKICBmaWxsPSJub25lIgogIHN0cm9rZT0iIzAwMCIgc3R5bGU9ImJhY2tncm91bmQtY29sb3I6ICNmZmY7IGJvcmRlci1yYWRpdXM6IDJweCIKICBzdHJva2Utd2lkdGg9IjIiCiAgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIgogIHN0cm9rZS1saW5lam9pbj0icm91bmQiCj4KICA8cmVjdCB3aWR0aD0iOCIgaGVpZ2h0PSI0IiB4PSI4IiB5PSIyIiByeD0iMSIgLz4KICA8cGF0aCBkPSJNMTYgNGgyYTIgMiAwIDAgMSAyIDJ2MTRhMiAyIDAgMCAxLTIgMmgtNS41IiAvPgogIDxwYXRoIGQ9Ik00IDEzLjVWNmEyIDIgMCAwIDEgMi0yaDIiIC8+CiAgPHBhdGggZD0iTTEzLjM3OCAxNS42MjZhMSAxIDAgMSAwLTMuMDA0LTMuMDA0bC01LjAxIDUuMDEyYTIgMiAwIDAgMC0uNTA2Ljg1NGwtLjgzNyAyLjg3YS41LjUgMCAwIDAgLjYyLjYybDIuODctLjgzN2EyIDIgMCAwIDAgLjg1NC0uNTA2eiIgLz4KPC9zdmc+Cg==) - https://lucide.dev/icons/clipboard-pen\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 ClipboardPen = createLucideIcon('ClipboardPen', [\n ['rect', { width: '8', height: '4', x: '8', y: '2', rx: '1', key: '1oijnt' }],\n ['path', { d: 'M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-5.5', key: 'cereej' }],\n ['path', { d: 'M4 13.5V6a2 2 0 0 1 2-2h2', key: '5ua5vh' }],\n [\n 'path',\n {\n d: 'M13.378 15.626a1 1 0 1 0-3.004-3.004l-5.01 5.012a2 2 0 0 0-.506.854l-.837 2.87a.5.5 0 0 0 .62.62l2.87-.837a2 2 0 0 0 .854-.506z',\n key: '1y4qbx',\n },\n ],\n]);\n\nexport default ClipboardPen;\n"],"names":[],"mappings":";;;;;;;;;AAaM,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAe,iBAAiB,cAAgB,CAAA,CAAA,CAAA;AAAA,CAAA,CACpD,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAE,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAO,KAAK,CAAQ,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,CAAG,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,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,CAC5E,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAA+C,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,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,CAC5E,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,CAC1D,CAAA,CAAA;AAAA,CAAA,CAAA,CAAA,CACE,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAAA,CACA,CAAA,CAAA,CAAA,CAAA;AAAA,CACE,CAAA,CAAA,CAAA,CAAA,CAAA,CAAG,EAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAAA,CACH,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,EAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAAA,CACP,CAAA,CAAA,CAAA,CAAA;AAAA,CACF,CAAA,CAAA;AACF,CAAC,CAAA,CAAA;;"}

View File

@@ -0,0 +1,55 @@
"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.processDetector = void 0;
const api_1 = require("@opentelemetry/api");
const semconv_1 = require("../../../semconv");
const os = require("os");
/**
* ProcessDetector will be used to detect the resources related current process running
* and being instrumented from the NodeJS Process module.
*/
class ProcessDetector {
detect(_config) {
const attributes = {
[semconv_1.ATTR_PROCESS_PID]: process.pid,
[semconv_1.ATTR_PROCESS_EXECUTABLE_NAME]: process.title,
[semconv_1.ATTR_PROCESS_EXECUTABLE_PATH]: process.execPath,
[semconv_1.ATTR_PROCESS_COMMAND_ARGS]: [
process.argv[0],
...process.execArgv,
...process.argv.slice(1),
],
[semconv_1.ATTR_PROCESS_RUNTIME_VERSION]: process.versions.node,
[semconv_1.ATTR_PROCESS_RUNTIME_NAME]: 'nodejs',
[semconv_1.ATTR_PROCESS_RUNTIME_DESCRIPTION]: 'Node.js',
};
if (process.argv.length > 1) {
attributes[semconv_1.ATTR_PROCESS_COMMAND] = process.argv[1];
}
try {
const userInfo = os.userInfo();
attributes[semconv_1.ATTR_PROCESS_OWNER] = userInfo.username;
}
catch (e) {
api_1.diag.debug(`error obtaining process owner: ${e}`);
}
return { attributes };
}
}
exports.processDetector = new ProcessDetector();
//# sourceMappingURL=ProcessDetector.js.map

View File

@@ -0,0 +1,9 @@
// Unless explicitly stated otherwise all files in this repository are licensed under the Apache 2.0 License.
//
// This product includes software developed at Datadog (https://www.datadoghq.com/). Copyright 2021 Datadog, Inc.
import { createHook } from './create-hook.mjs'
const { initialize, load, resolve, getFormat, getSource } = createHook(import.meta)
export { initialize, load, resolve, getFormat, getSource }

View File

@@ -0,0 +1,3 @@
import type { MigrationConfig } from "../migrator.cjs";
import type { MySql2Database } from "./driver.cjs";
export declare function migrate<TSchema extends Record<string, unknown>>(db: MySql2Database<TSchema>, config: MigrationConfig): Promise<void>;

View File

@@ -0,0 +1,32 @@
"use strict";
exports.previousSaturday = previousSaturday;
var _index = require("./previousDay.cjs");
/**
* The {@link previousSaturday} function options.
*/
/**
* @name previousSaturday
* @category Weekday Helpers
* @summary When is the previous Saturday?
*
* @description
* When is the previous Saturday?
*
* @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 date to start counting from
* @param options - The options
*
* @returns The previous Saturday
*
* @example
* // When is the previous Saturday before Jun, 20, 2021?
* const result = previousSaturday(new Date(2021, 5, 20))
* //=> Sat June 19 2021 00:00:00
*/
function previousSaturday(date, options) {
return (0, _index.previousDay)(date, 6, options);
}

View File

@@ -0,0 +1,200 @@
/* eslint-disable no-unused-vars */
/**
* The locale object with all functions and data needed to parse and format
* dates. This is what each locale implements and exports.
*/
/**
* The locale options.
*/
/// Format distance types
/**
* The function that takes a token (i.e. halfAMinute) passed by `formatDistance`
* or `formatDistanceStrict` and payload, and returns localized distance.
*
* @param token - The token to localize
* @param count - The distance number
* @param options - The object with options
*
* @returns The localized distance in words
*/
/**
* The {@link FormatDistanceFn} function options.
*/
/**
* The function used inside the {@link FormatDistanceFn} function, implementing
* formatting for a particular token.
*/
/**
* The tokens map to string templates used in the format distance function.
* It looks like this:
*
* const formatDistanceLocale: FormatDistanceLocale<FormatDistanceTokenValue> = {
* lessThanXSeconds: 'តិចជាង {{count}} វិនាទី',
* xSeconds: '{{count}} វិនាទី',
* // ...
* }
*
* @typeParam Template - The property value type.
*/
/**
* The token used in the format distance function. Represents the distance unit
* with prespecified precision.
*/
/// Format relative types
/**
* The locale function that does the work for the `formatRelative` function.
*
* @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 token - The token to localize
* @param date - The date to format
* @param baseDate - The date to compare with
* @param options - The object with options
*
* @returns The localized relative date format
*/
/**
* The {@link FormatRelativeFn} function options.
*/
/**
* The locale function used inside the {@link FormatRelativeFn} function
* implementing formatting for a particular token.
*
* @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 date to format
* @param baseDate - The date to compare with
* @param options - The object with options
*/
/**
* The {@link FormatRelativeTokenFn} function options.
*/
/**
* The token used in format relative function. Represents the time unit.
*/
/**
* A format part that represents a token or string literal, used by format parser/tokenizer
*/
/// Localize types
/**
* The object with functions used to localize various values. Part of the public
* locale API.
*/
/**
* Individual localize function. Part of {@link Localize}.
*
* @typeParam Value - The value type to localize.
*
* @param value - The value to localize
* @param options - The object with options
*
* @returns The localized string
*/
/**
* The {@link LocalizeFn} function options.
*/
/// Match types
/**
* The object with functions used to match and parse various localized values.
*/
/**
* The match function. Part of {@link Match}. Implements matcher for particular
* unit type.
*
* @typeParam Result - The matched value type.
* @typeParam ExtraOptions - The the extra options type.
*
* @param str - The string to match
* @param options - The object with options
*
* @returns The match result or null if match failed
*/
/**
* The {@link MatchFn} function options.
*
* @typeParam Result - The matched value type.
*/
/**
* The function that allows to map the matched value to the actual type.
*
* @typeParam Arg - The argument type.
* @typeParam Result - The matched value type.
*
* @param arg - The value to match
*
* @returns The matched value
*/
/**
* The {@link MatchFn} function result.
*
* @typeParam Result - The matched value type.
*/
/// Format long types
/**
* The object with functions that return localized formats. Long stands for
* sequence of tokens (i.e. PPpp) that allows to define how format both date
* and time at once. Part of the public locale API.
*/
/**
* The format long function. Formats date, time or both.
*
* @param options - The object with options
*
* @returns The localized string
*/
/**
* The {@link FormatLongFn} function options.
*/
/**
* The format long width token, defines how short or long the formnatted value
* might be. The actual result length is defined by the locale.
*/
/// Common types
/**
* The formatting unit value, represents the raw value that can be formatted.
*/
/**
* The format width. Defines how short or long the formatted string might be.
* The actaul result length depends on the locale.
*/
/**
* Token representing particular period of the day.
*/
/**
* The units commonly used in the date formatting or parsing.
*/ export {};

View File

@@ -0,0 +1,16 @@
import { jsx as _jsx } from "react/jsx-runtime";
export const OrderableRowDragPreview = ({
children,
className,
rowId
}) => typeof rowId === 'undefined' ? null : /*#__PURE__*/_jsx("div", {
className: className,
children: /*#__PURE__*/_jsx("table", {
cellPadding: 0,
cellSpacing: 0,
children: /*#__PURE__*/_jsx("tbody", {
children: children
})
})
});
//# sourceMappingURL=OrderableRowDragPreview.js.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"message-circle-reply.js","sources":["../../../src/icons/message-circle-reply.ts"],"sourcesContent":["import createLucideIcon from '../createLucideIcon';\n\n/**\n * @component @name MessageCircleReply\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview ![img](data:image/svg+xml;base64,PHN2ZyAgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIgogIHdpZHRoPSIyNCIKICBoZWlnaHQ9IjI0IgogIHZpZXdCb3g9IjAgMCAyNCAyNCIKICBmaWxsPSJub25lIgogIHN0cm9rZT0iIzAwMCIgc3R5bGU9ImJhY2tncm91bmQtY29sb3I6ICNmZmY7IGJvcmRlci1yYWRpdXM6IDJweCIKICBzdHJva2Utd2lkdGg9IjIiCiAgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIgogIHN0cm9rZS1saW5lam9pbj0icm91bmQiCj4KICA8cGF0aCBkPSJNNy45IDIwQTkgOSAwIDEgMCA0IDE2LjFMMiAyMloiIC8+CiAgPHBhdGggZD0ibTEwIDE1LTMtMyAzLTMiIC8+CiAgPHBhdGggZD0iTTcgMTJoN2EyIDIgMCAwIDEgMiAydjEiIC8+Cjwvc3ZnPgo=) - https://lucide.dev/icons/message-circle-reply\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 MessageCircleReply = createLucideIcon('MessageCircleReply', [\n ['path', { d: 'M7.9 20A9 9 0 1 0 4 16.1L2 22Z', key: 'vv11sd' }],\n ['path', { d: 'm10 15-3-3 3-3', key: '1pgupc' }],\n ['path', { d: 'M7 12h7a2 2 0 0 1 2 2v1', key: '1gheu4' }],\n]);\n\nexport default MessageCircleReply;\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,CAAA,CAAA,CAAA,CAAA,CAAqB,iBAAiB,oBAAsB,CAAA,CAAA,CAAA;AAAA,CAAA,CAChE,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAkC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,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,CAC/D,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,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,CAC/C,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,31 @@
import { findVersionsOperationGlobal, isolateObjectProperty } from 'payload';
import { buildSelectForCollectionMany } from '../../utilities/select.js';
export function findVersions(globalConfig) {
return async function resolver(_, args, context, info) {
const req = context.req = isolateObjectProperty(context.req, [
'locale',
'fallbackLocale',
'transactionID'
]);
const select = context.select = args.select ? buildSelectForCollectionMany(info) : undefined;
req.locale = args.locale || req.locale;
req.fallbackLocale = args.fallbackLocale || req.fallbackLocale;
req.query = req.query || {};
const { sort } = args;
const options = {
depth: 0,
globalConfig,
limit: args.limit,
page: args.page,
pagination: args.pagination,
req,
select,
sort: sort && typeof sort === 'string' ? sort.split(',') : undefined,
where: args.where
};
const result = await findVersionsOperationGlobal(options);
return result;
};
}
//# sourceMappingURL=findVersions.js.map

View File

@@ -0,0 +1,125 @@
'use strict';
const readDigit = (buffer, index) => {
const digit = buffer.readUInt16BE(8 + 2 * index);
if (digit > 9999) {
throw new RangeError('Invalid numeric digit: ' + digit);
}
return digit;
};
const readNumeric = buffer => {
const ndigits = buffer.readUInt16BE(0);
let weight = buffer.readInt16BE(2);
const sign = buffer.readUInt16BE(4);
const dscale = buffer.readUInt16BE(6);
let signText;
let isNegativeZero;
switch (sign) {
case 0x0000:
signText = '';
isNegativeZero = false;
break;
case 0x4000:
signText = '-';
isNegativeZero = true;
break;
case 0xc000:
return 'NaN';
default:
throw new RangeError('Invalid numeric sign: 0x' + sign.toString(16));
}
if (2 * ndigits !== buffer.length - 8) {
throw new RangeError('Invalid numeric length: ' + buffer.length + ' bytes of data representing ' + ndigits + ' digits');
}
if (dscale > 0x3fff) {
throw new RangeError('Invalid numeric dscale: 0x' + dscale.toString(16));
}
let result = signText;
let i = 0;
integerPart: {
for (;;) {
if (i >= ndigits) {
// no non-zero digits
weight = -1;
}
if (weight < 0) {
result += '0';
break integerPart;
}
const digit = readDigit(buffer, i);
i++;
weight--;
if (digit !== 0) {
isNegativeZero = false;
result += String(digit);
break;
}
}
while (weight >= 0 && i < ndigits) {
const digit = readDigit(buffer, i);
i++;
weight--;
result += String(10000 + digit).substring(1);
}
while (weight >= 0) {
result += '0000';
weight--;
}
}
fractionalPart: if (dscale !== 0) {
result += '.';
const omitted = -1 - weight;
if (omitted > 0) {
if (4 * omitted > dscale) {
result += '0'.repeat(dscale);
break fractionalPart;
}
result += '0'.repeat(4 * omitted);
}
while (-4 * weight <= dscale) {
const digit = i < ndigits ? readDigit(buffer, i) : 0;
i++;
weight--;
if (isNegativeZero && digit !== 0) {
isNegativeZero = false;
}
result += String(10000 + digit).substring(1);
}
{
const digit = i < ndigits ? readDigit(buffer, i) : 0;
result += String(10000 + digit).substr(1, dscale % 4);
if (isNegativeZero && digit >= Math.pow(10, 4 - dscale % 4)) {
isNegativeZero = false;
}
}
}
return isNegativeZero ? result.substring(1) : result;
};
module.exports = readNumeric;

View File

@@ -0,0 +1,17 @@
/**
* @license lucide-react v0.441.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
import createLucideIcon from '../createLucideIcon.js';
const SquareArrowRight = createLucideIcon("SquareArrowRight", [
["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", key: "afitv7" }],
["path", { d: "M8 12h8", key: "1wcyev" }],
["path", { d: "m12 16 4-4-4-4", key: "1i9zcv" }]
]);
export { SquareArrowRight as default };
//# sourceMappingURL=square-arrow-right.js.map

View File

@@ -0,0 +1,11 @@
/* eslint-env commonjs */
import { ono } from "./singleton";
export { Ono } from "./constructor";
export * from "./types";
export { ono };
export default ono;
// CommonJS default export hack
if (typeof module === "object" && typeof module.exports === "object") {
module.exports = Object.assign(module.exports.default, module.exports);
}
//# sourceMappingURL=index.js.map

View File

@@ -0,0 +1,31 @@
import { entityKind } from "../../entity.js";
import { GelColumn } from "./common.js";
import { GelLocalDateColumnBaseBuilder } from "./date.common.js";
class GelLocalTimeBuilder extends GelLocalDateColumnBaseBuilder {
static [entityKind] = "GelLocalTimeBuilder";
constructor(name) {
super(name, "localTime", "GelLocalTime");
}
/** @internal */
build(table) {
return new GelLocalTime(
table,
this.config
);
}
}
class GelLocalTime extends GelColumn {
static [entityKind] = "GelLocalTime";
getSQLType() {
return "cal::local_time";
}
}
function localTime(name) {
return new GelLocalTimeBuilder(name ?? "");
}
export {
GelLocalTime,
GelLocalTimeBuilder,
localTime
};
//# sourceMappingURL=localtime.js.map

View File

@@ -0,0 +1,2 @@
export declare const sanitizeSortParams: (sort: unknown) => string[] | undefined;
//# sourceMappingURL=sanitizeSortParams.d.ts.map

View File

@@ -0,0 +1,190 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.calculatePaddingBoxPath = exports.calculateContentBoxPath = exports.calculateBorderBoxPath = exports.BoundCurves = void 0;
var length_percentage_1 = require("../css/types/length-percentage");
var vector_1 = require("./vector");
var bezier_curve_1 = require("./bezier-curve");
var BoundCurves = /** @class */ (function () {
function BoundCurves(element) {
var styles = element.styles;
var bounds = element.bounds;
var _a = length_percentage_1.getAbsoluteValueForTuple(styles.borderTopLeftRadius, bounds.width, bounds.height), tlh = _a[0], tlv = _a[1];
var _b = length_percentage_1.getAbsoluteValueForTuple(styles.borderTopRightRadius, bounds.width, bounds.height), trh = _b[0], trv = _b[1];
var _c = length_percentage_1.getAbsoluteValueForTuple(styles.borderBottomRightRadius, bounds.width, bounds.height), brh = _c[0], brv = _c[1];
var _d = length_percentage_1.getAbsoluteValueForTuple(styles.borderBottomLeftRadius, bounds.width, bounds.height), blh = _d[0], blv = _d[1];
var factors = [];
factors.push((tlh + trh) / bounds.width);
factors.push((blh + brh) / bounds.width);
factors.push((tlv + blv) / bounds.height);
factors.push((trv + brv) / bounds.height);
var maxFactor = Math.max.apply(Math, factors);
if (maxFactor > 1) {
tlh /= maxFactor;
tlv /= maxFactor;
trh /= maxFactor;
trv /= maxFactor;
brh /= maxFactor;
brv /= maxFactor;
blh /= maxFactor;
blv /= maxFactor;
}
var topWidth = bounds.width - trh;
var rightHeight = bounds.height - brv;
var bottomWidth = bounds.width - brh;
var leftHeight = bounds.height - blv;
var borderTopWidth = styles.borderTopWidth;
var borderRightWidth = styles.borderRightWidth;
var borderBottomWidth = styles.borderBottomWidth;
var borderLeftWidth = styles.borderLeftWidth;
var paddingTop = length_percentage_1.getAbsoluteValue(styles.paddingTop, element.bounds.width);
var paddingRight = length_percentage_1.getAbsoluteValue(styles.paddingRight, element.bounds.width);
var paddingBottom = length_percentage_1.getAbsoluteValue(styles.paddingBottom, element.bounds.width);
var paddingLeft = length_percentage_1.getAbsoluteValue(styles.paddingLeft, element.bounds.width);
this.topLeftBorderDoubleOuterBox =
tlh > 0 || tlv > 0
? getCurvePoints(bounds.left + borderLeftWidth / 3, bounds.top + borderTopWidth / 3, tlh - borderLeftWidth / 3, tlv - borderTopWidth / 3, CORNER.TOP_LEFT)
: new vector_1.Vector(bounds.left + borderLeftWidth / 3, bounds.top + borderTopWidth / 3);
this.topRightBorderDoubleOuterBox =
tlh > 0 || tlv > 0
? getCurvePoints(bounds.left + topWidth, bounds.top + borderTopWidth / 3, trh - borderRightWidth / 3, trv - borderTopWidth / 3, CORNER.TOP_RIGHT)
: new vector_1.Vector(bounds.left + bounds.width - borderRightWidth / 3, bounds.top + borderTopWidth / 3);
this.bottomRightBorderDoubleOuterBox =
brh > 0 || brv > 0
? getCurvePoints(bounds.left + bottomWidth, bounds.top + rightHeight, brh - borderRightWidth / 3, brv - borderBottomWidth / 3, CORNER.BOTTOM_RIGHT)
: new vector_1.Vector(bounds.left + bounds.width - borderRightWidth / 3, bounds.top + bounds.height - borderBottomWidth / 3);
this.bottomLeftBorderDoubleOuterBox =
blh > 0 || blv > 0
? getCurvePoints(bounds.left + borderLeftWidth / 3, bounds.top + leftHeight, blh - borderLeftWidth / 3, blv - borderBottomWidth / 3, CORNER.BOTTOM_LEFT)
: new vector_1.Vector(bounds.left + borderLeftWidth / 3, bounds.top + bounds.height - borderBottomWidth / 3);
this.topLeftBorderDoubleInnerBox =
tlh > 0 || tlv > 0
? getCurvePoints(bounds.left + (borderLeftWidth * 2) / 3, bounds.top + (borderTopWidth * 2) / 3, tlh - (borderLeftWidth * 2) / 3, tlv - (borderTopWidth * 2) / 3, CORNER.TOP_LEFT)
: new vector_1.Vector(bounds.left + (borderLeftWidth * 2) / 3, bounds.top + (borderTopWidth * 2) / 3);
this.topRightBorderDoubleInnerBox =
tlh > 0 || tlv > 0
? getCurvePoints(bounds.left + topWidth, bounds.top + (borderTopWidth * 2) / 3, trh - (borderRightWidth * 2) / 3, trv - (borderTopWidth * 2) / 3, CORNER.TOP_RIGHT)
: new vector_1.Vector(bounds.left + bounds.width - (borderRightWidth * 2) / 3, bounds.top + (borderTopWidth * 2) / 3);
this.bottomRightBorderDoubleInnerBox =
brh > 0 || brv > 0
? getCurvePoints(bounds.left + bottomWidth, bounds.top + rightHeight, brh - (borderRightWidth * 2) / 3, brv - (borderBottomWidth * 2) / 3, CORNER.BOTTOM_RIGHT)
: new vector_1.Vector(bounds.left + bounds.width - (borderRightWidth * 2) / 3, bounds.top + bounds.height - (borderBottomWidth * 2) / 3);
this.bottomLeftBorderDoubleInnerBox =
blh > 0 || blv > 0
? getCurvePoints(bounds.left + (borderLeftWidth * 2) / 3, bounds.top + leftHeight, blh - (borderLeftWidth * 2) / 3, blv - (borderBottomWidth * 2) / 3, CORNER.BOTTOM_LEFT)
: new vector_1.Vector(bounds.left + (borderLeftWidth * 2) / 3, bounds.top + bounds.height - (borderBottomWidth * 2) / 3);
this.topLeftBorderStroke =
tlh > 0 || tlv > 0
? getCurvePoints(bounds.left + borderLeftWidth / 2, bounds.top + borderTopWidth / 2, tlh - borderLeftWidth / 2, tlv - borderTopWidth / 2, CORNER.TOP_LEFT)
: new vector_1.Vector(bounds.left + borderLeftWidth / 2, bounds.top + borderTopWidth / 2);
this.topRightBorderStroke =
tlh > 0 || tlv > 0
? getCurvePoints(bounds.left + topWidth, bounds.top + borderTopWidth / 2, trh - borderRightWidth / 2, trv - borderTopWidth / 2, CORNER.TOP_RIGHT)
: new vector_1.Vector(bounds.left + bounds.width - borderRightWidth / 2, bounds.top + borderTopWidth / 2);
this.bottomRightBorderStroke =
brh > 0 || brv > 0
? getCurvePoints(bounds.left + bottomWidth, bounds.top + rightHeight, brh - borderRightWidth / 2, brv - borderBottomWidth / 2, CORNER.BOTTOM_RIGHT)
: new vector_1.Vector(bounds.left + bounds.width - borderRightWidth / 2, bounds.top + bounds.height - borderBottomWidth / 2);
this.bottomLeftBorderStroke =
blh > 0 || blv > 0
? getCurvePoints(bounds.left + borderLeftWidth / 2, bounds.top + leftHeight, blh - borderLeftWidth / 2, blv - borderBottomWidth / 2, CORNER.BOTTOM_LEFT)
: new vector_1.Vector(bounds.left + borderLeftWidth / 2, bounds.top + bounds.height - borderBottomWidth / 2);
this.topLeftBorderBox =
tlh > 0 || tlv > 0
? getCurvePoints(bounds.left, bounds.top, tlh, tlv, CORNER.TOP_LEFT)
: new vector_1.Vector(bounds.left, bounds.top);
this.topRightBorderBox =
trh > 0 || trv > 0
? getCurvePoints(bounds.left + topWidth, bounds.top, trh, trv, CORNER.TOP_RIGHT)
: new vector_1.Vector(bounds.left + bounds.width, bounds.top);
this.bottomRightBorderBox =
brh > 0 || brv > 0
? getCurvePoints(bounds.left + bottomWidth, bounds.top + rightHeight, brh, brv, CORNER.BOTTOM_RIGHT)
: new vector_1.Vector(bounds.left + bounds.width, bounds.top + bounds.height);
this.bottomLeftBorderBox =
blh > 0 || blv > 0
? getCurvePoints(bounds.left, bounds.top + leftHeight, blh, blv, CORNER.BOTTOM_LEFT)
: new vector_1.Vector(bounds.left, bounds.top + bounds.height);
this.topLeftPaddingBox =
tlh > 0 || tlv > 0
? getCurvePoints(bounds.left + borderLeftWidth, bounds.top + borderTopWidth, Math.max(0, tlh - borderLeftWidth), Math.max(0, tlv - borderTopWidth), CORNER.TOP_LEFT)
: new vector_1.Vector(bounds.left + borderLeftWidth, bounds.top + borderTopWidth);
this.topRightPaddingBox =
trh > 0 || trv > 0
? getCurvePoints(bounds.left + Math.min(topWidth, bounds.width - borderRightWidth), bounds.top + borderTopWidth, topWidth > bounds.width + borderRightWidth ? 0 : Math.max(0, trh - borderRightWidth), Math.max(0, trv - borderTopWidth), CORNER.TOP_RIGHT)
: new vector_1.Vector(bounds.left + bounds.width - borderRightWidth, bounds.top + borderTopWidth);
this.bottomRightPaddingBox =
brh > 0 || brv > 0
? getCurvePoints(bounds.left + Math.min(bottomWidth, bounds.width - borderLeftWidth), bounds.top + Math.min(rightHeight, bounds.height - borderBottomWidth), Math.max(0, brh - borderRightWidth), Math.max(0, brv - borderBottomWidth), CORNER.BOTTOM_RIGHT)
: new vector_1.Vector(bounds.left + bounds.width - borderRightWidth, bounds.top + bounds.height - borderBottomWidth);
this.bottomLeftPaddingBox =
blh > 0 || blv > 0
? getCurvePoints(bounds.left + borderLeftWidth, bounds.top + Math.min(leftHeight, bounds.height - borderBottomWidth), Math.max(0, blh - borderLeftWidth), Math.max(0, blv - borderBottomWidth), CORNER.BOTTOM_LEFT)
: new vector_1.Vector(bounds.left + borderLeftWidth, bounds.top + bounds.height - borderBottomWidth);
this.topLeftContentBox =
tlh > 0 || tlv > 0
? getCurvePoints(bounds.left + borderLeftWidth + paddingLeft, bounds.top + borderTopWidth + paddingTop, Math.max(0, tlh - (borderLeftWidth + paddingLeft)), Math.max(0, tlv - (borderTopWidth + paddingTop)), CORNER.TOP_LEFT)
: new vector_1.Vector(bounds.left + borderLeftWidth + paddingLeft, bounds.top + borderTopWidth + paddingTop);
this.topRightContentBox =
trh > 0 || trv > 0
? getCurvePoints(bounds.left + Math.min(topWidth, bounds.width + borderLeftWidth + paddingLeft), bounds.top + borderTopWidth + paddingTop, topWidth > bounds.width + borderLeftWidth + paddingLeft ? 0 : trh - borderLeftWidth + paddingLeft, trv - (borderTopWidth + paddingTop), CORNER.TOP_RIGHT)
: new vector_1.Vector(bounds.left + bounds.width - (borderRightWidth + paddingRight), bounds.top + borderTopWidth + paddingTop);
this.bottomRightContentBox =
brh > 0 || brv > 0
? getCurvePoints(bounds.left + Math.min(bottomWidth, bounds.width - (borderLeftWidth + paddingLeft)), bounds.top + Math.min(rightHeight, bounds.height + borderTopWidth + paddingTop), Math.max(0, brh - (borderRightWidth + paddingRight)), brv - (borderBottomWidth + paddingBottom), CORNER.BOTTOM_RIGHT)
: new vector_1.Vector(bounds.left + bounds.width - (borderRightWidth + paddingRight), bounds.top + bounds.height - (borderBottomWidth + paddingBottom));
this.bottomLeftContentBox =
blh > 0 || blv > 0
? getCurvePoints(bounds.left + borderLeftWidth + paddingLeft, bounds.top + leftHeight, Math.max(0, blh - (borderLeftWidth + paddingLeft)), blv - (borderBottomWidth + paddingBottom), CORNER.BOTTOM_LEFT)
: new vector_1.Vector(bounds.left + borderLeftWidth + paddingLeft, bounds.top + bounds.height - (borderBottomWidth + paddingBottom));
}
return BoundCurves;
}());
exports.BoundCurves = BoundCurves;
var CORNER;
(function (CORNER) {
CORNER[CORNER["TOP_LEFT"] = 0] = "TOP_LEFT";
CORNER[CORNER["TOP_RIGHT"] = 1] = "TOP_RIGHT";
CORNER[CORNER["BOTTOM_RIGHT"] = 2] = "BOTTOM_RIGHT";
CORNER[CORNER["BOTTOM_LEFT"] = 3] = "BOTTOM_LEFT";
})(CORNER || (CORNER = {}));
var getCurvePoints = function (x, y, r1, r2, position) {
var kappa = 4 * ((Math.sqrt(2) - 1) / 3);
var ox = r1 * kappa; // control point offset horizontal
var oy = r2 * kappa; // control point offset vertical
var xm = x + r1; // x-middle
var ym = y + r2; // y-middle
switch (position) {
case CORNER.TOP_LEFT:
return new bezier_curve_1.BezierCurve(new vector_1.Vector(x, ym), new vector_1.Vector(x, ym - oy), new vector_1.Vector(xm - ox, y), new vector_1.Vector(xm, y));
case CORNER.TOP_RIGHT:
return new bezier_curve_1.BezierCurve(new vector_1.Vector(x, y), new vector_1.Vector(x + ox, y), new vector_1.Vector(xm, ym - oy), new vector_1.Vector(xm, ym));
case CORNER.BOTTOM_RIGHT:
return new bezier_curve_1.BezierCurve(new vector_1.Vector(xm, y), new vector_1.Vector(xm, y + oy), new vector_1.Vector(x + ox, ym), new vector_1.Vector(x, ym));
case CORNER.BOTTOM_LEFT:
default:
return new bezier_curve_1.BezierCurve(new vector_1.Vector(xm, ym), new vector_1.Vector(xm - ox, ym), new vector_1.Vector(x, y + oy), new vector_1.Vector(x, y));
}
};
var calculateBorderBoxPath = function (curves) {
return [curves.topLeftBorderBox, curves.topRightBorderBox, curves.bottomRightBorderBox, curves.bottomLeftBorderBox];
};
exports.calculateBorderBoxPath = calculateBorderBoxPath;
var calculateContentBoxPath = function (curves) {
return [
curves.topLeftContentBox,
curves.topRightContentBox,
curves.bottomRightContentBox,
curves.bottomLeftContentBox
];
};
exports.calculateContentBoxPath = calculateContentBoxPath;
var calculatePaddingBoxPath = function (curves) {
return [
curves.topLeftPaddingBox,
curves.topRightPaddingBox,
curves.bottomRightPaddingBox,
curves.bottomLeftPaddingBox
];
};
exports.calculatePaddingBoxPath = calculatePaddingBoxPath;
//# sourceMappingURL=bound-curves.js.map

View File

@@ -0,0 +1,24 @@
import { count, sql } from 'drizzle-orm';
export const countDistinct = async function countDistinct({ column, db, joins, tableName, where }) {
// When we don't have any joins - use a simple COUNT(*) query.
if (joins.length === 0) {
const countResult = await db.select({
count: column ? count(sql`DISTINCT ${column}`) : count()
}).from(this.tables[tableName]).where(where);
return Number(countResult?.[0]?.count ?? 0);
}
let query = db.select({
count: sql`COUNT(1) OVER()`
}).from(this.tables[tableName]).where(where).groupBy(column || this.tables[tableName].id).limit(1).$dynamic();
joins.forEach(({ type, condition, table })=>{
query = query[type ?? 'leftJoin'](table, condition);
});
// When we have any joins, we need to count each individual ID only once.
// COUNT(*) doesn't work for this well in this case, as it also counts joined tables.
// SELECT (COUNT DISTINCT id) has a very slow performance on large tables.
// Instead, COUNT (GROUP BY id) can be used which is still slower than COUNT(*) but acceptable.
const countResult = await query;
return Number(countResult?.[0]?.count ?? 0);
};
//# sourceMappingURL=countDistinct.js.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"monitor-up.js","sources":["../../../src/icons/monitor-up.ts"],"sourcesContent":["import createLucideIcon from '../createLucideIcon';\n\n/**\n * @component @name MonitorUp\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview ![img](data:image/svg+xml;base64,PHN2ZyAgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIgogIHdpZHRoPSIyNCIKICBoZWlnaHQ9IjI0IgogIHZpZXdCb3g9IjAgMCAyNCAyNCIKICBmaWxsPSJub25lIgogIHN0cm9rZT0iIzAwMCIgc3R5bGU9ImJhY2tncm91bmQtY29sb3I6ICNmZmY7IGJvcmRlci1yYWRpdXM6IDJweCIKICBzdHJva2Utd2lkdGg9IjIiCiAgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIgogIHN0cm9rZS1saW5lam9pbj0icm91bmQiCj4KICA8cGF0aCBkPSJtOSAxMCAzLTMgMyAzIiAvPgogIDxwYXRoIGQ9Ik0xMiAxM1Y3IiAvPgogIDxyZWN0IHdpZHRoPSIyMCIgaGVpZ2h0PSIxNCIgeD0iMiIgeT0iMyIgcng9IjIiIC8+CiAgPHBhdGggZD0iTTEyIDE3djQiIC8+CiAgPHBhdGggZD0iTTggMjFoOCIgLz4KPC9zdmc+Cg==) - https://lucide.dev/icons/monitor-up\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 MonitorUp = createLucideIcon('MonitorUp', [\n ['path', { d: 'm9 10 3-3 3 3', key: '11gsxs' }],\n ['path', { d: 'M12 13V7', key: 'h0r20n' }],\n ['rect', { width: '20', height: '14', x: '2', y: '3', rx: '2', key: '48i651' }],\n ['path', { d: 'M12 17v4', key: '1riwvh' }],\n ['path', { d: 'M8 21h8', key: '1ev6f3' }],\n]);\n\nexport default MonitorUp;\n"],"names":[],"mappings":";;;;;;;;;AAaM,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAY,iBAAiB,WAAa,CAAA,CAAA,CAAA;AAAA,CAAA,CAC9C,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,CAAA;AAAA,CAAA,CACzC,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,CAAA,CAAM,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,CAC9E,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,CAAA;AAAA,CAAA,CACzC,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAW,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA;AAC1C,CAAC,CAAA,CAAA;;"}

View File

@@ -0,0 +1 @@
{"version":3,"file":"venetian-mask.js","sources":["../../../src/icons/venetian-mask.ts"],"sourcesContent":["import createLucideIcon from '../createLucideIcon';\n\n/**\n * @component @name VenetianMask\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview ![img](data:image/svg+xml;base64,PHN2ZyAgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIgogIHdpZHRoPSIyNCIKICBoZWlnaHQ9IjI0IgogIHZpZXdCb3g9IjAgMCAyNCAyNCIKICBmaWxsPSJub25lIgogIHN0cm9rZT0iIzAwMCIgc3R5bGU9ImJhY2tncm91bmQtY29sb3I6ICNmZmY7IGJvcmRlci1yYWRpdXM6IDJweCIKICBzdHJva2Utd2lkdGg9IjIiCiAgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIgogIHN0cm9rZS1saW5lam9pbj0icm91bmQiCj4KICA8cGF0aCBkPSJNMiAxMmE1IDUgMCAwIDAgNSA1IDggOCAwIDAgMSA1IDIgOCA4IDAgMCAxIDUtMiA1IDUgMCAwIDAgNS01VjdoLTVhOCA4IDAgMCAwLTUgMiA4IDggMCAwIDAtNS0ySDJaIiAvPgogIDxwYXRoIGQ9Ik02IDExYzEuNSAwIDMgLjUgMyAyLTIgMC0zIDAtMy0yWiIgLz4KICA8cGF0aCBkPSJNMTggMTFjLTEuNSAwLTMgLjUtMyAyIDIgMCAzIDAgMy0yWiIgLz4KPC9zdmc+Cg==) - https://lucide.dev/icons/venetian-mask\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 VenetianMask = createLucideIcon('VenetianMask', [\n [\n 'path',\n {\n d: 'M2 12a5 5 0 0 0 5 5 8 8 0 0 1 5 2 8 8 0 0 1 5-2 5 5 0 0 0 5-5V7h-5a8 8 0 0 0-5 2 8 8 0 0 0-5-2H2Z',\n key: '1g6z3j',\n },\n ],\n ['path', { d: 'M6 11c1.5 0 3 .5 3 2-2 0-3 0-3-2Z', key: 'c2lwnf' }],\n ['path', { d: 'M18 11c-1.5 0-3 .5-3 2 2 0 3 0 3-2Z', key: 'njd9zo' }],\n]);\n\nexport default VenetianMask;\n"],"names":[],"mappings":";;;;;;;;;AAaM,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAe,iBAAiB,cAAgB,CAAA,CAAA,CAAA;AAAA,CACpD,CAAA,CAAA;AAAA,CAAA,CAAA,CAAA,CACE,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAAA,CACA,CAAA,CAAA,CAAA,CAAA;AAAA,CACE,CAAA,CAAA,CAAA,CAAA,CAAA,CAAG,EAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAAA,CACH,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,EAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAAA,CACP,CAAA,CAAA,CAAA,CAAA;AAAA,CACF,CAAA,CAAA,CAAA;AAAA,CAAA,CACA,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAqC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CAClE,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAuC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,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;AACtE,CAAC,CAAA,CAAA;;"}

View File

@@ -0,0 +1,96 @@
'use client';
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
import React, { useMemo, useRef, useState } from 'react';
import { Popup, PopupList } from '../Popup/index.js';
import './index.scss';
const baseClass = 'combobox';
/**
* A wrapper on top of Popup + PopupList.ButtonGroup that adds search functionality.
*
* @internal - this component may be removed or receive breaking changes in minor releases.
* @experimental
*/
export const Combobox = props => {
const {
entries,
minEntriesForSearch = 8,
onSelect,
onToggleClose,
onToggleOpen,
searchPlaceholder = 'Search...',
...popupProps
} = props;
const [searchValue, setSearchValue] = useState('');
const isOpenRef = useRef(false);
const searchInputRef = useRef(null);
const filteredEntries = useMemo(() => {
if (!searchValue) {
return entries;
}
const search = searchValue.toLowerCase();
return entries.filter(entry => entry.name.toLowerCase().includes(search));
}, [entries, searchValue]);
const showSearch = entries.length >= minEntriesForSearch;
const hasResults = filteredEntries.length > 0;
const handleToggleOpen = React.useCallback(active => {
isOpenRef.current = active;
if (active && showSearch) {
setTimeout(() => {
searchInputRef.current?.focus();
}, 100);
}
onToggleOpen?.(active);
}, [showSearch, onToggleOpen]);
const handleToggleClose = React.useCallback(() => {
isOpenRef.current = false;
setSearchValue('');
onToggleClose?.();
}, [onToggleClose]);
return /*#__PURE__*/_jsx(Popup, {
...popupProps,
className: `${baseClass} ${popupProps.className || ''}`,
onToggleClose: handleToggleClose,
onToggleOpen: handleToggleOpen,
render: ({
close
}) => /*#__PURE__*/_jsxs("div", {
className: `${baseClass}__content`,
children: [showSearch && /*#__PURE__*/_jsx("div", {
className: `${baseClass}__search-wrapper${!hasResults ? ` ${baseClass}__search-wrapper--no-results` : ''}`,
children: /*#__PURE__*/_jsx("input", {
"aria-label": searchPlaceholder,
className: `${baseClass}__search-input`,
onChange: e => setSearchValue(e.target.value),
placeholder: searchPlaceholder,
ref: searchInputRef,
type: "text",
value: searchValue
})
}), /*#__PURE__*/_jsx(PopupList.ButtonGroup, {
children: filteredEntries.map((entry_0, index) => {
const handleClick = () => {
if (onSelect) {
onSelect(entry_0);
}
close();
};
return /*#__PURE__*/_jsx("div", {
className: `${baseClass}__entry`,
onClick: handleClick,
onKeyDown: e_0 => {
if (e_0.key === 'Enter' || e_0.key === ' ') {
e_0.preventDefault();
handleClick();
}
},
role: "menuitem",
tabIndex: 0,
children: entry_0.Component
}, `${entry_0.name}-${index}`);
})
})]
})
});
};
//# sourceMappingURL=index.js.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"sendReplay.d.ts","sourceRoot":"","sources":["../../../../src/util/sendReplay.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAG/C;;GAEG;AACH,wBAAsB,UAAU,CAC9B,UAAU,EAAE,cAAc,EAC1B,WAAW;;;CAGV,GACA,OAAO,CAAC,OAAO,CAAC,CAuDlB"}

View File

@@ -0,0 +1,22 @@
import * as core from "../core/index.cjs";
import * as schemas from "./schemas.cjs";
export interface ZodMiniISODateTime extends schemas.ZodMiniStringFormat<"datetime"> {
_zod: core.$ZodISODateTimeInternals;
}
export declare const ZodMiniISODateTime: core.$constructor<ZodMiniISODateTime>;
export declare function datetime(params?: string | core.$ZodISODateTimeParams): ZodMiniISODateTime;
export interface ZodMiniISODate extends schemas.ZodMiniStringFormat<"date"> {
_zod: core.$ZodISODateInternals;
}
export declare const ZodMiniISODate: core.$constructor<ZodMiniISODate>;
export declare function date(params?: string | core.$ZodISODateParams): ZodMiniISODate;
export interface ZodMiniISOTime extends schemas.ZodMiniStringFormat<"time"> {
_zod: core.$ZodISOTimeInternals;
}
export declare const ZodMiniISOTime: core.$constructor<ZodMiniISOTime>;
export declare function time(params?: string | core.$ZodISOTimeParams): ZodMiniISOTime;
export interface ZodMiniISODuration extends schemas.ZodMiniStringFormat<"duration"> {
_zod: core.$ZodISODurationInternals;
}
export declare const ZodMiniISODuration: core.$constructor<ZodMiniISODuration>;
export declare function duration(params?: string | core.$ZodISODurationParams): ZodMiniISODuration;

View File

@@ -0,0 +1,164 @@
"use strict";
/**
*
* audit/utils
*
*/
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
var desc = Object.getOwnPropertyDescriptor(m, k);
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
desc = { enumerable: true, get: function() { return m[k]; } };
}
Object.defineProperty(o, k2, desc);
}) : (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
o[k2] = m[k];
}));
var __exportStar = (this && this.__exportStar) || function(m, exports) {
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.ressert = exports.AuditError = exports.audit = void 0;
__exportStar(require("../utils"), exports);
/**
* Wrap and prepare an audit for testing.
*
* @private
*/
function audit(id, name, fn) {
return {
id,
name,
fn: async () => {
try {
await fn();
return {
id,
name,
status: 'ok',
};
}
catch (err) {
if (!(err instanceof AuditError)) {
// anything thrown that is not an assertion error is considered fatal
throw err;
}
return {
id,
name,
status: name.startsWith('MUST')
? // failing MUSTs are considered errors
'error'
: name.startsWith('SHOULD')
? // recommendations are warnings
'warn'
: // everything else is truly optional
'notice',
reason: err.reason,
response: err.response,
};
}
},
};
}
exports.audit = audit;
/**
* Error thrown when an assertion test fails.
*
* @private
*/
class AuditError {
constructor(response, reason) {
this.response = response;
this.reason = reason;
}
}
exports.AuditError = AuditError;
/**
* Will throw an AuditError if the assertion on Response fails.
*
* All fatal problems will throw an instance of an Error.
*
* The name "ressert" is a wordplay combining "response" and "assert".
*
* @private
*/
function ressert(res) {
return {
status: {
toBe(code) {
if (res.status !== code) {
throw new AuditError(res, `Response status code is not ${code}`);
}
},
toBeBetween: (min, max) => {
if (!(min <= res.status && res.status <= max)) {
throw new AuditError(res, `Response status is not between ${min} and ${max}`);
}
},
},
header(key) {
return {
toContain(part) {
var _a;
if (!((_a = res.headers.get(key)) === null || _a === void 0 ? void 0 : _a.includes(part))) {
throw new AuditError(res, `Response header ${key} does not contain ${part}`);
}
},
notToContain(part) {
var _a;
if ((_a = res.headers.get(key)) === null || _a === void 0 ? void 0 : _a.includes(part)) {
throw new AuditError(res, `Response header ${key} contains ${part}`);
}
},
};
},
bodyAsExecutionResult: {
data: {
async toBe(val) {
const clonedRes = res.clone(); // allow the body to be re-read
const body = await assertBodyAsExecutionResult(res);
if (body.data !== val) {
throw new AuditError(clonedRes, `Response body execution result data is not "${val}"`);
}
},
},
async toHaveProperty(key) {
const clonedRes = res.clone(); // allow the body to be re-read
const body = await assertBodyAsExecutionResult(res);
if (!(key in body)) {
throw new AuditError(clonedRes, `Response body execution result does not have a property "${key}"`);
}
},
async notToHaveProperty(key) {
const clonedRes = res.clone(); // allow the body to be re-read
const body = await assertBodyAsExecutionResult(res);
if (key in body) {
throw new AuditError(clonedRes, `Response body execution result has a property "${key}"`);
}
},
},
};
}
exports.ressert = ressert;
/** @private */
async function assertBodyAsExecutionResult(res) {
let decoded;
try {
const decoder = new TextDecoder('utf-8');
const buff = await res.arrayBuffer();
decoded = decoder.decode(buff);
}
catch (err) {
throw new AuditError(res, 'Response body is not UTF-8 encoded');
}
let body;
try {
body = JSON.parse(decoded);
}
catch (err) {
throw new AuditError(res, 'Response body is not valid JSON');
}
return body;
}

View File

@@ -0,0 +1,7 @@
{
"name": "dom-helpers/prepend",
"private": true,
"main": "../cjs/prepend.js",
"module": "../esm/prepend.js",
"types": "../esm/prepend.d.ts"
}

View File

@@ -0,0 +1,2 @@
export { instrumentOpenAiClient } from '@sentry/core';
//# sourceMappingURL=index.instrumentopenaiclient.d.ts.map

View File

@@ -0,0 +1,150 @@
import { buildMatchFn } from "../../_lib/buildMatchFn.mjs";
import { buildMatchPatternFn } from "../../_lib/buildMatchPatternFn.mjs";
const matchOrdinalNumberPattern = /^(\d+)(\.)?/i;
const parseOrdinalNumberPattern = /\d+/i;
const matchEraPatterns = {
narrow: /^(mö|ms)/i,
abbreviated: /^(mö|ms)/i,
wide: /^(milattan önce|milattan sonra)/i,
};
const parseEraPatterns = {
any: [/(^mö|^milattan önce)/i, /(^ms|^milattan sonra)/i],
};
const matchQuarterPatterns = {
narrow: /^[1234]/i,
abbreviated: /^[1234]ç/i,
wide: /^((i|İ)lk|(i|İ)kinci|üçüncü|son) çeyrek/i,
};
const parseQuarterPatterns = {
any: [/1/i, /2/i, /3/i, /4/i],
abbreviated: [/1ç/i, /2ç/i, /3ç/i, /4ç/i],
wide: [
/^(i|İ)lk çeyrek/i,
/(i|İ)kinci çeyrek/i,
/üçüncü çeyrek/i,
/son çeyrek/i,
],
};
const matchMonthPatterns = {
narrow: /^[oşmnhtaek]/i,
abbreviated: /^(oca|şub|mar|nis|may|haz|tem|ağu|eyl|eki|kas|ara)/i,
wide: /^(ocak|şubat|mart|nisan|mayıs|haziran|temmuz|ağustos|eylül|ekim|kasım|aralık)/i,
};
const parseMonthPatterns = {
narrow: [
/^o/i,
/^ş/i,
/^m/i,
/^n/i,
/^m/i,
/^h/i,
/^t/i,
/^a/i,
/^e/i,
/^e/i,
/^k/i,
/^a/i,
],
any: [
/^o/i,
/^ş/i,
/^mar/i,
/^n/i,
/^may/i,
/^h/i,
/^t/i,
/^ağ/i,
/^ey/i,
/^ek/i,
/^k/i,
/^ar/i,
],
};
const matchDayPatterns = {
narrow: /^[psçc]/i,
short: /^(pz|pt|sa|ça|pe|cu|ct)/i,
abbreviated: /^(paz|pzt|sal|çar|per|cum|cts)/i,
wide: /^(pazar(?!tesi)|pazartesi|salı|çarşamba|perşembe|cuma(?!rtesi)|cumartesi)/i,
};
const parseDayPatterns = {
narrow: [/^p/i, /^p/i, /^s/i, /^ç/i, /^p/i, /^c/i, /^c/i],
any: [/^pz/i, /^pt/i, /^sa/i, /^ça/i, /^pe/i, /^cu/i, /^ct/i],
wide: [
/^pazar(?!tesi)/i,
/^pazartesi/i,
/^salı/i,
/^çarşamba/i,
/^perşembe/i,
/^cuma(?!rtesi)/i,
/^cumartesi/i,
],
};
const matchDayPeriodPatterns = {
narrow: /^(öö|ös|gy|ö|sa|ös|ak|ge)/i,
any: /^(ö\.?\s?[ös]\.?|öğleden sonra|gece yarısı|öğle|(sabah|öğ|akşam|gece)(leyin))/i,
};
const parseDayPeriodPatterns = {
any: {
am: /^ö\.?ö\.?/i,
pm: /^ö\.?s\.?/i,
midnight: /^(gy|gece yarısı)/i,
noon: /^öğ/i,
morning: /^sa/i,
afternoon: /^öğleden sonra/i,
evening: /^ak/i,
night: /^ge/i,
},
};
export const match = {
ordinalNumber: buildMatchPatternFn({
matchPattern: matchOrdinalNumberPattern,
parsePattern: parseOrdinalNumberPattern,
valueCallback: function (value) {
return parseInt(value, 10);
},
}),
era: buildMatchFn({
matchPatterns: matchEraPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseEraPatterns,
defaultParseWidth: "any",
}),
quarter: buildMatchFn({
matchPatterns: matchQuarterPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseQuarterPatterns,
defaultParseWidth: "any",
valueCallback: (index) => index + 1,
}),
month: buildMatchFn({
matchPatterns: matchMonthPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseMonthPatterns,
defaultParseWidth: "any",
}),
day: buildMatchFn({
matchPatterns: matchDayPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseDayPatterns,
defaultParseWidth: "any",
}),
dayPeriod: buildMatchFn({
matchPatterns: matchDayPeriodPatterns,
defaultMatchWidth: "any",
parsePatterns: parseDayPeriodPatterns,
defaultParseWidth: "any",
}),
};

View File

@@ -0,0 +1,185 @@
'use client';
import { c as _c } from "react/compiler-runtime";
import * as qs from 'qs-esm';
import { useEffect, useRef, useState } from 'react';
import { useLocale } from '../providers/Locale/index.js';
import { useTranslation } from '../providers/Translation/index.js';
import { requests } from '../utilities/api.js';
export const usePayloadAPI = (url, t0) => {
const $ = _c(30);
let t1;
if ($[0] !== t0) {
t1 = t0 === undefined ? {} : t0;
$[0] = t0;
$[1] = t1;
} else {
t1 = $[1];
}
const options = t1;
const {
initialData,
initialParams: t2
} = options;
let t3;
if ($[2] !== t2) {
t3 = t2 === undefined ? {} : t2;
$[2] = t2;
$[3] = t3;
} else {
t3 = $[3];
}
const initialParams = t3;
const {
i18n
} = useTranslation();
let t4;
if ($[4] !== initialData) {
t4 = initialData || {};
$[4] = initialData;
$[5] = t4;
} else {
t4 = $[5];
}
const [data, setData] = useState(t4);
const [params, setParams] = useState(initialParams);
const [isLoading, setIsLoading] = useState(!initialData);
const [isError, setIsError] = useState(false);
const {
code: locale
} = useLocale();
const hasInitialized = useRef(false);
let t5;
if ($[6] !== locale || $[7] !== params) {
t5 = qs.stringify({
locale,
...(typeof params === "object" ? params : {})
}, {
addQueryPrefix: true
});
$[6] = locale;
$[7] = params;
$[8] = t5;
} else {
t5 = $[8];
}
const search = t5;
let t6;
if ($[9] !== i18n.language || $[10] !== initialData || $[11] !== search || $[12] !== url) {
t6 = () => {
if (initialData && !hasInitialized.current) {
hasInitialized.current = true;
return;
}
const abortController = new AbortController();
const fetchData = async () => {
setIsError(false);
setIsLoading(true);
;
try {
const response = await requests.get(`${url}${search}`, {
headers: {
"Accept-Language": i18n.language
},
signal: abortController.signal
});
if (response.status > 201) {
setIsError(true);
}
const json = await response.json();
setData(json);
setIsLoading(false);
} catch (t7) {
if (!abortController.signal.aborted) {
setIsError(true);
setIsLoading(false);
}
}
};
if (url) {
fetchData();
} else {
setIsError(false);
setIsLoading(false);
}
return () => {
;
try {
abortController.abort();
} catch (t8) {
const _err = t8;
}
};
};
$[9] = i18n.language;
$[10] = initialData;
$[11] = search;
$[12] = url;
$[13] = t6;
} else {
t6 = $[13];
}
let t7;
if ($[14] !== i18n.language || $[15] !== initialData || $[16] !== locale || $[17] !== search || $[18] !== url) {
t7 = [url, locale, search, i18n.language, initialData];
$[14] = i18n.language;
$[15] = initialData;
$[16] = locale;
$[17] = search;
$[18] = url;
$[19] = t7;
} else {
t7 = $[19];
}
useEffect(t6, t7);
let t8;
let t9;
if ($[20] !== initialData) {
t8 = () => {
if (initialData && hasInitialized.current) {
setData(initialData);
}
};
t9 = [initialData];
$[20] = initialData;
$[21] = t8;
$[22] = t9;
} else {
t8 = $[21];
t9 = $[22];
}
useEffect(t8, t9);
let t10;
if ($[23] !== data || $[24] !== isError || $[25] !== isLoading) {
t10 = {
data,
isError,
isLoading
};
$[23] = data;
$[24] = isError;
$[25] = isLoading;
$[26] = t10;
} else {
t10 = $[26];
}
let t11;
if ($[27] === Symbol.for("react.memo_cache_sentinel")) {
t11 = {
setParams
};
$[27] = t11;
} else {
t11 = $[27];
}
let t12;
if ($[28] !== t10) {
t12 = [t10, t11];
$[28] = t10;
$[29] = t12;
} else {
t12 = $[29];
}
return t12;
};
//# sourceMappingURL=usePayloadAPI.js.map

View File

@@ -0,0 +1,457 @@
<div align="center">
<h1>babel-plugin-macros 🎣</h1>
<p>Allows you to build simple compile-time libraries</p>
</div>
---
<!-- prettier-ignore-start -->
[![Build Status][build-badge]][build]
[![Code Coverage][coverage-badge]][coverage]
[![version][version-badge]][package]
[![downloads][downloads-badge]][npmtrends]
[![MIT License][license-badge]][license]
[![All Contributors][all-contributors-badge]](#contributors-)
[![PRs Welcome][prs-badge]][prs]
[![Code of Conduct][coc-badge]][coc]
<!-- prettier-ignore-end -->
## The problem
Check out
[this guest post](https://babeljs.io/blog/2017/09/11/zero-config-with-babel-macros)
on the Babel.js blog for a complete write up on the problem, motivation, and
solution.
Currently, each babel plugin in the babel ecosystem requires that you configure
it individually. This is fine for things like language features, but can be
frustrating overhead for libraries that allow for compile-time code
transformation as an optimization.
## This solution
babel-plugin-macros defines a standard interface for libraries that want to use
compile-time code transformation without requiring the user to add a babel
plugin to their build system (other than `babel-plugin-macros`, which is ideally
already in place).
<details>
<summary>Expand for more details on the motivation</summary>
For instance, many css-in-js libraries have a css tagged template string
function:
```js
const styles = css`
.red {
color: red;
}
`
```
The function compiles your css into (for example) an object with generated class
names for each of the classes you defined in your css:
```js
console.log(styles) // { red: "1f-d34j8rn43y587t" }
```
This class name can be generated at runtime (in the browser), but this has some
disadvantages:
- There is cpu usage/time overhead; the client needs to run the code to generate
these classes every time the page loads
- There is code bundle size overhead; the client needs to receive a CSS parser
in order to generate these class names, and shipping this makes the amount of
js the client needs to parse larger.
To help solve those issues, many css-in-js libraries write their own babel
plugin that generates the class names at compile-time instead of runtime:
```js
// Before running through babel:
const styles = css`
.red {
color: red;
}
`
// After running through babel, with the library-specific plugin:
const styles = {red: '1f-d34j8rn43y587t'}
```
If the css-in-js library supported babel-plugin-macros instead, then they
wouldn't need their own babel plugin to compile these out; they could instead
rely on babel-plugin-macros to do it for them. So if a user already had
`babel-plugin-macros` installed and configured with babel, then they wouldn't
need to change their babel configuration to get the compile-time benefits of the
library. This would be most useful if the boilerplate they were using came with
`babel-plugin-macros` out of the box, which is true for
[`create-react-app`][cra].
Although css-in-js is the most common example, there are lots of other things
you could use `babel-plugin-macros` for, like:
- Compiling GraphQL fragments into objects so that the client doesn't need a
GraphQL parser
- Eval-ing out code at compile time that will be baked into the runtime code,
for instance to get a list of directories in the filesystem (see
[preval][preval])
</details>
## Table of Contents
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
- [Installation](#installation)
- [Usage](#usage)
- [User docs](#user-docs)
- [Author docs](#author-docs)
- [Caveats](#caveats)
- [FAQ](#faq)
- [How do I find available macros?](#how-do-i-find-available-macros)
- [What's the difference between babel plugins and macros?](#whats-the-difference-between-babel-plugins-and-macros)
- [In what order are macros executed?](#in-what-order-are-macros-executed)
- [Does it work with function calls only?](#does-it-work-with-function-calls-only)
- [How about implicit optimizations at compile time?](#how-about-implicit-optimizations-at-compile-time)
- [Inspiration](#inspiration)
- [Other Solutions](#other-solutions)
- [Issues](#issues)
- [🐛 Bugs](#-bugs)
- [💡 Feature Requests](#-feature-requests)
- [Contributors ✨](#contributors-)
- [LICENSE](#license)
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
## Installation
This module is distributed via [npm][npm] which is bundled with [node][node] and
should be installed as one of your project's `devDependencies`:
```
npm install --save-dev babel-plugin-macros
```
## Usage
> You may like to watch
> [this YouTube video](https://www.youtube.com/watch?v=1queadQ0048&list=PLV5CVI1eNcJgCrPH_e6d57KRUTiDZgs0u)
> to get an idea of what macros is and how it can be used.
### User docs
Are you trying to use `babel-plugin-macros`? Go to
[`other/docs/user.md`](other/docs/user.md).
### Author docs
Are you trying to make your own macros that works with `babel-plugin-macros`? Go
to [`other/docs/author.md`](other/docs/author.md). (you should probably read the
user docs too).
### Caveats
#### Babel cache problem
> **Note:** This issue is not present when used in Create React App.
Most of the time you'll probably be using this with the babel cache enabled in
webpack to rebuild faster. If your macro function is **not pure** which gets
different output with same code (e.g., IO side effects) it will cause recompile
mechanism fail. Unfortunately you'll also experience this problem while
developing your macro as well. If there's not a change to the source code that's
being transpiled, then babel will use the cache rather than running your macro
again.
For now, to force recompile the code you can simply add a cache busting comment
in the file:
```diff
import macro from 'non-pure.macro';
-// Do some changes of your code or
+// add a cache busting comment to force recompile.
macro('parameters');
```
This problem is still being worked on and is not unique to
`babel-plugin-macros`. For more details and workarounds, please check related
issues below:
- babel-plugin-preval:
[How to force recompile? #19](https://github.com/kentcdodds/babel-plugin-preval/issues/19)
- graphql.macro:
[Recompile problem (babel cache) #6](https://github.com/evenchange4/graphql.macro/issues/6)
- twin.macro:
[Can't change taliwind config #37](https://github.com/ben-rogerson/twin.macro/discussions/37)
## FAQ
### How do I find available macros?
You can write your own without publishing them to `npm`, but if you'd like to
see existing macros you can add to your project, then take a look at the
[Awesome babel macros](https://github.com/jgierer12/awesome-babel-macros)
repository.
Please add any you don't see listed!
### What's the difference between babel plugins and macros?
Let's use
[`babel-plugin-console`](https://www.npmjs.com/package/babel-plugin-console) as
an example.
If we used `babel-plugin-console`, it would look like this:
1. Add `babel-plugin-console` to `.babelrc`
2. Use it in a code:
```js
function add100(a) {
const oneHundred = 100
console.scope('Add 100 to another number')
return add(a, oneHundred)
}
function add(a, b) {
return a + b
}
```
When that code is run, the `scope` function does some pretty nifty things:
**Browser:**
![Browser console scoping add100](https://github.com/mattphillips/babel-plugin-console/raw/53536cba919d5be49d4f66d957769c07ca7a4207/assets/add100-chrome.gif)
**Node:**
<img alt="Node console scoping add100" src="https://github.com/mattphillips/babel-plugin-console/raw/53536cba919d5be49d4f66d957769c07ca7a4207/assets/add100-node.png" width="372" />
Instead, let's use the macro it's shipped with like this:
1. Add `babel-plugin-macros` to `.babelrc` (only once for all macros)
2. Use it in a code:
```js
import scope from 'babel-plugin-console/scope.macro'
function add100(a) {
const oneHundred = 100
scope('Add 100 to another number')
return add(a, oneHundred)
}
function add(a, b) {
return a + b
}
```
The result is exactly the same, but this approach has a few advantages:
**Advantages:**
- requires only one entry in `.babelrc` for all macros used in project. Add that
once and you can use all the macros you want
- toolkits (like [create-react-app][cra]) may already support
`babel-plugin-macros`, so no configuration is needed at all
- it's explicit. With `console.scope` people may be fooled that it's just a
normal `console` API when there's really a babel transpilation going on. When
you import `scope`, it's obvious that it's macro and does something with the
code at compile time. Some ESLint rules may also have issues with plugins that
look for "global" variables
- macros are safer and easier to write, because they receive exactly the AST
node to process
- If you misconfigure `babel-plugin-console` you wont find out until you run the
code. If you misconfigure `babel-plugin-macros` you'll get a compile-time
error.
**Drawbacks:**
- Cannot (should not) be used for implicit transpilations (like syntax plugins)
- Explicitness is more verbose. Which some people might consider a drawback...
### In what order are macros executed?
This is another advantage of `babel-plugin-macros` over regular plugins. The
user of the macro is in control of the ordering! The order of execution is the
same order as imported. The order of execution is clear, explicit and in full
control of the user:
```js
import preval from 'preval.macro'
import idx from 'idx.macro'
// preval macro is evaluated first, then idx
```
This differs from the current situation with babel plugins where it's
prohibitively difficult to control the order plugins run in a particular file.
### Does it work with function calls only?
No! Any AST node type is supported.
It can be tagged template literal:
```js
import eval from 'eval.macro'
const val = eval`7 * 6`
```
A function:
```js
import eval from 'eval.macro'
const val = eval('7 * 6')
```
JSX Element:
```js
import Eval from 'eval.macro'
const val = <Eval>7 * 6</Eval>
```
Really, anything...
See the [testing snapshot](src/__tests__/__snapshots__/index.js.snap) for more
examples.
### How about implicit optimizations at compile time?
All examples above were _explicit_ - a macro was imported and then evaluated
with a specific AST node.
Completely different story are _implicit_ babel plugins, like
[transform-react-constant-elements](https://babeljs.io/docs/plugins/transform-react-constant-elements/),
which process whole AST tree.
Explicit is often a better pattern than implicit because it requires others to
understand how things are globally configured. This is in this spirit are
`babel-plugin-macros` designed. However, some things _do_ need to be implicit,
and those kinds of babel plugins can't be turned into macros.
## Inspiration
- [threepointone/babel-plugin-macros](https://github.com/threepointone/babel-plugin-macros)
- [facebookincubator/create-react-app#2730][cra-issue]
Thank you to [@phpnode](https://github.com/phpnode) for donating the npm package
`babel-plugin-macros`.
## Other Solutions
- [sweetjs](http://sweetjs.org/)
## Issues
_Looking to contribute? Look for the [Good First Issue][good-first-issue]
label._
### 🐛 Bugs
Please file an issue for bugs, missing documentation, or unexpected behavior.
[**See Bugs**][bugs]
### 💡 Feature Requests
Please file an issue to suggest new features. Vote on feature requests by adding
a 👍. This helps maintainers prioritize what to work on.
[**See Feature Requests**][requests]
## Contributors ✨
Thanks goes to these people ([emoji key][emojis]):
<!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section -->
<!-- prettier-ignore-start -->
<!-- markdownlint-disable -->
<table>
<tr>
<td align="center"><a href="https://kentcdodds.com"><img src="https://avatars.githubusercontent.com/u/1500684?v=3?s=100" width="100px;" alt=""/><br /><sub><b>Kent C. Dodds</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=kentcdodds" title="Code">💻</a> <a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=kentcdodds" title="Documentation">📖</a> <a href="#infra-kentcdodds" title="Infrastructure (Hosting, Build-Tools, etc)">🚇</a> <a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=kentcdodds" title="Tests">⚠️</a></td>
<td align="center"><a href="https://github.com/threepointone"><img src="https://avatars1.githubusercontent.com/u/18808?v=3?s=100" width="100px;" alt=""/><br /><sub><b>Sunil Pai</b></sub></a><br /><a href="#ideas-threepointone" title="Ideas, Planning, & Feedback">🤔</a></td>
<td align="center"><a href="http://suchipi.com"><img src="https://avatars0.githubusercontent.com/u/1341513?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Lily Scott</b></sub></a><br /><a href="#question-suchipi" title="Answering Questions">💬</a> <a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=suchipi" title="Documentation">📖</a></td>
<td align="center"><a href="http://twitter.com/dralletje"><img src="https://avatars1.githubusercontent.com/u/767261?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Michiel Dral</b></sub></a><br /><a href="#ideas-dralletje" title="Ideas, Planning, & Feedback">🤔</a></td>
<td align="center"><a href="https://github.com/tkh44"><img src="https://avatars2.githubusercontent.com/u/662750?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Kye Hohenberger</b></sub></a><br /><a href="#ideas-tkh44" title="Ideas, Planning, & Feedback">🤔</a></td>
<td align="center"><a href="https://hamil.town"><img src="https://avatars1.githubusercontent.com/u/11481355?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Mitchell Hamilton</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=mitchellhamilton" title="Code">💻</a> <a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=mitchellhamilton" title="Tests">⚠️</a></td>
<td align="center"><a href="https://github.com/wKovacs64"><img src="https://avatars1.githubusercontent.com/u/1288694?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Justin Hall</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=wKovacs64" title="Documentation">📖</a></td>
</tr>
<tr>
<td align="center"><a href="https://github.com/PiereDome"><img src="https://avatars3.githubusercontent.com/u/1903016?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Brian Pedersen</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=PiereDome" title="Code">💻</a> <a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=PiereDome" title="Documentation">📖</a></td>
<td align="center"><a href="https://github.com/apalm"><img src="https://avatars3.githubusercontent.com/u/4495237?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Andrew Palm</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=apalm" title="Code">💻</a></td>
<td align="center"><a href="https://michaelhsu.tw/"><img src="https://avatars1.githubusercontent.com/u/1527371?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Michael Hsu</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=evenchange4" title="Documentation">📖</a> <a href="#plugin-evenchange4" title="Plugin/utility libraries">🔌</a></td>
<td align="center"><a href="https://github.com/citycide"><img src="https://avatars2.githubusercontent.com/u/16605186?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Bo Lingen</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=citycide" title="Code">💻</a></td>
<td align="center"><a href="https://github.com/tylerthehaas"><img src="https://avatars1.githubusercontent.com/u/11150235?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Tyler Haas</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=tylerthehaas" title="Documentation">📖</a></td>
<td align="center"><a href="https://github.com/FWeinb"><img src="https://avatars0.githubusercontent.com/u/1250430?v=4?s=100" width="100px;" alt=""/><br /><sub><b>FWeinb</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=FWeinb" title="Code">💻</a></td>
<td align="center"><a href="http://www.tomasehrlich.cz"><img src="https://avatars2.githubusercontent.com/u/827862?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Tomáš Ehrlich</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/issues?q=author%3Atricoder42" title="Bug reports">🐛</a> <a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=tricoder42" title="Code">💻</a></td>
</tr>
<tr>
<td align="center"><a href="https://github.com/jgierer12"><img src="https://avatars0.githubusercontent.com/u/4331946?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Jonas Gierer</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=jgierer12" title="Documentation">📖</a></td>
<td align="center"><a href="http://loicpadier.com"><img src="https://avatars2.githubusercontent.com/u/4009640?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Loïc Padier</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=lPadier" title="Code">💻</a></td>
<td align="center"><a href="https://www.pshrmn.com"><img src="https://avatars0.githubusercontent.com/u/1127037?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Paul Sherman</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=pshrmn" title="Code">💻</a></td>
<td align="center"><a href="http://burningpotato.com"><img src="https://avatars1.githubusercontent.com/u/540777?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Conrad Buck</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=conartist6" title="Code">💻</a> <a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=conartist6" title="Tests">⚠️</a> <a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=conartist6" title="Documentation">📖</a></td>
<td align="center"><a href="https://github.com/InvictusMB"><img src="https://avatars3.githubusercontent.com/u/3091209?v=4?s=100" width="100px;" alt=""/><br /><sub><b>InvictusMB</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=InvictusMB" title="Tests">⚠️</a></td>
<td align="center"><a href="https://codefund.io"><img src="https://avatars2.githubusercontent.com/u/12481?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Eric Berry</b></sub></a><br /><a href="#fundingFinding-coderberry" title="Funding Finding">🔍</a></td>
<td align="center"><a href="http://futagoza.github.io/"><img src="https://avatars1.githubusercontent.com/u/1943570?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Futago-za Ryuu</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=futagoza" title="Code">💻</a> <a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=futagoza" title="Tests">⚠️</a></td>
</tr>
<tr>
<td align="center"><a href="https://luc.im"><img src="https://avatars3.githubusercontent.com/u/6616955?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Luc</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=lucleray" title="Code">💻</a></td>
<td align="center"><a href="http://wintercounter.me"><img src="https://avatars2.githubusercontent.com/u/963776?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Victor Vincent</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=wintercounter" title="Code">💻</a></td>
<td align="center"><a href="http://mvasilkov.ovh"><img src="https://avatars3.githubusercontent.com/u/140257?v=4?s=100" width="100px;" alt=""/><br /><sub><b>я котик пур-пур</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=mvasilkov" title="Documentation">📖</a></td>
<td align="center"><a href="http://armandososa.com"><img src="https://avatars0.githubusercontent.com/u/139577?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Armando Sosa</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=soska" title="Documentation">📖</a></td>
<td align="center"><a href="https://github.com/matvp91"><img src="https://avatars3.githubusercontent.com/u/12699796?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Matthias</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=matvp91" title="Code">💻</a></td>
<td align="center"><a href="https://www.jovidecroock.com/"><img src="https://avatars3.githubusercontent.com/u/17125876?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Jovi De Croock</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=JoviDeCroock" title="Code">💻</a> <a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=JoviDeCroock" title="Tests">⚠️</a></td>
<td align="center"><a href="http://victorarowo.com"><img src="https://avatars0.githubusercontent.com/u/25545108?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Victor Arowo</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=VictorArowo" title="Documentation">📖</a></td>
</tr>
<tr>
<td align="center"><a href="https://twitter.com/alexandermchan"><img src="https://avatars.githubusercontent.com/u/1864372?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Alex Chan</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=alexanderchan" title="Documentation">📖</a></td>
<td align="center"><a href="https://probablyup.com"><img src="https://avatars.githubusercontent.com/u/570070?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Evan Jacobs</b></sub></a><br /><a href="https://github.com/kentcdodds/babel-plugin-macros/commits?author=probablyup" title="Code">💻</a></td>
</tr>
</table>
<!-- markdownlint-restore -->
<!-- prettier-ignore-end -->
<!-- ALL-CONTRIBUTORS-LIST:END -->
This project follows the [all-contributors][all-contributors] specification.
Contributions of any kind welcome!
## LICENSE
MIT
<!-- prettier-ignore-start -->
[npm]: https://www.npmjs.com
[node]: https://nodejs.org
[build-badge]: https://img.shields.io/github/workflow/status/kentcdodds/babel-plugin-macros/validate?logo=github&style=flat-square
[build]: https://github.com/kentcdodds/babel-plugin-macros/actions?query=workflow%3Avalidate
[coverage-badge]: https://img.shields.io/codecov/c/github/kentcdodds/babel-plugin-macros.svg?style=flat-square
[coverage]: https://codecov.io/github/kentcdodds/babel-plugin-macros
[version-badge]: https://img.shields.io/npm/v/babel-plugin-macros.svg?style=flat-square
[package]: https://www.npmjs.com/package/babel-plugin-macros
[downloads-badge]: https://img.shields.io/npm/dm/babel-plugin-macros.svg?style=flat-square
[npmtrends]: http://www.npmtrends.com/babel-plugin-macros
[license-badge]: https://img.shields.io/npm/l/babel-plugin-macros.svg?style=flat-square
[license]: https://github.com/kentcdodds/babel-plugin-macros/blob/main/LICENSE
[prs-badge]: https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square
[prs]: http://makeapullrequest.com
[coc-badge]: https://img.shields.io/badge/code%20of-conduct-ff69b4.svg?style=flat-square
[coc]: https://github.com/kentcdodds/babel-plugin-macros/blob/main/CODE_OF_CONDUCT.md
[emojis]: https://github.com/all-contributors/all-contributors#emoji-key
[all-contributors]: https://github.com/all-contributors/all-contributors
[all-contributors-badge]: https://img.shields.io/github/all-contributors/kentcdodds/babel-plugin-macros?color=orange&style=flat-square
[bugs]: https://github.com/kentcdodds/babel-plugin-macros/issues?utf8=%E2%9C%93&q=is%3Aissue+is%3Aopen+sort%3Acreated-desc+label%3Abug
[requests]: https://github.com/kentcdodds/babel-plugin-macros/issues?utf8=%E2%9C%93&q=is%3Aissue+is%3Aopen+sort%3Areactions-%2B1-desc+label%3Aenhancement
[good-first-issue]: https://github.com/kentcdodds/babel-plugin-macros/issues?utf8=%E2%9C%93&q=is%3Aissue+is%3Aopen+sort%3Areactions-%2B1-desc+label%3Aenhancement+label%3A%22good+first+issue%22
[preval]: https://github.com/kentcdodds/babel-plugin-preval
[cra]: https://github.com/facebook/create-react-app
[cra-issue]: https://github.com/facebook/create-react-app/issues/2730
<!-- prettier-ignore-end -->

View File

@@ -0,0 +1,83 @@
import * as origModule from '__SENTRY_NEXTJS_REQUEST_ASYNC_STORAGE_SHIM__';
import * as serverComponentModule from '__SENTRY_WRAPPING_TARGET_FILE__';
export * from '__SENTRY_WRAPPING_TARGET_FILE__';
import * as Sentry from '@sentry/nextjs';
// @ts-expect-error Because we cannot be sure if the RequestAsyncStorage module exists (it is not part of the Next.js public
// API) we use a shim if it doesn't exist. The logic for this is in the wrapping loader.
const asyncStorageModule = { ...origModule } ;
const requestAsyncStorage =
'workUnitAsyncStorage' in asyncStorageModule
? asyncStorageModule.workUnitAsyncStorage
: 'requestAsyncStorage' in asyncStorageModule
? asyncStorageModule.requestAsyncStorage
: undefined;
const serverComponent = serverComponentModule.default;
let wrappedServerComponent;
if (typeof serverComponent === 'function') {
// For some odd Next.js magic reason, `headers()` will not work if used inside `wrapServerComponentsWithSentry`.
// Current assumption is that Next.js applies some loader magic to userfiles, but not files in node_modules. This file
// is technically a userfile so it gets the loader magic applied.
wrappedServerComponent = new Proxy(serverComponent, {
apply: (originalFunction, thisArg, args) => {
let sentryTraceHeader = undefined;
let baggageHeader = undefined;
let headers = undefined;
// We try-catch here just in `requestAsyncStorage` is undefined since it may not be defined
try {
const requestAsyncStore = requestAsyncStorage?.getStore();
sentryTraceHeader = requestAsyncStore?.headers.get('sentry-trace') ?? undefined;
baggageHeader = requestAsyncStore?.headers.get('baggage') ?? undefined;
headers = requestAsyncStore?.headers;
} catch {
/** empty */
}
return Sentry.wrapServerComponentWithSentry(originalFunction, {
componentRoute: '__ROUTE__',
componentType: '__COMPONENT_TYPE__',
sentryTraceHeader,
baggageHeader,
headers,
}).apply(thisArg, args);
},
});
} else {
wrappedServerComponent = serverComponent;
}
const generateMetadata = serverComponentModule.generateMetadata
? Sentry.wrapGenerationFunctionWithSentry(serverComponentModule.generateMetadata, {
componentRoute: '__ROUTE__',
componentType: '__COMPONENT_TYPE__',
generationFunctionIdentifier: 'generateMetadata',
requestAsyncStorage,
})
: undefined;
const generateImageMetadata = serverComponentModule.generateImageMetadata
? Sentry.wrapGenerationFunctionWithSentry(serverComponentModule.generateImageMetadata, {
componentRoute: '__ROUTE__',
componentType: '__COMPONENT_TYPE__',
generationFunctionIdentifier: 'generateImageMetadata',
requestAsyncStorage,
})
: undefined;
const generateViewport = serverComponentModule.generateViewport
? Sentry.wrapGenerationFunctionWithSentry(serverComponentModule.generateViewport, {
componentRoute: '__ROUTE__',
componentType: '__COMPONENT_TYPE__',
generationFunctionIdentifier: 'generateViewport',
requestAsyncStorage,
})
: undefined;
const wrappedServerComponent_default = wrappedServerComponent;
export { wrappedServerComponent_default as default, generateImageMetadata, generateMetadata, generateViewport };

View File

@@ -0,0 +1,46 @@
import { constructFrom } from "../../../constructFrom.js";
import { getTimezoneOffsetInMilliseconds } from "../../../_lib/getTimezoneOffsetInMilliseconds.js";
import { timezonePatterns } from "../constants.js";
import { Parser } from "../Parser.js";
import { parseTimezonePattern } from "../utils.js";
// Timezone (ISO-8601)
export class ISOTimezoneParser extends Parser {
priority = 10;
parse(dateString, token) {
switch (token) {
case "x":
return parseTimezonePattern(
timezonePatterns.basicOptionalMinutes,
dateString,
);
case "xx":
return parseTimezonePattern(timezonePatterns.basic, dateString);
case "xxxx":
return parseTimezonePattern(
timezonePatterns.basicOptionalSeconds,
dateString,
);
case "xxxxx":
return parseTimezonePattern(
timezonePatterns.extendedOptionalSeconds,
dateString,
);
case "xxx":
default:
return parseTimezonePattern(timezonePatterns.extended, dateString);
}
}
set(date, flags, value) {
if (flags.timestampIsSet) return date;
return constructFrom(
date,
date.getTime() - getTimezoneOffsetInMilliseconds(date) - value,
);
}
incompatibleTokens = ["t", "T", "X"];
}

View File

@@ -0,0 +1,6 @@
/// <reference types="react" />
import type { InternalContextDescriptor, PublicContextDescriptor } from './types';
export declare const defaultPublicContext: PublicContextDescriptor;
export declare const defaultInternalContext: InternalContextDescriptor;
export declare const InternalContext: import("react").Context<InternalContextDescriptor>;
export declare const PublicContext: import("react").Context<PublicContextDescriptor>;

View File

@@ -0,0 +1,4 @@
export {
useInsertionEffectAlwaysWithSyncFallback,
useInsertionEffectWithLayoutFallback
} from "./emotion-use-insertion-effect-with-fallbacks.edge-light.cjs.js";

View File

@@ -0,0 +1,90 @@
import { normalizeDates } from "./_lib/normalizeDates.js";
import { addDays } from "./addDays.js";
import { differenceInCalendarDays } from "./differenceInCalendarDays.js";
import { isSameDay } from "./isSameDay.js";
import { isValid } from "./isValid.js";
import { isWeekend } from "./isWeekend.js";
/**
* The {@link differenceInBusinessDays} function options.
*/
/**
* @name differenceInBusinessDays
* @category Day Helpers
* @summary Get the number of business days between the given dates.
*
* @description
* Get the number of business day periods between the given dates.
* Business days being days that aren't in the weekend.
* Like `differenceInCalendarDays`, the function removes the times from
* the dates before calculating the difference.
*
* @param laterDate - The later date
* @param earlierDate - The earlier date
* @param options - An object with options
*
* @returns The number of business days
*
* @example
* // How many business days are between
* // 10 January 2014 and 20 July 2014?
* const result = differenceInBusinessDays(
* new Date(2014, 6, 20),
* new Date(2014, 0, 10)
* )
* //=> 136
*
* // How many business days are between
* // 30 November 2021 and 1 November 2021?
* const result = differenceInBusinessDays(
* new Date(2021, 10, 30),
* new Date(2021, 10, 1)
* )
* //=> 21
*
* // How many business days are between
* // 1 November 2021 and 1 December 2021?
* const result = differenceInBusinessDays(
* new Date(2021, 10, 1),
* new Date(2021, 11, 1)
* )
* //=> -22
*
* // How many business days are between
* // 1 November 2021 and 1 November 2021 ?
* const result = differenceInBusinessDays(
* new Date(2021, 10, 1),
* new Date(2021, 10, 1)
* )
* //=> 0
*/
export function differenceInBusinessDays(laterDate, earlierDate, options) {
const [laterDate_, earlierDate_] = normalizeDates(
options?.in,
laterDate,
earlierDate,
);
if (!isValid(laterDate_) || !isValid(earlierDate_)) return NaN;
const diff = differenceInCalendarDays(laterDate_, earlierDate_);
const sign = diff < 0 ? -1 : 1;
const weeks = Math.trunc(diff / 7);
let result = weeks * 5;
let movingDate = addDays(earlierDate_, weeks * 7);
// the loop below will run at most 6 times to account for the remaining days that don't makeup a full week
while (!isSameDay(laterDate_, movingDate)) {
// sign is used to account for both negative and positive differences
result += isWeekend(movingDate, options) ? 0 : sign;
movingDate = addDays(movingDate, sign);
}
// Prevent negative zero
return result === 0 ? 0 : result;
}
// Fallback for modularized imports:
export default differenceInBusinessDays;

View File

@@ -0,0 +1,26 @@
/**
* @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 HandPlatter = createLucideIcon("HandPlatter", [
["path", { d: "M12 3V2", key: "ar7q03" }],
["path", { d: "M5 10a7.1 7.1 0 0 1 14 0", key: "1t9y3n" }],
["path", { d: "M4 10h16", key: "img6z1" }],
["path", { d: "M2 14h12a2 2 0 1 1 0 4h-2", key: "loyjft" }],
[
"path",
{
d: "m15.4 17.4 3.2-2.8a2 2 0 0 1 2.8 2.9l-3.6 3.3c-.7.8-1.7 1.2-2.8 1.2h-4c-1.1 0-2.1-.4-2.8-1.2L5 18",
key: "1rixiy"
}
],
["path", { d: "M5 14v7H2", key: "3mujks" }]
]);
export { HandPlatter as default };
//# sourceMappingURL=hand-platter.js.map

View File

@@ -0,0 +1,3 @@
# Security
Please email [@ljharb](https://github.com/ljharb) or see https://tidelift.com/security if you have a potential security vulnerability to report.

View File

@@ -0,0 +1,154 @@
import { buildMatchFn } from "../../_lib/buildMatchFn.mjs";
import { buildMatchPatternFn } from "../../_lib/buildMatchPatternFn.mjs";
const matchOrdinalNumberPattern = /^(\d+)/i;
const parseOrdinalNumberPattern = /\d+/i;
const matchEraPatterns = {
narrow: /^(tcn|scn)/i,
abbreviated: /^(trước CN|sau CN)/i,
wide: /^(trước Công Nguyên|sau Công Nguyên)/i,
};
const parseEraPatterns = {
any: [/^t/i, /^s/i],
};
const matchQuarterPatterns = {
narrow: /^([1234]|i{1,3}v?)/i,
abbreviated: /^q([1234]|i{1,3}v?)/i,
wide: /^quý ([1234]|i{1,3}v?)/i,
};
const parseQuarterPatterns = {
any: [/(1|i)$/i, /(2|ii)$/i, /(3|iii)$/i, /(4|iv)$/i],
};
const matchMonthPatterns = {
// month number may contain leading 0, 'thg' prefix may have space, underscore or empty before number
// note the order of '1' since it is a sub-string of '10', so must be lower priority
narrow: /^(0?[2-9]|10|11|12|0?1)/i,
// note the order of 'thg 1' since it is sub-string of 'thg 10', so must be lower priority
abbreviated: /^thg[ _]?(0?[1-9](?!\d)|10|11|12)/i,
// note the order of 'Mười' since it is sub-string of Mười Một, so must be lower priority
wide: /^tháng ?(Một|Hai|Ba|Tư|Năm|Sáu|Bảy|Tám|Chín|Mười|Mười ?Một|Mười ?Hai|0?[1-9](?!\d)|10|11|12)/i,
};
const parseMonthPatterns = {
narrow: [
/0?1$/i,
/0?2/i,
/3/,
/4/,
/5/,
/6/,
/7/,
/8/,
/9/,
/10/,
/11/,
/12/,
],
abbreviated: [
/^thg[ _]?0?1(?!\d)/i,
/^thg[ _]?0?2/i,
/^thg[ _]?0?3/i,
/^thg[ _]?0?4/i,
/^thg[ _]?0?5/i,
/^thg[ _]?0?6/i,
/^thg[ _]?0?7/i,
/^thg[ _]?0?8/i,
/^thg[ _]?0?9/i,
/^thg[ _]?10/i,
/^thg[ _]?11/i,
/^thg[ _]?12/i,
],
wide: [
/^tháng ?(Một|0?1(?!\d))/i,
/^tháng ?(Hai|0?2)/i,
/^tháng ?(Ba|0?3)/i,
/^tháng ?(Tư|0?4)/i,
/^tháng ?(Năm|0?5)/i,
/^tháng ?(Sáu|0?6)/i,
/^tháng ?(Bảy|0?7)/i,
/^tháng ?(Tám|0?8)/i,
/^tháng ?(Chín|0?9)/i,
/^tháng ?(Mười|10)/i,
/^tháng ?(Mười ?Một|11)/i,
/^tháng ?(Mười ?Hai|12)/i,
],
};
const matchDayPatterns = {
narrow: /^(CN|T2|T3|T4|T5|T6|T7)/i,
short: /^(CN|Th ?2|Th ?3|Th ?4|Th ?5|Th ?6|Th ?7)/i,
abbreviated: /^(CN|Th ?2|Th ?3|Th ?4|Th ?5|Th ?6|Th ?7)/i,
wide: /^(Chủ ?Nhật|Chúa ?Nhật|thứ ?Hai|thứ ?Ba|thứ ?Tư|thứ ?Năm|thứ ?Sáu|thứ ?Bảy)/i,
};
const parseDayPatterns = {
narrow: [/CN/i, /2/i, /3/i, /4/i, /5/i, /6/i, /7/i],
short: [/CN/i, /2/i, /3/i, /4/i, /5/i, /6/i, /7/i],
abbreviated: [/CN/i, /2/i, /3/i, /4/i, /5/i, /6/i, /7/i],
wide: [/(Chủ|Chúa) ?Nhật/i, /Hai/i, /Ba/i, /Tư/i, /Năm/i, /Sáu/i, /Bảy/i],
};
const matchDayPeriodPatterns = {
narrow: /^(a|p|nửa đêm|trưa|(giờ) (sáng|chiều|tối|đêm))/i,
abbreviated: /^(am|pm|nửa đêm|trưa|(giờ) (sáng|chiều|tối|đêm))/i,
wide: /^(ch[^i]*|sa|nửa đêm|trưa|(giờ) (sáng|chiều|tối|đêm))/i,
};
const parseDayPeriodPatterns = {
any: {
am: /^(a|sa)/i,
pm: /^(p|ch[^i]*)/i,
midnight: /nửa đêm/i,
noon: /trưa/i,
morning: /sáng/i,
afternoon: /chiều/i,
evening: /tối/i,
night: /^đêm/i,
},
};
export const match = {
ordinalNumber: buildMatchPatternFn({
matchPattern: matchOrdinalNumberPattern,
parsePattern: parseOrdinalNumberPattern,
valueCallback: (value) => parseInt(value, 10),
}),
era: buildMatchFn({
matchPatterns: matchEraPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseEraPatterns,
defaultParseWidth: "any",
}),
quarter: buildMatchFn({
matchPatterns: matchQuarterPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseQuarterPatterns,
defaultParseWidth: "any",
valueCallback: (index) => index + 1,
}),
month: buildMatchFn({
matchPatterns: matchMonthPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseMonthPatterns,
defaultParseWidth: "wide",
}),
day: buildMatchFn({
matchPatterns: matchDayPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseDayPatterns,
defaultParseWidth: "wide",
}),
dayPeriod: buildMatchFn({
matchPatterns: matchDayPeriodPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseDayPeriodPatterns,
defaultParseWidth: "any",
}),
};

View File

@@ -0,0 +1,23 @@
/**
* @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 Eraser = createLucideIcon("Eraser", [
[
"path",
{
d: "m7 21-4.3-4.3c-1-1-1-2.5 0-3.4l9.6-9.6c1-1 2.5-1 3.4 0l5.6 5.6c1 1 1 2.5 0 3.4L13 21",
key: "182aya"
}
],
["path", { d: "M22 21H7", key: "t4ddhn" }],
["path", { d: "m5 11 9 9", key: "1mo9qw" }]
]);
export { Eraser as default };
//# sourceMappingURL=eraser.js.map

View File

@@ -0,0 +1,19 @@
/**
* @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 MonitorPause = createLucideIcon("MonitorPause", [
["path", { d: "M10 13V7", key: "1u13u9" }],
["path", { d: "M14 13V7", key: "1vj9om" }],
["rect", { width: "20", height: "14", x: "2", y: "3", rx: "2", key: "48i651" }],
["path", { d: "M12 17v4", key: "1riwvh" }],
["path", { d: "M8 21h8", key: "1ev6f3" }]
]);
export { MonitorPause as default };
//# sourceMappingURL=monitor-pause.js.map

View File

@@ -0,0 +1,50 @@
import "../types/number.js";
const PART_TYPES_TO_COLLAPSE = new Set([
"unit",
"exponentMinusSign",
"minusSign",
"plusSign",
"percentSign",
"exponentSeparator",
"percent",
"percentSign",
"currency",
"literal"
]);
/**
* https://tc39.es/ecma402/#sec-collapsenumberrange
* LDML: https://unicode-org.github.io/cldr/ldml/tr35-numbers.html#collapsing-number-ranges
*/
export function CollapseNumberRange(numberFormat, result, { getInternalSlots }) {
const internalSlots = getInternalSlots(numberFormat);
const symbols = internalSlots.dataLocaleData.numbers.symbols[internalSlots.numberingSystem];
const rangeSignRegex = new RegExp(`s?[${symbols.rangeSign}]s?`);
const rangeSignIndex = result.findIndex((r) => r.type === "literal" && rangeSignRegex.test(r.value));
let prefixSignParts = [];
for (let i = rangeSignIndex - 1; i >= 0; i--) {
if (!PART_TYPES_TO_COLLAPSE.has(result[i].type)) {
break;
}
prefixSignParts.unshift(result[i]);
}
// Don't collapse if it's a single code point
if (Array.from(prefixSignParts.map((p) => p.value).join("")).length > 1) {
const newResult = Array.from(result);
newResult.splice(rangeSignIndex - prefixSignParts.length, prefixSignParts.length);
return newResult;
}
let suffixSignParts = [];
for (let i = rangeSignIndex + 1; i < result.length; i++) {
if (!PART_TYPES_TO_COLLAPSE.has(result[i].type)) {
break;
}
suffixSignParts.push(result[i]);
}
// Don't collapse if it's a single code point
if (Array.from(suffixSignParts.map((p) => p.value).join("")).length > 1) {
const newResult = Array.from(result);
newResult.splice(rangeSignIndex + 1, suffixSignParts.length);
return newResult;
}
return result;
}

View File

@@ -0,0 +1 @@
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/elements/ReactSelect/Control/index.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,cAAc,CAAA;AAEhD,OAAO,KAAK,MAAM,OAAO,CAAA;AAGzB,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,aAAa,CAAA;AAEzC,eAAO,MAAM,OAAO,EAAE,KAAK,CAAC,EAAE,CAAC,YAAY,CAAC,MAAM,EAAE,GAAG,CAAC,CAqCvD,CAAA"}

View File

@@ -0,0 +1,2 @@
export { unleashIntegration } from './integration';
//# sourceMappingURL=index.d.ts.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"span_context.js","sourceRoot":"","sources":["../../../src/trace/span_context.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG","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 { TraceState } from './trace_state';\n\n/**\n * A SpanContext represents the portion of a {@link Span} which must be\n * serialized and propagated along side of a {@link Baggage}.\n */\nexport interface SpanContext {\n /**\n * The ID of the trace that this span belongs to. It is worldwide unique\n * with practically sufficient probability by being made as 16 randomly\n * generated bytes, encoded as a 32 lowercase hex characters corresponding to\n * 128 bits.\n */\n traceId: string;\n /**\n * The ID of the Span. It is globally unique with practically sufficient\n * probability by being made as 8 randomly generated bytes, encoded as a 16\n * lowercase hex characters corresponding to 64 bits.\n */\n spanId: string;\n /**\n * Only true if the SpanContext was propagated from a remote parent.\n */\n isRemote?: boolean;\n /**\n * Trace flags to propagate.\n *\n * It is represented as 1 byte (bitmap). Bit to represent whether trace is\n * sampled or not. When set, the least significant bit documents that the\n * caller may have recorded trace data. A caller who does not record trace\n * data out-of-band leaves this flag unset.\n *\n * see {@link TraceFlags} for valid flag values.\n */\n traceFlags: number;\n /**\n * Tracing-system-specific info to propagate.\n *\n * The tracestate field value is a `list` as defined below. The `list` is a\n * series of `list-members` separated by commas `,`, and a list-member is a\n * key/value pair separated by an equals sign `=`. Spaces and horizontal tabs\n * surrounding `list-members` are ignored. There can be a maximum of 32\n * `list-members` in a `list`.\n * More Info: https://www.w3.org/TR/trace-context/#tracestate-field\n *\n * Examples:\n * Single tracing system (generic format):\n * tracestate: rojo=00f067aa0ba902b7\n * Multiple tracing systems (with different formatting):\n * tracestate: rojo=00f067aa0ba902b7,congo=t61rcWkgMzE\n */\n traceState?: TraceState;\n}\n"]}

View File

@@ -0,0 +1,33 @@
import { entityKind } from "../entity.js";
class GelPolicy {
constructor(name, config) {
this.name = name;
if (config) {
this.as = config.as;
this.for = config.for;
this.to = config.to;
this.using = config.using;
this.withCheck = config.withCheck;
}
}
static [entityKind] = "GelPolicy";
as;
for;
to;
using;
withCheck;
/** @internal */
_linkedTable;
link(table) {
this._linkedTable = table;
return this;
}
}
function gelPolicy(name, config) {
return new GelPolicy(name, config);
}
export {
GelPolicy,
gelPolicy
};
//# sourceMappingURL=policies.js.map

View File

@@ -0,0 +1,17 @@
import { DirectusExtension } from "../../../schema/extension.cjs";
import { NestedPartial } from "../../../types/utils.cjs";
import { RestCommand } from "../../types.cjs";
//#region src/rest/commands/update/extensions.d.ts
/**
* Update an existing extension.
* @param bundle - Bundle this extension is in
* @param name - Unique name of the extension
* @param data - Partial extension object
* @returns Returns the extension that was updated
*/
declare const updateExtension: <Schema>(bundle: string | null, name: string, data: NestedPartial<DirectusExtension<Schema>>) => RestCommand<DirectusExtension<Schema>, Schema>;
//#endregion
export { updateExtension };
//# sourceMappingURL=extensions.d.cts.map

View File

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

View File

@@ -0,0 +1,154 @@
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
const diagnosticsChannel = require('node:diagnostics_channel');
const api = require('@opentelemetry/api');
const core$1 = require('@opentelemetry/core');
const instrumentation = require('@opentelemetry/instrumentation');
const core = require('@sentry/core');
const debugBuild = require('../../debug-build.js');
const getRequestUrl = require('../../utils/getRequestUrl.js');
const constants = require('./constants.js');
const outgoingHttpRequest = require('../../utils/outgoingHttpRequest.js');
/**
* This custom HTTP instrumentation is used to isolate incoming requests and annotate them with additional information.
* It does not emit any spans.
*
* The reason this is isolated from the OpenTelemetry instrumentation is that users may overwrite this,
* which would lead to Sentry not working as expected.
*
* Important note: Contrary to other OTEL instrumentation, this one cannot be unwrapped.
* It only does minimal things though and does not emit any spans.
*
* This is heavily inspired & adapted from:
* https://github.com/open-telemetry/opentelemetry-js/blob/f8ab5592ddea5cba0a3b33bf8d74f27872c0367f/experimental/packages/opentelemetry-instrumentation-http/src/http.ts
*/
class SentryHttpInstrumentation extends instrumentation.InstrumentationBase {
constructor(config = {}) {
super(constants.INSTRUMENTATION_NAME, core.SDK_VERSION, config);
this._propagationDecisionMap = new core.LRUMap(100);
this._ignoreOutgoingRequestsMap = new WeakMap();
}
/** @inheritdoc */
init() {
// We register handlers when either http or https is instrumented
// but we only want to register them once, whichever is loaded first
let hasRegisteredHandlers = false;
const onHttpClientResponseFinish = ((_data) => {
const data = _data ;
this._onOutgoingRequestFinish(data.request, data.response);
}) ;
const onHttpClientRequestError = ((_data) => {
const data = _data ;
this._onOutgoingRequestFinish(data.request, undefined);
}) ;
const onHttpClientRequestCreated = ((_data) => {
const data = _data ;
this._onOutgoingRequestCreated(data.request);
}) ;
const wrap = (moduleExports) => {
if (hasRegisteredHandlers) {
return moduleExports;
}
hasRegisteredHandlers = true;
diagnosticsChannel.subscribe('http.client.response.finish', onHttpClientResponseFinish);
// When an error happens, we still want to have a breadcrumb
// In this case, `http.client.response.finish` is not triggered
diagnosticsChannel.subscribe('http.client.request.error', onHttpClientRequestError);
// NOTE: This channel only exist since Node 22
// Before that, outgoing requests are not patched
// and trace headers are not propagated, sadly.
if (this.getConfig().propagateTraceInOutgoingRequests) {
diagnosticsChannel.subscribe('http.client.request.created', onHttpClientRequestCreated);
}
return moduleExports;
};
const unwrap = () => {
diagnosticsChannel.unsubscribe('http.client.response.finish', onHttpClientResponseFinish);
diagnosticsChannel.unsubscribe('http.client.request.error', onHttpClientRequestError);
diagnosticsChannel.unsubscribe('http.client.request.created', onHttpClientRequestCreated);
};
/**
* You may be wondering why we register these diagnostics-channel listeners
* in such a convoluted way (as InstrumentationNodeModuleDefinition...)˝,
* instead of simply subscribing to the events once in here.
* The reason for this is timing semantics: These functions are called once the http or https module is loaded.
* If we'd subscribe before that, there seem to be conflicts with the OTEL native instrumentation in some scenarios,
* especially the "import-on-top" pattern of setting up ESM applications.
*/
return [
new instrumentation.InstrumentationNodeModuleDefinition('http', ['*'], wrap, unwrap),
new instrumentation.InstrumentationNodeModuleDefinition('https', ['*'], wrap, unwrap),
];
}
/**
* This is triggered when an outgoing request finishes.
* It has access to the final request and response objects.
*/
_onOutgoingRequestFinish(request, response) {
debugBuild.DEBUG_BUILD && core.debug.log(constants.INSTRUMENTATION_NAME, 'Handling finished outgoing request');
const _breadcrumbs = this.getConfig().breadcrumbs;
const breadCrumbsEnabled = typeof _breadcrumbs === 'undefined' ? true : _breadcrumbs;
// Note: We cannot rely on the map being set by `_onOutgoingRequestCreated`, because that is not run in Node <22
const shouldIgnore = this._ignoreOutgoingRequestsMap.get(request) ?? this._shouldIgnoreOutgoingRequest(request);
this._ignoreOutgoingRequestsMap.set(request, shouldIgnore);
if (breadCrumbsEnabled && !shouldIgnore) {
outgoingHttpRequest.addRequestBreadcrumb(request, response);
}
}
/**
* This is triggered when an outgoing request is created.
* It has access to the request object, and can mutate it before the request is sent.
*/
_onOutgoingRequestCreated(request) {
const shouldIgnore = this._ignoreOutgoingRequestsMap.get(request) ?? this._shouldIgnoreOutgoingRequest(request);
this._ignoreOutgoingRequestsMap.set(request, shouldIgnore);
if (shouldIgnore) {
return;
}
outgoingHttpRequest.addTracePropagationHeadersToOutgoingRequest(request, this._propagationDecisionMap);
}
/**
* Check if the given outgoing request should be ignored.
*/
_shouldIgnoreOutgoingRequest(request) {
if (core$1.isTracingSuppressed(api.context.active())) {
return true;
}
const ignoreOutgoingRequests = this.getConfig().ignoreOutgoingRequests;
if (!ignoreOutgoingRequests) {
return false;
}
const options = outgoingHttpRequest.getRequestOptions(request);
const url = getRequestUrl.getRequestUrl(request);
return ignoreOutgoingRequests(url, options);
}
}
exports.SentryHttpInstrumentation = SentryHttpInstrumentation;
//# sourceMappingURL=SentryHttpInstrumentation.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 SquareLibrary = createLucideIcon("SquareLibrary", [
["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", key: "afitv7" }],
["path", { d: "M7 7v10", key: "d5nglc" }],
["path", { d: "M11 7v10", key: "pptsnr" }],
["path", { d: "m15 7 2 10", key: "1m7qm5" }]
]);
export { SquareLibrary as default };
//# sourceMappingURL=square-library.js.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"isEditing.d.ts","sourceRoot":"","sources":["../../src/utilities/isEditing.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,SAAS,wCAInB;IACD,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAAA;CACrB,KAAG,OAA0D,CAAA"}

View File

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

View File

@@ -0,0 +1 @@
{"version":3,"sources":["../../../src/resolvers/globals/findVersionByID.ts"],"sourcesContent":["import type { GraphQLResolveInfo } from 'graphql'\nimport type { Document, SanitizedGlobalConfig } from 'payload'\n\nimport { findVersionByIDOperationGlobal, isolateObjectProperty } from 'payload'\n\nimport type { Context } from '../types.js'\n\nimport { buildSelectForCollection } from '../../utilities/select.js'\n\nexport type Resolver = (\n _: unknown,\n args: {\n draft?: boolean\n fallbackLocale?: string\n id: number | string\n locale?: string\n select?: boolean\n },\n context: Context,\n info: GraphQLResolveInfo\n) => Promise<Document>\n\nexport function findVersionByID(globalConfig: SanitizedGlobalConfig): Resolver {\n return async function resolver(_, args, context, info) {\n const req = context.req = isolateObjectProperty(context.req, ['locale', 'fallbackLocale', 'transactionID'])\n const select = context.select = args.select ? buildSelectForCollection(info) : undefined\n\n req.locale = args.locale || req.locale\n req.fallbackLocale = args.fallbackLocale || req.fallbackLocale\n req.query = req.query || {}\n\n const options = {\n id: args.id,\n depth: 0,\n draft: args.draft,\n globalConfig,\n req,\n select,\n }\n\n const result = await findVersionByIDOperationGlobal(options)\n return result\n }\n}\n"],"names":["findVersionByIDOperationGlobal","isolateObjectProperty","buildSelectForCollection","findVersionByID","globalConfig","resolver","_","args","context","info","req","select","undefined","locale","fallbackLocale","query","options","id","depth","draft","result"],"mappings":"AAGA,SAASA,8BAA8B,EAAEC,qBAAqB,QAAQ,UAAS;AAI/E,SAASC,wBAAwB,QAAQ,4BAA2B;AAepE,OAAO,SAASC,gBAAgBC,YAAmC;IACjE,OAAO,eAAeC,SAASC,CAAC,EAAEC,IAAI,EAAEC,OAAO,EAAEC,IAAI;QACnD,MAAMC,MAAMF,QAAQE,GAAG,GAAGT,sBAAsBO,QAAQE,GAAG,EAAE;YAAC;YAAU;YAAkB;SAAgB;QAC1G,MAAMC,SAASH,QAAQG,MAAM,GAAGJ,KAAKI,MAAM,GAAGT,yBAAyBO,QAAQG;QAE/EF,IAAIG,MAAM,GAAGN,KAAKM,MAAM,IAAIH,IAAIG,MAAM;QACtCH,IAAII,cAAc,GAAGP,KAAKO,cAAc,IAAIJ,IAAII,cAAc;QAC9DJ,IAAIK,KAAK,GAAGL,IAAIK,KAAK,IAAI,CAAC;QAE1B,MAAMC,UAAU;YACdC,IAAIV,KAAKU,EAAE;YACXC,OAAO;YACPC,OAAOZ,KAAKY,KAAK;YACjBf;YACAM;YACAC;QACF;QAEA,MAAMS,SAAS,MAAMpB,+BAA+BgB;QACpD,OAAOI;IACT;AACF"}

View File

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

View File

@@ -0,0 +1,35 @@
import type { ContextOptions, DateArg } from "./types.js";
/**
* The {@link startOfQuarter} function options.
*/
export interface StartOfQuarterOptions<DateType extends Date = Date>
extends ContextOptions<DateType> {}
/**
* @name startOfQuarter
* @category Quarter Helpers
* @summary Return the start of a year quarter for the given date.
*
* @description
* Return the start of a year quarter 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 - The options
*
* @returns The start of a quarter
*
* @example
* // The start of a quarter for 2 September 2014 11:55:00:
* const result = startOfQuarter(new Date(2014, 8, 2, 11, 55, 0))
* //=> Tue Jul 01 2014 00:00:00
*/
export declare function startOfQuarter<
DateType extends Date,
ResultDate extends Date = DateType,
>(
date: DateArg<DateType>,
options?: StartOfQuarterOptions<ResultDate> | undefined,
): ResultDate;

View File

@@ -0,0 +1,277 @@
import { fieldAffectsData, fieldShouldBeLocalized, tabHasName } from '../fields/config/types.js';
/**
* Merges data from dataWithLocales onto docWithLocales for specified locales.
* For localized fields, merges only the specified locales while preserving others.
* For non-localized fields, keeps existing values from docWithLocales unchanged.
* Returns a new object without mutating the original.
*/ export function mergeLocalizedData({ configBlockReferences, dataWithLocales, docWithLocales, fields, parentIsLocalized = false, selectedLocales }) {
if (!docWithLocales || typeof docWithLocales !== 'object') {
return dataWithLocales || docWithLocales;
}
const result = {
...docWithLocales
};
for (const field of fields){
if (fieldAffectsData(field)) {
// If the parent is localized, all children are inherently "localized"
if (parentIsLocalized && dataWithLocales[field.name]) {
result[field.name] = dataWithLocales[field.name];
continue;
}
const fieldIsLocalized = fieldShouldBeLocalized({
field,
parentIsLocalized
});
switch(field.type){
case 'array':
{
if (field.name in dataWithLocales) {
const newValue = dataWithLocales[field.name];
const existingValue = docWithLocales[field.name];
if (fieldIsLocalized) {
// If localized, handle locale keys
if (newValue && typeof newValue === 'object' && !Array.isArray(newValue)) {
const updatedArray = {
...existingValue || {}
};
for (const locale of selectedLocales){
if (locale in newValue) {
updatedArray[locale] = newValue[locale];
}
}
result[field.name] = updatedArray;
} else {
// Preserve existing value if new value is not a valid object
result[field.name] = existingValue;
}
} else if (Array.isArray(newValue)) {
// Non-localized array - still process children for any localized fields
result[field.name] = newValue.map((newItem, index)=>{
const existingItem = existingValue?.[index] || {};
return mergeLocalizedData({
configBlockReferences,
dataWithLocales: newItem,
docWithLocales: existingItem,
fields: field.fields,
parentIsLocalized,
selectedLocales
});
});
}
}
break;
}
case 'blocks':
{
if (field.name in dataWithLocales) {
const newValue = dataWithLocales[field.name];
const existingValue = docWithLocales[field.name];
if (fieldIsLocalized) {
// If localized, handle locale keys
if (newValue && typeof newValue === 'object' && !Array.isArray(newValue)) {
const updatedData = {
...existingValue || {}
};
for (const locale of selectedLocales){
if (locale in newValue) {
updatedData[locale] = newValue[locale];
}
}
result[field.name] = updatedData;
} else {
// Preserve existing value if new value is not a valid object
result[field.name] = existingValue;
}
} else if (Array.isArray(newValue)) {
// Non-localized blocks - still process children for any localized fields
result[field.name] = newValue.map((newBlockData, index)=>{
let block;
if (configBlockReferences && field.blockReferences) {
for (const blockOrReference of field.blockReferences){
if (typeof blockOrReference === 'string') {
block = configBlockReferences.find((b)=>b.slug === newBlockData.blockType);
} else {
block = blockOrReference;
}
}
} else if (field.blocks) {
block = field.blocks.find((b)=>b.slug === newBlockData.blockType);
}
if (block) {
const blockData = Array.isArray(existingValue) && existingValue[index] ? existingValue[index] : {};
return mergeLocalizedData({
configBlockReferences,
dataWithLocales: newBlockData,
docWithLocales: blockData,
fields: block?.fields || [],
parentIsLocalized,
selectedLocales
});
}
return newBlockData;
});
}
}
break;
}
case 'group':
{
if (fieldAffectsData(field) && field.name) {
// Named groups create a nested data structure
if (field.name in dataWithLocales) {
const newValue = dataWithLocales[field.name];
const existingValue = docWithLocales[field.name];
if (fieldIsLocalized) {
if (newValue && typeof newValue === 'object' && !Array.isArray(newValue)) {
const groupData = {
...existingValue || {}
};
for (const locale of selectedLocales){
if (locale in newValue && typeof newValue[locale] === 'object') {
groupData[locale] = newValue[locale];
}
}
result[field.name] = groupData;
} else {
// Preserve existing value if new value is not a valid object
result[field.name] = existingValue;
}
} else if (typeof newValue === 'object' && !Array.isArray(newValue)) {
// Non-localized group - still process children for any localized fields
result[field.name] = mergeLocalizedData({
configBlockReferences,
dataWithLocales: newValue,
docWithLocales: existingValue || {},
fields: field.fields,
parentIsLocalized,
selectedLocales
});
}
}
} else {
// Unnamed groups pass through the same data level
const merged = mergeLocalizedData({
configBlockReferences,
dataWithLocales,
docWithLocales: result,
fields: field.fields,
parentIsLocalized,
selectedLocales
});
Object.assign(result, merged);
}
break;
}
default:
{
// For all other data-affecting fields (text, number, select, etc.)
if (fieldIsLocalized) {
if (field.name in dataWithLocales) {
const newValue = dataWithLocales[field.name];
const existingValue = docWithLocales[field.name] || {};
// If localized, handle locale keys
if (newValue && typeof newValue === 'object' && !Array.isArray(newValue)) {
const merged = {
...existingValue
};
for (const locale of selectedLocales){
if (locale in newValue) {
merged[locale] = newValue[locale];
}
}
result[field.name] = merged;
} else if (parentIsLocalized) {
// Child of localized parent - replace with new value
result[field.name] = newValue;
} else {
// Preserve existing value if new value is not a valid object
result[field.name] = existingValue;
}
}
} else if (parentIsLocalized) {
result[field.name] = dataWithLocales[field.name];
} else {
result[field.name] = field.name in dataWithLocales ? dataWithLocales[field.name] : docWithLocales[field.name];
}
break;
}
}
} else {
// Layout-only fields that don't affect data structure
switch(field.type){
case 'collapsible':
case 'row':
{
// These pass through the same data level
const merged = mergeLocalizedData({
configBlockReferences,
dataWithLocales,
docWithLocales: result,
fields: field.fields,
parentIsLocalized,
selectedLocales
});
Object.assign(result, merged);
break;
}
case 'tabs':
{
for (const tab of field.tabs){
if (tabHasName(tab)) {
// Named tabs create a nested data structure and can be localized
const tabIsLocalized = fieldShouldBeLocalized({
field: tab,
parentIsLocalized
});
if (tab.name in dataWithLocales) {
const newValue = dataWithLocales[tab.name];
const existingValue = docWithLocales[tab.name];
if (tabIsLocalized) {
if (newValue && typeof newValue === 'object' && !Array.isArray(newValue)) {
const merged = {
...existingValue || {}
};
for (const locale of selectedLocales){
if (locale in newValue && typeof newValue[locale] === 'object') {
merged[locale] = newValue[locale];
}
}
result[tab.name] = merged;
} else {
// Preserve existing value if new value is not a valid object
result[tab.name] = existingValue;
}
} else if (typeof newValue === 'object' && !Array.isArray(newValue)) {
// Non-localized tab - still process children for any localized fields
result[tab.name] = mergeLocalizedData({
configBlockReferences,
dataWithLocales: newValue,
docWithLocales: existingValue || {},
fields: tab.fields,
parentIsLocalized,
selectedLocales
});
}
}
} else {
// Unnamed tabs pass through the same data level
const merged = mergeLocalizedData({
configBlockReferences,
dataWithLocales,
docWithLocales: result,
fields: tab.fields,
parentIsLocalized,
selectedLocales
});
Object.assign(result, merged);
}
}
break;
}
}
}
}
return result;
}
//# sourceMappingURL=mergeLocalizedData.js.map

View File

@@ -0,0 +1,45 @@
"use strict";
exports.formatLong = void 0;
var _index = require("../../_lib/buildFormatLongFn.cjs");
// Ref: https://www.unicode.org/cldr/charts/32/summary/ta.html
// CLDR #1846 - #1849
const dateFormats = {
full: "EEEE, d MMMM, y",
long: "d MMMM, y",
medium: "d MMM, y",
short: "d/M/yy",
};
// CLDR #1850 - #1853
const timeFormats = {
full: "a h:mm:ss zzzz",
long: "a h:mm:ss z",
medium: "a h:mm:ss",
short: "a h:mm",
};
const dateTimeFormats = {
full: "{{date}} {{time}}",
long: "{{date}} {{time}}",
medium: "{{date}}, {{time}}",
short: "{{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: "full",
}),
});

View File

@@ -0,0 +1 @@
module.exports={C:{"5":0.00441,"115":0.07495,"125":0.00441,"128":0.00441,"132":0.17636,"135":0.00882,"136":0.00882,"139":0.00441,"140":0.01323,"141":0.01323,"142":0.01764,"143":0.01323,"144":0.01764,"145":0.41886,"146":0.54231,"147":0.00441,_:"2 3 4 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 116 117 118 119 120 121 122 123 124 126 127 129 130 131 133 134 137 138 148 149 3.5 3.6"},D:{"56":0.00441,"65":0.00441,"69":0.00882,"71":0.00441,"74":0.07936,"78":0.00441,"79":0.07936,"86":0.00441,"87":0.097,"88":0.00441,"91":0.01323,"94":0.01323,"95":0.00441,"98":0.00882,"103":0.02205,"104":0.00441,"105":0.00441,"106":0.00882,"107":0.00882,"108":0.03086,"109":0.53349,"110":0.00441,"111":0.00882,"112":0.44531,"113":0.00441,"114":0.00441,"115":0.00441,"116":0.03527,"117":0.00441,"118":0.00441,"119":0.01323,"120":0.0485,"121":0.01764,"122":0.08377,"123":0.01764,"124":0.18518,"125":0.10141,"126":0.07495,"127":0.02645,"128":0.03968,"129":0.02205,"130":0.05291,"131":0.04409,"132":0.03086,"133":0.03086,"134":0.02205,"135":0.04409,"136":0.04409,"137":0.05732,"138":2.447,"139":0.51144,"140":0.13227,"141":0.36154,"142":8.03761,"143":11.97484,"144":0.00441,_:"4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 57 58 59 60 61 62 63 64 66 67 68 70 72 73 75 76 77 80 81 83 84 85 89 90 92 93 96 97 99 100 101 102 145 146"},F:{"46":0.01323,"78":0.00441,"90":0.00441,"92":0.00882,"93":0.15432,"95":0.00441,"114":0.097,"122":0.00882,"123":0.02645,"124":0.67017,"125":0.19841,_:"9 11 12 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 47 48 49 50 51 52 53 54 55 56 57 58 60 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 79 80 81 82 83 84 85 86 87 88 89 91 94 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 115 116 117 118 119 120 121 9.5-9.6 10.0-10.1 10.5 10.6 11.1 11.5 11.6 12.1"},B:{"109":0.00882,"125":0.00441,"133":0.00441,"135":0.00441,"137":0.00441,"138":0.00441,"139":0.03527,"140":0.03527,"141":0.01764,"142":1.30947,"143":4.15769,_:"12 13 14 15 16 17 18 79 80 81 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 126 127 128 129 130 131 132 134 136"},E:{"14":0.00441,_:"0 4 5 6 7 8 9 10 11 12 13 15 3.1 3.2 5.1 6.1 7.1 9.1 10.1 11.1 12.1 15.1 15.2-15.3 15.4 15.5 17.0","13.1":0.18959,"14.1":0.03527,"15.6":0.04409,"16.0":0.00441,"16.1":0.00882,"16.2":0.00882,"16.3":0.02205,"16.4":0.00882,"16.5":0.00441,"16.6":0.07495,"17.1":0.05732,"17.2":0.02205,"17.3":0.00441,"17.4":0.02205,"17.5":0.03086,"17.6":0.08377,"18.0":0.02645,"18.1":0.01323,"18.2":0.01323,"18.3":0.0485,"18.4":0.02205,"18.5-18.6":0.08818,"26.0":0.04409,"26.1":0.27336,"26.2":0.07054,"26.3":0.00441},G:{"8":0,"3.2":0,"4.0-4.1":0,"4.2-4.3":0.00228,"5.0-5.1":0,"6.0-6.1":0.00456,"7.0-7.1":0.00342,"8.1-8.4":0,"9.0-9.2":0,"9.3":0.00913,"10.0-10.2":0.00114,"10.3":0.01598,"11.0-11.2":0.19627,"11.3-11.4":0.00571,"12.0-12.1":0.00456,"12.2-12.5":0.05135,"13.0-13.1":0.00114,"13.2":0.00799,"13.3":0.00228,"13.4-13.7":0.00799,"14.0-14.4":0.01598,"14.5-14.8":0.01712,"15.0-15.1":0.01826,"15.2-15.3":0.01369,"15.4":0.01483,"15.5":0.01598,"15.6-15.8":0.24762,"16.0":0.02853,"16.1":0.05477,"16.2":0.02853,"16.3":0.05135,"16.4":0.01255,"16.5":0.02168,"16.6-16.7":0.3218,"17.0":0.01826,"17.1":0.02967,"17.2":0.02168,"17.3":0.03309,"17.4":0.05592,"17.5":0.10955,"17.6-17.7":0.25333,"18.0":0.05706,"18.1":0.11868,"18.2":0.06276,"18.3":0.20426,"18.4":0.10498,"18.5-18.7":7.53826,"26.0":0.1472,"26.1":1.22443,"26.2":0.23279,"26.3":0.01027},P:{"4":0.11273,"20":0.01025,"21":0.0205,"22":0.04099,"23":0.04099,"24":0.04099,"25":0.06149,"26":0.07174,"27":0.12298,"28":0.36893,"29":3.3716,"5.0-5.4":0.01025,_:"6.2-6.4 9.2 11.1-11.2 12.0 13.0 15.0 16.0","7.2-7.4":0.10248,"8.2":0.0205,"10.1":0.0205,"14.0":0.0205,"17.0":0.0205,"18.0":0.01025,"19.0":0.01025},I:{"0":0.01675,"3":0,"4":0,"2.1":0,"2.2":0,"2.3":0,"4.1":0,"4.2-4.3":0,"4.4":0,"4.4.3-4.4.4":0.00001},A:{"11":0.02645,_:"6 7 8 9 10 5.5"},K:{"0":0.71565,_:"10 11 12 11.1 11.5 12.1"},N:{_:"10 11"},S:{"2.5":0.00559,_:"3.0-3.1"},J:{_:"7 10"},Q:{"14.9":0.01118},O:{"0":0.06709},H:{"0":0},L:{"0":44.58078},R:{_:"0"},M:{"0":0.55351}};

View File

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

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