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,23 @@
/*
* 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 {FocusableElement} from '@react-types/shared';
import {PressProps} from './usePress';
import React, {MutableRefObject} from 'react';
interface IPressResponderContext extends PressProps {
register(): void,
ref?: MutableRefObject<FocusableElement>
}
export const PressResponderContext: React.Context<IPressResponderContext> = React.createContext<IPressResponderContext>({register: () => {}});
PressResponderContext.displayName = 'PressResponderContext';
@@ -0,0 +1 @@
{"name":"@sinclair/typebox","version":"0.34.41","requiresBuild":false,"files":{"license":{"checkedAt":1794532099535,"integrity":"sha512-doE3FrhCkqf+onYCc39vt1NQZYukDkWKeKk2k6cib2QLKc0mnd0n6siJ4jbAy+l4x661rhkdo3UpHoxFF2JUWg==","mode":420,"size":1227},"build/cjs/type/any/any.js":{"checkedAt":1794532099535,"integrity":"sha512-c1AKLxSEXaBvY4ZUmjK6De4bv5F0ZOaQDdWRggj5nBamdRXhug/0cCqrg2FFaAcxG22f8wKyS97kqpn1HYSqEw==","mode":420,"size":320},"build/cjs/type/schema/anyschema.js":{"checkedAt":1794532099535,"integrity":"sha512-2X+xyjGu/Jnj0/X3qbWKodMwYytPoAJp6iy5mLXI7MBzhSA00jV2OmXPo8lgvWKBwiA4zxYTsQvjrrw7GZAnpQ==","mode":420,"size":78},"build/cjs/type/argument/argument.js":{"checkedAt":1794532099535,"integrity":"sha512-kw1L5P8HQsqJ30Nmrh/Wpn3R1Oe1af0gdSaku5w1jxs8oMuxAXQyT7JbmbsqwGXB1JVeV5PcS2xKcCoU/WYTTQ==","mode":420,"size":345},"build/cjs/type/array/array.js":{"checkedAt":1794532099536,"integrity":"sha512-TqxLwr/6nQttDWBedLOGuXgYk35Fz+NaYkhS02R+LJHTWsZ93OtqtRhMidr05P496UgN3zhNjqVJ6Dy5f4NOhg==","mode":420,"size":356},"build/cjs/value/assert/assert.js":{"checkedAt":1794532099536,"integrity":"sha512-sPjA7T6HA84mYjZpo9VVLMTHH7dEzblmyzHYMwChdhyHHE4jF4QuecHNlfaEshOrbiDLQbyUo8hvCiRZSmds1w==","mode":420,"size":3059},"build/cjs/type/async-iterator/async-iterator.js":{"checkedAt":1794532099536,"integrity":"sha512-R9eHIz9NjjBQaKPDafkshBu04UiyLntoFP2Wx3s2KvY2im7VAaH73RwjXUV9f3/ALptpeUxaCSbeb7PeU55leg==","mode":420,"size":409},"build/cjs/type/awaited/awaited.js":{"checkedAt":1794532099536,"integrity":"sha512-+04Kz3MXD5iAkNcHPD9QdFUDNHiAXZtEj2+LXF1T05fUZVvbUaQejB9sUmCUn4ejBNYQuwOsiUOOBVHFQxsrrg==","mode":420,"size":1617},"build/cjs/type/bigint/bigint.js":{"checkedAt":1794532099536,"integrity":"sha512-pySocvxfG6Lx/5F1QYJ7x+3GirGsJDsZlN0wiyCKUHGcwYS/KNGBFpMkpS7b+Nb/JuWpZ5KEtu8sMQZjMuJm6Q==","mode":420,"size":356},"build/cjs/type/boolean/boolean.js":{"checkedAt":1794532099536,"integrity":"sha512-84ND9CdAEi4gPDxBWr1d/y0tZxf1ojhw2DJ4vwQA2f5t7hprBbQi0jx7fPEITzddepFBxIw8+ko0DZQUH2GYaw==","mode":420,"size":356},"build/cjs/type/intrinsic/capitalize.js":{"checkedAt":1794532099537,"integrity":"sha512-2K85Pw6CSXDPNz5+zQb2k1a0uNNwScsQtHKrFgPP4cwT1pJrBzCy767D6Dpg66e8NpnBOocd7fzM7bT2ptwkrQ==","mode":420,"size":330},"build/cjs/value/cast/cast.js":{"checkedAt":1794532099537,"integrity":"sha512-UA0VGJhTSk3oIRwLcoebO3bUKZGUYtpfkGIDik82BMEWPcQSY0Mq/gUe2tvMwVVfuBG6ORkri+3hyN1eMJIeOQ==","mode":420,"size":11292},"build/cjs/value/check/check.js":{"checkedAt":1794532099537,"integrity":"sha512-8KvmmIhqtkMJs2q6KN8lUQPn7Am5CS/QfHZKUaaf+WRbajbwPFh+pg44L5yN+H2HdDG3WpF/i2+pph2zwcXw6g==","mode":420,"size":17934},"build/cjs/value/clean/clean.js":{"checkedAt":1794532099537,"integrity":"sha512-Xt+lnj5vls/nq+ntGuNjw1xou4GdVve0XFQLoGwFhZJXjOgwsXDQXIknDHNMZTen269nQ3B+73CRToQwK88FFg==","mode":420,"size":6464},"build/cjs/value/clone/clone.js":{"checkedAt":1794532099537,"integrity":"sha512-nNjZ3H0G1uND4/Ok1+UGPhFbEEDXJKd4YkjbwxGz8qaum3boR5eFg7y115iBKl8qeti780bo01U+tvjJ4uJ6Pw==","mode":420,"size":1911},"build/cjs/compiler/compiler.js":{"checkedAt":1794532099538,"integrity":"sha512-JoE5nnquuL60Eb4p10hNiaTzAOdgaEa14qmyHzLo/+dtFdgototsMisqAgSUrLfS5Xm+5CKncZwFGkxj5QqVog==","mode":420,"size":33129},"build/cjs/type/composite/composite.js":{"checkedAt":1794532099538,"integrity":"sha512-Sm3+NQW/UUiT1xLWca8spZWkY2bdncrlkpK3b3Yf31aKjUhghj7H5hc3BHD4pu36haLf/XeEbN+3fIKcsqMznw==","mode":420,"size":1393},"build/cjs/type/module/compute.js":{"checkedAt":1794532099538,"integrity":"sha512-wsX5M23Wj5iAvcAAI4QBbjVl6+6ria4HYL28sAAIqoqkqhbsJkIQ6ty7qZtWh4q8xWTFHA5dCw5bXPHE57ql6Q==","mode":420,"size":9654},"build/cjs/type/computed/computed.js":{"checkedAt":1794532099538,"integrity":"sha512-CmW5bTOwj1C+KcWeKvhj5gwmnE3a3EouGDz/4RljTW1J8JeWJgWvi0lKdgpK6JN03h4N8TAo5T6NeJ0MQ3MTuw==","mode":420,"size":519},"build/cjs/type/const/const.js":{"checkedAt":1794532099538,"integrity":"sha512-uz1qtdhhyqbO5Vggmx5JsNY3RZjQT4/o7tJsCJFlfWgzmsnU/MVDa6f+FjIzf6gyFc+40OWwTjTZm4Gtv8jp5A==","mode":420,"size":3078},"build/cjs/type/constructor-parameters/constructor-parameters.js":{"checkedAt":1794532099538,"integrity":"sha512-c04PArv741oNa8QKcNuR1fS623Ei5ptfkvQB0SEJww9vk0SemahCHXZJTlxjPU2PY5qIa/fGT1Mh/BUEH8axww==","mode":420,"size":1902},"build/cjs/type/constructor/constructor.js":{"checkedAt":1794532099539,"integrity":"sha512-3Hf68iGwPnJuFvNTSxVPOK32iytzduPH04VM9eRyS+bSvTX26dK7vqKO5a16D3YAkt0SXapzLfBH+sveUOYVcw==","mode":420,"size":425},"build/cjs/value/convert/convert.js":{"checkedAt":1794532099539,"integrity":"sha512-yIU0vhMA4srDRGIh8XWtzhnbj2zmzt9TktNFybz75jhkdqdg556NRPXm6c5/u1Zi+45RgJMZKk9XFCnRkFNU2w==","mode":420,"size":11849},"build/cjs/value/create/create.js":{"checkedAt":1794532099539,"integrity":"sha512-DVnxwOvpAxm4lT0zlwu7xgn3EExLeAwliSsF1w9+QSyi8vOrsGYyqIL4162Jfxaz5KU5Qh86ZThhAAw18I2LHg==","mode":420,"size":15753},"build/cjs/type/date/date.js":{"checkedAt":1794532099539,"integrity":"sha512-6cxMp9cK4IehVWVOejEUGMkFYg9Moa5mb8wPcV4MyBnX4N6pf2SqZLEPn7Qfkp+jnAjeR4aAf19QUY5C/evfGQ==","mode":420,"size":341},"builLine truncated
@@ -0,0 +1,5 @@
var convert = require('./convert'),
func = convert('stubArray', require('../stubArray'), require('./_falseOptions'));
func.placeholder = require('./placeholder');
module.exports = func;
@@ -0,0 +1,41 @@
import {
useSeparator
} from "./chunk-D2EG5U3Q.mjs";
// src/use-divider.ts
import { divider } from "@heroui/theme";
import { useCallback, useMemo } from "react";
function useDivider(props) {
const { as, className, orientation, ...otherProps } = props;
let Component = as || "hr";
if (Component === "hr" && orientation === "vertical") {
Component = "div";
}
const { separatorProps } = useSeparator({
elementType: typeof Component === "string" ? Component : "hr",
orientation
});
const styles = useMemo(
() => divider({
orientation,
className
}),
[orientation, className]
);
const getDividerProps = useCallback(
(props2 = {}) => ({
className: styles,
role: "separator",
"data-orientation": orientation,
...separatorProps,
...otherProps,
...props2
}),
[styles, orientation, separatorProps, otherProps]
);
return { Component, getDividerProps };
}
export {
useDivider
};
@@ -0,0 +1,24 @@
'use strict';
var callBound = require('call-bound');
// eslint-disable-next-line no-extra-parens
var $deref = /** @type {<T extends WeakKey>(thisArg: WeakRef<T>) => T | undefined} */ (callBound('WeakRef.prototype.deref', true));
/** @type {import('.')} */
module.exports = typeof WeakRef === 'undefined'
? function isWeakRef(_value) { // eslint-disable-line no-unused-vars
return false;
}
: function isWeakRef(value) {
if (!value || typeof value !== 'object') {
return false;
}
try {
// @ts-expect-error
$deref(value);
return true;
} catch (e) {
return false;
}
};
@@ -0,0 +1,148 @@
'use strict';
var utils = require('../utils.js');
require('eslint-visitor-keys');
require('espree');
require('estraverse');
var arrayBracketSpacing = utils.createRule({
name: "array-bracket-spacing",
package: "js",
meta: {
type: "layout",
docs: {
description: "Enforce consistent spacing inside array brackets"
},
fixable: "whitespace",
schema: [
{
type: "string",
enum: ["always", "never"]
},
{
type: "object",
properties: {
singleValue: {
type: "boolean"
},
objectsInArrays: {
type: "boolean"
},
arraysInArrays: {
type: "boolean"
}
},
additionalProperties: false
}
],
messages: {
unexpectedSpaceAfter: "There should be no space after '{{tokenValue}}'.",
unexpectedSpaceBefore: "There should be no space before '{{tokenValue}}'.",
missingSpaceAfter: "A space is required after '{{tokenValue}}'.",
missingSpaceBefore: "A space is required before '{{tokenValue}}'."
}
},
create(context) {
const spaced = context.options[0] === "always";
const sourceCode = context.sourceCode;
function isOptionSet(option) {
return context.options[1] ? context.options[1][option] === !spaced : false;
}
const options = {
spaced,
singleElementException: isOptionSet("singleValue"),
objectsInArraysException: isOptionSet("objectsInArrays"),
arraysInArraysException: isOptionSet("arraysInArrays")
};
function reportNoBeginningSpace(node, token) {
const nextToken = sourceCode.getTokenAfter(token);
context.report({
node,
loc: { start: token.loc.end, end: nextToken.loc.start },
messageId: "unexpectedSpaceAfter",
data: {
tokenValue: token.value
},
fix(fixer) {
return fixer.removeRange([token.range[1], nextToken.range[0]]);
}
});
}
function reportNoEndingSpace(node, token) {
const previousToken = sourceCode.getTokenBefore(token);
context.report({
node,
loc: { start: previousToken.loc.end, end: token.loc.start },
messageId: "unexpectedSpaceBefore",
data: {
tokenValue: token.value
},
fix(fixer) {
return fixer.removeRange([previousToken.range[1], token.range[0]]);
}
});
}
function reportRequiredBeginningSpace(node, token) {
context.report({
node,
loc: token.loc,
messageId: "missingSpaceAfter",
data: {
tokenValue: token.value
},
fix(fixer) {
return fixer.insertTextAfter(token, " ");
}
});
}
function reportRequiredEndingSpace(node, token) {
context.report({
node,
loc: token.loc,
messageId: "missingSpaceBefore",
data: {
tokenValue: token.value
},
fix(fixer) {
return fixer.insertTextBefore(token, " ");
}
});
}
function isObjectType(node) {
return node && (node.type === "ObjectExpression" || node.type === "ObjectPattern");
}
function isArrayType(node) {
return node && (node.type === "ArrayExpression" || node.type === "ArrayPattern");
}
function validateArraySpacing(node) {
if (options.spaced && node.elements.length === 0)
return;
const first = sourceCode.getFirstToken(node);
const second = sourceCode.getFirstToken(node, 1);
const last = node.type === "ArrayPattern" && node.typeAnnotation ? sourceCode.getTokenBefore(node.typeAnnotation) : sourceCode.getLastToken(node);
const penultimate = sourceCode.getTokenBefore(last);
const firstElement = node.elements[0];
const lastElement = node.elements[node.elements.length - 1];
const openingBracketMustBeSpaced = firstElement && options.objectsInArraysException && isObjectType(firstElement) || firstElement && options.arraysInArraysException && isArrayType(firstElement) || options.singleElementException && node.elements.length === 1 ? !options.spaced : options.spaced;
const closingBracketMustBeSpaced = lastElement && options.objectsInArraysException && isObjectType(lastElement) || lastElement && options.arraysInArraysException && isArrayType(lastElement) || options.singleElementException && node.elements.length === 1 ? !options.spaced : options.spaced;
if (utils.isTokenOnSameLine(first, second)) {
if (openingBracketMustBeSpaced && !sourceCode.isSpaceBetweenTokens(first, second))
reportRequiredBeginningSpace(node, first);
if (!openingBracketMustBeSpaced && sourceCode.isSpaceBetweenTokens(first, second))
reportNoBeginningSpace(node, first);
}
if (first !== penultimate && utils.isTokenOnSameLine(penultimate, last)) {
if (closingBracketMustBeSpaced && !sourceCode.isSpaceBetweenTokens(penultimate, last))
reportRequiredEndingSpace(node, last);
if (!closingBracketMustBeSpaced && sourceCode.isSpaceBetweenTokens(penultimate, last))
reportNoEndingSpace(node, last);
}
}
return {
ArrayPattern: validateArraySpacing,
ArrayExpression: validateArraySpacing
};
}
});
module.exports = arrayBracketSpacing;
@@ -0,0 +1 @@
{"mappings":";;AAAA;;;;;;;;;;CAUC;AAmBD,0GAA0G;AAC1G,4HAA4H;AAC5H,IAAI,8BAAe;AACnB,IAAI,wCAAkB;AACtB,IAAI,2CAAqB,IAAI;AAEtB,SAAS,0CAAqB,MAAgB;IACnD,IAAI,CAAA,GAAA,YAAI,KAAK;QACX,IAAI,gCAAU,WAAW;YAEvB,MAAM,iBAAiB,CAAA,GAAA,uBAAe,EAAE;YACxC,wCAAkB,eAAe,eAAe,CAAC,KAAK,CAAC,gBAAgB;YACvE,eAAe,eAAe,CAAC,KAAK,CAAC,gBAAgB,GAAG;QAC1D;QAEA,8BAAQ;IACV,OAAO,IAAI,kBAAkB,eAAe,kBAAkB,YAAY;QACxE,sFAAsF;QACtF,kDAAkD;QAClD,IAAI,WAAW,gBAAgB,OAAO,KAAK,GAAG,eAAe;QAC7D,yCAAmB,GAAG,CAAC,QAAQ,OAAO,KAAK,CAAC,SAAS;QACrD,OAAO,KAAK,CAAC,SAAS,GAAG;IAC3B;AACF;AAEO,SAAS,0CAAqB,MAAgB;IACnD,IAAI,CAAA,GAAA,YAAI,KAAK;QACX,0DAA0D;QAC1D,sEAAsE;QACtE,IAAI,gCAAU,YACZ;QAGF,8BAAQ;QAER,uEAAuE;QACvE,+DAA+D;QAC/D,WAAW;YACT,uEAAuE;YACvE,oEAAoE;YACpE,CAAA,GAAA,yBAAiB,EAAE;gBACjB,wBAAwB;gBACxB,IAAI,gCAAU,aAAa;oBAEzB,MAAM,iBAAiB,CAAA,GAAA,uBAAe,EAAE;oBACxC,IAAI,eAAe,eAAe,CAAC,KAAK,CAAC,gBAAgB,KAAK,QAC5D,eAAe,eAAe,CAAC,KAAK,CAAC,gBAAgB,GAAG,yCAAmB;oBAG7E,wCAAkB;oBAClB,8BAAQ;gBACV;YACF;QACF,GAAG;IACL,OAAO,IAAI,kBAAkB,eAAe,kBAAkB,YAC5D,+DAA+D;IAC/D,kDAAkD;IAClD;QAAA,IAAI,UAAU,yCAAmB,GAAG,CAAC,SAAS;YAC5C,IAAI,sBAAsB,yCAAmB,GAAG,CAAC;YACjD,IAAI,WAAW,gBAAgB,OAAO,KAAK,GAAG,eAAe;YAE7D,IAAI,OAAO,KAAK,CAAC,SAAS,KAAK,QAC7B,OAAO,KAAK,CAAC,SAAS,GAAG;YAG3B,IAAI,OAAO,YAAY,CAAC,aAAa,IACnC,OAAO,eAAe,CAAC;YAEzB,yCAAmB,MAAM,CAAC;QAC5B;IAAA;AAEJ","sources":["packages/@react-aria/interactions/src/textSelection.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 {getOwnerDocument, isIOS, runAfterTransition} from '@react-aria/utils';\n\n// Safari on iOS starts selecting text on long press. The only way to avoid this, it seems,\n// is to add user-select: none to the entire page. Adding it to the pressable element prevents\n// that element from being selected, but nearby elements may still receive selection. We add\n// user-select: none on touch start, and remove it again on touch end to prevent this.\n// This must be implemented using global state to avoid race conditions between multiple elements.\n\n// There are three possible states due to the delay before removing user-select: none after\n// pointer up. The 'default' state always transitions to the 'disabled' state, which transitions\n// to 'restoring'. The 'restoring' state can either transition back to 'disabled' or 'default'.\n\n// For non-iOS devices, we apply user-select: none to the pressed element instead to avoid possible\n// performance issues that arise from applying and removing user-select: none to the entire page\n// (see https://github.com/adobe/react-spectrum/issues/1609).\ntype State = 'default' | 'disabled' | 'restoring';\n\n// Note that state only matters here for iOS. Non-iOS gets user-select: none applied to the target element\n// rather than at the document level so we just need to apply/remove user-select: none for each pressed element individually\nlet state: State = 'default';\nlet savedUserSelect = '';\nlet modifiedElementMap = new WeakMap<Element, string>();\n\nexport function disableTextSelection(target?: Element): void {\n if (isIOS()) {\n if (state === 'default') {\n\n const documentObject = getOwnerDocument(target);\n savedUserSelect = documentObject.documentElement.style.webkitUserSelect;\n documentObject.documentElement.style.webkitUserSelect = 'none';\n }\n\n state = 'disabled';\n } else if (target instanceof HTMLElement || target instanceof SVGElement) {\n // If not iOS, store the target's original user-select and change to user-select: none\n // Ignore state since it doesn't apply for non iOS\n let property = 'userSelect' in target.style ? 'userSelect' : 'webkitUserSelect';\n modifiedElementMap.set(target, target.style[property]);\n target.style[property] = 'none';\n }\n}\n\nexport function restoreTextSelection(target?: Element): void {\n if (isIOS()) {\n // If the state is already default, there's nothing to do.\n // If it is restoring, then there's no need to queue a second restore.\n if (state !== 'disabled') {\n return;\n }\n\n state = 'restoring';\n\n // There appears to be a delay on iOS where selection still might occur\n // after pointer up, so wait a bit before removing user-select.\n setTimeout(() => {\n // Wait for any CSS transitions to complete so we don't recompute style\n // for the whole page in the middle of the animation and cause jank.\n runAfterTransition(() => {\n // AvoiLine truncated
@@ -0,0 +1,14 @@
import basicLogPrefix from "./basicLogPrefix.mjs";
import formatMessage from "./formatMessage.mjs";
class BasicLayout {
/**
* Format the log event (格式化日志事件)
* @param event Log event (日志事件)
*/
format(event) {
return `${basicLogPrefix(event)} ${formatMessage(event.message)}`;
}
}
export {
BasicLayout as default
};
@@ -0,0 +1,354 @@
var $4ae0260a69729f1d$exports = require("./conversion.main.js");
var $4d88eff242b38a9e$exports = require("./weekStartData.main.js");
function $parcel$export(e, n, v, s) {
Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
}
$parcel$export(module.exports, "isSameDay", () => $1f0f7ebf1ae6c530$export$ea39ec197993aef0);
$parcel$export(module.exports, "isSameMonth", () => $1f0f7ebf1ae6c530$export$a18c89cbd24170ff);
$parcel$export(module.exports, "startOfMonth", () => $1f0f7ebf1ae6c530$export$a5a3b454ada2268e);
$parcel$export(module.exports, "isSameYear", () => $1f0f7ebf1ae6c530$export$5841f9eb9773f25f);
$parcel$export(module.exports, "startOfYear", () => $1f0f7ebf1ae6c530$export$f91e89d3d0406102);
$parcel$export(module.exports, "isEqualDay", () => $1f0f7ebf1ae6c530$export$91b62ebf2ba703ee);
$parcel$export(module.exports, "isEqualCalendar", () => $1f0f7ebf1ae6c530$export$dbc69fd56b53d5e);
$parcel$export(module.exports, "isEqualMonth", () => $1f0f7ebf1ae6c530$export$5a8da0c44a3afdf2);
$parcel$export(module.exports, "isEqualYear", () => $1f0f7ebf1ae6c530$export$ea840f5a6dda8147);
$parcel$export(module.exports, "isToday", () => $1f0f7ebf1ae6c530$export$629b0a497aa65267);
$parcel$export(module.exports, "today", () => $1f0f7ebf1ae6c530$export$d0bdf45af03a6ea3);
$parcel$export(module.exports, "getDayOfWeek", () => $1f0f7ebf1ae6c530$export$2061056d06d7cdf7);
$parcel$export(module.exports, "now", () => $1f0f7ebf1ae6c530$export$461939dd4422153);
$parcel$export(module.exports, "compareDate", () => $1f0f7ebf1ae6c530$export$68781ddf31c0090f);
$parcel$export(module.exports, "compareTime", () => $1f0f7ebf1ae6c530$export$c19a80a9721b80f6);
$parcel$export(module.exports, "getHoursInDay", () => $1f0f7ebf1ae6c530$export$126c91c941de7e);
$parcel$export(module.exports, "getLocalTimeZone", () => $1f0f7ebf1ae6c530$export$aa8b41735afcabd2);
$parcel$export(module.exports, "setLocalTimeZone", () => $1f0f7ebf1ae6c530$export$61a9d83ceb59a3dd);
$parcel$export(module.exports, "resetLocalTimeZone", () => $1f0f7ebf1ae6c530$export$55753838ffe79333);
$parcel$export(module.exports, "endOfMonth", () => $1f0f7ebf1ae6c530$export$a2258d9c4118825c);
$parcel$export(module.exports, "endOfYear", () => $1f0f7ebf1ae6c530$export$8b7aa55c66d5569e);
$parcel$export(module.exports, "getMinimumMonthInYear", () => $1f0f7ebf1ae6c530$export$5412ac11713b72ad);
$parcel$export(module.exports, "getMinimumDayInMonth", () => $1f0f7ebf1ae6c530$export$b2f4953d301981d5);
$parcel$export(module.exports, "startOfWeek", () => $1f0f7ebf1ae6c530$export$42c81a444fbfb5d4);
$parcel$export(module.exports, "endOfWeek", () => $1f0f7ebf1ae6c530$export$ef8b6d9133084f4e);
$parcel$export(module.exports, "getWeeksInMonth", () => $1f0f7ebf1ae6c530$export$ccc1b2479e7dd654);
$parcel$export(module.exports, "minDate", () => $1f0f7ebf1ae6c530$export$5c333a116e949cdd);
$parcel$export(module.exports, "maxDate", () => $1f0f7ebf1ae6c530$export$a75f2bff57811055);
$parcel$export(module.exports, "isWeekend", () => $1f0f7ebf1ae6c530$export$618d60ea299da42);
$parcel$export(module.exports, "isWeekday", () => $1f0f7ebf1ae6c530$export$ee9d87258e1d19ed);
/*
* 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 $1f0f7ebf1ae6c530$export$ea39ec197993aef0(a, b) {
b = (0, $4ae0260a69729f1d$exports.toCalendar)(b, a.calendar);
return a.era === b.era && a.year === b.year && a.month === b.month && a.day === b.day;
}
function $1f0f7ebf1ae6c530$export$a18c89cbd24170ff(a, b) {
b = (0, $4ae0260a69729f1d$exports.toCalendar)(b, a.calendar);
// In the Japanese calendar, months can span multiple eras/years, so only compare the first of the month.
a = $1f0f7ebf1ae6c530$export$a5a3b454ada2268e(a);
b = $1f0f7ebf1ae6c530$export$a5a3b454ada2268e(b);
return a.era === b.era && a.year === b.year && a.month === b.month;
}
function $1f0f7ebf1ae6c530$export$5841f9eb9773f25f(a, b) {
b = (0, $4ae0260a69729f1d$exports.toCalendar)(b, a.calendar);
a = $1f0f7ebf1ae6c530$export$f91e89d3d0406102(a);
b = $1f0f7ebf1ae6c530$export$f91e89d3d0406102(b);
return a.era === b.era && a.year === b.year;
}
function $1f0f7ebf1ae6c530$export$91b62ebf2ba703ee(a, b) {
return $1f0f7ebf1ae6c530$export$dbc69fd56b53d5e(a.calendar, b.calendar) && $1f0f7ebf1ae6c530$export$ea39ec197993aef0(a, b);
}
function $1f0f7ebf1ae6c530$export$5a8da0c44a3afdf2(a, b) {
return $1f0f7ebf1ae6c530$export$dbc69fd56b53d5e(a.calendar, b.calendar) && $1f0f7ebf1ae6c530$export$a18c89cbd24170ff(a, b);
}
function $1f0f7ebf1ae6c530$export$ea840f5a6dda8147(a, b) {
return $1f0f7ebf1ae6c530$export$dbc69fd56b53d5e(a.calendar, b.calendar) && $1f0f7ebf1ae6c530$export$5841f9eb9773f25f(a, b);
}
function $1f0f7ebf1ae6c530$export$dbc69fd56b53d5e(a, b) {
var _a_isEqual, _b_isEqual;
var _a_isEqual1, _ref;
return (_ref = (_a_isEqual1 = (_a_isEqual = a.isEqual) === null || _a_isEqual === void 0 ? void 0 : _a_isEqual.call(a, b)) !== null && _a_isEqual1 !== void 0 ? _a_isEqual1 : (_b_isEqual = b.isEqual) === null || _b_isEqual === void 0 ? void 0 : _b_isEqual.call(b, a)) !== null && _ref !== void 0 ? _ref : a.identifier === b.identifier;
}
function $1f0f7ebf1ae6c530$export$629b0a497aa65267(date, timeZone) {
return $1f0f7ebf1ae6c530$export$ea39ec197993aef0(date, $1f0f7ebf1ae6c530$export$d0bdf45af03a6ea3(timeZone));
}
const $1f0f7ebf1ae6c530$var$DAY_MAP = {
sun: 0,
mon: 1,
tue: 2,
wed: 3,
thu: 4,
fri: 5,
sat: 6
};
function $1f0f7ebf1ae6c530$export$2061056d06d7cdf7(date, locale, firstDayOfWeek) {
let julian = date.calendar.toJulianDay(date);
// If julian is negative, then julian % 7 will be negative, so we adjust
// accordingly. Julian day 0 is Monday.
let weekStart = firstDayOfWeek ? $1f0f7ebf1ae6c530$var$DAY_MAP[firstDayOfWeek] : $1f0f7ebf1ae6c530$var$getWeekStart(locale);
let dayOfWeek = Math.ceil(julian + 1 - weekStart) % 7;
if (dayOfWeek < 0) dayOfWeek += 7;
return dayOfWeek;
}
function $1f0f7ebf1ae6c530$export$461939dd4422153(timeZone) {
return (0, $4ae0260a69729f1d$exports.fromAbsolute)(Date.now(), timeZone);
}
function $1f0f7ebf1ae6c530$export$d0bdf45af03a6ea3(timeZone) {
return (0, $4ae0260a69729f1d$exports.toCalendarDate)($1f0f7ebf1ae6c530$export$461939dd4422153(timeZone));
}
function $1f0f7ebf1ae6c530$export$68781ddf31c0090f(a, b) {
return a.calendar.toJulianDay(a) - b.calendar.toJulianDay(b);
}
function $1f0f7ebf1ae6c530$export$c19a80a9721b80f6(a, b) {
return $1f0f7ebf1ae6c530$var$timeToMs(a) - $1f0f7ebf1ae6c530$var$timeToMs(b);
}
function $1f0f7ebf1ae6c530$var$timeToMs(a) {
return a.hour * 3600000 + a.minute * 60000 + a.second * 1000 + a.millisecond;
}
function $1f0f7ebf1ae6c530$export$126c91c941de7e(a, timeZone) {
let ms = (0, $4ae0260a69729f1d$exports.toAbsolute)(a, timeZone);
let tomorrow = a.add({
days: 1
});
let tomorrowMs = (0, $4ae0260a69729f1d$exports.toAbsolute)(tomorrow, timeZone);
return (tomorrowMs - ms) / 3600000;
}
let $1f0f7ebf1ae6c530$var$localTimeZone = null;
function $1f0f7ebf1ae6c530$export$aa8b41735afcabd2() {
if ($1f0f7ebf1ae6c530$var$localTimeZone == null) $1f0f7ebf1ae6c530$var$localTimeZone = new Intl.DateTimeFormat().resolvedOptions().timeZone;
return $1f0f7ebf1ae6c530$var$localTimeZone;
}
function $1f0f7ebf1ae6c530$export$61a9d83ceb59a3dd(timeZone) {
$1f0f7ebf1ae6c530$var$localTimeZone = timeZone;
}
function $1f0f7ebf1ae6c530$export$55753838ffe79333() {
$1f0f7ebf1ae6c530$var$localTimeZone = null;
}
function $1f0f7ebf1ae6c530$export$a5a3b454ada2268e(date) {
// Use `subtract` instead of `set` so we don't get constrained in an era.
return date.subtract({
days: date.day - 1
});
}
function $1f0f7ebf1ae6c530$export$a2258d9c4118825c(date) {
return date.add({
days: date.calendar.getDaysInMonth(date) - date.day
});
}
function $1f0f7ebf1ae6c530$export$f91e89d3d0406102(date) {
return $1f0f7ebf1ae6c530$export$a5a3b454ada2268e(date.subtract({
months: date.month - 1
}));
}
function $1f0f7ebf1ae6c530$export$8b7aa55c66d5569e(date) {
return $1f0f7ebf1ae6c530$export$a2258d9c4118825c(date.add({
months: date.calendar.getMonthsInYear(date) - date.month
}));
}
function $1f0f7ebf1ae6c530$export$5412ac11713b72ad(date) {
if (date.calendar.getMinimumMonthInYear) return date.calendar.getMinimumMonthInYear(date);
return 1;
}
function $1f0f7ebf1ae6c530$export$b2f4953d301981d5(date) {
if (date.calendar.getMinimumDayInMonth) return date.calendar.getMinimumDayInMonth(date);
return 1;
}
function $1f0f7ebf1ae6c530$export$42c81a444fbfb5d4(date, locale, firstDayOfWeek) {
let dayOfWeek = $1f0f7ebf1ae6c530$export$2061056d06d7cdf7(date, locale, firstDayOfWeek);
return date.subtract({
days: dayOfWeek
});
}
function $1f0f7ebf1ae6c530$export$ef8b6d9133084f4e(date, locale, firstDayOfWeek) {
return $1f0f7ebf1ae6c530$export$42c81a444fbfb5d4(date, locale, firstDayOfWeek).add({
days: 6
});
}
const $1f0f7ebf1ae6c530$var$cachedRegions = new Map();
const $1f0f7ebf1ae6c530$var$cachedWeekInfo = new Map();
function $1f0f7ebf1ae6c530$var$getRegion(locale) {
// If the Intl.Locale API is available, use it to get the region for the locale.
// @ts-ignore
if (Intl.Locale) {
// Constructing an Intl.Locale is expensive, so cache the result.
let region = $1f0f7ebf1ae6c530$var$cachedRegions.get(locale);
if (!region) {
// @ts-ignore
region = new Intl.Locale(locale).maximize().region;
if (region) $1f0f7ebf1ae6c530$var$cachedRegions.set(locale, region);
}
return region;
}
// If not, just try splitting the string.
// If the second part of the locale string is 'u',
// then this is a unicode extension, so ignore it.
// Otherwise, it should be the region.
let part = locale.split('-')[1];
return part === 'u' ? undefined : part;
}
function $1f0f7ebf1ae6c530$var$getWeekStart(locale) {
// TODO: use Intl.Locale for this once browsers support the weekInfo property
// https://github.com/tc39/proposal-intl-locale-info
let weekInfo = $1f0f7ebf1ae6c530$var$cachedWeekInfo.get(locale);
if (!weekInfo) {
if (Intl.Locale) {
// @ts-ignore
let localeInst = new Intl.Locale(locale);
if ('getWeekInfo' in localeInst) {
// @ts-expect-error
weekInfo = localeInst.getWeekInfo();
if (weekInfo) {
$1f0f7ebf1ae6c530$var$cachedWeekInfo.set(locale, weekInfo);
return weekInfo.firstDay;
}
}
}
let region = $1f0f7ebf1ae6c530$var$getRegion(locale);
if (locale.includes('-fw-')) {
// pull the value for the attribute fw from strings such as en-US-u-ca-iso8601-fw-tue or en-US-u-ca-iso8601-fw-mon-nu-thai
// where the fw attribute could be followed by another unicode locale extension or not
let day = locale.split('-fw-')[1].split('-')[0];
if (day === 'mon') weekInfo = {
firstDay: 1
};
else if (day === 'tue') weekInfo = {
firstDay: 2
};
else if (day === 'wed') weekInfo = {
firstDay: 3
};
else if (day === 'thu') weekInfo = {
firstDay: 4
};
else if (day === 'fri') weekInfo = {
firstDay: 5
};
else if (day === 'sat') weekInfo = {
firstDay: 6
};
else weekInfo = {
firstDay: 0
};
} else if (locale.includes('-ca-iso8601')) weekInfo = {
firstDay: 1
};
else weekInfo = {
firstDay: region ? (0, $4d88eff242b38a9e$exports.weekStartData)[region] || 0 : 0
};
$1f0f7ebf1ae6c530$var$cachedWeekInfo.set(locale, weekInfo);
}
return weekInfo.firstDay;
}
function $1f0f7ebf1ae6c530$export$ccc1b2479e7dd654(date, locale, firstDayOfWeek) {
let days = date.calendar.getDaysInMonth(date);
return Math.ceil(($1f0f7ebf1ae6c530$export$2061056d06d7cdf7($1f0f7ebf1ae6c530$export$a5a3b454ada2268e(date), locale, firstDayOfWeek) + days) / 7);
}
function $1f0f7ebf1ae6c530$export$5c333a116e949cdd(a, b) {
if (a && b) return a.compare(b) <= 0 ? a : b;
return a || b;
}
function $1f0f7ebf1ae6c530$export$a75f2bff57811055(a, b) {
if (a && b) return a.compare(b) >= 0 ? a : b;
return a || b;
}
const $1f0f7ebf1ae6c530$var$WEEKEND_DATA = {
AF: [
4,
5
],
AE: [
5,
6
],
BH: [
5,
6
],
DZ: [
5,
6
],
EG: [
5,
6
],
IL: [
5,
6
],
IQ: [
5,
6
],
IR: [
5,
5
],
JO: [
5,
6
],
KW: [
5,
6
],
LY: [
5,
6
],
OM: [
5,
6
],
QA: [
5,
6
],
SA: [
5,
6
],
SD: [
5,
6
],
SY: [
5,
6
],
YE: [
5,
6
]
};
function $1f0f7ebf1ae6c530$export$618d60ea299da42(date, locale) {
let julian = date.calendar.toJulianDay(date);
// If julian is negative, then julian % 7 will be negative, so we adjust
// accordingly. Julian day 0 is Monday.
let dayOfWeek = Math.ceil(julian + 1) % 7;
if (dayOfWeek < 0) dayOfWeek += 7;
let region = $1f0f7ebf1ae6c530$var$getRegion(locale);
// Use Intl.Locale for this once weekInfo is supported.
// https://github.com/tc39/proposal-intl-locale-info
let [start, end] = $1f0f7ebf1ae6c530$var$WEEKEND_DATA[region] || [
6,
0
];
return dayOfWeek === start || dayOfWeek === end;
}
function $1f0f7ebf1ae6c530$export$ee9d87258e1d19ed(date, locale) {
return !$1f0f7ebf1ae6c530$export$618d60ea299da42(date, locale);
}
//# sourceMappingURL=queries.main.js.map
@@ -0,0 +1,145 @@
;(function (root, factory, undef) {
if (typeof exports === "object") {
// CommonJS
module.exports = exports = factory(require("./core"), require("./sha256"), require("./hmac"));
}
else if (typeof define === "function" && define.amd) {
// AMD
define(["./core", "./sha256", "./hmac"], factory);
}
else {
// Global (browser)
factory(root.CryptoJS);
}
}(this, function (CryptoJS) {
(function () {
// Shortcuts
var C = CryptoJS;
var C_lib = C.lib;
var Base = C_lib.Base;
var WordArray = C_lib.WordArray;
var C_algo = C.algo;
var SHA256 = C_algo.SHA256;
var HMAC = C_algo.HMAC;
/**
* Password-Based Key Derivation Function 2 algorithm.
*/
var PBKDF2 = C_algo.PBKDF2 = Base.extend({
/**
* Configuration options.
*
* @property {number} keySize The key size in words to generate. Default: 4 (128 bits)
* @property {Hasher} hasher The hasher to use. Default: SHA256
* @property {number} iterations The number of iterations to perform. Default: 250000
*/
cfg: Base.extend({
keySize: 128/32,
hasher: SHA256,
iterations: 250000
}),
/**
* Initializes a newly created key derivation function.
*
* @param {Object} cfg (Optional) The configuration options to use for the derivation.
*
* @example
*
* var kdf = CryptoJS.algo.PBKDF2.create();
* var kdf = CryptoJS.algo.PBKDF2.create({ keySize: 8 });
* var kdf = CryptoJS.algo.PBKDF2.create({ keySize: 8, iterations: 1000 });
*/
init: function (cfg) {
this.cfg = this.cfg.extend(cfg);
},
/**
* Computes the Password-Based Key Derivation Function 2.
*
* @param {WordArray|string} password The password.
* @param {WordArray|string} salt A salt.
*
* @return {WordArray} The derived key.
*
* @example
*
* var key = kdf.compute(password, salt);
*/
compute: function (password, salt) {
// Shortcut
var cfg = this.cfg;
// Init HMAC
var hmac = HMAC.create(cfg.hasher, password);
// Initial values
var derivedKey = WordArray.create();
var blockIndex = WordArray.create([0x00000001]);
// Shortcuts
var derivedKeyWords = derivedKey.words;
var blockIndexWords = blockIndex.words;
var keySize = cfg.keySize;
var iterations = cfg.iterations;
// Generate key
while (derivedKeyWords.length < keySize) {
var block = hmac.update(salt).finalize(blockIndex);
hmac.reset();
// Shortcuts
var blockWords = block.words;
var blockWordsLength = blockWords.length;
// Iterations
var intermediate = block;
for (var i = 1; i < iterations; i++) {
intermediate = hmac.finalize(intermediate);
hmac.reset();
// Shortcut
var intermediateWords = intermediate.words;
// XOR intermediate with block
for (var j = 0; j < blockWordsLength; j++) {
blockWords[j] ^= intermediateWords[j];
}
}
derivedKey.concat(block);
blockIndexWords[0]++;
}
derivedKey.sigBytes = keySize * 4;
return derivedKey;
}
});
/**
* Computes the Password-Based Key Derivation Function 2.
*
* @param {WordArray|string} password The password.
* @param {WordArray|string} salt A salt.
* @param {Object} cfg (Optional) The configuration options to use for this computation.
*
* @return {WordArray} The derived key.
*
* @static
*
* @example
*
* var key = CryptoJS.PBKDF2(password, salt);
* var key = CryptoJS.PBKDF2(password, salt, { keySize: 8 });
* var key = CryptoJS.PBKDF2(password, salt, { keySize: 8, iterations: 1000 });
*/
C.PBKDF2 = function (password, salt, cfg) {
return PBKDF2.create(cfg).compute(password, salt);
};
}());
return CryptoJS.PBKDF2;
}));
@@ -0,0 +1,116 @@
import * as util from "../core/util.js";
const error = () => {
const Sizable = {
string: { unit: "حرف", verb: "أن يحوي" },
file: { unit: "بايت", verb: "أن يحوي" },
array: { unit: "عنصر", verb: "أن يحوي" },
set: { unit: "عنصر", verb: "أن يحوي" },
};
function getSizing(origin) {
return Sizable[origin] ?? null;
}
const parsedType = (data) => {
const t = typeof data;
switch (t) {
case "number": {
return Number.isNaN(data) ? "NaN" : "number";
}
case "object": {
if (Array.isArray(data)) {
return "array";
}
if (data === null) {
return "null";
}
if (Object.getPrototypeOf(data) !== Object.prototype && data.constructor) {
return data.constructor.name;
}
}
}
return t;
};
const Nouns = {
regex: "مدخل",
email: "بريد إلكتروني",
url: "رابط",
emoji: "إيموجي",
uuid: "UUID",
uuidv4: "UUIDv4",
uuidv6: "UUIDv6",
nanoid: "nanoid",
guid: "GUID",
cuid: "cuid",
cuid2: "cuid2",
ulid: "ULID",
xid: "XID",
ksuid: "KSUID",
datetime: "تاريخ ووقت بمعيار ISO",
date: "تاريخ بمعيار ISO",
time: "وقت بمعيار ISO",
duration: "مدة بمعيار ISO",
ipv4: "عنوان IPv4",
ipv6: "عنوان IPv6",
cidrv4: "مدى عناوين بصيغة IPv4",
cidrv6: "مدى عناوين بصيغة IPv6",
base64: "نَص بترميز base64-encoded",
base64url: "نَص بترميز base64url-encoded",
json_string: "نَص على هيئة JSON",
e164: "رقم هاتف بمعيار E.164",
jwt: "JWT",
template_literal: "مدخل",
};
return (issue) => {
switch (issue.code) {
case "invalid_type":
return `مدخلات غير مقبولة: يفترض إدخال ${issue.expected}، ولكن تم إدخال ${parsedType(issue.input)}`;
case "invalid_value":
if (issue.values.length === 1)
return `مدخلات غير مقبولة: يفترض إدخال ${util.stringifyPrimitive(issue.values[0])}`;
return `اختيار غير مقبول: يتوقع انتقاء أحد هذه الخيارات: ${util.joinValues(issue.values, "|")}`;
case "too_big": {
const adj = issue.inclusive ? "<=" : "<";
const sizing = getSizing(issue.origin);
if (sizing)
return ` أكبر من اللازم: يفترض أن تكون ${issue.origin ?? "القيمة"} ${adj} ${issue.maximum.toString()} ${sizing.unit ?? "عنصر"}`;
return `أكبر من اللازم: يفترض أن تكون ${issue.origin ?? "القيمة"} ${adj} ${issue.maximum.toString()}`;
}
case "too_small": {
const adj = issue.inclusive ? ">=" : ">";
const sizing = getSizing(issue.origin);
if (sizing) {
return `أصغر من اللازم: يفترض لـ ${issue.origin} أن يكون ${adj} ${issue.minimum.toString()} ${sizing.unit}`;
}
return `أصغر من اللازم: يفترض لـ ${issue.origin} أن يكون ${adj} ${issue.minimum.toString()}`;
}
case "invalid_format": {
const _issue = issue;
if (_issue.format === "starts_with")
return `نَص غير مقبول: يجب أن يبدأ بـ "${issue.prefix}"`;
if (_issue.format === "ends_with")
return `نَص غير مقبول: يجب أن ينتهي بـ "${_issue.suffix}"`;
if (_issue.format === "includes")
return `نَص غير مقبول: يجب أن يتضمَّن "${_issue.includes}"`;
if (_issue.format === "regex")
return `نَص غير مقبول: يجب أن يطابق النمط ${_issue.pattern}`;
return `${Nouns[_issue.format] ?? issue.format} غير مقبول`;
}
case "not_multiple_of":
return `رقم غير مقبول: يجب أن يكون من مضاعفات ${issue.divisor}`;
case "unrecognized_keys":
return `معرف${issue.keys.length > 1 ? "ات" : ""} غريب${issue.keys.length > 1 ? "ة" : ""}: ${util.joinValues(issue.keys, "، ")}`;
case "invalid_key":
return `معرف غير مقبول في ${issue.origin}`;
case "invalid_union":
return "مدخل غير مقبول";
case "invalid_element":
return `مدخل غير مقبول في ${issue.origin}`;
default:
return "مدخل غير مقبول";
}
};
};
export default function () {
return {
localeError: error(),
};
}
@@ -0,0 +1 @@
{"name":"@react-aria/listbox","version":"3.13.6","requiresBuild":false,"files":{"LICENSE":{"checkedAt":1794532108612,"integrity":"sha512-cil7stSp3ik41Hdv2Dj+GMcbvUfs1q+MZ2Yte0804py9i6oJJN/diCiIr/brcQOZ5ZqwAI6dgaHA7l8FZheQBw==","mode":420,"size":11335},"dist/main.js":{"checkedAt":1794532108612,"integrity":"sha512-QllYFBvjgWWUwaxD6sOTVQJfyDw6KFYZKK2Yg4oV6VBsSAa3IYMLJFauz74XMA11F7DP0xx3xdpR/ZdCXPSdAg==","mode":420,"size":1506},"dist/module.js":{"checkedAt":1794532108612,"integrity":"sha512-jLcPSmk+LaxPWtC3iOoeRv54sRc4aJ3U/uPcVCgFL66UiW6DsqDYwKmgrYb7d6BpgwoDCr/ZSKTT34kJE602Sw==","mode":420,"size":1402},"dist/useListBox.main.js":{"checkedAt":1794532108613,"integrity":"sha512-dJfOFBybc5HFf+JZ9N4jq2LRlk2T3BZ5EN+frh3PPCPZXyTtZ6jisnpEbpBwZshe5bSbmy/mUsBrtHjYJGhxKw==","mode":420,"size":3640},"dist/useListBox.module.js":{"checkedAt":1794532108613,"integrity":"sha512-ckQ5VV74nsLEc84FE4SYyUo23emT9hvFNUHSwoXNwa7BfbGnTCOEvx7Wtlu5Tf4Vk38/DHU0cyEmbgwK8LNY5w==","mode":420,"size":3511},"dist/useListBoxSection.main.js":{"checkedAt":1794532108613,"integrity":"sha512-K1FEFXiOXnp/CoHRkz+jpYMNYQV0ZIe++hhzXFljjMdpsIy+4ZB9mucD5l6hzKCorhiolJY9cDqlRlqugSscBQ==","mode":420,"size":1736},"dist/useListBoxSection.module.js":{"checkedAt":1794532108613,"integrity":"sha512-8/GjJwD2peOJTNtJKDjIwq1BSzj9nqNk3i7WyYnVNbGk4YJPQc7dnD8vNjA9VcsAqsCK/VTGCtljAPZJDbWuow==","mode":420,"size":1564},"dist/useOption.main.js":{"checkedAt":1794532108613,"integrity":"sha512-xHA8TLY5Ib9CQcuI+2qJthtTzh6oOB6gJwhnwZdlZaK1eC1ZU6I/YuVubVPayfDHfghHZBjHtzLvAurg5ZSa1g==","mode":420,"size":6709},"dist/useOption.module.js":{"checkedAt":1794532108613,"integrity":"sha512-qLjANY5HW9XgGGsMiY8arDGSigaMT1oQBSCMvMZFNwOs5pd9zFx/WSuS6//sI39Q3XlGyVzSuPFVozjifEs+Nw==","mode":420,"size":6677},"dist/utils.main.js":{"checkedAt":1794532108613,"integrity":"sha512-wpgZRtUEyZQd/3NWWzkiwbnezaZu+D3G/QejOJm2rQ7A4DHEv+yA5rWS4HbHWefRIqyPGT3MgyNuyFBXqZLRBw==","mode":420,"size":1448},"dist/utils.module.js":{"checkedAt":1794532108614,"integrity":"sha512-uyTIUWQXm4mQylMJeMdyiMgW0cktRD1/C4Yu2cq9zJ8bJ9E5RDxLPX3USIwBs6BsrCnnsV6+SMeqwAew9GegWg==","mode":420,"size":1254},"package.json":{"checkedAt":1794532108614,"integrity":"sha512-RjCRoZQBmAADRYnMvJkCqqgAqvC4KAsQQqf1JxX5ysr8wGK2lSsoJ3nnKmlqX1s7/LOJZZm0bspi5V+gnZKQEQ==","mode":420,"size":1172},"dist/main.js.map":{"checkedAt":1794532108614,"integrity":"sha512-eh/PR64BR/B4Y2Tp7IShG3gDeImYuHkhNBjUMJ8rxqn8wLpkKF5EflieSjL5LUNqWzMzu7aA0yB2qQAnS5OwoA==","mode":420,"size":1272},"dist/module.js.map":{"checkedAt":1794532108614,"integrity":"sha512-CZnGjzu9KpP3HU5XjknWNG0eiiOogZ82yaBvFoNl8fjufSJvGZnWKKrsytn7kkNfBdNOUHMpiof+qLnKU2Wxqg==","mode":420,"size":1264},"dist/types.d.ts.map":{"checkedAt":1794532108614,"integrity":"sha512-YBZ1BT0GgLcM5XQKto2G9hcQtoYc5I8Zp3sUdXMjt8IJgnM54UpJvAG07zELgjL8ybN7dIsiocjwG7NWWKyVWA==","mode":420,"size":3772},"dist/useListBox.main.js.map":{"checkedAt":1794532108614,"integrity":"sha512-4fEdDn6G8nnupXLhidfv9qyfQOfwcPhtWg4StSe0LxMC2y2cVgyfYukkZv0eLNLkLWWFAyYU40Yg9lqNwPa85Q==","mode":420,"size":6297},"dist/useListBox.module.js.map":{"checkedAt":1794532108615,"integrity":"sha512-TbZ6bMYPbWhjYc8wgVxpY0JoDpfX0cLK9Hs+SN3m7GqQryrWEdjkqMragF1kTWFJtbWtjS3ieZoqn5BRFc2QfQ==","mode":420,"size":6291},"dist/useListBoxSection.main.js.map":{"checkedAt":1794532108615,"integrity":"sha512-RzhW1ADpcEW0v6EjYKoi2gaPgHMop9zEgVzrH/ulLfft7iPeHjU1CAzalAxL7rhxS5P+omAkqx82QSYvVI10kQ==","mode":420,"size":2647},"dist/useListBoxSection.module.js.map":{"checkedAt":1794532108615,"integrity":"sha512-7hCiuM0HUsWh3wAuKh4DLQ9WPGD3OG65sYK6gR6coVaAlqYvM3PbCsi4zSx6yfn1Tm+67zYXkmzN+xC0zerleQ==","mode":420,"size":2642},"dist/useOption.main.js.map":{"checkedAt":1794532108615,"integrity":"sha512-Ot4PX44Pd/1gQgiUzUM35D1cbzwov65LHtlNrIe7QzW6euNEhRUvnbzbDlWghgovo79ITQFjwX4cYIHdYlpfQA==","mode":420,"size":8434},"dist/useOption.module.js.map":{"checkedAt":1794532108615,"integrity":"sha512-3ALu0MNpjB7laf2k0f7K2SOkflQhITVHxiXXtM4KMnT/ZJu44J20hsA2j8COXc//Qwr+aR2P7OeqfP/ACJWqdA==","mode":420,"size":8426},"dist/utils.main.js.map":{"checkedAt":1794532108615,"integrity":"sha512-aKtshqebh2j+hdBLUg6fI/81wQwxcZYxiWtxoKxaJiRQOss84MRnrofpz5n+WsDck7CV4SMehnRaOWS9YFdL5w==","mode":420,"size":1886},"dist/utils.module.js.map":{"checkedAt":1794532108616,"integrity":"sha512-MJNRMhrMDQRyARYNyOJntK+5Yl2TozRxfCfTLgR5gDnQg819HlQiWSW1ii9R/sKGX8b4IyOqrCvtsiLNGh6Njw==","mode":420,"size":1881},"README.md":{"checkedAt":1794532108616,"integrity":"sha512-ecnkW5pc4GyQSguqo5CtFsahzuGDBFf8HXzThawvu2rjIKyFvI1eQZwoItH7y2eD+pLgjSl6nCraMygPausxTw==","mode":420,"size":136},"dist/import.mjs":{"checkedAt":1794532108616,"integrity":"sha512-JS/NgnespwsSBTh3BRXd9J4/cjrd2WGwgwjmWU0kc/YuY023m6SCe0TOM6TdmAHzn0cm+DkIu+66VW4CmWS2fQ==","mode":420,"size":1378},"dist/useListBox.mjs":{"checkedAt":1794532108616,"integrity":"sha512-v2AT8SBuLUZIR8D7Xun4GhW/KKxDKxf+mLhGwmLz7mRFJnBqpKF0JRVhL4w4AyXdk6wLbvbHNFRzCUHug+7jlw==","mode":420,"size":3505},"dist/useListBoxSection.mjs":{"checkedAt":1794532108613,"integrity":"sha512-8/GjJwD2peOJTNtJKDLine truncated
@@ -0,0 +1,53 @@
'use strict';
var GetIntrinsic = require('get-intrinsic');
var $TypeError = require('es-errors/type');
var $asyncIterator = GetIntrinsic('%Symbol.asyncIterator%', true);
var inspect = require('object-inspect');
var hasSymbols = require('has-symbols')();
var AdvanceStringIndex = require('./AdvanceStringIndex');
var CreateAsyncFromSyncIterator = require('./CreateAsyncFromSyncIterator');
var GetIteratorFromMethod = require('./GetIteratorFromMethod');
var GetMethod = require('./GetMethod');
var getIteratorMethod = require('../helpers/getIteratorMethod');
var ES = {
AdvanceStringIndex: AdvanceStringIndex,
GetMethod: GetMethod
};
// https://262.ecma-international.org/14.0/#sec-getiterator
module.exports = function GetIterator(obj, kind) {
if (kind !== 'sync' && kind !== 'async') {
throw new $TypeError("Assertion failed: `kind` must be one of 'sync' or 'async', got " + inspect(kind));
}
var method;
if (kind === 'async') { // step 1
if (hasSymbols && $asyncIterator) {
method = GetMethod(obj, $asyncIterator); // step 1.a
}
}
if (typeof method === 'undefined') { // step 1.b
// var syncMethod = GetMethod(obj, $iterator); // step 1.b.i
var syncMethod = getIteratorMethod(ES, obj);
if (kind === 'async') {
if (typeof syncMethod === 'undefined') {
throw new $TypeError('iterator method is `undefined`'); // step 1.b.ii
}
var syncIteratorRecord = GetIteratorFromMethod(obj, syncMethod); // step 1.b.iii
return CreateAsyncFromSyncIterator(syncIteratorRecord); // step 1.b.iv
}
method = syncMethod; // step 2, kind of
}
if (typeof method === 'undefined') {
throw new $TypeError('iterator method is `undefined`'); // step 3
}
return GetIteratorFromMethod(obj, method); // step 4
};
@@ -0,0 +1,526 @@
export default `flf2a$ 5 4 15 0 14
Thick by Randall Ransom 2/94
Figlet release 2.0 -- August 5, 1993
Date: 5 Mar 1994
Explanation of first line:
flf2 - "magic number" for file identification
a - should always be \`a', for now
$ - the "hardblank" -- prints as a blank, but can't be smushed
5 - height of a character
4 - height of a character, not including descenders
15 - max line length (excluding comment lines) + a fudge factor
0 - default smushmode for this font (like "-m 0" on command line)
14 - number of comment lines
$$$@
$$$@
$$$@
$$$@
$$$@@
8$@
8$@
"$@
w$@
$$@@
w w$@
" "$@
$ $$@
$ $$@
$ $$@@
8 8 $@
w8ww8w$@
w8ww8w$@
8 8 $@
$@@
.w8w.$@
"w8 "$@
8w $@
"w8w"$@
" $@@
o dP$@
dP $@
dP $@
dP o$@
$@@
dP8P$@
Ybww$@
dP $@
Yb8b$@
" $@@
w$@
."$@
$$$@
$$$@
$$$@@
.dP$@
8P $@
8 $@
8b $@
'Yb$@@
Yb.$@
Y8$@
8$@
d8$@
dP'$@@
Yb dP$@
wYbdPw$@
dPYb $@
dP Yb$@
$@@
$@
8 $@
ww8ww$@
8 $@
$@@
$$$@
$$$@
$$$@
$w$@
."$@@
$ $$@
$ $$@
wwww$@
$ $$@
$ $$@@
$$@
$$@
$$@
w$@
$$@@
dP$@
dP $@
dP $@
dP $@
$@@
.d88b.$@
8P Y8$@
8b d8$@
\`Y88P'$@
$@@
d8$@
8$@
8$@
8$@
$@@
d88b$@
" dP$@
dP $@
d888$@
$@@
d88b$@
wwP$@
8$@
Y88P$@
$@@
d8$@
dP8$@
dPw8$@
8$@
$@@
8888$@
8ww.$@
\`8$@
Y88P$@
$@@
d88b $@
8Pwww.$@
8b d8$@
\`Y88P'$@
$@@
8888P$@
dP $@
dP $@
dP $@
$@@
.dPYb.$@
YbwwdP$@
dP""Yb$@
\`YbdP'$@
$@@
.d88b$@
8 8$@
\`8w88$@
8$@
$@@
$$@
w$@
$$@
w$@
$$@@
$$@
w$@
$$@
w$@
."$@@
dP$@
dP $@
db $@
Yb $@
Yb$@@
$ $$@
wwww$@
wwww$@
$ $$@
$ $$@@
Yb $@
Yb $@
db$@
dP $@
dP $@@
dP"Yb$@
" d8$@
dP $@
w $@
$@@
d""""b$@
P PY 8$@
b bdwP$@
Ybwww'$@
$@@
db $@
dPYb $@
dPwwYb $@
dP Yb$@
$@@
888b.$@
8wwwP$@
8 b$@
888P'$@
$@@
.d88b$@
8P $@
8b $@
\`Y88P$@
$@@
888b.$@
8 8$@
8 8$@
888P'$@
$@@
8888$@
8www$@
8 $@
8888$@
$@@
8888$@
8www$@
8 $@
8 $@
$@@
.d88b $@
8P www$@
8b d8$@
\`Y88P'$@
$@@
8 8$@
8www8$@
8 8$@
8 8$@
$@@
888$@
8 $@
8 $@
888$@
$@@
8888$@
8 $@
w 8 $@
\`Yw" $@
$@@
8 dP$@
8wdP $@
88Yb $@
8 Yb$@
$@@
8 $@
8 $@
8 $@
8888$@
$@@
8b d8$@
8YbmdP8$@
8 " 8$@
8 8$@
$@@
8b 8$@
8Ybm8$@
8 "8$@
8 8$@
$@@
.d88b.$@
8P Y8$@
8b d8$@
\`Y88P'$@
$@@
888b.$@
8 .8$@
8wwP'$@
8 $@
$@@
.d88b.$@
8P Y8$@
8b wd8$@
\`Y88Pw$@
$@@
888b.$@
8 .8$@
8wwK'$@
8 Yb$@
$@@
.d88b.$@
YPwww.$@
d8$@
\`Y88P'$@
$@@
88888$@
8 $@
8 $@
8 $@
$@@
8 8$@
8 8$@
8b..d8$@
\`Y88P'$@
$@@
Yb dP$@
Yb dP $@
YbdP $@
YP $@
$@@
Yb dP$@
Yb db dP $@
YbdPYbdP $@
YP YP $@
$@@
Yb dP$@
YbdP $@
dPYb $@
dP Yb$@
$@@
Yb dP$@
YbdP $@
YP $@
88 $@
$@@
8888P$@
dP $@
dP $@
d8888$@
$@@
88$@
8 $@
8 $@
8 $@
88$@@
Yb $@
Yb $@
Yb $@
Yb$@
$@@
88$@
8$@
8$@
8$@
88$@@
dPYb $@
dP Yb$@
$ $$@
$ $$@
$ $$@@
$ $$@
$ $$@
$ $$@
wwww$@
$ $$@@
w $@
".$@
$$$@
$$$@
$$$@@
$@
.d88$@
8 8$@
\`Y88$@
$@@
8 $@
88b.$@
8 8$@
88P'$@
$@@
$@
.d8b$@
8 $@
\`Y8P$@
$@@
8$@
.d88$@
8 8$@
\`Y88$@
$@@
$@
.d88b$@
8.dP'$@
\`Y88P$@
$@@
d8b$@
8' $@
w8ww$@
8 $@
$@@
$@
.d88$@
8 8$@
\`Y88$@
wwdP$@@
8 $@
8d8b.$@
8P Y8$@
8 8$@
$@@
w$@
w$@
8$@
8$@
$@@
w$@
w$@
8$@
8$@
wdP$@@
8 $@
8.dP$@
88b $@
8 Yb$@
$@@
8$@
8$@
8$@
8$@
$@@
$@
8d8b.d8b.$@
8P Y8P Y8$@
8 8 8$@
$@@
$@
8d8b.$@
8P Y8$@
8 8$@
$@@
$@
.d8b.$@
8' .8$@
\`Y8P'$@
$@@
$@
88b.$@
8 8$@
88P'$@
8 $@@
$@
.d88 $@
8 8 $@
\`Y88 $@
8P$@@
$@
8d8b$@
8P $@
8 $@
$@@
$@
d88b$@
\`Yb.$@
Y88P$@
$@@
w $@
w8ww$@
8 $@
Y8P$@
$@@
$@
8 8$@
8b d8$@
\`Y8P8$@
$@@
$@
Yb dP$@
YbdP $@
YP $@
$@@
$@
Yb db dP$@
YbdPYbdP $@
YP YP $@
$@@
$@
Yb dP$@
\`8. $@
dP Yb$@
$@@
$@
Yb dP$@
YbdP $@
dP $@
dP $@@
$@
888P$@
dP $@
d888$@
$@@
.dP$@
8P $@
w' $@
8b $@
'Yb$@@
8$@
8$@
8$@
8$@
8$@@
Yb. $@
Y8 $@
\`w$@
d8 $@
dP' $@@
dPYb dP$@
dP YbdP $@
$@
$@
$@@
$@
$@
$@
$@
$@@
$@
$@
$@
$@
$@@
$@
$@
$@
$@
$@@
$@
$@
$@
$@
$@@
$@
$@
$@
$@
$@@
$@
$@
$@
$@
$@@
$@
$@
$@
$@
$@@
`
@@ -0,0 +1,19 @@
import actualApply from './actualApply';
type TupleSplitHead<T extends any[], N extends number> = T['length'] extends N
? T
: T extends [...infer R, any]
? TupleSplitHead<R, N>
: never
type TupleSplitTail<T, N extends number, O extends any[] = []> = O['length'] extends N
? T
: T extends [infer F, ...infer R]
? TupleSplitTail<[...R], N, [...O, F]>
: never
type TupleSplit<T extends any[], N extends number> = [TupleSplitHead<T, N>, TupleSplitTail<T, N>]
declare function applyBind(...args: TupleSplit<Parameters<typeof actualApply>, 2>[1]): ReturnType<typeof actualApply>;
export = applyBind;
@@ -0,0 +1 @@
{"name":"@internationalized/number","version":"3.6.5","requiresBuild":false,"files":{"LICENSE":{"checkedAt":1794532106122,"integrity":"sha512-cil7stSp3ik41Hdv2Dj+GMcbvUfs1q+MZ2Yte0804py9i6oJJN/diCiIr/brcQOZ5ZqwAI6dgaHA7l8FZheQBw==","mode":420,"size":11335},"dist/main.js":{"checkedAt":1794532106122,"integrity":"sha512-p0AogKsiSIW4ZRHd5l3d0reYk0TBt8Q0aW9a+rGueo64WTAtD2T6NF+UEcqU9I1whybk/tK8bCbPUAmXDClXEg==","mode":420,"size":1118},"dist/module.js":{"checkedAt":1794532106122,"integrity":"sha512-0dCC7z4/7u31P1oTNt/Ltb9WohubPwUsHSk0bAFFPBV7iQOo5Ugn1ywtGbp0waT2PJ7igo1VV3NxxVsdycG44g==","mode":420,"size":996},"dist/NumberFormatter.main.js":{"checkedAt":1794532106122,"integrity":"sha512-gDMbumjQZso5Jy6CQPy9EFNPV1PqsZ5Iw4f+DuHeyH6OatjSId12PDOYxvRAP5aRJUbpIzwd1wAMgUB82NOfpg==","mode":420,"size":7684},"dist/NumberFormatter.module.js":{"checkedAt":1794532106122,"integrity":"sha512-/4KZY/neZi4h5wh5P5xGHqGcx+LOww6Mm0chhqYx/hoiGWEuW8qb4zUVgFEObE9bcq+MBNP2V5kRdxc9uLWovQ==","mode":420,"size":7606},"dist/NumberParser.main.js":{"checkedAt":1794532106122,"integrity":"sha512-Op/OMSc+W5i0/M9c2Ee0BCk9SBkpuW1Is/1kuFDotkd+aV9VkgpIUX4TSu7OgKCrgBqStQgHHkTFGhUSA6No2Q==","mode":420,"size":17150},"dist/NumberParser.module.js":{"checkedAt":1794532106122,"integrity":"sha512-rOhRt5ymJu+ldOZLuiA/Z6yh5teQPVk+hcLars0g1Klj/OpgN/cdJzTb/tCvn1a4viZDt5hSsnEa7uRf7w+prg==","mode":420,"size":17030},"package.json":{"checkedAt":1794532106123,"integrity":"sha512-oh73x87g/cMudYVufy1CQUe/wJ6nTt7/XM5YHM1HBpdLaAC0YULYmOHHjAxB9TOa+XJLH4uLhRWAecirjfhmnQ==","mode":420,"size":793},"dist/main.js.map":{"checkedAt":1794532106123,"integrity":"sha512-eu+Wi2MEVIo0M8nV/yrntKDgtTdTpyVHwhSyx9GIHGy/trWKznqRm228Jg52mysalIaAn+vsHm9GubJu5kcYaw==","mode":420,"size":969},"dist/module.js.map":{"checkedAt":1794532106123,"integrity":"sha512-VpGSC4nUeHpJZMyaYuzwMSqN3Gg4/hxo60Gf9+rqJOmaQzb7QDIvksqiGGzBdWIZXJI8qry+Dqh/nnLJaN18GA==","mode":420,"size":964},"dist/NumberFormatter.main.js.map":{"checkedAt":1794532106123,"integrity":"sha512-V4pKizA3GBivo6lm/0Xt+EkuFNcHtJ/NHo3zXbeDoxP3JuihamzlmZ/0gKtivCSIWAzndad6MRF0A1uxX77OmQ==","mode":420,"size":11466},"dist/NumberFormatter.module.js.map":{"checkedAt":1794532106123,"integrity":"sha512-KECEUEjXOFApRwV/UB5dAFprU6VkoG3uhpZMxJS/JYd8HBp8ms4q8tRto/oOXHORyBlUinQmqXo7uj0Zy/u6HQ==","mode":420,"size":11462},"dist/NumberParser.main.js.map":{"checkedAt":1794532106123,"integrity":"sha512-Y/WJDz5Hs9ypedSHAHEItQ7fIVksLXZg4eK+AqV2Uz5FUk5vCiaXrgP+OcFN6NWFJVPJbd64l1tpdmlVy8y2Hg==","mode":420,"size":23724},"dist/NumberParser.module.js.map":{"checkedAt":1794532106123,"integrity":"sha512-CHr5TEC+2M3fSCwBJKjm3otR8H4mZEWaTDiHyv09cHlOGMvmI72AIeK88mtcGlWP8E5k5Z6OeFFlwlzrkQLOeA==","mode":420,"size":23720},"dist/types.d.ts.map":{"checkedAt":1794532106124,"integrity":"sha512-BH+lDRe3lefSnCmPXNMJU4Lo98CxbzSiTMVGq6gCa+r/jebYg7jxA5N+lSatFlz20rjktTse7eclhO3AWX9NVw==","mode":420,"size":2109},"README.md":{"checkedAt":1794532106124,"integrity":"sha512-Xp0sbJyI2kPUHMxMEGN0SdFRcHw+gt37B97FnIAzW1QMF7aTBO7LttE+B0eQruQvxlteQaHpg17TxAse+JlrKA==","mode":420,"size":1759},"dist/import.mjs":{"checkedAt":1794532106124,"integrity":"sha512-AhyBvpd6jcQf7+PVhp4shUHtYD/fhk9L5LsZUKMLhl5RNKM9TVXf3nhQgLX1QvXoBHrG6GpnMVOcudt1X+VBvA==","mode":420,"size":984},"dist/NumberFormatter.mjs":{"checkedAt":1794532106122,"integrity":"sha512-/4KZY/neZi4h5wh5P5xGHqGcx+LOww6Mm0chhqYx/hoiGWEuW8qb4zUVgFEObE9bcq+MBNP2V5kRdxc9uLWovQ==","mode":420,"size":7606},"dist/NumberParser.mjs":{"checkedAt":1794532106124,"integrity":"sha512-J1dIJXKMHRq6bixqT0/Xtp3a84XPe5KDngi7rtsc9FoZ3zu0QqbEWIoCcEndEqIGOXcY9I8bei57UucDcOZNwQ==","mode":420,"size":17024},"src/index.ts":{"checkedAt":1794532106124,"integrity":"sha512-v55tE+ArQutlDPJUItHQnpKn7I9mVvKPkaPeQUunAHzRndNLF7OoUl+gxxAggk+uA1ps2UhJ5ko+3Z8yKohcUA==","mode":420,"size":778},"src/NumberFormatter.ts":{"checkedAt":1794532106124,"integrity":"sha512-Iznq/BFasU8rWXQ8Z+FjAzaLIIKcjcEPc+JUGm8WpT+ctahQCktF4Q2afFRIo5mfE2WU2QHO6/NCgNunv2q11g==","mode":420,"size":7332},"src/NumberParser.ts":{"checkedAt":1794532106124,"integrity":"sha512-dsEHSOnuLhUd+yCXzVJK/UlVYKB5Ms3npAK5Q1kSRrt0spQSaV3HEF/QYPbSIRx49s5b8p3x9Vy4FFs4p/Z2gQ==","mode":420,"size":15213},"dist/types.d.ts":{"checkedAt":1794532106125,"integrity":"sha512-jJQ3TRoPN45YFBhOddAzvB4rk6xl7/VQuWWf/em8+fihfjq4UF1v0bra8H1tSAbOM8q0E9wm2tWUqrSj/Kg7GQ==","mode":420,"size":2465}}}
@@ -0,0 +1,29 @@
"use strict";
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
var desc = Object.getOwnPropertyDescriptor(m, k);
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
desc = { enumerable: true, get: function() { return m[k]; } };
}
Object.defineProperty(o, k2, desc);
}) : (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
o[k2] = m[k];
}));
var __exportStar = (this && this.__exportStar) || function(m, exports) {
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
};
Object.defineProperty(exports, "__esModule", { value: true });
__exportStar(require("./CatchClauseDefinition"), exports);
__exportStar(require("./ClassNameDefinition"), exports);
__exportStar(require("./Definition"), exports);
__exportStar(require("./DefinitionType"), exports);
__exportStar(require("./FunctionNameDefinition"), exports);
__exportStar(require("./ImplicitGlobalVariableDefinition"), exports);
__exportStar(require("./ImportBindingDefinition"), exports);
__exportStar(require("./ParameterDefinition"), exports);
__exportStar(require("./TSEnumMemberDefinition"), exports);
__exportStar(require("./TSEnumNameDefinition"), exports);
__exportStar(require("./TSModuleNameDefinition"), exports);
__exportStar(require("./TypeDefinition"), exports);
__exportStar(require("./VariableDefinition"), exports);
@@ -0,0 +1,538 @@
/*!
* depd
* Copyright(c) 2014-2018 Douglas Christopher Wilson
* MIT Licensed
*/
/**
* Module dependencies.
*/
var relative = require('path').relative
/**
* Module exports.
*/
module.exports = depd
/**
* Get the path to base files on.
*/
var basePath = process.cwd()
/**
* Determine if namespace is contained in the string.
*/
function containsNamespace (str, namespace) {
var vals = str.split(/[ ,]+/)
var ns = String(namespace).toLowerCase()
for (var i = 0; i < vals.length; i++) {
var val = vals[i]
// namespace contained
if (val && (val === '*' || val.toLowerCase() === ns)) {
return true
}
}
return false
}
/**
* Convert a data descriptor to accessor descriptor.
*/
function convertDataDescriptorToAccessor (obj, prop, message) {
var descriptor = Object.getOwnPropertyDescriptor(obj, prop)
var value = descriptor.value
descriptor.get = function getter () { return value }
if (descriptor.writable) {
descriptor.set = function setter (val) { return (value = val) }
}
delete descriptor.value
delete descriptor.writable
Object.defineProperty(obj, prop, descriptor)
return descriptor
}
/**
* Create arguments string to keep arity.
*/
function createArgumentsString (arity) {
var str = ''
for (var i = 0; i < arity; i++) {
str += ', arg' + i
}
return str.substr(2)
}
/**
* Create stack string from stack.
*/
function createStackString (stack) {
var str = this.name + ': ' + this.namespace
if (this.message) {
str += ' deprecated ' + this.message
}
for (var i = 0; i < stack.length; i++) {
str += '\n at ' + stack[i].toString()
}
return str
}
/**
* Create deprecate for namespace in caller.
*/
function depd (namespace) {
if (!namespace) {
throw new TypeError('argument namespace is required')
}
var stack = getStack()
var site = callSiteLocation(stack[1])
var file = site[0]
function deprecate (message) {
// call to self as log
log.call(deprecate, message)
}
deprecate._file = file
deprecate._ignored = isignored(namespace)
deprecate._namespace = namespace
deprecate._traced = istraced(namespace)
deprecate._warned = Object.create(null)
deprecate.function = wrapfunction
deprecate.property = wrapproperty
return deprecate
}
/**
* Determine if event emitter has listeners of a given type.
*
* The way to do this check is done three different ways in Node.js >= 0.8
* so this consolidates them into a minimal set using instance methods.
*
* @param {EventEmitter} emitter
* @param {string} type
* @returns {boolean}
* @private
*/
function eehaslisteners (emitter, type) {
var count = typeof emitter.listenerCount !== 'function'
? emitter.listeners(type).length
: emitter.listenerCount(type)
return count > 0
}
/**
* Determine if namespace is ignored.
*/
function isignored (namespace) {
if (process.noDeprecation) {
// --no-deprecation support
return true
}
var str = process.env.NO_DEPRECATION || ''
// namespace ignored
return containsNamespace(str, namespace)
}
/**
* Determine if namespace is traced.
*/
function istraced (namespace) {
if (process.traceDeprecation) {
// --trace-deprecation support
return true
}
var str = process.env.TRACE_DEPRECATION || ''
// namespace traced
return containsNamespace(str, namespace)
}
/**
* Display deprecation message.
*/
function log (message, site) {
var haslisteners = eehaslisteners(process, 'deprecation')
// abort early if no destination
if (!haslisteners && this._ignored) {
return
}
var caller
var callFile
var callSite
var depSite
var i = 0
var seen = false
var stack = getStack()
var file = this._file
if (site) {
// provided site
depSite = site
callSite = callSiteLocation(stack[1])
callSite.name = depSite.name
file = callSite[0]
} else {
// get call site
i = 2
depSite = callSiteLocation(stack[i])
callSite = depSite
}
// get caller of deprecated thing in relation to file
for (; i < stack.length; i++) {
caller = callSiteLocation(stack[i])
callFile = caller[0]
if (callFile === file) {
seen = true
} else if (callFile === this._file) {
file = this._file
} else if (seen) {
break
}
}
var key = caller
? depSite.join(':') + '__' + caller.join(':')
: undefined
if (key !== undefined && key in this._warned) {
// already warned
return
}
this._warned[key] = true
// generate automatic message from call site
var msg = message
if (!msg) {
msg = callSite === depSite || !callSite.name
? defaultMessage(depSite)
: defaultMessage(callSite)
}
// emit deprecation if listeners exist
if (haslisteners) {
var err = DeprecationError(this._namespace, msg, stack.slice(i))
process.emit('deprecation', err)
return
}
// format and write message
var format = process.stderr.isTTY
? formatColor
: formatPlain
var output = format.call(this, msg, caller, stack.slice(i))
process.stderr.write(output + '\n', 'utf8')
}
/**
* Get call site location as array.
*/
function callSiteLocation (callSite) {
var file = callSite.getFileName() || '<anonymous>'
var line = callSite.getLineNumber()
var colm = callSite.getColumnNumber()
if (callSite.isEval()) {
file = callSite.getEvalOrigin() + ', ' + file
}
var site = [file, line, colm]
site.callSite = callSite
site.name = callSite.getFunctionName()
return site
}
/**
* Generate a default message from the site.
*/
function defaultMessage (site) {
var callSite = site.callSite
var funcName = site.name
// make useful anonymous name
if (!funcName) {
funcName = '<anonymous@' + formatLocation(site) + '>'
}
var context = callSite.getThis()
var typeName = context && callSite.getTypeName()
// ignore useless type name
if (typeName === 'Object') {
typeName = undefined
}
// make useful type name
if (typeName === 'Function') {
typeName = context.name || typeName
}
return typeName && callSite.getMethodName()
? typeName + '.' + funcName
: funcName
}
/**
* Format deprecation message without color.
*/
function formatPlain (msg, caller, stack) {
var timestamp = new Date().toUTCString()
var formatted = timestamp +
' ' + this._namespace +
' deprecated ' + msg
// add stack trace
if (this._traced) {
for (var i = 0; i < stack.length; i++) {
formatted += '\n at ' + stack[i].toString()
}
return formatted
}
if (caller) {
formatted += ' at ' + formatLocation(caller)
}
return formatted
}
/**
* Format deprecation message with color.
*/
function formatColor (msg, caller, stack) {
var formatted = '\x1b[36;1m' + this._namespace + '\x1b[22;39m' + // bold cyan
' \x1b[33;1mdeprecated\x1b[22;39m' + // bold yellow
' \x1b[0m' + msg + '\x1b[39m' // reset
// add stack trace
if (this._traced) {
for (var i = 0; i < stack.length; i++) {
formatted += '\n \x1b[36mat ' + stack[i].toString() + '\x1b[39m' // cyan
}
return formatted
}
if (caller) {
formatted += ' \x1b[36m' + formatLocation(caller) + '\x1b[39m' // cyan
}
return formatted
}
/**
* Format call site location.
*/
function formatLocation (callSite) {
return relative(basePath, callSite[0]) +
':' + callSite[1] +
':' + callSite[2]
}
/**
* Get the stack as array of call sites.
*/
function getStack () {
var limit = Error.stackTraceLimit
var obj = {}
var prep = Error.prepareStackTrace
Error.prepareStackTrace = prepareObjectStackTrace
Error.stackTraceLimit = Math.max(10, limit)
// capture the stack
Error.captureStackTrace(obj)
// slice this function off the top
var stack = obj.stack.slice(1)
Error.prepareStackTrace = prep
Error.stackTraceLimit = limit
return stack
}
/**
* Capture call site stack from v8.
*/
function prepareObjectStackTrace (obj, stack) {
return stack
}
/**
* Return a wrapped function in a deprecation message.
*/
function wrapfunction (fn, message) {
if (typeof fn !== 'function') {
throw new TypeError('argument fn must be a function')
}
var args = createArgumentsString(fn.length)
var stack = getStack()
var site = callSiteLocation(stack[1])
site.name = fn.name
// eslint-disable-next-line no-new-func
var deprecatedfn = new Function('fn', 'log', 'deprecate', 'message', 'site',
'"use strict"\n' +
'return function (' + args + ') {' +
'log.call(deprecate, message, site)\n' +
'return fn.apply(this, arguments)\n' +
'}')(fn, log, this, message, site)
return deprecatedfn
}
/**
* Wrap property in a deprecation message.
*/
function wrapproperty (obj, prop, message) {
if (!obj || (typeof obj !== 'object' && typeof obj !== 'function')) {
throw new TypeError('argument obj must be object')
}
var descriptor = Object.getOwnPropertyDescriptor(obj, prop)
if (!descriptor) {
throw new TypeError('must call property on owner object')
}
if (!descriptor.configurable) {
throw new TypeError('property must be configurable')
}
var deprecate = this
var stack = getStack()
var site = callSiteLocation(stack[1])
// set site name
site.name = prop
// convert data descriptor
if ('value' in descriptor) {
descriptor = convertDataDescriptorToAccessor(obj, prop, message)
}
var get = descriptor.get
var set = descriptor.set
// wrap getter
if (typeof get === 'function') {
descriptor.get = function getter () {
log.call(deprecate, message, site)
return get.apply(this, arguments)
}
}
// wrap setter
if (typeof set === 'function') {
descriptor.set = function setter () {
log.call(deprecate, message, site)
return set.apply(this, arguments)
}
}
Object.defineProperty(obj, prop, descriptor)
}
/**
* Create DeprecationError for deprecation
*/
function DeprecationError (namespace, message, stack) {
var error = new Error()
var stackString
Object.defineProperty(error, 'constructor', {
value: DeprecationError
})
Object.defineProperty(error, 'message', {
configurable: true,
enumerable: false,
value: message,
writable: true
})
Object.defineProperty(error, 'name', {
enumerable: false,
configurable: true,
value: 'DeprecationError',
writable: true
})
Object.defineProperty(error, 'namespace', {
configurable: true,
enumerable: false,
value: namespace,
writable: true
})
Object.defineProperty(error, 'stack', {
configurable: true,
enumerable: false,
get: function () {
if (stackString !== undefined) {
return stackString
}
// prepare stack trace
return (stackString = createStackString.call(this, stack))
},
set: function setter (val) {
stackString = val
}
})
return error
}
@@ -0,0 +1,136 @@
# statuses
[![NPM Version][npm-version-image]][npm-url]
[![NPM Downloads][npm-downloads-image]][npm-url]
[![Node.js Version][node-version-image]][node-version-url]
[![Build Status][ci-image]][ci-url]
[![Test Coverage][coveralls-image]][coveralls-url]
HTTP status utility for node.
This module provides a list of status codes and messages sourced from
a few different projects:
* The [IANA Status Code Registry](https://www.iana.org/assignments/http-status-codes/http-status-codes.xhtml)
* The [Node.js project](https://nodejs.org/)
* The [NGINX project](https://www.nginx.com/)
* The [Apache HTTP Server project](https://httpd.apache.org/)
## Installation
This is a [Node.js](https://nodejs.org/en/) module available through the
[npm registry](https://www.npmjs.com/). Installation is done using the
[`npm install` command](https://docs.npmjs.com/getting-started/installing-npm-packages-locally):
```sh
$ npm install statuses
```
## API
<!-- eslint-disable no-unused-vars -->
```js
var status = require('statuses')
```
### status(code)
Returns the status message string for a known HTTP status code. The code
may be a number or a string. An error is thrown for an unknown status code.
<!-- eslint-disable no-undef -->
```js
status(403) // => 'Forbidden'
status('403') // => 'Forbidden'
status(306) // throws
```
### status(msg)
Returns the numeric status code for a known HTTP status message. The message
is case-insensitive. An error is thrown for an unknown status message.
<!-- eslint-disable no-undef -->
```js
status('forbidden') // => 403
status('Forbidden') // => 403
status('foo') // throws
```
### status.codes
Returns an array of all the status codes as `Integer`s.
### status.code[msg]
Returns the numeric status code for a known status message (in lower-case),
otherwise `undefined`.
<!-- eslint-disable no-undef, no-unused-expressions -->
```js
status['not found'] // => 404
```
### status.empty[code]
Returns `true` if a status code expects an empty body.
<!-- eslint-disable no-undef, no-unused-expressions -->
```js
status.empty[200] // => undefined
status.empty[204] // => true
status.empty[304] // => true
```
### status.message[code]
Returns the string message for a known numeric status code, otherwise
`undefined`. This object is the same format as the
[Node.js http module `http.STATUS_CODES`](https://nodejs.org/dist/latest/docs/api/http.html#http_http_status_codes).
<!-- eslint-disable no-undef, no-unused-expressions -->
```js
status.message[404] // => 'Not Found'
```
### status.redirect[code]
Returns `true` if a status code is a valid redirect status.
<!-- eslint-disable no-undef, no-unused-expressions -->
```js
status.redirect[200] // => undefined
status.redirect[301] // => true
```
### status.retry[code]
Returns `true` if you should retry the rest.
<!-- eslint-disable no-undef, no-unused-expressions -->
```js
status.retry[501] // => undefined
status.retry[503] // => true
```
## License
[MIT](LICENSE)
[ci-image]: https://badgen.net/github/checks/jshttp/statuses/master?label=ci
[ci-url]: https://github.com/jshttp/statuses/actions?query=workflow%3Aci
[coveralls-image]: https://badgen.net/coveralls/c/github/jshttp/statuses/master
[coveralls-url]: https://coveralls.io/r/jshttp/statuses?branch=master
[node-version-image]: https://badgen.net/npm/node/statuses
[node-version-url]: https://nodejs.org/en/download
[npm-downloads-image]: https://badgen.net/npm/dm/statuses
[npm-url]: https://npmjs.org/package/statuses
[npm-version-image]: https://badgen.net/npm/v/statuses
@@ -0,0 +1 @@
{"name":"which-builtin-type","version":"1.2.1","requiresBuild":false,"files":{".eslintrc":{"checkedAt":1794532097418,"integrity":"sha512-uwQPMWxPf8bFExglmBaJdHtT3+y5y3XKj/8kpJkbDhavvqvldlzmB25hckQ3KTFCQJE4ql2we2KXI7Lq46ApJQ==","mode":420,"size":209},".nycrc":{"checkedAt":1794532097418,"integrity":"sha512-2vm1RFz8Ajl/OYrfoCWPJIm3Bpnf7Gyn5bha/lZx/cq+We3uMy9xj15XeP6x4wF3jf/pO7KMHAkU9mllm605xg==","mode":420,"size":139},"LICENSE":{"checkedAt":1794532097418,"integrity":"sha512-ihuvWi5rePYJEeQzvoPQfE7iMb0ArCZnKAyrSLzDRyky1+A/wy1fqKm63xcmcygD4wSaHss419bYOU/UX+PFag==","mode":420,"size":1073},"index.js":{"checkedAt":1794532097418,"integrity":"sha512-eOCcsgcpvrsbly6+5HqXaA75NWYUsi193tI3Z5WsuB0iI2dumTTdcd4Iy2OnY+ue5JNAMLNg2XgOo4yO/0chbg==","mode":420,"size":3952},"test/index.js":{"checkedAt":1794532097418,"integrity":"sha512-BLNS18vcHozVd6tFZZORgu+T6WePNdhK3hhJAD8ynIY4C8+u/Q9fwKAWXNQrdpUwSnsVKgMcQA9+WUW/EKQEpQ==","mode":420,"size":4978},"package.json":{"checkedAt":1794532097418,"integrity":"sha512-kBACo6t5n9/HYJ4LnnmME7cPybrDWy1yQk9yBVLle+oQku2Jz2K4IoMyAbi+0+c0zaa19QTIp6BpuVxoCgsJoQ==","mode":420,"size":3223},"tsconfig.json":{"checkedAt":1794532097418,"integrity":"sha512-xBbrFV4Zb7DECDeefgt+yhGfHLeRKbwlh2H6L08d8tjUDpSQt9WyNmB4pcNL/slJJ50FIksbN+w5cFzfKhZ+bw==","mode":420,"size":123},"CHANGELOG.md":{"checkedAt":1794532097419,"integrity":"sha512-gdx2wEMIZwmjIGbGQwcKk9w5afHditZTRIYUnrE1JlHtwQV+RhvzI+YTSwFWj+ofDJf415gGlA/wzShkOXn8Jw==","mode":420,"size":11524},"README.md":{"checkedAt":1794532097419,"integrity":"sha512-cwhTcIlJQk0OgL3/sl+UZGqiceg1gcAZVpH29y07fbVVQokCcO1AEJ2dzsw0fl5ZJv+hbkY6w2XMF1oLb43Ckw==","mode":420,"size":3507},"index.d.ts":{"checkedAt":1794532097419,"integrity":"sha512-8vYK5+XUBHvSQdjEHnjloBQJa5S28YgHmT8D/akyw0bD0rREqU9IQZSm9gW+YJLPVOFq5L9vj9KC0Jg6uZaDVQ==","mode":420,"size":1313}}}
@@ -0,0 +1 @@
module.exports={C:{"89":0.00369,"98":0.00369,"115":0.01474,"123":0.00369,"128":0.00369,"133":0.00737,"135":0.00369,"136":0.00369,"137":0.00369,"138":0.00369,"139":0.00369,"140":0.02949,"141":0.01106,"142":0.01474,"143":0.44969,"144":0.27276,_:"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 90 91 92 93 94 95 96 97 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 116 117 118 119 120 121 122 124 125 126 127 129 130 131 132 134 145 146 147 3.5 3.6"},D:{"11":0.00737,"40":0.00369,"43":0.00369,"50":0.00369,"55":0.00369,"62":0.00369,"63":0.00369,"66":0.01843,"67":0.02212,"69":0.00369,"70":0.01106,"71":0.00369,"78":0.00369,"80":0.01106,"81":0.00737,"83":0.01474,"84":0.00369,"86":0.00369,"87":0.05529,"88":0.01106,"91":0.01106,"92":0.00369,"95":0.00737,"96":0.00369,"99":0.02949,"102":0.00369,"103":0.01106,"104":0.01474,"105":0.00737,"106":0.01106,"108":0.00737,"109":0.22485,"110":0.01106,"111":0.01843,"113":0.00369,"114":0.04423,"116":0.00737,"117":0.00737,"118":0.00369,"119":0.03686,"120":0.11427,"121":0.00369,"122":0.01474,"123":0.02212,"124":0.01106,"125":0.29488,"126":0.07003,"127":0.02949,"128":0.00737,"129":0.01106,"130":0.0258,"131":0.04792,"132":0.00737,"133":0.01843,"134":0.04055,"135":0.02212,"136":0.08109,"137":0.21379,"138":0.17693,"139":0.26908,"140":2.51017,"141":5.93077,"142":0.09584,_:"4 5 6 7 8 9 10 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 41 42 44 45 46 47 48 49 51 52 53 54 56 57 58 59 60 61 64 65 68 72 73 74 75 76 77 79 85 89 90 93 94 97 98 100 101 107 112 115 143 144 145"},F:{"51":0.00369,"79":0.01106,"83":0.00369,"90":0.0516,"91":0.06266,"92":0.04055,"95":0.00369,"107":0.00737,"110":0.00369,"120":0.04055,"122":0.35386,_:"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 46 47 48 49 50 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 84 85 86 87 88 89 93 94 96 97 98 99 100 101 102 103 104 105 106 108 109 111 112 113 114 115 116 117 118 119 121 9.5-9.6 10.0-10.1 10.5 10.6 11.1 11.5 11.6 12.1"},B:{"13":0.00369,"16":0.01106,"17":0.00369,"18":0.04792,"84":0.01106,"88":0.00369,"89":0.02949,"90":0.01106,"92":0.03686,"100":0.04792,"102":0.00369,"109":0.00369,"110":0.00369,"112":0.00369,"113":0.00369,"114":0.00737,"122":0.0258,"123":0.00369,"124":0.00737,"125":0.01106,"126":0.00737,"127":0.01474,"128":0.00369,"129":0.00369,"130":0.00369,"131":0.01843,"132":0.00369,"133":0.00737,"134":0.02949,"135":0.04423,"136":0.0258,"137":0.05529,"138":0.19904,"139":0.14007,"140":1.24587,"141":4.25364,"142":0.01474,_:"12 14 15 79 80 81 83 85 86 87 91 93 94 95 96 97 98 99 101 103 104 105 106 107 108 111 115 116 117 118 119 120 121"},E:{_:"0 4 5 6 7 8 9 10 11 12 13 14 15 3.1 3.2 6.1 7.1 9.1 10.1 11.1 13.1 15.1 15.2-15.3 15.4 15.5 16.0 16.5 17.0 18.4 26.1 26.2","5.1":0.00369,"12.1":0.01843,"14.1":0.01106,"15.6":0.01843,"16.1":0.00369,"16.2":0.1327,"16.3":0.0258,"16.4":0.00369,"16.6":0.01106,"17.1":0.00369,"17.2":0.01843,"17.3":0.00369,"17.4":0.00737,"17.5":0.01106,"17.6":0.03686,"18.0":0.01843,"18.1":0.00369,"18.2":0.00369,"18.3":0.00737,"18.5-18.6":0.02212,"26.0":0.02949},G:{"8":0,"3.2":0,"4.0-4.1":0,"4.2-4.3":0.00026,"5.0-5.1":0,"6.0-6.1":0.00103,"7.0-7.1":0.00077,"8.1-8.4":0,"9.0-9.2":0,"9.3":0.00231,"10.0-10.2":0.00026,"10.3":0.00436,"11.0-11.2":0.06461,"11.3-11.4":0.00154,"12.0-12.1":0.00051,"12.2-12.5":0.01256,"13.0-13.1":0,"13.2":0.00128,"13.3":0.00051,"13.4-13.7":0.00205,"14.0-14.4":0.00436,"14.5-14.8":0.00462,"15.0-15.1":0.00436,"15.2-15.3":0.00333,"15.4":0.00385,"15.5":0.00436,"15.6-15.8":0.05692,"16.0":0.00769,"16.1":0.01436,"16.2":0.00744,"16.3":0.01333,"16.4":0.00333,"16.5":0.0059,"16.6-16.7":0.07615,"17.0":0.00538,"17.1":0.0082,"17.2":0.0059,"17.3":0.00872,"17.4":0.01538,"17.5":0.02641,"17.6-17.7":0.06666,"18.0":0.01513,"18.1":0.03128,"18.2":0.01692,"18.3":0.05435,"18.4":0.02795,"18.5-18.6":1.42501,"26.0":0.17614,"26.1":0.00641},P:{"4":0.05151,"21":0.0103,"22":0.08242,"23":0.03091,"24":0.16484,"25":0.59753,"26":0.13393,"27":0.51511,"28":1.26718,"29":0.03091,_:"20 5.0-5.4 6.2-6.4 8.2 9.2 10.1 11.1-11.2 12.0 13.0 14.0 16.0 18.0","7.2-7.4":0.07212,"15.0":0.03091,"17.0":0.0103,"19.0":0.0206},I:{"0":0.38468,"3":0,"4":0,"2.1":0,"2.2":0,"2.3":0,"4.1":0,"4.2-4.3":0.00008,"4.4":0,"4.4.3-4.4.4":0.00019},K:{"0":0.73147,_:"10 11 12 11.1 11.5 12.1"},A:{"10":0.0172,"11":0.0086,_:"6 7 8 9 5.5"},S:{"2.5":0.01895,_:"3.0-3.1"},J:{_:"7 10"},N:{_:"10 11"},R:{_:"0"},M:{"0":0.18314},Q:{"14.9":0.05684},O:{"0":0.44205},H:{"0":0.14},L:{"0":72.00795}};
@@ -0,0 +1 @@
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.js"],"names":[],"mappings":"AA8CA;;;;;;;;;;GAUG;AAEH,mCARW,KAAK,WAEL,OAAO,GAEL,UAAU,CAgEtB;2BAnHqD,MAAM;6BADd,0BAA0B;gCAMP,YAAY"}
@@ -0,0 +1,59 @@
var $ee0bdf4faa47f2a8$exports = require("./utils.main.js");
function $parcel$export(e, n, v, s) {
Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
}
$parcel$export(module.exports, "DOMLayoutDelegate", () => $2ac4508142683dcb$export$8f5ed9ff9f511381);
/*
* Copyright 2024 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 $2ac4508142683dcb$export$8f5ed9ff9f511381 {
getItemRect(key) {
let container = this.ref.current;
if (!container) return null;
let item = key != null ? (0, $ee0bdf4faa47f2a8$exports.getItemElement)(this.ref, key) : null;
if (!item) return null;
let containerRect = container.getBoundingClientRect();
let itemRect = item.getBoundingClientRect();
return {
x: itemRect.left - containerRect.left - container.clientLeft + container.scrollLeft,
y: itemRect.top - containerRect.top - container.clientTop + container.scrollTop,
width: itemRect.width,
height: itemRect.height
};
}
getContentSize() {
let container = this.ref.current;
var _container_scrollWidth, _container_scrollHeight;
return {
width: (_container_scrollWidth = container === null || container === void 0 ? void 0 : container.scrollWidth) !== null && _container_scrollWidth !== void 0 ? _container_scrollWidth : 0,
height: (_container_scrollHeight = container === null || container === void 0 ? void 0 : container.scrollHeight) !== null && _container_scrollHeight !== void 0 ? _container_scrollHeight : 0
};
}
getVisibleRect() {
let container = this.ref.current;
var _container_scrollLeft, _container_scrollTop, _container_clientWidth, _container_clientHeight;
return {
x: (_container_scrollLeft = container === null || container === void 0 ? void 0 : container.scrollLeft) !== null && _container_scrollLeft !== void 0 ? _container_scrollLeft : 0,
y: (_container_scrollTop = container === null || container === void 0 ? void 0 : container.scrollTop) !== null && _container_scrollTop !== void 0 ? _container_scrollTop : 0,
width: (_container_clientWidth = container === null || container === void 0 ? void 0 : container.clientWidth) !== null && _container_clientWidth !== void 0 ? _container_clientWidth : 0,
height: (_container_clientHeight = container === null || container === void 0 ? void 0 : container.clientHeight) !== null && _container_clientHeight !== void 0 ? _container_clientHeight : 0
};
}
constructor(ref){
this.ref = ref;
}
}
//# sourceMappingURL=DOMLayoutDelegate.main.js.map
@@ -0,0 +1 @@
{"name":"is-weakref","version":"1.1.1","requiresBuild":false,"files":{".eslintrc":{"checkedAt":1794532097086,"integrity":"sha512-4+yheARSL/pPQeg25245ejEKIOgmGjgRW2fotkREQVMDnQQZj7Rw9FvimX0senKxW9R3GgLHQbPLwHLqbvQy6Q==","mode":420,"size":43},".nycrc":{"checkedAt":1794532097086,"integrity":"sha512-2vm1RFz8Ajl/OYrfoCWPJIm3Bpnf7Gyn5bha/lZx/cq+We3uMy9xj15XeP6x4wF3jf/pO7KMHAkU9mllm605xg==","mode":420,"size":139},"LICENSE":{"checkedAt":1794532096619,"integrity":"sha512-Pg0j9BX+Fmp8mAx1XW2wDVYsnbXuEq5QKBINQE+k1CyfdfAzv0tb/KUpKlAfmNVDddSa6Px43FQXpmTJrbd2Jw==","mode":420,"size":1067},"index.js":{"checkedAt":1794532097086,"integrity":"sha512-6gbil3l/H0QULWwUdYXfl0Ikrc2dr9DtZSYpCJGGqKbeJR6eWhHPiTvv2M9ahwZv1534H0lAre27bsKY4Mh4Ig==","mode":420,"size":599},"test/index.js":{"checkedAt":1794532097087,"integrity":"sha512-NB47TDkUuzT7eNMVcJl9ZT6BlYzt8ZXOfxVijTpq3wmI5XhIindCJ2Tf+i3pHaP7QOrCr+soMsqPsh5qXmnqEw==","mode":420,"size":696},"package.json":{"checkedAt":1794532097087,"integrity":"sha512-wPqJw0aDKZ87VaROnzJAT9X1MV3qX/43HVzqy15JJ/dL52IKZTStiYt/cKaW0bCS9eYZCirhLc7NwOqxJyDBUw==","mode":420,"size":2218},"tsconfig.json":{"checkedAt":1794532097087,"integrity":"sha512-xBbrFV4Zb7DECDeefgt+yhGfHLeRKbwlh2H6L08d8tjUDpSQt9WyNmB4pcNL/slJJ50FIksbN+w5cFzfKhZ+bw==","mode":420,"size":123},"CHANGELOG.md":{"checkedAt":1794532097087,"integrity":"sha512-V+OiuOCpPrj7o/o3e5k7ZTo/Ts3DQtgr+FUKBbCufmbUEuBV0oLIeQGS0rSAN1md44mFEDGCLVfcdGKtl2clzw==","mode":420,"size":8290},"README.md":{"checkedAt":1794532097087,"integrity":"sha512-x+hf9HBvYgvyWb+7ICn1TuQKH0MMQUfKb+OKuSN8yU/mNg/tAa5lErP1RbuYsLr9Ml4QmY74R2tsPNYH0eutnw==","mode":420,"size":2012},"index.d.ts":{"checkedAt":1794532097087,"integrity":"sha512-yEEi/Q/i1qpsdvFFqeg7rHTvyCk5GknqBQTOwAU2LKmX0h60Ch9bDtg8HDGm5CnCanilLssEW4Fc22woIPTTDQ==","mode":420,"size":104},".github/FUNDING.yml":{"checkedAt":1794532097087,"integrity":"sha512-4kFkEDEX1G0fytB6t5wK0+GWivubSQ0dynam/k9owF35Q/AVnnRtJzcQtHLQWXTKaSO2hj8phl4vaydmTQEiJw==","mode":420,"size":581}}}
@@ -0,0 +1,718 @@
export default `flf2a$ 7 7 16 -1 2
Relief by Nick Miners N.M.Miners@durham.ac.uk
June 1994
_____#
_____#
_____#
_____#
_____#
_____#
_____##
_____#
/~~\\_#
/~~\\_#
/~~\\_#
_____#
/~~\\_#
_____##
________#
/~\\_/~\\_#
/~\\_/~\\_#
________#
________#
________#
________##
____________#
__/~\\_/~\\___#
/~~~~~~~~~\\_#
__/~\\_/~\\___#
/~~~~~~~~~\\_#
__/~\\_/~\\___#
____________##
__________#
___/~~~~\\_#
__/~~\\____#
/~~~~~\\___#
__/~~\\____#
/~~~~~~~\\_#
__________##
_________#
/~\\_/~~\\_#
___/~~\\__#
__/~~\\___#
_/~~\\____#
/~~\\_/~\\_#
_________##
__________#
_/~~~~~\\__#
/~~\\______#
_/~~~~~~~\\#
/~~\\/~~\\__#
_/~~~~~\\__#
__________##
____#
/~\\_#
/\\__#
____#
____#
____#
____##
______#
_/~~\\_#
/~~\\__#
/~~\\__#
/~~\\__#
_/~~\\_#
______##
______#
/~~\\__#
_/~~\\_#
_/~~\\_#
_/~~\\_#
/~~\\__#
______##
__________#
___/~~\\___#
/~\\/~~\\/~\\#
_/~~~~~~\\_#
/~\\/~~\\/~\\#
___/~~\\___#
__________##
___________#
___/~~\\____#
___/~~\\____#
/~~~~~~~~\\_#
___/~~\\____#
___/~~\\____#
___________##
_____#
_____#
_____#
_____#
_____#
/~~\\_#
/~\\__##
__________#
__________#
__________#
/~~~~~~~\\_#
__________#
__________#
__________##
_____#
_____#
_____#
_____#
_____#
/~~\\_#
_____##
_________#
____/~~\\_#
___/~~\\__#
__/~~\\___#
_/~~\\____#
/~~\\_____#
_________##
____________#
__/~~~~~\\___#
_/~~\\_/~~\\__#
/~~\\___/~~\\_#
_/~~\\_/~~\\__#
__/~~~~~\\___#
____________##
_________#
__/~~\\___#
_/~~~\\___#
__/~~\\___#
__/~~\\___#
/~~~~~~\\_#
_________##
__________#
_/~~~~~~\\_#
/~~\\_/~~\\_#
___/~~\\___#
_/~~\\_____#
/~~~~~~~\\_#
__________##
__________#
_/~~~~~~\\_#
/~~\\_/~~\\_#
___/~~~\\__#
/~~\\_/~~\\_#
_/~~~~~~\\_#
__________##
___________#
__/~~~~~\\__#
_/~~\\/~~\\__#
/~~\\_/~~\\__#
/~~~~~~~~\\_#
_____/~~\\__#
___________##
_________#
/~~~~~~\\_#
/~~\\_____#
/~~~~~\\__#
____/~~\\_#
/~~~~~\\__#
_________##
__________#
___/~~\\___#
__/~~\\____#
_/~~~~~\\__#
/~~\\_/~~\\_#
_/~~~~~\\__#
__________##
_________#
/~~~~~~\\_#
___/~~\\__#
__/~~\\___#
_/~~\\____#
/~~\\_____#
_________##
__________#
_/~~~~~\\__#
/~~\\_/~~\\_#
_/~~~~~\\__#
/~~\\_/~~\\_#
_/~~~~~\\__#
__________##
__________#
_/~~~~~\\__#
/~~\\_/~~\\_#
_/~~~~~\\__#
___/~~\\___#
__/~~\\____#
__________##
_____#
_____#
_____#
_/~~\\#
_____#
_/~~\\#
_____##
_____#
_____#
_____#
_/~~\\#
_____#
_/~~\\#
_/~\\_##
_______#
__/~~\\_#
_/~~\\__#
/~~\\___#
_/~~\\__#
__/~~\\_#
_______##
__________#
__________#
/~~~~~~~\\_#
__________#
/~~~~~~~\\_#
__________#
__________##
_______#
_/~~\\__#
__/~~\\_#
__/~~\\_#
_/~~\\__#
/~~\\___#
_______##
_________#
_/~~~~\\__#
____/~~\\_#
___/~~\\__#
_________#
___/~~\\__#
_________##
___________#
_/~~~~~~\\__#
/~~\\__/~~\\_#
/~~\\/~~~~\\_#
/~~\\_______#
_/~~~~~~\\__#
___________##
___________#
_/~~~~~~\\__#
/~~\\__/~~\\_#
/~~~~~~~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
___________##
___________#
/~~~~~~~\\__#
/~~\\__/~~\\_#
/~~~~~~~\\__#
/~~\\__/~~\\_#
/~~~~~~~\\__#
___________##
___________#
_/~~~~~~\\__#
/~~\\__/~~\\_#
/~~\\_______#
/~~\\__/~~\\_#
_/~~~~~~\\__#
___________##
___________#
/~~~~~~~\\__#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~~~~~~\\__#
___________##
___________#
/~~~~~~~~\\_#
/~~\\_______#
/~~~~~~\\___#
/~~\\_______#
/~~~~~~~~\\_#
___________##
___________#
/~~~~~~~~\\_#
/~~\\_______#
/~~~~~~\\___#
/~~\\_______#
/~~\\_______#
___________##
___________#
_/~~~~~~\\__#
/~~\\__/~~\\_#
/~~\\_______#
/~~\\__/~~\\_#
_/~~~~~~~\\_#
______/~~\\_##
___________#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~~~~~~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
___________##
_______#
/~~~~\\_#
_/~~\\__#
_/~~\\__#
_/~~\\__#
/~~~~\\_#
_______##
_________#
__/~~~~\\_#
___/~~\\__#
___/~~\\__#
___/~~\\__#
/~~~~\\___#
_________##
___________#
/~~\\__/~~\\_#
/~~\\_/~~\\__#
/~~~~~\\____#
/~~\\_/~~\\__#
/~~\\__/~~\\_#
___________##
___________#
/~~\\_______#
/~~\\_______#
/~~\\_______#
/~~\\_______#
/~~~~~~~~\\_#
___________##
___________#
/~~\\__/~~\\_#
/~~~\\/~~~\\_#
/~~~~~~~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
___________##
___________#
/~~\\__/~~\\_#
/~~~~\\/~~\\_#
/~~~~~~~~\\_#
/~~\\/~~~~\\_#
/~~\\__/~~\\_#
___________##
___________#
_/~~~~~~\\__#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
_/~~~~~~\\__#
___________##
___________#
/~~~~~~~\\__#
/~~\\__/~~\\_#
/~~~~~~~\\__#
/~~\\_______#
/~~\\_______#
___________##
___________#
_/~~~~~~\\__#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~\\_/~~\\__#
_/~~~~~~~\\_#
___________##
___________#
/~~~~~~~\\__#
/~~\\__/~~\\_#
/~~~~~~~\\__#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
___________##
___________#
_/~~~~~~\\__#
/~~\\_______#
_/~~~~~~\\__#
______/~~\\_#
_/~~~~~~\\__#
___________##
___________#
/~~~~~~~~\\_#
___/~~\\____#
___/~~\\____#
___/~~\\____#
___/~~\\____#
___________##
___________#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
_/~~~~~~\\__#
___________##
___________#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
_/~~\\/~~\\__#
__/~~~~\\___#
___________##
_____________#
/~~\\/~~\\/~~\\_#
/~~\\/~~\\/~~\\_#
/~~\\/~~\\/~~\\_#
/~~\\/~~\\/~~\\_#
_/~~~~~~~~\\__#
_____________##
___________#
/~~\\__/~~\\_#
_/~~\\/~~\\__#
__/~~~~\\___#
_/~~\\/~~\\__#
/~~\\__/~~\\_#
___________##
___________#
/~~\\__/~~\\_#
_/~~\\/~~\\__#
__/~~~~\\___#
___/~~\\____#
___/~~\\____#
___________##
___________#
/~~~~~~~~\\_#
_____/~~\\__#
___/~~\\____#
_/~~\\______#
/~~~~~~~~\\_#
___________##
_______#
/~~~~\\_#
/~~\\___#
/~~\\___#
/~~\\___#
/~~~~\\_#
_______##
_________#
/~~\\_____#
_/~~\\____#
__/~~\\___#
___/~~\\__#
____/~~\\_#
_________##
_______#
/~~~~\\_#
__/~~\\_#
__/~~\\_#
__/~~\\_#
/~~~~\\_#
_______##
___________#
____/\\_____#
__/~~~~\\___#
/~~\\__/~~\\_#
___________#
___________#
___________##
___________#
___________#
___________#
___________#
___________#
/~~~~~~~~\\_#
___________##
____#
/~\\_#
_/\\_#
____#
____#
____#
____##
___________#
_/~~~~~~\\__#
/~~\\__/~~\\_#
/~~~~~~~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
___________##
___________#
/~~~~~~~\\__#
/~~\\__/~~\\_#
/~~~~~~~\\__#
/~~\\__/~~\\_#
/~~~~~~~\\__#
___________##
___________#
_/~~~~~~\\__#
/~~\\__/~~\\_#
/~~\\_______#
/~~\\__/~~\\_#
_/~~~~~~\\__#
___________##
___________#
/~~~~~~~\\__#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~~~~~~\\__#
___________##
___________#
/~~~~~~~~\\_#
/~~\\_______#
/~~~~~~\\___#
/~~\\_______#
/~~~~~~~~\\_#
___________##
___________#
/~~~~~~~~\\_#
/~~\\_______#
/~~~~~~\\___#
/~~\\_______#
/~~\\_______#
___________##
___________#
_/~~~~~~\\__#
/~~\\__/~~\\_#
/~~\\_______#
/~~\\__/~~\\_#
_/~~~~~~~\\_#
______/~~\\_##
___________#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~~~~~~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
___________##
_______#
/~~~~\\_#
_/~~\\__#
_/~~\\__#
_/~~\\__#
/~~~~\\_#
_______##
_________#
__/~~~~\\_#
___/~~\\__#
___/~~\\__#
___/~~\\__#
/~~~~\\___#
_________##
___________#
/~~\\__/~~\\_#
/~~\\_/~~\\__#
/~~~~~\\____#
/~~\\_/~~\\__#
/~~\\__/~~\\_#
___________##
___________#
/~~\\_______#
/~~\\_______#
/~~\\_______#
/~~\\_______#
/~~~~~~~~\\_#
___________##
___________#
/~~\\__/~~\\_#
/~~~\\/~~~\\_#
/~~~~~~~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
___________##
___________#
/~~\\__/~~\\_#
/~~~~\\/~~\\_#
/~~~~~~~~\\_#
/~~\\/~~~~\\_#
/~~\\__/~~\\_#
___________##
___________#
_/~~~~~~\\__#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
_/~~~~~~\\__#
___________##
___________#
/~~~~~~~\\__#
/~~\\__/~~\\_#
/~~~~~~~\\__#
/~~\\_______#
/~~\\_______#
___________##
___________#
_/~~~~~~\\__#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~\\_/~~\\__#
_/~~~~~~~\\_#
___________##
___________#
/~~~~~~~\\__#
/~~\\__/~~\\_#
/~~~~~~~\\__#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
___________##
___________#
_/~~~~~~\\__#
/~~\\_______#
_/~~~~~~\\__#
______/~~\\_#
_/~~~~~~\\__#
___________##
___________#
/~~~~~~~~\\_#
___/~~\\____#
___/~~\\____#
___/~~\\____#
___/~~\\____#
___________##
___________#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
_/~~~~~~\\__#
___________##
___________#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
_/~~\\/~~\\__#
__/~~~~\\___#
___________##
_____________#
/~~\\/~~\\/~~\\_#
/~~\\/~~\\/~~\\_#
/~~\\/~~\\/~~\\_#
/~~\\/~~\\/~~\\_#
_/~~~~~~~~\\__#
_____________##
___________#
/~~\\__/~~\\_#
_/~~\\/~~\\__#
__/~~~~\\___#
_/~~\\/~~\\__#
/~~\\__/~~\\_#
___________##
___________#
/~~\\__/~~\\_#
_/~~\\/~~\\__#
__/~~~~\\___#
___/~~\\____#
___/~~\\____#
___________##
___________#
/~~~~~~~~\\_#
_____/~~\\__#
___/~~\\____#
_/~~\\______#
/~~~~~~~~\\_#
___________##
_________#
__/~~~~\\_#
__/~~\\___#
/~~~~\\___#
__/~~\\___#
__/~~~~\\_#
_________##
_____#
/~~\\_#
/~~\\_#
/~~\\_#
/~~\\_#
/~~\\_#
_____##
_________#
/~~~~\\___#
__/~~\\___#
__/~~~~\\_#
__/~~\\___#
/~~~~\\___#
_________##
______________#
__/~~~\\__/~~\\_#
_/~~~~~~~~~\\__#
/~~\\__/~~~\\___#
______________#
______________#
______________##
___________#
_/~~~~~~\\__#
/~~\\__/~~\\_#
/~~~~~~~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
___________##
___________#
_/~~~~~~\\__#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
_/~~~~~~\\__#
___________##
___________#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
_/~~~~~~\\__#
___________##
___________#
_/~~~~~~\\__#
/~~\\__/~~\\_#
/~~~~~~~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
___________##
___________#
_/~~~~~~\\__#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
_/~~~~~~\\__#
___________##
___________#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
/~~\\__/~~\\_#
_/~~~~~~\\__#
___________##
___________#
_/~~~~~~\\__#
/~~\\__/~~\\_#
/~~\\_/~~\\__#
/~~\\__/~~\\_#
/~~\\_/~~\\__#
___________##
`
@@ -0,0 +1,15 @@
"use client";
import {
Form
} from "./chunk-GVH3SVCP.mjs";
import {
FormContext
} from "./chunk-ICU6NNET.mjs";
import {
useSlottedContext
} from "./chunk-YMDFNRVV.mjs";
export {
Form,
FormContext,
useSlottedContext
};
@@ -0,0 +1,17 @@
import { Parse } from './parse.mjs';
// ------------------------------------------------------------------
// Module
// ------------------------------------------------------------------
export class Module {
constructor(properties) {
this.properties = properties;
}
/** Parses using one of the parsers defined on this instance */
Parse(...args) {
// prettier-ignore
const [key, content, context] = (args.length === 3 ? [args[0], args[1], args[2]] :
args.length === 2 ? [args[0], args[1], undefined] :
(() => { throw Error('Invalid parse arguments'); })());
return Parse(this.properties, this.properties[key], content, context);
}
}
@@ -0,0 +1,38 @@
const defaultOptions = {
maxLength: 200,
// locale: "en-IN"
}
const localeMap = {
"$":"en-US",
"€":"de-DE",
"£":"en-GB",
"¥":"ja-JP",
"₹":"en-IN",
}
const sign = "(?:-|\+)?";
const digitsAndSeparator = "(?:\d+|\d{1,3}(?:,\d{3})+)";
const decimalPart = "(?:\.\d{1,2})?";
const symbol = "(?:\$|€|¥|₹)?";
const currencyCheckRegex = /^\s*(?:-|\+)?(?:\d+|\d{1,3}(?:,\d{3})+)?(?:\.\d{1,2})?\s*(?:\$|€|¥|₹)?\s*$/u;
export default class CurrencyParser{
constructor(options){
this.options = options || defaultOptions;
}
parse(val){
if (typeof val === 'string' && val.length <= this.options.maxLength) {
if(val.indexOf(",,") !== -1 && val.indexOf(".." !== -1)){
const match = val.match(currencyCheckRegex);
if(match){
const locale = this.options.locale || localeMap[match[2]||match[5]||"₹"];
const formatter = new Intl.NumberFormat(locale)
val = val.replace(/[^0-9,.]/g, '').trim();
val = Number(val.replace(formatter.format(1000)[1], ''));
}
}
}
return val;
}
}
CurrencyParser.defaultOptions = defaultOptions;
@@ -0,0 +1 @@
{"version":3,"file":"create-rule.js","sourceRoot":"","sources":["../../src/utils/create-rule.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAA;AACjD,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAA;AAQvC,MAAM,UAAU,WAAW,CACzB,UAAwC;IAIxC,OAAO,SAAS,eAAe,CAG7B,EACA,IAAI,EACJ,IAAI,EACJ,GAAG,IAAI,EAGR;QACC,OAAO,WAAW,CAAkC;YAClD,IAAI,EAAE;gBACJ,GAAG,IAAI;gBACP,IAAI,EAAE;oBACJ,GAAG,IAAI,CAAC,IAAI;oBACZ,GAAG,EAAE,UAAU,CAAC,IAAI,CAAC;iBACtB;aACF;YACD,GAAG,IAAI;SACR,CAAC,CAAA;IACJ,CAAC,CAAA;AACH,CAAC;AAED,SAAS,WAAW,CAIlB,EACA,MAAM,EACN,cAAc,EACd,IAAI,GAGL;IACC,OAAO;QACL,MAAM,CACJ,OAA4D;YAE5D,MAAM,kBAAkB,GAAG,YAAY,CAAC,cAAc,EAAE,OAAO,CAAC,OAAO,CAAC,CAAA;YACxE,OAAO,MAAM,CAAC,OAAO,EAAE,kBAAkB,CAAC,CAAA;QAC5C,CAAC;QACD,cAAc;QACd,IAAI;KACL,CAAA;AACH,CAAC;AASD,MAAM,CAAC,MAAM,UAAU,GAAG,WAAW,CAAoB,OAAO,CAAC,CAAA"}
@@ -0,0 +1,11 @@
Copyright (c) Felix Böhm
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
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 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 HOLDER 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,
EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
@@ -0,0 +1 @@
{"mappings":";AAAA,4BAAiB;IAAG,eAAe,CAAC,+DAAS,CAAC;AAC9C","sources":["packages/@react-aria/breadcrumbs/intl/ru-RU.json"],"sourcesContent":["{\n \"breadcrumbs\": \"Навигация\"\n}\n"],"names":[],"version":3,"file":"ru-RU.module.js.map"}
@@ -0,0 +1 @@
self.Flatted=function(t){"use strict";const{parse:e,stringify:n}=JSON,{keys:r}=Object,s=String,o="string",c={},l="object",a=(t,e)=>e,f=t=>t instanceof s?s(t):t,i=(t,e)=>typeof e===o?new s(e):e,u=(t,e,n,o)=>{const a=[];for(let f=r(n),{length:i}=f,u=0;u<i;u++){const r=f[u],i=n[r];if(i instanceof s){const s=t[i];typeof s!==l||e.has(s)?n[r]=o.call(n,r,s):(e.add(s),n[r]=c,a.push({k:r,a:[t,e,s,o]}))}else n[r]!==c&&(n[r]=o.call(n,r,i))}for(let{length:t}=a,e=0;e<t;e++){const{k:t,a:r}=a[e];n[t]=o.call(n,t,u.apply(null,r))}return n},p=(t,e,n)=>{const r=s(e.push(n)-1);return t.set(n,r),r},y=(t,n)=>{const r=e(t,i).map(f),s=r[0],o=n||a,c=typeof s===l&&s?u(r,new Set,s,o):s;return o.call({"":c},"",c)},g=(t,e,r)=>{const s=e&&typeof e===l?(t,n)=>""===t||-1<e.indexOf(t)?n:void 0:e||a,c=new Map,f=[],i=[];let u=+p(c,f,s.call({"":t},"",t)),y=!u;for(;u<f.length;)y=!0,i[u]=n(f[u++],g,r);return"["+i.join(",")+"]";function g(t,e){if(y)return y=!y,e;const n=s.call(this,t,e);switch(typeof n){case l:if(null===n)return n;case o:return c.get(n)||p(c,f,n)}return n}};return t.fromJSON=t=>y(n(t)),t.parse=y,t.stringify=g,t.toJSON=t=>e(g(t)),t}({});
@@ -0,0 +1,6 @@
module.exports = {
"dismiss": `Kapat`
};
//# sourceMappingURL=tr-TR.main.js.map
@@ -0,0 +1,12 @@
export declare class IpConverter {
private static isIPv4;
private static parseIPv4;
private static parseIPv6;
private static expandIPv6;
private static formatIPv6;
private static compressIPv6;
private static parseCIDR;
private static decodeIP;
static toString(buf: ArrayBuffer): string;
static fromString(text: string): ArrayBuffer;
}
@@ -0,0 +1 @@
module.exports={A:{A:{"2":"K D E F A B wC"},B:{"1":"0 1 2 3 4 5 C L M G N O P Q H R S T U V W X Y Z a b c d e f g h i j k l m n o p q r s t u v w x y z GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB I"},C:{"1":"0 1 2 3 4 5 6 7 8 9 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 G N O 0C 1C"},D:{"1":"0 1 2 3 4 5 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","2":"J ZB K D E F A B C L M G N O P jB kB lB mB nB oB pB qB rB sB tB","66":"6 7 8 9 aB AB BB CB DB EB FB bB cB dB eB fB gB hB iB"},E:{"1":"A B C L M G 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 K D E F 2C ZC 3C 4C 5C 6C"},F:{"1":"0 1 2 3 4 5 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","2":"F B C BB CB DB EB FB bB cB dB eB fB gB FD GD HD ID NC uC JD OC","66":"6 7 8 9 G N O P aB AB"},G:{"1":"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","2":"E ZC KD vC LD MD ND OD PD QD"},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 oD pD qD rD sD aC tD uD vD wD xD QC RC SC yD","2":"J"},Q:{"1":"zD"},R:{"1":"0D"},S:{"1":"1D 2D"}},B:6,C:"Proxy object",D:true};
@@ -0,0 +1 @@
{"version":3,"file":"getExtendedLifecycle.d.ts","sourceRoot":"","sources":["../../../../src/metadata/calculations/getExtendedLifecycle.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AACxD,OAAO,EAAE,sBAAsB,EAAE,MAAM,kCAAkC,CAAC;AAC1E,OAAO,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AAchE,wBAAgB,oBAAoB,CAClC,OAAO,EAAE,iBAAiB,EAC1B,qBAAqB,EAAE,aAAa,EACpC,YAAY,EAAE,aAAa,GAC1B,sBAAsB,CAsBxB"}
@@ -0,0 +1,2 @@
export declare const typescriptParameterTypesReflectKey: string;
//# sourceMappingURL=typescriptDesignParameterTypesReflectKey.d.ts.map
@@ -0,0 +1,14 @@
/**
* Turn an mdast `delete` node into hast.
*
* @param {State} state
* Info passed around.
* @param {Delete} node
* mdast node.
* @returns {Element}
* hast node.
*/
export function strikethrough(state: State, node: Delete): Element;
export type Element = import("hast").Element;
export type Delete = import("mdast").Delete;
export type State = import("../state.js").State;
@@ -0,0 +1 @@
module.exports={A:{A:{"2":"K D E F A B wC"},B:{"1":"1 2 3 4 5 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 Q H R S T U V W X Y Z a b c d e f g h i j k l m","194":"0 n o p q r s t u v w x y z"},C:{"1":"yC zC","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 0C 1C"},D:{"1":"1 2 3 4 5 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 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","194":"0 n o p q r s t u v w x y z"},E:{"1":"lC mC CD SC nC oC pC qC rC sC tC DD ED","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"},F:{"1":"0 1 2 3 4 5 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 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 FD GD HD ID NC uC JD OC","194":"Z a b c d e f g h i j k l m n o"},G:{"1":"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 ZD aD bD cD dD bC cC PC eD QC dC eC fC gC hC fD RC iC jC kC"},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:{"2":"MC"},N:{"2":"A B"},O:{"2":"PC"},P:{"1":"BB CB DB EB FB","2":"6 7 8 9 J AB oD pD qD rD sD aC tD uD vD wD xD QC RC SC yD"},Q:{"2":"zD"},R:{"2":"0D"},S:{"2":"1D 2D"}},B:5,C:"Scoped Styles: the @scope rule",D:true};
@@ -0,0 +1 @@
{"name":"domutils","version":"3.2.2","requiresBuild":false,"files":{"LICENSE":{"checkedAt":1794532100338,"integrity":"sha512-6jZ515oacWH/aN1CZdfom57iv/9PMtjaSAJpLW/cXBcG/57dXc42rU6I96pfdgYc9MyHlKAQ7785tbyx7wilUA==","mode":420,"size":1260},"lib/esm/feeds.js":{"checkedAt":1794532100343,"integrity":"sha512-uPwDR1dN8lKvGldXruxhyS7a7DeNT4MR2IbjRNYd4KL6pbS1H1jbo+UDujkT2odq77fXqt/zcwueboBsIRunVQ==","mode":420,"size":5981},"lib/feeds.js":{"checkedAt":1794532100343,"integrity":"sha512-GRbM/MgHLBt/kDb5yjCYbxknQekVgg+L+RtqYePai+5+LWsyzY1YWuR5k20Lh8IrNhI627rRtlxsJAaOLrpAlA==","mode":420,"size":6452},"lib/esm/helpers.js":{"checkedAt":1794532100344,"integrity":"sha512-7da89iq0dO8o1zXmIq0O3neoxDolUIM07shxchXLUi7wHGi1Alm/+V09fbiJK7UbbeH2FUIJoO/6Sb2IU0k4CQ==","mode":420,"size":4981},"lib/helpers.js":{"checkedAt":1794532100344,"integrity":"sha512-iB3aFud89PuL8qJ84Dj1c1mPvn8MsyyevA6lEZr1cB4zNe152sH+jCrOzA5tC0+aWNGg7BH4ztRJ0u3xZiS6Nw==","mode":420,"size":5265},"lib/esm/index.js":{"checkedAt":1794532100344,"integrity":"sha512-vpaVslUnIRqYktbhfVsJ/ciesTeeOXxu17deJ+9KMdl9ZqIaI7Gn7Aj5XJ5CnsXD9kmHhfgVTUvSHlrq9JJwXA==","mode":420,"size":405},"lib/index.js":{"checkedAt":1794532100344,"integrity":"sha512-Tph164RYqM3soO9Xff8P/AmqefddH2HAknBwAwbAyydq4qRcQM8B53lO363Wa7VR/TtmQOjTBG3ZvF7o7TNT2A==","mode":420,"size":2070},"lib/esm/legacy.js":{"checkedAt":1794532100344,"integrity":"sha512-N34skiboxBMXPkvbCK977ciWoRxude3/HHPHytanclG19UUkFN06trez94fkPhlnNo8lPQgpH5bjng+VHRS1+w==","mode":420,"size":5209},"lib/legacy.js":{"checkedAt":1794532100344,"integrity":"sha512-qOWFU1Ffh/rv3dfF4N9TJU/f8yYI72F0Wybm1tfrxYrezT5tY7qYGQwwIQWpr9UUFlQUuFywz7usih6OZ8Wnsg==","mode":420,"size":6232},"lib/esm/manipulation.js":{"checkedAt":1794532100344,"integrity":"sha512-fQz8iGSrCthRMfxw1sD6bYxokkXdHgSlzAaFn+pHzshMwRxlL/V5hsZNE5VCe08r76mCgMyMCBMqzek7g2j2ig==","mode":420,"size":3376},"lib/manipulation.js":{"checkedAt":1794532100345,"integrity":"sha512-xkYTqIMN0PGfKvdynM6jsl3OItQ9zTm1nqDD/O2xES/Qd0y3uz4xfXmGjN7WxHmaXUxlxtXNO+uRRcvpZun/dQ==","mode":420,"size":3595},"lib/esm/querying.js":{"checkedAt":1794532100345,"integrity":"sha512-FW2ecSF9mb+hxkiyxn38VAej0rFLb/i9O3shwnDVDhP+mpV3mcMPJ/nTZj5fleU2jh21aShR8FYuVta+PMfcdA==","mode":420,"size":5124},"lib/querying.js":{"checkedAt":1794532100345,"integrity":"sha512-IDZOCFHDVDF78uAzlvkLVM2K+gNWTJSVpMnz/wFE8i8wKYawHu8daJPRhd+E57iuvzr82wVKEbBJ4SVTIe6hAA==","mode":420,"size":5577},"lib/esm/stringify.js":{"checkedAt":1794532100345,"integrity":"sha512-+iCKUBGQSvx+/P7RTrpnry83EilkaUdQMpVyc2bzlZJfPKA1kStjwWKA/AHUiVdyyGEOL3JwVcu2/eiFHn3IPg==","mode":420,"size":2562},"lib/stringify.js":{"checkedAt":1794532100345,"integrity":"sha512-U+AXgjwnKSD51DvcpG1FRc3Sqttas+9qh5it4DAY1HTqgAYSeppPUkYoam8DVknVG4k84VgUhXy4dew9etHHng==","mode":420,"size":3138},"lib/esm/traversal.js":{"checkedAt":1794532100345,"integrity":"sha512-GGGrTb0eo3ICOBXVEYLR+wWCq1Gm4A6kLeiCqlqiLAF88nHWkaoMiqZARv4COFAtSQ4I7Ovlnd74HWE0MSsKeg==","mode":420,"size":3092},"lib/traversal.js":{"checkedAt":1794532100346,"integrity":"sha512-vT7XVmFRB0f2WjU7vclkUFCkRmTfLRBgoPqZt1h15ncvJj9qC9rDtymHMsjgzC+TJPVWja3CODpyHKGPh+VUKw==","mode":420,"size":3554},"lib/esm/package.json":{"checkedAt":1794532100338,"integrity":"sha512-yJaw9MUXdELVmz7z3SYVp2blYklya3nL3pU6DnmPcM5rDXeD26fLnxMcB3WmvAQ/Uq9woAMNLTYvYRv/3m6T8Q==","mode":420,"size":18},"package.json":{"checkedAt":1794532100346,"integrity":"sha512-5nEFds8In4u3NYmSvvhSq+CSJ3deJ6uiBbsiv6mUMSo7RuNFFKao+D3Gq2P+0byPCT9r6ae4gJ0UZVjMpVnWaQ==","mode":420,"size":2560},"lib/esm/feeds.d.ts.map":{"checkedAt":1794532100346,"integrity":"sha512-WZurt5MQYvwdRoAljo15a2WB50+B6fR1DgvTb9aNvLN6eC8rC5R1uoBG4uqHfVkmuiVnPoGy/ee8CIjWxgNdLg==","mode":420,"size":1453},"lib/feeds.d.ts.map":{"checkedAt":1794532100346,"integrity":"sha512-WZurt5MQYvwdRoAljo15a2WB50+B6fR1DgvTb9aNvLN6eC8rC5R1uoBG4uqHfVkmuiVnPoGy/ee8CIjWxgNdLg==","mode":420,"size":1453},"lib/esm/feeds.js.map":{"checkedAt":1794532100346,"integrity":"sha512-sbEbf6BHZILTZNi2L1Ucpgbb7h9niqIDcY7yWTry+FokG07N5zJ8t0SEJ334ZwUlyCN3y5I7ArB59Azf8rFTkg==","mode":420,"size":5078},"lib/feeds.js.map":{"checkedAt":1794532100346,"integrity":"sha512-QZm8/WsxEUQVTQPxAjQB/Fp4v1Kd6+dTAGzaZvDqA3ioRkHOgKihofK+ivjQFtpsLvGiG+NVpYokC860b+NPtw==","mode":420,"size":5120},"lib/esm/helpers.d.ts.map":{"checkedAt":1794532100346,"integrity":"sha512-WCOU3yBCAOeRB63Ir2Z5iQWSU+pd3jjoK+IX6c7OoonoMlPZyH8IJwgJK54MsMyMipckvEWwQAaJB63MAltKoA==","mode":420,"size":639},"lib/helpers.d.ts.map":{"checkedAt":1794532100346,"integrity":"sha512-WCOU3yBCAOeRB63Ir2Z5iQWSU+pd3jjoK+IX6c7OoonoMlPZyH8IJwgJK54MsMyMipckvEWwQAaJB63MAltKoA==","mode":420,"size":639},"lib/esm/helpers.js.map":{"checkedAt":1794532100346,"integrity":"sha512-pvhTGWmSoHKv3wIUlKP1nuw5o82ZSDHh/zRz95SU+V05qOasQLB4bb5rmiu6+TOZjivCOBkkRxXJS+POx+5dNQ==","mode":420,"size":3090},"lib/helpers.js.map":{"checkedAt":1794532100346,"integrity":"sha512-csdmhT2SBcWYv/+3DTI96dMOa4mwVgfTU86blTpHwpFQh2caFTsQUOhcc0uSEQB5AKIy6fssWisL3vaFBZycBg==","mode":420,"size":3088},"lib/esm/index.d.ts.map":{"checkedAt":17945Line truncated
@@ -0,0 +1,35 @@
function sortStarts(a, b) {
return (a.range ? a.range[0] : a.start) - (b.range ? b.range[0] : b.start);
}
/**
* Returns the string value of a template literal object.
* Tries to build it as best as it can based on the passed
* prop. For instance `This is a ${prop}` will return 'This is a {prop}'.
*
* If the template literal builds to undefined (`${undefined}`), then
* this should return "undefined".
*/
export default function extractValueFromTemplateLiteral(value) {
const {
quasis,
expressions,
} = value;
const partitions = quasis.concat(expressions);
return partitions.sort(sortStarts).map(({ type, value: { raw } = {}, name }) => {
if (type === 'TemplateElement') {
return raw;
}
if (type === 'Identifier') {
return name === 'undefined' ? name : `{${name}}`;
}
if (type.indexOf('Expression') > -1) {
return `{${type}}`;
}
return '';
}).join('');
}
@@ -0,0 +1,103 @@
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
exports[`parseFeed > (atomFeed) 1`] = `
{
"author": "johndoe@example.com",
"description": "A subtitle.",
"id": "urn:uuid:60a76c80-d399-11d9-b91C-0003939e0af6",
"items": [
{
"description": "Some content.",
"id": "urn:uuid:1225c695-cfb8-4ebb-aaaa-80da344efa6a",
"link": "http://example.org/2003/12/13/atom03",
"media": [],
"pubDate": 2003-12-13T18:30:02.000Z,
"title": "Atom-Powered Robots Run Amok",
},
{
"media": [],
},
],
"link": "http://example.org/feed/",
"title": "Example Feed",
"type": "atom",
"updated": 2003-12-13T18:30:02.000Z,
}
`;
exports[`parseFeed > (rdfFeed) 1`] = `
{
"id": "",
"items": [
{
"description": "Great test content<br>A link: <a href="http://github.com">Github</a>",
"link": "http://somefakesite/path/to/something.html",
"media": [],
"pubDate": 2011-11-04T16:35:17.000Z,
"title": "Fast HTML Parsing",
},
{
"description": "The early bird gets the worm",
"link": "http://somefakesite/path/to/something-else.html",
"media": [],
"pubDate": 2011-11-04T16:34:54.000Z,
"title": "This space intentionally left blank",
},
],
"link": "https://github.com/fb55/htmlparser2/",
"title": "A title to parse and remember",
"type": "rdf",
}
`;
exports[`parseFeed > (rssFeed) 1`] = `
{
"author": "editor@example.com",
"description": "Liftoff to Space Exploration.",
"id": "",
"items": [
{
"description": "How do Americans get ready to work with Russians aboard the International Space Station? They take a crash course in culture, language and protocol at Russia's <a href="http://howe.iki.rssi.ru/GCTC/gctc_e.htm">Star City</a>.",
"id": "http://liftoff.msfc.nasa.gov/2003/06/03.html#item573",
"link": "http://liftoff.msfc.nasa.gov/news/2003/news-starcity.asp",
"media": [],
"pubDate": 2003-06-03T09:39:21.000Z,
"title": "Star City",
},
{
"description": "Sky watchers in Europe, Asia, and parts of Alaska and Canada will experience a <a href="http://science.nasa.gov/headlines/y2003/30may_solareclipse.htm">partial eclipse of the Sun</a> on Saturday, May 31st.",
"id": "http://liftoff.msfc.nasa.gov/2003/05/30.html#item572",
"media": [],
"pubDate": 2003-05-30T11:06:42.000Z,
},
{
"description": "Before man travels to Mars, NASA hopes to design new engines that will let us fly through the Solar System more quickly. The proposed VASIMR engine would do that.",
"id": "http://liftoff.msfc.nasa.gov/2003/05/27.html#item571",
"link": "http://liftoff.msfc.nasa.gov/news/2003/news-VASIMR.asp",
"media": [],
"pubDate": 2003-05-27T08:37:32.000Z,
"title": "The Engine That Does More",
},
{
"description": "Compared to earlier spacecraft, the International Space Station has many luxuries, but laundry facilities are not one of them. Instead, astronauts have other options.",
"id": "http://liftoff.msfc.nasa.gov/2003/05/20.html#item570",
"link": "http://liftoff.msfc.nasa.gov/news/2003/news-laundry.asp",
"media": [
{
"height": 200,
"isDefault": false,
"medium": "image",
"url": "https://picsum.photos/200",
"width": 200,
},
],
"pubDate": 2003-05-20T08:56:02.000Z,
"title": "Astronauts' Dirty Laundry",
},
],
"link": "http://liftoff.msfc.nasa.gov/",
"title": "Liftoff News",
"type": "rss",
"updated": 2003-06-10T09:41:01.000Z,
}
`;
@@ -0,0 +1,18 @@
"use client";
import {
usePaginationItem
} from "./chunk-AQ7H3LB5.mjs";
// src/pagination-item.tsx
import { forwardRef } from "@heroui/system";
import { jsx } from "react/jsx-runtime";
var PaginationItem = forwardRef((props, ref) => {
const { Component, children, getItemProps } = usePaginationItem({ ...props, ref });
return /* @__PURE__ */ jsx(Component, { ...getItemProps(), children });
});
PaginationItem.displayName = "HeroUI.PaginationItem";
var pagination_item_default = PaginationItem;
export {
pagination_item_default
};
@@ -0,0 +1,133 @@
import _typeof from "./typeof.js";
import checkInRHS from "./checkInRHS.js";
import setFunctionName from "./setFunctionName.js";
import toPropertyKey from "./toPropertyKey.js";
function applyDecs2305(e, t, r, n, o, a) {
function i(e, t, r) {
return function (n, o) {
return r && r(n), e[t].call(n, o);
};
}
function c(e, t) {
for (var r = 0; r < e.length; r++) e[r].call(t);
return t;
}
function s(e, t, r, n) {
if ("function" != typeof e && (n || void 0 !== e)) throw new TypeError(t + " must " + (r || "be") + " a function" + (n ? "" : " or undefined"));
return e;
}
function applyDec(e, t, r, n, o, a, c, u, l, f, p, d, h) {
function m(e) {
if (!h(e)) throw new TypeError("Attempted to access private element on non-instance");
}
var y,
v = t[0],
g = t[3],
b = !u;
if (!b) {
r || Array.isArray(v) || (v = [v]);
var w = {},
S = [],
A = 3 === o ? "get" : 4 === o || d ? "set" : "value";
f ? (p || d ? w = {
get: setFunctionName(function () {
return g(this);
}, n, "get"),
set: function set(e) {
t[4](this, e);
}
} : w[A] = g, p || setFunctionName(w[A], n, 2 === o ? "" : A)) : p || (w = Object.getOwnPropertyDescriptor(e, n));
}
for (var P = e, j = v.length - 1; j >= 0; j -= r ? 2 : 1) {
var D = v[j],
E = r ? v[j - 1] : void 0,
I = {},
O = {
kind: ["field", "accessor", "method", "getter", "setter", "class"][o],
name: n,
metadata: a,
addInitializer: function (e, t) {
if (e.v) throw Error("attempted to call addInitializer after decoration was finished");
s(t, "An initializer", "be", !0), c.push(t);
}.bind(null, I)
};
try {
if (b) (y = s(D.call(E, P, O), "class decorators", "return")) && (P = y);else {
var k, F;
O["static"] = l, O["private"] = f, f ? 2 === o ? k = function k(e) {
return m(e), w.value;
} : (o < 4 && (k = i(w, "get", m)), 3 !== o && (F = i(w, "set", m))) : (k = function k(e) {
return e[n];
}, (o < 2 || 4 === o) && (F = function F(e, t) {
e[n] = t;
}));
var N = O.access = {
has: f ? h.bind() : function (e) {
return n in e;
}
};
if (k && (N.get = k), F && (N.set = F), P = D.call(E, d ? {
get: w.get,
set: w.set
} : w[A], O), d) {
if ("object" == _typeof(P) && P) (y = s(P.get, "accessor.get")) && (w.get = y), (y = s(P.set, "accessor.set")) && (w.set = y), (y = s(P.init, "accessor.init")) && S.push(y);else if (void 0 !== P) throw new TypeError("accessor decorators must return an object with get, set, or init properties or void 0");
} else s(P, (p ? "field" : "method") + " decorators", "return") && (p ? S.push(P) : w[A] = P);
}
} finally {
I.v = !0;
}
}
return (p || d) && u.push(function (e, t) {
for (var r = S.length - 1; r >= 0; r--) t = S[r].call(e, t);
return t;
}), p || b || (f ? d ? u.push(i(w, "get"), i(w, "set")) : u.push(2 === o ? w[A] : i.call.bind(w[A])) : Object.defineProperty(e, n, w)), P;
}
function u(e, t) {
return Object.defineProperty(e, Symbol.metadata || Symbol["for"]("Symbol.metadata"), {
configurable: !0,
enumerable: !0,
value: t
});
}
if (arguments.length >= 6) var l = a[Symbol.metadata || Symbol["for"]("Symbol.metadata")];
var f = Object.create(null == l ? null : l),
p = function (e, t, r, n) {
var o,
a,
i = [],
s = function s(t) {
return checkInRHS(t) === e;
},
u = new Map();
function l(e) {
e && i.push(c.bind(null, e));
}
for (var f = 0; f < t.length; f++) {
var p = t[f];
if (Array.isArray(p)) {
var d = p[1],
h = p[2],
m = p.length > 3,
y = 16 & d,
v = !!(8 & d),
g = 0 == (d &= 7),
b = h + "/" + v;
if (!g && !m) {
var w = u.get(b);
if (!0 === w || 3 === w && 4 !== d || 4 === w && 3 !== d) throw Error("Attempted to decorate a public method/accessor that has the same name as a previously decorated public method/accessor. This is not currently supported by the decorators plugin. Property name was: " + h);
u.set(b, !(d > 2) || d);
}
applyDec(v ? e : e.prototype, p, y, m ? "#" + h : toPropertyKey(h), d, n, v ? a = a || [] : o = o || [], i, v, m, g, 1 === d, v && m ? s : r);
}
}
return l(o), l(a), i;
}(e, t, o, f);
return r.length || u(e, f), {
e: p,
get c() {
var t = [];
return r.length && [u(applyDec(e, [r], n, e.name, 5, f, t), f), c.bind(null, t, e)];
}
};
}
export { applyDecs2305 as default };
@@ -0,0 +1,99 @@
/*
* 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 {getOwnerDocument, isIOS, runAfterTransition} from '@react-aria/utils';
// Safari on iOS starts selecting text on long press. The only way to avoid this, it seems,
// is to add user-select: none to the entire page. Adding it to the pressable element prevents
// that element from being selected, but nearby elements may still receive selection. We add
// user-select: none on touch start, and remove it again on touch end to prevent this.
// This must be implemented using global state to avoid race conditions between multiple elements.
// There are three possible states due to the delay before removing user-select: none after
// pointer up. The 'default' state always transitions to the 'disabled' state, which transitions
// to 'restoring'. The 'restoring' state can either transition back to 'disabled' or 'default'.
// For non-iOS devices, we apply user-select: none to the pressed element instead to avoid possible
// performance issues that arise from applying and removing user-select: none to the entire page
// (see https://github.com/adobe/react-spectrum/issues/1609).
type State = 'default' | 'disabled' | 'restoring';
// Note that state only matters here for iOS. Non-iOS gets user-select: none applied to the target element
// rather than at the document level so we just need to apply/remove user-select: none for each pressed element individually
let state: State = 'default';
let savedUserSelect = '';
let modifiedElementMap = new WeakMap<Element, string>();
export function disableTextSelection(target?: Element) {
if (isIOS()) {
if (state === 'default') {
const documentObject = getOwnerDocument(target);
savedUserSelect = documentObject.documentElement.style.webkitUserSelect;
documentObject.documentElement.style.webkitUserSelect = 'none';
}
state = 'disabled';
} else if (target instanceof HTMLElement || target instanceof SVGElement) {
// If not iOS, store the target's original user-select and change to user-select: none
// Ignore state since it doesn't apply for non iOS
modifiedElementMap.set(target, target.style.userSelect);
target.style.userSelect = 'none';
}
}
export function restoreTextSelection(target?: Element) {
if (isIOS()) {
// If the state is already default, there's nothing to do.
// If it is restoring, then there's no need to queue a second restore.
if (state !== 'disabled') {
return;
}
state = 'restoring';
// There appears to be a delay on iOS where selection still might occur
// after pointer up, so wait a bit before removing user-select.
setTimeout(() => {
// Wait for any CSS transitions to complete so we don't recompute style
// for the whole page in the middle of the animation and cause jank.
runAfterTransition(() => {
// Avoid race conditions
if (state === 'restoring') {
const documentObject = getOwnerDocument(target);
if (documentObject.documentElement.style.webkitUserSelect === 'none') {
documentObject.documentElement.style.webkitUserSelect = savedUserSelect || '';
}
savedUserSelect = '';
state = 'default';
}
});
}, 300);
} else if (target instanceof HTMLElement || target instanceof SVGElement) {
// If not iOS, restore the target's original user-select if any
// Ignore state since it doesn't apply for non iOS
if (target && modifiedElementMap.has(target)) {
let targetOldUserSelect = modifiedElementMap.get(target) as string;
if (target.style.userSelect === 'none') {
target.style.userSelect = targetOldUserSelect;
}
if (target.getAttribute('style') === '') {
target.removeAttribute('style');
}
modifiedElementMap.delete(target);
}
}
}
@@ -0,0 +1,8 @@
var $16125922964febca$exports = {};
$16125922964febca$exports = {
"breadcrumbs": `Drobtine`
};
export {$16125922964febca$exports as default};
//# sourceMappingURL=sl-SI.module.js.map
@@ -0,0 +1,46 @@
/**
* Rule: no-promise-in-callback
* Discourage using promises inside of callbacks.
*/
'use strict'
const { getAncestors } = require('./lib/eslint-compat')
const getDocsUrl = require('./lib/get-docs-url')
const isPromise = require('./lib/is-promise')
const isInsideCallback = require('./lib/is-inside-callback')
module.exports = {
meta: {
type: 'suggestion',
docs: {
description: 'Disallow using promises inside of callbacks.',
url: getDocsUrl('no-promise-in-callback'),
},
schema: [],
messages: {
avoidPromiseInCallback: 'Avoid using promises inside of callbacks.',
},
},
create(context) {
return {
CallExpression(node) {
if (!isPromise(node)) return
// if i'm returning the promise, it's probably not really a callback
// function, and I should be okay....
if (node.parent.type === 'ReturnStatement') return
// what about if the parent is an ArrowFunctionExpression
// would that imply an implicit return?
if (getAncestors(context, node).some(isInsideCallback)) {
context.report({
node: node.callee,
messageId: 'avoidPromiseInCallback',
})
}
},
}
},
}
@@ -0,0 +1,90 @@
{
"name": "mdast-util-gfm-task-list-item",
"version": "2.0.0",
"description": "mdast extension to parse and serialize GFM task list items",
"license": "MIT",
"keywords": [
"unist",
"mdast",
"mdast-util",
"util",
"utility",
"markdown",
"markup",
"task",
"list",
"item",
"check",
"checkbox",
"todo",
"gfm"
],
"repository": "syntax-tree/mdast-util-gfm-task-list-item",
"bugs": "https://github.com/syntax-tree/mdast-util-gfm-task-list-item/issues",
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/unified"
},
"author": "Titus Wormer <tituswormer@gmail.com> (https://wooorm.com)",
"contributors": [
"Titus Wormer <tituswormer@gmail.com> (https://wooorm.com)"
],
"sideEffects": false,
"type": "module",
"exports": "./index.js",
"files": [
"lib/",
"index.d.ts",
"index.js"
],
"dependencies": {
"@types/mdast": "^4.0.0",
"devlop": "^1.0.0",
"mdast-util-from-markdown": "^2.0.0",
"mdast-util-to-markdown": "^2.0.0"
},
"devDependencies": {
"@types/node": "^20.0.0",
"c8": "^8.0.0",
"micromark-extension-gfm-task-list-item": "^2.0.0",
"prettier": "^2.0.0",
"remark-cli": "^11.0.0",
"remark-preset-wooorm": "^9.0.0",
"type-coverage": "^2.0.0",
"typescript": "^5.0.0",
"unist-util-remove-position": "^5.0.0",
"xo": "^0.54.0"
},
"scripts": {
"prepack": "npm run build && npm run format",
"build": "tsc --build --clean && tsc --build && type-coverage",
"format": "remark . -qfo && prettier . -w --loglevel warn && xo --fix",
"test-api-prod": "node --conditions production test.js",
"test-api-dev": "node --conditions development test.js",
"test-api": "npm run test-api-dev && npm run test-api-prod",
"test-coverage": "c8 --100 --reporter lcov npm run test-api",
"test": "npm run build && npm run format && npm run test-coverage"
},
"prettier": {
"bracketSpacing": false,
"semi": false,
"singleQuote": true,
"tabWidth": 2,
"trailingComma": "none",
"useTabs": false
},
"remarkConfig": {
"plugins": [
"remark-preset-wooorm"
]
},
"typeCoverage": {
"atLeast": 100,
"detail": true,
"ignoreCatch": true,
"strict": true
},
"xo": {
"prettier": true
}
}
@@ -0,0 +1,130 @@
"use strict";
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
Object.defineProperty(exports, "__esModule", { value: true });
exports.DetailContext = exports.NoopContext = exports.VError = void 0;
/**
* Error thrown by validation. Besides an informative message, it includes the path to the
* property which triggered the failure.
*/
var VError = /** @class */ (function (_super) {
__extends(VError, _super);
function VError(path, message) {
var _this = _super.call(this, message) || this;
_this.path = path;
// See https://github.com/Microsoft/TypeScript/wiki/Breaking-Changes#extending-built-ins-like-error-array-and-map-may-no-longer-work for info about this workaround.
Object.setPrototypeOf(_this, VError.prototype);
return _this;
}
return VError;
}(Error));
exports.VError = VError;
/**
* Fast implementation of IContext used for first-pass validation. If that fails, we can validate
* using DetailContext to collect error messages. That's faster for the common case when messages
* normally pass validation.
*/
var NoopContext = /** @class */ (function () {
function NoopContext() {
}
NoopContext.prototype.fail = function (relPath, message, score) {
return false;
};
NoopContext.prototype.unionResolver = function () { return this; };
NoopContext.prototype.createContext = function () { return this; };
NoopContext.prototype.resolveUnion = function (ur) { };
return NoopContext;
}());
exports.NoopContext = NoopContext;
/**
* Complete implementation of IContext that collects meaningfull errors.
*/
var DetailContext = /** @class */ (function () {
function DetailContext() {
// Stack of property names and associated messages for reporting helpful error messages.
this._propNames = [""];
this._messages = [null];
// Score is used to choose the best union member whose DetailContext to use for reporting.
// Higher score means better match (or rather less severe mismatch).
this._score = 0;
}
DetailContext.prototype.fail = function (relPath, message, score) {
this._propNames.push(relPath);
this._messages.push(message);
this._score += score;
return false;
};
DetailContext.prototype.unionResolver = function () {
return new DetailUnionResolver();
};
DetailContext.prototype.resolveUnion = function (unionResolver) {
var _a, _b;
var u = unionResolver;
var best = null;
for (var _i = 0, _c = u.contexts; _i < _c.length; _i++) {
var ctx = _c[_i];
if (!best || ctx._score >= best._score) {
best = ctx;
}
}
if (best && best._score > 0) {
(_a = this._propNames).push.apply(_a, best._propNames);
(_b = this._messages).push.apply(_b, best._messages);
}
};
DetailContext.prototype.getError = function (path) {
var msgParts = [];
for (var i = this._propNames.length - 1; i >= 0; i--) {
var p = this._propNames[i];
path += (typeof p === "number") ? "[" + p + "]" : (p ? "." + p : "");
var m = this._messages[i];
if (m) {
msgParts.push(path + " " + m);
}
}
return new VError(path, msgParts.join("; "));
};
DetailContext.prototype.getErrorDetail = function (path) {
var details = [];
for (var i = this._propNames.length - 1; i >= 0; i--) {
var p = this._propNames[i];
path += (typeof p === "number") ? "[" + p + "]" : (p ? "." + p : "");
var message = this._messages[i];
if (message) {
details.push({ path: path, message: message });
}
}
var detail = null;
for (var i = details.length - 1; i >= 0; i--) {
if (detail) {
details[i].nested = [detail];
}
detail = details[i];
}
return detail;
};
return DetailContext;
}());
exports.DetailContext = DetailContext;
var DetailUnionResolver = /** @class */ (function () {
function DetailUnionResolver() {
this.contexts = [];
}
DetailUnionResolver.prototype.createContext = function () {
var ctx = new DetailContext();
this.contexts.push(ctx);
return ctx;
};
return DetailUnionResolver;
}());
@@ -0,0 +1,3 @@
declare const isPatternNumeric: (pattern: string) => boolean;
export { isPatternNumeric };
@@ -0,0 +1,61 @@
/*!
* word-wrap <https://github.com/jonschlinkert/word-wrap>
*
* Copyright (c) 2014-2023, Jon Schlinkert.
* Released under the MIT License.
*/
function trimEnd(str) {
let lastCharPos = str.length - 1;
let lastChar = str[lastCharPos];
while(lastChar === ' ' || lastChar === '\t') {
lastChar = str[--lastCharPos];
}
return str.substring(0, lastCharPos + 1);
}
function trimTabAndSpaces(str) {
const lines = str.split('\n');
const trimmedLines = lines.map((line) => trimEnd(line));
return trimmedLines.join('\n');
}
module.exports = function(str, options) {
options = options || {};
if (str == null) {
return str;
}
var width = options.width || 50;
var indent = (typeof options.indent === 'string')
? options.indent
: ' ';
var newline = options.newline || '\n' + indent;
var escape = typeof options.escape === 'function'
? options.escape
: identity;
var regexString = '.{1,' + width + '}';
if (options.cut !== true) {
regexString += '([\\s\u200B]+|$)|[^\\s\u200B]+?([\\s\u200B]+|$)';
}
var re = new RegExp(regexString, 'g');
var lines = str.match(re) || [];
var result = indent + lines.map(function(line) {
if (line.slice(-1) === '\n') {
line = line.slice(0, line.length - 1);
}
return escape(line);
}).join(newline);
if (options.trim === true) {
result = trimTabAndSpaces(result);
}
return result;
};
function identity(str) {
return str;
}
@@ -0,0 +1,14 @@
'use strict';
/**
* Check if the first letter of a string is capitalized.
* @param {string} word String to check
* @returns {boolean} True if first letter is capitalized.
*/
module.exports = function isFirstLetterCapitalized(word) {
if (!word) {
return false;
}
const firstLetter = word.replace(/^_+/, '').charAt(0);
return firstLetter.toUpperCase() === firstLetter;
};
@@ -0,0 +1,21 @@
MIT License
Copyright (c) 2021 Natural Intelligence
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
@@ -0,0 +1,2 @@
export {};
//# sourceMappingURL=PluginManager.spec.d.ts.map
@@ -0,0 +1,43 @@
var escapeHtmlChar = require('./_escapeHtmlChar'),
toString = require('./toString');
/** Used to match HTML entities and HTML characters. */
var reUnescapedHtml = /[&<>"']/g,
reHasUnescapedHtml = RegExp(reUnescapedHtml.source);
/**
* Converts the characters "&", "<", ">", '"', and "'" in `string` to their
* corresponding HTML entities.
*
* **Note:** No other characters are escaped. To escape additional
* characters use a third-party library like [_he_](https://mths.be/he).
*
* Though the ">" character is escaped for symmetry, characters like
* ">" and "/" don't need escaping in HTML and have no special meaning
* unless they're part of a tag or unquoted attribute value. See
* [Mathias Bynens's article](https://mathiasbynens.be/notes/ambiguous-ampersands)
* (under "semi-related fun fact") for more details.
*
* When working with HTML you should always
* [quote attribute values](http://wonko.com/post/html-escaping) to reduce
* XSS vectors.
*
* @static
* @since 0.1.0
* @memberOf _
* @category String
* @param {string} [string=''] The string to escape.
* @returns {string} Returns the escaped string.
* @example
*
* _.escape('fred, barney, & pebbles');
* // => 'fred, barney, &amp; pebbles'
*/
function escape(string) {
string = toString(string);
return (string && reHasUnescapedHtml.test(string))
? string.replace(reUnescapedHtml, escapeHtmlChar)
: string;
}
module.exports = escape;
@@ -0,0 +1,143 @@
import { css, setup } from 'goober';
import * as React from 'react';
import {
resolveValue,
ToasterProps,
ToastPosition,
ToastWrapperProps,
} from '../core/types';
import { useToaster } from '../core/use-toaster';
import { prefersReducedMotion } from '../core/utils';
import { ToastBar } from './toast-bar';
setup(React.createElement);
const ToastWrapper = ({
id,
className,
style,
onHeightUpdate,
children,
}: ToastWrapperProps) => {
const ref = React.useCallback(
(el: HTMLElement | null) => {
if (el) {
const updateHeight = () => {
const height = el.getBoundingClientRect().height;
onHeightUpdate(id, height);
};
updateHeight();
new MutationObserver(updateHeight).observe(el, {
subtree: true,
childList: true,
characterData: true,
});
}
},
[id, onHeightUpdate]
);
return (
<div ref={ref} className={className} style={style}>
{children}
</div>
);
};
const getPositionStyle = (
position: ToastPosition,
offset: number
): React.CSSProperties => {
const top = position.includes('top');
const verticalStyle: React.CSSProperties = top ? { top: 0 } : { bottom: 0 };
const horizontalStyle: React.CSSProperties = position.includes('center')
? {
justifyContent: 'center',
}
: position.includes('right')
? {
justifyContent: 'flex-end',
}
: {};
return {
left: 0,
right: 0,
display: 'flex',
position: 'absolute',
transition: prefersReducedMotion()
? undefined
: `all 230ms cubic-bezier(.21,1.02,.73,1)`,
transform: `translateY(${offset * (top ? 1 : -1)}px)`,
...verticalStyle,
...horizontalStyle,
};
};
const activeClass = css`
z-index: 9999;
> * {
pointer-events: auto;
}
`;
const DEFAULT_OFFSET = 16;
export const Toaster: React.FC<ToasterProps> = ({
reverseOrder,
position = 'top-center',
toastOptions,
gutter,
children,
toasterId,
containerStyle,
containerClassName,
}) => {
const { toasts, handlers } = useToaster(toastOptions, toasterId);
return (
<div
data-rht-toaster={toasterId || ''}
style={{
position: 'fixed',
zIndex: 9999,
top: DEFAULT_OFFSET,
left: DEFAULT_OFFSET,
right: DEFAULT_OFFSET,
bottom: DEFAULT_OFFSET,
pointerEvents: 'none',
...containerStyle,
}}
className={containerClassName}
onMouseEnter={handlers.startPause}
onMouseLeave={handlers.endPause}
>
{toasts.map((t) => {
const toastPosition = t.position || position;
const offset = handlers.calculateOffset(t, {
reverseOrder,
gutter,
defaultPosition: position,
});
const positionStyle = getPositionStyle(toastPosition, offset);
return (
<ToastWrapper
id={t.id}
key={t.id}
onHeightUpdate={handlers.updateHeight}
className={t.visible ? activeClass : ''}
style={positionStyle}
>
{t.type === 'custom' ? (
resolveValue(t.message, t)
) : children ? (
children(t)
) : (
<ToastBar toast={t} position={toastPosition} />
)}
</ToastWrapper>
);
})}
</div>
);
};
@@ -0,0 +1 @@
module.exports={C:{"2":0.01458,"69":0.00486,"115":0.70971,"118":0.01458,"123":0.00486,"125":0.00486,"128":0.00486,"136":0.02431,"137":0.00486,"140":0.20902,"141":0.00486,"142":0.44235,"143":2.44994,"144":2.05134,_:"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 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 119 120 121 122 124 126 127 129 130 131 132 133 134 135 138 139 145 146 147 3.5 3.6"},D:{"27":0.00972,"32":0.00486,"39":0.00972,"40":0.00972,"41":0.00972,"42":0.00972,"43":0.01458,"44":0.01944,"45":0.00972,"46":0.01458,"47":0.01458,"48":0.00972,"49":0.00972,"50":0.00972,"51":0.00972,"52":0.01458,"53":0.00972,"54":0.01458,"55":0.00972,"56":0.02431,"57":0.01458,"58":0.02431,"59":0.01458,"60":0.00972,"75":0.00486,"76":0.03889,"85":0.00972,"91":0.00486,"99":0.01458,"101":0.00486,"103":0.04861,"108":0.00972,"109":0.20416,"112":0.00486,"114":0.00486,"116":0.02917,"120":0.02917,"121":0.00486,"122":0.10208,"124":0.00486,"125":8.39981,"126":0.03403,"127":0.03889,"128":0.06319,"129":0.00972,"130":0.02431,"131":0.00972,"132":0.10208,"133":0.01944,"134":0.0875,"135":0.02431,"136":0.04375,"137":0.49582,"138":0.36458,"139":0.30624,"140":3.63117,"141":9.26993,"142":0.17986,_:"4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 28 29 30 31 33 34 35 36 37 38 61 62 63 64 65 66 67 68 69 70 71 72 73 74 77 78 79 80 81 83 84 86 87 88 89 90 92 93 94 95 96 97 98 100 102 104 105 106 107 110 111 113 115 117 118 119 123 143 144 145"},F:{"36":0.01458,"63":0.00486,"67":0.00486,"95":0.01458,"120":0.01944,"121":0.03403,"122":0.31597,_:"9 11 12 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 60 62 64 65 66 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 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.00486,"100":0.06805,"109":0.03403,"113":0.00486,"124":0.00972,"131":0.00486,"133":0.01458,"134":0.00486,"135":0.00486,"137":0.00486,"138":0.00486,"139":0.05833,"140":1.2833,"141":6.30472,"142":0.00486,_:"12 13 14 15 16 17 79 80 81 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 101 102 103 104 105 106 107 108 110 111 112 114 115 116 117 118 119 120 121 122 123 125 126 127 128 129 130 132 136"},E:{_:"0 4 5 6 7 8 9 10 11 12 13 14 15 3.1 3.2 5.1 6.1 7.1 9.1 10.1 11.1 12.1 13.1 15.1 15.2-15.3 15.4 15.5 16.0 16.1 16.2 16.3 17.0 26.2","14.1":0.00972,"15.6":0.24305,"16.4":0.00486,"16.5":0.19444,"16.6":0.1118,"17.1":0.25763,"17.2":0.00972,"17.3":0.00972,"17.4":0.02917,"17.5":0.06319,"17.6":0.17014,"18.0":0.01458,"18.1":0.01458,"18.2":0.01944,"18.3":0.10694,"18.4":0.09722,"18.5-18.6":0.24305,"26.0":0.57846,"26.1":0.02917},G:{"8":0,"3.2":0,"4.0-4.1":0,"4.2-4.3":0.00252,"5.0-5.1":0,"6.0-6.1":0.01006,"7.0-7.1":0.00755,"8.1-8.4":0,"9.0-9.2":0,"9.3":0.02264,"10.0-10.2":0.00252,"10.3":0.04277,"11.0-11.2":0.63405,"11.3-11.4":0.0151,"12.0-12.1":0.00503,"12.2-12.5":0.12329,"13.0-13.1":0,"13.2":0.01258,"13.3":0.00503,"13.4-13.7":0.02013,"14.0-14.4":0.04277,"14.5-14.8":0.04529,"15.0-15.1":0.04277,"15.2-15.3":0.03271,"15.4":0.03774,"15.5":0.04277,"15.6-15.8":0.55856,"16.0":0.07548,"16.1":0.1409,"16.2":0.07297,"16.3":0.13083,"16.4":0.03271,"16.5":0.05787,"16.6-16.7":0.74727,"17.0":0.05284,"17.1":0.08051,"17.2":0.05787,"17.3":0.08555,"17.4":0.15096,"17.5":0.25915,"17.6-17.7":0.65417,"18.0":0.14845,"18.1":0.30696,"18.2":0.16606,"18.3":0.5334,"18.4":0.27425,"18.5-18.6":13.98423,"26.0":1.72853,"26.1":0.0629},P:{"4":0.01051,"24":0.03152,"25":0.01051,"26":0.02102,"27":0.04203,"28":2.88966,"29":0.25219,_:"20 21 22 23 5.0-5.4 8.2 9.2 10.1 11.1-11.2 12.0 13.0 14.0 15.0 16.0 17.0 18.0 19.0","6.2-6.4":0.01051,"7.2-7.4":0.02102},I:{"0":0.01026,"3":0,"4":0,"2.1":0,"2.2":0,"2.3":0,"4.1":0,"4.2-4.3":0,"4.4":0,"4.4.3-4.4.4":0.00001},K:{"0":0.26723,_:"10 11 12 11.1 11.5 12.1"},A:{"11":0.07292,_:"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.33917},Q:{_:"14.9"},O:{"0":0.05139},H:{"0":0},L:{"0":24.63679}};
@@ -0,0 +1 @@
{"version":3,"file":"verifySignature.d.ts","sourceRoot":"","sources":["../../src/helpers/verifySignature.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAiB,MAAM,WAAW,CAAC;AAInD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAErD;;GAEG;AACH,wBAAgB,eAAe,CAAC,IAAI,EAAE;IACpC,SAAS,EAAE,WAAW,CAAC;IACvB,IAAI,EAAE,WAAW,CAAC;IAClB,mBAAmB,CAAC,EAAE,WAAW,CAAC;IAClC,eAAe,CAAC,EAAE,WAAW,CAAC;IAC9B,aAAa,CAAC,EAAE,OAAO,CAAC;CACzB,GAAG,OAAO,CAAC,OAAO,CAAC,CAmCnB;AAED;;;GAGG;AACH,eAAO,MAAM,yBAAyB;sBAClB,OAAO,CAAC,OAAO,CAAC;CACnC,CAAC"}
@@ -0,0 +1,175 @@
/*
* Copyright 2022 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 $6818b1c4fc67028d$export$1994a077b98ee0d5(width) {
return width != null && (!isNaN(width) || String(width).match(/^(\d+)(?=%$)/) !== null);
}
function $6818b1c4fc67028d$export$9078bad4c3934604(width) {
if (!width || typeof width === 'number') return 1;
let match = width.match(/^(.+)(?=fr$)/);
// if width is the incorrect format, just default it to a 1fr
if (!match) {
if (process.env.NODE_ENV !== 'production') console.warn(`width: ${width} is not a supported format, width should be a number (ex. 150), percentage (ex. '50%') or fr unit (ex. '2fr')`, 'defaulting to \'1fr\'');
return 1;
}
return parseFloat(match[0]);
}
function $6818b1c4fc67028d$export$7bbad27896f7ae9f(width, tableWidth) {
if (typeof width === 'string') {
let match = width.match(/^(\d+)(?=%$)/);
if (!match) throw new Error('Only percentages or numbers are supported for static column widths');
return tableWidth * (parseFloat(match[0]) / 100);
}
return width;
}
function $6818b1c4fc67028d$export$59185c62a7544aa0(maxWidth, tableWidth) {
return maxWidth != null ? $6818b1c4fc67028d$export$7bbad27896f7ae9f(maxWidth, tableWidth) : Number.MAX_SAFE_INTEGER;
}
function $6818b1c4fc67028d$export$f556054ce4358701(minWidth, tableWidth) {
return minWidth != null ? $6818b1c4fc67028d$export$7bbad27896f7ae9f(minWidth, tableWidth) : 0;
}
function $6818b1c4fc67028d$export$55d50dc687385491(availableWidth, columns, changedColumns, getDefaultWidth, getDefaultMinWidth) {
let hasNonFrozenItems = false;
let flexItems = columns.map((column, index)=>{
var _changedColumns_get, _column_width, _ref, _ref1;
let width = changedColumns.get(column.key) != null ? (_changedColumns_get = changedColumns.get(column.key)) !== null && _changedColumns_get !== void 0 ? _changedColumns_get : '1fr' : (_ref1 = (_ref = (_column_width = column.width) !== null && _column_width !== void 0 ? _column_width : column.defaultWidth) !== null && _ref !== void 0 ? _ref : getDefaultWidth === null || getDefaultWidth === void 0 ? void 0 : getDefaultWidth(index)) !== null && _ref1 !== void 0 ? _ref1 : '1fr';
let frozen = false;
let baseSize = 0;
let flex = 0;
let targetMainSize = 0;
if ($6818b1c4fc67028d$export$1994a077b98ee0d5(width)) {
baseSize = $6818b1c4fc67028d$export$7bbad27896f7ae9f(width, availableWidth);
frozen = true;
} else {
flex = $6818b1c4fc67028d$export$9078bad4c3934604(width);
if (flex <= 0) frozen = true;
}
var _column_minWidth, _ref2;
let min = $6818b1c4fc67028d$export$f556054ce4358701((_ref2 = (_column_minWidth = column.minWidth) !== null && _column_minWidth !== void 0 ? _column_minWidth : getDefaultMinWidth === null || getDefaultMinWidth === void 0 ? void 0 : getDefaultMinWidth(index)) !== null && _ref2 !== void 0 ? _ref2 : 0, availableWidth);
let max = $6818b1c4fc67028d$export$59185c62a7544aa0(column.maxWidth, availableWidth);
let hypotheticalMainSize = Math.max(min, Math.min(baseSize, max));
// 9.7.1
// We don't make use of flex basis, it's always 0, so we are always in 'grow' mode.
// 9.7.2
if (frozen) targetMainSize = hypotheticalMainSize;
else if (baseSize > hypotheticalMainSize) {
frozen = true;
targetMainSize = hypotheticalMainSize;
}
// 9.7.3
if (!frozen) hasNonFrozenItems = true;
return {
frozen: frozen,
baseSize: baseSize,
hypotheticalMainSize: hypotheticalMainSize,
min: min,
max: max,
flex: flex,
targetMainSize: targetMainSize,
violation: 0
};
});
// 9.7.4
// 9.7.4.a
while(hasNonFrozenItems){
// 9.7.4.b
/**
* Calculate the remaining free space as for initial free space,
* above (9.7.3). If the sum of the unfrozen flex items’ flex factors is
* less than one, multiply the initial free space by this sum (of flex factors).
* If the magnitude of this value is less than the magnitude of
* the remaining free space, use this as the remaining free space.
*/ let usedWidth = 0;
let flexFactors = 0;
flexItems.forEach((item)=>{
if (item.frozen) usedWidth += item.targetMainSize;
else {
usedWidth += item.baseSize;
flexFactors += item.flex;
}
});
let remainingFreeSpace = availableWidth - usedWidth;
// we only support integer FR's, and because of hasNonFrozenItems, we know that flexFactors > 0
// so no need to check for flexFactors < 1
// 9.7.4.c
/**
* If the remaining free space is zero
* - Do nothing.
* Else // remember, we're always in grow mode
* - Find the ratio of the item’s flex grow factor to the
* sum of the flex grow factors of all unfrozen items on
* the line. Set the item’s target main size to its flex
* base size plus a fraction of the remaining free space
* proportional to the ratio.
*/ if (remainingFreeSpace > 0) flexItems.forEach((item)=>{
if (!item.frozen) {
let ratio = item.flex / flexFactors;
item.targetMainSize = item.baseSize + ratio * remainingFreeSpace;
}
});
// 9.7.4.d
/**
* Fix min/max violations. Clamp each non-frozen item’s
* target main size by its used min and max main sizes
* and floor its content-box size at zero. If the item’s
* target main size was made smaller by this, it’s a max
* violation. If the item’s target main size was made
* larger by this, it’s a min violation.
*/ let totalViolation = 0;
flexItems.forEach((item)=>{
item.violation = 0;
if (!item.frozen) {
let { min: min, max: max, targetMainSize: targetMainSize } = item;
item.targetMainSize = Math.max(min, Math.min(targetMainSize, max));
item.violation = item.targetMainSize - targetMainSize;
totalViolation += item.violation;
}
});
// 9.7.4.e
/**
* Freeze over-flexed items. The total violation is the
* sum of the adjustments from the previous step
* ∑(clamped size - unclamped size). If the total violation is:
* Zero
* - Freeze all items.
*
* Positive
* - Freeze all the items with min violations.
*
* Negative
* - Freeze all the items with max violations.
*/ hasNonFrozenItems = false;
flexItems.forEach((item)=>{
if (totalViolation === 0 || Math.sign(totalViolation) === Math.sign(item.violation)) item.frozen = true;
else if (!item.frozen) hasNonFrozenItems = true;
});
}
return $6818b1c4fc67028d$var$cascadeRounding(flexItems);
}
function $6818b1c4fc67028d$var$cascadeRounding(flexItems) {
/*
Given an array of floats that sum to an integer, this rounds the floats
and returns an array of integers with the same sum.
*/ let fpTotal = 0;
let intTotal = 0;
let roundedArray = [];
flexItems.forEach(function(item) {
let float = item.targetMainSize;
let integer = Math.round(float + fpTotal) - intTotal;
fpTotal += float;
intTotal += integer;
roundedArray.push(integer);
});
return roundedArray;
}
export {$6818b1c4fc67028d$export$1994a077b98ee0d5 as isStatic, $6818b1c4fc67028d$export$9078bad4c3934604 as parseFractionalUnit, $6818b1c4fc67028d$export$7bbad27896f7ae9f as parseStaticWidth, $6818b1c4fc67028d$export$59185c62a7544aa0 as getMaxWidth, $6818b1c4fc67028d$export$f556054ce4358701 as getMinWidth, $6818b1c4fc67028d$export$55d50dc687385491 as calculateColumnSizes};
//# sourceMappingURL=TableUtils.module.js.map
@@ -0,0 +1 @@
{"version":3,"file":"jsx-handler-names.d.ts","sourceRoot":"","sources":["jsx-handler-names.js"],"names":[],"mappings":"wBA6BW,OAAO,QAAQ,EAAE,IAAI,CAAC,UAAU"}
@@ -0,0 +1,99 @@
{
"name": "is-date-object",
"version": "1.1.0",
"author": "Jordan Harband",
"funding": {
"url": "https://github.com/sponsors/ljharb"
},
"description": "Is this value a JS Date object? This module works cross-realm/iframe, and despite ES6 @@toStringTag.",
"license": "MIT",
"main": "index.js",
"exports": {
".": "./index.js",
"./package.json": "./package.json"
},
"sideEffects": false,
"scripts": {
"prepack": "npmignore --auto --commentLines=autogenerated",
"prepublishOnly": "safe-publish-latest",
"prepublish": "not-in-publish || npm run prepublishOnly",
"pretest": "npm run lint",
"test": "npm run tests-only && npm run test:corejs",
"tests-only": "nyc tape 'test/**/*.js'",
"test:corejs": "nyc tape test-corejs.js",
"posttest": "npx npm@'>= 10.2' audit --production",
"lint": "eslint --ext=js,mjs .",
"postlint": "tsc && attw -P",
"version": "auto-changelog && git add CHANGELOG.md",
"postversion": "auto-changelog && git add CHANGELOG.md && git commit --no-edit --amend && git tag -f \"v$(node -e \"console.log(require('./package.json').version)\")\""
},
"repository": {
"type": "git",
"url": "git://github.com/inspect-js/is-date-object.git"
},
"keywords": [
"Date",
"ES6",
"toStringTag",
"@@toStringTag",
"Date object"
],
"dependencies": {
"call-bound": "^1.0.2",
"has-tostringtag": "^1.0.2"
},
"devDependencies": {
"@arethetypeswrong/cli": "^0.17.1",
"@ljharb/eslint-config": "^21.1.1",
"@ljharb/tsconfig": "^0.2.2",
"@types/core-js": "^2.5.8",
"@types/tape": "^5.6.5",
"auto-changelog": "^2.5.0",
"core-js": "^3.39.0",
"encoding": "^0.1.13",
"eslint": "=8.8.0",
"in-publish": "^2.0.1",
"indexof": "^0.0.1",
"is": "^3.3.0",
"npmignore": "^0.3.1",
"nyc": "^10.3.2",
"safe-publish-latest": "^2.0.0",
"tape": "^5.9.0",
"typescript": "^5.8.0-dev.20241212"
},
"testling": {
"files": "test/index.js",
"browsers": [
"iexplore/6.0..latest",
"firefox/3.0..6.0",
"firefox/15.0..latest",
"firefox/nightly",
"chrome/4.0..10.0",
"chrome/20.0..latest",
"chrome/canary",
"opera/10.0..latest",
"opera/next",
"safari/4.0..latest",
"ipad/6.0..latest",
"iphone/6.0..latest",
"android-browser/4.2"
]
},
"engines": {
"node": ">= 0.4"
},
"auto-changelog": {
"output": "CHANGELOG.md",
"template": "keepachangelog",
"unreleased": false,
"commitLimit": false,
"backfillLimit": false,
"hideCredit": true
},
"publishConfig": {
"ignore": [
".github/workflows",
"test-corejs.js"
]
}
}
@@ -0,0 +1,11 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.DEPRECATED_ALIASES = void 0;
const DEPRECATED_ALIASES = exports.DEPRECATED_ALIASES = {
ModuleDeclaration: "ImportOrExportDeclaration"
};
//# sourceMappingURL=deprecated-aliases.js.map
@@ -0,0 +1,394 @@
import { createApi } from '@reduxjs/toolkit/query/react'
import {
act,
getByTestId,
render,
screen,
waitFor,
} from '@testing-library/react'
import { delay } from 'msw'
import { vi } from 'vitest'
import { setupApiStore } from '../../tests/utils/helpers'
describe('fixedCacheKey', () => {
const onNewCacheEntry = vi.fn()
const api = createApi({
async baseQuery(arg: string | Promise<string>) {
return { data: await arg }
},
endpoints: (build) => ({
send: build.mutation<string, string | Promise<string>>({
query: (arg) => arg,
}),
}),
})
const storeRef = setupApiStore(api)
function Component({
name,
fixedCacheKey,
value = name,
}: {
name: string
fixedCacheKey?: string
value?: string | Promise<string>
}) {
const [trigger, result] = api.endpoints.send.useMutation({ fixedCacheKey })
return (
<div data-testid={name}>
<div data-testid="status">{result.status}</div>
<div data-testid="data">{result.data}</div>
<div data-testid="originalArgs">{String(result.originalArgs)}</div>
<button data-testid="trigger" onClick={() => trigger(value)}>
trigger
</button>
<button data-testid="reset" onClick={result.reset}>
reset
</button>
</div>
)
}
test('two mutations without `fixedCacheKey` do not influence each other', async () => {
render(
<>
<Component name="C1" />
<Component name="C2" />
</>,
{ wrapper: storeRef.wrapper },
)
const c1 = screen.getByTestId('C1')
const c2 = screen.getByTestId('C2')
expect(getByTestId(c1, 'status').textContent).toBe('uninitialized')
expect(getByTestId(c2, 'status').textContent).toBe('uninitialized')
act(() => {
getByTestId(c1, 'trigger').click()
})
await waitFor(() =>
expect(getByTestId(c1, 'status').textContent).toBe('fulfilled'),
)
expect(getByTestId(c1, 'data').textContent).toBe('C1')
expect(getByTestId(c2, 'status').textContent).toBe('uninitialized')
})
test('two mutations with the same `fixedCacheKey` do influence each other', async () => {
render(
<>
<Component name="C1" fixedCacheKey="test" />
<Component name="C2" fixedCacheKey="test" />
</>,
{ wrapper: storeRef.wrapper },
)
const c1 = screen.getByTestId('C1')
const c2 = screen.getByTestId('C2')
expect(getByTestId(c1, 'status').textContent).toBe('uninitialized')
expect(getByTestId(c2, 'status').textContent).toBe('uninitialized')
act(() => {
getByTestId(c1, 'trigger').click()
})
await waitFor(() => {
expect(getByTestId(c1, 'status').textContent).toBe('fulfilled')
expect(getByTestId(c1, 'data').textContent).toBe('C1')
expect(getByTestId(c2, 'status').textContent).toBe('fulfilled')
expect(getByTestId(c2, 'data').textContent).toBe('C1')
})
// test reset from the other component
act(() => {
getByTestId(c2, 'reset').click()
})
await waitFor(() => {
expect(getByTestId(c1, 'status').textContent).toBe('uninitialized')
expect(getByTestId(c1, 'data').textContent).toBe('')
expect(getByTestId(c2, 'status').textContent).toBe('uninitialized')
expect(getByTestId(c2, 'data').textContent).toBe('')
})
})
test('resetting from the component that triggered the mutation resets for each shared result', async () => {
render(
<>
<Component name="C1" fixedCacheKey="test-A" />
<Component name="C2" fixedCacheKey="test-A" />
<Component name="C3" fixedCacheKey="test-B" />
<Component name="C4" fixedCacheKey="test-B" />
</>,
{ wrapper: storeRef.wrapper },
)
const c1 = screen.getByTestId('C1')
const c2 = screen.getByTestId('C2')
const c3 = screen.getByTestId('C3')
const c4 = screen.getByTestId('C4')
expect(getByTestId(c1, 'status').textContent).toBe('uninitialized')
expect(getByTestId(c2, 'status').textContent).toBe('uninitialized')
expect(getByTestId(c3, 'status').textContent).toBe('uninitialized')
expect(getByTestId(c4, 'status').textContent).toBe('uninitialized')
// trigger with a component using the first cache key
act(() => {
getByTestId(c1, 'trigger').click()
})
await waitFor(() =>
expect(getByTestId(c1, 'status').textContent).toBe('fulfilled'),
)
// the components with the first cache key should be affected
expect(getByTestId(c1, 'data').textContent).toBe('C1')
expect(getByTestId(c2, 'status').textContent).toBe('fulfilled')
expect(getByTestId(c2, 'data').textContent).toBe('C1')
expect(getByTestId(c2, 'status').textContent).toBe('fulfilled')
// the components with the second cache key should be unaffected
expect(getByTestId(c3, 'data').textContent).toBe('')
expect(getByTestId(c3, 'status').textContent).toBe('uninitialized')
expect(getByTestId(c4, 'data').textContent).toBe('')
expect(getByTestId(c4, 'status').textContent).toBe('uninitialized')
// trigger with a component using the second cache key
act(() => {
getByTestId(c3, 'trigger').click()
})
await waitFor(() =>
expect(getByTestId(c3, 'status').textContent).toBe('fulfilled'),
)
// the components with the first cache key should be unaffected
await waitFor(() => {
expect(getByTestId(c1, 'data').textContent).toBe('C1')
expect(getByTestId(c2, 'status').textContent).toBe('fulfilled')
expect(getByTestId(c2, 'data').textContent).toBe('C1')
expect(getByTestId(c2, 'status').textContent).toBe('fulfilled')
// the component with the second cache key should be affected
expect(getByTestId(c3, 'data').textContent).toBe('C3')
expect(getByTestId(c3, 'status').textContent).toBe('fulfilled')
expect(getByTestId(c4, 'data').textContent).toBe('C3')
expect(getByTestId(c4, 'status').textContent).toBe('fulfilled')
})
// test reset from the component that triggered the mutation for the first cache key
act(() => {
getByTestId(c1, 'reset').click()
})
await waitFor(() => {
// the components with the first cache key should be affected
expect(getByTestId(c1, 'data').textContent).toBe('')
expect(getByTestId(c1, 'status').textContent).toBe('uninitialized')
expect(getByTestId(c2, 'data').textContent).toBe('')
expect(getByTestId(c2, 'status').textContent).toBe('uninitialized')
// the components with the second cache key should be unaffected
expect(getByTestId(c3, 'data').textContent).toBe('C3')
expect(getByTestId(c3, 'status').textContent).toBe('fulfilled')
expect(getByTestId(c4, 'data').textContent).toBe('C3')
expect(getByTestId(c4, 'status').textContent).toBe('fulfilled')
})
})
test('two mutations with different `fixedCacheKey` do not influence each other', async () => {
render(
<>
<Component name="C1" fixedCacheKey="test" />
<Component name="C2" fixedCacheKey="toast" />
</>,
{ wrapper: storeRef.wrapper },
)
const c1 = screen.getByTestId('C1')
const c2 = screen.getByTestId('C2')
expect(getByTestId(c1, 'status').textContent).toBe('uninitialized')
expect(getByTestId(c2, 'status').textContent).toBe('uninitialized')
act(() => {
getByTestId(c1, 'trigger').click()
})
await waitFor(() =>
expect(getByTestId(c1, 'status').textContent).toBe('fulfilled'),
)
expect(getByTestId(c1, 'data').textContent).toBe('C1')
expect(getByTestId(c2, 'status').textContent).toBe('uninitialized')
})
test('unmounting and remounting keeps data intact', async () => {
const { rerender } = render(<Component name="C1" fixedCacheKey="test" />, {
wrapper: storeRef.wrapper,
})
let c1 = screen.getByTestId('C1')
expect(getByTestId(c1, 'status').textContent).toBe('uninitialized')
act(() => {
getByTestId(c1, 'trigger').click()
})
await waitFor(() =>
expect(getByTestId(c1, 'status').textContent).toBe('fulfilled'),
)
expect(getByTestId(c1, 'data').textContent).toBe('C1')
rerender(<div />)
expect(screen.queryByTestId('C1')).toBe(null)
rerender(<Component name="C1" fixedCacheKey="test" />)
c1 = screen.getByTestId('C1')
expect(getByTestId(c1, 'status').textContent).toBe('fulfilled')
expect(getByTestId(c1, 'data').textContent).toBe('C1')
})
test('(limitation) mutations using `fixedCacheKey` do not return `originalArgs`', async () => {
render(
<>
<Component name="C1" fixedCacheKey="test" />
<Component name="C2" fixedCacheKey="test" />
</>,
{ wrapper: storeRef.wrapper },
)
const c1 = screen.getByTestId('C1')
const c2 = screen.getByTestId('C2')
expect(getByTestId(c1, 'status').textContent).toBe('uninitialized')
expect(getByTestId(c2, 'status').textContent).toBe('uninitialized')
act(() => {
getByTestId(c1, 'trigger').click()
})
await waitFor(() =>
expect(getByTestId(c1, 'status').textContent).toBe('fulfilled'),
)
expect(getByTestId(c1, 'data').textContent).toBe('C1')
expect(getByTestId(c2, 'status').textContent).toBe('fulfilled')
expect(getByTestId(c2, 'data').textContent).toBe('C1')
})
test('a component without `fixedCacheKey` has `originalArgs`', async () => {
render(<Component name="C1" />, {
wrapper: storeRef.wrapper,
})
let c1 = screen.getByTestId('C1')
expect(getByTestId(c1, 'status').textContent).toBe('uninitialized')
expect(getByTestId(c1, 'originalArgs').textContent).toBe('undefined')
await act(async () => {
getByTestId(c1, 'trigger').click()
await Promise.resolve()
})
expect(getByTestId(c1, 'originalArgs').textContent).toBe('C1')
})
test('a component with `fixedCacheKey` does never have `originalArgs`', async () => {
render(<Component name="C1" fixedCacheKey="test" />, {
wrapper: storeRef.wrapper,
})
let c1 = screen.getByTestId('C1')
expect(getByTestId(c1, 'status').textContent).toBe('uninitialized')
expect(getByTestId(c1, 'originalArgs').textContent).toBe('undefined')
await act(async () => {
getByTestId(c1, 'trigger').click()
})
expect(getByTestId(c1, 'originalArgs').textContent).toBe('undefined')
})
test('using `fixedCacheKey` will always use the latest dispatched thunk, prevent races', async () => {
let resolve1: (str: string) => void, resolve2: (str: string) => void
const p1 = new Promise<string>((resolve) => {
resolve1 = resolve
})
const p2 = new Promise<string>((resolve) => {
resolve2 = resolve
})
render(
<>
<Component name="C1" fixedCacheKey="test" value={p1} />
<Component name="C2" fixedCacheKey="test" value={p2} />
</>,
{ wrapper: storeRef.wrapper },
)
const c1 = screen.getByTestId('C1')
const c2 = screen.getByTestId('C2')
expect(getByTestId(c1, 'status').textContent).toBe('uninitialized')
expect(getByTestId(c2, 'status').textContent).toBe('uninitialized')
await act(async () => {
getByTestId(c1, 'trigger').click()
await Promise.resolve()
})
expect(getByTestId(c1, 'status').textContent).toBe('pending')
expect(getByTestId(c1, 'data').textContent).toBe('')
act(() => {
getByTestId(c2, 'trigger').click()
})
expect(getByTestId(c1, 'status').textContent).toBe('pending')
expect(getByTestId(c1, 'data').textContent).toBe('')
await act(async () => {
resolve1!('this should not show up any more')
await Promise.resolve()
})
await delay(150)
expect(getByTestId(c1, 'status').textContent).toBe('pending')
expect(getByTestId(c1, 'data').textContent).toBe('')
await act(async () => {
resolve2!('this should be visible')
await Promise.resolve()
})
await delay(150)
expect(getByTestId(c1, 'status').textContent).toBe('fulfilled')
expect(getByTestId(c1, 'data').textContent).toBe('this should be visible')
})
test('using fixedCacheKey should create a new cache entry', async () => {
api.enhanceEndpoints({
endpoints: {
send: {
onCacheEntryAdded: (arg) => onNewCacheEntry(arg),
},
},
})
render(<Component name="C1" fixedCacheKey={'testKey'} />, {
wrapper: storeRef.wrapper,
})
let c1 = screen.getByTestId('C1')
expect(getByTestId(c1, 'status').textContent).toBe('uninitialized')
expect(getByTestId(c1, 'originalArgs').textContent).toBe('undefined')
await act(async () => {
getByTestId(c1, 'trigger').click()
await Promise.resolve()
})
expect(onNewCacheEntry).toHaveBeenCalledWith('C1')
api.enhanceEndpoints({
endpoints: {
send: {
onCacheEntryAdded: undefined,
},
},
})
})
})
@@ -0,0 +1,3 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=ManagedClassElementMetadata.js.map
@@ -0,0 +1,87 @@
/**
* Splits an input string into lexical tokens, i.e. smaller strings that are
* easily identifiable by `tokens.tokenType()`.
*
* Lexing starts always in a "stream" context. Incomplete input may be buffered
* until a complete token can be emitted.
*
* In addition to slices of the original input, the following control characters
* may also be emitted:
*
* - `\x02` (Start of Text): A document starts with the next token
* - `\x18` (Cancel): Unexpected end of flow-mode (indicates an error)
* - `\x1f` (Unit Separator): Next token is a scalar value
* - `\u{FEFF}` (Byte order mark): Emitted separately outside documents
*/
export declare class Lexer {
/**
* Flag indicating whether the end of the current buffer marks the end of
* all input
*/
private atEnd;
/**
* Explicit indent set in block scalar header, as an offset from the current
* minimum indent, so e.g. set to 1 from a header `|2+`. Set to -1 if not
* explicitly set.
*/
private blockScalarIndent;
/**
* Block scalars that include a + (keep) chomping indicator in their header
* include trailing empty lines, which are otherwise excluded from the
* scalar's contents.
*/
private blockScalarKeep;
/** Current input */
private buffer;
/**
* Flag noting whether the map value indicator : can immediately follow this
* node within a flow context.
*/
private flowKey;
/** Count of surrounding flow collection levels. */
private flowLevel;
/**
* Minimum level of indentation required for next lines to be parsed as a
* part of the current scalar value.
*/
private indentNext;
/** Indentation level of the current line. */
private indentValue;
/** Position of the next \n character. */
private lineEndPos;
/** Stores the state of the lexer if reaching the end of incpomplete input */
private next;
/** A pointer to `buffer`; the current position of the lexer. */
private pos;
/**
* Generate YAML tokens from the `source` string. If `incomplete`,
* a part of the last line may be left as a buffer for the next call.
*
* @returns A generator of lexical tokens
*/
lex(source: string, incomplete?: boolean): Generator<string, void>;
private atLineEnd;
private charAt;
private continueScalar;
private getLine;
private hasChars;
private setNext;
private peek;
private parseNext;
private parseStream;
private parseLineStart;
private parseBlockStart;
private parseDocument;
private parseFlowCollection;
private parseQuotedScalar;
private parseBlockScalarHeader;
private parseBlockScalar;
private parsePlainScalar;
private pushCount;
private pushToIndex;
private pushIndicators;
private pushTag;
private pushNewline;
private pushSpaces;
private pushUntil;
}
@@ -0,0 +1,103 @@
import $4stjr$intlStringsmodulejs from "./intlStrings.mjs";
import {announce as $4stjr$announce} from "@react-aria/live-announcer";
import {useEffectEvent as $4stjr$useEffectEvent, useUpdateEffect as $4stjr$useUpdateEffect} from "@react-aria/utils";
import {useLocalizedStringFormatter as $4stjr$useLocalizedStringFormatter} from "@react-aria/i18n";
import {useRef as $4stjr$useRef} from "react";
function $parcel$interopDefault(a) {
return a && a.__esModule ? a.default : a;
}
/*
* Copyright 2022 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 $92599c3fd427b763$export$137e594ef3218a10(props, state) {
let { getRowText: getRowText = (key)=>{
var _state_collection_getTextValue, _state_collection, _state_collection_getItem;
var _state_collection_getTextValue1;
return (_state_collection_getTextValue1 = (_state_collection_getTextValue = (_state_collection = state.collection).getTextValue) === null || _state_collection_getTextValue === void 0 ? void 0 : _state_collection_getTextValue.call(_state_collection, key)) !== null && _state_collection_getTextValue1 !== void 0 ? _state_collection_getTextValue1 : (_state_collection_getItem = state.collection.getItem(key)) === null || _state_collection_getItem === void 0 ? void 0 : _state_collection_getItem.textValue;
} } = props;
let stringFormatter = (0, $4stjr$useLocalizedStringFormatter)((0, ($parcel$interopDefault($4stjr$intlStringsmodulejs))), '@react-aria/grid');
// Many screen readers do not announce when items in a grid are selected/deselected.
// We do this using an ARIA live region.
let selection = state.selectionManager.rawSelection;
let lastSelection = (0, $4stjr$useRef)(selection);
let announceSelectionChange = (0, $4stjr$useEffectEvent)(()=>{
var _lastSelection_current;
if (!state.selectionManager.isFocused || selection === lastSelection.current) {
lastSelection.current = selection;
return;
}
let addedKeys = $92599c3fd427b763$var$diffSelection(selection, lastSelection.current);
let removedKeys = $92599c3fd427b763$var$diffSelection(lastSelection.current, selection);
// If adding or removing a single row from the selection, announce the name of that item.
let isReplace = state.selectionManager.selectionBehavior === 'replace';
let messages = [];
if (state.selectionManager.selectedKeys.size === 1 && isReplace) {
let firstKey = state.selectionManager.selectedKeys.keys().next().value;
if (firstKey != null && state.collection.getItem(firstKey)) {
let currentSelectionText = getRowText(firstKey);
if (currentSelectionText) messages.push(stringFormatter.format('selectedItem', {
item: currentSelectionText
}));
}
} else if (addedKeys.size === 1 && removedKeys.size === 0) {
let firstKey = addedKeys.keys().next().value;
if (firstKey != null) {
let addedText = getRowText(firstKey);
if (addedText) messages.push(stringFormatter.format('selectedItem', {
item: addedText
}));
}
} else if (removedKeys.size === 1 && addedKeys.size === 0) {
let firstKey = removedKeys.keys().next().value;
if (firstKey != null && state.collection.getItem(firstKey)) {
let removedText = getRowText(firstKey);
if (removedText) messages.push(stringFormatter.format('deselectedItem', {
item: removedText
}));
}
}
// Announce how many items are selected, except when selecting the first item.
if (state.selectionManager.selectionMode === 'multiple') {
if (messages.length === 0 || selection === 'all' || selection.size > 1 || lastSelection.current === 'all' || ((_lastSelection_current = lastSelection.current) === null || _lastSelection_current === void 0 ? void 0 : _lastSelection_current.size) > 1) messages.push(selection === 'all' ? stringFormatter.format('selectedAll') : stringFormatter.format('selectedCount', {
count: selection.size
}));
}
if (messages.length > 0) (0, $4stjr$announce)(messages.join(' '));
lastSelection.current = selection;
});
(0, $4stjr$useUpdateEffect)(()=>{
if (state.selectionManager.isFocused) announceSelectionChange();
else {
// Wait a frame in case the collection is about to become focused (e.g. on mouse down).
let raf = requestAnimationFrame(announceSelectionChange);
return ()=>cancelAnimationFrame(raf);
}
}, [
selection,
state.selectionManager.isFocused
]);
}
function $92599c3fd427b763$var$diffSelection(a, b) {
let res = new Set();
if (a === 'all' || b === 'all') return res;
for (let key of a.keys())if (!b.has(key)) res.add(key);
return res;
}
export {$92599c3fd427b763$export$137e594ef3218a10 as useGridSelectionAnnouncement};
//# sourceMappingURL=useGridSelectionAnnouncement.module.js.map
@@ -0,0 +1,105 @@
'use strict';
var utils = require('../utils.js');
require('eslint-visitor-keys');
require('espree');
require('estraverse');
var templateCurlySpacing = utils.createRule({
name: "template-curly-spacing",
package: "js",
meta: {
type: "layout",
docs: {
description: "Require or disallow spacing around embedded expressions of template strings"
},
fixable: "whitespace",
schema: [
{
type: "string",
enum: ["always", "never"]
}
],
messages: {
expectedBefore: "Expected space(s) before '}'.",
expectedAfter: "Expected space(s) after '${'.",
unexpectedBefore: "Unexpected space(s) before '}'.",
unexpectedAfter: "Unexpected space(s) after '${'."
}
},
create(context) {
const sourceCode = context.sourceCode;
const always = context.options[0] === "always";
function checkSpacingBefore(token) {
if (!token.value.startsWith("}"))
return;
const prevToken = sourceCode.getTokenBefore(token, { includeComments: true });
const hasSpace = sourceCode.isSpaceBetween(prevToken, token);
if (!utils.isTokenOnSameLine(prevToken, token))
return;
if (always && !hasSpace) {
context.report({
loc: {
start: token.loc.start,
end: {
line: token.loc.start.line,
column: token.loc.start.column + 1
}
},
messageId: "expectedBefore",
fix: (fixer) => fixer.insertTextBefore(token, " ")
});
}
if (!always && hasSpace) {
context.report({
loc: {
start: prevToken.loc.end,
end: token.loc.start
},
messageId: "unexpectedBefore",
fix: (fixer) => fixer.removeRange([prevToken.range[1], token.range[0]])
});
}
}
function checkSpacingAfter(token) {
if (!token.value.endsWith("${"))
return;
const nextToken = sourceCode.getTokenAfter(token, { includeComments: true });
const hasSpace = sourceCode.isSpaceBetween(token, nextToken);
if (!utils.isTokenOnSameLine(token, nextToken))
return;
if (always && !hasSpace) {
context.report({
loc: {
start: {
line: token.loc.end.line,
column: token.loc.end.column - 2
},
end: token.loc.end
},
messageId: "expectedAfter",
fix: (fixer) => fixer.insertTextAfter(token, " ")
});
}
if (!always && hasSpace) {
context.report({
loc: {
start: token.loc.end,
end: nextToken.loc.start
},
messageId: "unexpectedAfter",
fix: (fixer) => fixer.removeRange([token.range[1], nextToken.range[0]])
});
}
}
return {
TemplateElement(node) {
const token = sourceCode.getFirstToken(node);
checkSpacingBefore(token);
checkSpacingAfter(token);
}
};
}
});
module.exports = templateCurlySpacing;
@@ -0,0 +1,28 @@
"use strict"
const startsWithKeywordRegexp = /^(all|not|only|print|screen)/i
module.exports = function (parentMedia, childMedia) {
if (!parentMedia.length && childMedia.length) return childMedia
if (parentMedia.length && !childMedia.length) return parentMedia
if (!parentMedia.length && !childMedia.length) return []
const media = []
parentMedia.forEach(parentItem => {
const parentItemStartsWithKeyword = startsWithKeywordRegexp.test(parentItem)
childMedia.forEach(childItem => {
const childItemStartsWithKeyword = startsWithKeywordRegexp.test(childItem)
if (parentItem !== childItem) {
if (childItemStartsWithKeyword && !parentItemStartsWithKeyword) {
media.push(`${childItem} and ${parentItem}`)
} else {
media.push(`${parentItem} and ${childItem}`)
}
}
})
})
return media
}
@@ -0,0 +1,13 @@
// ------------------------------------------------------------------
// JsonTypeBuilder
// ------------------------------------------------------------------
export { JsonTypeBuilder } from './json.mjs';
// ------------------------------------------------------------------
// JavaScriptTypeBuilder
// ------------------------------------------------------------------
import * as TypeBuilder from './type.mjs';
import { JavaScriptTypeBuilder } from './javascript.mjs';
/** JavaScript Type Builder with Static Resolution for TypeScript */
const Type = TypeBuilder;
export { JavaScriptTypeBuilder };
export { Type };
@@ -0,0 +1 @@
export { MotionA as a, MotionAbbr as abbr, MotionAddress as address, MotionAnimate as animate, MotionArea as area, MotionArticle as article, MotionAside as aside, MotionAudio as audio, MotionB as b, MotionBase as base, MotionBdi as bdi, MotionBdo as bdo, MotionBig as big, MotionBlockquote as blockquote, MotionBody as body, MotionButton as button, MotionCanvas as canvas, MotionCaption as caption, MotionCircle as circle, MotionCite as cite, MotionClipPath as clipPath, MotionCode as code, MotionCol as col, MotionColgroup as colgroup, MotionData as data, MotionDatalist as datalist, MotionDd as dd, MotionDefs as defs, MotionDel as del, MotionDesc as desc, MotionDetails as details, MotionDfn as dfn, MotionDialog as dialog, MotionDiv as div, MotionDl as dl, MotionDt as dt, MotionEllipse as ellipse, MotionEm as em, MotionEmbed as embed, MotionFeBlend as feBlend, MotionFeColorMatrix as feColorMatrix, MotionFeComponentTransfer as feComponentTransfer, MotionFeComposite as feComposite, MotionFeConvolveMatrix as feConvolveMatrix, MotionFeDiffuseLighting as feDiffuseLighting, MotionFeDisplacementMap as feDisplacementMap, MotionFeDistantLight as feDistantLight, MotionFeDropShadow as feDropShadow, MotionFeFlood as feFlood, MotionFeFuncA as feFuncA, MotionFeFuncB as feFuncB, MotionFeFuncG as feFuncG, MotionFeFuncR as feFuncR, MotionFeGaussianBlur as feGaussianBlur, MotionFeImage as feImage, MotionFeMerge as feMerge, MotionFeMergeNode as feMergeNode, MotionFeMorphology as feMorphology, MotionFeOffset as feOffset, MotionFePointLight as fePointLight, MotionFeSpecularLighting as feSpecularLighting, MotionFeSpotLight as feSpotLight, MotionFeTile as feTile, MotionFeTurbulence as feTurbulence, MotionFieldset as fieldset, MotionFigcaption as figcaption, MotionFigure as figure, MotionFilter as filter, MotionFooter as footer, MotionForeignObject as foreignObject, MotionForm as form, MotionG as g, MotionH1 as h1, MotionH2 as h2, MotionH3 as h3, MotionH4 as h4, MotionH5 as h5, MotionH6 as h6, MotionHead as head, MotionHeader as header, MotionHgroup as hgroup, MotionHr as hr, MotionHtml as html, MotionI as i, MotionIframe as iframe, MotionImage as image, MotionImg as img, MotionInput as input, MotionIns as ins, MotionKbd as kbd, MotionKeygen as keygen, MotionLabel as label, MotionLegend as legend, MotionLi as li, MotionLine as line, MotionLinearGradient as linearGradient, MotionLink as link, MotionMain as main, MotionMap as map, MotionMark as mark, MotionMarker as marker, MotionMask as mask, MotionMenu as menu, MotionMenuitem as menuitem, MotionMetadata as metadata, MotionMeter as meter, MotionNav as nav, MotionObject as object, MotionOl as ol, MotionOptgroup as optgroup, MotionOption as option, MotionOutput as output, MotionP as p, MotionParam as param, MotionPath as path, MotionPattern as pattern, MotionPicture as picture, MotionPolygon as polygon, MotionPolyline as polyline, MotionPre as pre, MotionProgress as progress, MotionQ as q, MotionRadialGradient as radialGradient, MotionRect as rect, MotionRp as rp, MotionRt as rt, MotionRuby as ruby, MotionS as s, MotionSamp as samp, MotionScript as script, MotionSection as section, MotionSelect as select, MotionSmall as small, MotionSource as source, MotionSpan as span, MotionStop as stop, MotionStrong as strong, MotionStyle as style, MotionSub as sub, MotionSummary as summary, MotionSup as sup, MotionSvg as svg, MotionSymbol as symbol, MotionTable as table, MotionTbody as tbody, MotionTd as td, MotionText as text, MotionTextPath as textPath, MotionTextarea as textarea, MotionTfoot as tfoot, MotionTh as th, MotionThead as thead, MotionTime as time, MotionTitle as title, MotionTr as tr, MotionTrack as track, MotionTspan as tspan, MotionU as u, MotionUl as ul, MotionUse as use, MotionVideo as video, MotionView as view, MotionWbr as wbr, MotionWebview as webview } from './render/components/motion/elements.mjs';
@@ -0,0 +1,29 @@
# Changelog
All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [v1.0.1](https://github.com/ljharb/es-define-property/compare/v1.0.0...v1.0.1) - 2024-12-06
### Commits
- [types] use shared tsconfig [`954a663`](https://github.com/ljharb/es-define-property/commit/954a66360326e508a0e5daa4b07493d58f5e110e)
- [actions] split out node 10-20, and 20+ [`3a8e84b`](https://github.com/ljharb/es-define-property/commit/3a8e84b23883f26ff37b3e82ff283834228e18c6)
- [Dev Deps] update `@ljharb/eslint-config`, `@ljharb/tsconfig`, `@types/get-intrinsic`, `@types/tape`, `auto-changelog`, `gopd`, `tape` [`86ae27b`](https://github.com/ljharb/es-define-property/commit/86ae27bb8cc857b23885136fad9cbe965ae36612)
- [Refactor] avoid using `get-intrinsic` [`02480c0`](https://github.com/ljharb/es-define-property/commit/02480c0353ef6118965282977c3864aff53d98b1)
- [Tests] replace `aud` with `npm audit` [`f6093ff`](https://github.com/ljharb/es-define-property/commit/f6093ff74ab51c98015c2592cd393bd42478e773)
- [Tests] configure testling [`7139e66`](https://github.com/ljharb/es-define-property/commit/7139e66959247a56086d9977359caef27c6849e7)
- [Dev Deps] update `tape` [`b901b51`](https://github.com/ljharb/es-define-property/commit/b901b511a75e001a40ce1a59fef7d9ffcfc87482)
- [Tests] fix types in tests [`469d269`](https://github.com/ljharb/es-define-property/commit/469d269fd141b1e773ec053a9fa35843493583e0)
- [Dev Deps] add missing peer dep [`733acfb`](https://github.com/ljharb/es-define-property/commit/733acfb0c4c96edf337e470b89a25a5b3724c352)
## v1.0.0 - 2024-02-12
### Commits
- Initial implementation, tests, readme, types [`3e154e1`](https://github.com/ljharb/es-define-property/commit/3e154e11a2fee09127220f5e503bf2c0a31dd480)
- Initial commit [`07d98de`](https://github.com/ljharb/es-define-property/commit/07d98de34a4dc31ff5e83a37c0c3f49e0d85cd50)
- npm init [`c4eb634`](https://github.com/ljharb/es-define-property/commit/c4eb6348b0d3886aac36cef34ad2ee0665ea6f3e)
- Only apps should have lockfiles [`7af86ec`](https://github.com/ljharb/es-define-property/commit/7af86ec1d311ec0b17fdfe616a25f64276903856)
@@ -0,0 +1,6 @@
import type { TSchema } from '../schema/index';
import { type TReadonly } from '../readonly/index';
import { type TOptional } from '../optional/index';
export type TReadonlyOptional<T extends TSchema> = TOptional<T> & TReadonly<T>;
/** `[Json]` Creates a Readonly and Optional property */
export declare function ReadonlyOptional<T extends TSchema>(schema: T): TReadonly<TOptional<T>>;
@@ -0,0 +1,4 @@
/**
* IS `true` for Node.js 10.10 and greater.
*/
export declare const IS_SUPPORT_READDIR_WITH_FILE_TYPES: boolean;
@@ -0,0 +1,185 @@
const { dirname, join, resolve, relative, isAbsolute } = require('path')
const rimraf_ = require('rimraf')
const { promisify } = require('util')
const {
access: access_,
accessSync,
copyFile: copyFile_,
copyFileSync,
readdir: readdir_,
readdirSync,
rename: rename_,
renameSync,
stat: stat_,
statSync,
lstat: lstat_,
lstatSync,
symlink: symlink_,
symlinkSync,
readlink: readlink_,
readlinkSync,
} = require('fs')
const access = promisify(access_)
const copyFile = promisify(copyFile_)
const readdir = promisify(readdir_)
const rename = promisify(rename_)
const stat = promisify(stat_)
const lstat = promisify(lstat_)
const symlink = promisify(symlink_)
const readlink = promisify(readlink_)
const rimraf = promisify(rimraf_)
const rimrafSync = rimraf_.sync
const mkdirp = require('mkdirp')
const pathExists = async path => {
try {
await access(path)
return true
} catch (er) {
return er.code !== 'ENOENT'
}
}
const pathExistsSync = path => {
try {
accessSync(path)
return true
} catch (er) {
return er.code !== 'ENOENT'
}
}
const moveFile = async (source, destination, options = {}, root = true, symlinks = []) => {
if (!source || !destination) {
throw new TypeError('`source` and `destination` file required')
}
options = {
overwrite: true,
...options,
}
if (!options.overwrite && await pathExists(destination)) {
throw new Error(`The destination file exists: ${destination}`)
}
await mkdirp(dirname(destination))
try {
await rename(source, destination)
} catch (error) {
if (error.code === 'EXDEV' || error.code === 'EPERM') {
const sourceStat = await lstat(source)
if (sourceStat.isDirectory()) {
const files = await readdir(source)
await Promise.all(files.map((file) =>
moveFile(join(source, file), join(destination, file), options, false, symlinks)
))
} else if (sourceStat.isSymbolicLink()) {
symlinks.push({ source, destination })
} else {
await copyFile(source, destination)
}
} else {
throw error
}
}
if (root) {
await Promise.all(symlinks.map(async ({ source: symSource, destination: symDestination }) => {
let target = await readlink(symSource)
// junction symlinks in windows will be absolute paths, so we need to
// make sure they point to the symlink destination
if (isAbsolute(target)) {
target = resolve(symDestination, relative(symSource, target))
}
// try to determine what the actual file is so we can create the correct
// type of symlink in windows
let targetStat = 'file'
try {
targetStat = await stat(resolve(dirname(symSource), target))
if (targetStat.isDirectory()) {
targetStat = 'junction'
}
} catch {
// targetStat remains 'file'
}
await symlink(
target,
symDestination,
targetStat
)
}))
await rimraf(source)
}
}
const moveFileSync = (source, destination, options = {}, root = true, symlinks = []) => {
if (!source || !destination) {
throw new TypeError('`source` and `destination` file required')
}
options = {
overwrite: true,
...options,
}
if (!options.overwrite && pathExistsSync(destination)) {
throw new Error(`The destination file exists: ${destination}`)
}
mkdirp.sync(dirname(destination))
try {
renameSync(source, destination)
} catch (error) {
if (error.code === 'EXDEV' || error.code === 'EPERM') {
const sourceStat = lstatSync(source)
if (sourceStat.isDirectory()) {
const files = readdirSync(source)
for (const file of files) {
moveFileSync(join(source, file), join(destination, file), options, false, symlinks)
}
} else if (sourceStat.isSymbolicLink()) {
symlinks.push({ source, destination })
} else {
copyFileSync(source, destination)
}
} else {
throw error
}
}
if (root) {
for (const { source: symSource, destination: symDestination } of symlinks) {
let target = readlinkSync(symSource)
// junction symlinks in windows will be absolute paths, so we need to
// make sure they point to the symlink destination
if (isAbsolute(target)) {
target = resolve(symDestination, relative(symSource, target))
}
// try to determine what the actual file is so we can create the correct
// type of symlink in windows
let targetStat = 'file'
try {
targetStat = statSync(resolve(dirname(symSource), target))
if (targetStat.isDirectory()) {
targetStat = 'junction'
}
} catch {
// targetStat remains 'file'
}
symlinkSync(
target,
symDestination,
targetStat
)
}
rimrafSync(source)
}
}
module.exports = moveFile
module.exports.sync = moveFileSync
@@ -0,0 +1,43 @@
import {DelimiterCasedPropertiesDeep} from './delimiter-cased-properties-deep';
/**
Convert object properties to snake case recursively.
This can be useful when, for example, converting some API types from a different style.
@see SnakeCase
@see SnakeCasedProperties
@example
```
interface User {
userId: number;
userName: string;
}
interface UserWithFriends {
userInfo: User;
userFriends: User[];
}
const result: SnakeCasedPropertiesDeep<UserWithFriends> = {
user_info: {
user_id: 1,
user_name: 'Tom',
},
user_friends: [
{
user_id: 2,
user_name: 'Jerry',
},
{
user_id: 3,
user_name: 'Spike',
},
],
};
```
@category Template Literals
*/
export type SnakeCasedPropertiesDeep<Value> = DelimiterCasedPropertiesDeep<Value, '_'>;
@@ -0,0 +1,39 @@
{
"name": "path-key",
"version": "3.1.1",
"description": "Get the PATH environment variable key cross-platform",
"license": "MIT",
"repository": "sindresorhus/path-key",
"author": {
"name": "Sindre Sorhus",
"email": "sindresorhus@gmail.com",
"url": "sindresorhus.com"
},
"engines": {
"node": ">=8"
},
"scripts": {
"test": "xo && ava && tsd"
},
"files": [
"index.js",
"index.d.ts"
],
"keywords": [
"path",
"key",
"environment",
"env",
"variable",
"var",
"get",
"cross-platform",
"windows"
],
"devDependencies": {
"@types/node": "^11.13.0",
"ava": "^1.4.1",
"tsd": "^0.7.2",
"xo": "^0.24.0"
}
}
@@ -0,0 +1,45 @@
import {Except} from './except';
import {ConditionalKeys} from './conditional-keys';
/**
Exclude keys from a shape that matches the given `Condition`.
This is useful when you want to create a new type with a specific set of keys from a shape. For example, you might want to exclude all the primitive properties from a class and form a new shape containing everything but the primitive properties.
@example
```
import {Primitive, ConditionalExcept} from 'type-fest';
class Awesome {
name: string;
successes: number;
failures: bigint;
run() {}
}
type ExceptPrimitivesFromAwesome = ConditionalExcept<Awesome, Primitive>;
//=> {run: () => void}
```
@example
```
import {ConditionalExcept} from 'type-fest';
interface Example {
a: string;
b: string | number;
c: () => void;
d: {};
}
type NonStringKeysOnly = ConditionalExcept<Example, string>;
//=> {b: string | number; c: () => void; d: {}}
```
@category Utilities
*/
export type ConditionalExcept<Base, Condition> = Except<
Base,
ConditionalKeys<Base, Condition>
>;
@@ -0,0 +1,7 @@
"use client";
import {
useBreadcrumbItem
} from "./chunk-QRIBVF72.mjs";
export {
useBreadcrumbItem
};
@@ -0,0 +1,90 @@
'use strict';
var path = require('path');
var fs = require('fs');
var acorn = require('./acorn.js');
function _interopNamespaceDefault(e) {
var n = Object.create(null);
if (e) {
Object.keys(e).forEach(function (k) {
if (k !== 'default') {
var d = Object.getOwnPropertyDescriptor(e, k);
Object.defineProperty(n, k, d.get ? d : {
enumerable: true,
get: function () { return e[k]; }
});
}
});
}
n.default = e;
return Object.freeze(n);
}
var acorn__namespace = /*#__PURE__*/_interopNamespaceDefault(acorn);
var inputFilePaths = [], forceFileName = false, fileMode = false, silent = false, compact = false, tokenize = false;
var options = {};
function help(status) {
var print = (status === 0) ? console.log : console.error;
print("usage: " + path.basename(process.argv[1]) + " [--ecma3|--ecma5|--ecma6|--ecma7|--ecma8|--ecma9|...|--ecma2015|--ecma2016|--ecma2017|--ecma2018|...]");
print(" [--tokenize] [--locations] [--allow-hash-bang] [--allow-await-outside-function] [--compact] [--silent] [--module] [--help] [--] [<infile>...]");
process.exit(status);
}
for (var i = 2; i < process.argv.length; ++i) {
var arg = process.argv[i];
if (arg[0] !== "-" || arg === "-") { inputFilePaths.push(arg); }
else if (arg === "--") {
inputFilePaths.push.apply(inputFilePaths, process.argv.slice(i + 1));
forceFileName = true;
break
} else if (arg === "--locations") { options.locations = true; }
else if (arg === "--allow-hash-bang") { options.allowHashBang = true; }
else if (arg === "--allow-await-outside-function") { options.allowAwaitOutsideFunction = true; }
else if (arg === "--silent") { silent = true; }
else if (arg === "--compact") { compact = true; }
else if (arg === "--help") { help(0); }
else if (arg === "--tokenize") { tokenize = true; }
else if (arg === "--module") { options.sourceType = "module"; }
else {
var match = arg.match(/^--ecma(\d+)$/);
if (match)
{ options.ecmaVersion = +match[1]; }
else
{ help(1); }
}
}
function run(codeList) {
var result = [], fileIdx = 0;
try {
codeList.forEach(function (code, idx) {
fileIdx = idx;
if (!tokenize) {
result = acorn__namespace.parse(code, options);
options.program = result;
} else {
var tokenizer = acorn__namespace.tokenizer(code, options), token;
do {
token = tokenizer.getToken();
result.push(token);
} while (token.type !== acorn__namespace.tokTypes.eof)
}
});
} catch (e) {
console.error(fileMode ? e.message.replace(/\(\d+:\d+\)$/, function (m) { return m.slice(0, 1) + inputFilePaths[fileIdx] + " " + m.slice(1); }) : e.message);
process.exit(1);
}
if (!silent) { console.log(JSON.stringify(result, function (_, value) { return typeof value === "bigint" ? null : value; }, compact ? null : 2)); }
}
if (fileMode = inputFilePaths.length && (forceFileName || !inputFilePaths.includes("-") || inputFilePaths.length !== 1)) {
run(inputFilePaths.map(function (path) { return fs.readFileSync(path, "utf8"); }));
} else {
var code = "";
process.stdin.resume();
process.stdin.on("data", function (chunk) { return code += chunk; });
process.stdin.on("end", function () { return run([code]); });
}
@@ -0,0 +1,48 @@
var tape = require('tape')
var through = require('through2')
var stream = require('stream')
var shift = require('./')
tape('shifts next', function (t) {
var passthrough = through()
passthrough.write('hello')
passthrough.write('world')
t.same(shift(passthrough), Buffer.from('hello'))
t.same(shift(passthrough), Buffer.from('world'))
t.end()
})
tape('shifts next with core', function (t) {
var passthrough = stream.PassThrough()
passthrough.write('hello')
passthrough.write('world')
t.same(shift(passthrough), Buffer.from('hello'))
t.same(shift(passthrough), Buffer.from('world'))
t.end()
})
tape('shifts next with object mode', function (t) {
var passthrough = through({objectMode: true})
passthrough.write({hello: 1})
passthrough.write({world: 1})
t.same(shift(passthrough), {hello: 1})
t.same(shift(passthrough), {world: 1})
t.end()
})
tape('shifts next with object mode with core', function (t) {
var passthrough = stream.PassThrough({objectMode: true})
passthrough.write({hello: 1})
passthrough.write({world: 1})
t.same(shift(passthrough), {hello: 1})
t.same(shift(passthrough), {world: 1})
t.end()
})
@@ -0,0 +1,2 @@
import { TCreateConverter, TPatternConverter } from './typings';
export default function compilePattern(pattern: string, createConverter: TCreateConverter, literalConverter: (text: string) => TPatternConverter): TPatternConverter[];
@@ -0,0 +1,30 @@
import { DownloadBaseEmojiByIdReq, DownloadBaseEmojiByUrlReq, GetBaseEmojiPathReq, PullSysEmojisReq } from '../types';
import { GeneralCallResult } from './common';
export interface NodeIKernelBaseEmojiService {
removeKernelBaseEmojiListener(listenerId: number): void;
addKernelBaseEmojiListener(listener: unknown): number;
isBaseEmojiPathExist(args: Array<string>): unknown;
fetchFullSysEmojis(pullSysEmojisReq: PullSysEmojisReq): Promise<GeneralCallResult & {
rsp: {
otherPanelResult: {
SysEmojiGroupList: Array<unknown>;
downloadInfo: Array<unknown>;
};
normalPanelResult: {
SysEmojiGroupList: Array<unknown>;
downloadInfo: Array<unknown>;
};
superPanelResult: {
SysEmojiGroupList: Array<unknown>;
downloadInfo: Array<unknown>;
};
redHeartPanelResult: {
SysEmojiGroupList: Array<unknown>;
downloadInfo: Array<unknown>;
};
};
}>;
getBaseEmojiPathByIds(getBaseEmojiPathReqs: Array<GetBaseEmojiPathReq>): unknown;
downloadBaseEmojiByIdWithUrl(downloadBaseEmojiByUrlReq: DownloadBaseEmojiByUrlReq): unknown;
downloadBaseEmojiById(downloadBaseEmojiByIdReq: DownloadBaseEmojiByIdReq): unknown;
}
@@ -0,0 +1,68 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.glob = exports.sync = exports.iterate = exports.iterateSync = exports.stream = exports.streamSync = exports.Ignore = exports.hasMagic = exports.Glob = exports.unescape = exports.escape = void 0;
exports.globStreamSync = globStreamSync;
exports.globStream = globStream;
exports.globSync = globSync;
exports.globIterateSync = globIterateSync;
exports.globIterate = globIterate;
const minimatch_1 = require("minimatch");
const glob_js_1 = require("./glob.js");
const has_magic_js_1 = require("./has-magic.js");
var minimatch_2 = require("minimatch");
Object.defineProperty(exports, "escape", { enumerable: true, get: function () { return minimatch_2.escape; } });
Object.defineProperty(exports, "unescape", { enumerable: true, get: function () { return minimatch_2.unescape; } });
var glob_js_2 = require("./glob.js");
Object.defineProperty(exports, "Glob", { enumerable: true, get: function () { return glob_js_2.Glob; } });
var has_magic_js_2 = require("./has-magic.js");
Object.defineProperty(exports, "hasMagic", { enumerable: true, get: function () { return has_magic_js_2.hasMagic; } });
var ignore_js_1 = require("./ignore.js");
Object.defineProperty(exports, "Ignore", { enumerable: true, get: function () { return ignore_js_1.Ignore; } });
function globStreamSync(pattern, options = {}) {
return new glob_js_1.Glob(pattern, options).streamSync();
}
function globStream(pattern, options = {}) {
return new glob_js_1.Glob(pattern, options).stream();
}
function globSync(pattern, options = {}) {
return new glob_js_1.Glob(pattern, options).walkSync();
}
async function glob_(pattern, options = {}) {
return new glob_js_1.Glob(pattern, options).walk();
}
function globIterateSync(pattern, options = {}) {
return new glob_js_1.Glob(pattern, options).iterateSync();
}
function globIterate(pattern, options = {}) {
return new glob_js_1.Glob(pattern, options).iterate();
}
// aliases: glob.sync.stream() glob.stream.sync() glob.sync() etc
exports.streamSync = globStreamSync;
exports.stream = Object.assign(globStream, { sync: globStreamSync });
exports.iterateSync = globIterateSync;
exports.iterate = Object.assign(globIterate, {
sync: globIterateSync,
});
exports.sync = Object.assign(globSync, {
stream: globStreamSync,
iterate: globIterateSync,
});
exports.glob = Object.assign(glob_, {
glob: glob_,
globSync,
sync: exports.sync,
globStream,
stream: exports.stream,
globStreamSync,
streamSync: exports.streamSync,
globIterate,
iterate: exports.iterate,
globIterateSync,
iterateSync: exports.iterateSync,
Glob: glob_js_1.Glob,
hasMagic: has_magic_js_1.hasMagic,
escape: minimatch_1.escape,
unescape: minimatch_1.unescape,
});
exports.glob.glob = exports.glob;
//# sourceMappingURL=index.js.map
@@ -0,0 +1,858 @@
import { GrayTipElement, GroupNotify, MessageElement, NapCatCore, Peer, RawMessage, SendMessageElement } from '../../napcat-core';
import { NapCatOneBot11Adapter, OB11Message, OB11MessageData, OB11MessageDataType } from '../index';
import { OB11FriendAddNoticeEvent } from '../event/notice/OB11FriendAddNoticeEvent';
import { OB11GroupIncreaseEvent } from '../event/notice/OB11GroupIncreaseEvent';
import { GroupDecreaseSubType, OB11GroupDecreaseEvent } from '../event/notice/OB11GroupDecreaseEvent';
import { OB11GroupAdminNoticeEvent } from '../event/notice/OB11GroupAdminNoticeEvent';
import { OB11GroupRequestEvent } from '../event/request/OB11GroupRequest';
import { LRUCache } from '../../napcat-common/src/lru-cache';
import { OB11OnlineFileReceiveEvent } from '../event/notice/OB11OnlineFileReceiveEvent';
import { OB11OnlineFileSendEvent } from '../event/notice/OB11OnlineFileSendEvent';
type RawToOb11Converters = {
[Key in keyof MessageElement as Key extends `${string}Element` ? Key : never]: (element: Exclude<MessageElement[Key], null | undefined>, msg: RawMessage, elementWrapper: MessageElement, context: RecvMessageContext) => Promise<OB11MessageData | null | undefined>;
};
type Ob11ToRawConverters = {
[Key in OB11MessageDataType]: (sendMsg: Extract<OB11MessageData, {
type: Key;
}>, context: SendMessageContext) => Promise<SendMessageElement | undefined>;
};
export type SendMessageContext = {
deleteAfterSentFiles: string[];
peer: Peer;
};
export type RecvMessageContext = {
parseMultMsg: boolean;
disableGetUrl: boolean;
quick_reply: boolean;
};
export declare class OneBotMsgApi {
obContext: NapCatOneBot11Adapter;
core: NapCatCore;
notifyGroupInvite: LRUCache<string, GroupNotify>;
rawToOb11Converters: RawToOb11Converters;
ob11ToRawConverters: Ob11ToRawConverters;
constructor(obContext: NapCatOneBot11Adapter, core: NapCatCore);
/**
* 解析带有JSON标记的文本
* @param text 要解析的文本
* @returns 解析后的结果数组,每个元素包含类型(text或json)和内容
*/
parseTextWithJson(text: string): {
type: "text" | "json";
content: string | object;
}[];
parsePrivateMsgEvent(msg: RawMessage, grayTipElement: GrayTipElement): Promise<import("../index").OB11FriendPokeEvent | OB11FriendAddNoticeEvent | undefined>;
private getMultiMessages;
private parseMultiMessageContent;
parseMessage(msg: RawMessage, messagePostFormat: string, parseMultMsg?: boolean, disableGetUrl?: boolean, quick_reply?: boolean): Promise<{
group_id?: string | number | undefined;
emoji_likes_list?: {
emoji_id: string;
emoji_type: string;
likes_cnt: string;
}[] | undefined;
real_seq?: string | undefined;
temp_source?: number | undefined;
message_sent_type?: string | undefined;
target_id?: number | undefined;
self_id?: number | undefined;
group_name?: string | undefined;
sub_type?: "normal" | "group" | "friend" | undefined;
post_type?: string | undefined;
raw?: unknown;
time: number;
message: string | ({
type: OB11MessageDataType.text;
data: {
text: string;
};
} | {
type: OB11MessageDataType.face;
data: {
resultId?: string | undefined;
chainCount?: number | undefined;
id: string;
};
} | {
type: OB11MessageDataType.mface;
data: {
key: string;
summary: string;
emoji_package_id: number;
emoji_id: string;
};
} | {
type: OB11MessageDataType.at;
data: {
name?: string | undefined;
qq: string;
};
} | {
type: OB11MessageDataType.reply;
data: {
id?: string | undefined;
seq?: number | undefined;
};
} | {
type: OB11MessageDataType.image;
data: {
path?: string | undefined;
url?: string | undefined;
name?: string | undefined;
thumb?: string | undefined;
file: string;
} & {
summary?: string | undefined;
sub_type?: number | undefined;
};
} | {
type: OB11MessageDataType.voice;
data: {
path?: string | undefined;
url?: string | undefined;
name?: string | undefined;
thumb?: string | undefined;
file: string;
};
} | {
type: OB11MessageDataType.video;
data: {
path?: string | undefined;
url?: string | undefined;
name?: string | undefined;
thumb?: string | undefined;
file: string;
};
} | {
type: OB11MessageDataType.file;
data: {
path?: string | undefined;
url?: string | undefined;
name?: string | undefined;
thumb?: string | undefined;
file: string;
};
} | {
type: OB11MessageDataType.music;
data: {
id: string | number;
type: "qq" | "163" | "kugou" | "migu" | "kuwo";
};
} | {
type: OB11MessageDataType.music;
data: {
content?: string | undefined;
title?: string | undefined;
audio?: string | undefined;
id: undefined;
type: "qq" | "163" | "kugou" | "migu" | "kuwo" | "custom";
url: string;
image: string;
};
} | {
type: OB11MessageDataType.poke;
data: {
id: string;
type: string;
};
} | {
type: OB11MessageDataType.dice;
data: {
result: string | number;
};
} | {
type: OB11MessageDataType.rps;
data: {
result: string | number;
};
} | {
type: OB11MessageDataType.contact;
data: {
id: string;
type: "qq" | "group";
};
} | {
type: OB11MessageDataType.json;
data: {
config?: {
token: string;
} | undefined;
data: string | {};
};
} | {
type: OB11MessageDataType.markdown;
data: {
content: string;
};
} | {
type: OB11MessageDataType.node;
data: {
summary?: string | undefined;
id?: string | undefined;
time?: string | undefined;
name?: string | undefined;
uin?: string | number | undefined;
source?: string | undefined;
news?: {
text: string;
}[] | undefined;
user_id?: string | number | undefined;
prompt?: string | undefined;
content: any;
nickname: string;
};
} | {
type: OB11MessageDataType.forward;
data: {
content?: any;
id: string;
};
} | {
type: OB11MessageDataType.onlinefile;
data: {
elementId: string;
fileSize: string;
fileName: string;
msgId: string;
isDir: boolean;
};
} | {
type: OB11MessageDataType.flashtransfer;
data: {
fileSetId: string;
};
})[];
message_id: number;
message_type: "group" | "private";
real_id: number;
message_seq: number;
sender: {
level?: string | undefined;
age?: number | undefined;
sex?: string | undefined;
area?: string | undefined;
title?: string | undefined;
card?: string | undefined;
role?: string | undefined;
user_id: string | number;
nickname: string;
};
raw_message: string;
font: number;
user_id: string | number;
message_format: "string" | "array";
} | undefined>;
parseMessageV2(msg: RawMessage, parseMultMsg?: boolean, disableGetUrl?: boolean, quick_reply?: boolean): Promise<{
stringMsg: {
group_id?: string | number | undefined;
emoji_likes_list?: {
emoji_id: string;
emoji_type: string;
likes_cnt: string;
}[] | undefined;
real_seq?: string | undefined;
temp_source?: number | undefined;
message_sent_type?: string | undefined;
target_id?: number | undefined;
self_id?: number | undefined;
group_name?: string | undefined;
sub_type?: "normal" | "group" | "friend" | undefined;
post_type?: string | undefined;
raw?: unknown;
time: number;
message: string | ({
type: OB11MessageDataType.text;
data: {
text: string;
};
} | {
type: OB11MessageDataType.face;
data: {
resultId?: string | undefined;
chainCount?: number | undefined;
id: string;
};
} | {
type: OB11MessageDataType.mface;
data: {
key: string;
summary: string;
emoji_package_id: number;
emoji_id: string;
};
} | {
type: OB11MessageDataType.at;
data: {
name?: string | undefined;
qq: string;
};
} | {
type: OB11MessageDataType.reply;
data: {
id?: string | undefined;
seq?: number | undefined;
};
} | {
type: OB11MessageDataType.image;
data: {
path?: string | undefined;
url?: string | undefined;
name?: string | undefined;
thumb?: string | undefined;
file: string;
} & {
summary?: string | undefined;
sub_type?: number | undefined;
};
} | {
type: OB11MessageDataType.voice;
data: {
path?: string | undefined;
url?: string | undefined;
name?: string | undefined;
thumb?: string | undefined;
file: string;
};
} | {
type: OB11MessageDataType.video;
data: {
path?: string | undefined;
url?: string | undefined;
name?: string | undefined;
thumb?: string | undefined;
file: string;
};
} | {
type: OB11MessageDataType.file;
data: {
path?: string | undefined;
url?: string | undefined;
name?: string | undefined;
thumb?: string | undefined;
file: string;
};
} | {
type: OB11MessageDataType.music;
data: {
id: string | number;
type: "qq" | "163" | "kugou" | "migu" | "kuwo";
};
} | {
type: OB11MessageDataType.music;
data: {
content?: string | undefined;
title?: string | undefined;
audio?: string | undefined;
id: undefined;
type: "qq" | "163" | "kugou" | "migu" | "kuwo" | "custom";
url: string;
image: string;
};
} | {
type: OB11MessageDataType.poke;
data: {
id: string;
type: string;
};
} | {
type: OB11MessageDataType.dice;
data: {
result: string | number;
};
} | {
type: OB11MessageDataType.rps;
data: {
result: string | number;
};
} | {
type: OB11MessageDataType.contact;
data: {
id: string;
type: "qq" | "group";
};
} | {
type: OB11MessageDataType.json;
data: {
config?: {
token: string;
} | undefined;
data: string | {};
};
} | {
type: OB11MessageDataType.markdown;
data: {
content: string;
};
} | {
type: OB11MessageDataType.node;
data: {
summary?: string | undefined;
id?: string | undefined;
time?: string | undefined;
name?: string | undefined;
uin?: string | number | undefined;
source?: string | undefined;
news?: {
text: string;
}[] | undefined;
user_id?: string | number | undefined;
prompt?: string | undefined;
content: any;
nickname: string;
};
} | {
type: OB11MessageDataType.forward;
data: {
content?: any;
id: string;
};
} | {
type: OB11MessageDataType.onlinefile;
data: {
elementId: string;
fileSize: string;
fileName: string;
msgId: string;
isDir: boolean;
};
} | {
type: OB11MessageDataType.flashtransfer;
data: {
fileSetId: string;
};
})[];
message_id: number;
message_type: "group" | "private";
real_id: number;
message_seq: number;
sender: {
level?: string | undefined;
age?: number | undefined;
sex?: string | undefined;
area?: string | undefined;
title?: string | undefined;
card?: string | undefined;
role?: string | undefined;
user_id: string | number;
nickname: string;
};
raw_message: string;
font: number;
user_id: string | number;
message_format: "string" | "array";
};
arrayMsg: {
group_id?: string | number | undefined;
emoji_likes_list?: {
emoji_id: string;
emoji_type: string;
likes_cnt: string;
}[] | undefined;
real_seq?: string | undefined;
temp_source?: number | undefined;
message_sent_type?: string | undefined;
target_id?: number | undefined;
self_id?: number | undefined;
group_name?: string | undefined;
sub_type?: "normal" | "group" | "friend" | undefined;
post_type?: string | undefined;
raw?: unknown;
time: number;
message: string | ({
type: OB11MessageDataType.text;
data: {
text: string;
};
} | {
type: OB11MessageDataType.face;
data: {
resultId?: string | undefined;
chainCount?: number | undefined;
id: string;
};
} | {
type: OB11MessageDataType.mface;
data: {
key: string;
summary: string;
emoji_package_id: number;
emoji_id: string;
};
} | {
type: OB11MessageDataType.at;
data: {
name?: string | undefined;
qq: string;
};
} | {
type: OB11MessageDataType.reply;
data: {
id?: string | undefined;
seq?: number | undefined;
};
} | {
type: OB11MessageDataType.image;
data: {
path?: string | undefined;
url?: string | undefined;
name?: string | undefined;
thumb?: string | undefined;
file: string;
} & {
summary?: string | undefined;
sub_type?: number | undefined;
};
} | {
type: OB11MessageDataType.voice;
data: {
path?: string | undefined;
url?: string | undefined;
name?: string | undefined;
thumb?: string | undefined;
file: string;
};
} | {
type: OB11MessageDataType.video;
data: {
path?: string | undefined;
url?: string | undefined;
name?: string | undefined;
thumb?: string | undefined;
file: string;
};
} | {
type: OB11MessageDataType.file;
data: {
path?: string | undefined;
url?: string | undefined;
name?: string | undefined;
thumb?: string | undefined;
file: string;
};
} | {
type: OB11MessageDataType.music;
data: {
id: string | number;
type: "qq" | "163" | "kugou" | "migu" | "kuwo";
};
} | {
type: OB11MessageDataType.music;
data: {
content?: string | undefined;
title?: string | undefined;
audio?: string | undefined;
id: undefined;
type: "qq" | "163" | "kugou" | "migu" | "kuwo" | "custom";
url: string;
image: string;
};
} | {
type: OB11MessageDataType.poke;
data: {
id: string;
type: string;
};
} | {
type: OB11MessageDataType.dice;
data: {
result: string | number;
};
} | {
type: OB11MessageDataType.rps;
data: {
result: string | number;
};
} | {
type: OB11MessageDataType.contact;
data: {
id: string;
type: "qq" | "group";
};
} | {
type: OB11MessageDataType.json;
data: {
config?: {
token: string;
} | undefined;
data: string | {};
};
} | {
type: OB11MessageDataType.markdown;
data: {
content: string;
};
} | {
type: OB11MessageDataType.node;
data: {
summary?: string | undefined;
id?: string | undefined;
time?: string | undefined;
name?: string | undefined;
uin?: string | number | undefined;
source?: string | undefined;
news?: {
text: string;
}[] | undefined;
user_id?: string | number | undefined;
prompt?: string | undefined;
content: any;
nickname: string;
};
} | {
type: OB11MessageDataType.forward;
data: {
content?: any;
id: string;
};
} | {
type: OB11MessageDataType.onlinefile;
data: {
elementId: string;
fileSize: string;
fileName: string;
msgId: string;
isDir: boolean;
};
} | {
type: OB11MessageDataType.flashtransfer;
data: {
fileSetId: string;
};
})[];
message_id: number;
message_type: "group" | "private";
real_id: number;
message_seq: number;
sender: {
level?: string | undefined;
age?: number | undefined;
sex?: string | undefined;
area?: string | undefined;
title?: string | undefined;
card?: string | undefined;
role?: string | undefined;
user_id: string | number;
nickname: string;
};
raw_message: string;
font: number;
user_id: string | number;
message_format: "string" | "array";
};
} | undefined>;
private initializeMessage;
private handleGroupMessage;
private handlePrivateMessage;
private handleTempGroupMessage;
private parseMessageSegments;
private convertArrayToStringMessage;
importArrayTostringMsg(originMsg: OB11Message): Promise<{
group_id?: string | number | undefined;
emoji_likes_list?: {
emoji_id: string;
emoji_type: string;
likes_cnt: string;
}[] | undefined;
real_seq?: string | undefined;
temp_source?: number | undefined;
message_sent_type?: string | undefined;
target_id?: number | undefined;
self_id?: number | undefined;
group_name?: string | undefined;
sub_type?: "normal" | "group" | "friend" | undefined;
post_type?: string | undefined;
raw?: unknown;
time: number;
message: string | ({
type: OB11MessageDataType.text;
data: {
text: string;
};
} | {
type: OB11MessageDataType.face;
data: {
resultId?: string | undefined;
chainCount?: number | undefined;
id: string;
};
} | {
type: OB11MessageDataType.mface;
data: {
key: string;
summary: string;
emoji_package_id: number;
emoji_id: string;
};
} | {
type: OB11MessageDataType.at;
data: {
name?: string | undefined;
qq: string;
};
} | {
type: OB11MessageDataType.reply;
data: {
id?: string | undefined;
seq?: number | undefined;
};
} | {
type: OB11MessageDataType.image;
data: {
path?: string | undefined;
url?: string | undefined;
name?: string | undefined;
thumb?: string | undefined;
file: string;
} & {
summary?: string | undefined;
sub_type?: number | undefined;
};
} | {
type: OB11MessageDataType.voice;
data: {
path?: string | undefined;
url?: string | undefined;
name?: string | undefined;
thumb?: string | undefined;
file: string;
};
} | {
type: OB11MessageDataType.video;
data: {
path?: string | undefined;
url?: string | undefined;
name?: string | undefined;
thumb?: string | undefined;
file: string;
};
} | {
type: OB11MessageDataType.file;
data: {
path?: string | undefined;
url?: string | undefined;
name?: string | undefined;
thumb?: string | undefined;
file: string;
};
} | {
type: OB11MessageDataType.music;
data: {
id: string | number;
type: "qq" | "163" | "kugou" | "migu" | "kuwo";
};
} | {
type: OB11MessageDataType.music;
data: {
content?: string | undefined;
title?: string | undefined;
audio?: string | undefined;
id: undefined;
type: "qq" | "163" | "kugou" | "migu" | "kuwo" | "custom";
url: string;
image: string;
};
} | {
type: OB11MessageDataType.poke;
data: {
id: string;
type: string;
};
} | {
type: OB11MessageDataType.dice;
data: {
result: string | number;
};
} | {
type: OB11MessageDataType.rps;
data: {
result: string | number;
};
} | {
type: OB11MessageDataType.contact;
data: {
id: string;
type: "qq" | "group";
};
} | {
type: OB11MessageDataType.json;
data: {
config?: {
token: string;
} | undefined;
data: string | {};
};
} | {
type: OB11MessageDataType.markdown;
data: {
content: string;
};
} | {
type: OB11MessageDataType.node;
data: {
summary?: string | undefined;
id?: string | undefined;
time?: string | undefined;
name?: string | undefined;
uin?: string | number | undefined;
source?: string | undefined;
news?: {
text: string;
}[] | undefined;
user_id?: string | number | undefined;
prompt?: string | undefined;
content: any;
nickname: string;
};
} | {
type: OB11MessageDataType.forward;
data: {
content?: any;
id: string;
};
} | {
type: OB11MessageDataType.onlinefile;
data: {
elementId: string;
fileSize: string;
fileName: string;
msgId: string;
isDir: boolean;
};
} | {
type: OB11MessageDataType.flashtransfer;
data: {
fileSetId: string;
};
})[];
message_id: number;
message_type: "group" | "private";
real_id: number;
message_seq: number;
sender: {
level?: string | undefined;
age?: number | undefined;
sex?: string | undefined;
area?: string | undefined;
title?: string | undefined;
card?: string | undefined;
role?: string | undefined;
user_id: string | number;
nickname: string;
};
raw_message: string;
font: number;
user_id: string | number;
message_format: "string" | "array";
}>;
createSendElements(messageData: OB11MessageData[], peer: Peer, ignoreTypes?: OB11MessageDataType[]): Promise<{
sendElements: SendMessageElement[];
deleteAfterSentFiles: string[];
}>;
sendMsgWithOb11UniqueId(peer: Peer, sendElements: SendMessageElement[], deleteAfterSentFiles: string[]): Promise<RawMessage>;
private handleOb11FileLikeMessage;
handleObfuckName(name: string): Promise<string | undefined>;
groupChangDecreseType2String(type: number): GroupDecreaseSubType;
waitGroupNotify(groupUin: string, memberUid?: string, operatorUid?: string): Promise<string | undefined>;
parseSysMessage(msg: number[]): Promise<OB11GroupIncreaseEvent | import("../index").OB11ProfileLikeEvent | OB11GroupDecreaseEvent | OB11GroupAdminNoticeEvent | OB11GroupRequestEvent | OB11OnlineFileReceiveEvent | OB11OnlineFileSendEvent | undefined>;
}
export {};
@@ -0,0 +1,52 @@
"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/use-kbd.ts
var use_kbd_exports = {};
__export(use_kbd_exports, {
useKbd: () => useKbd
});
module.exports = __toCommonJS(use_kbd_exports);
var import_system_rsc = require("@heroui/system-rsc");
var import_theme = require("@heroui/theme");
var import_shared_utils = require("@heroui/shared-utils");
var import_react = require("react");
function useKbd(originalProps) {
const [props, variantProps] = (0, import_system_rsc.mapPropsVariants)(originalProps, import_theme.kbd.variantKeys);
const { as, children, className, keys, title, classNames, ...otherProps } = props;
const Component = as || "kbd";
const slots = (0, import_react.useMemo)(
() => (0, import_theme.kbd)({
...variantProps
}),
[(0, import_shared_utils.objectToDeps)(variantProps)]
);
const baseStyles = (0, import_shared_utils.clsx)(classNames == null ? void 0 : classNames.base, className);
const keysToRender = typeof keys === "string" ? [keys] : Array.isArray(keys) ? keys : [];
const getKbdProps = (props2 = {}) => ({
...otherProps,
...props2,
className: (0, import_shared_utils.clsx)(slots.base({ class: (0, import_shared_utils.clsx)(baseStyles, props2.className) }))
});
return { Component, slots, classNames, title, children, keysToRender, getKbdProps };
}
// Annotate the CommonJS export names for ESM import in node:
0 && (module.exports = {
useKbd
});
@@ -0,0 +1,2 @@
import type { LibDefinition } from '../variable';
export declare const esnext_sharedmemory: LibDefinition;
@@ -0,0 +1 @@
{"mappings":";;;;;;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;AAmCM,MAAM,0DACX,CAAA,GAAA,sCAAI,EAAE,aAAa,CAAuF;AAMrG,SAAS,0CAAQ,KAAmB;IACzC,IAAI,QAAQ,CAAA,GAAA,4BAAO;IACnB,IAAI,mBAAC,kBAAkB,QAAQ,OAAO,SAAS,IAAI,aAAE,SAAS,EAAC,GAAG;IAClE,IAAI,CAAC,SAAS,WAAW,GAAG,CAAA,GAAA,qBAAO,EAAE;IACrC,IAAI,eAAe,CAAA,GAAA,oBAAM,EAAE,IAAO,CAAA;qBAAC;wBAAS;QAAU,CAAA,GAAI;QAAC;QAAS;KAAW;IAE/E,IAAI,gBAAC,YAAY,EAAC,GAAG,CAAA,GAAA,iDAAsB;IAC3C,IAAI,CAAC,MAAM,eAAe,IAAI,cAC5B,kBAAkB;IAGpB,IAAI,CAAC,iBACH,OAAO;IAGT,IAAI,WAAW,MAAM,QAAQ;IAC7B,IAAI,CAAC,MAAM,sBAAsB,EAC/B,yBACE,0DAAC,CAAA,GAAA,gCAAS;QAAE,cAAA;QAAa,SAAS,AAAC,CAAA,MAAM,kBAAkB,IAAI,OAAM,KAAM,CAAC;OACzE;IAKP,yBACE,0DAAC,0CAAe,QAAQ;QAAC,OAAO;qBAC9B,0DAAC,CAAA,GAAA,gDAAkB,SAChB;IAKP,qBAAO,CAAA,GAAA,yCAAO,EAAE,YAAY,CAAC,UAAU;AACzC;AAGO,SAAS;IACd,IAAI,MAAM,CAAA,GAAA,uBAAS,EAAE;IACrB,IAAI,aAAa,gBAAA,0BAAA,IAAK,UAAU;IAChC,CAAA,GAAA,qCAAc,EAAE;QACd,uBAAA,iCAAA,WAAa;IACf,GAAG;QAAC;KAAW;AACjB","sources":["packages/@react-aria/overlays/src/Overlay.tsx"],"sourcesContent":["/*\n * Copyright 2022 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 {ClearPressResponder} from '@react-aria/interactions';\nimport {FocusScope} from '@react-aria/focus';\nimport React, {ReactNode, useContext, useMemo, useState} from 'react';\nimport ReactDOM from 'react-dom';\nimport {useIsSSR} from '@react-aria/ssr';\nimport {useLayoutEffect} from '@react-aria/utils';\nimport {useUNSAFE_PortalContext} from './PortalProvider';\n\nexport interface OverlayProps {\n /**\n * The container element in which the overlay portal will be placed.\n * @default document.body\n */\n portalContainer?: Element,\n /** The overlay to render in the portal. */\n children: ReactNode,\n /**\n * Disables default focus management for the overlay, including containment and restoration.\n * This option should be used very carefully. When focus management is disabled, you must\n * implement focus containment and restoration to ensure the overlay is keyboard accessible.\n */\n disableFocusManagement?: boolean,\n /**\n * Whether to contain focus within the overlay.\n */\n shouldContainFocus?: boolean,\n /**\n * Whether the overlay is currently performing an exit animation. When true,\n * focus is allowed to move outside.\n */\n isExiting?: boolean\n}\n\nexport const OverlayContext: React.Context<{contain: boolean, setContain: React.Dispatch<React.SetStateAction<boolean>>} | null> =\n React.createContext<{contain: boolean, setContain: React.Dispatch<React.SetStateAction<boolean>>} | null>(null);\n\n/**\n * A container which renders an overlay such as a popover or modal in a portal,\n * and provides a focus scope for the child elements.\n */\nexport function Overlay(props: OverlayProps): React.ReactPortal | null {\n let isSSR = useIsSSR();\n let {portalContainer = isSSR ? null : document.body, isExiting} = props;\n let [contain, setContain] = useState(false);\n let contextValue = useMemo(() => ({contain, setContain}), [contain, setContain]);\n\n let {getContainer} = useUNSAFE_PortalContext();\n if (!props.portalContainer && getContainer) {\n portalContainer = getContainer();\n }\n\n if (!portalContainer) {\n return null;\n }\n\n let contents = props.children;\n if (!props.disableFocusManagement) {\n contents = (\n <FocusScope restoreFocus contain={(props.shouldContainFocus || contain) && !isExiting}>\n {contents}\n </FocusScope>\n );\n }\n\n contents = (\n <OverlayContext.Provider value={contextValue}>\n <ClearPressResponder>\n {contents}\n </ClearPressResponder>\n </OverlayContext.Provider>\n );\n\n return ReactDOM.createPortal(contents, portalContainer);\n}\n\n/** @private */\nexport function useOverlayFocusContain(): void {\n let ctx = useContext(OverlayContext);\n let setContain = ctx?.setContain;\n useLayoutEffect(() => {\n setContain?.(true);\n }, [setContain]);\n}\n"],"names":[],"version":3,"file":"Overlay.main.js.map"}
@@ -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 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","16":"Q"},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":"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 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"},E:{"1":"B","2":"J ZB K D E F A 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":"0 1 2 3 4 5 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 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 FD GD HD ID NC uC JD OC"},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 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:{"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:{"2":"0D"},S:{"2":"1D 2D"}},B:7,C:"Explicit descendant combinator >>",D:true};
@@ -0,0 +1,46 @@
/*
MIT License http://www.opensource.org/licenses/mit-license.php
Author Tobias Koppers @sokra
*/
"use strict";
const Hook = require("./Hook");
const HookCodeFactory = require("./HookCodeFactory");
class SyncHookCodeFactory extends HookCodeFactory {
content({ onError, onDone, rethrowIfPossible }) {
return this.callTapsSeries({
onError: (i, err) => onError(err),
onDone,
rethrowIfPossible
});
}
}
const factory = new SyncHookCodeFactory();
const TAP_ASYNC = () => {
throw new Error("tapAsync is not supported on a SyncHook");
};
const TAP_PROMISE = () => {
throw new Error("tapPromise is not supported on a SyncHook");
};
function COMPILE(options) {
factory.setup(this, options);
return factory.create(options);
}
function SyncHook(args = [], name = undefined) {
const hook = new Hook(args, name);
hook.constructor = SyncHook;
hook.tapAsync = TAP_ASYNC;
hook.tapPromise = TAP_PROMISE;
hook.compile = COMPILE;
return hook;
}
SyncHook.prototype = null;
module.exports = SyncHook;
@@ -0,0 +1,144 @@
"use strict"
const { CALL, CONSTRUCT, READ } = require("@eslint-community/eslint-utils")
/**
* @satisfies {import('../types.js').SupportVersionTraceMap}
*/
const WebCrypto = {
[READ]: { experimental: ["15.0.0"], supported: ["19.0.0"] },
subtle: {
[READ]: { supported: ["15.0.0"] },
decrypt: { [READ]: { supported: ["15.0.0"] } },
deriveBits: { [READ]: { supported: ["15.0.0"] } },
deriveKey: { [READ]: { supported: ["15.0.0"] } },
digest: { [READ]: { supported: ["15.0.0"] } },
encrypt: { [READ]: { supported: ["15.0.0"] } },
exportKey: { [READ]: { supported: ["15.0.0"] } },
generateKey: { [READ]: { supported: ["15.0.0"] } },
importKey: { [READ]: { supported: ["15.0.0"] } },
sign: { [READ]: { supported: ["15.0.0"] } },
unwrapKey: { [READ]: { supported: ["15.0.0"] } },
verify: { [READ]: { supported: ["15.0.0"] } },
wrapKey: { [READ]: { supported: ["15.0.0"] } },
},
getRandomValues: { [READ]: { supported: ["15.0.0"] } },
randomUUID: { [READ]: { supported: ["16.7.0"] } },
}
/**
* @satisfies {import('../types.js').SupportVersionTraceMap}
*/
const crypto = {
constants: { [READ]: { supported: ["6.3.0"] } },
fips: { [READ]: { supported: ["6.0.0"], deprecated: ["10.0.0"] } },
webcrypto: WebCrypto,
subtle: {
...WebCrypto.subtle,
[READ]: { experimental: ["17.4.0"], supported: ["19.0.0"] },
},
// methods and properties
checkPrime: { [READ]: { supported: ["15.8.0"] } },
checkPrimeSync: { [READ]: { supported: ["15.8.0"] } },
createCipher: { [READ]: { supported: ["0.1.94"], deprecated: ["10.0.0"] } },
createCipheriv: { [READ]: { supported: ["0.1.94"] } },
createDecipher: {
[READ]: { supported: ["0.1.94"], deprecated: ["10.0.0"] },
},
createDecipheriv: { [READ]: { supported: ["0.1.94"] } },
createDiffieHellman: { [READ]: { supported: ["0.11.12"] } },
createDiffieHellmanGroup: { [READ]: { supported: ["0.9.3"] } },
createECDH: { [READ]: { supported: ["0.11.14"] } },
createHash: { [READ]: { supported: ["0.1.92"] } },
createHmac: { [READ]: { supported: ["0.1.94"] } },
createPrivateKey: { [READ]: { supported: ["11.6.0"] } },
createPublicKey: { [READ]: { supported: ["11.6.0"] } },
createSecretKey: { [READ]: { supported: ["11.6.0"] } },
createSign: { [READ]: { supported: ["0.1.92"] } },
createVerify: { [READ]: { supported: ["0.1.92"] } },
diffieHellman: { [READ]: { supported: ["13.9.0", "12.17.0"] } },
generateKey: { [READ]: { supported: ["15.0.0"] } },
generateKeyPair: { [READ]: { supported: ["10.12.0"] } },
generateKeyPairSync: { [READ]: { supported: ["10.12.0"] } },
generateKeySync: { [READ]: { supported: ["15.0.0"] } },
generatePrime: { [READ]: { supported: ["15.8.0"] } },
generatePrimeSync: { [READ]: { supported: ["15.8.0"] } },
getCipherInfo: { [READ]: { supported: ["15.0.0"] } },
getCiphers: { [READ]: { supported: ["0.9.3"] } },
getCurves: { [READ]: { supported: ["2.3.0"] } },
getDiffieHellman: { [READ]: { supported: ["0.7.5"] } },
getFips: { [READ]: { supported: ["10.0.0"] } },
getHashes: { [READ]: { supported: ["0.9.3"] } },
getRandomValues: { [READ]: { supported: ["17.4.0"] } },
hash: { [READ]: { supported: ["20.12.0", "21.7.0"] } },
hkdf: { [READ]: { supported: ["15.0.0"] } },
hkdfSync: { [READ]: { supported: ["15.0.0"] } },
pbkdf2: { [READ]: { supported: ["0.5.5"] } },
pbkdf2Sync: { [READ]: { supported: ["0.9.3"] } },
privateDecrypt: { [READ]: { supported: ["0.11.14"] } },
privateEncrypt: { [READ]: { supported: ["1.1.0"] } },
publicDecrypt: { [READ]: { supported: ["1.1.0"] } },
publicEncrypt: { [READ]: { supported: ["0.11.14"] } },
randomBytes: { [READ]: { supported: ["0.5.8"] } },
randomFillSync: { [READ]: { supported: ["7.10.0", "6.13.0"] } },
randomFill: { [READ]: { supported: ["7.10.0", "6.13.0"] } },
randomInt: { [READ]: { supported: ["14.10.0", "12.19.0"] } },
randomUUID: { [READ]: { supported: ["15.6.0", "14.17.0"] } },
scrypt: { [READ]: { supported: ["10.5.0"] } },
scryptSync: { [READ]: { supported: ["10.5.0"] } },
secureHeapUsed: { [READ]: { supported: ["15.6.0"] } },
setEngine: { [READ]: { supported: ["0.11.11"] } },
setFips: { [READ]: { supported: ["10.0.0"] } },
sign: { [READ]: { supported: ["12.0.0"] } },
timingSafeEqual: { [READ]: { supported: ["6.6.0"] } },
verify: { [READ]: { supported: ["12.0.0"] } },
// Classes
Certificate: {
[READ]: { supported: ["0.11.8"] },
exportChallenge: { [READ]: { supported: ["9.0.0"] } },
exportPublicKey: { [READ]: { supported: ["9.0.0"] } },
verifySpkac: { [READ]: { supported: ["9.0.0"] } },
},
Cipher: { [READ]: { supported: ["0.1.94"] } },
Decipher: { [READ]: { supported: ["0.1.94"] } },
DiffieHellman: { [READ]: { supported: ["0.5.0"] } },
DiffieHellmanGroup: { [READ]: { supported: ["0.7.5"] } },
ECDH: {
[READ]: { supported: ["0.11.14"] },
convertKey: { [READ]: { supported: ["10.0.0"] } },
},
Hash: {
[READ]: { supported: ["0.1.92"] },
[CALL]: { deprecated: ["22.0.0", "20.13.0"] },
[CONSTRUCT]: { deprecated: ["22.0.0", "20.13.0"] },
},
Hmac: {
[READ]: { supported: ["0.1.94"] },
[CALL]: { deprecated: ["22.0.0", "20.13.0"] },
[CONSTRUCT]: { deprecated: ["22.0.0", "20.13.0"] },
},
KeyObject: {
[READ]: { supported: ["11.6.0"] },
from: { [READ]: { supported: ["15.0.0"] } },
},
Sign: { [READ]: { supported: ["0.1.92"] } },
Verify: { [READ]: { supported: ["0.1.92"] } },
X509Certificate: { [READ]: { supported: ["15.6.0"] } },
}
/**
* @satisfies {import('../types.js').SupportVersionTraceMap}
*/
module.exports = {
crypto: {
[READ]: { supported: ["0.1.92"] },
...crypto,
},
"node:crypto": {
[READ]: { supported: ["14.13.1", "12.20.0"] },
...crypto,
},
}
@@ -0,0 +1,27 @@
/*!
* remove-bom-buffer <https://github.com/jonschlinkert/remove-bom-buffer>
*
* Copyright (c) 2015-2017, Jon Schlinkert.
* Released under the MIT License.
*/
'use strict';
var isUTF8 = require('is-utf8');
var isBuffer = require('is-buffer');
function matchBOM(buf) {
return buf[0] === 0xEF && buf[1] === 0xBB && buf[2] === 0xBF;
}
function maybeUTF8(buf) {
// Only "maybe" because we aren't sniffing the whole buffer
return isUTF8(buf.slice(3, 7));
}
module.exports = function(buf) {
if (isBuffer(buf) && matchBOM(buf) && maybeUTF8(buf)) {
return buf.slice(3);
}
return buf;
};
@@ -0,0 +1,43 @@
{
"name": "clone-buffer",
"version": "1.0.0",
"description": "Easier Buffer cloning in node.",
"author": "Gulp Team <team@gulpjs.com> (http://gulpjs.com/)",
"contributors": [
"Blaine Bublitz <blaine.bublitz@gmail.com>"
],
"repository": "gulpjs/clone-buffer",
"license": "MIT",
"engines": {
"node": ">= 0.10"
},
"main": "index.js",
"files": [
"LICENSE",
"index.js"
],
"scripts": {
"lint": "eslint . && jscs index.js test/",
"pretest": "npm run lint",
"test": "mocha --async-only",
"cover": "istanbul cover _mocha --report lcovonly",
"coveralls": "npm run cover && istanbul-coveralls"
},
"dependencies": {},
"devDependencies": {
"eslint": "^1.7.3",
"eslint-config-gulp": "^2.0.0",
"expect": "^1.19.0",
"istanbul": "^0.4.3",
"istanbul-coveralls": "^1.0.3",
"jscs": "^2.3.5",
"jscs-preset-gulp": "^1.0.0",
"mocha": "^2.4.5"
},
"keywords": [
"buffer",
"clone",
"from",
"copy"
]
}
@@ -0,0 +1,37 @@
import { OneBotAction } from '../../action/OneBotAction';
import { OB11Message, OB11MessageNodePlain as OB11MessageNode } from '../../index';
import { Static } from '@sinclair/typebox';
declare const PayloadSchema: import("@sinclair/typebox").TObject<{
message_id: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
id: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
}>;
type PayloadType = Static<typeof PayloadSchema>;
declare const ReturnSchema: import("@sinclair/typebox").TObject<{
messages: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TUnknown>>;
}>;
type ReturnType = Static<typeof ReturnSchema>;
export declare class GoCQHTTPGetForwardMsgAction extends OneBotAction<PayloadType, ReturnType> {
actionName: "get_forward_msg";
payloadSchema: import("@sinclair/typebox").TObject<{
message_id: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
id: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
}>;
returnSchema: import("@sinclair/typebox").TObject<{
messages: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TUnknown>>;
}>;
actionSummary: string;
actionDescription: string;
actionTags: string[];
payloadExample: {
message_id: string;
};
returnExample: {
messages: never[];
};
private createTemplateNode;
parseForward(messages: OB11Message[]): Promise<OB11MessageNode[]>;
_handle(payload: PayloadType): Promise<{
messages: any;
}>;
}
export {};
@@ -0,0 +1,48 @@
{
"name": "@monaco-editor/loader",
"version": "1.6.1",
"description": "the library aims to setup monaco editor into your browser",
"main": "lib/cjs/index.js",
"module": "lib/es/index.js",
"unpkg": "lib/umd/monaco-loader.min.js",
"jsdelivr": "lib/umd/monaco-loader.min.js",
"types": "lib/types.d.ts",
"repository": "https://github.com/suren-atoyan/monaco-loader.git",
"homepage": "https://github.com/suren-atoyan/monaco-loader.git",
"author": "Suren Atoyan <contact@surenatoyan.com>",
"license": "MIT",
"scripts": {
"test": "jest",
"test-watch": "npm run build && jest --watch",
"coverage": "jest --collect-coverage",
"lint": "npx eslint src",
"prepublishOnly": "npm test && npm run lint && npm run build",
"build": "rollup -c && cp ./src/types.d.ts ./lib/",
"prepare": "husky"
},
"keywords": [
"monaco",
"editor",
"loader",
"monaco-editor",
"monaco editor"
],
"devDependencies": {
"@babel/core": "^7.25.0",
"@babel/preset-env": "^7.25.0",
"@rollup/plugin-babel": "^6.0.4",
"@rollup/plugin-commonjs": "^28.0.0",
"@rollup/plugin-node-resolve": "^15.3.0",
"@rollup/plugin-replace": "^6.0.1",
"@rollup/plugin-terser": "^0.4.4",
"babel-jest": "^29.7.0",
"babel-loader": "^9.2.1",
"eslint": "^9.14.0",
"husky": "^9.1.6",
"jest": "^29.7.0",
"rollup": "^4.24.0"
},
"dependencies": {
"state-local": "^1.0.6"
}
}
@@ -0,0 +1,205 @@
/**
* @fileoverview Rule to validate spacing before function paren.
* @author Mathias Schreck <https://github.com/lo1tuma>
* @deprecated in ESLint v8.53.0
*/
"use strict";
//------------------------------------------------------------------------------
// Requirements
//------------------------------------------------------------------------------
const astUtils = require("./utils/ast-utils");
//------------------------------------------------------------------------------
// Rule Definition
//------------------------------------------------------------------------------
/** @type {import('../types').Rule.RuleModule} */
module.exports = {
meta: {
deprecated: {
message: "Formatting rules are being moved out of ESLint core.",
url: "https://eslint.org/blog/2023/10/deprecating-formatting-rules/",
deprecatedSince: "8.53.0",
availableUntil: "11.0.0",
replacedBy: [
{
message:
"ESLint Stylistic now maintains deprecated stylistic core rules.",
url: "https://eslint.style/guide/migration",
plugin: {
name: "@stylistic/eslint-plugin",
url: "https://eslint.style",
},
rule: {
name: "space-before-function-paren",
url: "https://eslint.style/rules/space-before-function-paren",
},
},
],
},
type: "layout",
docs: {
description:
"Enforce consistent spacing before `function` definition opening parenthesis",
recommended: false,
url: "https://eslint.org/docs/latest/rules/space-before-function-paren",
},
fixable: "whitespace",
schema: [
{
oneOf: [
{
enum: ["always", "never"],
},
{
type: "object",
properties: {
anonymous: {
enum: ["always", "never", "ignore"],
},
named: {
enum: ["always", "never", "ignore"],
},
asyncArrow: {
enum: ["always", "never", "ignore"],
},
},
additionalProperties: false,
},
],
},
],
messages: {
unexpectedSpace: "Unexpected space before function parentheses.",
missingSpace: "Missing space before function parentheses.",
},
},
create(context) {
const sourceCode = context.sourceCode;
const baseConfig =
typeof context.options[0] === "string"
? context.options[0]
: "always";
const overrideConfig =
typeof context.options[0] === "object" ? context.options[0] : {};
/**
* Determines whether a function has a name.
* @param {ASTNode} node The function node.
* @returns {boolean} Whether the function has a name.
*/
function isNamedFunction(node) {
if (node.id) {
return true;
}
const parent = node.parent;
return (
parent.type === "MethodDefinition" ||
(parent.type === "Property" &&
(parent.kind === "get" ||
parent.kind === "set" ||
parent.method))
);
}
/**
* Gets the config for a given function
* @param {ASTNode} node The function node
* @returns {string} "always", "never", or "ignore"
*/
function getConfigForFunction(node) {
if (node.type === "ArrowFunctionExpression") {
// Always ignore non-async functions and arrow functions without parens, e.g. async foo => bar
if (
node.async &&
astUtils.isOpeningParenToken(
sourceCode.getFirstToken(node, { skip: 1 }),
)
) {
return overrideConfig.asyncArrow || baseConfig;
}
} else if (isNamedFunction(node)) {
return overrideConfig.named || baseConfig;
// `generator-star-spacing` should warn anonymous generators. E.g. `function* () {}`
} else if (!node.generator) {
return overrideConfig.anonymous || baseConfig;
}
return "ignore";
}
/**
* Checks the parens of a function node
* @param {ASTNode} node A function node
* @returns {void}
*/
function checkFunction(node) {
const functionConfig = getConfigForFunction(node);
if (functionConfig === "ignore") {
return;
}
const rightToken = sourceCode.getFirstToken(
node,
astUtils.isOpeningParenToken,
);
const leftToken = sourceCode.getTokenBefore(rightToken);
const hasSpacing = sourceCode.isSpaceBetweenTokens(
leftToken,
rightToken,
);
if (hasSpacing && functionConfig === "never") {
context.report({
node,
loc: {
start: leftToken.loc.end,
end: rightToken.loc.start,
},
messageId: "unexpectedSpace",
fix(fixer) {
const comments =
sourceCode.getCommentsBefore(rightToken);
// Don't fix anything if there's a single line comment between the left and the right token
if (comments.some(comment => comment.type === "Line")) {
return null;
}
return fixer.replaceTextRange(
[leftToken.range[1], rightToken.range[0]],
comments.reduce(
(text, comment) =>
text + sourceCode.getText(comment),
"",
),
);
},
});
} else if (!hasSpacing && functionConfig === "always") {
context.report({
node,
loc: rightToken.loc,
messageId: "missingSpace",
fix: fixer => fixer.insertTextAfter(leftToken, " "),
});
}
}
return {
ArrowFunctionExpression: checkFunction,
FunctionDeclaration: checkFunction,
FunctionExpression: checkFunction,
};
},
};
@@ -0,0 +1,152 @@
/**
* Copyright (c) 2017 The xterm.js authors. All rights reserved.
* @license MIT
*/
import { IRenderDimensions } from 'browser/renderer/shared/Types';
import { BaseRenderLayer } from './BaseRenderLayer';
import { IBufferService, IDecorationService, IOptionsService } from 'common/services/Services';
import { ICoreBrowserService, IThemeService } from 'browser/services/Services';
import { Terminal } from '@xterm/xterm';
interface ISelectionState {
start?: [number, number];
end?: [number, number];
columnSelectMode?: boolean;
ydisp?: number;
}
export class SelectionRenderLayer extends BaseRenderLayer {
private _state!: ISelectionState;
constructor(
terminal: Terminal,
container: HTMLElement,
zIndex: number,
bufferService: IBufferService,
coreBrowserService: ICoreBrowserService,
decorationService: IDecorationService,
optionsService: IOptionsService,
themeService: IThemeService
) {
super(terminal, container, 'selection', zIndex, true, themeService, bufferService, optionsService, decorationService, coreBrowserService);
this._clearState();
}
private _clearState(): void {
this._state = {
start: undefined,
end: undefined,
columnSelectMode: undefined,
ydisp: undefined
};
}
public resize(dim: IRenderDimensions): void {
super.resize(dim);
// On resize use the base render layer's cached selection values since resize clears _state
// inside reset.
if (this._selectionModel.selectionStart && this._selectionModel.selectionEnd) {
this._clearState();
this._redrawSelection(this._selectionModel.selectionStart, this._selectionModel.selectionEnd, this._selectionModel.columnSelectMode);
}
}
public reset(): void {
if (this._state.start && this._state.end) {
this._clearState();
this._clearAll();
}
}
public handleBlur(): void {
this.reset();
this._redrawSelection(this._selectionModel.selectionStart, this._selectionModel.selectionEnd, this._selectionModel.columnSelectMode);
}
public handleFocus(): void {
this.reset();
this._redrawSelection(this._selectionModel.selectionStart, this._selectionModel.selectionEnd, this._selectionModel.columnSelectMode);
}
public handleSelectionChanged(start: [number, number] | undefined, end: [number, number] | undefined, columnSelectMode: boolean): void {
super.handleSelectionChanged(start, end, columnSelectMode);
this._redrawSelection(start, end, columnSelectMode);
}
private _redrawSelection(start: [number, number] | undefined, end: [number, number] | undefined, columnSelectMode: boolean): void {
// Selection has not changed
if (!this._didStateChange(start, end, columnSelectMode, this._bufferService.buffer.ydisp)) {
return;
}
// Remove all selections
this._clearAll();
// Selection does not exist
if (!start || !end) {
this._clearState();
return;
}
// Translate from buffer position to viewport position
const viewportStartRow = start[1] - this._bufferService.buffer.ydisp;
const viewportEndRow = end[1] - this._bufferService.buffer.ydisp;
const viewportCappedStartRow = Math.max(viewportStartRow, 0);
const viewportCappedEndRow = Math.min(viewportEndRow, this._bufferService.rows - 1);
// No need to draw the selection
if (viewportCappedStartRow >= this._bufferService.rows || viewportCappedEndRow < 0) {
this._state.ydisp = this._bufferService.buffer.ydisp;
return;
}
this._ctx.fillStyle = (this._coreBrowserService.isFocused
? this._themeService.colors.selectionBackgroundTransparent
: this._themeService.colors.selectionInactiveBackgroundTransparent).css;
if (columnSelectMode) {
const startCol = start[0];
const width = end[0] - startCol;
const height = viewportCappedEndRow - viewportCappedStartRow + 1;
this._fillCells(startCol, viewportCappedStartRow, width, height);
} else {
// Draw first row
const startCol = viewportStartRow === viewportCappedStartRow ? start[0] : 0;
const startRowEndCol = viewportCappedStartRow === viewportEndRow ? end[0] : this._bufferService.cols;
this._fillCells(startCol, viewportCappedStartRow, startRowEndCol - startCol, 1);
// Draw middle rows
const middleRowsCount = Math.max(viewportCappedEndRow - viewportCappedStartRow - 1, 0);
this._fillCells(0, viewportCappedStartRow + 1, this._bufferService.cols, middleRowsCount);
// Draw final row
if (viewportCappedStartRow !== viewportCappedEndRow) {
// Only draw viewportEndRow if it's not the same as viewportStartRow
const endCol = viewportEndRow === viewportCappedEndRow ? end[0] : this._bufferService.cols;
this._fillCells(0, viewportCappedEndRow, endCol, 1);
}
}
// Save state for next render
this._state.start = [start[0], start[1]];
this._state.end = [end[0], end[1]];
this._state.columnSelectMode = columnSelectMode;
this._state.ydisp = this._bufferService.buffer.ydisp;
}
private _didStateChange(start: [number, number] | undefined, end: [number, number] | undefined, columnSelectMode: boolean, ydisp: number): boolean {
return !this._areCoordinatesEqual(start, this._state.start) ||
!this._areCoordinatesEqual(end, this._state.end) ||
columnSelectMode !== this._state.columnSelectMode ||
ydisp !== this._state.ydisp;
}
private _areCoordinatesEqual(coord1: [number, number] | undefined, coord2: [number, number] | undefined): boolean {
if (!coord1 || !coord2) {
return false;
}
return coord1[0] === coord2[0] && coord1[1] === coord2[1];
}
}
@@ -0,0 +1,8 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.FormatNumeric = FormatNumeric;
var PartitionNumberPattern_1 = require("./PartitionNumberPattern");
function FormatNumeric(internalSlots, x) {
var parts = (0, PartitionNumberPattern_1.PartitionNumberPattern)(internalSlots, x);
return parts.map(function (p) { return p.value; }).join('');
}
@@ -0,0 +1 @@
{"mappings":";;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;AAmCM,SAAS,0CAAY,KAAwB,EAAE,KAAkB,EAAE,QAA4C;IACpH,+FAA+F;IAC/F,IAAI,kBAAkB,CAAA,GAAA,8CAAqB,EAAE;QAAC,GAAG,KAAK;QAAE,OAAO,MAAM,UAAU;IAAA;IAC/E,IAAI,aAAC,SAAS,oBAAE,gBAAgB,qBAAE,iBAAiB,EAAC,GAAG,gBAAgB,iBAAiB;IACxF,IAAI,cAAC,UAAU,cAAE,UAAU,cAAE,UAAU,aAAE,SAAS,cAAE,UAAU,cAAE,UAAU,EAAC,GAAG,CAAA,GAAA,gCAAQ,EAAE;QACtF,GAAG,KAAK;mBACR;IACF,GAAG,OAAO;IAEV,CAAA,GAAA,sCAAgB,EAAE,OAAO,iBAAiB;IAE1C,IAAI,mBAAC,eAAe,cAAE,UAAU,sBAAE,qBAAqB,QAAO,GAAG;IACjE,CAAA,GAAA,sBAAQ,EAAE;QACR,qEAAqE;QACrE,mDAAmD;QACnD,IAAI,SAAS,OAAO,EAClB,SAAS,OAAO,CAAC,aAAa,GAAG,CAAC,CAAC;IAEvC;IAEA,0EAA0E;IAC1E,IAAI,cAAC,UAAU,EAAC,GAAG,CAAA,GAAA,qCAAO,EAAE;QAC1B,YAAY,cAAc;QAC1B;YACE,mBAAmB;YACnB,IAAI,EAAC,CAAC,CAAA,GAAA,kDAAyB,EAAE,EAAE,oBAAoB,EAAC,GAAG;YAE3D,IAAI,oBAAC,gBAAgB,EAAC,GAAG,uBACvB,uBACA;YAEF;QACF;IACF;IAEA,OAAO;QACL,YAAY,CAAA,GAAA,gCAAS,EACnB,YACA,YACA,CAAA,GAAA,oBAAM,EAAE,IAAO,CAAA;gBACb,0DAA0D;gBAC1D,iFAAiF;gBACjF,aAAa,CAAA,IAAK,EAAE,cAAc;YACpC,CAAA,GAAI,EAAE;QACR,YAAY;YACV,GAAG,UAAU;YACb,SAAS;YACT,iBAAiB,AAAC,cAAc,uBAAuB,UAAW;YAClE,UAAU,cAAc,uBAAuB;QACjD;oBACA;mBACA;oBACA;oBACA;mBACA;0BACA;2BACA;IACF;AACF","sources":["packages/@react-aria/checkbox/src/useCheckbox.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 {AriaCheckboxProps} from '@react-types/checkbox';\nimport {InputHTMLAttributes, LabelHTMLAttributes, useEffect, useMemo} from 'react';\nimport {mergeProps} from '@react-aria/utils';\nimport {privateValidationStateProp, useFormValidationState} from '@react-stately/form';\nimport {RefObject, ValidationResult} from '@react-types/shared';\nimport {ToggleState} from '@react-stately/toggle';\nimport {useFormValidation} from '@react-aria/form';\nimport {usePress} from '@react-aria/interactions';\nimport {useToggle} from '@react-aria/toggle';\n\nexport interface CheckboxAria extends ValidationResult {\n /** Props for the label wrapper element. */\n labelProps: LabelHTMLAttributes<HTMLLabelElement>,\n /** Props for the input element. */\n inputProps: InputHTMLAttributes<HTMLInputElement>,\n /** Whether the checkbox is selected. */\n isSelected: boolean,\n /** Whether the checkbox is in a pressed state. */\n isPressed: boolean,\n /** Whether the checkbox is disabled. */\n isDisabled: boolean,\n /** Whether the checkbox is read only. */\n isReadOnly: boolean\n}\n\n/**\n * Provides the behavior and accessibility implementation for a checkbox component.\n * Checkboxes allow users to select multiple items from a list of individual items, or\n * to mark one individual item as selected.\n * @param props - Props for the checkbox.\n * @param state - State for the checkbox, as returned by `useToggleState`.\n * @param inputRef - A ref for the HTML input element.\n */\nexport function useCheckbox(props: AriaCheckboxProps, state: ToggleState, inputRef: RefObject<HTMLInputElement | null>): CheckboxAria {\n // Create validation state here because it doesn't make sense to add to general useToggleState.\n let validationState = useFormValidationState({...props, value: state.isSelected});\n let {isInvalid, validationErrors, validationDetails} = validationState.displayValidation;\n let {labelProps, inputProps, isSelected, isPressed, isDisabled, isReadOnly} = useToggle({\n ...props,\n isInvalid\n }, state, inputRef);\n\n useFormValidation(props, validationState, inputRef);\n\n let {isIndeterminate, isRequired, validationBehavior = 'aria'} = props;\n useEffect(() => {\n // indeterminate is a property, but it can only be set via javascript\n // https://css-tricks.com/indeterminate-checkboxes/\n if (inputRef.current) {\n inputRef.current.indeterminate = !!isIndeterminate;\n }\n });\n\n // Reset validation state on label press for checkbox with a hidden input.\n let {pressProps} = usePress({\n isDisabled: isDisabled || isReadOnly,\n onPress() {\n // @ts-expect-error\n let {[privateValidationStateProp]: groupValidationState} = props;\n\n let {commitValidation} = groupValidationState\n ? groupValidationState\n : validationState;\n\n commitValidation();\n }\n });\n\n return {\n labelProps: mergeProps(\n labelProps,\n pressProps,\n useMemo(() => ({\n // Prevent label from being focused when mouse down on it.\n // Note, this does not prevent the input from being focused in the `click` evLine truncated
Loaded 100 of 35554 files, more files were not shown because too many files have changed in this diff. Show more