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

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

No files matched your search

@@ -0,0 +1,73 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.findBasePathOfAlias = exports.relativeOutPathToConfigDir = void 0;
const normalizePath = require("normalize-path");
const globby_1 = require("globby");
const path_1 = require("path");
function getProjectDirPathInOutDir(outDir, projectDir) {
const posixOutput = outDir.replace(/\\/g, '/');
const dirs = (0, globby_1.sync)([
`${posixOutput}/**/${projectDir}`,
`!${posixOutput}/**/${projectDir}/**/${projectDir}`,
`!${posixOutput}/**/node_modules`
], {
dot: true,
onlyDirectories: true
});
return dirs.reduce((prev, curr) => prev.split('/').length > curr.split('/').length ? prev : curr, dirs[0]);
}
function relativeOutPathToConfigDir(config) {
config.configDirInOutPath = getProjectDirPathInOutDir(config.outPath, config.confDirParentFolderName);
if (config.configDirInOutPath) {
config.hasExtraModule = true;
const stepsbackPath = (0, path_1.relative)(config.configDirInOutPath, config.outPath);
const splitStepBackPath = normalizePath(stepsbackPath).split('/');
const nbOfStepBack = splitStepBackPath.length;
const splitConfDirInOutPath = config.configDirInOutPath.split('/');
let i = 1;
const splitRelPath = [];
while (i <= nbOfStepBack) {
splitRelPath.unshift(splitConfDirInOutPath[splitConfDirInOutPath.length - i]);
i++;
}
config.relConfDirPathInOutPath = splitRelPath.join('/');
}
}
exports.relativeOutPathToConfigDir = relativeOutPathToConfigDir;
function findBasePathOfAlias(config) {
return (path) => {
const aliasPath = { path };
if ((0, path_1.normalize)(aliasPath.path).includes('..')) {
const tempBasePath = normalizePath((0, path_1.normalize)(`${config.outDir}/` +
`${config.hasExtraModule && config.relConfDirPathInOutPath
? config.relConfDirPathInOutPath
: ''}/${config.baseUrl}`));
const absoluteBasePath = normalizePath((0, path_1.normalize)(`${tempBasePath}/${aliasPath.path}`));
if (config.pathCache.existsResolvedAlias(absoluteBasePath)) {
aliasPath.isExtra = false;
aliasPath.basePath = tempBasePath;
}
else {
aliasPath.isExtra = true;
aliasPath.basePath = absoluteBasePath;
}
return aliasPath;
}
if (aliasPath.path.match(/^(\.\/|)node_modules/g)) {
aliasPath.basePath = (0, path_1.resolve)(config.baseUrl, 'node_modules');
aliasPath.isExtra = false;
return aliasPath;
}
if (config.hasExtraModule) {
aliasPath.isExtra = false;
aliasPath.basePath = normalizePath((0, path_1.normalize)(`${config.outDir}/` +
`${config.relConfDirPathInOutPath}/${config.baseUrl}`));
return aliasPath;
}
aliasPath.basePath = config.outDir;
aliasPath.isExtra = false;
return aliasPath;
};
}
exports.findBasePathOfAlias = findBasePathOfAlias;
//# sourceMappingURL=path.js.map
@@ -0,0 +1,28 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports["default"] = getImplicitRoleForMenuitem;
var _jsxAstUtils = require("jsx-ast-utils");
/**
* Returns the implicit role for a menuitem tag.
*/
function getImplicitRoleForMenuitem(attributes) {
var type = (0, _jsxAstUtils.getProp)(attributes, 'type');
if (type) {
var value = (0, _jsxAstUtils.getLiteralPropValue)(type) || '';
switch (typeof value === 'string' && value.toUpperCase()) {
case 'COMMAND':
return 'menuitem';
case 'CHECKBOX':
return 'menuitemcheckbox';
case 'RADIO':
return 'menuitemradio';
default:
return '';
}
}
return '';
}
module.exports = exports.default;
@@ -0,0 +1,97 @@
import { CSSProperties } from 'react';
export type ToastType = 'success' | 'error' | 'loading' | 'blank' | 'custom';
export type ToastPosition =
| 'top-left'
| 'top-center'
| 'top-right'
| 'bottom-left'
| 'bottom-center'
| 'bottom-right';
export type Renderable = React.ReactElement | string | null;
export interface IconTheme {
primary: string;
secondary: string;
}
export type ValueFunction<TValue, TArg> = (arg: TArg) => TValue;
export type ValueOrFunction<TValue, TArg> =
| TValue
| ValueFunction<TValue, TArg>;
const isFunction = <TValue, TArg>(
valOrFunction: ValueOrFunction<TValue, TArg>
): valOrFunction is ValueFunction<TValue, TArg> =>
typeof valOrFunction === 'function';
export const resolveValue = <TValue, TArg>(
valOrFunction: ValueOrFunction<TValue, TArg>,
arg: TArg
): TValue => (isFunction(valOrFunction) ? valOrFunction(arg) : valOrFunction);
export interface Toast {
type: ToastType;
id: string;
toasterId?: string;
message: ValueOrFunction<Renderable, Toast>;
icon?: Renderable;
duration?: number;
pauseDuration: number;
position?: ToastPosition;
removeDelay?: number;
ariaProps: {
role: 'status' | 'alert';
'aria-live': 'assertive' | 'off' | 'polite';
};
style?: CSSProperties;
className?: string;
iconTheme?: IconTheme;
createdAt: number;
visible: boolean;
dismissed: boolean;
height?: number;
}
export type ToastOptions = Partial<
Pick<
Toast,
| 'id'
| 'icon'
| 'duration'
| 'ariaProps'
| 'className'
| 'style'
| 'position'
| 'iconTheme'
| 'toasterId'
| 'removeDelay'
>
>;
export type DefaultToastOptions = ToastOptions & {
[key in ToastType]?: ToastOptions;
};
export interface ToasterProps {
position?: ToastPosition;
toastOptions?: DefaultToastOptions;
reverseOrder?: boolean;
gutter?: number;
containerStyle?: React.CSSProperties;
containerClassName?: string;
toasterId?: string;
children?: (toast: Toast) => React.ReactElement;
}
export interface ToastWrapperProps {
id: string;
className?: string;
style?: React.CSSProperties;
onHeightUpdate: (id: string, height: number) => void;
children?: React.ReactNode;
}
@@ -0,0 +1,36 @@
/**
* @typedef {import('./core.js').CoreOptions & import('./util/format-smart.js').FormatSmartOptions} Options
* @typedef {import('./core.js').CoreOptions} LightOptions
*/
import {core} from './core.js'
import {formatSmart} from './util/format-smart.js'
import {formatBasic} from './util/format-basic.js'
/**
* Encode special characters in `value`.
*
* @param {string} value
* Value to encode.
* @param {Options} [options]
* Configuration.
* @returns {string}
* Encoded value.
*/
export function stringifyEntities(value, options) {
return core(value, Object.assign({format: formatSmart}, options))
}
/**
* Encode special characters in `value` as hexadecimals.
*
* @param {string} value
* Value to encode.
* @param {LightOptions} [options]
* Configuration.
* @returns {string}
* Encoded value.
*/
export function stringifyEntitiesLight(value, options) {
return core(value, Object.assign({format: formatBasic}, options))
}
@@ -0,0 +1,21 @@
MIT License
Copyright (c) 2021 UnTS
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,72 @@
"use strict"
const { READ } = require("@eslint-community/eslint-utils")
/**
* @satisfies {import('../types.js').SupportVersionTraceMap}
*/
const dns = {
Resolver: { [READ]: { supported: ["8.3.0"] } },
getServers: { [READ]: { supported: ["0.11.3"] } },
lookup: { [READ]: { supported: ["0.1.90"] } },
lookupService: { [READ]: { supported: ["0.11.14"] } },
resolve: { [READ]: { supported: ["0.1.27"] } },
resolve4: { [READ]: { supported: ["0.1.16"] } },
resolve6: { [READ]: { supported: ["0.1.16"] } },
resolveAny: { [READ]: { supported: ["0.1.16"] } },
resolveCname: { [READ]: { supported: ["0.3.2"] } },
resolveCaa: { [READ]: { supported: ["15.0.0", "14.17.0"] } },
resolveMx: { [READ]: { supported: ["0.1.27"] } },
resolveNaptr: { [READ]: { supported: ["0.9.12"] } },
resolveNs: { [READ]: { supported: ["0.1.90"] } },
resolvePtr: { [READ]: { supported: ["6.0.0"] } },
resolveSoa: { [READ]: { supported: ["0.11.10"] } },
resolveSrv: { [READ]: { supported: ["0.1.27"] } },
resolveTlsa: { [READ]: { supported: ["22.15.0", "23.9.0"] } },
resolveTxt: { [READ]: { supported: ["0.1.27"] } },
reverse: { [READ]: { supported: ["0.1.16"] } },
setDefaultResultOrder: { [READ]: { supported: ["16.4.0", "14.18.0"] } },
getDefaultResultOrder: { [READ]: { supported: ["20.1.0", "18.17.0"] } },
setServers: { [READ]: { supported: ["0.11.3"] } },
promises: {
[READ]: {
experimental: ["10.6.0"],
supported: ["11.14.0", "10.17.0"],
},
Resolver: { [READ]: { supported: ["10.6.0"] } },
cancel: { [READ]: { supported: ["15.3.0", "14.17.0"] } },
getServers: { [READ]: { supported: ["10.6.0"] } },
lookup: { [READ]: { supported: ["10.6.0"] } },
lookupService: { [READ]: { supported: ["10.6.0"] } },
resolve: { [READ]: { supported: ["10.6.0"] } },
resolve4: { [READ]: { supported: ["10.6.0"] } },
resolve6: { [READ]: { supported: ["10.6.0"] } },
resolveAny: { [READ]: { supported: ["10.6.0"] } },
resolveCaa: { [READ]: { supported: ["15.0.0", "14.17.0"] } },
resolveCname: { [READ]: { supported: ["10.6.0"] } },
resolveMx: { [READ]: { supported: ["10.6.0"] } },
resolveNaptr: { [READ]: { supported: ["10.6.0"] } },
resolveNs: { [READ]: { supported: ["10.6.0"] } },
resolvePtr: { [READ]: { supported: ["10.6.0"] } },
resolveSoa: { [READ]: { supported: ["10.6.0"] } },
resolveSrv: { [READ]: { supported: ["10.6.0"] } },
resolveTlsa: { [READ]: { supported: ["22.15.0", "23.9.0"] } },
resolveTxt: { [READ]: { supported: ["10.6.0"] } },
reverse: { [READ]: { supported: ["10.6.0"] } },
setDefaultResultOrder: { [READ]: { supported: ["16.4.0", "14.18.0"] } },
getDefaultResultOrder: { [READ]: { supported: ["20.1.0", "18.17.0"] } },
setServers: { [READ]: { supported: ["10.6.0"] } },
},
}
/**
* @satisfies {import('../types.js').SupportVersionTraceMap}
*/
module.exports = {
dns: { ...dns, [READ]: { supported: ["0.1.16"] } },
"node:dns": { ...dns, [READ]: { supported: ["14.13.1", "12.20.0"] } },
"dns/promises": { ...dns.promises, [READ]: { supported: ["15.0.0"] } },
"node:dns/promises": { ...dns.promises, [READ]: { supported: ["15.0.0"] } },
}
@@ -0,0 +1 @@
{"version":3,"file":"ServiceReferenceManager.d.ts","sourceRoot":"","sources":["../../../../src/container/services/ServiceReferenceManager.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,kBAAkB,EAClB,cAAc,EACd,oBAAoB,EACpB,sBAAsB,EACvB,MAAM,mBAAmB,CAAC;AAE3B;;;GAGG;AACH,qBAAa,uBAAuB;;IAC3B,iBAAiB,EAAE,kBAAkB,CAAC;IACtC,cAAc,EAAE,cAAc,CAAC;IAC/B,mBAAmB,EAAE,oBAAoB,CAAC;IACjD,SAAgB,sBAAsB,EAAE,sBAAsB,CAAC;gBAK7D,iBAAiB,EAAE,kBAAkB,EACrC,cAAc,EAAE,cAAc,EAC9B,mBAAmB,EAAE,oBAAoB,EACzC,sBAAsB,EAAE,sBAAsB;IAUzC,KAAK,CACV,iBAAiB,EAAE,kBAAkB,EACrC,cAAc,EAAE,cAAc,EAC9B,mBAAmB,EAAE,oBAAoB,GACxC,IAAI;IAYA,OAAO,CAAC,QAAQ,EAAE,MAAM,IAAI,GAAG,IAAI;CAG3C"}
@@ -0,0 +1,21 @@
The MIT License (MIT)
Copyright (c) 2024 [Motion](https://motion.dev) B.V.
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,567 @@
import type { Action, Dispatch, MiddlewareAPI, UnknownAction } from 'redux'
import { isAction } from '../reduxImports'
import type { ThunkDispatch } from 'redux-thunk'
import { createAction } from '../createAction'
import { nanoid } from '../nanoid'
import {
TaskAbortError,
listenerCancelled,
listenerCompleted,
taskCancelled,
taskCompleted,
} from './exceptions'
import {
createDelay,
createPause,
raceWithSignal,
runTask,
validateActive,
} from './task'
import type {
AbortSignalWithReason,
AddListenerOverloads,
AnyListenerPredicate,
CreateListenerMiddlewareOptions,
FallbackAddListenerOptions,
ForkOptions,
ForkedTask,
ForkedTaskExecutor,
ListenerEntry,
ListenerErrorHandler,
ListenerErrorInfo,
ListenerMiddleware,
ListenerMiddlewareInstance,
TakePattern,
TaskResult,
TypedAddListener,
TypedCreateListenerEntry,
TypedRemoveListener,
UnsubscribeListener,
UnsubscribeListenerOptions,
} from './types'
import {
abortControllerWithReason,
addAbortSignalListener,
assertFunction,
catchRejection,
noop,
} from './utils'
export { TaskAbortError } from './exceptions'
export type {
AsyncTaskExecutor,
CreateListenerMiddlewareOptions,
ForkedTask,
ForkedTaskAPI,
ForkedTaskExecutor,
ListenerEffect,
ListenerEffectAPI,
ListenerErrorHandler,
ListenerMiddleware,
ListenerMiddlewareInstance,
SyncTaskExecutor,
TaskCancelled,
TaskRejected,
TaskResolved,
TaskResult,
TypedAddListener,
TypedRemoveListener,
TypedStartListening,
TypedStopListening,
UnsubscribeListener,
UnsubscribeListenerOptions,
} from './types'
//Overly-aggressive byte-shaving
const { assign } = Object
/**
* @internal
*/
const INTERNAL_NIL_TOKEN = {} as const
const alm = 'listenerMiddleware' as const
const createFork = (
parentAbortSignal: AbortSignalWithReason<unknown>,
parentBlockingPromises: Promise<any>[],
) => {
const linkControllers = (controller: AbortController) =>
addAbortSignalListener(parentAbortSignal, () =>
abortControllerWithReason(controller, parentAbortSignal.reason),
)
return <T>(
taskExecutor: ForkedTaskExecutor<T>,
opts?: ForkOptions,
): ForkedTask<T> => {
assertFunction(taskExecutor, 'taskExecutor')
const childAbortController = new AbortController()
linkControllers(childAbortController)
const result = runTask<T>(
async (): Promise<T> => {
validateActive(parentAbortSignal)
validateActive(childAbortController.signal)
const result = (await taskExecutor({
pause: createPause(childAbortController.signal),
delay: createDelay(childAbortController.signal),
signal: childAbortController.signal,
})) as T
validateActive(childAbortController.signal)
return result
},
() => abortControllerWithReason(childAbortController, taskCompleted),
)
if (opts?.autoJoin) {
parentBlockingPromises.push(result.catch(noop))
}
return {
result: createPause<TaskResult<T>>(parentAbortSignal)(result),
cancel() {
abortControllerWithReason(childAbortController, taskCancelled)
},
}
}
}
const createTakePattern = <S>(
startListening: AddListenerOverloads<UnsubscribeListener, S, Dispatch>,
signal: AbortSignal,
): TakePattern<S> => {
/**
* A function that takes a ListenerPredicate and an optional timeout,
* and resolves when either the predicate returns `true` based on an action
* state combination or when the timeout expires.
* If the parent listener is canceled while waiting, this will throw a
* TaskAbortError.
*/
const take = async <P extends AnyListenerPredicate<S>>(
predicate: P,
timeout: number | undefined,
) => {
validateActive(signal)
// Placeholder unsubscribe function until the listener is added
let unsubscribe: UnsubscribeListener = () => {}
const tuplePromise = new Promise<[Action, S, S]>((resolve, reject) => {
// Inside the Promise, we synchronously add the listener.
let stopListening = startListening({
predicate: predicate as any,
effect: (action, listenerApi): void => {
// One-shot listener that cleans up as soon as the predicate passes
listenerApi.unsubscribe()
// Resolve the promise with the same arguments the predicate saw
resolve([
action,
listenerApi.getState(),
listenerApi.getOriginalState(),
])
},
})
unsubscribe = () => {
stopListening()
reject()
}
})
const promises: (Promise<null> | Promise<[Action, S, S]>)[] = [tuplePromise]
if (timeout != null) {
promises.push(
new Promise<null>((resolve) => setTimeout(resolve, timeout, null)),
)
}
try {
const output = await raceWithSignal(signal, Promise.race(promises))
validateActive(signal)
return output
} finally {
// Always clean up the listener
unsubscribe()
}
}
return ((predicate: AnyListenerPredicate<S>, timeout: number | undefined) =>
catchRejection(take(predicate, timeout))) as TakePattern<S>
}
const getListenerEntryPropsFrom = (options: FallbackAddListenerOptions) => {
let { type, actionCreator, matcher, predicate, effect } = options
if (type) {
predicate = createAction(type).match
} else if (actionCreator) {
type = actionCreator!.type
predicate = actionCreator.match
} else if (matcher) {
predicate = matcher
} else if (predicate) {
// pass
} else {
throw new Error(
'Creating or removing a listener requires one of the known fields for matching an action',
)
}
assertFunction(effect, 'options.listener')
return { predicate, type, effect }
}
/** Accepts the possible options for creating a listener, and returns a formatted listener entry */
export const createListenerEntry: TypedCreateListenerEntry<unknown> =
/* @__PURE__ */ assign(
(options: FallbackAddListenerOptions) => {
const { type, predicate, effect } = getListenerEntryPropsFrom(options)
const entry: ListenerEntry<unknown> = {
id: nanoid(),
effect,
type,
predicate,
pending: new Set<AbortController>(),
unsubscribe: () => {
throw new Error('Unsubscribe not initialized')
},
}
return entry
},
{ withTypes: () => createListenerEntry },
) as unknown as TypedCreateListenerEntry<unknown>
const findListenerEntry = (
listenerMap: Map<string, ListenerEntry>,
options: FallbackAddListenerOptions,
) => {
const { type, effect, predicate } = getListenerEntryPropsFrom(options)
return Array.from(listenerMap.values()).find((entry) => {
const matchPredicateOrType =
typeof type === 'string'
? entry.type === type
: entry.predicate === predicate
return matchPredicateOrType && entry.effect === effect
})
}
const cancelActiveListeners = (
entry: ListenerEntry<unknown, Dispatch<UnknownAction>>,
) => {
entry.pending.forEach((controller) => {
abortControllerWithReason(controller, listenerCancelled)
})
}
const createClearListenerMiddleware = (
listenerMap: Map<string, ListenerEntry>,
executingListeners: Map<ListenerEntry, number>,
) => {
return () => {
for (const listener of executingListeners.keys()) {
cancelActiveListeners(listener)
}
listenerMap.clear()
}
}
/**
* Safely reports errors to the `errorHandler` provided.
* Errors that occur inside `errorHandler` are notified in a new task.
* Inspired by [rxjs reportUnhandledError](https://github.com/ReactiveX/rxjs/blob/6fafcf53dc9e557439b25debaeadfd224b245a66/src/internal/util/reportUnhandledError.ts)
* @param errorHandler
* @param errorToNotify
*/
const safelyNotifyError = (
errorHandler: ListenerErrorHandler,
errorToNotify: unknown,
errorInfo: ListenerErrorInfo,
): void => {
try {
errorHandler(errorToNotify, errorInfo)
} catch (errorHandlerError) {
// We cannot let an error raised here block the listener queue.
// The error raised here will be picked up by `window.onerror`, `process.on('error')` etc...
setTimeout(() => {
throw errorHandlerError
}, 0)
}
}
/**
* @public
*/
export const addListener = /* @__PURE__ */ assign(
/* @__PURE__ */ createAction(`${alm}/add`),
{
withTypes: () => addListener,
},
) as unknown as TypedAddListener<unknown>
/**
* @public
*/
export const clearAllListeners = /* @__PURE__ */ createAction(
`${alm}/removeAll`,
)
/**
* @public
*/
export const removeListener = /* @__PURE__ */ assign(
/* @__PURE__ */ createAction(`${alm}/remove`),
{
withTypes: () => removeListener,
},
) as unknown as TypedRemoveListener<unknown>
const defaultErrorHandler: ListenerErrorHandler = (...args: unknown[]) => {
console.error(`${alm}/error`, ...args)
}
/**
* @public
*/
export const createListenerMiddleware = <
StateType = unknown,
DispatchType extends Dispatch<Action> = ThunkDispatch<
StateType,
unknown,
UnknownAction
>,
ExtraArgument = unknown,
>(
middlewareOptions: CreateListenerMiddlewareOptions<ExtraArgument> = {},
) => {
const listenerMap = new Map<string, ListenerEntry>()
// Track listeners whose effect is currently executing so clearListeners can
// abort even listeners that have become unsubscribed while executing.
const executingListeners = new Map<ListenerEntry, number>()
const trackExecutingListener = (entry: ListenerEntry) => {
const count = executingListeners.get(entry) ?? 0
executingListeners.set(entry, count + 1)
}
const untrackExecutingListener = (entry: ListenerEntry) => {
const count = executingListeners.get(entry) ?? 1
if (count === 1) {
executingListeners.delete(entry)
} else {
executingListeners.set(entry, count - 1)
}
}
const { extra, onError = defaultErrorHandler } = middlewareOptions
assertFunction(onError, 'onError')
const insertEntry = (entry: ListenerEntry) => {
entry.unsubscribe = () => listenerMap.delete(entry.id)
listenerMap.set(entry.id, entry)
return (cancelOptions?: UnsubscribeListenerOptions) => {
entry.unsubscribe()
if (cancelOptions?.cancelActive) {
cancelActiveListeners(entry)
}
}
}
const startListening = ((options: FallbackAddListenerOptions) => {
const entry =
findListenerEntry(listenerMap, options) ??
createListenerEntry(options as any)
return insertEntry(entry)
}) as AddListenerOverloads<any>
assign(startListening, {
withTypes: () => startListening,
})
const stopListening = (
options: FallbackAddListenerOptions & UnsubscribeListenerOptions,
): boolean => {
const entry = findListenerEntry(listenerMap, options)
if (entry) {
entry.unsubscribe()
if (options.cancelActive) {
cancelActiveListeners(entry)
}
}
return !!entry
}
assign(stopListening, {
withTypes: () => stopListening,
})
const notifyListener = async (
entry: ListenerEntry<unknown, Dispatch<UnknownAction>>,
action: unknown,
api: MiddlewareAPI,
getOriginalState: () => StateType,
) => {
const internalTaskController = new AbortController()
const take = createTakePattern(
startListening as AddListenerOverloads<any>,
internalTaskController.signal,
)
const autoJoinPromises: Promise<any>[] = []
try {
entry.pending.add(internalTaskController)
trackExecutingListener(entry)
await Promise.resolve(
entry.effect(
action,
// Use assign() rather than ... to avoid extra helper functions added to bundle
assign({}, api, {
getOriginalState,
condition: (
predicate: AnyListenerPredicate<any>,
timeout?: number,
) => take(predicate, timeout).then(Boolean),
take,
delay: createDelay(internalTaskController.signal),
pause: createPause<any>(internalTaskController.signal),
extra,
signal: internalTaskController.signal,
fork: createFork(internalTaskController.signal, autoJoinPromises),
unsubscribe: entry.unsubscribe,
subscribe: () => {
listenerMap.set(entry.id, entry)
},
cancelActiveListeners: () => {
entry.pending.forEach((controller, _, set) => {
if (controller !== internalTaskController) {
abortControllerWithReason(controller, listenerCancelled)
set.delete(controller)
}
})
},
cancel: () => {
abortControllerWithReason(
internalTaskController,
listenerCancelled,
)
entry.pending.delete(internalTaskController)
},
throwIfCancelled: () => {
validateActive(internalTaskController.signal)
},
}),
),
)
} catch (listenerError) {
if (!(listenerError instanceof TaskAbortError)) {
safelyNotifyError(onError, listenerError, {
raisedBy: 'effect',
})
}
} finally {
await Promise.all(autoJoinPromises)
abortControllerWithReason(internalTaskController, listenerCompleted) // Notify that the task has completed
untrackExecutingListener(entry)
entry.pending.delete(internalTaskController)
}
}
const clearListenerMiddleware = createClearListenerMiddleware(
listenerMap,
executingListeners,
)
const middleware: ListenerMiddleware<
StateType,
DispatchType,
ExtraArgument
> = (api) => (next) => (action) => {
if (!isAction(action)) {
// we only want to notify listeners for action objects
return next(action)
}
if (addListener.match(action)) {
return startListening(action.payload as any)
}
if (clearAllListeners.match(action)) {
clearListenerMiddleware()
return
}
if (removeListener.match(action)) {
return stopListening(action.payload)
}
// Need to get this state _before_ the reducer processes the action
let originalState: StateType | typeof INTERNAL_NIL_TOKEN = api.getState()
// `getOriginalState` can only be called synchronously.
// @see https://github.com/reduxjs/redux-toolkit/discussions/1648#discussioncomment-1932820
const getOriginalState = (): StateType => {
if (originalState === INTERNAL_NIL_TOKEN) {
throw new Error(
`${alm}: getOriginalState can only be called synchronously`,
)
}
return originalState as StateType
}
let result: unknown
try {
// Actually forward the action to the reducer before we handle listeners
result = next(action)
if (listenerMap.size > 0) {
const currentState = api.getState()
// Work around ESBuild+TS transpilation issue
const listenerEntries = Array.from(listenerMap.values())
for (const entry of listenerEntries) {
let runListener = false
try {
runListener = entry.predicate(action, currentState, originalState)
} catch (predicateError) {
runListener = false
safelyNotifyError(onError, predicateError, {
raisedBy: 'predicate',
})
}
if (!runListener) {
continue
}
notifyListener(entry, action, api, getOriginalState)
}
}
} finally {
// Remove `originalState` store from this scope.
originalState = INTERNAL_NIL_TOKEN
}
return result
}
return {
middleware,
startListening,
stopListening,
clearListeners: clearListenerMiddleware,
} as ListenerMiddlewareInstance<StateType, DispatchType, ExtraArgument>
}
@@ -0,0 +1,17 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.roles = exports.roleElements = exports.elementRoles = exports.dom = exports.aria = void 0;
var _ariaPropsMap = _interopRequireDefault(require("./ariaPropsMap"));
var _domMap = _interopRequireDefault(require("./domMap"));
var _rolesMap = _interopRequireDefault(require("./rolesMap"));
var _elementRoleMap = _interopRequireDefault(require("./elementRoleMap"));
var _roleElementMap = _interopRequireDefault(require("./roleElementMap"));
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
var aria = exports.aria = _ariaPropsMap.default;
var dom = exports.dom = _domMap.default;
var roles = exports.roles = _rolesMap.default;
var elementRoles = exports.elementRoles = _elementRoleMap.default;
var roleElements = exports.roleElements = _roleElementMap.default;
@@ -0,0 +1,100 @@
import { createNode, updateNode } from './proxy'
import type { Node } from './tracking'
import { createCacheKeyComparator, referenceEqualityCheck } from '../lruMemoize'
import type { AnyFunction, DefaultMemoizeFields, Simplify } from '../types'
import { createCache } from './autotracking'
/**
* Uses an "auto-tracking" approach inspired by the work of the Ember Glimmer team.
* It uses a Proxy to wrap arguments and track accesses to nested fields
* in your selector on first read. Later, when the selector is called with
* new arguments, it identifies which accessed fields have changed and
* only recalculates the result if one or more of those accessed fields have changed.
* This allows it to be more precise than the shallow equality checks in `lruMemoize`.
*
* __Design Tradeoffs for `autotrackMemoize`:__
* - Pros:
* - It is likely to avoid excess calculations and recalculate fewer times than `lruMemoize` will,
* which may also result in fewer component re-renders.
* - Cons:
* - It only has a cache size of 1.
* - It is slower than `lruMemoize`, because it has to do more work. (How much slower is dependent on the number of accessed fields in a selector, number of calls, frequency of input changes, etc)
* - It can have some unexpected behavior. Because it tracks nested field accesses,
* cases where you don't access a field will not recalculate properly.
* For example, a badly-written selector like:
* ```ts
* createSelector([state => state.todos], todos => todos)
* ```
* that just immediately returns the extracted value will never update, because it doesn't see any field accesses to check.
*
* __Use Cases for `autotrackMemoize`:__
* - It is likely best used for cases where you need to access specific nested fields
* in data, and avoid recalculating if other fields in the same data objects are immutably updated.
*
* @param func - The function to be memoized.
* @returns A memoized function with a `.clearCache()` method attached.
*
* @example
* <caption>Using `createSelector`</caption>
* ```ts
* import { unstable_autotrackMemoize as autotrackMemoize, createSelector } from 'reselect'
*
* const selectTodoIds = createSelector(
* [(state: RootState) => state.todos],
* (todos) => todos.map(todo => todo.id),
* { memoize: autotrackMemoize }
* )
* ```
*
* @example
* <caption>Using `createSelectorCreator`</caption>
* ```ts
* import { unstable_autotrackMemoize as autotrackMemoize, createSelectorCreator } from 'reselect'
*
* const createSelectorAutotrack = createSelectorCreator({ memoize: autotrackMemoize })
*
* const selectTodoIds = createSelectorAutotrack(
* [(state: RootState) => state.todos],
* (todos) => todos.map(todo => todo.id)
* )
* ```
*
* @template Func - The type of the function that is memoized.
*
* @see {@link https://reselect.js.org/api/unstable_autotrackMemoize autotrackMemoize}
*
* @since 5.0.0
* @public
* @experimental
*/
export function autotrackMemoize<Func extends AnyFunction>(func: Func) {
// we reference arguments instead of spreading them for performance reasons
const node: Node<Record<string, unknown>> = createNode(
[] as unknown as Record<string, unknown>
)
let lastArgs: IArguments | null = null
const shallowEqual = createCacheKeyComparator(referenceEqualityCheck)
const cache = createCache(() => {
const res = func.apply(null, node.proxy as unknown as any[])
return res
})
function memoized() {
if (!shallowEqual(lastArgs, arguments)) {
updateNode(node, arguments as unknown as Record<string, unknown>)
lastArgs = arguments
}
return cache.value
}
memoized.clearCache = () => {
return cache.clear()
}
return memoized as Func & Simplify<DefaultMemoizeFields>
}
@@ -0,0 +1,39 @@
# Mylas
![npm](https://img.shields.io/npm/dt/mylas)
![install size](https://badgen.net/packagephobia/install/mylas)
![npm bundle size (scoped)](https://img.shields.io/bundlephobia/min/mylas)
![npm bundle size (scoped)](https://img.shields.io/bundlephobia/minzip/mylas)
![dependencie count](https://img.shields.io/badge/dependencies-0-brightgreen)
![GitHub](https://img.shields.io/github/license/raouldeheer/Mylas)
![npm (scoped)](https://img.shields.io/npm/v/mylas)
![node-current (scoped)](https://img.shields.io/node/v/mylas)
Mylas is a npm package that makes the loading and storing of data from fs easy and reliable. And it supports multithreading, json with comments and loading buffers with multithreading. It can also find [node_modules](https://github.com/raouldeheer/Mylas/wiki/Dir#nodemodules) folders.
<img src="https://raw.githubusercontent.com/raouldeheer/Mylas/HEAD/.github/logo.png" width="600">
## Installation
Install Mylas from NPM
```ts
npm i mylas
// Or
yarn add mylas
```
## Getting started
To get started have a look at our [wiki](https://github.com/raouldeheer/Mylas/wiki)
## Examples
- [Json examples](https://github.com/raouldeheer/Mylas/wiki/Json)
- [File examples](https://github.com/raouldeheer/Mylas/wiki/File)
- [Buf examples](https://github.com/raouldeheer/Mylas/wiki/Buf)
- [Dir examples](https://github.com/raouldeheer/Mylas/wiki/Dir)
## Documentation
All features are listed at the [wiki](https://github.com/raouldeheer/Mylas/wiki)
## Contributing
We would love more contributors! To start contributing read our [Contributing page](https://github.com/raouldeheer/Mylas/blob/main/.github/CONTRIBUTING.md).
## Supported Versions
Check for supported versions at the [security policy](https://github.com/raouldeheer/Mylas/security/policy).
@@ -0,0 +1 @@
{"version":3,"file":"assertMetadataFromTypescriptIfManaged.d.ts","sourceRoot":"","sources":["../../../../src/metadata/calculations/assertMetadataFromTypescriptIfManaged.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,2BAA2B,EAAE,MAAM,uCAAuC,CAAC;AAEpF,OAAO,EAAE,gCAAgC,EAAE,MAAM,4CAA4C,CAAC;AAE9F,wBAAgB,qCAAqC,CACnD,QAAQ,EAAE,gCAAgC,GAAG,2BAA2B,GACvE,IAAI,CAUN"}
@@ -0,0 +1,6 @@
declare const _default: {
settings: {
'import-x/core-modules': string[];
};
};
export default _default;
@@ -0,0 +1,22 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = void 0;
var tabpanelRole = {
abstract: false,
accessibleNameRequired: true,
baseConcepts: [],
childrenPresentational: false,
nameFrom: ['author'],
prohibitedProps: [],
props: {},
relatedConcepts: [],
requireContextRole: [],
requiredContextRole: [],
requiredOwnedElements: [],
requiredProps: {},
superClass: [['roletype', 'structure', 'section']]
};
var _default = exports.default = tabpanelRole;
@@ -0,0 +1,51 @@
var assignValue = require('./_assignValue'),
castPath = require('./_castPath'),
isIndex = require('./_isIndex'),
isObject = require('./isObject'),
toKey = require('./_toKey');
/**
* The base implementation of `_.set`.
*
* @private
* @param {Object} object The object to modify.
* @param {Array|string} path The path of the property to set.
* @param {*} value The value to set.
* @param {Function} [customizer] The function to customize path creation.
* @returns {Object} Returns `object`.
*/
function baseSet(object, path, value, customizer) {
if (!isObject(object)) {
return object;
}
path = castPath(path, object);
var index = -1,
length = path.length,
lastIndex = length - 1,
nested = object;
while (nested != null && ++index < length) {
var key = toKey(path[index]),
newValue = value;
if (key === '__proto__' || key === 'constructor' || key === 'prototype') {
return object;
}
if (index != lastIndex) {
var objValue = nested[key];
newValue = customizer ? customizer(objValue, key, nested) : undefined;
if (newValue === undefined) {
newValue = isObject(objValue)
? objValue
: (isIndex(path[index + 1]) ? [] : {});
}
}
assignValue(nested, key, newValue);
nested = nested[key];
}
return object;
}
module.exports = baseSet;
@@ -0,0 +1,15 @@
'use strict';
var $TypeError = require('es-errors/type');
var BigIntEqual = require('./equal');
// https://262.ecma-international.org/11.0/#sec-numeric-types-bigint-sameValue
module.exports = function BigIntSameValue(x, y) {
if (typeof x !== 'bigint' || typeof y !== 'bigint') {
throw new $TypeError('Assertion failed: `x` and `y` arguments must be BigInts');
}
return BigIntEqual(x, y);
};
@@ -0,0 +1,129 @@
'use strict';
var $RangeError = require('es-errors/range');
var $SyntaxError = require('es-errors/syntax');
var $TypeError = require('es-errors/type');
var GetIntrinsic = require('get-intrinsic');
var isInteger = require('math-intrinsics/isInteger');
var typedArrayBuffer = require('typed-array-buffer');
var typedArrayByteLength = require('typed-array-byte-length');
var typedArrayByteOffset = require('typed-array-byte-offset');
var typedArrayLength = require('typed-array-length');
var whichTypedArray = require('which-typed-array');
var CloneArrayBuffer = require('./CloneArrayBuffer');
var GetValueFromBuffer = require('./GetValueFromBuffer');
var IsDetachedBuffer = require('./IsDetachedBuffer');
var IsSharedArrayBuffer = require('./IsSharedArrayBuffer');
var SameValue = require('./SameValue');
var SetValueInBuffer = require('./SetValueInBuffer');
var TypedArrayElementSize = require('./TypedArrayElementSize');
var TypedArrayElementType = require('./TypedArrayElementType');
var $ArrayBuffer = GetIntrinsic('%ArrayBuffer%', true);
// https://262.ecma-international.org/14.0/#sec-settypedarrayfromtypedarray
module.exports = function SetTypedArrayFromTypedArray(target, targetOffset, source) {
var whichTarget = whichTypedArray(target);
if (!whichTarget) {
throw new $TypeError('Assertion failed: target must be a TypedArray instance');
}
if (targetOffset !== Infinity && (!isInteger(targetOffset) || targetOffset < 0)) {
throw new $TypeError('Assertion failed: targetOffset must be a non-negative integer or +Infinity');
}
var whichSource = whichTypedArray(source);
if (!whichSource) {
throw new $TypeError('Assertion failed: source must be a TypedArray instance');
}
var targetBuffer = typedArrayBuffer(target); // step 1
if (IsDetachedBuffer(targetBuffer)) {
throw new $TypeError('target’s buffer is detached'); // step 2
}
var targetLength = typedArrayLength(target); // step 3
var srcBuffer = typedArrayBuffer(source); // step 4
if (IsDetachedBuffer(srcBuffer)) {
throw new $TypeError('source’s buffer is detached'); // step 5
}
var targetType = TypedArrayElementType(target); // step 6
var targetElementSize = TypedArrayElementSize(target); // step 7
var targetByteOffset = typedArrayByteOffset(target); // step 8
var srcType = TypedArrayElementType(source); // step 9
var srcElementSize = TypedArrayElementSize(source); // step 10
var srcLength = typedArrayLength(source); // step 11
var srcByteOffset = typedArrayByteOffset(source); // step 12
if (targetOffset === Infinity) {
throw new $RangeError('targetOffset must be a non-negative integer or +Infinity'); // step 13
}
if (srcLength + targetOffset > targetLength) {
throw new $RangeError('targetOffset + source.length must not be greater than target.length'); // step 14
}
var targetContentType = whichTarget === 'BigInt64Array' || whichTarget === 'BigUint64Array' ? 'BigInt' : 'Number';
var sourceContentType = whichSource === 'BigInt64Array' || whichSource === 'BigUint64Array' ? 'BigInt' : 'Number';
if (targetContentType !== sourceContentType) {
throw new $TypeError('source and target must have the same content type'); // step 15
}
var sameSharedArrayBuffer = false;
if (IsSharedArrayBuffer(srcBuffer) && IsSharedArrayBuffer(targetBuffer)) { // step 16
// a. If srcBuffer.[[ArrayBufferData]] and targetBuffer.[[ArrayBufferData]] are the same Shared Data Block values, let same be true; else let same be false.
throw new $SyntaxError('SharedArrayBuffer is not supported by this implementation');
}
var srcByteIndex;
if (SameValue(srcBuffer, targetBuffer) || sameSharedArrayBuffer) { // step 17
var srcByteLength = typedArrayByteLength(source); // step 17.a
srcBuffer = CloneArrayBuffer(srcBuffer, srcByteOffset, srcByteLength, $ArrayBuffer); // step 17.b
srcByteIndex = 0; // step 17.c
} else {
srcByteIndex = srcByteOffset; // step 18
}
var targetByteIndex = (targetOffset * targetElementSize) + targetByteOffset; // step 19
var limit = targetByteIndex + (targetElementSize * srcLength); // step 20
var value;
if (srcType === targetType) { // step 21
// a. NOTE: The transfer must be performed in a manner that preserves the bit-level encoding of the source data.
while (targetByteIndex < limit) { // step 21.b
value = GetValueFromBuffer(srcBuffer, srcByteIndex, 'Uint8', true, 'Unordered'); // step 21.b.i
SetValueInBuffer(targetBuffer, targetByteIndex, 'Uint8', value, true, 'Unordered'); // step 21.b.ii
srcByteIndex += 1; // step 21.b.iii
targetByteIndex += 1; // step 21.b.iv
}
} else { // step 22
while (targetByteIndex < limit) { // step 22.a
value = GetValueFromBuffer(srcBuffer, srcByteIndex, srcType, true, 'Unordered'); // step 22.a.i
SetValueInBuffer(targetBuffer, targetByteIndex, targetType, value, true, 'Unordered'); // step 22.a.ii
srcByteIndex += srcElementSize; // step 22.a.iii
targetByteIndex += targetElementSize; // step 22.a.iv
}
}
};
@@ -0,0 +1,151 @@
/// <reference types="node" />
/// <reference types="node" />
/// <reference types="node" />
import { Duplex } from 'stream';
import { Socket, SocketConnectOpts } from 'net';
declare const DEFAULT_TIMEOUT = 30000;
type SocksProxyType = 4 | 5;
declare const ERRORS: {
InvalidSocksCommand: string;
InvalidSocksCommandForOperation: string;
InvalidSocksCommandChain: string;
InvalidSocksClientOptionsDestination: string;
InvalidSocksClientOptionsExistingSocket: string;
InvalidSocksClientOptionsProxy: string;
InvalidSocksClientOptionsTimeout: string;
InvalidSocksClientOptionsProxiesLength: string;
InvalidSocksClientOptionsCustomAuthRange: string;
InvalidSocksClientOptionsCustomAuthOptions: string;
NegotiationError: string;
SocketClosed: string;
ProxyConnectionTimedOut: string;
InternalError: string;
InvalidSocks4HandshakeResponse: string;
Socks4ProxyRejectedConnection: string;
InvalidSocks4IncomingConnectionResponse: string;
Socks4ProxyRejectedIncomingBoundConnection: string;
InvalidSocks5InitialHandshakeResponse: string;
InvalidSocks5IntiailHandshakeSocksVersion: string;
InvalidSocks5InitialHandshakeNoAcceptedAuthType: string;
InvalidSocks5InitialHandshakeUnknownAuthType: string;
Socks5AuthenticationFailed: string;
InvalidSocks5FinalHandshake: string;
InvalidSocks5FinalHandshakeRejected: string;
InvalidSocks5IncomingConnectionResponse: string;
Socks5ProxyRejectedIncomingBoundConnection: string;
};
declare const SOCKS_INCOMING_PACKET_SIZES: {
Socks5InitialHandshakeResponse: number;
Socks5UserPassAuthenticationResponse: number;
Socks5ResponseHeader: number;
Socks5ResponseIPv4: number;
Socks5ResponseIPv6: number;
Socks5ResponseHostname: (hostNameLength: number) => number;
Socks4Response: number;
};
type SocksCommandOption = 'connect' | 'bind' | 'associate';
declare enum SocksCommand {
connect = 1,
bind = 2,
associate = 3
}
declare enum Socks4Response {
Granted = 90,
Failed = 91,
Rejected = 92,
RejectedIdent = 93
}
declare enum Socks5Auth {
NoAuth = 0,
GSSApi = 1,
UserPass = 2
}
declare const SOCKS5_CUSTOM_AUTH_START = 128;
declare const SOCKS5_CUSTOM_AUTH_END = 254;
declare const SOCKS5_NO_ACCEPTABLE_AUTH = 255;
declare enum Socks5Response {
Granted = 0,
Failure = 1,
NotAllowed = 2,
NetworkUnreachable = 3,
HostUnreachable = 4,
ConnectionRefused = 5,
TTLExpired = 6,
CommandNotSupported = 7,
AddressNotSupported = 8
}
declare enum Socks5HostType {
IPv4 = 1,
Hostname = 3,
IPv6 = 4
}
declare enum SocksClientState {
Created = 0,
Connecting = 1,
Connected = 2,
SentInitialHandshake = 3,
ReceivedInitialHandshakeResponse = 4,
SentAuthentication = 5,
ReceivedAuthenticationResponse = 6,
SentFinalHandshake = 7,
ReceivedFinalResponse = 8,
BoundWaitingForConnection = 9,
Established = 10,
Disconnected = 11,
Error = 99
}
/**
* Represents a SocksProxy
*/
interface SocksProxy {
ipaddress?: string;
host?: string;
port: number;
type: SocksProxyType;
userId?: string;
password?: string;
custom_auth_method?: number;
custom_auth_request_handler?: () => Promise<Buffer>;
custom_auth_response_size?: number;
custom_auth_response_handler?: (data: Buffer) => Promise<boolean>;
}
/**
* Represents a remote host
*/
interface SocksRemoteHost {
host: string;
port: number;
}
/**
* SocksClient connection options.
*/
interface SocksClientOptions {
command: SocksCommandOption;
destination: SocksRemoteHost;
proxy: SocksProxy;
timeout?: number;
existing_socket?: Duplex;
set_tcp_nodelay?: boolean;
socket_options?: SocketConnectOpts;
}
/**
* SocksClient chain connection options.
*/
interface SocksClientChainOptions {
command: 'connect';
destination: SocksRemoteHost;
proxies: SocksProxy[];
timeout?: number;
randomizeChain?: false;
}
interface SocksClientEstablishedEvent {
socket: Socket;
remoteHost?: SocksRemoteHost;
}
type SocksClientBoundEvent = SocksClientEstablishedEvent;
interface SocksUDPFrameDetails {
frameNumber?: number;
remoteHost: SocksRemoteHost;
data: Buffer;
}
export { DEFAULT_TIMEOUT, ERRORS, SocksProxyType, SocksCommand, Socks4Response, Socks5Auth, Socks5HostType, Socks5Response, SocksClientState, SocksProxy, SocksRemoteHost, SocksCommandOption, SocksClientOptions, SocksClientChainOptions, SocksClientEstablishedEvent, SocksClientBoundEvent, SocksUDPFrameDetails, SOCKS_INCOMING_PACKET_SIZES, SOCKS5_CUSTOM_AUTH_START, SOCKS5_CUSTOM_AUTH_END, SOCKS5_NO_ACCEPTABLE_AUTH, };
@@ -0,0 +1 @@
{"version":3,"names":["finalize","deepArr","Object","freeze","flattenToSet","arr","result","Set","stack","length","el","pop","Array","isArray","push","add"],"sources":["../../../src/config/helpers/deep-array.ts"],"sourcesContent":["export type DeepArray<T> = Array<T | ReadonlyDeepArray<T>>;\n\n// Just to make sure that DeepArray<T> is not assignable to ReadonlyDeepArray<T>\ndeclare const __marker: unique symbol;\nexport type ReadonlyDeepArray<T> = ReadonlyArray<T | ReadonlyDeepArray<T>> & {\n [__marker]: true;\n};\n\nexport function finalize<T>(deepArr: DeepArray<T>): ReadonlyDeepArray<T> {\n return Object.freeze(deepArr) as ReadonlyDeepArray<T>;\n}\n\nexport function flattenToSet<T extends string>(\n arr: ReadonlyDeepArray<T>,\n): Set<T> {\n const result = new Set<T>();\n const stack = [arr];\n while (stack.length > 0) {\n for (const el of stack.pop()) {\n if (Array.isArray(el)) stack.push(el as ReadonlyDeepArray<T>);\n else result.add(el as T);\n }\n }\n return result;\n}\n"],"mappings":";;;;;;;AAQO,SAASA,QAAQA,CAAIC,OAAqB,EAAwB;EACvE,OAAOC,MAAM,CAACC,MAAM,CAACF,OAAO,CAAC;AAC/B;AAEO,SAASG,YAAYA,CAC1BC,GAAyB,EACjB;EACR,MAAMC,MAAM,GAAG,IAAIC,GAAG,CAAI,CAAC;EAC3B,MAAMC,KAAK,GAAG,CAACH,GAAG,CAAC;EACnB,OAAOG,KAAK,CAACC,MAAM,GAAG,CAAC,EAAE;IACvB,KAAK,MAAMC,EAAE,IAAIF,KAAK,CAACG,GAAG,CAAC,CAAC,EAAE;MAC5B,IAAIC,KAAK,CAACC,OAAO,CAACH,EAAE,CAAC,EAAEF,KAAK,CAACM,IAAI,CAACJ,EAA0B,CAAC,CAAC,KACzDJ,MAAM,CAACS,GAAG,CAACL,EAAO,CAAC;IAC1B;EACF;EACA,OAAOJ,MAAM;AACf;AAAC","ignoreList":[]}
@@ -0,0 +1,75 @@
// Copyright (c) 2011-2016 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.
#include "AgentLocation.h"
#include <windows.h>
#include <string>
#include "../shared/WinptyAssert.h"
#include "LibWinptyException.h"
#define AGENT_EXE L"winpty-agent.exe"
static HMODULE getCurrentModule() {
HMODULE module;
if (!GetModuleHandleExW(
GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS |
GET_MODULE_HANDLE_EX_FLAG_UNCHANGED_REFCOUNT,
reinterpret_cast<LPCWSTR>(getCurrentModule),
&module)) {
ASSERT(false && "GetModuleHandleEx failed");
}
return module;
}
static std::wstring getModuleFileName(HMODULE module) {
const int bufsize = 4096;
wchar_t path[bufsize];
int size = GetModuleFileNameW(module, path, bufsize);
ASSERT(size != 0 && size != bufsize);
return std::wstring(path);
}
static std::wstring dirname(const std::wstring &path) {
std::wstring::size_type pos = path.find_last_of(L"\\/");
if (pos == std::wstring::npos) {
return L"";
} else {
return path.substr(0, pos);
}
}
static bool pathExists(const std::wstring &path) {
return GetFileAttributesW(path.c_str()) != 0xFFFFFFFF;
}
std::wstring findAgentProgram() {
std::wstring progDir = dirname(getModuleFileName(getCurrentModule()));
std::wstring ret = progDir + (L"\\" AGENT_EXE);
if (!pathExists(ret)) {
throw LibWinptyException(
WINPTY_ERROR_AGENT_EXE_MISSING,
(L"agent executable does not exist: '" + ret + L"'").c_str());
}
return ret;
}
@@ -0,0 +1,101 @@
import cloneDeep = require('lodash.clonedeep');
import isEqual = require('lodash.isequal');
interface AttributeMap {
[key: string]: unknown;
}
namespace AttributeMap {
export function compose(
a: AttributeMap = {},
b: AttributeMap = {},
keepNull = false,
): AttributeMap | undefined {
if (typeof a !== 'object') {
a = {};
}
if (typeof b !== 'object') {
b = {};
}
let attributes = cloneDeep(b);
if (!keepNull) {
attributes = Object.keys(attributes).reduce<AttributeMap>((copy, key) => {
if (attributes[key] != null) {
copy[key] = attributes[key];
}
return copy;
}, {});
}
for (const key in a) {
if (a[key] !== undefined && b[key] === undefined) {
attributes[key] = a[key];
}
}
return Object.keys(attributes).length > 0 ? attributes : undefined;
}
export function diff(
a: AttributeMap = {},
b: AttributeMap = {},
): AttributeMap | undefined {
if (typeof a !== 'object') {
a = {};
}
if (typeof b !== 'object') {
b = {};
}
const attributes = Object.keys(a)
.concat(Object.keys(b))
.reduce<AttributeMap>((attrs, key) => {
if (!isEqual(a[key], b[key])) {
attrs[key] = b[key] === undefined ? null : b[key];
}
return attrs;
}, {});
return Object.keys(attributes).length > 0 ? attributes : undefined;
}
export function invert(
attr: AttributeMap = {},
base: AttributeMap = {},
): AttributeMap {
attr = attr || {};
const baseInverted = Object.keys(base).reduce<AttributeMap>((memo, key) => {
if (base[key] !== attr[key] && attr[key] !== undefined) {
memo[key] = base[key];
}
return memo;
}, {});
return Object.keys(attr).reduce<AttributeMap>((memo, key) => {
if (attr[key] !== base[key] && base[key] === undefined) {
memo[key] = null;
}
return memo;
}, baseInverted);
}
export function transform(
a: AttributeMap | undefined,
b: AttributeMap | undefined,
priority = false,
): AttributeMap | undefined {
if (typeof a !== 'object') {
return b;
}
if (typeof b !== 'object') {
return undefined;
}
if (!priority) {
return b; // b simply overwrites us without priority
}
const attributes = Object.keys(b).reduce<AttributeMap>((attrs, key) => {
if (a[key] === undefined) {
attrs[key] = b[key]; // null is a valid value
}
return attrs;
}, {});
return Object.keys(attributes).length > 0 ? attributes : undefined;
}
}
export default AttributeMap;
@@ -0,0 +1,10 @@
#include <windows.h>
#include "TestUtil.cc"
int main(int argc, char *argv[]) {
int col = atoi(argv[1]);
int row = atoi(argv[2]);
setCursorPos(col, row);
return 0;
}
@@ -0,0 +1,56 @@
'use strict';
var StrictEqualityComparison = require('./StrictEqualityComparison');
var StringToBigInt = require('./StringToBigInt');
var ToNumber = require('./ToNumber');
var ToPrimitive = require('./ToPrimitive');
var isNaN = require('math-intrinsics/isNaN');
var isObject = require('es-object-atoms/isObject');
var isSameType = require('../helpers/isSameType');
// https://262.ecma-international.org/11.0/#sec-abstract-equality-comparison
module.exports = function AbstractEqualityComparison(x, y) {
if (isSameType(x, y)) {
return StrictEqualityComparison(x, y);
}
if (x == null && y == null) {
return true;
}
if (typeof x === 'number' && typeof y === 'string') {
return AbstractEqualityComparison(x, ToNumber(y));
}
if (typeof x === 'string' && typeof y === 'number') {
return AbstractEqualityComparison(ToNumber(x), y);
}
if (typeof x === 'bigint' && typeof y === 'string') {
var n = StringToBigInt(y);
if (isNaN(n)) {
return false;
}
return AbstractEqualityComparison(x, n);
}
if (typeof x === 'string' && typeof y === 'bigint') {
return AbstractEqualityComparison(y, x);
}
if (typeof x === 'boolean') {
return AbstractEqualityComparison(ToNumber(x), y);
}
if (typeof y === 'boolean') {
return AbstractEqualityComparison(x, ToNumber(y));
}
if ((typeof x === 'string' || typeof x === 'number' || typeof x === 'bigint' || typeof x === 'symbol') && isObject(y)) {
return AbstractEqualityComparison(x, ToPrimitive(y));
}
if (isObject(x) && (typeof y === 'string' || typeof y === 'number' || typeof y === 'bigint' || typeof y === 'symbol')) {
return AbstractEqualityComparison(ToPrimitive(x), y);
}
if ((typeof x === 'bigint' && typeof y === 'number') || (typeof x === 'number' && typeof y === 'bigint')) {
if (isNaN(x) || isNaN(y) || x === Infinity || y === Infinity || x === -Infinity || y === -Infinity) {
return false;
}
return x == y; // eslint-disable-line eqeqeq
}
return false;
};
@@ -0,0 +1,18 @@
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
var _index = require('../tokenizer/index');
var _charcodes = require('../util/charcodes');
var _base = require('./base');
var _statement = require('./statement');
function parseFile() {
// If enabled, skip leading hashbang line.
if (
_base.state.pos === 0 &&
_base.input.charCodeAt(0) === _charcodes.charCodes.numberSign &&
_base.input.charCodeAt(1) === _charcodes.charCodes.exclamationMark
) {
_index.skipLineComment.call(void 0, 2);
}
_index.nextToken.call(void 0, );
return _statement.parseTopLevel.call(void 0, );
} exports.parseFile = parseFile;
@@ -0,0 +1,35 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.getTypeOfPropertyOfName = getTypeOfPropertyOfName;
exports.getTypeOfPropertyOfType = getTypeOfPropertyOfType;
function getTypeOfPropertyOfName(checker, type, name, escapedName) {
// Most names are directly usable in the checker and aren't different from escaped names
if (!escapedName || !isSymbol(escapedName)) {
return checker.getTypeOfPropertyOfType(type, name);
}
// Symbolic names may differ in their escaped name compared to their human-readable name
// https://github.com/typescript-eslint/typescript-eslint/issues/2143
const escapedProperty = type
.getProperties()
.find(property => property.escapedName === escapedName);
return escapedProperty
? checker.getDeclaredTypeOfSymbol(escapedProperty)
: undefined;
}
function getTypeOfPropertyOfType(checker, type, property) {
return getTypeOfPropertyOfName(checker, type, property.getName(), property.getEscapedName());
}
// Symbolic names need to be specially handled because TS api is not sufficient for these cases.
// Source based on:
// https://github.com/microsoft/TypeScript/blob/0043abe982aae0d35f8df59f9715be6ada758ff7/src/compiler/utilities.ts#L3388-L3402
function isSymbol(escapedName) {
return isKnownSymbol(escapedName) || isPrivateIdentifierSymbol(escapedName);
}
// case for escapedName: "__@foo@10", name: "__@foo@10"
function isKnownSymbol(escapedName) {
return escapedName.startsWith('__@');
}
// case for escapedName: "__#1@#foo", name: "#foo"
function isPrivateIdentifierSymbol(escapedName) {
return escapedName.startsWith('__#');
}
@@ -0,0 +1,142 @@
var $82z6W$react = require("react");
function $parcel$export(e, n, v, s) {
Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
}
$parcel$export(module.exports, "useHover", () => $ffbc150311c75f01$export$ae780daf29e6d456);
/*
* 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.
*/ // Portions of the code in this file are based on code from react.
// Original licensing for the following can be found in the
// NOTICE file in the root directory of this source tree.
// See https://github.com/facebook/react/tree/cc7c1aece46a6b69b41958d731e0fd27c94bfc6c/packages/react-interactions
// iOS fires onPointerEnter twice: once with pointerType="touch" and again with pointerType="mouse".
// We want to ignore these emulated events so they do not trigger hover behavior.
// See https://bugs.webkit.org/show_bug.cgi?id=214609.
let $ffbc150311c75f01$var$globalIgnoreEmulatedMouseEvents = false;
let $ffbc150311c75f01$var$hoverCount = 0;
function $ffbc150311c75f01$var$setGlobalIgnoreEmulatedMouseEvents() {
$ffbc150311c75f01$var$globalIgnoreEmulatedMouseEvents = true;
// Clear globalIgnoreEmulatedMouseEvents after a short timeout. iOS fires onPointerEnter
// with pointerType="mouse" immediately after onPointerUp and before onFocus. On other
// devices that don't have this quirk, we don't want to ignore a mouse hover sometime in
// the distant future because a user previously touched the element.
setTimeout(()=>{
$ffbc150311c75f01$var$globalIgnoreEmulatedMouseEvents = false;
}, 50);
}
function $ffbc150311c75f01$var$handleGlobalPointerEvent(e) {
if (e.pointerType === 'touch') $ffbc150311c75f01$var$setGlobalIgnoreEmulatedMouseEvents();
}
function $ffbc150311c75f01$var$setupGlobalTouchEvents() {
if (typeof document === 'undefined') return;
if (typeof PointerEvent !== 'undefined') document.addEventListener('pointerup', $ffbc150311c75f01$var$handleGlobalPointerEvent);
else document.addEventListener('touchend', $ffbc150311c75f01$var$setGlobalIgnoreEmulatedMouseEvents);
$ffbc150311c75f01$var$hoverCount++;
return ()=>{
$ffbc150311c75f01$var$hoverCount--;
if ($ffbc150311c75f01$var$hoverCount > 0) return;
if (typeof PointerEvent !== 'undefined') document.removeEventListener('pointerup', $ffbc150311c75f01$var$handleGlobalPointerEvent);
else document.removeEventListener('touchend', $ffbc150311c75f01$var$setGlobalIgnoreEmulatedMouseEvents);
};
}
function $ffbc150311c75f01$export$ae780daf29e6d456(props) {
let { onHoverStart: onHoverStart, onHoverChange: onHoverChange, onHoverEnd: onHoverEnd, isDisabled: isDisabled } = props;
let [isHovered, setHovered] = (0, $82z6W$react.useState)(false);
let state = (0, $82z6W$react.useRef)({
isHovered: false,
ignoreEmulatedMouseEvents: false,
pointerType: '',
target: null
}).current;
(0, $82z6W$react.useEffect)($ffbc150311c75f01$var$setupGlobalTouchEvents, []);
let { hoverProps: hoverProps, triggerHoverEnd: triggerHoverEnd } = (0, $82z6W$react.useMemo)(()=>{
let triggerHoverStart = (event, pointerType)=>{
state.pointerType = pointerType;
if (isDisabled || pointerType === 'touch' || state.isHovered || !event.currentTarget.contains(event.target)) return;
state.isHovered = true;
let target = event.currentTarget;
state.target = target;
if (onHoverStart) onHoverStart({
type: 'hoverstart',
target: target,
pointerType: pointerType
});
if (onHoverChange) onHoverChange(true);
setHovered(true);
};
let triggerHoverEnd = (event, pointerType)=>{
state.pointerType = '';
state.target = null;
if (pointerType === 'touch' || !state.isHovered) return;
state.isHovered = false;
let target = event.currentTarget;
if (onHoverEnd) onHoverEnd({
type: 'hoverend',
target: target,
pointerType: pointerType
});
if (onHoverChange) onHoverChange(false);
setHovered(false);
};
let hoverProps = {};
if (typeof PointerEvent !== 'undefined') {
hoverProps.onPointerEnter = (e)=>{
if ($ffbc150311c75f01$var$globalIgnoreEmulatedMouseEvents && e.pointerType === 'mouse') return;
triggerHoverStart(e, e.pointerType);
};
hoverProps.onPointerLeave = (e)=>{
if (!isDisabled && e.currentTarget.contains(e.target)) triggerHoverEnd(e, e.pointerType);
};
} else {
hoverProps.onTouchStart = ()=>{
state.ignoreEmulatedMouseEvents = true;
};
hoverProps.onMouseEnter = (e)=>{
if (!state.ignoreEmulatedMouseEvents && !$ffbc150311c75f01$var$globalIgnoreEmulatedMouseEvents) triggerHoverStart(e, 'mouse');
state.ignoreEmulatedMouseEvents = false;
};
hoverProps.onMouseLeave = (e)=>{
if (!isDisabled && e.currentTarget.contains(e.target)) triggerHoverEnd(e, 'mouse');
};
}
return {
hoverProps: hoverProps,
triggerHoverEnd: triggerHoverEnd
};
}, [
onHoverStart,
onHoverChange,
onHoverEnd,
isDisabled,
state
]);
(0, $82z6W$react.useEffect)(()=>{
// Call the triggerHoverEnd as soon as isDisabled changes to true
// Safe to call triggerHoverEnd, it will early return if we aren't currently hovering
if (isDisabled) triggerHoverEnd({
currentTarget: state.target
}, state.pointerType);
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [
isDisabled
]);
return {
hoverProps: hoverProps,
isHovered: isHovered
};
}
//# sourceMappingURL=useHover.main.js.map
@@ -0,0 +1,9 @@
'use strict';
var callBound = require('call-bound');
var $strSlice = callBound('String.prototype.slice');
module.exports = function padTimeComponent(c, count) {
return $strSlice('00' + c, -(count || 2));
};
@@ -0,0 +1,70 @@
'use strict';
Object.defineProperty(exports, '__esModule', { value: true });
function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
var React = require('react');
var React__default = _interopDefault(React);
const hiddenStyles = {
display: 'none'
};
function HiddenText(_ref) {
let {
id,
value
} = _ref;
return React__default.createElement("div", {
id: id,
style: hiddenStyles
}, value);
}
function LiveRegion(_ref) {
let {
id,
announcement,
ariaLiveType = "assertive"
} = _ref;
// Hide element visually but keep it readable by screen readers
const visuallyHidden = {
position: 'fixed',
top: 0,
left: 0,
width: 1,
height: 1,
margin: -1,
border: 0,
padding: 0,
overflow: 'hidden',
clip: 'rect(0 0 0 0)',
clipPath: 'inset(100%)',
whiteSpace: 'nowrap'
};
return React__default.createElement("div", {
id: id,
style: visuallyHidden,
role: "status",
"aria-live": ariaLiveType,
"aria-atomic": true
}, announcement);
}
function useAnnouncement() {
const [announcement, setAnnouncement] = React.useState('');
const announce = React.useCallback(value => {
if (value != null) {
setAnnouncement(value);
}
}, []);
return {
announce,
announcement
};
}
exports.HiddenText = HiddenText;
exports.LiveRegion = LiveRegion;
exports.useAnnouncement = useAnnouncement;
//# sourceMappingURL=accessibility.cjs.development.js.map
@@ -0,0 +1,37 @@
import baseForRight from './_baseForRight.js';
import castFunction from './_castFunction.js';
import keysIn from './keysIn.js';
/**
* This method is like `_.forIn` except that it iterates over properties of
* `object` in the opposite order.
*
* @static
* @memberOf _
* @since 2.0.0
* @category Object
* @param {Object} object The object to iterate over.
* @param {Function} [iteratee=_.identity] The function invoked per iteration.
* @returns {Object} Returns `object`.
* @see _.forIn
* @example
*
* function Foo() {
* this.a = 1;
* this.b = 2;
* }
*
* Foo.prototype.c = 3;
*
* _.forInRight(new Foo, function(value, key) {
* console.log(key);
* });
* // => Logs 'c', 'b', then 'a' assuming `_.forIn` logs 'a', 'b', then 'c'.
*/
function forInRight(object, iteratee) {
return object == null
? object
: baseForRight(object, castFunction(iteratee), keysIn);
}
export default forInRight;
@@ -0,0 +1,111 @@
import CodePathSegment = require("./code-path-segment");
export = CodePath;
/**
* A code path.
*/
declare class CodePath {
/**
* Gets the state of a given code path.
* @param {CodePath} codePath A code path to get.
* @returns {CodePathState} The state of the code path.
*/
static getState(codePath: CodePath): CodePathState;
/**
* Creates a new instance.
* @param {Object} options Options for the function (see below).
* @param {string} options.id An identifier.
* @param {string} options.origin The type of code path origin.
* @param {CodePath|null} options.upper The code path of the upper function scope.
* @param {Function} options.onLooped A callback function to notify looping.
*/
constructor({ id, origin, upper, onLooped }: {
id: string;
origin: string;
upper: CodePath | null;
onLooped: Function;
});
/**
* The identifier of this code path.
* Rules use it to store additional information of each rule.
* @type {string}
*/
id: string;
/**
* The reason that this code path was started. May be "program",
* "function", "class-field-initializer", or "class-static-block".
* @type {string}
*/
origin: string;
/**
* The code path of the upper function scope.
* @type {CodePath|null}
*/
upper: CodePath | null;
/**
* The code paths of nested function scopes.
* @type {CodePath[]}
*/
childCodePaths: CodePath[];
/**
* The initial code path segment. This is the segment that is at the head
* of the code path.
* This is a passthrough to the underlying `CodePathState`.
* @type {CodePathSegment}
*/
get initialSegment(): CodePathSegment;
/**
* Final code path segments. These are the terminal (tail) segments in the
* code path, which is the combination of `returnedSegments` and `thrownSegments`.
* All segments in this array are reachable.
* This is a passthrough to the underlying `CodePathState`.
* @type {CodePathSegment[]}
*/
get finalSegments(): CodePathSegment[];
/**
* Final code path segments that represent normal completion of the code path.
* For functions, this means both explicit `return` statements and implicit returns,
* such as the last reachable segment in a function that does not have an
* explicit `return` as this implicitly returns `undefined`. For scripts,
* modules, class field initializers, and class static blocks, this means
* all lines of code have been executed.
* These segments are also present in `finalSegments`.
* This is a passthrough to the underlying `CodePathState`.
* @type {CodePathSegment[]}
*/
get returnedSegments(): CodePathSegment[];
/**
* Final code path segments that represent `throw` statements.
* This is a passthrough to the underlying `CodePathState`.
* These segments are also present in `finalSegments`.
* @type {CodePathSegment[]}
*/
get thrownSegments(): CodePathSegment[];
/**
* Traverses all segments in this code path.
*
* codePath.traverseSegments((segment, controller) => {
* // do something.
* });
*
* This method enumerates segments in order from the head.
*
* The `controller` argument has two methods:
*
* - `skip()` - skips the following segments in this branch
* - `break()` - skips all following segments in the traversal
*
* A note on the parameters: the `options` argument is optional. This means
* the first argument might be an options object or the callback function.
* @param {Object} [optionsOrCallback] Optional first and last segments to traverse.
* @param {CodePathSegment} [optionsOrCallback.first] The first segment to traverse.
* @param {CodePathSegment} [optionsOrCallback.last] The last segment to traverse.
* @param {Function} callback A callback function.
* @returns {void}
*/
traverseSegments(optionsOrCallback: {
first?: CodePathSegment;
last?: CodePathSegment;
} | Function, callback?: Function): void;
}
import CodePathState = require("./code-path-state");
@@ -0,0 +1,66 @@
/**
* @fileoverview Enforce <marquee> elements are not used.
* @author Ethan Cohen
*/
// -----------------------------------------------------------------------------
// Requirements
// -----------------------------------------------------------------------------
import { RuleTester } from 'eslint';
import parserOptionsMapper from '../../__util__/parserOptionsMapper';
import rule from '../../../src/rules/accessible-emoji';
import parsers from '../../__util__/helpers/parsers';
// -----------------------------------------------------------------------------
// Tests
// -----------------------------------------------------------------------------
const ruleTester = new RuleTester();
const expectedError = {
message: 'Emojis should be wrapped in <span>, have role="img", and have an accessible description with aria-label or aria-labelledby.',
type: 'JSXOpeningElement',
};
ruleTester.run('accessible-emoji', rule, {
valid: parsers.all([].concat(
{ code: '<div />;' },
{ code: '<span />' },
{ code: '<span>No emoji here!</span>' },
{ code: '<span role="img" aria-label="Panda face">🐼</span>' },
{ code: '<span role="img" aria-label="Snowman">&#9731;</span>' },
{ code: '<span role="img" aria-labelledby="id1">🐼</span>' },
{ code: '<span role="img" aria-labelledby="id1">&#9731;</span>' },
{ code: '<span role="img" aria-labelledby="id1" aria-label="Snowman">&#9731;</span>' },
{ code: '<span>{props.emoji}</span>' },
{ code: '<span aria-hidden>{props.emoji}</span>' },
{ code: '<span aria-hidden="true">🐼</span>' },
{ code: '<span aria-hidden>🐼</span>' },
{ code: '<div aria-hidden="true">🐼</div>' },
{ code: '<input type="hidden">🐼</input>' },
{
code: '<CustomInput type="hidden">🐼</CustomInput>',
settings: { 'jsx-a11y': { components: { CustomInput: 'input' } } },
},
{
code: '<Box as="input" type="hidden">🐼</Box>',
settings: { 'jsx-a11y': { polymorphicPropName: 'as' } },
},
)).map(parserOptionsMapper),
invalid: parsers.all([].concat(
{ code: '<span>🐼</span>', errors: [expectedError] },
{ code: '<span>foo🐼bar</span>', errors: [expectedError] },
{ code: '<span>foo 🐼 bar</span>', errors: [expectedError] },
{ code: '<i role="img" aria-label="Panda face">🐼</i>', errors: [expectedError] },
{ code: '<i role="img" aria-labelledby="id1">🐼</i>', errors: [expectedError] },
{ code: '<Foo>🐼</Foo>', errors: [expectedError] },
{ code: '<span aria-hidden="false">🐼</span>', errors: [expectedError] },
{ code: '<CustomInput type="hidden">🐼</CustomInput>', errors: [expectedError] },
{
code: '<Box as="span">🐼</Box>',
settings: { 'jsx-a11y': { polymorphicPropName: 'as' } },
errors: [expectedError],
},
)).map(parserOptionsMapper),
});
@@ -0,0 +1 @@
{"version":3,"file":"decode_codepoint.js","sourceRoot":"https://raw.githubusercontent.com/fb55/entities/61afd4701eaa736978b13c7351cd3de9a96b04bc/src/","sources":["decode_codepoint.ts"],"names":[],"mappings":";AAAA,qHAAqH;;;;AAErH,IAAM,SAAS,GAAG,IAAI,GAAG,CAAC;IACtB,CAAC,CAAC,EAAE,KAAK,CAAC;IACV,sDAAsD;IACtD,CAAC,GAAG,EAAE,IAAI,CAAC;IACX,CAAC,GAAG,EAAE,IAAI,CAAC;IACX,CAAC,GAAG,EAAE,GAAG,CAAC;IACV,CAAC,GAAG,EAAE,IAAI,CAAC;IACX,CAAC,GAAG,EAAE,IAAI,CAAC;IACX,CAAC,GAAG,EAAE,IAAI,CAAC;IACX,CAAC,GAAG,EAAE,IAAI,CAAC;IACX,CAAC,GAAG,EAAE,GAAG,CAAC;IACV,CAAC,GAAG,EAAE,IAAI,CAAC;IACX,CAAC,GAAG,EAAE,GAAG,CAAC;IACV,CAAC,GAAG,EAAE,IAAI,CAAC;IACX,CAAC,GAAG,EAAE,GAAG,CAAC;IACV,CAAC,GAAG,EAAE,GAAG,CAAC;IACV,CAAC,GAAG,EAAE,IAAI,CAAC;IACX,CAAC,GAAG,EAAE,IAAI,CAAC;IACX,CAAC,GAAG,EAAE,IAAI,CAAC;IACX,CAAC,GAAG,EAAE,IAAI,CAAC;IAC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AAC,CAAC,CAAC;AACtD,CAAC;AAFD,kCAEC"}
@@ -0,0 +1,220 @@
import {calculatePosition as $edcf132a9284368a$export$b3ceb0cbf1056d98, getRect as $edcf132a9284368a$export$4b834cebd9e5cebe} from "./calculatePosition.module.js";
import {useCloseOnScroll as $dd149f63282afbbf$export$18fc8428861184da} from "./useCloseOnScroll.module.js";
import {useState as $39EOa$useState, useRef as $39EOa$useRef, useEffect as $39EOa$useEffect, useCallback as $39EOa$useCallback} from "react";
import {useLayoutEffect as $39EOa$useLayoutEffect, useResizeObserver as $39EOa$useResizeObserver} from "@react-aria/utils";
import {useLocale as $39EOa$useLocale} from "@react-aria/i18n";
/*
* 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.
*/
let $2a41e45df1593e64$var$visualViewport = typeof document !== 'undefined' ? window.visualViewport : null;
function $2a41e45df1593e64$export$d39e1813b3bdd0e1(props) {
let { direction: direction } = (0, $39EOa$useLocale)();
let { arrowSize: arrowSize, targetRef: targetRef, overlayRef: overlayRef, arrowRef: arrowRef, scrollRef: scrollRef = overlayRef, placement: placement = 'bottom', containerPadding: containerPadding = 12, shouldFlip: shouldFlip = true, boundaryElement: boundaryElement = typeof document !== 'undefined' ? document.body : null, offset: offset = 0, crossOffset: crossOffset = 0, shouldUpdatePosition: shouldUpdatePosition = true, isOpen: isOpen = true, onClose: onClose, maxHeight: maxHeight, arrowBoundaryOffset: arrowBoundaryOffset = 0 } = props;
let [position, setPosition] = (0, $39EOa$useState)(null);
let deps = [
shouldUpdatePosition,
placement,
overlayRef.current,
targetRef.current,
arrowRef === null || arrowRef === void 0 ? void 0 : arrowRef.current,
scrollRef.current,
containerPadding,
shouldFlip,
boundaryElement,
offset,
crossOffset,
isOpen,
direction,
maxHeight,
arrowBoundaryOffset,
arrowSize
];
// Note, the position freezing breaks if body sizes itself dynamicly with the visual viewport but that might
// just be a non-realistic use case
// Upon opening a overlay, record the current visual viewport scale so we can freeze the overlay styles
let lastScale = (0, $39EOa$useRef)($2a41e45df1593e64$var$visualViewport === null || $2a41e45df1593e64$var$visualViewport === void 0 ? void 0 : $2a41e45df1593e64$var$visualViewport.scale);
(0, $39EOa$useEffect)(()=>{
if (isOpen) lastScale.current = $2a41e45df1593e64$var$visualViewport === null || $2a41e45df1593e64$var$visualViewport === void 0 ? void 0 : $2a41e45df1593e64$var$visualViewport.scale;
}, [
isOpen
]);
let updatePosition = (0, $39EOa$useCallback)(()=>{
if (shouldUpdatePosition === false || !isOpen || !overlayRef.current || !targetRef.current || !boundaryElement) return;
if (($2a41e45df1593e64$var$visualViewport === null || $2a41e45df1593e64$var$visualViewport === void 0 ? void 0 : $2a41e45df1593e64$var$visualViewport.scale) !== lastScale.current) return;
// Determine a scroll anchor based on the focused element.
// This stores the offset of the anchor element from the scroll container
// so it can be restored after repositioning. This way if the overlay height
// changes, the focused element appears to stay in the same position.
let anchor = null;
if (scrollRef.current && scrollRef.current.contains(document.activeElement)) {
var _document_activeElement;
let anchorRect = (_document_activeElement = document.activeElement) === null || _document_activeElement === void 0 ? void 0 : _document_activeElement.getBoundingClientRect();
let scrollRect = scrollRef.current.getBoundingClientRect();
var _anchorRect_top;
// Anchor from the top if the offset is in the top half of the scrollable element,
// otherwise anchor from the bottom.
anchor = {
type: 'top',
offset: ((_anchorRect_top = anchorRect === null || anchorRect === void 0 ? void 0 : anchorRect.top) !== null && _anchorRect_top !== void 0 ? _anchorRect_top : 0) - scrollRect.top
};
if (anchor.offset > scrollRect.height / 2) {
anchor.type = 'bottom';
var _anchorRect_bottom;
anchor.offset = ((_anchorRect_bottom = anchorRect === null || anchorRect === void 0 ? void 0 : anchorRect.bottom) !== null && _anchorRect_bottom !== void 0 ? _anchorRect_bottom : 0) - scrollRect.bottom;
}
}
// Always reset the overlay's previous max height if not defined by the user so that we can compensate for
// RAC collections populating after a second render and properly set a correct max height + positioning when it populates.
let overlay = overlayRef.current;
if (!maxHeight && overlayRef.current) {
var _window_visualViewport;
overlay.style.top = '0px';
overlay.style.bottom = '';
var _window_visualViewport_height;
overlay.style.maxHeight = ((_window_visualViewport_height = (_window_visualViewport = window.visualViewport) === null || _window_visualViewport === void 0 ? void 0 : _window_visualViewport.height) !== null && _window_visualViewport_height !== void 0 ? _window_visualViewport_height : window.innerHeight) + 'px';
}
let position = (0, $edcf132a9284368a$export$b3ceb0cbf1056d98)({
placement: $2a41e45df1593e64$var$translateRTL(placement, direction),
overlayNode: overlayRef.current,
targetNode: targetRef.current,
scrollNode: scrollRef.current || overlayRef.current,
padding: containerPadding,
shouldFlip: shouldFlip,
boundaryElement: boundaryElement,
offset: offset,
crossOffset: crossOffset,
maxHeight: maxHeight,
arrowSize: arrowSize !== null && arrowSize !== void 0 ? arrowSize : (arrowRef === null || arrowRef === void 0 ? void 0 : arrowRef.current) ? (0, $edcf132a9284368a$export$4b834cebd9e5cebe)(arrowRef.current, true).width : 0,
arrowBoundaryOffset: arrowBoundaryOffset
});
if (!position.position) return;
// Modify overlay styles directly so positioning happens immediately without the need of a second render
// This is so we don't have to delay autoFocus scrolling or delay applying preventScroll for popovers
overlay.style.top = '';
overlay.style.bottom = '';
overlay.style.left = '';
overlay.style.right = '';
Object.keys(position.position).forEach((key)=>overlay.style[key] = position.position[key] + 'px');
overlay.style.maxHeight = position.maxHeight != null ? position.maxHeight + 'px' : '';
// Restore scroll position relative to anchor element.
if (anchor && document.activeElement && scrollRef.current) {
let anchorRect = document.activeElement.getBoundingClientRect();
let scrollRect = scrollRef.current.getBoundingClientRect();
let newOffset = anchorRect[anchor.type] - scrollRect[anchor.type];
scrollRef.current.scrollTop += newOffset - anchor.offset;
}
// Trigger a set state for a second render anyway for arrow positioning
setPosition(position);
// eslint-disable-next-line react-hooks/exhaustive-deps
}, deps);
// Update position when anything changes
// eslint-disable-next-line react-hooks/exhaustive-deps
(0, $39EOa$useLayoutEffect)(updatePosition, deps);
// Update position on window resize
$2a41e45df1593e64$var$useResize(updatePosition);
// Update position when the overlay changes size (might need to flip).
(0, $39EOa$useResizeObserver)({
ref: overlayRef,
onResize: updatePosition
});
// Update position when the target changes size (might need to flip).
(0, $39EOa$useResizeObserver)({
ref: targetRef,
onResize: updatePosition
});
// Reposition the overlay and do not close on scroll while the visual viewport is resizing.
// This will ensure that overlays adjust their positioning when the iOS virtual keyboard appears.
let isResizing = (0, $39EOa$useRef)(false);
(0, $39EOa$useLayoutEffect)(()=>{
let timeout;
let onResize = ()=>{
isResizing.current = true;
clearTimeout(timeout);
timeout = setTimeout(()=>{
isResizing.current = false;
}, 500);
updatePosition();
};
// Only reposition the overlay if a scroll event happens immediately as a result of resize (aka the virtual keyboard has appears)
// We don't want to reposition the overlay if the user has pinch zoomed in and is scrolling the viewport around.
let onScroll = ()=>{
if (isResizing.current) onResize();
};
$2a41e45df1593e64$var$visualViewport === null || $2a41e45df1593e64$var$visualViewport === void 0 ? void 0 : $2a41e45df1593e64$var$visualViewport.addEventListener('resize', onResize);
$2a41e45df1593e64$var$visualViewport === null || $2a41e45df1593e64$var$visualViewport === void 0 ? void 0 : $2a41e45df1593e64$var$visualViewport.addEventListener('scroll', onScroll);
return ()=>{
$2a41e45df1593e64$var$visualViewport === null || $2a41e45df1593e64$var$visualViewport === void 0 ? void 0 : $2a41e45df1593e64$var$visualViewport.removeEventListener('resize', onResize);
$2a41e45df1593e64$var$visualViewport === null || $2a41e45df1593e64$var$visualViewport === void 0 ? void 0 : $2a41e45df1593e64$var$visualViewport.removeEventListener('scroll', onScroll);
};
}, [
updatePosition
]);
let close = (0, $39EOa$useCallback)(()=>{
if (!isResizing.current) onClose === null || onClose === void 0 ? void 0 : onClose();
}, [
onClose,
isResizing
]);
// When scrolling a parent scrollable region of the trigger (other than the body),
// we hide the popover. Otherwise, its position would be incorrect.
(0, $dd149f63282afbbf$export$18fc8428861184da)({
triggerRef: targetRef,
isOpen: isOpen,
onClose: onClose && close
});
var _position_maxHeight, _position_placement, _position_triggerAnchorPoint;
return {
overlayProps: {
style: {
position: position ? 'absolute' : 'fixed',
top: !position ? 0 : undefined,
left: !position ? 0 : undefined,
zIndex: 100000,
...position === null || position === void 0 ? void 0 : position.position,
maxHeight: (_position_maxHeight = position === null || position === void 0 ? void 0 : position.maxHeight) !== null && _position_maxHeight !== void 0 ? _position_maxHeight : '100vh'
}
},
placement: (_position_placement = position === null || position === void 0 ? void 0 : position.placement) !== null && _position_placement !== void 0 ? _position_placement : null,
triggerAnchorPoint: (_position_triggerAnchorPoint = position === null || position === void 0 ? void 0 : position.triggerAnchorPoint) !== null && _position_triggerAnchorPoint !== void 0 ? _position_triggerAnchorPoint : null,
arrowProps: {
'aria-hidden': 'true',
role: 'presentation',
style: {
left: position === null || position === void 0 ? void 0 : position.arrowOffsetLeft,
top: position === null || position === void 0 ? void 0 : position.arrowOffsetTop
}
},
updatePosition: updatePosition
};
}
function $2a41e45df1593e64$var$useResize(onResize) {
(0, $39EOa$useLayoutEffect)(()=>{
window.addEventListener('resize', onResize, false);
return ()=>{
window.removeEventListener('resize', onResize, false);
};
}, [
onResize
]);
}
function $2a41e45df1593e64$var$translateRTL(position, direction) {
if (direction === 'rtl') return position.replace('start', 'right').replace('end', 'left');
return position.replace('start', 'left').replace('end', 'right');
}
export {$2a41e45df1593e64$export$d39e1813b3bdd0e1 as useOverlayPosition};
//# sourceMappingURL=useOverlayPosition.module.js.map
@@ -0,0 +1,45 @@
//#region src/index.ts
const table = /* @__PURE__ */ new WeakMap();
let counter = 0;
const { toString } = Object.prototype;
const isType = (arg, type) => toString.call(arg) === `[object ${type}]`;
const isPlainObject = (val) => {
const prototype = Object.getPrototypeOf(val);
return prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null;
};
function stableHash(arg, crossRealm) {
const type = typeof arg;
const constructor = arg === null || arg === void 0 ? void 0 : arg.constructor;
const isDate = crossRealm ? isType(arg, "Date") : constructor === Date;
if (Object(arg) === arg && !isDate && !(crossRealm ? isType(arg, "RegExp") : constructor === RegExp)) {
const arg_ = arg;
let result = table.get(arg_);
if (result) return result;
result = ++counter + "~";
table.set(arg_, result);
let index;
if (crossRealm ? Array.isArray(arg) : constructor === Array) {
const arg_$1 = arg;
result = "@";
for (index = 0; index < arg_$1.length; index++) result += stableHash(arg_$1[index], crossRealm) + ",";
table.set(arg_$1, result);
} else if (crossRealm ? isPlainObject(arg_) : constructor === null || constructor === Object) {
result = "#";
const keys = Object.keys(arg_).sort();
while ((index = keys.pop()) !== void 0) {
const index_ = index;
if (arg_[index_] !== void 0) result += index + ":" + stableHash(arg_[index_], crossRealm) + ",";
}
table.set(arg_, result);
}
return result;
}
if (isDate) return arg.toJSON();
if (type === "symbol") return arg.toString();
return type === "string" ? JSON.stringify(arg) : "" + arg;
}
//#endregion
exports.hash = stableHash;
exports.stableHash = stableHash;
@@ -0,0 +1,59 @@
/**
* @author Toru Nagashima
* See LICENSE file in root directory for full license.
*/
"use strict"
/**
* @typedef {string[]} AllowModules
*/
/**
* @type {AllowModules}
*/
const DEFAULT_VALUE = []
/**
* @typedef {{allowModules?: AllowModules}|undefined} Option
*/
/**
* Gets `allowModules` property from a given option object.
*
* @param {Option} option - An option object to get.
* @returns {AllowModules|null} The `allowModules` value, or `null`.
*/
function get(option) {
if (Array.isArray(option?.allowModules)) {
return option.allowModules.map(String)
}
return null
}
/**
* Gets "allowModules" setting.
*
* 1. This checks `options` property, then returns it if exists.
* 2. This checks `settings.n` | `settings.node` property, then returns it if exists.
* 3. This returns `[]`.
*
* @param {import('eslint').Rule.RuleContext} context - The rule context.
* @returns {AllowModules} A list of extensions.
*/
module.exports = function getAllowModules(context) {
return (
get(/** @type {Option} */ (context.options[0])) ??
get(/** @type {Option} */ (context.settings?.n)) ??
get(/** @type {Option} */ (context.settings?.node)) ??
DEFAULT_VALUE
)
}
module.exports.schema = {
type: "array",
items: {
type: "string",
pattern: "^(?:virtual:)?(?:@[a-zA-Z0-9_\\-.]+/)?[a-zA-Z0-9_\\-.]+$",
},
uniqueItems: true,
}
@@ -0,0 +1,9 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.getBaseType = getBaseType;
function getBaseType(type) {
const prototype = Object.getPrototypeOf(type.prototype);
const baseType = prototype?.constructor;
return baseType;
}
//# sourceMappingURL=getBaseType.js.map
@@ -0,0 +1,2 @@
!function(n,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(n="undefined"!=typeof globalThis?globalThis:n||self).InlineStyleParser=e()}(this,(function(){"use strict";var n=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,e=/\n/g,r=/^\s*/,t=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,i=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,u=/^[;\s]*/,c=/^\s+|\s+$/g,f="";function s(n){return n?n.replace(c,f):f}return function(c,a){if("string"!=typeof c)throw new TypeError("First argument must be a string");if(!c)return[];a=a||{};var l=1,p=1;function h(n){var r=n.match(e);r&&(l+=r.length);var t=n.lastIndexOf("\n");p=~t?n.length-t:p+n.length}function m(){var n={line:l,column:p};return function(e){return e.position=new v(n),y(),e}}function v(n){this.start=n,this.end={line:l,column:p},this.source=a.source}function d(n){var e=new Error(a.source+":"+l+":"+p+": "+n);if(e.reason=n,e.filename=a.source,e.line=l,e.column=p,e.source=c,!a.silent)throw e}function g(n){var e=n.exec(c);if(e){var r=e[0];return h(r),c=c.slice(r.length),e}}function y(){g(r)}function w(n){var e;for(n=n||[];e=A();)!1!==e&&n.push(e);return n}function A(){var n=m();if("/"==c.charAt(0)&&"*"==c.charAt(1)){for(var e=2;f!=c.charAt(e)&&("*"!=c.charAt(e)||"/"!=c.charAt(e+1));)++e;if(e+=2,f===c.charAt(e-1))return d("End of comment missing");var r=c.slice(2,e-2);return p+=2,h(r),c=c.slice(e),p+=2,n({type:"comment",comment:r})}}function b(){var e=m(),r=g(t);if(r){if(A(),!g(o))return d("property missing ':'");var c=g(i),a=e({type:"declaration",property:s(r[0].replace(n,f)),value:c?s(c[0].replace(n,f)):f});return g(u),a}}return v.prototype.content=c,y(),function(){var n,e=[];for(w(e);n=b();)!1!==n&&(e.push(n),w(e));return e}()}}));
//# sourceMappingURL=inline-style-parser.min.js.map
@@ -0,0 +1,2 @@
import type { LibDefinition } from '../variable';
export declare const esnext_disposable: LibDefinition;
@@ -0,0 +1,2 @@
import type { LibDefinition } from '../variable';
export declare const es2024_object: LibDefinition;
@@ -0,0 +1,936 @@
export default `flf2a$ 9 8 13 16 16
Epic by Claude Martins 12/94
Figlet release 2.1 -- 12 Aug 1994
Permission is hereby given to modify this font, as long as the
modifier's name is placed on a comment line.
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
8 - height of a character, not including descenders
13 - max line length (excluding comment lines) + a fudge factor
16 - default smushmode for this font
16 - number of comment lines
$$@
$$@
$$@
$$@
$$@
$$@
$$@
$$@
$$@@
_ @
( )@
| |@
| |@
| |@
(_)@
_ @
(_)@
@@
_ _ @
( )( )@
\\||/ @
@
@
@
@
@
@@
_ _ @
( ) ( ) @
_| |_| |_ @
(_ _ _)@
_| (_) |_ @
(_ _ _)@
| | | | @
(_) (_) @
@@
_ @
__|_|___@
( _____/@
| (|_|__ @
(_____ )@
/\\_|_|) |@
\\_______)@
|_| @
@@
@
/\\@
() / /@
/ / @
/ / @
/ / @
/ / ()@
\\/ @
@@
__ @
/__\\ @
( \\/ ) @
\\ / @
/ \\/\\@
/ /\\ /@
( \\/ \\@
\\___/\\/@
@@
_ @
( )@
|/ @
@
@
@
@
@
@@
_ @
/ )@
/ / @
( ( @
| | @
( ( @
\\ \\ @
\\_)@
@@
_ @
( \\ @
\\ \\ @
) )@
| |@
) )@
/ / @
(_/ @
@@
@
/\\ /\\ @
\\ \\ / / @
_) () (_ @
(_ _)@
) () ( @
/ / \\ \\ @
\\/ \\/ @
@@
_ @
( ) @
| | @
__| |__ @
(__ __)@
| | @
| | @
(_) @
@@
@
@
@
@
@
@
_ @
( )@
|/ @@
@
@
@
_____ @
(_____)@
@
@
@
@@
@
@
@
@
@
@
_ @
(_)@
@@
@
/\\@
/ /@
/ / @
/ / @
/ / @
/ / @
\\/ @
@@
_______ @
( __ )@
| ( ) |@
| | / |@
| (/ /) |@
| / | |@
| (__) |@
(_______)@
@@
__ @
/ \\ @
\\/) ) @
| | @
| | @
| | @
__) (_@
\\____/@
@@
_______ @
/ ___ )@
\\/ ) |@
/ )@
_/ / @
/ _/ @
( (__/\\@
\\_______/@
@@
______ @
/ ___ \\ @
\\/ \\ \\@
___) /@
(___ ( @
) \\@
/\\___/ /@
\\______/ @
@@
___ @
/ ) @
/ /) | @
/ (_) (_ @
(____ _)@
) ( @
| | @
(_) @
@@
_______ @
( ____ \\@
| ( \\/@
| (____ @
(_____ \\ @
) )@
/\\____) )@
\\______/ @
@@
______ @
/ ____ \\@
( ( \\/@
| (____ @
| ___ \\ @
| ( ) )@
( (___) )@
\\_____/ @
@@
______ @
/ ___ \\ @
\\/ ) )@
/ / @
/ / @
/ / @
/ / @
\\_/ @
@@
_____ @
/ ___ \\ @
( (___) )@
\\ / @
/ ___ \\ @
( ( ) )@
( (___) )@
\\_____/ @
@@
_____ @
/ ___ \\ @
( ( ) )@
( (___) |@
\\____ |@
) |@
/\\____) )@
\\______/ @
@@
@
@
_ @
(_)@
@
_ @
(_)@
@
@@
@
@
@
_ @
(_)@
@
_ @
( )@
|/ @@
_ @
/ )@
/ / @
/ / @
( ( @
\\ \\ @
\\ \\ @
\\_)@
@@
@
@
___ @
(___)@
___ @
(___)@
@
@
@@
_ @
( \\ @
\\ \\ @
\\ \\ @
) )@
/ / @
/ / @
(_/ @
@@
_____ @
/ ___ \\ @
( ( ) )@
\\/ / / @
( ( @
| | @
(_) @
_ @
(_) @@
_____ @
/ ___ \\ @
/ / _ \\ \\ @
( ( / \\ ) )@
| |(()// / @
( ( \\___/ @
\\ \\____/\\ @
\\______/ @
@@
_______ @
( ___ )@
| ( ) |@
| (___) |@
| ___ |@
| ( ) |@
| ) ( |@
|/ \\|@
@@
______ @
( ___ \\ @
| ( ) )@
| (__/ / @
| __ ( @
| ( \\ \\ @
| )___) )@
|/ \\___/ @
@@
_______ @
( ____ \\@
| ( \\/@
| | @
| | @
| | @
| (____/\\@
(_______/@
@@
______ @
( __ \\ @
| ( \\ )@
| | ) |@
| | | |@
| | ) |@
| (__/ )@
(______/ @
@@
_______ @
( ____ \\@
| ( \\/@
| (__ @
| __) @
| ( @
| (____/\\@
(_______/@
@@
_______ @
( ____ \\@
| ( \\/@
| (__ @
| __) @
| ( @
| ) @
|/ @
@@
_______ @
( ____ \\@
| ( \\/@
| | @
| | ____ @
| | \\_ )@
| (___) |@
(_______)@
@@
@
|\\ /|@
| ) ( |@
| (___) |@
| ___ |@
| ( ) |@
| ) ( |@
|/ \\|@
@@
_________@
\\__ __/@
) ( @
| | @
| | @
| | @
___) (___@
\\_______/@
@@
_________@
\\__ _/@
) ( @
| | @
| | @
| | @
|\\_) ) @
(____/ @
@@
_ @
| \\ /\\@
| \\ / /@
| (_/ / @
| _ ( @
| ( \\ \\ @
| / \\ \\@
|_/ \\/@
@@
_ @
( \\ @
| ( @
| | @
| | @
| | @
| (____/\\@
(_______/@
@@
_______ @
( )@
| () () |@
| || || |@
| |(_)| |@
| | | |@
| ) ( |@
|/ \\|@
@@
_ @
( ( /|@
| \\ ( |@
| \\ | |@
| (\\ \\) |@
| | \\ |@
| ) \\ |@
|/ )_)@
@@
_______ @
( ___ )@
| ( ) |@
| | | |@
| | | |@
| | | |@
| (___) |@
(_______)@
@@
_______ @
( ____ )@
| ( )|@
| (____)|@
| _____)@
| ( @
| ) @
|/ @
@@
_______ @
( ___ )@
| ( ) |@
| | | |@
| | | |@
| | /\\| |@
| (_\\ \\ |@
(____\\/_)@
@@
_______ @
( ____ )@
| ( )|@
| (____)|@
| __)@
| (\\ ( @
| ) \\ \\__@
|/ \\__/@
@@
_______ @
( ____ \\@
| ( \\/@
| (_____ @
(_____ )@
) |@
/\\____) |@
\\_______)@
@@
_________@
\\__ __/@
) ( @
| | @
| | @
| | @
| | @
)_( @
@@
@
|\\ /|@
| ) ( |@
| | | |@
| | | |@
| | | |@
| (___) |@
(_______)@
@@
@
|\\ /|@
| ) ( |@
| | | |@
( ( ) )@
\\ \\_/ / @
\\ / @
\\_/ @
@@
@
|\\ /|@
| ) ( |@
| | _ | |@
| |( )| |@
| || || |@
| () () |@
(_______)@
@@
@
|\\ /|@
( \\ / )@
\\ (_) / @
) _ ( @
/ ( ) \\ @
( / \\ )@
|/ \\|@
@@
@
|\\ /|@
( \\ / )@
\\ (_) / @
\\ / @
) ( @
| | @
\\_/ @
@@
_______ @
/ ___ )@
\\/ ) |@
/ )@
/ / @
/ / @
/ (_/\\@
(_______/@
@@
____ @
( __)@
| ( @
| | @
| | @
| | @
| (__ @
(____)@
@@
@
/\\ @
\\ \\ @
\\ \\ @
\\ \\ @
\\ \\ @
\\ \\@
\\/@
@@
____ @
(__ )@
) |@
| |@
| |@
| |@
__) |@
(____)@
@@
/\\ @
(/\\)@
@
@
@
@
@
@
@@
@
@
@
@
@
@
@
_____ @
(_____)@@
_ @
( )@
\\|@
@
@
@
@
@
@@
_______ @
( ___ )@
| ( ) |@
| (___) |@
| ___ |@
| ( ) |@
| ) ( |@
|/ \\|@
@@
______ @
( ___ \\ @
| ( ) )@
| (__/ / @
| __ ( @
| ( \\ \\ @
| )___) )@
|/ \\___/ @
@@
_______ @
( ____ \\@
| ( \\/@
| | @
| | @
| | @
| (____/\\@
(_______/@
@@
______ @
( __ \\ @
| ( \\ )@
| | ) |@
| | | |@
| | ) |@
| (__/ )@
(______/ @
@@
_______ @
( ____ \\@
| ( \\/@
| (__ @
| __) @
| ( @
| (____/\\@
(_______/@
@@
_______ @
( ____ \\@
| ( \\/@
| (__ @
| __) @
| ( @
| ) @
|/ @
@@
_______ @
( ____ \\@
| ( \\/@
| | @
| | ____ @
| | \\_ )@
| (___) |@
(_______)@
@@
@
|\\ /|@
| ) ( |@
| (___) |@
| ___ |@
| ( ) |@
| ) ( |@
|/ \\|@
@@
_________@
\\__ __/@
) ( @
| | @
| | @
| | @
___) (___@
\\_______/@
@@
_________@
\\__ _/@
) ( @
| | @
| | @
| | @
|\\_) ) @
(____/ @
@@
_ @
| \\ /\\@
| \\ / /@
| (_/ / @
| _ ( @
| ( \\ \\ @
| / \\ \\@
|_/ \\/@
@@
_ @
( \\ @
| ( @
| | @
| | @
| | @
| (____/\\@
(_______/@
@@
_______ @
( )@
| () () |@
| || || |@
| |(_)| |@
| | | |@
| ) ( |@
|/ \\|@
@@
_ @
( ( /|@
| \\ ( |@
| \\ | |@
| (\\ \\) |@
| | \\ |@
| ) \\ |@
|/ )_)@
@@
_______ @
( ___ )@
| ( ) |@
| | | |@
| | | |@
| | | |@
| (___) |@
(_______)@
@@
_______ @
( ____ )@
| ( )|@
| (____)|@
| _____)@
| ( @
| ) @
|/ @
@@
_______ @
( ___ )@
| ( ) |@
| | | |@
| | | |@
| | /\\| |@
| (_\\ \\ |@
(____\\/_)@
@@
_______ @
( ____ )@
| ( )|@
| (____)|@
| __)@
| (\\ ( @
| ) \\ \\__@
|/ \\__/@
@@
_______ @
( ____ \\@
| ( \\/@
| (_____ @
(_____ )@
) |@
/\\____) |@
\\_______)@
@@
_________@
\\__ __/@
) ( @
| | @
| | @
| | @
| | @
)_( @
@@
@
|\\ /|@
| ) ( |@
| | | |@
| | | |@
| | | |@
| (___) |@
(_______)@
@@
@
|\\ /|@
| ) ( |@
| | | |@
( ( ) )@
\\ \\_/ / @
\\ / @
\\_/ @
@@
@
|\\ /|@
| ) ( |@
| | _ | |@
| |( )| |@
| || || |@
| () () |@
(_______)@
@@
@
|\\ /|@
( \\ / )@
\\ (_) / @
) _ ( @
/ ( ) \\ @
( / \\ )@
|/ \\|@
@@
@
|\\ /|@
( \\ / )@
\\ (_) / @
\\ / @
) ( @
| | @
\\_/ @
@@
_______ @
/ ___ )@
\\/ ) |@
/ )@
/ / @
/ / @
/ (_/\\@
(_______/@
@@
__ @
( _)@
)( @
/ | @
\\ | @
)(_ @
(__)@
@
@@
_ @
( )@
| |@
(_)@
_ @
( )@
| |@
(_)@
@@
__ @
(_ ) @
)( @
| \\@
| /@
_)( @
(__) @
@
@@
_ @
/_\\_/)@
(/ \\_/ @
@
@
@
@
@
@@
__ __ @
(__) (__)@
_______ @
( ___ )@
| (___) |@
| ___ |@
| ) ( |@
|/ \\|@
@@
__ __ @
(__) (__)@
_______ @
( ___ )@
| ( ) |@
| | | |@
| (___) |@
(_______)@
@@
__ __ @
(__) (__)@
@
|\\ /|@
| ) ( |@
| | | |@
| (___) |@
(_______)@
@@
__ __ @
(__) (__)@
_______ @
( ___ )@
| (___) |@
| ___ |@
| ) ( |@
|/ \\|@
@@
__ __ @
(__) (__)@
_______ @
( ___ )@
| ( ) |@
| | | |@
| (___) |@
(_______)@
@@
__ __ @
(__) (__)@
@
|\\ /|@
| ) ( |@
| | | |@
| (___) |@
(_______)@
@@
______ @
( ___ \\ @
| (___) )@
| ___ / @
| (___)\\ @
| |\\___/ @
| ) @
|/ @
@@
`
@@ -0,0 +1 @@
{"mappings":";;AAAA;;;;;;;;;;CAUC;AAOD,SAAS,0BAAO,KAAkB;IAChC,OAAO;AACT;AAEA,0BAAI,iBAAiB,GAAG,UAAU,kBAAqB,KAAkB,EAAE,OAAoC;IAC7G,IAAI,YAAC,QAAQ,aAAE,SAAS,uBAAE,mBAAmB,EAAC,GAAG;IAEjD,MAAM;QACJ,MAAM;QACN,OAAO;mBACP;QACA,cAAc,KAAK,CAAC,aAAa;QACjC,eAAe;QACf,CAAC;YACC,sBAAsB;YACtB,IAAI,Q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W,OAAO,CAAC,MAAM,KAAK,QAAQ,OAAO,CAAC,MAAM,IACzD,WAAW,OAAO,CAAC,IAAI,CAAC,CAAC,GAAG,IAAM,EAAE,GAAG,KAAK,QAAQ,OAAO,CAAC,EAAE,CAAC,GAAG,KAClE,WAAW,uBAAuB,KAAK,QAAQ,uBAAuB,IACtE,WAAW,eAAe,KAAK,QAAQ,eAAe,IACtD,WAAW,aAAa,KAAK,QAAQ,aAAa;QACtD;IACF;AACF;AAEA;;;;CAIC,GACD,oEAAoE;AACpE,IAAI,4CAAO","sources":["packages/@react-stately/table/src/Row.ts"],"sourcesContent":["/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {CollectionBuilderContext} from './useTableState';\nimport {PartialNode} from '@react-stately/collections';\nimport React, {JSX, ReactElement} from 'react';\nimport {RowProps} from '@react-types/table';\n\nfunction Row<T>(props: RowProps<T>): ReactElement | null { // eslint-disable-line @typescript-eslint/no-unused-vars\n return null;\n}\n\nRow.getCollectionNode = function* getCollectionNode<T>(props: RowProps<T>, context: CollectionBuilderContext<T>): Generator<PartialNode<T>> {\n let {children, textValue, UNSTABLE_childItems} = props;\n\n yield {\n type: 'item',\n props: props,\n textValue,\n 'aria-label': props['aria-label'],\n hasChildNodes: true,\n *childNodes() {\n // Process cells first\n if (context.showDragButtons) {\n yield {\n type: 'cell',\n key: 'header-drag', // this is combined with the row key by CollectionBuilder\n props: {\n isDragButtonCell: true\n }\n };\n }\n\n if (context.showSelectionCheckboxes && context.selectionMode !== 'none') {\n yield {\n type: 'cell',\n key: 'header', // this is combined with the row key by CollectionBuilder\n props: {\n isSelectionCell: true\n }\n };\n }\n\n if (typeof children === 'function') {\n for (let column of context.columns) {\n yield {\n type: 'cell',\n element: children(column.key),\n key: column.key // this is combined with the row key by CollectionBuilder\n };\n }\n\n if (UNSTABLE_childItems) {\n for (let child of UNSTABLE_childItems) {\n // Note: in order to reuse the render function of TableBody for our child rows, we just need to yield a type and a value here. CollectionBuilder will then look up\n // the parent renderer and use that to build the full node of this child row, using the value provided here to generate the cells\n yield {\n type: 'item',\n value: child\n };\n }\n }\n } else {\n let cells: PartialNode<T>[] = [];\n let childRows: PartialNode<T>[] = [];\n let columnCount = 0;\n React.Children.forEach(children, node => {\n if (node.type === Row) {\n if (cells.length < context.columns.length) {\n throw new Error('All of a Row\\'s child Cells must be positioned before any child Rows.');\n }\n\n childRows.push({\n type: 'item',\n element: node\n });\n } else {\n Line truncated
@@ -0,0 +1,7 @@
function formatErrorMessage(message, errorCode) {
return errorCode
? `${message}. For more information and steps for solving, visit https://motion.dev/troubleshooting/${errorCode}`
: message;
}
export { formatErrorMessage };
@@ -0,0 +1,12 @@
function depsAreSame(oldDeps, deps) {
if (oldDeps === deps) {
return true;
}
for (var i = 0; i < oldDeps.length; i++) {
if (!Object.is(oldDeps[i], deps[i])) {
return false;
}
}
return true;
}
export default depsAreSame;
@@ -0,0 +1,11 @@
import AttributeMap from './AttributeMap';
interface Op {
insert?: string | Record<string, unknown>;
delete?: number;
retain?: number | Record<string, unknown>;
attributes?: AttributeMap;
}
declare namespace Op {
function length(op: Op): number;
}
export default Op;
@@ -0,0 +1,68 @@
By providing `validator` prop you can specify custom validation for files.
The value must be a function that accepts File object and returns null if file should be accepted or error object/array of error objects if file should be rejected.
```jsx harmony
import React from 'react';
import {useDropzone} from 'react-dropzone';
const maxLength = 20;
function nameLengthValidator(file) {
if (file.name.length > maxLength) {
return {
code: "name-too-large",
message: `Name is larger than ${maxLength} characters`
};
}
return null
}
function CustomValidation(props) {
const {
acceptedFiles,
fileRejections,
getRootProps,
getInputProps
} = useDropzone({
validator: nameLengthValidator
});
const acceptedFileItems = acceptedFiles.map(file => (
<li key={file.path}>
{file.path} - {file.size} bytes
</li>
));
const fileRejectionItems = fileRejections.map(({ file, errors }) => (
<li key={file.path}>
{file.path} - {file.size} bytes
<ul>
{errors.map(e => (
<li key={e.code}>{e.message}</li>
))}
</ul>
</li>
));
return (
<section className="container">
<div {...getRootProps({ className: 'dropzone' })}>
<input {...getInputProps()} />
<p>Drag 'n' drop some files here, or click to select files</p>
<em>(Only files with name less than 20 characters will be accepted)</em>
</div>
<aside>
<h4>Accepted files</h4>
<ul>{acceptedFileItems}</ul>
<h4>Rejected files</h4>
<ul>{fileRejectionItems}</ul>
</aside>
</section>
);
}
<CustomValidation />
```
@@ -0,0 +1,35 @@
import { DataSource, Group, GroupDetailInfo, GroupListUpdateType, GroupMember, GroupNotify, ShutUpGroupMember } from '../types';
export declare class NodeIKernelGroupListener {
onGroupListInited(_listEmpty: boolean): any;
onGroupMemberLevelInfoChange(..._args: unknown[]): any;
onGetGroupBulletinListResult(..._args: unknown[]): any;
onGroupAllInfoChange(..._args: unknown[]): any;
onGroupBulletinChange(..._args: unknown[]): any;
onGroupBulletinRemindNotify(..._args: unknown[]): any;
onGroupArkInviteStateResult(..._args: unknown[]): any;
onGroupBulletinRichMediaDownloadComplete(..._args: unknown[]): any;
onGroupConfMemberChange(..._args: unknown[]): any;
onGroupDetailInfoChange(_detailInfo: GroupDetailInfo): any;
onGroupExtListUpdate(..._args: unknown[]): any;
onGroupFirstBulletinNotify(..._args: unknown[]): any;
onGroupListUpdate(_updateType: GroupListUpdateType, _groupList: Group[]): any;
onGroupNotifiesUpdated(_dboubt: boolean, _notifies: GroupNotify[]): any;
onGroupBulletinRichMediaProgressUpdate(..._args: unknown[]): any;
onGroupNotifiesUnreadCountUpdated(..._args: unknown[]): any;
onGroupSingleScreenNotifies(_doubt: boolean, _seq: string, _notifies: GroupNotify[]): any;
onGroupsMsgMaskResult(..._args: unknown[]): any;
onGroupStatisticInfoChange(..._args: unknown[]): any;
onJoinGroupNotify(..._args: unknown[]): any;
onJoinGroupNoVerifyFlag(..._args: unknown[]): any;
onMemberInfoChange(_groupCode: string, _dateSource: DataSource, _members: Map<string, GroupMember>): any;
onMemberListChange(_arg: {
sceneId: string;
ids: string[];
infos: Map<string, GroupMember>;
hasPrev: boolean;
hasNext: boolean;
hasRobot: boolean;
}): any;
onSearchMemberChange(..._args: unknown[]): any;
onShutUpMemberListChanged(_groupCode: string, _members: Array<ShutUpGroupMember>): any;
}
@@ -0,0 +1 @@
{"mappings":"AAYA,qBAAqB,WAAW,GAAG,QAAQ,CAAC;AAO5C,eAAe,MAAM,GAAG;IAAC,iBAAiB,EAAE,MAAM,CAAA;CAAC,CAAC;AAEpD;;GAEG;AACH,yBACE,OAAO,EAAE,OAAO,EAChB,aAAa,GAAE,aAA2B,EAC1C,OAAO,GAAE,MAAiC,GACzC,IAAI,CAuBN;AAED;;GAEG;AACH,+BAA+B,aAAa,EAAE,aAAa,GAAG,IAAI,CAIjE;AAED;;GAEG;AACH,oCAAoC,IAAI,CAKvC","sources":["packages/@react-aria/live-announcer/src/packages/@react-aria/live-announcer/src/LiveAnnouncer.tsx","packages/@react-aria/live-announcer/src/packages/@react-aria/live-announcer/src/index.ts","packages/@react-aria/live-announcer/src/index.ts"],"sourcesContent":[null,null,"/*\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 {announce, clearAnnouncer, destroyAnnouncer} from './LiveAnnouncer';\n"],"names":[],"version":3,"file":"types.d.ts.map"}
@@ -0,0 +1,258 @@
/*
MIT License http://www.opensource.org/licenses/mit-license.php
Author Tobias Koppers @sokra
*/
"use strict";
/** @typedef {import("./Resolver").FileSystem} FileSystem */
/** @typedef {import("./Resolver").StringCallback} StringCallback */
/** @typedef {import("./Resolver").SyncFileSystem} SyncFileSystem */
// eslint-disable-next-line jsdoc/no-restricted-syntax
/** @typedef {Function} SyncOrAsyncFunction */
// eslint-disable-next-line jsdoc/no-restricted-syntax
/** @typedef {any} ResultOfSyncOrAsyncFunction */
/**
* @param {SyncFileSystem} fs file system implementation
* @constructor
*/
function SyncAsyncFileSystemDecorator(fs) {
this.fs = fs;
this.lstat = undefined;
this.lstatSync = undefined;
const { lstatSync } = fs;
if (lstatSync) {
this.lstat =
/** @type {FileSystem["lstat"]} */
(
(arg, options, callback) => {
let result;
try {
result = /** @type {SyncOrAsyncFunction | undefined} */ (callback)
? lstatSync.call(fs, arg, options)
: lstatSync.call(fs, arg);
} catch (err) {
return (callback || options)(
/** @type {NodeJS.ErrnoException | null} */
(err),
);
}
(callback || options)(
null,
/** @type {ResultOfSyncOrAsyncFunction} */
(result),
);
}
);
this.lstatSync =
/** @type {SyncFileSystem["lstatSync"]} */
((arg, options) => lstatSync.call(fs, arg, options));
}
this.stat =
/** @type {FileSystem["stat"]} */
(
(arg, options, callback) => {
let result;
try {
result = /** @type {SyncOrAsyncFunction | undefined} */ (callback)
? fs.statSync(arg, options)
: fs.statSync(arg);
} catch (err) {
return (callback || options)(
/** @type {NodeJS.ErrnoException | null} */
(err),
);
}
(callback || options)(
null,
/** @type {ResultOfSyncOrAsyncFunction} */
(result),
);
}
);
this.statSync =
/** @type {SyncFileSystem["statSync"]} */
((arg, options) => fs.statSync(arg, options));
this.readdir =
/** @type {FileSystem["readdir"]} */
(
(arg, options, callback) => {
let result;
try {
result = /** @type {SyncOrAsyncFunction | undefined} */ (callback)
? fs.readdirSync(
arg,
/** @type {Exclude<Parameters<FileSystem["readdir"]>[1], (err: NodeJS.ErrnoException | null, files: string[]) => void>} */
(options),
)
: fs.readdirSync(arg);
} catch (err) {
return (callback || options)(
/** @type {NodeJS.ErrnoException | null} */
(err),
[],
);
}
(callback || options)(
null,
/** @type {ResultOfSyncOrAsyncFunction} */
(result),
);
}
);
this.readdirSync =
/** @type {SyncFileSystem["readdirSync"]} */
(
(arg, options) =>
fs.readdirSync(
arg,
/** @type {Parameters<SyncFileSystem["readdirSync"]>[1]} */ (options),
)
);
this.readFile =
/** @type {FileSystem["readFile"]} */
(
(arg, options, callback) => {
let result;
try {
result = /** @type {SyncOrAsyncFunction | undefined} */ (callback)
? fs.readFileSync(arg, options)
: fs.readFileSync(arg);
} catch (err) {
return (callback || options)(
/** @type {NodeJS.ErrnoException | null} */
(err),
);
}
(callback || options)(
null,
/** @type {ResultOfSyncOrAsyncFunction} */
(result),
);
}
);
this.readFileSync =
/** @type {SyncFileSystem["readFileSync"]} */
((arg, options) => fs.readFileSync(arg, options));
this.readlink =
/** @type {FileSystem["readlink"]} */
(
(arg, options, callback) => {
let result;
try {
result = /** @type {SyncOrAsyncFunction | undefined} */ (callback)
? fs.readlinkSync(
arg,
/** @type {Exclude<Parameters<FileSystem["readlink"]>[1], StringCallback>} */
(options),
)
: fs.readlinkSync(arg);
} catch (err) {
return (callback || options)(
/** @type {NodeJS.ErrnoException | null} */
(err),
);
}
(callback || options)(
null,
/** @type {ResultOfSyncOrAsyncFunction} */
(result),
);
}
);
this.readlinkSync =
/** @type {SyncFileSystem["readlinkSync"]} */
(
(arg, options) =>
fs.readlinkSync(
arg,
/** @type {Parameters<SyncFileSystem["readlinkSync"]>[1]} */ (
options
),
)
);
this.readJson = undefined;
this.readJsonSync = undefined;
const { readJsonSync } = fs;
if (readJsonSync) {
this.readJson =
/** @type {FileSystem["readJson"]} */
(
(arg, callback) => {
let result;
try {
result = readJsonSync.call(fs, arg);
} catch (err) {
return callback(
/** @type {NodeJS.ErrnoException | Error | null} */ (err),
);
}
callback(null, result);
}
);
this.readJsonSync =
/** @type {SyncFileSystem["readJsonSync"]} */
((arg) => readJsonSync.call(fs, arg));
}
this.realpath = undefined;
this.realpathSync = undefined;
const { realpathSync } = fs;
if (realpathSync) {
this.realpath =
/** @type {FileSystem["realpath"]} */
(
(arg, options, callback) => {
let result;
try {
result = /** @type {SyncOrAsyncFunction | undefined} */ (callback)
? realpathSync.call(
fs,
arg,
/** @type {Exclude<Parameters<NonNullable<FileSystem["realpath"]>>[1], StringCallback>} */
(options),
)
: realpathSync.call(fs, arg);
} catch (err) {
return (callback || options)(
/** @type {NodeJS.ErrnoException | null} */
(err),
);
}
(callback || options)(
null,
/** @type {ResultOfSyncOrAsyncFunction} */
(result),
);
}
);
this.realpathSync =
/** @type {SyncFileSystem["realpathSync"]} */
(
(arg, options) =>
realpathSync.call(
fs,
arg,
/** @type {Parameters<NonNullable<SyncFileSystem["realpathSync"]>>[1]} */
(options),
)
);
}
}
module.exports = SyncAsyncFileSystemDecorator;
@@ -0,0 +1 @@
module.exports={A:{A:{"2":"K D E F A B wC"},B:{"1":"0 1 2 3 4 5 r s t u v w x y z GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB I","2":"C L M G N O P 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","194":"o p q"},C:{"1":"0 1 2 3 4 5 k l m n o p q r s t u v w x y z GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB I XC MC YC yC zC","2":"6 7 8 9 xC TC J ZB K D E F A B C L M G N O P aB AB BB CB DB EB FB bB cB dB eB fB gB hB iB jB kB lB mB nB oB pB qB rB sB tB uB vB wB xB yB zB 0B 1B 2B 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 0C 1C"},D:{"1":"0 1 2 3 4 5 r s t u v w x y z GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB I XC MC YC","2":"6 7 8 9 J ZB K D E F A B C L M G N O P aB AB BB CB DB EB FB bB cB dB eB fB gB hB iB jB kB lB mB nB oB pB qB rB sB tB uB vB wB xB yB zB 0B 1B 2B 3B UC 4B VC 5B 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","194":"j k l m n o p q"},E:{"1":"cC PC AD QC dC eC fC gC hC BD RC iC jC kC lC mC CD SC nC oC pC qC rC sC tC DD ED","2":"J ZB K D E F A B C L M G 2C ZC 3C 4C 5C 6C aC NC OC 7C 8C 9C bC"},F:{"1":"0 1 2 3 4 5 d e f g h i j k l m n o p q r s t u v w x y z","2":"6 7 8 9 F B C G N O P aB AB BB CB DB EB FB bB cB dB eB fB gB hB iB jB kB lB mB nB oB pB qB rB sB tB uB 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 FD GD HD ID NC uC JD OC","194":"a b c"},G:{"1":"cC PC eD QC dC eC fC gC hC fD RC iC jC kC lC mC gD SC nC oC pC qC rC sC tC","2":"E ZC KD vC LD MD ND OD PD QD RD SD TD UD VD WD XD YD ZD aD bD cD dD bC"},H:{"2":"hD"},I:{"1":"I","2":"TC J iD jD kD lD vC mD nD"},J:{"2":"D A"},K:{"1":"H","2":"A B C NC uC OC"},L:{"1":"I"},M:{"1":"MC"},N:{"2":"A B"},O:{"2":"PC"},P:{"1":"7 8 9 AB BB CB DB EB FB","2":"6 J oD pD qD rD sD aC tD uD vD wD xD QC RC SC yD"},Q:{"2":"zD"},R:{"2":"0D"},S:{"2":"1D 2D"}},B:5,C:"Small, Large, and Dynamic viewport units",D:true};
@@ -0,0 +1,8 @@
{
"presets": ["env"],
"plugins": [
["transform-replace-object-assign", { "moduleSpecifier": "object.assign" }],
"transform-object-rest-spread",
// "@babel/plugin-proposal-nullish-coalescing-operator", // TODO: update to babel 7
],
}
@@ -0,0 +1,109 @@
import {gridIds as $2140fb2337097f2d$export$552312adfd451dab} from "./utils.mjs";
import $dDeJM$intlStringsmodulejs from "./intlStrings.mjs";
import {TableKeyboardDelegate as $0ba3c81c7f1caedd$export$da43f8f5cb04028d} from "./TableKeyboardDelegate.mjs";
import {announce as $dDeJM$announce} from "@react-aria/live-announcer";
import {useGrid as $dDeJM$useGrid} from "@react-aria/grid";
import {useId as $dDeJM$useId, useDescription as $dDeJM$useDescription, useUpdateEffect as $dDeJM$useUpdateEffect, mergeProps as $dDeJM$mergeProps} from "@react-aria/utils";
import {tableNestedRows as $dDeJM$tableNestedRows} from "@react-stately/flags";
import {useCollator as $dDeJM$useCollator, useLocale as $dDeJM$useLocale, useLocalizedStringFormatter as $dDeJM$useLocalizedStringFormatter} from "@react-aria/i18n";
import {useMemo as $dDeJM$useMemo} from "react";
function $parcel$interopDefault(a) {
return a && a.__esModule ? a.default : a;
}
/*
* Copyright 2020 Adobe. All rights reserved.
* This file is licensed to you under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. You may obtain a copy
* of the License at http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software distributed under
* the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
* OF ANY KIND, either express or implied. See the License for the specific language
* governing permissions and limitations under the License.
*/
function $6e31608fbba75bab$export$25bceaac3c7e4dc7(props, state, ref) {
let { keyboardDelegate: keyboardDelegate, isVirtualized: isVirtualized, layoutDelegate: layoutDelegate, layout: layout } = props;
// By default, a KeyboardDelegate is provided which uses the DOM to query layout information (e.g. for page up/page down).
// When virtualized, the layout object will be passed in as a prop and override this.
let collator = (0, $dDeJM$useCollator)({
usage: 'search',
sensitivity: 'base'
});
let { direction: direction } = (0, $dDeJM$useLocale)();
let disabledBehavior = state.selectionManager.disabledBehavior;
let delegate = (0, $dDeJM$useMemo)(()=>keyboardDelegate || new (0, $0ba3c81c7f1caedd$export$da43f8f5cb04028d)({
collection: state.collection,
disabledKeys: state.disabledKeys,
disabledBehavior: disabledBehavior,
ref: ref,
direction: direction,
collator: collator,
layoutDelegate: layoutDelegate,
layout: layout
}), [
keyboardDelegate,
state.collection,
state.disabledKeys,
disabledBehavior,
ref,
direction,
collator,
layoutDelegate,
layout
]);
let id = (0, $dDeJM$useId)(props.id);
(0, $2140fb2337097f2d$export$552312adfd451dab).set(state, id);
let { gridProps: gridProps } = (0, $dDeJM$useGrid)({
...props,
id: id,
keyboardDelegate: delegate
}, state, ref);
// Override to include header rows
if (isVirtualized) gridProps['aria-rowcount'] = state.collection.size + state.collection.headerRows.length;
if ((0, $dDeJM$tableNestedRows)() && 'expandedKeys' in state) gridProps.role = 'treegrid';
let { column: column, direction: sortDirection } = state.sortDescriptor || {};
let stringFormatter = (0, $dDeJM$useLocalizedStringFormatter)((0, ($parcel$interopDefault($dDeJM$intlStringsmodulejs))), '@react-aria/table');
let sortDescription = (0, $dDeJM$useMemo)(()=>{
var _state_collection_columns_find;
var _state_collection_columns_find_textValue;
let columnName = (_state_collection_columns_find_textValue = (_state_collection_columns_find = state.collection.columns.find((c)=>c.key === column)) === null || _state_collection_columns_find === void 0 ? void 0 : _state_collection_columns_find.textValue) !== null && _state_collection_columns_find_textValue !== void 0 ? _state_collection_columns_find_textValue : '';
return sortDirection && column ? stringFormatter.format(`${sortDirection}Sort`, {
columnName: columnName
}) : undefined;
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [
sortDirection,
column,
state.collection.columns
]);
let descriptionProps = (0, $dDeJM$useDescription)(sortDescription);
// Only announce after initial render, tabbing to the table will tell you the initial sort info already
(0, $dDeJM$useUpdateEffect)(()=>{
if (sortDescription) (0, $dDeJM$announce)(sortDescription, 'assertive', 500);
}, [
sortDescription
]);
return {
gridProps: (0, $dDeJM$mergeProps)(gridProps, descriptionProps, {
// merge sort description with long press information
'aria-describedby': [
descriptionProps['aria-describedby'],
gridProps['aria-describedby']
].filter(Boolean).join(' ')
})
};
}
export {$6e31608fbba75bab$export$25bceaac3c7e4dc7 as useTable};
//# sourceMappingURL=useTable.module.js.map
@@ -0,0 +1,41 @@
import camelCase from './camelCase.js';
import capitalize from './capitalize.js';
import deburr from './deburr.js';
import endsWith from './endsWith.js';
import escape from './escape.js';
import escapeRegExp from './escapeRegExp.js';
import kebabCase from './kebabCase.js';
import lowerCase from './lowerCase.js';
import lowerFirst from './lowerFirst.js';
import pad from './pad.js';
import padEnd from './padEnd.js';
import padStart from './padStart.js';
import parseInt from './parseInt.js';
import repeat from './repeat.js';
import replace from './replace.js';
import snakeCase from './snakeCase.js';
import split from './split.js';
import startCase from './startCase.js';
import startsWith from './startsWith.js';
import template from './template.js';
import templateSettings from './templateSettings.js';
import toLower from './toLower.js';
import toUpper from './toUpper.js';
import trim from './trim.js';
import trimEnd from './trimEnd.js';
import trimStart from './trimStart.js';
import truncate from './truncate.js';
import unescape from './unescape.js';
import upperCase from './upperCase.js';
import upperFirst from './upperFirst.js';
import words from './words.js';
export default {
camelCase, capitalize, deburr, endsWith, escape,
escapeRegExp, kebabCase, lowerCase, lowerFirst, pad,
padEnd, padStart, parseInt, repeat, replace,
snakeCase, split, startCase, startsWith, template,
templateSettings, toLower, toUpper, trim, trimEnd,
trimStart, truncate, unescape, upperCase, upperFirst,
words
};
@@ -0,0 +1,3 @@
export function isValueProvider(provider) {
return provider.useValue != undefined;
}
@@ -0,0 +1 @@
{"mappings":";;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;AAmBM,SAAS,0CAA4B,KAAuC;IACjF,IAAI,OAAO,aAAa,aAAa;QACnC,QAAQ,GAAG,CAAC;QACZ,OAAO;IACT;IAEA,IAAI,SAAC,KAAK,UAAE,MAAM,WAAE,OAAO,EAAC,GAAG;IAC/B,4DAA4D;IAC5D,2DAA2D;IAC3D,qBAAO,0DAAC;QAAO,OAAO,OAAO,WAAW,cAAc,QAAQ;QAAI,0BAAA;QAAyB,yBAAyB;YAAC,QAAQ,0CAA6B,QAAQ;QAAQ;;AAC5K;AAKO,SAAS,0CAA6B,MAAc,EAAE,OAAgC;IAC3F,OAAO,CAAC,6CAA6C,EAAE,KAAK,SAAS,CAAC,QAAQ,E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OAAO,KAAK,SAAS,CAAC,OAAO,IAAI,CAAC,EAAE,EAAE,CAAC,CAAC;QACjE;QACA,MAAM,IAAI,KAAK,CAAC,GAAG,MAAM;IAC3B;IACA,MAAM,IAAI,KAAK,CAAC,GAAG,MAAM;IACzB,4BAAM,GAAG,CAAC,SAAS;IACnB,OAAO;AACT","sources":["packages/@react-aria/i18n/src/server.tsx"],"sourcesContent":["/*\n * Copyright 2023 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport type {LocalizedString} from '@internationalized/string';\nimport React from 'react';\n\ntype PackageLocalizedStrings = {\n [packageName: string]: Record<string, LocalizedString>\n};\n\ninterface PackageLocalizationProviderProps {\n locale: string,\n strings: PackageLocalizedStrings,\n nonce?: string\n}\n\n/**\n * A PackageLocalizationProvider can be rendered on the server to inject the localized strings\n * needed by the client into the initial HTML.\n */\nexport function PackageLocalizationProvider(props: PackageLocalizationProviderProps) {\n if (typeof document !== 'undefined') {\n console.log('PackageLocalizationProvider should only be rendered on the server.');\n return null;\n }\n\n let {nonce, locale, strings} = props;\n // suppressHydrationWarning is necessary because the browser\n // remove the nonce parameter from the DOM before hydration\n return <script nonce={typeof window === 'undefined' ? nonce : ''} suppressHydrationWarning dangerouslySetInnerHTML={{__html: getPackageLocalizationScript(locale, strings)}} />;\n}\n\n/**\n * Returns the content for an inline `<script>` tag to inject localized strings into initial HTML.\n */\nexport function getPackageLocalizationScript(locale: string, strings: PackageLocalizedStrings) {\n return `window[Symbol.for('react-aria.i18n.locale')]=${JSON.stringify(locale)};{${serialize(strings)}}`;\n}\n\nconst cache = new WeakMap<PackageLocalizedStrings, string>();\n\nfunction serialize(strings: PackageLocalizedStrings): string {\n let cached = cache.get(strings);\n if (cached) {\n return cached;\n }\n\n // Find common strings between packages and hoist them into variables.\n let seen = new Set();\n let common = new Map();\n for (let pkg in strings) {\n for (let key in strings[pkg]) {\n let v = strings[pkg][key];\n let s = typeof v === 'string' ? JSON.stringify(v) : v.toString();\n if (seen.has(s) && !common.has(s)) {\n let name = String.fromCharCode(common.size > 25 ? common.size + 97 : common.size + 65);\n common.set(s, name);\n }\n seen.add(s);\n }\n }\n\n let res = '';\n if (common.size > 0) {\n res += 'let ';\n }\n for (let [string, name] of common) {\n res += `${name}=${string},`;\n }\n if (common.size > 0) {\n res = res.slice(0, -1) + ';';\n }\n\n res += \"window[Symbol.for('react-aria.i18n.strings')]={\";\n for (let pkg in strings) {\n res += `'${pkg}':{`;\n for (let key in strings[pkg]) {\n let v = strings[pkg][key];\n let s = typeof v === 'string' ? JSON.stringify(v) : v.toString();\n if (common.has(s)) {\n s = common.get(s);\n }\n res += Line truncated
@@ -0,0 +1,11 @@
import type { COSEPublicKey } from './cose.js';
import type { Uint8Array_ } from '../types/index.js';
export declare function decodeCredentialPublicKey(publicKey: Uint8Array_): COSEPublicKey;
/**
* Make it possible to stub the return value during testing
* @ignore Don't include this in docs output
*/
export declare const _decodeCredentialPublicKeyInternals: {
stubThis: (value: COSEPublicKey) => COSEPublicKey;
};
//# sourceMappingURL=decodeCredentialPublicKey.d.ts.map
@@ -0,0 +1,717 @@
flf2a$ 7 6 20 0 2
computer.flf by Mike Rosulek <mjr@netins.net>, 7/12/95. Check out my
homepage at: http://www.netins.net/showcase/mikewrld/
$ $#
$ $#
$ $#
$ $#
$ $#
$ $#
$ $##
8$ #
88$#
88$#
88$#
$ #
88$#
$##
8 8$#
" "$#
$ #
$ #
$ #
$ #
$ ##
dP dP$ #
888888888$#
dP dP$ #
888888888$ #
dP dP$ #
$ #
$ ##
ee8ee$#
8 8$#
8eeee$#
88$#
e 88$#
8ee88$#
8$ ##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\$ #
| 8ee8 |$#
\ 88 8 /$ #
`.__.'$ #
$ ##
8""""8$#
8 8$#
8eeee8$#
88 8$#
88 8$#
88 8$#
$ ##
8""""8$ #
8 8$ #
8eeee8ee$#
88 8$#
88 8$#
88eeeee8$#
$ ##
8""""8$#
8 "$#
8e$ #
88$ #
88 e$#
88eee8$#
$ ##
8""""8$#
8 8$#
8e 8$#
88 8$#
88 8$#
88eee8$#
$ ##
8""""$#
8$ #
8eeee$#
88$ #
88$ #
88eee$#
$ ##
8""""$#
8$ #
8eeee$#
88$ #
88$ #
88$ #
$ ##
8""""8$#
8 "$#
8e$ #
88 ee$#
88 8$#
88eee8$#
$ ##
8 8$#
8 8$#
8eee8$#
88 8$#
88 8$#
88 8$#
$ ##
8$ #
8$ #
8e$#
88$#
88$#
88$#
$ ##
8$ #
8$ #
8e$#
88$#
e 88$#
8eee88$#
$ ##
8 8$ #
8 8$ #
8eee8e$#
88 8$#
88 8$#
88 8$#
$ ##
8$ #
8$ #
8e$ #
88$ #
88$ #
88eee$#
$ ##
8""8""8$#
8 8 8$#
8e 8 8$#
88 8 8$#
88 8 8$#
88 8 8$#
$ ##
8"""8$#
8 8$#
8e 8$#
88 8$#
88 8$#
88 8$#
$ ##
8"""88$#
8 8$#
8 8$#
8 8$#
8 8$#
8eeee8$#
$ ##
8""""8$#
8 8$#
8eeee8$#
88$ #
88$ #
88$ #
$ ##
8""""8$#
8 8$#
8 8$#
8 8$#
8 ___8$#
8e8888$#
$ ##
8"""8$ #
8 8$ #
8eee8e$#
88 8$#
88 8$#
88 8$#
$ ##
8""""8$#
8 $#
8eeeee$#
88$#
e 88$#
8eee88$#
$ ##
""8""$#
8$ #
8e$ #
88$ #
88$ #
88$ #
$ ##
8 8$#
8 8$#
8e 8$#
88 8$#
88 8$#
88ee8$#
$ ##
88 8$#
88 8$#
88 e8$#
"8 8$ #
8 8$ #
8ee8$ #
$ ##
8 8 8$#
8 8 8$#
8e 8 8$#
88 8 8$#
88 8 8$#
88ee8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
8eee8e$#
88 8$#
88 8$#
$ ##
$ #
eeeee$#
8 "$#
8eeee$#
88$#
8ee88$#
$ ##
$ #
eeeee$#
8$ #
8e$ #
88$ #
88$ #
$ ##
$ #
e e$#
8 8$#
8e 8$#
88 8$#
88ee8$#
$ ##
$ #
ee e$#
88 8$#
88 e8$#
8 8$ #
8ee8$ #
$ ##
$ #
e e e$#
8 8 8$#
8e 8 8$#
88 8 8$#
88ee8ee8$#
$ ##
$ #
e e$#
8 8$#
eeeeee$#
88 8$#
88 8$#
$ ##
$ #
e e$#
8 8$#
8eeee8$#
88$ #
88$ #
$ ##
$ #
eeeee$#
" 8$#
eeee8$#
88$ #
88ee8$#
$ ##
/"$#
|$ #
|$ #
<$ #
|$ #
|$ #
\_$##
8$#
8$#
8$#
8$#
8$#
8$#
$ ##
"\$ #
|$ #
|$ #
>$#
|$ #
|$ #
_/$ ##
/\/$#
$ #
$ #
$ #
$ #
$ #
$ ##
"" ""$#
eeeee$#
8 8$#
8eee8$#
88 8$#
88 8$#
$ ##
"" ""$#
eeeee$#
8 88$#
8 8$#
8 8$#
8eee8$#
$ ##
"" ""$#
e e$#
8 8$#
8e 8$#
88 8$#
88ee8$#
$ ##
"" ""$#
eeeee$#
8 8$#
8eee8$#
88 8$#
88 8$#
$ ##
"" ""$#
eeeee$#
8 88$#
8 8$#
8 8$#
8eee8$#
$ ##
"" ""$#
e e$#
8 8$#
8e 8$#
88 8$#
88ee8$#
$ ##
$#
$#
$#
$#
$#
$#
$##
@@ -0,0 +1,88 @@
{
"name": "to-regex-range",
"description": "Pass two numbers, get a regex-compatible source string for matching ranges. Validated against more than 2.78 million test assertions.",
"version": "5.0.1",
"homepage": "https://github.com/micromatch/to-regex-range",
"author": "Jon Schlinkert (https://github.com/jonschlinkert)",
"contributors": [
"Jon Schlinkert (http://twitter.com/jonschlinkert)",
"Rouven Weßling (www.rouvenwessling.de)"
],
"repository": "micromatch/to-regex-range",
"bugs": {
"url": "https://github.com/micromatch/to-regex-range/issues"
},
"license": "MIT",
"files": [
"index.js"
],
"main": "index.js",
"engines": {
"node": ">=8.0"
},
"scripts": {
"test": "mocha"
},
"dependencies": {
"is-number": "^7.0.0"
},
"devDependencies": {
"fill-range": "^6.0.0",
"gulp-format-md": "^2.0.0",
"mocha": "^6.0.2",
"text-table": "^0.2.0",
"time-diff": "^0.3.1"
},
"keywords": [
"bash",
"date",
"expand",
"expansion",
"expression",
"glob",
"match",
"match date",
"match number",
"match numbers",
"match year",
"matches",
"matching",
"number",
"numbers",
"numerical",
"range",
"ranges",
"regex",
"regexp",
"regular",
"regular expression",
"sequence"
],
"verb": {
"layout": "default",
"toc": false,
"tasks": [
"readme"
],
"plugins": [
"gulp-format-md"
],
"lint": {
"reflinks": true
},
"helpers": {
"examples": {
"displayName": "examples"
}
},
"related": {
"list": [
"expand-range",
"fill-range",
"micromatch",
"repeat-element",
"repeat-string"
]
}
}
}
@@ -0,0 +1,24 @@
# @heroui/pagination
The Pagination component allows you to display active page and navigate between multiple pages.
Please refer to the [documentation](https://heroui.com/docs/components/pagination) for more information.
## Installation
```sh
yarn add @heroui/pagination
# or
npm i @heroui/pagination
```
## Contribution
Yes please! See the
[contributing guidelines](https://github.com/heroui-inc/heroui/blob/master/CONTRIBUTING.md)
for details.
## License
This project is licensed under the terms of the
[MIT license](https://github.com/heroui-inc/heroui/blob/master/LICENSE).
@@ -0,0 +1,5 @@
import type { PreviewServer, ViteDevServer } from 'vite';
export declare function isDevServer(server: ViteDevServer | PreviewServer): server is ViteDevServer;
export declare const FS_PREFIX = "/@fs/";
export declare function fsPathFromId(id: string): string;
export declare function cleanUrl(url: string): string;
@@ -0,0 +1,69 @@
'use strict'
const u = require('universalify').fromCallback
const path = require('path')
const fs = require('graceful-fs')
const mkdir = require('../mkdirs')
function createFile (file, callback) {
function makeFile () {
fs.writeFile(file, '', err => {
if (err) return callback(err)
callback()
})
}
fs.stat(file, (err, stats) => { // eslint-disable-line handle-callback-err
if (!err && stats.isFile()) return callback()
const dir = path.dirname(file)
fs.stat(dir, (err, stats) => {
if (err) {
// if the directory doesn't exist, make it
if (err.code === 'ENOENT') {
return mkdir.mkdirs(dir, err => {
if (err) return callback(err)
makeFile()
})
}
return callback(err)
}
if (stats.isDirectory()) makeFile()
else {
// parent is not a directory
// This is just to cause an internal ENOTDIR error to be thrown
fs.readdir(dir, err => {
if (err) return callback(err)
})
}
})
})
}
function createFileSync (file) {
let stats
try {
stats = fs.statSync(file)
} catch {}
if (stats && stats.isFile()) return
const dir = path.dirname(file)
try {
if (!fs.statSync(dir).isDirectory()) {
// parent is not a directory
// This is just to cause an internal ENOTDIR error to be thrown
fs.readdirSync(dir)
}
} catch (err) {
// If the stat call above failed because the directory doesn't exist, create it
if (err && err.code === 'ENOENT') mkdir.mkdirsSync(dir)
else throw err
}
fs.writeFileSync(file, '')
}
module.exports = {
createFile: u(createFile),
createFileSync
}
@@ -0,0 +1,3 @@
import CryptoJS = require("./index");
export = CryptoJS.enc.Hex;
@@ -0,0 +1,22 @@
import baseEach from './_baseEach.js';
import isArrayLike from './isArrayLike.js';
/**
* The base implementation of `_.map` without support for iteratee shorthands.
*
* @private
* @param {Array|Object} collection The collection to iterate over.
* @param {Function} iteratee The function invoked per iteration.
* @returns {Array} Returns the new mapped array.
*/
function baseMap(collection, iteratee) {
var index = -1,
result = isArrayLike(collection) ? Array(collection.length) : [];
baseEach(collection, function(value, key, collection) {
result[++index] = iteratee(value, key, collection);
});
return result;
}
export default baseMap;
@@ -0,0 +1 @@
{"name":"hast-util-to-jsx-runtime","version":"2.3.6","requiresBuild":false,"files":{"license":{"checkedAt":1794532112631,"integrity":"sha512-ic4iF2Ap25Sn5T9MMw7nJ9C20WL6V01rybBBQi2Qx8cQC9/ERFEqGnove1HT65tK2TIKM30PZoOV3Qbz2FE//A==","mode":420,"size":1094},"index.js":{"checkedAt":1794532112631,"integrity":"sha512-doad3Y7pP0Bid1rr33CAj6iOFCIwEKQwot1l8s6BVJcUtJ8bBNCya9khquJslvUDqlD3CIzcgurb9t+H9Iz+NQ==","mode":420,"size":86},"lib/index.js":{"checkedAt":1794532112631,"integrity":"sha512-JqfMK2SYSMJPyQbqm9+DjFKI2/XIJfomPckqkO9cmV0POo6PbfVGLQIUHmGZsBh38BrV6hzUo2GQb+WMFaWwSg==","mode":420,"size":19757},"lib/types.js":{"checkedAt":1794532112631,"integrity":"sha512-i3APj5VLajk+EmP6qLB8kXv6iepFpYCaa53KfewCERsf4QvQ7VAvDva5pRTebwq1APzNvKiE8iT1r0yPcNySiw==","mode":420,"size":30},"package.json":{"checkedAt":1794532112631,"integrity":"sha512-vYCP6djLaiyrMSj53imZIf+YseRI1mZ6A3lP4brOPLOVqW9VIJBRqBSXFBuDPtrPK1zSYdDBpRVk6gBOi3BH8w==","mode":420,"size":3705},"lib/index.d.ts.map":{"checkedAt":1794532112631,"integrity":"sha512-6iOS7K5R//qPYKbS4dr/m4h2f/OSDYyVBVvDLOC30l/4R9ryHBBEomY6WsUzlpsihjbyd7Q5UgmNEc1Gg7xZJw==","mode":420,"size":196},"readme.md":{"checkedAt":1794532112632,"integrity":"sha512-XMoKJgxB8wAV7/gskgjsgC86dkmweKzu74/f3z/jG8hzXAcZZ9KunxoXmqwID165pkfaIvmipRojAYupMwZEJQ==","mode":420,"size":20738},"index.d.ts":{"checkedAt":1794532112632,"integrity":"sha512-rL6n2d1hEA5JEGB48LUCIyp20CepdDjP26SC1ZYWeurdplnXJML7ssz0gTZabH63rGWljjvxBmJgPvGgnFyURw==","mode":420,"size":303},"lib/index.d.ts":{"checkedAt":1794532112632,"integrity":"sha512-n+DIhmviUQaz9yutqqO27RpAKppBD/XTSgiX4zAYub0ENjUfep71HPKfFSAWnFgZ0WTotSXr6dSqt7ZmOq4l1w==","mode":420,"size":509},"lib/types.d.ts":{"checkedAt":1794532112632,"integrity":"sha512-zrX4LkR2WbQGdDu6NeXFxx65t8dr+8ggSXq+Zf2f0zRLptczemHvNpKduUYTKD4wIc5O2vJK5BUdrnnroU5lHw==","mode":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EMPLATE","join","preview","root","querySelector","listen","addEventListener","event","classList","contains","save","edit","textContent","preventDefault","linkRange","range","restoreFocus","quill","formatText","sources","USER","hide","on","events","SELECTION_CHANGE","oldRange","source","length","link","offset","scroll","descendant","index","formats","domNode","setAttribute","show","bounds","getBounds","position","removeAttribute","SnowTheme","constructor","options","modules","toolbar","container","add","extendToolbar","buildButtons","querySelectorAll","buildPickers","tooltip","keyboard","addBinding","key","shortKey","_range","context","handlers","call","format","DEFAULTS","value","getSelection","getText","test","indexOf","theme"],"sources":["../../src/themes/snow.ts"],"sourcesContent":["import { merge } from 'lodash-es';\nimport Emitter from '../core/emitter.js';\nimport BaseTheme, { BaseTooltip } from './base.js';\nimport LinkBlot from '../formats/link.js';\nimport { Range } from '../core/selection.js';\nimport icons from '../ui/icons.js';\nimport Quill from '../core/quill.js';\nimport type { Context } from '../modules/keyboard.js';\nimport type Toolbar from '../modules/toolbar.js';\nimport type { ToolbarConfig } from '../modules/toolbar.js';\nimport type { ThemeOptions } from '../core/theme.js';\n\nconst TOOLBAR_CONFIG: ToolbarConfig = [\n [{ header: ['1', '2', '3', false] }],\n ['bold', 'italic', 'underline', 'link'],\n [{ list: 'ordered' }, { list: 'bullet' }],\n ['clean'],\n];\n\nclass SnowTooltip extends BaseTooltip {\n static TEMPLATE = [\n '<a class=\"ql-preview\" rel=\"noopener noreferrer\" target=\"_blank\" href=\"about:blank\"></a>',\n '<input type=\"text\" data-formula=\"e=mc^2\" data-link=\"https://quilljs.com\" data-video=\"Embed URL\">',\n '<a class=\"ql-action\"></a>',\n '<a class=\"ql-remove\"></a>',\n ].join('');\n\n preview = this.root.querySelector('a.ql-preview');\n\n listen() {\n super.listen();\n // @ts-expect-error Fix me later\n this.root\n .querySelector('a.ql-action')\n .addEventListener('click', (event) => {\n if (this.root.classList.contains('ql-editing')) {\n this.save();\n } else {\n // @ts-expect-error Fix me later\n this.edit('link', this.preview.textContent);\n }\n event.preventDefault();\n });\n // @ts-expect-error Fix me later\n this.root\n .querySelector('a.ql-remove')\n .addEventListener('click', (event) => {\n if (this.linkRange != null) {\n const range = this.linkRange;\n this.restoreFocus();\n this.quill.formatText(range, 'link', false, Emitter.sources.USER);\n delete this.linkRange;\n }\n event.preventDefault();\n this.hide();\n });\n this.quill.on(\n Emitter.events.SELECTION_CHANGE,\n (range, oldRange, source) => {\n if (range == null) return;\n if (range.length === 0 && source === Emitter.sources.USER) {\n const [link, offset] = this.quill.scroll.descendant(\n LinkBlot,\n range.index,\n );\n if (link != null) {\n this.linkRange = new Range(range.index - offset, link.length());\n const preview = LinkBlot.formats(link.domNode);\n // @ts-expect-error Fix me later\n this.preview.textContent = preview;\n // @ts-expect-error Fix me later\n this.preview.setAttribute('href', preview);\n this.show();\n const bounds = this.quill.getBounds(this.linkRange);\n if (bounds != null) {\n this.position(bounds);\n }\n return;\n }\n } else {\n delete this.linkRange;\n }\n this.hide();\n },\n );\n }\n\n show() {\n super.show();\n this.root.removeAttribute('data-mode');\n }\n}\n\nclass SnowTheme extends BaseTheme {\n constructor(quill: Quill, options: ThemeOptions) {\n if (\n options.modules.toolbar != null &&\n options.modules.toolbar.container == null\n ) {\n options.modules.toolbar.container = TOOLBAR_CONFIG;\n }\n super(quill, options);\n this.quill.container.classList.add('ql-snow');\n }\n\n extendToolbar(toolbar: Toolbar) {\n if (toolbar.container != null) {\n toolbar.container.classList.add('ql-snow');\n this.buildButtons(toolbar.container.querySelectorAll('button'), icons);\n this.buildPickers(toolbar.container.querySelectorAll('select'), icons);\n // @ts-expect-error\n this.tooltip = new SnowTooltip(this.quill, this.options.bounds);\n if (toolbar.container.querySelector('.ql-link')) {\n this.quill.keyboard.addBinding(\n { key: 'k', shortKey: true },\n (_range: Range, context: ContexLine truncated
@@ -0,0 +1,63 @@
"use strict"
const {
definePrototypeMethodHandler,
} = require("../util/define-prototype-method-handler")
module.exports = {
meta: {
docs: {
description: "disallow the `Date.prototype.toGMTString` method.",
category: "legacy",
recommended: false,
url: "http://eslint-community.github.io/eslint-plugin-es-x/rules/no-date-prototype-togmtstring.html",
},
fixable: "code",
messages: {
forbidden: "Annex B feature '{{name}}' method is forbidden.",
},
schema: [
{
type: "object",
properties: {
aggressive: { type: "boolean" },
},
additionalProperties: false,
},
],
type: "problem",
hasSuggestions: true,
},
create(context) {
return definePrototypeMethodHandler(
context,
{
Date: ["toGMTString"],
},
{
createReport({ objectTypeResult, node }) {
if (node.computed) {
return null
}
if (objectTypeResult !== true) {
return {
suggest: [
{
desc: "Replace with 'toUTCString'",
fix,
},
],
}
}
return {
fix,
}
function fix(fixer) {
return fixer.replaceText(node.property, "toUTCString")
}
},
},
)
},
}
@@ -0,0 +1,146 @@
function resolveProps(tokens, { flow, indicator, next, offset, onError, parentIndent, startOnNewline }) {
let spaceBefore = false;
let atNewline = startOnNewline;
let hasSpace = startOnNewline;
let comment = '';
let commentSep = '';
let hasNewline = false;
let reqSpace = false;
let tab = null;
let anchor = null;
let tag = null;
let newlineAfterProp = null;
let comma = null;
let found = null;
let start = null;
for (const token of tokens) {
if (reqSpace) {
if (token.type !== 'space' &&
token.type !== 'newline' &&
token.type !== 'comma')
onError(token.offset, 'MISSING_CHAR', 'Tags and anchors must be separated from the next token by white space');
reqSpace = false;
}
if (tab) {
if (atNewline && token.type !== 'comment' && token.type !== 'newline') {
onError(tab, 'TAB_AS_INDENT', 'Tabs are not allowed as indentation');
}
tab = null;
}
switch (token.type) {
case 'space':
// At the doc level, tabs at line start may be parsed
// as leading white space rather than indentation.
// In a flow collection, only the parser handles indent.
if (!flow &&
(indicator !== 'doc-start' || next?.type !== 'flow-collection') &&
token.source.includes('\t')) {
tab = token;
}
hasSpace = true;
break;
case 'comment': {
if (!hasSpace)
onError(token, 'MISSING_CHAR', 'Comments must be separated from other tokens by white space characters');
const cb = token.source.substring(1) || ' ';
if (!comment)
comment = cb;
else
comment += commentSep + cb;
commentSep = '';
atNewline = false;
break;
}
case 'newline':
if (atNewline) {
if (comment)
comment += token.source;
else if (!found || indicator !== 'seq-item-ind')
spaceBefore = true;
}
else
commentSep += token.source;
atNewline = true;
hasNewline = true;
if (anchor || tag)
newlineAfterProp = token;
hasSpace = true;
break;
case 'anchor':
if (anchor)
onError(token, 'MULTIPLE_ANCHORS', 'A node can have at most one anchor');
if (token.source.endsWith(':'))
onError(token.offset + token.source.length - 1, 'BAD_ALIAS', 'Anchor ending in : is ambiguous', true);
anchor = token;
start ?? (start = token.offset);
atNewline = false;
hasSpace = false;
reqSpace = true;
break;
case 'tag': {
if (tag)
onError(token, 'MULTIPLE_TAGS', 'A node can have at most one tag');
tag = token;
start ?? (start = token.offset);
atNewline = false;
hasSpace = false;
reqSpace = true;
break;
}
case indicator:
// Could here handle preceding comments differently
if (anchor || tag)
onError(token, 'BAD_PROP_ORDER', `Anchors and tags must be after the ${token.source} indicator`);
if (found)
onError(token, 'UNEXPECTED_TOKEN', `Unexpected ${token.source} in ${flow ?? 'collection'}`);
found = token;
atNewline =
indicator === 'seq-item-ind' || indicator === 'explicit-key-ind';
hasSpace = false;
break;
case 'comma':
if (flow) {
if (comma)
onError(token, 'UNEXPECTED_TOKEN', `Unexpected , in ${flow}`);
comma = token;
atNewline = false;
hasSpace = false;
break;
}
// else fallthrough
default:
onError(token, 'UNEXPECTED_TOKEN', `Unexpected ${token.type} token`);
atNewline = false;
hasSpace = false;
}
}
const last = tokens[tokens.length - 1];
const end = last ? last.offset + last.source.length : offset;
if (reqSpace &&
next &&
next.type !== 'space' &&
next.type !== 'newline' &&
next.type !== 'comma' &&
(next.type !== 'scalar' || next.source !== '')) {
onError(next.offset, 'MISSING_CHAR', 'Tags and anchors must be separated from the next token by white space');
}
if (tab &&
((atNewline && tab.indent <= parentIndent) ||
next?.type === 'block-map' ||
next?.type === 'block-seq'))
onError(tab, 'TAB_AS_INDENT', 'Tabs are not allowed as indentation');
return {
comma,
found,
spaceBefore,
comment,
hasNewline,
anchor,
tag,
newlineAfterProp,
end,
start: start ?? end
};
}
export { resolveProps };
@@ -0,0 +1,66 @@
{
"name": "@react-aria/i18n",
"version": "3.12.4",
"description": "Spectrum UI components in React",
"license": "Apache-2.0",
"main": "dist/main.js",
"module": "dist/module.js",
"exports": {
".": {
"types": "./dist/types.d.ts",
"import": "./dist/import.mjs",
"require": "./dist/main.js"
},
"./server": {
"import": "./server/index.mjs",
"require": "./server/index.js"
}
},
"server-module": "server/index.mjs",
"server-main": "server/index.js",
"types": "dist/types.d.ts",
"source": "src/index.ts",
"targets": {
"main": {},
"module": {},
"server-module": {
"source": "src/server.tsx",
"outputFormat": "esmodule",
"isLibrary": true,
"includeNodeModules": false
},
"server-main": {
"source": "src/server.tsx",
"outputFormat": "commonjs",
"isLibrary": true,
"includeNodeModules": false
}
},
"files": [
"dist",
"src",
"server"
],
"sideEffects": false,
"repository": {
"type": "git",
"url": "https://github.com/adobe/react-spectrum"
},
"dependencies": {
"@internationalized/date": "^3.6.0",
"@internationalized/message": "^3.1.6",
"@internationalized/number": "^3.6.0",
"@internationalized/string": "^3.2.5",
"@react-aria/ssr": "^3.9.7",
"@react-aria/utils": "^3.26.0",
"@react-types/shared": "^3.26.0",
"@swc/helpers": "^0.5.0"
},
"peerDependencies": {
"react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1"
},
"publishConfig": {
"access": "public"
},
"gitHead": "71f0ef23053f9e03ee7e97df736e8b083e006849"
}
@@ -0,0 +1,7 @@
import * as ts from 'typescript';
/**
* Get the type name of a given type.
* @param typeChecker The context sensitive TypeScript TypeChecker.
* @param type The type to get the name of.
*/
export declare function getTypeName(typeChecker: ts.TypeChecker, type: ts.Type): string;
@@ -0,0 +1,634 @@
flf2a$ 6 5 18 -1 21
Figlet conversion by Kent Nassen (kentn@cyberspace.org) based on the
font designed by:
Article 2687 of rec.arts.ascii:
Path: news.itd.umich.edu!caen!math.ohio-state.edu!howland.reston.ans.net!news.sprintlink.net!sashimi.wwa.com!not-for-mail
From: dissel@nunic.nu.edu (David S. Issel)
Newsgroups: rec.arts.ascii,alt.ascii-art
Subject: Line: Smaller BLOOD font (5 line)
Date: 6 Nov 1994 15:06:30 -0600
Organization: National University
Lines: 73
Sender: boba@wwa.com
Approved: boba@wwa.com
Message-ID: <39jggm$in2@gagme.wwa.com>
NNTP-Posting-Host: gagme.wwa.com
Xref: news.itd.umich.edu rec.arts.ascii:2687 alt.ascii-art:15734
For those who thought that BLOOD was too big... I offer SBLOOD:
------------
$ $#
$ $#
$ $#
$ $#
$ $#
$ $##
$@@@#
$@@@#
$!@!#
$ #
$:.:#
$ ##
$@@ @@$#
$ @! @!#
$ $#
$ $#
$ $#
$ $##
$ @@@ @@@ #
$@@@!@@@@@#
$ @!@ !@! #
$!!!:!!!!:#
$ :: : : #
$ ##
$ @@@@@ #
$!@@!! #
$ !@@!! #
$ !!:!#
$ :.:.: #
$ ##
$ @@ @@#
$ @@!#
$ @@! #
$!!: #
$:. :: #
$ ##
$ @@@@@ #
$@@! @@@ #
$ !@!@! #
$!!: !!! #
$ :.: : .:#
$ ##
$ @@#
$!@$#
$ $#
$ $#
$ $#
$ $##
$ @@@#
$@@@ #
$!@! #
$!!! #
$ : :#
$ ##
$@@@ #
$ @@@#
$ !@!#
$ !!!#
$: : #
$ ##
$ @@@ @@@ #
$ @@!!@@ #
$!!!@@!@!!!#
$ !:::!! #
$ :.: .:: #
$ ##
$ @@@ #
$ @@@ #
$!@!@!@!#
$ !!! #
$ : : #
$ ##
$ $#
$ $#
$ $#
$ !!#
$ ::#
$.: ##
$ $#
$ $#
$@!@!@!@!#
$ $#
$ $#
$ $##
$ $#
$ $#
$ $#
$ $#
$::#
$ $##
$ @@@#
$ @@@ #
$ !!@ #
$ !!! #
$: : #
$ ##
$ @@@@@@ #
$@@! @@@#
$@!@ !@!#
$!!: !!!#
$ : : :: #
$ ##
$ @@@#
$ @@@#
$ !@!#
$ !!!#
$ : #
$ $##
$ @@@@@@ #
$@@ @@@#
$ .!!@! #
$ !!: #
$:.:: :::#
$ ##
$@@@@@@ #
$ @@!#
$ @!!!: #
$ !!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: : #
$ ##
$@@@ @@@#
$@@! @@@#
$@!@ !@!#
$ !: .:! #
$ :: #
$ ##
$@@@ @@@ @@@#
$@@! @@! @@!#
$@!! !!@ @!@#
$ !: !!: !! #
$ ::.: ::: #
$ ##
$@@@ @@@#
$@@! !@@#
$ !@@!@! #
$ !: :!! #
$::: :::#
$ ##
$@@@ @@@#
$@@! !@@#
$ !@!@! #
$ !!: #
$ .: #
$ ##
$@@@@@@@@#
$ @@!#
$ @!! #
$ !!: #
$:.::.: :#
$ ##
$ @@@#
$ @@@#
$!!@ #
$ !!!#
$ : :#
$ ##
$ @@@#
$ @@@#
$ @!!#
$ !!!#
$ :.:#
$ . :##
$ @@@ #
$ @@@ #
$ @!!#
$ !!! #
$ : : #
$ ##
$ @@@ @@#
$@@ @@@$#
$ $#
$ $#
$ $#
$ $##
#
#
#
#
#
##
#
#
#
#
#
##
#
#
#
#
#
##
#
#
#
#
#
##
#
#
#
#
#
##
#
#
#
#
#
##
#
#
#
#
#
##
@@ -0,0 +1,7 @@
{
"extends": "@dabh/eslint-config-populist",
"rules": {
"one-var": ["error", { var: "never", let: "never", const: "never" }],
"strict": 0
}
}
@@ -0,0 +1 @@
{"version":3,"file":"resolveModuleDeactivations.js","sourceRoot":"","sources":["../../../../src/resolution/actions/resolveModuleDeactivations.ts"],"names":[],"mappings":";;AAIA,gEAQC;AAVD,iFAA8E;AAE9E,SAAgB,0BAA0B,CACxC,MAA0B,EAC1B,QAAgB;IAEhB,MAAM,QAAQ,GACZ,MAAM,CAAC,qBAAqB,CAAC,QAAQ,CAAC,CAAC;IAEzC,OAAO,IAAA,2DAA4B,EAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;AACxD,CAAC"}
@@ -0,0 +1 @@
{"version":3,"file":"isMultipleResolvedValueMetadataInjectOptions.d.ts","sourceRoot":"","sources":["../../../../src/binding/calculations/isMultipleResolvedValueMetadataInjectOptions.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,0CAA0C,EAC1C,0BAA0B,EAC3B,MAAM,sCAAsC,CAAC;AAE9C,wBAAgB,4CAA4C,CAAC,CAAC,EAC5D,OAAO,EAAE,0BAA0B,CAAC,CAAC,CAAC,GACrC,OAAO,IAAI,0BAA0B,CAAC,CAAC,CAAC,GACzC,0CAA0C,CAAC,CAAC,CAAC,CAK9C"}
@@ -0,0 +1,87 @@
const ignoreRegexp = /\bmso-list:[^;]*ignore/i;
const idRegexp = /\bmso-list:[^;]*\bl(\d+)/i;
const indentRegexp = /\bmso-list:[^;]*\blevel(\d+)/i;
const parseListItem = (element, html) => {
const style = element.getAttribute('style');
const idMatch = style?.match(idRegexp);
if (!idMatch) {
return null;
}
const id = Number(idMatch[1]);
const indentMatch = style?.match(indentRegexp);
const indent = indentMatch ? Number(indentMatch[1]) : 1;
const typeRegexp = new RegExp(`@list l${id}:level${indent}\\s*\\{[^\\}]*mso-level-number-format:\\s*([\\w-]+)`, 'i');
const typeMatch = html.match(typeRegexp);
const type = typeMatch && typeMatch[1] === 'bullet' ? 'bullet' : 'ordered';
return {
id,
indent,
type,
element
};
};
// list items are represented as `p` tags with styles like `mso-list: l0 level1` where:
// 1. "0" in "l0" means the list item id;
// 2. "1" in "level1" means the indent level, starting from 1.
const normalizeListItem = doc => {
const msoList = Array.from(doc.querySelectorAll('[style*=mso-list]'));
const ignored = [];
const others = [];
msoList.forEach(node => {
const shouldIgnore = (node.getAttribute('style') || '').match(ignoreRegexp);
if (shouldIgnore) {
ignored.push(node);
} else {
others.push(node);
}
});
// Each list item contains a marker wrapped with "mso-list: Ignore".
ignored.forEach(node => node.parentNode?.removeChild(node));
// The list stype is not defined inline with the tag, instead, it's in the
// style tag so we need to pass the html as a string.
const html = doc.documentElement.innerHTML;
const listItems = others.map(element => parseListItem(element, html)).filter(parsed => parsed);
while (listItems.length) {
const childListItems = [];
let current = listItems.shift();
// Group continuous items into the same group (aka "ul")
while (current) {
childListItems.push(current);
current = listItems.length && listItems[0]?.element === current.element.nextElementSibling &&
// Different id means the next item doesn't belong to this group.
listItems[0].id === current.id ? listItems.shift() : null;
}
const ul = document.createElement('ul');
childListItems.forEach(listItem => {
const li = document.createElement('li');
li.setAttribute('data-list', listItem.type);
if (listItem.indent > 1) {
li.setAttribute('class', `ql-indent-${listItem.indent - 1}`);
}
li.innerHTML = listItem.element.innerHTML;
ul.appendChild(li);
});
const element = childListItems[0]?.element;
const {
parentNode
} = element ?? {};
if (element) {
parentNode?.replaceChild(ul, element);
}
childListItems.slice(1).forEach(_ref => {
let {
element: e
} = _ref;
parentNode?.removeChild(e);
});
}
};
export default function normalize(doc) {
if (doc.documentElement.getAttribute('xmlns:w') === 'urn:schemas-microsoft-com:office:word') {
normalizeListItem(doc);
}
}
//# sourceMappingURL=msWord.js.map
@@ -0,0 +1,127 @@
{
"name": "fflate",
"version": "0.8.2",
"description": "High performance (de)compression in an 8kB package",
"main": "./lib/index.cjs",
"module": "./esm/browser.js",
"types": "./lib/index.d.ts",
"unpkg": "./umd/index.js",
"jsdelivr": "./umd/index.js",
"browser": {
"./lib/node-worker.cjs": "./lib/worker.cjs"
},
"exports": {
".": {
"node": {
"import": {
"types": "./esm/index.d.mts",
"default": "./esm/index.mjs"
},
"require": {
"types": "./lib/node.d.cts",
"default": "./lib/node.cjs"
}
},
"import": {
"types": "./esm/browser.d.ts",
"default": "./esm/browser.js"
},
"require": {
"types": "./lib/browser.d.cts",
"default": "./lib/browser.cjs"
}
},
"./node": {
"import": {
"types": "./esm/index.d.mts",
"default": "./esm/index.mjs"
},
"require": {
"types": "./lib/node.d.cts",
"default": "./lib/node.cjs"
}
},
"./browser": {
"import": {
"types": "./esm/browser.d.ts",
"default": "./esm/browser.js"
},
"require": {
"types": "./lib/browser.d.cts",
"default": "./lib/browser.cjs"
}
}
},
"targets": {
"main": false,
"module": false,
"browser": false,
"types": false
},
"sideEffects": false,
"homepage": "https://101arrowz.github.io/fflate",
"repository": "https://github.com/101arrowz/fflate",
"bugs": {
"email": "arjunbarrett@gmail.com",
"url": "https://github.com/101arrowz/fflate/issues"
},
"author": "Arjun Barrett <arjunbarrett@gmail.com>",
"license": "MIT",
"keywords": [
"gzip",
"gunzip",
"deflate",
"inflate",
"compression",
"decompression",
"zlib",
"pako",
"jszip",
"browser",
"node.js",
"tiny",
"fast",
"zip",
"unzip",
"non-blocking"
],
"scripts": {
"build": "npm run build:lib && npm run build:docs && npm run build:demo",
"script": "node -r ts-node/register scripts/$SC.ts",
"build:lib": "tsc && tsc --project tsconfig.esm.json && npm run build:rewrite && npm run build:umd",
"build:umd": "SC=buildUMD npm run script",
"build:rewrite": "SC=rewriteBuilds npm run script",
"build:demo": "tsc --project tsconfig.demo.json && parcel build demo/index.html --no-cache --public-url \"./\" && SC=cpGHPages npm run script",
"build:docs": "typedoc --plugin typedoc-plugin-markdown --hideBreadcrumbs --readme none --disableSources --excludePrivate --excludeProtected --githubPages false --out docs/ src/index.ts",
"test": "TS_NODE_PROJECT=test/tsconfig.json uvu -b -r ts-node/register test",
"prepack": "npm run build && npm run test"
},
"devDependencies": {
"@parcel/service-worker": "^2.9.3",
"@types/node": "^14.11.2",
"@types/pako": "*",
"@types/react": "^18.2.21",
"@types/react-dom": "^18.2.7",
"jszip": "^3.5.0",
"pako": "*",
"parcel": "^2.9.3",
"preact": "^10.17.1",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"simple-git": "^3.19.1",
"terser": "^5.3.8",
"tiny-inflate": "*",
"ts-node": "^10.9.1",
"typedoc": "^0.25.0",
"typedoc-plugin-markdown": "^3.16.0",
"typescript": "^5.2.2",
"uvu": "^0.3.3",
"uzip": "*"
},
"alias": {
"react": "preact/compat",
"react-dom": "preact/compat",
"buffer": false,
"process": false
}
}
@@ -0,0 +1,70 @@
# err-code
[![NPM version][npm-image]][npm-url] [![Downloads][downloads-image]][npm-url] [![Build Status][travis-image]][travis-url] [![Dependency status][david-dm-image]][david-dm-url] [![Dev Dependency status][david-dm-dev-image]][david-dm-dev-url] [![Greenkeeper badge][greenkeeper-image]][greenkeeper-url]
[npm-url]:https://npmjs.org/package/err-code
[downloads-image]:http://img.shields.io/npm/dm/err-code.svg
[npm-image]:http://img.shields.io/npm/v/err-code.svg
[travis-url]:https://travis-ci.org/IndigoUnited/js-err-code
[travis-image]:http://img.shields.io/travis/IndigoUnited/js-err-code/master.svg
[david-dm-url]:https://david-dm.org/IndigoUnited/js-err-code
[david-dm-image]:https://img.shields.io/david/IndigoUnited/js-err-code.svg
[david-dm-dev-url]:https://david-dm.org/IndigoUnited/js-err-code?type=dev
[david-dm-dev-image]:https://img.shields.io/david/dev/IndigoUnited/js-err-code.svg
[greenkeeper-image]:https://badges.greenkeeper.io/IndigoUnited/js-err-code.svg
[greenkeeper-url]:https://greenkeeper.io/
Create new error instances with a code and additional properties.
## Installation
```console
$ npm install err-code
// or
$ bower install err-code
```
The browser file is named index.umd.js which supports CommonJS, AMD and globals (errCode).
## Why
I find myself doing this repeatedly:
```js
var err = new Error('My message');
err.code = 'SOMECODE';
err.detail = 'Additional information about the error';
throw err;
```
## Usage
Simple usage.
```js
var errcode = require('err-code');
// fill error with message + code
throw errcode(new Error('My message'), 'ESOMECODE');
// fill error with message + code + props
throw errcode(new Error('My message'), 'ESOMECODE', { detail: 'Additional information about the error' });
// fill error with message + props
throw errcode(new Error('My message'), { detail: 'Additional information about the error' });
```
## Pre-existing fields
If the passed `Error` already has a `.code` field, or fields specified in the third argument to `errcode` they will be overwritten, unless the fields are read only or otherwise throw during assignment in which case a new object will be created that shares a prototype chain with the original `Error`. The `.stack` and `.message` properties will be carried over from the original error and `.code` or any passed properties will be set on it.
## Tests
`$ npm test`
## License
Released under the [MIT License](http://www.opensource.org/licenses/mit-license.php).
@@ -0,0 +1,7 @@
import { TypeBoxError } from '../../type/error/index.mjs';
export declare class ValueHashError extends TypeBoxError {
readonly value: unknown;
constructor(value: unknown);
}
/** Creates a FNV1A-64 non cryptographic hash of the given value */
export declare function Hash(value: unknown): bigint;
@@ -0,0 +1,2 @@
# Automatically normalize line endings for all text-based files
* text=auto
@@ -0,0 +1,32 @@
var isArrayLike = require('./isArrayLike');
/**
* Creates a `baseEach` or `baseEachRight` function.
*
* @private
* @param {Function} eachFunc The function to iterate over a collection.
* @param {boolean} [fromRight] Specify iterating from right to left.
* @returns {Function} Returns the new base function.
*/
function createBaseEach(eachFunc, fromRight) {
return function(collection, iteratee) {
if (collection == null) {
return collection;
}
if (!isArrayLike(collection)) {
return eachFunc(collection, iteratee);
}
var length = collection.length,
index = fromRight ? length : -1,
iterable = Object(collection);
while ((fromRight ? index-- : ++index < length)) {
if (iteratee(iterable[index], index, iterable) === false) {
break;
}
}
return collection;
};
}
module.exports = createBaseEach;
@@ -0,0 +1,37 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.decodeAuthenticatorExtensions = decodeAuthenticatorExtensions;
const index_js_1 = require("./iso/index.js");
/**
* Convert authenticator extension data buffer to a proper object
*
* @param extensionData Authenticator Extension Data buffer
*/
function decodeAuthenticatorExtensions(extensionData) {
let toCBOR;
try {
toCBOR = index_js_1.isoCBOR.decodeFirst(extensionData);
}
catch (err) {
const _err = err;
throw new Error(`Error decoding authenticator extensions: ${_err.message}`);
}
return convertMapToObjectDeep(toCBOR);
}
/**
* CBOR-encoded extensions can be deeply-nested Maps, which are too deep for a simple
* `Object.entries()`. This method will recursively make sure that all Maps are converted into
* basic objects.
*/
function convertMapToObjectDeep(input) {
const mapped = {};
for (const [key, value] of input) {
if (value instanceof Map) {
mapped[key] = convertMapToObjectDeep(value);
}
else {
mapped[key] = value;
}
}
return mapped;
}
@@ -0,0 +1 @@
{"mappings":"AAAA;;;;;;;;;;CAUC,GAEM,SAAS,0CAAa,IAAoB,EAAE,gBAA0B;IAC3E,IAAI,CAAC,MACH,OAAO;IAET,IAAI,QAAQ,OAAO,gBAAgB,CAAC;IACpC,IAAI,eAAe,gBAAgB,IAAI,CAAC,MAAM,QAAQ,GAAG,MAAM,SAAS,GAAG,MAAM,SAAS;IAE1F,IAAI,gBAAgB,kBAClB,eAAe,KAAK,YAAY,KAAK,KAAK,YAAY,IAAI,KAAK,WAAW,KAAK,KAAK,WAAW;IAGjG,OAAO;AACT","sources":["packages/@react-aria/utils/src/isScrollable.ts"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nexport function isScrollable(node: Element | null, checkForOverflow?: boolean): boolean {\n if (!node) {\n return false;\n }\n let style = window.getComputedStyle(node);\n let isScrollable = /(auto|scroll)/.test(style.overflow + style.overflowX + style.overflowY);\n\n if (isScrollable && checkForOverflow) {\n isScrollable = node.scrollHeight !== node.clientHeight || node.scrollWidth !== node.clientWidth;\n }\n\n return isScrollable;\n}\n"],"names":[],"version":3,"file":"isScrollable.module.js.map"}
@@ -0,0 +1,374 @@
import * as tailwind_variants from 'tailwind-variants';
import * as _heroui_system from '@heroui/system';
import { HTMLHeroUIProps, PropGetter } from '@heroui/system';
import { SlotsToClasses, PaginationSlots, PaginationVariantProps } from '@heroui/theme';
import { Ref, Key, ReactNode } from 'react';
import { PaginationItemValue, UsePaginationProps as UsePaginationProps$1 } from '@heroui/use-pagination';
import { PressEvent } from '@react-types/shared';
type PaginationItemRenderProps = {
/**
* The pagination item ref.
*/
ref?: Ref<any>;
/**
* React key.
*/
key?: Key;
/**
* The pagination item value.
*/
children?: ReactNode;
/**
* The pagination item value.
*/
value: PaginationItemValue;
/**
* The pagination item index.
*/
index: number;
/**
* Calculated pagination item position. This includes the dots.
*/
page: number;
/**
* The pagination total number of pages.
*/
total: number;
/**
* The active page number.
*/
activePage: number;
/**
* Whether the pagination item is active.
*/
isActive: boolean;
/**
* Whether the item is before the active page.
*/
isBefore: boolean;
/**
* Whether the pagination item is the first item in the pagination.
*/
isFirst: boolean;
/**
* Whether the pagination item is the last item in the pagination.
*/
isLast: boolean;
/**
* Whether the pagination item is the next item in the pagination.
*/
isNext: boolean;
/**
* Number of pages that are added or subtracted on the '...' button.
* @default 5
*/
dotsJump: number;
/**
* Whether the pagination item is the previous item in the pagination.
*/
isPrevious: boolean;
/**
* The pagination item className.
*/
className: string;
/**
* Callback to go to the next page.
*/
onNext: () => void;
/**
* Callback to go to the previous page.
*/
onPrevious: () => void;
/**
* Callback to go to the page.
*/
setPage: (page: number) => void;
/**
* Callback fired when the item is clicked.
* @param e PressEvent
*/
onPress?: (e: PressEvent) => void;
/**
* Function to get the aria-label of the item.
*/
getAriaLabel?: (page?: PaginationItemValue) => string | undefined;
};
interface Props extends Omit<HTMLHeroUIProps<"nav">, "onChange"> {
/**
* Ref to the DOM node.
*/
ref?: Ref<HTMLElement>;
/**
* Number of pages that are added or subtracted on the '...' button.
* @default 5
*/
dotsJump?: number;
/**
* Non disable next/previous controls
* @default false
*/
loop?: boolean;
/**
* Whether the pagination should display controls (left/right arrows).
* @default true
*/
showControls?: boolean;
/**
* Render a custom pagination item.
* @param props Pagination item props
* @returns ReactNode
*/
renderItem?: (props: PaginationItemRenderProps) => ReactNode;
/**
* Function to get the aria-label of the item. If not provided, pagination will use the default one.
*/
getItemAriaLabel?: (page?: string | PaginationItemValue) => string;
/**
* Classname or List of classes to change the classNames of the element.
* if `className` is passed, it will be added to the base slot.
*
* @example
* ```ts
* <Pagination classNames={{
* base:"base-classes",
* prev: "prev-classes", // prev button classes
* item: "item-classes",
* next: "next-classes", // next button classes
* cursor: "cursor-classes", // this is the one that moves when an item is selected
* forwardIcon: "forward-icon-classes", // forward icon
* ellipsis: "ellipsis-classes", // ellipsis icon
* chevronNext: "chevron-next-classes", // chevron next icon
* }} />
* ```
*/
classNames?: SlotsToClasses<PaginationSlots>;
}
type UsePaginationProps = Props & UsePaginationProps$1 & PaginationVariantProps;
declare const CURSOR_TRANSITION_TIMEOUT = 300;
declare function usePagination(originalProps: UsePaginationProps): {
Component: _heroui_system.As<any>;
showControls: boolean;
dotsJump: number;
slots: {
base: (slotProps?: ({
size?: "md" | "sm" | "lg" | undefined;
color?: "default" | "primary" | "secondary" | "success" | "warning" | "danger" | undefined;
radius?: "none" | "md" | "full" | "sm" | "lg" | undefined;
isDisabled?: boolean | undefined;
disableAnimation?: boolean | undefined;
variant?: "flat" | "bordered" | "faded" | "light" | undefined;
isCompact?: boolean | undefined;
showShadow?: boolean | undefined;
disableCursorAnimation?: boolean | undefined;
} & tailwind_variants.ClassProp<tailwind_variants.ClassValue>) | undefined) => string;
wrapper: (slotProps?: ({
size?: "md" | "sm" | "lg" | undefined;
color?: "default" | "primary" | "secondary" | "success" | "warning" | "danger" | undefined;
radius?: "none" | "md" | "full" | "sm" | "lg" | undefined;
isDisabled?: boolean | undefined;
disableAnimation?: boolean | undefined;
variant?: "flat" | "bordered" | "faded" | "light" | undefined;
isCompact?: boolean | undefined;
showShadow?: boolean | undefined;
disableCursorAnimation?: boolean | undefined;
} & tailwind_variants.ClassProp<tailwind_variants.ClassValue>) | undefined) => string;
item: (slotProps?: ({
size?: "md" | "sm" | "lg" | undefined;
color?: "default" | "primary" | "secondary" | "success" | "warning" | "danger" | undefined;
radius?: "none" | "md" | "full" | "sm" | "lg" | undefined;
isDisabled?: boolean | undefined;
disableAnimation?: boolean | undefined;
variant?: "flat" | "bordered" | "faded" | "light" | undefined;
isCompact?: boolean | undefined;
showShadow?: boolean | undefined;
disableCursorAnimation?: boolean | undefined;
} & tailwind_variants.ClassProp<tailwind_variants.ClassValue>) | undefined) => string;
prev: (slotProps?: ({
size?: "md" | "sm" | "lg" | undefined;
color?: "default" | "primary" | "secondary" | "success" | "warning" | "danger" | undefined;
radius?: "none" | "md" | "full" | "sm" | "lg" | undefined;
isDisabled?: boolean | undefined;
disableAnimation?: boolean | undefined;
variant?: "flat" | "bordered" | "faded" | "light" | undefined;
isCompact?: boolean | undefined;
showShadow?: boolean | undefined;
disableCursorAnimation?: boolean | undefined;
} & tailwind_variants.ClassProp<tailwind_variants.ClassValue>) | undefined) => string;
next: (slotProps?: ({
size?: "md" | "sm" | "lg" | undefined;
color?: "default" | "primary" | "secondary" | "success" | "warning" | "danger" | undefined;
radius?: "none" | "md" | "full" | "sm" | "lg" | undefined;
isDisabled?: boolean | undefined;
disableAnimation?: boolean | undefined;
variant?: "flat" | "bordered" | "faded" | "light" | undefined;
isCompact?: boolean | undefined;
showShadow?: boolean | undefined;
disableCursorAnimation?: boolean | undefined;
} & tailwind_variants.ClassProp<tailwind_variants.ClassValue>) | undefined) => string;
cursor: (slotProps?: ({
size?: "md" | "sm" | "lg" | undefined;
color?: "default" | "primary" | "secondary" | "success" | "warning" | "danger" | undefined;
radius?: "none" | "md" | "full" | "sm" | "lg" | undefined;
isDisabled?: boolean | undefined;
disableAnimation?: boolean | undefined;
variant?: "flat" | "bordered" | "faded" | "light" | undefined;
isCompact?: boolean | undefined;
showShadow?: boolean | undefined;
disableCursorAnimation?: boolean | undefined;
} & tailwind_variants.ClassProp<tailwind_variants.ClassValue>) | undefined) => string;
forwardIcon: (slotProps?: ({
size?: "md" | "sm" | "lg" | undefined;
color?: "default" | "primary" | "secondary" | "success" | "warning" | "danger" | undefined;
radius?: "none" | "md" | "full" | "sm" | "lg" | undefined;
isDisabled?: boolean | undefined;
disableAnimation?: boolean | undefined;
variant?: "flat" | "bordered" | "faded" | "light" | undefined;
isCompact?: boolean | undefined;
showShadow?: boolean | undefined;
disableCursorAnimation?: boolean | undefined;
} & tailwind_variants.ClassProp<tailwind_variants.ClassValue>) | undefined) => string;
ellipsis: (slotProps?: ({
size?: "md" | "sm" | "lg" | undefined;
color?: "default" | "primary" | "secondary" | "success" | "warning" | "danger" | undefined;
radius?: "none" | "md" | "full" | "sm" | "lg" | undefined;
isDisabled?: boolean | undefined;
disableAnimation?: boolean | undefined;
variant?: "flat" | "bordered" | "faded" | "light" | undefined;
isCompact?: boolean | undefined;
showShadow?: boolean | undefined;
disableCursorAnimation?: boolean | undefined;
} & tailwind_variants.ClassProp<tailwind_variants.ClassValue>) | undefined) => string;
chevronNext: (slotProps?: ({
size?: "md" | "sm" | "lg" | undefined;
color?: "default" | "primary" | "secondary" | "success" | "warning" | "danger" | undefined;
radius?: "none" | "md" | "full" | "sm" | "lg" | undefined;
isDisabled?: boolean | undefined;
disableAnimation?: boolean | undefined;
variant?: "flat" | "bordered" | "faded" | "light" | undefined;
isCompact?: boolean | undefined;
showShadow?: boolean | undefined;
disableCursorAnimation?: boolean | undefined;
} & tailwind_variants.ClassProp<tailwind_variants.ClassValue>) | undefined) => string;
} & {
base: (slotProps?: ({
size?: "md" | "sm" | "lg" | undefined;
color?: "default" | "primary" | "secondary" | "success" | "warning" | "danger" | undefined;
radius?: "none" | "md" | "full" | "sm" | "lg" | undefined;
isDisabled?: boolean | undefined;
disableAnimation?: boolean | undefined;
variant?: "flat" | "bordered" | "faded" | "light" | undefined;
isCompact?: boolean | undefined;
showShadow?: boolean | undefined;
disableCursorAnimation?: boolean | undefined;
} & tailwind_variants.ClassProp<tailwind_variants.ClassValue>) | undefined) => string;
wrapper: (slotProps?: ({
size?: "md" | "sm" | "lg" | undefined;
color?: "default" | "primary" | "secondary" | "success" | "warning" | "danger" | undefined;
radius?: "none" | "md" | "full" | "sm" | "lg" | undefined;
isDisabled?: boolean | undefined;
disableAnimation?: boolean | undefined;
variant?: "flat" | "bordered" | "faded" | "light" | undefined;
isCompact?: boolean | undefined;
showShadow?: boolean | undefined;
disableCursorAnimation?: boolean | undefined;
} & tailwind_variants.ClassProp<tailwind_variants.ClassValue>) | undefined) => string;
item: (slotProps?: ({
size?: "md" | "sm" | "lg" | undefined;
color?: "default" | "primary" | "secondary" | "success" | "warning" | "danger" | undefined;
radius?: "none" | "md" | "full" | "sm" | "lg" | undefined;
isDisabled?: boolean | undefined;
disableAnimation?: boolean | undefined;
variant?: "flat" | "bordered" | "faded" | "light" | undefined;
isCompact?: boolean | undefined;
showShadow?: boolean | undefined;
disableCursorAnimation?: boolean | undefined;
} & tailwind_variants.ClassProp<tailwind_variants.ClassValue>) | undefined) => string;
prev: (slotProps?: ({
size?: "md" | "sm" | "lg" | undefined;
color?: "default" | "primary" | "secondary" | "success" | "warning" | "danger" | undefined;
radius?: "none" | "md" | "full" | "sm" | "lg" | undefined;
isDisabled?: boolean | undefined;
disableAnimation?: boolean | undefined;
variant?: "flat" | "bordered" | "faded" | "light" | undefined;
isCompact?: boolean | undefined;
showShadow?: boolean | undefined;
disableCursorAnimation?: boolean | undefined;
} & tailwind_variants.ClassProp<tailwind_variants.ClassValue>) | undefined) => string;
next: (slotProps?: ({
size?: "md" | "sm" | "lg" | undefined;
color?: "default" | "primary" | "secondary" | "success" | "warning" | "danger" | undefined;
radius?: "none" | "md" | "full" | "sm" | "lg" | undefined;
isDisabled?: boolean | undefined;
disableAnimation?: boolean | undefined;
variant?: "flat" | "bordered" | "faded" | "light" | undefined;
isCompact?: boolean | undefined;
showShadow?: boolean | undefined;
disableCursorAnimation?: boolean | undefined;
} & tailwind_variants.ClassProp<tailwind_variants.ClassValue>) | undefined) => string;
cursor: (slotProps?: ({
size?: "md" | "sm" | "lg" | undefined;
color?: "default" | "primary" | "secondary" | "success" | "warning" | "danger" | undefined;
radius?: "none" | "md" | "full" | "sm" | "lg" | undefined;
isDisabled?: boolean | undefined;
disableAnimation?: boolean | undefined;
variant?: "flat" | "bordered" | "faded" | "light" | undefined;
isCompact?: boolean | undefined;
showShadow?: boolean | undefined;
disableCursorAnimation?: boolean | undefined;
} & tailwind_variants.ClassProp<tailwind_variants.ClassValue>) | undefined) => string;
forwardIcon: (slotProps?: ({
size?: "md" | "sm" | "lg" | undefined;
color?: "default" | "primary" | "secondary" | "success" | "warning" | "danger" | undefined;
radius?: "none" | "md" | "full" | "sm" | "lg" | undefined;
isDisabled?: boolean | undefined;
disableAnimation?: boolean | undefined;
variant?: "flat" | "bordered" | "faded" | "light" | undefined;
isCompact?: boolean | undefined;
showShadow?: boolean | undefined;
disableCursorAnimation?: boolean | undefined;
} & tailwind_variants.ClassProp<tailwind_variants.ClassValue>) | undefined) => string;
ellipsis: (slotProps?: ({
size?: "md" | "sm" | "lg" | undefined;
color?: "default" | "primary" | "secondary" | "success" | "warning" | "danger" | undefined;
radius?: "none" | "md" | "full" | "sm" | "lg" | undefined;
isDisabled?: boolean | undefined;
disableAnimation?: boolean | undefined;
variant?: "flat" | "bordered" | "faded" | "light" | undefined;
isCompact?: boolean | undefined;
showShadow?: boolean | undefined;
disableCursorAnimation?: boolean | undefined;
} & tailwind_variants.ClassProp<tailwind_variants.ClassValue>) | undefined) => string;
chevronNext: (slotProps?: ({
size?: "md" | "sm" | "lg" | undefined;
color?: "default" | "primary" | "secondary" | "success" | "warning" | "danger" | undefined;
radius?: "none" | "md" | "full" | "sm" | "lg" | undefined;
isDisabled?: boolean | undefined;
disableAnimation?: boolean | undefined;
variant?: "flat" | "bordered" | "faded" | "light" | undefined;
isCompact?: boolean | undefined;
showShadow?: boolean | undefined;
disableCursorAnimation?: boolean | undefined;
} & tailwind_variants.ClassProp<tailwind_variants.ClassValue>) | undefined) => string;
} & {};
classNames: SlotsToClasses<"prev" | "next" | "base" | "cursor" | "wrapper" | "ellipsis" | "chevronNext" | "item" | "forwardIcon"> | undefined;
loop: boolean;
total: number;
range: PaginationItemValue[];
activePage: number;
getItemRef: (node: HTMLElement | null, value: number) => void;
disableAnimation: boolean;
disableCursorAnimation: boolean;
setPage: (pageNumber: number) => void;
onPrevious: () => void;
onNext: () => void;
renderItem: ((props: PaginationItemRenderProps) => ReactNode) | undefined;
getBaseProps: PropGetter;
getWrapperProps: PropGetter;
getItemProps: PropGetter;
getCursorProps: PropGetter;
getItemAriaLabel: (page?: string | PaginationItemValue) => string | undefined;
};
type UsePaginationReturn = ReturnType<typeof usePagination>;
export { CURSOR_TRANSITION_TIMEOUT, type PaginationItemRenderProps, type UsePaginationProps, type UsePaginationReturn, usePagination };
@@ -0,0 +1,28 @@
import Symbol from './_Symbol.js';
import getRawTag from './_getRawTag.js';
import objectToString from './_objectToString.js';
/** `Object#toString` result references. */
var nullTag = '[object Null]',
undefinedTag = '[object Undefined]';
/** Built-in value references. */
var symToStringTag = Symbol ? Symbol.toStringTag : undefined;
/**
* The base implementation of `getTag` without fallbacks for buggy environments.
*
* @private
* @param {*} value The value to query.
* @returns {string} Returns the `toStringTag`.
*/
function baseGetTag(value) {
if (value == null) {
return value === undefined ? undefinedTag : nullTag;
}
return (symToStringTag && symToStringTag in Object(value))
? getRawTag(value)
: objectToString(value);
}
export default baseGetTag;
@@ -0,0 +1,36 @@
{
"name": "@eslint/js",
"version": "9.39.1",
"description": "ESLint JavaScript language implementation",
"funding": "https://eslint.org/donate",
"main": "./src/index.js",
"types": "./types/index.d.ts",
"scripts": {
"test:types": "tsc -p tests/types/tsconfig.json"
},
"files": [
"LICENSE",
"README.md",
"src",
"types"
],
"publishConfig": {
"access": "public"
},
"repository": {
"type": "git",
"url": "https://github.com/eslint/eslint.git",
"directory": "packages/js"
},
"homepage": "https://eslint.org",
"bugs": "https://github.com/eslint/eslint/issues/",
"keywords": [
"javascript",
"eslint-plugin",
"eslint"
],
"license": "MIT",
"engines": {
"node": "^18.18.0 || ^20.9.0 || >=21.1.0"
}
}
@@ -0,0 +1,73 @@
## Scopes
A _local handle_ is a pointer to an object. All V8 objects are accessed using handles, they are necessary because of the way the V8 garbage collector works.
A handle scope can be thought of as a container for any number of handles. When you've finished with your handles, instead of deleting each one individually you can simply delete their scope.
The creation of `HandleScope` objects is different across the supported versions of V8. Therefore, NAN provides its own implementations that can be used safely across these.
- <a href="#api_nan_handle_scope"><b><code>Nan::HandleScope</code></b></a>
- <a href="#api_nan_escapable_handle_scope"><b><code>Nan::EscapableHandleScope</code></b></a>
Also see the V8 Embedders Guide section on [Handles and Garbage Collection](https://github.com/v8/v8/wiki/Embedder%27s%20Guide#handles-and-garbage-collection).
<a name="api_nan_handle_scope"></a>
### Nan::HandleScope
A simple wrapper around [`v8::HandleScope`](https://v8docs.nodesource.com/node-8.16/d3/d95/classv8_1_1_handle_scope.html).
Definition:
```c++
class Nan::HandleScope {
public:
Nan::HandleScope();
static int NumberOfHandles();
};
```
Allocate a new `Nan::HandleScope` whenever you are creating new V8 JavaScript objects. Note that an implicit `HandleScope` is created for you on JavaScript-accessible methods so you do not need to insert one yourself.
Example:
```c++
// new object is created, it needs a new scope:
void Pointless() {
Nan::HandleScope scope;
v8::Local<v8::Object> obj = Nan::New<v8::Object>();
}
// JavaScript-accessible method already has a HandleScope
NAN_METHOD(Pointless2) {
v8::Local<v8::Object> obj = Nan::New<v8::Object>();
}
```
<a name="api_nan_escapable_handle_scope"></a>
### Nan::EscapableHandleScope
Similar to [`Nan::HandleScope`](#api_nan_handle_scope) but should be used in cases where a function needs to return a V8 JavaScript type that has been created within it.
Definition:
```c++
class Nan::EscapableHandleScope {
public:
Nan::EscapableHandleScope();
static int NumberOfHandles();
template<typename T> v8::Local<T> Escape(v8::Local<T> value);
}
```
Use `Escape(value)` to return the object.
Example:
```c++
v8::Local<v8::Object> EmptyObj() {
Nan::EscapableHandleScope scope;
v8::Local<v8::Object> obj = Nan::New<v8::Object>();
return scope.Escape(obj);
}
```
@@ -0,0 +1,43 @@
'use strict';
var add = require('./add');
var bitwiseAND = require('./bitwiseAND');
var bitwiseNOT = require('./bitwiseNOT');
var bitwiseOR = require('./bitwiseOR');
var bitwiseXOR = require('./bitwiseXOR');
var divide = require('./divide');
var equal = require('./equal');
var exponentiate = require('./exponentiate');
var leftShift = require('./leftShift');
var lessThan = require('./lessThan');
var multiply = require('./multiply');
var remainder = require('./remainder');
var sameValue = require('./sameValue');
var sameValueZero = require('./sameValueZero');
var signedRightShift = require('./signedRightShift');
var subtract = require('./subtract');
var toString = require('./toString');
var unaryMinus = require('./unaryMinus');
var unsignedRightShift = require('./unsignedRightShift');
module.exports = {
add: add,
bitwiseAND: bitwiseAND,
bitwiseNOT: bitwiseNOT,
bitwiseOR: bitwiseOR,
bitwiseXOR: bitwiseXOR,
divide: divide,
equal: equal,
exponentiate: exponentiate,
leftShift: leftShift,
lessThan: lessThan,
multiply: multiply,
remainder: remainder,
sameValue: sameValue,
sameValueZero: sameValueZero,
signedRightShift: signedRightShift,
subtract: subtract,
toString: toString,
unaryMinus: unaryMinus,
unsignedRightShift: unsignedRightShift
};
@@ -0,0 +1,572 @@
/*
@license
Rollup.js v4.53.2
Mon, 10 Nov 2025 08:56:08 GMT - commit d8b0150971681d9efa4f173de5edd2c79a6e03d9
https://github.com/rollup/rollup
Released under the MIT License.
*/
'use strict';
const promises = require('node:fs/promises');
const path = require('node:path');
const process$1 = require('node:process');
const node_url = require('node:url');
const rollup = require('./rollup.js');
const parseAst_js = require('./parseAst.js');
const getLogFilter_js = require('../getLogFilter.js');
function batchWarnings(command) {
const silent = !!command.silent;
const logFilter = generateLogFilter(command);
let count = 0;
const deferredWarnings = new Map();
let warningOccurred = false;
const add = (warning) => {
count += 1;
warningOccurred = true;
if (silent)
return;
if (warning.code in deferredHandlers) {
rollup.getOrCreate(deferredWarnings, warning.code, rollup.getNewArray).push(warning);
}
else if (warning.code in immediateHandlers) {
immediateHandlers[warning.code](warning);
}
else {
title(warning.message);
defaultBody(warning);
}
};
return {
add,
get count() {
return count;
},
flush() {
if (count === 0 || silent)
return;
const codes = [...deferredWarnings.keys()].sort((a, b) => deferredWarnings.get(b).length - deferredWarnings.get(a).length);
for (const code of codes) {
deferredHandlers[code](deferredWarnings.get(code));
}
deferredWarnings.clear();
count = 0;
},
log(level, log) {
if (!logFilter(log))
return;
switch (level) {
case parseAst_js.LOGLEVEL_WARN: {
return add(log);
}
case parseAst_js.LOGLEVEL_DEBUG: {
if (!silent) {
rollup.stderr(rollup.bold(rollup.pc.blue(log.message)));
defaultBody(log);
}
return;
}
default: {
if (!silent) {
rollup.stderr(rollup.bold(rollup.pc.cyan(log.message)));
defaultBody(log);
}
}
}
},
get warningOccurred() {
return warningOccurred;
}
};
}
const immediateHandlers = {
MISSING_NODE_BUILTINS(warning) {
title(`Missing shims for Node.js built-ins`);
rollup.stderr(`Creating a browser bundle that depends on ${parseAst_js.printQuotedStringList(warning.ids)}. You might need to include https://github.com/FredKSchott/rollup-plugin-polyfill-node`);
},
UNKNOWN_OPTION(warning) {
title(`You have passed an unrecognized option`);
rollup.stderr(warning.message);
}
};
const deferredHandlers = {
CIRCULAR_DEPENDENCY(warnings) {
title(`Circular dependenc${warnings.length > 1 ? 'ies' : 'y'}`);
const displayed = warnings.length > 5 ? warnings.slice(0, 3) : warnings;
for (const warning of displayed) {
rollup.stderr(warning.ids.map(parseAst_js.relativeId).join(' -> '));
}
if (warnings.length > displayed.length) {
rollup.stderr(`...and ${warnings.length - displayed.length} more`);
}
},
EMPTY_BUNDLE(warnings) {
title(`Generated${warnings.length === 1 ? ' an' : ''} empty ${warnings.length > 1 ? 'chunks' : 'chunk'}`);
rollup.stderr(parseAst_js.printQuotedStringList(warnings.map(warning => warning.names[0])));
},
EVAL(warnings) {
title('Use of eval is strongly discouraged');
info(parseAst_js.getRollupUrl(parseAst_js.URL_AVOIDING_EVAL));
showTruncatedWarnings(warnings);
},
MISSING_EXPORT(warnings) {
title('Missing exports');
info(parseAst_js.getRollupUrl(parseAst_js.URL_NAME_IS_NOT_EXPORTED));
for (const warning of warnings) {
rollup.stderr(rollup.bold(parseAst_js.relativeId(warning.id)));
rollup.stderr(`${warning.binding} is not exported by ${parseAst_js.relativeId(warning.exporter)}`);
rollup.stderr(rollup.gray(warning.frame));
}
},
MISSING_GLOBAL_NAME(warnings) {
title(`Missing global variable ${warnings.length > 1 ? 'names' : 'name'}`);
info(parseAst_js.getRollupUrl(parseAst_js.URL_OUTPUT_GLOBALS));
rollup.stderr(`Use "output.globals" to specify browser global variable names corresponding to external modules:`);
for (const warning of warnings) {
rollup.stderr(`${rollup.bold(warning.id)} (guessing "${warning.names[0]}")`);
}
},
MIXED_EXPORTS(warnings) {
title('Mixing named and default exports');
info(parseAst_js.getRollupUrl(parseAst_js.URL_OUTPUT_EXPORTS));
rollup.stderr(rollup.bold('The following entry modules are using named and default exports together:'));
warnings.sort((a, b) => (a.id < b.id ? -1 : 1));
const displayedWarnings = warnings.length > 5 ? warnings.slice(0, 3) : warnings;
for (const warning of displayedWarnings) {
rollup.stderr(parseAst_js.relativeId(warning.id));
}
if (displayedWarnings.length < warnings.length) {
rollup.stderr(`...and ${warnings.length - displayedWarnings.length} other entry modules`);
}
rollup.stderr(`\nConsumers of your bundle will have to use chunk.default to access their default export, which may not be what you want. Use \`output.exports: "named"\` to disable this warning.`);
},
NAMESPACE_CONFLICT(warnings) {
title(`Conflicting re-exports`);
for (const warning of warnings) {
rollup.stderr(`"${rollup.bold(parseAst_js.relativeId(warning.reexporter))}" re-exports "${warning.binding}" from both "${parseAst_js.relativeId(warning.ids[0])}" and "${parseAst_js.relativeId(warning.ids[1])}" (will be ignored).`);
}
},
PLUGIN_WARNING(warnings) {
const nestedByPlugin = nest(warnings, 'plugin');
for (const { items } of nestedByPlugin) {
const nestedByMessage = nest(items, 'message');
let lastUrl = '';
for (const { key: message, items } of nestedByMessage) {
title(message);
for (const warning of items) {
if (warning.url && warning.url !== lastUrl)
info((lastUrl = warning.url));
const loc = formatLocation(warning);
if (loc) {
rollup.stderr(rollup.bold(loc));
}
if (warning.frame)
info(warning.frame);
}
}
}
},
SOURCEMAP_BROKEN(warnings) {
title(`Broken sourcemap`);
info(parseAst_js.getRollupUrl(parseAst_js.URL_SOURCEMAP_IS_LIKELY_TO_BE_INCORRECT));
const plugins = [...new Set(warnings.map(({ plugin }) => plugin).filter(Boolean))];
rollup.stderr(`Plugins that transform code (such as ${parseAst_js.printQuotedStringList(plugins)}) should generate accompanying sourcemaps.`);
},
THIS_IS_UNDEFINED(warnings) {
title('"this" has been rewritten to "undefined"');
info(parseAst_js.getRollupUrl(parseAst_js.URL_THIS_IS_UNDEFINED));
showTruncatedWarnings(warnings);
},
UNRESOLVED_IMPORT(warnings) {
title('Unresolved dependencies');
info(parseAst_js.getRollupUrl(parseAst_js.URL_TREATING_MODULE_AS_EXTERNAL_DEPENDENCY));
const dependencies = new Map();
for (const warning of warnings) {
rollup.getOrCreate(dependencies, parseAst_js.relativeId(warning.exporter), rollup.getNewArray).push(parseAst_js.relativeId(warning.id));
}
for (const [dependency, importers] of dependencies) {
rollup.stderr(`${rollup.bold(dependency)} (imported by ${parseAst_js.printQuotedStringList(importers)})`);
}
},
UNUSED_EXTERNAL_IMPORT(warnings) {
title('Unused external imports');
for (const warning of warnings) {
rollup.stderr(warning.names +
' imported from external module "' +
warning.exporter +
'" but never used in ' +
parseAst_js.printQuotedStringList(warning.ids.map(parseAst_js.relativeId)) +
'.');
}
}
};
function defaultBody(log) {
if (log.url) {
info(log.url);
}
const loc = formatLocation(log);
if (loc) {
rollup.stderr(rollup.bold(loc));
}
if (log.frame)
info(log.frame);
}
function title(string_) {
rollup.stderr(rollup.bold(rollup.yellow(`(!) ${string_}`)));
}
function info(url) {
rollup.stderr(rollup.gray(url));
}
function nest(array, property) {
const nested = [];
const lookup = new Map();
for (const item of array) {
const key = item[property];
rollup.getOrCreate(lookup, key, () => {
const items = {
items: [],
key
};
nested.push(items);
return items;
}).items.push(item);
}
return nested;
}
function showTruncatedWarnings(warnings) {
const nestedByModule = nest(warnings, 'id');
const displayedByModule = nestedByModule.length > 5 ? nestedByModule.slice(0, 3) : nestedByModule;
for (const { key: id, items } of displayedByModule) {
rollup.stderr(rollup.bold(parseAst_js.relativeId(id)));
rollup.stderr(rollup.gray(items[0].frame));
if (items.length > 1) {
rollup.stderr(`...and ${items.length - 1} other ${items.length > 2 ? 'occurrences' : 'occurrence'}`);
}
}
if (nestedByModule.length > displayedByModule.length) {
rollup.stderr(`\n...and ${nestedByModule.length - displayedByModule.length} other files`);
}
}
function generateLogFilter(command) {
const filters = rollup.ensureArray(command.filterLogs).flatMap(filter => String(filter).split(','));
if (process.env.ROLLUP_FILTER_LOGS) {
filters.push(...process.env.ROLLUP_FILTER_LOGS.split(','));
}
return getLogFilter_js.getLogFilter(filters);
}
function formatLocation(log) {
const id = log.loc?.file || log.id;
if (!id)
return null;
return log.loc ? `${id}:${log.loc.line}:${log.loc.column}` : id;
}
const stdinName = '-';
let stdinResult = null;
function stdinPlugin(argument) {
const suffix = typeof argument == 'string' && argument.length > 0 ? '.' + argument : '';
return {
load(id) {
if (id === stdinName || id.startsWith(stdinName + '.')) {
return stdinResult || (stdinResult = readStdin());
}
},
name: 'stdin',
resolveId(id) {
if (id === stdinName) {
return id + suffix;
}
}
};
}
function readStdin() {
return new Promise((resolve, reject) => {
const chunks = [];
process$1.stdin.setEncoding('utf8');
process$1.stdin
.on('data', chunk => chunks.push(chunk))
.on('end', () => {
const result = chunks.join('');
resolve(result);
})
.on('error', error => {
reject(error);
});
});
}
function waitForInputPlugin() {
return {
async buildStart(options) {
const inputSpecifiers = Array.isArray(options.input)
? options.input
: Object.keys(options.input);
let lastAwaitedSpecifier = null;
checkSpecifiers: while (true) {
for (const specifier of inputSpecifiers) {
if ((await this.resolve(specifier)) === null) {
if (lastAwaitedSpecifier !== specifier) {
rollup.stderr(`waiting for input ${rollup.bold(specifier)}...`);
lastAwaitedSpecifier = specifier;
}
await new Promise(resolve => setTimeout(resolve, 500));
continue checkSpecifiers;
}
}
break;
}
},
name: 'wait-for-input'
};
}
async function addCommandPluginsToInputOptions(inputOptions, command) {
if (command.stdin !== false) {
inputOptions.plugins.push(stdinPlugin(command.stdin));
}
if (command.waitForBundleInput === true) {
inputOptions.plugins.push(waitForInputPlugin());
}
await addPluginsFromCommandOption(command.plugin, inputOptions);
}
async function addPluginsFromCommandOption(commandPlugin, inputOptions) {
if (commandPlugin) {
const plugins = await rollup.normalizePluginOption(commandPlugin);
for (const plugin of plugins) {
if (/[={}]/.test(plugin)) {
// -p plugin=value
// -p "{transform(c,i){...}}"
await loadAndRegisterPlugin(inputOptions, plugin);
}
else {
// split out plugins joined by commas
// -p node-resolve,commonjs,buble
for (const p of plugin.split(',')) {
await loadAndRegisterPlugin(inputOptions, p);
}
}
}
}
}
async function loadAndRegisterPlugin(inputOptions, pluginText) {
let plugin = null;
let pluginArgument = undefined;
if (pluginText[0] === '{') {
// -p "{transform(c,i){...}}"
plugin = new Function('return ' + pluginText);
}
else {
const match = pluginText.match(/^([\w./:@\\^{|}-]+)(=(.*))?$/);
if (match) {
// -p plugin
// -p plugin=arg
pluginText = match[1];
pluginArgument = new Function('return ' + match[3])();
}
else {
throw new Error(`Invalid --plugin argument format: ${JSON.stringify(pluginText)}`);
}
if (!/^\.|^rollup-plugin-|[/@\\]/.test(pluginText)) {
// Try using plugin prefix variations first if applicable.
// Prefix order is significant - left has higher precedence.
for (const prefix of ['@rollup/plugin-', 'rollup-plugin-']) {
try {
plugin = await requireOrImport(prefix + pluginText);
break;
}
catch {
// if this does not work, we try requiring the actual name below
}
}
}
if (!plugin) {
try {
if (pluginText[0] == '.')
pluginText = path.resolve(pluginText);
// Windows absolute paths must be specified as file:// protocol URL
// Note that we do not have coverage for Windows-only code paths
else if (/^[A-Za-z]:\\/.test(pluginText)) {
pluginText = node_url.pathToFileURL(path.resolve(pluginText)).href;
}
plugin = await requireOrImport(pluginText);
}
catch (error) {
throw new Error(`Cannot load plugin "${pluginText}": ${error.message}.`);
}
}
}
// some plugins do not use `module.exports` for their entry point,
// in which case we try the named default export and the plugin name
if (typeof plugin === 'object') {
plugin = plugin.default || plugin[getCamelizedPluginBaseName(pluginText)];
}
if (!plugin) {
throw new Error(`Cannot find entry for plugin "${pluginText}". The plugin needs to export a function either as "default" or "${getCamelizedPluginBaseName(pluginText)}" for Rollup to recognize it.`);
}
inputOptions.plugins.push(typeof plugin === 'function' ? plugin.call(plugin, pluginArgument) : plugin);
}
function getCamelizedPluginBaseName(pluginText) {
return (pluginText.match(/(@rollup\/plugin-|rollup-plugin-)(.+)$/)?.[2] || pluginText)
.split(/[/\\]/)
.slice(-1)[0]
.split('.')[0]
.split('-')
.map((part, index) => (index === 0 || !part ? part : part[0].toUpperCase() + part.slice(1)))
.join('');
}
async function requireOrImport(pluginPath) {
try {
// eslint-disable-next-line @typescript-eslint/no-require-imports
return require(pluginPath);
}
catch {
return import(pluginPath);
}
}
const loadConfigFile = async (fileName, commandOptions = {}, watchMode = false) => {
const configs = await getConfigList(getDefaultFromCjs(await getConfigFileExport(fileName, commandOptions, watchMode)), commandOptions);
const warnings = batchWarnings(commandOptions);
try {
const normalizedConfigs = [];
for (const config of configs) {
const options = await rollup.mergeOptions(config, watchMode, commandOptions, warnings.log);
await addCommandPluginsToInputOptions(options, commandOptions);
normalizedConfigs.push(options);
}
return { options: normalizedConfigs, warnings };
}
catch (error_) {
warnings.flush();
throw error_;
}
};
async function getConfigFileExport(fileName, commandOptions, watchMode) {
if (commandOptions.configPlugin || commandOptions.bundleConfigAsCjs) {
try {
return await loadTranspiledConfigFile(fileName, commandOptions);
}
catch (error_) {
if (error_.message.includes('not defined in ES module scope')) {
return parseAst_js.error(parseAst_js.logCannotBundleConfigAsEsm(error_));
}
throw error_;
}
}
let cannotLoadEsm = false;
const handleWarning = (warning) => {
if (warning.message?.includes('To load an ES module') ||
warning.message?.includes('Failed to load the ES module')) {
cannotLoadEsm = true;
}
};
process$1.on('warning', handleWarning);
try {
const fileUrl = node_url.pathToFileURL(fileName);
if (watchMode) {
// We are adding the current date to allow reloads in watch mode
fileUrl.search = `?${Date.now()}`;
}
return (await import(fileUrl.href)).default;
}
catch (error_) {
if (cannotLoadEsm) {
return parseAst_js.error(parseAst_js.logCannotLoadConfigAsCjs(error_));
}
if (error_.message.includes('not defined in ES module scope')) {
return parseAst_js.error(parseAst_js.logCannotLoadConfigAsEsm(error_));
}
throw error_;
}
finally {
process$1.off('warning', handleWarning);
}
}
function getDefaultFromCjs(namespace) {
return namespace.default || namespace;
}
function getConfigImportAttributesKey(input) {
if (input === 'assert' || input === 'with')
return input;
return;
}
async function loadTranspiledConfigFile(fileName, commandOptions) {
const { bundleConfigAsCjs, configPlugin, configImportAttributesKey, silent } = commandOptions;
const warnings = batchWarnings(commandOptions);
const inputOptions = {
// Do *not* specify external callback here - instead, perform the externality check it via fallback-plugin just below this comment.
// This allows config plugin to first decide whether some import is external or not, and only then trigger the check in fallback-plugin.
// Since the check is ultra-simple during this stage of transforming the config file itself, it should be fallback instead of primary check.
// That way, e.g. importing workspace packages will work as expected - the workspace package will be bundled.
input: fileName,
onwarn: warnings.add,
plugins: [],
treeshake: false
};
await addPluginsFromCommandOption(configPlugin, inputOptions);
// Add plugin as *last* item after addPluginsFromCommandOption is complete.
// This plugin will trigger for imports not resolved by config plugin, and mark all non-relative imports as external.
inputOptions.plugins.push({
name: 'external-fallback',
resolveId: source => {
const looksLikeExternal = (source[0] !== '.' && !path.isAbsolute(source)) || source.slice(-5) === '.json';
return looksLikeExternal ? false : null;
}
});
const bundle = await rollup.rollup(inputOptions);
const { output: [{ code }] } = await bundle.generate({
exports: 'named',
format: bundleConfigAsCjs ? 'cjs' : 'es',
importAttributesKey: getConfigImportAttributesKey(configImportAttributesKey),
plugins: [
{
name: 'transpile-import-meta',
resolveImportMeta(property, { moduleId }) {
if (property === 'url') {
return `'${node_url.pathToFileURL(moduleId).href}'`;
}
if (property == 'filename') {
return `'${moduleId}'`;
}
if (property == 'dirname') {
return `'${path.dirname(moduleId)}'`;
}
if (property == null) {
return `{url:'${node_url.pathToFileURL(moduleId).href}', filename: '${moduleId}', dirname: '${path.dirname(moduleId)}'}`;
}
}
}
]
});
if (!silent && warnings.count > 0) {
rollup.stderr(rollup.bold(`loaded ${parseAst_js.relativeId(fileName)} with warnings`));
warnings.flush();
}
return loadConfigFromWrittenFile(path.join(path.dirname(fileName), `rollup.config-${Date.now()}.${bundleConfigAsCjs ? 'cjs' : 'mjs'}`), code);
}
async function loadConfigFromWrittenFile(bundledFileName, bundledCode) {
await promises.writeFile(bundledFileName, bundledCode);
try {
return (await import(node_url.pathToFileURL(bundledFileName).href)).default;
}
finally {
promises.unlink(bundledFileName).catch(error => console.warn(error?.message || error));
}
}
async function getConfigList(configFileExport, commandOptions) {
const config = await (typeof configFileExport === 'function'
? configFileExport(commandOptions)
: configFileExport);
if (Object.keys(config).length === 0) {
return parseAst_js.error(parseAst_js.logMissingConfig());
}
return Array.isArray(config) ? config : [config];
}
exports.addCommandPluginsToInputOptions = addCommandPluginsToInputOptions;
exports.batchWarnings = batchWarnings;
exports.loadConfigFile = loadConfigFile;
exports.stdinName = stdinName;
//# sourceMappingURL=loadConfigFile.js.map
@@ -0,0 +1,82 @@
import baseRandom from './_baseRandom.js';
import isIterateeCall from './_isIterateeCall.js';
import toFinite from './toFinite.js';
/** Built-in method references without a dependency on `root`. */
var freeParseFloat = parseFloat;
/* Built-in method references for those with the same name as other `lodash` methods. */
var nativeMin = Math.min,
nativeRandom = Math.random;
/**
* Produces a random number between the inclusive `lower` and `upper` bounds.
* If only one argument is provided a number between `0` and the given number
* is returned. If `floating` is `true`, or either `lower` or `upper` are
* floats, a floating-point number is returned instead of an integer.
*
* **Note:** JavaScript follows the IEEE-754 standard for resolving
* floating-point values which can produce unexpected results.
*
* @static
* @memberOf _
* @since 0.7.0
* @category Number
* @param {number} [lower=0] The lower bound.
* @param {number} [upper=1] The upper bound.
* @param {boolean} [floating] Specify returning a floating-point number.
* @returns {number} Returns the random number.
* @example
*
* _.random(0, 5);
* // => an integer between 0 and 5
*
* _.random(5);
* // => also an integer between 0 and 5
*
* _.random(5, true);
* // => a floating-point number between 0 and 5
*
* _.random(1.2, 5.2);
* // => a floating-point number between 1.2 and 5.2
*/
function random(lower, upper, floating) {
if (floating && typeof floating != 'boolean' && isIterateeCall(lower, upper, floating)) {
upper = floating = undefined;
}
if (floating === undefined) {
if (typeof upper == 'boolean') {
floating = upper;
upper = undefined;
}
else if (typeof lower == 'boolean') {
floating = lower;
lower = undefined;
}
}
if (lower === undefined && upper === undefined) {
lower = 0;
upper = 1;
}
else {
lower = toFinite(lower);
if (upper === undefined) {
upper = lower;
lower = 0;
} else {
upper = toFinite(upper);
}
}
if (lower > upper) {
var temp = lower;
lower = upper;
upper = temp;
}
if (floating || lower % 1 || upper % 1) {
var rand = nativeRandom();
return nativeMin(lower + (rand * (upper - lower + freeParseFloat('1e-' + ((rand + '').length - 1)))), upper);
}
return baseRandom(lower, upper);
}
export default random;
@@ -0,0 +1 @@
{"version":3,"names":["_options","require","_parse","_populate","literalTemplate","formatter","tpl","opts","metadata","names","buildLiteralData","arg","defaultReplacements","forEach","replacement","i","replacements","normalizeReplacements","Object","keys","key","hasOwnProperty","call","Error","unwrap","populatePlaceholders","assign","prefix","raw","join","includes","code","buildTemplateCode","parseAndBuildMetadata","parser","placeholderWhitelist","Set","concat","Array","from","placeholderPattern","preserveComments","syntacticPlaceholders","length","value","push"],"sources":["../src/literal.ts"],"sourcesContent":["import type { Formatter } from \"./formatters.ts\";\nimport type { TemplateReplacements, TemplateOpts } from \"./options.ts\";\nimport { normalizeReplacements } from \"./options.ts\";\nimport parseAndBuildMetadata from \"./parse.ts\";\nimport populatePlaceholders from \"./populate.ts\";\n\nexport default function literalTemplate<T>(\n formatter: Formatter<T>,\n tpl: Array<string>,\n opts: TemplateOpts,\n): (_: Array<unknown>) => (_: unknown) => T {\n const { metadata, names } = buildLiteralData(formatter, tpl, opts);\n\n return arg => {\n const defaultReplacements: TemplateReplacements = {};\n arg.forEach((replacement, i) => {\n defaultReplacements[names[i]] = replacement;\n });\n\n return (arg: unknown) => {\n const replacements = normalizeReplacements(arg);\n\n if (replacements) {\n Object.keys(replacements).forEach(key => {\n if (Object.hasOwn(defaultReplacements, key)) {\n throw new Error(\"Unexpected replacement overlap.\");\n }\n });\n }\n\n return formatter.unwrap(\n populatePlaceholders(\n metadata,\n replacements\n ? Object.assign(replacements, defaultReplacements)\n : defaultReplacements,\n ),\n );\n };\n };\n}\n\nfunction buildLiteralData<T>(\n formatter: Formatter<T>,\n tpl: Array<string>,\n opts: TemplateOpts,\n) {\n let prefix = \"BABEL_TPL$\";\n\n const raw = tpl.join(\"\");\n\n do {\n // If there are cases where the template already contains $$BABEL_TPL$0 or any other\n // matching pattern, we keep adding \"$$\" characters until a unique prefix\n // is found.\n prefix = \"$$\" + prefix;\n } while (raw.includes(prefix));\n\n const { names, code } = buildTemplateCode(tpl, prefix);\n\n const metadata = parseAndBuildMetadata(formatter, formatter.code(code), {\n parser: opts.parser,\n\n // Explicitly include our generated names in the whitelist so users never\n // have to think about whether their placeholder pattern will match.\n placeholderWhitelist: new Set(\n names.concat(\n opts.placeholderWhitelist ? Array.from(opts.placeholderWhitelist) : [],\n ),\n ),\n placeholderPattern: opts.placeholderPattern,\n preserveComments: opts.preserveComments,\n syntacticPlaceholders: opts.syntacticPlaceholders,\n });\n\n return { metadata, names };\n}\n\nfunction buildTemplateCode(\n tpl: Array<string>,\n prefix: string,\n): { names: Array<string>; code: string } {\n const names = [];\n\n let code = tpl[0];\n\n for (let i = 1; i < tpl.length; i++) {\n const value = `${prefix}${i - 1}`;\n names.push(value);\n\n code += value + tpl[i];\n }\n\n return { names, code };\n}\n"],"mappings":";;;;;;AAEA,IAAAA,QAAA,GAAAC,OAAA;AACA,IAAAC,MAAA,GAAAD,OAAA;AACA,IAAAE,SAAA,GAAAF,OAAA;AAEe,SAASG,eAAeA,CACrCC,SAAuB,EACvBC,GAAkB,EAClBC,IAAkB,EACwB;EAC1C,MAAM;IAAEC,QAAQ;IAAEC;EAAM,CAAC,GAAGC,gBAAgB,CAACL,SAAS,EAAEC,GAAG,EAAEC,IAAI,CAAC;EAElE,OAAOI,GAAG,IAAI;IACZ,MAAMC,mBAAyC,GAAG,CAAC,CAAC;IACpDD,GAAG,CAACE,OAAO,CAAC,CAACC,WAAW,EAAEC,CAAC,KAAK;MAC9BH,mBAAmB,CAACH,KAAK,CAACM,CAAC,CAAC,CAAC,GAAGD,WAAW;IAC7C,CAAC,CAAC;IAEF,OAAQH,GAAY,IAAK;MACvB,MAAMK,YAAY,GAAG,IAAAC,8BAAqB,EAACN,GAAG,CAAC;MAE/C,IAAIK,YAAY,EAAE;QAChBE,MAAM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CAACmC;EAC9B,CAAC,CAAC;EAEF,OAAO;ILine truncated
@@ -0,0 +1,196 @@
import { expect, expectTypeOf, test } from "vitest";
import * as z from "zod/v4";
const stringMap = z.map(z.string(), z.string());
type stringMap = z.infer<typeof stringMap>;
test("type inference", () => {
expectTypeOf<stringMap>().toEqualTypeOf<Map<string, string>>();
});
test("valid parse", () => {
const result = stringMap.safeParse(
new Map([
["first", "foo"],
["second", "bar"],
])
);
expect(result.success).toEqual(true);
expect(result.data).toMatchInlineSnapshot(`
Map {
"first" => "foo",
"second" => "bar",
}
`);
});
test("valid parse async", async () => {
const asyncMap = z.map(
z.string().refine(async () => false, "bad key"),
z.string().refine(async () => false, "bad value")
);
const result = await asyncMap.safeParseAsync(new Map([["first", "foo"]]));
expect(result.success).toEqual(false);
expect(result.error).toMatchInlineSnapshot(`
[ZodError: [
{
"code": "custom",
"path": [
"first"
],
"message": "bad key"
},
{
"code": "custom",
"path": [
"first"
],
"message": "bad value"
}
]]
`);
});
test("throws when a Set is given", () => {
const result = stringMap.safeParse(new Set([]));
expect(result.success).toEqual(false);
if (result.success === false) {
expect(result.error.issues.length).toEqual(1);
expect(result.error.issues[0].code).toEqual("invalid_type");
}
});
test("throws when the given map has invalid key and invalid input", () => {
const result = stringMap.safeParse(new Map([[42, Symbol()]]));
expect(result.success).toEqual(false);
if (result.success === false) {
expect(result.error.issues.length).toEqual(2);
expect(result.error).toMatchInlineSnapshot(`
[ZodError: [
{
"expected": "string",
"code": "invalid_type",
"path": [
42
],
"message": "Invalid input: expected string, received number"
},
{
"expected": "string",
"code": "invalid_type",
"path": [
42
],
"message": "Invalid input: expected string, received symbol"
}
]]
`);
}
});
test("throws when the given map has multiple invalid entries", () => {
// const result = stringMap.safeParse(new Map([[42, Symbol()]]));
const result = stringMap.safeParse(
new Map([
[1, "foo"],
["bar", 2],
] as [any, any][]) as Map<any, any>
);
// const result = stringMap.safeParse(new Map([[42, Symbol()]]));
expect(result.success).toEqual(false);
if (result.success === false) {
expect(result.error.issues.length).toEqual(2);
expect(result.error.issues).toMatchInlineSnapshot(`
[
{
"code": "invalid_type",
"expected": "string",
"message": "Invalid input: expected string, received number",
"path": [
1,
],
},
{
"code": "invalid_type",
"expected": "string",
"message": "Invalid input: expected string, received number",
"path": [
"bar",
],
},
]
`);
}
});
test("dirty", async () => {
const map = z.map(
z.string().refine((val) => val === val.toUpperCase(), {
message: "Keys must be uppercase",
}),
z.string()
);
const result = await map.spa(
new Map([
["first", "foo"],
["second", "bar"],
])
);
expect(result.success).toEqual(false);
if (!result.success) {
expect(result.error.issues.length).toEqual(2);
expect(result.error).toMatchInlineSnapshot(`
[ZodError: [
{
"code": "custom",
"path": [
"first"
],
"message": "Keys must be uppercase"
},
{
"code": "custom",
"path": [
"second"
],
"message": "Keys must be uppercase"
}
]]
`);
}
});
test("map with object keys", () => {
const map = z.map(
z.object({
name: z.string(),
age: z.number(),
}),
z.string()
);
const data = new Map([
[{ name: "John", age: 30 }, "foo"],
[{ name: "Jane", age: 25 }, "bar"],
]);
const result = map.safeParse(data);
expect(result.success).toEqual(true);
expect(result.data!).toEqual(data);
const badData = new Map([["bad", "foo"]]);
const badResult = map.safeParse(badData);
expect(badResult.success).toEqual(false);
expect(badResult.error).toMatchInlineSnapshot(`
[ZodError: [
{
"expected": "object",
"code": "invalid_type",
"path": [
"bad"
],
"message": "Invalid input: expected object, received string"
}
]]
`);
});
@@ -0,0 +1 @@
{"version":3,"file":"inversify-InversifyJs-issue-1806-containerSnapshotShouldNotBeUpdated.spec.d.ts","sourceRoot":"","sources":["../../../src/issues/inversify-InversifyJs-issue-1806-containerSnapshotShouldNotBeUpdated.spec.ts"],"names":[],"mappings":"AAEA,OAAO,kBAAkB,CAAC"}
@@ -0,0 +1,164 @@
import { FileSystemAdapter, Pattern } from './types';
export declare const DEFAULT_FILE_SYSTEM_ADAPTER: FileSystemAdapter;
export type Options = {
/**
* Return the absolute path for entries.
*
* @default false
*/
absolute?: boolean;
/**
* If set to `true`, then patterns without slashes will be matched against
* the basename of the path if it contains slashes.
*
* @default false
*/
baseNameMatch?: boolean;
/**
* Enables Bash-like brace expansion.
*
* @default true
*/
braceExpansion?: boolean;
/**
* Enables a case-sensitive mode for matching files.
*
* @default true
*/
caseSensitiveMatch?: boolean;
/**
* Specifies the maximum number of concurrent requests from a reader to read
* directories.
*
* @default os.cpus().length
*/
concurrency?: number;
/**
* The current working directory in which to search.
*
* @default process.cwd()
*/
cwd?: string;
/**
* Specifies the maximum depth of a read directory relative to the start
* directory.
*
* @default Infinity
*/
deep?: number;
/**
* Allow patterns to match entries that begin with a period (`.`).
*
* @default false
*/
dot?: boolean;
/**
* Enables Bash-like `extglob` functionality.
*
* @default true
*/
extglob?: boolean;
/**
* Indicates whether to traverse descendants of symbolic link directories.
*
* @default true
*/
followSymbolicLinks?: boolean;
/**
* Custom implementation of methods for working with the file system.
*
* @default fs.*
*/
fs?: Partial<FileSystemAdapter>;
/**
* Enables recursively repeats a pattern containing `**`.
* If `false`, `**` behaves exactly like `*`.
*
* @default true
*/
globstar?: boolean;
/**
* An array of glob patterns to exclude matches.
* This is an alternative way to use negative patterns.
*
* @default []
*/
ignore?: Pattern[];
/**
* Mark the directory path with the final slash.
*
* @default false
*/
markDirectories?: boolean;
/**
* Returns objects (instead of strings) describing entries.
*
* @default false
*/
objectMode?: boolean;
/**
* Return only directories.
*
* @default false
*/
onlyDirectories?: boolean;
/**
* Return only files.
*
* @default true
*/
onlyFiles?: boolean;
/**
* Enables an object mode (`objectMode`) with an additional `stats` field.
*
* @default false
*/
stats?: boolean;
/**
* By default this package suppress only `ENOENT` errors.
* Set to `true` to suppress any error.
*
* @default false
*/
suppressErrors?: boolean;
/**
* Throw an error when symbolic link is broken if `true` or safely
* return `lstat` call if `false`.
*
* @default false
*/
throwErrorOnBrokenSymbolicLink?: boolean;
/**
* Ensures that the returned entries are unique.
*
* @default true
*/
unique?: boolean;
};
export default class Settings {
private readonly _options;
readonly absolute: boolean;
readonly baseNameMatch: boolean;
readonly braceExpansion: boolean;
readonly caseSensitiveMatch: boolean;
readonly concurrency: number;
readonly cwd: string;
readonly deep: number;
readonly dot: boolean;
readonly extglob: boolean;
readonly followSymbolicLinks: boolean;
readonly fs: FileSystemAdapter;
readonly globstar: boolean;
readonly ignore: Pattern[];
readonly markDirectories: boolean;
readonly objectMode: boolean;
readonly onlyDirectories: boolean;
readonly onlyFiles: boolean;
readonly stats: boolean;
readonly suppressErrors: boolean;
readonly throwErrorOnBrokenSymbolicLink: boolean;
readonly unique: boolean;
constructor(_options?: Options);
private _getValue;
private _getFileSystemMethods;
}
@@ -0,0 +1,3 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=InjectFromHierarchyOptionsLifecycle.js.map
@@ -0,0 +1,5 @@
var convert = require('./convert'),
func = convert('isArrayLike', require('../isArrayLike'), require('./_falseOptions'));
func.placeholder = require('./placeholder');
module.exports = func;
@@ -0,0 +1,115 @@
{
"name": "array.prototype.findlastindex",
"version": "1.2.6",
"description": "An ESnext spec-compliant `Array.prototype.findLastIndex` shim/polyfill/replacement that works as far down as ES3.",
"author": {
"name": "Jordan Harband",
"email": "ljharb@gmail.com",
"url": "http://ljharb.codes"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
},
"contributors": [
{
"name": "Jordan Harband",
"email": "ljharb@gmail.com",
"url": "http://ljharb.codes"
}
],
"license": "MIT",
"bugs": {
"url": "https://github.com/es-shims/Array.prototype.findLastIndex/issues"
},
"homepage": "https://github.com/es-shims/Array.prototype.findLastIndex#readme",
"main": "index.js",
"exports": {
".": "./index.js",
"./auto": "./auto.js",
"./polyfill": "./polyfill.js",
"./implementation": "./implementation.js",
"./shim": "./shim.js",
"./package.json": "./package.json"
},
"scripts": {
"prepack": "npmignore --auto --commentLines=autogenerated",
"prepublishOnly": "safe-publish-latest",
"prepublish": "not-in-publish || npm run prepublishOnly",
"pretest": "npm run --silent lint",
"posttest": "npx npm@\">= 10.2\" audit --production",
"tests-only": "nyc tape 'test/**/*.js'",
"test": "npm run tests-only",
"prelint": "evalmd README.md",
"lint": "eslint --ext=js,mjs .",
"postlint": "es-shim-api --bound",
"version": "auto-changelog && git add CHANGELOG.md",
"postversion": "auto-changelog && git add CHANGELOG.md && git commit --no-edit --amend && git tag -f \"v$(node -e \"console.log(require('./package.json').version)\")\""
},
"repository": {
"type": "git",
"url": "git+https://github.com/es-shims/Array.prototype.findLastIndex.git"
},
"keywords": [
"Array.prototype.findLastIndex",
"find",
"findLast",
"findLastIndex",
"array",
"ESnext",
"shim",
"polyfill",
"last",
"es-shim API"
],
"dependencies": {
"call-bind": "^1.0.8",
"call-bound": "^1.0.4",
"define-properties": "^1.2.1",
"es-abstract": "^1.23.9",
"es-errors": "^1.3.0",
"es-object-atoms": "^1.1.1",
"es-shim-unscopables": "^1.1.0"
},
"devDependencies": {
"@es-shims/api": "^2.5.1",
"@ljharb/eslint-config": "^21.1.1",
"auto-changelog": "^2.5.0",
"encoding": "^0.1.13",
"es-value-fixtures": "^1.7.1",
"eslint": "=8.8.0",
"evalmd": "^0.0.19",
"for-each": "^0.3.5",
"functions-have-names": "^1.2.3",
"globalthis": "^1.0.4",
"has-strict-mode": "^1.1.0",
"hasown": "^2.0.2",
"in-publish": "^2.0.1",
"npmignore": "^0.3.1",
"nyc": "^10.3.2",
"object-inspect": "^1.13.4",
"safe-publish-latest": "^2.0.0",
"tape": "^5.9.0"
},
"testling": {
"files": [
"test/index.js",
"test/shimmed.js"
]
},
"engines": {
"node": ">= 0.4"
},
"auto-changelog": {
"output": "CHANGELOG.md",
"template": "keepachangelog",
"unreleased": false,
"commitLimit": false,
"backfillLimit": false,
"hideCredit": true
},
"publishConfig": {
"ignore": [
".github/workflows"
]
}
}
@@ -0,0 +1 @@
{"name":"micromark","version":"4.0.2","requiresBuild":false,"files":{"license":{"checkedAt":1794532112631,"integrity":"sha512-ic4iF2Ap25Sn5T9MMw7nJ9C20WL6V01rybBBQi2Qx8cQC9/ERFEqGnove1HT65tK2TIKM30PZoOV3Qbz2FE//A==","mode":420,"size":1094},"dev/lib/compile.js":{"checkedAt":1794532112904,"integrity":"sha512-QUbYibbNms8loGMhNaQbIr+VQ2KBgFNemF3D6gt38jUXUBrmtV5pSwlq5k1FN86nUMLY15e52wncMsoP1j93OA==","mode":420,"size":27510},"lib/compile.js":{"checkedAt":1794532112904,"integrity":"sha512-SAW2pP2ijooSoq57mw7a4URDq3MlFxLWQhubcn1Ai8nTaMPoO3lzOaxNLseeRofLaktkDeq/ja2BLT2j7YhTaw==","mode":420,"size":26755},"dev/lib/constructs.js":{"checkedAt":1794532112906,"integrity":"sha512-LYfSdEvh262tgryPv80gpBRN5uQ5ufDKkzegmYIXYTqw/ZCgfKgc8Pqva6ESo3Jrl9RsMDtaSo/S5HYDcZaCOQ==","mode":420,"size":2578},"lib/constructs.js":{"checkedAt":1794532112906,"integrity":"sha512-kwW1JS2on9LqOYGqtqJmSQP40RPT0RFRFnuvjtj0IpvtfP4scf0FPInv/vfBccQwqx5xmaPFuSezYtBIt7vWJQ==","mode":420,"size":1964},"dev/lib/initialize/content.js":{"checkedAt":1794532112906,"integrity":"sha512-uyFTzp2VhrpIuld9S7WEzuiy7JBPX9RSzCBEUzyonGkD0Ccd7fQFVRevWpV2CLw1ycYJylO6OB414fnikcLnBw==","mode":420,"size":2101},"lib/initialize/content.js":{"checkedAt":1794532112906,"integrity":"sha512-XWErAcbepEjDbuU1VU+WTFHwCecyxLWBqO3DGxqW7CU3E0DgTDoymXKWLSbLOHU8cIMdoxQZLsVGnxogtJObIw==","mode":420,"size":1721},"dev/lib/create-tokenizer.js":{"checkedAt":1794532112906,"integrity":"sha512-0kar5OISBgvGgUi0MovtFcuJeNJexNQ+lq8ujBCYeL9DwG2rIvL2a0mYBPAxD96k6sHu1nvLvyEUHVfkvj79/g==","mode":420,"size":17859},"lib/create-tokenizer.js":{"checkedAt":1794532112907,"integrity":"sha512-4BxqQepo4TwxWA84I/ZfCADsz1rV/YJDQwsTW/B6zRf68vzZfWCrhwfhW8PtaOBinH5VU6QBdrQmWNet6mAzAQ==","mode":420,"size":15175},"dev/lib/initialize/document.js":{"checkedAt":1794532112907,"integrity":"sha512-j5pQsE2iOJdL0gT2vI8YJN1kszuWxOt4BOFWj/vaq4zqidjRQtNt1pIYKVVOsRIRRtrR6CJAk/Qf7D1dVnjN9Q==","mode":420,"size":12231},"lib/initialize/document.js":{"checkedAt":1794532112907,"integrity":"sha512-i6JJfWvtxc0rWfpJOiC1kPk/PobOsf1tapg2wmXQh/6m7LRvLz5/BOieJYMm19+hN2t2OdpmGOe0AJ/hnNwWyQ==","mode":420,"size":10860},"dev/lib/initialize/flow.js":{"checkedAt":1794532112907,"integrity":"sha512-WCKVO2mp8mbHSJo2egYqqB9B+foEZr1VPdzmhE0mhD9OZGTJxH+4NIYrFWygp185OBIEIHbh4nzGaFZiQESRcg==","mode":420,"size":1911},"lib/initialize/flow.js":{"checkedAt":1794532112907,"integrity":"sha512-RN/FI80ncrS/YDS1T+9wdGdIkSe2Gb7XzMhvOmNqing4x4b8l/UmiGYLF1uv5Gf+eEX9t3r+PR0b+KghwFeGWA==","mode":420,"size":1507},"dev/index.js":{"checkedAt":1794532112907,"integrity":"sha512-ZT9ene0dTejMryBsKze+17QgDHiFkYfOeuhr9wDi8pb/Ha+pzThNxWPuCCumOBtFJNhO0BmSUZ1H4D8bjJqD2A==","mode":420,"size":1907},"index.js":{"checkedAt":1794532112907,"integrity":"sha512-dwzLuRP8yCZiIozsks91RXvd9q76G14Sg59oZg+UmgGE/qiKd8iKPkVHUmXmuEkVJwBNeBIsa9CtiOOe1w5MxA==","mode":420,"size":1893},"dev/lib/parse.js":{"checkedAt":1794532112907,"integrity":"sha512-TtUGqwabN7yCpIihPUAxy2yaLHLvagAdf1mAfxupst06GjcI3a43fnFC4hU4gTNhoAPZzkc3XRI3RyalOT1/KA==","mode":420,"size":1420},"lib/parse.js":{"checkedAt":1794532112908,"integrity":"sha512-XnGcBXUjgKrHZuGPMC6NNZmUV53wQ0AbO1taGbRgPYXSqTCS2toR/MHT0Ogy7qmajLRLVo0Qa47nmBLmWh6tkw==","mode":420,"size":1435},"dev/lib/postprocess.js":{"checkedAt":1794532112908,"integrity":"sha512-hCZ7VeeR4Sp02blOH1zZsdKudOcq8L7F5bHMjlQVHfVoGmd1NmMYDa2YzDXGuuQFp+9b5n4HX9d0tkYVva7a6A==","mode":420,"size":312},"lib/postprocess.js":{"checkedAt":1794532112908,"integrity":"sha512-il86oZPFsACR578qIZwWEEfXR83e7j2B/XP4OHAzBTSVKc19TDdYNw887/AQWtrupfbXqSpQYl+L0cMvIgCSOg==","mode":420,"size":314},"dev/lib/preprocess.js":{"checkedAt":1794532112908,"integrity":"sha512-kwKBXkdjaQ+Zlkzfmy9RVdbwynxroQUe3u/1D3nv20xEDHlDXJeG5jNRTGLx1lBNlzbXlKckIY6LWafZ+ayxFg==","mode":420,"size":3289},"lib/preprocess.js":{"checkedAt":1794532112908,"integrity":"sha512-MpHIVPTfgfo1GONIj07SQmJHRf+0OyaJNghzXdyDrVpbEwk41iOzFEtedeKobKO9rLcmirRhCYtxS7ZSGxqhVg==","mode":420,"size":3063},"dev/stream.js":{"checkedAt":1794532112908,"integrity":"sha512-2HhAeUsi+IQleqZvs37mr408zW4M9EheFgUrihnpFgAQmm843PcvzXetJjRGvgzE0/C4smHrGlyMIRabmycrHg==","mode":420,"size":7701},"stream.js":{"checkedAt":1794532112909,"integrity":"sha512-3UWhpX4kX7ZN3ZB4/IzAHX806eNcrkeiMbIhxKCqZT9KE9jsJD8Zp0QkknafuGQbQPGECTr1o+eUrtpfjEmGrg==","mode":420,"size":7744},"dev/lib/initialize/text.js":{"checkedAt":1794532112910,"integrity":"sha512-OT9GQQo7zeeUNw1HHr+Zadk+VNQyIjjwYLIzHGaiiKoxiVZt5Ksh7DGr5DPsAYHeJ8y+CIPqVxFjcH8AK2t8Kw==","mode":420,"size":5959},"lib/initialize/text.js":{"checkedAt":1794532112910,"integrity":"sha512-Z34gDjRz7kA81IV06g1+WBzolvfCuablrY4+uJFCtCWlPFvKOaB3yrUV+K64TOIA7oynf6Ho17pXnocVTOLeTg==","mode":420,"size":5566},"package.json":{"checkedAt":1794532112910,"integrity":"sha512-U4bC6goelr7yJloRA0AQptjlzM411PH8N9vL+Kw5/cbSSJGX0aMSBEhwzAywO6944vSnNoYQFCsqZlLwz2jidQ==","mode":420,"size":2498},"dev/lib/compile.d.ts.map":{"checkedAt":1794532112910,"integrity":"sha512-H1XvvLo465JDw9gf9rLbdHJ2qXeGZf8YR9Mtxr2jmsXrHpkIaSq93TpmqZ2TZTAWnna/hXZivxxggiyNvD1Ovg==","modeLine truncated
@@ -0,0 +1,7 @@
import * as react_jsx_runtime from 'react/jsx-runtime';
import { IconSvgProps } from './types.mjs';
import 'react';
declare const AvatarIcon: (props: IconSvgProps) => react_jsx_runtime.JSX.Element;
export { AvatarIcon };
@@ -0,0 +1 @@
{"name":"ttf2woff2","version":"4.0.5","requiresBuild":true,"files":{"LICENSE":{"checkedAt":1794532120985,"integrity":"sha512-vtaCl/zJKrh8m6yB+LA5z9LTL3Cdr9rc18RRBrFXULGwCmaPutLULAbKrBVj+iEQe8x2QxsFyBIsiCgZlyRu9Q==","mode":420,"size":1089},"csrc/addon.cc":{"checkedAt":1794532120985,"integrity":"sha512-xkLHGSNsd1bl68jkwJAkfsV5/vsuglFywwk8BizlTJn7fJsTSPHaqMq5rw5B1rYYZJipSnU8pkcmDj4CXd6UCA==","mode":420,"size":1597},"csrc/enc/backward_references.cc":{"checkedAt":1794532120985,"integrity":"sha512-mee9ydlsUiKsDgOipmk7QF5OTMuOtC740XVZpG2BQHYwFkTqggl3Vqw9Po61rVTIOSzKD6rSYZvgLEn1sDCSqw==","mode":420,"size":15446},"csrc/enc/block_splitter.cc":{"checkedAt":1794532120985,"integrity":"sha512-b+VLF8Tw3jf0uJHuwJ9I04IMrvNEHyGBiITnvv1PwnlijVwaVBT00KW5UECgFUGav5w0ImORHdZkn6UOzmKR8w==","mode":420,"size":13542},"csrc/enc/brotli_bit_stream.cc":{"checkedAt":1794532120986,"integrity":"sha512-bNKgsOwegzW7r4nCshxJvnIXCktgVCD6JKsW2iDt/TMmQlkg8QeL0qyZs1knyByzpylS0J8cIMNLtU2VWkJ2YQ==","mode":420,"size":29327},"csrc/enc/encode_parallel.cc":{"checkedAt":1794532120986,"integrity":"sha512-MMFs74OhIdKg/ns1CXpMBkqYa2d8qidRNFCK3Yqaoc6uqrQFHKa+6bKETouTJo/1SIYR9PeGXC+/4MsCgSXBTw==","mode":420,"size":11528},"csrc/enc/encode.cc":{"checkedAt":1794532120986,"integrity":"sha512-kVD61bU+iJKcObVg8HG+ZhgnAYXLjF+ukVRpGP93YtIkyFIW7QmQIlu3eEFALWzHjnKsmd2BNHG9fod/LSr+NQ==","mode":420,"size":20624},"csrc/enc/entropy_encode.cc":{"checkedAt":1794532120986,"integrity":"sha512-CJT77wbVw0WDPdTyejAuGN4aA0Ves+8weBAx/lNbkBwgQjHzsfzAmt05Dr1rJYK0V68Jx2AmjdyEQxudmmVsWw==","mode":420,"size":13832},"csrc/fallback.cc":{"checkedAt":1794532120986,"integrity":"sha512-Xp7cQ7ggHfuWT/cjeCRunHQ/pCfiTSb5vDjw7+wd+6YVz5l+H0w+ZeqDYAIaPVEVwAGuHJC9aIJ4MBW1vAD60A==","mode":420,"size":1393},"csrc/woff2/font.cc":{"checkedAt":1794532120986,"integrity":"sha512-tSqxqujVH5OoYEiZ+2QzsF3Ovu60659P9LW0tmB4+4lmQV6MZrMjT6YGkgR3Epswb8moBTGnVPOf8thG5PfW1w==","mode":420,"size":12352},"csrc/woff2/glyph.cc":{"checkedAt":1794532120986,"integrity":"sha512-afB4aKhp79ZQqJ6hCz5XqFDdlnJIrbtuZZBeeSN/oCfOvrbsnaRbsthaqtDOUQ90AL6oLmTsQhCXeLAHvOe5JA==","mode":420,"size":11643},"csrc/enc/histogram.cc":{"checkedAt":1794532120987,"integrity":"sha512-oiULifoRV4X6yxDYoNKiZfaansncjn5Shzx9bYF66GYmQyQcK4jFJOLTRFQG1sDtDObzSXDhiKz20Q0/m6n8oQ==","mode":420,"size":2565},"csrc/enc/literal_cost.cc":{"checkedAt":1794532120987,"integrity":"sha512-1SOZEDDIw310VZQ4snoxJwpIgk6exsgWa44dMDNmD+WXEOG+wjGl68//rbcFwRR1OYpat5Qa62NxlH2E2ewYbA==","mode":420,"size":5652},"csrc/enc/metablock.cc":{"checkedAt":1794532120987,"integrity":"sha512-V1bd67KV3umeTQYbIVFLtYD2ftulKrJdrmfmT9I4DMSx4b/Ykbd6OdNQVoyVgD46ukcZb3UjHsfjeMYVv/V6zw==","mode":420,"size":12070},"csrc/woff2/normalize.cc":{"checkedAt":1794532120987,"integrity":"sha512-BFPQx787Tyv1E4rehu5ULwOFvoj+pSYGGYZsu0HIj5/X5ZtU0lCje0byi/3ol+PcHUqxq01flEldjKYA3RtVSQ==","mode":420,"size":9319},"csrc/enc/streams.cc":{"checkedAt":1794532120987,"integrity":"sha512-6ylOWYNMWjpem1kmBC9bq8j87DQU5Dj1qr7jHHspQo5+bqoEB27jJylkHfQXAI7iwCAc/FkdOCxIg9LGQLVZpg==","mode":420,"size":2959},"csrc/woff2/table_tags.cc":{"checkedAt":1794532120987,"integrity":"sha512-YlH4DaATWFJYfW/8AkWLYOXJRlmqRmq6Eom0Rd9iU2+j/WAaHBAjJJryXCc9CFZAMNN1IGNzGRoOZ6qv3AcP7g==","mode":420,"size":2995},"csrc/woff2/transform.cc":{"checkedAt":1794532120988,"integrity":"sha512-2kum1BDgUvuINCOpfOsJaRlYhhgWibm2U7vqp7mbFcxgMv8Iu5V/4J7Ba8dBCGqDjxnv1wPeKoYegbTwn4Gbjg==","mode":420,"size":9653},"csrc/woff2/variable_length.cc":{"checkedAt":1794532120988,"integrity":"sha512-CpiKER334MoruVrAAfNBYHx9AZyU31HGSJHAHAQh3xMiViRLurLq1c1z+3yny1KHXsyduYCGHmABuhm2AQY6Iw==","mode":420,"size":3479},"csrc/woff2/woff2_common.cc":{"checkedAt":1794532120988,"integrity":"sha512-1JtJBTyrkLOveEPpXNw9p4o0MmjuOxRFTe7BgT3dwAs+Ql/DeIXM0DVGop17de93kEZc22efsTVJpKhqJ9aRAQ==","mode":420,"size":1438},"csrc/woff2/woff2_dec.cc":{"checkedAt":1794532120988,"integrity":"sha512-GdaaWxikucw+82jGAQtz2ljS13iitxvlSnmqTum2Ofkmct/CwVpACql+hA3JqIjSaSMPbyImzruCG2RceTJ04w==","mode":420,"size":37531},"csrc/woff2/woff2_enc.cc":{"checkedAt":1794532120988,"integrity":"sha512-+E1xympvbznivwta3N2XiDY7qYu3RhcvDQEMASql6sw9C/K7wMwkt0uHHwOJK75gEgkM8CntlvipqbI7zH8uIQ==","mode":420,"size":14853},"csrc/enc/streams.h.gch":{"checkedAt":1794532120994,"integrity":"sha512-VWPNwJk70xGtMpRLDjhrncfEaMv3HC8vFj1SSAaooHU8U6cexXmXl+N1ahVN6zo0siWao3e9baIiujl07IUNnQ==","mode":420,"size":2468344},"binding.gyp":{"checkedAt":1794532120994,"integrity":"sha512-CdUT1x7PoLfDgE2bP4oyCCyAX2YgfdVwZSZiV8iY8o37NQWF/5LQ7NgI77aFQkqTkE5bkcUdCdoiyTE9Cn7qIw==","mode":420,"size":1154},"csrc/enc/backward_references.h":{"checkedAt":1794532120994,"integrity":"sha512-aBNAA2IslrgRWWxqqZrknx/6QEBpOK5MXakhVX8Hcko4WfvjaLqQ5YllwRnx/uq24UBoWykIidcxDhkRyonyNg==","mode":420,"size":1695},"csrc/enc/bit_cost.h":{"checkedAt":1794532120994,"integrity":"sha512-cTP/F+OLtCy0Vs5yST4IwUDI3kBB1Xz5bGJWl6FrJd/kGoIFMRNYdUh86dBWrL/QPe6gi0M2YPuSMja9IFfyOw==","mode":420,"size":4254},"csrc/enc/block_splitter.h":{"checkedAt":1794532120994,"integrity":"sha512-obvUVma+auLine truncated
Loaded 100 of 35554 files, more files were not shown because too many files have changed in this diff. Show more