docs: 仓库链接指向本镜像仓库
Build NapCat Artifacts / Windows Loader Test (push) Canceled after 0s
Build NapCat Artifacts / Type Check & Test (push) Canceled after 0s
Build NapCat Artifacts / Build NapCat.Framework (push) Canceled after 0s
Build NapCat Artifacts / Build NapCat.Shell (push) Canceled after 0s

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

No files matched your search

@@ -0,0 +1,2 @@
export {};
//# sourceMappingURL=curryBuildPlanServiceNode.spec.d.ts.map
@@ -0,0 +1 @@
module.exports={C:{"38":0.0023,"68":0.0023,"109":0.0023,"115":0.1196,"121":0.0069,"127":0.0023,"128":0.0161,"129":0.0023,"132":0.0023,"135":0.0184,"137":0.0023,"139":0.0023,"140":0.0115,"141":0.0046,"142":0.0069,"143":0.1886,"144":0.1679,"145":0.0023,_:"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 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 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 110 111 112 113 114 116 117 118 119 120 122 123 124 125 126 130 131 133 134 136 138 146 147 3.5 3.6"},D:{"39":0.0023,"40":0.0023,"41":0.0023,"42":0.0023,"43":0.0023,"44":0.0023,"45":0.0023,"46":0.0023,"47":0.0023,"48":0.0023,"49":0.0023,"50":0.0023,"51":0.0069,"52":0.0023,"53":0.0023,"54":0.0023,"55":0.0023,"56":0.0023,"57":0.0023,"58":0.0046,"59":0.0023,"60":0.0046,"63":0.0069,"68":0.0023,"70":0.0092,"71":0.0092,"72":0.0023,"73":0.0161,"74":0.0023,"75":0.0069,"76":0.0023,"78":0.0069,"79":0.0161,"80":0.0023,"81":0.0161,"83":0.0184,"84":0.0023,"85":0.0023,"86":0.0138,"87":0.0322,"88":0.0046,"89":0.0023,"90":0.0092,"91":0.0184,"92":0.0023,"93":0.0046,"94":0.0046,"95":0.0023,"96":0.0138,"97":0.0023,"98":0.0184,"99":0.0023,"100":0.0092,"101":0.0092,"102":0.0023,"103":0.0368,"104":0.0207,"105":0.0023,"106":0.0046,"108":0.0115,"109":1.0327,"110":0.0092,"111":0.0161,"112":0.0023,"113":0.0023,"114":0.0138,"115":0.0023,"116":0.0161,"118":0.0046,"119":0.0046,"120":0.0138,"121":0.0069,"122":0.0138,"123":0.046,"124":0.0092,"125":1.5042,"126":0.0138,"127":0.0184,"128":0.0092,"129":0.0069,"130":0.0115,"131":0.0943,"132":0.0138,"133":0.0115,"134":0.0161,"135":0.0345,"136":0.0437,"137":0.0851,"138":0.1311,"139":0.1886,"140":1.9366,"141":4.6667,"142":0.046,"143":0.0023,_:"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 61 62 64 65 66 67 69 77 107 117 144 145"},F:{"40":0.0023,"46":0.0023,"73":0.0046,"79":0.0161,"81":0.0092,"82":0.0023,"84":0.0046,"85":0.0069,"90":0.0023,"91":0.0713,"92":0.1081,"95":0.0345,"114":0.0023,"117":0.0023,"119":0.0023,"120":0.046,"121":0.0322,"122":0.4715,_:"9 11 12 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 41 42 43 44 45 47 48 49 50 51 52 53 54 55 56 57 58 60 62 63 64 65 66 67 68 69 70 71 72 74 75 76 77 78 80 83 86 87 88 89 93 94 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 115 116 118 9.5-9.6 10.0-10.1 10.5 10.6 11.1 11.5 11.6 12.1"},B:{"13":0.0023,"14":0.0023,"15":0.0023,"16":0.0023,"18":0.0115,"84":0.0023,"89":0.0023,"90":0.0023,"92":0.0276,"100":0.0046,"109":0.0184,"114":0.2001,"122":0.0046,"123":0.0115,"129":0.0023,"130":0.0023,"131":0.023,"132":0.0023,"133":0.0023,"134":0.0368,"135":0.0023,"136":0.0069,"137":0.0046,"138":0.0161,"139":0.0207,"140":0.3105,"141":1.4835,"142":0.0046,_:"12 17 79 80 81 83 85 86 87 88 91 93 94 95 96 97 98 99 101 102 103 104 105 106 107 108 110 111 112 113 115 116 117 118 119 120 121 124 125 126 127 128"},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 12.1 13.1 15.1 15.2-15.3 15.4 15.5 16.0 16.3 16.4 16.5 26.2","5.1":0.0253,"14.1":0.322,"15.6":0.0069,"16.1":0.0115,"16.2":0.0023,"16.6":0.0138,"17.0":0.0046,"17.1":0.0046,"17.2":0.0046,"17.3":0.0046,"17.4":0.0046,"17.5":0.0046,"17.6":0.023,"18.0":0.0023,"18.1":0.0092,"18.2":0.0023,"18.3":0.0069,"18.4":0.0046,"18.5-18.6":0.023,"26.0":0.0713,"26.1":0.0023},G:{"8":0,"3.2":0,"4.0-4.1":0,"4.2-4.3":0.00096,"5.0-5.1":0,"6.0-6.1":0.00384,"7.0-7.1":0.00288,"8.1-8.4":0,"9.0-9.2":0,"9.3":0.00865,"10.0-10.2":0.00096,"10.3":0.01633,"11.0-11.2":0.24213,"11.3-11.4":0.00577,"12.0-12.1":0.00192,"12.2-12.5":0.04708,"13.0-13.1":0,"13.2":0.0048,"13.3":0.00192,"13.4-13.7":0.00769,"14.0-14.4":0.01633,"14.5-14.8":0.0173,"15.0-15.1":0.01633,"15.2-15.3":0.01249,"15.4":0.01441,"15.5":0.01633,"15.6-15.8":0.21331,"16.0":0.02883,"16.1":0.05381,"16.2":0.02786,"16.3":0.04996,"16.4":0.01249,"16.5":0.0221,"16.6-16.7":0.28537,"17.0":0.02018,"17.1":0.03075,"17.2":0.0221,"17.3":0.03267,"17.4":0.05765,"17.5":0.09897,"17.6-17.7":0.24982,"18.0":0.05669,"18.1":0.11722,"18.2":0.06342,"18.3":0.2037,"18.4":0.10473,"18.5-18.6":5.34032,"26.0":0.66009,"26.1":0.02402},P:{"4":0.02043,"20":0.01021,"21":0.03064,"22":0.08171,"23":0.06128,"24":0.26556,"25":0.33705,"26":0.16342,"27":0.4494,"28":2.50235,"29":0.12256,_:"5.0-5.4 8.2 10.1","6.2-6.4":0.02043,"7.2-7.4":0.19406,"9.2":0.02043,"11.1-11.2":0.02043,"12.0":0.01021,"13.0":0.01021,"14.0":0.02043,"15.0":0.01021,"16.0":0.03064,"17.0":0.04085,"18.0":0.05107,"19.0":0.09192},I:{"0":0.02306,"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":5.96752,_:"10 11 12 11.1 11.5 12.1"},A:{"11":0.0092,_:"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.16938},Q:{_:"14.9"},O:{"0":0.17708},H:{"0":0.03},L:{"0":63.84712}};
@@ -0,0 +1,70 @@
"use strict";
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
var desc = Object.getOwnPropertyDescriptor(m, k);
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
desc = { enumerable: true, get: function() { return m[k]; } };
}
Object.defineProperty(o, k2, desc);
}) : (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
o[k2] = m[k];
}));
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
Object.defineProperty(o, "default", { enumerable: true, value: v });
}) : function(o, v) {
o["default"] = v;
});
var __importStar = (this && this.__importStar) || (function () {
var ownKeys = function(o) {
ownKeys = Object.getOwnPropertyNames || function (o) {
var ar = [];
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
return ar;
};
return ownKeys(o);
};
return function (mod) {
if (mod && mod.__esModule) return mod;
var result = {};
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
__setModuleDefault(result, mod);
return result;
};
})();
Object.defineProperty(exports, "__esModule", { value: true });
exports.getTypeFlags = getTypeFlags;
exports.isTypeFlagSet = isTypeFlagSet;
const tsutils = __importStar(require("ts-api-utils"));
const ts = __importStar(require("typescript"));
const ANY_OR_UNKNOWN = ts.TypeFlags.Any | ts.TypeFlags.Unknown;
/**
* Gets all of the type flags in a type, iterating through unions automatically.
*/
function getTypeFlags(type) {
// @ts-expect-error Since typescript 5.0, this is invalid, but uses 0 as the default value of TypeFlags.
let flags = 0;
for (const t of tsutils.unionConstituents(type)) {
flags |= t.flags;
}
return flags;
}
/**
* @param flagsToCheck The composition of one or more `ts.TypeFlags`.
* @param isReceiver Whether the type is a receiving type (e.g. the type of a
* called function's parameter).
* @remarks
* Note that if the type is a union, this function will decompose it into the
* parts and get the flags of every union constituent. If this is not desired,
* use the `isTypeFlag` function from tsutils.
*/
function isTypeFlagSet(type, flagsToCheck,
/** @deprecated This params is not used and will be removed in the future.*/
isReceiver) {
const flags = getTypeFlags(type);
// eslint-disable-next-line @typescript-eslint/no-deprecated -- not used
if (isReceiver && flags & ANY_OR_UNKNOWN) {
return true;
}
return (flags & flagsToCheck) !== 0;
}
@@ -0,0 +1,63 @@
import {useUNSTABLE_PortalContext as $96b38030c423d352$export$574e9b0fb070c3b0} from "./PortalProvider.module.js";
import {ClearPressResponder as $1CM7W$ClearPressResponder} from "@react-aria/interactions";
import {FocusScope as $1CM7W$FocusScope} from "@react-aria/focus";
import $1CM7W$react, {useState as $1CM7W$useState, useMemo as $1CM7W$useMemo, useContext as $1CM7W$useContext} from "react";
import $1CM7W$reactdom from "react-dom";
import {useIsSSR as $1CM7W$useIsSSR} from "@react-aria/ssr";
import {useLayoutEffect as $1CM7W$useLayoutEffect} from "@react-aria/utils";
/*
* 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.
*/
const $337b884510726a0d$export$a2200b96afd16271 = /*#__PURE__*/ (0, $1CM7W$react).createContext(null);
function $337b884510726a0d$export$c6fdb837b070b4ff(props) {
let isSSR = (0, $1CM7W$useIsSSR)();
let { portalContainer: portalContainer = isSSR ? null : document.body, isExiting: isExiting } = props;
let [contain, setContain] = (0, $1CM7W$useState)(false);
let contextValue = (0, $1CM7W$useMemo)(()=>({
contain: contain,
setContain: setContain
}), [
contain,
setContain
]);
let { getContainer: getContainer } = (0, $96b38030c423d352$export$574e9b0fb070c3b0)();
if (!props.portalContainer && getContainer) portalContainer = getContainer();
if (!portalContainer) return null;
let contents = props.children;
if (!props.disableFocusManagement) contents = /*#__PURE__*/ (0, $1CM7W$react).createElement((0, $1CM7W$FocusScope), {
restoreFocus: true,
contain: contain && !isExiting
}, contents);
contents = /*#__PURE__*/ (0, $1CM7W$react).createElement($337b884510726a0d$export$a2200b96afd16271.Provider, {
value: contextValue
}, /*#__PURE__*/ (0, $1CM7W$react).createElement((0, $1CM7W$ClearPressResponder), null, contents));
return /*#__PURE__*/ (0, $1CM7W$reactdom).createPortal(contents, portalContainer);
}
function $337b884510726a0d$export$14c98a7594375490() {
let ctx = (0, $1CM7W$useContext)($337b884510726a0d$export$a2200b96afd16271);
let setContain = ctx === null || ctx === void 0 ? void 0 : ctx.setContain;
(0, $1CM7W$useLayoutEffect)(()=>{
setContain === null || setContain === void 0 ? void 0 : setContain(true);
}, [
setContain
]);
}
export {$337b884510726a0d$export$a2200b96afd16271 as OverlayContext, $337b884510726a0d$export$c6fdb837b070b4ff as Overlay, $337b884510726a0d$export$14c98a7594375490 as useOverlayFocusContain};
//# sourceMappingURL=Overlay.module.js.map
@@ -0,0 +1,58 @@
/**
* @author Toru Nagashima
* See LICENSE file in root directory for full license.
*/
"use strict"
const fs = require("fs")
const path = require("path")
const Cache = require("./cache")
const ROOT = /^(?:[/.]|\.\.|[A-Z]:\\|\\\\)(?:[/\\]\.\.)*$/u
const cache = new Cache()
/**
* Check whether the file exists or not.
* @param {string} filePath The file path to check.
* @returns {boolean} `true` if the file exists.
*/
function existsCaseSensitive(filePath) {
let dirPath = filePath
while (dirPath !== "" && !ROOT.test(dirPath)) {
const fileName = path.basename(dirPath)
dirPath = path.dirname(dirPath)
if (fs.readdirSync(dirPath).indexOf(fileName) === -1) {
return false
}
}
return true
}
/**
* Checks whether or not the file of a given path exists.
*
* @param {string} filePath - A file path to check.
* @returns {boolean} `true` if the file of a given path exists.
*/
module.exports = function exists(filePath) {
let result = cache.get(filePath)
if (result == null) {
try {
const relativePath = path.relative(process.cwd(), filePath)
result =
fs.statSync(relativePath).isFile() &&
existsCaseSensitive(relativePath)
} catch (error) {
if (error.code !== "ENOENT") {
throw error
}
result = false
}
cache.set(filePath, result)
}
return result
}
@@ -0,0 +1,54 @@
{
"name": "@heroui/framer-utils",
"version": "2.1.23",
"description": "A set of framer motion transitions for react",
"keywords": [
"framer-utils"
],
"author": "HeroUI <support@heroui.com>",
"homepage": "https://heroui.com",
"license": "MIT",
"main": "dist/index.js",
"sideEffects": false,
"files": [
"dist"
],
"publishConfig": {
"access": "public"
},
"repository": {
"type": "git",
"url": "git+https://github.com/heroui-inc/heroui.git",
"directory": "packages/utilities/framer-utils"
},
"bugs": {
"url": "https://github.com/heroui-inc/heroui/issues"
},
"peerDependencies": {
"react": ">=18 || >=19.0.0-rc.0",
"react-dom": ">=18 || >=19.0.0-rc.0",
"framer-motion": ">=11.5.6 || >=12.0.0-alpha.1"
},
"dependencies": {
"@heroui/system": "2.4.23",
"@heroui/use-measure": "2.1.8"
},
"clean-package": "../../../clean-package.config.json",
"module": "dist/index.mjs",
"types": "dist/index.d.ts",
"exports": {
".": {
"types": "./dist/index.d.ts",
"import": "./dist/index.mjs",
"require": "./dist/index.js"
},
"./package.json": "./package.json"
},
"scripts": {
"build": "tsup src --dts",
"build:fast": "tsup src",
"dev": "pnpm build:fast --watch",
"clean": "rimraf dist .turbo",
"typecheck": "tsc --noEmit"
}
}
@@ -0,0 +1,21 @@
MIT License
Copyright (c) 2020 Evan Wallace
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 @@
{"version":3,"file":"useController.d.ts","sourceRoot":"","sources":["../src/useController.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAGV,SAAS,EAET,WAAW,EAEX,kBAAkB,EAClB,mBAAmB,EACpB,MAAM,SAAS,CAAC;AAKjB;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,wBAAgB,aAAa,CAC3B,YAAY,SAAS,WAAW,GAAG,WAAW,EAC9C,KAAK,SAAS,SAAS,CAAC,YAAY,CAAC,GAAG,SAAS,CAAC,YAAY,CAAC,EAC/D,kBAAkB,GAAG,YAAY,EAEjC,KAAK,EAAE,kBAAkB,CAAC,YAAY,EAAE,KAAK,EAAE,kBAAkB,CAAC,GACjE,mBAAmB,CAAC,YAAY,EAAE,KAAK,CAAC,CAuM1C"}
@@ -0,0 +1,18 @@
// src/console.ts
var warningStack = {};
function warn(message, component, ...args) {
const tag = component ? ` [${component}]` : " ";
const log = `[Next UI]${tag}: ${message}`;
if (typeof console === "undefined")
return;
if (warningStack[log])
return;
warningStack[log] = true;
if (process.env.NODE_ENV !== "production") {
return console.warn(log, args);
}
}
export {
warn
};
@@ -0,0 +1,67 @@
{
"name": "prebuild-install",
"version": "7.1.3",
"description": "A command line tool to easily install prebuilt binaries for multiple version of node/iojs on a specific platform",
"scripts": {
"test": "standard && hallmark && tape test/*-test.js",
"hallmark": "hallmark --fix"
},
"keywords": [
"prebuilt",
"binaries",
"native",
"addon",
"module",
"c",
"c++",
"bindings",
"devops",
"napi"
],
"dependencies": {
"detect-libc": "^2.0.0",
"expand-template": "^2.0.3",
"github-from-package": "0.0.0",
"minimist": "^1.2.3",
"mkdirp-classic": "^0.5.3",
"napi-build-utils": "^2.0.0",
"node-abi": "^3.3.0",
"pump": "^3.0.0",
"rc": "^1.2.7",
"simple-get": "^4.0.0",
"tar-fs": "^2.0.0",
"tunnel-agent": "^0.6.0"
},
"devDependencies": {
"a-native-module": "^1.0.0",
"hallmark": "^4.0.0",
"nock": "^10.0.6",
"rimraf": "^2.5.2",
"standard": "^16.0.4",
"tape": "^5.3.1",
"tempy": "0.2.1"
},
"bin": "./bin.js",
"repository": {
"type": "git",
"url": "https://github.com/prebuild/prebuild-install.git"
},
"author": "Mathias Buus (@mafintosh)",
"contributors": [
"Julian Gruber <julian@juliangruber.com> (https://github.com/juliangruber)",
"Brett Lawson <brett19@gmail.com> (https://github.com/brett19)",
"Pieter Hintjens <ph@imatix.com> (https://github.com/hintjens)",
"Lars-Magnus Skog <ralphtheninja@riseup.net> (https://github.com/ralphtheninja)",
"Jesús Leganés Combarro <piranna@gmail.com> (https://github.com/piranna)",
"Mathias Küsel <mathiask@hotmail.de> (https://github.com/mathiask88)",
"Lukas Geiger <lukas.geiger94@gmail.com> (https://github.com/lgeiger)"
],
"license": "MIT",
"bugs": {
"url": "https://github.com/prebuild/prebuild-install/issues"
},
"homepage": "https://github.com/prebuild/prebuild-install",
"engines": {
"node": ">=10"
}
}
@@ -0,0 +1,802 @@
# remark-rehype
[![Build][badge-build-image]][badge-build-url]
[![Coverage][badge-coverage-image]][badge-coverage-url]
[![Downloads][badge-downloads-image]][badge-downloads-url]
[![Size][badge-size-image]][badge-size-url]
**[remark][github-remark]** plugin that turns markdown into HTML to support
**[rehype][github-rehype]**.
## Contents
* [What is this?](#what-is-this)
* [When should I use this?](#when-should-i-use-this)
* [Install](#install)
* [Use](#use)
* [API](#api)
* [`defaultFootnoteBackContent(referenceIndex, rereferenceIndex)`](#defaultfootnotebackcontentreferenceindex-rereferenceindex)
* [`defaultFootnoteBackLabel(referenceIndex, rereferenceIndex)`](#defaultfootnotebacklabelreferenceindex-rereferenceindex)
* [`defaultHandlers`](#defaulthandlers)
* [`unified().use(remarkRehype[, destination][, options])`](#unifieduseremarkrehype-destination-options)
* [`Options`](#options)
* [Examples](#examples)
* [Example: supporting HTML in markdown naïvely](#example-supporting-html-in-markdown-naïvely)
* [Example: supporting HTML in markdown properly](#example-supporting-html-in-markdown-properly)
* [Example: footnotes in languages other than English](#example-footnotes-in-languages-other-than-english)
* [HTML](#html-1)
* [CSS](#css)
* [Syntax tree](#syntax-tree)
* [Types](#types)
* [Compatibility](#compatibility)
* [Security](#security)
* [Related](#related)
* [Contribute](#contribute)
* [License](#license)
## What is this?
This package is a [unified][github-unified] ([remark][github-remark])
plugin that switches from remark (the markdown ecosystem)
to rehype (the HTML ecosystem).
It does this by transforming the current markdown (mdast) syntax tree into an
HTML (hast) syntax tree.
remark plugins deal with mdast and rehype plugins deal with hast,
so plugins used after `remark-rehype` have to be rehype plugins.
The reason that there are different ecosystems for markdown and HTML is that
turning markdown into HTML is,
while frequently needed,
not the only purpose of markdown.
Checking (linting) and formatting markdown are also common use cases for
remark and markdown.
There are several aspects of markdown that do not translate 1-to-1 to HTML.
In some cases markdown contains more information than HTML:
for example,
there are several ways to add a link in markdown
(as in,
autolinks: `<https://url>`,
resource links: `[label](url)`,
and reference links with definitions:
`[label][id]` and `[id]: url`).
In other cases HTML contains more information than markdown:
there are many tags,
which add new meaning (semantics),
available in HTML that aren’t available in markdown.
If there was just one AST,
it would be quite hard to perform the tasks that several remark and rehype
plugins currently do.
## When should I use this?
This project is useful when you want to turn markdown to HTML.
It opens up a whole new ecosystem with tons of plugins to do all kinds of
things.
You can [minify HTML][github-rehype-minify],
[format HTML][github-rehype-format],
[make sure it’s safe][github-rehype-sanitize],
[highlight code][github-rehype-starry-night],
[add metadata][github-rehype-meta],
and a lot more.
A different plugin,
[`rehype-raw`][github-rehype-raw],
adds support for raw HTML written inside markdown.
This is a separate plugin because supporting HTML inside markdown is a heavy
task (performance and bundle size) and not always needed.
To use both together,
you also have to configure `remark-rehype` with `allowDangerousHtml: true` and
then use `rehype-raw`.
The rehype plugin [`rehype-remark`][github-rehype-remark] does the inverse of
this plugin.
It turns HTML into markdown.
If you don’t use plugins and want to access syntax trees,
you can use
[`mdast-util-to-hast`][github-mdast-util-to-hast].
## Install
This package is [ESM only][github-gist-esm].
In Node.js (version 16+),
install with [npm][npmjs-install]:
```sh
npm install remark-rehype
```
In Deno with [`esm.sh`][esmsh]:
```js
import remarkRehype from 'https://esm.sh/remark-rehype@11'
```
In browsers with [`esm.sh`][esmsh]:
```html
<script type="module">
import remarkRehype from 'https://esm.sh/remark-rehype@11?bundle'
</script>
```
## Use
Say our document `example.md` contains:
```markdown
# Pluto
**Pluto** (minor-planet designation: **134340 Pluto**) is a
[dwarf planet](https://en.wikipedia.org/wiki/Dwarf_planet) in the
[Kuiper belt](https://en.wikipedia.org/wiki/Kuiper_belt).
```
…and our module `example.js` contains:
```js
import rehypeDocument from 'rehype-document'
import rehypeFormat from 'rehype-format'
import rehypeStringify from 'rehype-stringify'
import remarkParse from 'remark-parse'
import remarkRehype from 'remark-rehype'
import {read} from 'to-vfile'
import {unified} from 'unified'
import {reporter} from 'vfile-reporter'
const file = await unified()
.use(remarkParse)
.use(remarkRehype)
.use(rehypeDocument)
.use(rehypeFormat)
.use(rehypeStringify)
.process(await read('example.md'))
console.error(reporter(file))
console.log(String(file))
```
…then running `node example.js` yields:
```text
example.md: no issues found
```
```html
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>example</title>
<meta content="width=device-width, initial-scale=1" name="viewport">
</head>
<body>
<h1>Pluto</h1>
<p>
<strong>Pluto</strong> (minor-planet designation: <strong>134340 Pluto</strong>) is a
<a href="https://en.wikipedia.org/wiki/Dwarf_planet">dwarf planet</a> in the
<a href="https://en.wikipedia.org/wiki/Kuiper_belt">Kuiper belt</a>.
</p>
</body>
</html>
```
## API
This package exports the identifiers
[`defaultFootnoteBackContent`][api-default-footnote-back-content],
[`defaultFootnoteBackLabel`][api-default-footnote-back-label],
and
[`defaultHandlers`][api-default-handlers].
The default export is [`remarkRehype`][api-remark-rehype].
### `defaultFootnoteBackContent(referenceIndex, rereferenceIndex)`
See [`defaultFootnoteBackContent` from
`mdast-util-to-hast`][github-mdast-util-to-hast-default-back-content].
### `defaultFootnoteBackLabel(referenceIndex, rereferenceIndex)`
See [`defaultFootnoteBackLabel` from
`mdast-util-to-hast`][github-mdast-util-to-hast-default-back-label].
### `defaultHandlers`
See [`defaultHandlers` from
`mdast-util-to-hast`][github-mdast-util-to-hast-default-handlers].
### `unified().use(remarkRehype[, destination][, options])`
Turn markdown into HTML.
###### Parameters
* `destination`
([`Processor`][github-unified-processor], optional)
— processor
* `options`
([`Options`][api-options], optional)
— configuration
###### Returns
Transform ([`Transformer`][github-unified-transformer]).
##### Notes
###### Signature
* if a [processor][github-unified-processor] is given,
runs the (rehype) plugins used on it with a hast tree,
then discards the result
([*bridge mode*][github-unified-mode])
* otherwise,
returns a hast tree,
the plugins used after `remarkRehype` are rehype plugins
([*mutate mode*][github-unified-mode])
> 👉 **Note**:
> it’s highly unlikely that you want to pass a `processor`.
###### HTML
Raw HTML is available in mdast as [`html`][github-mdast-html] nodes and can be
embedded in hast as semistandard `raw` nodes.
Most plugins ignore `raw` nodes but two notable ones don’t:
* [`rehype-stringify`][github-rehype-stringify] also has an option
`allowDangerousHtml` which will output the raw HTML;
this is typically discouraged as noted by the option name but is useful if
you completely trust authors
* [`rehype-raw`][github-rehype-raw] can handle the raw embedded HTML strings by
parsing them into standard hast nodes
(`element`, `text`, etc);
This is a heavy task as it needs a full HTML parser,
but it is the only way to support untrusted content
###### Footnotes
Many options supported here relate to footnotes.
Footnotes are not specified by CommonMark,
which we follow by default.
They are supported by GitHub,
so footnotes can be enabled in markdown with [`remark-gfm`][github-remark-gfm].
The options `footnoteBackLabel` and `footnoteLabel` define natural language
that explains footnotes,
which is hidden for sighted users but shown to assistive technology.
When your page is not in English,
you must define translated values.
Back references use ARIA attributes,
but the section label itself uses a heading that is hidden with an
`sr-only` class.
To show it to sighted users,
define different attributes in `footnoteLabelProperties`.
###### Clobbering
Footnotes introduces a problem,
as it links footnote calls to footnote definitions on the page through `id`
attributes generated from user content,
which results in DOM clobbering.
DOM clobbering is this:
```html
<p id=x></p>
<script>alert(x) // `x` now refers to the DOM `p#x` element</script>
```
Elements by their ID are made available by browsers on the `window` object,
which is a security risk.
Using a prefix solves this problem.
More information on how to handle clobbering and the prefix is explained in
[*Example: headings (DOM clobbering)* in
`rehype-sanitize`][github-rehype-sanitize-clobber].
###### Unknown nodes
Unknown nodes are nodes with a type that isn’t in `handlers` or `passThrough`.
The default behavior for unknown nodes is:
* when the node has a `value`
(and doesn’t have `data.hName`, `data.hProperties`, or `data.hChildren`,
see later),
create a hast `text` node
* otherwise,
create a `<div>` element
(which could be changed with `data.hName`),
with its children mapped from mdast to hast as well
This behavior can be changed by passing an `unknownHandler`.
### `Options`
Configuration (TypeScript type).
###### Fields
* `allowDangerousHtml`
(`boolean`, default: `false`)
— whether to persist raw HTML in markdown in the hast tree
* `clobberPrefix`
(`string`, default: `'user-content-'`)
— prefix to use before the `id` property on footnotes to prevent them from
*clobbering*
* `footnoteBackContent`
([`FootnoteBackContentTemplate` from
`mdast-util-to-hast`][github-mdast-util-to-hast-back-content-template]
or `string`, default:
[`defaultFootnoteBackContent` from
`mdast-util-to-hast`][github-mdast-util-to-hast-default-back-content])
— content of the backreference back to references
* `footnoteBackLabel`
([`FootnoteBackLabelTemplate` from
`mdast-util-to-hast`][github-mdast-util-to-hast-back-label-template]
or `string`, default:
[`defaultFootnoteBackLabel` from
`mdast-util-to-hast`][github-mdast-util-to-hast-default-back-label])
— label to describe the backreference back to references
* `footnoteLabel`
(`string`, default: `'Footnotes'`)
— label to use for the footnotes section (affects screen readers)
* `footnoteLabelProperties`
([`Properties` from `@types/hast`][github-hast-properties], default:
`{className: ['sr-only']}`)
— properties to use on the footnote label
(note that `id: 'footnote-label'` is always added as footnote calls use it
with `aria-describedby` to provide an accessible label)
* `footnoteLabelTagName`
(`string`, default: `h2`)
— tag name to use for the footnote label
* `handlers`
([`Handlers` from
`mdast-util-to-hast`][github-mdast-util-to-hast-handlers], optional)
— extra handlers for nodes
* `passThrough`
(`Array<Nodes['type']>`, optional)
— list of custom mdast node types to pass through (keep) in hast (note that
the node itself is passed, but eventual children are transformed)
* `unknownHandler`
([`Handler` from
`mdast-util-to-hast`][github-mdast-util-to-hast-handler], optional)
— handle all unknown nodes
## Examples
### Example: supporting HTML in markdown naïvely
If you completely trust the authors of the input markdown and want to allow them
to write HTML inside markdown,
you can pass `allowDangerousHtml` to `remark-rehype` and `rehype-stringify`:
```js
import rehypeStringify from 'rehype-stringify'
import remarkParse from 'remark-parse'
import remarkRehype from 'remark-rehype'
import {unified} from 'unified'
const file = await unified()
.use(remarkParse)
.use(remarkRehype, {allowDangerousHtml: true})
.use(rehypeStringify, {allowDangerousHtml: true})
.process('<a href="/wiki/Dysnomia_(moon)" onclick="alert(1)">Dysnomia</a>')
console.log(String(file))
```
Yields:
```html
<p><a href="/wiki/Dysnomia_(moon)" onclick="alert(1)">Dysnomia</a></p>
```
> ⚠️ **Danger**:
> observe that the XSS attack through `onclick` is present.
### Example: supporting HTML in markdown properly
If you do not trust the authors of the input markdown,
or if you want to make sure that rehype plugins can see HTML embedded in
markdown,
use [`rehype-raw`][github-rehype-raw].
The following example passes `allowDangerousHtml` to `remark-rehype`,
then turns the raw embedded HTML into proper HTML nodes with `rehype-raw`,
and finally sanitizes the HTML by only allowing safe things with
`rehype-sanitize`:
```js
import rehypeSanitize from 'rehype-sanitize'
import rehypeStringify from 'rehype-stringify'
import rehypeRaw from 'rehype-raw'
import remarkParse from 'remark-parse'
import remarkRehype from 'remark-rehype'
import {unified} from 'unified'
const file = await unified()
.use(remarkParse)
.use(remarkRehype, {allowDangerousHtml: true})
.use(rehypeRaw)
.use(rehypeSanitize)
.use(rehypeStringify)
.process('<a href="/wiki/Dysnomia_(moon)" onclick="alert(1)">Dysnomia</a>')
console.log(String(file))
```
Running that code yields:
```html
<p><a href="/wiki/Dysnomia_(moon)">Dysnomia</a></p>
```
> ⚠️ **Danger**:
> observe that the XSS attack through `onclick` is **not** present.
### Example: footnotes in languages other than English
If you know that the markdown is authored in a language other than English,
and you’re using `remark-gfm` to match how GitHub renders markdown,
and you know that footnotes are (or can?) be used,
you should translate the labels associated with them.
Let’s first set the stage:
```js
import {unified} from 'unified'
import remarkParse from 'remark-parse'
import remarkGfm from 'remark-gfm'
import remarkRehype from 'remark-rehype'
import rehypeStringify from 'rehype-stringify'
const doc = `
Ceres ist nach der römischen Göttin des Ackerbaus benannt;
ihr astronomisches Symbol ist daher eine stilisierte Sichel: ⚳.[^nasa-2015]
[^nasa-2015]: JPL/NASA:
[*What is a Dwarf Planet?*](https://www.jpl.nasa.gov/infographics/what-is-a-dwarf-planet)
In: Jet Propulsion Laboratory.
22. April 2015,
abgerufen am 19. Januar 2022 (englisch).
`
const file = await unified()
.use(remarkParse)
.use(remarkGfm)
.use(remarkRehype)
.use(rehypeStringify)
.process(doc)
console.log(String(file))
```
Yields:
```html
<p>Ceres ist nach der römischen Göttin des Ackerbaus benannt;
ihr astronomisches Symbol ist daher eine stilisierte Sichel: ⚳.<sup><a href="#user-content-fn-nasa-2015" id="user-content-fnref-nasa-2015" data-footnote-ref aria-describedby="footnote-label">1</a></sup></p>
<section data-footnotes class="footnotes"><h2 class="sr-only" id="footnote-label">Footnotes</h2>
<ol>
<li id="user-content-fn-nasa-2015">
<p>JPL/NASA:
<a href="https://www.jpl.nasa.gov/infographics/what-is-a-dwarf-planet"><em>What is a Dwarf Planet?</em></a>
In: Jet Propulsion Laboratory.
22. April 2015,
abgerufen am 19. Januar 2022 (englisch). <a href="#user-content-fnref-nasa-2015" data-footnote-backref="" aria-label="Back to reference 1" class="data-footnote-backref">↩</a></p>
</li>
</ol>
</section>
```
This is a mix of English and German that isn’t very accessible,
such as that screen readers can’t handle it nicely.
Let’s say our program *does* know that the markdown is in German.
In that case,
it’s important to translate and define the labels relating to footnotes so that
screen reader users can properly pronounce the page:
```diff
@@ -18,7 +18,16 @@ ihr astronomisches Symbol ist daher eine stilisierte Sichel: ⚳.[^nasa-2015]
const file = await unified()
.use(remarkParse)
.use(remarkGfm)
- .use(remarkRehype)
+ .use(remarkRehype, {
+ footnoteBackLabel(referenceIndex, rereferenceIndex) {
+ return (
+ 'Hochspringen nach: ' +
+ (referenceIndex + 1) +
+ (rereferenceIndex > 1 ? '-' + rereferenceIndex : '')
+ )
+ },
+ footnoteLabel: 'Fußnoten'
+ })
.use(rehypeStringify)
.process(doc)
```
Running the code with the above patch applied,
yields:
```diff
@@ -1,13 +1,13 @@
<p>Ceres ist nach der römischen Göttin des Ackerbaus benannt;
ihr astronomisches Symbol ist daher eine stilisierte Sichel: ⚳.<sup><a href="#user-content-fn-nasa-2015" id="user-content-fnref-nasa-2015" data-footnote-ref aria-describedby="footnote-label">1</a></sup></p>
-<section data-footnotes class="footnotes"><h2 class="sr-only" id="footnote-label">Footnotes</h2>
+<section data-footnotes class="footnotes"><h2 class="sr-only" id="footnote-label">Fußnoten</h2>
<ol>
<li id="user-content-fn-nasa-2015">
<p>JPL/NASA:
<a href="https://www.jpl.nasa.gov/infographics/what-is-a-dwarf-planet"><em>What is a Dwarf Planet?</em></a>
In: Jet Propulsion Laboratory.
22. April 2015,
-abgerufen am 19. Januar 2022 (englisch). <a href="#user-content-fnref-nasa-2015" data-footnote-backref="" aria-label="Back to reference 1" class="data-footnote-backref">↩</a></p>
+abgerufen am 19. Januar 2022 (englisch). <a href="#user-content-fnref-nasa-2015" data-footnote-backref="" aria-label="Hochspringen nach: 1" class="data-footnote-backref">↩</a></p>
</li>
</ol>
</section>
```
## HTML
See [*Algorithm* in
`mdast-util-to-hast`](https://github.com/syntax-tree/mdast-util-to-hast#algorithm)
for info on how mdast (markdown) nodes are transformed to hast (HTML).
## CSS
Assuming you know how to use (semantic) HTML and CSS,
then it should generally be straightforward to style the HTML produced by this
plugin.
With CSS,
you can get creative and style the results as you please.
Some semistandard features,
notably GFMs tasklists and footnotes,
generate HTML that be unintuitive,
as it matches exactly what GitHub produces for their website.
There is a project,
[`sindresorhus/github-markdown-css`][github-markdown-css],
that exposes the stylesheet that GitHub uses for rendered markdown,
which might either be inspirational for more complex features,
or can be used as-is to exactly match how GitHub styles rendered markdown.
The following CSS is needed to make footnotes look a bit like GitHub:
```css
/* Style the footnotes section. */
.footnotes {
font-size: smaller;
color: #8b949e;
border-top: 1px solid #30363d;
}
/* Hide the section label for visual users. */
.sr-only {
position: absolute;
width: 1px;
height: 1px;
padding: 0;
overflow: hidden;
clip: rect(0, 0, 0, 0);
word-wrap: normal;
border: 0;
}
/* Place `[` and `]` around footnote calls. */
[data-footnote-ref]::before {
content: '[';
}
[data-footnote-ref]::after {
content: ']';
}
```
## Syntax tree
This projects turns [mdast][github-mdast] (markdown) into [hast][github-hast]
(HTML).
It extends mdast by supporting `data` fields on mdast nodes to specify how they
should be transformed.
See [*Fields on nodes* in
`mdast-util-to-hast`](https://github.com/syntax-tree/mdast-util-to-hast#fields-on-nodes)
for info on how these fields work.
It extends hast by using a semistandard raw nodes for raw HTML.
See the [*HTML* note above](#html) for more info.
## Types
This package is fully typed with [TypeScript][].
It exports the types
[`Options`][api-options].
The types of `mdast-util-to-hast` can be referenced to register data fields
with `@types/mdast` and `Raw` nodes with `@types/hast`.
```js
/**
* @import {Root as HastRoot} from 'hast'
* @import {Root as MdastRoot} from 'mdast'
* @import {} from 'mdast-util-to-hast'
*/
import {visit} from 'unist-util-visit'
const mdastNode = /** @type {MdastRoot} */ ({/* … */})
console.log(mdastNode.data?.hName) // Typed as `string | undefined`.
const hastNode = /** @type {HastRoot} */ ({/* … */})
visit(hastNode, function (node) {
// `node` can now be `raw`.
})
```
## Compatibility
Projects maintained by the unified collective are compatible with maintained
versions of Node.js.
When we cut a new major release,
we drop support for unmaintained versions of Node.
This means we try to keep the current release line,
`remark-rehype@11`,
compatible with Node.js 16.
This plugin works with `unified` version 6+,
`remark-parse` version 3+
(used in `remark` version 7),
and `rehype-stringify` version 3+
(used in `rehype` version 5).
## Security
Use of `remark-rehype` can open you up to a
[cross-site scripting (XSS)][wikipedia-xss] attack.
Embedded **[hast][github-hast]** properties
(`hName`, `hProperties`, `hChildren`)
in [mdast][github-mdast],
custom handlers,
and the `allowDangerousHtml` option all provide openings.
Use [`rehype-sanitize`][github-rehype-sanitize] to make the tree safe.
## Related
* [`rehype-raw`][github-rehype-raw]
— rehype plugin to parse the tree again and support `raw` nodes
* [`rehype-sanitize`][github-rehype-sanitize]
— rehype plugin to sanitize HTML
* [`rehype-remark`][github-rehype-remark]
— rehype plugin to turn HTML into markdown
* [`rehype-retext`](https://github.com/rehypejs/rehype-retext)
— rehype plugin to support retext
* [`remark-retext`](https://github.com/remarkjs/remark-retext)
— remark plugin to support retext
## Contribute
See [`contributing.md`][health-contributing] in [`remarkjs/.github`][health]
for ways to get started.
See [`support.md`][health-support] for ways to get help.
This project has a [code of conduct][health-coc].
By interacting with this repository,
organization,
or community you agree to abide by its terms.
## License
[MIT][file-license] © [Titus Wormer][wooorm]
<!-- Definitions -->
[api-default-footnote-back-content]: #defaultfootnotebackcontentreferenceindex-rereferenceindex
[api-default-footnote-back-label]: #defaultfootnotebacklabelreferenceindex-rereferenceindex
[api-default-handlers]: #defaulthandlers
[api-options]: #options
[api-remark-rehype]: #unifieduseremarkrehype-destination-options
[badge-build-image]: https://github.com/remarkjs/remark-rehype/workflows/main/badge.svg
[badge-build-url]: https://github.com/remarkjs/remark-rehype/actions
[badge-coverage-image]: https://img.shields.io/codecov/c/github/remarkjs/remark-rehype.svg
[badge-coverage-url]: https://codecov.io/github/remarkjs/remark-rehype
[badge-downloads-image]: https://img.shields.io/npm/dm/remark-rehype.svg
[badge-downloads-url]: https://www.npmjs.com/package/remark-rehype
[badge-size-image]: https://img.shields.io/bundlejs/size/remark-rehype
[badge-size-url]: https://bundlejs.com/?q=remark-rehype
[esmsh]: https://esm.sh
[file-license]: license
[github-gist-esm]: https://gist.github.com/sindresorhus/a39789f98801d908bbc7ff3ecc99d99c
[github-hast]: https://github.com/syntax-tree/hast
[github-hast-properties]: https://github.com/syntax-tree/hast#properties
[github-markdown-css]: https://github.com/sindresorhus/github-markdown-css
[github-mdast]: https://github.com/syntax-tree/mdast
[github-mdast-html]: https://github.com/syntax-tree/mdast#html
[github-mdast-util-to-hast]: https://github.com/syntax-tree/mdast-util-to-hast
[github-mdast-util-to-hast-back-content-template]: https://github.com/syntax-tree/mdast-util-to-hast#footnotebackcontenttemplate
[github-mdast-util-to-hast-back-label-template]: https://github.com/syntax-tree/mdast-util-to-hast#footnotebacklabeltemplate
[github-mdast-util-to-hast-default-back-content]: https://github.com/syntax-tree/mdast-util-to-hast#defaultfootnotebackcontentreferenceindex-rereferenceindex
[github-mdast-util-to-hast-default-back-label]: https://github.com/syntax-tree/mdast-util-to-hast#defaultfootnotebacklabelreferenceindex-rereferenceindex
[github-mdast-util-to-hast-default-handlers]: https://github.com/syntax-tree/mdast-util-to-hast#defaulthandlers
[github-mdast-util-to-hast-handler]: https://github.com/syntax-tree/mdast-util-to-hast#handler
[github-mdast-util-to-hast-handlers]: https://github.com/syntax-tree/mdast-util-to-hast#handlers
[github-rehype]: https://github.com/rehypejs/rehype
[github-rehype-format]: https://github.com/rehypejs/rehype-format
[github-rehype-meta]: https://github.com/rehypejs/rehype-meta
[github-rehype-minify]: https://github.com/rehypejs/rehype-minify
[github-rehype-raw]: https://github.com/rehypejs/rehype-raw
[github-rehype-remark]: https://github.com/rehypejs/rehype-remark
[github-rehype-sanitize]: https://github.com/rehypejs/rehype-sanitize
[github-rehype-sanitize-clobber]: https://github.com/rehypejs/rehype-sanitize#example-headings-dom-clobbering
[github-rehype-starry-night]: https://github.com/rehypejs/rehype-starry-night
[github-rehype-stringify]: https://github.com/rehypejs/rehype/tree/main/packages/rehype-stringify
[github-remark]: https://github.com/remarkjs/remark
[github-remark-gfm]: https://github.com/remarkjs/remark-gfm
[github-unified]: https://github.com/unifiedjs/unified
[github-unified-mode]: https://github.com/unifiedjs/unified#transforming-between-ecosystems
[github-unified-processor]: https://github.com/unifiedjs/unified#processor
[github-unified-transformer]: https://github.com/unifiedjs/unified#transformer
[health]: https://github.com/remarkjs/.github
[health-coc]: https://github.com/remarkjs/.github/blob/main/code-of-conduct.md
[health-contributing]: https://github.com/remarkjs/.github/blob/main/contributing.md
[health-support]: https://github.com/remarkjs/.github/blob/main/support.md
[npmjs-install]: https://docs.npmjs.com/cli/install
[typescript]: https://www.typescriptlang.org
[wikipedia-xss]: https://en.wikipedia.org/wiki/Cross-site_scripting
[wooorm]: https://wooorm.com
@@ -0,0 +1 @@
{"name":"fs-extra","version":"10.1.0","requiresBuild":false,"files":{"LICENSE":{"checkedAt":1794532124386,"integrity":"sha512-DqND0OaWuieHfcBhF2bFJqpz9uevRt9aD4OEDcTHhR+1g3t/a9qKAUMCv4d/47Sz45K5Q877Ovl56K/GdVml/w==","mode":420,"size":1084},"lib/copy/copy-sync.js":{"checkedAt":1794532124386,"integrity":"sha512-iOZ1vlxX8g72AViSzqf3kwOZHuCml0p9sQXoMnVy9VSr3XbRJqzjoHzTYHOGF76tqqglSTOhjjhvkcKLUaNjiA==","mode":420,"size":5776},"lib/copy/copy.js":{"checkedAt":1794532124387,"integrity":"sha512-ioiW28fJ7SUcEIPBMaMRCLI23XVmCKsxSyaSP+pmcFLCrnznKl9vMXopTaKYPpoMS6ubhiVH5K8u/ymMqG/U5Q==","mode":420,"size":7756},"lib/ensure/file.js":{"checkedAt":1794532124387,"integrity":"sha512-zlzH+5+iOi7ZSJ4X/MlwLWKR7GVuLGxWo0DBTmDPFU/D2f0nTFnj/O58lA7QxmoOHVZHaxGwxVQSaze6FanFcQ==","mode":420,"size":1709},"lib/copy/index.js":{"checkedAt":1794532124387,"integrity":"sha512-zda3QPienVNaUmGWvzGa8YcgU3IZzaW1XCAerW9BgN3WiRLf0vWXTDwT3X4pxXqmBTjlWQ2rZG3P2lIv8HwxRQ==","mode":420,"size":147},"lib/empty/index.js":{"checkedAt":1794532124387,"integrity":"sha512-1TVD5N1s2WfH8u+bYC6SaVIFL3bxRaZ/H0BShmlEqrXgI/CmEhaNdAo+G/lxMZlAKSxVfT8XBOGLlRlKbAmhAA==","mode":420,"size":747},"lib/ensure/index.js":{"checkedAt":1794532124387,"integrity":"sha512-ykL5D+bLWBCEuAnmG8KDhALcUv2LVL458iSeOUsno0MSs4/gguPX15rUuNO8zW7RjJvSwVMdbaDJQGRJJseOew==","mode":420,"size":542},"lib/fs/index.js":{"checkedAt":1794532124387,"integrity":"sha512-L55DDYGKSKpxLusCpwpuZdkAmE2fgYZkwCTRmPpNLzqsE5q5NddZR0CXAIKb2noW7kG+CK6a8qAoEeQ7dL+SWQ==","mode":420,"size":3373},"lib/index.js":{"checkedAt":1794532124387,"integrity":"sha512-J07v9VIl47niKmVEPSwzc0/95oDYzp+omU2bOWa084l9xci9Qd6BGyEve5eTuzHVuYitkVlpJrkz6rYcKLCrLw==","mode":420,"size":358},"lib/json/index.js":{"checkedAt":1794532124387,"integrity":"sha512-R4YPFVgUwHRPuyeIAQwNgYjoEeVitlP6XeXGuFK4cKDSnH6MxtH6VSeDEbjIYlyT7RQ1vwbM9uFZjKhks2ngag==","mode":420,"size":508},"lib/mkdirs/index.js":{"checkedAt":1794532124387,"integrity":"sha512-WGUvT546CCoEcbJwVHLhJquCSfGAX3jGlmYlrqwwbtGHMjsMTMFF6vs59vnQRlqowqu+E/JzqypyLgOQGZS7eA==","mode":420,"size":328},"lib/move/index.js":{"checkedAt":1794532124388,"integrity":"sha512-qOoQ/wrXtkufr4SngZqk+JyoHRJHZTZUB1q0Q0pbNsQJ8AfwEQ0MDwECfoO0aJcxTL+q5liFSnn9XUampLN2kg==","mode":420,"size":147},"lib/output-file/index.js":{"checkedAt":1794532124388,"integrity":"sha512-S9lvpiZZLoVkMcPaGPfyxSYvz3+PyVpPqLPs1r1/U+gu4n0yVXEd8K3aqqP8e6XhEQTdRI+Q9JDlUX6rwc2tQg==","mode":420,"size":947},"lib/path-exists/index.js":{"checkedAt":1794532124388,"integrity":"sha512-U9k7Zu1KLsojBG5vKwj8vkzeQKK4Qas424OKx1sIgpRzcQJMt0rkPSyaLgleJFfiIHl5xF8H1G5uK1+Z78/HlA==","mode":420,"size":263},"lib/remove/index.js":{"checkedAt":1794532124388,"integrity":"sha512-1XcnrIypbRgN2eYrrWEFzyxopz/FcnWt67XfwzsANI81q2/1ao0OL/nJsdwG1h1FiOr7aCpR5H7jvWiYQmSvMQ==","mode":420,"size":489},"lib/json/jsonfile.js":{"checkedAt":1794532124388,"integrity":"sha512-8+N0MGTcxbzzmYkkFasE2Fuc7TOzXvZLmtm2WwANd/JfHqOagLE9MJo0ttv1ltg/2sgl5+vQAdsyyk7Ih9B1EA==","mode":420,"size":238},"lib/ensure/link.js":{"checkedAt":1794532124388,"integrity":"sha512-xgSVi3pe6ZzYaGMkpdTVa5Sf/tWtQnt2De1VqNGUJOxZV4r1WTjld0/P45ghy1XlFhECcpMzX7upDaAiRblyLw==","mode":420,"size":1652},"lib/mkdirs/make-dir.js":{"checkedAt":1794532124388,"integrity":"sha512-u1Rs4vlkj3lkl0O4LQN7w1+3S6SShm0JpbEXNEP3A6AEEo0ko6RPeSDo+N5XnrYSI175i7Rm9bXtFk6PNFEqqA==","mode":420,"size":545},"lib/move/move-sync.js":{"checkedAt":1794532124389,"integrity":"sha512-EjLTOO8NOF5S7hII4IMg9Qz6bQ23K6WSeAcUdkcK/h5QjN672Vg9nTg/WVsM/IWaSy1LSfQKEXr/o9+aIwdzHA==","mode":420,"size":1485},"lib/move/move.js":{"checkedAt":1794532124389,"integrity":"sha512-dn/esY/F5Qm/4vVfTXuRSlcANE4aEU2aGo28buGr4vqwMJj2SRXo2j0jGKyX32XJgRV8wCsBINIqlVP+ZTjP8g==","mode":420,"size":2010},"lib/json/output-json-sync.js":{"checkedAt":1794532124389,"integrity":"sha512-otPG43YsTwK8g3kydKstl9c1a94iCCcvnaAMLQ8qECrZ6COIJNAUjMcCNfYuYZJBvJx8h2YWVNum+fQJL+Ueew==","mode":420,"size":276},"lib/json/output-json.js":{"checkedAt":1794532124389,"integrity":"sha512-s7nInL7OfrQareRhH2jpfCWTU05nkUKQnpvw6zPUaQkx/FyHcjrXvRzgAxC85dIKaUU/COvP7B56pR3YJvgyTA==","mode":420,"size":277},"lib/remove/rimraf.js":{"checkedAt":1794532124389,"integrity":"sha512-gcgswQmy/QXSFYoli85sRFfzo50wXGgkPhjgH6qMEM/Sp6heiYCzOfKyZu/F+OuoiI9VsaD1Y1WoGyZs9TWobA==","mode":420,"size":7443},"lib/util/stat.js":{"checkedAt":1794532124389,"integrity":"sha512-axP7i0yi6n1kl0z44e/UDSosT91RSQ3CbOJRRm/7Lr/UvO5BnWIPqjDyU9XoGK6mInu9QU1u/67RI9aLnhyLsw==","mode":420,"size":5226},"lib/ensure/symlink-paths.js":{"checkedAt":1794532124389,"integrity":"sha512-vjQwh14P7AAwwmOqwHV7VZpP3DrM1oHSv1g3G+GHPW65Wb02eLe3LYt4XEt0IVVgu5vRabW4GsaJyQgM35BRVg==","mode":420,"size":3374},"lib/ensure/symlink-type.js":{"checkedAt":1794532124389,"integrity":"sha512-pnApSc3DuAr6avKAUIyVFM1PmJB/KxCf8atj4DD9uenBvmEX1StPYDvUAuyfwe8qPlsjQoBnnQzEuPBD4N6Wrw==","mode":420,"size":694},"lib/ensure/symlink.js":{"checkedAt":1794532124390,"integrity":"sha512-Osr7qO60U1etQFwsuAKUl/upc0+EYiVIUUYE+lkxOGe8ogZeEWQB5ETJ/2+CZAz0loyxupt9bzMl29Br2Hytyw==","mode":420,"size":25Line truncated
@@ -0,0 +1,21 @@
The MIT License (MIT)
Copyright (c) 2015-2017, Jon Schlinkert.
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,107 @@
/**
* @author Toru Nagashima <https://github.com/mysticatea>
* See LICENSE file in root directory for full license.
*/
"use strict"
// https://www-archive.mozilla.org/js/language/E262-3.pdf
const keywords = new Set([
"abstract",
"boolean",
"break",
"byte",
"case",
"catch",
"char",
"class",
"const",
"continue",
"debugger",
"default",
"delete",
"do",
"double",
"else",
"enum",
"export",
"extends",
"false",
"final",
"finally",
"float",
"for",
"function",
"goto",
"if",
"implements",
"import",
"in",
"instanceof",
"int",
"interface",
"long",
"native",
"new",
"null",
"package",
"private",
"protected",
"public",
"return",
"short",
"static",
"super",
"switch",
"synchronized",
"this",
"throw",
"throws",
"transient",
"true",
"try",
"typeof",
"var",
"void",
"volatile",
"while",
"with",
])
module.exports = {
meta: {
docs: {
description: "disallow reserved words as property names.",
category: "ES5",
recommended: false,
url: "http://eslint-community.github.io/eslint-plugin-es-x/rules/no-keyword-properties.html",
},
fixable: null,
messages: {
forbidden: "ES5 reserved words as property names are forbidden.",
},
schema: [],
type: "problem",
},
create(context) {
return {
Property(node) {
if (
!node.computed &&
node.key.type === "Identifier" &&
keywords.has(node.key.name)
) {
context.report({ node, messageId: "forbidden" })
}
},
MemberExpression(node) {
if (
!node.computed &&
node.property.type === "Identifier" &&
keywords.has(node.property.name)
) {
context.report({ node, messageId: "forbidden" })
}
},
}
},
}
@@ -0,0 +1,5 @@
var convert = require('./convert'),
func = convert('pick', require('../pick'));
func.placeholder = require('./placeholder');
module.exports = func;
@@ -0,0 +1,52 @@
# path-exists [![Build Status](https://travis-ci.org/sindresorhus/path-exists.svg?branch=master)](https://travis-ci.org/sindresorhus/path-exists)
> Check if a path exists
NOTE: `fs.existsSync` has been un-deprecated in Node.js since 6.8.0. If you only need to check synchronously, this module is not needed.
While [`fs.exists()`](https://nodejs.org/api/fs.html#fs_fs_exists_path_callback) is being [deprecated](https://github.com/iojs/io.js/issues/103), there's still a genuine use-case of being able to check if a path exists for other purposes than doing IO with it.
Never use this before handling a file though:
> In particular, checking if a file exists before opening it is an anti-pattern that leaves you vulnerable to race conditions: another process may remove the file between the calls to `fs.exists()` and `fs.open()`. Just open the file and handle the error when it's not there.
## Install
```
$ npm install path-exists
```
## Usage
```js
// foo.js
const pathExists = require('path-exists');
(async () => {
console.log(await pathExists('foo.js'));
//=> true
})();
```
## API
### pathExists(path)
Returns a `Promise<boolean>` of whether the path exists.
### pathExists.sync(path)
Returns a `boolean` of whether the path exists.
## Related
- [path-exists-cli](https://github.com/sindresorhus/path-exists-cli) - CLI for this module
## License
MIT © [Sindre Sorhus](https://sindresorhus.com)
@@ -0,0 +1,2 @@
import type { Coordinates, DistanceMeasurement } from '../../types';
export declare function hasExceededDistance(delta: Coordinates, measurement: DistanceMeasurement): boolean;
@@ -0,0 +1,29 @@
declare const _default: {
extends: string[];
rules: {
'@typescript-eslint/adjacent-overload-signatures': "error";
'@typescript-eslint/array-type': "error";
'@typescript-eslint/ban-tslint-comment': "error";
'@typescript-eslint/class-literal-property-style': "error";
'@typescript-eslint/consistent-generic-constructors': "error";
'@typescript-eslint/consistent-indexed-object-style': "error";
'@typescript-eslint/consistent-type-assertions': "error";
'@typescript-eslint/consistent-type-definitions': "error";
'dot-notation': "off";
'@typescript-eslint/dot-notation': "error";
'@typescript-eslint/no-confusing-non-null-assertion': "error";
'no-empty-function': "off";
'@typescript-eslint/no-empty-function': "error";
'@typescript-eslint/no-inferrable-types': "error";
'@typescript-eslint/non-nullable-type-assertion-style': "error";
'@typescript-eslint/prefer-find': "error";
'@typescript-eslint/prefer-for-of': "error";
'@typescript-eslint/prefer-function-type': "error";
'@typescript-eslint/prefer-includes': "error";
'@typescript-eslint/prefer-nullish-coalescing': "error";
'@typescript-eslint/prefer-optional-chain': "error";
'@typescript-eslint/prefer-regexp-exec': "error";
'@typescript-eslint/prefer-string-starts-ends-with': "error";
};
};
export = _default;
@@ -0,0 +1,57 @@
import {useToggleButton as $55f54f7887471b58$export$51e84d46ca0bc451} from "./useToggleButton.module.js";
import {useToolbar as $9iEyV$useToolbar} from "@react-aria/toolbar";
/*
* 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.
*/
function $4547d1bf40011fdf$export$dd5580ae642f110f(props, state, ref) {
let { isDisabled: isDisabled } = props;
let { toolbarProps: toolbarProps } = (0, $9iEyV$useToolbar)(props, ref);
return {
groupProps: {
...toolbarProps,
role: state.selectionMode === 'single' ? 'radiogroup' : toolbarProps.role,
'aria-disabled': isDisabled
}
};
}
function $4547d1bf40011fdf$export$bc53712daae3d6e6(props, state, ref) {
let toggleState = {
isSelected: state.selectedKeys.has(props.id),
setSelected (isSelected) {
state.setSelected(props.id, isSelected);
},
toggle () {
state.toggleKey(props.id);
}
};
let { isPressed: isPressed, isSelected: isSelected, isDisabled: isDisabled, buttonProps: buttonProps } = (0, $55f54f7887471b58$export$51e84d46ca0bc451)({
...props,
id: undefined,
isDisabled: props.isDisabled || state.isDisabled
}, toggleState, ref);
if (state.selectionMode === 'single') {
buttonProps.role = 'radio';
buttonProps['aria-checked'] = toggleState.isSelected;
delete buttonProps['aria-pressed'];
}
return {
isPressed: isPressed,
isSelected: isSelected,
isDisabled: isDisabled,
buttonProps: buttonProps
};
}
export {$4547d1bf40011fdf$export$dd5580ae642f110f as useToggleButtonGroup, $4547d1bf40011fdf$export$bc53712daae3d6e6 as useToggleButtonGroupItem};
//# sourceMappingURL=useToggleButtonGroup.module.js.map
@@ -0,0 +1,134 @@
'use strict';
var identity = require('./nodes/identity.js');
var publicApi = require('./public-api.js');
var visit = require('./visit.js');
const scalarChar = {
BLOCK_FOLDED: '>',
BLOCK_LITERAL: '|',
PLAIN: ':',
QUOTE_DOUBLE: '"',
QUOTE_SINGLE: "'"
};
function anchorExists(doc, anchor) {
let found = false;
visit.visit(doc, {
Value(_key, node) {
if (node.anchor === anchor) {
found = true;
return visit.visit.BREAK;
}
}
});
return found;
}
// test harness for yaml-test-suite event tests
function testEvents(src) {
const docs = publicApi.parseAllDocuments(src);
const errDoc = docs.find(doc => doc.errors.length > 0);
const error = errDoc ? errDoc.errors[0].message : null;
const events = ['+STR'];
try {
for (let i = 0; i < docs.length; ++i) {
const doc = docs[i];
let root = doc.contents;
if (Array.isArray(root))
root = root[0];
const [rootStart] = doc.range || [0];
const error = doc.errors[0];
if (error && (!error.pos || error.pos[0] < rootStart))
throw new Error();
let docStart = '+DOC';
if (doc.directives.docStart)
docStart += ' ---';
else if (doc.contents &&
doc.contents.range[2] === doc.contents.range[0] &&
!doc.contents.anchor &&
!doc.contents.tag)
continue;
events.push(docStart);
addEvents(events, doc, error?.pos[0] ?? -1, root);
let docEnd = '-DOC';
if (doc.directives.docEnd)
docEnd += ' ...';
events.push(docEnd);
}
}
catch (e) {
return { events, error: error ?? e };
}
events.push('-STR');
return { events, error };
}
function addEvents(events, doc, errPos, node) {
if (!node) {
events.push('=VAL :');
return;
}
if (errPos !== -1 && identity.isNode(node) && node.range[0] >= errPos)
throw new Error();
let props = '';
let anchor = identity.isScalar(node) || identity.isCollection(node) ? node.anchor : undefined;
if (anchor) {
if (/\d$/.test(anchor)) {
const alt = anchor.replace(/\d$/, '');
if (anchorExists(doc, alt))
anchor = alt;
}
props = ` &${anchor}`;
}
if (identity.isNode(node) && node.tag)
props += ` <${node.tag}>`;
if (identity.isMap(node)) {
const ev = node.flow ? '+MAP {}' : '+MAP';
events.push(`${ev}${props}`);
node.items.forEach(({ key, value }) => {
addEvents(events, doc, errPos, key);
addEvents(events, doc, errPos, value);
});
events.push('-MAP');
}
else if (identity.isSeq(node)) {
const ev = node.flow ? '+SEQ []' : '+SEQ';
events.push(`${ev}${props}`);
node.items.forEach(item => {
addEvents(events, doc, errPos, item);
});
events.push('-SEQ');
}
else if (identity.isPair(node)) {
events.push(`+MAP${props}`);
addEvents(events, doc, errPos, node.key);
addEvents(events, doc, errPos, node.value);
events.push('-MAP');
}
else if (identity.isAlias(node)) {
let alias = node.source;
if (alias && /\d$/.test(alias)) {
const alt = alias.replace(/\d$/, '');
if (anchorExists(doc, alt))
alias = alt;
}
events.push(`=ALI${props} *${alias}`);
}
else {
const scalar = scalarChar[String(node.type)];
if (!scalar)
throw new Error(`Unexpected node type ${node.type}`);
const value = node.source
.replace(/\\/g, '\\\\')
.replace(/\0/g, '\\0')
.replace(/\x07/g, '\\a')
.replace(/\x08/g, '\\b')
.replace(/\t/g, '\\t')
.replace(/\n/g, '\\n')
.replace(/\v/g, '\\v')
.replace(/\f/g, '\\f')
.replace(/\r/g, '\\r')
.replace(/\x1b/g, '\\e');
events.push(`=VAL${props} ${scalar}${value}`);
}
}
exports.testEvents = testEvents;
@@ -0,0 +1,32 @@
var baseNth = require('./_baseNth'),
baseRest = require('./_baseRest'),
toInteger = require('./toInteger');
/**
* Creates a function that gets the argument at index `n`. If `n` is negative,
* the nth argument from the end is returned.
*
* @static
* @memberOf _
* @since 4.0.0
* @category Util
* @param {number} [n=0] The index of the argument to return.
* @returns {Function} Returns the new pass-thru function.
* @example
*
* var func = _.nthArg(1);
* func('a', 'b', 'c', 'd');
* // => 'b'
*
* var func = _.nthArg(-2);
* func('a', 'b', 'c', 'd');
* // => 'c'
*/
function nthArg(n) {
n = toInteger(n);
return baseRest(function(args) {
return baseNth(args, n);
});
}
module.exports = nthArg;
@@ -0,0 +1,284 @@
import * as checks from "./checks.js";
import type * as core from "./core.js";
import type * as errors from "./errors.js";
import * as schemas from "./schemas.js";
import * as util from "./util.js";
export type Params<T extends schemas.$ZodType | checks.$ZodCheck, IssueTypes extends errors.$ZodIssueBase, OmitKeys extends keyof T["_zod"]["def"] = never> = util.Flatten<Partial<util.EmptyToNever<Omit<T["_zod"]["def"], OmitKeys> & ([IssueTypes] extends [never] ? {} : {
error?: string | errors.$ZodErrorMap<IssueTypes> | undefined;
/** @deprecated This parameter is deprecated. Use `error` instead. */
message?: string | undefined;
})>>>;
export type TypeParams<T extends schemas.$ZodType = schemas.$ZodType & {
_isst: never;
}, AlsoOmit extends Exclude<keyof T["_zod"]["def"], "type" | "checks" | "error"> = never> = Params<T, NonNullable<T["_zod"]["isst"]>, "type" | "checks" | "error" | AlsoOmit>;
export type CheckParams<T extends checks.$ZodCheck = checks.$ZodCheck, // & { _issc: never },
AlsoOmit extends Exclude<keyof T["_zod"]["def"], "check" | "error"> = never> = Params<T, NonNullable<T["_zod"]["issc"]>, "check" | "error" | AlsoOmit>;
export type StringFormatParams<T extends schemas.$ZodStringFormat = schemas.$ZodStringFormat, AlsoOmit extends Exclude<keyof T["_zod"]["def"], "type" | "coerce" | "checks" | "error" | "check" | "format"> = never> = Params<T, NonNullable<T["_zod"]["isst"] | T["_zod"]["issc"]>, "type" | "coerce" | "checks" | "error" | "check" | "format" | AlsoOmit>;
export type CheckStringFormatParams<T extends schemas.$ZodStringFormat = schemas.$ZodStringFormat, AlsoOmit extends Exclude<keyof T["_zod"]["def"], "type" | "coerce" | "checks" | "error" | "check" | "format"> = never> = Params<T, NonNullable<T["_zod"]["issc"]>, "type" | "coerce" | "checks" | "error" | "check" | "format" | AlsoOmit>;
export type CheckTypeParams<T extends schemas.$ZodType & checks.$ZodCheck = schemas.$ZodType & checks.$ZodCheck, AlsoOmit extends Exclude<keyof T["_zod"]["def"], "type" | "checks" | "error" | "check"> = never> = Params<T, NonNullable<T["_zod"]["isst"] | T["_zod"]["issc"]>, "type" | "checks" | "error" | "check" | AlsoOmit>;
export type $ZodStringParams = TypeParams<schemas.$ZodString<string>, "coerce">;
export declare function _string<T extends schemas.$ZodString>(Class: util.SchemaClass<T>, params?: string | $ZodStringParams): T;
export declare function _coercedString<T extends schemas.$ZodString>(Class: util.SchemaClass<T>, params?: string | $ZodStringParams): T;
export type $ZodStringFormatParams = CheckTypeParams<schemas.$ZodStringFormat, "format" | "coerce">;
export type $ZodCheckStringFormatParams = CheckParams<checks.$ZodCheckStringFormat, "format">;
export type $ZodEmailParams = StringFormatParams<schemas.$ZodEmail>;
export type $ZodCheckEmailParams = CheckStringFormatParams<schemas.$ZodEmail>;
export declare function _email<T extends schemas.$ZodEmail>(Class: util.SchemaClass<T>, params?: string | $ZodEmailParams | $ZodCheckEmailParams): T;
export type $ZodGUIDParams = StringFormatParams<schemas.$ZodGUID, "pattern">;
export type $ZodCheckGUIDParams = CheckStringFormatParams<schemas.$ZodGUID, "pattern">;
export declare function _guid<T extends schemas.$ZodGUID>(Class: util.SchemaClass<T>, params?: string | $ZodGUIDParams | $ZodCheckGUIDParams): T;
export type $ZodUUIDParams = StringFormatParams<schemas.$ZodUUID, "pattern">;
export type $ZodCheckUUIDParams = CheckStringFormatParams<schemas.$ZodUUID, "pattern">;
export declare function _uuid<T extends schemas.$ZodUUID>(Class: util.SchemaClass<T>, params?: string | $ZodUUIDParams | $ZodCheckUUIDParams): T;
export type $ZodUUIDv4Params = StringFormatParams<schemas.$ZodUUID, "pattern">;
export type $ZodCheckUUIDv4Params = CheckStringFormatParams<schemas.$ZodUUID, "pattern">;
export declare function _uuidv4<T extends schemas.$ZodUUID>(Class: util.SchemaClass<T>, params?: string | $ZodUUIDv4Params | $ZodCheckUUIDv4Params): T;
export type $ZodUUIDv6Params = StringFormatParams<schemas.$ZodUUID, "pattern">;
export type $ZodCheckUUIDv6Params = CheckStringFormatParams<schemas.$ZodUUID, "pattern">;
export declare function _uuidv6<T extends schemas.$ZodUUID>(Class: util.SchemaClass<T>, params?: string | $ZodUUIDv6Params | $ZodCheckUUIDv6Params): T;
export type $ZodUUIDv7Params = StringFormatParams<schemas.$ZodUUID, "pattern">;
export type $ZodCheckUUIDv7Params = CheckStringFormatParams<schemas.$ZodUUID, "pattern">;
export declare function _uuidv7<T extends schemas.$ZodUUID>(Class: util.SchemaClass<T>, params?: string | $ZodUUIDv7Params | $ZodCheckUUIDv7Params): T;
export type $ZodURLParams = StringFormatParams<schemas.$ZodURL>;
export type $ZodCheckURLParams = CheckStringFormatParams<schemas.$ZodURL>;
export declare function _url<T extends schemas.$ZodURL>(Class: util.SchemaClass<T>, params?: string | $ZodURLParams | $ZodCheckURLParams): T;
export type $ZodEmojiParams = StringFormatParams<schemas.$ZodEmoji>;
export type $ZodCheckEmojiParams = CheckStringFormatParams<schemas.$ZodEmoji>;
export declare function _emoji<T extends schemas.$ZodEmoji>(Class: util.SchemaClass<T>, params?: string | $ZodEmojiParams | $ZodCheckEmojiParams): T;
export type $ZodNanoIDParams = StringFormatParams<schemas.$ZodNanoID>;
export type $ZodCheckNanoIDParams = CheckStringFormatParams<schemas.$ZodNanoID>;
export declare function _nanoid<T extends schemas.$ZodNanoID>(Class: util.SchemaClass<T>, params?: string | $ZodNanoIDParams | $ZodCheckNanoIDParams): T;
export type $ZodCUIDParams = StringFormatParams<schemas.$ZodCUID>;
export type $ZodCheckCUIDParams = CheckStringFormatParams<schemas.$ZodCUID>;
export declare function _cuid<T extends schemas.$ZodCUID>(Class: util.SchemaClass<T>, params?: string | $ZodCUIDParams | $ZodCheckCUIDParams): T;
export type $ZodCUID2Params = StringFormatParams<schemas.$ZodCUID2>;
export type $ZodCheckCUID2Params = CheckStringFormatParams<schemas.$ZodCUID2>;
export declare function _cuid2<T extends schemas.$ZodCUID2>(Class: util.SchemaClass<T>, params?: string | $ZodCUID2Params | $ZodCheckCUID2Params): T;
export type $ZodULIDParams = StringFormatParams<schemas.$ZodULID>;
export type $ZodCheckULIDParams = CheckStringFormatParams<schemas.$ZodULID>;
export declare function _ulid<T extends schemas.$ZodULID>(Class: util.SchemaClass<T>, params?: string | $ZodULIDParams | $ZodCheckULIDParams): T;
export type $ZodXIDParams = StringFormatParams<schemas.$ZodXID>;
export type $ZodCheckXIDParams = CheckStringFormatParams<schemas.$ZodXID>;
export declare function _xid<T extends schemas.$ZodXID>(Class: util.SchemaClass<T>, params?: string | $ZodXIDParams | $ZodCheckXIDParams): T;
export type $ZodKSUIDParams = StringFormatParams<schemas.$ZodKSUID>;
export type $ZodCheckKSUIDParams = CheckStringFormatParams<schemas.$ZodKSUID>;
export declare function _ksuid<T extends schemas.$ZodKSUID>(Class: util.SchemaClass<T>, params?: string | $ZodKSUIDParams | $ZodCheckKSUIDParams): T;
export type $ZodIPv4Params = StringFormatParams<schemas.$ZodIPv4, "pattern">;
export type $ZodCheckIPv4Params = CheckStringFormatParams<schemas.$ZodIPv4, "pattern">;
export declare function _ipv4<T extends schemas.$ZodIPv4>(Class: util.SchemaClass<T>, params?: string | $ZodIPv4Params | $ZodCheckIPv4Params): T;
export type $ZodIPv6Params = StringFormatParams<schemas.$ZodIPv6, "pattern">;
export type $ZodCheckIPv6Params = CheckStringFormatParams<schemas.$ZodIPv6, "pattern">;
export declare function _ipv6<T extends schemas.$ZodIPv6>(Class: util.SchemaClass<T>, params?: string | $ZodIPv6Params | $ZodCheckIPv6Params): T;
export type $ZodCIDRv4Params = StringFormatParams<schemas.$ZodCIDRv4, "pattern">;
export type $ZodCheckCIDRv4Params = CheckStringFormatParams<schemas.$ZodCIDRv4, "pattern">;
export declare function _cidrv4<T extends schemas.$ZodCIDRv4>(Class: util.SchemaClass<T>, params?: string | $ZodCIDRv4Params | $ZodCheckCIDRv4Params): T;
export type $ZodCIDRv6Params = StringFormatParams<schemas.$ZodCIDRv6, "pattern">;
export type $ZodCheckCIDRv6Params = CheckStringFormatParams<schemas.$ZodCIDRv6, "pattern">;
export declare function _cidrv6<T extends schemas.$ZodCIDRv6>(Class: util.SchemaClass<T>, params?: string | $ZodCIDRv6Params | $ZodCheckCIDRv6Params): T;
export type $ZodBase64Params = StringFormatParams<schemas.$ZodBase64, "pattern">;
export type $ZodCheckBase64Params = CheckStringFormatParams<schemas.$ZodBase64, "pattern">;
export declare function _base64<T extends schemas.$ZodBase64>(Class: util.SchemaClass<T>, params?: string | $ZodBase64Params | $ZodCheckBase64Params): T;
export type $ZodBase64URLParams = StringFormatParams<schemas.$ZodBase64URL, "pattern">;
export type $ZodCheckBase64URLParams = CheckStringFormatParams<schemas.$ZodBase64URL, "pattern">;
export declare function _base64url<T extends schemas.$ZodBase64URL>(Class: util.SchemaClass<T>, params?: string | $ZodBase64URLParams | $ZodCheckBase64URLParams): T;
export type $ZodE164Params = StringFormatParams<schemas.$ZodE164>;
export type $ZodCheckE164Params = CheckStringFormatParams<schemas.$ZodE164>;
export declare function _e164<T extends schemas.$ZodE164>(Class: util.SchemaClass<T>, params?: string | $ZodE164Params | $ZodCheckE164Params): T;
export type $ZodJWTParams = StringFormatParams<schemas.$ZodJWT, "pattern">;
export type $ZodCheckJWTParams = CheckStringFormatParams<schemas.$ZodJWT, "pattern">;
export declare function _jwt<T extends schemas.$ZodJWT>(Class: util.SchemaClass<T>, params?: string | $ZodJWTParams | $ZodCheckJWTParams): T;
export declare const TimePrecision: {
readonly Any: null;
readonly Minute: -1;
readonly Second: 0;
readonly Millisecond: 3;
readonly Microsecond: 6;
};
export type $ZodISODateTimeParams = StringFormatParams<schemas.$ZodISODateTime, "pattern">;
export type $ZodCheckISODateTimeParams = CheckStringFormatParams<schemas.$ZodISODateTime, "pattern">;
export declare function _isoDateTime<T extends schemas.$ZodISODateTime>(Class: util.SchemaClass<T>, params?: string | $ZodISODateTimeParams | $ZodCheckISODateTimeParams): T;
export type $ZodISODateParams = StringFormatParams<schemas.$ZodISODate, "pattern">;
export type $ZodCheckISODateParams = CheckStringFormatParams<schemas.$ZodISODate, "pattern">;
export declare function _isoDate<T extends schemas.$ZodISODate>(Class: util.SchemaClass<T>, params?: string | $ZodISODateParams | $ZodCheckISODateParams): T;
export type $ZodISOTimeParams = StringFormatParams<schemas.$ZodISOTime, "pattern">;
export type $ZodCheckISOTimeParams = CheckStringFormatParams<schemas.$ZodISOTime, "pattern">;
export declare function _isoTime<T extends schemas.$ZodISOTime>(Class: util.SchemaClass<T>, params?: string | $ZodISOTimeParams | $ZodCheckISOTimeParams): T;
export type $ZodISODurationParams = StringFormatParams<schemas.$ZodISODuration>;
export type $ZodCheckISODurationParams = CheckStringFormatParams<schemas.$ZodISODuration>;
export declare function _isoDuration<T extends schemas.$ZodISODuration>(Class: util.SchemaClass<T>, params?: string | $ZodISODurationParams | $ZodCheckISODurationParams): T;
export type $ZodNumberParams = TypeParams<schemas.$ZodNumber<number>, "coerce">;
export type $ZodNumberFormatParams = CheckTypeParams<schemas.$ZodNumberFormat, "format" | "coerce">;
export type $ZodCheckNumberFormatParams = CheckParams<checks.$ZodCheckNumberFormat, "format">;
export declare function _number<T extends schemas.$ZodNumber>(Class: util.SchemaClass<T>, params?: string | $ZodNumberParams): T;
export declare function _coercedNumber<T extends schemas.$ZodNumber>(Class: util.SchemaClass<T>, params?: string | $ZodNumberParams): T;
export declare function _int<T extends schemas.$ZodNumberFormat>(Class: util.SchemaClass<T>, params?: string | $ZodCheckNumberFormatParams): T;
export declare function _float32<T extends schemas.$ZodNumberFormat>(Class: util.SchemaClass<T>, params?: string | $ZodCheckNumberFormatParams): T;
export declare function _float64<T extends schemas.$ZodNumberFormat>(Class: util.SchemaClass<T>, params?: string | $ZodCheckNumberFormatParams): T;
export declare function _int32<T extends schemas.$ZodNumberFormat>(Class: util.SchemaClass<T>, params?: string | $ZodCheckNumberFormatParams): T;
export declare function _uint32<T extends schemas.$ZodNumberFormat>(Class: util.SchemaClass<T>, params?: string | $ZodCheckNumberFormatParams): T;
export type $ZodBooleanParams = TypeParams<schemas.$ZodBoolean<boolean>, "coerce">;
export declare function _boolean<T extends schemas.$ZodBoolean>(Class: util.SchemaClass<T>, params?: string | $ZodBooleanParams): T;
export declare function _coercedBoolean<T extends schemas.$ZodBoolean>(Class: util.SchemaClass<T>, params?: string | $ZodBooleanParams): T;
export type $ZodBigIntParams = TypeParams<schemas.$ZodBigInt<bigint>>;
export type $ZodBigIntFormatParams = CheckTypeParams<schemas.$ZodBigIntFormat, "format" | "coerce">;
export type $ZodCheckBigIntFormatParams = CheckParams<checks.$ZodCheckBigIntFormat, "format">;
export declare function _bigint<T extends schemas.$ZodBigInt>(Class: util.SchemaClass<T>, params?: string | $ZodBigIntParams): T;
export declare function _coercedBigint<T extends schemas.$ZodBigInt>(Class: util.SchemaClass<T>, params?: string | $ZodBigIntParams): T;
export declare function _int64<T extends schemas.$ZodBigIntFormat>(Class: util.SchemaClass<T>, params?: string | $ZodBigIntFormatParams): T;
export declare function _uint64<T extends schemas.$ZodBigIntFormat>(Class: util.SchemaClass<T>, params?: string | $ZodBigIntFormatParams): T;
export type $ZodSymbolParams = TypeParams<schemas.$ZodSymbol>;
export declare function _symbol<T extends schemas.$ZodSymbol>(Class: util.SchemaClass<T>, params?: string | $ZodSymbolParams): T;
export type $ZodUndefinedParams = TypeParams<schemas.$ZodUndefined>;
export declare function _undefined<T extends schemas.$ZodUndefined>(Class: util.SchemaClass<T>, params?: string | $ZodUndefinedParams): T;
export type $ZodNullParams = TypeParams<schemas.$ZodNull>;
export declare function _null<T extends schemas.$ZodNull>(Class: util.SchemaClass<T>, params?: string | $ZodNullParams): T;
export type $ZodAnyParams = TypeParams<schemas.$ZodAny>;
export declare function _any<T extends schemas.$ZodAny>(Class: util.SchemaClass<T>): T;
export type $ZodUnknownParams = TypeParams<schemas.$ZodUnknown>;
export declare function _unknown<T extends schemas.$ZodUnknown>(Class: util.SchemaClass<T>): T;
export type $ZodNeverParams = TypeParams<schemas.$ZodNever>;
export declare function _never<T extends schemas.$ZodNever>(Class: util.SchemaClass<T>, params?: string | $ZodNeverParams): T;
export type $ZodVoidParams = TypeParams<schemas.$ZodVoid>;
export declare function _void<T extends schemas.$ZodVoid>(Class: util.SchemaClass<T>, params?: string | $ZodVoidParams): T;
export type $ZodDateParams = TypeParams<schemas.$ZodDate, "coerce">;
export declare function _date<T extends schemas.$ZodDate>(Class: util.SchemaClass<T>, params?: string | $ZodDateParams): T;
export declare function _coercedDate<T extends schemas.$ZodDate>(Class: util.SchemaClass<T>, params?: string | $ZodDateParams): T;
export type $ZodNaNParams = TypeParams<schemas.$ZodNaN>;
export declare function _nan<T extends schemas.$ZodNaN>(Class: util.SchemaClass<T>, params?: string | $ZodNaNParams): T;
export type $ZodCheckLessThanParams = CheckParams<checks.$ZodCheckLessThan, "inclusive" | "value">;
export declare function _lt(value: util.Numeric, params?: string | $ZodCheckLessThanParams): checks.$ZodCheckLessThan<util.Numeric>;
export declare function _lte(value: util.Numeric, params?: string | $ZodCheckLessThanParams): checks.$ZodCheckLessThan<util.Numeric>;
export {
/** @deprecated Use `z.lte()` instead. */
_lte as _max, };
export type $ZodCheckGreaterThanParams = CheckParams<checks.$ZodCheckGreaterThan, "inclusive" | "value">;
export declare function _gt(value: util.Numeric, params?: string | $ZodCheckGreaterThanParams): checks.$ZodCheckGreaterThan;
export declare function _gte(value: util.Numeric, params?: string | $ZodCheckGreaterThanParams): checks.$ZodCheckGreaterThan;
export {
/** @deprecated Use `z.gte()` instead. */
_gte as _min, };
export declare function _positive(params?: string | $ZodCheckGreaterThanParams): checks.$ZodCheckGreaterThan;
export declare function _negative(params?: string | $ZodCheckLessThanParams): checks.$ZodCheckLessThan;
export declare function _nonpositive(params?: string | $ZodCheckLessThanParams): checks.$ZodCheckLessThan;
export declare function _nonnegative(params?: string | $ZodCheckGreaterThanParams): checks.$ZodCheckGreaterThan;
export type $ZodCheckMultipleOfParams = CheckParams<checks.$ZodCheckMultipleOf, "value">;
export declare function _multipleOf(value: number | bigint, params?: string | $ZodCheckMultipleOfParams): checks.$ZodCheckMultipleOf;
export type $ZodCheckMaxSizeParams = CheckParams<checks.$ZodCheckMaxSize, "maximum">;
export declare function _maxSize(maximum: number, params?: string | $ZodCheckMaxSizeParams): checks.$ZodCheckMaxSize<util.HasSize>;
export type $ZodCheckMinSizeParams = CheckParams<checks.$ZodCheckMinSize, "minimum">;
export declare function _minSize(minimum: number, params?: string | $ZodCheckMinSizeParams): checks.$ZodCheckMinSize<util.HasSize>;
export type $ZodCheckSizeEqualsParams = CheckParams<checks.$ZodCheckSizeEquals, "size">;
export declare function _size(size: number, params?: string | $ZodCheckSizeEqualsParams): checks.$ZodCheckSizeEquals<util.HasSize>;
export type $ZodCheckMaxLengthParams = CheckParams<checks.$ZodCheckMaxLength, "maximum">;
export declare function _maxLength(maximum: number, params?: string | $ZodCheckMaxLengthParams): checks.$ZodCheckMaxLength<util.HasLength>;
export type $ZodCheckMinLengthParams = CheckParams<checks.$ZodCheckMinLength, "minimum">;
export declare function _minLength(minimum: number, params?: string | $ZodCheckMinLengthParams): checks.$ZodCheckMinLength<util.HasLength>;
export type $ZodCheckLengthEqualsParams = CheckParams<checks.$ZodCheckLengthEquals, "length">;
export declare function _length(length: number, params?: string | $ZodCheckLengthEqualsParams): checks.$ZodCheckLengthEquals<util.HasLength>;
export type $ZodCheckRegexParams = CheckParams<checks.$ZodCheckRegex, "format" | "pattern">;
export declare function _regex(pattern: RegExp, params?: string | $ZodCheckRegexParams): checks.$ZodCheckRegex;
export type $ZodCheckLowerCaseParams = CheckParams<checks.$ZodCheckLowerCase, "format">;
export declare function _lowercase(params?: string | $ZodCheckLowerCaseParams): checks.$ZodCheckLowerCase;
export type $ZodCheckUpperCaseParams = CheckParams<checks.$ZodCheckUpperCase, "format">;
export declare function _uppercase(params?: string | $ZodCheckUpperCaseParams): checks.$ZodCheckUpperCase;
export type $ZodCheckIncludesParams = CheckParams<checks.$ZodCheckIncludes, "includes" | "format" | "pattern">;
export declare function _includes(includes: string, params?: string | $ZodCheckIncludesParams): checks.$ZodCheckIncludes;
export type $ZodCheckStartsWithParams = CheckParams<checks.$ZodCheckStartsWith, "prefix" | "format" | "pattern">;
export declare function _startsWith(prefix: string, params?: string | $ZodCheckStartsWithParams): checks.$ZodCheckStartsWith;
export type $ZodCheckEndsWithParams = CheckParams<checks.$ZodCheckEndsWith, "suffix" | "format" | "pattern">;
export declare function _endsWith(suffix: string, params?: string | $ZodCheckEndsWithParams): checks.$ZodCheckEndsWith;
export type $ZodCheckPropertyParams = CheckParams<checks.$ZodCheckProperty, "property" | "schema">;
export declare function _property<K extends string, T extends schemas.$ZodType>(property: K, schema: T, params?: string | $ZodCheckPropertyParams): checks.$ZodCheckProperty<{
[k in K]: core.output<T>;
}>;
export type $ZodCheckMimeTypeParams = CheckParams<checks.$ZodCheckMimeType, "mime">;
export declare function _mime(types: util.MimeTypes[], params?: string | $ZodCheckMimeTypeParams): checks.$ZodCheckMimeType;
export declare function _overwrite<T>(tx: (input: T) => T): checks.$ZodCheckOverwrite<T>;
export declare function _normalize(form?: "NFC" | "NFD" | "NFKC" | "NFKD" | (string & {})): checks.$ZodCheckOverwrite<string>;
export declare function _trim(): checks.$ZodCheckOverwrite<string>;
export declare function _toLowerCase(): checks.$ZodCheckOverwrite<string>;
export declare function _toUpperCase(): checks.$ZodCheckOverwrite<string>;
export type $ZodArrayParams = TypeParams<schemas.$ZodArray, "element">;
export declare function _array<T extends schemas.$ZodType>(Class: util.SchemaClass<schemas.$ZodArray>, element: T, params?: string | $ZodArrayParams): schemas.$ZodArray<T>;
export type $ZodObjectParams = TypeParams<schemas.$ZodObject, "shape" | "catchall">;
export type $ZodUnionParams = TypeParams<schemas.$ZodUnion, "options">;
export declare function _union<const T extends readonly schemas.$ZodObject[]>(Class: util.SchemaClass<schemas.$ZodUnion>, options: T, params?: string | $ZodUnionParams): schemas.$ZodUnion<T>;
export interface $ZodTypeDiscriminableInternals extends schemas.$ZodTypeInternals {
propValues: util.PropValues;
}
export interface $ZodTypeDiscriminable extends schemas.$ZodType {
_zod: $ZodTypeDiscriminableInternals;
}
export type $ZodDiscriminatedUnionParams = TypeParams<schemas.$ZodDiscriminatedUnion, "options" | "discriminator">;
export declare function _discriminatedUnion<Types extends [$ZodTypeDiscriminable, ...$ZodTypeDiscriminable[]]>(Class: util.SchemaClass<schemas.$ZodDiscriminatedUnion>, discriminator: string, options: Types, params?: string | $ZodDiscriminatedUnionParams): schemas.$ZodDiscriminatedUnion<Types>;
export type $ZodIntersectionParams = TypeParams<schemas.$ZodIntersection, "left" | "right">;
export declare function _intersection<T extends schemas.$ZodObject, U extends schemas.$ZodObject>(Class: util.SchemaClass<schemas.$ZodIntersection>, left: T, right: U): schemas.$ZodIntersection<T, U>;
export type $ZodTupleParams = TypeParams<schemas.$ZodTuple, "items" | "rest">;
export declare function _tuple<T extends readonly [schemas.$ZodType, ...schemas.$ZodType[]]>(Class: util.SchemaClass<schemas.$ZodTuple>, items: T, params?: string | $ZodTupleParams): schemas.$ZodTuple<T, null>;
export declare function _tuple<T extends readonly [schemas.$ZodType, ...schemas.$ZodType[]], Rest extends schemas.$ZodType>(Class: util.SchemaClass<schemas.$ZodTuple>, items: T, rest: Rest, params?: string | $ZodTupleParams): schemas.$ZodTuple<T, Rest>;
export type $ZodRecordParams = TypeParams<schemas.$ZodRecord, "keyType" | "valueType">;
export declare function _record<Key extends schemas.$ZodRecordKey, Value extends schemas.$ZodObject>(Class: util.SchemaClass<schemas.$ZodRecord>, keyType: Key, valueType: Value, params?: string | $ZodRecordParams): schemas.$ZodRecord<Key, Value>;
export type $ZodMapParams = TypeParams<schemas.$ZodMap, "keyType" | "valueType">;
export declare function _map<Key extends schemas.$ZodObject, Value extends schemas.$ZodObject>(Class: util.SchemaClass<schemas.$ZodMap>, keyType: Key, valueType: Value, params?: string | $ZodMapParams): schemas.$ZodMap<Key, Value>;
export type $ZodSetParams = TypeParams<schemas.$ZodSet, "valueType">;
export declare function _set<Value extends schemas.$ZodObject>(Class: util.SchemaClass<schemas.$ZodSet>, valueType: Value, params?: string | $ZodSetParams): schemas.$ZodSet<Value>;
export type $ZodEnumParams = TypeParams<schemas.$ZodEnum, "entries">;
export declare function _enum<const T extends string[]>(Class: util.SchemaClass<schemas.$ZodEnum>, values: T, params?: string | $ZodEnumParams): schemas.$ZodEnum<util.ToEnum<T[number]>>;
export declare function _enum<T extends util.EnumLike>(Class: util.SchemaClass<schemas.$ZodEnum>, entries: T, params?: string | $ZodEnumParams): schemas.$ZodEnum<T>;
/** @deprecated This API has been merged into `z.enum()`. Use `z.enum()` instead.
*
* ```ts
* enum Colors { red, green, blue }
* z.enum(Colors);
* ```
*/
export declare function _nativeEnum<T extends util.EnumLike>(Class: util.SchemaClass<schemas.$ZodEnum>, entries: T, params?: string | $ZodEnumParams): schemas.$ZodEnum<T>;
export type $ZodLiteralParams = TypeParams<schemas.$ZodLiteral, "values">;
export declare function _literal<const T extends Array<util.Literal>>(Class: util.SchemaClass<schemas.$ZodLiteral>, value: T, params?: string | $ZodLiteralParams): schemas.$ZodLiteral<T[number]>;
export declare function _literal<const T extends util.Literal>(Class: util.SchemaClass<schemas.$ZodLiteral>, value: T, params?: string | $ZodLiteralParams): schemas.$ZodLiteral<T>;
export type $ZodFileParams = TypeParams<schemas.$ZodFile>;
export declare function _file(Class: util.SchemaClass<schemas.$ZodFile>, params?: string | $ZodFileParams): schemas.$ZodFile;
export type $ZodTransformParams = TypeParams<schemas.$ZodTransform, "transform">;
export declare function _transform<I = unknown, O = I>(Class: util.SchemaClass<schemas.$ZodTransform>, fn: (input: I, ctx?: schemas.ParsePayload) => O): schemas.$ZodTransform<Awaited<O>, I>;
export type $ZodOptionalParams = TypeParams<schemas.$ZodOptional, "innerType">;
export declare function _optional<T extends schemas.$ZodObject>(Class: util.SchemaClass<schemas.$ZodOptional>, innerType: T): schemas.$ZodOptional<T>;
export type $ZodNullableParams = TypeParams<schemas.$ZodNullable, "innerType">;
export declare function _nullable<T extends schemas.$ZodObject>(Class: util.SchemaClass<schemas.$ZodNullable>, innerType: T): schemas.$ZodNullable<T>;
export type $ZodDefaultParams = TypeParams<schemas.$ZodDefault, "innerType" | "defaultValue">;
export declare function _default<T extends schemas.$ZodObject>(Class: util.SchemaClass<schemas.$ZodDefault>, innerType: T, defaultValue: util.NoUndefined<core.output<T>> | (() => util.NoUndefined<core.output<T>>)): schemas.$ZodDefault<T>;
export type $ZodNonOptionalParams = TypeParams<schemas.$ZodNonOptional, "innerType">;
export declare function _nonoptional<T extends schemas.$ZodObject>(Class: util.SchemaClass<schemas.$ZodNonOptional>, innerType: T, params?: string | $ZodNonOptionalParams): schemas.$ZodNonOptional<T>;
export type $ZodSuccessParams = TypeParams<schemas.$ZodSuccess, "innerType">;
export declare function _success<T extends schemas.$ZodObject>(Class: util.SchemaClass<schemas.$ZodSuccess>, innerType: T): schemas.$ZodSuccess<T>;
export type $ZodCatchParams = TypeParams<schemas.$ZodCatch, "innerType" | "catchValue">;
export declare function _catch<T extends schemas.$ZodObject>(Class: util.SchemaClass<schemas.$ZodCatch>, innerType: T, catchValue: core.output<T> | ((ctx: schemas.$ZodCatchCtx) => core.output<T>)): schemas.$ZodCatch<T>;
export type $ZodPipeParams = TypeParams<schemas.$ZodPipe, "in" | "out">;
export declare function _pipe<const A extends schemas.$ZodType, B extends schemas.$ZodType<unknown, core.output<A>> = schemas.$ZodType<unknown, core.output<A>>>(Class: util.SchemaClass<schemas.$ZodPipe>, in_: A, out: B | schemas.$ZodType<unknown, core.output<A>>): schemas.$ZodPipe<A, B>;
export type $ZodReadonlyParams = TypeParams<schemas.$ZodReadonly, "innerType">;
export declare function _readonly<T extends schemas.$ZodObject>(Class: util.SchemaClass<schemas.$ZodReadonly>, innerType: T): schemas.$ZodReadonly<T>;
export type $ZodTemplateLiteralParams = TypeParams<schemas.$ZodTemplateLiteral, "parts">;
export declare function _templateLiteral<const Parts extends schemas.$ZodTemplateLiteralPart[]>(Class: util.SchemaClass<schemas.$ZodTemplateLiteral>, parts: Parts, params?: string | $ZodTemplateLiteralParams): schemas.$ZodTemplateLiteral<schemas.$PartsToTemplateLiteral<Parts>>;
export type $ZodLazyParams = TypeParams<schemas.$ZodLazy, "getter">;
export declare function _lazy<T extends schemas.$ZodType>(Class: util.SchemaClass<schemas.$ZodLazy>, getter: () => T): schemas.$ZodLazy<T>;
export type $ZodPromiseParams = TypeParams<schemas.$ZodPromise, "innerType">;
export declare function _promise<T extends schemas.$ZodObject>(Class: util.SchemaClass<schemas.$ZodPromise>, innerType: T): schemas.$ZodPromise<T>;
export type $ZodCustomParams = CheckTypeParams<schemas.$ZodCustom, "fn">;
export declare function _custom<O = unknown, I = O>(Class: util.SchemaClass<schemas.$ZodCustom>, fn: (data: O) => unknown, _params: string | $ZodCustomParams | undefined): schemas.$ZodCustom<O, I>;
export declare function _refine<O = unknown, I = O>(Class: util.SchemaClass<schemas.$ZodCustom>, fn: (data: O) => unknown, _params: string | $ZodCustomParams | undefined): schemas.$ZodCustom<O, I>;
export interface $ZodStringBoolParams extends TypeParams {
truthy?: string[];
falsy?: string[];
/**
* Options: `"sensitive"`, `"insensitive"`
*
* @default `"insensitive"`
*/
case?: "sensitive" | "insensitive" | undefined;
}
export declare function _stringbool(Classes: {
Pipe?: typeof schemas.$ZodPipe;
Boolean?: typeof schemas.$ZodBoolean;
Transform?: typeof schemas.$ZodTransform;
String?: typeof schemas.$ZodString;
}, _params?: string | $ZodStringBoolParams): schemas.$ZodPipe<schemas.$ZodPipe<schemas.$ZodString, schemas.$ZodTransform<boolean, string>>, schemas.$ZodBoolean<boolean>>;
export declare function _stringFormat<Format extends string>(Class: typeof schemas.$ZodCustomStringFormat, format: Format, fnOrRegex: ((arg: string) => util.MaybeAsync<unknown>) | RegExp, _params?: string | $ZodStringFormatParams): schemas.$ZodCustomStringFormat<Format>;
@@ -0,0 +1,37 @@
"use strict";
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
Object.defineProperty(exports, "__esModule", {
value: true
});
exports["default"] = useBoolean;
var _tslib = require("tslib");
var _react = require("react");
var _useToggle = _interopRequireDefault(require("../useToggle"));
function useBoolean(defaultValue) {
if (defaultValue === void 0) {
defaultValue = false;
}
var _a = (0, _tslib.__read)((0, _useToggle["default"])(!!defaultValue), 2),
state = _a[0],
_b = _a[1],
toggle = _b.toggle,
_set = _b.set;
var actions = (0, _react.useMemo)(function () {
var setTrue = function setTrue() {
return _set(true);
};
var setFalse = function setFalse() {
return _set(false);
};
return {
toggle: toggle,
set: function set(v) {
return _set(!!v);
},
setTrue: setTrue,
setFalse: setFalse
};
}, []);
return [state, actions];
}
@@ -0,0 +1,138 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.ZodError = exports.quotelessJson = exports.ZodIssueCode = void 0;
const util_js_1 = require("./helpers/util.cjs");
exports.ZodIssueCode = util_js_1.util.arrayToEnum([
"invalid_type",
"invalid_literal",
"custom",
"invalid_union",
"invalid_union_discriminator",
"invalid_enum_value",
"unrecognized_keys",
"invalid_arguments",
"invalid_return_type",
"invalid_date",
"invalid_string",
"too_small",
"too_big",
"invalid_intersection_types",
"not_multiple_of",
"not_finite",
]);
const quotelessJson = (obj) => {
const json = JSON.stringify(obj, null, 2);
return json.replace(/"([^"]+)":/g, "$1:");
};
exports.quotelessJson = quotelessJson;
class ZodError extends Error {
get errors() {
return this.issues;
}
constructor(issues) {
super();
this.issues = [];
this.addIssue = (sub) => {
this.issues = [...this.issues, sub];
};
this.addIssues = (subs = []) => {
this.issues = [...this.issues, ...subs];
};
const actualProto = new.target.prototype;
if (Object.setPrototypeOf) {
// eslint-disable-next-line ban/ban
Object.setPrototypeOf(this, actualProto);
}
else {
this.__proto__ = actualProto;
}
this.name = "ZodError";
this.issues = issues;
}
format(_mapper) {
const mapper = _mapper ||
function (issue) {
return issue.message;
};
const fieldErrors = { _errors: [] };
const processError = (error) => {
for (const issue of error.issues) {
if (issue.code === "invalid_union") {
issue.unionErrors.map(processError);
}
else if (issue.code === "invalid_return_type") {
processError(issue.returnTypeError);
}
else if (issue.code === "invalid_arguments") {
processError(issue.argumentsError);
}
else if (issue.path.length === 0) {
fieldErrors._errors.push(mapper(issue));
}
else {
let curr = fieldErrors;
let i = 0;
while (i < issue.path.length) {
const el = issue.path[i];
const terminal = i === issue.path.length - 1;
if (!terminal) {
curr[el] = curr[el] || { _errors: [] };
// if (typeof el === "string") {
// curr[el] = curr[el] || { _errors: [] };
// } else if (typeof el === "number") {
// const errorArray: any = [];
// errorArray._errors = [];
// curr[el] = curr[el] || errorArray;
// }
}
else {
curr[el] = curr[el] || { _errors: [] };
curr[el]._errors.push(mapper(issue));
}
curr = curr[el];
i++;
}
}
}
};
processError(this);
return fieldErrors;
}
static assert(value) {
if (!(value instanceof ZodError)) {
throw new Error(`Not a ZodError: ${value}`);
}
}
toString() {
return this.message;
}
get message() {
return JSON.stringify(this.issues, util_js_1.util.jsonStringifyReplacer, 2);
}
get isEmpty() {
return this.issues.length === 0;
}
flatten(mapper = (issue) => issue.message) {
const fieldErrors = {};
const formErrors = [];
for (const sub of this.issues) {
if (sub.path.length > 0) {
const firstEl = sub.path[0];
fieldErrors[firstEl] = fieldErrors[firstEl] || [];
fieldErrors[firstEl].push(mapper(sub));
}
else {
formErrors.push(mapper(sub));
}
}
return { formErrors, fieldErrors };
}
get formErrors() {
return this.flatten();
}
}
exports.ZodError = ZodError;
ZodError.create = (issues) => {
const error = new ZodError(issues);
return error;
};
@@ -0,0 +1,29 @@
import type { ITokenizerOptions, IReadChunkOptions, IRandomAccessFileInfo, IRandomAccessTokenizer } from './types.js';
import { AbstractTokenizer } from './AbstractTokenizer.js';
export declare class BufferTokenizer extends AbstractTokenizer implements IRandomAccessTokenizer {
private uint8Array;
fileInfo: IRandomAccessFileInfo;
/**
* Construct BufferTokenizer
* @param uint8Array - Uint8Array to tokenize
* @param options Tokenizer options
*/
constructor(uint8Array: Uint8Array, options?: ITokenizerOptions);
/**
* Read buffer from tokenizer
* @param uint8Array - Uint8Array to tokenize
* @param options - Read behaviour options
* @returns {Promise<number>}
*/
readBuffer(uint8Array: Uint8Array, options?: IReadChunkOptions): Promise<number>;
/**
* Peek (read ahead) buffer from tokenizer
* @param uint8Array
* @param options - Read behaviour options
* @returns {Promise<number>}
*/
peekBuffer(uint8Array: Uint8Array, options?: IReadChunkOptions): Promise<number>;
close(): Promise<void>;
supportsRandomAccess(): boolean;
setPosition(position: number): void;
}
@@ -0,0 +1,2 @@
import Decimal from 'decimal.js';
export declare function ToIntlMathematicalValue(input: unknown): Decimal;
@@ -0,0 +1,19 @@
import type { GenMapping } from '@jridgewell/gen-mapping';
import type { DecodedSourceMap, EncodedSourceMap, Options } from './types.mts';
/**
* A SourceMap v3 compatible sourcemap, which only includes fields that were
* provided to it.
*/
export default class SourceMap {
file?: string | null;
mappings: EncodedSourceMap['mappings'] | DecodedSourceMap['mappings'];
sourceRoot?: string;
names: string[];
sources: (string | null)[];
sourcesContent?: (string | null)[];
version: 3;
ignoreList: number[] | undefined;
constructor(map: GenMapping, options: Options);
toString(): string;
}
//# sourceMappingURL=source-map.d.ts.map
@@ -0,0 +1,27 @@
import createCompounder from './_createCompounder.js';
/**
* Converts `string`, as space separated words, to upper case.
*
* @static
* @memberOf _
* @since 4.0.0
* @category String
* @param {string} [string=''] The string to convert.
* @returns {string} Returns the upper cased string.
* @example
*
* _.upperCase('--foo-bar');
* // => 'FOO BAR'
*
* _.upperCase('fooBar');
* // => 'FOO BAR'
*
* _.upperCase('__foo_bar__');
* // => 'FOO BAR'
*/
var upperCase = createCompounder(function(result, word, index) {
return result + (index ? ' ' : '') + word.toUpperCase();
});
export default upperCase;
@@ -0,0 +1,63 @@
{
"name": "@heroui/slider",
"version": "2.4.8",
"description": "A slider allows a user to select one or more values within a range.",
"keywords": [
"slider"
],
"author": "Junior Garcia <jrgarciadev@gmail.com>",
"homepage": "https://heroui.com",
"license": "MIT",
"main": "dist/index.js",
"sideEffects": false,
"files": [
"dist"
],
"publishConfig": {
"access": "public"
},
"repository": {
"type": "git",
"url": "git+https://github.com/heroui-inc/heroui.git",
"directory": "packages/components/slider"
},
"bugs": {
"url": "https://github.com/heroui-inc/heroui/issues"
},
"peerDependencies": {
"react": ">=18 || >=19.0.0-rc.0",
"react-dom": ">=18 || >=19.0.0-rc.0",
"@heroui/theme": ">=2.4.0",
"@heroui/system": ">=2.4.0"
},
"dependencies": {
"@react-aria/focus": "3.19.0",
"@react-aria/i18n": "3.12.4",
"@react-aria/interactions": "3.22.5",
"@react-aria/slider": "3.7.14",
"@react-aria/utils": "3.26.0",
"@react-aria/visually-hidden": "3.8.18",
"@react-stately/slider": "3.6.0",
"@heroui/shared-utils": "2.1.3",
"@heroui/react-utils": "2.1.4",
"@heroui/tooltip": "2.2.8"
},
"clean-package": "../../../clean-package.config.json",
"module": "dist/index.mjs",
"types": "dist/index.d.ts",
"exports": {
".": {
"types": "./dist/index.d.ts",
"import": "./dist/index.mjs",
"require": "./dist/index.js"
},
"./package.json": "./package.json"
},
"scripts": {
"build": "tsup src --dts",
"build:fast": "tsup src",
"dev": "pnpm build:fast --watch",
"clean": "rimraf dist .turbo",
"typecheck": "tsc --noEmit"
}
}
@@ -0,0 +1,3 @@
import { LazyServiceIdentifier, ServiceIdentifier } from '@inversifyjs/common';
export declare function inject(serviceIdentifier: ServiceIdentifier | LazyServiceIdentifier): MethodDecorator & ParameterDecorator & PropertyDecorator;
//# sourceMappingURL=inject.d.ts.map
@@ -0,0 +1,10 @@
import * as fsWalk from '@nodelib/fs.walk';
import { Entry, ReaderOptions, Pattern } from '../types';
import Reader from './reader';
import ReaderStream from './stream';
export default class ReaderAsync extends Reader<Promise<Entry[]>> {
protected _walkAsync: typeof fsWalk.walk;
protected _readerStream: ReaderStream;
dynamic(root: string, options: ReaderOptions): Promise<Entry[]>;
static(patterns: Pattern[], options: ReaderOptions): Promise<Entry[]>;
}
@@ -0,0 +1,6 @@
{
"extends": "@ljharb/tsconfig",
"exclude": [
"coverage",
],
}
@@ -0,0 +1,11 @@
export default function instancePerContainerCachingFactory(factoryFunc) {
const cache = new WeakMap();
return (dependencyContainer) => {
let instance = cache.get(dependencyContainer);
if (instance == undefined) {
instance = factoryFunc(dependencyContainer);
cache.set(dependencyContainer, instance);
}
return instance;
};
}
@@ -0,0 +1,8 @@
language: node_js
node_js:
- '7'
- '6'
- '5'
- '4'
- '0.12'
- '0.10'
@@ -0,0 +1 @@
{"name":"eslint-plugin-node","version":"11.1.0","requiresBuild":false,"files":{"LICENSE":{"checkedAt":1794532118158,"integrity":"sha512-lKRaVozpq3l11Xbu5NdT1MRtD/qWbFK2Q86T+Pxzbp6mSvfsb9cVMPfHV435SGBLBJ0048DcmSZBgYHGw5vjrA==","mode":438,"size":1082},"lib/configs/_commons.js":{"checkedAt":1794532118158,"integrity":"sha512-FOQSet11SgqYovUZI52jMpSEfn2y3/1A40Ry7lRbTZV+PA8EuaRgIgWDANRAsLw2G5QYvpi7HCjPMdTspjvTpQ==","mode":438,"size":2297},"lib/rules/prefer-global/buffer.js":{"checkedAt":1794532118158,"integrity":"sha512-wNspuFJ7uhuS5EnL+4nZrZ5xovmOpXwYl/1ZsutcV37cm4v0qve4YkaHkQ6FtiRJ0jy4gsGGr7Fy1XGBEE3kNQ==","mode":438,"size":1316},"lib/util/cache.js":{"checkedAt":1794532118158,"integrity":"sha512-xjR4a7S3HdxDlDA/BGbK6G7IgNCHbHa++EoRlVNLMRLsMHe6kZ/QuNsK++XC8r1Sb0BD8ool0NaHOPljC84DIw==","mode":438,"size":1301},"lib/rules/callback-return.js":{"checkedAt":1794532118158,"integrity":"sha512-HpZjQxte2HTMP5VEakuNU4je4tW7cRlk8/qszvykfsmXE4O/+wXQ18j1hPj8o30uoc48PYdjjouWHqBQegK5Sw==","mode":438,"size":6559},"lib/util/check-existence.js":{"checkedAt":1794532118158,"integrity":"sha512-adZaceBRFvKnrPN9oHMkhmwPhV/Aanz4h7LM7d8fCvCPoEmxly3jvBV4zHXpSFnIslPp5xIDcJB3orNv5WIkSg==","mode":438,"size":1192},"lib/util/check-extraneous.js":{"checkedAt":1794532118159,"integrity":"sha512-hSdARdn5N/aizPgKvPj7j1YuFdBU/czrPRBWbwpqXhDIRaZksgS5EAeDVA0AkDM8Tcv6UmUrgPSy0RvAbkXRCg==","mode":438,"size":1610},"lib/util/check-prefer-global.js":{"checkedAt":1794532118159,"integrity":"sha512-pJOJTlSiiS/qchEmrOzjOcP0j5nrxOcXbALx6b6a2luel3jGfdPZGPKJ8ZI4yIyZ9kDS4CUnBklj6iHSROt+Dw==","mode":438,"size":1734},"lib/util/check-publish.js":{"checkedAt":1794532118159,"integrity":"sha512-1cJZ6RLhZZv+VE+fvwhSnFODZpWNYLUmrqUbTQgj7Fh463kth3PNCzsn6dVaFrH9BJf24SJzsQWN2xvpT/gj5Q==","mode":438,"size":2514},"lib/util/check-restricted.js":{"checkedAt":1794532118159,"integrity":"sha512-CbW4mzskBNsbr3RF3sGuEyBWX8y3x0GDY9Twsh2x6jU2ExDlxyVpIQ/85ilVTFjOHsVHKnOaQths9rtkoSOElw==","mode":438,"size":3290},"lib/util/check-unsupported-builtins.js":{"checkedAt":1794532118159,"integrity":"sha512-VL8rabk2x3IEOXcjFhU77WldHBl/UEu5OuDSWrhcE0vYbmCyLJFr4VdC//UlbKW8Q9zpn4jxGtp4UQkEbJ/HGg==","mode":438,"size":3473},"lib/rules/prefer-global/console.js":{"checkedAt":1794532118159,"integrity":"sha512-4+30cRb8NnCTpK0LRcAP/2u1oQcD3+p6DABCIHDdG1hEffOpIXYFuf4omCkYG1WdWHIgpGLbgeywziojJlbTmg==","mode":438,"size":1255},"lib/rules/prefer-promises/dns.js":{"checkedAt":1794532118159,"integrity":"sha512-zxRHMrib2K6NIa8EIsawEIiNH7KeO3bxrjVA7PA8QoWNjluDQOQZG5zJmtl7+w+8UQ1Ff91uZrEG1UgrjrX4Tw==","mode":438,"size":2364},"lib/util/enumerate-property-names.js":{"checkedAt":1794532118159,"integrity":"sha512-drVXsd5+UoycUsbr/4NrpCRS7G7fLEj1OVivQ8N19o3khoKnphNr9Xe2VGI40EudRKajKyygntmqVIIgfVbcdA==","mode":438,"size":1045},"lib/rules/no-unsupported-features/es-builtins.js":{"checkedAt":1794532118159,"integrity":"sha512-+bMQP8RDjmt7jxPaJFtYMVlpOmIdzUJX5fm1EpCvWAF8z728OyGXfPEdXP4wXD1CB8FDJrW4z7zlcG250cX5KA==","mode":438,"size":6035},"lib/rules/no-unsupported-features/es-syntax.js":{"checkedAt":1794532118160,"integrity":"sha512-/0ZEi3n7nH62lDx2Q6oONz58br/ezcZJJdxyhvypXJCb2DNe73dQfI+6s498Ct2t6Gb9F0oo/I8tf4EtzUecrg==","mode":438,"size":23411},"lib/util/exists.js":{"checkedAt":1794532118160,"integrity":"sha512-oQrE15ns+qhBdeMBBwHDmOX2MFa6PJSX47lXwReVprMPtWvWdKC/Zts+CfROtCccD0CcuikX37QJOw6jkO3zuw==","mode":438,"size":1480},"lib/rules/exports-style.js":{"checkedAt":1794532118160,"integrity":"sha512-wFeLC3HxJsWQDG8Wa/6W5ji5oBEDnh9KFU5dnae1cs2Za0kJJQe+DEuYgoN4LU8xaCa6HSM0ZGT94U99YLI4LA==","mode":438,"size":8425},"lib/rules/file-extension-in-import.js":{"checkedAt":1794532118160,"integrity":"sha512-TjETuEVV+WcrP3WWQFlDbLYkTb4Wd1HVdPK5945bloeOdORuihI3B+CGlB76RocJVWVI8FVeMCkZxYvGPynLog==","mode":438,"size":4654},"lib/rules/prefer-promises/fs.js":{"checkedAt":1794532118160,"integrity":"sha512-hN0jp04dY4EJK4YdknqCcazWRkM3wmbvZicHCXDjCNl2DYCTztxCHPT6J3bm9VXJ9NBSPmfD4LdsrfWUimV2hw==","mode":438,"size":2261},"lib/util/get-allow-modules.js":{"checkedAt":1794532118160,"integrity":"sha512-NyBtydVbh5LISyp2DKWok6HkMtczOptdsb2FTkS7owOSKtG/05TXUpJDRgqxxHkgOtMe6/5kwoRe2JEEnBpctw==","mode":438,"size":1209},"lib/util/get-configured-node-version.js":{"checkedAt":1794532118160,"integrity":"sha512-a+EcYxhQv1vCKxZJLTJ/gnl5sA2QZznBypl5WbyR9U3yAgfmF2Y1HpXt3Rbrb+psxt2i/ft7GMk4Rwyp/3f91A==","mode":438,"size":1332},"lib/util/get-convert-path.js":{"checkedAt":1794532118161,"integrity":"sha512-JKd9klOhEMr3hNMQS7oDJEWHRrZRa8TdH0Xok1rAN1GU4dJoYZvzf9mr6LY1hOXF6eSeQKOf0MV8I0mrkdTY+A==","mode":438,"size":5267},"lib/util/get-npmignore.js":{"checkedAt":1794532118161,"integrity":"sha512-GDE2iuttsGrf6o5xhte+KTjjtkRqHuOTEM5oq0+AsfOlksUq0XVKO5kQ+qaKyKxgBuupv2WgdRVuxwU9GfnYNw==","mode":438,"size":5334},"lib/util/get-package-json.js":{"checkedAt":1794532118161,"integrity":"sha512-7nu+Hi4RY+DQlV5z4xvm7yypyWcz97MCgJ63dKV8FufcIGxoVZwK03aFxcGx+EBdKshZtbScb5w5Y1+kawDDEw==","mode":438,"size":1788},"lib/util/get-resolve-paths.js":{"checkedAt":1794532118161,"integrity":"sha51Line truncated
@@ -0,0 +1,8 @@
export * from './registration/generateRegistrationOptions.js';
export * from './registration/verifyRegistrationResponse.js';
export * from './authentication/generateAuthenticationOptions.js';
export * from './authentication/verifyAuthenticationResponse.js';
export * from './services/metadataService.js';
export * from './services/settingsService.js';
export * from './metadata/mdsTypes.js';
export * from './types/index.js';
@@ -0,0 +1,3 @@
// Note: more types exposed from `index.d.ts`.
export { gfmStrikethroughHtml } from './lib/html.js';
export { gfmStrikethrough } from './lib/syntax.js';
@@ -0,0 +1,27 @@
// Copyright (c) 2015 Ryan Prichard
//
// 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.
#ifndef WINPTY_VERSION_H
#define WINPTY_VERSION_H
void dumpVersionToStdout();
void dumpVersionToTrace();
#endif // WINPTY_VERSION_H
@@ -0,0 +1 @@
module.exports={A:{A:{"2":"K D E wC","260":"F","516":"A B"},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 N O P aB AB BB CB DB EB FB bB cB dB eB fB gB hB iB jB kB lB mB nB oB pB qB rB sB tB uB vB wB xB yB zB 0B 1B 2B 3B UC 4B VC 5B 6B 7B 8B 9B AC BC CC DC EC FC GC HC IC JC KC LC Q H R WC S T U V W X Y Z a b c d e f g h i j k l m n o p q r s t u v w x y z GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB I XC MC YC yC zC","2":"xC TC 0C 1C","33":"J ZB K D E F A B C L M G"},D:{"1":"0 1 2 3 4 5 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","2":"J ZB K D E F A B C L M G N O P","33":"6 7 8 9 aB AB BB"},E:{"1":"D E F A B C L M G 4C 5C 6C aC NC OC 7C 8C 9C bC cC PC AD QC dC eC fC gC hC BD RC iC jC kC lC mC CD SC nC oC pC qC rC sC tC DD ED","2":"J ZB 2C ZC 3C","33":"K"},F:{"1":"0 1 2 3 4 5 6 7 8 9 G N O P aB AB BB CB DB EB FB bB cB dB eB fB gB hB iB jB kB lB mB nB oB pB qB rB sB tB uB vB wB xB yB zB 0B 1B 2B 3B 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 FD GD HD ID NC uC JD OC"},G:{"1":"E 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","2":"ZC KD vC LD","33":"MD"},H:{"2":"hD"},I:{"1":"I","2":"TC J iD jD kD lD vC","132":"mD nD"},J:{"1":"A","2":"D"},K:{"1":"H","2":"A B C NC uC OC"},L:{"1":"I"},M:{"1":"MC"},N:{"1":"A B"},O:{"1":"PC"},P:{"1":"6 7 8 9 J AB BB CB DB EB FB oD pD qD rD sD aC tD uD vD wD xD QC RC SC yD"},Q:{"1":"zD"},R:{"1":"0D"},S:{"1":"1D 2D"}},B:4,C:"calc() as CSS unit value",D:true};
@@ -0,0 +1,22 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.ExcludeFromMappedResult = ExcludeFromMappedResult;
const index_1 = require("../mapped/index");
const exclude_1 = require("./exclude");
// prettier-ignore
function FromProperties(P, U) {
const Acc = {};
for (const K2 of globalThis.Object.getOwnPropertyNames(P))
Acc[K2] = (0, exclude_1.Exclude)(P[K2], U);
return Acc;
}
// prettier-ignore
function FromMappedResult(R, T) {
return FromProperties(R.properties, T);
}
// prettier-ignore
function ExcludeFromMappedResult(R, T) {
const P = FromMappedResult(R, T);
return (0, index_1.MappedResult)(P);
}
@@ -0,0 +1,30 @@
import { ServiceIdentifier } from '@inversifyjs/common';
import { BindingActivation, BindingDeactivation } from '@inversifyjs/core';
import { BindToFluentSyntax } from '../../binding/models/BindingFluentSyntax';
import { BindingIdentifier } from '../../binding/models/BindingIdentifier';
import { IsBoundOptions } from './isBoundOptions';
export type Bind = <T>(serviceIdentifier: ServiceIdentifier<T>) => BindToFluentSyntax<T>;
export type IsBound = (serviceIdentifier: ServiceIdentifier, options?: IsBoundOptions) => boolean;
export type OnActivation = <T>(serviceIdentifier: ServiceIdentifier<T>, activation: BindingActivation<T>) => void;
export type OnDeactivation = <T>(serviceIdentifier: ServiceIdentifier<T>, deactivation: BindingDeactivation<T>) => void;
export type Rebind = <T>(serviceIdentifier: ServiceIdentifier<T>) => Promise<BindToFluentSyntax<T>>;
export type RebindSync = <T>(serviceIdentifier: ServiceIdentifier<T>) => BindToFluentSyntax<T>;
export type Unbind = (identifier: BindingIdentifier | ServiceIdentifier) => Promise<void>;
export type UnbindSync = (identifier: BindingIdentifier | ServiceIdentifier) => void;
export interface ContainerModuleLoadOptions {
bind: Bind;
isBound: IsBound;
onActivation: OnActivation;
onDeactivation: OnDeactivation;
rebind: Rebind;
rebindSync: RebindSync;
unbind: Unbind;
unbindSync: UnbindSync;
}
export declare class ContainerModule {
#private;
constructor(load: (options: ContainerModuleLoadOptions) => void | Promise<void>);
get id(): number;
load(options: ContainerModuleLoadOptions): void | Promise<void>;
}
//# sourceMappingURL=ContainerModule.d.ts.map
@@ -0,0 +1 @@
{"name":"on-finished","version":"2.4.1","requiresBuild":false,"files":{"LICENSE":{"checkedAt":1794532089030,"integrity":"sha512-2YQonuWZRYnohIL3SPwAMnptZqMsF3PcCLg1tDG3bugEGii+UEPgyWx159x3IjoJTOfBFiInr607zuCmCmgjLw==","mode":420,"size":1167},"index.js":{"checkedAt":1794532089030,"integrity":"sha512-QiXHFL7HGNfMWc0skaB6d+Qczjq1JQK/m1uczX0M6IwEDgp2XlssNXasjxAdwA//lPjHrHWGERpUWyKIMaEe0A==","mode":420,"size":4430},"package.json":{"checkedAt":1794532089030,"integrity":"sha512-0mHiYbydLlo5pQxrBy5tqZV2R2mr3E+fPPIZzCKWwORe4ZTD9PQxokj9HUbZB0WtC1dtL8sk5Z2SCIBLnBUy1w==","mode":420,"size":1057},"HISTORY.md":{"checkedAt":1794532089030,"integrity":"sha512-cb29L9UiOASdkSdc8rE+hJacpWfJjH2MpwXBtQOni0PWgRxnJ8de+DAgVq6Fr+hR8v1+cPTgM05EyPatEacscg==","mode":420,"size":1865},"README.md":{"checkedAt":1794532089031,"integrity":"sha512-E7x+3t1PeyfLKKR4len/I55V3Od9wc3b47tgNGLUT1ZP0cSlNvYms9ac0bqxWSD2XPerBoP8/H8zhysSQvLiCA==","mode":420,"size":5160}}}
@@ -0,0 +1,12 @@
var parsePath = require('./lib/parse-path')
var setValue = require('./lib/set-value')
function appendField (store, key, value) {
var steps = parsePath(key)
steps.reduce(function (context, step) {
return setValue(context, step, context[step.key], value)
}, store)
}
module.exports = appendField
@@ -0,0 +1,16 @@
/**
* Subtracts a specified number of years from a date.
* 从日期中减去指定数量的年份。
*
* @param date - The date to subtract years from. (要减去年份的日期。)
* @param years - The number of years to subtract. (要减去的年份数。)
* @returns A new date with the subtracted years. (减去年份后的新日期。)
* @example
* ```ts
* //Subtracting 2 years from a date (从日期中减去2)
* const date = new Date('2023-10-01T12:00:00Z');
* subYears(date, 2);
* // Returns: 2021-10-01T12:00:00.000Z (返回: 2021-10-01T12:00:00.000Z)
* ```
*/
export default function subYears(date: Date, years: number): Date;
@@ -0,0 +1,21 @@
The MIT License (MIT)
Copyright (c) 2016 Jonas Kello
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,34 @@
{
"name": "@rolldown/pluginutils",
"version": "1.0.0-beta.47",
"license": "MIT",
"type": "module",
"repository": {
"type": "git",
"url": "git+https://github.com/rolldown/rolldown.git",
"directory": "packages/pluginutils"
},
"publishConfig": {
"access": "public"
},
"main": "./dist/index.js",
"module": "./dist/index.js",
"types": "./dist/index.d.ts",
"exports": {
".": "./dist/index.js",
"./package.json": "./package.json"
},
"files": [
"dist"
],
"devDependencies": {
"@types/picomatch": "^4.0.0",
"picomatch": "^4.0.2",
"typescript": "^5.8.3",
"vitest": "^4.0.1"
},
"scripts": {
"build": "tsc",
"test": "vitest --typecheck"
}
}
@@ -0,0 +1,57 @@
'use strict';
Object.defineProperty(exports, "__esModule", {
value: true
});
var _applyEach = require('./internal/applyEach.js');
var _applyEach2 = _interopRequireDefault(_applyEach);
var _map = require('./map.js');
var _map2 = _interopRequireDefault(_map);
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
/**
* Applies the provided arguments to each function in the array, calling
* `callback` after all functions have completed. If you only provide the first
* argument, `fns`, then it will return a function which lets you pass in the
* arguments as if it were a single function call. If more arguments are
* provided, `callback` is required while `args` is still optional. The results
* for each of the applied async functions are passed to the final callback
* as an array.
*
* @name applyEach
* @static
* @memberOf module:ControlFlow
* @method
* @category Control Flow
* @param {Array|Iterable|AsyncIterable|Object} fns - A collection of {@link AsyncFunction}s
* to all call with the same arguments
* @param {...*} [args] - any number of separate arguments to pass to the
* function.
* @param {Function} [callback] - the final argument should be the callback,
* called when all functions have completed processing.
* @returns {AsyncFunction} - Returns a function that takes no args other than
* an optional callback, that is the result of applying the `args` to each
* of the functions.
* @example
*
* const appliedFn = async.applyEach([enableSearch, updateSchema], 'bucket')
*
* appliedFn((err, results) => {
* // results[0] is the results for `enableSearch`
* // results[1] is the results for `updateSchema`
* });
*
* // partial application example:
* async.each(
* buckets,
* async (bucket) => async.applyEach([enableSearch, updateSchema], bucket)(),
* callback
* );
*/
exports.default = (0, _applyEach2.default)(_map2.default);
module.exports = exports.default;
@@ -0,0 +1,61 @@
let matchingBrackets = new Map([
['{', '}'],
['[', ']'],
['(', ')'],
])
let inverseMatchingBrackets = new Map(
Array.from(matchingBrackets.entries()).map(([k, v]) => [v, k])
)
let quotes = new Set(['"', "'", '`'])
// Arbitrary values must contain balanced brackets (), [] and {}. Escaped
// values don't count, and brackets inside quotes also don't count.
//
// E.g.: w-[this-is]w-[weird-and-invalid]
// E.g.: w-[this-is\\]w-\\[weird-but-valid]
// E.g.: content-['this-is-also-valid]-weirdly-enough']
export default function isSyntacticallyValidPropertyValue(value) {
let stack = []
let inQuotes = false
for (let i = 0; i < value.length; i++) {
let char = value[i]
if (char === ':' && !inQuotes && stack.length === 0) {
return false
}
// Non-escaped quotes allow us to "allow" anything in between
if (quotes.has(char) && value[i - 1] !== '\\') {
inQuotes = !inQuotes
}
if (inQuotes) continue
if (value[i - 1] === '\\') continue // Escaped
if (matchingBrackets.has(char)) {
stack.push(char)
} else if (inverseMatchingBrackets.has(char)) {
let inverse = inverseMatchingBrackets.get(char)
// Nothing to pop from, therefore it is unbalanced
if (stack.length <= 0) {
return false
}
// Popped value must match the inverse value, otherwise it is unbalanced
if (stack.pop() !== inverse) {
return false
}
}
}
// If there is still something on the stack, it is also unbalanced
if (stack.length > 0) {
return false
}
// All good, totally balanced!
return true
}
@@ -0,0 +1,545 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.monaco_loader = factory());
})(this, (function () { 'use strict';
function _arrayLikeToArray(r, a) {
(null == a || a > r.length) && (a = r.length);
for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
return n;
}
function _arrayWithHoles(r) {
if (Array.isArray(r)) return r;
}
function _defineProperty$1(e, r, t) {
return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, {
value: t,
enumerable: true,
configurable: true,
writable: true
}) : e[r] = t, e;
}
function _iterableToArrayLimit(r, l) {
var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
if (null != t) {
var e,
n,
i,
u,
a = [],
f = true,
o = false;
try {
if (i = (t = t.call(r)).next, 0 === l) ; else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0);
} catch (r) {
o = true, n = r;
} finally {
try {
if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return;
} finally {
if (o) throw n;
}
}
return a;
}
}
function _nonIterableRest() {
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
}
function ownKeys$1(e, r) {
var t = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var o = Object.getOwnPropertySymbols(e);
r && (o = o.filter(function (r) {
return Object.getOwnPropertyDescriptor(e, r).enumerable;
})), t.push.apply(t, o);
}
return t;
}
function _objectSpread2$1(e) {
for (var r = 1; r < arguments.length; r++) {
var t = null != arguments[r] ? arguments[r] : {};
r % 2 ? ownKeys$1(Object(t), true).forEach(function (r) {
_defineProperty$1(e, r, t[r]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$1(Object(t)).forEach(function (r) {
Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
});
}
return e;
}
function _objectWithoutProperties(e, t) {
if (null == e) return {};
var o,
r,
i = _objectWithoutPropertiesLoose(e, t);
if (Object.getOwnPropertySymbols) {
var n = Object.getOwnPropertySymbols(e);
for (r = 0; r < n.length; r++) o = n[r], -1 === t.indexOf(o) && {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]);
}
return i;
}
function _objectWithoutPropertiesLoose(r, e) {
if (null == r) return {};
var t = {};
for (var n in r) if ({}.hasOwnProperty.call(r, n)) {
if (-1 !== e.indexOf(n)) continue;
t[n] = r[n];
}
return t;
}
function _slicedToArray(r, e) {
return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest();
}
function _toPrimitive(t, r) {
if ("object" != typeof t || !t) return t;
var e = t[Symbol.toPrimitive];
if (void 0 !== e) {
var i = e.call(t, r);
if ("object" != typeof i) return i;
throw new TypeError("@@toPrimitive must return a primitive value.");
}
return ("string" === r ? String : Number)(t);
}
function _toPropertyKey(t) {
var i = _toPrimitive(t, "string");
return "symbol" == typeof i ? i : i + "";
}
function _unsupportedIterableToArray(r, a) {
if (r) {
if ("string" == typeof r) return _arrayLikeToArray(r, a);
var t = {}.toString.call(r).slice(8, -1);
return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0;
}
}
function _defineProperty(obj, key, value) {
if (key in obj) {
Object.defineProperty(obj, key, {
value: value,
enumerable: true,
configurable: true,
writable: true
});
} else {
obj[key] = value;
}
return obj;
}
function ownKeys(object, enumerableOnly) {
var keys = Object.keys(object);
if (Object.getOwnPropertySymbols) {
var symbols = Object.getOwnPropertySymbols(object);
if (enumerableOnly) symbols = symbols.filter(function (sym) {
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
});
keys.push.apply(keys, symbols);
}
return keys;
}
function _objectSpread2(target) {
for (var i = 1; i < arguments.length; i++) {
var source = arguments[i] != null ? arguments[i] : {};
if (i % 2) {
ownKeys(Object(source), true).forEach(function (key) {
_defineProperty(target, key, source[key]);
});
} else if (Object.getOwnPropertyDescriptors) {
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
} else {
ownKeys(Object(source)).forEach(function (key) {
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
});
}
}
return target;
}
function compose$1() {
for (var _len = arguments.length, fns = new Array(_len), _key = 0; _key < _len; _key++) {
fns[_key] = arguments[_key];
}
return function (x) {
return fns.reduceRight(function (y, f) {
return f(y);
}, x);
};
}
function curry$1(fn) {
return function curried() {
var _this = this;
for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
args[_key2] = arguments[_key2];
}
return args.length >= fn.length ? fn.apply(this, args) : function () {
for (var _len3 = arguments.length, nextArgs = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {
nextArgs[_key3] = arguments[_key3];
}
return curried.apply(_this, [].concat(args, nextArgs));
};
};
}
function isObject$1(value) {
return {}.toString.call(value).includes('Object');
}
function isEmpty(obj) {
return !Object.keys(obj).length;
}
function isFunction(value) {
return typeof value === 'function';
}
function hasOwnProperty(object, property) {
return Object.prototype.hasOwnProperty.call(object, property);
}
function validateChanges(initial, changes) {
if (!isObject$1(changes)) errorHandler$1('changeType');
if (Object.keys(changes).some(function (field) {
return !hasOwnProperty(initial, field);
})) errorHandler$1('changeField');
return changes;
}
function validateSelector(selector) {
if (!isFunction(selector)) errorHandler$1('selectorType');
}
function validateHandler(handler) {
if (!(isFunction(handler) || isObject$1(handler))) errorHandler$1('handlerType');
if (isObject$1(handler) && Object.values(handler).some(function (_handler) {
return !isFunction(_handler);
})) errorHandler$1('handlersType');
}
function validateInitial(initial) {
if (!initial) errorHandler$1('initialIsRequired');
if (!isObject$1(initial)) errorHandler$1('initialType');
if (isEmpty(initial)) errorHandler$1('initialContent');
}
function throwError$1(errorMessages, type) {
throw new Error(errorMessages[type] || errorMessages["default"]);
}
var errorMessages$1 = {
initialIsRequired: 'initial state is required',
initialType: 'initial state should be an object',
initialContent: 'initial state shouldn\'t be an empty object',
handlerType: 'handler should be an object or a function',
handlersType: 'all handlers should be a functions',
selectorType: 'selector should be a function',
changeType: 'provided value of changes should be an object',
changeField: 'it seams you want to change a field in the state which is not specified in the "initial" state',
"default": 'an unknown error accured in `state-local` package'
};
var errorHandler$1 = curry$1(throwError$1)(errorMessages$1);
var validators$1 = {
changes: validateChanges,
selector: validateSelector,
handler: validateHandler,
initial: validateInitial
};
function create(initial) {
var handler = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
validators$1.initial(initial);
validators$1.handler(handler);
var state = {
current: initial
};
var didUpdate = curry$1(didStateUpdate)(state, handler);
var update = curry$1(updateState)(state);
var validate = curry$1(validators$1.changes)(initial);
var getChanges = curry$1(extractChanges)(state);
function getState() {
var selector = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : function (state) {
return state;
};
validators$1.selector(selector);
return selector(state.current);
}
function setState(causedChanges) {
compose$1(didUpdate, update, validate, getChanges)(causedChanges);
}
return [getState, setState];
}
function extractChanges(state, causedChanges) {
return isFunction(causedChanges) ? causedChanges(state.current) : causedChanges;
}
function updateState(state, changes) {
state.current = _objectSpread2(_objectSpread2({}, state.current), changes);
return changes;
}
function didStateUpdate(state, handler, changes) {
isFunction(handler) ? handler(state.current) : Object.keys(changes).forEach(function (field) {
var _handler$field;
return (_handler$field = handler[field]) === null || _handler$field === void 0 ? void 0 : _handler$field.call(handler, state.current[field]);
});
return changes;
}
var index = {
create: create
};
var config$1 = {
paths: {
vs: 'https://cdn.jsdelivr.net/npm/monaco-editor@0.54.0/min/vs'
}
};
function curry(fn) {
return function curried() {
var _this = this;
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
args[_key] = arguments[_key];
}
return args.length >= fn.length ? fn.apply(this, args) : function () {
for (var _len2 = arguments.length, nextArgs = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
nextArgs[_key2] = arguments[_key2];
}
return curried.apply(_this, [].concat(args, nextArgs));
};
};
}
function isObject(value) {
return {}.toString.call(value).includes('Object');
}
/**
* validates the configuration object and informs about deprecation
* @param {Object} config - the configuration object
* @return {Object} config - the validated configuration object
*/
function validateConfig(config) {
if (!config) errorHandler('configIsRequired');
if (!isObject(config)) errorHandler('configType');
if (config.urls) {
informAboutDeprecation();
return {
paths: {
vs: config.urls.monacoBase
}
};
}
return config;
}
/**
* logs deprecation message
*/
function informAboutDeprecation() {
console.warn(errorMessages.deprecation);
}
function throwError(errorMessages, type) {
throw new Error(errorMessages[type] || errorMessages["default"]);
}
var errorMessages = {
configIsRequired: 'the configuration object is required',
configType: 'the configuration object should be an object',
"default": 'an unknown error accured in `@monaco-editor/loader` package',
deprecation: "Deprecation warning!\n You are using deprecated way of configuration.\n\n Instead of using\n monaco.config({ urls: { monacoBase: '...' } })\n use\n monaco.config({ paths: { vs: '...' } })\n\n For more please check the link https://github.com/suren-atoyan/monaco-loader#config\n "
};
var errorHandler = curry(throwError)(errorMessages);
var validators = {
config: validateConfig
};
var compose = function compose() {
for (var _len = arguments.length, fns = new Array(_len), _key = 0; _key < _len; _key++) {
fns[_key] = arguments[_key];
}
return function (x) {
return fns.reduceRight(function (y, f) {
return f(y);
}, x);
};
};
function merge(target, source) {
Object.keys(source).forEach(function (key) {
if (source[key] instanceof Object) {
if (target[key]) {
Object.assign(source[key], merge(target[key], source[key]));
}
}
});
return _objectSpread2$1(_objectSpread2$1({}, target), source);
}
// The source (has been changed) is https://github.com/facebook/react/issues/5465#issuecomment-157888325
var CANCELATION_MESSAGE = {
type: 'cancelation',
msg: 'operation is manually canceled'
};
function makeCancelable(promise) {
var hasCanceled_ = false;
var wrappedPromise = new Promise(function (resolve, reject) {
promise.then(function (val) {
return hasCanceled_ ? reject(CANCELATION_MESSAGE) : resolve(val);
});
promise["catch"](reject);
});
return wrappedPromise.cancel = function () {
return hasCanceled_ = true;
}, wrappedPromise;
}
var _excluded = ["monaco"];
/** the local state of the module */
var _state$create = index.create({
config: config$1,
isInitialized: false,
resolve: null,
reject: null,
monaco: null
}),
_state$create2 = _slicedToArray(_state$create, 2),
getState = _state$create2[0],
setState = _state$create2[1];
/**
* set the loader configuration
* @param {Object} config - the configuration object
*/
function config(globalConfig) {
var _validators$config = validators.config(globalConfig),
monaco = _validators$config.monaco,
config = _objectWithoutProperties(_validators$config, _excluded);
setState(function (state) {
return {
config: merge(state.config, config),
monaco: monaco
};
});
}
/**
* handles the initialization of the monaco-editor
* @return {Promise} - returns an instance of monaco (with a cancelable promise)
*/
function init() {
var state = getState(function (_ref) {
var monaco = _ref.monaco,
isInitialized = _ref.isInitialized,
resolve = _ref.resolve;
return {
monaco: monaco,
isInitialized: isInitialized,
resolve: resolve
};
});
if (!state.isInitialized) {
setState({
isInitialized: true
});
if (state.monaco) {
state.resolve(state.monaco);
return makeCancelable(wrapperPromise);
}
if (window.monaco && window.monaco.editor) {
storeMonacoInstance(window.monaco);
state.resolve(window.monaco);
return makeCancelable(wrapperPromise);
}
compose(injectScripts, getMonacoLoaderScript)(configureLoader);
}
return makeCancelable(wrapperPromise);
}
/**
* injects provided scripts into the document.body
* @param {Object} script - an HTML script element
* @return {Object} - the injected HTML script element
*/
function injectScripts(script) {
return document.body.appendChild(script);
}
/**
* creates an HTML script element with/without provided src
* @param {string} [src] - the source path of the script
* @return {Object} - the created HTML script element
*/
function createScript(src) {
var script = document.createElement('script');
return src && (script.src = src), script;
}
/**
* creates an HTML script element with the monaco loader src
* @return {Object} - the created HTML script element
*/
function getMonacoLoaderScript(configureLoader) {
var state = getState(function (_ref2) {
var config = _ref2.config,
reject = _ref2.reject;
return {
config: config,
reject: reject
};
});
var loaderScript = createScript("".concat(state.config.paths.vs, "/loader.js"));
loaderScript.onload = function () {
return configureLoader();
};
loaderScript.onerror = state.reject;
return loaderScript;
}
/**
* configures the monaco loader
*/
function configureLoader() {
var state = getState(function (_ref3) {
var config = _ref3.config,
resolve = _ref3.resolve,
reject = _ref3.reject;
return {
config: config,
resolve: resolve,
reject: reject
};
});
var require = window.require;
require.config(state.config);
require(['vs/editor/editor.main'], function (_ref4) {
var monaco = _ref4.m;
storeMonacoInstance(monaco);
state.resolve(monaco);
}, function (error) {
state.reject(error);
});
}
/**
* store monaco instance in local state
*/
function storeMonacoInstance(monaco) {
if (!getState().monaco) {
setState({
monaco: monaco
});
}
}
/**
* internal helper function
* extracts stored monaco instance
* @return {Object|null} - the monaco instance
*/
function __getMonacoInstance() {
return getState(function (_ref5) {
var monaco = _ref5.monaco;
return monaco;
});
}
var wrapperPromise = new Promise(function (resolve, reject) {
return setState({
resolve: resolve,
reject: reject
});
});
var loader = {
config: config,
init: init,
__getMonacoInstance: __getMonacoInstance
};
return loader;
}));
@@ -0,0 +1,69 @@
/*
* 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 {AriaLabelingProps, DOMAttributes, DOMProps, LabelableProps} from '@react-types/shared';
import {ElementType, LabelHTMLAttributes} from 'react';
import {useId, useLabels} from '@react-aria/utils';
export interface LabelAriaProps extends LabelableProps, DOMProps, AriaLabelingProps {
/**
* The HTML element used to render the label, e.g. 'label', or 'span'.
* @default 'label'
*/
labelElementType?: ElementType
}
export interface LabelAria {
/** Props to apply to the label container element. */
labelProps: DOMAttributes | LabelHTMLAttributes<HTMLLabelElement>,
/** Props to apply to the field container element being labeled. */
fieldProps: AriaLabelingProps & DOMProps
}
/**
* Provides the accessibility implementation for labels and their associated elements.
* Labels provide context for user inputs.
* @param props - The props for labels and fields.
*/
export function useLabel(props: LabelAriaProps): LabelAria {
let {
id,
label,
'aria-labelledby': ariaLabelledby,
'aria-label': ariaLabel,
labelElementType = 'label'
} = props;
id = useId(id);
let labelId = useId();
let labelProps = {};
if (label) {
ariaLabelledby = ariaLabelledby ? `${labelId} ${ariaLabelledby}` : labelId;
labelProps = {
id: labelId,
htmlFor: labelElementType === 'label' ? id : undefined
};
} else if (!ariaLabelledby && !ariaLabel && process.env.NODE_ENV !== 'production') {
console.warn('If you do not provide a visible label, you must specify an aria-label or aria-labelledby attribute for accessibility');
}
let fieldProps = useLabels({
id,
'aria-label': ariaLabel,
'aria-labelledby': ariaLabelledby
});
return {
labelProps,
fieldProps
};
}
@@ -0,0 +1,40 @@
'use strict';
var test = require('tape');
var getProto = require('get-proto');
var semver = require('semver');
var getAsyncFunction = require('../');
test('getAsyncFunction', function (t) {
var result = getAsyncFunction();
/* eslint-env browser */
if (typeof window === 'undefined' && typeof process !== 'undefined') {
t.equal(
!!result,
semver.satisfies(process.version, '>= 7.6'),
'result is present or absent as expected for node ' + process.version
);
}
t.test('exists', { skip: !result }, function (st) {
if (result && getProto) { // TS can't infer `skip`, or that getProto definitely exists if AsyncFunction exists
st.equal(typeof result, 'function', 'is a function');
st.equal(getProto(result), Function, 'extends Function');
return result('a', 'return a')(42).then(function (a) {
st.equal(a, 42, 'returns an async function');
});
}
return st.fail('should never get here');
});
t.test('does not exist', { skip: !!result }, function (st) {
st.equal(result, false, 'is false');
st.end();
});
t.end();
});
@@ -0,0 +1 @@
{"mappings":";;;AAAA;;;;;;;;;;CAUC","sources":["packages/@react-aria/tooltip/src/index.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 */\nexport {useTooltip} from './useTooltip';\nexport {useTooltipTrigger} from './useTooltipTrigger';\nexport type {AriaTooltipProps, TooltipTriggerProps} from '@react-types/tooltip';\nexport type {TooltipAria} from './useTooltip';\nexport type {TooltipTriggerAria} from './useTooltipTrigger';\n"],"names":[],"version":3,"file":"module.js.map"}
@@ -0,0 +1,263 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.MetadataService = exports.BaseMetadataService = void 0;
const validateCertificatePath_js_1 = require("../helpers/validateCertificatePath.js");
const convertCertBufferToPEM_js_1 = require("../helpers/convertCertBufferToPEM.js");
const convertAAGUIDToString_js_1 = require("../helpers/convertAAGUIDToString.js");
const settingsService_js_1 = require("./settingsService.js");
const logging_js_1 = require("../helpers/logging.js");
const convertPEMToBytes_js_1 = require("../helpers/convertPEMToBytes.js");
const fetch_js_1 = require("../helpers/fetch.js");
const parseJWT_js_1 = require("../metadata/parseJWT.js");
const verifyJWT_js_1 = require("../metadata/verifyJWT.js");
const defaultURLMDS = 'https://mds.fidoalliance.org/'; // v3
var SERVICE_STATE;
(function (SERVICE_STATE) {
SERVICE_STATE[SERVICE_STATE["DISABLED"] = 0] = "DISABLED";
SERVICE_STATE[SERVICE_STATE["REFRESHING"] = 1] = "REFRESHING";
SERVICE_STATE[SERVICE_STATE["READY"] = 2] = "READY";
})(SERVICE_STATE || (SERVICE_STATE = {}));
const log = (0, logging_js_1.getLogger)('MetadataService');
/**
* An implementation of `MetadataService` that can download and parse BLOBs, and support on-demand
* requesting and caching of individual metadata statements.
*
* https://fidoalliance.org/metadata/
*/
class BaseMetadataService {
constructor() {
Object.defineProperty(this, "mdsCache", {
enumerable: true,
configurable: true,
writable: true,
value: {}
});
Object.defineProperty(this, "statementCache", {
enumerable: true,
configurable: true,
writable: true,
value: {}
});
Object.defineProperty(this, "state", {
enumerable: true,
configurable: true,
writable: true,
value: SERVICE_STATE.DISABLED
});
Object.defineProperty(this, "verificationMode", {
enumerable: true,
configurable: true,
writable: true,
value: 'strict'
});
}
async initialize(opts = {}) {
const { mdsServers = [defaultURLMDS], statements, verificationMode } = opts;
this.setState(SERVICE_STATE.REFRESHING);
// If metadata statements are provided, load them into the cache first
if (statements?.length) {
let statementsAdded = 0;
statements.forEach((statement) => {
// Only cache statements that are for FIDO2-compatible authenticators
if (statement.aaguid) {
this.statementCache[statement.aaguid] = {
entry: {
metadataStatement: statement,
statusReports: [],
timeOfLastStatusChange: '1970-01-01',
},
url: '',
};
statementsAdded += 1;
}
});
log(`Cached ${statementsAdded} local statements`);
}
// If MDS servers are provided, then process them and add their statements to the cache
if (mdsServers?.length) {
// Get a current count so we know how many new statements we've added from MDS servers
const currentCacheCount = Object.keys(this.statementCache).length;
let numServers = mdsServers.length;
for (const url of mdsServers) {
try {
await this.downloadBlob({
url,
no: 0,
nextUpdate: new Date(0),
});
}
catch (err) {
// Notify of the error and move on
log(`Could not download BLOB from ${url}:`, err);
numServers -= 1;
}
}
// Calculate the difference to get the total number of new statements we successfully added
const newCacheCount = Object.keys(this.statementCache).length;
const cacheDiff = newCacheCount - currentCacheCount;
log(`Cached ${cacheDiff} statements from ${numServers} metadata server(s)`);
}
if (verificationMode) {
this.verificationMode = verificationMode;
}
this.setState(SERVICE_STATE.READY);
}
async getStatement(aaguid) {
if (this.state === SERVICE_STATE.DISABLED) {
return;
}
if (!aaguid) {
return;
}
if (aaguid instanceof Uint8Array) {
aaguid = (0, convertAAGUIDToString_js_1.convertAAGUIDToString)(aaguid);
}
// If a cache refresh is in progress then pause this until the service is ready
await this.pauseUntilReady();
// Try to grab a cached statement
const cachedStatement = this.statementCache[aaguid];
if (!cachedStatement) {
if (this.verificationMode === 'strict') {
// FIDO conformance requires RP's to only support registered AAGUID's
throw new Error(`No metadata statement found for aaguid "${aaguid}"`);
}
// Allow registration verification to continue without using metadata
return;
}
// If the statement points to an MDS API, check the MDS' nextUpdate to see if we need to refresh
if (cachedStatement.url) {
const mds = this.mdsCache[cachedStatement.url];
const now = new Date();
if (now > mds.nextUpdate) {
try {
this.setState(SERVICE_STATE.REFRESHING);
await this.downloadBlob(mds);
}
finally {
this.setState(SERVICE_STATE.READY);
}
}
}
const { entry } = cachedStatement;
// Check to see if the this aaguid has a status report with a "compromised" status
for (const report of entry.statusReports) {
const { status } = report;
if (status === 'USER_VERIFICATION_BYPASS' ||
status === 'ATTESTATION_KEY_COMPROMISE' ||
status === 'USER_KEY_REMOTE_COMPROMISE' ||
status === 'USER_KEY_PHYSICAL_COMPROMISE') {
throw new Error(`Detected compromised aaguid "${aaguid}"`);
}
}
return entry.metadataStatement;
}
/**
* Download and process the latest BLOB from MDS
*/
async downloadBlob(mds) {
const { url, no } = mds;
// Get latest "BLOB" (FIDO's terminology, not mine)
const resp = await (0, fetch_js_1.fetch)(url);
const data = await resp.text();
// Parse the JWT
const parsedJWT = (0, parseJWT_js_1.parseJWT)(data);
const header = parsedJWT[0];
const payload = parsedJWT[1];
if (payload.no <= no) {
// From FIDO MDS docs: "also ignore the file if its number (no) is less or equal to the
// number of the last BLOB cached locally."
throw new Error(`Latest BLOB no. "${payload.no}" is not greater than previous ${no}`);
}
const headerCertsPEM = header.x5c.map(convertCertBufferToPEM_js_1.convertCertBufferToPEM);
try {
// Validate the certificate chain
const rootCerts = settingsService_js_1.SettingsService.getRootCertificates({
identifier: 'mds',
});
await (0, validateCertificatePath_js_1.validateCertificatePath)(headerCertsPEM, rootCerts);
}
catch (error) {
const _error = error;
// From FIDO MDS docs: "ignore the file if the chain cannot be verified or if one of the
// chain certificates is revoked"
throw new Error('BLOB certificate path could not be validated', { cause: _error });
}
// Verify the BLOB JWT signature
const leafCert = headerCertsPEM[0];
const verified = await (0, verifyJWT_js_1.verifyJWT)(data, (0, convertPEMToBytes_js_1.convertPEMToBytes)(leafCert));
if (!verified) {
// From FIDO MDS docs: "The FIDO Server SHOULD ignore the file if the signature is invalid."
throw new Error('BLOB signature could not be verified');
}
// Cache statements for FIDO2 devices
for (const entry of payload.entries) {
// Only cache entries with an `aaguid`
if (entry.aaguid) {
this.statementCache[entry.aaguid] = { entry, url };
}
}
// Remember info about the server so we can refresh later
const [year, month, day] = payload.nextUpdate.split('-');
this.mdsCache[url] = {
...mds,
// Store the payload `no` to make sure we're getting the next BLOB in the sequence
no: payload.no,
// Convert the nextUpdate property into a Date so we can determine when to re-download
nextUpdate: new Date(parseInt(year, 10),
// Months need to be zero-indexed
parseInt(month, 10) - 1, parseInt(day, 10)),
};
}
/**
* A helper method to pause execution until the service is ready
*/
pauseUntilReady() {
if (this.state === SERVICE_STATE.READY) {
return new Promise((resolve) => {
resolve();
});
}
// State isn't ready, so set up polling
const readyPromise = new Promise((resolve, reject) => {
const totalTimeoutMS = 70000;
const intervalMS = 100;
let iterations = totalTimeoutMS / intervalMS;
// Check service state every `intervalMS` milliseconds
const intervalID = globalThis.setInterval(() => {
if (iterations < 1) {
clearInterval(intervalID);
reject(`State did not become ready in ${totalTimeoutMS / 1000} seconds`);
}
else if (this.state === SERVICE_STATE.READY) {
clearInterval(intervalID);
resolve();
}
iterations -= 1;
}, intervalMS);
});
return readyPromise;
}
/**
* Report service status on change
*/
setState(newState) {
this.state = newState;
if (newState === SERVICE_STATE.DISABLED) {
log('MetadataService is DISABLED');
}
else if (newState === SERVICE_STATE.REFRESHING) {
log('MetadataService is REFRESHING');
}
else if (newState === SERVICE_STATE.READY) {
log('MetadataService is READY');
}
}
}
exports.BaseMetadataService = BaseMetadataService;
/**
* A basic service for coordinating interactions with the FIDO Metadata Service. This includes BLOB
* download and parsing, and on-demand requesting and caching of individual metadata statements.
*
* https://fidoalliance.org/metadata/
*/
exports.MetadataService = new BaseMetadataService();
@@ -0,0 +1,179 @@
import { expect, expectTypeOf, test } from "vitest";
import * as z from "zod/v4";
const stringSet = z.set(z.string());
type stringSet = z.infer<typeof stringSet>;
const minTwo = z.set(z.string()).min(2);
const maxTwo = z.set(z.string()).max(2);
const justTwo = z.set(z.string()).size(2);
const nonEmpty = z.set(z.string()).nonempty();
const nonEmptyMax = z.set(z.string()).nonempty().max(2);
test("type inference", () => {
expectTypeOf<stringSet>().toEqualTypeOf<Set<string>>();
});
test("valid parse", () => {
const result = stringSet.safeParse(new Set(["first", "second"]));
expect(result.success).toEqual(true);
expect(result.data!.has("first")).toEqual(true);
expect(result.data!.has("second")).toEqual(true);
expect(result.data!.has("third")).toEqual(false);
expect(() => {
minTwo.parse(new Set(["a", "b"]));
minTwo.parse(new Set(["a", "b", "c"]));
maxTwo.parse(new Set(["a", "b"]));
maxTwo.parse(new Set(["a"]));
justTwo.parse(new Set(["a", "b"]));
nonEmpty.parse(new Set(["a"]));
nonEmptyMax.parse(new Set(["a"]));
}).not.toThrow();
});
test("valid parse async", async () => {
const result = await stringSet.spa(new Set(["first", "second"]));
expect(result.success).toEqual(true);
expect(result.data!.has("first")).toEqual(true);
expect(result.data!.has("second")).toEqual(true);
expect(result.data!.has("third")).toEqual(false);
const asyncResult = await stringSet.safeParse(new Set(["first", "second"]));
expect(asyncResult.success).toEqual(true);
expect(asyncResult.data!.has("first")).toEqual(true);
expect(asyncResult.data!.has("second")).toEqual(true);
expect(asyncResult.data!.has("third")).toEqual(false);
});
test("valid parse: size-related methods", () => {
expect(() => {
minTwo.parse(new Set(["a", "b"]));
minTwo.parse(new Set(["a", "b", "c"]));
maxTwo.parse(new Set(["a", "b"]));
maxTwo.parse(new Set(["a"]));
justTwo.parse(new Set(["a", "b"]));
nonEmpty.parse(new Set(["a"]));
nonEmptyMax.parse(new Set(["a"]));
}).not.toThrow();
const sizeZeroResult = stringSet.parse(new Set());
expect(sizeZeroResult.size).toBe(0);
const sizeTwoResult = minTwo.parse(new Set(["a", "b"]));
expect(sizeTwoResult.size).toBe(2);
});
test("failing when parsing empty set in nonempty ", () => {
const result = nonEmpty.safeParse(new Set());
expect(result.success).toEqual(false);
expect(result.error!.issues.length).toEqual(1);
expect(result.error!.issues[0].code).toEqual("too_small");
});
test("failing when set is smaller than min() ", () => {
const result = minTwo.safeParse(new Set(["just_one"]));
expect(result.success).toEqual(false);
expect(result.error!.issues.length).toEqual(1);
expect(result.error!.issues[0].code).toEqual("too_small");
});
test("failing when set is bigger than max() ", () => {
const result = maxTwo.safeParse(new Set(["one", "two", "three"]));
expect(result.success).toEqual(false);
expect(result.error!.issues.length).toEqual(1);
expect(result.error!.issues[0].code).toEqual("too_big");
});
test("doesn’t throw when an empty set is given", () => {
const result = stringSet.safeParse(new Set([]));
expect(result.success).toEqual(true);
});
test("throws when a Map is given", () => {
const result = stringSet.safeParse(new Map([]));
expect(result.success).toEqual(false);
expect(result.error).toMatchInlineSnapshot(`
[ZodError: [
{
"expected": "set",
"code": "invalid_type",
"path": [],
"message": "Invalid input: expected set, received Map"
}
]]
`);
});
test("throws when the given set has invalid input", () => {
const result = stringSet.safeParse(new Set([Symbol()]));
expect(result.success).toEqual(false);
expect(result.error!.issues.length).toEqual(1);
expect(result.error).toMatchInlineSnapshot(`
[ZodError: [
{
"expected": "string",
"code": "invalid_type",
"path": [],
"message": "Invalid input: expected string, received symbol"
}
]]
`);
});
test("throws when the given set has multiple invalid entries", () => {
const result = stringSet.safeParse(new Set([1, 2] as any[]));
expect(result.success).toEqual(false);
expect(result.error!.issues.length).toEqual(2);
expect(result.error).toMatchInlineSnapshot(`
[ZodError: [
{
"expected": "string",
"code": "invalid_type",
"path": [],
"message": "Invalid input: expected string, received number"
},
{
"expected": "string",
"code": "invalid_type",
"path": [],
"message": "Invalid input: expected string, received number"
}
]]
`);
});
test("min/max", async () => {
const schema = z.set(z.string()).min(4).max(5);
const r1 = schema.safeParse(new Set(["a", "b", "c", "d"]));
expect(r1.success).toEqual(true);
const r2 = schema.safeParse(new Set(["a", "b", "c"]));
expect(r2.success).toEqual(false);
expect(r2.error!.issues).toMatchInlineSnapshot(`
[
{
"code": "too_small",
"message": "Too small: expected set to have >4 items",
"minimum": 4,
"origin": "set",
"path": [],
},
]
`);
const r3 = schema.safeParse(new Set(["a", "b", "c", "d", "e", "f"]));
expect(r3.success).toEqual(false);
expect(r3.error!.issues).toMatchInlineSnapshot(`
[
{
"code": "too_big",
"maximum": 5,
"message": "Too big: expected set to have <5 items",
"origin": "set",
"path": [],
},
]
`);
});
@@ -0,0 +1,7 @@
var getPrototypeOf = require("./getPrototypeOf.js");
var isNativeReflectConstruct = require("./isNativeReflectConstruct.js");
var possibleConstructorReturn = require("./possibleConstructorReturn.js");
function _callSuper(t, o, e) {
return o = getPrototypeOf(o), possibleConstructorReturn(t, isNativeReflectConstruct() ? Reflect.construct(o, e || [], getPrototypeOf(t).constructor) : o.apply(t, e));
}
module.exports = _callSuper, module.exports.__esModule = true, module.exports["default"] = module.exports;
@@ -0,0 +1,39 @@
{
"name": "@types/send",
"version": "0.17.6",
"description": "TypeScript definitions for send",
"homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/send",
"license": "MIT",
"contributors": [
{
"name": "Mike Jerred",
"githubUsername": "MikeJerred",
"url": "https://github.com/MikeJerred"
},
{
"name": "Piotr Błażejewicz",
"githubUsername": "peterblazejewicz",
"url": "https://github.com/peterblazejewicz"
},
{
"name": "Sebastian Beltran",
"githubUsername": "bjohansebas",
"url": "https://github.com/bjohansebas"
}
],
"main": "",
"types": "index.d.ts",
"repository": {
"type": "git",
"url": "https://github.com/DefinitelyTyped/DefinitelyTyped.git",
"directory": "types/send"
},
"scripts": {},
"dependencies": {
"@types/mime": "^1",
"@types/node": "*"
},
"peerDependencies": {},
"typesPublisherContentHash": "a1fa60652d5b2e0b448a0370c009054b3adfcc6c06edf12af3deb32ac1f92ac2",
"typeScriptVersion": "5.2"
}
@@ -0,0 +1,887 @@
export declare const Attr: {
codePage: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
time: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
random: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
color: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
size: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
effect: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
charSet: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pitchAndFamily: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fontName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
reserveData: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
};
export declare const NotOnlineFile: {
fileType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
sig: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
fileUuid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
fileMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
fileName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
fileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT64, true, false>;
note: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
reserved: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
subcmd: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
microCloud: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
bytesFileUrls: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, true>;
downloadFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
dangerEvel: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
lifeTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
uploadTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
absFileType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
clientType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
expireTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
fileHash: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
};
export declare const Ptt: {
fileType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
srcUin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
fileUuid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
reserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
serverIp: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
serverPort: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
boolValid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
signature: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
shortcut: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileKey: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
magicPttIndex: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
voiceSwitch: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pttUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
groupFileKey: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
time: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
downPara: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
format: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
bytesPttUrls: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, true>;
downloadFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
};
export declare const RichText: {
attr: import("napcat-protobuf").MessageProtoFieldType<() => {
codePage: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
time: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
random: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
color: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
size: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
effect: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
charSet: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pitchAndFamily: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fontName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
reserveData: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
elems: import("napcat-protobuf").MessageProtoFieldType<() => {
text: import("napcat-protobuf").MessageProtoFieldType<() => {
str: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
lint: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
attr6Buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
attr7Buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
}, true, false>;
face: import("napcat-protobuf").MessageProtoFieldType<() => {
index: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
old: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
}, true, false>;
onlineImage: import("napcat-protobuf").MessageProtoFieldType<() => {
guid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
filePath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
oldVerSendFile: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
notOnlineImage: import("napcat-protobuf").MessageProtoFieldType<() => {
filePath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
downloadPath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
oldVerSendFile: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
imgType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
previewsImage: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
picMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
picHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
picWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
resId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
flag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
thumbUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
original: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bigUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
origUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
bizType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
result: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
index: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
opFaceBuf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
oldPicMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
thumbWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
showLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
downloadLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
x400Url: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
x400Width: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
x400Height: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbRes: import("napcat-protobuf").MessageProtoFieldType<() => {
subType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field3: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field4: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
summary: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
field10: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field20: import("napcat-protobuf").MessageProtoFieldType<() => {
field1: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field2: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
field3: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field4: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field7: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
}, false, false>;
url: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
md5Str: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
}, false, false>;
}, true, false>;
transElem: import("napcat-protobuf").MessageProtoFieldType<() => {
elemType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
elemValue: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
marketFace: import("napcat-protobuf").MessageProtoFieldType<() => {
faceName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
itemType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
faceInfo: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
faceId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
tabId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
subType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
key: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
param: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
mediaType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
imageWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
imageHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
mobileparam: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
pbReserve: import("napcat-protobuf").MessageProtoFieldType<() => {
field8: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
}, false, false>;
}, true, false>;
customFace: import("napcat-protobuf").MessageProtoFieldType<() => {
guid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
filePath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
shortcut: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
buffer: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
flag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
oldData: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
serverIp: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
serverPort: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
fileType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
signature: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
useful: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
md5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
thumbUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
bigUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
origUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
bizType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
repeatIndex: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
repeatImage: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
imageType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
index: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
width: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
height: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
source: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
size: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
origin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
thumbHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
showLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
downloadLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
x400Url: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
x400Width: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
x400Height: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbRes: import("napcat-protobuf").MessageProtoFieldType<() => {
subType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
summary: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
}, true, false>;
}, true, false>;
elemFlags2: import("napcat-protobuf").MessageProtoFieldType<() => {
colorTextId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
msgId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
whisperSessionId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
pttChangeBit: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
vipStatus: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
compatibleId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
insts: import("napcat-protobuf").MessageProtoFieldType<() => {
appId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
instId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
}, false, true>;
msgRptCnt: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
srcInst: import("napcat-protobuf").MessageProtoFieldType<() => {
appId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
instId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
}, false, false>;
longtitude: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
latitude: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
customFont: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
pcSupportDef: import("napcat-protobuf").MessageProtoFieldType<() => {
pcPtlBegin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
pcPtlEnd: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
macPtlBegin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
macPtlEnd: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
ptlsSupport: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, true>;
ptlsNotSupport: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, true>;
}, false, false>;
crmFlags: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, true, false>;
}, true, false>;
richMsg: import("napcat-protobuf").MessageProtoFieldType<() => {
template1: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
serviceId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
msgResId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
rand: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
seq: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, true, false>;
}, true, false>;
groupFile: import("napcat-protobuf").MessageProtoFieldType<() => {
filename: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
batchId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileKey: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
mark: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
sequence: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
batchItemId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
feedMsgTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
extraInfo: import("napcat-protobuf").MessageProtoFieldType<() => {
nick: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
groupCard: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
level: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
flags: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
groupMask: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
msgTailId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
senderTitle: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
apnsTips: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
uin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
msgStateFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
apnsSoundType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
newGroupFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
}, true, false>;
videoFile: import("napcat-protobuf").MessageProtoFieldType<() => {
fileUuid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileFormat: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbFileMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
source: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
thumbFileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
busiType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fromChatType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
toChatType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
boolSupportProgressive: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
fileWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
subBusiType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
videoAttr: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bytesThumbFileUrls: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, true>;
bytesVideoFileUrls: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, true>;
thumbDownloadFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
videoDownloadFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
anonymousGroupMessage: import("napcat-protobuf").MessageProtoFieldType<() => {
flags: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
anonId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
anonNick: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
headPortrait: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
expireTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bubbleId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
rankColor: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
customElem: import("napcat-protobuf").MessageProtoFieldType<() => {
desc: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
data: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
enumType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
ext: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
sound: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
generalFlags: import("napcat-protobuf").MessageProtoFieldType<() => {
bubbleDiyTextId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
groupFlagNew: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
uin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
rpId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
prpFold: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
longTextFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
longTextResId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
groupType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
toUinFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
glamourLevel: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
memberLevel: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
groupRankSeq: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
olympicTorch: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
babyqGuideMsgCookie: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
uin32ExpertFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bubbleSubId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pendantId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
rpIndex: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
srcMsg: import("napcat-protobuf").MessageProtoFieldType<() => {
origSeqs: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, true>;
senderUin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
time: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
flag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
elems: import("napcat-protobuf").MessageProtoFieldType<() => {
text: import("napcat-protobuf").MessageProtoFieldType<() => {
str: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
lint: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
attr6Buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
attr7Buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
}, true, false>;
face: import("napcat-protobuf").MessageProtoFieldType<() => {
index: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
old: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
buf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
}, true, false>;
onlineImage: import("napcat-protobuf").MessageProtoFieldType<() => {
guid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
filePath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
oldVerSendFile: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
notOnlineImage: import("napcat-protobuf").MessageProtoFieldType<() => {
filePath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
downloadPath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
oldVerSendFile: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
imgType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
previewsImage: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
picMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
picHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
picWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
resId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
flag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
thumbUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
original: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bigUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
origUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
bizType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
result: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
index: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
opFaceBuf: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
oldPicMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
thumbWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
showLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
downloadLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
x400Url: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
x400Width: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
x400Height: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbRes: import("napcat-protobuf").MessageProtoFieldType<() => {
subType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field3: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field4: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
summary: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
field10: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field20: import("napcat-protobuf").MessageProtoFieldType<() => {
field1: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field2: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
field3: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field4: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
field7: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
}, false, false>;
url: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
md5Str: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
}, false, false>;
}, true, false>;
transElem: import("napcat-protobuf").MessageProtoFieldType<() => {
elemType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
elemValue: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
marketFace: import("napcat-protobuf").MessageProtoFieldType<() => {
faceName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
itemType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
faceInfo: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
faceId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
tabId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
subType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
key: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
param: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
mediaType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
imageWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
imageHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
mobileparam: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
pbReserve: import("napcat-protobuf").MessageProtoFieldType<() => {
field8: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
}, false, false>;
}, true, false>;
customFace: import("napcat-protobuf").MessageProtoFieldType<() => {
guid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
filePath: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
shortcut: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
buffer: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
flag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
oldData: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
serverIp: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
serverPort: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
fileType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
signature: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
useful: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
md5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
thumbUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
bigUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
origUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
bizType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
repeatIndex: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
repeatImage: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
imageType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
index: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
width: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
height: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
source: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
size: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
origin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
thumbHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
showLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
downloadLen: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
x400Url: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
x400Width: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
x400Height: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbRes: import("napcat-protobuf").MessageProtoFieldType<() => {
subType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
summary: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
}, true, false>;
}, true, false>;
elemFlags2: import("napcat-protobuf").MessageProtoFieldType<() => {
colorTextId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
msgId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
whisperSessionId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
pttChangeBit: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
vipStatus: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
compatibleId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
insts: import("napcat-protobuf").MessageProtoFieldType<() => {
appId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
instId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
}, false, true>;
msgRptCnt: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
srcInst: import("napcat-protobuf").MessageProtoFieldType<() => {
appId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
instId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
}, false, false>;
longtitude: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
latitude: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
customFont: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
pcSupportDef: import("napcat-protobuf").MessageProtoFieldType<() => {
pcPtlBegin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
pcPtlEnd: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
macPtlBegin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
macPtlEnd: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
ptlsSupport: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, true>;
ptlsNotSupport: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, true>;
}, false, false>;
crmFlags: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, true, false>;
}, true, false>;
richMsg: import("napcat-protobuf").MessageProtoFieldType<() => {
template1: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
serviceId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
msgResId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
rand: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
seq: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, true, false>;
}, true, false>;
groupFile: import("napcat-protobuf").MessageProtoFieldType<() => {
filename: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
batchId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileKey: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
mark: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
sequence: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
batchItemId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
feedMsgTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
extraInfo: import("napcat-protobuf").MessageProtoFieldType<() => {
nick: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
groupCard: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
level: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
flags: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
groupMask: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
msgTailId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
senderTitle: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
apnsTips: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
uin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
msgStateFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
apnsSoundType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
newGroupFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
}, true, false>;
videoFile: import("napcat-protobuf").MessageProtoFieldType<() => {
fileUuid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileFormat: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
thumbFileMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
source: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
thumbFileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
busiType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fromChatType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
toChatType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
boolSupportProgressive: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
fileWidth: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
fileHeight: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
subBusiType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
videoAttr: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bytesThumbFileUrls: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, true>;
bytesVideoFileUrls: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, true>;
thumbDownloadFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
videoDownloadFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
anonymousGroupMessage: import("napcat-protobuf").MessageProtoFieldType<() => {
flags: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
anonId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
anonNick: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
headPortrait: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
expireTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bubbleId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
rankColor: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
customElem: import("napcat-protobuf").MessageProtoFieldType<() => {
desc: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
data: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
enumType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
ext: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
sound: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
generalFlags: import("napcat-protobuf").MessageProtoFieldType<() => {
bubbleDiyTextId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
groupFlagNew: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
uin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
rpId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
prpFold: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
longTextFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
longTextResId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
groupType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
toUinFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
glamourLevel: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
memberLevel: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
groupRankSeq: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
olympicTorch: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
babyqGuideMsgCookie: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
uin32ExpertFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
bubbleSubId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pendantId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
rpIndex: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, true, false>;
srcMsg: import("napcat-protobuf").MessageProtoFieldType</*elided*/ any, true, false>;
lightAppElem: import("napcat-protobuf").MessageProtoFieldType<() => {
data: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
msgResid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
}, true, false>;
commonElem: import("napcat-protobuf").MessageProtoFieldType<() => {
serviceType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbElem: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
businessType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
}, true, false>;
}, false, true>;
type: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
richMsg: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
pbReserve: import("napcat-protobuf").MessageProtoFieldType<() => {
messageId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
senderUid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
receiverUid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
friendSeq: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, true, false>;
}, true, false>;
sourceMsg: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
toUin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, true, false>;
troopName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
}, true, false>;
lightAppElem: import("napcat-protobuf").MessageProtoFieldType<() => {
data: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
msgResid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
}, true, false>;
commonElem: import("napcat-protobuf").MessageProtoFieldType<() => {
serviceType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbElem: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
businessType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
}, true, false>;
}, false, true>;
notOnlineFile: import("napcat-protobuf").MessageProtoFieldType<() => {
fileType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
sig: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
fileUuid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
fileMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
fileName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
fileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT64, true, false>;
note: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
reserved: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
subcmd: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
microCloud: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
bytesFileUrls: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, true>;
downloadFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
dangerEvel: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
lifeTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
uploadTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
absFileType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
clientType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
expireTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
fileHash: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
}, true, false>;
ptt: import("napcat-protobuf").MessageProtoFieldType<() => {
fileType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
srcUin: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
fileUuid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
reserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
serverIp: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
serverPort: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
boolValid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
signature: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
shortcut: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
fileKey: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
magicPttIndex: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
voiceSwitch: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pttUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
groupFileKey: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
time: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
downPara: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
format: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
bytesPttUrls: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, true>;
downloadFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
}, true, false>;
};
export declare const ButtonExtra: {
data: import("napcat-protobuf").MessageProtoFieldType<() => {
rows: import("napcat-protobuf").MessageProtoFieldType<() => {
buttons: import("napcat-protobuf").MessageProtoFieldType<() => {
id: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
renderData: import("napcat-protobuf").MessageProtoFieldType<() => {
label: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
visitedLabel: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
style: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
}, false, false>;
action: import("napcat-protobuf").MessageProtoFieldType<() => {
type: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
permission: import("napcat-protobuf").MessageProtoFieldType<() => {
type: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
specifyRoleIds: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, true>;
specifyUserIds: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, true>;
}, false, false>;
unsupportTips: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
data: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
reply: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
enter: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
}, false, false>;
}, false, true>;
}, false, true>;
}, false, false>;
};
export declare const KeyboardData: {
rows: import("napcat-protobuf").MessageProtoFieldType<() => {
buttons: import("napcat-protobuf").MessageProtoFieldType<() => {
id: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
renderData: import("napcat-protobuf").MessageProtoFieldType<() => {
label: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
visitedLabel: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
style: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
}, false, false>;
action: import("napcat-protobuf").MessageProtoFieldType<() => {
type: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
permission: import("napcat-protobuf").MessageProtoFieldType<() => {
type: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
specifyRoleIds: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, true>;
specifyUserIds: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, true>;
}, false, false>;
unsupportTips: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
data: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
reply: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
enter: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
}, false, false>;
}, false, true>;
}, false, true>;
};
export declare const Row: {
buttons: import("napcat-protobuf").MessageProtoFieldType<() => {
id: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
renderData: import("napcat-protobuf").MessageProtoFieldType<() => {
label: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
visitedLabel: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
style: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
}, false, false>;
action: import("napcat-protobuf").MessageProtoFieldType<() => {
type: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
permission: import("napcat-protobuf").MessageProtoFieldType<() => {
type: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
specifyRoleIds: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, true>;
specifyUserIds: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, true>;
}, false, false>;
unsupportTips: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
data: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
reply: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
enter: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
}, false, false>;
}, false, true>;
};
export declare const Button: {
id: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
renderData: import("napcat-protobuf").MessageProtoFieldType<() => {
label: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
visitedLabel: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
style: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
}, false, false>;
action: import("napcat-protobuf").MessageProtoFieldType<() => {
type: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
permission: import("napcat-protobuf").MessageProtoFieldType<() => {
type: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
specifyRoleIds: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, true>;
specifyUserIds: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, true>;
}, false, false>;
unsupportTips: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
data: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
reply: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
enter: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
}, false, false>;
};
export declare const RenderData: {
label: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
visitedLabel: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
style: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
};
export declare const Action: {
type: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
permission: import("napcat-protobuf").MessageProtoFieldType<() => {
type: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
specifyRoleIds: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, true>;
specifyUserIds: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, true>;
}, false, false>;
unsupportTips: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
data: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
reply: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
enter: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BOOL, false, false>;
};
export declare const Permission: {
type: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, false, false>;
specifyRoleIds: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, true>;
specifyUserIds: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, true>;
};
export declare const FileExtra: {
file: import("napcat-protobuf").MessageProtoFieldType<() => {
fileType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
sig: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
fileUuid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
fileMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
fileName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
fileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT64, true, false>;
note: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
reserved: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
subcmd: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
microCloud: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
bytesFileUrls: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, true>;
downloadFlag: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
dangerEvel: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
lifeTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
uploadTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
absFileType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
clientType: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
expireTime: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.INT32, true, false>;
pbReserve: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, true, false>;
fileHash: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, true, false>;
}, false, false>;
field6: import("napcat-protobuf").MessageProtoFieldType<() => {
field2: import("napcat-protobuf").MessageProtoFieldType<() => {
field1: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
fileUuid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
field6: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
field7: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
field8: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
timestamp1: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
fileHash: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
selfUid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
destUid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
}, false, false>;
}, false, false>;
};
export declare const PrivateFileExtra: {
field2: import("napcat-protobuf").MessageProtoFieldType<() => {
field1: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
fileUuid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
field6: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
field7: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
field8: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
timestamp1: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
fileHash: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
selfUid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
destUid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
}, false, false>;
};
export declare const PrivateFileExtraField2: {
field1: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
fileUuid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
field6: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
field7: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
field8: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
timestamp1: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
fileHash: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
selfUid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
destUid: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
};
export declare const GroupFileExtra: {
field1: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
fileName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
display: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
inner: import("napcat-protobuf").MessageProtoFieldType<() => {
info: import("napcat-protobuf").MessageProtoFieldType<() => {
busId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
fileName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
field5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
fileSha: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
extInfoString: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, false, false>;
}, false, false>;
};
export declare const GroupFileExtraInner: {
info: import("napcat-protobuf").MessageProtoFieldType<() => {
busId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
fileName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
field5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
fileSha: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
extInfoString: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
}, false, false>;
};
export declare const GroupFileExtraInfo: {
busId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
fileId: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileSize: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT64, false, false>;
fileName: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
field5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
fileSha: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
extInfoString: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
fileMd5: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.BYTES, false, false>;
};
export declare const ImageExtraUrl: {
origUrl: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.STRING, false, false>;
};
export declare const PokeExtra: {
type: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
field7: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
field8: import("napcat-protobuf").ScalarProtoFieldType<ScalarType.UINT32, false, false>;
};
@@ -0,0 +1,14 @@
'use strict';
var implementation = require('./implementation');
var getProto = require('get-proto');
module.exports = function getPolyfill() {
if (typeof Reflect === 'object' && Reflect && Reflect.getPrototypeOf) {
return Reflect.getPrototypeOf;
}
return getProto
? function getPrototypeOf(O) { return getProto(O); }
: implementation;
};
@@ -0,0 +1,2 @@
declare const useTimeout: (fn: () => void, delay?: number) => () => void;
export default useTimeout;
@@ -0,0 +1 @@
{"name":"@react-aria/form","version":"3.0.11","requiresBuild":false,"files":{"LICENSE":{"checkedAt":1794532105972,"integrity":"sha512-cil7stSp3ik41Hdv2Dj+GMcbvUfs1q+MZ2Yte0804py9i6oJJN/diCiIr/brcQOZ5ZqwAI6dgaHA7l8FZheQBw==","mode":420,"size":11335},"dist/main.js":{"checkedAt":1794532109023,"integrity":"sha512-SAT0LfS72pbUxJsQ0txaHQwhtLFOmt6zXtrwuF/sAZQYb427/SiDk3vLdzsu4sFLtkVhrPkPQJ0PMeCCxiXTTg==","mode":420,"size":962},"dist/module.js":{"checkedAt":1794532109023,"integrity":"sha512-o+/U5+MsWzgeOVj0WhCt5ZKNQaGgSJWo7fdy7xSkd87RLowvnvIJe0WXgU9VbXwpdc6Io1qWcxxOqwyIP3FRpQ==","mode":420,"size":842},"dist/useFormValidation.main.js":{"checkedAt":1794532109023,"integrity":"sha512-VorBY8TUTixiuYFQ7kfWV6WY/Iyu4esEb+skLSkfAfpGjRTes7dUtISwpzg0JBM7pAkae5Pjhe59FT+u8G1UAw==","mode":420,"size":5481},"dist/useFormValidation.module.js":{"checkedAt":1794532109023,"integrity":"sha512-lgHMdUY8YT212nzFjX1dfohxaYqXN+JuxbnN/jx0anpZsLJ5X26Oessib9HQdA0/id5owGmk5nsW1H6dm/MTYw==","mode":420,"size":5339},"package.json":{"checkedAt":1794532109024,"integrity":"sha512-CEIC38emjOom+gCf5uuZuS4SK6ZWpxUfLh5f+FtA+7HvfsRV1M5VV2ATuusH4TmvYp+9drvgmjheOwIu1+40uQ==","mode":420,"size":938},"dist/main.js.map":{"checkedAt":1794532109024,"integrity":"sha512-DO+B1BWV27WziowKPv+VmWj1/I4wrnpQHp6UsCjRRNJeGKIseFUEXd1DNdOWYkpip0o6izJ1uoQsh0Hi6ASJOw==","mode":420,"size":853},"dist/module.js.map":{"checkedAt":1794532109024,"integrity":"sha512-EXnVnuplOTJNgwag/vioKBXocMgi26y/dRuxFdkiudiXL1r5gMeZgn/No31LBjHwB0Wnxm+45q7LpLemYaSj5Q==","mode":420,"size":849},"dist/types.d.ts.map":{"checkedAt":1794532109024,"integrity":"sha512-OeT+TYjyyzFaynjilko50OiGf8n1uMLML+EnIok/hwubXyW0xeDvTDZpJ7HlKkK1HGHUDwDS2uz6Qqe/wJAGyw==","mode":420,"size":1259},"dist/useFormValidation.main.js.map":{"checkedAt":1794532109024,"integrity":"sha512-Bt3rflqGZq0WyAUIX29Pc7vxvj8D5kROav7TlOYZi9aI3m60VqGvpdtRinEQD3Y3ja5sMDHJXBqdhI6n4jXanQ==","mode":420,"size":7167},"dist/useFormValidation.module.js.map":{"checkedAt":1794532109024,"integrity":"sha512-datS2hB3y0aI3ivKu6WmsFAEVYmLi3DM7WnOgW0pajTLopZHpFy0r+poVEzDHyBth3evjHhZnxqO4WormY1EjA==","mode":420,"size":7163},"README.md":{"checkedAt":1794532109024,"integrity":"sha512-ELvvJaEbSyR+vYiTFw0Wor08eceQ5Y5k4s6JXZco2/PAc41DUvFXdUdm86w+xJN7dS0aHWT0B6QF6UcU5ARmWA==","mode":420,"size":134},"dist/import.mjs":{"checkedAt":1794532109024,"integrity":"sha512-jZIffjSRtL+Z2qoc9ZWU/0QnOd54rPRMEEWr+H7b1CFnvPtN3CeTT7n6FhjqduEJNAESzOn4GOaS3vITTkADcQ==","mode":420,"size":836},"dist/useFormValidation.mjs":{"checkedAt":1794532109023,"integrity":"sha512-lgHMdUY8YT212nzFjX1dfohxaYqXN+JuxbnN/jx0anpZsLJ5X26Oessib9HQdA0/id5owGmk5nsW1H6dm/MTYw==","mode":420,"size":5339},"src/index.ts":{"checkedAt":1794532109025,"integrity":"sha512-Hn7qA7IalMdg/vYeBSshqY5udjp11cDOO14lQNjnhozH5Mjs6SX0CvkHq02SBDnq56LwlENipiBMTxls7XWQ+w==","mode":420,"size":676},"dist/types.d.ts":{"checkedAt":1794532109025,"integrity":"sha512-NWh5RPrNVzkVZ5lrnn2Hyxmg2oGKrLVCSg+MOYy89ZIggzlpxeT5mBhPtIRHxq4plGQwnjczF5fhp6mUamhKcg==","mode":420,"size":484},"src/useFormValidation.ts":{"checkedAt":1794532109025,"integrity":"sha512-Y8/ODBDRV6C3qtb9Kji+r0zHozgLsV2QncygIDhFiWC137mIVOT/IOoi9Rkv4MSTYGrh/nHGPZ89aciXfU699w==","mode":420,"size":4764}}}
@@ -0,0 +1 @@
{"version":3,"names":["_package","require","_configuration","_plugins"],"sources":["../../../src/config/files/index.ts"],"sourcesContent":["type indexBrowserType = typeof import(\"./index-browser\");\ntype indexType = typeof import(\"./index\");\n\n// Kind of gross, but essentially asserting that the exports of this module are the same as the\n// exports of index-browser, since this file may be replaced at bundle time with index-browser.\n({}) as any as indexBrowserType as indexType;\n\nexport { findPackageData } from \"./package.ts\";\n\nexport {\n findConfigUpwards,\n findRelativeConfig,\n findRootConfig,\n loadConfig,\n resolveShowConfigPath,\n ROOT_CONFIG_FILENAMES,\n} from \"./configuration.ts\";\nexport type {\n ConfigFile,\n IgnoreFile,\n RelativeConfig,\n FilePackageData,\n} from \"./types.ts\";\nexport {\n loadPlugin,\n loadPreset,\n resolvePlugin,\n resolvePreset,\n} from \"./plugins.ts\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAOA,IAAAA,QAAA,GAAAC,OAAA;AAEA,IAAAC,cAAA,GAAAD,OAAA;AAcA,IAAAE,QAAA,GAAAF,OAAA;AAlBA,CAAC,CAAC,CAAC;AAA0C","ignoreList":[]}
@@ -0,0 +1,71 @@
// Adapted from https://github.com/mathiasbynens/he/blob/36afe179392226cf1b6ccdb16ebbb7a5a844d93a/src/he.js#L106-L134
var _a;
const decodeMap = new Map([
[0, 65533],
// C1 Unicode control character reference replacements
[128, 8364],
[130, 8218],
[131, 402],
[132, 8222],
[133, 8230],
[134, 8224],
[135, 8225],
[136, 710],
[137, 8240],
[138, 352],
[139, 8249],
[140, 338],
[142, 381],
[145, 8216],
[146, 8217],
[147, 8220],
[148, 8221],
[149, 8226],
[150, 8211],
[151, 8212],
[152, 732],
[153, 8482],
[154, 353],
[155, 8250],
[156, 339],
[158, 382],
[159, 376],
]);
/**
* Polyfill for `String.fromCodePoint`. It is used to create a string from a Unicode code point.
*/
export const fromCodePoint =
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition, node/no-unsupported-features/es-builtins
(_a = String.fromCodePoint) !== null && _a !== void 0 ? _a : function (codePoint) {
let output = "";
if (codePoint > 0xffff) {
codePoint -= 0x10000;
output += String.fromCharCode(((codePoint >>> 10) & 0x3ff) | 0xd800);
codePoint = 0xdc00 | (codePoint & 0x3ff);
}
output += String.fromCharCode(codePoint);
return output;
};
/**
* Replace the given code point with a replacement character if it is a
* surrogate or is outside the valid range. Otherwise return the code
* point unchanged.
*/
export function replaceCodePoint(codePoint) {
var _a;
if ((codePoint >= 0xd800 && codePoint <= 0xdfff) || codePoint > 0x10ffff) {
return 0xfffd;
}
return (_a = decodeMap.get(codePoint)) !== null && _a !== void 0 ? _a : codePoint;
}
/**
* Replace the code point if relevant, then convert it to a string.
*
* @deprecated Use `fromCodePoint(replaceCodePoint(codePoint))` instead.
* @param codePoint The code point to decode.
* @returns The decoded code point.
*/
export default function decodeCodePoint(codePoint) {
return fromCodePoint(replaceCodePoint(codePoint));
}
//# sourceMappingURL=decode_codepoint.js.map
@@ -0,0 +1,21 @@
import { TIsTemplateLiteralFinite } from './finite.mjs';
import { TypeBoxError } from '../error/index.mjs';
import type { Assert } from '../helpers/index.mjs';
import type { TBoolean } from '../boolean/index.mjs';
import type { TTemplateLiteral, TTemplateLiteralKind } from './index.mjs';
import type { TLiteral, TLiteralValue } from '../literal/index.mjs';
import type { Expression } from './parse.mjs';
import type { TUnion } from '../union/index.mjs';
export declare class TemplateLiteralGenerateError extends TypeBoxError {
}
type TStringReduceUnary<L extends string, R extends string[], Acc extends string[] = []> = R extends [infer A extends string, ...infer B extends string[]] ? TStringReduceUnary<L, B, [...Acc, `${L}${A}`]> : Acc;
type TStringReduceBinary<L extends string[], R extends string[], Acc extends string[] = []> = L extends [infer A extends string, ...infer B extends string[]] ? TStringReduceBinary<B, R, [...Acc, ...TStringReduceUnary<A, R>]> : Acc;
type TStringReduceMany<T extends string[][]> = T extends [infer L extends string[], infer R extends string[], ...infer Rest extends string[][]] ? TStringReduceMany<[TStringReduceBinary<L, R>, ...Rest]> : T;
type TStringReduce<T extends string[][], O = TStringReduceMany<T>> = 0 extends keyof O ? Assert<O[0], string[]> : [];
type TFromTemplateLiteralUnionKinds<T extends TTemplateLiteralKind[]> = T extends [infer L extends TLiteral, ...infer R extends TLiteral[]] ? [`${L['const']}`, ...TFromTemplateLiteralUnionKinds<R>] : [];
type TFromTemplateLiteralKinds<T extends TTemplateLiteralKind[], Acc extends TLiteralValue[][] = []> = T extends [infer L extends TTemplateLiteralKind, ...infer R extends TTemplateLiteralKind[]] ? (L extends TTemplateLiteral<infer S extends TTemplateLiteralKind[]> ? TFromTemplateLiteralKinds<[...S, ...R], Acc> : L extends TLiteral<infer S extends TLiteralValue> ? TFromTemplateLiteralKinds<R, [...Acc, [S]]> : L extends TUnion<infer S extends TTemplateLiteralKind[]> ? TFromTemplateLiteralKinds<R, [...Acc, TFromTemplateLiteralUnionKinds<S>]> : L extends TBoolean ? TFromTemplateLiteralKinds<R, [...Acc, ['true', 'false']]> : Acc) : Acc;
export declare function TemplateLiteralExpressionGenerate(expression: Expression): IterableIterator<string>;
export type TTemplateLiteralGenerate<T extends TTemplateLiteral, F = TIsTemplateLiteralFinite<T>> = F extends true ? (T extends TTemplateLiteral<infer S extends TTemplateLiteralKind[]> ? TFromTemplateLiteralKinds<S> extends infer R extends string[][] ? TStringReduce<R> : [] : []) : [];
/** Generates a tuple of strings from the given TemplateLiteral. Returns an empty tuple if infinite. */
export declare function TemplateLiteralGenerate<T extends TTemplateLiteral>(schema: T): TTemplateLiteralGenerate<T>;
export {};
@@ -0,0 +1,13 @@
"use strict";
// THIS CODE WAS AUTOMATICALLY GENERATED
// DO NOT EDIT THIS CODE BY HAND
// RUN THE FOLLOWING COMMAND FROM THE WORKSPACE ROOT TO REGENERATE:
// npx nx generate-lib repo
Object.defineProperty(exports, "__esModule", { value: true });
exports.es2020_date = void 0;
const base_config_1 = require("./base-config");
const es2020_intl_1 = require("./es2020.intl");
exports.es2020_date = {
libs: [es2020_intl_1.es2020_intl],
variables: [['Date', base_config_1.TYPE]],
};
@@ -0,0 +1,17 @@
# Build configure for https://www.tea-ci.org (fork of Drone CI with Msys2 support)
build:
image: teaci/msys$$arch
pull: true
shell: msys$$arch
commands:
- pacman -S --needed --noconfirm --noprogressbar mingw-w64-cross-gcc mingw-w64-cross-crt-git
- ./configure
- make
- make tests
- build/trivial_test.exe
- mintty --log - --exec build/winpty.exe cmd /c ver | grep Windows
matrix:
arch:
- 64
- 32
@@ -0,0 +1,6 @@
export declare function groupPossibilities(possibilities: string[]): string;
export declare function padGroup(group: string): string;
export declare const ADDRESS_BOUNDARY = "[^A-Fa-f0-9:]";
export declare function simpleRegularExpression(groups: string[]): string;
export declare function possibleElisions(elidedGroups: number, moreLeft?: boolean, moreRight?: boolean): string;
//# sourceMappingURL=regular-expressions.d.ts.map
@@ -0,0 +1,4 @@
"use strict";var K=Object.defineProperty;var o=(s,e)=>K(s,"name",{value:e,configurable:!0});var Y=require("./get-pipe-path-BoR10qr8.cjs"),u=require("node:module"),m=require("node:path"),L=require("node:url"),b=require("get-tsconfig"),O=require("node:fs"),w=require("./index-gckBtVBf.cjs"),R=require("./client-D6NvIMSC.cjs"),V=require("node:util"),g=require("./index-BWFBUo6r.cjs");const W=o(s=>{if(!s.startsWith("data:text/javascript,"))return;const e=s.indexOf("?");if(e===-1)return;const n=new URLSearchParams(s.slice(e+1)).get("filePath");if(n)return n},"getOriginalFilePath"),D=o(s=>{const e=W(s);return e&&(u._cache[e]=u._cache[s],delete u._cache[s],s=e),s},"interopCjsExports"),Z=o(s=>{const e=s.indexOf(":");if(e!==-1)return s.slice(0,e)},"getScheme"),N=o(s=>s[0]==="."&&(s[1]==="/"||s[1]==="."||s[2]==="/"),"isRelativePath"),j=o(s=>N(s)||m.isAbsolute(s),"isFilePath"),q=o(s=>{if(j(s))return!0;const e=Z(s);return e&&e!=="node"},"requestAcceptsQuery"),v="file://",ee=[".ts",".tsx",".jsx",".mts",".cts"],C=/\.([cm]?ts|[tj]sx)($|\?)/,se=/[/\\].+\.(?:cts|cjs)(?:$|\?)/,te=/\.json($|\?)/,_=/\/(?:$|\?)/,ne=/^(?:@[^/]+\/)?[^/\\]+$/,J=`${m.sep}node_modules${m.sep}`;exports.fileMatcher=void 0,exports.tsconfigPathsMatcher=void 0,exports.allowJs=!1;const Q=o(s=>{let e=null;if(s){const r=m.resolve(s);e={path:r,config:b.parseTsconfig(r)}}else{try{e=b.getTsconfig()}catch{}if(!e)return}exports.fileMatcher=b.createFilesMatcher(e),exports.tsconfigPathsMatcher=b.createPathsMatcher(e),exports.allowJs=e?.config.compilerOptions?.allowJs??!1},"loadTsconfig"),T=o(s=>Array.from(s).length>0?`?${s.toString()}`:"","urlSearchParamsStringify"),re=`
//# sourceMappingURL=data:application/json;base64,`,A=o(()=>process.sourceMapsEnabled??!0,"shouldApplySourceMap"),$=o(({code:s,map:e})=>s+re+Buffer.from(JSON.stringify(e),"utf8").toString("base64"),"inlineSourceMap"),M=Number(process.env.TSX_DEBUG);M&&(g.options.enabled=!0,g.options.supportLevel=3);const I=o(s=>(e,...r)=>{if(!M||e>M)return;const n=`${g.bgGray(` tsx P${process.pid} `)} ${s}`,t=r.map(a=>typeof a=="string"?a:V.inspect(a,{colors:!0})).join(" ");O.writeSync(1,`${n} ${t}
`)},"createLog"),x=I(g.bgLightYellow(g.black(" CJS "))),ae=I(g.bgBlue(" ESM ")),oe=[".cts",".mts",".ts",".tsx",".jsx"],ie=[".js",".cjs",".mjs"],k=[".ts",".tsx",".jsx"],F=o((s,e,r,n)=>{const t=Object.getOwnPropertyDescriptor(s,e);t?.set?s[e]=r:(!t||t.configurable)&&Object.defineProperty(s,e,{value:r,enumerable:t?.enumerable||n?.enumerable,writable:n?.writable??(t?t.writable:!0),configurable:n?.configurable??(t?t.configurable:!0)})},"safeSet"),ce=o((s,e,r)=>{const n=e[".js"],t=o((a,i)=>{if(s.enabled===!1)return n(a,i);const[c,f]=i.split("?");if((new URLSearchParams(f).get("namespace")??void 0)!==r)return n(a,i);x(2,"load",{filePath:i}),a.id.startsWith("data:text/javascript,")&&(a.path=m.dirname(c)),R.parent?.send&&R.parent.send({type:"dependency",path:c});const p=oe.some(h=>c.endsWith(h)),P=ie.some(h=>c.endsWith(h));if(!p&&!P)return n(a,c);let d=O.readFileSync(c,"utf8");if(c.endsWith(".cjs")){const h=w.transformDynamicImport(i,d);h&&(d=A()?$(h):h.code)}else if(p||w.isESM(d)){const h=w.transformSync(d,i,{tsconfigRaw:exports.fileMatcher?.(c)});d=A()?$(h):h.code}x(1,"loaded",{filePath:c}),a._compile(d,c)},"transformer");F(e,".js",t);for(const a of k)F(e,a,t,{enumerable:!r,writable:!0,configurable:!0});return F(e,".mjs",t,{writable:!0,configurable:!0}),()=>{e[".js"]===t&&(e[".js"]=n);for(const a of[...k,".mjs"])e[a]===t&&delete e[a]}},"createExtensions"),le=o(s=>e=>{if((e==="."||e===".."||e.endsWith("/.."))&&(e+="/"),_.test(e)){let r=m.join(e,"index.js");e.startsWith("./")&&(r=`./${r}`);try{return s(r)}catch{}}try{return s(e)}catch(r){const n=r;if(n.code==="MODULE_NOT_FOUND")try{return s(`${e}${m.sep}index.js`)}catch{}throw n}},"createImplicitResolver"),B=[".js",".json"],G=[".ts",".tsx",".jsx"],fe=[...G,...B],he=[...B,...G],y=Object.create(null);y[".js"]=[".ts",".tsx",".js",".jsx"],y[".jsx"]=[".tsx",".ts",".jsx",".js"],y[".cjs"]=[".cts"],y[".mjs"]=[".mts"];const X=o(s=>{const e=s.split("?"),r=e[1]?`?${e[1]}`:"",[n]=e,t=m.extname(n),a=[],i=y[t];if(i){const f=n.slice(0,-t.length);a.push(...i.map(l=>f+l+r))}const c=!(s.startsWith(v)||j(n))||n.includes(J)||n.includes("/node_modules/")?he:fe;return a.push(...c.map(f=>n+f+r)),a},"mapTsExtensions"),S=o((s,e,r)=>{if(x(3,"resolveTsFilename",{request:e,isDirectory:_.test(e),isTsParent:r,allowJs:exports.allowJs}),_.test(e)||!r&&!exports.allowJs)return;const n=X(e);if(n)for(const t of n)try{return s(t)}catch(a){const{code:i}=a;if(i!=="MODULE_NOT_FOUND"&&i!=="ERR_PACKAGE_PATH_NOT_EXPORTED")throw a}},"resolveTsFilename"),me=o((s,e)=>r=>{if(x(3,"resolveTsFilename",{request:r,isTsParent:e,isFilePath:j(r)}),j(r)){const n=S(s,r,e);if(n)return n}try{return s(r)}catch(n){const t=n;if(t.code==="MODULE_NOT_FOUND"){if(t.path){const i=t.message.match(/^Cannot find module '([^']+)'$/);if(i){const f=i[1],l=S(s,f,e);if(l)return l}const c=t.message.match(/^Cannot find module '([^']+)'. Please verify that the package.json has a valid "main" entry$/);if(c){const f=c[1],l=S(s,f,e);if(l)return l}}const a=S(s,r,e);if(a)return a}throw t}},"createTsExtensionResolver"),z="at cjsPreparseModuleExports (node:internal",de=o(s=>{const e=s.stack.split(`
`).slice(1);return e[1].includes(z)||e[2].includes(z)},"isFromCjsLexer"),ue=o((s,e)=>{const r=s.split("?"),n=new URLSearchParams(r[1]);if(e?.filename){const t=W(e.filename);let a;if(t){const f=t.split("?"),l=f[0];a=f[1],e.filename=l,e.path=m.dirname(l),e.paths=u._nodeModulePaths(e.path),u._cache[l]=e}a||(a=e.filename.split("?")[1]);const c=new URLSearchParams(a).get("namespace");c&&n.append("namespace",c)}return[r[0],n,(t,a)=>(m.isAbsolute(t)&&!t.endsWith(".json")&&!t.endsWith(".node")&&!(a===0&&de(new Error))&&(t+=T(n)),t)]},"preserveQuery"),pe=o((s,e,r)=>{if(s.startsWith(v)&&(s=L.fileURLToPath(s)),exports.tsconfigPathsMatcher&&!j(s)&&!e?.filename?.includes(J)){const n=exports.tsconfigPathsMatcher(s);for(const t of n)try{return r(t)}catch{}}return r(s)},"resolveTsPaths"),Pe=o((s,e,r)=>(n,t,...a)=>{if(s.enabled===!1)return e(n,t,...a);n=D(n);const[i,c,f]=ue(n,t);if((c.get("namespace")??void 0)!==r)return e(n,t,...a);x(2,"resolve",{request:n,parent:t?.filename??t,restOfArgs:a});let l=o(P=>e(P,t,...a),"nextResolveSimple");l=me(l,!!(r||t?.filename&&C.test(t.filename))),l=le(l);const p=f(pe(i,t,l),a.length);return x(1,"resolved",{request:n,parent:t?.filename??t,resolved:p}),p},"createResolveFilename"),H=o((s,e)=>{if(!e)throw new Error("The current file path (__filename or import.meta.url) must be provided in the second argument of tsx.require()");return s.startsWith(".")?((typeof e=="string"&&e.startsWith(v)||e instanceof URL)&&(e=L.fileURLToPath(e)),m.resolve(m.dirname(e),s)):s},"resolveContext"),ge=o(s=>{const{sourceMapsEnabled:e}=process,r={enabled:!0};Q(process.env.TSX_TSCONFIG_PATH),process.setSourceMapsEnabled(!0);const n=u._resolveFilename,t=Pe(r,n,s?.namespace);u._resolveFilename=t;const a=ce(r,u._extensions,s?.namespace),i=o(()=>{e===!1&&process.setSourceMapsEnabled(!1),r.enabled=!1,u._resolveFilename===t&&(u._resolveFilename=n),a()},"unregister");if(s?.namespace){const c=o((l,p)=>{const P=H(l,p),[d,h]=P.split("?"),E=new URLSearchParams(h);return s.namespace&&!d.startsWith("node:")&&E.set("namespace",s.namespace),Y.require(d+T(E))},"scopedRequire");i.require=c;const f=o((l,p,P)=>{const d=H(l,p),[h,E]=d.split("?"),U=new URLSearchParams(E);return s.namespace&&!h.startsWith("node:")&&U.set("namespace",s.namespace),t(h+T(U),module,!1,P)},"scopedResolve");i.resolve=f,i.unregister=i}return i},"register");exports.cjsExtensionPattern=se,exports.debugEnabled=M,exports.fileUrlPrefix=v,exports.inlineSourceMap=$,exports.interopCjsExports=D,exports.isBarePackageNamePattern=ne,exports.isDirectoryPattern=_,exports.isJsonPattern=te,exports.isRelativePath=N,exports.loadTsconfig=Q,exports.logEsm=ae,exports.mapTsExtensions=X,exports.register=ge,exports.requestAcceptsQuery=q,exports.tsExtensions=ee,exports.tsExtensionsPattern=C;
@@ -0,0 +1,6 @@
import { findInPrototypeChain } from './prototype/calculations/findInPrototypeChain';
import { getBaseType } from './prototype/calculations/getBaseType';
import { Prototype } from './prototype/models/Prototype';
export type { Prototype };
export { findInPrototypeChain, getBaseType };
//# sourceMappingURL=index.d.ts.map
@@ -0,0 +1,29 @@
'use strict'
const contentVer = require('../../package.json')['cache-version'].content
const hashToSegments = require('../util/hash-to-segments')
const path = require('path')
const ssri = require('ssri')
// Current format of content file path:
//
// sha512-BaSE64Hex= ->
// ~/.my-cache/content-v2/sha512/ba/da/55deadbeefc0ffee
//
module.exports = contentPath
function contentPath (cache, integrity) {
const sri = ssri.parse(integrity, { single: true })
// contentPath is the *strongest* algo given
return path.join(
contentDir(cache),
sri.algorithm,
...hashToSegments(sri.hexDigest())
)
}
module.exports.contentDir = contentDir
function contentDir (cache) {
return path.join(cache, `content-v${contentVer}`)
}
@@ -0,0 +1,18 @@
/**
* Converts `set` to an array of its values.
*
* @private
* @param {Object} set The set to convert.
* @returns {Array} Returns the values.
*/
function setToArray(set) {
var index = -1,
result = Array(set.size);
set.forEach(function(value) {
result[++index] = value;
});
return result;
}
export default setToArray;
@@ -0,0 +1,37 @@
var baseRepeat = require('./_baseRepeat'),
isIterateeCall = require('./_isIterateeCall'),
toInteger = require('./toInteger'),
toString = require('./toString');
/**
* Repeats the given string `n` times.
*
* @static
* @memberOf _
* @since 3.0.0
* @category String
* @param {string} [string=''] The string to repeat.
* @param {number} [n=1] The number of times to repeat the string.
* @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
* @returns {string} Returns the repeated string.
* @example
*
* _.repeat('*', 3);
* // => '***'
*
* _.repeat('abc', 2);
* // => 'abcabc'
*
* _.repeat('abc', 0);
* // => ''
*/
function repeat(string, n, guard) {
if ((guard ? isIterateeCall(string, n, guard) : n === undefined)) {
n = 1;
} else {
n = toInteger(n);
}
return baseRepeat(toString(string), n);
}
module.exports = repeat;
@@ -0,0 +1,68 @@
/*********************************************************************
* NAN - Native Abstractions for Node.js
*
* Copyright (c) 2018 NAN contributors
*
* MIT License <https://github.com/nodejs/nan/blob/master/LICENSE.md>
********************************************************************/
#ifndef NAN_CONVERTERS_43_INL_H_
#define NAN_CONVERTERS_43_INL_H_
#define X(TYPE) \
imp::ToFactory<v8::TYPE>::return_t \
imp::ToFactory<v8::TYPE>::convert(v8::Local<v8::Value> val) { \
v8::Isolate *isolate = v8::Isolate::GetCurrent(); \
v8::EscapableHandleScope scope(isolate); \
return scope.Escape( \
val->To ## TYPE(isolate->GetCurrentContext()) \
.FromMaybe(v8::Local<v8::TYPE>())); \
}
X(Number)
X(String)
X(Object)
X(Integer)
X(Uint32)
X(Int32)
// V8 <= 7.0
#if V8_MAJOR_VERSION < 7 || (V8_MAJOR_VERSION == 7 && V8_MINOR_VERSION == 0)
X(Boolean)
#else
imp::ToFactory<v8::Boolean>::return_t \
imp::ToFactory<v8::Boolean>::convert(v8::Local<v8::Value> val) { \
v8::Isolate *isolate = v8::Isolate::GetCurrent(); \
v8::EscapableHandleScope scope(isolate); \
return scope.Escape(val->ToBoolean(isolate)); \
}
#endif
#undef X
#define X(TYPE, NAME) \
imp::ToFactory<TYPE>::return_t \
imp::ToFactory<TYPE>::convert(v8::Local<v8::Value> val) { \
v8::Isolate *isolate = v8::Isolate::GetCurrent(); \
v8::HandleScope scope(isolate); \
return val->NAME ## Value(isolate->GetCurrentContext()); \
}
X(double, Number)
X(int64_t, Integer)
X(uint32_t, Uint32)
X(int32_t, Int32)
// V8 <= 7.0
#if V8_MAJOR_VERSION < 7 || (V8_MAJOR_VERSION == 7 && V8_MINOR_VERSION == 0)
X(bool, Boolean)
#else
imp::ToFactory<bool>::return_t \
imp::ToFactory<bool>::convert(v8::Local<v8::Value> val) { \
v8::Isolate *isolate = v8::Isolate::GetCurrent(); \
v8::HandleScope scope(isolate); \
return Just<bool>(val->BooleanValue(isolate)); \
}
#endif
#undef X
#endif // NAN_CONVERTERS_43_INL_H_
@@ -0,0 +1,9 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports["default"] = void 0;
var _react = require("react");
var _createDeepCompareEffect = require("../createDeepCompareEffect");
var _default = exports["default"] = (0, _createDeepCompareEffect.createDeepCompareEffect)(_react.useEffect);
@@ -0,0 +1 @@
{"version":3,"names":["virtualTypes","require","_debug","_index","_index2","_t","t","cache","_generator","NodePath_ancestry","NodePath_inference","NodePath_replacement","NodePath_evaluation","NodePath_conversion","NodePath_introspection","_context","NodePath_context","NodePath_removal","NodePath_modification","NodePath_family","NodePath_comments","NodePath_virtual_types_validator","validate","debug","buildDebug","REMOVED","exports","SHOULD_STOP","SHOULD_SKIP","NodePath_Final","default","NodePath","constructor","hub","parent","contexts","state","_traverseFlags","skipKeys","parentPath","container","listKey","key","node","type","_store","data","context","scope","removed","v","shouldStop","shouldSkip","get","Error","targetNode","paths","getOrCreateCachedPaths","path","set","setup","call","getScope","isScope","Scope","setData","val","Object","create","getData","def","undefined","hasNode","buildCodeFrameError","msg","SyntaxError","buildError","traverse","visitor","getPathLocation","parts","inList","unshift","join","message","enabled","toString","generator","code","parentKey","methods","findParent","find","getFunctionParent","getStatementParent","getEarliestCommonAncestorFrom","getDeepestCommonAncestorFrom","getAncestry","isAncestor","isDescendant","inType","getTypeAnnotation","isBaseType","couldBeBaseType","baseTypeStrictlyMatches","isGenericType","replaceWithMultiple","replaceWithSourceString","replaceWith","replaceExpressionWithStatements","replaceInline","evaluateTruthy","evaluate","toComputedKey","ensureBlock","unwrapFunctionEnvironment","arrowFunctionToExpression","splitExportDeclaration","ensureFunctionName","matchesPattern","isStatic","isNodeType","canHaveVariableDeclarationOrExpression","canSwapBetweenExpressionAndStatement","isCompletionRecord","isStatementOrBlock","referencesImport","getSource","willIMaybeExecuteBefore","_guessExecutionStatusRelativeTo","resolve","isConstantExpression","isInStrictMode","isDenylisted","visit","skip","skipKey","stop","setContext","requeue","requeueComputedKeyAndDecorators","remove","insertBefore","insertAfter","unshiftContainer","pushContainer","getOpposite","getCompletionRecords","getSibling","getPrevSibling","getNextSibling","getAllNextSiblings","getAllPrevSiblings","getAssignmentIdentifiers","getBindingIdentifiers","getOuterBindingIdentifiers","getBindingIdentifierPaths","getOuterBindingIdentifierPaths","shareCommentsWithSiblings","addComment","addComments","assign","prototype","arrowFunctionToShadowed","String","has","is","isnt","equals","hoist","updateSiblingKeys","isBlacklisted","setScope","resync","popContext","pushContext","setKey","_guessExecutionStatusRelativeToDifferentFunctions","_getTypeAnnotation","_replaceWith","_resolve","_call","_resyncParent","_resyncKey","_resyncList","_resyncRemoved","_getQueueContexts","_removeFromScope","_callRemovalHooks","_remove","_markRemoved","_assertUnremoved","_containerInsert","_containerInsertBefore","_containerInsertAfter","_verifyNodeList","_getKey","_getPattern","TYPES","typeKey","fn","opts","TypeError","keys","includes","push"],"sources":["../../src/path/index.ts"],"sourcesContent":["import type { HubInterface } from \"../hub.ts\";\nimport type TraversalContext from \"../context.ts\";\nimport type { ExplodedTraverseOptions } from \"../index.ts\";\nimport * as virtualTypes from \"./lib/virtual-types.ts\";\nimport buildDebug from \"debug\";\nimport traverse from \"../index.ts\";\nimport type { Visitor } from \"../types.ts\";\nimport Scope from \"../scope/index.ts\";\nimport { validate } from \"@babel/types\";\nimport * as t from \"@babel/types\";\nimport * as cache from \"../cache.ts\";\nimport generator from \"@babel/generator\";\n\n// NodePath is split across many files.\nimport * as NodePath_ancestry from \"./ancestry.ts\";\nimport * as NodePath_inference from \"./inference/index.ts\";\nimport * as NodePath_replacement from \"./replacement.ts\";\nimport * as NodePath_evaluation from \"./evaluation.ts\";\nimport * as NodePath_conversion from \"./conversion.ts\";\nimport * as NodePath_introspection from \"./introspection.ts\";\nimport * as NodePath_context from \"./context.ts\";\nimport * as NodePath_removal from \"./removal.ts\";\nimport * as NodePath_modification from \"./modification.ts\";\nimport * as NodePath_family from \"./family.ts\";\nimport * as NodePath_comments from \"./comments.ts\";\nimport * as NodePath_virtual_types_validator from \"./lib/virtual-types-validator.ts\";\nimport type { NodePathAssertions } from \"./generated/asserts.ts\";\nimport type { NodePathValidators } from \"./generated/validators.ts\";\nimport { setup } from \"./context.ts\";\n\nconst debug = buildDebug(\"babel\");\n\nexport const REMOVED = 1 << 0;\nexport const SHOULD_STOP = 1 << 1;\nexport const SHOULD_SKIP = 1 << 2;\n\ndeclare const bit: import(\"../../../../scripts/babel-plugin-bit-decorator/types.d.ts\").BitDecorator<\n NodePath_Final<t.Node>\n>;\n\nexport type NodePaths<T extends t.Node | t.Node[]> = T extends t.Node[]\n ? { [Line truncated
@@ -0,0 +1,950 @@
flf2a$ 9 7 13 15 30
NTGreek by Bruce Jakeway--based on Standard by Glenn Chappell & Ian Chai
Questions and comments regarding ntgreek.flf to pbjakeway@neumann.uwaterloo.ca
For figlet release 2.0
Date: 1994 Apr 2
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
9 - height of a character
7 - height of a character, not including descenders
13 - max line length (excluding comment lines) + a fudge factor
15 - default smushmode for this font (like "-m 15" on command line)
30 - number of comment lines
Greek keyboard maps:
All keys map to those in standard except:
alpha = A,a lambda = L,l phi = F,f rough breathing = (
beta = B,b mu = M,m chi = C,c smooth breathing = )
gamma = G,g nu = N,n psi = Y,y acute accent = '
delta = D,d xi = X,x omega = w,w grave accent = `
epsilon = E,e omicron = O,o script theta = J diaresis = ^
zeta = Z,z pi = P,p script phi = j
eta = H,h rho = R,r final sigma = V
theta = Q,q sigma = S,s omega bar = v
iota = I,i tau = T,t raised period = :
kappa = K,k upsilon = U,u iota subscript = _
$@
$@
$@
$@
$@
$@
$@
$@
$@@
@
_ @
| |@
| |@
|_|@
_ @
(_)@
@
@@
@
_ _ @
( )( )@
V V @
@
@
$ @
@
@@
@
_ _ @
_| |_| |_ @
(_ _ _)@
_| |_| |_ @
(_ _ _)@
|_| |_| @
@
@@
_ @
_| |_ @
/ _) @
( (| |_ @
\_ \ @
_| |) )@
(_ _/ @
|_| @
@@
@
_ __@
(_) / /@
/ / @
/ / @
/ / _ @
/_/ (_)@
@
@@
@
___ @
/ \ @
\ O / @
/ _ \/\@
( (_> <@
\___/\/@
@
@@
@
@
//@
// @
@
@
@
@
@@
@
@
@
((@
@
@
@
@
@@
@
@
@
))@
@
@
@
@
@@
@
@
__/\__@
\ /@
/_ _\@
\/ @
@
@
@@
@
@
_ @
_| |_ @
(_ _)@
|_| @
@
@
@@
@
@
$ @
@
@
_ @
( )@
|/ @
@@
@
@
@
_____ @
(_____)@
@
$ @
@
@@
@
@
$ @
@
@
_ @
(_)@
@
@@
@
__@
/ /@
/ / @
/ / @
/ / @
/_/ @
@
@@
@
___ @
/ _ \ @
| | | |@
| | | |@
| |_| |@
\___/ @
@
@@
@
_ @
/ |@
- |@
| |@
| |@
|_|@
@
@@
@
____ @
(___ \ @
__) )@
/ __/ @
| |___ @
|_____)@
@
@@
@
_____ @
(__ / @
/ / @
(__ \ @
___) )@
(____/ @
@
@@
@
_ @
/ | @
/ o |_ @
/__ _)@
| | @
|_| @
@
@@
@
____ @
| __) @
| |__ @
|___ \ @
___) )@
(____/ @
@
@@
@
__ @
/ / @
/ /_ @
| '_ \ @
| (_) )@
\___/ @
@
@@
@
_____ @
(___ )@
_/ / @
( _) @
/ / @
/_/ @
@
@@
@
___ @
/ \ @
\ O / @
/ _ \ @
( (_) )@
\___/ @
@
@@
@
___ @
/ _ \ @
( (_) |@
\__, |@
/ / @
/_/ @
@
@@
@
@
$ @
_ @
(_)@
@
$ @
@
@@
@
@
@
_ @
(_)@
_ @
( )@
|/ @
@@
@
__@
/ /@
/ / @
< < @
\ \ @
\_\@
@
@@
@
@
_____ @
(_____)@
_____ @
(_____)@
@
@
@@
@
__ @
\ \ @
\ \ @
> >@
/ / @
/_/ @
@
@@
@
___ @
(__ \@
/ /@
|_| @
_ @
(_) @
@
@@
@
_____ @
/ ___ \ @
/ / | |@
( ( () | |@
\ \____/_@
\______/@
@
@@
@
___ @
/ _ \ @
| |_| |@
| _ |@
| | | |@
|_| |_|@
@
@@
@
____ @
| _ \ @
| |_) )@
| _ ( @
| |_) )@
|____/ @
@
@@
@
__ __@
\ \ / /@
\ v / @
> < @
/ ^ \ @
/_/ \_\@
@
@@
@
@
/\ @
/ \ @
/ /\ \ @
/ /__\ \ @
/________\@
@
@@
@
_____ @
| ___)@
| |_ @
| _) @
| |___ @
|_____)@
@
@@
@
_ @
_| |_ @
/ \ @
( (| |) )@
\_ _/ @
|_| @
@
@@
@
_____ @
| ___)@
| |$ @
| |$ @
| | @
|_| @
@
@@
@
_ _ @
| | | |@
| |_| |@
| _ |@
| | | |@
|_| |_|@
@
@@
@
___ @
( )@
| | @
| | @
| | @
(___)@
@
@@
@
___ @
/ _ \ @
( (_| |_ @
_ \ _ _)@
| |___| | @
\_____/ @
@
@@
@
_ __@
| | / /@
| |/ / @
| < @
| |\ \ @
|_| \_\@
@
@@
@
@
/\ @
/ \ @
/ /\ \ @
/ / \ \ @
/_/ \_\@
@
@@
@
__ __ @
| \ / |@
| v |@
| |\_/| |@
| | | |@
|_| |_|@
@
@@
@
_ _ @
| \ | |@
| \| |@
| |@
| |\ |@
|_| \_|@
@
@@
@
___ @
/ _ \ @
| | | |@
| | | |@
| |_| |@
\___/ @
@
@@
@
_______ @
( _ )@
| | | | @
| | | | @
| | | | @
|_| |_| @
@
@@
@
____ @
/ __ \ @
| |__| |@
| __ |@
| |__| |@
\____/ @
@
@@
@
____ @
| _ \ @
| |_) )@
| __/ @
| | @
|_| @
@
@@
@
______ @
\ ___)@
\ \ @
> > @
/ /__ @
/_____)@
@
@@
@
_____ @
(_ _)@
| | @
| | @
| | @
|_| @
@
@@
@
__ __ @
(_ \ / _)@
\ v / @
| | @
| | @
|_| @
@
@@
@
@
@
____ @
/ ___)@
( (__ @
\__ \ @
_) )@
(__/ @@
@
____ @
/ __ \ @
| | | | @
| | | | @
_\ \/ /_ @
(___||___)@
@
@@
@
_____ @
(_____)@
___ @
(___) @
_____ @
(_____)@
@
@@
@
_ _ _ @
| || || |@
| \| |/ |@
\_ _/ @
| | @
|_| @
@
@@
@
______@
(___ /@
/ / @
/ / @
/ /__ @
/_____)@
@
@@
___ @
| _)@
| | @
| | @
| | @
| | @
| |_ @
|___)@
@@
@
__ @
\ \ @
\ \ @
\ \ @
\ \ @
\_\@
@
@@
___ @
(_ |@
| |@
| |@
| |@
| |@
_| |@
(___|@
@@
@
_ _ @
(_) (_)@
@
@
@
@
@
@@
@
@
@
@
@
@
@
@
||@@
@
@
\\ @
\\@
@
@
@
@
@@
@
@
@
__ __@
/ \/ /@
( () < @
\__/\_\@
@
@@
@
___ @
/ _ \ @
| |_) )@
| _ < @
| |_) )@
| __/ @
| | @
|_| @@
@
@
@
__ __@
\ \ / /@
\ v / @
> < @
/ ^ \ @
/_/ \_\@@
@
__ @
/ _) @
\ \ @
/ _ \ @
( (_) )@
\___/ @
@
@@
@
@
@
___ @
/ __)@
> _) @
\___)@
@
@@
@
_ @
| | @
_| |_ @
/ \ @
( (| |) )@
\_ _/ @
| | @
|_| @@
@
@
@
_ _ @
( \ / )@
\ v / @
| | @
| | @
|_| @@
@
@
@
_ __ @
| '_ \ @
| | | |@
|_| | |@
| |@
|_|@@
@
@
@
_ @
| | @
| | @
\_)@
@
@@
@
@
@
_ __ @
| | / \ @
| || || )@
\_ _/ @
| | @
|_| @@
@
@
@
_ __@
| |/ /@
| < @
|_|\_\@
@
@@
@
__ @
\ \ @
\ \ @
> \ @
/ ^ \ @
/_/ \_\@
@
@@
@
@
@
_ _ @
| | | |@
| |_| |@
| ._,_|@
| | @
|_| @@
@
@
@
_ __@
| |/ /@
| / / @
|__/ @
@
@@
@
@
@
___ @
/ _ \ @
( (_) )@
\___/ @
@
@@
@
@
@
______ @
( __ )@
| || | @
|_||_| @
@
@@
@
___ @
/ _ \ @
| |_| |@
| _ |@
| |_| |@
\___/ @
@
@@
@
@
@
___ @
/ _ \ @
| |_) )@
| __/ @
| | @
|_| @@
@
@
@
____ @
/ ._)@
( () ) @
\__/ @
@
@@
@
@
@
___ @
( )@
| | @
\_)@
@
@@
@
@
@
_ _ @
| | | |@
| |_| |@
\___/ @
@
@@
@
@
@
_________ @
( _____ )@
| |_/ \_| |@
\___^___/ @
@
@@
@
@
@
__ __ @
/ / _ \ \ @
| |_/ \_| |@
\___^___/ @
@
@@
__ @
\ \__ @
> __) @
( (_ @
> _) @
( (__ @
\__ \ @
) )@
(_/ @@
@
@
@
_ _ _ @
| || || |@
| \| |/ |@
\_ _/ @
| | @
|_| @@
@
_____ @
\__ ) @
/ / @
/ / @
| |__ @
\__ \ @
) )@
(_/ @@
__@
/ /@
| | @
| | @
< < @
| | @
| | @
\_\@
@@
_ @
| |@
| |@
| |@
| |@
| |@
| |@
|_|@
@@
__ @
\ \ @
| | @
| | @
> >@
| | @
| | @
/_/ @
@@
@
/\/|@
|/\/ @
@
@
@
@
@
@@
_ _ @
(_)_(_)@
/ _ \ @
| |_| |@
| _ |@
| | | |@
|_| |_|@
@
@@
_ _ @
(_)_(_)@
/ _ \ @
| | | |@
| | | |@
| |_| |@
\___/ @
@
@@
_ _ @
(_) (_)@
| | | |@
| | | |@
| | | |@
| |_| |@
\___/ @
@
@@
@
@
_ _ @
(_)_(_)@
/ _` |@
( (_| |@
\__,_|@
@
@@
@
@
_ _ @
(_)_(_)@
/ _ \ @
( (_) )@
\___/ @
@
@@
@
@
_ _ @
(_) (_)@
| | | |@
| |_| |@
\__,_|@
@
@@
@
___ @
/ _ \ @
| | ) )@
| |< < @
| | ) )@
| ||_/ @
|_| @
@@
@@ -0,0 +1,246 @@
#include <windows.h>
#include <assert.h>
#include <vector>
#include "TestUtil.cc"
#define COUNT_OF(x) (sizeof(x) / sizeof((x)[0]))
CHAR_INFO ci(wchar_t ch, WORD attributes) {
CHAR_INFO ret;
ret.Char.UnicodeChar = ch;
ret.Attributes = attributes;
return ret;
}
CHAR_INFO ci(wchar_t ch) {
return ci(ch, 7);
}
CHAR_INFO ci() {
return ci(L' ');
}
bool operator==(SMALL_RECT x, SMALL_RECT y) {
return !memcmp(&x, &y, sizeof(x));
}
SMALL_RECT sr(COORD pt, COORD size) {
return {
pt.X, pt.Y,
static_cast<SHORT>(pt.X + size.X - 1),
static_cast<SHORT>(pt.Y + size.Y - 1)
};
}
static void set(
const COORD pt,
const COORD size,
const std::vector<CHAR_INFO> &data) {
assert(data.size() == size.X * size.Y);
SMALL_RECT writeRegion = sr(pt, size);
BOOL ret = WriteConsoleOutputW(
GetStdHandle(STD_OUTPUT_HANDLE),
data.data(), size, {0, 0}, &writeRegion);
assert(ret && writeRegion == sr(pt, size));
}
static void set(
const COORD pt,
const std::vector<CHAR_INFO> &data) {
set(pt, {static_cast<SHORT>(data.size()), 1}, data);
}
static void writeAttrsAt(
const COORD pt,
const std::vector<WORD> &data) {
DWORD actual = 0;
BOOL ret = WriteConsoleOutputAttribute(
GetStdHandle(STD_OUTPUT_HANDLE),
data.data(), data.size(), pt, &actual);
assert(ret && actual == data.size());
}
static void writeCharsAt(
const COORD pt,
const std::vector<wchar_t> &data) {
DWORD actual = 0;
BOOL ret = WriteConsoleOutputCharacterW(
GetStdHandle(STD_OUTPUT_HANDLE),
data.data(), data.size(), pt, &actual);
assert(ret && actual == data.size());
}
static void writeChars(
const std::vector<wchar_t> &data) {
DWORD actual = 0;
BOOL ret = WriteConsoleW(
GetStdHandle(STD_OUTPUT_HANDLE),
data.data(), data.size(), &actual, NULL);
assert(ret && actual == data.size());
}
std::vector<CHAR_INFO> get(
const COORD pt,
const COORD size) {
std::vector<CHAR_INFO> data(size.X * size.Y);
SMALL_RECT readRegion = sr(pt, size);
BOOL ret = ReadConsoleOutputW(
GetStdHandle(STD_OUTPUT_HANDLE),
data.data(), size, {0, 0}, &readRegion);
assert(ret && readRegion == sr(pt, size));
return data;
}
std::vector<wchar_t> readCharsAt(
const COORD pt,
int size) {
std::vector<wchar_t> data(size);
DWORD actual = 0;
BOOL ret = ReadConsoleOutputCharacterW(
GetStdHandle(STD_OUTPUT_HANDLE),
data.data(), data.size(), pt, &actual);
assert(ret);
data.resize(actual); // With double-width chars, we can read fewer than `size`.
return data;
}
static void dump(const COORD pt, const COORD size) {
for (CHAR_INFO ci : get(pt, size)) {
printf("%04X %04X\n", ci.Char.UnicodeChar, ci.Attributes);
}
}
static void dumpCharsAt(const COORD pt, int size) {
for (wchar_t ch : readCharsAt(pt, size)) {
printf("%04X\n", ch);
}
}
static COORD getCursorPos() {
CONSOLE_SCREEN_BUFFER_INFO info = { sizeof(info) };
assert(GetConsoleScreenBufferInfo(GetStdHandle(STD_OUTPUT_HANDLE), &info));
return info.dwCursorPosition;
}
static void test1() {
// We write "䀀䀀", then write "䀁" in the middle of the two. The second
// write turns the first and last cells into spaces. The LEADING/TRAILING
// flags retain consistency.
printf("test1 - overlap full-width char with full-width char\n");
writeCharsAt({1,0}, {0x4000, 0x4000});
dump({0,0}, {6,1});
printf("\n");
writeCharsAt({2,0}, {0x4001});
dump({0,0}, {6,1});
printf("\n");
}
static void test2() {
// Like `test1`, but use a lower-level API to do the write. Consistency is
// preserved here too -- the first and last cells are replaced with spaces.
printf("test2 - overlap full-width char with full-width char (lowlevel)\n");
writeCharsAt({1,0}, {0x4000, 0x4000});
dump({0,0}, {6,1});
printf("\n");
set({2,0}, {ci(0x4001,0x107), ci(0x4001,0x207)});
dump({0,0}, {6,1});
printf("\n");
}
static void test3() {
// However, the lower-level API can break the LEADING/TRAILING invariant
// explicitly:
printf("test3 - explicitly violate LEADING/TRAILING using lowlevel API\n");
set({1,0}, {
ci(0x4000, 0x207),
ci(0x4001, 0x107),
ci(0x3044, 7),
ci(L'X', 0x107),
ci(L'X', 0x207),
});
dump({0,0}, {7,1});
}
static void test4() {
// It is possible for the two cells of a double-width character to have two
// colors.
printf("test4 - use lowlevel to assign two colors to one full-width char\n");
set({0,0}, {
ci(0x4000, 0x142),
ci(0x4000, 0x224),
});
dump({0,0}, {2,1});
}
static void test5() {
// WriteConsoleOutputAttribute doesn't seem to affect the LEADING/TRAILING
// flags.
printf("test5 - WriteConsoleOutputAttribute cannot affect LEADING/TRAILING\n");
// Trying to clear the flags doesn't work...
writeCharsAt({0,0}, {0x4000});
dump({0,0}, {2,1});
writeAttrsAt({0,0}, {0x42, 0x24});
printf("\n");
dump({0,0}, {2,1});
// ... and trying to add them also doesn't work.
writeCharsAt({0,1}, {'A', ' '});
writeAttrsAt({0,1}, {0x107, 0x207});
printf("\n");
dump({0,1}, {2,1});
}
static void test6() {
// The cursor position may be on either cell of a double-width character.
// Visually, the cursor appears under both cells, regardless of which
// specific one has the cursor.
printf("test6 - cursor can be either left or right cell of full-width char\n");
writeCharsAt({2,1}, {0x4000});
setCursorPos(2, 1);
auto pos1 = getCursorPos();
Sleep(1000);
setCursorPos(3, 1);
auto pos2 = getCursorPos();
Sleep(1000);
setCursorPos(0, 15);
printf("%d,%d\n", pos1.X, pos1.Y);
printf("%d,%d\n", pos2.X, pos2.Y);
}
static void runTest(void (&test)()) {
system("cls");
setCursorPos(0, 14);
test();
system("pause");
}
int main(int argc, char *argv[]) {
if (argc == 1) {
startChildProcess(L"CHILD");
return 0;
}
setWindowPos(0, 0, 1, 1);
setBufferSize(80, 40);
setWindowPos(0, 0, 80, 40);
auto cp = GetConsoleOutputCP();
assert(cp == 932 || cp == 936 || cp == 949 || cp == 950);
runTest(test1);
runTest(test2);
runTest(test3);
runTest(test4);
runTest(test5);
runTest(test6);
return 0;
}
@@ -0,0 +1,23 @@
(The MIT License)
Copyright (c) 2014 Jonathan Ong <me@jongleberry.com>
Copyright (c) 2015 Douglas Christopher Wilson <doug@somethingdoug.com>
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,5 @@
var convert = require('./convert'),
func = convert('take', require('../take'));
func.placeholder = require('./placeholder');
module.exports = func;
@@ -0,0 +1,15 @@
# Installation
> `npm install --save @types/http-errors`
# Summary
This package contains type definitions for http-errors (https://github.com/jshttp/http-errors).
# Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/http-errors.
### Additional Details
* Last updated: Sat, 07 Jun 2025 02:15:25 GMT
* Dependencies: none
# Credits
These definitions were written by [Tanguy Krotoff](https://github.com/tkrotoff), [BendingBender](https://github.com/BendingBender), and [Sebastian Beltran](https://github.com/bjohansebas).
@@ -0,0 +1 @@
{"version":3,"file":"eager.d.ts","sourceRoot":"","sources":["../../../src/types/path/eager.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AAC7C,OAAO,KAAK,EAAE,mBAAmB,EAAE,KAAK,EAAE,OAAO,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAE/E,OAAO,KAAK,EAAE,QAAQ,EAAE,OAAO,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAE7D;;;;GAIG;AACH,KAAK,UAAU,CAAC,EAAE,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE,GACnC,OAAO,CAAC,EAAE,EAAE,EAAE,CAAC,SAAS,IAAI,GAC1B,IAAI,GACJ,KAAK,GACP,KAAK,CAAC;AAEV;;;;;;GAMG;AACH,KAAK,QAAQ,CAAC,CAAC,SAAS,MAAM,GAAG,MAAM,EAAE,CAAC,EAAE,cAAc,IAAI,CAAC,SAC3D,SAAS,GACT,mBAAmB,GACnB,GAAG,CAAC,EAAE,GAIN,IAAI,SAAS,UAAU,CAAC,cAAc,EAAE,CAAC,CAAC,GACxC,GAAG,CAAC,EAAE,GACN,GAAG,CAAC,EAAE,GAAG,GAAG,CAAC,IAAI,YAAY,CAAC,CAAC,EAAE,cAAc,GAAG,CAAC,CAAC,EAAE,CAAC;AAE7D;;;;;GAKG;AACH,KAAK,YAAY,CAAC,CAAC,EAAE,cAAc,GAAG,CAAC,IACrC,CAAC,SAAS,aAAa,CAAC,MAAM,CAAC,CAAC,GAC5B,OAAO,CAAC,CAAC,CAAC,SAAS,IAAI,GACrB;KACG,CAAC,IAAI,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,QAAQ,CAAC,CAAC,GAAG,MAAM,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,cAAc,CAAC;CAClE,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,GACf,QAAQ,CAAC,QAAQ,EAAE,CAAC,EAAE,cAAc,CAAC,GACvC;KACG,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,QAAQ,CAAC,CAAC,GAAG,MAAM,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,cAAc,CAAC;CAC7D,CAAC,MAAM,CAAC,CAAC,CAAC;AAEjB;;;;;;;GAOG;AAGH,MAAM,MAAM,IAAI,CAAC,CAAC,IAAI,CAAC,SAAS,GAAG,GAAG,YAAY,CAAC,CAAC,CAAC,GAAG,KAAK,CAAC;AAE9D;;GAEG;AACH,MAAM,MAAM,SAAS,CAAC,YAAY,SAAS,WAAW,IAAI,IAAI,CAAC,YAAY,CAAC,CAAC;AAE7E;;;;;;GAMG;AACH,KAAK,aAAa,CAAC,CAAC,SAAS,MAAM,GAAG,MAAM,EAAE,CAAC,EAAE,cAAc,IAAI,CAAC,SAChE,SAAS,GACT,mBAAmB,GACnB,KAAK,CAAC,CAAC,CAAC,SAAS,IAAI,GACnB,MAAM,GACN,KAAK,GACP,CAAC,SAAS,aAAa,CAAC,MAAM,CAAC,CAAC,GAC9B,CAAC,SAAS,SAAS,GAAG,mBAAmB,GACvC,KAAK,CAAC,CAAC,CAAC,SAAS,IAAI,GACnB,MAAM,GACN,KAAK,GAIP,IAAI,SAAS,UAAU,CAAC,cAAc,EAAE,CAAC,CAAC,GACxC,KAAK,GACL,GAAG,CAAC,EAAE,GAAG,GAAG,CAAC,IAAI,iBAAiB,CAAC,CAAC,EAAE,cAAc,GAAG,CAAC,CAAC,EAAE,GAC/D,IAAI,SAAS,UAAU,CAAC,cAAc,EAAE,CAAC,CAAC,GACxC,KAAK,GACL,GAAG,CAAC,IAAI,iBAAiB,CAAC,CAAC,EAAE,cAAc,GAAG,CAAC,CAAC,EAAE,CAAC;AAE3D;;;;;GAKG;AACH,KAAK,iBAAiB,CAAC,CAAC,EAAE,cAAc,GAAG,CAAC,IAC1C,CAAC,SAAS,aAAa,CAAC,MAAM,CAAC,CAAC,GAC5B,OAAO,CAAC,CAAC,CAAC,SAAS,IAAI,GACrB;KACG,CAAC,IAAI,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,aAAa,CAClC,CAAC,GAAG,MAAM,EACV,CAAC,CAAC,CAAC,CAAC,EACJ,cAAc,CACf;CACF,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,GACf,aAAa,CAAC,QAAQ,EAAE,CAAC,EAAE,cAAc,CAAC,GAC5C;KACG,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,aAAa,CAAC,CAAC,GAAG,MAAM,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,cAAc,CAAC;CAClE,CAAC,MAAM,CAAC,CAAC,CAAC;AAEjB;;;;;;;;GAQG;AAGH,MAAM,MAAM,SAAS,CAAC,CAAC,IAAI,CAAC,SAAS,GAAG,GAAG,iBAAiB,CAAC,CAAC,CAAC,GAAG,KAAK,CAAC;AAExE;;GAEG;AACH,MAAM,MAAM,cAAc,CAAC,YAAY,SAAS,WAAW,IACzD,SAAS,CAAC,YAAY,CAAC,CAAC;AAE1B;;;;;;;;;GASG;AACH,MAAM,MAAM,SAAS,CAAC,CAAC,EAAE,CAAC,SAAS,IAAI,CAAC,CAAC,CAAC,GAAG,SAAS,CAAC,CAAC,CAAC,IAAI,aAAa,CACxE,CAAC,EACD,CAAC,CACF,CAAC;AAEF,KAAK,aAAa,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM,IAAI,CAAC,SAAS,GAAG,GACnD,CAAC,SAAS,GAAG,MAAM,CAAC,IAAI,MAAM,CAAC,EAAE,GAC/B,CAAC,SAAS,MAAM,CAAC,GACf,SAAS,SAAS,CAAC,CAAC,CAAC,CAAC,GACpB,aAAa,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,SAAS,GAClC,aAAa,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,GACxB,CAAC,SAAS,GAAG,QAAQ,EAAE,GACrB,CAAC,SAAS,aAAa,CAAC,MAAM,CAAC,CAAC,GAC9B,aAAa,CAAC,CAAC,EAAE,CAAC,CAAC,GACnB,KAAK,GACP,KAAK,GACT,CAAC,SAAS,MAAM,CAAC,GACf,CAAC,CAAC,CAAC,CAAC,GACJ,CAAC,SAAS,GAAG,QAAQ,EAAE,GACrB,CAAC,SAAS,aAAa,CAAC,MAAM,CAAC,CAAC,GAC9B,CAAC,GACD,SAAS,SAAS,CAAC,GACjB,SAAS,GACT,KAAK,GACT,KAAK,GACX,KAAK,CAAC;AAEV;;GAEG;AACH,MAAM,MAAM,cAAc,CACxB,YAAY,SAAS,WAAW,EAChC,UAAU,SAAS,SAAS,CAAC,YAAY,CAAC,IACxC,SAAS,CAAC,YAAY,EAAE,UAAU,CAAC,CAAC;AAExC;;GAEG;AACH,MAAM,MAAM,mBAAmB,CAC7B,YAAY,SAAS,WAAW,EAChC,eAAe,SAAS,cAAc,CAAC,YAAY,CAAC,IAClD,SAAS,CAAC,YAAY,EAAE,eAAe,CAAC,CAAC;AAE7C;;;;;;;;;GASG;AACH,MAAM,MAAM,eAAe,CACzB,YAAY,SAAS,WAAW,EAChC,KAAK,SAAS,SAAS,CAAC,YAAY,CAAC,EAAE,GAAG,SAAS,SAAS,CAAC,YAAY,CAAC,EAAE,IAC1E,EAAE,GAAG;KACN,CAAC,IAAI,MAAM,KAAK,GAAG,cAAc,CAChC,YAAY,EACZ,KAAK,CAAC,CAAC,CAAC,GAAG,SAAS,CAAC,YAAY,CAAC,CACnC;CACF,CAAC;AAEF;;;;;;;;;GASG;AACH,MAAM,MAAM,gBAAgB,CAAC,YAAY,SAAS,WAAW,EAAE,MAAM,IAAI;KACtE,GAAG,IAAI,SAAS,CAAC,YAAY,CAAC,GAAG,cAAc,CAC9C,YAAY,EACZ,GAAG,CACJ,SAAS,MAAM,GACZ,GAAG,GACH,KAAK;CACV,CAAC,SAAS,CAAC,YAAY,CAAC,CAAC,CAAC;AAE3B;;;;;;;;;GASG;AACH,MAAM,MAAM,qBAAqB,CAAC,YAAY,SAAS,WAAW,EAAE,MAAM,IAAI;KAC3E,GAAG,IAAI,cAAc,CAAC,YAAY,CAAC,GAAG,mBAAmB,CACxD,YAAY,EACZ,GAAG,CACJ,SAAS,MAAM,GACZ,GAAG,GACH,KAAK;CACV,CAAC,cAAc,CAAC,YAAY,CAAC,CAAC,CAAC"}
@@ -0,0 +1,76 @@
{
"name": "unist-util-position",
"version": "5.0.0",
"description": "unist utility to get the position of a node",
"license": "MIT",
"keywords": [
"unist",
"unist-util",
"util",
"utility",
"node",
"position",
"point"
],
"repository": "syntax-tree/unist-util-position",
"bugs": "https://github.com/syntax-tree/unist-util-position/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/unist": "^3.0.0"
},
"devDependencies": {
"@types/node": "^20.0.0",
"c8": "^8.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",
"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": "node --conditions development test.js",
"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,7 @@
import {
useMultiSelectState
} from "./chunk-TCDHLXYC.mjs";
import "./chunk-RVB7J7GX.mjs";
export {
useMultiSelectState
};
@@ -0,0 +1 @@
{"name":"globals","version":"14.0.0","requiresBuild":false,"files":{"license":{"checkedAt":1794532093291,"integrity":"sha512-0fM2/ycrxrltyaBKfQ748Ck23VlPUUBgNAR47ldf4B1V/HoXTfWBSk+vcshGKwEpmOynu4mOP5o+hyBfuRNa8g==","mode":420,"size":1117},"index.js":{"checkedAt":1794532093292,"integrity":"sha512-VhySceycwo/hJ/Ks8R38KJ5djKl0pXcuuD1p2k4/5mPZQlRB7dH8s5iBGqOLJw/hKJNqlz4jNu4Rxg1783OSLw==","mode":420,"size":58},"globals.json":{"checkedAt":1794532093292,"integrity":"sha512-T1pc4TIymB8dFQJL7S4mVft6qKu9h7vJ4bGn+YM49wDspPIEL+Ows1LOcErrh/lrGwuOhuI4tLqfo1DkuF6gMw==","mode":420,"size":47996},"package.json":{"checkedAt":1794532093292,"integrity":"sha512-VOTG67n3xKXxe3M2kFfMbZdjwMvEqh5Z5KnMve7GS+b3MY8UKfrDpm/uLBhNM4RrXHpHvlMrNL+n7F/2f4YpcA==","mode":420,"size":1165},"readme.md":{"checkedAt":1794532093292,"integrity":"sha512-LEG/U8A1nBMtxsbNjhWcb6P1Hia3j8Av5fXcCN1hE2dVbGTEaT0KW9pJ9rRRgQJp8fdPXKf3kF8HyJDhUGUwWg==","mode":420,"size":1662},"index.d.ts":{"checkedAt":1794532093292,"integrity":"sha512-WUGtF3wHJBW1OXUc33fus45s7ndykd5lEOwIYqZN5yB5Zab8FA04474v2MbD9NEBp37q2wQBB+c+YGmLoYPCTA==","mode":420,"size":65265}}}
@@ -0,0 +1,3 @@
declare function useIsMobile(): boolean;
export { useIsMobile };
@@ -0,0 +1,441 @@
import path from 'node:path';
import { promises as fs } from 'node:fs';
import { createRequire } from 'module';
import { find } from './find.js';
import { toJson } from './to-json.js';
import {
makePromise,
native2posix,
resolve2posix,
replaceTokens,
resolveReferencedTSConfigFiles,
resolveSolutionTSConfig,
resolveTSConfigJson
} from './util.js';
const not_found_result = {
tsconfigFile: null,
tsconfig: {}
};
/**
* parse the closest tsconfig.json file
*
* @param {string} filename - path to a tsconfig .json or a source file or directory (absolute or relative to cwd)
* @param {import('./public.d.ts').TSConfckParseOptions} [options] - options
* @returns {Promise<import('./public.d.ts').TSConfckParseResult>}
* @throws {TSConfckParseError}
*/
export async function parse(filename, options) {
/** @type {import('./cache.js').TSConfckCache} */
const cache = options?.cache;
if (cache?.hasParseResult(filename)) {
return getParsedDeep(filename, cache, options);
}
const {
resolve,
reject,
/** @type {Promise<import('./public.d.ts').TSConfckParseResult>}*/
promise
} = makePromise();
cache?.setParseResult(filename, promise, true);
try {
let tsconfigFile =
(await resolveTSConfigJson(filename, cache)) || (await find(filename, options));
if (!tsconfigFile) {
resolve(not_found_result);
return promise;
}
let result;
if (filename !== tsconfigFile && cache?.hasParseResult(tsconfigFile)) {
result = await getParsedDeep(tsconfigFile, cache, options);
} else {
result = await parseFile(tsconfigFile, cache, filename === tsconfigFile);
await Promise.all([parseExtends(result, cache), parseReferences(result, options)]);
}
replaceTokens(result);
resolve(resolveSolutionTSConfig(filename, result));
} catch (e) {
reject(e);
}
return promise;
}
/**
* ensure extends and references are parsed
*
* @param {string} filename - cached file
* @param {import('./cache.js').TSConfckCache} cache - cache
* @param {import('./public.d.ts').TSConfckParseOptions} options - options
*/
async function getParsedDeep(filename, cache, options) {
const result = await cache.getParseResult(filename);
if (
(result.tsconfig.extends && !result.extended) ||
(result.tsconfig.references && !result.referenced)
) {
const promise = Promise.all([
parseExtends(result, cache),
parseReferences(result, options)
]).then(() => result);
cache.setParseResult(filename, promise, true);
return promise;
}
return result;
}
/**
*
* @param {string} tsconfigFile - path to tsconfig file
* @param {import('./cache.js').TSConfckCache} [cache] - cache
* @param {boolean} [skipCache] - skip cache
* @returns {Promise<import('./public.d.ts').TSConfckParseResult>}
*/
async function parseFile(tsconfigFile, cache, skipCache) {
if (
!skipCache &&
cache?.hasParseResult(tsconfigFile) &&
!cache.getParseResult(tsconfigFile)._isRootFile_
) {
return cache.getParseResult(tsconfigFile);
}
const promise = fs
.readFile(tsconfigFile, 'utf-8')
.then(toJson)
.then((json) => {
const parsed = JSON.parse(json);
applyDefaults(parsed, tsconfigFile);
return {
tsconfigFile,
tsconfig: normalizeTSConfig(parsed, path.dirname(tsconfigFile))
};
})
.catch((e) => {
throw new TSConfckParseError(
`parsing ${tsconfigFile} failed: ${e}`,
'PARSE_FILE',
tsconfigFile,
e
);
});
if (
!skipCache &&
(!cache?.hasParseResult(tsconfigFile) || !cache.getParseResult(tsconfigFile)._isRootFile_)
) {
cache?.setParseResult(tsconfigFile, promise);
}
return promise;
}
/**
* normalize to match the output of ts.parseJsonConfigFileContent
*
* @param {any} tsconfig - typescript tsconfig output
* @param {string} dir - directory
*/
function normalizeTSConfig(tsconfig, dir) {
// set baseUrl to absolute path
const baseUrl = tsconfig.compilerOptions?.baseUrl;
if (baseUrl && !baseUrl.startsWith('${') && !path.isAbsolute(baseUrl)) {
tsconfig.compilerOptions.baseUrl = resolve2posix(dir, baseUrl);
}
return tsconfig;
}
/**
*
* @param {import('./public.d.ts').TSConfckParseResult} result
* @param {import('./public.d.ts').TSConfckParseOptions} [options]
* @returns {Promise<void>}
*/
async function parseReferences(result, options) {
if (!result.tsconfig.references) {
return;
}
const referencedFiles = resolveReferencedTSConfigFiles(result, options);
const referenced = await Promise.all(
referencedFiles.map((file) => parseFile(file, options?.cache))
);
await Promise.all(referenced.map((ref) => parseExtends(ref, options?.cache)));
referenced.forEach((ref) => {
ref.solution = result;
replaceTokens(ref);
});
result.referenced = referenced;
}
/**
* @param {import('./public.d.ts').TSConfckParseResult} result
* @param {import('./cache.js').TSConfckCache}[cache]
* @returns {Promise<void>}
*/
async function parseExtends(result, cache) {
if (!result.tsconfig.extends) {
return;
}
// use result as first element in extended
// but dereference tsconfig so that mergeExtended can modify the original without affecting extended[0]
/** @type {import('./public.d.ts').TSConfckParseResult[]} */
const extended = [
{ tsconfigFile: result.tsconfigFile, tsconfig: JSON.parse(JSON.stringify(result.tsconfig)) }
];
// flatten extends graph into extended
let pos = 0;
/** @type {string[]} */
const extendsPath = [];
let currentBranchDepth = 0;
while (pos < extended.length) {
const extending = extended[pos];
extendsPath.push(extending.tsconfigFile);
if (extending.tsconfig.extends) {
// keep following this branch
currentBranchDepth += 1;
/** @type {string[]} */
let resolvedExtends;
if (!Array.isArray(extending.tsconfig.extends)) {
resolvedExtends = [resolveExtends(extending.tsconfig.extends, extending.tsconfigFile)];
} else {
// reverse because typescript 5.0 treats ['a','b','c'] as c extends b extends a
resolvedExtends = extending.tsconfig.extends
.reverse()
.map((ex) => resolveExtends(ex, extending.tsconfigFile));
}
const circularExtends = resolvedExtends.find((tsconfigFile) =>
extendsPath.includes(tsconfigFile)
);
if (circularExtends) {
const circle = extendsPath.concat([circularExtends]).join(' -> ');
throw new TSConfckParseError(
`Circular dependency in "extends": ${circle}`,
'EXTENDS_CIRCULAR',
result.tsconfigFile
);
}
// add new extends to the list directly after current
extended.splice(
pos + 1,
0,
...(await Promise.all(resolvedExtends.map((file) => parseFile(file, cache))))
);
} else {
// reached a leaf, backtrack to the last branching point and continue
extendsPath.splice(-currentBranchDepth);
currentBranchDepth = 0;
}
pos = pos + 1;
}
result.extended = extended;
// skip first as it is the original config
for (const ext of result.extended.slice(1)) {
extendTSConfig(result, ext);
}
}
/**
*
* @param {string} extended
* @param {string} from
* @returns {string}
*/
function resolveExtends(extended, from) {
// see #149 and #220
if (['.', '..'].includes(extended)) {
extended = extended + '/tsconfig.json';
}
const req = createRequire(from);
let error;
try {
return req.resolve(extended);
} catch (e) {
error = e;
}
if (extended[0] !== '.' && !path.isAbsolute(extended)) {
try {
return req.resolve(`${extended}/tsconfig.json`);
} catch (e) {
error = e;
}
}
throw new TSConfckParseError(
`failed to resolve "extends":"${extended}" in ${from}`,
'EXTENDS_RESOLVE',
from,
error
);
}
// references, extends and custom keys are not carried over
const EXTENDABLE_KEYS = [
'compilerOptions',
'files',
'include',
'exclude',
'watchOptions',
'compileOnSave',
'typeAcquisition',
'buildOptions'
];
/**
*
* @param {import('./public.d.ts').TSConfckParseResult} extending
* @param {import('./public.d.ts').TSConfckParseResult} extended
* @returns void
*/
function extendTSConfig(extending, extended) {
const extendingConfig = extending.tsconfig;
const extendedConfig = extended.tsconfig;
const relativePath = native2posix(
path.relative(path.dirname(extending.tsconfigFile), path.dirname(extended.tsconfigFile))
);
for (const key of Object.keys(extendedConfig).filter((key) => EXTENDABLE_KEYS.includes(key))) {
if (key === 'compilerOptions') {
if (!extendingConfig.compilerOptions) {
extendingConfig.compilerOptions = {};
}
for (const option of Object.keys(extendedConfig.compilerOptions)) {
if (Object.prototype.hasOwnProperty.call(extendingConfig.compilerOptions, option)) {
continue; // already set
}
extendingConfig.compilerOptions[option] = rebaseRelative(
option,
extendedConfig.compilerOptions[option],
relativePath
);
}
} else if (extendingConfig[key] === undefined) {
if (key === 'watchOptions') {
extendingConfig.watchOptions = {};
for (const option of Object.keys(extendedConfig.watchOptions)) {
extendingConfig.watchOptions[option] = rebaseRelative(
option,
extendedConfig.watchOptions[option],
relativePath
);
}
} else {
extendingConfig[key] = rebaseRelative(key, extendedConfig[key], relativePath);
}
}
}
}
const REBASE_KEYS = [
// root
'files',
'include',
'exclude',
// compilerOptions
'baseUrl',
'rootDir',
'rootDirs',
'typeRoots',
'outDir',
'outFile',
'declarationDir',
// watchOptions
'excludeDirectories',
'excludeFiles'
];
/** @typedef {string | string[]} PathValue */
/**
*
* @param {string} key
* @param {PathValue} value
* @param {string} prependPath
* @returns {PathValue}
*/
function rebaseRelative(key, value, prependPath) {
if (!REBASE_KEYS.includes(key)) {
return value;
}
if (Array.isArray(value)) {
return value.map((x) => rebasePath(x, prependPath));
} else {
return rebasePath(value, prependPath);
}
}
/**
*
* @param {string} value
* @param {string} prependPath
* @returns {string}
*/
function rebasePath(value, prependPath) {
if (path.isAbsolute(value) || value.startsWith('${configDir}')) {
return value;
} else {
// relative paths use posix syntax in tsconfig
return path.posix.normalize(path.posix.join(prependPath, value));
}
}
export class TSConfckParseError extends Error {
/**
* error code
* @type {string}
*/
code;
/**
* error cause
* @type { Error | undefined}
*/
cause;
/**
* absolute path of tsconfig file where the error happened
* @type {string}
*/
tsconfigFile;
/**
*
* @param {string} message - error message
* @param {string} code - error code
* @param {string} tsconfigFile - path to tsconfig file
* @param {Error?} cause - cause of this error
*/
constructor(message, code, tsconfigFile, cause) {
super(message);
// Set the prototype explicitly.
Object.setPrototypeOf(this, TSConfckParseError.prototype);
this.name = TSConfckParseError.name;
this.code = code;
this.cause = cause;
this.tsconfigFile = tsconfigFile;
}
}
/**
*
* @param {any} tsconfig
* @param {string} tsconfigFile
*/
function applyDefaults(tsconfig, tsconfigFile) {
if (isJSConfig(tsconfigFile)) {
tsconfig.compilerOptions = {
...DEFAULT_JSCONFIG_COMPILER_OPTIONS,
...tsconfig.compilerOptions
};
}
}
const DEFAULT_JSCONFIG_COMPILER_OPTIONS = {
allowJs: true,
maxNodeModuleJsDepth: 2,
allowSyntheticDefaultImports: true,
skipLibCheck: true,
noEmit: true
};
/**
* @param {string} configFileName
*/
function isJSConfig(configFileName) {
return path.basename(configFileName) === 'jsconfig.json';
}
@@ -0,0 +1,80 @@
/**
* ```asn1
* id-pkix OBJECT IDENTIFIER ::=
* { iso(1) identified-organization(3) dod(6) internet(1)
* security(5) mechanisms(5) pkix(7) }
* ```
*/
export declare const id_pkix = "1.3.6.1.5.5.7";
/**
* ```asn1
* id-pe OBJECT IDENTIFIER ::= { id-pkix 1 }
* -- arc for private certificate extensions
* ```
*/
export declare const id_pe = "1.3.6.1.5.5.7.1";
/**
* ```asn1
* id-qt OBJECT IDENTIFIER ::= { id-pkix 2 }
* -- arc for policy qualifier types
* ```
*/
export declare const id_qt = "1.3.6.1.5.5.7.2";
/**
* ```asn1
* id-kp OBJECT IDENTIFIER ::= { id-pkix 3 }
* -- arc for extended key purpose OIDS
* ```
*/
export declare const id_kp = "1.3.6.1.5.5.7.3";
/**
* ```asn1
* id-ad OBJECT IDENTIFIER ::= { id-pkix 48 }
* -- arc for access descriptors
* ```
*/
export declare const id_ad = "1.3.6.1.5.5.7.48";
/**
* ```asn1
* id-qt-cps OBJECT IDENTIFIER ::= { id-qt 1 }
* -- OID for CPS qualifier
* ```
*/
export declare const id_qt_csp = "1.3.6.1.5.5.7.2.1";
/**
* ```asn1
* id-qt-unotice OBJECT IDENTIFIER ::= { id-qt 2 }
* -- OID for user notice qualifier
* ```
*/
export declare const id_qt_unotice = "1.3.6.1.5.5.7.2.2";
/**
* ```asn1
* id-ad-ocsp OBJECT IDENTIFIER ::= { id-ad 1 }
* ```
*/
export declare const id_ad_ocsp = "1.3.6.1.5.5.7.48.1";
/**
* ```asn1
* id-ad-caIssuers OBJECT IDENTIFIER ::= { id-ad 2 }
* ```
*/
export declare const id_ad_caIssuers = "1.3.6.1.5.5.7.48.2";
/**
* ```asn1
* id-ad-timeStamping OBJECT IDENTIFIER ::= { id-ad 3 }
* ```
*/
export declare const id_ad_timeStamping = "1.3.6.1.5.5.7.48.3";
/**
* ```asn1
* id-ad-caRepository OBJECT IDENTIFIER ::= { id-ad 5 }
* ```
*/
export declare const id_ad_caRepository = "1.3.6.1.5.5.7.48.5";
/**
* ```asn1
* id-ce OBJECT IDENTIFIER ::= {joint-iso-ccitt(2) ds(5) 29}
* ```
*/
export declare const id_ce = "2.5.29";
@@ -0,0 +1,56 @@
{
"name": "@heroui/use-update-effect",
"version": "2.1.2",
"description": "React effect hook that invokes only on update",
"keywords": [
"use-update-effect"
],
"author": "Junior Garcia <jrgarciadev@gmail.com>",
"homepage": "https://heroui.com",
"license": "MIT",
"main": "dist/index.js",
"sideEffects": false,
"files": [
"dist"
],
"publishConfig": {
"access": "public"
},
"repository": {
"type": "git",
"url": "git+https://github.com/heroui-inc/heroui.git",
"directory": "packages/hooks/use-update-effect"
},
"bugs": {
"url": "https://github.com/heroui-inc/heroui/issues"
},
"peerDependencies": {
"react": ">=18 || >=19.0.0-rc.0"
},
"clean-package": "../../../clean-package.config.json",
"tsup": {
"clean": true,
"target": "es2019",
"format": [
"cjs",
"esm"
]
},
"module": "dist/index.mjs",
"types": "dist/index.d.ts",
"exports": {
".": {
"types": "./dist/index.d.ts",
"import": "./dist/index.mjs",
"require": "./dist/index.js"
},
"./package.json": "./package.json"
},
"scripts": {
"build": "tsup src --dts",
"build:fast": "tsup src",
"dev": "pnpm build:fast --watch",
"clean": "rimraf dist .turbo",
"typecheck": "tsc --noEmit"
}
}
@@ -0,0 +1,29 @@
import eq from './eq.js';
/** Used for built-in method references. */
var objectProto = Object.prototype;
/** Used to check objects for own properties. */
var hasOwnProperty = objectProto.hasOwnProperty;
/**
* Used by `_.defaults` to customize its `_.assignIn` use to assign properties
* of source objects to the destination object for all destination properties
* that resolve to `undefined`.
*
* @private
* @param {*} objValue The destination value.
* @param {*} srcValue The source value.
* @param {string} key The key of the property to assign.
* @param {Object} object The parent object of `objValue`.
* @returns {*} Returns the value to assign.
*/
function customDefaultsAssignIn(objValue, srcValue, key, object) {
if (objValue === undefined ||
(eq(objValue, objectProto[key]) && !hasOwnProperty.call(object, key))) {
return srcValue;
}
return objValue;
}
export default customDefaultsAssignIn;
@@ -0,0 +1,4 @@
export declare function parse(): void;
export * from './types';
export declare const _Parser: undefined;
export { isStructurallySame } from './manipulator';
@@ -0,0 +1,13 @@
import {
user
} from "../chunk-ETLZPM2W.mjs";
import "../chunk-CWYZ2GEH.mjs";
import "../chunk-GQT3YUX3.mjs";
import "../chunk-46U6G7UJ.mjs";
import "../chunk-DGTYPKBN.mjs";
import "../chunk-UWE6H66T.mjs";
import "../chunk-GIXI35A3.mjs";
import "../chunk-GH5E4FQB.mjs";
export {
user
};
@@ -0,0 +1,74 @@
// Copyright 2013 Google Inc. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// 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 CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Block split point selection utilities.
#ifndef BROTLI_ENC_BLOCK_SPLITTER_H_
#define BROTLI_ENC_BLOCK_SPLITTER_H_
#include <stddef.h>
#include <stdint.h>
#include <string.h>
#include <vector>
#include <utility>
#include "./command.h"
#include "./metablock.h"
namespace brotli {
struct BlockSplitIterator {
explicit BlockSplitIterator(const BlockSplit& split)
: split_(split), idx_(0), type_(0), length_(0) {
if (!split.lengths.empty()) {
length_ = split.lengths[0];
}
}
void Next() {
if (length_ == 0) {
++idx_;
type_ = split_.types[idx_];
length_ = split_.lengths[idx_];
}
--length_;
}
const BlockSplit& split_;
int idx_;
int type_;
int length_;
};
void CopyLiteralsToByteArray(const Command* cmds,
const size_t num_commands,
const uint8_t* data,
std::vector<uint8_t>* literals);
void SplitBlock(const Command* cmds,
const size_t num_commands,
const uint8_t* data,
BlockSplit* literal_split,
BlockSplit* insert_and_copy_split,
BlockSplit* dist_split);
void SplitBlockByTotalLength(const Command* all_commands,
const size_t num_commands,
int input_size,
int target_length,
std::vector<std::vector<Command> >* blocks);
} // namespace brotli
#endif // BROTLI_ENC_BLOCK_SPLITTER_H_
@@ -0,0 +1,54 @@
{
"name": "vite-plugin-cp",
"version": "6.0.3",
"description": "A powerful Vite plugin for copying files/directories with advanced transformation and renaming capabilities.",
"types": "./dist/index.d.ts",
"module": "./dist/index.mjs",
"main": "./dist/index.js",
"exports": {
".": {
"types": "./dist/index.d.ts",
"import": "./dist/index.mjs",
"require": "./dist/index.js"
}
},
"engines": {
"node": ">=14.18.0",
"vite": ">=3.1.0"
},
"repository": {
"type": "git",
"url": "git+https://github.com/fengxinming/vite-plugins.git",
"directory": "packages/vite-plugin-cp"
},
"keywords": [
"vite",
"vite-plugin",
"vite-plugin-cp"
],
"author": "Jesse Feng <fxm0016@126.com>",
"license": "MIT",
"bugs": {
"url": "https://github.com/fengxinming/vite-plugins/issues"
},
"homepage": "https://fengxinming.github.io/vite-plugins/plugins/vite-plugin-cp/quick-start",
"dependencies": {
"fs-extra": "^11.3.0",
"is-what-type": "^1.0.0",
"tinyglobby": "^0.2.12",
"vp-runtime-helper": "^1.0.9"
},
"devDependencies": {
"@rollup/plugin-typescript": "^12.1.2",
"@types/fs-extra": "^11.0.4",
"vite": "^6.1.0"
},
"files": [
"dist"
],
"scripts": {
"build:lib": "vite build",
"watch": "vite build --watch",
"release": "pnpm publish --no-git-checks"
}
}
@@ -0,0 +1,15 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = _toArray;
var _arrayWithHoles = require("./arrayWithHoles.js");
var _iterableToArray = require("./iterableToArray.js");
var _unsupportedIterableToArray = require("./unsupportedIterableToArray.js");
var _nonIterableRest = require("./nonIterableRest.js");
function _toArray(arr) {
return (0, _arrayWithHoles.default)(arr) || (0, _iterableToArray.default)(arr) || (0, _unsupportedIterableToArray.default)(arr) || (0, _nonIterableRest.default)();
}
//# sourceMappingURL=toArray.js.map
@@ -0,0 +1,91 @@
import { CreateType } from '../create/type.mjs';
import { TypeBoxError } from '../error/index.mjs';
import { Computed } from '../computed/index.mjs';
import { Never } from '../never/index.mjs';
import { IntersectEvaluated } from '../intersect/index.mjs';
import { UnionEvaluated } from '../union/index.mjs';
import { IndexPropertyKeys } from './indexed-property-keys.mjs';
import { IndexFromMappedKey } from './indexed-from-mapped-key.mjs';
import { IndexFromMappedResult } from './indexed-from-mapped-result.mjs';
// ------------------------------------------------------------------
// TypeGuard
// ------------------------------------------------------------------
import { IsArray, IsIntersect, IsObject, IsMappedKey, IsMappedResult, IsNever, IsSchema, IsTuple, IsUnion, IsRef } from '../guard/kind.mjs';
// prettier-ignore
function FromRest(types, key) {
return types.map(type => IndexFromPropertyKey(type, key));
}
// prettier-ignore
function FromIntersectRest(types) {
return types.filter(type => !IsNever(type));
}
// prettier-ignore
function FromIntersect(types, key) {
return (IntersectEvaluated(FromIntersectRest(FromRest(types, key))));
}
// prettier-ignore
function FromUnionRest(types) {
return (types.some(L => IsNever(L))
? []
: types);
}
// prettier-ignore
function FromUnion(types, key) {
return (UnionEvaluated(FromUnionRest(FromRest(types, key))));
}
// prettier-ignore
function FromTuple(types, key) {
return (key in types ? types[key] :
key === '[number]' ? UnionEvaluated(types) :
Never());
}
// prettier-ignore
function FromArray(type, key) {
return (key === '[number]'
? type
: Never());
}
// prettier-ignore
function FromProperty(properties, propertyKey) {
return (propertyKey in properties ? properties[propertyKey] : Never());
}
// prettier-ignore
export function IndexFromPropertyKey(type, propertyKey) {
return (IsIntersect(type) ? FromIntersect(type.allOf, propertyKey) :
IsUnion(type) ? FromUnion(type.anyOf, propertyKey) :
IsTuple(type) ? FromTuple(type.items ?? [], propertyKey) :
IsArray(type) ? FromArray(type.items, propertyKey) :
IsObject(type) ? FromProperty(type.properties, propertyKey) :
Never());
}
// prettier-ignore
export function IndexFromPropertyKeys(type, propertyKeys) {
return propertyKeys.map(propertyKey => IndexFromPropertyKey(type, propertyKey));
}
// prettier-ignore
function FromSchema(type, propertyKeys) {
return (UnionEvaluated(IndexFromPropertyKeys(type, propertyKeys)));
}
// prettier-ignore
export function IndexFromComputed(type, key) {
return Computed('Index', [type, key]);
}
/** `[Json]` Returns an Indexed property type for the given keys */
export function Index(type, key, options) {
// computed-type
if (IsRef(type) || IsRef(key)) {
const error = `Index types using Ref parameters require both Type and Key to be of TSchema`;
if (!IsSchema(type) || !IsSchema(key))
throw new TypeBoxError(error);
return Computed('Index', [type, key]);
}
// mapped-types
if (IsMappedResult(key))
return IndexFromMappedResult(type, key, options);
if (IsMappedKey(key))
return IndexFromMappedKey(type, key, options);
// prettier-ignore
return CreateType(IsSchema(key)
? FromSchema(type, IndexPropertyKeys(key))
: FromSchema(type, key), options);
}
@@ -0,0 +1,891 @@
// Type definitions for commander
// Original definitions by: Alan Agius <https://github.com/alan-agius4>, Marcelo Dezem <https://github.com/mdezem>, vvakame <https://github.com/vvakame>, Jules Randolph <https://github.com/sveinburne>
// Using method rather than property for method-signature-style, to document method overloads separately. Allow either.
/* eslint-disable @typescript-eslint/method-signature-style */
/* eslint-disable @typescript-eslint/no-explicit-any */
export class CommanderError extends Error {
code: string;
exitCode: number;
message: string;
nestedError?: string;
/**
* Constructs the CommanderError class
* @param exitCode - suggested exit code which could be used with process.exit
* @param code - an id string representing the error
* @param message - human-readable description of the error
* @constructor
*/
constructor(exitCode: number, code: string, message: string);
}
export class InvalidArgumentError extends CommanderError {
/**
* Constructs the InvalidArgumentError class
* @param message - explanation of why argument is invalid
* @constructor
*/
constructor(message: string);
}
export { InvalidArgumentError as InvalidOptionArgumentError }; // deprecated old name
export interface ErrorOptions { // optional parameter for error()
/** an id string representing the error */
code?: string;
/** suggested exit code which could be used with process.exit */
exitCode?: number;
}
export class Argument {
description: string;
required: boolean;
variadic: boolean;
/**
* Initialize a new command argument with the given name and description.
* The default is that the argument is required, and you can explicitly
* indicate this with <> around the name. Put [] around the name for an optional argument.
*/
constructor(arg: string, description?: string);
/**
* Return argument name.
*/
name(): string;
/**
* Set the default value, and optionally supply the description to be displayed in the help.
*/
default(value: unknown, description?: string): this;
/**
* Set the custom handler for processing CLI command arguments into argument values.
*/
argParser<T>(fn: (value: string, previous: T) => T): this;
/**
* Only allow argument value to be one of choices.
*/
choices(values: readonly string[]): this;
/**
* Make argument required.
*/
argRequired(): this;
/**
* Make argument optional.
*/
argOptional(): this;
}
export class Option {
flags: string;
description: string;
required: boolean; // A value must be supplied when the option is specified.
optional: boolean; // A value is optional when the option is specified.
variadic: boolean;
mandatory: boolean; // The option must have a value after parsing, which usually means it must be specified on command line.
optionFlags: string;
short?: string;
long?: string;
negate: boolean;
defaultValue?: any;
defaultValueDescription?: string;
parseArg?: <T>(value: string, previous: T) => T;
hidden: boolean;
argChoices?: string[];
constructor(flags: string, description?: string);
/**
* Set the default value, and optionally supply the description to be displayed in the help.
*/
default(value: unknown, description?: string): this;
/**
* Preset to use when option used without option-argument, especially optional but also boolean and negated.
* The custom processing (parseArg) is called.
*
* @example
* ```ts
* new Option('--color').default('GREYSCALE').preset('RGB');
* new Option('--donate [amount]').preset('20').argParser(parseFloat);
* ```
*/
preset(arg: unknown): this;
/**
* Add option name(s) that conflict with this option.
* An error will be displayed if conflicting options are found during parsing.
*
* @example
* ```ts
* new Option('--rgb').conflicts('cmyk');
* new Option('--js').conflicts(['ts', 'jsx']);
* ```
*/
conflicts(names: string | string[]): this;
/**
* Specify implied option values for when this option is set and the implied options are not.
*
* The custom processing (parseArg) is not called on the implied values.
*
* @example
* program
* .addOption(new Option('--log', 'write logging information to file'))
* .addOption(new Option('--trace', 'log extra details').implies({ log: 'trace.txt' }));
*/
implies(optionValues: OptionValues): this;
/**
* Set environment variable to check for option value.
*
* An environment variables is only used if when processed the current option value is
* undefined, or the source of the current value is 'default' or 'config' or 'env'.
*/
env(name: string): this;
/**
* Calculate the full description, including defaultValue etc.
*/
fullDescription(): string;
/**
* Set the custom handler for processing CLI option arguments into option values.
*/
argParser<T>(fn: (value: string, previous: T) => T): this;
/**
* Whether the option is mandatory and must have a value after parsing.
*/
makeOptionMandatory(mandatory?: boolean): this;
/**
* Hide option in help.
*/
hideHelp(hide?: boolean): this;
/**
* Only allow option value to be one of choices.
*/
choices(values: readonly string[]): this;
/**
* Return option name.
*/
name(): string;
/**
* Return option name, in a camelcase format that can be used
* as a object attribute key.
*/
attributeName(): string;
/**
* Return whether a boolean option.
*
* Options are one of boolean, negated, required argument, or optional argument.
*/
isBoolean(): boolean;
}
export class Help {
/** output helpWidth, long lines are wrapped to fit */
helpWidth?: number;
sortSubcommands: boolean;
sortOptions: boolean;
showGlobalOptions: boolean;
constructor();
/** Get the command term to show in the list of subcommands. */
subcommandTerm(cmd: Command): string;
/** Get the command summary to show in the list of subcommands. */
subcommandDescription(cmd: Command): string;
/** Get the option term to show in the list of options. */
optionTerm(option: Option): string;
/** Get the option description to show in the list of options. */
optionDescription(option: Option): string;
/** Get the argument term to show in the list of arguments. */
argumentTerm(argument: Argument): string;
/** Get the argument description to show in the list of arguments. */
argumentDescription(argument: Argument): string;
/** Get the command usage to be displayed at the top of the built-in help. */
commandUsage(cmd: Command): string;
/** Get the description for the command. */
commandDescription(cmd: Command): string;
/** Get an array of the visible subcommands. Includes a placeholder for the implicit help command, if there is one. */
visibleCommands(cmd: Command): Command[];
/** Get an array of the visible options. Includes a placeholder for the implicit help option, if there is one. */
visibleOptions(cmd: Command): Option[];
/** Get an array of the visible global options. (Not including help.) */
visibleGlobalOptions(cmd: Command): Option[];
/** Get an array of the arguments which have descriptions. */
visibleArguments(cmd: Command): Argument[];
/** Get the longest command term length. */
longestSubcommandTermLength(cmd: Command, helper: Help): number;
/** Get the longest option term length. */
longestOptionTermLength(cmd: Command, helper: Help): number;
/** Get the longest global option term length. */
longestGlobalOptionTermLength(cmd: Command, helper: Help): number;
/** Get the longest argument term length. */
longestArgumentTermLength(cmd: Command, helper: Help): number;
/** Calculate the pad width from the maximum term length. */
padWidth(cmd: Command, helper: Help): number;
/**
* Wrap the given string to width characters per line, with lines after the first indented.
* Do not wrap if insufficient room for wrapping (minColumnWidth), or string is manually formatted.
*/
wrap(str: string, width: number, indent: number, minColumnWidth?: number): string;
/** Generate the built-in help text. */
formatHelp(cmd: Command, helper: Help): string;
}
export type HelpConfiguration = Partial<Help>;
export interface ParseOptions {
from: 'node' | 'electron' | 'user';
}
export interface HelpContext { // optional parameter for .help() and .outputHelp()
error: boolean;
}
export interface AddHelpTextContext { // passed to text function used with .addHelpText()
error: boolean;
command: Command;
}
export interface OutputConfiguration {
writeOut?(str: string): void;
writeErr?(str: string): void;
getOutHelpWidth?(): number;
getErrHelpWidth?(): number;
outputError?(str: string, write: (str: string) => void): void;
}
export type AddHelpTextPosition = 'beforeAll' | 'before' | 'after' | 'afterAll';
export type HookEvent = 'preSubcommand' | 'preAction' | 'postAction';
export type OptionValueSource = 'default' | 'config' | 'env' | 'cli' | 'implied';
export interface OptionValues {
[key: string]: any;
}
export class Command {
args: string[];
processedArgs: any[];
commands: Command[];
parent: Command | null;
constructor(name?: string);
/**
* Set the program version to `str`.
*
* This method auto-registers the "-V, --version" flag
* which will print the version number when passed.
*
* You can optionally supply the flags and description to override the defaults.
*/
version(str: string, flags?: string, description?: string): this;
/**
* Define a command, implemented using an action handler.
*
* @remarks
* The command description is supplied using `.description`, not as a parameter to `.command`.
*
* @example
* ```ts
* program
* .command('clone <source> [destination]')
* .description('clone a repository into a newly created directory')
* .action((source, destination) => {
* console.log('clone command called');
* });
* ```
*
* @param nameAndArgs - command name and arguments, args are `<required>` or `[optional]` and last may also be `variadic...`
* @param opts - configuration options
* @returns new command
*/
command(nameAndArgs: string, opts?: CommandOptions): ReturnType<this['createCommand']>;
/**
* Define a command, implemented in a separate executable file.
*
* @remarks
* The command description is supplied as the second parameter to `.command`.
*
* @example
* ```ts
* program
* .command('start <service>', 'start named service')
* .command('stop [service]', 'stop named service, or all if no name supplied');
* ```
*
* @param nameAndArgs - command name and arguments, args are `<required>` or `[optional]` and last may also be `variadic...`
* @param description - description of executable command
* @param opts - configuration options
* @returns `this` command for chaining
*/
command(nameAndArgs: string, description: string, opts?: ExecutableCommandOptions): this;
/**
* Factory routine to create a new unattached command.
*
* See .command() for creating an attached subcommand, which uses this routine to
* create the command. You can override createCommand to customise subcommands.
*/
createCommand(name?: string): Command;
/**
* Add a prepared subcommand.
*
* See .command() for creating an attached subcommand which inherits settings from its parent.
*
* @returns `this` command for chaining
*/
addCommand(cmd: Command, opts?: CommandOptions): this;
/**
* Factory routine to create a new unattached argument.
*
* See .argument() for creating an attached argument, which uses this routine to
* create the argument. You can override createArgument to return a custom argument.
*/
createArgument(name: string, description?: string): Argument;
/**
* Define argument syntax for command.
*
* The default is that the argument is required, and you can explicitly
* indicate this with <> around the name. Put [] around the name for an optional argument.
*
* @example
* ```
* program.argument('<input-file>');
* program.argument('[output-file]');
* ```
*
* @returns `this` command for chaining
*/
argument<T>(flags: string, description: string, fn: (value: string, previous: T) => T, defaultValue?: T): this;
argument(name: string, description?: string, defaultValue?: unknown): this;
/**
* Define argument syntax for command, adding a prepared argument.
*
* @returns `this` command for chaining
*/
addArgument(arg: Argument): this;
/**
* Define argument syntax for command, adding multiple at once (without descriptions).
*
* See also .argument().
*
* @example
* ```
* program.arguments('<cmd> [env]');
* ```
*
* @returns `this` command for chaining
*/
arguments(names: string): this;
/**
* Override default decision whether to add implicit help command.
*
* @example
* ```
* addHelpCommand() // force on
* addHelpCommand(false); // force off
* addHelpCommand('help [cmd]', 'display help for [cmd]'); // force on with custom details
* ```
*
* @returns `this` command for chaining
*/
addHelpCommand(enableOrNameAndArgs?: string | boolean, description?: string): this;
/**
* Add hook for life cycle event.
*/
hook(event: HookEvent, listener: (thisCommand: Command, actionCommand: Command) => void | Promise<void>): this;
/**
* Register callback to use as replacement for calling process.exit.
*/
exitOverride(callback?: (err: CommanderError) => never | void): this;
/**
* Display error message and exit (or call exitOverride).
*/
error(message: string, errorOptions?: ErrorOptions): never;
/**
* You can customise the help with a subclass of Help by overriding createHelp,
* or by overriding Help properties using configureHelp().
*/
createHelp(): Help;
/**
* You can customise the help by overriding Help properties using configureHelp(),
* or with a subclass of Help by overriding createHelp().
*/
configureHelp(configuration: HelpConfiguration): this;
/** Get configuration */
configureHelp(): HelpConfiguration;
/**
* The default output goes to stdout and stderr. You can customise this for special
* applications. You can also customise the display of errors by overriding outputError.
*
* The configuration properties are all functions:
* ```
* // functions to change where being written, stdout and stderr
* writeOut(str)
* writeErr(str)
* // matching functions to specify width for wrapping help
* getOutHelpWidth()
* getErrHelpWidth()
* // functions based on what is being written out
* outputError(str, write) // used for displaying errors, and not used for displaying help
* ```
*/
configureOutput(configuration: OutputConfiguration): this;
/** Get configuration */
configureOutput(): OutputConfiguration;
/**
* Copy settings that are useful to have in common across root command and subcommands.
*
* (Used internally when adding a command using `.command()` so subcommands inherit parent settings.)
*/
copyInheritedSettings(sourceCommand: Command): this;
/**
* Display the help or a custom message after an error occurs.
*/
showHelpAfterError(displayHelp?: boolean | string): this;
/**
* Display suggestion of similar commands for unknown commands, or options for unknown options.
*/
showSuggestionAfterError(displaySuggestion?: boolean): this;
/**
* Register callback `fn` for the command.
*
* @example
* ```
* program
* .command('serve')
* .description('start service')
* .action(function() {
* // do work here
* });
* ```
*
* @returns `this` command for chaining
*/
action(fn: (...args: any[]) => void | Promise<void>): this;
/**
* Define option with `flags`, `description` and optional
* coercion `fn`.
*
* The `flags` string contains the short and/or long flags,
* separated by comma, a pipe or space. The following are all valid
* all will output this way when `--help` is used.
*
* "-p, --pepper"
* "-p|--pepper"
* "-p --pepper"
*
* @example
* ```
* // simple boolean defaulting to false
* program.option('-p, --pepper', 'add pepper');
*
* --pepper
* program.pepper
* // => Boolean
*
* // simple boolean defaulting to true
* program.option('-C, --no-cheese', 'remove cheese');
*
* program.cheese
* // => true
*
* --no-cheese
* program.cheese
* // => false
*
* // required argument
* program.option('-C, --chdir <path>', 'change the working directory');
*
* --chdir /tmp
* program.chdir
* // => "/tmp"
*
* // optional argument
* program.option('-c, --cheese [type]', 'add cheese [marble]');
* ```
*
* @returns `this` command for chaining
*/
option(flags: string, description?: string, defaultValue?: string | boolean | string[]): this;
option<T>(flags: string, description: string, fn: (value: string, previous: T) => T, defaultValue?: T): this;
/** @deprecated since v7, instead use choices or a custom function */
option(flags: string, description: string, regexp: RegExp, defaultValue?: string | boolean | string[]): this;
/**
* Define a required option, which must have a value after parsing. This usually means
* the option must be specified on the command line. (Otherwise the same as .option().)
*
* The `flags` string contains the short and/or long flags, separated by comma, a pipe or space.
*/
requiredOption(flags: string, description?: string, defaultValue?: string | boolean | string[]): this;
requiredOption<T>(flags: string, description: string, fn: (value: string, previous: T) => T, defaultValue?: T): this;
/** @deprecated since v7, instead use choices or a custom function */
requiredOption(flags: string, description: string, regexp: RegExp, defaultValue?: string | boolean | string[]): this;
/**
* Factory routine to create a new unattached option.
*
* See .option() for creating an attached option, which uses this routine to
* create the option. You can override createOption to return a custom option.
*/
createOption(flags: string, description?: string): Option;
/**
* Add a prepared Option.
*
* See .option() and .requiredOption() for creating and attaching an option in a single call.
*/
addOption(option: Option): this;
/**
* Whether to store option values as properties on command object,
* or store separately (specify false). In both cases the option values can be accessed using .opts().
*
* @returns `this` command for chaining
*/
storeOptionsAsProperties<T extends OptionValues>(): this & T;
storeOptionsAsProperties<T extends OptionValues>(storeAsProperties: true): this & T;
storeOptionsAsProperties(storeAsProperties?: boolean): this;
/**
* Retrieve option value.
*/
getOptionValue(key: string): any;
/**
* Store option value.
*/
setOptionValue(key: string, value: unknown): this;
/**
* Store option value and where the value came from.
*/
setOptionValueWithSource(key: string, value: unknown, source: OptionValueSource): this;
/**
* Get source of option value.
*/
getOptionValueSource(key: string): OptionValueSource | undefined;
/**
* Get source of option value. See also .optsWithGlobals().
*/
getOptionValueSourceWithGlobals(key: string): OptionValueSource | undefined;
/**
* Alter parsing of short flags with optional values.
*
* @example
* ```
* // for `.option('-f,--flag [value]'):
* .combineFlagAndOptionalValue(true) // `-f80` is treated like `--flag=80`, this is the default behaviour
* .combineFlagAndOptionalValue(false) // `-fb` is treated like `-f -b`
* ```
*
* @returns `this` command for chaining
*/
combineFlagAndOptionalValue(combine?: boolean): this;
/**
* Allow unknown options on the command line.
*
* @returns `this` command for chaining
*/
allowUnknownOption(allowUnknown?: boolean): this;
/**
* Allow excess command-arguments on the command line. Pass false to make excess arguments an error.
*
* @returns `this` command for chaining
*/
allowExcessArguments(allowExcess?: boolean): this;
/**
* Enable positional options. Positional means global options are specified before subcommands which lets
* subcommands reuse the same option names, and also enables subcommands to turn on passThroughOptions.
*
* The default behaviour is non-positional and global options may appear anywhere on the command line.
*
* @returns `this` command for chaining
*/
enablePositionalOptions(positional?: boolean): this;
/**
* Pass through options that come after command-arguments rather than treat them as command-options,
* so actual command-options come before command-arguments. Turning this on for a subcommand requires
* positional options to have been enabled on the program (parent commands).
*
* The default behaviour is non-positional and options may appear before or after command-arguments.
*
* @returns `this` command for chaining
*/
passThroughOptions(passThrough?: boolean): this;
/**
* Parse `argv`, setting options and invoking commands when defined.
*
* The default expectation is that the arguments are from node and have the application as argv[0]
* and the script being run in argv[1], with user parameters after that.
*
* @example
* ```
* program.parse(process.argv);
* program.parse(); // implicitly use process.argv and auto-detect node vs electron conventions
* program.parse(my-args, { from: 'user' }); // just user supplied arguments, nothing special about argv[0]
* ```
*
* @returns `this` command for chaining
*/
parse(argv?: readonly string[], options?: ParseOptions): this;
/**
* Parse `argv`, setting options and invoking commands when defined.
*
* Use parseAsync instead of parse if any of your action handlers are async. Returns a Promise.
*
* The default expectation is that the arguments are from node and have the application as argv[0]
* and the script being run in argv[1], with user parameters after that.
*
* @example
* ```
* program.parseAsync(process.argv);
* program.parseAsync(); // implicitly use process.argv and auto-detect node vs electron conventions
* program.parseAsync(my-args, { from: 'user' }); // just user supplied arguments, nothing special about argv[0]
* ```
*
* @returns Promise
*/
parseAsync(argv?: readonly string[], options?: ParseOptions): Promise<this>;
/**
* Parse options from `argv` removing known options,
* and return argv split into operands and unknown arguments.
*
* argv => operands, unknown
* --known kkk op => [op], []
* op --known kkk => [op], []
* sub --unknown uuu op => [sub], [--unknown uuu op]
* sub -- --unknown uuu op => [sub --unknown uuu op], []
*/
parseOptions(argv: string[]): ParseOptionsResult;
/**
* Return an object containing local option values as key-value pairs
*/
opts<T extends OptionValues>(): T;
/**
* Return an object containing merged local and global option values as key-value pairs.
*/
optsWithGlobals<T extends OptionValues>(): T;
/**
* Set the description.
*
* @returns `this` command for chaining
*/
description(str: string): this;
/** @deprecated since v8, instead use .argument to add command argument with description */
description(str: string, argsDescription: {[argName: string]: string}): this;
/**
* Get the description.
*/
description(): string;
/**
* Set the summary. Used when listed as subcommand of parent.
*
* @returns `this` command for chaining
*/
summary(str: string): this;
/**
* Get the summary.
*/
summary(): string;
/**
* Set an alias for the command.
*
* You may call more than once to add multiple aliases. Only the first alias is shown in the auto-generated help.
*
* @returns `this` command for chaining
*/
alias(alias: string): this;
/**
* Get alias for the command.
*/
alias(): string;
/**
* Set aliases for the command.
*
* Only the first alias is shown in the auto-generated help.
*
* @returns `this` command for chaining
*/
aliases(aliases: readonly string[]): this;
/**
* Get aliases for the command.
*/
aliases(): string[];
/**
* Set the command usage.
*
* @returns `this` command for chaining
*/
usage(str: string): this;
/**
* Get the command usage.
*/
usage(): string;
/**
* Set the name of the command.
*
* @returns `this` command for chaining
*/
name(str: string): this;
/**
* Get the name of the command.
*/
name(): string;
/**
* Set the name of the command from script filename, such as process.argv[1],
* or require.main.filename, or __filename.
*
* (Used internally and public although not documented in README.)
*
* @example
* ```ts
* program.nameFromFilename(require.main.filename);
* ```
*
* @returns `this` command for chaining
*/
nameFromFilename(filename: string): this;
/**
* Set the directory for searching for executable subcommands of this command.
*
* @example
* ```ts
* program.executableDir(__dirname);
* // or
* program.executableDir('subcommands');
* ```
*
* @returns `this` command for chaining
*/
executableDir(path: string): this;
/**
* Get the executable search directory.
*/
executableDir(): string;
/**
* Output help information for this command.
*
* Outputs built-in help, and custom text added using `.addHelpText()`.
*
*/
outputHelp(context?: HelpContext): void;
/** @deprecated since v7 */
outputHelp(cb?: (str: string) => string): void;
/**
* Return command help documentation.
*/
helpInformation(context?: HelpContext): string;
/**
* You can pass in flags and a description to override the help
* flags and help description for your command. Pass in false
* to disable the built-in help option.
*/
helpOption(flags?: string | boolean, description?: string): this;
/**
* Output help information and exit.
*
* Outputs built-in help, and custom text added using `.addHelpText()`.
*/
help(context?: HelpContext): never;
/** @deprecated since v7 */
help(cb?: (str: string) => string): never;
/**
* Add additional text to be displayed with the built-in help.
*
* Position is 'before' or 'after' to affect just this command,
* and 'beforeAll' or 'afterAll' to affect this command and all its subcommands.
*/
addHelpText(position: AddHelpTextPosition, text: string): this;
addHelpText(position: AddHelpTextPosition, text: (context: AddHelpTextContext) => string): this;
/**
* Add a listener (callback) for when events occur. (Implemented using EventEmitter.)
*/
on(event: string | symbol, listener: (...args: any[]) => void): this;
}
export interface CommandOptions {
hidden?: boolean;
isDefault?: boolean;
/** @deprecated since v7, replaced by hidden */
noHelp?: boolean;
}
export interface ExecutableCommandOptions extends CommandOptions {
executableFile?: string;
}
export interface ParseOptionsResult {
operands: string[];
unknown: string[];
}
export function createCommand(name?: string): Command;
export function createOption(flags: string, description?: string): Option;
export function createArgument(name: string, description?: string): Argument;
export const program: Command;
Loaded 100 of 35554 files, more files were not shown because too many files have changed in this diff. Show more