docs: 仓库链接指向本镜像仓库
Build NapCat Artifacts / Type Check & Test (push) Waiting to run

This commit is contained in:
TanTan committed 2026-11-13 09:25:58 +08:00
1 parent f954252a34
commit e311ca3275
35554 files changed
+6229626 -4

No files matched your search

@@ -0,0 +1,2 @@
import 'reflect-metadata';
//# sourceMappingURL=inversify-monorepo-issue-959-parentContainerAutobindWithChildNonAutobind.int.spec.d.ts.map
@@ -0,0 +1,111 @@
var baseToString = require('./_baseToString'),
castSlice = require('./_castSlice'),
hasUnicode = require('./_hasUnicode'),
isObject = require('./isObject'),
isRegExp = require('./isRegExp'),
stringSize = require('./_stringSize'),
stringToArray = require('./_stringToArray'),
toInteger = require('./toInteger'),
toString = require('./toString');
/** Used as default options for `_.truncate`. */
var DEFAULT_TRUNC_LENGTH = 30,
DEFAULT_TRUNC_OMISSION = '...';
/** Used to match `RegExp` flags from their coerced string values. */
var reFlags = /\w*$/;
/**
* Truncates `string` if it's longer than the given maximum string length.
* The last characters of the truncated string are replaced with the omission
* string which defaults to "...".
*
* @static
* @memberOf _
* @since 4.0.0
* @category String
* @param {string} [string=''] The string to truncate.
* @param {Object} [options={}] The options object.
* @param {number} [options.length=30] The maximum string length.
* @param {string} [options.omission='...'] The string to indicate text is omitted.
* @param {RegExp|string} [options.separator] The separator pattern to truncate to.
* @returns {string} Returns the truncated string.
* @example
*
* _.truncate('hi-diddly-ho there, neighborino');
* // => 'hi-diddly-ho there, neighbo...'
*
* _.truncate('hi-diddly-ho there, neighborino', {
* 'length': 24,
* 'separator': ' '
* });
* // => 'hi-diddly-ho there,...'
*
* _.truncate('hi-diddly-ho there, neighborino', {
* 'length': 24,
* 'separator': /,? +/
* });
* // => 'hi-diddly-ho there...'
*
* _.truncate('hi-diddly-ho there, neighborino', {
* 'omission': ' [...]'
* });
* // => 'hi-diddly-ho there, neig [...]'
*/
function truncate(string, options) {
var length = DEFAULT_TRUNC_LENGTH,
omission = DEFAULT_TRUNC_OMISSION;
if (isObject(options)) {
var separator = 'separator' in options ? options.separator : separator;
length = 'length' in options ? toInteger(options.length) : length;
omission = 'omission' in options ? baseToString(options.omission) : omission;
}
string = toString(string);
var strLength = string.length;
if (hasUnicode(string)) {
var strSymbols = stringToArray(string);
strLength = strSymbols.length;
}
if (length >= strLength) {
return string;
}
var end = length - stringSize(omission);
if (end < 1) {
return omission;
}
var result = strSymbols
? castSlice(strSymbols, 0, end).join('')
: string.slice(0, end);
if (separator === undefined) {
return result + omission;
}
if (strSymbols) {
end += (result.length - end);
}
if (isRegExp(separator)) {
if (string.slice(end).search(separator)) {
var match,
substring = result;
if (!separator.global) {
separator = RegExp(separator.source, toString(reFlags.exec(separator)) + 'g');
}
separator.lastIndex = 0;
while ((match = separator.exec(substring))) {
var newEnd = match.index;
}
result = result.slice(0, newEnd === undefined ? end : newEnd);
}
} else if (string.indexOf(baseToString(separator), end) != end) {
var index = result.lastIndexOf(separator);
if (index > -1) {
result = result.slice(0, index);
}
}
return result + omission;
}
module.exports = truncate;
@@ -0,0 +1,58 @@
module.exports = {
'castArray': require('./castArray'),
'clone': require('./clone'),
'cloneDeep': require('./cloneDeep'),
'cloneDeepWith': require('./cloneDeepWith'),
'cloneWith': require('./cloneWith'),
'conformsTo': require('./conformsTo'),
'eq': require('./eq'),
'gt': require('./gt'),
'gte': require('./gte'),
'isArguments': require('./isArguments'),
'isArray': require('./isArray'),
'isArrayBuffer': require('./isArrayBuffer'),
'isArrayLike': require('./isArrayLike'),
'isArrayLikeObject': require('./isArrayLikeObject'),
'isBoolean': require('./isBoolean'),
'isBuffer': require('./isBuffer'),
'isDate': require('./isDate'),
'isElement': require('./isElement'),
'isEmpty': require('./isEmpty'),
'isEqual': require('./isEqual'),
'isEqualWith': require('./isEqualWith'),
'isError': require('./isError'),
'isFinite': require('./isFinite'),
'isFunction': require('./isFunction'),
'isInteger': require('./isInteger'),
'isLength': require('./isLength'),
'isMap': require('./isMap'),
'isMatch': require('./isMatch'),
'isMatchWith': require('./isMatchWith'),
'isNaN': require('./isNaN'),
'isNative': require('./isNative'),
'isNil': require('./isNil'),
'isNull': require('./isNull'),
'isNumber': require('./isNumber'),
'isObject': require('./isObject'),
'isObjectLike': require('./isObjectLike'),
'isPlainObject': require('./isPlainObject'),
'isRegExp': require('./isRegExp'),
'isSafeInteger': require('./isSafeInteger'),
'isSet': require('./isSet'),
'isString': require('./isString'),
'isSymbol': require('./isSymbol'),
'isTypedArray': require('./isTypedArray'),
'isUndefined': require('./isUndefined'),
'isWeakMap': require('./isWeakMap'),
'isWeakSet': require('./isWeakSet'),
'lt': require('./lt'),
'lte': require('./lte'),
'toArray': require('./toArray'),
'toFinite': require('./toFinite'),
'toInteger': require('./toInteger'),
'toLength': require('./toLength'),
'toNumber': require('./toNumber'),
'toPlainObject': require('./toPlainObject'),
'toSafeInteger': require('./toSafeInteger'),
'toString': require('./toString')
};
@@ -0,0 +1,57 @@
var baseRest = require('./_baseRest'),
createWrap = require('./_createWrap'),
getHolder = require('./_getHolder'),
replaceHolders = require('./_replaceHolders');
/** Used to compose bitmasks for function metadata. */
var WRAP_BIND_FLAG = 1,
WRAP_PARTIAL_FLAG = 32;
/**
* Creates a function that invokes `func` with the `this` binding of `thisArg`
* and `partials` prepended to the arguments it receives.
*
* The `_.bind.placeholder` value, which defaults to `_` in monolithic builds,
* may be used as a placeholder for partially applied arguments.
*
* **Note:** Unlike native `Function#bind`, this method doesn't set the "length"
* property of bound functions.
*
* @static
* @memberOf _
* @since 0.1.0
* @category Function
* @param {Function} func The function to bind.
* @param {*} thisArg The `this` binding of `func`.
* @param {...*} [partials] The arguments to be partially applied.
* @returns {Function} Returns the new bound function.
* @example
*
* function greet(greeting, punctuation) {
* return greeting + ' ' + this.user + punctuation;
* }
*
* var object = { 'user': 'fred' };
*
* var bound = _.bind(greet, object, 'hi');
* bound('!');
* // => 'hi fred!'
*
* // Bound with placeholders.
* var bound = _.bind(greet, object, _, '!');
* bound('hi');
* // => 'hi fred!'
*/
var bind = baseRest(function(func, thisArg, partials) {
var bitmask = WRAP_BIND_FLAG;
if (partials.length) {
var holders = replaceHolders(partials, getHolder(bind));
bitmask |= WRAP_PARTIAL_FLAG;
}
return createWrap(func, bitmask, thisArg, partials, holders);
});
// Assign default placeholders.
bind.placeholder = {};
module.exports = bind;
@@ -0,0 +1,9 @@
import 'react';
import '@react-stately/slider';
import '@heroui/system';
import '@heroui/theme';
import '@heroui/react-utils';
import '@react-aria/slider';
import '@heroui/tooltip';
import '@react-types/shared';
export { b as SliderRenderThumbProps, a as SliderStepMark, S as SliderValue, U as UseSliderProps, h as UseSliderReturn, u as useSlider } from './use-slider-9ae8d8d3.js';
@@ -0,0 +1,17 @@
"use strict";
var AuthenticatedSafe_1;
Object.defineProperty(exports, "__esModule", { value: true });
exports.AuthenticatedSafe = void 0;
const tslib_1 = require("tslib");
const asn1_schema_1 = require("@peculiar/asn1-schema");
const asn1_cms_1 = require("@peculiar/asn1-cms");
let AuthenticatedSafe = AuthenticatedSafe_1 = class AuthenticatedSafe extends asn1_schema_1.AsnArray {
constructor(items) {
super(items);
Object.setPrototypeOf(this, AuthenticatedSafe_1.prototype);
}
};
exports.AuthenticatedSafe = AuthenticatedSafe;
exports.AuthenticatedSafe = AuthenticatedSafe = AuthenticatedSafe_1 = tslib_1.__decorate([
(0, asn1_schema_1.AsnType)({ type: asn1_schema_1.AsnTypeTypes.Sequence, itemType: asn1_cms_1.ContentInfo })
], AuthenticatedSafe);
@@ -0,0 +1,15 @@
module.exports = {
"deselectedItem": (args)=>`${args.item} nicht ausgew\xe4hlt.`,
"longPressToSelect": `Gedr\xfcckt halten, um Auswahlmodus zu \xf6ffnen.`,
"select": `Ausw\xe4hlen`,
"selectedAll": `Alle Elemente ausgew\xe4hlt.`,
"selectedCount": (args, formatter)=>`${formatter.plural(args.count, {
"=0": `Keine Elemente ausgew\xe4hlt`,
one: ()=>`${formatter.number(args.count)} Element ausgew\xe4hlt`,
other: ()=>`${formatter.number(args.count)} Elemente ausgew\xe4hlt`
})}.`,
"selectedItem": (args)=>`${args.item} ausgew\xe4hlt.`
};
//# sourceMappingURL=de-DE.main.js.map
@@ -0,0 +1 @@
{"mappings":"AAAA,iBAAiB;IAAG,aAAa,CAAC,0CAAM,CAAC;IACvC,iBAAiB,CAAC,OAAS,CAAC,qGAAiB,EAAE,KAAK,UAAU,CAAC,sFAAc,CAAC;IAC9E,cAAc,CAAC,OAAS,GAAG,KAAK,KAAK,CAAC,kDAAQ,CAAC;IAC/C,cAAc,CAAC,0CAAM,CAAC;IACtB,kBAAkB,CAAC,OAAS,CAAC,qGAAiB,EAAE,KAAK,UAAU,CAAC,sFAAc,CAAC;IAC/E,sBAAsB,CAAC,iMAAqC,CAAC;IAC7D,UAAU,CAAC,mCAAK,CAAC;IACjB,aAAa,CAAC,gEAAU,CAAC;IACzB,YAAY,CAAC,2GAAiB,CAAC;AACjC","sources":["packages/@react-aria/table/intl/ar-AE.json"],"sourcesContent":["{\n \"ascending\": \"تصاعدي\",\n \"ascendingSort\": \"ترتيب حسب العمود {columnName} بترتيب تصاعدي\",\n \"columnSize\": \"{value} بالبكسل\",\n \"descending\": \"تنازلي\",\n \"descendingSort\": \"ترتيب حسب العمود {columnName} بترتيب تنازلي\",\n \"resizerDescription\": \"اضغط على مفتاح Enter لبدء تغيير الحجم\",\n \"select\": \"تحديد\",\n \"selectAll\": \"تحديد الكل\",\n \"sortable\": \"عمود قابل للترتيب\"\n}\n"],"names":[],"version":3,"file":"ar-AE.main.js.map"}
@@ -0,0 +1 @@
{"name":"@types/json5","version":"0.0.29","requiresBuild":false,"files":{"README.md":{"checkedAt":1794532125546,"integrity":"sha512-1iyoeb8Xj/KHbWZWiK9Jv/FJnmrYL3bsq8veBpodelj5FrhH9DNryDO2RalzAd6uZINzohhMd34bt1HCo71QIw==","mode":420,"size":543},"index.d.ts":{"checkedAt":1794532125546,"integrity":"sha512-dOspV4Juyn08ljS5BXXKsAI4iMDmgYNpAOKdJjKK7Tz7KHlwuxtjaYT2PP7TyGCjGpjdcVaMzl+XQf5ieMv1uQ==","mode":420,"size":1210},"package.json":{"checkedAt":1794532125546,"integrity":"sha512-ent2Kff5H6LFIafwTpOJU8LvbCkLZTrgLFdSY1NSrmfn7oRlJT+x9tt4+6T9z4XhEXYnxZ4srFmw8u8YdHgvdg==","mode":420,"size":517},"types-metadata.json":{"checkedAt":1794532125546,"integrity":"sha512-LAAFmfc1T1ewd4Aj55sZCLa9mEJfKVwC7A5zdEicgno/kySaJM+CVUVw8i+XfRZFLtlwwa683PK4HtyX+1k92g==","mode":420,"size":728}}}
@@ -0,0 +1,3 @@
import { OB11MessageData } from '../types';
export declare function decodeCQCode(source: string): OB11MessageData[];
export declare function encodeCQCode(data: OB11MessageData): string;
@@ -0,0 +1,7 @@
import type { ESLintUtils, TSESLint } from '@typescript-eslint/utils';
export declare function RuleCreator<PluginDocs = unknown>(urlCreator: (ruleName: string) => string): <Options extends readonly unknown[], MessageIds extends string>({ meta, name, ...rule }: Readonly<ESLintUtils.RuleWithMetaAndName<Options, MessageIds, PluginDocs>>) => TSESLint.RuleModule<MessageIds, Options, PluginDocs>;
export interface ImportXPluginDocs {
category?: string;
recommended?: true;
}
export declare const createRule: <Options extends readonly unknown[], MessageIds extends string>({ meta, name, ...rule }: Readonly<ESLintUtils.RuleWithMetaAndName<Options, MessageIds, ImportXPluginDocs>>) => ESLintUtils.RuleModule<MessageIds, Options, ImportXPluginDocs, ESLintUtils.RuleListener>;
@@ -0,0 +1,7 @@
import { CreateType } from '../create/type.mjs';
import { Never } from '../never/index.mjs';
import * as KindGuard from '../guard/kind.mjs';
/** `[JavaScript]` Extracts the ReturnType from the given Function type */
export function ReturnType(schema, options) {
return (KindGuard.IsFunction(schema) ? CreateType(schema.returns, options) : Never(options));
}
@@ -0,0 +1,31 @@
{
"name": "clone-stats",
"description": "Safely clone node's fs.Stats instances without losing their class methods",
"version": "0.0.1",
"main": "index.js",
"browser": "index.js",
"dependencies": {},
"devDependencies": {
"tape": "~2.3.2"
},
"scripts": {
"test": "node test"
},
"author": "Hugh Kennedy <hughskennedy@gmail.com> (http://hughsk.io/)",
"license": "MIT",
"repository": {
"type": "git",
"url": "git://github.com/hughsk/clone-stats"
},
"bugs": {
"url": "https://github.com/hughsk/clone-stats/issues"
},
"homepage": "https://github.com/hughsk/clone-stats",
"keywords": [
"stats",
"fs",
"clone",
"copy",
"prototype"
]
}
@@ -0,0 +1 @@
{"mappings":";;AAAA;;;;;;;;;;CAUC;AAYM,SAAS;IACd,IAAI,kBAAkB,CAAA,GAAA,aAAK,EAAE,IAAI;IACjC,IAAI,oBAAoB,CAAA,GAAA,kBAAU,EAAE,CAAC,aAAa,MAAM,UAAU;QAChE,8EAA8E;QAC9E,IAAI,KAAK,CAAA,oBAAA,8BAAA,QAAS,IAAI,IAAG,CAAC,GAAG;YAC3B,gBAAgB,OAAO,CAAC,MAAM,CAAC;YAC/B,YAAY;QACd,IAAI;QACJ,gBAAgB,OAAO,CAAC,GAAG,CAAC,UAAU;kBAAC;yBAAM;gBAAa;qBAAI;QAAO;QACrE,YAAY,gBAAgB,CAAC,MAAM,UAAU;IAC/C,GAAG,EAAE;IACL,IAAI,uBAAuB,CAAA,GAAA,kBAAU,EAAE,CAAC,aAAa,MAAM,UAAU;YAC1D;QAAT,IAAI,KAAK,EAAA,+BAAA,gBAAgB,OAAO,CAAC,GAAG,CAAC,uBAA5B,mDAAA,6BAAuC,EAAE,KAAI;QACtD,YAAY,mBAAmB,CAAC,MAAM,IAAI;QAC1C,gBAAgB,OAAO,CAAC,MAAM,CAAC;IACjC,GAAG,EAAE;IACL,IAAI,2BAA2B,CAAA,GAAA,kBAAU,EAAE;QACzC,gBAAgB,OAAO,CAAC,OAAO,CAAC,CAAC,OAAO;YACtC,qBAAqB,MAAM,WAAW,EAAE,MAAM,IAAI,EAAE,KAAK,MAAM,OAAO;QACxE;IACF,GAAG;QAAC;KAAqB;IAGzB,CAAA,GAAA,gBAAQ,EAAE;QACR,OAAO;IACT,GAAG;QAAC;KAAyB;IAE7B,OAAO;2BAAC;8BAAmB;kCAAsB;IAAwB;AAC3E","sources":["packages/@react-aria/utils/src/useGlobalListeners.ts"],"sourcesContent":["/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {useCallback, useEffect, useRef} from 'react';\n\ninterface GlobalListeners {\n addGlobalListener<K extends keyof DocumentEventMap>(el: EventTarget, type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void,\n addGlobalListener(el: EventTarget, type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void,\n removeGlobalListener<K extends keyof DocumentEventMap>(el: EventTarget, type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | EventListenerOptions): void,\n removeGlobalListener(el: EventTarget, type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void,\n removeAllGlobalListeners(): void\n}\n\nexport function useGlobalListeners(): GlobalListeners {\n let globalListeners = useRef(new Map());\n let addGlobalListener = useCallback((eventTarget, type, listener, options) => {\n // Make sure we remove the listener after it is called with the `once` option.\n let fn = options?.once ? (...args) => {\n globalListeners.current.delete(listener);\n listener(...args);\n } : listener;\n globalListeners.current.set(listener, {type, eventTarget, fn, options});\n eventTarget.addEventListener(type, listener, options);\n }, []);\n let removeGlobalListener = useCallback((eventTarget, type, listener, options) => {\n let fn = globalListeners.current.get(listener)?.fn || listener;\n eventTarget.removeEventListener(type, fn, options);\n globalListeners.current.delete(listener);\n }, []);\n let removeAllGlobalListeners = useCallback(() => {\n globalListeners.current.forEach((value, key) => {\n removeGlobalListener(value.eventTarget, value.type, key, value.options);\n });\n }, [removeGlobalListener]);\n\n \n useEffect(() => {\n return removeAllGlobalListeners;\n }, [removeAllGlobalListeners]);\n\n return {addGlobalListener, removeGlobalListener, removeAllGlobalListeners};\n}\n"],"names":[],"version":3,"file":"useGlobalListeners.module.js.map"}
@@ -0,0 +1 @@
{"mappings":";;;;;;;;;AAAA;;;;;;;;;;CAUC,GAED,gEAAgE;AAChE,gGAAgG;;;AAMhG,mBAAmB;AACnB,MAAM,yCAAmB;AAEzB,gEAAgE;AAChE,MAAM,0CAAoB;AAOnB,MAAM,kDAAuB,CAAA,GAAA,2CAAgB;IAGlD,cAAc,EAAU,EAAgB;QACtC,gCAAgC;QAChC,IAAI,OAAO,KAAK,CAAC,cAAc;QAE/B,mBAAmB;QACnB,IAAI,aAAa,KAAK,IAAI,GAAG;QAE7B,iDAAiD;QACjD,IAAI,OAAO,KAAK,CAAA,GAAA,8CAAmB,EAAE,KAAK,GAAG,EAAE,KAAK,IAAI,EAAE,GAAG;QAE7D,IAAI;QACJ,IAAI,OAAO,yCAAmB;YAC5B,gDAAgD;YAChD;YAEA,uDAAuD;YACvD,YAAY,CAAA,GAAA,oCAAS,EAAE,KAAK,IAAI,GAAG,KAAK,KAAK;YAC7C,QAAQ,YAAa,MAAW,KAAU;QAC5C,OAAO;YACL,8BAA8B;YAC9B,YAAY,CAAA,GAAA,oCAAS,EAAE,KAAK,IAAI,IAAI,KAAK;YACzC,QAAQ;QACV;QAEA,IAAI;QACJ,IAAI;QACJ,IAAI,OAAO,WAAW;YACpB,cAAc;YACd,YAAY,OAAO;QACrB,OAAO;YACL,IAAI,OAAO,OAAO;YAClB,IAAI,OAAQ,KAAS;gBACnB,cAAc,KAAK,KAAK,CAAC,OAAO,MAAM;gBACtC,YAAY,AAAC,OAAO,KAAM;YAC5B,OAAO;gBACL,QAAQ;gBACR,cAAc,KAAK,KAAK,CAAC,OAAO,MAAM;gBACtC,YAAY,AAAC,OAAO,KAAM;YAC5B;QACF;QAEA,OAAO,IAAI,CAAA,GAAA,sCAAW,EAAE,IAAI,EAAE,YAAY,aAAa;IACzD;IAEA,YAAY,IAAqB,EAAU;QACzC,IAAI,eAAe,KAAK,IAAI,GAAG;QAC/B,IAAI,CAAC,KAAK,KAAK,GAAG,CAAA,GAAA,0CAAe,EAAE;QAEnC,IAAI;QACJ,IAAI;QACJ,IAAI,CAAA,GAAA,oCAAS,EAAE,OAAO;YACpB,YAAY;YACZ,KAAK,CAAA,GAAA,8CAAmB,EAAE,KAAK,MAAM,GAAG;QAC1C,OAAO;YACL,YAAY;YACZ,KAAK,CAAA,GAAA,8CAAmB,EAAE,KAAK,MAAM,GAAG;QAC1C;QAEA,IAAI,KAAK,KAAK,KAAK,GACjB,OAAO,KAAK,KAAK,GAAG,GAAG;QAGzB,MAAM,YAAY,KAAK,GAAG,CAAC,KAAK,KAAK,GAAG,GAAG,KAAK;QAEhD,IAAI,KAAK,KAAK,IAAI,GAChB,MAAM,AAAC,CAAA,KAAK,KAAK,GAAG,CAAA,IAAK;QAG3B,MAAM,KAAK,GAAG,GAAG;QACjB,OAAO;IACT;IAEA,eAAe,IAAqB,EAAU;QAC5C,IAAI,KAAK,KAAK,KAAK,KAAK,CAAA,GAAA,oCAAS,EAAE,KAAK,IAAI,GAAG,yCAC7C,OAAO;QAGT,IAAI,KAAK,KAAK,IAAI,KAAK,KAAK,KAAK,IAAI,GACnC,OAAO;QAGT,OAAO;IACT;IAEA,gBAAwB;QACtB,6CAA6C;QAC7C,6CAA6C;QAC7C,OAAO;IACT;IAEA,UAAoB;QAClB,OAAO;YAAC;SAAO;IACjB;IAEA,cAAoB,CAAC;;QAjGhB,qBACL,aAAiC;;AAiGnC","sources":["packages/@internationalized/date/src/calendars/IndianCalendar.ts"],"sourcesContent":["/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\n// Portions of the code in this file are based on code from ICU.\n// Original licensing can be found in the NOTICE file in the root directory of this source tree.\n\nimport {AnyCalendarDate, CalendarIdentifier} from '../types';\nimport {CalendarDate} from '../CalendarDate';\nimport {fromExtendedYear, GregorianCalendar, gregorianToJulianDay, isLeapYear} from './GregorianCalendar';\n\n// Starts in 78 AD,\nconst INDIAN_ERA_START = 78;\n\n// The Indian year starts 80 days later than the Gregorian year.\nconst INDIAN_YEAR_START = 80;\n\n/**\n * The Indian National Calendar is similar to the Gregorian calendar, but with\n * years numbered since the Saka era in 78 AD (Gregorian). There are 12 months\n * in each year, with either 30 or 31 days. Only one era identifier is supported: 'saka'.\n */\nexport class IndianCalendar extends GregorianCalendar {\n identifier: CalendarIdentifier = 'indian';\n\n fromJulianDay(jd: number): CalendarDate {\n // Gregorian date for Julian day\n let date = super.fromJulianDay(jd);\n\n // Year in Saka era\n let indianYear = date.year - INDIAN_ERA_START;\n\n // Day number in Gregorian year (starting from 0)\n let yDay = jd - gregorianToJulianDay(date.era, date.year, 1, 1);\n\n let leapMonth: number;\n if (yDay < INDIAN_YEAR_START) {\n // Day is at the end of the preceding Saka year\n indianYear--;\n\n // Days in leapMonth this year, previous Gregorian year\n leapMonth = isLeapYear(date.year - 1) ? 31 : 30;\n yDay += leapMonth + (31 * 5) + (30 * 3) + 10;\n } else {\n // Days in leapMonth this year\n leapMonth = isLeapYear(date.year) ? 31 : 30;\n yDay -= INDIAN_YEAR_START;\n }\n\n let indianMonth: number;\n let indianDay: number;\n if (yDay < leapMonth) {\n indianMonth = 1;\n indianDay = yDay + 1;\n } else {\n let mDay = yDay - leapMonth;\n if (mDay < (31 * 5)) {\n indianMonth = Math.floor(mDay / 31) + 2;\n indianDay = (mDay % 31) + 1;\n } else {\n mDay -= 31 * 5;\n indianMonth = Math.floor(mDay / 30) + 7;\n indianDay = (mDay % 30) + 1;\n }\n }\n\n return new CalendarDate(this, indianYear, indianMonth, indianDay);\n }\n\n toJulianDay(date: AnyCalendarDate): number {\n let extendedYear = date.year + INDIAN_ERA_START;\n let [era, year] = fromExtendedYear(extendedYear);\n\n let leapMonth: number;\n let jd: number;\n if (isLeapYear(year)) {\n leapMonth = 31;\nLine truncated
@@ -0,0 +1 @@
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.js"],"names":[],"mappings":"AAcA;;;;;;;;GAQG;AACH,4CALW,OAAO,GAAG,IAAI,GAAG,SAAS,GAExB,SAAS,CAoBrB;6BAtCyB,YAAY"}
@@ -0,0 +1,19 @@
import Inline from '../blots/inline.js';
class Bold extends Inline {
static blotName = 'bold';
static tagName = ['STRONG', 'B'];
static create() {
return super.create();
}
static formats() {
return true;
}
optimize(context) {
super.optimize(context);
if (this.domNode.tagName !== this.statics.tagName[0]) {
this.replaceWith(this.statics.blotName);
}
}
}
export default Bold;
//# sourceMappingURL=bold.js.map
@@ -0,0 +1 @@
!function(e,n){"object"==typeof exports&&"undefined"!=typeof module?module.exports=n(require("dayjs")):"function"==typeof define&&define.amd?define(["dayjs"],n):(e="undefined"!=typeof globalThis?globalThis:e||self).dayjs_locale_fr_ca=n(e.dayjs)}(this,(function(e){"use strict";function n(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var i=n(e),_={name:"fr-ca",weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),months:"janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),monthsShort:"janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"),weekdaysMin:"di_lu_ma_me_je_ve_sa".split("_"),ordinal:function(e){return e},formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY-MM-DD",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"}};return i.default.locale(_,null,!0),_}));
@@ -0,0 +1,89 @@
/**
* @author Toru Nagashima
* See LICENSE file in root directory for full license.
*/
"use strict"
const { CALL, ReferenceTracker } = require("@eslint-community/eslint-utils")
const { getScope } = require("../../util/eslint-compat")
const {
iterateProcessGetBuiltinModuleReferences,
} = require("../../util/iterate-process-get-builtin-module-references")
/** @type {import('@eslint-community/eslint-utils').TraceMap<boolean>} */
const traceMap = {
fs: {
access: { [CALL]: true },
copyFile: { [CALL]: true },
open: { [CALL]: true },
rename: { [CALL]: true },
truncate: { [CALL]: true },
rmdir: { [CALL]: true },
mkdir: { [CALL]: true },
readdir: { [CALL]: true },
readlink: { [CALL]: true },
symlink: { [CALL]: true },
lstat: { [CALL]: true },
stat: { [CALL]: true },
link: { [CALL]: true },
unlink: { [CALL]: true },
chmod: { [CALL]: true },
lchmod: { [CALL]: true },
lchown: { [CALL]: true },
chown: { [CALL]: true },
utimes: { [CALL]: true },
realpath: { [CALL]: true },
mkdtemp: { [CALL]: true },
writeFile: { [CALL]: true },
appendFile: { [CALL]: true },
readFile: { [CALL]: true },
},
}
traceMap["node:fs"] = traceMap.fs
/** @type {import('../rule-module').RuleModule} */
module.exports = {
meta: {
docs: {
description: 'enforce `require("fs").promises`',
recommended: false,
url: "https://github.com/eslint-community/eslint-plugin-n/blob/HEAD/docs/rules/prefer-promises/fs.md",
},
fixable: null,
messages: {
preferPromises: "Use 'fs.promises.{{name}}()' instead.",
},
schema: [],
type: "suggestion",
},
create(context) {
return {
"Program:exit"() {
const scope = getScope(context)
const tracker = new ReferenceTracker(scope, { mode: "legacy" })
const references = [
...tracker.iterateCjsReferences(traceMap),
...iterateProcessGetBuiltinModuleReferences(
tracker,
traceMap
),
...tracker.iterateEsmReferences(traceMap),
]
for (const { node, path } of references) {
const name = path.at(-1)
if (name == null) {
continue
}
context.report({
node,
messageId: "preferPromises",
data: { name },
})
}
},
}
},
}
@@ -0,0 +1,30 @@
{
"version": "1.0.0-next.29",
"name": "@polka/url",
"repository": "lukeed/polka",
"description": "Super fast, memoized `req.url` parser",
"module": "build.mjs",
"types": "index.d.ts",
"main": "build.js",
"license": "MIT",
"exports": {
".": {
"types": "./index.d.ts",
"import": "./build.mjs",
"require": "./build.js"
},
"./package.json": "./package.json"
},
"files": [
"build.*",
"index.d.*"
],
"author": {
"name": "Luke Edwards",
"email": "luke@lukeed.com",
"url": "https://lukeed.com"
},
"publishConfig": {
"access": "public"
}
}
@@ -0,0 +1,2 @@
export { MouseSensor } from './MouseSensor';
export type { MouseSensorOptions, MouseSensorProps } from './MouseSensor';
@@ -0,0 +1,37 @@
<!-- This file is autogenerated. If you want to change this content, please do the changes in `./docs/README.md` instead. -->
<div align="center">
<br />
<a href="https://github.com/dcastil/tailwind-merge">
<img src="https://github.com/dcastil/tailwind-merge/raw/v1.14.0/assets/logo.svg" alt="tailwind-merge" height="150px" />
</a>
</div>
# tailwind-merge
Utility function to efficiently merge [Tailwind CSS](https://tailwindcss.com) classes in JS without style conflicts.
```ts
import { twMerge } from 'tailwind-merge'
twMerge('px-2 py-1 bg-red hover:bg-dark-red', 'p-3 bg-[#B91C1C]')
// → 'hover:bg-dark-red p-3 bg-[#B91C1C]'
```
- Supports Tailwind v3.0 up to v3.3 (if you use Tailwind v2, use [tailwind-merge v0.9.0](https://github.com/dcastil/tailwind-merge/tree/v0.9.0))
- Works in all modern browsers and Node >=12
- Fully typed
- [Check bundle size on Bundlephobia](https://bundlephobia.com/package/tailwind-merge)
## Get started
- [What is it for](https://github.com/dcastil/tailwind-merge/tree/v1.14.0/docs/what-is-it-for.md)
- [When and how to use it](https://github.com/dcastil/tailwind-merge/tree/v1.14.0/docs/when-and-how-to-use-it.md)
- [Features](https://github.com/dcastil/tailwind-merge/tree/v1.14.0/docs/features.md)
- [Configuration](https://github.com/dcastil/tailwind-merge/tree/v1.14.0/docs/configuration.md)
- [Recipes](https://github.com/dcastil/tailwind-merge/tree/v1.14.0/docs/recipes.md)
- [API reference](https://github.com/dcastil/tailwind-merge/tree/v1.14.0/docs/api-reference.md)
- [Writing plugins](https://github.com/dcastil/tailwind-merge/tree/v1.14.0/docs/writing-plugins.md)
- [Versioning](https://github.com/dcastil/tailwind-merge/tree/v1.14.0/docs/versioning.md)
- [Contributing](https://github.com/dcastil/tailwind-merge/tree/v1.14.0/docs/contributing.md)
- [Similar packages](https://github.com/dcastil/tailwind-merge/tree/v1.14.0/docs/similar-packages.md)
@@ -0,0 +1,47 @@
import {Point as $3041db3296945e6e$export$baf26146a414f24a} from "./Point.module.js";
import {Rect as $60423f92c7f9ad87$export$c79fc6492f3af13d} from "./Rect.module.js";
/*
* Copyright 2020 Adobe. All rights reserved.
* This file is licensed to you 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 http://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 REPRESENTATIONS
* OF ANY KIND, either express or implied. See the License for the specific language
* governing permissions and limitations under the License.
*/
class $364191b3decf3697$export$4455ee6afb38dcbb {
setVisibleRect(rect) {
let time = performance.now() - this.startTime;
if (time < 500) {
if (rect.x !== this.visibleRect.x && time > 0) this.velocity.x = (rect.x - this.visibleRect.x) / time;
if (rect.y !== this.visibleRect.y && time > 0) this.velocity.y = (rect.y - this.visibleRect.y) / time;
}
this.startTime = performance.now();
this.visibleRect = rect;
}
getOverscannedRect() {
let overscanned = this.visibleRect.copy();
let overscanY = this.visibleRect.height / 3;
overscanned.height += overscanY;
if (this.velocity.y < 0) overscanned.y -= overscanY;
if (this.velocity.x !== 0) {
let overscanX = this.visibleRect.width / 3;
overscanned.width += overscanX;
if (this.velocity.x < 0) overscanned.x -= overscanX;
}
return overscanned;
}
constructor(){
this.startTime = 0;
this.velocity = new (0, $3041db3296945e6e$export$baf26146a414f24a)(0, 0);
this.visibleRect = new (0, $60423f92c7f9ad87$export$c79fc6492f3af13d)();
}
}
export {$364191b3decf3697$export$4455ee6afb38dcbb as OverscanManager};
//# sourceMappingURL=OverscanManager.module.js.map
@@ -0,0 +1,32 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = pathCeil;
/**
* @file 对路径进行四舍五入
* @author mengke01(kekee000@gmail.com)
*/
/**
* 对path坐标进行调整
*
* @param {Array} contour 轮廓点数组
* @param {number} point 四舍五入的点数
* @return {Object} contour 坐标点
*/
function pathCeil(contour, point) {
var p;
for (var i = 0, l = contour.length; i < l; i++) {
p = contour[i];
if (!point) {
p.x = Math.round(p.x);
p.y = Math.round(p.y);
} else {
p.x = Number(p.x.toFixed(point));
p.y = Number(p.y.toFixed(point));
}
}
return contour;
}
@@ -0,0 +1,90 @@
"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);
// src/index.ts
var index_exports = {};
__export(index_exports, {
useIntersectionObserver: () => useIntersectionObserver
});
module.exports = __toCommonJS(index_exports);
var import_react = require("react");
function useIntersectionObserver({
threshold = 0,
root = null,
rootMargin = "0%",
isEnabled = true,
freezeOnceVisible = false,
initialIsIntersecting = false,
onChange
} = {}) {
var _a;
const [ref, setRef] = (0, import_react.useState)(null);
const [state, setState] = (0, import_react.useState)(() => ({
isIntersecting: initialIsIntersecting,
entry: void 0
}));
const callbackRef = (0, import_react.useRef)();
callbackRef.current = onChange;
const frozen = ((_a = state.entry) == null ? void 0 : _a.isIntersecting) && freezeOnceVisible;
(0, import_react.useEffect)(() => {
if (!isEnabled) return;
if (!ref) return;
if (!("IntersectionObserver" in window)) return;
if (frozen) return;
let unobserve;
const observer = new IntersectionObserver(
(entries) => {
const thresholds = Array.isArray(observer.thresholds) ? observer.thresholds : [observer.thresholds];
entries.forEach((entry) => {
const isIntersecting = entry.isIntersecting && thresholds.some((threshold2) => entry.intersectionRatio >= threshold2);
setState({ isIntersecting, entry });
if (callbackRef.current) {
callbackRef.current(isIntersecting, entry);
}
if (isIntersecting && freezeOnceVisible && unobserve) {
unobserve();
unobserve = void 0;
}
});
},
{ threshold, root, rootMargin }
);
observer.observe(ref);
return () => {
observer.disconnect();
};
}, [ref, isEnabled, JSON.stringify(threshold), root, rootMargin, frozen, freezeOnceVisible]);
const prevRef = (0, import_react.useRef)(null);
(0, import_react.useEffect)(() => {
var _a2;
if (!ref && ((_a2 = state.entry) == null ? void 0 : _a2.target) && !freezeOnceVisible && !frozen && prevRef.current !== state.entry.target) {
prevRef.current = state.entry.target;
setState({ isIntersecting: initialIsIntersecting, entry: void 0 });
}
}, [ref, state.entry, freezeOnceVisible, frozen, initialIsIntersecting]);
const result = [setRef, !!state.isIntersecting, state.entry];
result.ref = result[0];
result.isIntersecting = result[1];
result.entry = result[2];
return result;
}
// Annotate the CommonJS export names for ESM import in node:
0 && (module.exports = {
useIntersectionObserver
});
@@ -0,0 +1 @@
module.exports={A:{A:{"2":"K D E F A B wC"},B:{"1":"0 1 2 3 4 5 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 GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB I","2":"C L M G N O","130":"P"},C:{"1":"0 1 2 3 4 5 3B UC 4B VC 5B 6B 7B 8B 9B AC BC CC DC EC FC GC HC IC JC KC LC Q H R WC 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 GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB I XC MC YC yC zC","2":"6 7 8 9 xC TC J ZB K D E F A B C L M G N O P aB AB BB CB DB EB FB bB cB 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 0C 1C"},D:{"1":"0 1 2 3 4 5 6B 7B 8B 9B AC BC CC DC EC FC GC HC IC JC KC LC 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 GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB I XC MC YC","2":"6 7 8 9 J ZB K D E F A B C L M G N O P aB AB BB CB DB EB FB bB cB 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 UC 4B VC 5B"},E:{"1":"L M G 7C 8C 9C bC cC PC AD QC dC eC fC gC hC BD RC iC jC kC lC mC CD SC nC oC pC qC rC sC tC DD ED","2":"J ZB K D E F A B C 2C ZC 3C 4C 5C 6C aC NC OC"},F:{"1":"0 1 2 3 4 5 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 Q H R WC 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":"6 7 8 9 F B C G N O P aB AB BB CB DB EB FB bB cB dB eB fB gB hB iB jB kB lB mB nB oB pB qB rB sB tB uB FD GD HD ID NC uC JD OC"},G:{"1":"XD YD ZD aD bD cD dD bC cC PC eD QC dC eC fC gC hC fD RC iC jC kC lC mC gD SC nC oC pC qC rC sC tC","2":"E ZC KD vC LD MD ND OD PD QD RD SD TD UD VD WD"},H:{"2":"hD"},I:{"1":"I","2":"TC J iD jD kD lD vC mD nD"},J:{"2":"D A"},K:{"1":"H","2":"A B C NC uC OC"},L:{"1":"I"},M:{"1":"MC"},N:{"2":"A B"},O:{"1":"PC"},P:{"1":"6 7 8 9 AB BB CB DB EB FB rD sD aC tD uD vD wD xD QC RC SC yD","2":"J oD pD qD"},Q:{"1":"zD"},R:{"1":"0D"},S:{"1":"2D","2":"1D"}},B:6,C:"Intl.PluralRules API",D:true};
@@ -0,0 +1,30 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = void 0;
var docPagefooterRole = {
abstract: false,
accessibleNameRequired: false,
baseConcepts: [],
childrenPresentational: false,
nameFrom: ['prohibited'],
prohibitedProps: [],
props: {
'aria-braillelabel': null,
'aria-brailleroledescription': null,
'aria-description': null,
'aria-disabled': null,
'aria-errormessage': null,
'aria-haspopup': null,
'aria-invalid': null
},
relatedConcepts: [],
requireContextRole: [],
requiredContextRole: [],
requiredOwnedElements: [],
requiredProps: {},
superClass: [['roletype', 'structure', 'section']]
};
var _default = exports.default = docPagefooterRole;
@@ -0,0 +1 @@
{"name":"http-cache-semantics","version":"4.2.0","requiresBuild":false,"files":{"LICENSE":{"checkedAt":1794532121795,"integrity":"sha512-SgivpscCq1W/ejegoKsslMwh2HujD2M8d3AM8YtUPnLSvLrCbtnyykJgiekrXKO+BhDKuWkPDsiZYNMoKN/bBg==","mode":420,"size":1274},"index.js":{"checkedAt":1794532121795,"integrity":"sha512-lrX/sKazZTDN3cqeogc40AUTnQhaafJ1RHGWEzfvy5pl0B7UaohCTmubFQur1nCx0+oENUkzQnAejXIYi/AMsw==","mode":420,"size":35412},"package.json":{"checkedAt":1794532121795,"integrity":"sha512-d+Pba0/JjK70zGydFgbRvtKOQ9WgSXqJggK1qu2MP5Q58+/MhHM2OpU0FO3As78qdV3xOjftIf/rJ/8vgZu3KQ==","mode":420,"size":600},"README.md":{"checkedAt":1794532121796,"integrity":"sha512-l99/24kMO9RReYlABUbNmU8iF8VQPNmu9ghwQM9k6wWR18pXFNrhHNFswSWymuAEmGYxLyD4vsAISxgHnEDUCQ==","mode":420,"size":12687}}}
@@ -0,0 +1,11 @@
import { HTMLProjectionNode } from '../../projection/node/HTMLProjectionNode.mjs';
import { MeasureLayout } from './layout/MeasureLayout.mjs';
const layout = {
layout: {
ProjectionNode: HTMLProjectionNode,
MeasureLayout,
},
};
export { layout };
@@ -0,0 +1,180 @@
import path from 'path';
import { normalizePath } from 'vite';
import fs from 'fs';
import fs$1 from 'fs-extra';
import chalk from 'chalk';
import zlib from 'zlib';
import Debug from 'debug';
const isFunction = (arg) => typeof arg === "function";
const isRegExp = (arg) => Object.prototype.toString.call(arg) === "[object RegExp]";
function readAllFile(root, reg) {
let resultArr = [];
try {
if (fs.existsSync(root)) {
const stat = fs.lstatSync(root);
if (stat.isDirectory()) {
const files = fs.readdirSync(root);
files.forEach(function(file) {
const t = readAllFile(path.join(root, "/", file), reg);
resultArr = resultArr.concat(t);
});
} else {
if (reg !== void 0) {
if (isFunction(reg.test) && reg.test(root)) {
resultArr.push(root);
}
} else {
resultArr.push(root);
}
}
}
} catch (error) {
throw error;
}
return resultArr;
}
const debug = Debug.debug("vite-plugin-compression");
const extRE = /\.(js|mjs|json|css|html)$/i;
const mtimeCache = /* @__PURE__ */ new Map();
function index(options = {}) {
let outputPath;
let config;
const emptyPlugin = {
name: "vite:compression"
};
const {
disable = false,
filter = extRE,
verbose = true,
threshold = 1025,
compressionOptions = {},
deleteOriginFile = false,
success = () => {
}
} = options;
let { ext = "" } = options;
const { algorithm = "gzip" } = options;
if (algorithm === "gzip" && !ext) {
ext = ".gz";
}
if (algorithm === "brotliCompress" && !ext) {
ext = ".br";
}
if (disable) {
return emptyPlugin;
}
debug("plugin options:", options);
return {
...emptyPlugin,
apply: "build",
enforce: "post",
configResolved(resolvedConfig) {
config = resolvedConfig;
outputPath = path.isAbsolute(config.build.outDir) ? config.build.outDir : path.join(config.root, config.build.outDir);
debug("resolvedConfig:", resolvedConfig);
},
async closeBundle() {
let files = readAllFile(outputPath) || [];
debug("files:", files);
if (!files.length)
return;
files = filterFiles(files, filter);
const compressOptions = getCompressionOptions(algorithm, compressionOptions);
const compressMap = /* @__PURE__ */ new Map();
const handles = files.map(async (filePath) => {
const { mtimeMs, size: oldSize } = await fs$1.stat(filePath);
if (mtimeMs <= (mtimeCache.get(filePath) || 0) || oldSize < threshold)
return;
let content = await fs$1.readFile(filePath);
if (deleteOriginFile) {
fs$1.remove(filePath);
}
try {
content = await compress(content, algorithm, compressOptions);
} catch (error) {
config.logger.error("compress error:" + filePath);
}
const size = content.byteLength;
const cname = getOutputFileName(filePath, ext);
compressMap.set(filePath, {
size: size / 1024,
oldSize: oldSize / 1024,
cname
});
await fs$1.writeFile(cname, content);
mtimeCache.set(filePath, Date.now());
});
return Promise.all(handles).then(() => {
if (verbose) {
handleOutputLogger(config, compressMap, algorithm);
success();
}
});
}
};
}
function filterFiles(files, filter) {
if (filter) {
const isRe = isRegExp(filter);
const isFn = isFunction(filter);
files = files.filter((file) => {
if (isRe) {
return filter.test(file);
}
if (isFn) {
return filter(file);
}
return true;
});
}
return files;
}
function getCompressionOptions(algorithm = "", compressionOptions = {}) {
const defaultOptions = {
gzip: {
level: zlib.constants.Z_BEST_COMPRESSION
},
deflate: {
level: zlib.constants.Z_BEST_COMPRESSION
},
deflateRaw: {
level: zlib.constants.Z_BEST_COMPRESSION
},
brotliCompress: {
params: {
[zlib.constants.BROTLI_PARAM_QUALITY]: zlib.constants.BROTLI_MAX_QUALITY,
[zlib.constants.BROTLI_PARAM_MODE]: zlib.constants.BROTLI_MODE_TEXT
}
}
};
return {
...defaultOptions[algorithm],
...compressionOptions
};
}
function compress(content, algorithm, options = {}) {
return new Promise((resolve, reject) => {
zlib[algorithm](content, options, (err, result) => err ? reject(err) : resolve(result));
});
}
function getOutputFileName(filepath, ext) {
const compressExt = ext.startsWith(".") ? ext : `.${ext}`;
return `${filepath}${compressExt}`;
}
function handleOutputLogger(config, compressMap, algorithm) {
config.logger.info(`
${chalk.cyan("\u2728 [vite-plugin-compression]:algorithm=" + algorithm)} - compressed file successfully: `);
const keyLengths = Array.from(compressMap.keys(), (name) => name.length);
const maxKeyLength = Math.max(...keyLengths);
compressMap.forEach((value, name) => {
const { size, oldSize, cname } = value;
const rName = normalizePath(cname).replace(normalizePath(`${config.build.outDir}/`), "");
const sizeStr = `${oldSize.toFixed(2)}kb / ${algorithm}: ${size.toFixed(2)}kb`;
config.logger.info(chalk.dim(path.basename(config.build.outDir) + "/") + chalk.blueBright(rName) + " ".repeat(2 + maxKeyLength - name.length) + " " + chalk.dim(sizeStr));
});
config.logger.info("\n");
}
export { index as default };
@@ -0,0 +1,34 @@
var Fu=Object.create;var pt=Object.defineProperty;var pu=Object.getOwnPropertyDescriptor;var du=Object.getOwnPropertyNames;var mu=Object.getPrototypeOf,Eu=Object.prototype.hasOwnProperty;var er=e=>{throw TypeError(e)};var Cu=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),dt=(e,t)=>{for(var r in t)pt(e,r,{get:t[r],enumerable:!0})},hu=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let u of du(t))!Eu.call(e,u)&&u!==r&&pt(e,u,{get:()=>t[u],enumerable:!(n=pu(t,u))||n.enumerable});return e};var gu=(e,t,r)=>(r=e!=null?Fu(mu(e)):{},hu(t||!e||!e.__esModule?pt(r,"default",{value:e,enumerable:!0}):r,e));var yu=(e,t,r)=>t.has(e)||er("Cannot "+r);var tr=(e,t,r)=>t.has(e)?er("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,r);var fe=(e,t,r)=>(yu(e,t,"access private method"),r);var Pn=Cu(Mt=>{"use strict";Object.defineProperty(Mt,"__esModule",{value:!0});function Co(){return new Proxy({},{get:()=>e=>e})}var On=/\r\n|[\n\r\u2028\u2029]/;function ho(e,t,r){let n=Object.assign({column:0,line:-1},e.start),u=Object.assign({},n,e.end),{linesAbove:o=2,linesBelow:i=3}=r||{},s=n.line,a=n.column,c=u.line,D=u.column,p=Math.max(s-(o+1),0),l=Math.min(t.length,c+i);s===-1&&(p=0),c===-1&&(l=t.length);let F=c-s,f={};if(F)for(let d=0;d<=F;d++){let m=d+s;if(!a)f[m]=!0;else if(d===0){let C=t[m-1].length;f[m]=[a,C-a+1]}else if(d===F)f[m]=[0,D];else{let C=t[m-d].length;f[m]=[0,C]}}else a===D?a?f[s]=[a,0]:f[s]=!0:f[s]=[a,D-a];return{start:p,end:l,markerLines:f}}function go(e,t,r={}){let u=Co(!1),o=e.split(On),{start:i,end:s,markerLines:a}=ho(t,o,r),c=t.start&&typeof t.start.column=="number",D=String(s).length,l=e.split(On,s).slice(i,s).map((F,f)=>{let d=i+1+f,C=` ${` ${d}`.slice(-D)} |`,E=a[d],h=!a[d+1];if(E){let x="";if(Array.isArray(E)){let A=F.slice(0,Math.max(E[0]-1,0)).replace(/[^\t]/g," "),$=E[1]||1;x=[`
`,u.gutter(C.replace(/\d/g," "))," ",A,u.marker("^").repeat($)].join(""),h&&r.message&&(x+=" "+u.message(r.message))}return[u.marker(">"),u.gutter(C),F.length>0?` ${F}`:"",x].join("")}else return` ${u.gutter(C)}${F.length>0?` ${F}`:""}`}).join(`
`);return r.message&&!c&&(l=`${" ".repeat(D+1)}${r.message}
${l}`),l}Mt.codeFrameColumns=go});var Zt={};dt(Zt,{__debug:()=>ui,check:()=>ri,doc:()=>qt,format:()=>fu,formatWithCursor:()=>cu,getSupportInfo:()=>ni,util:()=>Qt,version:()=>tu});var Au=(e,t,r,n)=>{if(!(e&&t==null))return t.replaceAll?t.replaceAll(r,n):r.global?t.replace(r,n):t.split(r).join(n)},te=Au;var _e=class{diff(t,r,n={}){let u;typeof n=="function"?(u=n,n={}):"callback"in n&&(u=n.callback);let o=this.castInput(t,n),i=this.castInput(r,n),s=this.removeEmpty(this.tokenize(o,n)),a=this.removeEmpty(this.tokenize(i,n));return this.diffWithOptionsObj(s,a,n,u)}diffWithOptionsObj(t,r,n,u){var o;let i=E=>{if(E=this.postProcess(E,n),u){setTimeout(function(){u(E)},0);return}else return E},s=r.length,a=t.length,c=1,D=s+a;n.maxEditLength!=null&&(D=Math.min(D,n.maxEditLength));let p=(o=n.timeout)!==null&&o!==void 0?o:1/0,l=Date.now()+p,F=[{oldPos:-1,lastComponent:void 0}],f=this.extractCommon(F[0],r,t,0,n);if(F[0].oldPos+1>=a&&f+1>=s)return i(this.buildValues(F[0].lastComponent,r,t));let d=-1/0,m=1/0,C=()=>{for(let E=Math.max(d,-c);E<=Math.min(m,c);E+=2){let h,x=F[E-1],A=F[E+1];x&&(F[E-1]=void 0);let $=!1;if(A){let Be=A.oldPos-E;$=A&&0<=Be&&Be<s}let ue=x&&x.oldPos+1<a;if(!$&&!ue){F[E]=void 0;continue}if(!ue||$&&x.oldPos<A.oldPos?h=this.addToPath(A,!0,!1,0,n):h=this.addToPath(x,!1,!0,1,n),f=this.extractCommon(h,r,t,E,n),h.oldPos+1>=a&&f+1>=s)return i(this.buildValues(h.lastComponent,r,t))||!0;F[E]=h,h.oldPos+1>=a&&(m=Math.min(m,E-1)),f+1>=s&&(d=Math.max(d,E+1))}c++};if(u)(function E(){setTimeout(function(){if(c>D||Date.now()>l)return u(void 0);C()||E()},0)})();else for(;c<=D&&Date.now()<=l;){let E=C();if(E)return E}}addToPath(t,r,n,u,o){let i=t.lastComponent;return i&&!o.oneChangePerToken&&i.added===r&&i.removed===n?{oldPos:t.oldPos+u,lastComponent:{count:i.count+1,added:r,removed:n,previousComponent:i.previousComponent}}:{oldPos:t.oldPos+u,lastComponent:{count:1,added:r,removed:n,previousComponent:i}}}extractCommon(t,r,n,u,o){let i=r.length,s=n.length,a=t.oldPos,c=a-u,D=0;for(;c+1<i&&a+1<s&&this.equals(n[a+1],r[c+1],o);)c++,a++,D++,o.oneChangePerToken&&(t.lastComponent={count:1,previousComponent:t.lastComponent,added:!1,removed:!1});return D&&!o.oneChangePerToken&&(t.lastComponent={count:D,previousComponent:t.lastComponent,added:!1,removed:!1}),t.oldPos=a,c}equals(t,r,n){return n.comparator?n.comparator(t,r):t===r||!!n.ignoreCase&&t.toLowerCase()===r.toLowerCase()}removeEmpty(t){let r=[];for(let n=0;n<t.length;n++)t[n]&&r.push(t[n]);return r}castInput(t,r){return t}tokenize(t,r){return Array.from(t)}join(t){return t.join("")}postProcess(t,r){return t}get useLongestToken(){return!1}buildValues(t,r,n){let u=[],o;for(;t;)u.push(t),o=t.previousComponent,delete t.previousComponent,t=o;u.reverse();let i=u.length,s=0,a=0,c=0;for(;s<i;s++){let D=u[s];if(D.removed)D.value=this.join(n.slice(c,c+D.count)),c+=D.count;else{if(!D.added&&this.useLongestToken){let p=r.slice(a,a+D.count);p=p.map(function(l,F){let f=n[c+F];return f.length>l.length?f:l}),D.value=this.join(p)}else D.value=this.join(r.slice(a,a+D.count));a+=D.count,D.added||(c+=D.count)}}return u}};var mt=class extends _e{tokenize(t){return t.slice()}join(t){return t}removeEmpty(t){return t}},rr=new mt;function Et(e,t,r){return rr.diff(e,t,r)}function nr(e){let t=e.indexOf("\r");return t!==-1?e.charAt(t+1)===`
`?"crlf":"cr":"lf"}function xe(e){switch(e){case"cr":return"\r";case"crlf":return`\r
`;default:return`
`}}function Ct(e,t){let r;switch(t){case`
`:r=/\n/gu;break;case"\r":r=/\r/gu;break;case`\r
`:r=/\r\n/gu;break;default:throw new Error(`Unexpected "eol" ${JSON.stringify(t)}.`)}let n=e.match(r);return n?n.length:0}function ur(e){return te(!1,e,/\r\n?/gu,`
`)}var W="string",Y="array",j="cursor",N="indent",O="align",P="trim",B="group",k="fill",_="if-break",v="indent-if-break",L="line-suffix",I="line-suffix-boundary",g="line",S="label",w="break-parent",Ue=new Set([j,N,O,P,B,k,_,v,L,I,g,S,w]);var Bu=(e,t,r)=>{if(!(e&&t==null))return Array.isArray(t)||typeof t=="string"?t[r<0?t.length+r:r]:t.at(r)},y=Bu;function or(e){let t=e.length;for(;t>0&&(e[t-1]==="\r"||e[t-1]===`
`);)t--;return t<e.length?e.slice(0,t):e}function _u(e){if(typeof e=="string")return W;if(Array.isArray(e))return Y;if(!e)return;let{type:t}=e;if(Ue.has(t))return t}var M=_u;var xu=e=>new Intl.ListFormat("en-US",{type:"disjunction"}).format(e);function wu(e){let t=e===null?"null":typeof e;if(t!=="string"&&t!=="object")return`Unexpected doc '${t}',
Expected it to be 'string' or 'object'.`;if(M(e))throw new Error("doc is valid.");let r=Object.prototype.toString.call(e);if(r!=="[object Object]")return`Unexpected doc '${r}'.`;let n=xu([...Ue].map(u=>`'${u}'`));return`Unexpected doc.type '${e.type}'.
Expected it to be ${n}.`}var ht=class extends Error{name="InvalidDocError";constructor(t){super(wu(t)),this.doc=t}},q=ht;var ir={};function bu(e,t,r,n){let u=[e];for(;u.length>0;){let o=u.pop();if(o===ir){r(u.pop());continue}r&&u.push(o,ir);let i=M(o);if(!i)throw new q(o);if((t==null?void 0:t(o))!==!1)switch(i){case Y:case k:{let s=i===Y?o:o.parts;for(let a=s.length,c=a-1;c>=0;--c)u.push(s[c]);break}case _:u.push(o.flatContents,o.breakContents);break;case B:if(n&&o.expandedStates)for(let s=o.expandedStates.length,a=s-1;a>=0;--a)u.push(o.expandedStates[a]);else u.push(o.contents);break;case O:case N:case v:case S:case L:u.push(o.contents);break;case W:case j:case P:case I:case g:case w:break;default:throw new q(o)}}}var le=bu;function be(e,t){if(typeof e=="string")return t(e);let r=new Map;return n(e);function n(o){if(r.has(o))return r.get(o);let i=u(o);return r.set(o,i),i}function u(o){switch(M(o)){case Y:return t(o.map(n));case k:return t({...o,parts:o.parts.map(n)});case _:return t({...o,breakContents:n(o.breakContents),flatContents:n(o.flatContents)});case B:{let{expandedStates:i,contents:s}=o;return i?(i=i.map(n),s=i[0]):s=n(s),t({...o,contents:s,expandedStates:i})}case O:case N:case v:case S:case L:return t({...o,contents:n(o.contents)});case W:case j:case P:case I:case g:case w:return t(o);default:throw new q(o)}}}function Ve(e,t,r){let n=r,u=!1;function o(i){if(u)return!1;let s=t(i);s!==void 0&&(u=!0,n=s)}return le(e,o),n}function ku(e){if(e.type===B&&e.break||e.type===g&&e.hard||e.type===w)return!0}function Dr(e){return Ve(e,ku,!1)}function sr(e){if(e.length>0){let t=y(!1,e,-1);!t.expandedStates&&!t.break&&(t.break="propagated")}return null}function cr(e){let t=new Set,r=[];function n(o){if(o.type===w&&sr(r),o.type===B){if(r.push(o),t.has(o))return!1;t.add(o)}}function u(o){o.type===B&&r.pop().break&&sr(r)}le(e,n,u,!0)}function Su(e){return e.type===g&&!e.hard?e.soft?"":" ":e.type===_?e.flatContents:e}function fr(e){return be(e,Su)}function ar(e){for(e=[...e];e.length>=2&&y(!1,e,-2).type===g&&y(!1,e,-1).type===w;)e.length-=2;if(e.length>0){let t=we(y(!1,e,-1));e[e.length-1]=t}return e}function we(e){switch(M(e)){case N:case v:case B:case L:case S:{let t=we(e.contents);return{...e,contents:t}}case _:return{...e,breakContents:we(e.breakContents),flatContents:we(e.flatContents)};case k:return{...e,parts:ar(e.parts)};case Y:return ar(e);case W:return or(e);case O:case j:case P:case I:case g:case w:break;default:throw new q(e)}return e}function $e(e){return we(Nu(e))}function Tu(e){switch(M(e)){case k:if(e.parts.every(t=>t===""))return"";break;case B:if(!e.contents&&!e.id&&!e.break&&!e.expandedStates)return"";if(e.contents.type===B&&e.contents.id===e.id&&e.contents.break===e.break&&e.contents.expandedStates===e.expandedStates)return e.contents;break;case O:case N:case v:case L:if(!e.contents)return"";break;case _:if(!e.flatContents&&!e.breakContents)return"";break;case Y:{let t=[];for(let r of e){if(!r)continue;let[n,...u]=Array.isArray(r)?r:[r];typeof n=="string"&&typeof y(!1,t,-1)=="string"?t[t.length-1]+=n:t.push(n),t.push(...u)}return t.length===0?"":t.length===1?t[0]:t}case W:case j:case P:case I:case g:case S:case w:break;default:throw new q(e)}return e}function Nu(e){return be(e,t=>Tu(t))}function lr(e,t=We){return be(e,r=>typeof r=="string"?ke(t,r.split(`
`)):r)}function Ou(e){if(e.type===g)return!0}function Fr(e){return Ve(e,Ou,!1)}function Fe(e,t){return e.type===S?{...e,contents:t(e.contents)}:t(e)}var gt=()=>{},K=gt,yt=gt,pr=gt;function ie(e){return K(e),{type:N,contents:e}}function oe(e,t){return K(t),{type:O,contents:t,n:e}}function At(e,t={}){return K(e),yt(t.expandedStates,!0),{type:B,id:t.id,contents:e,break:!!t.shouldBreak,expandedStates:t.expandedStates}}function dr(e){return oe(Number.NEGATIVE_INFINITY,e)}function mr(e){return oe({type:"root"},e)}function Er(e){return oe(-1,e)}function Cr(e,t){return At(e[0],{...t,expandedStates:e})}function hr(e){return pr(e),{type:k,parts:e}}function gr(e,t="",r={}){return K(e),t!==""&&K(t),{type:_,breakContents:e,flatContents:t,groupId:r.groupId}}function yr(e,t){return K(e),{type:v,contents:e,groupId:t.groupId,negate:t.negate}}function Se(e){return K(e),{type:L,contents:e}}var Ar={type:I},pe={type:w},Br={type:P},Te={type:g,hard:!0},Bt={type:g,hard:!0,literal:!0},Me={type:g},_r={type:g,soft:!0},z=[Te,pe],We=[Bt,pe],X={type:j};function ke(e,t){K(e),yt(t);let r=[];for(let n=0;n<t.length;n++)n!==0&&r.push(e),r.push(t[n]);return r}function Ge(e,t,r){K(e);let n=e;if(t>0){for(let u=0;u<Math.floor(t/r);++u)n=ie(n);n=oe(t%r,n),n=oe(Number.NEGATIVE_INFINITY,n)}return n}function xr(e,t){return K(t),e?{type:S,label:e,contents:t}:t}function Q(e){var t;if(!e)return"";if(Array.isArray(e)){let r=[];for(let n of e)if(Array.isArray(n))r.push(...Q(n));else{let u=Q(n);u!==""&&r.push(u)}return r}return e.type===_?{...e,breakContents:Q(e.breakContents),flatContents:Q(e.flatContents)}:e.type===B?{...e,contents:Q(e.contents),expandedStates:(t=e.expandedStates)==null?void 0:t.map(Q)}:e.type===k?{type:"fill",parts:e.parts.map(Q)}:e.contents?{...e,contents:Q(e.contents)}:e}function wr(e){let t=Object.create(null),r=new Set;return n(Q(e));function n(o,i,s){var a,c;if(typeof o=="string")return JSON.stringify(o);if(Array.isArray(o)){let D=o.map(n).filter(Boolean);return D.length===1?D[0]:`[${D.join(", ")}]`}if(o.type===g){let D=((a=s==null?void 0:s[i+1])==null?void 0:a.type)===w;return o.literal?D?"literalline":"literallineWithoutBreakParent":o.hard?D?"hardline":"hardlineWithoutBreakParent":o.soft?"softline":"line"}if(o.type===w)return((c=s==null?void 0:s[i-1])==null?void 0:c.type)===g&&s[i-1].hard?void 0:"breakParent";if(o.type===P)return"trim";if(o.type===N)return"indent("+n(o.contents)+")";if(o.type===O)return o.n===Number.NEGATIVE_INFINITY?"dedentToRoot("+n(o.contents)+")":o.n<0?"dedent("+n(o.contents)+")":o.n.type==="root"?"markAsRoot("+n(o.contents)+")":"align("+JSON.stringify(o.n)+", "+n(o.contents)+")";if(o.type===_)return"ifBreak("+n(o.breakContents)+(o.flatContents?", "+n(o.flatContents):"")+(o.groupId?(o.flatContents?"":', ""')+`, { groupId: ${u(o.groupId)} }`:"")+")";if(o.type===v){let D=[];o.negate&&D.push("negate: true"),o.groupId&&D.push(`groupId: ${u(o.groupId)}`);let p=D.length>0?`, { ${D.join(", ")} }`:"";return`indentIfBreak(${n(o.contents)}${p})`}if(o.type===B){let D=[];o.break&&o.break!=="propagated"&&D.push("shouldBreak: true"),o.id&&D.push(`id: ${u(o.id)}`);let p=D.length>0?`, { ${D.join(", ")} }`:"";return o.expandedStates?`conditionalGroup([${o.expandedStates.map(l=>n(l)).join(",")}]${p})`:`group(${n(o.contents)}${p})`}if(o.type===k)return`fill([${o.parts.map(D=>n(D)).join(", ")}])`;if(o.type===L)return"lineSuffix("+n(o.contents)+")";if(o.type===I)return"lineSuffixBoundary";if(o.type===S)return`label(${JSON.stringify(o.label)}, ${n(o.contents)})`;if(o.type===j)return"cursor";throw new Error("Unknown doc type "+o.type)}function u(o){if(typeof o!="symbol")return JSON.stringify(String(o));if(o in t)return t[o];let i=o.description||"symbol";for(let s=0;;s++){let a=i+(s>0?` #${s}`:"");if(!r.has(a))return r.add(a),t[o]=`Symbol.for(${JSON.stringify(a)})`}}}var br=()=>/[#*0-9]\uFE0F?\u20E3|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26AA\u26B0\u26B1\u26BD\u26BE\u26C4\u26C8\u26CF\u26D1\u26E9\u26F0-\u26F5\u26F7\u26F8\u26FA\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2757\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B55\u3030\u303D\u3297\u3299]\uFE0F?|[\u261D\u270C\u270D](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\u270A\u270B](?:\uD83C[\uDFFB-\uDFFF])?|[\u23E9-\u23EC\u23F0\u23F3\u25FD\u2693\u26A1\u26AB\u26C5\u26CE\u26D4\u26EA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2795-\u2797\u27B0\u27BF\u2B50]|\u26D3\uFE0F?(?:\u200D\uD83D\uDCA5)?|\u26F9(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\u2764\uFE0F?(?:\u200D(?:\uD83D\uDD25|\uD83E\uDE79))?|\uD83C(?:[\uDC04\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF9Line truncated
`?te(!1,f,`
`,u):f;s.push(d),i.length>0&&(o+=Ne(d));break}case Y:for(let d=f.length-1;d>=0;d--)i.push({ind:l,mode:F,doc:f[d]});break;case j:if(D>=2)throw new Error("There are too many 'cursor' in doc.");s.push(de),D++;break;case N:i.push({ind:Lu(l,t),mode:F,doc:f.contents});break;case O:i.push({ind:Iu(l,f.n,t),mode:F,doc:f.contents});break;case P:o-=wt(s);break;case B:switch(F){case H:if(!a){i.push({ind:l,mode:f.break?R:H,doc:f.contents});break}case R:{a=!1;let d={ind:l,mode:H,doc:f.contents},m=n-o,C=c.length>0;if(!f.break&&Ke(d,i,m,C,r))i.push(d);else if(f.expandedStates){let E=y(!1,f.expandedStates,-1);if(f.break){i.push({ind:l,mode:R,doc:E});break}else for(let h=1;h<f.expandedStates.length+1;h++)if(h>=f.expandedStates.length){i.push({ind:l,mode:R,doc:E});break}else{let x=f.expandedStates[h],A={ind:l,mode:H,doc:x};if(Ke(A,i,m,C,r)){i.push(A);break}}}else i.push({ind:l,mode:R,doc:f.contents});break}}f.id&&(r[f.id]=y(!1,i,-1).mode);break;case k:{let d=n-o,m=f[_t]??0,{parts:C}=f,E=C.length-m;if(E===0)break;let h=C[m+0],x=C[m+1],A={ind:l,mode:H,doc:h},$={ind:l,mode:R,doc:h},ue=Ke(A,[],d,c.length>0,r,!0);if(E===1){ue?i.push(A):i.push($);break}let Be={ind:l,mode:H,doc:x},lt={ind:l,mode:R,doc:x};if(E===2){ue?i.push(Be,A):i.push(lt,$);break}let lu=C[m+2],Ft={ind:l,mode:F,doc:{...f,[_t]:m+2}};Ke({ind:l,mode:H,doc:[h,x,lu]},[],d,c.length>0,r,!0)?i.push(Ft,Be,A):ue?i.push(Ft,lt,A):i.push(Ft,lt,$);break}case _:case v:{let d=f.groupId?r[f.groupId]:F;if(d===R){let m=f.type===_?f.breakContents:f.negate?f.contents:ie(f.contents);m&&i.push({ind:l,mode:F,doc:m})}if(d===H){let m=f.type===_?f.flatContents:f.negate?ie(f.contents):f.contents;m&&i.push({ind:l,mode:F,doc:m})}break}case L:c.push({ind:l,mode:F,doc:f.contents});break;case I:c.length>0&&i.push({ind:l,mode:F,doc:Te});break;case g:switch(F){case H:if(f.hard)a=!0;else{f.soft||(s.push(" "),o+=1);break}case R:if(c.length>0){i.push({ind:l,mode:F,doc:f},...c.reverse()),c.length=0;break}f.literal?l.root?(s.push(u,l.root.value),o=l.root.length):(s.push(u),o=0):(o-=wt(s),s.push(u+l.value),o=l.length);break}break;case S:i.push({ind:l,mode:F,doc:f.contents});break;case w:break;default:throw new q(f)}i.length===0&&c.length>0&&(i.push(...c.reverse()),c.length=0)}let p=s.indexOf(de);if(p!==-1){let l=s.indexOf(de,p+1);if(l===-1)return{formatted:s.filter(m=>m!==de).join("")};let F=s.slice(0,p).join(""),f=s.slice(p+1,l).join(""),d=s.slice(l+1).join("");return{formatted:F+f+d,cursorNodeStart:F.length,cursorNodeText:f}}return{formatted:s.join("")}}function Ru(e,t,r=0){let n=0;for(let u=r;u<e.length;++u)e[u]===" "?n=n+t-n%t:n++;return n}var Ee=Ru;var Z,kt,ze,bt=class{constructor(t){tr(this,Z);this.stack=[t]}get key(){let{stack:t,siblings:r}=this;return y(!1,t,r===null?-2:-4)??null}get index(){return this.siblings===null?null:y(!1,this.stack,-2)}get node(){return y(!1,this.stack,-1)}get parent(){return this.getNode(1)}get grandparent(){return this.getNode(2)}get isInArray(){return this.siblings!==null}get siblings(){let{stack:t}=this,r=y(!1,t,-3);return Array.isArray(r)?r:null}get next(){let{siblings:t}=this;return t===null?null:t[this.index+1]}get previous(){let{siblings:t}=this;return t===null?null:t[this.index-1]}get isFirst(){return this.index===0}get isLast(){let{siblings:t,index:r}=this;return t!==null&&r===t.length-1}get isRoot(){return this.stack.length===1}get root(){return this.stack[0]}get ancestors(){return[...fe(this,Z,ze).call(this)]}getName(){let{stack:t}=this,{length:r}=t;return r>1?y(!1,t,-2):null}getValue(){return y(!1,this.stack,-1)}getNode(t=0){let r=fe(this,Z,kt).call(this,t);return r===-1?null:this.stack[r]}getParentNode(t=0){return this.getNode(t+1)}call(t,...r){let{stack:n}=this,{length:u}=n,o=y(!1,n,-1);for(let i of r)o=o[i],n.push(i,o);try{return t(this)}finally{n.length=u}}callParent(t,r=0){let n=fe(this,Z,kt).call(this,r+1),u=this.stack.splice(n+1);try{return t(this)}finally{this.stack.push(...u)}}each(t,...r){let{stack:n}=this,{length:u}=n,o=y(!1,n,-1);for(let i of r)o=o[i],n.push(i,o);try{for(let i=0;i<o.length;++i)n.push(i,o[i]),t(this,i,o),n.length-=2}finally{n.length=u}}map(t,...r){let n=[];return this.each((u,o,i)=>{n[o]=t(u,o,i)},...r),n}match(...t){let r=this.stack.length-1,n=null,u=this.stack[r--];for(let o of t){if(u===void 0)return!1;let i=null;if(typeof n=="number"&&(i=n,n=this.stack[r--],u=this.stack[r--]),o&&!o(u,n,i))return!1;n=this.stack[r--],u=this.stack[r--]}return!0}findAncestor(t){for(let r of fe(this,Z,ze).call(this))if(t(r))return r}hasAncestor(t){for(let r of fe(this,Z,ze).call(this))if(t(r))return!0;return!1}};Z=new WeakSet,kt=function(t){let{stack:r}=this;for(let n=r.length-1;n>=0;n-=2)if(!Array.isArray(r[n])&&--t<0)return n;return-1},ze=function*(){let{stack:t}=this;for(let r=t.length-3;r>=0;r-=2){let n=t[r];Array.isArray(n)||(yield n)}};var Or=bt;var Pr=new Proxy(()=>{},{get:()=>Pr}),Oe=Pr;function Yu(e){return e!==null&&typeof e=="object"}var vr=Yu;function*Ce(e,t){let{getVisitorKeys:r,filter:n=()=>!0}=t,u=o=>vr(o)&&n(o);for(let o of r(e)){letLine truncated
`)return t-2;if(u===`
`||u==="\r"||u==="\u2028"||u==="\u2029")return t-1}else{if(u==="\r"&&e.charAt(t+1)===`
`)return t+2;if(u===`
`||u==="\r"||u==="\u2028"||u==="\u2029")return t+1}return t}var U=ju;function Uu(e,t,r={}){let n=T(e,r.backwards?t-1:t,r),u=U(e,n,r);return n!==u}var G=Uu;function Vu(e){return Array.isArray(e)&&e.length>0}var qe=Vu;var Yr=new Set(["tokens","comments","parent","enclosingNode","precedingNode","followingNode"]),$u=e=>Object.keys(e).filter(t=>!Yr.has(t));function Wu(e){return e?t=>e(t,Yr):$u}var J=Wu;function Mu(e){let t=e.type||e.kind||"(unknown type)",r=String(e.name||e.id&&(typeof e.id=="object"?e.id.name:e.id)||e.key&&(typeof e.key=="object"?e.key.name:e.key)||e.value&&(typeof e.value=="object"?"":String(e.value))||e.operator||"");return r.length>20&&(r=r.slice(0,19)+"\u2026"),t+(r?" "+r:"")}function St(e,t){(e.comments??(e.comments=[])).push(t),t.printed=!1,t.nodeDescription=Mu(e)}function se(e,t){t.leading=!0,t.trailing=!1,St(e,t)}function ee(e,t,r){t.leading=!1,t.trailing=!1,r&&(t.marker=r),St(e,t)}function ae(e,t){t.leading=!1,t.trailing=!0,St(e,t)}var Tt=new WeakMap;function Xe(e,t){if(Tt.has(e))return Tt.get(e);let{printer:{getCommentChildNodes:r,canAttachComment:n,getVisitorKeys:u},locStart:o,locEnd:i}=t;if(!n)return[];let s=((r==null?void 0:r(e,t))??[...Ce(e,{getVisitorKeys:J(u)})]).flatMap(a=>n(a)?[a]:Xe(a,t));return s.sort((a,c)=>o(a)-o(c)||i(a)-i(c)),Tt.set(e,s),s}function Ur(e,t,r,n){let{locStart:u,locEnd:o}=r,i=u(t),s=o(t),a=Xe(e,r),c,D,p=0,l=a.length;for(;p<l;){let F=p+l>>1,f=a[F],d=u(f),m=o(f);if(d<=i&&s<=m)return Ur(f,t,r,f);if(m<=i){c=f,p=F+1;continue}if(s<=d){D=f,l=F;continue}throw new Error("Comment location overlaps with node location")}if((n==null?void 0:n.type)==="TemplateLiteral"){let{quasis:F}=n,f=Ot(F,t,r);c&&Ot(F,c,r)!==f&&(c=null),D&&Ot(F,D,r)!==f&&(D=null)}return{enclosingNode:n,precedingNode:c,followingNode:D}}var Nt=()=>!1;function Vr(e,t){let{comments:r}=e;if(delete e.comments,!qe(r)||!t.printer.canAttachComment)return;let n=[],{printer:{experimentalFeatures:{avoidAstMutation:u=!1}={},handleComments:o={}},originalText:i}=t,{ownLine:s=Nt,endOfLine:a=Nt,remaining:c=Nt}=o,D=r.map((p,l)=>({...Ur(e,p,t),comment:p,text:i,options:t,ast:e,isLastComment:r.length-1===l}));for(let[p,l]of D.entries()){let{comment:F,precedingNode:f,enclosingNode:d,followingNode:m,text:C,options:E,ast:h,isLastComment:x}=l,A;if(u?A=[l]:(F.enclosingNode=d,F.precedingNode=f,F.followingNode=m,A=[F,C,E,h,x]),Gu(C,E,D,p))F.placement="ownLine",s(...A)||(m?se(m,F):f?ae(f,F):d?ee(d,F):ee(h,F));else if(Ku(C,E,D,p))F.placement="endOfLine",a(...A)||(f?ae(f,F):m?se(m,F):d?ee(d,F):ee(h,F));else if(F.placement="remaining",!c(...A))if(f&&m){let $=n.length;$>0&&n[$-1].followingNode!==m&&jr(n,E),n.push(l)}else f?ae(f,F):m?se(m,F):d?ee(d,F):ee(h,F)}if(jr(n,t),!u)for(let p of r)delete p.precedingNode,delete p.enclosingNode,delete p.followingNode}var $r=e=>!/[\S\n\u2028\u2029]/u.test(e);function Gu(e,t,r,n){let{comment:u,precedingNode:o}=r[n],{locStart:i,locEnd:s}=t,a=i(u);if(o)for(let c=n-1;c>=0;c--){let{comment:D,precedingNode:p}=r[c];if(p!==o||!$r(e.slice(s(D),a)))break;a=i(D)}return G(e,a,{backwards:!0})}function Ku(e,t,r,n){let{comment:u,followingNode:o}=r[n],{locStart:i,locEnd:s}=t,a=s(u);if(o)for(let c=n+1;c<r.length;c++){let{comment:D,followingNode:p}=r[c];if(p!==o||!$r(e.slice(a,i(D))))break;a=s(D)}return G(e,a)}function jr(e,t){var s,a;let r=e.length;if(r===0)return;let{precedingNode:n,followingNode:u}=e[0],o=t.locStart(u),i;for(i=r;i>0;--i){let{comment:c,precedingNode:D,followingNode:p}=e[i-1];Oe.strictEqual(D,n),Oe.strictEqual(p,u);let l=t.originalText.slice(t.locEnd(c),o);if(((a=(s=t.printer).isGap)==null?void 0:a.call(s,l,t))??/^[\s(]*$/u.test(l))o=t.locStart(c);else break}for(let[c,{comment:D}]of e.entries())c<i?ae(n,D):se(u,D);for(let c of[n,u])c.comments&&c.comments.length>1&&c.comments.sort((D,p)=>t.locStart(D)-t.locStart(p));e.length=0}function Ot(e,t,r){let n=r.locStart(t)-1;for(let u=1;u<e.length;++u)if(n<r.locStart(e[u]))return u-1;return 0}function zu(e,t){let r=t-1;r=T(e,r,{backwards:!0}),r=U(e,r,{backwards:!0}),r=T(e,r,{backwards:!0});let n=U(e,r,{backwards:!0});return r!==n}var Pe=zu;function Wr(e,t){let r=e.node;return r.printed=!0,t.printer.printComment(e,t)}function Hu(e,t){var D;let r=e.node,n=[Wr(e,t)],{printer:u,originalText:o,locStart:i,locEnd:s}=t;if((D=u.isBlockComment)==null?void 0:D.call(u,r)){let p=G(o,s(r))?G(o,i(r),{backwards:!0})?z:Me:" ";n.push(p)}else n.push(z);let c=U(o,T(o,s(r)));return c!==!1&&G(o,c)&&n.push(z),n}function Ju(e,t,r){var c;let n=e.node,u=Wr(e,t),{printer:o,originalText:i,locStart:s}=t,a=(c=o.isBlockComment)==null?void 0:c.call(o,n);if(r!=null&&r.hasLineSuffix&&!(r!=null&&r.isBlock)||G(i,s(n),{backwards:!0})){let D=Pe(i,s(n));return{doc:Se([z,D?z:"",u]),isBlock:a,hasLineSuffix:!0}}return!a||r!=null&&r.hasLineSuffix?{doc:[Se([" ",u]),pe],isBlock:a,hasLineSuffix:!0}:{doc:[" ",u],isBlock:a,hasLineSuffix:!1}}function qu(e,t){let r=e.node;if(!r)return{};let n=t[Symbol.for("printedComments")];if((r.comments||[]).filter(a=>!n.has(a)).length===0)return{leading:"",trailing:""Line truncated
(mixed values within one file are normalised by looking at what's used after the first line)`}]},filepath:{category:"Special",type:"path",description:"Specify the input filepath. This will be used to do parser inference.",cliName:"stdin-filepath",cliCategory:"Other",cliDescription:"Path to the file to pretend that stdin comes from."},insertPragma:{category:"Special",type:"boolean",default:!1,description:"Insert @format pragma into file's first docblock comment.",cliCategory:"Other"},parser:{category:"Global",type:"choice",default:void 0,description:"Which parser to use.",exception:e=>typeof e=="string"||typeof e=="function",choices:[{value:"flow",description:"Flow"},{value:"babel",description:"JavaScript"},{value:"babel-flow",description:"Flow"},{value:"babel-ts",description:"TypeScript"},{value:"typescript",description:"TypeScript"},{value:"acorn",description:"JavaScript"},{value:"espree",description:"JavaScript"},{value:"meriyah",description:"JavaScript"},{value:"css",description:"CSS"},{value:"less",description:"Less"},{value:"scss",description:"SCSS"},{value:"json",description:"JSON"},{value:"json5",description:"JSON5"},{value:"jsonc",description:"JSON with Comments"},{value:"json-stringify",description:"JSON.stringify"},{value:"graphql",description:"GraphQL"},{value:"markdown",description:"Markdown"},{value:"mdx",description:"MDX"},{value:"vue",description:"Vue"},{value:"yaml",description:"YAML"},{value:"glimmer",description:"Ember / Handlebars"},{value:"html",description:"HTML"},{value:"angular",description:"Angular"},{value:"lwc",description:"Lightning Web Components"},{value:"mjml",description:"MJML"}]},plugins:{type:"path",array:!0,default:[{value:[]}],category:"Global",description:"Add a plugin. Multiple plugins can be passed as separate `--plugin`s.",exception:e=>typeof e=="string"||typeof e=="object",cliName:"plugin",cliCategory:"Config"},printWidth:{category:"Global",type:"int",default:80,description:"The line length where Prettier will try wrap.",range:{start:0,end:1/0,step:1}},rangeEnd:{category:"Special",type:"int",default:1/0,range:{start:0,end:1/0,step:1},description:`Format code ending at a given character offset (exclusive).
The range will extend forwards to the end of the selected statement.`,cliCategory:"Editor"},rangeStart:{category:"Special",type:"int",default:0,range:{start:0,end:1/0,step:1},description:`Format code starting at a given character offset.
The range will extend backwards to the start of the first line containing the selected statement.`,cliCategory:"Editor"},requirePragma:{category:"Special",type:"boolean",default:!1,description:"Require either '@prettier' or '@format' to be present in the file's first docblock comment in order for it to be formatted.",cliCategory:"Other"},tabWidth:{type:"int",category:"Global",default:2,description:"Number of spaces per indentation level.",range:{start:0,end:1/0,step:1}},useTabs:{category:"Global",type:"boolean",default:!1,description:"Indent with tabs instead of spaces."},embeddedLanguageFormatting:{category:"Global",type:"choice",default:"auto",description:"Control how Prettier formats quoted code embedded in the file.",choices:[{value:"auto",description:"Format embedded code if Prettier can automatically identify it."},{value:"off",description:"Never automatically format embedded code."}]}};function Qe({plugins:e=[],showDeprecated:t=!1}={}){let r=e.flatMap(u=>u.languages??[]),n=[];for(let u of Zu(Object.assign({},...e.map(({options:o})=>o),zr)))!t&&u.deprecated||(Array.isArray(u.choices)&&(t||(u.choices=u.choices.filter(o=>!o.deprecated)),u.name==="parser"&&(u.choices=[...u.choices,...Qu(u.choices,r,e)])),u.pluginDefaults=Object.fromEntries(e.filter(o=>{var i;return((i=o.defaultOptions)==null?void 0:i[u.name])!==void 0}).map(o=>[o.name,o.defaultOptions[u.name]])),n.push(u));return{languages:r,options:n}}function*Qu(e,t,r){let n=new Set(e.map(u=>u.value));for(let u of t)if(u.parsers){for(let o of u.parsers)if(!n.has(o)){n.add(o);let i=r.find(a=>a.parsers&&Object.prototype.hasOwnProperty.call(a.parsers,o)),s=u.name;i!=null&&i.name&&(s+=` (plugin: ${i.name})`),yield{value:o,description:s}}}}function Zu(e){let t=[];for(let[r,n]of Object.entries(e)){let u={name:r,...n};Array.isArray(u.default)&&(u.default=y(!1,u.default,-1).value),t.push(u)}return t}var eo=(e,t)=>{if(!(e&&t==null))return t.toReversed||!Array.isArray(t)?t.toReversed():[...t].reverse()},Hr=eo;var Jr,qr,Xr,Qr,Zr,to=((Jr=globalThis.Deno)==null?void 0:Jr.build.os)==="windows"||((Xr=(qr=globalThis.navigator)==null?void 0:qr.platform)==null?void 0:Xr.startsWith("Win"))||((Zr=(Qr=globalThis.process)==null?void 0:Qr.platform)==null?void 0:Zr.startsWith("win"))||!1;function en(e){if(e=e instanceof URL?e:new URL(e),e.protocol!=="file:")throw new TypeError(`URL must be a file URL: received "${e.protocol}"`);return e}function ro(e){return e=en(e),decodeURIComponent(e.pathname.replace(/%(?![0-9A-Fa-f]{2})/g,"%25"))}function no(e){e=en(e);let t=decodeURIComponent(e.pathname.replace(/\//g,"\\").replace(/%(?![0-9A-Fa-f]{2})/g,"%25")).replace(/^\\*([A-Za-z]:)(\\|$)/,"$1\\");return e.hostname!==""&&(t=`\\\\${e.hostname}${t}`),t}function tn(e){return to?no(e):ro(e)}var rn=tn;var uo=e=>String(e).split(/[/\\]/u).pop();function nn(e,t){if(!t)return;let r=uo(t).toLowerCase();return e.find(({filenames:n})=>n==null?void 0:n.some(u=>u.toLowerCase()===r))??e.find(({extensions:n})=>n==null?void 0:n.some(u=>r.endsWith(u)))}function oo(e,t){if(t)return e.find(({name:r})=>r.toLowerCase()===t)??e.find(({aliases:r})=>r==null?void 0:r.includes(t))??e.find(({extensions:r})=>r==null?void 0:r.includes(`.${t}`))}function un(e,t){if(t){if(String(t).startsWith("file:"))try{t=rn(t)}catch{return}if(typeof t=="string")return e.find(({isSupported:r})=>r==null?void 0:r({filepath:t}))}}function io(e,t){let r=Hr(!1,e.plugins).flatMap(u=>u.languages??[]),n=oo(r,t.language)??nn(r,t.physicalFile)??nn(r,t.file)??un(r,t.physicalFile)??un(r,t.file)??(t.physicalFile,void 0);return n==null?void 0:n.parsers[0]}var on=io;var re={key:e=>/^[$_a-zA-Z][$_a-zA-Z0-9]*$/.test(e)?e:JSON.stringify(e),value(e){if(e===null||typeof e!="object")return JSON.stringify(e);if(Array.isArray(e))return`[${e.map(r=>re.value(r)).join(", ")}]`;let t=Object.keys(e);return t.length===0?"{}":`{ ${t.map(r=>`${re.key(r)}: ${re.value(e[r])}`).join(", ")} }`},pair:({key:e,value:t})=>re.value({[e]:t})};var sn=new Proxy(String,{get:()=>sn}),V=sn;var an=(e,t,{descriptor:r})=>{let n=[`${V.yellow(typeof e=="string"?r.key(e):r.pair(e))} is deprecated`];return t&&n.push(`we now treat it as ${V.blue(typeof t=="string"?r.key(t):r.pair(t))}`),n.join("; ")+"."};var Ze=Symbol.for("vnopts.VALUE_NOT_EXIST"),ge=Symbol.for("vnopts.VALUE_UNCHANGED");var Dn=" ".repeat(2),fn=(e,t,r)=>{let{text:n,list:u}=r.normalizeExpectedResult(r.schemas[e].expected(r)),o=[];return n&&o.push(cn(e,t,n,r.descriptor)),u&&o.push([cn(e,t,u.title,r.descriptor)].concat(u.values.map(i=>ln(i,r.loggerPrintWidth))).join(`
`)),Fn(o,r.loggerPrintWidth)};function cn(e,t,r,n){return[`Invalid ${V.red(n.key(e))} value.`,`Expected ${V.blue(r)},`,`but received ${t===Ze?V.gray("nothing"):V.red(n.value(t))}.`].join(" ")}function ln({text:e,list:t},r){let n=[];return e&&n.push(`- ${V.blue(e)}`),t&&n.push([`- ${V.blue(t.title)}:`].concat(t.values.map(u=>ln(u,r-Dn.length).replace(/^|\n/g,`$&${Dn}`))).join(`
`)),Fn(n,r)}function Fn(e,t){if(e.length===1)return e[0];let[r,n]=e,[u,o]=e.map(i=>i.split(`
`,1)[0].length);return u>t&&u>o?n:r}var Pt=[],pn=[];function vt(e,t){if(e===t)return 0;let r=e;e.length>t.length&&(e=t,t=r);let n=e.length,u=t.length;for(;n>0&&e.charCodeAt(~-n)===t.charCodeAt(~-u);)n--,u--;let o=0;for(;o<n&&e.charCodeAt(o)===t.charCodeAt(o);)o++;if(n-=o,u-=o,n===0)return u;let i,s,a,c,D=0,p=0;for(;D<n;)pn[D]=e.charCodeAt(o+D),Pt[D]=++D;for(;p<u;)for(i=t.charCodeAt(o+p),a=p++,s=p,D=0;D<n;D++)c=i===pn[D]?a:a+1,a=Pt[D],s=Pt[D]=a>s?c>s?s+1:c:c>a?a+1:c;return s}var et=(e,t,{descriptor:r,logger:n,schemas:u})=>{let o=[`Ignored unknown option ${V.yellow(r.pair({key:e,value:t}))}.`],i=Object.keys(u).sort().find(s=>vt(e,s)<3);i&&o.push(`Did you mean ${V.blue(r.key(i))}?`),n.warn(o.join(" "))};var so=["default","expected","validate","deprecated","forward","redirect","overlap","preprocess","postprocess"];function ao(e,t){let r=new e(t),n=Object.create(r);for(let u of so)u in t&&(n[u]=Do(t[u],r,b.prototype[u].length));return n}var b=class{static create(t){return ao(this,t)}constructor(t){this.name=t.name}default(t){}expected(t){return"nothing"}validate(t,r){return!1}deprecated(t,r){return!1}forward(t,r){}redirect(t,r){}overlap(t,r,n){return t}preprocess(t,r){return t}postprocess(t,r){return ge}};function Do(e,t,r){return typeof e=="function"?(...n)=>e(...n.slice(0,r-1),t,...n.slice(r-1)):()=>e}var tt=class extends b{constructor(t){super(t),this._sourceName=t.sourceName}expected(t){return t.schemas[this._sourceName].expected(t)}validate(t,r){return r.schemas[this._sourceName].validate(t,r)}redirect(t,r){return this._sourceName}};var rt=class extends b{expected(){return"anything"}validate(){return!0}};var nt=class extends b{constructor({valueSchema:t,name:r=t.name,...n}){super({...n,name:r}),this._valueSchema=t}expected(t){let{text:r,list:n}=t.normalizeExpectedResult(this._valueSchema.expected(t));return{text:r&&`an array of ${r}`,list:n&&{title:"an array of the following values",values:[{list:n}]}}}validate(t,r){if(!Array.isArray(t))return!1;let n=[];for(let u of t){let o=r.normalizeValidateResult(this._valueSchema.validate(u,r),u);o!==!0&&n.push(o.value)}return n.length===0?!0:{value:n}}deprecated(t,r){let n=[];for(let u of t){let o=r.normalizeDeprecatedResult(this._valueSchema.deprecated(u,r),u);o!==!1&&n.push(...o.map(({value:i})=>({value:[i]})))}return n}forward(t,r){let n=[];for(let u of t){let o=r.normalizeForwardResult(this._valueSchema.forward(u,r),u);n.push(...o.map(dn))}return n}redirect(t,r){let n=[],u=[];for(let o of t){let i=r.normalizeRedirectResult(this._valueSchema.redirect(o,r),o);"remain"in i&&n.push(i.remain),u.push(...i.redirect.map(dn))}return n.length===0?{redirect:u}:{redirect:u,remain:n}}overlap(t,r){return t.concat(r)}};function dn({from:e,to:t}){return{from:[e],to:t}}var ut=class extends b{expected(){return"true or false"}validate(t){return typeof t=="boolean"}};function En(e,t){let r=Object.create(null);for(let n of e){let u=n[t];if(r[u])throw new Error(`Duplicate ${t} ${JSON.stringify(u)}`);r[u]=n}return r}function Cn(e,t){let r=new Map;for(let n of e){let u=n[t];if(r.has(u))throw new Error(`Duplicate ${t} ${JSON.stringify(u)}`);r.set(u,n)}return r}function hn(){let e=Object.create(null);return t=>{let r=JSON.stringify(t);return e[r]?!0:(e[r]=!0,!1)}}function gn(e,t){let r=[],n=[];for(let u of e)t(u)?r.push(u):n.push(u);return[r,n]}function yn(e){return e===Math.floor(e)}function An(e,t){if(e===t)return 0;let r=typeof e,n=typeof t,u=["undefined","object","boolean","number","string"];return r!==n?u.indexOf(r)-u.indexOf(n):r!=="string"?Number(e)-Number(t):e.localeCompare(t)}function Bn(e){return(...t)=>{let r=e(...t);return typeof r=="string"?new Error(r):r}}function Lt(e){return e===void 0?{}:e}function It(e){if(typeof e=="string")return{text:e};let{text:t,list:r}=e;return co((t||r)!==void 0,"Unexpected `expected` result, there should be at least one field."),r?{text:t,list:{title:r.title,values:r.values.map(It)}}:{text:t}}function Rt(e,t){return e===!0?!0:e===!1?{value:t}:e}function Yt(e,t,r=!1){return e===!1?!1:e===!0?r?!0:[{value:t}]:"value"in e?[e]:e.length===0?!1:e}function mn(e,t){return typeof e=="string"||"key"in e?{from:t,to:e}:"from"in e?{from:e.from,to:e.to}:{from:t,to:e.to}}function ot(e,t){return e===void 0?[]:Array.isArray(e)?e.map(r=>mn(r,t)):[mn(e,t)]}function jt(e,t){let r=ot(typeof e=="object"&&"redirect"in e?e.redirect:e,t);return r.length===0?{remain:t,redirect:r}:typeof e=="object"&&"remain"in e?{remain:e.remain,redirect:r}:{redirect:r}}function co(e,t){if(!e)throw new Error(t)}var it=class extends b{constructor(t){super(t),this._choices=Cn(t.choices.map(r=>r&&typeof r=="object"?r:{value:r}),"value")}expected({descriptor:t}){let r=Array.from(this._choices.keys()).map(i=>this._choices.get(i)).filter(({hidden:i})=>!i).map(i=>i.value).sort(An).map(t.value),n=r.slice(0,-2),u=r.slice(-2);return{text:n.concat(u.join(" or ")).join(", "),list:{title:"one of the following values",values:r}}}validate(t){return this._choices.has(t)}deprecated(t){let r=this._choices.Line truncated
`+n,e.codeFrame=n,e}throw e}var De=yo;async function Ln(e,t,r,n,u){let{embeddedLanguageFormatting:o,printer:{embed:i,hasPrettierIgnore:s=()=>!1,getVisitorKeys:a}}=r;if(!i||o!=="auto")return;if(i.length>2)throw new Error("printer.embed has too many parameters. The API changed in Prettier v3. Please update your plugin. See https://prettier.io/docs/plugins#optional-embed");let c=J(i.getVisitorKeys??a),D=[];F();let p=e.stack;for(let{print:f,node:d,pathStack:m}of D)try{e.stack=m;let C=await f(l,t,e,r);C&&u.set(d,C)}catch(C){if(globalThis.PRETTIER_DEBUG)throw C}e.stack=p;function l(f,d){return Bo(f,d,r,n)}function F(){let{node:f}=e;if(f===null||typeof f!="object"||s(e))return;for(let m of c(f))Array.isArray(f[m])?e.each(F,m):e.call(F,m);let d=i(e,r);if(d){if(typeof d=="function"){D.push({print:d,node:f,pathStack:[...e.stack]});return}u.set(f,d)}}}async function Bo(e,t,r,n){let u=await ne({...r,...t,parentParser:r.parser,originalText:e,cursorOffset:void 0,rangeStart:void 0,rangeEnd:void 0},{passThrough:!0}),{ast:o}=await De(e,u),i=await n(o,u);return $e(i)}function _o(e,t){let{originalText:r,[Symbol.for("comments")]:n,locStart:u,locEnd:o,[Symbol.for("printedComments")]:i}=t,{node:s}=e,a=u(s),c=o(s);for(let D of n)u(D)>=a&&o(D)<=c&&i.add(D);return r.slice(a,c)}var In=_o;async function Ye(e,t){({ast:e}=await Gt(e,t));let r=new Map,n=new Or(e),u=Kr(t),o=new Map;await Ln(n,s,t,Ye,o);let i=await Rn(n,t,s,void 0,o);if(Gr(t),t.cursorOffset>=0){if(t.nodeAfterCursor&&!t.nodeBeforeCursor)return[X,i];if(t.nodeBeforeCursor&&!t.nodeAfterCursor)return[i,X]}return i;function s(c,D){return c===void 0||c===n?a(D):Array.isArray(c)?n.call(()=>a(D),...c):n.call(()=>a(D),c)}function a(c){u(n);let D=n.node;if(D==null)return"";let p=D&&typeof D=="object"&&c===void 0;if(p&&r.has(D))return r.get(D);let l=Rn(n,t,s,c,o);return p&&r.set(D,l),l}}function Rn(e,t,r,n,u){var a;let{node:o}=e,{printer:i}=t,s;switch((a=i.hasPrettierIgnore)!=null&&a.call(i,e)?s=In(e,t):u.has(o)?s=u.get(o):s=i.print(e,t,r,n),o){case t.cursorNode:s=Fe(s,c=>[X,c,X]);break;case t.nodeBeforeCursor:s=Fe(s,c=>[c,X]);break;case t.nodeAfterCursor:s=Fe(s,c=>[X,c]);break}return i.printComment&&(!i.willPrintOwnComments||!i.willPrintOwnComments(e,t))&&(s=Mr(e,s,t)),s}async function Gt(e,t){let r=e.comments??[];t[Symbol.for("comments")]=r,t[Symbol.for("printedComments")]=new Set,Vr(e,t);let{printer:{preprocess:n}}=t;return e=n?await n(e,t):e,{ast:e,comments:r}}function xo(e,t){let{cursorOffset:r,locStart:n,locEnd:u}=t,o=J(t.printer.getVisitorKeys),i=F=>n(F)<=r&&u(F)>=r,s=e,a=[e];for(let F of Lr(e,{getVisitorKeys:o,filter:i}))a.push(F),s=F;if(Ir(s,{getVisitorKeys:o}))return{cursorNode:s};let c,D,p=-1,l=Number.POSITIVE_INFINITY;for(;a.length>0&&(c===void 0||D===void 0);){s=a.pop();let F=c!==void 0,f=D!==void 0;for(let d of Ce(s,{getVisitorKeys:o})){if(!F){let m=u(d);m<=r&&m>p&&(c=d,p=m)}if(!f){let m=n(d);m>=r&&m<l&&(D=d,l=m)}}}return{nodeBeforeCursor:c,nodeAfterCursor:D}}var Kt=xo;function wo(e,t){let{printer:{massageAstNode:r,getVisitorKeys:n}}=t;if(!r)return e;let u=J(n),o=r.ignoredProperties??new Set;return i(e);function i(s,a){if(!(s!==null&&typeof s=="object"))return s;if(Array.isArray(s))return s.map(l=>i(l,a)).filter(Boolean);let c={},D=new Set(u(s));for(let l in s)!Object.prototype.hasOwnProperty.call(s,l)||o.has(l)||(D.has(l)?c[l]=i(s[l],s):c[l]=s[l]);let p=r(s,c,a);if(p!==null)return p??c}}var Yn=wo;var bo=(e,t,r)=>{if(!(e&&t==null)){if(t.findLastIndex)return t.findLastIndex(r);for(let n=t.length-1;n>=0;n--){let u=t[n];if(r(u,n,t))return n}return-1}},jn=bo;var ko=({parser:e})=>e==="json"||e==="json5"||e==="jsonc"||e==="json-stringify";function So(e,t){let r=[e.node,...e.parentNodes],n=new Set([t.node,...t.parentNodes]);return r.find(u=>$n.has(u.type)&&n.has(u))}function Un(e){let t=jn(!1,e,r=>r.type!=="Program"&&r.type!=="File");return t===-1?e:e.slice(0,t+1)}function To(e,t,{locStart:r,locEnd:n}){let u=e.node,o=t.node;if(u===o)return{startNode:u,endNode:o};let i=r(e.node);for(let a of Un(t.parentNodes))if(r(a)>=i)o=a;else break;let s=n(t.node);for(let a of Un(e.parentNodes)){if(n(a)<=s)u=a;else break;if(u===o)break}return{startNode:u,endNode:o}}function zt(e,t,r,n,u=[],o){let{locStart:i,locEnd:s}=r,a=i(e),c=s(e);if(!(t>c||t<a||o==="rangeEnd"&&t===a||o==="rangeStart"&&t===c)){for(let D of Xe(e,r)){let p=zt(D,t,r,n,[e,...u],o);if(p)return p}if(!n||n(e,u[0]))return{node:e,parentNodes:u}}}function No(e,t){return t!=="DeclareExportDeclaration"&&e!=="TypeParameterDeclaration"&&(e==="Directive"||e==="TypeAlias"||e==="TSExportAssignment"||e.startsWith("Declare")||e.startsWith("TSDeclare")||e.endsWith("Statement")||e.endsWith("Declaration"))}var $n=new Set(["JsonRoot","ObjectExpression","ArrayExpression","StringLiteral","NumericLiteral","BooleanLiteral","NullLiteral","UnaryExpression","TemplateLiteral"]),Oo=new Set(["OperationDefinition","FragmentDefinition","VariableDefinition","TypeExtensionDefinition","ObjectTypeDefinition","FieldDefinition","DirectiveDefinition","EnumTypeDefLine truncated
`,u)+1),a=n.slice(s,u).match(/^\s*/u)[0],c=Ee(a,t.tabWidth),D=await Hn(i,{...t,rangeStart:0,rangeEnd:Number.POSITIVE_INFINITY,cursorOffset:t.cursorOffset>u&&t.cursorOffset<=o?t.cursorOffset-u:-1,endOfLine:"lf"},c),p=D.formatted.trimEnd(),{cursorOffset:l}=t;l>o?l+=p.length-i.length:D.cursorOffset>=0&&(l=D.cursorOffset+u);let F=n.slice(0,u)+p+n.slice(o);if(t.endOfLine!=="lf"){let f=xe(t.endOfLine);l>=0&&f===`\r
`&&(l+=Ct(F.slice(0,l),`
`)),F=te(!1,F,`
`,f)}return{formatted:F,cursorOffset:l,comments:D.comments}}function Ht(e,t,r){return typeof t!="number"||Number.isNaN(t)||t<0||t>e.length?r:t}function Gn(e,t){let{cursorOffset:r,rangeStart:n,rangeEnd:u}=t;return r=Ht(e,r,-1),n=Ht(e,n,0),u=Ht(e,u,e.length),{...t,cursorOffset:r,rangeStart:n,rangeEnd:u}}function Jn(e,t){let{cursorOffset:r,rangeStart:n,rangeEnd:u,endOfLine:o}=Gn(e,t),i=e.charAt(0)===zn;if(i&&(e=e.slice(1),r--,n--,u--),o==="auto"&&(o=nr(e)),e.includes("\r")){let s=a=>Ct(e.slice(0,Math.max(a,0)),`\r
`);r-=s(r),n-=s(n),u-=s(u),e=ur(e)}return{hasBOM:i,text:e,options:Gn(e,{...t,cursorOffset:r,rangeStart:n,rangeEnd:u,endOfLine:o})}}async function Kn(e,t){let r=await Re(t);return!r.hasPragma||r.hasPragma(e)}async function vo(e,t){var n;let r=await Re(t);return(n=r.hasIgnorePragma)==null?void 0:n.call(r,e)}async function Jt(e,t){let{hasBOM:r,text:n,options:u}=Jn(e,await ne(t));if(u.rangeStart>=u.rangeEnd&&n!==""||u.requirePragma&&!await Kn(n,u)||u.checkIgnorePragma&&await vo(n,u))return{formatted:e,cursorOffset:t.cursorOffset,comments:[]};let o;return u.rangeStart>0||u.rangeEnd<n.length?o=await Po(n,u):(!u.requirePragma&&u.insertPragma&&u.printer.insertPragma&&!await Kn(n,u)&&(n=u.printer.insertPragma(n)),o=await Hn(n,u)),r&&(o.formatted=zn+o.formatted,o.cursorOffset>=0&&o.cursorOffset++),o}async function qn(e,t,r){let{text:n,options:u}=Jn(e,await ne(t)),o=await De(n,u);return r&&(r.preprocessForPrint&&(o.ast=await Gt(o.ast,u)),r.massage&&(o.ast=Yn(o.ast,u))),o}async function Xn(e,t){t=await ne(t);let r=await Ye(e,t);return me(r,t)}async function Qn(e,t){let r=wr(e),{formatted:n}=await Jt(r,{...t,parser:"__js_expression"});return n}async function Zn(e,t){t=await ne(t);let{ast:r}=await De(e,t);return t.cursorOffset>=0&&(t={...t,...Kt(r,t)}),Ye(r,t)}async function eu(e,t){return me(e,await ne(t))}var qt={};dt(qt,{builders:()=>Io,printer:()=>Ro,utils:()=>Yo});var Io={join:ke,line:Me,softline:_r,hardline:z,literalline:We,group:At,conditionalGroup:Cr,fill:hr,lineSuffix:Se,lineSuffixBoundary:Ar,cursor:X,breakParent:pe,ifBreak:gr,trim:Br,indent:ie,indentIfBreak:yr,align:oe,addAlignmentToDoc:Ge,markAsRoot:mr,dedentToRoot:dr,dedent:Er,hardlineWithoutBreakParent:Te,literallineWithoutBreakParent:Bt,label:xr,concat:e=>e},Ro={printDocToString:me},Yo={willBreak:Dr,traverseDoc:le,findInDoc:Ve,mapDoc:be,removeLines:fr,stripTrailingHardline:$e,replaceEndOfLine:lr,canBreak:Fr};var tu="3.6.2";var Qt={};dt(Qt,{addDanglingComment:()=>ee,addLeadingComment:()=>se,addTrailingComment:()=>ae,getAlignmentSize:()=>Ee,getIndentSize:()=>ru,getMaxContinuousCount:()=>nu,getNextNonSpaceNonCommentCharacter:()=>uu,getNextNonSpaceNonCommentCharacterIndex:()=>Xo,getPreferredQuote:()=>iu,getStringWidth:()=>Ne,hasNewline:()=>G,hasNewlineInRange:()=>su,hasSpaces:()=>au,isNextLineEmpty:()=>ti,isNextLineEmptyAfterIndex:()=>ct,isPreviousLineEmpty:()=>Zo,makeString:()=>Du,skip:()=>he,skipEverythingButNewLine:()=>Je,skipInlineComment:()=>ye,skipNewline:()=>U,skipSpaces:()=>T,skipToLineEnd:()=>He,skipTrailingComment:()=>Ae,skipWhitespace:()=>Rr});function jo(e,t){if(t===!1)return!1;if(e.charAt(t)==="/"&&e.charAt(t+1)==="*"){for(let r=t+2;r<e.length;++r)if(e.charAt(r)==="*"&&e.charAt(r+1)==="/")return r+2}return t}var ye=jo;function Uo(e,t){return t===!1?!1:e.charAt(t)==="/"&&e.charAt(t+1)==="/"?Je(e,t):t}var Ae=Uo;function Vo(e,t){let r=null,n=t;for(;n!==r;)r=n,n=T(e,n),n=ye(e,n),n=Ae(e,n),n=U(e,n);return n}var je=Vo;function $o(e,t){let r=null,n=t;for(;n!==r;)r=n,n=He(e,n),n=ye(e,n),n=T(e,n);return n=Ae(e,n),n=U(e,n),n!==!1&&G(e,n)}var ct=$o;function Wo(e,t){let r=e.lastIndexOf(`
`);return r===-1?0:Ee(e.slice(r+1).match(/^[\t ]*/u)[0],t)}var ru=Wo;function Xt(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function Mo(e,t){let r=e.match(new RegExp(`(${Xt(t)})+`,"gu"));return r===null?0:r.reduce((n,u)=>Math.max(n,u.length/t.length),0)}var nu=Mo;function Go(e,t){let r=je(e,t);return r===!1?"":e.charAt(r)}var uu=Go;var ft="'",ou='"';function Ko(e,t){let r=t===!0||t===ft?ft:ou,n=r===ft?ou:ft,u=0,o=0;for(let i of e)i===r?u++:i===n&&o++;return u>o?n:r}var iu=Ko;function zo(e,t,r){for(let n=t;n<r;++n)if(e.charAt(n)===`
`)return!0;return!1}var su=zo;function Ho(e,t,r={}){return T(e,r.backwards?t-1:t,r)!==t}var au=Ho;function Jo(e,t,r){let n=t==='"'?"'":'"',o=te(!1,e,/\\(.)|(["'])/gsu,(i,s,a)=>s===n?s:a===t?"\\"+a:a||(r&&/^[^\n\r"'0-7\\bfnrt-vx\u2028\u2029]$/u.test(s)?s:"\\"+s));return t+o+t}var Du=Jo;function qo(e,t,r){return je(e,r(t))}function Xo(e,t){return arguments.length===2||typeof t=="number"?je(e,t):qo(...arguments)}function Qo(e,t,r){return Pe(e,r(t))}function Zo(e,t){return arguments.length===2||typeof t=="number"?Pe(e,t):Qo(...arguments)}function ei(e,t,r){return ct(e,r(t))}function ti(e,t){return arguments.length===2||typeof t=="number"?ct(e,t):ei(...arguments)}function ce(e,t=1){return async(...r)=>{let n=r[t]??{},u=n.plugins??[];return r[t]={...n,plugins:Array.isArray(u)?u:Object.values(u)},e(...r)}}var cu=ce(Jt);async function fu(e,t){let{formatted:r}=await cu(e,{...t,cursorOffset:-1});return r}async function ri(e,t){return await fu(e,t)===e}var ni=ce(Qe,0),ui={parse:ce(qn),formatAST:ce(Xn),formatDoc:ce(Qn),printToDoc:ce(Zn),printDocToString:ce(eu)};var xf=Zt;export{ui as __debug,ri as check,xf as default,qt as doc,fu as format,cu as formatWithCursor,ni as getSupportInfo,Qt as util,tu as version};
@@ -0,0 +1,8 @@
import type { Token } from "./tokenizer/index";
import type { Scope } from "./tokenizer/state";
export declare class File {
tokens: Array<Token>;
scopes: Array<Scope>;
constructor(tokens: Array<Token>, scopes: Array<Scope>);
}
export declare function parse(input: string, isJSXEnabled: boolean, isTypeScriptEnabled: boolean, isFlowEnabled: boolean): File;
@@ -0,0 +1,30 @@
'use strict'
var fib = require('./fib')
var max = 100000000
var start = Date.now()
// create a funcion with the typical error
// pattern, that delegates the heavy load
// to something else
function createNoCodeFunction () {
/* eslint no-constant-condition: "off" */
var num = 100
;(function () {
if (null) {
// do nothing
} else {
fib(num)
}
})()
}
for (var i = 0; i < max; i++) {
createNoCodeFunction()
}
var time = Date.now() - start
console.log('Total time', time)
console.log('Total iterations', max)
console.log('Iteration/s', max / time * 1000)
@@ -0,0 +1,2 @@
export {};
//# sourceMappingURL=cloneBinding.spec.d.ts.map
@@ -0,0 +1,2 @@
import type { File } from "../index";
export declare function parseFile(): File;
@@ -0,0 +1,135 @@
/**
* Minimal `EventEmitter` interface that is molded against the Node.js
* `EventEmitter` interface.
*/
declare class EventEmitter<
EventTypes extends EventEmitter.ValidEventTypes = string | symbol,
Context extends any = any
> {
static prefixed: string | boolean;
/**
* Return an array listing the events for which the emitter has registered
* listeners.
*/
eventNames(): Array<EventEmitter.EventNames<EventTypes>>;
/**
* Return the listeners registered for a given event.
*/
listeners<T extends EventEmitter.EventNames<EventTypes>>(
event: T
): Array<EventEmitter.EventListener<EventTypes, T>>;
/**
* Return the number of listeners listening to a given event.
*/
listenerCount(event: EventEmitter.EventNames<EventTypes>): number;
/**
* Calls each of the listeners registered for a given event.
*/
emit<T extends EventEmitter.EventNames<EventTypes>>(
event: T,
...args: EventEmitter.EventArgs<EventTypes, T>
): boolean;
/**
* Add a listener for a given event.
*/
on<T extends EventEmitter.EventNames<EventTypes>>(
event: T,
fn: EventEmitter.EventListener<EventTypes, T>,
context?: Context
): this;
addListener<T extends EventEmitter.EventNames<EventTypes>>(
event: T,
fn: EventEmitter.EventListener<EventTypes, T>,
context?: Context
): this;
/**
* Add a one-time listener for a given event.
*/
once<T extends EventEmitter.EventNames<EventTypes>>(
event: T,
fn: EventEmitter.EventListener<EventTypes, T>,
context?: Context
): this;
/**
* Remove the listeners of a given event.
*/
removeListener<T extends EventEmitter.EventNames<EventTypes>>(
event: T,
fn?: EventEmitter.EventListener<EventTypes, T>,
context?: Context,
once?: boolean
): this;
off<T extends EventEmitter.EventNames<EventTypes>>(
event: T,
fn?: EventEmitter.EventListener<EventTypes, T>,
context?: Context,
once?: boolean
): this;
/**
* Remove all listeners, or those of the specified event.
*/
removeAllListeners(event?: EventEmitter.EventNames<EventTypes>): this;
}
declare namespace EventEmitter {
export interface ListenerFn<Args extends any[] = any[]> {
(...args: Args): void;
}
export interface EventEmitterStatic {
new <
EventTypes extends ValidEventTypes = string | symbol,
Context = any
>(): EventEmitter<EventTypes, Context>;
}
/**
* `object` should be in either of the following forms:
* ```
* interface EventTypes {
* 'event-with-parameters': any[]
* 'event-with-example-handler': (...args: any[]) => void
* }
* ```
*/
export type ValidEventTypes = string | symbol | object;
export type EventNames<T extends ValidEventTypes> = T extends string | symbol
? T
: keyof T;
export type ArgumentMap<T extends object> = {
[K in keyof T]: T[K] extends (...args: any[]) => void
? Parameters<T[K]>
: T[K] extends any[]
? T[K]
: any[];
};
export type EventListener<
T extends ValidEventTypes,
K extends EventNames<T>
> = T extends string | symbol
? (...args: any[]) => void
: (
...args: ArgumentMap<Exclude<T, string | symbol>>[Extract<K, keyof T>]
) => void;
export type EventArgs<
T extends ValidEventTypes,
K extends EventNames<T>
> = Parameters<EventListener<T, K>>;
export const EventEmitter: EventEmitterStatic;
}
export { EventEmitter }
export default EventEmitter;
@@ -0,0 +1,75 @@
# Installation
> `npm install --save @types/cors`
# Summary
This package contains type definitions for cors (https://github.com/expressjs/cors/).
# Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/cors.
## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/cors/index.d.ts)
````ts
/// <reference types="node" />
import { IncomingHttpHeaders } from "http";
type StaticOrigin = boolean | string | RegExp | Array<boolean | string | RegExp>;
type CustomOrigin = (
requestOrigin: string | undefined,
callback: (err: Error | null, origin?: StaticOrigin) => void,
) => void;
declare namespace e {
interface CorsRequest {
method?: string | undefined;
headers: IncomingHttpHeaders;
}
interface CorsOptions {
/**
* @default '*'
*/
origin?: StaticOrigin | CustomOrigin | undefined;
/**
* @default 'GET,HEAD,PUT,PATCH,POST,DELETE'
*/
methods?: string | string[] | undefined;
allowedHeaders?: string | string[] | undefined;
exposedHeaders?: string | string[] | undefined;
credentials?: boolean | undefined;
maxAge?: number | undefined;
/**
* @default false
*/
preflightContinue?: boolean | undefined;
/**
* @default 204
*/
optionsSuccessStatus?: number | undefined;
}
type CorsOptionsDelegate<T extends CorsRequest = CorsRequest> = (
req: T,
callback: (err: Error | null, options?: CorsOptions) => void,
) => void;
}
declare function e<T extends e.CorsRequest = e.CorsRequest>(
options?: e.CorsOptions | e.CorsOptionsDelegate<T>,
): (
req: T,
res: {
statusCode?: number | undefined;
setHeader(key: string, value: string): any;
end(): any;
},
next: (err?: any) => any,
) => void;
export = e;
````
### Additional Details
* Last updated: Sat, 07 Jun 2025 02:15:25 GMT
* Dependencies: [@types/node](https://npmjs.com/package/@types/node)
# Credits
These definitions were written by [Alan Plum](https://github.com/pluma), [Gaurav Sharma](https://github.com/gtpan77), and [Sebastian Beltran](https://github.com/bjohansebas).
@@ -0,0 +1 @@
{"mappings":";;;;;;AAAA;;;;;;;;;;CAUC;;;;;AAqED,IAAI,uCAAiB,OAAO,aAAa,cAAc,OAAO,cAAc,GAAG;AAMxE,SAAS,0CAAmB,KAAwB;IACzD,IAAI,aAAC,SAAS,EAAC,GAAG,CAAA,GAAA,gBAAQ;IAC1B,IAAI,aACF,YAAY,cACZ,SAAS,cACT,UAAU,aACV,YAAY,uBACZ,YAAY,4BACZ,mBAAmB,gBACnB,aAAa,uBACb,kBAAkB,OAAO,aAAa,cAAc,SAAS,IAAI,GAAG,cACpE,SAAS,gBACT,cAAc,yBACd,uBAAuB,cACvB,SAAS,eACT,OAAO,aACP,SAAS,uBACT,sBAAsB,GACvB,GAAG;IACJ,IAAI,CAAC,UAAU,YAAY,GAAG,CAAA,GAAA,eAAO,EAAyB;IAE9D,IAAI,OAAO;QACT;QACA;QACA,WAAW,OAAO;QAClB,UAAU,OAAO;QACjB,UAAU,OAAO;QACjB;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;KACD;IAED,4GAA4G;IAC5G,mCAAmC;IACnC,uGAAuG;IACvG,IAAI,YAAY,CAAA,GAAA,aAAK,EAAE,iDAAA,2DAAA,qCAAgB,KAAK;IAC5C,CAAA,GAAA,gBAAQ,EAAE;QACR,IAAI,QACF,UAAU,OAAO,GAAG,iDAAA,2DAAA,qCAAgB,KAAK;IAE7C,GAAG;QAAC;KAAO;IAEX,IAAI,iBAAiB,CAAA,GAAA,kBAAU,EAAE;QAC/B,IAAI,yBAAyB,SAAS,CAAC,UAAU,CAAC,WAAW,OAAO,IAAI,CAAC,UAAU,OAAO,IAAI,CAAC,iBAC7F;QAGF,IAAI,CAAA,iDAAA,2DAAA,qCAAgB,KAAK,MAAK,UAAU,OAAO,EAC7C;QAGF,0DAA0D;QAC1D,yEAAyE;QACzE,4EAA4E;QAC5E,qEAAqE;QACrE,IAAI,SAA8B;QAClC,IAAI,UAAU,OAAO,IAAI,UAAU,OAAO,CAAC,QAAQ,CAAC,SAAS,aAAa,GAAG;gBAC1D;YAAjB,IAAI,cAAa,0BAAA,SAAS,aAAa,cAAtB,8CAAA,wBAAwB,qBAAqB;YAC9D,IAAI,aAAa,UAAU,OAAO,CAAC,qBAAqB;gBAK7C;YAJX,kFAAkF;YAClF,oCAAoC;YACpC,SAAS;gBACP,MAAM;gBACN,QAAQ,AAAC,CAAA,CAAA,kBAAA,uBAAA,iCAAA,WAAY,GAAG,cAAf,6BAAA,kBAAmB,CAAA,IAAK,WAAW,GAAG;YACjD;YACA,IAAI,OAAO,MAAM,GAAG,WAAW,MAAM,GAAG,GAAG;gBACzC,OAAO,IAAI,GAAG;oBACG;gBAAjB,OAAO,MAAM,GAAG,AAAC,CAAA,CAAA,qBAAA,uBAAA,iCAAA,WAAY,MAAM,cAAlB,gCAAA,qBAAsB,CAAA,IAAK,WAAW,MAAM;YAC/D;QACF;QAEA,0GAA0G;QAC1G,0HAA0H;QAC1H,IAAI,UAAW,WAAW,OAAO;QACjC,IAAI,CAAC,aAAa,WAAW,OAAO,EAAE;gBAGT;YAF3B,QAAQ,KAAK,CAAC,GAAG,GAAG;YACpB,QAAQ,KAAK,CAAC,MAAM,GAAG;gBACI;YAA3B,QAAQ,KAAK,CAAC,SAAS,GAAG,AAAC,CAAA,CAAA,iCAAA,yBAAA,OAAO,cAAc,cAArB,6CAAA,uBAAuB,MAAM,cAA7B,2CAAA,gCAAiC,OAAO,WAAW,AAAD,IAAK;QACpF;QAEA,IAAI,WAAW,CAAA,GAAA,yCAAgB,EAAE;YAC/B,WAAW,mCAAa,WAAW;YACnC,aAAa,WAAW,OAAO;YAC/B,YAAY,UAAU,OAAO;YAC7B,YAAY,UAAU,OAAO,IAAI,WAAW,OAAO;YACnD,SAAS;wBACT;6BACA;oBACA;yBACA;uBACA;uBACA;iCACA;QACF;QAEA,IAAI,CAAC,SAAS,QAAQ,EACpB;QAGF,wGAAwG;QACxG,qGAAqG;QACrG,QAAQ,KAAK,CAAC,GAAG,GAAG;QACpB,QAAQ,KAAK,CAAC,MAAM,GAAG;QACvB,QAAQ,KAAK,CAAC,IAAI,GAAG;QACrB,QAAQ,KAAK,CAAC,KAAK,GAAG;QAEtB,OAAO,IAAI,CAAC,SAAS,QAAQ,EAAE,OAAO,CAAC,CAAA,MAAO,QAAQ,KAAK,CAAC,IAAI,GAAG,AAAC,SAAS,QAAQ,AAAE,CAAC,IAAI,GAAG;QAC/F,QAAQ,KAAK,CAAC,SAAS,GAAG,SAAS,SAAS,IAAI,OAAQ,SAAS,SAAS,GAAG,OAAO;QAEpF,sDAAsD;QACtD,IAAI,UAAU,SAAS,aAAa,IAAI,UAAU,OAAO,EAAE;YACzD,IAAI,aAAa,SAAS,aAAa,CAAC,qBAAqB;YAC7D,IAAI,aAAa,UAAU,OAAO,CAAC,qBAAqB;YACxD,IAAI,YAAY,UAAU,CAAC,OAAO,IAAI,CAAC,GAAG,UAAU,CAAC,OAAO,IAAI,CAAC;YACjE,UAAU,OAAO,CAAC,SAAS,IAAI,YAAY,OAAO,MAAM;QAC1D;QAEA,uEAAuE;QACvE,YAAY;IACd,uDAAuD;IACvD,GAAG;IAEH,wCAAwC;IACxC,uDAAuD;IACvD,CAAA,GAAA,sBAAc,EAAE,gBAAgB;IAEhC,mCAAmC;IACnC,gCAAU;IAEV,sEAAsE;IACtE,CAAA,GAAA,wBAAgB,EAAE;QAChB,KAAK;QACL,UAAU;IACZ;IAEA,qEAAqE;IACrE,CAAA,GAAA,wBAAgB,EAAE;QAChB,KAAK;QACL,UAAU;IACZ;IAEA,2FAA2F;IAC3F,iGAAiG;IACjG,IAAI,aAAa,CAAA,GAAA,aAAK,EAAE;IACxB,CAAA,GAAA,sBAAc,EAAE;QACd,IAAI;QACJ,IAAI,WAAW;YACb,WAAW,OAAO,GAAG;YACrB,aAAa;YAEb,UAAU,WAAW;gBACnB,WAAW,OAAO,GAAG;YACvB,GAAG;YAEH;QACF;QAEA,iIAAiI;QACjI,gHAAgH;QAChH,IAAI,WAAW;YACb,IAAI,WAAW,OAAO,EACpB;QAEJ;QAEA,iDAAA,2DAAA,qCAAgB,gBAAgB,CAAC,UAAU;QAC3C,iDAAA,2DAAA,qCAAgB,gBAAgB,CAAC,UAAU;QAC3C,OAAO;YACL,iDAAA,2DAAA,qCAAgB,mBAAmB,CAAC,UAAU;YAC9C,iDAAA,2DAAA,qCAAgB,mBAAmB,CAAC,UAAU;QAChD;IACF,GAAG;QAAC;KAAe;IAEnB,IAAI,QAAQ,CAAA,GAAA,kBAAU,EAAE;QACtB,IAAI,CAAC,WAAW,OAAO,EACrB,oBAAA,8BAAA;IAEJ,GAAG;QAAC;QAAS;KAAW;IAExB,kFAAkF;IAClF,mEAAmE;IACnE,CAAA,GAAA,yCAAe,EAAE;QACf,YAAY;gBACZ;QACA,SAAS,WAAW;IACtB;QAQiB,qBAGJ;IATb,OAAO;QACL,cAAc;YACZ,OAAO;gBACL,UAAU;gBACV,QAAQ;mBACL,qBAAA,+BAAA,SAAU,QAAQ,AAArB;gBACA,WAAW,CAAA,sBAAA,qBAAA,+BAAA,SAAU,SAAS,cAAnB,iCAAA,sBAAuB;YACpC;QACF;QACA,WAAW,CAAA,sBAAA,qBAAA,+BAAA,SAAU,SAAS,cAAnB,iCAAA,sBAAuB;QAClC,YAAY;YACV,eAAe;YACf,MAAM;YACN,OAAO;gBACL,IAAI,EAAE,qBAAA,+BAAA,SAAU,eAAe;gBAC/B,GAAG,EAAE,qBAAA,+BAAA,SAAU,cAAc;YAC/B;QACF;wBACA;IACF;AACF;AAEA,SAAS,gCAAU,QAAQ;IACzB,CAAA,GAAA,sBAAc,EAAE;QACd,OAAO,gBAAgB,CAAC,UAAU,UAAU;QAC5C,OAAO;YACL,OAAO,mBAAmB,CAAC,UAAU,UAAU;QACjD;IACF,GAAG;QAAC;KAAS;AACf;AAEA,SAAS,mCAAa,QAAQ,EAAE,SAAS;IACvC,IAAI,cAAc,OAChB,OAAO,SAAS,OAAO,CAAC,SAAS,SAAS,OAAO,CAAC,OAAO;IAE3D,OAAO,SAAS,OAAO,CAAC,SAAS,QAAQ,OAAO,CAAC,OAAO;AAC1D","sources":["packages/@react-aria/overlays/src/useOverlayPosition.ts"],"sourcesContent":["/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {caLine truncated
@@ -0,0 +1,79 @@
export const BITS = 128;
export const GROUPS = 8;
/**
* Represents IPv6 address scopes
* @memberof Address6
* @static
*/
export const SCOPES: { [key: number]: string | undefined } = {
0: 'Reserved',
1: 'Interface local',
2: 'Link local',
4: 'Admin local',
5: 'Site local',
8: 'Organization local',
14: 'Global',
15: 'Reserved',
} as const;
/**
* Represents IPv6 address types
* @memberof Address6
* @static
*/
export const TYPES: { [key: string]: string | undefined } = {
'ff01::1/128': 'Multicast (All nodes on this interface)',
'ff01::2/128': 'Multicast (All routers on this interface)',
'ff02::1/128': 'Multicast (All nodes on this link)',
'ff02::2/128': 'Multicast (All routers on this link)',
'ff05::2/128': 'Multicast (All routers in this site)',
'ff02::5/128': 'Multicast (OSPFv3 AllSPF routers)',
'ff02::6/128': 'Multicast (OSPFv3 AllDR routers)',
'ff02::9/128': 'Multicast (RIP routers)',
'ff02::a/128': 'Multicast (EIGRP routers)',
'ff02::d/128': 'Multicast (PIM routers)',
'ff02::16/128': 'Multicast (MLDv2 reports)',
'ff01::fb/128': 'Multicast (mDNSv6)',
'ff02::fb/128': 'Multicast (mDNSv6)',
'ff05::fb/128': 'Multicast (mDNSv6)',
'ff02::1:2/128': 'Multicast (All DHCP servers and relay agents on this link)',
'ff05::1:2/128': 'Multicast (All DHCP servers and relay agents in this site)',
'ff02::1:3/128': 'Multicast (All DHCP servers on this link)',
'ff05::1:3/128': 'Multicast (All DHCP servers in this site)',
'::/128': 'Unspecified',
'::1/128': 'Loopback',
'ff00::/8': 'Multicast',
'fe80::/10': 'Link-local unicast',
} as const;
/**
* A regular expression that matches bad characters in an IPv6 address
* @memberof Address6
* @static
*/
export const RE_BAD_CHARACTERS = /([^0-9a-f:/%])/gi;
/**
* A regular expression that matches an incorrect IPv6 address
* @memberof Address6
* @static
*/
export const RE_BAD_ADDRESS = /([0-9a-f]{5,}|:{3,}|[^:]:$|^:[^:]|\/$)/gi;
/**
* A regular expression that matches an IPv6 subnet
* @memberof Address6
* @static
*/
export const RE_SUBNET_STRING = /\/\d{1,3}(?=%|$)/;
/**
* A regular expression that matches an IPv6 zone
* @memberof Address6
* @static
*/
export const RE_ZONE_STRING = /%.*$/;
export const RE_URL = /^\[{0,1}([0-9a-f:]+)\]{0,1}/;
export const RE_URL_WITH_PORT = /\[([0-9a-f:]+)\]:([0-9]{1,5})/;
@@ -0,0 +1,9 @@
import type { Rule } from 'eslint';
export type Extension = `.${string}`;
export type ESLintSettings = NonNullable<Rule.RuleContext['settings']> & {
'import/extensions'?: Extension[];
'import/parsers'?: { [k: string]: Extension[] };
'import/cache'?: { lifetime: number | '∞' | 'Infinity' };
};
@@ -0,0 +1,18 @@
import type { TSchema } from '../schema/index';
import type { Evaluate } from '../helpers/index';
import { type TIntersectEvaluated } from '../intersect/index';
import { type TIndexFromPropertyKeys } from '../indexed/index';
import { type TKeyOfPropertyKeys } from '../keyof/index';
import { type TNever } from '../never/index';
import { type TObject, type TProperties, type ObjectOptions } from '../object/index';
import { TSetDistinct } from '../sets/index';
type TCompositeKeys<T extends TSchema[], Acc extends PropertyKey[] = []> = (T extends [infer L extends TSchema, ...infer R extends TSchema[]] ? TCompositeKeys<R, [...Acc, ...TKeyOfPropertyKeys<L>]> : TSetDistinct<Acc>);
type TFilterNever<T extends TSchema[], Acc extends TSchema[] = []> = (T extends [infer L extends TSchema, ...infer R extends TSchema[]] ? L extends TNever ? TFilterNever<R, [...Acc]> : TFilterNever<R, [...Acc, L]> : Acc);
type TCompositeProperty<T extends TSchema[], K extends PropertyKey, Acc extends TSchema[] = []> = (T extends [infer L extends TSchema, ...infer R extends TSchema[]] ? TCompositeProperty<R, K, [...Acc, ...TIndexFromPropertyKeys<L, [K]>]> : TFilterNever<Acc>);
type TCompositeProperties<T extends TSchema[], K extends PropertyKey[], Acc = {}> = (K extends [infer L extends PropertyKey, ...infer R extends PropertyKey[]] ? TCompositeProperties<T, R, Acc & {
[_ in L]: TIntersectEvaluated<TCompositeProperty<T, L>>;
}> : Acc);
type TCompositeEvaluate<T extends TSchema[], K extends PropertyKey[] = TCompositeKeys<T>, P extends TProperties = Evaluate<TCompositeProperties<T, K>>, R extends TSchema = TObject<P>> = R;
export type TComposite<T extends TSchema[]> = TCompositeEvaluate<T>;
export declare function Composite<T extends TSchema[]>(T: [...T], options?: ObjectOptions): TComposite<T>;
export {};
@@ -0,0 +1,16 @@
var $ac03861c6e8605f4$exports = {};
$ac03861c6e8605f4$exports = {
"ascending": `\u{3B1}\u{3CD}\u{3BE}\u{3BF}\u{3C5}\u{3C3}\u{3B1}`,
"ascendingSort": (args)=>`\u{3B4}\u{3B9}\u{3B1}\u{3BB}\u{3BF}\u{3B3}\u{3AE} \u{3B1}\u{3BD}\u{3AC} \u{3C3}\u{3C4}\u{3AE}\u{3BB}\u{3B7} ${args.columnName} \u{3C3}\u{3B5} \u{3B1}\u{3CD}\u{3BE}\u{3BF}\u{3C5}\u{3C3}\u{3B1} \u{3C3}\u{3B5}\u{3B9}\u{3C1}\u{3AC}`,
"columnSize": (args)=>`${args.value} pixel`,
"descending": `\u{3C6}\u{3B8}\u{3AF}\u{3BD}\u{3BF}\u{3C5}\u{3C3}\u{3B1}`,
"descendingSort": (args)=>`\u{3B4}\u{3B9}\u{3B1}\u{3BB}\u{3BF}\u{3B3}\u{3AE} \u{3B1}\u{3BD}\u{3AC} \u{3C3}\u{3C4}\u{3AE}\u{3BB}\u{3B7} ${args.columnName} \u{3C3}\u{3B5} \u{3C6}\u{3B8}\u{3AF}\u{3BD}\u{3BF}\u{3C5}\u{3C3}\u{3B1} \u{3C3}\u{3B5}\u{3B9}\u{3C1}\u{3AC}`,
"resizerDescription": `\u{3A0}\u{3B1}\u{3C4}\u{3AE}\u{3C3}\u{3C4}\u{3B5} Enter \u{3B3}\u{3B9}\u{3B1} \u{3AD}\u{3BD}\u{3B1}\u{3C1}\u{3BE}\u{3B7} \u{3C4}\u{3B7}\u{3C2} \u{3B1}\u{3BB}\u{3BB}\u{3B1}\u{3B3}\u{3AE}\u{3C2} \u{3BC}\u{3B5}\u{3B3}\u{3AD}\u{3B8}\u{3BF}\u{3C5}\u{3C2}`,
"select": `\u{395}\u{3C0}\u{3B9}\u{3BB}\u{3BF}\u{3B3}\u{3AE}`,
"selectAll": `\u{395}\u{3C0}\u{3B9}\u{3BB}\u{3BF}\u{3B3}\u{3AE} \u{3CC}\u{3BB}\u{3C9}\u{3BD}`,
"sortable": `\u{3A3}\u{3C4}\u{3AE}\u{3BB}\u{3B7} \u{3B4}\u{3B9}\u{3B1}\u{3BB}\u{3BF}\u{3B3}\u{3AE}\u{3C2}`
};
export {$ac03861c6e8605f4$exports as default};
//# sourceMappingURL=el-GR.module.js.map
@@ -0,0 +1 @@
{"name":"get-stdin","version":"9.0.0","requiresBuild":false,"files":{"license":{"checkedAt":1794532119112,"integrity":"sha512-0fM2/ycrxrltyaBKfQ748Ck23VlPUUBgNAR47ldf4B1V/HoXTfWBSk+vcshGKwEpmOynu4mOP5o+hyBfuRNa8g==","mode":420,"size":1117},"index.js":{"checkedAt":1794532119112,"integrity":"sha512-kzwvrkZmFo4IlOL7MJF9Popp35yhrFI89EYGOyZjvuOfL4xRXy895NWT0pLUFdAMxsJevHwIx0myGimOgvHrMA==","mode":420,"size":488},"package.json":{"checkedAt":1794532119112,"integrity":"sha512-r8hkw5ATWvjx2m3CDE8KfnamKCoehtkryA+XIp65UHJwSqR82JZLy2o3Ce8fpiHZrBy4vaDSblvzue4Zf7jKBQ==","mode":420,"size":805},"readme.md":{"checkedAt":1794532119113,"integrity":"sha512-rG4h4Wsc+NLj6CrowrbtC86uFdNZbV6XdLd60ur+Bg3j8aFFnj1+Oxcd10L1Yyr8WdXuRbBAOz8dhLvwtFbnOA==","mode":420,"size":1273},"index.d.ts":{"checkedAt":1794532119113,"integrity":"sha512-+sotLjdAoggpxCrpBZZa6hPH1gxSaLdE/M9AawT1SWCHCh/wzwZcvhCS7Dirx3H+9INAKsk2a45Zh0BgXaa/0w==","mode":420,"size":852}}}
@@ -0,0 +1 @@
module.exports={C:{"115":0.04949,"128":0.00354,"132":0.00354,"133":0.00354,"140":0.00354,"141":0.00354,"142":0.01061,"143":0.19443,"144":0.17675,_:"2 3 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 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 125 126 127 129 130 131 134 135 136 137 138 139 145 146 147 3.5 3.6"},D:{"38":0.00354,"39":0.00354,"40":0.00354,"41":0.00354,"42":0.00354,"43":0.00354,"44":0.00354,"45":0.00354,"46":0.00354,"47":0.00354,"48":0.00354,"49":0.00354,"50":0.00354,"51":0.00354,"52":0.00354,"53":0.00354,"54":0.00354,"55":0.00707,"56":0.00354,"57":0.00354,"58":0.00354,"59":0.00354,"60":0.00354,"65":0.00354,"66":0.00707,"68":0.00707,"69":0.00707,"73":0.00354,"75":0.00707,"78":0.00354,"79":0.03182,"80":0.00354,"81":0.00354,"83":0.02475,"87":0.07777,"88":0.01061,"90":0.00354,"91":0.00707,"93":0.01061,"94":0.00354,"98":0.01414,"99":0.00354,"103":0.18382,"104":0.01414,"105":0.00354,"108":0.01414,"109":0.50551,"110":0.01768,"111":0.02475,"112":2.3331,"113":0.00707,"114":0.07424,"115":0.00707,"116":0.03535,"117":0.00354,"118":0.00354,"119":0.02828,"120":0.01768,"121":0.00707,"122":0.03889,"123":0.01061,"124":0.02828,"125":2.30129,"126":0.25806,"127":0.01768,"128":0.02121,"129":0.01414,"130":0.01061,"131":0.04596,"132":0.03535,"133":0.02121,"134":0.02121,"135":0.04949,"136":0.0707,"137":0.07777,"138":0.34997,"139":0.23685,"140":4.74044,"141":10.20201,"142":0.08131,"143":0.00707,_:"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 61 62 63 64 67 70 71 72 74 76 77 84 85 86 89 92 95 96 97 100 101 102 106 107 144 145"},F:{"46":0.00354,"79":0.01061,"91":0.01768,"92":0.04242,"95":0.00707,"120":0.02828,"121":0.04596,"122":0.29694,_:"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 78 80 81 82 83 84 85 86 87 88 89 90 93 94 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 9.5-9.6 10.0-10.1 10.5 10.6 11.1 11.5 11.6 12.1"},B:{"18":0.00707,"92":0.00354,"109":0.01768,"112":0.00354,"114":0.13787,"115":0.00354,"120":0.00354,"122":0.00354,"124":0.00707,"130":0.00354,"131":0.00354,"134":0.01414,"135":0.00354,"136":0.01061,"137":0.01061,"138":0.01061,"139":0.03182,"140":0.36764,"141":2.2624,_:"12 13 14 15 16 17 79 80 81 83 84 85 86 87 88 89 90 91 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 110 111 113 116 117 118 119 121 123 125 126 127 128 129 132 133 142"},E:{"15":0.00707,_:"0 4 5 6 7 8 9 10 11 12 13 14 3.1 3.2 6.1 7.1 9.1 10.1 11.1 12.1 15.1 15.4 16.0 16.4 17.0 26.2","5.1":0.00354,"13.1":0.01768,"14.1":0.01414,"15.2-15.3":0.00354,"15.5":0.00354,"15.6":0.03889,"16.1":0.00354,"16.2":0.00354,"16.3":0.00707,"16.5":0.00354,"16.6":0.04949,"17.1":0.03535,"17.2":0.00354,"17.3":0.00354,"17.4":0.00707,"17.5":0.01414,"17.6":0.06363,"18.0":0.00354,"18.1":0.01061,"18.2":0.00707,"18.3":0.02121,"18.4":0.01061,"18.5-18.6":0.11666,"26.0":0.21564,"26.1":0.00707},G:{"8":0,"3.2":0,"4.0-4.1":0,"4.2-4.3":0.00105,"5.0-5.1":0,"6.0-6.1":0.0042,"7.0-7.1":0.00315,"8.1-8.4":0,"9.0-9.2":0,"9.3":0.00946,"10.0-10.2":0.00105,"10.3":0.01786,"11.0-11.2":0.26478,"11.3-11.4":0.0063,"12.0-12.1":0.0021,"12.2-12.5":0.05149,"13.0-13.1":0,"13.2":0.00525,"13.3":0.0021,"13.4-13.7":0.00841,"14.0-14.4":0.01786,"14.5-14.8":0.01891,"15.0-15.1":0.01786,"15.2-15.3":0.01366,"15.4":0.01576,"15.5":0.01786,"15.6-15.8":0.23326,"16.0":0.03152,"16.1":0.05884,"16.2":0.03047,"16.3":0.05464,"16.4":0.01366,"16.5":0.02417,"16.6-16.7":0.31207,"17.0":0.02207,"17.1":0.03362,"17.2":0.02417,"17.3":0.03572,"17.4":0.06304,"17.5":0.10822,"17.6-17.7":0.27319,"18.0":0.06199,"18.1":0.12819,"18.2":0.06935,"18.3":0.22275,"18.4":0.11453,"18.5-18.6":5.83993,"26.0":0.72185,"26.1":0.02627},P:{"4":0.0622,"21":0.01037,"22":0.01037,"23":0.0311,"24":0.01037,"25":0.0622,"26":0.05183,"27":0.1244,"28":1.89716,"29":0.14514,_:"20 8.2 10.1 11.1-11.2 12.0 13.0 14.0 15.0 18.0 19.0","5.0-5.4":0.01037,"6.2-6.4":0.01037,"7.2-7.4":0.0311,"9.2":0.02073,"16.0":0.01037,"17.0":0.02073},I:{"0":0.0452,"3":0,"4":0,"2.1":0,"2.2":0,"2.3":0,"4.1":0,"4.2-4.3":0.00001,"4.4":0,"4.4.3-4.4.4":0.00002},K:{"0":0.6854,_:"10 11 12 11.1 11.5 12.1"},A:{"11":0.00707,_:"6 7 8 9 10 5.5"},S:{_:"2.5 3.0-3.1"},J:{_:"7 10"},N:{_:"10 11"},R:{_:"0"},M:{"0":0.13579},Q:{"14.9":0.00647},O:{"0":0.6272},H:{"0":0},L:{"0":57.79954}};
@@ -0,0 +1,23 @@
/** Used to match wrap detail comments. */
var reWrapComment = /\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/;
/**
* Inserts wrapper `details` in a comment at the top of the `source` body.
*
* @private
* @param {string} source The source to modify.
* @returns {Array} details The details to insert.
* @returns {string} Returns the modified source.
*/
function insertWrapDetails(source, details) {
var length = details.length;
if (!length) {
return source;
}
var lastIndex = length - 1;
details[lastIndex] = (length > 1 ? '& ' : '') + details[lastIndex];
details = details.join(length > 2 ? ', ' : ' ');
return source.replace(reWrapComment, '{\n/* [wrapped with ' + details + '] */\n');
}
export default insertWrapDetails;
@@ -0,0 +1 @@
{"version":3,"file":"buildDeactivationParams.js","sourceRoot":"","sources":["../../../../src/container/calculations/buildDeactivationParams.ts"],"names":[],"mappings":";;AAIA,0DAgBC;AApBD,4CAAyE;AAIzE,SAAgB,uBAAuB,CACrC,uBAAgD;IAEhD,OAAO;QACL,WAAW,EAAE,uBAAuB,CAAC,cAAc,CAAC,GAAG,CAAC,IAAI,CAC1D,uBAAuB,CAAC,cAAc,CACvC;QACD,qBAAqB,EACnB,uBAAuB,CAAC,cAAc,CAAC,aAAa,CAAC,IAAI,CACvD,uBAAuB,CAAC,cAAc,CACvC;QACH,gBAAgB,EAAhB,uBAAgB;QAChB,gBAAgB,EAAE,uBAAuB,CAAC,mBAAmB,CAAC,GAAG,CAAC,IAAI,CACpE,uBAAuB,CAAC,mBAAmB,CAC5C;KACF,CAAC;AACJ,CAAC"}
@@ -0,0 +1,15 @@
The ISC License
Copyright (c) 2009-2022 Isaac Z. Schlueter and Contributors
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.
@@ -0,0 +1,9 @@
const semver = require('semver')
const satisfies = (range) => {
return semver.satisfies(process.version, range, { includePrerelease: true })
}
module.exports = {
satisfies,
}
@@ -0,0 +1,140 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.AsnSchemaStorage = void 0;
const asn1js = require("asn1js");
const enums_1 = require("./enums");
const helper_1 = require("./helper");
class AsnSchemaStorage {
constructor() {
this.items = new WeakMap();
}
has(target) {
return this.items.has(target);
}
get(target, checkSchema = false) {
const schema = this.items.get(target);
if (!schema) {
throw new Error(`Cannot get schema for '${target.prototype.constructor.name}' target`);
}
if (checkSchema && !schema.schema) {
throw new Error(`Schema '${target.prototype.constructor.name}' doesn't contain ASN.1 schema. Call 'AsnSchemaStorage.cache'.`);
}
return schema;
}
cache(target) {
const schema = this.get(target);
if (!schema.schema) {
schema.schema = this.create(target, true);
}
}
createDefault(target) {
const schema = { type: enums_1.AsnTypeTypes.Sequence, items: {} };
const parentSchema = this.findParentSchema(target);
if (parentSchema) {
Object.assign(schema, parentSchema);
schema.items = Object.assign({}, schema.items, parentSchema.items);
}
return schema;
}
create(target, useNames) {
const schema = this.items.get(target) || this.createDefault(target);
const asn1Value = [];
for (const key in schema.items) {
const item = schema.items[key];
const name = useNames ? key : "";
let asn1Item;
if (typeof item.type === "number") {
const Asn1TypeName = enums_1.AsnPropTypes[item.type];
const Asn1Type = asn1js[Asn1TypeName];
if (!Asn1Type) {
throw new Error(`Cannot get ASN1 class by name '${Asn1TypeName}'`);
}
asn1Item = new Asn1Type({ name });
}
else if ((0, helper_1.isConvertible)(item.type)) {
const instance = new item.type();
asn1Item = instance.toSchema(name);
}
else if (item.optional) {
const itemSchema = this.get(item.type);
if (itemSchema.type === enums_1.AsnTypeTypes.Choice) {
asn1Item = new asn1js.Any({ name });
}
else {
asn1Item = this.create(item.type, false);
asn1Item.name = name;
}
}
else {
asn1Item = new asn1js.Any({ name });
}
const optional = !!item.optional || item.defaultValue !== undefined;
if (item.repeated) {
asn1Item.name = "";
const Container = item.repeated === "set" ? asn1js.Set : asn1js.Sequence;
asn1Item = new Container({
name: "",
value: [new asn1js.Repeated({ name, value: asn1Item })],
});
}
if (item.context !== null && item.context !== undefined) {
if (item.implicit) {
if (typeof item.type === "number" || (0, helper_1.isConvertible)(item.type)) {
const Container = item.repeated ? asn1js.Constructed : asn1js.Primitive;
asn1Value.push(new Container({ name, optional, idBlock: { tagClass: 3, tagNumber: item.context } }));
}
else {
this.cache(item.type);
const isRepeated = !!item.repeated;
let value = !isRepeated ? this.get(item.type, true).schema : asn1Item;
value =
"valueBlock" in value
? value.valueBlock.value
:
value.value;
asn1Value.push(new asn1js.Constructed({
name: !isRepeated ? name : "",
optional,
idBlock: { tagClass: 3, tagNumber: item.context },
value: value,
}));
}
}
else {
asn1Value.push(new asn1js.Constructed({
optional,
idBlock: { tagClass: 3, tagNumber: item.context },
value: [asn1Item],
}));
}
}
else {
asn1Item.optional = optional;
asn1Value.push(asn1Item);
}
}
switch (schema.type) {
case enums_1.AsnTypeTypes.Sequence:
return new asn1js.Sequence({ value: asn1Value, name: "" });
case enums_1.AsnTypeTypes.Set:
return new asn1js.Set({ value: asn1Value, name: "" });
case enums_1.AsnTypeTypes.Choice:
return new asn1js.Choice({ value: asn1Value, name: "" });
default:
throw new Error(`Unsupported ASN1 type in use`);
}
}
set(target, schema) {
this.items.set(target, schema);
return this;
}
findParentSchema(target) {
const parent = Object.getPrototypeOf(target);
if (parent) {
const schema = this.items.get(parent);
return schema || this.findParentSchema(parent);
}
return null;
}
}
exports.AsnSchemaStorage = AsnSchemaStorage;
@@ -0,0 +1 @@
{"name":"@types/estree","version":"1.0.8","requiresBuild":false,"files":{"LICENSE":{"checkedAt":1794532089978,"integrity":"sha512-HQaIQk9pwOcyKutyDk4o2a87WnotwYuLGYFW43emGm4FvIJFKPyg+OYaw5sTegKAKf+C5SKa1ACjzCLivbaHrQ==","mode":420,"size":1141},"README.md":{"checkedAt":1794532089978,"integrity":"sha512-alZQw4vOCWtDJlTmYSm+aEvD0weTLtGERCy5tNbpyvPI5F2j9hEWxHuUdwL+TZU2Nhdx7EGRhitAiv0xuSxaeg==","mode":420,"size":458},"flow.d.ts":{"checkedAt":1794532089979,"integrity":"sha512-f3OqA/2H/A62ZLT0qAZlUCUAiI89dMFcY+XrAU08dNgwHhXSQmFeMc7w/Ee7RE8tHU5RXFoQazarmCUsnCvXxg==","mode":420,"size":4801},"index.d.ts":{"checkedAt":1794532089979,"integrity":"sha512-YwR3YirWettZcjZgr7aNimg/ibEuP+6JMqAvL+cT6ubq2ctYKL9Xv+PgBssGCPES01PG5zKTHSvhShXCjXOrDg==","mode":420,"size":18944},"package.json":{"checkedAt":1794532089979,"integrity":"sha512-KaEBTHEFL2oVUvCrjSJR/H812XIaeRGbSZFP8DBb2Hon+IQwND0zz7oRvrXTm2AzzjneqH+pkB2Lusw29yJ/WA==","mode":420,"size":829}}}
@@ -0,0 +1,38 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.mapX509SignatureAlgToCOSEAlg = mapX509SignatureAlgToCOSEAlg;
const cose_js_1 = require("./cose.js");
/**
* Map X.509 signature algorithm OIDs to COSE algorithm IDs
*
* - EC2 OIDs: https://oidref.com/1.2.840.10045.4.3
* - RSA OIDs: https://oidref.com/1.2.840.113549.1.1
*/
function mapX509SignatureAlgToCOSEAlg(signatureAlgorithm) {
let alg;
if (signatureAlgorithm === '1.2.840.10045.4.3.2') {
alg = cose_js_1.COSEALG.ES256;
}
else if (signatureAlgorithm === '1.2.840.10045.4.3.3') {
alg = cose_js_1.COSEALG.ES384;
}
else if (signatureAlgorithm === '1.2.840.10045.4.3.4') {
alg = cose_js_1.COSEALG.ES512;
}
else if (signatureAlgorithm === '1.2.840.113549.1.1.11') {
alg = cose_js_1.COSEALG.RS256;
}
else if (signatureAlgorithm === '1.2.840.113549.1.1.12') {
alg = cose_js_1.COSEALG.RS384;
}
else if (signatureAlgorithm === '1.2.840.113549.1.1.13') {
alg = cose_js_1.COSEALG.RS512;
}
else if (signatureAlgorithm === '1.2.840.113549.1.1.5') {
alg = cose_js_1.COSEALG.RS1;
}
else {
throw new Error(`Unable to map X.509 signature algorithm ${signatureAlgorithm} to a COSE algorithm`);
}
return alg;
}
@@ -0,0 +1,28 @@
const JS_RESERVED = {
Array,
Date,
Infinity,
Math,
Number,
Object,
String,
undefined,
};
/**
* Extractor function for a Identifier type value node.
* An Identifier is usually a reference to a variable.
* Just return variable name to determine its existence.
*
* @param - value - AST Value object with type `Identifier`
* @returns - The extracted value converted to correct type.
*/
export default function extractValueFromIdentifier(value) {
const { name } = value;
if (Object.hasOwnProperty.call(JS_RESERVED, name)) {
return JS_RESERVED[name];
}
return name;
}
@@ -0,0 +1,17 @@
'use strict';
const pico = require('./lib/picomatch');
const utils = require('./lib/utils');
function picomatch(glob, options, returnState = false) {
// default to os.platform()
if (options && (options.windows === null || options.windows === undefined)) {
// don't mutate the original options object
options = { ...options, windows: utils.isWindows() };
}
return pico(glob, options, returnState);
}
Object.assign(picomatch, pico);
module.exports = picomatch;
@@ -0,0 +1,233 @@
import type {
BaseQueryApi,
BaseQueryArg,
BaseQueryEnhancer,
BaseQueryError,
BaseQueryExtraOptions,
BaseQueryFn,
BaseQueryMeta,
} from './baseQueryTypes'
import type { FetchBaseQueryError } from './fetchBaseQuery'
import { HandledError } from './HandledError'
/**
* Exponential backoff based on the attempt number.
*
* @remarks
* 1. 600ms * random(0.4, 1.4)
* 2. 1200ms * random(0.4, 1.4)
* 3. 2400ms * random(0.4, 1.4)
* 4. 4800ms * random(0.4, 1.4)
* 5. 9600ms * random(0.4, 1.4)
*
* @param attempt - Current attempt
* @param maxRetries - Maximum number of retries
*/
async function defaultBackoff(
attempt: number = 0,
maxRetries: number = 5,
signal?: AbortSignal,
) {
const attempts = Math.min(attempt, maxRetries)
const timeout = ~~((Math.random() + 0.4) * (300 << attempts)) // Force a positive int in the case we make this an option
await new Promise<void>((resolve, reject) => {
const timeoutId = setTimeout(() => resolve(), timeout)
// If signal is provided and gets aborted, clear timeout and reject
if (signal) {
const abortHandler = () => {
clearTimeout(timeoutId)
reject(new Error('Aborted'))
}
// Check if already aborted
if (signal.aborted) {
clearTimeout(timeoutId)
reject(new Error('Aborted'))
} else {
signal.addEventListener('abort', abortHandler, { once: true })
}
}
})
}
type RetryConditionFunction = (
error: BaseQueryError<BaseQueryFn>,
args: BaseQueryArg<BaseQueryFn>,
extraArgs: {
attempt: number
baseQueryApi: BaseQueryApi
extraOptions: BaseQueryExtraOptions<BaseQueryFn> & RetryOptions
},
) => boolean
export type RetryOptions = {
/**
* Function used to determine delay between retries
*/
backoff?: (
attempt: number,
maxRetries: number,
signal?: AbortSignal,
) => Promise<void>
} & (
| {
/**
* How many times the query will be retried (default: 5)
*/
maxRetries?: number
retryCondition?: undefined
}
| {
/**
* Callback to determine if a retry should be attempted.
* Return `true` for another retry and `false` to quit trying prematurely.
*/
retryCondition?: RetryConditionFunction
maxRetries?: undefined
}
)
function fail<BaseQuery extends BaseQueryFn = BaseQueryFn>(
error: BaseQueryError<BaseQuery>,
meta?: BaseQueryMeta<BaseQuery>,
): never {
throw Object.assign(new HandledError({ error, meta }), {
throwImmediately: true,
})
}
/**
* Checks if the abort signal is aborted and fails immediately if so.
* Used to exit retry loops cleanly when a request is aborted.
*/
function failIfAborted(signal: AbortSignal): void {
if (signal.aborted) {
fail({ status: 'CUSTOM_ERROR', error: 'Aborted' })
}
}
const EMPTY_OPTIONS = {}
const retryWithBackoff: BaseQueryEnhancer<
unknown,
RetryOptions,
RetryOptions | void
> = (baseQuery, defaultOptions) => async (args, api, extraOptions) => {
// We need to figure out `maxRetries` before we define `defaultRetryCondition.
// This is probably goofy, but ought to work.
// Put our defaults in one array, filter out undefineds, grab the last value.
const possibleMaxRetries: number[] = [
5,
((defaultOptions as any) || EMPTY_OPTIONS).maxRetries,
((extraOptions as any) || EMPTY_OPTIONS).maxRetries,
].filter((x) => x !== undefined)
const [maxRetries] = possibleMaxRetries.slice(-1)
const defaultRetryCondition: RetryConditionFunction = (_, __, { attempt }) =>
attempt <= maxRetries
const options: {
maxRetries: number
backoff: typeof defaultBackoff
retryCondition: typeof defaultRetryCondition
} = {
maxRetries,
backoff: defaultBackoff,
retryCondition: defaultRetryCondition,
...defaultOptions,
...extraOptions,
}
let retry = 0
while (true) {
// Check if aborted before each attempt
failIfAborted(api.signal)
try {
const result = await baseQuery(args, api, extraOptions)
// baseQueries _should_ return an error property, so we should check for that and throw it to continue retrying
if (result.error) {
throw new HandledError(result)
}
return result
} catch (e: any) {
retry++
if (e.throwImmediately) {
if (e instanceof HandledError) {
return e.value
}
// We don't know what this is, so we have to rethrow it
throw e
}
if (e instanceof HandledError) {
if (
!options.retryCondition(e.value.error as FetchBaseQueryError, args, {
attempt: retry,
baseQueryApi: api,
extraOptions,
})
) {
return e.value // Max retries for expected error
}
} else {
// For unexpected errors, respect maxRetries
if (retry > options.maxRetries) {
// Return the error as a proper error response instead of throwing
return { error: e }
}
}
// Check if aborted before backoff
failIfAborted(api.signal)
try {
await options.backoff(retry, options.maxRetries, api.signal)
} catch (backoffError) {
// If backoff was aborted, exit the retry loop
failIfAborted(api.signal)
// Otherwise, rethrow the backoff error
throw backoffError
}
}
}
}
/**
* A utility that can wrap `baseQuery` in the API definition to provide retries with a basic exponential backoff.
*
* @example
*
* ```ts
* // codeblock-meta title="Retry every request 5 times by default"
* import { createApi, fetchBaseQuery, retry } from '@reduxjs/toolkit/query/react'
* interface Post {
* id: number
* name: string
* }
* type PostsResponse = Post[]
*
* // maxRetries: 5 is the default, and can be omitted. Shown for documentation purposes.
* const staggeredBaseQuery = retry(fetchBaseQuery({ baseUrl: '/' }), { maxRetries: 5 });
* export const api = createApi({
* baseQuery: staggeredBaseQuery,
* endpoints: (build) => ({
* getPosts: build.query<PostsResponse, void>({
* query: () => ({ url: 'posts' }),
* }),
* getPost: build.query<PostsResponse, string>({
* query: (id) => ({ url: `post/${id}` }),
* extraOptions: { maxRetries: 8 }, // You can override the retry behavior on each endpoint
* }),
* }),
* });
*
* export const { useGetPostsQuery, useGetPostQuery } = api;
* ```
*/
export const retry = /* @__PURE__ */ Object.assign(retryWithBackoff, { fail })
@@ -0,0 +1,41 @@
{
"name": "cors",
"description": "Node.js CORS middleware",
"version": "2.8.5",
"author": "Troy Goode <troygoode@gmail.com> (https://github.com/troygoode/)",
"license": "MIT",
"keywords": [
"cors",
"express",
"connect",
"middleware"
],
"repository": "expressjs/cors",
"main": "./lib/index.js",
"dependencies": {
"object-assign": "^4",
"vary": "^1"
},
"devDependencies": {
"after": "0.8.2",
"eslint": "2.13.1",
"express": "4.16.3",
"mocha": "5.2.0",
"nyc": "13.1.0",
"supertest": "3.3.0"
},
"files": [
"lib/index.js",
"CONTRIBUTING.md",
"HISTORY.md",
"LICENSE",
"README.md"
],
"engines": {
"node": ">= 0.10"
},
"scripts": {
"test": "npm run lint && nyc --reporter=html --reporter=text mocha --require test/support/env",
"lint": "eslint lib test"
}
}
@@ -0,0 +1 @@
{"version":3,"file":"index.module.es.js","sources":["../src/guard.ts","../src/ColorError.ts","../src/parseToRgba.ts","../src/parseToHsla.ts","../src/hsla.ts","../src/adjustHue.ts","../src/darken.ts","../src/desaturate.ts","../src/getLuminance.ts","../src/getContrast.ts","../src/rgba.ts","../src/mix.ts","../src/getScale.ts","../src/hasBadContrast.ts","../src/lighten.ts","../src/transparentize.ts","../src/opacify.ts","../src/readableColorIsBlack.ts","../src/readableColor.ts","../src/saturate.ts","../src/toHex.ts","../src/toRgba.ts","../src/toHsla.ts"],"sourcesContent":["/**\n * A simple guard function:\n *\n * ```js\n * Math.min(Math.max(low, value), high)\n * ```\n */\nfunction guard(low: number, high: number, value: number): number {\n return Math.min(Math.max(low, value), high);\n}\n\nexport default guard;\n","class ColorError extends Error {\n constructor(color: string) {\n super(`Failed to parse color: \"${color}\"`);\n }\n}\n\nexport default ColorError;\n","import guard from './guard';\nimport ColorError from './ColorError';\n\n/**\n * Parses a color into red, gree, blue, alpha parts\n *\n * @param color the input color. Can be a RGB, RBGA, HSL, HSLA, or named color\n */\nfunction parseToRgba(color: string): [number, number, number, number] {\n if (typeof color !== 'string') throw new ColorError(color);\n if (color.trim().toLowerCase() === 'transparent') return [0, 0, 0, 0];\n\n let normalizedColor = color.trim();\n normalizedColor = namedColorRegex.test(color) ? nameToHex(color) : color;\n\n const reducedHexMatch = reducedHexRegex.exec(normalizedColor);\n if (reducedHexMatch) {\n const arr = Array.from(reducedHexMatch).slice(1);\n return [\n ...arr.slice(0, 3).map((x) => parseInt(r(x, 2), 16)),\n parseInt(r(arr[3] || 'f', 2), 16) / 255,\n ] as [number, number, number, number];\n }\n\n const hexMatch = hexRegex.exec(normalizedColor);\n if (hexMatch) {\n const arr = Array.from(hexMatch).slice(1);\n return [\n ...arr.slice(0, 3).map((x) => parseInt(x, 16)),\n parseInt(arr[3] || 'ff', 16) / 255,\n ] as [number, number, number, number];\n }\n\n const rgbaMatch = rgbaRegex.exec(normalizedColor);\n if (rgbaMatch) {\n const arr = Array.from(rgbaMatch).slice(1);\n return [\n ...arr.slice(0, 3).map((x) => parseInt(x, 10)),\n parseFloat(arr[3] || '1'),\n ] as [number, number, number, number];\n }\n\n const hslaMatch = hslaRegex.exec(normalizedColor);\n if (hslaMatch) {\n const [h, s, l, a] = Array.from(hslaMatch).slice(1).map(parseFloat);\n if (guard(0, 100, s) !== s) throw new ColorError(color);\n if (guard(0, 100, l) !== l) throw new ColorError(color);\n return [...hslToRgb(h, s, l), Number.isNaN(a) ? 1 : a] as [\n number,\n number,\n number,\n number\n ];\n }\n\n throw new ColorError(color);\n}\n\nfunction hash(str: string) {\n let hash = 5381;\n let i = str.length;\n\n while (i) {\n hash = (hash * 33) ^ str.charCodeAt(--i);\n }\n\n /* JavaScript does bitwise operations (like XOR, above) on 32-bit signed\n * integers. Since we want the results to be always positive, convert the\n * signed int to an unsigned by doing an unsigned bitshift. */\n return (hash >>> 0) % 2341;\n}\n\nconst colorToInt = (x: string) => parseInt(x.replace(/_/g, ''), 36);\n\nconst compressedColorMap =\n '1q29ehhb 1n09sgk7 1kl1ekf_ _yl4zsno 16z9eiv3 1p29lhp8 _bd9zg04 17u0____ _iw9zhe5 _to73___ _r45e31e _7l6g016 _jh8ouiv _zn3qba8 1jy4zshs 11u87k0u 1ro9yvyo 1aj3xael 1gz9zjz0 _3w8l4xo 1bf1ekf_ _ke3v___ _4rrkb__ 13j776yz _646mbhl _nrjr4__ _le6mbhl 1n37ehkb _m75f91n _qj3bzfz 1939yygw 11i5z6x8 _1k5f8xs 1509441m 15t5lwgf _ae2th1n _tg1ugcv 1lp1ugcv 16e14up_ _h55rw7n _ny9yavn _7a11xb_ 1ih442g9 _pv442g9 1mv16xof 14e6y7tu 1oo9zkds 17d1cisi _4v9y70f _y98m8kc 1019pq0v 12o9zda8 _348j4f4 1et50i2o _8epa8__ _ts6senj 1o350i2o 1mi9eiuo 1259yrp0 1ln80gnw _632xcoy 1cn9zldc _f29edu4 1n490c8q _9f9ziet 1b94vk74 _m49zkct 1kz6s73a 1eu9dtog _q58s1rz 1dy9sjiq __u89jo3 _aj5nkwg _ld89jo3 13h9z6wx _qa9z2ii _l119xgq _bs5arju 1hj4nwk9 1qt4nwk9 1ge6wau6 14j9zlcw 11p1edc_ _ms1zcxe _439shk6 _jt9y70f _754zsow 1la40eju _oq5p___ _x279qkz 1fa5r3rv _yd2d9ip _424tcku _8y1di2_ _zi2uabw _yy7rn9h 12yz980_ __39ljp6 1b59zg0x _n39zfzp 1fy9zest _b33k___ _hp9wq92 1il50hz4 _io472ub _lj9z3eo 19z9ykg0 _8t8iu3a 12b9bl4a 1ak5yw0o _896v4ku _tb8k8lv _s59zi6t _c09ze0p 1lg80oqn 1id9z8wb _238nba5 1kq6wgdi _154zssg _tn3zk49 _da9y6tc 1sg7cv4f _r12jvtt 1gq5fmkz 1cs9rvci _lp9jn1c _xw1tdnb 13f9zje6 16f6973h _vo7ir40 _bt5arjf _rc45e4t _hr4e100 10v4e100 _hc9zke2 _w91egv_ _sj2r1kk 13c87yx8 _vqpds__ _ni8ggk8 _tj9yqfb 1ia2j4r4 _7x9b10u 1fc9ld4j 1eq9zldr _5j9lhpx _ez9zl6o _md61fzm'\n .split(' ')\n .reduce((acc, next) => {\n const key = colorToInt(next.substring(0, 3));\n const hex = colorToInt(next.substring(3)).toString(16);\n\n // NOTE: padStart could be used here but it breaks Node 6 compat\n // https://github.com/ricokahler/color2k/issues/351\n leLine truncated
@@ -0,0 +1,178 @@
'use strict';
var identity = require('../nodes/identity.js');
var visit = require('../visit.js');
const escapeChars = {
'!': '%21',
',': '%2C',
'[': '%5B',
']': '%5D',
'{': '%7B',
'}': '%7D'
};
const escapeTagName = (tn) => tn.replace(/[!,[\]{}]/g, ch => escapeChars[ch]);
class Directives {
constructor(yaml, tags) {
/**
* The directives-end/doc-start marker `---`. If `null`, a marker may still be
* included in the document's stringified representation.
*/
this.docStart = null;
/** The doc-end marker `...`. */
this.docEnd = false;
this.yaml = Object.assign({}, Directives.defaultYaml, yaml);
this.tags = Object.assign({}, Directives.defaultTags, tags);
}
clone() {
const copy = new Directives(this.yaml, this.tags);
copy.docStart = this.docStart;
return copy;
}
/**
* During parsing, get a Directives instance for the current document and
* update the stream state according to the current version's spec.
*/
atDocument() {
const res = new Directives(this.yaml, this.tags);
switch (this.yaml.version) {
case '1.1':
this.atNextDocument = true;
break;
case '1.2':
this.atNextDocument = false;
this.yaml = {
explicit: Directives.defaultYaml.explicit,
version: '1.2'
};
this.tags = Object.assign({}, Directives.defaultTags);
break;
}
return res;
}
/**
* @param onError - May be called even if the action was successful
* @returns `true` on success
*/
add(line, onError) {
if (this.atNextDocument) {
this.yaml = { explicit: Directives.defaultYaml.explicit, version: '1.1' };
this.tags = Object.assign({}, Directives.defaultTags);
this.atNextDocument = false;
}
const parts = line.trim().split(/[ \t]+/);
const name = parts.shift();
switch (name) {
case '%TAG': {
if (parts.length !== 2) {
onError(0, '%TAG directive should contain exactly two parts');
if (parts.length < 2)
return false;
}
const [handle, prefix] = parts;
this.tags[handle] = prefix;
return true;
}
case '%YAML': {
this.yaml.explicit = true;
if (parts.length !== 1) {
onError(0, '%YAML directive should contain exactly one part');
return false;
}
const [version] = parts;
if (version === '1.1' || version === '1.2') {
this.yaml.version = version;
return true;
}
else {
const isValid = /^\d+\.\d+$/.test(version);
onError(6, `Unsupported YAML version ${version}`, isValid);
return false;
}
}
default:
onError(0, `Unknown directive ${name}`, true);
return false;
}
}
/**
* Resolves a tag, matching handles to those defined in %TAG directives.
*
* @returns Resolved tag, which may also be the non-specific tag `'!'` or a
* `'!local'` tag, or `null` if unresolvable.
*/
tagName(source, onError) {
if (source === '!')
return '!'; // non-specific tag
if (source[0] !== '!') {
onError(`Not a valid tag: ${source}`);
return null;
}
if (source[1] === '<') {
const verbatim = source.slice(2, -1);
if (verbatim === '!' || verbatim === '!!') {
onError(`Verbatim tags aren't resolved, so ${source} is invalid.`);
return null;
}
if (source[source.length - 1] !== '>')
onError('Verbatim tags must end with a >');
return verbatim;
}
const [, handle, suffix] = source.match(/^(.*!)([^!]*)$/s);
if (!suffix)
onError(`The ${source} tag has no suffix`);
const prefix = this.tags[handle];
if (prefix) {
try {
return prefix + decodeURIComponent(suffix);
}
catch (error) {
onError(String(error));
return null;
}
}
if (handle === '!')
return source; // local tag
onError(`Could not resolve tag: ${source}`);
return null;
}
/**
* Given a fully resolved tag, returns its printable string form,
* taking into account current tag prefixes and defaults.
*/
tagString(tag) {
for (const [handle, prefix] of Object.entries(this.tags)) {
if (tag.startsWith(prefix))
return handle + escapeTagName(tag.substring(prefix.length));
}
return tag[0] === '!' ? tag : `!<${tag}>`;
}
toString(doc) {
const lines = this.yaml.explicit
? [`%YAML ${this.yaml.version || '1.2'}`]
: [];
const tagEntries = Object.entries(this.tags);
let tagNames;
if (doc && tagEntries.length > 0 && identity.isNode(doc.contents)) {
const tags = {};
visit.visit(doc.contents, (_key, node) => {
if (identity.isNode(node) && node.tag)
tags[node.tag] = true;
});
tagNames = Object.keys(tags);
}
else
tagNames = [];
for (const [handle, prefix] of tagEntries) {
if (handle === '!!' && prefix === 'tag:yaml.org,2002:')
continue;
if (!doc || tagNames.some(tn => tn.startsWith(prefix)))
lines.push(`%TAG ${handle} ${prefix}`);
}
return lines.join('\n');
}
}
Directives.defaultYaml = { explicit: false, version: '1.2' };
Directives.defaultTags = { '!!': 'tag:yaml.org,2002:' };
exports.Directives = Directives;
@@ -0,0 +1,33 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports["default"] = getTabIndex;
var _jsxAstUtils = require("jsx-ast-utils");
/**
* Returns the tabIndex value.
*/
function getTabIndex(tabIndex) {
var literalValue = (0, _jsxAstUtils.getLiteralPropValue)(tabIndex);
// String and number values.
if (['string', 'number'].indexOf(typeof literalValue) > -1) {
// Empty string will convert to zero, so check for it explicity.
if (typeof literalValue === 'string' && literalValue.length === 0) {
return undefined;
}
var value = Number(literalValue);
if (Number.isNaN(value)) {
return undefined;
}
return Number.isInteger(value) ? value : undefined;
}
// Booleans are not valid values, return undefined.
if (literalValue === true || literalValue === false) {
return undefined;
}
return (0, _jsxAstUtils.getPropValue)(tabIndex);
}
module.exports = exports.default;
@@ -0,0 +1,6 @@
// Fixes https://github.com/motiondivision/motion/issues/2270
const getContextWindow = ({ current }) => {
return current ? current.ownerDocument.defaultView : null;
};
export { getContextWindow };
@@ -0,0 +1,106 @@
# MZ - Modernize node.js
[![NPM version][npm-image]][npm-url]
[![Build status][travis-image]][travis-url]
[![Test coverage][coveralls-image]][coveralls-url]
[![Dependency Status][david-image]][david-url]
[![License][license-image]][license-url]
[![Downloads][downloads-image]][downloads-url]
Modernize node.js to current ECMAScript specifications!
node.js will not update their API to ES6+ [for a while](https://github.com/joyent/node/issues/7549).
This library is a wrapper for various aspects of node.js' API.
## Installation and Usage
Set `mz` as a dependency and install it.
```bash
npm i mz
```
Then prefix the relevant `require()`s with `mz/`:
```js
var fs = require('mz/fs')
fs.exists(__filename).then(function (exists) {
if (exists) // do something
})
```
With ES2017, this will allow you to use async functions cleanly with node's core API:
```js
const fs = require('mz/fs')
async function doSomething () {
if (await fs.exists(__filename)) // do something
}
```
## Promisification
Many node methods are converted into promises.
Any properties that are deprecated or aren't asynchronous will simply be proxied.
The modules wrapped are:
- `child_process`
- `crypto`
- `dns`
- `fs` (uses `graceful-fs` if available)
- `readline`
- `zlib`
```js
var exec = require('mz/child_process').exec
exec('node --version').then(function (stdout) {
console.log(stdout)
})
```
## Promise Engine
`mz` uses [`any-promise`](https://github.com/kevinbeaty/any-promise).
## FAQ
### Can I use this in production?
Yes, Node 4.x ships with stable promises support. For older engines,
you should probably install your own promise implementation and register it with
`require('any-promise/register')('bluebird')`.
### Will this make my app faster?
Nope, probably slower actually.
### Can I add more features?
Sure.
Open an issue.
Currently, the plans are to eventually support:
- New APIs in node.js that are not available in older versions of node
- ECMAScript7 Streams
[bluebird]: https://github.com/petkaantonov/bluebird
[npm-image]: https://img.shields.io/npm/v/mz.svg?style=flat-square
[npm-url]: https://npmjs.org/package/mz
[github-tag]: http://img.shields.io/github/tag/normalize/mz.svg?style=flat-square
[github-url]: https://github.com/normalize/mz/tags
[travis-image]: https://img.shields.io/travis/normalize/mz.svg?style=flat-square
[travis-url]: https://travis-ci.org/normalize/mz
[coveralls-image]: https://img.shields.io/coveralls/normalize/mz.svg?style=flat-square
[coveralls-url]: https://coveralls.io/r/normalize/mz?branch=master
[david-image]: http://img.shields.io/david/normalize/mz.svg?style=flat-square
[david-url]: https://david-dm.org/normalize/mz
[license-image]: http://img.shields.io/npm/l/mz.svg?style=flat-square
[license-url]: LICENSE
[downloads-image]: http://img.shields.io/npm/dm/mz.svg?style=flat-square
[downloads-url]: https://npmjs.org/package/mz
@@ -0,0 +1,42 @@
"use strict"
const { READ, ReferenceTracker } = require("@eslint-community/eslint-utils")
const { getSourceCode } = require("eslint-compat-utils")
module.exports = {
meta: {
docs: {
description: "disallow the `Intl.getCanonicalLocales` method.",
category: "ES2016-Intl-API",
recommended: false,
url: "http://eslint-community.github.io/eslint-plugin-es-x/rules/no-intl-getcanonicallocales.html",
},
fixable: null,
messages: {
forbidden: "ES2016 Intl API '{{name}}' method is forbidden.",
},
schema: [],
type: "problem",
},
create(context) {
return {
"Program:exit"(program) {
const sourceCode = getSourceCode(context)
const tracker = new ReferenceTracker(
sourceCode.getScope(program),
)
for (const { node, path } of tracker.iterateGlobalReferences({
Intl: {
getCanonicalLocales: { [READ]: true },
},
})) {
context.report({
node,
messageId: "forbidden",
data: { name: path.join(".") },
})
}
},
}
},
}
@@ -0,0 +1,32 @@
import {SplitIncludingDelimiters} from './delimiter-case';
import {SnakeCase} from './snake-case';
import {Includes} from './includes';
/**
Returns a boolean for whether the string is screaming snake case.
*/
type IsScreamingSnakeCase<Value extends string> = Value extends Uppercase<Value>
? Includes<SplitIncludingDelimiters<Lowercase<Value>, '_'>, '_'> extends true
? true
: false
: false;
/**
Convert a string literal to screaming-snake-case.
This can be useful when, for example, converting a camel-cased object property to a screaming-snake-cased SQL column name.
@example
```
import {ScreamingSnakeCase} from 'type-fest';
const someVariable: ScreamingSnakeCase<'fooBar'> = 'FOO_BAR';
```
@category Template Literals
*/
export type ScreamingSnakeCase<Value> = Value extends string
? IsScreamingSnakeCase<Value> extends true
? Value
: Uppercase<SnakeCase<Value>>
: Value;
@@ -0,0 +1,5 @@
declare class MissingLocaleDataError extends Error {
type: string;
}
export declare function isMissingLocaleDataError(e: Error): e is MissingLocaleDataError;
export {};
@@ -0,0 +1 @@
module.exports={A:{A:{"2":"K D E F A B wC"},B:{"2":"0 1 2 3 4 5 C L M G N O P p q r s t u v w x y z GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB I","513":"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"},C:{"1":"AC BC CC DC EC FC GC HC IC JC KC LC Q H R WC 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","2":"0 1 2 3 4 5 6 7 8 9 xC TC J ZB K D E F A B C L M G N O P aB AB BB CB DB EB FB bB cB dB eB fB gB hB iB jB kB lB mB nB oB pB qB rB x y z GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB I XC MC YC yC zC 0C 1C","322":"sB tB uB vB wB xB yB zB 0B 1B 2B 3B UC 4B VC 5B 6B 7B 8B 9B v w"},D:{"2":"0 1 2 3 4 5 6 7 8 9 J ZB K D E F A B C L M G N O P aB AB BB CB DB EB FB bB cB dB eB fB gB hB iB p q r s t u v w x y z GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB I XC MC YC","130":"jB kB lB","513":"mB nB oB pB qB rB sB tB uB vB wB xB yB zB 0B 1B 2B 3B UC 4B VC 5B 6B 7B 8B 9B AC BC CC DC EC FC GC HC IC JC KC LC Q H R S T U V W X Y Z a b c d e f g","578":"h i j k l m n o"},E:{"1":"L M G 7C 8C 9C bC cC PC AD QC dC eC fC gC hC BD RC iC jC kC lC mC CD SC nC oC pC qC rC sC tC DD ED","2":"J ZB K D E F A B C 2C ZC 3C 4C 5C 6C aC NC OC"},F:{"2":"6 7 8 9 F B C G N O P aB AB BB CB DB EB FB bB cB dB eB fB gB hB iB jB kB mB FD GD HD ID NC uC JD OC","513":"0 1 2 3 4 5 lB 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 Q H R WC 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"},G:{"1":"ZD aD bD cD dD bC cC PC eD QC dC eC fC gC hC fD RC iC jC kC lC mC gD SC nC oC pC qC rC sC tC","2":"E ZC KD vC LD MD ND OD PD QD RD SD TD UD VD WD XD YD"},H:{"2":"hD"},I:{"2":"TC J I iD jD kD lD vC mD nD"},J:{"2":"D A"},K:{"2":"A B C H NC uC OC"},L:{"2":"I"},M:{"1":"MC"},N:{"2":"A B"},O:{"2":"PC"},P:{"2":"6 7 8 9 J AB BB CB DB EB FB oD pD qD rD sD aC tD uD vD wD xD QC RC SC yD"},Q:{"2":"zD"},R:{"2":"0D"},S:{"1":"2D","322":"1D"}},B:7,C:"FIDO U2F API",D:true};
@@ -0,0 +1,19 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.CreateType = CreateType;
const policy_1 = require("../../system/policy");
const immutable_1 = require("./immutable");
const value_1 = require("../clone/value");
/** Creates TypeBox schematics using the configured InstanceMode */
function CreateType(schema, options) {
const result = options !== undefined ? { ...options, ...schema } : schema;
switch (policy_1.TypeSystemPolicy.InstanceMode) {
case 'freeze':
return (0, immutable_1.Immutable)(result);
case 'clone':
return (0, value_1.Clone)(result);
default:
return result;
}
}
@@ -0,0 +1,16 @@
/*
* Copyright 2020 Adobe. All rights reserved.
* This file is licensed to you 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 http://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 REPRESENTATIONS
* OF ANY KIND, either express or implied. See the License for the specific language
* governing permissions and limitations under the License.
*/
export {useGridState} from './useGridState';
export {GridCollection} from './GridCollection';
export type {GridStateOptions, GridState} from './useGridState';
@@ -0,0 +1,73 @@
/*
* Copyright 2020 Adobe. All rights reserved.
* This file is licensed to you 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 http://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 REPRESENTATIONS
* OF ANY KIND, either express or implied. See the License for the specific language
* governing permissions and limitations under the License.
*/
import {useCallback, useEffect, useRef, useState} from 'react';
export function useControlledState<T, C = T>(value: Exclude<T, undefined>, defaultValue: Exclude<T, undefined> | undefined, onChange?: (v: C, ...args: any[]) => void): [T, (value: T, ...args: any[]) => void];
export function useControlledState<T, C = T>(value: Exclude<T, undefined> | undefined, defaultValue: Exclude<T, undefined>, onChange?: (v: C, ...args: any[]) => void): [T, (value: T, ...args: any[]) => void];
export function useControlledState<T, C = T>(value: T, defaultValue: T, onChange?: (v: C, ...args: any[]) => void): [T, (value: T, ...args: any[]) => void] {
let [stateValue, setStateValue] = useState(value || defaultValue);
let isControlledRef = useRef(value !== undefined);
let isControlled = value !== undefined;
useEffect(() => {
let wasControlled = isControlledRef.current;
if (wasControlled !== isControlled) {
console.warn(`WARN: A component changed from ${wasControlled ? 'controlled' : 'uncontrolled'} to ${isControlled ? 'controlled' : 'uncontrolled'}.`);
}
isControlledRef.current = isControlled;
}, [isControlled]);
let currentValue = isControlled ? value : stateValue;
let setValue = useCallback((value, ...args) => {
let onChangeCaller = (value, ...onChangeArgs) => {
if (onChange) {
if (!Object.is(currentValue, value)) {
onChange(value, ...onChangeArgs);
}
}
if (!isControlled) {
// If uncontrolled, mutate the currentValue local variable so that
// calling setState multiple times with the same value only emits onChange once.
// We do not use a ref for this because we specifically _do_ want the value to
// reset every render, and assigning to a ref in render breaks aborted suspended renders.
// eslint-disable-next-line react-hooks/exhaustive-deps
currentValue = value;
}
};
if (typeof value === 'function') {
console.warn('We can not support a function callback. See Github Issues for details https://github.com/adobe/react-spectrum/issues/2320');
// this supports functional updates https://reactjs.org/docs/hooks-reference.html#functional-updates
// when someone using useControlledState calls setControlledState(myFunc)
// this will call our useState setState with a function as well which invokes myFunc and calls onChange with the value from myFunc
// if we're in an uncontrolled state, then we also return the value of myFunc which to setState looks as though it was just called with myFunc from the beginning
// otherwise we just return the controlled value, which won't cause a rerender because React knows to bail out when the value is the same
let updateFunction = (oldValue, ...functionArgs) => {
let interceptedValue = value(isControlled ? currentValue : oldValue, ...functionArgs);
onChangeCaller(interceptedValue, ...args);
if (!isControlled) {
return interceptedValue;
}
return oldValue;
};
setStateValue(updateFunction);
} else {
if (!isControlled) {
setStateValue(value);
}
onChangeCaller(value, ...args);
}
}, [isControlled, currentValue, onChange]);
return [currentValue, setValue];
}
@@ -0,0 +1,6 @@
import { ColorfulAppender } from "./ColorfulAppender.mjs";
import { colors } from "./colors.mjs";
export {
ColorfulAppender,
colors
};
@@ -0,0 +1,44 @@
/*
* Copyright 2020 Adobe. All rights reserved.
* This file is licensed to you 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 http://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 REPRESENTATIONS
* OF ANY KIND, either express or implied. See the License for the specific language
* governing permissions and limitations under the License.
*/
export {Pressable} from './Pressable';
export {PressResponder, ClearPressResponder} from './PressResponder';
export {useFocus} from './useFocus';
export {
isFocusVisible,
getInteractionModality,
setInteractionModality,
addWindowFocusTracking,
useInteractionModality,
useFocusVisible,
useFocusVisibleListener
} from './useFocusVisible';
export {useFocusWithin} from './useFocusWithin';
export {useHover} from './useHover';
export {useInteractOutside} from './useInteractOutside';
export {useKeyboard} from './useKeyboard';
export {useMove} from './useMove';
export {usePress} from './usePress';
export {useScrollWheel} from './useScrollWheel';
export {useLongPress} from './useLongPress';
export type {FocusProps, FocusResult} from './useFocus';
export type {FocusVisibleHandler, FocusVisibleProps, FocusVisibleResult, Modality} from './useFocusVisible';
export type {FocusWithinProps, FocusWithinResult} from './useFocusWithin';
export type {HoverProps, HoverResult} from './useHover';
export type {InteractOutsideProps} from './useInteractOutside';
export type {KeyboardProps, KeyboardResult} from './useKeyboard';
export type {PressProps, PressHookProps, PressResult} from './usePress';
export type {PressEvent, PressEvents, MoveStartEvent, MoveMoveEvent, MoveEndEvent, MoveEvents, HoverEvent, HoverEvents, FocusEvents, KeyboardEvents} from '@react-types/shared';
export type {MoveResult} from './useMove';
export type {LongPressProps, LongPressResult} from './useLongPress';
export type {ScrollWheelProps} from './useScrollWheel';
@@ -0,0 +1,108 @@
var $ca0f93ae476efcee$exports = require("./ar-AE.main.js");
var $8fcf86b24fd399a9$exports = require("./bg-BG.main.js");
var $146712099a722811$exports = require("./cs-CZ.main.js");
var $2735c96991aebe53$exports = require("./da-DK.main.js");
var $d85ed0c826146b1e$exports = require("./de-DE.main.js");
var $1aecf8df24cd2c6e$exports = require("./el-GR.main.js");
var $8629e38d73986227$exports = require("./en-US.main.js");
var $219ef73190fd7b54$exports = require("./es-ES.main.js");
var $28e4d12b64c559fe$exports = require("./et-EE.main.js");
var $d443cdd0bb14863a$exports = require("./fi-FI.main.js");
var $e7b61bd0e93b97c5$exports = require("./fr-FR.main.js");
var $b09d12ffa0a56a3e$exports = require("./he-IL.main.js");
var $c3d9f76f15300329$exports = require("./hr-HR.main.js");
var $9904561a995a328e$exports = require("./hu-HU.main.js");
var $b63a88a974650d19$exports = require("./it-IT.main.js");
var $f79114b6f7838962$exports = require("./ja-JP.main.js");
var $305e358db516b233$exports = require("./ko-KR.main.js");
var $c37a95c245032ee0$exports = require("./lt-LT.main.js");
var $0d99b6662f72a76d$exports = require("./lv-LV.main.js");
var $b350dd154e1c203e$exports = require("./nb-NO.main.js");
var $94dcc10598f2ecbe$exports = require("./nl-NL.main.js");
var $847263ec44d85feb$exports = require("./pl-PL.main.js");
var $649f25af616381b6$exports = require("./pt-BR.main.js");
var $63863f752f22090b$exports = require("./pt-PT.main.js");
var $1011caef6838d0cf$exports = require("./ro-RO.main.js");
var $5c0e71883f016b2f$exports = require("./ru-RU.main.js");
var $9799788df99a536e$exports = require("./sk-SK.main.js");
var $79bf9bea0e0b8579$exports = require("./sl-SI.main.js");
var $374736afc1a4c11c$exports = require("./sr-SP.main.js");
var $948317bce9061901$exports = require("./sv-SE.main.js");
var $73e2289d5a9ac4de$exports = require("./tr-TR.main.js");
var $aca57efccc60ebb1$exports = require("./uk-UA.main.js");
var $ccd86abad329f871$exports = require("./zh-CN.main.js");
var $ad6eb5efb83fe2f8$exports = require("./zh-TW.main.js");
module.exports = {
"ar-AE": $ca0f93ae476efcee$exports,
"bg-BG": $8fcf86b24fd399a9$exports,
"cs-CZ": $146712099a722811$exports,
"da-DK": $2735c96991aebe53$exports,
"de-DE": $d85ed0c826146b1e$exports,
"el-GR": $1aecf8df24cd2c6e$exports,
"en-US": $8629e38d73986227$exports,
"es-ES": $219ef73190fd7b54$exports,
"et-EE": $28e4d12b64c559fe$exports,
"fi-FI": $d443cdd0bb14863a$exports,
"fr-FR": $e7b61bd0e93b97c5$exports,
"he-IL": $b09d12ffa0a56a3e$exports,
"hr-HR": $c3d9f76f15300329$exports,
"hu-HU": $9904561a995a328e$exports,
"it-IT": $b63a88a974650d19$exports,
"ja-JP": $f79114b6f7838962$exports,
"ko-KR": $305e358db516b233$exports,
"lt-LT": $c37a95c245032ee0$exports,
"lv-LV": $0d99b6662f72a76d$exports,
"nb-NO": $b350dd154e1c203e$exports,
"nl-NL": $94dcc10598f2ecbe$exports,
"pl-PL": $847263ec44d85feb$exports,
"pt-BR": $649f25af616381b6$exports,
"pt-PT": $63863f752f22090b$exports,
"ro-RO": $1011caef6838d0cf$exports,
"ru-RU": $5c0e71883f016b2f$exports,
"sk-SK": $9799788df99a536e$exports,
"sl-SI": $79bf9bea0e0b8579$exports,
"sr-SP": $374736afc1a4c11c$exports,
"sv-SE": $948317bce9061901$exports,
"tr-TR": $73e2289d5a9ac4de$exports,
"uk-UA": $aca57efccc60ebb1$exports,
"zh-CN": $ccd86abad329f871$exports,
"zh-TW": $ad6eb5efb83fe2f8$exports
};
//# sourceMappingURL=intlStrings.main.js.map
@@ -0,0 +1 @@
{"mappings":";;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;;;AAcM,SAAS,0CAAe,IAAwB;IACrD,OAAQ;QACN,KAAK;YACH,OAAO,IAAI,CAAA,GAAA,yCAAe;QAC5B,KAAK;YACH,OAAO,IAAI,CAAA,GAAA,yCAAe;QAC5B,KAAK;YACH,OAAO,IAAI,CAAA,GAAA,yCAAwB;QACrC,KAAK;YACH,OAAO,IAAI,CAAA,GAAA,yCAAa;QAC1B,KAAK;YACH,OAAO,IAAI,CAAA,GAAA,wCAAa;QAC1B,KAAK;YACH,OAAO,IAAI,CAAA,GAAA,yCAAa;QAC1B,KAAK;YACH,OAAO,IAAI,CAAA,GAAA,yCAAmB;QAChC,KAAK;YACH,OAAO,IAAI,CAAA,GAAA,yCAAqB;QAClC,KAAK;YACH,OAAO,IAAI,CAAA,GAAA,yCAAsB;QACnC,KAAK;YACH,OAAO,IAAI,CAAA,GAAA,yCAAe;QAC5B,KAAK;YACH,OAAO,IAAI,CAAA,GAAA,yCAAc;QAC3B,KAAK;YACH,OAAO,IAAI,CAAA,GAAA,yCAAa;QAC1B,KAAK;QACL;YACE,OAAO,IAAI,CAAA,GAAA,yCAAgB;IAC/B;AACF","sources":["packages/@internationalized/date/src/createCalendar.ts"],"sourcesContent":["/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {BuddhistCalendar} from './calendars/BuddhistCalendar';\nimport {Calendar, CalendarIdentifier} from './types';\nimport {CopticCalendar, EthiopicAmeteAlemCalendar, EthiopicCalendar} from './calendars/EthiopicCalendar';\nimport {GregorianCalendar} from './calendars/GregorianCalendar';\nimport {HebrewCalendar} from './calendars/HebrewCalendar';\nimport {IndianCalendar} from './calendars/IndianCalendar';\nimport {IslamicCivilCalendar, IslamicTabularCalendar, IslamicUmalquraCalendar} from './calendars/IslamicCalendar';\nimport {JapaneseCalendar} from './calendars/JapaneseCalendar';\nimport {PersianCalendar} from './calendars/PersianCalendar';\nimport {TaiwanCalendar} from './calendars/TaiwanCalendar';\n\n/** Creates a `Calendar` instance from a Unicode calendar identifier string. */\nexport function createCalendar(name: CalendarIdentifier): Calendar {\n switch (name) {\n case 'buddhist':\n return new BuddhistCalendar();\n case 'ethiopic':\n return new EthiopicCalendar();\n case 'ethioaa':\n return new EthiopicAmeteAlemCalendar();\n case 'coptic':\n return new CopticCalendar();\n case 'hebrew':\n return new HebrewCalendar();\n case 'indian':\n return new IndianCalendar();\n case 'islamic-civil':\n return new IslamicCivilCalendar();\n case 'islamic-tbla':\n return new IslamicTabularCalendar();\n case 'islamic-umalqura':\n return new IslamicUmalquraCalendar();\n case 'japanese':\n return new JapaneseCalendar();\n case 'persian':\n return new PersianCalendar();\n case 'roc':\n return new TaiwanCalendar();\n case 'gregory':\n default:\n return new GregorianCalendar();\n }\n}\n"],"names":[],"version":3,"file":"createCalendar.module.js.map"}
@@ -0,0 +1,67 @@
'use strict';
var GetIntrinsic = require('get-intrinsic');
var callBound = require('call-bound');
var $RangeError = require('es-errors/range');
var $SyntaxError = require('es-errors/syntax');
var $TypeError = require('es-errors/type');
var $BigInt = GetIntrinsic('%BigInt%', true);
var hasOwnProperty = require('./HasOwnProperty');
var IsArray = require('./IsArray');
var IsBigIntElementType = require('./IsBigIntElementType');
var IsUnsignedElementType = require('./IsUnsignedElementType');
var bytesAsFloat32 = require('../helpers/bytesAsFloat32');
var bytesAsFloat64 = require('../helpers/bytesAsFloat64');
var bytesAsInteger = require('../helpers/bytesAsInteger');
var every = require('../helpers/every');
var isByteValue = require('../helpers/isByteValue');
var $reverse = callBound('Array.prototype.reverse');
var $slice = callBound('Array.prototype.slice');
var tableTAO = require('./tables/typed-array-objects');
// https://262.ecma-international.org/15.0/#sec-rawbytestonumeric
module.exports = function RawBytesToNumeric(type, rawBytes, isLittleEndian) {
if (!hasOwnProperty(tableTAO.size, '$' + type)) {
throw new $TypeError('Assertion failed: `type` must be a TypedArray element type');
}
if (!IsArray(rawBytes) || !every(rawBytes, isByteValue)) {
throw new $TypeError('Assertion failed: `rawBytes` must be an Array of bytes');
}
if (typeof isLittleEndian !== 'boolean') {
throw new $TypeError('Assertion failed: `isLittleEndian` must be a Boolean');
}
var elementSize = tableTAO.size['$' + type]; // step 1
if (rawBytes.length !== elementSize) {
// this assertion is not in the spec, but it'd be an editorial error if it were ever violated
throw new $RangeError('Assertion failed: `rawBytes` must have a length of ' + elementSize + ' for type ' + type);
}
var isBigInt = IsBigIntElementType(type);
if (isBigInt && !$BigInt) {
throw new $SyntaxError('this environment does not support BigInts');
}
// eslint-disable-next-line no-param-reassign
rawBytes = $slice(rawBytes, 0, elementSize);
if (!isLittleEndian) {
$reverse(rawBytes); // step 2
}
if (type === 'FLOAT32') { // step 3
return bytesAsFloat32(rawBytes);
}
if (type === 'FLOAT64') { // step 4
return bytesAsFloat64(rawBytes);
}
return bytesAsInteger(rawBytes, elementSize, IsUnsignedElementType(type), isBigInt);
};
@@ -0,0 +1,67 @@
var $7hdEs$reactstatelyoverlays = require("@react-stately/overlays");
var $7hdEs$react = require("react");
function $parcel$export(e, n, v, s) {
Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
}
$parcel$export(module.exports, "useMenuTriggerState", () => $f39cdb649cd48930$export$79fefeb1c2091ac3);
/*
* Copyright 2020 Adobe. All rights reserved.
* This file is licensed to you 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 http://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 REPRESENTATIONS
* OF ANY KIND, either express or implied. See the License for the specific language
* governing permissions and limitations under the License.
*/
function $f39cdb649cd48930$export$79fefeb1c2091ac3(props) {
let overlayTriggerState = (0, $7hdEs$reactstatelyoverlays.useOverlayTriggerState)(props);
let [focusStrategy, setFocusStrategy] = (0, $7hdEs$react.useState)(null);
let [expandedKeysStack, setExpandedKeysStack] = (0, $7hdEs$react.useState)([]);
let closeAll = ()=>{
setExpandedKeysStack([]);
overlayTriggerState.close();
};
let openSubmenu = (triggerKey, level)=>{
setExpandedKeysStack((oldStack)=>{
if (level > oldStack.length) return oldStack;
return [
...oldStack.slice(0, level),
triggerKey
];
});
};
let closeSubmenu = (triggerKey, level)=>{
setExpandedKeysStack((oldStack)=>{
let key = oldStack[level];
if (key === triggerKey) return oldStack.slice(0, level);
else return oldStack;
});
};
return {
focusStrategy: focusStrategy,
...overlayTriggerState,
open (focusStrategy = null) {
setFocusStrategy(focusStrategy);
overlayTriggerState.open();
},
toggle (focusStrategy = null) {
setFocusStrategy(focusStrategy);
overlayTriggerState.toggle();
},
close () {
closeAll();
},
expandedKeysStack: expandedKeysStack,
openSubmenu: openSubmenu,
closeSubmenu: closeSubmenu
};
}
//# sourceMappingURL=useMenuTriggerState.main.js.map
@@ -0,0 +1,26 @@
import { __read } from "tslib";
import { useCallback, useState } from 'react';
import useLatest from '../useLatest';
import { isFunction } from '../utils';
function useEventTarget(options) {
var _a = options || {}, initialValue = _a.initialValue, transformer = _a.transformer;
var _b = __read(useState(initialValue), 2), value = _b[0], setValue = _b[1];
var transformerRef = useLatest(transformer);
var reset = useCallback(function () { return setValue(initialValue); }, []);
var onChange = useCallback(function (e) {
var _value = e.target.value;
if (isFunction(transformerRef.current)) {
return setValue(transformerRef.current(_value));
}
// no transformer => U and T should be the same
return setValue(_value);
}, []);
return [
value,
{
onChange: onChange,
reset: reset,
},
];
}
export default useEventTarget;
@@ -0,0 +1 @@
{"name":"regexp.prototype.flags","version":"1.5.4","requiresBuild":false,"files":{".editorconfig":{"checkedAt":1794532097299,"integrity":"sha512-p35O0lNr5b8Aha4N1dns/Zy3+rV1ZLx6ffSVcrlURzE+W3zbryu0BkQ6tiGeSgp248nP94ZxUa8iBmtp1ocZng==","mode":420,"size":276},".eslintrc":{"checkedAt":1794532097299,"integrity":"sha512-MS7oyAF+WHZBy/X8auGbl23RP+G8PYZWK/VFMhVjCtHtYxM11xQbgjO5nQg8qXB4guiXVD2VzTWLKChGwL2m3A==","mode":420,"size":243},".nycrc":{"checkedAt":1794532089075,"integrity":"sha512-2vm1RFz8Ajl/OYrfoCWPJIm3Bpnf7Gyn5bha/lZx/cq+We3uMy9xj15XeP6x4wF3jf/pO7KMHAkU9mllm605xg==","mode":420,"size":139},"LICENSE":{"checkedAt":1794532097299,"integrity":"sha512-63+JOkjF2MIs+LELMQIrjVzHRYrKKhh2vYXZYJBn8T2FRw5t0zHr+VbvnqBUDvx+gCC2VeYZD2TXVArRYDVZng==","mode":420,"size":1082},"auto.js":{"checkedAt":1794532097299,"integrity":"sha512-8Q3Im5cACiIFrMmxvLnJnA8SXOjAd1kh/R0UIDVnErDD1WUlJIDrNfaOcIB6rtjAXNhq/OdL1374JM/QcAJ1VQ==","mode":420,"size":36},"test/builtin.js":{"checkedAt":1794532097299,"integrity":"sha512-g4M3NgydkOlsEcgsn68qmnbJN+mde2SAgquLU4AsXdUGfIL77JGqlEkWNaO6s1A8ceJFYiW8fP/KHPQeoKUAjQ==","mode":420,"size":1718},"implementation.js":{"checkedAt":1794532097299,"integrity":"sha512-M5oKff2KL+IfKEJjMWLM3XBtFro1P4EqOaq87odiKuAsjs3Ft9nsrQxZSL2ffF1WrGhZ46MD+G8GV1gbrqvw1A==","mode":420,"size":710},"test/implementation.js":{"checkedAt":1794532097300,"integrity":"sha512-XdQscCh+qHGHxCjqfsA7BywaBFK7rMRMgg5aNf+c4IEJeGf/BfQHNLeB9vP5hhQe/sD9u9DMLBMMIWNsD9YN9g==","mode":420,"size":601},"index.js":{"checkedAt":1794532097300,"integrity":"sha512-nzmopT//zwmGDeTEPb/3gYKrideXNVxFUYeuPn/HpV7NI/U9tkQkAdL3glhIOdlf74B0iXgPD8c4h55Wvj4iug==","mode":420,"size":388},"test/index.js":{"checkedAt":1794532097300,"integrity":"sha512-pmuIZgCKKANk6L9zKCI17rePGaxHdMAiYwkw3rkRDfUsOxSEApXW9AZkAKwi+/jEsE5oSQBRXvOySqJJmRh4aQ==","mode":420,"size":420},"polyfill.js":{"checkedAt":1794532097300,"integrity":"sha512-i5485EPTAifdarH5kEvhvOBB9RVESLw87WvifGpdRFkdR49cdCD9hbCBLsYXI4hwlBOIX/pef16HRObPq6NZjw==","mode":420,"size":864},"shim.js":{"checkedAt":1794532097300,"integrity":"sha512-S4d8Gj8nPNVfxDa+Wk8pDv9dKYqqxRlwTrg5goi8rGJQG8/H6MqXNsOcGCuUwi40tX1PMRsJcYY+31Ugi4cp4Q==","mode":420,"size":779},"test/shimmed.js":{"checkedAt":1794532097300,"integrity":"sha512-Lf/lSg49kfY3p9f3warVytCWleZrqSEBSXh1vRrG0CAziJ7DwDZEfDT7evXIdaoZFuKyv1Nz1LFzWHrLVA138w==","mode":420,"size":1739},"test/tests.js":{"checkedAt":1794532097300,"integrity":"sha512-AauEchjxkxJYFjDlaruegba0WV8P4CZVOAVGM1x9NbFIBqwnFfI6w0mCiY+HOwwZDqf/jeBOlrXeKn5m3RnXWg==","mode":420,"size":4322},"package.json":{"checkedAt":1794532097300,"integrity":"sha512-gakWDyHhOj8ZqsSzaT3FUGDftAJQbELEOPBcOgI4hCvM0H4XFA4wz2BB6qPEXOof0RLfnMMXEXv1/2kpcdjT9Q==","mode":420,"size":2718},"CHANGELOG.md":{"checkedAt":1794532097301,"integrity":"sha512-wlEKXTTPhuXRKm1YogLg1TyluQDlAjmyoRirwNUYFBRUESwvPhQnwUw2aWAT9m/lYsApMk91f9zv/O98Dw9ThA==","mode":420,"size":25748},"README.md":{"checkedAt":1794532097301,"integrity":"sha512-P410vJunHCOEEOU55B3U1ClYiitZfQ5QmpmHj0mjnRwXV0+ZfylpTPBZmHaMPH2anvNJ5k10LBsHHbIxAg+omw==","mode":420,"size":2527}}}
@@ -0,0 +1,175 @@
var $8c61827343eed941$exports = require("./useId.main.js");
var $1e2191638e54f613$exports = require("./chain.main.js");
var $8e13b2545651735a$exports = require("./ShadowTreeWalker.main.js");
var $d723bea02f3e2567$exports = require("./DOMFunctions.main.js");
var $aaa611146751592e$exports = require("./domHelpers.main.js");
var $f847cd1382ea7cd4$exports = require("./mergeProps.main.js");
var $f05dc24eafaeb7e2$exports = require("./mergeRefs.main.js");
var $8d15d0e1797d4238$exports = require("./filterDOMProps.main.js");
var $1117b6c0d4c4c164$exports = require("./focusWithoutScrolling.main.js");
var $16ec41ef3e36c19c$exports = require("./getOffset.main.js");
var $4068a0fae83b6d84$exports = require("./openLink.main.js");
var $e8117ebcab55be6a$exports = require("./runAfterTransition.main.js");
var $28ed3fb20343b78b$exports = require("./useDrag1D.main.js");
var $4571ff54ac709100$exports = require("./useGlobalListeners.main.js");
var $6ec78bde395c477d$exports = require("./useLabels.main.js");
var $475b35fe72ba49b3$exports = require("./useObjectRef.main.js");
var $29293a6f5c75b37e$exports = require("./useUpdateEffect.main.js");
var $0fa310503218f75f$exports = require("./useUpdateLayoutEffect.main.js");
var $78605a5d7424e31b$exports = require("./useLayoutEffect.main.js");
var $37733e1652f47193$exports = require("./useResizeObserver.main.js");
var $6fc733991a9f977c$exports = require("./useSyncRef.main.js");
var $d796e7157ac96470$exports = require("./getScrollParent.main.js");
var $49f0d9486c2408aa$exports = require("./getScrollParents.main.js");
var $9a54e9cd5db23b5d$exports = require("./isScrollable.main.js");
var $8b24bab62f5c65ad$exports = require("./useViewportSize.main.js");
var $34da4502ea8120db$exports = require("./useDescription.main.js");
var $9e20cff0af27e8cc$exports = require("./platform.main.js");
var $2a8c0bb1629926c8$exports = require("./useEvent.main.js");
var $19a2307bfabafaf1$exports = require("./useValueEffect.main.js");
var $449412113267a1fe$exports = require("./scrollIntoView.main.js");
var $577e795361f19be9$exports = require("./isVirtualEvent.main.js");
var $1254e5bb94ac8761$exports = require("./useEffectEvent.main.js");
var $20e6e72fbf5dc81e$exports = require("./useDeepMemo.main.js");
var $1f205e845604a423$exports = require("./useFormReset.main.js");
var $faa6ccd6fb62f877$exports = require("./useLoadMore.main.js");
var $f6a4874a7c582761$exports = require("./useLoadMoreSentinel.main.js");
var $13915169b1e4142c$exports = require("./inertValue.main.js");
var $a0850d0add29d276$exports = require("./constants.main.js");
var $2308dc377e184bb0$exports = require("./keyboard.main.js");
var $5bd06107f98811f5$exports = require("./animation.main.js");
var $506b33fd893eab7d$exports = require("./isFocusable.main.js");
var $1Yh1N$reactstatelyutils = require("@react-stately/utils");
function $parcel$export(e, n, v, s) {
Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
}
$parcel$export(module.exports, "useId", () => $8c61827343eed941$exports.useId);
$parcel$export(module.exports, "mergeIds", () => $8c61827343eed941$exports.mergeIds);
$parcel$export(module.exports, "useSlotId", () => $8c61827343eed941$exports.useSlotId);
$parcel$export(module.exports, "chain", () => $1e2191638e54f613$exports.chain);
$parcel$export(module.exports, "createShadowTreeWalker", () => $8e13b2545651735a$exports.createShadowTreeWalker);
$parcel$export(module.exports, "ShadowTreeWalker", () => $8e13b2545651735a$exports.ShadowTreeWalker);
$parcel$export(module.exports, "getActiveElement", () => $d723bea02f3e2567$exports.getActiveElement);
$parcel$export(module.exports, "getEventTarget", () => $d723bea02f3e2567$exports.getEventTarget);
$parcel$export(module.exports, "nodeContains", () => $d723bea02f3e2567$exports.nodeContains);
$parcel$export(module.exports, "getOwnerDocument", () => $aaa611146751592e$exports.getOwnerDocument);
$parcel$export(module.exports, "getOwnerWindow", () => $aaa611146751592e$exports.getOwnerWindow);
$parcel$export(module.exports, "isShadowRoot", () => $aaa611146751592e$exports.isShadowRoot);
$parcel$export(module.exports, "mergeProps", () => $f847cd1382ea7cd4$exports.mergeProps);
$parcel$export(module.exports, "mergeRefs", () => $f05dc24eafaeb7e2$exports.mergeRefs);
$parcel$export(module.exports, "filterDOMProps", () => $8d15d0e1797d4238$exports.filterDOMProps);
$parcel$export(module.exports, "focusWithoutScrolling", () => $1117b6c0d4c4c164$exports.focusWithoutScrolling);
$parcel$export(module.exports, "getOffset", () => $16ec41ef3e36c19c$exports.getOffset);
$parcel$export(module.exports, "openLink", () => $4068a0fae83b6d84$exports.openLink);
$parcel$export(module.exports, "getSyntheticLinkProps", () => $4068a0fae83b6d84$exports.getSyntheticLinkProps);
$parcel$export(module.exports, "useSyntheticLinkProps", () => $4068a0fae83b6d84$exports.useSyntheticLinkProps);
$parcel$export(module.exports, "RouterProvider", () => $4068a0fae83b6d84$exports.RouterProvider);
$parcel$export(module.exports, "shouldClientNavigate", () => $4068a0fae83b6d84$exports.shouldClientNavigate);
$parcel$export(module.exports, "useRouter", () => $4068a0fae83b6d84$exports.useRouter);
$parcel$export(module.exports, "useLinkProps", () => $4068a0fae83b6d84$exports.useLinkProps);
$parcel$export(module.exports, "handleLinkClick", () => $4068a0fae83b6d84$exports.handleLinkClick);
$parcel$export(module.exports, "runAfterTransition", () => $e8117ebcab55be6a$exports.runAfterTransition);
$parcel$export(module.exports, "useDrag1D", () => $28ed3fb20343b78b$exports.useDrag1D);
$parcel$export(module.exports, "useGlobalListeners", () => $4571ff54ac709100$exports.useGlobalListeners);
$parcel$export(module.exports, "useLabels", () => $6ec78bde395c477d$exports.useLabels);
$parcel$export(module.exports, "useObjectRef", () => $475b35fe72ba49b3$exports.useObjectRef);
$parcel$export(module.exports, "useUpdateEffect", () => $29293a6f5c75b37e$exports.useUpdateEffect);
$parcel$export(module.exports, "useUpdateLayoutEffect", () => $0fa310503218f75f$exports.useUpdateLayoutEffect);
$parcel$export(module.exports, "useLayoutEffect", () => $78605a5d7424e31b$exports.useLayoutEffect);
$parcel$export(module.exports, "useResizeObserver", () => $37733e1652f47193$exports.useResizeObserver);
$parcel$export(module.exports, "useSyncRef", () => $6fc733991a9f977c$exports.useSyncRef);
$parcel$export(module.exports, "getScrollParent", () => $d796e7157ac96470$exports.getScrollParent);
$parcel$export(module.exports, "getScrollParents", () => $49f0d9486c2408aa$exports.getScrollParents);
$parcel$export(module.exports, "isScrollable", () => $9a54e9cd5db23b5d$exports.isScrollable);
$parcel$export(module.exports, "useViewportSize", () => $8b24bab62f5c65ad$exports.useViewportSize);
$parcel$export(module.exports, "useDescription", () => $34da4502ea8120db$exports.useDescription);
$parcel$export(module.exports, "isMac", () => $9e20cff0af27e8cc$exports.isMac);
$parcel$export(module.exports, "isIPhone", () => $9e20cff0af27e8cc$exports.isIPhone);
$parcel$export(module.exports, "isIPad", () => $9e20cff0af27e8cc$exports.isIPad);
$parcel$export(module.exports, "isIOS", () => $9e20cff0af27e8cc$exports.isIOS);
$parcel$export(module.exports, "isAppleDevice", () => $9e20cff0af27e8cc$exports.isAppleDevice);
$parcel$export(module.exports, "isWebKit", () => $9e20cff0af27e8cc$exports.isWebKit);
$parcel$export(module.exports, "isChrome", () => $9e20cff0af27e8cc$exports.isChrome);
$parcel$export(module.exports, "isAndroid", () => $9e20cff0af27e8cc$exports.isAndroid);
$parcel$export(module.exports, "isFirefox", () => $9e20cff0af27e8cc$exports.isFirefox);
$parcel$export(module.exports, "useEvent", () => $2a8c0bb1629926c8$exports.useEvent);
$parcel$export(module.exports, "useValueEffect", () => $19a2307bfabafaf1$exports.useValueEffect);
$parcel$export(module.exports, "scrollIntoView", () => $449412113267a1fe$exports.scrollIntoView);
$parcel$export(module.exports, "scrollIntoViewport", () => $449412113267a1fe$exports.scrollIntoViewport);
$parcel$export(module.exports, "clamp", () => $1Yh1N$reactstatelyutils.clamp);
$parcel$export(module.exports, "snapValueToStep", () => $1Yh1N$reactstatelyutils.snapValueToStep);
$parcel$export(module.exports, "isVirtualClick", () => $577e795361f19be9$exports.isVirtualClick);
$parcel$export(module.exports, "isVirtualPointerEvent", () => $577e795361f19be9$exports.isVirtualPointerEvent);
$parcel$export(module.exports, "useEffectEvent", () => $1254e5bb94ac8761$exports.useEffectEvent);
$parcel$export(module.exports, "useDeepMemo", () => $20e6e72fbf5dc81e$exports.useDeepMemo);
$parcel$export(module.exports, "useFormReset", () => $1f205e845604a423$exports.useFormReset);
$parcel$export(module.exports, "useLoadMore", () => $faa6ccd6fb62f877$exports.useLoadMore);
$parcel$export(module.exports, "useLoadMoreSentinel", () => $f6a4874a7c582761$exports.useLoadMoreSentinel);
$parcel$export(module.exports, "UNSTABLE_useLoadMoreSentinel", () => $f6a4874a7c582761$exports.useLoadMoreSentinel);
$parcel$export(module.exports, "inertValue", () => $13915169b1e4142c$exports.inertValue);
$parcel$export(module.exports, "CLEAR_FOCUS_EVENT", () => $a0850d0add29d276$exports.CLEAR_FOCUS_EVENT);
$parcel$export(module.exports, "FOCUS_EVENT", () => $a0850d0add29d276$exports.FOCUS_EVENT);
$parcel$export(module.exports, "isCtrlKeyPressed", () => $2308dc377e184bb0$exports.isCtrlKeyPressed);
$parcel$export(module.exports, "willOpenKeyboard", () => $2308dc377e184bb0$exports.willOpenKeyboard);
$parcel$export(module.exports, "useEnterAnimation", () => $5bd06107f98811f5$exports.useEnterAnimation);
$parcel$export(module.exports, "useExitAnimation", () => $5bd06107f98811f5$exports.useExitAnimation);
$parcel$export(module.exports, "isFocusable", () => $506b33fd893eab7d$exports.isFocusable);
$parcel$export(module.exports, "isTabbable", () => $506b33fd893eab7d$exports.isTabbable);
/*
* Copyright 2020 Adobe. All rights reserved.
* This file is licensed to you 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 http://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 REPRESENTATIONS
* OF ANY KIND, either express or implied. See the License for the specific language
* governing permissions and limitations under the License.
*/
//# sourceMappingURL=main.js.map
@@ -0,0 +1,9 @@
'use strict';
var implementation = require('./implementation');
var $Iterator = require('../Iterator');
module.exports = function getPolyfill() {
return typeof $Iterator.concat === 'function' ? $Iterator.concat : implementation;
};
@@ -0,0 +1,18 @@
'use strict';
var getPolyfill = require('./polyfill');
var define = require('define-properties');
var getIteratorPolyfill = require('../Iterator/polyfill');
module.exports = function shimIteratorZipKeyed() {
var $Iterator = getIteratorPolyfill();
var polyfill = getPolyfill();
define(
$Iterator,
{ zipKeyed: polyfill },
{ zipKeyed: function () { return $Iterator.zipKeyed !== polyfill; } }
);
return polyfill;
};
@@ -0,0 +1,68 @@
/**
* @fileoverview Enforce autoFocus prop is not used.
* @author Ethan Cohen <@evcohen>
*/
// -----------------------------------------------------------------------------
// Requirements
// -----------------------------------------------------------------------------
import { RuleTester } from 'eslint';
import parserOptionsMapper from '../../__util__/parserOptionsMapper';
import parsers from '../../__util__/helpers/parsers';
import rule from '../../../src/rules/no-autofocus';
// -----------------------------------------------------------------------------
// Tests
// -----------------------------------------------------------------------------
const ruleTester = new RuleTester();
const expectedError = {
message: 'The autoFocus prop should not be used, as it can reduce usability and accessibility for users.',
type: 'JSXAttribute',
};
const ignoreNonDOMSchema = [
{
ignoreNonDOM: true,
},
];
const componentsSettings = {
'jsx-a11y': {
components: {
Button: 'button',
},
},
};
ruleTester.run('no-autofocus', rule, {
valid: parsers.all([].concat(
{ code: '<div />;' },
{ code: '<div autofocus />;' },
{ code: '<input autofocus="true" />;' },
{ code: '<Foo bar />' },
{ code: '<Foo autoFocus />', options: ignoreNonDOMSchema },
{ code: '<div><div autofocus /></div>', options: ignoreNonDOMSchema },
{ code: '<Button />', settings: componentsSettings },
{ code: '<Button />', options: ignoreNonDOMSchema, settings: componentsSettings },
)).map(parserOptionsMapper),
invalid: parsers.all([].concat(
{ code: '<div autoFocus />', errors: [expectedError] },
{ code: '<div autoFocus={true} />', errors: [expectedError] },
{ code: '<div autoFocus={false} />', errors: [expectedError] },
{ code: '<div autoFocus={undefined} />', errors: [expectedError] },
{ code: '<div autoFocus="true" />', errors: [expectedError] },
{ code: '<div autoFocus="false" />', errors: [expectedError] },
{ code: '<input autoFocus />', errors: [expectedError] },
{ code: '<Foo autoFocus />', errors: [expectedError] },
{ code: '<Button autoFocus />', errors: [expectedError], settings: componentsSettings },
{
code: '<Button autoFocus />',
errors: [expectedError],
options: ignoreNonDOMSchema,
settings: componentsSettings,
},
)).map(parserOptionsMapper),
});
@@ -0,0 +1,894 @@
export declare const Elem: {
text: import("napcat-protobuf").MessageProtoFieldType<() => {
str: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
lint: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
attr6Buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
attr7Buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
}, true, false>;
face: import("napcat-protobuf").MessageProtoFieldType<() => {
index: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
old: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
}, true, false>;
onlineImage: import("napcat-protobuf").MessageProtoFieldType<() => {
guid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
filePath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
oldVerSendFile: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
notOnlineImage: import("napcat-protobuf").MessageProtoFieldType<() => {
filePath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
downloadPath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
oldVerSendFile: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
imgType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
previewsImage: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
picMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
picHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
picWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
resId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
flag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
thumbUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
original: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bigUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
origUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
bizType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
result: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
index: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
opFaceBuf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
oldPicMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
thumbWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
showLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
downloadLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
x400Url: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
x400Width: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
x400Height: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbRes: import("napcat-protobuf").MessageProtoFieldType<() => {
subType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field3: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field4: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
summary: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
field10: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field20: import("napcat-protobuf").MessageProtoFieldType<() => {
field1: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field2: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
field3: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field4: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field7: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
}, false, false>;
url: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
md5Str: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
}, false, false>;
}, true, false>;
transElem: import("napcat-protobuf").MessageProtoFieldType<() => {
elemType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
elemValue: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
marketFace: import("napcat-protobuf").MessageProtoFieldType<() => {
faceName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
itemType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
faceInfo: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
faceId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
tabId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
subType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
key: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
param: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
mediaType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
imageWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
imageHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
mobileparam: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
pbReserve: import("napcat-protobuf").MessageProtoFieldType<() => {
field8: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
}, false, false>;
}, true, false>;
customFace: import("napcat-protobuf").MessageProtoFieldType<() => {
guid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
filePath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
shortcut: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
buffer: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
flag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
oldData: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
serverIp: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
serverPort: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
fileType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
signature: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
useful: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
md5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
thumbUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
bigUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
origUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
bizType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
repeatIndex: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
repeatImage: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
imageType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
index: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
width: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
height: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
source: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
size: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
origin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
thumbHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
showLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
downloadLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
x400Url: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
x400Width: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
x400Height: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbRes: import("napcat-protobuf").MessageProtoFieldType<() => {
subType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
summary: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
}, true, false>;
}, true, false>;
elemFlags2: import("napcat-protobuf").MessageProtoFieldType<() => {
colorTextId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
msgId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
whisperSessionId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
pttChangeBit: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
vipStatus: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
compatibleId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
insts: import("napcat-protobuf").MessageProtoFieldType<() => {
appId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
instId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
}, false, true>;
msgRptCnt: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
srcInst: import("napcat-protobuf").MessageProtoFieldType<() => {
appId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
instId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
}, false, false>;
longtitude: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
latitude: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
customFont: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
pcSupportDef: import("napcat-protobuf").MessageProtoFieldType<() => {
pcPtlBegin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
pcPtlEnd: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
macPtlBegin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
macPtlEnd: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
ptlsSupport: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, true>;
ptlsNotSupport: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, true>;
}, false, false>;
crmFlags: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, true, false>;
}, true, false>;
richMsg: import("napcat-protobuf").MessageProtoFieldType<() => {
template1: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
serviceId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
msgResId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
rand: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
seq: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, true, false>;
}, true, false>;
groupFile: import("napcat-protobuf").MessageProtoFieldType<() => {
filename: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
batchId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileKey: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
mark: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
sequence: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
batchItemId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
feedMsgTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
extraInfo: import("napcat-protobuf").MessageProtoFieldType<() => {
nick: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
groupCard: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
level: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
flags: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
groupMask: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
msgTailId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
senderTitle: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
apnsTips: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
uin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
msgStateFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
apnsSoundType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
newGroupFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
}, true, false>;
videoFile: import("napcat-protobuf").MessageProtoFieldType<() => {
fileUuid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileFormat: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbFileMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
source: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
thumbFileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
busiType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fromChatType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
toChatType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
boolSupportProgressive: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
fileWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
subBusiType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
videoAttr: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bytesThumbFileUrls: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, true>;
bytesVideoFileUrls: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, true>;
thumbDownloadFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
videoDownloadFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
anonymousGroupMessage: import("napcat-protobuf").MessageProtoFieldType<() => {
flags: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
anonId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
anonNick: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
headPortrait: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
expireTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bubbleId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
rankColor: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
customElem: import("napcat-protobuf").MessageProtoFieldType<() => {
desc: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
data: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
enumType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
ext: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
sound: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
generalFlags: import("napcat-protobuf").MessageProtoFieldType<() => {
bubbleDiyTextId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
groupFlagNew: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
uin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
rpId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
prpFold: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
longTextFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
longTextResId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
groupType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
toUinFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
glamourLevel: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
memberLevel: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
groupRankSeq: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
olympicTorch: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
babyqGuideMsgCookie: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
uin32ExpertFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bubbleSubId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pendantId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
rpIndex: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
srcMsg: import("napcat-protobuf").MessageProtoFieldType<() => {
origSeqs: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, true>;
senderUin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
time: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
flag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
elems: import("napcat-protobuf").MessageProtoFieldType<() => /*elided*/ any, false, true>;
type: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
richMsg: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
pbReserve: import("napcat-protobuf").MessageProtoFieldType<() => {
messageId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
senderUid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
receiverUid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
friendSeq: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, true, false>;
}, true, false>;
sourceMsg: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
toUin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, true, false>;
troopName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
}, true, false>;
lightAppElem: import("napcat-protobuf").MessageProtoFieldType<() => {
data: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
msgResid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
}, true, false>;
commonElem: import("napcat-protobuf").MessageProtoFieldType<() => {
serviceType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbElem: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
businessType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
}, true, false>;
};
export declare const Text: {
str: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
lint: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
attr6Buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
attr7Buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
};
export declare const Face: {
index: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
old: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
};
export declare const OnlineImage: {
guid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
filePath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
oldVerSendFile: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
};
export declare const NotOnlineImage: {
filePath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
downloadPath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
oldVerSendFile: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
imgType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
previewsImage: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
picMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
picHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
picWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
resId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
flag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
thumbUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
original: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bigUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
origUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
bizType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
result: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
index: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
opFaceBuf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
oldPicMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
thumbWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
showLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
downloadLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
x400Url: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
x400Width: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
x400Height: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbRes: import("napcat-protobuf").MessageProtoFieldType<() => {
subType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field3: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field4: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
summary: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
field10: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field20: import("napcat-protobuf").MessageProtoFieldType<() => {
field1: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field2: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
field3: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field4: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field7: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
}, false, false>;
url: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
md5Str: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
}, false, false>;
};
export declare const NotOnlineImage_PbReserve: {
subType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field3: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field4: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
summary: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
field10: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field20: import("napcat-protobuf").MessageProtoFieldType<() => {
field1: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field2: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
field3: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field4: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field7: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
}, false, false>;
url: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
md5Str: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
};
export declare const NotOnlineImage_PbReserve2: {
field1: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field2: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
field3: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field4: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field7: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
};
export declare const TransElem: {
elemType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
elemValue: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
};
export declare const MarketFace: {
faceName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
itemType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
faceInfo: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
faceId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
tabId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
subType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
key: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
param: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
mediaType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
imageWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
imageHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
mobileparam: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
pbReserve: import("napcat-protobuf").MessageProtoFieldType<() => {
field8: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
}, false, false>;
};
export declare const MarketFacePbRes: {
field8: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
};
export declare const CustomFace: {
guid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
filePath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
shortcut: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
buffer: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
flag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
oldData: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
serverIp: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
serverPort: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
fileType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
signature: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
useful: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
md5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
thumbUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
bigUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
origUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
bizType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
repeatIndex: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
repeatImage: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
imageType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
index: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
width: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
height: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
source: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
size: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
origin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
thumbHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
showLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
downloadLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
x400Url: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
x400Width: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
x400Height: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbRes: import("napcat-protobuf").MessageProtoFieldType<() => {
subType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
summary: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
}, true, false>;
};
export declare const CustomFace_PbReserve: {
subType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
summary: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
};
export declare const ElemFlags2: {
colorTextId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
msgId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
whisperSessionId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
pttChangeBit: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
vipStatus: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
compatibleId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
insts: import("napcat-protobuf").MessageProtoFieldType<() => {
appId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
instId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
}, false, true>;
msgRptCnt: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
srcInst: import("napcat-protobuf").MessageProtoFieldType<() => {
appId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
instId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
}, false, false>;
longtitude: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
latitude: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
customFont: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
pcSupportDef: import("napcat-protobuf").MessageProtoFieldType<() => {
pcPtlBegin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
pcPtlEnd: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
macPtlBegin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
macPtlEnd: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
ptlsSupport: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, true>;
ptlsNotSupport: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, true>;
}, false, false>;
crmFlags: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, true, false>;
};
export declare const PcSupportDef: {
pcPtlBegin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
pcPtlEnd: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
macPtlBegin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
macPtlEnd: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
ptlsSupport: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, true>;
ptlsNotSupport: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, true>;
};
export declare const Instance: {
appId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
instId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
};
export declare const RichMsg: {
template1: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
serviceId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
msgResId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
rand: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
seq: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, true, false>;
};
export declare const GroupFile: {
filename: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
batchId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileKey: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
mark: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
sequence: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
batchItemId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
feedMsgTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
};
export declare const ExtraInfo: {
nick: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
groupCard: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
level: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
flags: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
groupMask: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
msgTailId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
senderTitle: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
apnsTips: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
uin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
msgStateFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
apnsSoundType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
newGroupFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
};
export declare const VideoFile: {
fileUuid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileFormat: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbFileMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
source: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
thumbFileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
busiType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fromChatType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
toChatType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
boolSupportProgressive: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
fileWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
subBusiType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
videoAttr: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bytesThumbFileUrls: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, true>;
bytesVideoFileUrls: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, true>;
thumbDownloadFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
videoDownloadFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
};
export declare const AnonymousGroupMessage: {
flags: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
anonId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
anonNick: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
headPortrait: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
expireTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bubbleId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
rankColor: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
};
export declare const CustomElem: {
desc: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
data: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
enumType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
ext: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
sound: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
};
export declare const GeneralFlags: {
bubbleDiyTextId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
groupFlagNew: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
uin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
rpId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
prpFold: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
longTextFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
longTextResId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
groupType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
toUinFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
glamourLevel: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
memberLevel: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
groupRankSeq: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
olympicTorch: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
babyqGuideMsgCookie: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
uin32ExpertFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bubbleSubId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pendantId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
rpIndex: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
};
export declare const SrcMsg: {
origSeqs: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, true>;
senderUin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
time: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
flag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
elems: import("napcat-protobuf").MessageProtoFieldType<() => {
text: import("napcat-protobuf").MessageProtoFieldType<() => {
str: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
lint: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
attr6Buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
attr7Buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
}, true, false>;
face: import("napcat-protobuf").MessageProtoFieldType<() => {
index: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
old: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
}, true, false>;
onlineImage: import("napcat-protobuf").MessageProtoFieldType<() => {
guid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
filePath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
oldVerSendFile: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
notOnlineImage: import("napcat-protobuf").MessageProtoFieldType<() => {
filePath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
downloadPath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
oldVerSendFile: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
imgType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
previewsImage: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
picMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
picHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
picWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
resId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
flag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
thumbUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
original: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bigUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
origUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
bizType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
result: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
index: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
opFaceBuf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
oldPicMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
thumbWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
showLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
downloadLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
x400Url: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
x400Width: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
x400Height: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbRes: import("napcat-protobuf").MessageProtoFieldType<() => {
subType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field3: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field4: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
summary: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
field10: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field20: import("napcat-protobuf").MessageProtoFieldType<() => {
field1: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field2: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
field3: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field4: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field7: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
}, false, false>;
url: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
md5Str: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
}, false, false>;
}, true, false>;
transElem: import("napcat-protobuf").MessageProtoFieldType<() => {
elemType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
elemValue: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
marketFace: import("napcat-protobuf").MessageProtoFieldType<() => {
faceName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
itemType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
faceInfo: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
faceId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
tabId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
subType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
key: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
param: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
mediaType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
imageWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
imageHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
mobileparam: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
pbReserve: import("napcat-protobuf").MessageProtoFieldType<() => {
field8: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
}, false, false>;
}, true, false>;
customFace: import("napcat-protobuf").MessageProtoFieldType<() => {
guid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
filePath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
shortcut: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
buffer: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
flag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
oldData: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
serverIp: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
serverPort: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
fileType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
signature: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
useful: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
md5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
thumbUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
bigUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
origUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
bizType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
repeatIndex: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
repeatImage: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
imageType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
index: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
width: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
height: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
source: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
size: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
origin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
thumbHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
showLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
downloadLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
x400Url: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
x400Width: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
x400Height: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbRes: import("napcat-protobuf").MessageProtoFieldType<() => {
subType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
summary: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
}, true, false>;
}, true, false>;
elemFlags2: import("napcat-protobuf").MessageProtoFieldType<() => {
colorTextId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
msgId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
whisperSessionId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
pttChangeBit: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
vipStatus: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
compatibleId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
insts: import("napcat-protobuf").MessageProtoFieldType<() => {
appId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
instId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
}, false, true>;
msgRptCnt: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
srcInst: import("napcat-protobuf").MessageProtoFieldType<() => {
appId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
instId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
}, false, false>;
longtitude: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
latitude: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
customFont: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
pcSupportDef: import("napcat-protobuf").MessageProtoFieldType<() => {
pcPtlBegin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
pcPtlEnd: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
macPtlBegin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
macPtlEnd: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
ptlsSupport: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, true>;
ptlsNotSupport: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, true>;
}, false, false>;
crmFlags: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, true, false>;
}, true, false>;
richMsg: import("napcat-protobuf").MessageProtoFieldType<() => {
template1: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
serviceId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
msgResId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
rand: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
seq: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, true, false>;
}, true, false>;
groupFile: import("napcat-protobuf").MessageProtoFieldType<() => {
filename: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
batchId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileKey: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
mark: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
sequence: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
batchItemId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
feedMsgTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
extraInfo: import("napcat-protobuf").MessageProtoFieldType<() => {
nick: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
groupCard: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
level: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
flags: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
groupMask: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
msgTailId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
senderTitle: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
apnsTips: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
uin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
msgStateFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
apnsSoundType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
newGroupFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
}, true, false>;
videoFile: import("napcat-protobuf").MessageProtoFieldType<() => {
fileUuid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileFormat: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbFileMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
source: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
thumbFileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
busiType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fromChatType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
toChatType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
boolSupportProgressive: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
fileWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
subBusiType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
videoAttr: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bytesThumbFileUrls: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, true>;
bytesVideoFileUrls: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, true>;
thumbDownloadFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
videoDownloadFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
anonymousGroupMessage: import("napcat-protobuf").MessageProtoFieldType<() => {
flags: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
anonId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
anonNick: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
headPortrait: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
expireTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bubbleId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
rankColor: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
customElem: import("napcat-protobuf").MessageProtoFieldType<() => {
desc: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
data: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
enumType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
ext: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
sound: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
generalFlags: import("napcat-protobuf").MessageProtoFieldType<() => {
bubbleDiyTextId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
groupFlagNew: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
uin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
rpId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
prpFold: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
longTextFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
longTextResId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
groupType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
toUinFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
glamourLevel: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
memberLevel: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
groupRankSeq: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
olympicTorch: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
babyqGuideMsgCookie: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
uin32ExpertFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bubbleSubId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pendantId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
rpIndex: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
srcMsg: import("napcat-protobuf").MessageProtoFieldType<() => /*elided*/ any, true, false>;
lightAppElem: import("napcat-protobuf").MessageProtoFieldType<() => {
data: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
msgResid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
}, true, false>;
commonElem: import("napcat-protobuf").MessageProtoFieldType<() => {
serviceType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbElem: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
businessType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
}, true, false>;
}, false, true>;
type: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
richMsg: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
pbReserve: import("napcat-protobuf").MessageProtoFieldType<() => {
messageId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
senderUid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
receiverUid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
friendSeq: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, true, false>;
}, true, false>;
sourceMsg: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
toUin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, true, false>;
troopName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
};
export declare const SrcMsgPbRes: {
messageId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
senderUid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
receiverUid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
friendSeq: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, true, false>;
};
export declare const LightAppElem: {
data: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
msgResid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
};
export declare const CommonElem: {
serviceType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbElem: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
businessType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
};
export declare const FaceExtra: {
faceId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
};
export declare const MentionExtra: {
type: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
uin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, true, false>;
field5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
uid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
};
export declare const QBigFaceExtra: {
AniStickerPackId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
AniStickerId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
faceId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
sourceType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
AniStickerType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
resultId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
preview: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
randomType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
};
export declare const QSmallFaceExtra: {
faceId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
preview: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
preview2: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
};
export declare const MarkdownData: {
content: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
};
@@ -0,0 +1,6 @@
"use strict";
module.exports = function () {
// https://mths.be/emoji
return /\uD83C\uDFF4\uDB40\uDC67\uDB40\uDC62(?:\uDB40\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDB40\uDC73\uDB40\uDC63\uDB40\uDC74|\uDB40\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F|\uD83D\uDC68(?:\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68\uD83C\uDFFB|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFE])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83D\uDC68|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D[\uDC66\uDC67])|[\u2695\u2696\u2708]\uFE0F|\uD83D[\uDC66\uDC67]|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|(?:\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708])\uFE0F|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C[\uDFFB-\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFB\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)\uD83C\uDFFB|\uD83E\uDDD1(?:\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1(?:\uD83C[\uDFFB-\uDFFF])|\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1)|(?:\uD83E\uDDD1\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFE])|(?:\uD83E\uDDD1\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)(?:\uD83C[\uDFFB\uDFFC])|\uD83D\uDC69(?:\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFC-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|(?:\uD83E\uDDD1\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)(?:\uD83C[\uDFFB-\uDFFD])|\uD83D\uDC69\u200D\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D\uDC41\uFE0F\u200D\uD83D\uDDE8|\uD83D\uDC69(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])|(?:(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)\uFE0F|\uD83D\uDC6F|\uD83E[\uDD3C\uDDDE\uDDDF])\u200D[\u2640\u2642]|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD6-\uDDDD])(?:(?:\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|\u200D[\u2640\u2642])|\uD83C\uDFF4\u200D\u2620)\uFE0F|\uD83D\uDC69\u200D\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|\uD83C\uDFF3\uFE0F\u200D\uD83C\uDF08|\uD83D\uDC15\u200D\uD83E\uDDBA|\uLine truncated
};
@@ -0,0 +1,26 @@
Copyright (c) 2013, Dominic Tarr
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
The views and conclusions contained in the software and documentation are those
of the authors and should not be interpreted as representing official policies,
either expressed or implied, of the FreeBSD Project.
@@ -0,0 +1,16 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = assertNode;
var _isNode = require("../validators/isNode.js");
function assertNode(node) {
if (!(0, _isNode.default)(node)) {
var _node$type;
const type = (_node$type = node == null ? void 0 : node.type) != null ? _node$type : JSON.stringify(node);
throw new TypeError(`Not a valid node of type "${type}"`);
}
}
//# sourceMappingURL=assertNode.js.map
@@ -0,0 +1,28 @@
"use strict";
var _construct = require("./_construct.cjs");
var _get_prototype_of = require("./_get_prototype_of.cjs");
var _is_native_function = require("./_is_native_function.cjs");
var _set_prototype_of = require("./_set_prototype_of.cjs");
function _wrap_native_super(Class) {
var _cache = typeof Map === "function" ? new Map() : undefined;
exports._ = _wrap_native_super = function(Class) {
if (Class === null || !_is_native_function._(Class)) return Class;
if (typeof Class !== "function") throw new TypeError("Super expression must either be null or a function");
if (typeof _cache !== "undefined") {
if (_cache.has(Class)) return _cache.get(Class);
_cache.set(Class, Wrapper);
}
function Wrapper() {
return _construct._(Class, arguments, _get_prototype_of._(this).constructor);
}
Wrapper.prototype = Object.create(Class.prototype, { constructor: { value: Wrapper, enumerable: false, writable: true, configurable: true } });
return _set_prototype_of._(Wrapper, Class);
};
return _wrap_native_super(Class);
}
exports._ = _wrap_native_super;
@@ -0,0 +1,39 @@
var baseMerge = require('./_baseMerge'),
createAssigner = require('./_createAssigner');
/**
* This method is like `_.merge` except that it accepts `customizer` which
* is invoked to produce the merged values of the destination and source
* properties. If `customizer` returns `undefined`, merging is handled by the
* method instead. The `customizer` is invoked with six arguments:
* (objValue, srcValue, key, object, source, stack).
*
* **Note:** This method mutates `object`.
*
* @static
* @memberOf _
* @since 4.0.0
* @category Object
* @param {Object} object The destination object.
* @param {...Object} sources The source objects.
* @param {Function} customizer The function to customize assigned values.
* @returns {Object} Returns `object`.
* @example
*
* function customizer(objValue, srcValue) {
* if (_.isArray(objValue)) {
* return objValue.concat(srcValue);
* }
* }
*
* var object = { 'a': [1], 'b': [2] };
* var other = { 'a': [3], 'b': [4] };
*
* _.mergeWith(object, other, customizer);
* // => { 'a': [1, 3], 'b': [2, 4] }
*/
var mergeWith = createAssigner(function(object, source, srcIndex, customizer) {
baseMerge(object, source, srcIndex, customizer);
});
module.exports = mergeWith;
@@ -0,0 +1 @@
module.exports={A:{A:{"2":"K D E F A B wC"},B:{"1":"0 1 2 3 4 5 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 GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB I","2":"C L M G N O P"},C:{"1":"0 1 2 3 4 5 6 7 8 9 G N O P aB AB BB CB DB EB FB bB cB 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 UC 4B VC 5B 6B 7B 8B 9B AC BC CC DC EC FC GC HC IC JC KC LC Q H R WC 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 GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB I XC MC YC yC zC","2":"xC TC J ZB K D E F A B C L M 0C 1C"},D:{"1":"0 1 2 3 4 5 6 7 8 9 G N O P aB AB BB CB DB EB FB bB cB 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 UC 4B VC 5B 6B 7B 8B 9B AC BC CC DC EC FC GC HC IC JC KC LC 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 GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB I XC MC YC","16":"J ZB K D E F A B C L M"},E:{"1":"K D E F A B C L M G 3C 4C 5C 6C aC NC OC 7C 8C 9C bC cC PC AD QC dC eC fC gC hC BD RC iC jC kC lC mC CD SC nC oC pC qC rC sC tC DD ED","2":"J ZB 2C ZC"},F:{"1":"0 1 2 3 4 5 6 7 8 9 C G N O P aB AB BB CB DB EB FB bB cB dB eB fB gB hB iB jB kB lB mB nB oB pB qB rB sB tB uB vB wB xB yB zB 0B 1B 2B 3B 4B 5B 6B 7B 8B 9B AC BC CC DC EC FC GC HC IC JC KC LC Q H R WC 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 JD OC","2":"F B FD GD HD ID NC uC"},G:{"1":"E LD MD ND OD PD QD RD SD TD UD VD WD XD YD ZD aD bD cD dD bC cC PC eD QC dC eC fC gC hC fD RC iC jC kC lC mC gD SC nC oC pC qC rC sC tC","16":"ZC KD vC"},H:{"1":"hD"},I:{"1":"I mD nD","16":"TC J iD jD kD lD vC"},J:{"16":"D A"},K:{"1":"C H OC","2":"A B NC uC"},L:{"1":"I"},M:{"1":"MC"},N:{"2":"A B"},O:{"1":"PC"},P:{"1":"6 7 8 9 J AB BB CB DB EB FB oD pD qD rD sD aC tD uD vD wD xD QC RC SC yD"},Q:{"1":"zD"},R:{"1":"0D"},S:{"1":"1D 2D"}},B:4,C:"SVG vector-effect: non-scaling-stroke",D:true};
@@ -0,0 +1,46 @@
/**
* @author Toru Nagashima <https://github.com/mysticatea>
* See LICENSE file in root directory for full license.
*/
"use strict"
const { READ, ReferenceTracker } = require("@eslint-community/eslint-utils")
const { getSourceCode } = require("eslint-compat-utils")
module.exports = {
meta: {
docs: {
description: "disallow the `Object.getPrototypeOf` method.",
category: "ES5",
recommended: false,
url: "http://eslint-community.github.io/eslint-plugin-es-x/rules/no-object-getprototypeof.html",
},
fixable: null,
messages: {
forbidden: "ES5 '{{name}}' method is forbidden.",
},
schema: [],
type: "problem",
},
create(context) {
return {
"Program:exit"(program) {
const sourceCode = getSourceCode(context)
const tracker = new ReferenceTracker(
sourceCode.getScope(program),
)
for (const { node, path } of tracker.iterateGlobalReferences({
Object: {
getPrototypeOf: { [READ]: true },
},
})) {
context.report({
node,
messageId: "forbidden",
data: { name: path.join(".") },
})
}
},
}
},
}
@@ -0,0 +1,9 @@
{
"extends": "@ljharb/tsconfig",
"compilerOptions": {
"target": "es2021",
},
"exclude": [
"coverage",
],
}
@@ -0,0 +1,116 @@
#
# PowerShell script for controlling the console QuickEdit and InsertMode flags.
#
# Turn QuickEdit off to interact with mouse-driven console programs.
#
# Usage:
#
# powershell .\ConinMode.ps1 [Options]
#
# Options:
# -QuickEdit [on/off]
# -InsertMode [on/off]
# -Mode [integer]
#
param (
[ValidateSet("on", "off")][string] $QuickEdit,
[ValidateSet("on", "off")][string] $InsertMode,
[int] $Mode
)
$signature = @'
[DllImport("kernel32.dll", SetLastError = true)]
public static extern IntPtr GetStdHandle(int nStdHandle);
[DllImport("kernel32.dll", SetLastError = true)]
public static extern uint GetConsoleMode(
IntPtr hConsoleHandle,
out uint lpMode);
[DllImport("kernel32.dll", SetLastError = true)]
public static extern uint SetConsoleMode(
IntPtr hConsoleHandle,
uint dwMode);
public const int STD_INPUT_HANDLE = -10;
public const int ENABLE_INSERT_MODE = 0x0020;
public const int ENABLE_QUICK_EDIT_MODE = 0x0040;
public const int ENABLE_EXTENDED_FLAGS = 0x0080;
'@
$WinAPI = Add-Type -MemberDefinition $signature `
-Name WinAPI -Namespace ConinModeScript `
-PassThru
function GetConIn {
$ret = $WinAPI::GetStdHandle($WinAPI::STD_INPUT_HANDLE)
if ($ret -eq -1) {
throw "error: cannot get stdin"
}
return $ret
}
function GetConsoleMode {
$conin = GetConIn
$mode = 0
$ret = $WinAPI::GetConsoleMode($conin, [ref]$mode)
if ($ret -eq 0) {
throw "GetConsoleMode failed (is stdin a console?)"
}
return $mode
}
function SetConsoleMode($mode) {
$conin = GetConIn
$ret = $WinAPI::SetConsoleMode($conin, $mode)
if ($ret -eq 0) {
throw "SetConsoleMode failed (is stdin a console?)"
}
}
$oldMode = GetConsoleMode
$newMode = $oldMode
$doingSomething = $false
if ($PSBoundParameters.ContainsKey("Mode")) {
$newMode = $Mode
$doingSomething = $true
}
if ($QuickEdit + $InsertMode -ne "") {
if (!($newMode -band $WinAPI::ENABLE_EXTENDED_FLAGS)) {
# We can't enable an extended flag without overwriting the existing
# QuickEdit/InsertMode flags. AFAICT, there is no way to query their
# existing values, so at least we can choose sensible defaults.
$newMode = $newMode -bor $WinAPI::ENABLE_EXTENDED_FLAGS
$newMode = $newMode -bor $WinAPI::ENABLE_QUICK_EDIT_MODE
$newMode = $newMode -bor $WinAPI::ENABLE_INSERT_MODE
$doingSomething = $true
}
}
if ($QuickEdit -eq "on") {
$newMode = $newMode -bor $WinAPI::ENABLE_QUICK_EDIT_MODE
$doingSomething = $true
} elseif ($QuickEdit -eq "off") {
$newMode = $newMode -band (-bnot $WinAPI::ENABLE_QUICK_EDIT_MODE)
$doingSomething = $true
}
if ($InsertMode -eq "on") {
$newMode = $newMode -bor $WinAPI::ENABLE_INSERT_MODE
$doingSomething = $true
} elseif ($InsertMode -eq "off") {
$newMode = $newMode -band (-bnot $WinAPI::ENABLE_INSERT_MODE)
$doingSomething = $true
}
if ($doingSomething) {
echo "old mode: $oldMode"
SetConsoleMode $newMode
$newMode = GetConsoleMode
echo "new mode: $newMode"
} else {
echo "mode: $oldMode"
}
@@ -0,0 +1 @@
{"mappings":";;;;;AAAA;;;;;;;;;;CAUC;;;;AAgBM,SAAS,0CAAiB,OAA8B;IAC7D,yGAAyG;IACzG,UAAU,CAAA,GAAA,kBAAU,EAAE,oBAAA,qBAAA,UAAW,CAAC,GAAG;IACrC,IAAI,UAAC,MAAM,EAAC,GAAG,CAAA,GAAA,yCAAQ;IACvB,OAAO,CAAA,GAAA,cAAM,EAAE,IAAM,IAAI,CAAA,GAAA,oBAAY,EAAE,QAAQ,UAAU;QAAC;QAAQ;KAAQ;AAC5E;AAEA,SAAS,8BAAQ,CAAuB,EAAE,CAAuB;IAC/D,IAAI,MAAM,GACR,OAAO;IAGT,IAAI,QAAQ,OAAO,IAAI,CAAC;IACxB,IAAI,QAAQ,OAAO,IAAI,CAAC;IACxB,IAAI,MAAM,MAAM,KAAK,MAAM,MAAM,EAC/B,OAAO;IAGT,KAAK,IAAI,OAAO,MAAO;QACrB,IAAI,CAAC,CAAC,IAAI,KAAK,CAAC,CAAC,IAAI,EACnB,OAAO;IAEX;IAEA,OAAO;AACT","sources":["packages/@react-aria/i18n/src/useDateFormatter.ts"],"sourcesContent":["/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {DateFormatter} from '@internationalized/date';\nimport {useDeepMemo} from '@react-aria/utils';\nimport {useLocale} from './context';\nimport {useMemo} from 'react';\n\nexport interface DateFormatterOptions extends Intl.DateTimeFormatOptions {\n calendar?: string\n}\n\n/**\n * Provides localized date formatting for the current locale. Automatically updates when the locale changes,\n * and handles caching of the date formatter for performance.\n * @param options - Formatting options.\n */\nexport function useDateFormatter(options?: DateFormatterOptions): DateFormatter {\n // Reuse last options object if it is shallowly equal, which allows the useMemo result to also be reused.\n options = useDeepMemo(options ?? {}, isEqual);\n let {locale} = useLocale();\n return useMemo(() => new DateFormatter(locale, options), [locale, options]);\n}\n\nfunction isEqual(a: DateFormatterOptions, b: DateFormatterOptions) {\n if (a === b) {\n return true;\n }\n\n let aKeys = Object.keys(a);\n let bKeys = Object.keys(b);\n if (aKeys.length !== bKeys.length) {\n return false;\n }\n\n for (let key of aKeys) {\n if (b[key] !== a[key]) {\n return false;\n }\n }\n\n return true;\n}\n"],"names":[],"version":3,"file":"useDateFormatter.module.js.map"}
@@ -0,0 +1 @@
{"version":3,"file":"decode-data-xml.d.ts","sourceRoot":"https://raw.githubusercontent.com/fb55/entities/61afd4701eaa736978b13c7351cd3de9a96b04bc/src/","sources":["generated/decode-data-xml.ts"],"names":[],"mappings":";AAEA,wBAKE"}
@@ -0,0 +1,61 @@
# typedarray
TypedArray polyfill ripped from [this
module](https://raw.github.com/inexorabletash/polyfill).
[![build status](https://secure.travis-ci.org/substack/typedarray.png)](http://travis-ci.org/substack/typedarray)
[![testling badge](https://ci.testling.com/substack/typedarray.png)](https://ci.testling.com/substack/typedarray)
# example
``` js
var Uint8Array = require('typedarray').Uint8Array;
var ua = new Uint8Array(5);
ua[1] = 256 + 55;
console.log(ua[1]);
```
output:
```
55
```
# methods
``` js
var TA = require('typedarray')
```
The `TA` object has the following constructors:
* TA.ArrayBuffer
* TA.DataView
* TA.Float32Array
* TA.Float64Array
* TA.Int8Array
* TA.Int16Array
* TA.Int32Array
* TA.Uint8Array
* TA.Uint8ClampedArray
* TA.Uint16Array
* TA.Uint32Array
# install
With [npm](https://npmjs.org) do:
```
npm install typedarray
```
To use this module in the browser, compile with
[browserify](http://browserify.org)
or download a UMD build from browserify CDN:
http://wzrd.in/standalone/typedarray@latest
# license
MIT
@@ -0,0 +1,17 @@
/**
* https://tc39.es/ecma402/#sec-isvalidtimezonename
* @param tz
* @param implDetails implementation details
*/
export function IsValidTimeZoneName(tz, _a) {
var zoneNamesFromData = _a.zoneNamesFromData, uppercaseLinks = _a.uppercaseLinks;
var uppercasedTz = tz.toUpperCase();
var zoneNames = new Set();
var linkNames = new Set();
zoneNamesFromData.map(function (z) { return z.toUpperCase(); }).forEach(function (z) { return zoneNames.add(z); });
Object.keys(uppercaseLinks).forEach(function (linkName) {
linkNames.add(linkName.toUpperCase());
zoneNames.add(uppercaseLinks[linkName].toUpperCase());
});
return zoneNames.has(uppercasedTz) || linkNames.has(uppercasedTz);
}
@@ -0,0 +1 @@
module.exports={A:{A:{"2":"K D E F A B wC"},B:{"2":"C L M G N O P Q H R S T","132":"0 1 2 3 4 5 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 GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB I"},C:{"2":"0 1 2 3 4 5 6 7 8 9 xC TC J ZB K D E F A B C L M G N O P aB AB BB CB DB EB FB bB cB 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 UC 4B VC 5B 6B 7B 8B 9B AC BC CC DC EC FC GC HC IC JC KC LC Q H R WC 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 GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB I XC MC YC yC zC 0C 1C"},D:{"2":"6 7 8 9 J ZB K D E F A B C L M G N O P aB AB BB CB DB EB FB bB cB 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 UC 4B VC 5B 6B 7B 8B 9B AC BC CC DC EC FC GC HC IC JC KC LC Q H R S T","132":"0 1 2 3 4 5 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 GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB I XC MC YC"},E:{"2":"J ZB K D E F A B C L M G 2C ZC 3C 4C 5C 6C aC NC OC 7C 8C 9C bC cC PC AD QC dC eC fC gC hC BD RC iC jC kC lC mC CD SC nC oC pC qC rC sC tC DD ED"},F:{"2":"6 7 8 9 F B C G N O P aB AB BB CB DB EB FB bB cB dB eB fB gB hB iB jB kB lB mB nB oB pB qB rB sB tB uB vB wB xB yB zB 0B 1B 2B 3B 4B 5B 6B 7B 8B 9B AC BC CC DC FD GD HD ID NC uC JD OC","132":"0 1 2 3 4 5 EC FC GC HC IC JC KC LC Q H R WC 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"},G:{"2":"E ZC KD vC LD MD ND OD PD QD RD SD TD UD VD WD XD YD ZD aD bD cD dD bC cC PC eD QC dC eC fC gC hC fD RC iC jC kC lC mC gD SC nC oC pC qC rC sC tC"},H:{"2":"hD"},I:{"2":"TC J iD jD kD lD vC mD nD","132":"I"},J:{"2":"D A"},K:{"2":"A B C NC uC OC","132":"H"},L:{"132":"I"},M:{"2":"MC"},N:{"2":"A B"},O:{"2":"PC"},P:{"2":"6 7 8 9 J AB BB CB DB EB FB oD pD qD rD sD aC tD uD vD wD xD QC RC SC yD"},Q:{"2":"zD"},R:{"132":"0D"},S:{"2":"1D 2D"}},B:7,C:"Document Policy",D:true};
@@ -0,0 +1,23 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports["default"] = void 0;
var _ariaQuery = require("aria-query");
var _jsxAstUtils = require("jsx-ast-utils");
var abstractRoles = new Set(_ariaQuery.roles.keys().filter(function (role) {
return _ariaQuery.roles.get(role)["abstract"];
}));
var DOMElements = new Set(_ariaQuery.dom.keys());
var isAbstractRole = function isAbstractRole(tagName, attributes) {
// Do not test higher level JSX components, as we do not know what
// low-level DOM element this maps to.
if (!DOMElements.has(tagName)) {
return false;
}
var role = (0, _jsxAstUtils.getLiteralPropValue)((0, _jsxAstUtils.getProp)(attributes, 'role'));
return abstractRoles.has(role);
};
var _default = exports["default"] = isAbstractRole;
module.exports = exports.default;
@@ -0,0 +1 @@
function e(e){"@hwc/retry"===globalThis?.process?.env.DEBUG&&console.debug(e)}class RetryTask{id=Math.random().toString(36).slice(2);fn;error;timestamp=Date.now();lastAttempt=this.timestamp;resolve;reject;signal;constructor(e,t,r,i,s){this.fn=e,this.error=t,this.timestamp=Date.now(),this.lastAttempt=Date.now(),this.resolve=r,this.reject=i,this.signal=s}get age(){return Date.now()-this.timestamp}}class Retrier{#e=[];#t=[];#r=0;#i;#s;#n;#o;#c;constructor(e,{timeout:t=6e4,maxDelay:r=100,concurrency:i=1e3}={}){if("function"!=typeof e)throw new Error("Missing function to check errors");this.#o=e,this.#i=t,this.#s=r,this.#c=i}get retrying(){return this.#e.length}get pending(){return this.#t.length}get working(){return this.#r}#a(t,{signal:r,promise:i,resolve:s,reject:n}){let o;try{o=t()}catch(e){return n(new Error(`Synchronous error: ${e.message}`,{cause:e})),i}return o&&"function"==typeof o.then?(this.#r++,i.finally((()=>{this.#r--,this.#h()})).catch((()=>{})),Promise.resolve(o).then((t=>{e("Function called successfully without retry."),s(t)})).catch((i=>{if(!this.#o(i))return void n(i);const o=new RetryTask(t,i,s,n,r);e(`Function failed, queuing for retry with task ${o.id}.`),this.#e.push(o),r?.addEventListener("abort",(()=>{e(`Task ${o.id} was aborted due to AbortSignal.`),n(r.reason)})),this.#g()})),i):(n(new Error("Result is not a promise.")),i)}retry(e,{signal:t}={}){t?.throwIfAborted();const{promise:r,resolve:i,reject:s}=function(){if(Promise.withResolvers)return Promise.withResolvers();let e,t;const r=new Promise(((r,i)=>{e=r,t=i}));if(void 0===e||void 0===t)throw new Error("Promise executor did not initialize resolve or reject.");return{promise:r,resolve:e,reject:t}}();return this.#t.push((()=>this.#a(e,{signal:t,promise:r,resolve:i,reject:s}))),this.#h(),r}#u(){this.pending&&this.#h(),this.retrying&&this.#g()}#h(){e(`Processing pending tasks: ${this.pending} pending, ${this.working} working.`);const t=this.#c-this.working;if(t<=0)return;const r=Math.min(this.pending,t);for(let e=0;e<r;e++){const e=this.#t.shift();e?.()}e(`Processed pending tasks: ${this.pending} pending, ${this.working} working.`)}#g(){clearTimeout(this.#n),this.#n=void 0,e(`Processing retry queue: ${this.retrying} retrying, ${this.working} working.`);const t=()=>{this.#n=setTimeout((()=>this.#u()),0)},r=this.#e.shift();return r?function(e,t){return e.age>t}(r,this.#i)?(e(`Task ${r.id} was abandoned due to timeout.`),r.reject(r.error),void t()):function(e,t){const r=Date.now()-e.lastAttempt,i=Math.max(e.lastAttempt-e.timestamp,1);return r>=Math.min(1.2*i,t)}(r,this.#s)?(r.lastAttempt=Date.now(),void Promise.resolve(r.fn()).then((t=>{e(`Task ${r.id} succeeded after ${r.age}ms.`),r.resolve(t)})).catch((t=>{if(!this.#o(t))return e(`Task ${r.id} failed with non-retryable error: ${t.message}.`),void r.reject(t);r.lastAttempt=Date.now(),this.#e.push(r),e(`Task ${r.id} failed, requeueing to try again.`)})).finally((()=>{this.#u()}))):(e(`Task ${r.id} is not ready to retry, skipping.`),this.#e.push(r),void t()):(e("Queue is empty, exiting."),void(this.pending&&t()))}}export{Retrier};
Loaded 100 of 35554 files, more files were not shown because too many files have changed in this diff. Show more